[ Back | Previous | Next ]

How to change System colors of swing?

Package:
javax.swing.*
Product:
Swing
Release:
1.1.1
Related Links:
ComboBox
JDialog
JFileChooser
JFrame
JOptionPane
JProgressBar
JScrollPane
JTable
General
JTree
JWindow
KeyStroke
LayeredPane
UIDefaults
Comment:

UIDefaults defaults = UIManager.getDefaults();

     defaults.put("Label.font", a font goes here);
     defaults.put("Button.font", a font goes here);
     defaults.put("Panel.font", a font goes here);

Installing a new look and feel
Button ToggleButton, RadioButton, CheckBox The Rest
Colorchooser ComboBox FileChooser FileView InternalFrame
DesktopIcon Label List MenuBar MenuItem
RadioButtonMenuItem CheckBoxMenuItem Menu PopupMenu OptionPane
Panel ProgressBar Separator List ScrollPane
ScrollPane viewport Slider SplitPane TabbedPane Table
TableHeader TextField PasswordField TextPane TextArea
EditorPane TitledBorder Toolbar Tooltip tree

Keys and Values

Buttons
   Button.background                    com.sun.java.swing.plaf.ColorUIResource[r=204,g=204,b=204]
   Button.border                    com.sun.java.swing.plaf.BorderUIResource@75cf
   Button.disabled                    com.sun.java.swing.plaf.ColorUIResource[r=204,g=204,b=204]
   Button.disabledText                    com.sun.java.swing.plaf.ColorUIResource[r=153,g=153,b=153]
   Button.focus                    com.sun.java.swing.plaf.ColorUIResource[r=153,g=153,b=204]
   Button.font                    com.sun.java.swing.plaf.FontUIResource[family=Dialog,name=Dialog,style=bold,size=12]
   Button.foreground                    com.sun.java.swing.plaf.ColorUIResource[r=0,g=0,b=0]
   Button.pressed                    java.awt.Color[r=0,g=0,b=255]
   Button.pressed                    java.awt.Color[r=0,g=0,b=255]
   ButtonUI                    com.sun.java.swing.plaf.metal.MetalButtonUI


ToggleButton, RadioButton, CheckBox
   
   ToggleButton.background                    com.sun.java.swing.plaf.ColorUIResource[r=204,g=204,b=204]
   ToggleButton.border                    com.sun.java.swing.plaf.BorderUIResource@78d7
   ToggleButton.disabledBackground                    com.sun.java.swing.plaf.ColorUIResource[r=204,g=204,b=204]
   ToggleButton.disabledSelectedBackground                    com.sun.java.swing.plaf.ColorUIResource[r=153,g=153,b=153]
   ToggleButton.disabledSelectedText                    com.sun.java.swing.plaf.ColorUIResource[r=102,g=102,b=102]
   ToggleButton.disabledText                    com.sun.java.swing.plaf.ColorUIResource[r=153,g=153,b=153]
   ToggleButton.focus                    com.sun.java.swing.plaf.ColorUIResource[r=153,g=153,b=204]
   ToggleButton.font                    com.sun.java.swing.plaf.FontUIResource[family=Dialog,name=Dialog,style=bold,size=12]
   ToggleButton.foreground                    com.sun.java.swing.plaf.ColorUIResource[r=0,g=0,b=0]
   ToggleButton.pressed                    java.awt.Color[r=0,g=0,b=255]
   ToggleButton.pressed                    java.awt.Color[r=0,g=0,b=255]
   ToggleButton.selected                    com.sun.java.swing.plaf.ColorUIResource[r=153,g=153,b=153]
   ToggleButtonUI                    com.sun.java.swing.plaf.metal.MetalToggleButtonUI
   
   RadioButton.background                    com.sun.java.swing.plaf.ColorUIResource[r=204,g=204,b=204]
   RadioButton.border                    com.sun.java.swing.plaf.BorderUIResource@199f
   RadioButton.focus                    java.awt.Color[r=0,g=255,b=0]
   RadioButton.focus                    java.awt.Color[r=0,g=255,b=0]
   RadioButton.font                    com.sun.java.swing.plaf.FontUIResource[family=Dialog,name=Dialog,style=bold,size=12]
   RadioButton.foreground                    java.awt.Color[r=0,g=0,b=255]
   RadioButton.foreground                    java.awt.Color[r=0,g=0,b=255]
   RadioButton.icon                    com.sun.java.swing.plaf.metal.MetalIconFactory$RadioButtonIcon@4a7
   RadioButton.select                    java.awt.Color[r=0,g=0,b=255]
   RadioButtonMenuItem.icon                    com.sun.java.swing.plaf.metal.MetalIconFactory$RadioButtonMenuItemIcon@111
   RadioButtonMenuItemUI                    com.sun.java.swing.plaf.basic.BasicRadioButtonMenuItemUI
   RadioButtonUI                    com.sun.java.swing.plaf.metal.MetalRadioButtonUI
   
   CheckBox.background                    java.awt.Color[r=99,g=99,b=255]
   CheckBox.focus                    java.awt.Color[r=255,g=255,b=255]
   CheckBox.font                    com.sun.java.swing.plaf.FontUIResource[family=Dialog,name=Dialog,style=bold,size=12]
   CheckBox.icon                    com.sun.java.swing.plaf.metal.MetalCheckBoxIcon@51c6



ColorChooser

   ColorChooser.background                    com.sun.java.swing.plaf.ColorUIResource[r=204,g=204,b=204]
   ColorChooser.font                    com.sun.java.swing.plaf.FontUIResource[family=Dialog,name=Dialog,style=plain,size=12]
   ColorChooser.foreground                    com.sun.java.swing.plaf.ColorUIResource[r=0,g=0,b=0]
   ColorChooser.selectedColorBorder                    com.sun.java.swing.plaf.BorderUIResource@6387
   ColorChooserUI                    com.sun.java.swing.plaf.basic.BasicColorChooserUI
  
   ColorChooser.swatchesSwatchSize	Dimension
   ColorChooser.swatchesRecentSwatchSize	Dimension
   ColorChooser.swatchesDefaultRecentColor	ColorUIResource
   
   ColorChooser.rgbRedMnemonic	Integer(KeyEvent.VK_R)
   ColorChooser.rgbGreenMnemonic	Integer(KeyEvent.VK_G)
   ColorChooser.rgbBlueMnemonic	Integer(KeyEvent.VK_B)



ComboBox

   ComboBox.background                    com.sun.java.swing.plaf.ColorUIResource[r=204,g=204,b=204]
   ComboBox.disabledBackground                    com.sun.java.swing.plaf.ColorUIResource[r=204,g=204,b=204]
   ComboBox.disabledForeground                    com.sun.java.swing.plaf.ColorUIResource[r=153,g=153,b=153]
   ComboBox.editor                    com.sun.java.swing.plaf.metal.MetalComboBoxEditor$UIResource@7235
   ComboBox.font                    com.sun.java.swing.plaf.FontUIResource[family=Dialog,name=Dialog,style=bold,size=12]
   ComboBox.foreground                    com.sun.java.swing.plaf.ColorUIResource[r=0,g=0,b=0]
   ComboBox.listBackground                    com.sun.java.swing.plaf.ColorUIResource[r=204,g=204,b=204]
   ComboBox.listForeground                    com.sun.java.swing.plaf.ColorUIResource[r=0,g=0,b=0]
   ComboBox.renderer                    com.sun.java.swing.plaf.basic.BasicComboBoxRenderer$UIResource[,0,0,0x0,invalid]
   ComboBox.selectedBackground                    com.sun.java.swing.plaf.ColorUIResource[r=153,g=153,b=204]
   ComboBox.selectedForeground                    com.sun.java.swing.plaf.ColorUIResource[r=0,g=0,b=0]
   ComboBoxUI                    com.sun.java.swing.plaf.metal.MetalComboBoxUI


FileChooser

   FileChooser.acceptAllFileFilterText                    All Files (*.*)
   FileChooser.cancelButtonText                    Cancel
   FileChooser.cancelButtonToolTipText                    Abort file chooser dialog.
   FileChooser.detailsViewIcon                    com.sun.java.swing.plaf.metal.MetalIconFactory$FileChooserDetailViewIcon@6ab3
   FileChooser.helpButtonText                    Help
   FileChooser.helpButtonToolTipText                    FileChooser help.
   FileChooser.homeFolderIcon                    com.sun.java.swing.plaf.metal.MetalIconFactory$FileChooserHomeFolderIcon@6dab
   FileChooser.listViewIcon                    com.sun.java.swing.plaf.metal.MetalIconFactory$FileChooserListViewIcon@70a1
   FileChooser.newFolderIcon                    com.sun.java.swing.plaf.metal.MetalIconFactory$FileChooserNewFolderIcon@7399
   FileChooser.openButtonText                    Open
   FileChooser.openButtonToolTipText                    Open selected file.
   FileChooser.saveButtonText                    Save
   FileChooser.saveButtonToolTipText                    Save selected file.
   FileChooser.upFolderIcon                    com.sun.java.swing.plaf.metal.MetalIconFactory$FileChooserUpFolderIcon@768f
   FileChooser.updateButtonText                    Update
   FileChooser.updateButtonToolTipText                    Update directory listing.
   FileChooserUI                    com.sun.java.swing.plaf.metal.MetalFileChooserUI



FileView

   FileView.computerIcon                    com.sun.java.swing.plaf.metal.MetalIconFactory$TreeComputerIcon@61d3
   FileView.directoryIcon                    com.sun.java.swing.plaf.metal.MetalIconFactory$TreeFolderIcon@59d9
   FileView.fileIcon                    com.sun.java.swing.plaf.metal.MetalIconFactory$TreeLeafIcon@5edf
   FileView.floppyDriveIcon                    com.sun.java.swing.plaf.metal.MetalIconFactory$TreeFloppyDriveIcon@67bb
   FileView.hardDriveIcon                    com.sun.java.swing.plaf.metal.MetalIconFactory$TreeHardDriveIcon@64c7



InternalFrame

   InternalFrame.border                    com.sun.java.swing.plaf.BorderUIResource@1c9
   InternalFrame.closeIcon                    com.sun.java.swing.plaf.basic.BasicIconFactory$EmptyFrameIcon@74df
   InternalFrame.icon                    com.sun.java.swing.plaf.metal.MetalIconFactory$InternalFrameDefaultMenuIcon@6f4b
   InternalFrame.iconifyIcon                    com.sun.java.swing.plaf.basic.BasicIconFactory$EmptyFrameIcon@74df
   InternalFrame.maximizeIcon                    com.sun.java.swing.plaf.basic.BasicIconFactory$EmptyFrameIcon@74df
   InternalFrame.minimizeIcon                    com.sun.java.swing.plaf.basic.BasicIconFactory$EmptyFrameIcon@74df
   InternalFrame.titleFont                    com.sun.java.swing.plaf.FontUIResource[family=Dialog,name=Dialog,style=bold,size=12]
   InternalFrameTitlePane.altMaximizeIcon                    com.sun.java.swing.plaf.metal.MetalIconFactory$InternalFrameAltMaximizeIcon@1ab
   InternalFrameTitlePane.closeIcon                    com.sun.java.swing.plaf.metal.MetalIconFactory$InternalFrameCloseIcon@7b99
   InternalFrameTitlePane.font                    com.sun.java.swing.plaf.FontUIResource[family=Dialog,name=Dialog,style=bold,size=12]
   InternalFrameTitlePane.iconizeIcon                    com.sun.java.swing.plaf.metal.MetalIconFactory$InternalFrameMinimizeIcon@7ea8
   InternalFrameTitlePane.maximizeIcon                    com.sun.java.swing.plaf.metal.MetalIconFactory$InternalFrameMaximizeIcon@7ba7
   InternalFrameUI                    com.sun.java.swing.plaf.metal.MetalInternalFrameUI
   InternalFrame.titleFont	FontUIResource
  
   InternalFrame.activeTitleBackground	ColorUIResource
   InternalFrame.activeTitleForeground	ColorUIResource
   InternalFrame.inactiveTitleBackground	ColorUIResource
   InternalFrame.inactiveTitleForeground	ColorUIResource
   


DesktopIcon

  DesktopIcon.border	BorderUIResource
  
  Desktop.background	ColorUIResource



Label

   Label.background                    com.sun.java.swing.plaf.ColorUIResource[r=204,g=204,b=204]
   Label.disabled                    com.sun.java.swing.plaf.ColorUIResource[r=153,g=153,b=153]
   Label.disabledShadow                    com.sun.java.swing.plaf.ColorUIResource[r=153,g=153,b=153]
   Label.font                    com.sun.java.swing.plaf.FontUIResource[family=Dialog,name=Dialog,style=bold,size=12]
   Label.foreground                    java.awt.Color[r=0,g=0,b=255]
   Label.foreground                    java.awt.Color[r=0,g=0,b=255]
   LabelUI                    com.sun.java.swing.plaf.metal.MetalLabelUI


List

   List.background                    com.sun.java.swing.plaf.ColorUIResource[r=255,g=255,b=255]
   List.cellRenderer                    com.sun.java.swing.plaf.basic.BasicListCellRenderer$UIResource[,0,0,0x0,invalid]
   List.focusCellHighlightBorder                    com.sun.java.swing.plaf.BorderUIResource@4d6c
   List.font                    com.sun.java.swing.plaf.FontUIResource[family=Dialog,name=Dialog,style=plain,size=12]
   List.foreground                    com.sun.java.swing.plaf.ColorUIResource[r=0,g=0,b=0]
   List.selectionBackground                    com.sun.java.swing.plaf.ColorUIResource[r=204,g=204,b=255]
   List.selectionForeground                    com.sun.java.swing.plaf.ColorUIResource[r=0,g=0,b=0]
   ListUI                    com.sun.java.swing.plaf.basic.BasicListUI


MenuBar

   MenuBar.background                    com.sun.java.swing.plaf.ColorUIResource[r=204,g=204,b=204]
   MenuBar.border                    com.sun.java.swing.plaf.BorderUIResource@4cd
   MenuBar.font                    com.sun.java.swing.plaf.FontUIResource[family=Dialog,name=Dialog,style=bold,size=12]
   MenuBar.foreground                    com.sun.java.swing.plaf.ColorUIResource[r=0,g=0,b=0]
   MenuBarUI                    com.sun.java.swing.plaf.basic.BasicMenuBarUI


MenuItem

   MenuItem.acceleratorFont                    com.sun.java.swing.plaf.FontUIResource[family=Dialog,name=Dialog,style=plain,size=10]
   MenuItem.acceleratorForeground                    com.sun.java.swing.plaf.ColorUIResource[r=102,g=102,b=153]
   MenuItem.acceleratorPressedForeground                    com.sun.java.swing.plaf.ColorUIResource[r=0,g=0,b=0]
   MenuItem.arrowIcon                    com.sun.java.swing.plaf.metal.MetalIconFactory$MenuItemArrowIcon@7b25
   MenuItem.background                    com.sun.java.swing.plaf.ColorUIResource[r=204,g=204,b=204]
   MenuItem.border                    com.sun.java.swing.plaf.BorderUIResource@ad1
   MenuItem.borderPainted                    true
   MenuItem.checkIcon                    com.sun.java.swing.plaf.metal.MetalIconFactory$MenuItemCheckIcon@7831
   MenuItem.disabledForeground                    com.sun.java.swing.plaf.ColorUIResource[r=153,g=153,b=153]
   MenuItem.font                    com.sun.java.swing.plaf.FontUIResource[family=Dialog,name=Dialog,style=bold,size=12]
   MenuItem.foreground                    com.sun.java.swing.plaf.ColorUIResource[r=0,g=0,b=0]
   MenuItem.pressedBackground                    com.sun.java.swing.plaf.ColorUIResource[r=153,g=153,b=204]
   MenuItem.pressedForeground                    com.sun.java.swing.plaf.ColorUIResource[r=0,g=0,b=0]
   MenuItemUI                    com.sun.java.swing.plaf.basic.BasicMenuItemUI
   MenuItem.selectionForeground	ColorUIResource
   MenuItem.selectionBackground	ColorUIResource
   MenuItem.acceleratorSelectionForeground	ColorUIResource
   MenuItem.margin	InsetsUIResource
   MenuItem.checkIcon	Icon


RadioButtonMenuItem

  RadioButtonMenuItem.font	FontUIResource
  RadioButtonMenuItem.acceleratorFont	FontUIResource
  RadioButtonMenuItem.background	ColorUIResource
  RadioButtonMenuItem.foreground	ColorUIResource
  RadioButtonMenuItem.selectionForeground	ColorUIResource
  RadioButtonMenuItem.selectionBackground	ColorUIResource
  RadioButtonMenuItem.disabledForeground	 ColorUIResource 
  RadioButtonMenuItem.acceleratorForeground	 ColorUIResource 
  RadioButtonMenuItem.acceleratorSelectionForeground	ColorUIResource
  RadioButtonMenuItem.border	BorderUIResource
  RadioButtonMenuItem.borderPainted	Boolean
  RadioButtonMenuItem.margin	InsetsUIResource
  RadioButtonMenuItem.checkIcon	Icon
  RadioButtonMenuItem.arrowIcon	Icon


CheckBoxMenuItem

  CheckBoxMenuItem.font	FontUIResource
  CheckBoxMenuItem.acceleratorFont	FontUIResource
  CheckBoxMenuItem.background	 ColorUIResource 
  CheckBoxMenuItem.foreground	 ColorUIResource 
  CheckBoxMenuItem.selectionForeground	ColorUIResource
  CheckBoxMenuItem.selectionBackground	ColorUIResource
  CheckBoxMenuItem.disabledForeground	 ColorUIResource 
  CheckBoxMenuItem.acceleratorForeground	 ColorUIResource 
  CheckBoxMenuItem.acceleratorSelectionForeground	ColorUIResource
  CheckBoxMenuItem.border	BorderUIResource
  CheckBoxMenuItem.borderPainted	Boolean
  CheckBoxMenuItem.margin	InsetsUIResource
  CheckBoxMenuItem.checkIcon	Icon
  CheckBoxMenuItem.arrowIcon	Icon



Menu

   Menu.pressedBackground                    com.sun.java.swing.plaf.ColorUIResource[r=153,g=153,b=204]
   Menu.pressedForeground                    com.sun.java.swing.plaf.ColorUIResource[r=0,g=0,b=0]
   Menu.font	FontUIResource
   Menu.acceleratorFont	FontUIResource
   Menu.background	ColorUIResource
   Menu.foreground	ColorUIResource
   Menu.selectionForeground	ColorUIResource
   Menu.selectionBackground	ColorUIResource
   Menu.disabledForeground	null
   Menu.acceleratorForeground	ColorUIResource
   Menu.acceleratorSelectionForeground	ColorUIResource
   Menu.border	marginBorder
   Menu.borderPainted	Boolean
   Menu.margin	InsetsUIResource(2 2 2 2)
   Menu.checkIcon	menuItemCheckIcon
   Menu.arrowIcon	menuArrowIcon
   Menu.consumesTabs	Boolean



PopupMenu

   PopupMenu.background                    com.sun.java.swing.plaf.ColorUIResource[r=204,g=204,b=204]
   PopupMenu.border                    com.sun.java.swing.plaf.BorderUIResource@7cf
   PopupMenu.font                    com.sun.java.swing.plaf.FontUIResource[family=Dialog,name=Dialog,style=plain,size=12]
   PopupMenu.foreground                    com.sun.java.swing.plaf.ColorUIResource[r=0,g=0,b=0]
   PopupMenuUI                    com.sun.java.swing.plaf.basic.BasicPopupMenuUI



OptionPane

  OptionPane.font	FontUIResource
  OptionPane.background	ColorUIResource
  OptionPane.foreground	ColorUIResource
  OptionPane.messageForeground	ColorUIResource
  OptionPane.border	 BorderUIResource 
  OptionPane.messageAreaBorder	BorderUIResource
  OptionPane.buttonAreaBorder	BorderUIResource
  OptionPane.minimumSize	Integer
  OptionPane.errorIcon	Icon
  OptionPane.informationIcon	 Icon 
  OptionPane.warningIcon	 Icon 
  OptionPane.questionIcon	 Icon 



Panel

   Panel.background                    java.awt.Color[r=255,g=207,b=24]
   Panel.font                    com.sun.java.swing.plaf.FontUIResource[family=Dialog,name=Dialog,style=plain,size=12]
   Panel.foreground                    com.sun.java.swing.plaf.ColorUIResource[r=0,g=0,b=0]


ProgressBar

   ProgressBar.background                    com.sun.java.swing.plaf.ColorUIResource[r=204,g=204,b=204]
   ProgressBar.backgroundHighlight                    com.sun.java.swing.plaf.ColorUIResource[r=204,g=204,b=204]
   ProgressBar.border                    com.sun.java.swing.plaf.BorderUIResource@4d60
   ProgressBar.cellLength                    1
   ProgressBar.cellSpacing                    0
   ProgressBar.font                    com.sun.java.swing.plaf.FontUIResource[family=Dialog,name=Dialog,style=plain,size=12]
   ProgressBar.foreground                    com.sun.java.swing.plaf.ColorUIResource[r=153,g=153,b=204]
   ProgressBar.foregroundHighlight                    com.sun.java.swing.plaf.ColorUIResource[r=153,g=153,b=204]
   ProgressBarUI                    com.sun.java.swing.plaf.metal.MetalProgressBarUI
   ProgressBar.selectionForeground	ColorUIResource
   ProgressBar.selectionBackground	ColorUIResource


Separator

  Separator.shadow	 ColorUIResource 
  Separator.highlight	ColorUIResource



ScrollBar

   ScrollBar.background                    com.sun.java.swing.plaf.ColorUIResource[r=204,g=204,b=204]
   ScrollBar.foreground                    com.sun.java.swing.plaf.ColorUIResource[r=204,g=204,b=204]
   ScrollBar.highlight                    com.sun.java.swing.plaf.ColorUIResource[r=255,g=255,b=255]
   ScrollBar.shadow                    com.sun.java.swing.plaf.ColorUIResource[r=102,g=102,b=102]
   ScrollBar.thumb                    com.sun.java.swing.plaf.ColorUIResource[r=153,g=153,b=204]
   ScrollBar.thumbDarkShadow                    com.sun.java.swing.plaf.ColorUIResource[r=102,g=102,b=102]
   ScrollBar.thumbHighlight                    com.sun.java.swing.plaf.ColorUIResource[r=204,g=204,b=255]
   ScrollBar.thumbLightShadow                    com.sun.java.swing.plaf.ColorUIResource[r=153,g=153,b=153]
   ScrollBar.thumbShadow                    com.sun.java.swing.plaf.ColorUIResource[r=102,g=102,b=153]
   ScrollBar.track                    com.sun.java.swing.plaf.ColorUIResource[r=224,g=224,b=224]
   ScrollBar.trackHighlight                    com.sun.java.swing.plaf.ColorUIResource[r=102,g=102,b=102]
   ScrollBar.width                    17
   ScrollBarUI                    com.sun.java.swing.plaf.metal.MetalScrollBarUI
   ScrollBar.minimumThumbSize	Integer
   ScrollBar.maximumThumbSize	 Integer 



ScrollPane

  ScrollPane.font	FontUIResource
  ScrollPane.background	ColorUIResource
  ScrollPane.foreground	ColorUIResource
  ScrollPane.border	BorderUIResource
  ScrollPane.viewportBorder	 BorderUIResource 



ScrollPane Viewport (?)

  Viewport.font	FontUIResource
  Viewport.background	ColorUIResource
  Viewport.foreground	ColorUIResource



Slider

   Slider.background                    com.sun.java.swing.plaf.ColorUIResource[r=204,g=204,b=204]
   Slider.focus                    com.sun.java.swing.plaf.ColorUIResource[r=153,g=153,b=204]
   Slider.foreground                    com.sun.java.swing.plaf.ColorUIResource[r=153,g=153,b=204]
   Slider.highlight                    com.sun.java.swing.plaf.ColorUIResource[r=255,g=255,b=255]
   Slider.horizontalThumbIcon                    com.sun.java.swing.plaf.metal.MetalIconFactory$HorizontalSliderThumbIcon@7ba
   Slider.majorTickLength                    6
   Slider.shadow                    com.sun.java.swing.plaf.ColorUIResource[r=153,g=153,b=153]
   Slider.trackWidth                    9
   Slider.verticalThumbIcon                    com.sun.java.swing.plaf.metal.MetalIconFactory$VerticalSliderThumbIcon@3ce9
   SliderUI                    com.sun.java.swing.plaf.metal.MetalSliderUI
   Slider.border	BorderUIResource
   Slider.focusInsets	InsetsUIResource



SplitPane

  SplitPane.background	ColorUIResource
  SplitPane.highlight	ColorUIResource
  SplitPane.shadow	 ColorUIResource 
  SplitPane.border	BorderUIResource
  SplitPane.dividerSize	Integer



TabbedPane

   TabbedPane.background	ColorUIResource
   TabbedPane.contentBorderInsets	InsetsUIResource
   TabbedPane.darkShadow	ColorUIResource
   TabbedPane.focus                    com.sun.java.swing.plaf.ColorUIResource[r=102,g=102,b=153]
   TabbedPane.font                    com.sun.java.swing.plaf.FontUIResource[family=Dialog,name=Dialog,style=bold,size=12]
   TabbedPane.foreground	ColorUIResource
   TabbedPane.highlight	 ColorUIResource 
   TabbedPane.lightHighlight	ColorUIResource
   TabbedPane.selectHighlight                    com.sun.java.swing.plaf.ColorUIResource[r=204,g=204,b=255]
   TabbedPane.selected                    com.sun.java.swing.plaf.ColorUIResource[r=153,g=153,b=204]
   TabbedPane.selectedTabPadInsets	InsetsUIResource
   TabbedPane.shadow	 ColorUIResource 
   TabbedPane.tabAreaInsets	InsetsUIResource
   TabbedPane.tabBackground                    com.sun.java.swing.plaf.ColorUIResource[r=204,g=204,b=204]
   TabbedPane.tabDarkShadow                    com.sun.java.swing.plaf.ColorUIResource[r=102,g=102,b=102]
   TabbedPane.tabForeground                    com.sun.java.swing.plaf.ColorUIResource[r=0,g=0,b=0]
   TabbedPane.tabHighlight                    com.sun.java.swing.plaf.ColorUIResource[r=255,g=255,b=255]
   TabbedPane.tabInsets	InsetsUIResource
   TabbedPane.tabRunOverlay	Integer
   TabbedPane.tabShadow                    com.sun.java.swing.plaf.ColorUIResource[r=153,g=153,b=153]
   TabbedPane.textIconGap	Integer
   TabbedPaneUI                    com.sun.java.swing.plaf.metal.MetalTabbedPaneUI



Table

   Table.background                    com.sun.java.swing.plaf.ColorUIResource[r=255,g=255,b=255]
   Table.focusCellBackground                    com.sun.java.swing.plaf.ColorUIResource[r=153,g=153,b=204]
   Table.focusCellForeground                    com.sun.java.swing.plaf.ColorUIResource[r=0,g=0,b=0]
   Table.focusCellHighlightBorder                    com.sun.java.swing.plaf.BorderUIResource@4d6c
   Table.font                    com.sun.java.swing.plaf.FontUIResource[family=Dialog,name=Dialog,style=plain,size=12]
   Table.foreground                    com.sun.java.swing.plaf.ColorUIResource[r=0,g=0,b=0]
   Table.gridColor                    com.sun.java.swing.plaf.ColorUIResource[r=153,g=153,b=153]
   Table.scrollPaneBorder                    com.sun.java.swing.plaf.BorderUIResource@72c5
   Table.selectionBackground                    com.sun.java.swing.plaf.ColorUIResource[r=204,g=204,b=255]
   Table.selectionForeground                    com.sun.java.swing.plaf.ColorUIResource[r=0,g=0,b=0]



TableHeader

  TableHeader.font	FontUIResource
  TableHeader.foreground	ColorUIResource
  TableHeader.background	ColorUIResource
  TableHeader.cellBorder	BorderUIResource



TextField

  TextField.background	 ColorUIResource 
  TextField.border	BorderUIResource
  TextField.caretBlinkRate	Integer
  TextField.caretForeground	ColorUIResource
  TextField.font	FontUIResource
  TextField.foreground	ColorUIResource
  TextField.inactiveForeground	 ColorUIResource 
  TextField.keyBindings	fieldBindings
  TextField.margin	InsetsUIResource
  TextField.selectionBackground	ColorUIResource
  TextField.selectionForeground	ColorUIResource



PasswordField

   PasswordField.background                    com.sun.java.swing.plaf.ColorUIResource[r=255,g=255,b=255]
   PasswordField.border                    com.sun.java.swing.plaf.BorderUIResource@710f
   PasswordField.caretBlinkRate                    500
   PasswordField.caretForeground                    com.sun.java.swing.plaf.ColorUIResource[r=0,g=0,b=0]
   PasswordField.font                    com.sun.java.swing.plaf.FontUIResource[family=SansSerif,name=SansSerif,style=plain,size=12]
   PasswordField.foreground                    com.sun.java.swing.plaf.ColorUIResource[r=0,g=0,b=0]
   PasswordField.inactiveForeground                    com.sun.java.swing.plaf.ColorUIResource[r=153,g=153,b=153]
   PasswordField.keyBindings                    [Lcom.sun.java.swing.text.JTextComponent$KeyBinding;@711e
   PasswordField.selectionBackground                    com.sun.java.swing.plaf.ColorUIResource[r=204,g=204,b=255]
   PasswordField.selectionForeground                    com.sun.java.swing.plaf.ColorUIResource[r=0,g=0,b=0]
   PasswordFieldUI                    com.sun.java.swing.plaf.basic.BasicPasswordFieldUI
   PasswordField.margin	InsetsUIResource



TextArea

   TextArea.background	 ColorUIResource 
   TextArea.border	BorderUIResource
   TextArea.caretBlinkRate	Integer
   TextArea.caretForeground	ColorUIResource
   TextArea.font	FontUIResource
   TextArea.foreground	ColorUIResource
   TextArea.inactiveForeground	 ColorUIResource 
   TextArea.keyBindings	multilineBindings
   TextArea.margin	InsetsUIResource
   TextArea.selectionBackground	ColorUIResource
  TextArea.selectionForeground	ColorUIResource



TextPane

   TextPane.background	 ColorUIResource 
   TextPane.border	BorderUIResource
   TextPane.caretBlinkRate	Integer
   TextPane.caretForeground	ColorUIResource
   TextPane.font	FontUIResource
   TextPane.foreground	ColorUIResource
   TextPane.inactiveForeground	 ColorUIResource 
   TextPane.keyBindings	multilineBindings
   TextPane.margin	InsetsUIResource
   TextPane.selectionBackground	lightGray
   TextPane.selectionForeground	ColorUIResource



EditorPane

   EditorPane.background	 ColorUIResource 
   EditorPane.border	BorderUIResource
   EditorPane.caretBlinkRate	Integer
   EditorPane.caretForeground	 ColorUIResource 
   EditorPane.font	FontUIResource
   EditorPane.foreground	ColorUIResource
   EditorPane.inactiveForeground	 ColorUIResource 
   EditorPane.keyBindings	multilineBindings
   EditorPane.margin	InsetsUIResource
   EditorPane.selectionBackground	 ColorUIResource 
   EditorPane.selectionForeground	ColorUIResource
   


TitledBorder

   TitledBorder.font	FontUIResource
   TitledBorder.titleColor	ColorUIResource
   TitledBorder.border	BorderUIResource



ToolBar

   ToolBar.font	FontUIResource
   ToolBar.background	ColorUIResource
   ToolBar.foreground	ColorUIResource
   ToolBar.dockingBackground	ColorUIResource
   ToolBar.dockingForeground	 ColorUIResource 
   ToolBar.floatingBackground	ColorUIResource
   ToolBar.floatingForeground	 ColorUIResource 
   ToolBar.border	BorderUIResource
   ToolBar.separatorSize	Integer



ToolTip

   ToolTip.font	FontUIResource
   ToolTip.background	 ColorUIResource 
   ToolTip.foreground	 ColorUIResource 
   ToolTip.border	BorderUIResource
  
  

Tree

   Tree.background                    com.sun.java.swing.plaf.ColorUIResource[r=255,g=255,b=255]
   Tree.backgroundNonSelectionColor                    com.sun.java.swing.plaf.ColorUIResource[r=255,g=255,b=255]
   Tree.backgroundSelectionColor                    com.sun.java.swing.plaf.ColorUIResource[r=204,g=204,b=255]
   Tree.borderSelectionColor                    com.sun.java.swing.plaf.ColorUIResource[r=255,g=255,b=255]
   Tree.changeSelectionWithFocus	Boolean
   Tree.closedIcon                    com.sun.java.swing.plaf.metal.MetalIconFactory$TreeFolderIcon@59d9
   Tree.collapsedIcon                    com.sun.java.swing.plaf.metal.MetalIconFactory$TreeControlIcon@40d
   Tree.drawsFocusBorderAroundIcon	Boolean
   Tree.editorBorder	BorderUIResource
   Tree.expandedIcon                    com.sun.java.swing.plaf.metal.MetalIconFactory$TreeControlIcon@408
   Tree.font                    com.sun.java.swing.plaf.FontUIResource[family=Dialog,name=Dialog,style=plain,size=12]
   Tree.foreground	ColorUIResource
   Tree.hash                    com.sun.java.swing.plaf.ColorUIResource[r=204,g=204,b=255]
   Tree.leafIcon                    com.sun.java.swing.plaf.metal.MetalIconFactory$TreeLeafIcon@5edf
   Tree.leftChildIndent	Integer
   Tree.line                    com.sun.java.swing.plaf.ColorUIResource[r=204,g=204,b=255]
   Tree.openIcon                    com.sun.java.swing.plaf.metal.MetalIconFactory$TreeFolderIcon@59d9
   Tree.rightChildIndent	Integer
   Tree.rowHeight	Integer
   Tree.scrollsOnExpand	Boolean
   Tree.selectionBackground	ColorUIResource
   Tree.selectionBorderColor	 ColorUIResource 
   Tree.selectionForeground	ColorUIResource
   Tree.textBackground	 ColorUIResource 
   Tree.textForeground	ColorUIResource
   Tree.textNonSelectionColor                    com.sun.java.swing.plaf.ColorUIResource[r=0,g=0,b=0]
   Tree.textSelectionColor                    com.sun.java.swing.plaf.ColorUIResource[r=0,g=0,b=0]


The Rest

activeCaption                    com.sun.java.swing.plaf.ColorUIResource[r=204,g=204,b=255]
activeCaptionBorder                    com.sun.java.swing.plaf.ColorUIResource[r=153,g=153,b=204]
activeCaptionText                    com.sun.java.swing.plaf.ColorUIResource[r=0,g=0,b=0]
control                    com.sun.java.swing.plaf.ColorUIResource[r=204,g=204,b=204]
controlDkShadow                    com.sun.java.swing.plaf.ColorUIResource[r=102,g=102,b=102]
controlHighlight                    com.sun.java.swing.plaf.ColorUIResource[r=255,g=255,b=255]
controlLtHighlight                    com.sun.java.swing.plaf.ColorUIResource[r=255,g=255,b=255]
controlShadow                    com.sun.java.swing.plaf.ColorUIResource[r=153,g=153,b=153]
controlText                    com.sun.java.swing.plaf.ColorUIResource[r=0,g=0,b=0]
desktop                    com.sun.java.swing.plaf.ColorUIResource[r=153,g=153,b=204]
inactiveCaption                    com.sun.java.swing.plaf.ColorUIResource[r=204,g=204,b=204]
inactiveCaptionBorder                    com.sun.java.swing.plaf.ColorUIResource[r=153,g=153,b=153]
inactiveCaptionText                    com.sun.java.swing.plaf.ColorUIResource[r=0,g=0,b=0]
info                    com.sun.java.swing.plaf.ColorUIResource[r=204,g=204,b=255]
infoText                    com.sun.java.swing.plaf.ColorUIResource[r=0,g=0,b=0]
menu                    com.sun.java.swing.plaf.ColorUIResource[r=204,g=204,b=204]
menuText                    com.sun.java.swing.plaf.ColorUIResource[r=0,g=0,b=0]
scrollbar                    com.sun.java.swing.plaf.ColorUIResource[r=204,g=204,b=204]
text                    com.sun.java.swing.plaf.ColorUIResource[r=255,g=255,b=255]
textHighlight                    com.sun.java.swing.plaf.ColorUIResource[r=204,g=204,b=255]
textHighlightText                    com.sun.java.swing.plaf.ColorUIResource[r=0,g=0,b=0]
textInactiveText                    com.sun.java.swing.plaf.ColorUIResource[r=153,g=153,b=153]
textText                    com.sun.java.swing.plaf.ColorUIResource[r=0,g=0,b=0]
window                    com.sun.java.swing.plaf.ColorUIResource[r=255,g=255,b=255]
windowBorder                    com.sun.java.swing.plaf.ColorUIResource[r=204,g=204,b=204]
windowText                    com.sun.java.swing.plaf.ColorUIResource[r=0,g=0,b=0]


Installation UIDefaults

public MyExample { …. …. Public void init() { lnfName="MyLookAndFeel"; try { System.out.println (" UIManager.setLookAndFeel"); UIManager.setLookAndFeel (lnfName); System.out.println ("SwingUtilities.updateComponentTreeUI"); SwingUtilities.updateComponentTreeUI (MyExample.this); System.out.println ("MyExample.this.validate"); MyExample.this.validate (); } catch (ClassNotFoundException cnfe) { System.err.println ("Class not found exception " + lnfName); } catch (InstantiationException ie) { System.err.println ("InstantiationException " + lnfName); } catch (IllegalAccessException iae) { System.err.println ("IllegalAccessException " + lnfName); } catch (UnsupportedLookAndFeelException ulafe) { System.err.println ("UnsupportedLookAndFeelException " + lnfName); } catch (Exception ex) { System.err.println ("Could not swap LookAndFeel: " + lnfName); } } MyLookAndFeel import java.awt.Color; import javax.swing.UIDefaults; import javax.swing.plaf.basic.BasicLookAndFeel; public class MyLookAndFeel extends BasicLookAndFeel { public MyLookAndFeel () { System.out.println ("Konstruktor"); } public String getName() { System.out.println ("getName"); return "MyLookAndFeel"; } public String getDescription() { System.out.println ("getDescription"); return "The My Look and Feel"; } public boolean isNativeLookAndFeel() { System.out.println ("isNative"); return false; } public boolean isSupportedLookAndFeel() { System.out.println ("isSupported"); return true; } public String getID () { System.out.println ("getID"); return "MyLookAndFeel"; } protected void initClassDefaults (UIDefaults table) { System.out.println ("initClassDef"); super.initClassDefaults (table); table.put ("ButtonUI", "MyButtonUI"); } }

1