18 Feb 2010 04:58:37 UTC
- Distribution: Tk-DirSelect
- Module version: 1.12
- Source (raw)
- Browse (raw)
- How to Contribute
- Issues (1)
- Testers (4039 / 1045 / 0)
- KwaliteeBus factor: 0
- 85.71% Coverage
- License: perl_5
- Activity24 month
- Download (7.91KB)
- MetaCPAN Explorer
- Subscribe to distribution
- This version
- Latest versionMJCARMAN Michael Carman
- LICENSE AND COPYRIGHT
Tk::DirSelect - Cross-platform directory selection widget.
use Tk::DirSelect; my $ds = $mw->DirSelect(); my $dir = $ds->Show();
This module provides a cross-platform directory selection widget. For systems running Microsoft Windows, this includes selection of local and mapped network drives. A context menu (right-click or <Button3>) allows the creation, renaming, and deletion of directories while browsing.
Note: Perl/Tk 804 added the
chooseDirectorymethod which uses native system dialogs where available. (i.e. Windows) If you want a native feel for your program, you probably want to use that method instead -- possibly using this module as a fallback for systems with older versions of Tk installed.
Constructs a new DirSelect widget as a child of the invoking object (usually a MainWindow).
The title for the widget can be set by specifying
-title => 'Title'. Any other options provided will be passed through to the DirTree widget that displays directories, so be sure they're appropriate (e.g.
Displays the DirSelect widget and returns the user selected directory or
undefif the operation is canceled.
All arguments are optional. The first argument (if defined) is the initial directory to display. The default is to display the current working directory. Any additional options are passed through to the Popup() method. This means that you can do something like
$ds->Show(undef, -popover => $mw);
to center the dialog over your application.
Win32API::File (under Microsoft Windows only)
Copyright 2000-2001 Kristi Thompson <firstname.lastname@example.org> Copyright 2002-2005,2010 Michael Carman <email@example.com>
This program is free software; you can redistribute it and/or modify it under the terms of either: the GNU General Public License as published by the Free Software Foundation; or the Artistic License.
See http://dev.perl.org/licenses/ for more information.
Module Install Instructions
To install Tk::DirSelect, copy and paste the appropriate command in to your terminal.
perl -MCPAN -e shell install Tk::DirSelect
For more information on module installation, please visit the detailed CPAN module installation guide.