public TransitionPanel() { setLayout(cardLayout); add(contentPane, "default"); add(transitionPane, "transition"); transitionPane.setUI(new PanelUI() { @Override public void paint(Graphics g, JComponent c) { super.paint(g, c); if(animation!=null) { animation.paint(g); } } }); }
public UnitCellRenderer() { itemPanel.setOpaque(false); itemPanel.setLayout(new MigLayout("", "[60]")); selectedPanel.setOpaque(false); selectedPanel.setLayout(new MigLayout("", "[60]")); selectedPanel.setUI((PanelUI)FreeColSelectedPanelUI.createUI(selectedPanel)); locationLabel.setFont(locationLabel.getFont() .deriveFont(Font.ITALIC)); }
public StopRenderer() { NORMAL_COMPONENT.setLayout(new MigLayout("", "[80, center][]")); NORMAL_COMPONENT.setOpaque(false); SELECTED_COMPONENT.setLayout(new MigLayout("", "[80, center][]")); SELECTED_COMPONENT.setOpaque(false); SELECTED_COMPONENT.setUI((PanelUI)FreeColSelectedPanelUI .createUI(SELECTED_COMPONENT)); }
public DefaultBuildQueueCellRenderer() { itemPanel.setOpaque(false); itemPanel.setLayout(new MigLayout()); selectedPanel.setOpaque(false); selectedPanel.setLayout(new MigLayout()); selectedPanel.setUI((PanelUI)FreeColSelectedPanelUI.createUI(selectedPanel)); }
public void testCreateUI() { JComponent component = new JPanel(); ComponentUI ui = BasicPanelUI.createUI(component); assertTrue(ui != null && (ui instanceof PanelUI)); component = new JButton(); ui = BasicPanelUI.createUI(component); assertTrue(ui != null); }
public StopRenderer() { NORMAL_COMPONENT.setLayout(new MigLayout("", "[80, center][]")); NORMAL_COMPONENT.setOpaque(false); SELECTED_COMPONENT.setLayout(new MigLayout("", "[80, center][]")); SELECTED_COMPONENT.setOpaque(false); SELECTED_COMPONENT.setUI((PanelUI) FreeColSelectedPanelUI.createUI(SELECTED_COMPONENT)); }
public UnitCellRenderer() { itemPanel.setOpaque(false); itemPanel.setLayout(new MigLayout("", "[60]")); selectedPanel.setOpaque(false); selectedPanel.setLayout(new MigLayout("", "[60]")); selectedPanel.setUI((PanelUI) FreeColSelectedPanelUI.createUI(selectedPanel)); locationLabel.setFont(locationLabel.getFont().deriveFont(Font.ITALIC)); }
public DefaultBuildQueueCellRenderer() { itemPanel.setOpaque(false); itemPanel.setLayout(new MigLayout()); selectedPanel.setOpaque(false); selectedPanel.setLayout(new MigLayout()); selectedPanel.setUI((PanelUI) FreeColSelectedPanelUI.createUI(selectedPanel)); }
@Override public void setUI(PanelUI ui) { preferredSize = null; super.setUI(ui); }
public PanelUI getUI() { return null; }
public void setUI(PanelUI ui) { super.setUI(ui); }
/** * Sets this panel's UI delegate to the default (obtained from the * {@link UIManager}) for the current look and feel. */ public void updateUI() { setUI((PanelUI) UIManager.getUI(this)); }
@Override public void setUI(PanelUI ui) { clearCaches(); super.setUI(ui); }
@Override public void setUI(PanelUI ui) { getNavBarUI().clearItems(); super.setUI(ui); }
@Override public void setUI(PanelUI ui) { super.setUI(ui); updateUiParameters(); }
/** * Sets value taken from current L&F to UI property of the panel */ public void updateUI() { setUI((PanelUI)UIManager.getUI(this)); }
/** * Sets the UI delegate for the <code>JPanel</code> component. * * @param ui the UI delegate. * * @since 1.4 * @see #getUI() */ public void setUI(PanelUI ui) { super.setUI(ui); }
/** * Returns the UI delegate for the <code>JPanel</code> component. * * @return The UI delegate. * * @since 1.4 * @see #setUI(PanelUI) */ public PanelUI getUI() { return (PanelUI) ui; }
/** * * Sets new value for look-and-feel object for the panel * * @param ui new look-and-feel renderer */ public void setUI(final PanelUI ui) { super.setUI(ui); }
/** * * Gets the value of the look-and-feel object of the panel * * @return the <code>PanelUI</code> - components look-and-feel object */ public PanelUI getUI() { return (PanelUI)ui; }