Cutom colors to popup menu

Advertisement
November 30

Hi all, I need to install custom look and feel for my popup menu,
the following code works fine most of the time but still it turns back to the default colors some time, can any one tell me why this behaviour.
Also when a menuitem is selected a grey line is appeared below the selection I want to change that color too
Thanks in advance, below is the code I am using
UIManager.put("MenuItem.background",
                    oStyleReader.schemeMenuItemBackGroundColor);
      UIManager.put("MenuItem.foreground",
                    oStyleReader.schemeMenuItemForeGroundColor);
      UIManager.put("MenuItem.selectionBackground",
                    oStyleReader.schemeMenuItemSelectionBackGroundColor);
      UIManager.put("MenuItem.selectionForeground",
                    oStyleReader.schemeMenuItemSelectionForeGroundColor);
      UIManager.put("MenuItem.font", schemeMenuItemFont);
      UIManager.put("PopupMenu.border", oStyleReader.schemePopupMenuBorderColor);
      UIManager.put("PopupMenu.background",
                    oStyleReader.schemePopupMenuBackGroundColor);
      UIManager.put("PopupMenu.foreground",
                    oStyleReader.schemePopupMenuBackGroundColor);
      UIManager.put("Separator.highlight",
                    oStyleReader.schemeSeparatorHighLightColor);
      UIManager.put("Separator.shadow", oStyleReader.schemeSeparatorShadowColor);
      UIManager.put("Separator.background",
                    oStyleReader.schemeSeparatorBackGroundColor);
      UIManager.put("Separator.foreground",
                    oStyleReader.schemeSeparatorForeGroundColor);

Advertisement

Replay

the following code works fine most of the time but still it turns back to the
default colors some time.you would need to post a working sample program that demonstrates the behavior,
along with instructions on how to achieve "back to the default colors some time"

View 3 Replies

Tags:

  1. on nxt finger sensor issue
  2. connecting hp f4580 to bt hub 6
  3. Bbm channels how to add on 9300
  4. PARNR LiVE ViDEo ON
  5. ME_PROCESS_PO_CUST BAPI_PO_CREATE1
  6. Primary BT ID
  7. SOFFICEINTEGRATION 898 error
  8. usefule1m
  9. DAQmx_Val_ChanPerLine
  10. queenvix
Copyrights 2019 Fcffair BigData Resource, All rights reserved