You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@netbeans.apache.org by "johntor (via GitHub)" <gi...@apache.org> on 2023/01/30 14:42:15 UTC

[GitHub] [netbeans] johntor opened a new pull request, #5391: Fix POM Graph colors for dark themes

johntor opened a new pull request, #5391:
URL: https://github.com/apache/netbeans/pull/5391

   I noticed a problem using the Graph of a POM when a dark theme is selected.
   
   The foreground color was requested from the Theme while backgrounds are hardcoded into the Class causing printing WHITE on Bright Colors.
   
   With this fix I added transparency to these hardcoded colors so the become darker on darker backgrounds.
   
   I also removed gradients that looked a bit outdated to my eyes.
   
   ![215498346-c8cecdd1-e0a5-4354-9998-9b0bc4ad6ab9](https://user-images.githubusercontent.com/478884/215508015-3706e750-45d7-43ab-a1a5-c4cccd1448db.png)
   
   


-- 
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: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

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


[GitHub] [netbeans] mbien commented on pull request #5391: Fix POM Graph colors for dark themes

Posted by "mbien (via GitHub)" <gi...@apache.org>.
mbien commented on PR #5391:
URL: https://github.com/apache/netbeans/pull/5391#issuecomment-1411064073

   squashed, reverted formatting and force pushed


-- 
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: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

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


[GitHub] [netbeans] mbien commented on pull request #5391: Fix POM Graph colors for dark themes

Posted by "mbien (via GitHub)" <gi...@apache.org>.
mbien commented on PR #5391:
URL: https://github.com/apache/netbeans/pull/5391#issuecomment-1409044597

   hi @johntor, thanks for working on this.
   
   it certainly does look much better and I agree the gradients have to go given that NetBeans is using a theme called **Flat** LAF  by default :)
   
   However, I still see problems with FlatLAF dark, what theme are you using since your screenshorts show white font on dark background.
   
   (FlatLaf dark, items in graph don't have focus)
   before PR:
   ![before-unfocussed](https://user-images.githubusercontent.com/114367/215551074-2274312a-f146-4daf-a185-82a8b4396c7c.png)
   
   
   after PR:
   ![after-unfocussed](https://user-images.githubusercontent.com/114367/215551094-e055a07a-5137-4ae9-8e48-e05057906f05.png)
   


-- 
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: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

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


[GitHub] [netbeans] mbien commented on pull request #5391: Fix POM Graph colors for dark themes

Posted by "mbien (via GitHub)" <gi...@apache.org>.
mbien commented on PR #5391:
URL: https://github.com/apache/netbeans/pull/5391#issuecomment-1409614007

   > Hello again I think is fine now but how am I supposed to update the file and how I force my pull request?
   
   you have now two commits, I think the easiest option in this particular case is to remove the last commit again with:
   
   ```
   git reset HEAD^
   ```
   This will only remove the commit, the changes you made will remain in the source code.
   
   Now you can simply commit with NetBeans again but check the `Amend last Commit` checkbox, this will add the changes to the first commit, instead of creating a second one again - basically updating the commit.
   
   To replace the remote `delivery` branch with your local `delivery` branch you type in a console:
   ```
   git push -f git@github.com:johntor/netbeans delivery:delivery
   ```
   


-- 
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: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

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


[GitHub] [netbeans] mbien commented on pull request #5391: Fix POM Graph colors for dark themes

Posted by "mbien (via GitHub)" <gi...@apache.org>.
mbien commented on PR #5391:
URL: https://github.com/apache/netbeans/pull/5391#issuecomment-1410750212

   > You create a palette of background colours that works with black-ish text, and one that works with white-ish text. Working on something similar with the visual library myself at the moment.
   
   If the background would be theme aware - the foreground must be theme aware too, I agree.
   
   But in this particular case the background fill colors (red/orange) already work with dark/light themes, additionally to that the boxes have an outline which is controlled by the theme - which makes it extra resistant to clash with theme colors. So the main problem here was that some boxes set the background fill without setting the font color. That is the reason I said I do not think the logic has to be aware of the theme at all - it only has to follow the rule to not pick the foreground from a theme color while hard coding the background. 
   
   The visual for "Scopes" will need more work since it used to be a gradient but this is outside the scope of this PR :) (I don't think it will look good in any color the way it is currently rendered as simple box in a box)


-- 
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: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

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


[GitHub] [netbeans] mbien commented on pull request #5391: Fix POM Graph colors for dark themes

Posted by "mbien (via GitHub)" <gi...@apache.org>.
mbien commented on PR #5391:
URL: https://github.com/apache/netbeans/pull/5391#issuecomment-1412407363

   @johntor congrats on your first contribution.


-- 
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: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

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


[GitHub] [netbeans] neilcsmith-net commented on pull request #5391: Fix POM Graph colors for dark themes

Posted by "neilcsmith-net (via GitHub)" <gi...@apache.org>.
neilcsmith-net commented on PR #5391:
URL: https://github.com/apache/netbeans/pull/5391#issuecomment-1411011910

   > A side note for @neilcsmith-net: aren't "release candidate" versions supposed to be very stable, with only critical bugfixes going into them?
   
   Bug fixes until rc3, only critical fixes afterwards - https://lists.apache.org/thread/hyjbsz55zb9xfcnccghkrsvqsnt83nwf
   
   Yes, there are risks to lower priority fixes, but it's worth it to improve the release experience IMO.


-- 
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: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

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


[GitHub] [netbeans] eirikbakke commented on pull request #5391: Fix POM Graph colors for dark themes

Posted by "eirikbakke (via GitHub)" <gi...@apache.org>.
eirikbakke commented on PR #5391:
URL: https://github.com/apache/netbeans/pull/5391#issuecomment-1410995584

   @mbien Yeah, I trust your judgment here.
   
   (I just remember having made "cosmetic-only" patches like this myself only to find I introduced a NullPointerException somewhere a week later...)


-- 
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: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

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


[GitHub] [netbeans] neilcsmith-net commented on pull request #5391: Fix POM Graph colors for dark themes

Posted by "neilcsmith-net (via GitHub)" <gi...@apache.org>.
neilcsmith-net commented on PR #5391:
URL: https://github.com/apache/netbeans/pull/5391#issuecomment-1409159812

   Yes, two hard coded colours for each pallette option based on value of `nb.dark.theme` boolean from UIManager might be way to go, at least for a quick fix.


-- 
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: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

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


[GitHub] [netbeans] johntor commented on a diff in pull request #5391: Fix POM Graph colors for dark themes

Posted by "johntor (via GitHub)" <gi...@apache.org>.
johntor commented on code in PR #5391:
URL: https://github.com/apache/netbeans/pull/5391#discussion_r1092420694


##########
java/java.graph/src/org/netbeans/modules/java/graph/NodeWidget.java:
##########
@@ -78,13 +77,18 @@
     private static final int RIGHT_TOP = 3;
     private static final int RIGHT_BOTTOM = 4;
 
-    private static final @StaticResource String LOCK_ICON = "org/netbeans/modules/java/graph/resources/lock.png";
-    private static final @StaticResource String LOCK_BROKEN_ICON = "org/netbeans/modules/java/graph/resources/lock-broken.png";
-    private static final @StaticResource String BULB_ICON = "org/netbeans/modules/java/graph/resources/bulb.gif";
-    private static final @StaticResource String BULB_HIGHLIGHT_ICON = "org/netbeans/modules/java/graph/resources/bulb-highlight.gif";
+    private static final @StaticResource
+    String LOCK_ICON = "org/netbeans/modules/java/graph/resources/lock.png";
+    private static final @StaticResource
+    String LOCK_BROKEN_ICON = "org/netbeans/modules/java/graph/resources/lock-broken.png";
+    private static final @StaticResource
+    String BULB_ICON = "org/netbeans/modules/java/graph/resources/bulb.gif";
+    private static final @StaticResource
+    String BULB_HIGHLIGHT_ICON = "org/netbeans/modules/java/graph/resources/bulb-highlight.gif";

Review Comment:
   My Netbeans autoformatter has different setting than yours!



-- 
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: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

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


[GitHub] [netbeans] mbien commented on pull request #5391: Fix POM Graph colors for dark themes

Posted by "mbien (via GitHub)" <gi...@apache.org>.
mbien commented on PR #5391:
URL: https://github.com/apache/netbeans/pull/5391#issuecomment-1411069792

   @eirikbakke @neilcsmith-net I am willing to accept this one as my side quest, if it causes followup problems assign issues to me.


-- 
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: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

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


[GitHub] [netbeans] neilcsmith-net merged pull request #5391: Fix POM Graph colors for dark themes

Posted by "neilcsmith-net (via GitHub)" <gi...@apache.org>.
neilcsmith-net merged PR #5391:
URL: https://github.com/apache/netbeans/pull/5391


-- 
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: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

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


[GitHub] [netbeans] johntor commented on pull request #5391: Fix POM Graph colors for dark themes

Posted by "johntor (via GitHub)" <gi...@apache.org>.
johntor commented on PR #5391:
URL: https://github.com/apache/netbeans/pull/5391#issuecomment-1411010849

   I am sorry that I have no time to completed this Pull Request till the end right now...  (busy at work)
   Can anybody else take care of it?
   I promise next time I will complete the work all the way...
   Thank you all!
   Keep on your great job!


-- 
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: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

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


[GitHub] [netbeans] mbien commented on pull request #5391: Fix POM Graph colors for dark themes

Posted by "mbien (via GitHub)" <gi...@apache.org>.
mbien commented on PR #5391:
URL: https://github.com/apache/netbeans/pull/5391#issuecomment-1411016338

   @johntor no worries. I can take over. Will remove the formatting changes and force push into this PR. Thanks for your work!
   
   This might add me as co author to the commit. Lets see how this works.


-- 
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: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

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


[GitHub] [netbeans] mbien commented on pull request #5391: Fix POM Graph colors for dark themes

Posted by "mbien (via GitHub)" <gi...@apache.org>.
mbien commented on PR #5391:
URL: https://github.com/apache/netbeans/pull/5391#issuecomment-1409094412

   @johntor would be great. Simply force push into this PR if you want to make changes.
   
   I believe the font color might need to be hard coded if the custom (non-standard) background fill is active - otherwise there gonna be always some theme which will clash.


-- 
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: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

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


[GitHub] [netbeans] johntor commented on pull request #5391: Fix POM Graph colors for dark themes

Posted by "johntor (via GitHub)" <gi...@apache.org>.
johntor commented on PR #5391:
URL: https://github.com/apache/netbeans/pull/5391#issuecomment-1409108580

   Yes I was thinking determining if the theme is light/dark then apply fixed black/white colors for fonts 


-- 
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: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

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


[GitHub] [netbeans] mbien commented on pull request #5391: Fix POM Graph colors for dark themes

Posted by "mbien (via GitHub)" <gi...@apache.org>.
mbien commented on PR #5391:
URL: https://github.com/apache/netbeans/pull/5391#issuecomment-1409067237

   the scope markers are now also painted as solid blocks which is going to need some tweaks too:
   ![scope-after](https://user-images.githubusercontent.com/114367/215555703-fa8b5b2e-c199-410c-b771-af60e29fd198.png)
   (Cupertino Dark, scopes set to Test)


-- 
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: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

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


[GitHub] [netbeans] johntor commented on pull request #5391: Fix POM Graph colors for dark themes

Posted by "johntor (via GitHub)" <gi...@apache.org>.
johntor commented on PR #5391:
URL: https://github.com/apache/netbeans/pull/5391#issuecomment-1409585787

   Hello again I think is fine now but how am I supposed to update the file and how I force my pull request? 
   
   ![Image](https://user-images.githubusercontent.com/478884/215630500-d78ecbdf-3a16-4638-8400-25b7abe5d62d.png)
   
   ![Image (1)](https://user-images.githubusercontent.com/478884/215630519-0f942cae-8fc6-48a4-88ce-1a29e4765885.png)
   
   ![Image (3)](https://user-images.githubusercontent.com/478884/215630531-f582e458-8e50-4177-9dac-fc8580686a09.png)
   


-- 
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: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

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


[GitHub] [netbeans] johntor commented on pull request #5391: Fix POM Graph colors for dark themes

Posted by "johntor (via GitHub)" <gi...@apache.org>.
johntor commented on PR #5391:
URL: https://github.com/apache/netbeans/pull/5391#issuecomment-1412549827

   > @johntor congrats on your first contribution.
   
   Thank you very much! I thought contributing to a complicated project like Netbeans is too difficult... I realized that I was wrong!
   
   I will be back!
   
   Take care! 


-- 
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: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

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


[GitHub] [netbeans] mbien commented on pull request #5391: Fix POM Graph colors for dark themes

Posted by "mbien (via GitHub)" <gi...@apache.org>.
mbien commented on PR #5391:
URL: https://github.com/apache/netbeans/pull/5391#issuecomment-1409174949

   > Yes, two hard coded colours for each pallette option based on value of `nb.dark.theme` boolean from UIManager might be way to go, at least for a quick fix.
   
   i don't think any of this needs to know if the dark theme is active or not if it follows the simple rule of changing both, foreground and background at the same time but never only one of them while leaving the other to the theme.


-- 
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: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

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


[GitHub] [netbeans] johntor commented on a diff in pull request #5391: Fix POM Graph colors for dark themes

Posted by "johntor (via GitHub)" <gi...@apache.org>.
johntor commented on code in PR #5391:
URL: https://github.com/apache/netbeans/pull/5391#discussion_r1092419589


##########
java/java.graph/src/org/netbeans/modules/java/graph/NodeWidget.java:
##########
@@ -178,48 +184,52 @@ public String getConflictTooltip(GraphNode<I> node) {
             String version = scene.getVersion(firstConflict);
             String requester = parent != null ? parent.getName() : "???";
             tooltip.append(conflictType == VERSION_CONFLICT ? TIP_SingleConflict(version, requester) : TIP_SingleWarning(version, requester));
-        } else if (conflictCount > 1) {
-            tooltip.append(conflictType == VERSION_CONFLICT ? TIP_MultipleConflict() : TIP_MultipleWarning());
-            for (I nd : node.getDuplicatesOrConflicts()) {
-                if (scene.isConflict(nd)) {
-                    tooltip.append("<tr><td>");
-                    tooltip.append(scene.getVersion(nd));
-                    tooltip.append("</td>");
-                    tooltip.append("<td>");
-                    GraphNodeImplementation parent = nd.getParent();
-                    if (parent != null) {
+        } else {
+            if (conflictCount > 1) {

Review Comment:
   Fixed



-- 
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: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

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


[GitHub] [netbeans] neilcsmith-net commented on pull request #5391: Fix POM Graph colors for dark themes

Posted by "neilcsmith-net (via GitHub)" <gi...@apache.org>.
neilcsmith-net commented on PR #5391:
URL: https://github.com/apache/netbeans/pull/5391#issuecomment-1410029826

   > i don't think any of this needs to know if the dark theme is active or not if it follows the simple rule of changing both, foreground and background at the same time but never only one of them while leaving the other to the theme.
   
   You create a palette of background colours that works with black-ish text, and one that works with white-ish text.  Working on something similar with the visual library myself at the moment.
   
   However, this fix looks good for now.  If we can get it amended and force pushed as above, we can merge later today for 17-rc3.


-- 
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: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

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


[GitHub] [netbeans] eirikbakke commented on a diff in pull request #5391: Fix POM Graph colors for dark themes

Posted by "eirikbakke (via GitHub)" <gi...@apache.org>.
eirikbakke commented on code in PR #5391:
URL: https://github.com/apache/netbeans/pull/5391#discussion_r1092400107


##########
java/java.graph/src/org/netbeans/modules/java/graph/NodeWidget.java:
##########
@@ -254,16 +264,34 @@ void updatePaintContent() {
                 foreC = Color.LIGHT_GRAY;
             }
             if (isDisabled) {
-                foreC = new Color ((int)(foreC.getAlpha() / 1.3f), foreC.getRed(),
-                        foreC.getGreen(), foreC.getBlue());
+                foreC = new Color(foreC.getRed(), foreC.getGreen(), foreC.getBlue(), (int) (foreC.getAlpha() / 1.3f));
             }
         }
-
-        contentW.setBorder(BorderFactory.createLineBorder(10, foreC));
         nodeW.setForeground(foreC);
-        if(versionW != null) {
+        DependencyGraphScene scene = getDependencyGraphScene();
+        int conflictType = scene.supportsVersions() ? node.getConflictType(scene::isConflict, scene::compareVersions) : VERSION_NO_CONFLICT;
+        if (isHighlighted) {
+            nodeW.getLabelWidget().setForeground(Color.BLACK);
+        } else {
+            nodeW.getLabelWidget().setForeground(origForeground);
+//      if (paintState != EdgeWidget.GRAYED) {

Review Comment:
   Commented code here should be removed.



##########
java/java.graph/src/org/netbeans/modules/java/graph/NodeWidget.java:
##########
@@ -78,13 +77,18 @@
     private static final int RIGHT_TOP = 3;
     private static final int RIGHT_BOTTOM = 4;
 
-    private static final @StaticResource String LOCK_ICON = "org/netbeans/modules/java/graph/resources/lock.png";
-    private static final @StaticResource String LOCK_BROKEN_ICON = "org/netbeans/modules/java/graph/resources/lock-broken.png";
-    private static final @StaticResource String BULB_ICON = "org/netbeans/modules/java/graph/resources/bulb.gif";
-    private static final @StaticResource String BULB_HIGHLIGHT_ICON = "org/netbeans/modules/java/graph/resources/bulb-highlight.gif";
+    private static final @StaticResource
+    String LOCK_ICON = "org/netbeans/modules/java/graph/resources/lock.png";
+    private static final @StaticResource
+    String LOCK_BROKEN_ICON = "org/netbeans/modules/java/graph/resources/lock-broken.png";
+    private static final @StaticResource
+    String BULB_ICON = "org/netbeans/modules/java/graph/resources/bulb.gif";
+    private static final @StaticResource
+    String BULB_HIGHLIGHT_ICON = "org/netbeans/modules/java/graph/resources/bulb-highlight.gif";

Review Comment:
   These formatting changes can be left out of the patch.



##########
java/java.graph/src/org/netbeans/modules/java/graph/NodeWidget.java:
##########
@@ -102,25 +106,27 @@
 
     private String tooltipText;
     private final WidgetAction fixConflictAction;
-    private final WidgetAction sceneHoverActionAction; 
-    
+    private final WidgetAction sceneHoverActionAction;
+
     // for use from FruchtermanReingoldLayout
-    public double locX, locY, dispX, dispY; 
-    private boolean fixed; 
-    
-    NodeWidget(@NonNull DependencyGraphScene scene, GraphNode<I> node, final Action fixConflictAction, final WidgetAction sceneHoverActionAction) {        
+    public double locX, locY, dispX, dispY;
+    private boolean fixed;
+
+    NodeWidget(@NonNull DependencyGraphScene scene, GraphNode<I> node, final Action fixConflictAction, final WidgetAction sceneHoverActionAction) {
         super(scene);
         Parameters.notNull("node", node);
-        if(fixConflictAction != null) {
+        if (fixConflictAction != null) {

Review Comment:
   Nit: Lots of whitespace changes in this commit makes it hard to review the real changes. It's a good idea to put whitespace changes in a separate commit (though no need to change it now).



##########
java/java.graph/src/org/netbeans/modules/java/graph/NodeWidget.java:
##########
@@ -484,50 +511,55 @@ protected void notifyStateChanged(ObjectState previousState, ObjectState state)
                 enlargedFromHover = false;
             }
         }
-        
+
         if (previousState.isSelected() != state.isSelected()) {
             updateNeeded = true;
         }
 
         if (updateNeeded) {
             updateContent();
-        } else if (repaintNeeded) {
-            repaint();
+        } else {
+            if (repaintNeeded) {
+                repaint();
+            }
         }
 
     }
 
-    @Override public void actionPerformed(ActionEvent e) {
+    @Override
+    public void actionPerformed(ActionEvent e) {
         enlargedFromHover = true;
         updateContent();
     }
 
-    public void setReadable (boolean readable) {
+    public void setReadable(boolean readable) {
         if (this.readable == readable) {
             return;
         }
         this.readable = readable;
         updateContent();
     }
 
-    public boolean isReadable () {
+    public boolean isReadable() {
         return readable;
     }
 
-    public GraphNode getNode () {
+    public GraphNode getNode() {
         return node;
     }
 
     /**
-     * readable widgets are calculated  based on scene zoom factor when zoom factor changes, the readable scope should too
+     * readable widgets are calculated based on scene zoom factor when zoom
+     * factor
+     * changes, the readable scope should too

Review Comment:
   Unintended formatting change?



##########
java/java.graph/src/org/netbeans/modules/java/graph/NodeWidget.java:
##########
@@ -484,50 +511,55 @@ protected void notifyStateChanged(ObjectState previousState, ObjectState state)
                 enlargedFromHover = false;
             }
         }
-        
+
         if (previousState.isSelected() != state.isSelected()) {
             updateNeeded = true;
         }
 
         if (updateNeeded) {
             updateContent();
-        } else if (repaintNeeded) {
-            repaint();
+        } else {
+            if (repaintNeeded) {

Review Comment:
   Another case of an "else if" becoming a nested if...



##########
java/java.graph/src/org/netbeans/modules/java/graph/NodeWidget.java:
##########
@@ -178,48 +184,52 @@ public String getConflictTooltip(GraphNode<I> node) {
             String version = scene.getVersion(firstConflict);
             String requester = parent != null ? parent.getName() : "???";
             tooltip.append(conflictType == VERSION_CONFLICT ? TIP_SingleConflict(version, requester) : TIP_SingleWarning(version, requester));
-        } else if (conflictCount > 1) {
-            tooltip.append(conflictType == VERSION_CONFLICT ? TIP_MultipleConflict() : TIP_MultipleWarning());
-            for (I nd : node.getDuplicatesOrConflicts()) {
-                if (scene.isConflict(nd)) {
-                    tooltip.append("<tr><td>");
-                    tooltip.append(scene.getVersion(nd));
-                    tooltip.append("</td>");
-                    tooltip.append("<td>");
-                    GraphNodeImplementation parent = nd.getParent();
-                    if (parent != null) {
+        } else {
+            if (conflictCount > 1) {

Review Comment:
   Why did the "else if" become a separate "if" here?



-- 
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: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

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


[GitHub] [netbeans] johntor commented on pull request #5391: Fix POM Graph colors for dark themes

Posted by "johntor (via GitHub)" <gi...@apache.org>.
johntor commented on PR #5391:
URL: https://github.com/apache/netbeans/pull/5391#issuecomment-1410961383

   I think current solution is simple and efficient for any color theme. Keep in mind the new feature of changing the colors of Flat Laf. 
   
   This solution is adaptioning theme colors while keeping original colors with BLACK foreground to boxes with background yellow orange and red. 


-- 
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: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

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


[GitHub] [netbeans] johntor commented on a diff in pull request #5391: Fix POM Graph colors for dark themes

Posted by "johntor (via GitHub)" <gi...@apache.org>.
johntor commented on code in PR #5391:
URL: https://github.com/apache/netbeans/pull/5391#discussion_r1092420936


##########
java/java.graph/src/org/netbeans/modules/java/graph/NodeWidget.java:
##########
@@ -102,25 +106,27 @@
 
     private String tooltipText;
     private final WidgetAction fixConflictAction;
-    private final WidgetAction sceneHoverActionAction; 
-    
+    private final WidgetAction sceneHoverActionAction;
+
     // for use from FruchtermanReingoldLayout
-    public double locX, locY, dispX, dispY; 
-    private boolean fixed; 
-    
-    NodeWidget(@NonNull DependencyGraphScene scene, GraphNode<I> node, final Action fixConflictAction, final WidgetAction sceneHoverActionAction) {        
+    public double locX, locY, dispX, dispY;
+    private boolean fixed;
+
+    NodeWidget(@NonNull DependencyGraphScene scene, GraphNode<I> node, final Action fixConflictAction, final WidgetAction sceneHoverActionAction) {
         super(scene);
         Parameters.notNull("node", node);
-        if(fixConflictAction != null) {
+        if (fixConflictAction != null) {

Review Comment:
   My Netbeans autoformatter has different setting than yours!



-- 
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: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

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


[GitHub] [netbeans] mbien commented on pull request #5391: Fix POM Graph colors for dark themes

Posted by "mbien (via GitHub)" <gi...@apache.org>.
mbien commented on PR #5391:
URL: https://github.com/apache/netbeans/pull/5391#issuecomment-1410978551

   > (A side note for @neilcsmith-net: aren't "release candidate" versions supposed to be very stable, with only critical bugfixes going into them? Patches like these benefit from being tested for a few weeks in dev environments before going into production.)
   
   @eirikbakke well the colors and gradients were borderline unreadable before, so the bar is lower here for a hotfix. This is only a UI change which removes gradients and tweaks colors so it has low risk to cause trouble. I agree with the formatting changes which were added by the second commit - those should be reverted.


-- 
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: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

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


[GitHub] [netbeans] johntor commented on a diff in pull request #5391: Fix POM Graph colors for dark themes

Posted by "johntor (via GitHub)" <gi...@apache.org>.
johntor commented on code in PR #5391:
URL: https://github.com/apache/netbeans/pull/5391#discussion_r1092421621


##########
java/java.graph/src/org/netbeans/modules/java/graph/NodeWidget.java:
##########
@@ -254,16 +264,34 @@ void updatePaintContent() {
                 foreC = Color.LIGHT_GRAY;
             }
             if (isDisabled) {
-                foreC = new Color ((int)(foreC.getAlpha() / 1.3f), foreC.getRed(),
-                        foreC.getGreen(), foreC.getBlue());
+                foreC = new Color(foreC.getRed(), foreC.getGreen(), foreC.getBlue(), (int) (foreC.getAlpha() / 1.3f));
             }
         }
-
-        contentW.setBorder(BorderFactory.createLineBorder(10, foreC));
         nodeW.setForeground(foreC);
-        if(versionW != null) {
+        DependencyGraphScene scene = getDependencyGraphScene();
+        int conflictType = scene.supportsVersions() ? node.getConflictType(scene::isConflict, scene::compareVersions) : VERSION_NO_CONFLICT;
+        if (isHighlighted) {
+            nodeW.getLabelWidget().setForeground(Color.BLACK);
+        } else {
+            nodeW.getLabelWidget().setForeground(origForeground);
+//      if (paintState != EdgeWidget.GRAYED) {

Review Comment:
   Fixed



-- 
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: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

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


[GitHub] [netbeans] neilcsmith-net commented on pull request #5391: Fix POM Graph colors for dark themes

Posted by "neilcsmith-net (via GitHub)" <gi...@apache.org>.
neilcsmith-net commented on PR #5391:
URL: https://github.com/apache/netbeans/pull/5391#issuecomment-1411101588

   Thanks @johntor and @mbien Will merge tomorrow.
   
   @mbien given my comments on #5390 asking for it to be rebased, we can share any side quest 😆 


-- 
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: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

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


[GitHub] [netbeans] johntor commented on pull request #5391: Fix POM Graph colors for dark themes

Posted by "johntor (via GitHub)" <gi...@apache.org>.
johntor commented on PR #5391:
URL: https://github.com/apache/netbeans/pull/5391#issuecomment-1409188514

   > > Yes, two hard coded colours for each pallette option based on value of `nb.dark.theme` boolean from UIManager might be way to go, at least for a quick fix.
   > 
   > i don't think any of this needs to know if the dark theme is active or not if it follows the simple rule of changing both, foreground and background at the same time but never only one of them while leaving the other to the theme.
   
   Then we have problems to apply your light-grey text over orange or yellow. I will go with the hardcoded solution and we see how it goes...


-- 
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: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

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


[GitHub] [netbeans] mbien commented on pull request #5391: Fix POM Graph colors for dark themes

Posted by "mbien (via GitHub)" <gi...@apache.org>.
mbien commented on PR #5391:
URL: https://github.com/apache/netbeans/pull/5391#issuecomment-1409194182

   > Then we have problems to apply your light-grey text over orange or yellow.
   
   why would you do that? I am trying to say that if you change the background to orange, you have to change the text to a color which fits to orange. You can't leave the text color up to the theme.


-- 
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: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

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


[GitHub] [netbeans] johntor commented on pull request #5391: Fix POM Graph colors for dark themes

Posted by "johntor (via GitHub)" <gi...@apache.org>.
johntor commented on PR #5391:
URL: https://github.com/apache/netbeans/pull/5391#issuecomment-1409079757

   I did not notice all these! If you like the idea of the removed gradients we can optimize the code more.


-- 
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: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

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


[GitHub] [netbeans] mbien commented on pull request #5391: Fix POM Graph colors for dark themes

Posted by "mbien (via GitHub)" <gi...@apache.org>.
mbien commented on PR #5391:
URL: https://github.com/apache/netbeans/pull/5391#issuecomment-1409117114

   > Yes I was thinking determining if the theme is light/dark then apply fixed black/white colors for fonts
   
   if the background is taken from the theme, its ok to take the font color from the theme too. But as soon the background is changed, for example when set to orange, the color can't be taken from the theme anymore - it has to fit to the orange background.
   
   I wouldn't hardcode all font colors, only conditional when the background actually changes.


-- 
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: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

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