summaryrefslogtreecommitdiffstats
path: root/doc/chooseDirectory.n
diff options
context:
space:
mode:
authordkf <donal.k.fellows@manchester.ac.uk>2004-06-21 14:19:38 (GMT)
committerdkf <donal.k.fellows@manchester.ac.uk>2004-06-21 14:19:38 (GMT)
commitf3e2946fd89fe5577b128af95756bd815b830a4d (patch)
tree720b2670714e31cfc8ad6bcbcce8ad71a3b281b2 /doc/chooseDirectory.n
parent803c90ca3f790775351db3072ae5e57fe8d1beb7 (diff)
downloadtk-f3e2946fd89fe5577b128af95756bd815b830a4d.zip
tk-f3e2946fd89fe5577b128af95756bd815b830a4d.tar.gz
tk-f3e2946fd89fe5577b128af95756bd815b830a4d.tar.bz2
Added example
Diffstat (limited to 'doc/chooseDirectory.n')
-rw-r--r--doc/chooseDirectory.n18
1 files changed, 13 insertions, 5 deletions
diff --git a/doc/chooseDirectory.n b/doc/chooseDirectory.n
index 42bf636..ad9cf75 100644
--- a/doc/chooseDirectory.n
+++ b/doc/chooseDirectory.n
@@ -2,7 +2,7 @@
'\" Copyright (c) 1998-2000 by Scriptics Corporation.
'\" All rights reserved.
'\"
-'\" RCS: @(#) $Id: chooseDirectory.n,v 1.1 2000/01/27 00:23:10 ericm Exp $
+'\" RCS: @(#) $Id: chooseDirectory.n,v 1.2 2004/06/21 14:19:38 dkf Exp $
'\"
.so man.macros
.TH tk_chooseDirectory n 8.3 Tk "Tk Built-In Commands"
@@ -43,10 +43,18 @@ option is not specified, then a default title will be displayed.
Specifies whether the user may specify non-existant directories. If
this parameter is true, then the user may only select directories that
already exist. The default value is \fIfalse\fR.
-.LP
+.SH EXAMPLE
+.CS
+set dir [tk_chooseDirectory \\
+ \-initialdir ~ \-title "Choose a directory"]
+if {$dir eq ""} {
+ label .l -text "No directory selected"
+} else {
+ label .l -text "Selected $dir"
+}
+.CE
.SH "SEE ALSO"
-tk_getOpenFile, tk_getSaveFile
-
+tk_getOpenFile(n), tk_getSaveFile(n)
.SH KEYWORDS
-directory selection dialog
+directory, selection, dialog, platform-specific