Tk::GetoptTk::Getopt is a user configuration window for Tk with interface to Getopt::Long. | |
Download |
Tk::Getopt Ranking & Summary
Advertisement
- License:
- Perl Artistic License
- Price:
- FREE
- Publisher Name:
- Slaven Rezic
- Publisher web site:
- http://search.cpan.org/~srezic/
Tk::Getopt Tags
Tk::Getopt Description
Tk::Getopt is a user configuration window for Tk with interface to Getopt::Long. Tk::Getopt is a user configuration window for Tk with interface to Getopt::Long.SYNOPSIS use Tk::Getopt; @opttable = (, , ...); $opt = new Tk::Getopt(-opttable => @opttable, -options => %options, -filename => "$ENV{HOME}/.options"); $opt->set_defaults; # set default values $opt->load_options; # configuration file $opt->get_options; # command line $opt->process_options; # process callbacks, check restrictions ... print $options->{'opt1'}, $options->{'opt2'} ...; ... $top = new MainWindow; $opt->option_editor($top);or using a Getopt::Long-like interface $opt = new Tk::Getopt(-getopt => );or an alternative Getopt::Long interface %optctl = ('foo' => $foo, 'bar' => $bar); $opt = new Tk::Getopt(-getopt => );Tk::Getopt provides an interface to access command line options via Getopt::Long and editing with a graphical user interface via a Tk window.Unlike Getopt::Long, this package uses a object oriented interface, so you have to create a new Tk::Getopt object with new. Unlike other packages in the Tk hierarchy, this package does not define a Tk widget. The graphical interface is calles by the method option_editor.After creating an object with new, you can parse command line options by calling get_options. This method calls itself Getopt::Long::GetOptions. Requirements: · Perl
Tk::Getopt Related Software