java.awt.Adjustable Java Examples

The following examples show how to use java.awt.Adjustable. You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: LWScrollBarPeer.java    From jdk8u60 with GNU General Public License v2.0 6 votes vote down vote up
@Override
void initializeImpl() {
    super.initializeImpl();
    final Scrollbar target = getTarget();
    setLineIncrement(target.getUnitIncrement());
    setPageIncrement(target.getBlockIncrement());
    setValues(target.getValue(), target.getVisibleAmount(),
              target.getMinimum(), target.getMaximum());

    final int orientation = target.getOrientation();
    final JScrollBar delegate = getDelegate();
    synchronized (getDelegateLock()) {
        delegate.setOrientation(orientation == Scrollbar.HORIZONTAL
                                ? Adjustable.HORIZONTAL
                                : Adjustable.VERTICAL);
        delegate.addAdjustmentListener(this);
    }
}
 
Example #2
Source File: ScrollPaneWheelScroller.java    From jdk8u_jdk with GNU General Public License v2.0 6 votes vote down vote up
public static void handleWheelScrolling(ScrollPane sp, MouseWheelEvent e) {
    if (log.isLoggable(PlatformLogger.Level.FINER)) {
        log.finer("x = " + e.getX() + ", y = " + e.getY() + ", src is " + e.getSource());
    }
    int increment = 0;

    if (sp != null && e.getScrollAmount() != 0) {
        Adjustable adj = getAdjustableToScroll(sp);
        if (adj != null) {
            increment = getIncrementFromAdjustable(adj, e);
            if (log.isLoggable(PlatformLogger.Level.FINER)) {
                log.finer("increment from adjustable(" + adj.getClass() + ") : " + increment);
            }
            scrollAdjustable(adj, increment);
        }
    }
}
 
Example #3
Source File: ScrollPaneWheelScroller.java    From openjdk-jdk8u with GNU General Public License v2.0 6 votes vote down vote up
public static void handleWheelScrolling(ScrollPane sp, MouseWheelEvent e) {
    if (log.isLoggable(PlatformLogger.Level.FINER)) {
        log.finer("x = " + e.getX() + ", y = " + e.getY() + ", src is " + e.getSource());
    }
    int increment = 0;

    if (sp != null && e.getScrollAmount() != 0) {
        Adjustable adj = getAdjustableToScroll(sp);
        if (adj != null) {
            increment = getIncrementFromAdjustable(adj, e);
            if (log.isLoggable(PlatformLogger.Level.FINER)) {
                log.finer("increment from adjustable(" + adj.getClass() + ") : " + increment);
            }
            scrollAdjustable(adj, increment);
        }
    }
}
 
Example #4
Source File: ScrollPaneWheelScroller.java    From jdk8u-dev-jdk with GNU General Public License v2.0 6 votes vote down vote up
public static void handleWheelScrolling(ScrollPane sp, MouseWheelEvent e) {
    if (log.isLoggable(PlatformLogger.Level.FINER)) {
        log.finer("x = " + e.getX() + ", y = " + e.getY() + ", src is " + e.getSource());
    }
    int increment = 0;

    if (sp != null && e.getScrollAmount() != 0) {
        Adjustable adj = getAdjustableToScroll(sp);
        if (adj != null) {
            increment = getIncrementFromAdjustable(adj, e);
            if (log.isLoggable(PlatformLogger.Level.FINER)) {
                log.finer("increment from adjustable(" + adj.getClass() + ") : " + increment);
            }
            scrollAdjustable(adj, increment);
        }
    }
}
 
Example #5
Source File: ScrollPaneWheelScroller.java    From jdk8u-jdk with GNU General Public License v2.0 6 votes vote down vote up
public static int getIncrementFromAdjustable(Adjustable adj,
                                             MouseWheelEvent e) {
    if (log.isLoggable(PlatformLogger.Level.FINE)) {
        if (adj == null) {
            log.fine("Assertion (adj != null) failed");
        }
    }

    int increment = 0;

    if (e.getScrollType() == MouseWheelEvent.WHEEL_UNIT_SCROLL) {
        increment = e.getUnitsToScroll() * adj.getUnitIncrement();
    }
    else if (e.getScrollType() == MouseWheelEvent.WHEEL_BLOCK_SCROLL) {
        increment = adj.getBlockIncrement() * e.getWheelRotation();
    }
    return increment;
}
 
Example #6
Source File: ScrollPaneWheelScroller.java    From openjdk-jdk8u with GNU General Public License v2.0 6 votes vote down vote up
public static int getIncrementFromAdjustable(Adjustable adj,
                                             MouseWheelEvent e) {
    if (log.isLoggable(PlatformLogger.Level.FINE)) {
        if (adj == null) {
            log.fine("Assertion (adj != null) failed");
        }
    }

    int increment = 0;

    if (e.getScrollType() == MouseWheelEvent.WHEEL_UNIT_SCROLL) {
        increment = e.getUnitsToScroll() * adj.getUnitIncrement();
    }
    else if (e.getScrollType() == MouseWheelEvent.WHEEL_BLOCK_SCROLL) {
        increment = adj.getBlockIncrement() * e.getWheelRotation();
    }
    return increment;
}
 
Example #7
Source File: ScrollPaneWheelScroller.java    From openjdk-8 with GNU General Public License v2.0 6 votes vote down vote up
public static void handleWheelScrolling(ScrollPane sp, MouseWheelEvent e) {
    if (log.isLoggable(PlatformLogger.Level.FINER)) {
        log.finer("x = " + e.getX() + ", y = " + e.getY() + ", src is " + e.getSource());
    }
    int increment = 0;

    if (sp != null && e.getScrollAmount() != 0) {
        Adjustable adj = getAdjustableToScroll(sp);
        if (adj != null) {
            increment = getIncrementFromAdjustable(adj, e);
            if (log.isLoggable(PlatformLogger.Level.FINER)) {
                log.finer("increment from adjustable(" + adj.getClass() + ") : " + increment);
            }
            scrollAdjustable(adj, increment);
        }
    }
}
 
Example #8
Source File: ScrollPaneWheelScroller.java    From openjdk-jdk8u-backup with GNU General Public License v2.0 6 votes vote down vote up
public static void handleWheelScrolling(ScrollPane sp, MouseWheelEvent e) {
    if (log.isLoggable(PlatformLogger.Level.FINER)) {
        log.finer("x = " + e.getX() + ", y = " + e.getY() + ", src is " + e.getSource());
    }
    int increment = 0;

    if (sp != null && e.getScrollAmount() != 0) {
        Adjustable adj = getAdjustableToScroll(sp);
        if (adj != null) {
            increment = getIncrementFromAdjustable(adj, e);
            if (log.isLoggable(PlatformLogger.Level.FINER)) {
                log.finer("increment from adjustable(" + adj.getClass() + ") : " + increment);
            }
            scrollAdjustable(adj, increment);
        }
    }
}
 
Example #9
Source File: ScrollPaneWheelScroller.java    From jdk8u-jdk with GNU General Public License v2.0 6 votes vote down vote up
public static void handleWheelScrolling(ScrollPane sp, MouseWheelEvent e) {
    if (log.isLoggable(PlatformLogger.Level.FINER)) {
        log.finer("x = " + e.getX() + ", y = " + e.getY() + ", src is " + e.getSource());
    }
    int increment = 0;

    if (sp != null && e.getScrollAmount() != 0) {
        Adjustable adj = getAdjustableToScroll(sp);
        if (adj != null) {
            increment = getIncrementFromAdjustable(adj, e);
            if (log.isLoggable(PlatformLogger.Level.FINER)) {
                log.finer("increment from adjustable(" + adj.getClass() + ") : " + increment);
            }
            scrollAdjustable(adj, increment);
        }
    }
}
 
Example #10
Source File: ScrollBarUI.java    From rapidminer-studio with GNU Affero General Public License v3.0 6 votes vote down vote up
@Override
protected void paintTrack(Graphics g, JComponent c, Rectangle trackBounds) {
	int x = (int) trackBounds.getX();
	int y = (int) trackBounds.getY();
	int w = (int) trackBounds.getWidth();
	int h = (int) trackBounds.getHeight();

	g.setColor(Colors.SCROLLBAR_TRACK_BACKGROUND);
	g.fillRect(x - 1, y - 1, w + 2, h + 2);

	g.setColor(Colors.SCROLLBAR_TRACK_BORDER);
	if (this.scrollbar.getOrientation() == Adjustable.HORIZONTAL) {
		g.drawLine(x, y, x + w, y);
	} else {
		g.drawLine(x, y, x, y + h);
	}
}
 
Example #11
Source File: LWScrollBarPeer.java    From dragonwell8_jdk with GNU General Public License v2.0 6 votes vote down vote up
@Override
void initializeImpl() {
    super.initializeImpl();
    final Scrollbar target = getTarget();
    setLineIncrement(target.getUnitIncrement());
    setPageIncrement(target.getBlockIncrement());
    setValues(target.getValue(), target.getVisibleAmount(),
              target.getMinimum(), target.getMaximum());

    final int orientation = target.getOrientation();
    final JScrollBar delegate = getDelegate();
    synchronized (getDelegateLock()) {
        delegate.setOrientation(orientation == Scrollbar.HORIZONTAL
                                ? Adjustable.HORIZONTAL
                                : Adjustable.VERTICAL);
        delegate.addAdjustmentListener(this);
    }
}
 
Example #12
Source File: ScrollPaneWheelScroller.java    From openjdk-8-source with GNU General Public License v2.0 6 votes vote down vote up
public static void handleWheelScrolling(ScrollPane sp, MouseWheelEvent e) {
    if (log.isLoggable(PlatformLogger.Level.FINER)) {
        log.finer("x = " + e.getX() + ", y = " + e.getY() + ", src is " + e.getSource());
    }
    int increment = 0;

    if (sp != null && e.getScrollAmount() != 0) {
        Adjustable adj = getAdjustableToScroll(sp);
        if (adj != null) {
            increment = getIncrementFromAdjustable(adj, e);
            if (log.isLoggable(PlatformLogger.Level.FINER)) {
                log.finer("increment from adjustable(" + adj.getClass() + ") : " + increment);
            }
            scrollAdjustable(adj, increment);
        }
    }
}
 
Example #13
Source File: ScrollPaneWheelScroller.java    From Bytecoder with Apache License 2.0 6 votes vote down vote up
public static void handleWheelScrolling(ScrollPane sp, MouseWheelEvent e) {
    if (log.isLoggable(PlatformLogger.Level.FINER)) {
        log.finer("x = " + e.getX() + ", y = " + e.getY() + ", src is " + e.getSource());
    }
    int increment = 0;

    if (sp != null && e.getScrollAmount() != 0) {
        Adjustable adj = getAdjustableToScroll(sp);
        if (adj != null) {
            increment = getIncrementFromAdjustable(adj, e);
            if (log.isLoggable(PlatformLogger.Level.FINER)) {
                log.finer("increment from adjustable(" + adj.getClass() + ") : " + increment);
            }
            scrollAdjustable(adj, increment);
        }
    }
}
 
Example #14
Source File: ScrollPaneWheelScroller.java    From hottub with GNU General Public License v2.0 6 votes vote down vote up
public static int getIncrementFromAdjustable(Adjustable adj,
                                             MouseWheelEvent e) {
    if (log.isLoggable(PlatformLogger.Level.FINE)) {
        if (adj == null) {
            log.fine("Assertion (adj != null) failed");
        }
    }

    int increment = 0;

    if (e.getScrollType() == MouseWheelEvent.WHEEL_UNIT_SCROLL) {
        increment = e.getUnitsToScroll() * adj.getUnitIncrement();
    }
    else if (e.getScrollType() == MouseWheelEvent.WHEEL_BLOCK_SCROLL) {
        increment = adj.getBlockIncrement() * e.getWheelRotation();
    }
    return increment;
}
 
Example #15
Source File: ScrollPaneOperator.java    From openjdk-jdk9 with GNU General Public License v2.0 6 votes vote down vote up
/**
 * Scrolls pane to right.
 *
 * @throws TimeoutExpiredException
 */
public void scrollToRight() {
    output.printTrace("Scroll ScrollPane to right\n"
            + toStringSource());
    output.printGolden("Scroll ScrollPane to right");
    produceTimeRestricted(new Action<Void, Void>() {
        @Override
        public Void launch(Void obj) {
            driver.scrollToMaximum(ScrollPaneOperator.this, Adjustable.HORIZONTAL);
            return null;
        }

        @Override
        public String getDescription() {
            return "Scrolling";
        }

        @Override
        public String toString() {
            return "ScrollPaneOperator.scrollToRight.Action{description = " + getDescription() + '}';
        }
    }, "ScrollbarOperator.WholeScrollTimeout");
}
 
Example #16
Source File: ScrollPaneWheelScroller.java    From jdk8u60 with GNU General Public License v2.0 6 votes vote down vote up
public static void handleWheelScrolling(ScrollPane sp, MouseWheelEvent e) {
    if (log.isLoggable(PlatformLogger.Level.FINER)) {
        log.finer("x = " + e.getX() + ", y = " + e.getY() + ", src is " + e.getSource());
    }
    int increment = 0;

    if (sp != null && e.getScrollAmount() != 0) {
        Adjustable adj = getAdjustableToScroll(sp);
        if (adj != null) {
            increment = getIncrementFromAdjustable(adj, e);
            if (log.isLoggable(PlatformLogger.Level.FINER)) {
                log.finer("increment from adjustable(" + adj.getClass() + ") : " + increment);
            }
            scrollAdjustable(adj, increment);
        }
    }
}
 
Example #17
Source File: LWScrollBarPeer.java    From openjdk-8 with GNU General Public License v2.0 6 votes vote down vote up
@Override
void initializeImpl() {
    super.initializeImpl();
    final Scrollbar target = getTarget();
    setLineIncrement(target.getUnitIncrement());
    setPageIncrement(target.getBlockIncrement());
    setValues(target.getValue(), target.getVisibleAmount(),
              target.getMinimum(), target.getMaximum());

    final int orientation = target.getOrientation();
    final JScrollBar delegate = getDelegate();
    synchronized (getDelegateLock()) {
        delegate.setOrientation(orientation == Scrollbar.HORIZONTAL
                                ? Adjustable.HORIZONTAL
                                : Adjustable.VERTICAL);
        delegate.addAdjustmentListener(this);
    }
}
 
Example #18
Source File: ScrollPaneWheelScroller.java    From hottub with GNU General Public License v2.0 6 votes vote down vote up
public static void handleWheelScrolling(ScrollPane sp, MouseWheelEvent e) {
    if (log.isLoggable(PlatformLogger.Level.FINER)) {
        log.finer("x = " + e.getX() + ", y = " + e.getY() + ", src is " + e.getSource());
    }
    int increment = 0;

    if (sp != null && e.getScrollAmount() != 0) {
        Adjustable adj = getAdjustableToScroll(sp);
        if (adj != null) {
            increment = getIncrementFromAdjustable(adj, e);
            if (log.isLoggable(PlatformLogger.Level.FINER)) {
                log.finer("increment from adjustable(" + adj.getClass() + ") : " + increment);
            }
            scrollAdjustable(adj, increment);
        }
    }
}
 
Example #19
Source File: ScrollPaneOperator.java    From openjdk-jdk9 with GNU General Public License v2.0 6 votes vote down vote up
/**
 * Scrolls pane to bottom.
 *
 * @throws TimeoutExpiredException
 */
public void scrollToBottom() {
    output.printTrace("Scroll ScrollPane to bottom\n"
            + toStringSource());
    output.printGolden("Scroll ScrollPane to bottom");
    produceTimeRestricted(new Action<Void, Void>() {
        @Override
        public Void launch(Void obj) {
            driver.scrollToMaximum(ScrollPaneOperator.this, Adjustable.VERTICAL);
            return null;
        }

        @Override
        public String getDescription() {
            return "Scrolling";
        }

        @Override
        public String toString() {
            return "ScrollPaneOperator.scrollToBottom.Action{description = " + getDescription() + '}';
        }
    }, "ScrollbarOperator.WholeScrollTimeout");
}
 
Example #20
Source File: ScrollPaneWheelScroller.java    From jdk8u-jdk with GNU General Public License v2.0 6 votes vote down vote up
public static int getIncrementFromAdjustable(Adjustable adj,
                                             MouseWheelEvent e) {
    if (log.isLoggable(PlatformLogger.Level.FINE)) {
        if (adj == null) {
            log.fine("Assertion (adj != null) failed");
        }
    }

    int increment = 0;

    if (e.getScrollType() == MouseWheelEvent.WHEEL_UNIT_SCROLL) {
        increment = e.getUnitsToScroll() * adj.getUnitIncrement();
    }
    else if (e.getScrollType() == MouseWheelEvent.WHEEL_BLOCK_SCROLL) {
        increment = adj.getBlockIncrement() * e.getWheelRotation();
    }
    return increment;
}
 
Example #21
Source File: ScrollPaneWheelScroller.java    From openjdk-8 with GNU General Public License v2.0 6 votes vote down vote up
public static int getIncrementFromAdjustable(Adjustable adj,
                                             MouseWheelEvent e) {
    if (log.isLoggable(PlatformLogger.Level.FINE)) {
        if (adj == null) {
            log.fine("Assertion (adj != null) failed");
        }
    }

    int increment = 0;

    if (e.getScrollType() == MouseWheelEvent.WHEEL_UNIT_SCROLL) {
        increment = e.getUnitsToScroll() * adj.getUnitIncrement();
    }
    else if (e.getScrollType() == MouseWheelEvent.WHEEL_BLOCK_SCROLL) {
        increment = adj.getBlockIncrement() * e.getWheelRotation();
    }
    return increment;
}
 
Example #22
Source File: ScrollPaneWheelScroller.java    From TencentKona-8 with GNU General Public License v2.0 5 votes vote down vote up
public static void scrollAdjustable(Adjustable adj, int amount) {
    if (log.isLoggable(PlatformLogger.Level.FINE)) {
        if (adj == null) {
            log.fine("Assertion (adj != null) failed");
        }
        if (amount == 0) {
            log.fine("Assertion (amount != 0) failed");
        }
    }

    int current = adj.getValue();
    int upperLimit = adj.getMaximum() - adj.getVisibleAmount();
    if (log.isLoggable(PlatformLogger.Level.FINER)) {
        log.finer("doScrolling by " + amount);
    }

    if (amount > 0 && current < upperLimit) { // still some room to scroll
                                              // down
        if (current + amount < upperLimit) {
            adj.setValue(current + amount);
            return;
        }
        else {
            adj.setValue(upperLimit);
            return;
        }
    }
    else if (amount < 0 && current > adj.getMinimum()) { // still some room
                                                         // to scroll up
        if (current + amount > adj.getMinimum()) {
            adj.setValue(current + amount);
            return;
        }
        else {
            adj.setValue(adj.getMinimum());
            return;
        }
    }
}
 
Example #23
Source File: ScrollPaneWheelScroller.java    From jdk8u60 with GNU General Public License v2.0 5 votes vote down vote up
public static void scrollAdjustable(Adjustable adj, int amount) {
    if (log.isLoggable(PlatformLogger.Level.FINE)) {
        if (adj == null) {
            log.fine("Assertion (adj != null) failed");
        }
        if (amount == 0) {
            log.fine("Assertion (amount != 0) failed");
        }
    }

    int current = adj.getValue();
    int upperLimit = adj.getMaximum() - adj.getVisibleAmount();
    if (log.isLoggable(PlatformLogger.Level.FINER)) {
        log.finer("doScrolling by " + amount);
    }

    if (amount > 0 && current < upperLimit) { // still some room to scroll
                                              // down
        if (current + amount < upperLimit) {
            adj.setValue(current + amount);
            return;
        }
        else {
            adj.setValue(upperLimit);
            return;
        }
    }
    else if (amount < 0 && current > adj.getMinimum()) { // still some room
                                                         // to scroll up
        if (current + amount > adj.getMinimum()) {
            adj.setValue(current + amount);
            return;
        }
        else {
            adj.setValue(adj.getMinimum());
            return;
        }
    }
}
 
Example #24
Source File: KeyboardJSliderScrollDriver.java    From openjdk-jdk9 with GNU General Public License v2.0 5 votes vote down vote up
private static int getButton(int direction, int orientation) {
    if (direction == ScrollAdjuster.DECREASE_SCROLL_DIRECTION) {
        return (orientation == Adjustable.HORIZONTAL) ? KeyEvent.VK_LEFT : KeyEvent.VK_DOWN;
    } else {
        return (orientation == Adjustable.HORIZONTAL) ? KeyEvent.VK_RIGHT : KeyEvent.VK_UP;
    }
}
 
Example #25
Source File: ScrollPaneOperator.java    From openjdk-jdk9 with GNU General Public License v2.0 5 votes vote down vote up
/**
 * Maps {@code ScrollPane.getVAdjustable()} through queue
 */
public Adjustable getVAdjustable() {
    return (runMapping(new MapAction<Adjustable>("getVAdjustable") {
        @Override
        public Adjustable map() {
            return ((ScrollPane) getSource()).getVAdjustable();
        }
    }));
}
 
Example #26
Source File: ScrollPaneWheelScroller.java    From openjdk-jdk8u-backup with GNU General Public License v2.0 5 votes vote down vote up
public static void scrollAdjustable(Adjustable adj, int amount) {
    if (log.isLoggable(PlatformLogger.Level.FINE)) {
        if (adj == null) {
            log.fine("Assertion (adj != null) failed");
        }
        if (amount == 0) {
            log.fine("Assertion (amount != 0) failed");
        }
    }

    int current = adj.getValue();
    int upperLimit = adj.getMaximum() - adj.getVisibleAmount();
    if (log.isLoggable(PlatformLogger.Level.FINER)) {
        log.finer("doScrolling by " + amount);
    }

    if (amount > 0 && current < upperLimit) { // still some room to scroll
                                              // down
        if (current + amount < upperLimit) {
            adj.setValue(current + amount);
            return;
        }
        else {
            adj.setValue(upperLimit);
            return;
        }
    }
    else if (amount < 0 && current > adj.getMinimum()) { // still some room
                                                         // to scroll up
        if (current + amount > adj.getMinimum()) {
            adj.setValue(current + amount);
            return;
        }
        else {
            adj.setValue(adj.getMinimum());
            return;
        }
    }
}
 
Example #27
Source File: ScrollBarUI.java    From rapidminer-studio with GNU Affero General Public License v3.0 5 votes vote down vote up
@Override
public Dimension getPreferredSize(JComponent c) {
	if (this.scrollbar.getOrientation() == Adjustable.VERTICAL) {
		return new Dimension(SCROLLBAR_WIDTH, 53 + 10);
	} else {
		return new Dimension(100, SCROLLBAR_WIDTH);
	}
}
 
Example #28
Source File: ScrollPaneWheelScroller.java    From Bytecoder with Apache License 2.0 5 votes vote down vote up
public static void scrollAdjustable(Adjustable adj, int amount) {
    if (log.isLoggable(PlatformLogger.Level.FINE)) {
        if (adj == null) {
            log.fine("Assertion (adj != null) failed");
        }
        if (amount == 0) {
            log.fine("Assertion (amount != 0) failed");
        }
    }

    int current = adj.getValue();
    int upperLimit = adj.getMaximum() - adj.getVisibleAmount();
    if (log.isLoggable(PlatformLogger.Level.FINER)) {
        log.finer("doScrolling by " + amount);
    }

    if (amount > 0 && current < upperLimit) { // still some room to scroll
                                              // down
        if (current + amount < upperLimit) {
            adj.setValue(current + amount);
            return;
        }
        else {
            adj.setValue(upperLimit);
            return;
        }
    }
    else if (amount < 0 && current > adj.getMinimum()) { // still some room
                                                         // to scroll up
        if (current + amount > adj.getMinimum()) {
            adj.setValue(current + amount);
            return;
        }
        else {
            adj.setValue(adj.getMinimum());
            return;
        }
    }
}
 
Example #29
Source File: ScrollPaneOperator.java    From openjdk-jdk9 with GNU General Public License v2.0 5 votes vote down vote up
/**
 * Scrolls vertical scroll bar.
 *
 * @param proportionalValue Value to scroll vertical scroll bar to.
 * @throws TimeoutExpiredException
 */
public void scrollToVerticalValue(double proportionalValue) {
    output.printTrace("Scroll ScrollPane to " + Double.toString(proportionalValue) + " proportional vertical value \n"
            + toStringSource());
    output.printGolden("Scroll ScrollPane to " + Double.toString(proportionalValue) + " proportional vertical value");
    Adjustable adj = getVAdjustable();
    scrollTo(new ValueScrollAdjuster((int) (adj.getMinimum()
            + (adj.getMaximum()
            - adj.getVisibleAmount()
            - adj.getMinimum()) * proportionalValue),
            Adjustable.VERTICAL,
            getVAdjustable()));
}
 
Example #30
Source File: ScrollBarUI.java    From rapidminer-studio with GNU Affero General Public License v3.0 5 votes vote down vote up
@Override
public Dimension getMinimumSize(JComponent c) {
	if (this.scrollbar.getOrientation() == Adjustable.VERTICAL) {
		return new Dimension(SCROLLBAR_WIDTH, 40);
	} else {
		return new Dimension(40, SCROLLBAR_WIDTH);
	}
}