The "Filewin" Widget

This widget provides a file selector (browser).

Library: karmawidets
Link With: -lkarmawidgets

Tables

Filewin_ResourceNamesList of resource names for Filewin widget
Filewin_ResourcesList of resources for Filewin widget

Functions

XkwFilewinRescanForce a directory rescan in a Filewin widget.
XkwFilewinCurrentDirectoryGet the current directory in a Filewin widget.
XkwFilewinRegisterDirCbkRegister a callback to capture directory selection events.
XkwFilewinStandardFileTester_nDStandard file tester.
XkwFilewinStandardFileTester_3DStandard file tester for cube files.
XkwFilewinChangeDirectoryChange the current directory for a Filewin widget.


Tables


Filewin_ResourceNames

Name Purpose
XkwNfileSelectCallback Callbacks for file selection
XkwNfilenameTester Callbacks to test filenames
XtNforeground The foreground pixel
XkwNforwardSyntheticEvents Forward synthetic events
XkwNtrapDirectoryDatasets Trap directories which are known dataset types


Filewin_Resources

Name Class Rep. Type Default
XkwNfileSelectCallback XtCCallback XtRCallback NULL
XkwNfilenameTester XtCCallback XtRPointer NULL
XtNforeground XtCForeground XtRPixel XtDefaultForeground
XkwNforwardSyntheticEvents XkwCForwardSyntheticEvents XtRBool False
XkwNtrapDirectoryDatasets XkwCTrapDirectoryDatasets XtRBool False


Functions


EXPERIMENTAL FUNCTION: subject to change without notice

void XkwFilewinRescan (Widget W)

Force a directory rescan in a Filewin widget.

Parameters:

Returns: Nothing.
Multithreading Level: Unsafe


EXPERIMENTAL FUNCTION: subject to change without notice

char * XkwFilewinCurrentDirectory (Widget W)

Get the current directory in a Filewin widget.

Parameters:

Returns: A pointer to a dynamically allocated string containing the current directory for the widget. This must be freed with m_free.
Multithreading Level: Unsafe


EXPERIMENTAL FUNCTION: subject to change without notice

KCallbackFunc XkwFilewinRegisterDirCbk (Widget w, flag (*callback) (Widget w, void *info, CONST char *dirname), void *info)

This routine will register a callback to capture directory selection events prior to the Filewin widget changing directory.

Parameters:

Returns: A KCallbackFunc object.
Multithreading Level: Unsafe


EXPERIMENTAL FUNCTION: subject to change without notice

flag XkwFilewinStandardFileTester_nD (KFileInfo finfo)

This routine may be passed as the value for the XkwNfilenameTester resource on a FilewinWidget or FilepopupWidget. The routine will accept all known filetypes.

Parameters:

Returns: TRUE if the file is to be displayed, else FALSE.
Multithreading Level: Unsafe


EXPERIMENTAL FUNCTION: subject to change without notice

flag XkwFilewinStandardFileTester_3D (KFileInfo finfo)

This routine may be passed as the value for the XkwNfilenameTester resource on a FilewinWidget or FilepopupWidget. The routine will accept all known filetypes which are capable of containing a 3-dimensional array of data.

Parameters:

Returns: TRUE if the file is to be displayed, else FALSE.
Multithreading Level: Unsafe


EXPERIMENTAL FUNCTION: subject to change without notice

flag XkwFilewinChangeDirectory (Widget W, CONST char *dirname)

Change the current directory for a Filewin widget.

Parameters:

Returns: TRUE on success, else FALSE. On error the directory is unchanged.
Multithreading Level: Unsafe


Back to Karma Home Page
Contact: Richard Gooch
Web Development: Ariel Internet Services