@Inject public Window(SexyPanelUI panelUI) { super("Tomighty"); panel.setUI(panelUI); setAlwaysOnTop(true); setContentPane(panel); setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE); setLocation(100, 100); setResizable(false); setSize(180, 115); setUndecorated(true); addWindowFocusListener(new HideWindowWhenLosingFocus()); addMouseListener(dragger); addMouseMotionListener(dragger); }
/** * Sets the look and feel (L&F) object that renders this component. * * @param ui * The UI delegate. */ protected void setUI(RichTooltipPanelUI ui) { super.setUI(ui); }
/** * Sets the L&F object that renders this component. * * @param ui the <code>TaskPaneUI</code> L&F object * @see javax.swing.UIDefaults#getUI * * @beaninfo bound: true hidden: true description: The UI object that * implements the taskpane group's LookAndFeel. */ public void setUI(TaskPaneUI ui) { super.setUI(ui); }
/** * Sets the look and feel (L&F) object that renders this component. * * @param ui * the PopupGalleryUI L&F object */ protected void setUI(PopupPanelUI ui) { super.setUI(ui); }
/** * Sets the L&F object that renders this component. * * @param ui the <code>TaskPaneUI</code> L&F object * @see javax.swing.UIDefaults#getUI * * @beaninfo bound: true hidden: true description: The UI object that * implements the taskpane group's LookAndFeel. */ public void setUI(TaskPaneUI ui) { super.setUI(ui); }
/** * Sets the L&F object that renders this component. * * @param ui the <code>TaskPaneUI</code> L&F object * @see javax.swing.UIDefaults#getUI * * @beaninfo bound: true hidden: true description: The UI object that * implements the taskpane group's LookAndFeel. */ public void setUI(TaskPaneUI ui) { super.setUI(ui); }
/** * Sets the look and feel (L&F) object that renders this component. * * @param ui * The UI delegate. */ protected void setUI(RichTooltipPanelUI ui) { super.setUI(ui); }
/** * Sets the L&F object that renders this component. * * @param ui the <code>TaskPaneUI</code> L&F object * @see javax.swing.UIDefaults#getUI * * @beaninfo bound: true hidden: true description: The UI object that * implements the taskpane group's LookAndFeel. */ public void setUI(TaskPaneUI ui) { super.setUI(ui); }
/** * Sets the UI object which implements the L&F for this component. * * @param ui the new UI object * @see javax.swing.UIDefaults#getUI */ public void setUI(SidePaneUI ui) { super.setUI(ui); }
public void setUI(PanelUI ui) { if (ui instanceof ToolWindowTitleBarUI) super.setUI(ui); } };
/** * Sets the L&F object that renders this component. * * @param ui the <code>TaskPaneUI</code> L&F object * @see javax.swing.UIDefaults#getUI * * @beaninfo bound: true hidden: true description: The UI object that * implements the taskpane group's LookAndFeel. */ public void setUI(TaskPaneUI ui) { super.setUI(ui); }
@Override public void setUI(PanelUI ui) { super.setUI(ui); refreshMinimizeIcon(); }
/*************************************************************************** * * **************************************************************************/ public static void installHeaderUI (final JPanel pnHeader) { pnHeader.setUI(HeaderPanelUI.createUI(pnHeader)); }
private static void updateUIToRemoveLF(JPanel panel) { panel.setUI(new javax.swing.plaf.PanelUI() { }); panel.setBackground(Color.WHITE); panel.setForeground(Color.BLACK); panel.setBorder(null); panel.setOpaque(true); }
/*************************************************************************** * * **************************************************************************/ public static void installHeaderUI (final JPanel pnHeader) { pnHeader.setUI(HeaderPanelUI.createUI(pnHeader)); }
public void setUI(PanelUI ui) { super.setUI(ui); init(); }
public Component create(Context context) { JPanel titleBar = new JPanel() { public void setUI(PanelUI ui) { if (ui instanceof ToolWindowTitleBarUI) super.setUI(ui); } }; titleBar.setBorder(null); titleBar.setUI((PanelUI) context.get(ResourceManager.class) .createComponentUI(MyDoggyKeySpace.TOOL_WINDOW_TITLE_BAR_UI, context) ); return titleBar; } }
private void initGrid() { // For having a black background with any Look and Feel grid.setUI(new PanelUI() { }); setGridBackground(Color.BLACK); add(grid, BorderLayout.CENTER); }
public ImageViewerPlugin(ImageViewerEventManager<E> eventManager, GridBagLayoutModel layoutModel, String uid, String pluginName, Icon icon, String tooltips) { super(uid, pluginName, icon, tooltips); if (eventManager == null) { throw new IllegalArgumentException("EventManager cannot be null"); //$NON-NLS-1$ } this.eventManager = eventManager; view2ds = new ArrayList<>(); components = new ArrayList<>(); grid = new JPanel(); // For having a black background with any Look and Feel grid.setUI(new PanelUI() { }); grid.setBackground(Color.BLACK); grid.setFocusCycleRoot(true); grid.setLayout(new GridBagLayout()); add(grid, BorderLayout.CENTER); setLayoutModel(layoutModel); this.mouseHandler = new MouseHandler(); grid.addMouseListener(mouseHandler); grid.addMouseMotionListener(mouseHandler); }
@Override protected void buildChooser() { initComponents(); PaletteLookAndFeel laf = PaletteLookAndFeel.getInstance(); setUI(PalettePanelUI.createUI(this)); slidersHolder.setUI((PanelUI) PalettePanelUI.createUI(slidersHolder)); slidersComboBox.setFont(laf.getFont("ColorChooser.font")); slidersHolder.add(new PaletteRGBChooser(),""+laf.getString("ColorChooser.rgbSliders")); slidersHolder.add(new PaletteCMYKChooser(),""+laf.getString("ColorChooser.cmykSliders")); slidersHolder.add(new PaletteHSBChooser(),""+laf.getString("ColorChooser.hsbSliders")); DefaultComboBoxModel cbm = new DefaultComboBoxModel(); cbm.addElement(laf.getString("ColorChooser.rgbSliders")); cbm.addElement(laf.getString("ColorChooser.cmykSliders")); cbm.addElement(laf.getString("ColorChooser.hsbSliders")); slidersComboBox.setModel(cbm); slidersComboBox.addItemListener(new ItemListener() { @Override public void itemStateChanged(ItemEvent evt) { if (evt.getStateChange() == ItemEvent.SELECTED) { ((CardLayout) slidersHolder.getLayout()).show(slidersHolder, (String) evt.getItem()); lastSelectedPanelIndex = slidersComboBox.getSelectedIndex(); } } }); slidersComboBox.setSelectedIndex(lastSelectedPanelIndex); }