@Override protected void configureLabel(JXTaskPane group) { label.applyComponentOrientation(group.getComponentOrientation()); label.setFont(group.getFont()); label.setText(group.getTitle()); label.setIcon(group.getIcon() == null ? new EmptyIcon() : group .getIcon()); } }
/** * Configures label for the group using its title, font, icon and * orientation. * * @param group * Selected group. */ protected void configureLabel(JXTaskPane group) { label.applyComponentOrientation(group.getComponentOrientation()); label.setFont(group.getFont()); label.setText(group.getTitle()); label.setIcon(group.getIcon() == null ? new EmptyIcon() : group .getIcon()); }
/** * Configures label for the group using its title, font, icon and * orientation. * * @param group * Selected group. */ protected void configureLabel(JXTaskPane group) { label.applyComponentOrientation(group.getComponentOrientation()); label.setFont(group.getFont()); label.setText(group.getTitle()); label.setIcon(group.getIcon() == null ? new EmptyIcon() : group .getIcon()); }
/** * Configures label for the group using its title, font, icon and * orientation. * * @param group * Selected group. */ protected void configureLabel(JXTaskPane group) { label.applyComponentOrientation(group.getComponentOrientation()); label.setFont(group.getFont()); label.setText(group.getTitle()); label.setIcon(group.getIcon() == null ? new EmptyIcon() : group .getIcon()); }
/** * Configures label for the group using its title, font, icon and * orientation. * * @param group * Selected group. */ protected void configureLabel(JXTaskPane group) { label.applyComponentOrientation(group.getComponentOrientation()); label.setFont(group.getFont()); label.setText(group.getTitle()); label.setIcon(group.getIcon() == null ? new EmptyIcon() : group .getIcon()); }
/** * Configures label for the group using its title, font, icon and * orientation. * * @param group * Selected group. */ protected void configureLabel(JXTaskPane group) { label.applyComponentOrientation(group.getComponentOrientation()); label.setFont(group.getFont()); label.setText(group.getTitle()); label.setIcon(group.getIcon() == null ? new EmptyIcon() : group .getIcon()); }
0f, group.getWidth() / 2, group.getComponentOrientation().isLeftToRight()? titleBackgroundGradientStart :titleBackgroundGradientEnd, group.getWidth(), getTitleHeight(group), group.getComponentOrientation().isLeftToRight()? titleBackgroundGradientEnd :titleBackgroundGradientStart);
0f, group.getWidth() / 2, group.getComponentOrientation().isLeftToRight()? titleBackgroundGradientStart :titleBackgroundGradientEnd, group.getWidth(), getTitleHeight(group), group.getComponentOrientation().isLeftToRight()? titleBackgroundGradientEnd :titleBackgroundGradientStart);
0f, group.getWidth() / 2, group.getComponentOrientation().isLeftToRight()? titleBackgroundGradientStart :titleBackgroundGradientEnd, group.getWidth(), getTitleHeight(group), group.getComponentOrientation().isLeftToRight()? titleBackgroundGradientEnd :titleBackgroundGradientStart);
0f, group.getWidth() / 2, group.getComponentOrientation().isLeftToRight()? titleBackgroundGradientStart :titleBackgroundGradientEnd, group.getWidth(), getTitleHeight(group), group.getComponentOrientation().isLeftToRight()? titleBackgroundGradientEnd :titleBackgroundGradientStart);
0f, group.getWidth() / 2, group.getComponentOrientation().isLeftToRight()? titleBackgroundGradientStart :titleBackgroundGradientEnd, group.getWidth(), getTitleHeight(group), group.getComponentOrientation().isLeftToRight()? titleBackgroundGradientEnd :titleBackgroundGradientStart);
@Override public void paintBorder(Component c, Graphics g, int x, int y, int width, int height) { JXTaskPane group = (JXTaskPane) c; // calculate position of title and toggle controls int controlWidth = getTitleHeight(group) - 2 * getRoundHeight(); int controlX = group.getWidth() - getTitleHeight(group); int controlY = getRoundHeight() - 1; int titleX = 3; int titleY = 0; int titleWidth = group.getWidth() - getTitleHeight(group) - 3; int titleHeight = getTitleHeight(group); if (!group.getComponentOrientation().isLeftToRight()) { controlX = group.getWidth() - controlX - controlWidth; titleX = group.getWidth() - titleX - titleWidth; } // paint the title background paintTitleBackground(group, g); // paint the the toggles paintExpandedControls(group, g, controlX, controlY, controlWidth, controlWidth); // paint the title text and icon Color paintColor = getPaintColor(group); // focus painted same color as text if (group.hasFocus()) { paintFocus(g, paintColor, 3, 3, width - 6, getTitleHeight(group) - 6); } paintTitle(group, g, paintColor, titleX, titleY, titleWidth, titleHeight); }
public void paintBorder(Component c, Graphics g, int x, int y, int width, int height) { JXTaskPane group = (JXTaskPane) c; // calculate position of title and toggle controls int controlWidth = getTitleHeight(group) - 2 * getRoundHeight(); int controlX = group.getWidth() - getTitleHeight(group); int controlY = getRoundHeight() - 1; int titleX = 3; int titleY = 0; int titleWidth = group.getWidth() - getTitleHeight(group) - 3; int titleHeight = getTitleHeight(group); if (!group.getComponentOrientation().isLeftToRight()) { controlX = group.getWidth() - controlX - controlWidth; titleX = group.getWidth() - titleX - titleWidth; } // paint the title background paintTitleBackground(group, g); // paint the the toggles paintExpandedControls(group, g, controlX, controlY, controlWidth, controlWidth); // paint the title text and icon Color paintColor = getPaintColor(group); // focus painted same color as text if (group.hasFocus()) { paintFocus(g, paintColor, 3, 3, width - 6, getTitleHeight(group) - 6); } paintTitle(group, g, paintColor, titleX, titleY, titleWidth, titleHeight); }
@Override public void paintBorder(Component c, Graphics g, int x, int y, int width, int height) { JXTaskPane group = (JXTaskPane) c; // calculate position of title and toggle controls int controlWidth = getTitleHeight(group) - 2 * getRoundHeight(); int controlX = group.getWidth() - getTitleHeight(group); int controlY = getRoundHeight() - 1; int titleX = 3; int titleY = 0; int titleWidth = group.getWidth() - getTitleHeight(group) - 3; int titleHeight = getTitleHeight(group); if (!group.getComponentOrientation().isLeftToRight()) { controlX = group.getWidth() - controlX - controlWidth; titleX = group.getWidth() - titleX - titleWidth; } // paint the title background paintTitleBackground(group, g); // paint the the toggles paintExpandedControls(group, g, controlX, controlY, controlWidth, controlWidth); // paint the title text and icon Color paintColor = getPaintColor(group); // focus painted same color as text if (group.hasFocus()) { paintFocus(g, paintColor, 3, 3, width - 6, getTitleHeight(group) - 6); } paintTitle(group, g, paintColor, titleX, titleY, titleWidth, titleHeight); }
@Override public void paintBorder(Component c, Graphics g, int x, int y, int width, int height) { JXTaskPane group = (JXTaskPane) c; // calculate position of title and toggle controls int controlWidth = getTitleHeight(group) - 2 * getRoundHeight(); int controlX = group.getWidth() - getTitleHeight(group); int controlY = getRoundHeight() - 1; int titleX = 3; int titleY = 0; int titleWidth = group.getWidth() - getTitleHeight(group) - 3; int titleHeight = getTitleHeight(group); if (!group.getComponentOrientation().isLeftToRight()) { controlX = group.getWidth() - controlX - controlWidth; titleX = group.getWidth() - titleX - titleWidth; } // paint the title background paintTitleBackground(group, g); // paint the the toggles paintExpandedControls(group, g, controlX, controlY, controlWidth, controlWidth); // paint the title text and icon Color paintColor = getPaintColor(group); // focus painted same color as text if (group.hasFocus()) { paintFocus(g, paintColor, 3, 3, width - 6, getTitleHeight(group) - 6); } paintTitle(group, g, paintColor, titleX, titleY, titleWidth, titleHeight); }
@Override public void paintBorder(Component c, Graphics g, int x, int y, int width, int height) { JXTaskPane group = (JXTaskPane) c; // calculate position of title and toggle controls int controlWidth = getTitleHeight(group) - 2 * getRoundHeight(); int controlX = group.getWidth() - getTitleHeight(group); int controlY = getRoundHeight() - 1; int titleX = 3; int titleY = 0; int titleWidth = group.getWidth() - getTitleHeight(group) - 3; int titleHeight = getTitleHeight(group); if (!group.getComponentOrientation().isLeftToRight()) { controlX = group.getWidth() - controlX - controlWidth; titleX = group.getWidth() - titleX - titleWidth; } // paint the title background paintTitleBackground(group, g); // paint the the toggles paintExpandedControls(group, g, controlX, controlY, controlWidth, controlWidth); // paint the title text and icon Color paintColor = getPaintColor(group); // focus painted same color as text if (group.hasFocus()) { paintFocus(g, paintColor, 3, 3, width - 6, getTitleHeight(group) - 6); } paintTitle(group, g, paintColor, titleX, titleY, titleWidth, titleHeight); }