Skip to Main Content
Volume 6A: Motif Programming Manual
book

Volume 6A: Motif Programming Manual

by David Brennan, Dan Heller, Paula Ferguson
September 1993
Intermediate to advanced content levelIntermediate to advanced
1014 pages
28h 26m
English
O'Reilly Media, Inc.
Content preview from Volume 6A: Motif Programming Manual
For automatic scrolling, the only thing left to decide is how you want the ScrollBars to be displayed if the work
window dynamically grows or shrinks. There may be situations where the work window is the same size as or smaller
than the clip window. In this case, you may not want to display the ScrollBars, since they are not needed. If so, you
can set XmN-scrollBarDisplayPolicy to XmAS_NEEDED. If you always want the ScrollBars to be visible,
whether or not they are needed, you can set the resource to XmSTATIC. Some people prefer static ScrollBars, so that
consistency is maintained in the interface; having ScrollBars appear and disappear frequently may be confusing.
Perhaps the best thing to do is to allow the user to specify the XmNscrollBarDisplayPolicy. You can always
set your preference in the application defaults file, as shown below:
*XmScrolledWindow.scrollBarDisplayPolicy: static
10.2.2 Application−defined Scrolling
In the application−defined scrolling mode, XmNscrollingPolicy is set to XmAPPLICATION_DEFINED. In this
case, the work window must be the same size as the clip window, so the size of the work window is set by the toolkit.
As a result, the XmNvisualPolicy resource has the value of XmVARIABLE, which indicates that the work window
grows and shrinks with the ScrolledWindow. Since the two windows are the same size, the ScrolledWindow doesn't
need to have a clip window, so it doesn't create one.
Because application−defined scrolling implies that you are responsible for the creation ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Volume 7A: XView Programming Manual

Volume 7A: XView Programming Manual

Dan Heller

Publisher Resources

ISBN: 9780596000431