The Perl Toolchain Summit needs more sponsors. If your company depends on Perl, please support this very important event.

NAME

  SimpleFileSelect - Easy-to-Use File Selection Widget

SYNOPSIS

  use Tk::SimpleFileSelect;

  my $fs = $mw -> SimpleFileSelect();
  my $file = $fs -> Show();

Options

-font

Name of the font to display in the directory list and file name entry. The default is "*-helvetica-medium-r-*-*-12-*."

-width

Width in character columns of the directory listbox. The default is 30.

-height

Height in lines of the directory listbox. The default is 14.

-directory
-initialdir

Path name of initial directory to display. The default is "." (current directory).

-files

If non-zero, display files as well as directories. The default is 1 (display files).

-dotfiles

If non-zero, display normally hidden files that begin with ".". The default is 0 (don't display hidden files).

-acceptlabel

Text label of the "Accept" button. Defaults to "Accept," naturally. The first character is underlined to correspond with an Alt- accelerator constructed with the first letter of the label.

-filter

Display only files matching this pattern. The default is "*" (all files).

-initialtext

The text to appear in the entry box when the widget is opened.

DESCRIPTION

Tk::SimpleFileSelect is an easy-to-use file selection widget based on Tk::FileSelect. Unlike a FileSelect widget, it does not attempt to verify that a file exists. A SimpleFileSelect Dialog returns whatever text is entered or selected, along with the complete pathname. It is the job of the calling program perform any operations or validation of filenames.

Clicking in the list box on a file or directory name selects it and inserts the selected item in the entry box. Double clicking on a directory or entering it in the entry box changes to that directory.

The Show() method causes the FileSelectWidget to wait until a file is selected in the Listbox, a file name is entered in the text entry widget, or the "Cancel" button is clicked.

The return value is the pathname of a file selected in the Listbox, or the path of the filename in the text entry, or an empty string if no file name is specified.

ADVERTISED SUBWIDGETS

None.

VERSION INFORMATION

  $Id: SimpleFileSelect.pm,v 1.2 2003/11/29 11:33:08 kiesling Exp $

COPYRIGHT INFO

Tk::SimpleFileSelect is derived from the Tk::FileSelect widget in the Perl/Tk library. It is freely distributable and modifiable under the same conditions as Perl. Please refer to the file "Artistic" in the distribution archive.

Written by Robert Allan Kiesling, rkies@cpan.org.

1 POD Error

The following errors were encountered while parsing the POD:

Around line 325:

You forgot a '=back' before '=head1'