File: demo-cuml

package info (click to toggle)
libcurses-ui-perl 0.9609-2
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 1,312 kB
  • sloc: perl: 12,464; makefile: 2
file content (36 lines) | stat: -rwxr-xr-x 857 bytes parent folder | download | duplicates (7)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
#!/usr/bin/perl -w
# Tutorial example
# 2003 (c) by Marcus Thiesen (marcus@cpan.org)
# This file is a part of Curses::UI and might be distributed 
# under the same terms as perl itself.

# Use the libraries from the distribution, instead of 
# system wide libraries.
use FindBin;
use lib "$FindBin::RealBin/../lib";

use strict;
use Curses::UI;
my $cui = new Curses::UI( -color_support => 1 );

my $win1 = $cui->add(
		     'win1', 'Window',
		     -border => 1,
		     -y    => 1,
		     -bfg  => 'red',
		     );

my $listbox = $win1->add('lb', 'Listbox',
			 -multi => 1,
			 -htmltext => 1,
			 -values => [ "<reverse>reverse text</reverse>",
				      "<bold>bold text</bold>",
				      "<underline>underlined text</underline>",
				      "<blink>blinking text</blink>",
				      "<dim>dim text</dim>",
				      ],
			 );
$cui->draw;
sleep 5;