Curses-UI
view release on metacpan or search on metacpan
let Window centering be real Window centering. This
also makes it possible to create a "popup"
menubar by letting the main windows draw over
the menubar (the menubar will only be visible
if it gets the focus).
- Widgets now can focus another widget using their
event callback routines. Before, the widget would
always go to the next or previous widget, but now
loose_focus() won't do this if the focus is not on
the widget itself anymore. I'm not sure if it works
for all widgets already, but I needed it to be
able to use the menubar to shift focus between
windows.
2002-01-27 - Renamed the 'return' binding in all widgets to
'loose-focus'. This makes much more sense in
the new event system (in the old event system
a widget would actually return a value when
the 'return' binding was called).
- Renamed the '-homeonreturn' option for TextEditor
and its descendants to '-homeonblur' for the
same reason as mentioned above.
- The buttonbox will handle the TAB key different
than before. Now it will cycle through the buttons.
If the last button is selected and TAB is pressed,
the total Buttonbox will loose focus. This is much
more like the behaviour that a user would expect.
- Fixed a layout bug in Dialog::Basic (if the buttonwidth
was larger than the messagewidth, a 'screen not large
enough' error would show).
- Fixed a bug in FileBrowser.pm. The popupbox in the
FileBrowser window was still built for the old
event system. Now it has an -onchange event which
reloads the file list. Also, the focus will not
longer go to the buttons, but to the filelistbox
or the fileentry field if -editfilename is set
to a true value.
2002-01-26 - Reading keys is not done anymore using the halfdelay
function of curses. Now a select() call is used to
determine if there is input waiting.
- The timeout for reading a key is now depending
upon the smallest active timed event interval.
If there are no active timed events at all,
the timeout will be -1, which causes a full
blocking read. In this way as little as possible
resources are used.
- -windowscr, screenwidth and screenheight were a
little bit too cryptic I think. These are now
renamed to -canvasscr, canvaswidth and
canvasheight.
- Fixed bug in Searchable.pm (cursor was not visible
during search).
- Switched testing to Test::Harness (t/*.t)
- Buttonbox now also has Curses::UI->fatalerror() in
case of an illegal button definition.
- Curses::UI now checks if there is only one
instance of Curses:UI and it now exports
MainLoop() (just for fun, it is like the
Tk MainLoop function).
2002-01-25 - Fixed some problems with modal focused windows.
- The Popupmenu widget now also works. This widget
is partly rewritten to make it more clean and
make it fit in the new event system.
- New method: Curses::UI->fatalerror( [error] ).
This will display a fatal error to the user.
After pressing a key, the program will exit.
This is usefull in places where you would
otherwise use die() (or one of its Carp friends).
- Moved usemodule() from the Container package to
Curses::UI. This method now honours the %INC
hash, which means less on-the-fly loading of
modules will occur.
- Made searching through listboxes and textviewers
possible in the new event system.
- Fixed some -onchange event bugs in popupmenu.
till 2002-01-24 - The complete event structure is set upside-down.
By using this new event structure, timed routines
and mouse events are possibilities. Maybe even
integration with POE! :-) (but I haven't looked
into that enough to be sure). We also have a
Tk-like mainloop() now.
- Updated a lot of widgets to support the new event
structure (central mainloop in Curses::UI which
delegates events). This means that a widget has
a event_keypress() method, which handles
delegated keypresses.
Version 0.64
============
2002-01-19: - Started on building a complete new event handling
system. This should simplify a couple of things and
it should enable new features like some kind of
time loop and mouse events.
Version 0.63
============
2002-01-16: - Added a CLASS HIERARCHY section to the
documentation of each Curses::UI class.
- All focusable objects now have the following
event callbacks:
-onfocus / onFocus()
-onblur / onBlur()
- The Curses::UI::Calendar widget now fully
supports the years 0 - 9999, including the
transition from the Julian to the Gregorian
calendar (september 1752). This beats the
use of timelocal/localtime (which would
currently only support 1900 - 2038 IIRC).
- Added intellidraw() method to Curses::UI::Widget.
If this method is called, the widget is redrawn, but
only if it's visible (not hidden and in topwindow)
and if intellidraw is enabled (-intellidraw data
member has a true value).
This routine can be used to be able to redraw
widgets on a status change, without having to figure
out yourself if this wouldn't clutter up the screen.
The -intellidraw option is meant for widget
builders (see for example the Checkbox code).
- Incorporated intellidraw() method in:
- Curses::UI::Window
- Curses::UI::Label
- Curses::UI::Calendar
- Curses::UI::Buttonbox
- Curses::UI::Listbox (+ descendants)
- Curses::UI::Checkbox
- Curses::UI::Popupbox
- Curses::UI::Progressbar
- Curses::UI::TextEditor (+ descendants)
- Curses::UI::SearchEntry
- Added a little example application to demonstrate
the new intellidraw feature: examples/demo-intellidraw
2002-01-15: - Changed the displaying of the calendar widget
a little. The topbar showing a date is only
highlighted if the cursor is on the selected date.
- Renamed some widgets (now we still can). I think
there are too many capitals in them...
- Curses::UI::ListBox renamed to
Curses::UI::Listbox
- Curses::UI::CheckBox renamed to
Curses::UI::Checkbox
- Curses::UI::MenuBar renamed to
Curses::UI::Menubar
- Curses::UI::MenuListBox renamed to
Curses::UI::MenuListbox
- Curses::UI::PopupBox renamed to
Curses::UI::Popupmenu
- Curses::UI::ProgressBar renamed to
Curses::UI::Progressbar
- Curses::UI::ButtonBox renamed to
Curses::UI::Buttonbox
- Curses::UI::RadioButtonBox renamed to
Curses::UI::Radiobuttonbox
- Curses::UI::Dialog::FileBrowser renamed to
Curses::UI::Dialog::Filebrowser
- Added event callbacks to:
- Curses::UI::Calendar (-onchange / onChange())
- Curses::UI::Listbox (-onchange / onChange())
- Curses::UI::Checkbox (-onchange / onChange())
- Curses::UI::TextEditor (-onchange / onChange())
- Curses::UI::TextEntry (-onchange / onChange())
- Curses::UI::PasswordEntry (-onchange / onChange())
- Curses::UI::Popupmenu (-onchange / onChange())
- The options that can be passed to the new()
methods, are case insensitive now. So it is
perfectly okay to write:
$win->add(
'cb', 'Checkbox',
-Label => 'Demonstration widget',
-onChange => sub { exit() }
);
Version 0.62
============
2002-01-14: - Changed the Label widget. The text to
show on the widget may contain more than
one line of text (so newline characters
may be used). The status-dialog is changed
accordingly. Other widgets that use Labels
are not updated yet.
- Updated Curses::UI::Dialog::Progress for
use with the new Label widget.
- Fixed a layout bug in Curses::UI::Widget
(the available height and width were
incorrectly computed when using negative
-x and -y offsets).
( run in 0.792 second using v1.01-cache-2.11-cpan-39bf76dae61 )