Interface Scrollable
All Packages  Class Hierarchy  This Package  Previous  Next  Index

Interface Scrollable

public interface netscape.application.Scrollable
{
    /* Fields
     */
    public final static int HORIZONTAL;
    public final static int VERTICAL;

    /* Methods
     */
    public abstract int lengthOfContentViewForAxis(int);
    public abstract int lengthOfScrollViewForAxis(int);
    public abstract int positionOfContentViewForAxis(int);
    public abstract void scrollBy(int, int);
    public abstract void scrollTo(int, int);
}
Interface for objects interested in being controlled by a ScrollBar, such as a ScrollView.
See Also:
ScrollBar, ScrollView, ScrollGroup

Fields

HORIZONTAL

  public final static int HORIZONTAL
Axis value indicating a Horizontal scroller.

VERTICAL

  public final static int VERTICAL
Axis value indicating a Vertical scroller.

Methods

.lengthOfScrollViewForAxis

  public abstract int lengthOfScrollViewForAxis(int axis)
This method should return the total length of the visible scroll area. This length determines the percent visible area, which sets the scroller knob size. axis indicates the scrolling direction, either VERTICAL or HORIZONTAL.

.lengthOfContentViewForAxis

  public abstract int lengthOfContentViewForAxis(int axis)
This method should return the total length of the View being scrolled. This length determines the percent visible area, which sets the scroller knob size. axis indicates the scrolling direction, either VERTICAL or HORIZONTAL.

.positionOfContentViewForAxis

  public abstract int positionOfContentViewForAxis(int axis)
This method should return the visible scroll area's origin relative to the origin of the View being scrolled. This position determines the scroller knob's position. axis indicates the scrolling direction, either VERTICAL or HORIZONTAL.

.scrollTo

  public abstract void scrollTo(int x,
                                int y)
This method tells the Scrollable to change the origin of the View it's scrolling to (x, y)

.scrollBy

  public abstract void scrollBy(int deltaX,
                                int deltaY)
This method tells the Scrollable to move the origin of the View it's scrolling by (deltaX, deltaY)

All Packages  Class Hierarchy  This Package  Previous  Next  Index

Copyright © 1997 Netscape Communications Corporation. All rights reserved
Please send any comments or corrections to ifcfeedback@netscape.com
HTML generated on 21 Oct 1997