1tixFileSelectBox(n) Tix Built-In Commands tixFileSelectBox(n)
2
3
4
6 tixFileSelectBox - Create and manipulate Tix FileSelectBox widgets
7
9 tixFileSelectBox pathName ?options?
10
12 The FileSelectBox widget supports all the standard options of a frame
13 widget. See the options(n) manual entry for details on the standard
14 options.
15
17 [-browsecmd browsecmd] Specifies the command to execute when the user
18 browses through the files. By default, if the -browsecmd is specified,
19 the browse command will be executed when the user clicks on a filename
20 in the Files listbox. [-command command] Specifies the command to exe‐
21 cute when the FileSelectBox is invoked. This command is executed with
22 one parameter : the filename selected by the user.
23
24 Name: directory
25 Class: Directory
26 Switch: -directory
27 Alias: -dir
28
29 Specifies the directory to look for files. By default this will
30 be the current working directory of the program and will be
31 changed as the user browses through the directories. [-disable‐
32 callback disableCallback] A boolean value indicating whether
33 callbacks should be disabled. When set to true, the TCL command
34 specified by the -command option is not executed when the -value
35 of the ExFileSelectBox widget changes. [-pattern pattern] Spec‐
36 ifies the matching pattern of the file names that should be
37 listed in the Files listbox. For example "*.c" matches all the
38 filenames that end with ".c". If this option is set to the empty
39 string, the default pattern "*" will be used.
40
41 Name: value
42 Class: Value
43 Switch: -value
44 Alias: -selection
45
46 Specifies the name of the filename currently selected by the
47 user.
48
50 Name: dirlist
51 Class: TixScrolledListBox
52
53 The scrolled listbox that shows the directories.
54
55 Name: filelist
56 Class: TixScrolledListBox
57
58 The scrolled listbox that shows the files.
59
60 Name: filter
61 Class: TixComboBox
62
63 The ComboBox listbox that shows the filter string.
64
65 Name: selection
66 Class: TixComboBox
67
68 The ComboBox listbox that shows the file selection.
69
71 The tixFileSelectBox command creates a new window (given by the path‐
72 Name argument) and makes it into a FileSelectBox widget. Additional
73 options, described above, may be specified on the command line or in
74 the option database to configure aspects of the FileSelectBox such as
75 its cursor and relief.
76
77 The FileSelectBox is similar to the standard Motif(TM) file-selection
78 box. It is generally used for the user to choose a file. FileSelectBox
79 stores the files mostly recently selected into a ComboBox widget so
80 that they can be quickly selected again. The tixFileSelectDialog widget
81 is a combination of the FileSelectBox widget and a dialog widget.
82
84 The tixFileSelectBox command creates a new Tcl command whose name is
85 the same as the path name of the FileSelectBox's window. This command
86 may be used to invoke various operations on the widget. It has the
87 following general form:
88 pathName option ?arg arg ...?
89 PathName is the name of the command, which is the same as the FileSe‐
90 lectBox widget's path name. Option and the args determine the exact
91 behavior of the command. The following commands are possible for File‐
92 SelectBox widgets:
93
94 pathName cget option
95 Returns the current value of the configuration option given by
96 option. Option may have any of the values accepted by the tix‐
97 FileSelectBox command.
98
99 pathName configure ?option? ?value option value ...?
100 Query or modify the configuration options of the widget. If no
101 option is specified, returns a list describing all of the avail‐
102 able options for pathName (see Tk_ConfigureInfo for information
103 on the format of this list). If option is specified with no
104 value, then the command returns a list describing the one named
105 option (this list will be identical to the corresponding sublist
106 of the value returned if no option is specified). If one or
107 more option-value pairs are specified, then the command modifies
108 the given widget option(s) to have the given value(s); in this
109 case the command returns an empty string. Option may have any
110 of the values accepted by the tixFileSelectBox command.
111
112 pathName filter
113 Updates the files listed in the FileSelectBox according to the
114 filtering pattern sepcified in the filter subwidget.
115
116 pathName invoke
117 Execute the command specified by the -command option with the
118 filename stored in the selection subwidget.
119
120 pathName subwidget name ?args?
121 When no options are given, this command returns the pathname of
122 the subwidget of the specified name.
123
124 When options are given, the widget command of the specified sub‐
125 widget will be called with these options.
126
128 TIX automatically creates class bindings for FileSelectBoxes that give
129 them the following default behavior:
130
131 [1] Mouse button 1 in the Directory listbox will change the filter
132 string to the selected directory.
133
134 [2] Mouse button 1 in the Files listbox will change the filename
135 that appears in the Selection entry. It will also trigger the
136 -browsecmd if the option has been specified.
137
138 [3] The current directory will be changed by (1) double clicking the
139 Directory listbox or (2) invoking the Filter ComboBox. Please
140 refer to the man page of tixComboBox for the default bindings of
141 the ComboBoxes and how they can be invoked.
142
143 [4] The command specified by the option -command will be invoked by
144 (1) double clicking the Files listbox or (2) invoking Selection
145 ComboBox.
146
148 tixFileSelectBox, tixComboBox, tixFileSelectDialog, Tix(n),
149
150
151
152
153
154
155Tix 4.0 tixFileSelectBox(n)