Tk::Date 0.42 review

Download
by rbytes.net on

Tk::Date is a date/time widget for perl/Tk. SYNOPSIS use Tk::Date; $date_widget = $top->Date->pack; $date_widget-

License: Perl Artistic License
File size: 17K
Developer: Slaven Rezic
0 stars award from rbytes.net

Tk::Date is a date/time widget for perl/Tk.

SYNOPSIS

use Tk::Date;
$date_widget = $top->Date->pack;
$date_widget->get("%x %X");

Tk::Date implements a date/time widget. There are three ways to input a date:
Using the keyboard to input the digits and the tab key or the mouse pointer to move focus between fields.

Using up and down cursor keys to increment/decrement the date (only with installed Tk::NumEntryPlain widget).

Selecting up and down arrow buttons will increment or decrement the value of the active field (only with installed Tk::FireButton widget).

The Date/Time Format

Unlike Java, Perl does not have a date/time object. However, it is possible to use the unix time (seconds since epoch, that is 1st January 1970) as a replacement. This is limited, since on most architectures, the valid range is between 14th December 1901 and 19th January 2038. For other dates, it is possible to use a hash notation:

{ y => year,
m => month,
d => day,
H => hour,
M => minute,
S => second }

The abbreviations are derivated from the format letters of strftime. Note that year is the full year (1998 instead of 98) and month is the real month number, as opposed to the output of localtime(), where the month is subtracted by one.

In this document, the first method will be referred as unixtime and the second method as datehash.

STANDARD OPTIONS

Tk::Date descends from Frame and inherits all of its options.

-orient

Specified orientation of the increment and decrements buttons. May be vertical (default) or horizontal.

Requirements:
Perl

Tk::Date 0.42 keywords