1 30 31 package com.jgoodies.looks.plastic.theme; 32 33 import javax.swing.UIDefaults ; 34 import javax.swing.plaf.ColorUIResource ; 35 36 import com.jgoodies.looks.plastic.PlasticLookAndFeel; 37 import com.jgoodies.looks.plastic.PlasticScrollBarUI; 38 39 40 47 public class DesertBlue extends DesertBluer { 48 49 public String getName() { return "Desert Blue"; } 50 51 52 private static final ColorUIResource secondary2 = new ColorUIResource (148, 144, 140); 53 private static final ColorUIResource secondary3 = new ColorUIResource (211, 210, 204); 54 55 56 57 protected ColorUIResource getPrimary1() { return Colors.GRAY_DARK; } 58 protected ColorUIResource getPrimary2() { return Colors.BLUE_LOW_MEDIUM; } 59 protected ColorUIResource getPrimary3() { return Colors.BLUE_LOW_LIGHTEST; } 60 61 protected ColorUIResource getSecondary1() { return Colors.GRAY_MEDIUM;} 62 protected ColorUIResource getSecondary2() { return secondary2; } 63 protected ColorUIResource getSecondary3() { return secondary3; } 64 65 public ColorUIResource getTitleTextColor() { return Colors.BLUE_MEDIUM_DARKEST;} 66 67 public ColorUIResource getFocusColor() { 68 return PlasticLookAndFeel.useHighContrastFocusColors 69 ? Colors.YELLOW_FOCUS 70 : Colors.BLUE_MEDIUM_DARK; 71 } 72 public ColorUIResource getPrimaryControlShadow() { return getPrimary3(); } 74 public ColorUIResource getMenuItemSelectedBackground() { return getPrimary1(); } 75 76 public void addCustomEntriesToTable(UIDefaults table) { 77 super.addCustomEntriesToTable(table); 78 Object [] uiDefaults = { 79 "ScrollBar.is3DEnabled", Boolean.FALSE, 80 "ScrollBar.thumbHighlight", getPrimaryControlHighlight(), 81 PlasticScrollBarUI.MAX_BUMPS_WIDTH_KEY, null, 82 }; 83 table.putDefaults(uiDefaults); 84 } 85 86 87 } | Popular Tags |