Event XbpBrowse():scroll Foundation

Scroll the browse window vertically.

Syntax
:scroll := {| @nScroll, mp2, self | ... }
:scroll ( <nScroll>, <mp2> ) --> self 
xbeBRW_Scroll (1048987)
Parameters
<nScroll>
<nScroll> is a numeric value which indicates the direction in which to scroll the browse window. It corresponds to constants defined in XBP.CH, which are listed below:
First message parameter for :scroll
Constant Scroll
XBPBRW_Scroll_Up One line up
XBPBRW_Scroll_Down One line down
XBPBRW_Scroll_PageUp One page up
XBPBRW_Scroll_PageDown One page down
XBPBRW_Scroll_Top To the beginning of the data
XBPBRW_Scroll_Bottom To the end of the data
XBPBRW_Scroll_Pos To certain percentage position, see :goPosBlock
XBPBRW_Scroll_Track To position according to vertical scroll bar
<mp2>
The second message parameter indicates how many rows the visible area is scrolled. The parameter is only used when scrolling to a specific position.
Return

The method returns a reference to the XbpBrowse object.

Description

The xbeBRW_Scroll event is created whenever the data area of the browse must be scrolled in a vertical direction. The first message parameter indicates the direction in which the data area is scrolled. If the operation involves a position which is to be reached by the scroll, this position is specified in second message parameter.

Unlike the operation triggered by the xbeBRW_Navigate event, scrolling does not reposition the browse cursor. Browse objects may generate both scroll and navigate events depending on the operations performed by the user. For example, pressing the Ctrl and Page Down keys together generates an xbeBRW_Scroll events However, pressing just the Arrow Down key generates an xbeBRW_Navigate event instead. This is because the Arrow Down key moves the browse cursor whereas Ctrl + Page Down just scrolls (pans) the visible display.

Default handling of the xbeBRW_Scroll event automatically executes the :scroll() method to scroll the visible area of the browse. The default handling can be overriden by assigning the value NIL to the <nScroll> parameter passed to the code block. If NIL is contained in <nScroll> when the code block returns, the method :scroll() is not automatically executed. This is useful for applications which implement custom scroll behavior using the :scroll code block.

The navigational behavior of an XbpBrowse object depends on the value in the :navigationMode instance variable. If this is set to XBPBRW_NAVIGATION_1XCOMPATIBLE, no xbeBRW_Scroll events are generated. Instead, vertical movement within the browse generates xbeBRW_Navigate events and hence moves the browse cursor.

Feedback

If you see anything in the documentation that is not correct, does not match your experience with the particular feature or requires further clarification, please use this form to report a documentation issue.