 |
DECwindows Extensions to Motif
DXmSvnAutoScrollCheck
Controls whether the DXmSvnAutoScrollDisplay routine should be called.
Format
int DXmSvnAutoScrollCheck(widget, x, y)
Widget widget;
int x;
int y;
|
Return Value
An integer that indicates whether the DXmSvnAutoScrollDisplay routine
will be called, as follows:
| Value |
Description |
|
0 (False)
|
DXmSvnAutoScrollDisplay will not be called.
|
|
1 (True)
|
DXmSvnAutoScrollDisplay will be called.
|
Arguments
widget
The identifier (widget ID) of the SVN widget.
x
An integer that represents the x location of the cursor
relative to the upper left corner of the SVN window.
y
An integer that represents the y location of the cursor
relative to the upper left corner of the SVN window.
Description
The DXmSvnAutoScrollCheck routine determines whether the cursor is
currently in an area where automatic scrolling (initiated when the user
moves an entry outside the window) can occur. This routine returns True
if the cursor is in such an area and if there are no entries
displayed in that direction. The application should call the
DXmSvnAutoScrollDisplay routine if this routine returns True.
Use this routine if your application controls the dragging operations
(using the DXmSvnSetApplDragging routine). See the
DXmSvnSetApplDragging and DXmSvnAutoScrollDisplay routines for related
information.
DXmSvnAutoScrollDisplay
Automatically scrolls the screen one unit based on the cursor position.
Format
void DXmSvnAutoScrollDisplay(widget, x, y)
Widget widget;
int x;
int y;
|
Arguments
widget
The identifier (widget ID) of the SVN widget.
x
An integer that represents the current x location of the
cursor.
y
An integer that represents the current y location of the
cursor.
Description
The DXmSvnAutoScrollDisplay routine automatically scrolls the screen
one unit based on the current cursor location. If the cursor is not in
a location that permits automatic scrolling, this call is ignored.
Use this routine if your application controls the dragging operations
(using the DXmSvnSetApplDragging routine). See the
DXmSvnSetApplDragging and DXmSvnAutoScrollCheck routines for related
information.
DXmSvnClearHighlight
Removes (clears) highlighting from a specified entry.
Format
void DXmSvnClearHighlight(widget, entry)
Widget widget;
int entry;
|
Arguments
widget
The identifier (widget ID) of the SVN widget.
entry
An integer that represents the entry that will no longer be highlighted.
Description
The DXmSvnClearHighlight routine removes (clears) highlighting from a
specified entry in the structure. If the entry is not currently
highlighted, this call is ignored. Make this call in your application
between calls to DXmSvnDisableDisplay and DXmSvnEnableDisplay.
DXmSvnClearHighlighting
Removes (clears) all highlighting from the entries.
Format
void DXmSvnClearHighlighting(widget)
Widget widget;
|
Arguments
widget
The identifier (widget ID) of the SVN widget.
Description
The DXmSvnClearHighlighting routine removes (clears) all highlighting
from all entries in the structure. If there are currently no
highlighted entries, this call is ignored. Make this call in your
application between calls to DXmSvnDisableDisplay and
DXmSvnEnableDisplay.
DXmSvnClearSelection
Clears (cancels) the selection of a specified entry.
Format
void DXmSvnClearSelection(widget, entry)
Widget widget;
int entry;
|
Arguments
widget
The identifier (widget ID) of the SVN widget.
entry
An integer that represents the entry that will no longer be selected.
Description
The DXmSvnClearSelection routine clears, or cancels, the selection of a
particular entry in the structure. If the entry is not currently
selected, the call is ignored. Make this call in your application
between calls to DXmSvnDisableDisplay and DXmSvnEnableDisplay.
DXmSvnClearSelections
Clears all selections.
Format
void DXmSvnClearSelections(widget)
Widget widget;
|
Arguments
widget
The identifier (widget ID) of the SVN widget.
Description
The DXmSvnClearSelections routine clears (cancels) all of the entries
in the structure. If no entries are currently selected, the call is
ignored. (Use the DXmSvnGetSelections, DXmSvnClearSelections, and
DXmSvnShowSelections routines when getting, clearing, and showing
selections.) Make this call in your application between calls to
DXmSvnDisableDisplay and DXmSvnEnableDisplay.
DXmSvnDeleteEntries
Deletes entries from the structure.
Format
void DXmSvnDeleteEntries(widget, after, count)
Widget widget;
int after;
int count;
|
Arguments
widget
The identifier (widget ID) of the SVN widget.
after
An integer that represents the entry number after which a specified
number of entries are to be deleted.
count
An integer that represents the number of entries to delete from the
array.
Description
The DXmSvnDeleteEntries routine enables an application to process the
removal (collapse) of an entry. This routine specifies how many entries
to delete and after which entry those deletions should begin. Make this
call in your application between calls to DXmSvnDisableDisplay and
DXmSvnEnableDisplay.
DXmSvnDisableDisplay
Temporarily disables the SVN widget from generating a display.
Format
void DXmSvnDisableDisplay(widget)
Widget widget;
|
Arguments
widget
The identifier (widget ID) of the SVN widget.
Description
The DXmSvnDisableDisplay routine allows your application to make
changes to the SVN widget without the user making additional changes.
For example, the DXmSvnDisableDisplay routine must be called when the
user has selected to either expand or collapse an entry in the
structure. No further user actions will be processed (because the SVN
widget is temporarily disabled) until that expand or collapse operation
has been completed and the DXmSvnEnableDisplay routine has been called
(which re-enables the SVN widget and makes the changes visible to the
user).
The kinds of changes that can be implemented while the widget is
disabled include the following:
- Calling the DXmSvnSelectAll or DXmSvnClearSelections routine to
change selections
- Calling the DXmSvnAddEntries or DXmSvnDeleteEntries routine to
change the underlying structure
- Changing the appearance of an entry (adding highlighting or
sensitivity, for example)
This routine is required only when the changes are not in response to
an SVN callback. (The SVN widget automatically disables the SVN widget
prior to issuing the callback and automatically enables the widget upon
return.)
See the DXmSvnEnableDisplay routine for related information.
DXmSvnEnableDisplay
Reenables the SVN widget.
Format
void DXmSvnEnableDisplay(widget)
Widget widget;
|
Arguments
widget
The identifier (widget ID) of the SVN widget.
Description
The DXmSvnEnableDisplay routine reenables the SVN widget, which then
determines whether to update the display (make changes visible to the
user) based on activities recorded while the SVN widget was in the
disabled mode. These activities can include changes to selections, the
addition or deletion of entries, or changes to the appearance of
entries.
Your application must call this routine following a call to the
DXmSvnDisableDisplay routine. (See the description of that routine for
related information.)
DXmSvnFlushEntry
Displays the specified entry on the screen if it is the next logically
displayed entry.
Format
void DXmSvnFlushEntry(widget, entry)
Widget widget;
int entry;
|
Arguments
widget
The identifier (widget ID) of the SVN widget.
entry
An integer that represents the specified entry.
Description
The DXmSvnFlushEntry routine displays (or "flushes") an entry
on the screen (in outline mode only) if the entry number passed to the
routine is one integer greater than the entry number of the last
displayed entry and there is enough space for the entry to fit
in the display. If there is not enough blank space for the entry to
fit, DXmSvnFlushEntry permits the SVN widget to scroll to the entry.
DXmSvnGetComponentNumber
Retrieves (returns) the component number containing a supplied tag
value.
Format
int DXmSvnGetComponentNumber(widget, tag)
Widget widget;
XtPointer tag;
|
Return Value
An integer that represents the component number. (Returns 0 if the
supplied tag value is not found.)
Arguments
widget
The identifier (widget ID) of the SVN widget.
tag
A value that represents the component tag.
Description
The DXmSvnGetComponentNumber routine is called whenever the application
requires the component number that is associated with a particular tag
value. If the specified tag value is not found, then a value of 0 is
returned.
See the descriptions of the DXmSvnSetComponentTag and
DXmSvnInsertComponent routines for information about setting the tag
value for a component.
DXmSvnGetComponentTag
Retrieves (returns) a component tag for a specified component number.
Format
XtPointer DXmSvnGetComponentTag(widget, comp_number)
Widget widget;
unsigned int comp_number;
|
Return Value
An integer that represents the tag value (returns 0 if the component
tag has not been set).
Arguments
widget
The identifier (widget ID) of the SVN widget.
comp_number
An integer that represents the component number.
Description
The DXmSvnGetComponentTag routine retrieves (returns) a component tag
for a specified component number whenever the application requires that
information. You can set the value for this tag by using the
DXmSvnInsertComponent or DXmSvnSetComponentTag routine.
DXmSvnGetComponentText
Retrieves (returns) the address of a compound string.
Format
XmString DXmSvnGetComponentText(widget, entry_number, comp_number)
Widget widget;
int entry_number;
int comp_number;
|
Return Value
A pointer to the compound string.
Arguments
widget
The identifier (widget ID) of the SVN widget.
entry_number
An integer that represents the number of the entry.
comp_number
An integer that represents the number of the component.
Description
The DXmSvnGetComponentText routine returns the address of a compound
string that was previously stored from a call to the
DXmSvnSetComponentText routine.
DXmSvnGetComponentWidth
Retrieves (returns) the width of a specified component.
Format
int DXmSvnGetComponentWidth(widget, comp_number)
Widget widget;
int comp_number;
|
Return Value
An integer that represents the width of the component.
Arguments
widget
The identifier (widget ID) of the SVN widget.
comp_number
An integer that represents the component number.
Description
The DXmSvnGetComponentWidth routine is called whenever the application
requires the component width that is associated with a particular
component number. You can set the value for the width by using the
DXmSvnInsertComponent or DXmSvnSetComponentWidth routine. Note that the
SVN widget automatically increases the width field whenever it
encounters a component that is wider than the current width value.
DXmSvnGetDisplayed
Retrieves (returns) displayed entry numbers and related information
necessary to draw a corresponding display.
Format
void DXmSvnGetDisplayed(widget, entries, tags, ys, len)
Widget widget;
int *entries[];
unsigned int *tags[];
int *ys[];
int len;
|
Arguments
widget
The identifier (widget ID) of the SVN widget.
entries
A pointer to an array of integers to receive the entry numbers of the
entries being displayed.
tags
A pointer to an array of longwords to receive the application's
entry_tag value for each entry displayed. If tags are
not required, a Null pointer may be passed.
ys
A pointer to an array of longwords to receive the y-coordinates for
each entry displayed. If y-coordinates are not required, a Null pointer
can be passed.
len
The number of entries allocated in the provided array.
Description
The DXmSvnGetDisplayed routine returns information about the entries
that the SVN widget is currently displaying. This information can then
be used to keep a simultaneous display up to date with the SVN widget
window (in the case of a dialog box, for example, which might contain
totals for the entries being displayed).
The application is responsible for managing the memory used to return
this list of entries. As such, note the following:
- At the minimum, the number of entries in the array should be
capable of holding at least the number of entries indicated by the
value returned from the DXmSvnGetNumDisplayed routine.
- If there are more entries in the array than the application will
need, the SVN widget will set the value for those extra entries to 0.
- If the capacity of the arrays passed is less than the number of
selected entries, only the number of entries allocated in the provided
array (the value for len) will be returned.
DXmSvnGetEntryLevel
Retrieves (returns) the level of an entry in the display.
Format
int DXmSvnGetEntryLevel(widget, entry)
Widget widget;
int entry;
|
Return Value
An integer that represents the entry level.
Arguments
widget
The identifier (widget ID) of the SVN widget.
entry
An integer that represents the entry number.
Description
The DXmSvnGetEntryLevel routine is called whenever the application
requires the level number for a given entry number.
DXmSvnGetEntryNumber
Retrieves (returns) an entry number for a specified entry tag value.
Format
int DXmSvnGetEntryNumber(widget, tag)
Widget widget;
XtPointer tag;
|
Return Value
An integer that represents the entry number (returns 0 if the entry tag
value does not correspond to any entry number).
Arguments
widget
The identifier (widget ID) of the SVN widget.
tag
A value that represents the entry tag.
Description
The DXmSvnGetEntryNumber routine retrieves (returns) an entry number
for a specified entry tag value whenever the application requires that
information. See the DXmSvnAddEntries and DXmSvnSetEntry routines for
related information.
DXmSvnGetEntryPosition
Retrieves (returns) the position of an entry in the display.
Format
void DXmSvnGetEntryPosition(widget, entry, mode, x, y)
Widget widget;
int entry;
Boolean mode;
int *x;
int *y;
|
Arguments
widget
The identifier (widget ID) of the SVN widget.
entry
An integer that represents the number of the entry for which position
information is required.
mode
A Boolean value that, when True, specifies that position information
returned is relative to the upper left corner of the SVN window. When
False, the position information returned is internal SVN information
only (for column and outline mode) or indicates the position of the
entry in the entire tree (tree mode).
x
A pointer to the x position in the tree.
y
A pointer to the y position in the tree.
Description
The DXmSvnGetEntryPosition routine allows an application to determine
the position of entries. The routine interprets the x- and
y-coordinates differently, depending on the application's mode:
- Outline and Column mode
When the application is in outline or
column mode (the DXmSvnNdisplayMode resource has been set to either
DXmSvnKdisplayOutline or DXmSvnKdisplayColumn) and
mode for the DXmSvnGetEntryPosition routine has been
set to True, the x- and y-coordinates indicate, in pixels, the distance
of the displayed entry from the upper left corner of the SVN window.
However, if the specified entry is not visible in the SVN
window, the routine returns -1 (an invalid value) for both the x- and
y-coordinates, because the SVN widget cannot determine the position of
such an entry when the application is in outline or column mode.
When mode is False, the values returned for the x-
and y-coordinates are only meaningful internally to the SVN widget.
- Tree mode
When the application is in tree mode (the
DXmSvnNdisplayMode resource is set to DXmSvnKdisplayTree) and the
DXmSvnNtreeStyle resource is set to DXmSvnKuserDefinedTree (the
application controls the format), the x- and y-coordinates indicate, in
pixels, the distance of the displayed entry from the upper left corner
of the SVN window, when mode is True. If the entry
is not visible in the SVN window, the mode is
False. However, in tree mode, the returned x- and y-coordinates
indicate the position of the entry in the entire tree, even though that
position extends beyond the limit of what can currently be displayed in
the SVN window.
Note that for position values to be valid, the SVN widget must have
been enabled prior to any changes made to the contents of the display.
|