/** * Returns the image for a horizontal track. * * @param scrollBar * Scroll bar. * @param leftActiveButton * The closest left button in the scroll bar. May be * <code>null</code>. * @param rightActiveButton * The closest right button in the scroll bar. May be * <code>null</code> . * @param width * Scroll track width. * @param height * Scroll track height. * @return Horizontal track image. */ private static void paintTrackBackHorizontal(Graphics g, JScrollBar scrollBar, AbstractButton leftActiveButton, AbstractButton rightActiveButton, int width, int height) { SubstanceButtonShaper shaper = SubstanceCoreUtilities .getButtonShaper(scrollBar); int radius = height / 2; if (shaper instanceof ClassicButtonShaper) radius = 2; SubstanceImageCreator.paintCompositeRoundedBackground(scrollBar, g, width, height, radius, leftActiveButton, rightActiveButton, false); }
if (shaper instanceof ClassicButtonShaper) radius = 2; SubstanceImageCreator.paintCompositeRoundedBackground(scrollBar, g, width, height, radius, leftActiveButton, rightActiveButton, false);
at.rotate(-Math.PI / 2); g2d.transform(at); SubstanceImageCreator.paintCompositeRoundedBackground(scrollBar, g2d, height, width, radius, topActiveButton, bottomActiveButton, true);
at.rotate(-Math.PI / 2); g2d.transform(at); SubstanceImageCreator.paintCompositeRoundedBackground(scrollBar, g2d, height, width, radius, topActiveButton, bottomActiveButton, true);