mbien commented on PR #7930:
URL: https://github.com/apache/netbeans/pull/7930#issuecomment-2573830273

   @troizet while looking through other code, I noticed NB has a boolean 
property for dark themes, we can use that for having a different blend value 
based on dark/light themes:
   
   ```diff
   diff --git 
a/platform/core.multitabs/src/org/netbeans/core/multitabs/impl/FolderNameTabDecorator.java
 
b/platform/core.multitabs/src/org/netbeans/core/multitabs/impl/FolderNameTabDecorator.java
   index 421cdc9..f1a64fd 100644
   --- 
a/platform/core.multitabs/src/org/netbeans/core/multitabs/impl/FolderNameTabDecorator.java
   +++ 
b/platform/core.multitabs/src/org/netbeans/core/multitabs/impl/FolderNameTabDecorator.java
   @@ -124,10 +124,14 @@
        }
    
        private String fadeColor(Color f, Color b) {
   -        float a = 0.7f;
   +        float a = isDarkLaF() ? 0.7f : 0.6f;
            return String.format("#%02x%02x%02x", //NOI18N
                     (int)(b.getRed()   + a * (f.getRed()   - b.getRed())),
                     (int)(b.getGreen() + a * (f.getGreen() - b.getGreen())),
                     (int)(b.getBlue()  + a * (f.getBlue()  - b.getBlue())));
        }
   +    
   +    private static boolean isDarkLaF() {
   +        return UIManager.getBoolean("nb.dark.theme"); //NOI18N 
   +    }
    }
   ```
   
   I could force push into this PR if you want since I have it locally already 
anyway.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists

Reply via email to