2
* @OPENGROUP_COPYRIGHT@
4
* Copyright (c) 1990, 1991, 1992, 1993 Open Software Foundation, Inc.
5
* Copyright (c) 1996, 1997, 1998, 1999, 2000 The Open Group
6
* ALL RIGHTS RESERVED (MOTIF). See the file named COPYRIGHT.MOTIF for
7
* the full copyright text.
9
* This software is subject to an open license. It may only be
10
* used on, with or for operating systems which are themselves open
11
* source systems. You must contact The Open Group for a license
12
* allowing distribution and sublicensing of this software on, with,
13
* or for operating systems which are not Open Source programs.
15
* See http://www.opengroup.org/openmotif/license for full
16
* details of the license agreement. Any use, reproduction, or
17
* distribution of the program constitutes recipient's acceptance of
20
* EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, THE PROGRAM IS
21
* PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
22
* KIND, EITHER EXPRESS OR IMPLIED INCLUDING, WITHOUT LIMITATION, ANY
23
* WARRANTIES OR CONDITIONS OF TITLE, NON-INFRINGEMENT, MERCHANTABILITY
24
* OR FITNESS FOR A PARTICULAR PURPOSE
26
* EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, NEITHER RECIPIENT
27
* NOR ANY CONTRIBUTORS SHALL HAVE ANY LIABILITY FOR ANY DIRECT,
28
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
29
* DAMAGES (INCLUDING WITHOUT LIMITATION LOST PROFITS), HOWEVER CAUSED
30
* AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
31
* LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN
32
* ANY WAY OUT OF THE USE OR DISTRIBUTION OF THE PROGRAM OR THE
33
* EXERCISE OF ANY RIGHTS GRANTED HEREUNDER, EVEN IF ADVISED OF THE
34
* POSSIBILITY OF SUCH DAMAGES.
39
/* $XConsortium: FileSBP.h /main/13 1995/09/19 23:02:34 cde-sun $ */
41
* (c) Copyright 1989, DIGITAL EQUIPMENT CORPORATION, MAYNARD, MASS. */
43
* (c) Copyright 1987, 1988, 1989, 1990, 1991, 1992 HEWLETT-PACKARD COMPANY */
47
#include <Xm/SelectioBP.h>
48
#include <Xm/FileSB.h>
54
/* Defines for use in allocation geometry matrix. */
56
#define XmFSB_MAX_WIDGETS_VERT 12
58
/* Bit locations for the state_flags bit field.
60
#define XmFS_NO_MATCH (1 << 0)
61
#define XmFS_IN_FILE_SEARCH (1 << 1)
62
#define XmFS_DIR_SEARCH_PROC (1 << 2)
64
/* Constraint part record for FileSelectionBox widget */
66
typedef struct _XmFileSelectionBoxConstraintPart
69
} XmFileSelectionBoxConstraintPart, * XmFileSelectionBoxConstraint;
71
/* New fields for the FileSelectionBox widget class record */
75
XtPointer extension; /* Pointer to extension record */
76
} XmFileSelectionBoxClassPart;
79
/* Full class record declaration */
81
typedef struct _XmFileSelectionBoxClassRec
83
CoreClassPart core_class;
84
CompositeClassPart composite_class;
85
ConstraintClassPart constraint_class;
86
XmManagerClassPart manager_class;
87
XmBulletinBoardClassPart bulletin_board_class;
88
XmSelectionBoxClassPart selection_box_class;
89
XmFileSelectionBoxClassPart file_selection_box_class;
90
} XmFileSelectionBoxClassRec;
92
externalref XmFileSelectionBoxClassRec xmFileSelectionBoxClassRec;
95
/* New fields for the FileSelectionBox widget record */
99
XmString directory; /* directory specification */
100
XmString pattern; /* file search pattern */
101
Widget dir_list_label; /* directory list Label */
102
XmString dir_list_label_string;/* directory list label text */
103
Widget dir_list; /* directory List */
104
XmString * dir_list_items; /* items in directory List */
105
int dir_list_item_count;/* number of items in directory List */
106
int dir_list_selected_item_position;
107
Widget filter_label; /* file search filter label */
108
XmString filter_label_string;/* filter label text */
109
Widget filter_text; /* filter text entry field */
110
XmString dir_mask; /* string in filter text entry field */
111
XmString no_match_string; /* string in list when no file match */
112
XmQualifyProc qualify_search_data_proc; /* directory and mask routine */
113
XmSearchProc dir_search_proc; /* change directory routine */
114
XmSearchProc file_search_proc; /* file search routine */
115
unsigned char file_type_mask; /* mask for type of files in file list */
116
Boolean list_updated; /* flag to indicate file list update */
117
Boolean directory_valid ; /* flag to indicate valid new directory*/
118
unsigned char state_flags ; /* internal flags to indicate state. */
121
XtEnum file_filter_style ;
123
Widget dir_text_label ;
124
XmString dir_text_label_string ;
125
time_t prev_dir_modtime;
126
} XmFileSelectionBoxPart;
129
/****************************************************************
131
* Full instance record declaration
133
****************************************************************/
135
typedef struct _XmFileSelectionBoxRec
138
CompositePart composite;
139
ConstraintPart constraint;
140
XmManagerPart manager;
141
XmBulletinBoardPart bulletin_board;
142
XmSelectionBoxPart selection_box;
143
XmFileSelectionBoxPart file_selection_box;
144
} XmFileSelectionBoxRec;
149
#define FS_Directory( w) \
150
(((XmFileSelectionBoxWidget)(w))->file_selection_box.directory)
151
#define FS_DirMask( w) \
152
(((XmFileSelectionBoxWidget)(w))->file_selection_box.dir_mask)
153
#define FS_DirListLabel( w) \
154
(((XmFileSelectionBoxWidget)(w))->file_selection_box.dir_list_label)
155
#define FS_DirListLabelString( w) \
156
(((XmFileSelectionBoxWidget)(w))->file_selection_box.dir_list_label_string)
157
#define FS_DirList( w) \
158
(((XmFileSelectionBoxWidget)(w))->file_selection_box.dir_list)
159
#define FS_DirListItems( w) \
160
(((XmFileSelectionBoxWidget)(w))->file_selection_box.dir_list_items)
161
#define FS_DirListItemCount( w) \
162
(((XmFileSelectionBoxWidget)(w))->file_selection_box.dir_list_item_count)
163
#define FS_FilterLabel( w) \
164
(((XmFileSelectionBoxWidget)(w))->file_selection_box.filter_label)
165
#define FS_FilterLabelString( w) \
166
(((XmFileSelectionBoxWidget)(w))->file_selection_box.filter_label_string)
167
#define FS_FilterText( w) \
168
(((XmFileSelectionBoxWidget)(w))->file_selection_box.filter_text)
169
#define FS_Pattern( w) \
170
(((XmFileSelectionBoxWidget)(w))->file_selection_box.pattern)
171
#define FS_NoMatchString( w) \
172
(((XmFileSelectionBoxWidget)(w))->file_selection_box.no_match_string)
173
#define FS_QualifySearchDataProc( w) (((XmFileSelectionBoxWidget) \
174
(w))->file_selection_box.qualify_search_data_proc)
175
#define FS_DirSearchProc( w) \
176
(((XmFileSelectionBoxWidget)(w))->file_selection_box.dir_search_proc)
177
#define FS_FileSearchProc( w) \
178
(((XmFileSelectionBoxWidget)(w))->file_selection_box.file_search_proc)
179
#define FS_RealDefaultButton( w) \
180
(((XmFileSelectionBoxWidget)(w))->file_selection_box.real_default_button)
181
#define FS_FileTypeMask( w) \
182
(((XmFileSelectionBoxWidget)(w))->file_selection_box.file_type_mask)
183
#define FS_ListUpdated( w) \
184
(((XmFileSelectionBoxWidget)(w))->file_selection_box.list_updated)
185
#define FS_DirectoryValid( w) \
186
(((XmFileSelectionBoxWidget)(w))->file_selection_box.directory_valid)
187
#define FS_StateFlags( w) \
188
(((XmFileSelectionBoxWidget)(w))->file_selection_box.state_flags)
189
#define FS_DirListSelectedItemPosition( w) (((XmFileSelectionBoxWidget) w) \
190
->file_selection_box.dir_list_selected_item_position)
192
#define FS_PathMode( w) (((XmFileSelectionBoxWidget) w) \
193
->file_selection_box.path_mode)
194
#define FS_FileFilterStyle( w) (((XmFileSelectionBoxWidget) w) \
195
->file_selection_box.file_filter_style)
196
#define FS_DirText( w) (((XmFileSelectionBoxWidget) w) \
197
->file_selection_box.dir_text)
198
#define FS_DirTextLabel( w) (((XmFileSelectionBoxWidget) w) \
199
->file_selection_box.dir_text_label)
200
#define FS_DirTextLabelString( w) (((XmFileSelectionBoxWidget) w) \
201
->file_selection_box.dir_text_label_string)
202
#define FS_PrevDirModTime( w) (((XmFileSelectionBoxWidget) w) \
203
->file_selection_box.prev_dir_modtime)
206
/******** Private Function Declarations ********/
209
/******** End Private Function Declarations ********/
213
} /* Close scope of 'extern "C"' declaration which encloses file. */
216
#endif /* _XmFSelectP_h */
217
/* DON'T ADD ANYTHING AFTER THIS #endif */