- Timestamp:
- 2015-12-30T14:18:30+01:00 (9 years ago)
- Location:
- trunk/src/org/openstreetmap/josm/gui
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/openstreetmap/josm/gui/Notification.java
r8419 r9221 2 2 package org.openstreetmap.josm.gui; 3 3 4 import java.awt.Color; 4 5 import java.awt.Component; 5 6 6 7 import javax.swing.Icon; 8 import javax.swing.JEditorPane; 7 9 import javax.swing.JOptionPane; 8 10 import javax.swing.UIManager; … … 102 104 JMultilineLabel lbl = new JMultilineLabel(msg); 103 105 lbl.setMaxWidth(DEFAULT_CONTENT_WIDTH); 106 lbl.putClientProperty(JEditorPane.HONOR_DISPLAY_PROPERTIES, Boolean.TRUE); 107 lbl.setForeground(Color.BLACK); 104 108 content = lbl; 105 109 return this; -
trunk/src/org/openstreetmap/josm/gui/layer/AlignImageryPanel.java
r9135 r9221 45 45 nagLabel.setLabelFor(detailsList); 46 46 nagLabel.setFont(font); 47 nagLabel.setForeground(Color.BLACK); 47 48 detailsList.setFont(font); 48 49 final JCheckBox doNotShowAgain = new JCheckBox(tr("Do not show this message again")); 49 50 doNotShowAgain.setOpaque(false); 51 doNotShowAgain.setForeground(Color.BLACK); 50 52 51 53 JButton closeButton = new JButton(ImageProvider.get("misc", "black_x")); -
trunk/src/org/openstreetmap/josm/gui/preferences/display/ColorPreference.java
r9078 r9221 228 228 return new JLabel(); 229 229 if (column == 1) { 230 JLabel l = new JLabel(ColorHelper.color2html((Color) o)); 231 l.setBackground((Color) o); 230 Color c = (Color) o; 231 JLabel l = new JLabel(ColorHelper.color2html(c)); 232 l.setBackground(c); 233 // http://stackoverflow.com/a/3943023/2257172 234 l.setForeground((c.getRed()*0.299 + c.getGreen()*0.587 + c.getBlue()*0.114) > 186 ? 235 Color.BLACK : Color.WHITE); 232 236 l.setOpaque(true); 233 237 return l;
Note:
See TracChangeset
for help on using the changeset viewer.