Dialog
view release on metacpan or search on metacpan
void Dialog::refresh();
int Dialog::ungetch(ch);
void Dialog::attrset(attr);
void Dialog::mvprintw(y, x, s);
void Dialog::gotoyx(y, x);
int Dialog::getch();
int Dialog::YesNo(title, prompt, h, w);
int Dialog::PrgBox(title, line, h, w, pause, use_shell);
int Dialog::MsgBox(title, prompt, h, w, pause);
int Dialog::TextBox(title, file, h, w);
str Dialog::Menu(title, prompt, h, w, menu_h, ...);
str Dialog::RadioList(title, prompt, h, w, list_h, ...);
array Dialog::CheckList(title, prompt, h, w, list_h, ...);
str Dialog::InputBox(title, prompt, h, w, str);
int Dialog::Y();
int Dialog::X();
Strings passed to Menu, CheckList and RadioList may contain single
zero char (ASCII 0) which delimites menu columns. You may, of course,
pass such strings into other routines, but it will be your pain yet.
And, at all, see B<test.pl> and try to understand anything.
If you have any suggestions and/or contributions, please, don't
hesitate to send me.
=head1 AUTHOR
char * file
int height
int width
PROTOTYPE: $$$$
CODE:
RETVAL = dialog_textbox(title, file, height, width);
OUTPUT:
RETVAL
void
Menu(title, prompt, height, width, menu_height, menu_item1, ...)
char * title
char * prompt
int height
int width
int menu_height
SV * menu_item1 = NO_INIT
PROTOTYPE: $$$$$@
PREINIT:
int item_no, i, cancel, zero = 0;
uchar **item_list, **item_ptr, *item;
my $dlg = Dialog->new('Clients', 5, 10, 15, 60);
my $il_host = $dlg->inputline("il_host", 2, 3, 50);
$dlg->label("label1", 2, 4, "Client host");
my $il_desc = $dlg->inputline("il_name", 5, 3, 50);
$dlg->label("label2", 5, 4, "Description");
$dlg->button("bt_ok", 11, 25, " &Ok ", mrOk);
$dlg->button("bt_cancel", 11, 39, "C&ancel", mrCancel);
Dialog::Clear();
my $host = Dialog::Menu('Edit host', 'Choose host to edit',
20, 30, 13, @hosts);
Dialog::Clear();
my $radio = Dialog::RadioList('Radio demo', 'Pick one of the options',
20, 30, 13, @radio);
Dialog::Clear();
$il_host->data($host);
$il_desc->data($hosts{$host});
$dlg->redraw;
( run in 1.164 second using v1.01-cache-2.11-cpan-49f99fa48dc )