Initial import of the CDE 2.1.30 sources from the Open Group.
[oweals/cde.git] / cde / programs / dtfile / Prefs.h
1 /* $XConsortium: Prefs.h /main/4 1995/12/12 13:11:56 rswiston $ */
2 /************************************<+>*************************************
3  ****************************************************************************
4  *
5  *   FILE:           Prefs.h
6  *
7  *   COMPONENT_NAME: Desktop File Manager
8  *
9  *   DESCRIPTION:    Public include file for the preferences dialog.
10  *
11  *   (c) Copyright 1993, 1994, 1995 Hewlett-Packard Company
12  *   (c) Copyright 1993, 1994, 1995 International Business Machines Corp.
13  *   (c) Copyright 1993, 1994, 1995 Sun Microsystems, Inc.
14  *   (c) Copyright 1993, 1994, 1995 Novell, Inc.
15  *
16  ****************************************************************************
17  ************************************<+>*************************************/
18
19 #ifndef _Preferences_h
20 #define _Preferences_h
21
22
23 /*  Resource names  */
24
25 #define SELECTION_LIST          "selectionList"
26 #define SHOW_TYPE               "showType"
27 #define TREE_FILES              "treeFiles"
28 #define VIEW                    "view"
29 #define ORDER                   "order"
30 #define DIRECTION_RESRC         "direction"
31 #define RANDOM                  "random"
32
33
34 /*  Defines used as values for the preferences  */
35
36 #define UNSET_VALUE             99
37
38 #define SINGLE_DIRECTORY        0
39 #define MULTIPLE_DIRECTORY      1
40
41 #define TREE_FILES_NEVER        0
42 #define TREE_FILES_CHOOSE       1
43 #define TREE_FILES_ALWAYS       2
44
45 #define BY_NAME                 0
46 #define BY_NAME_AND_ICON        1
47 #define BY_NAME_AND_SMALL_ICON  2
48 #define BY_ATTRIBUTES           3
49
50 #define ORDER_BY_FILE_TYPE      0
51 #define ORDER_BY_ALPHABETICAL   1
52 #define ORDER_BY_DATE           2
53 #define ORDER_BY_SIZE           3
54
55 #define DIRECTION_ASCENDING     0
56 #define DIRECTION_DESCENDING    1
57
58 #define RANDOM_ON               0
59 #define RANDOM_OFF              1
60
61
62 extern DialogClass * preferencesClass;
63
64
65 typedef struct
66 {
67    Boolean       displayed;
68    Position      x;
69    Position      y;
70    Dimension     width;
71    Dimension     height;
72
73    Boolean show_iconic_path;
74    Boolean show_current_dir;
75    Boolean show_status_line;
76    unsigned char show_type;
77    unsigned char tree_files;
78    unsigned char view_single;
79    unsigned char view_tree;
80    unsigned char order;
81    unsigned char direction;
82    unsigned char positionEnabled;
83
84 } PreferencesData, * PreferencesDataPtr;
85
86
87 typedef struct
88 {
89    XtCallbackProc   callback;
90    XtPointer        client_data;
91    XtPointer        preferences_rec;
92 } PreferencesApply;
93
94
95 typedef struct
96 {
97    Widget shell;
98    Widget show_iconic_path;
99    Widget show_current_dir;
100    Widget show_status_line;
101    Widget show_single;
102    Widget show_multiple;
103    Widget tree_files_never;
104    Widget tree_files_choose;
105    Widget tree_files_always;
106    Widget random_on;
107    Widget random_off;
108    Widget by_name;
109    Widget by_name_and_icon;
110    Widget by_name_and_small_icon;
111    Widget by_attributes;
112    Widget order_file_type;
113    Widget order_alphabetical;
114    Widget order_date;
115    Widget order_size;
116    Widget direction_ascending;
117    Widget direction_descending;
118    Widget position;
119
120    Widget ok;
121    Widget apply;
122    Widget reset;
123    Widget close;
124    Widget help;
125
126    unsigned char view_single, view_tree;
127
128    PreferencesApply * apply_data;
129 } PreferencesRec;
130
131 #endif /* _Preferences_h */
132 /* DON'T ADD ANYTHING AFTER THIS #endif */