Curses:...gressbar(3)
π Curses::UI::Progressbar π
okay so bestie, welcome to the Curses:...gressbar(3) page from User Contributed Perl Documentation. this is the whole tea on the progressbar widget, and we're keeping every single detail because that's the vibe. no cap. π«Ά
πΈ NAME πΈ
Curses::UI::Progressbar β create and manipulate progressbar widgets. slay. β¨
π§ CLASS HIERARCHY π§
the family tree is literally right here, bestie:
Curses::UI::Widget
|
+----Curses::UI::Progressbar
π¦ SYNOPSIS π¦
here's the starter pack, exact code and all:
use Curses::UI;
my $cui = new Curses::UI;
my $win = $cui->add('window_id', 'Window');
my $progressbar = $win->add(
'myprogressbar', 'Progressbar',
-max => 250,
-pos => 42,
);
$progressbar->draw;
π DESCRIPTION π
Curses::UI::Progressbar is a widget that can be used to give some sort of progress information to your program's user. it's giving "loading screen main character energy," honestly. the progressbar looks like this:
+------------------------------------------+
|||||||||---------- 14% ------------------ |
+------------------------------------------+
there's a short demo in the distribution at exampes/demo-Curses::UI::Progressbar β yes, that's the path exactly as the page says it. iykyk. π
β¨ STANDARD OPTIONS β¨
the standard-option lineup is literally:
-parent-x-y-width-height-pad-padleft-padright-padtop-padbottom-ipad-ipadleft-ipadright-ipadtop-ipadbottom-title-titlefullwidth-titlereverse
for an explanation of these standard options, see Curses::UI::Widget. π
π WIDGET-SPECIFIC OPTIONS π
these are the options that are specifically about the progressbar, bestie:
-min < VALUE >β this option sets the minimum value for the progress bar. the default is0.-max < VALUE >β this option sets the maximum value for the progress bar.-pos < VALUE >β this option sets the startposition for the progress bar.-nopercentage < BOOLEAN >β this option controls whether a percentage indicator should be drawn in the widget. the default for theBOOLEANvalue is false, so a percentage indicator will be drawn. π-showvalue < BOOLEAN >β if this option is set to a true value, the current position value will be drawn in the widget.-nocenterline < BOOLEAN >β this option controls whether a horizontal line should be drawn in the widget. the default for theBOOLEANvalue is false, so a horizontal line will be drawn.
π METHODS π
new ( OPTIONS )layout ( )draw ( BOOLEAN )intellidraw ( )focus ( )
these are standard methods. see Curses::UI::Widget for an explanation of these. π
get ( )β this method will return the current-posvalue of the widget.pos ( VALUE )β this method will set the-posvalue of the widget toSCALAR.
π DEFAULT BINDINGS π
since a Progressbar is a non-interacting widget, it does not have any bindings. periodt. no keyboard drama here. π
π₯ SEE ALSO π₯
Curses::UICurses::UI::WidgetCurses::UI::Common
π AUTHOR π
Copyright (c) 2001-2002 Maurice Makaay. All rights reserved.
Maintained by Marcus Thiesen (marcus@cpan.thiesenweb.de)
This package is free software and is provided "as is" without express or implied warranty. It may be used, redistributed and/or modified under the same terms as perl itself.
cute little sign-off snuggle: perl v5.42.2, 2023-07-03 β mwah, byeee π
π¦ where this page comes from
- alpine 3.24: perl-curses-ui-doc 0.9609-r3 Β· GPL-1.0-or-later OR Artistic-1.0-Perl
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms