Leser: 1
|< 1 2 3 >| | 25 Einträge, 3 Seiten |
1
2
3
...
my $can = $objects->Canvas(-relief => "raised", -borderwidth => 2, -width => 225, height => 150)->place(-x => 5, -y => 180);
...
my $node = Tk::GraphItems::TextBox->new(canvas => $can, text => 'test', x => 50, y => 50);
my $node = Tk::GraphItems->TextBox(canvas => $can, text => 'test', x => 50, y => 50);
Tk::GraphItems::TextBox->new
(Tk::GraphItems::TextBox())->new
'Tk::GraphItems::TextBox'->new
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
use strict;
use warnings;
use Tk;
use Tk::GraphItems;
#require Tk::GraphItems;
use Tk::GraphItems::TextBox;
my $mw = tkinit;
my $c = $mw->Canvas->pack;
my $tb = Tk::GraphItems::TextBox->new(canvas => $c,
x => 10,
y => 20,
text => 'test');
MainLoop;
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
my $mw = new MainWindow(-title => "Robot Control GUI", -height => 600, -width => 800);
my $objects = $leftframe->Frame(-relief => "raised", -borderwidth => 2,-height => 350, -width => 250)->grid(-row => 1, -sticky => "nw");
$objects->Label(-text => "OPTICAL OBJECT SETUP\n========================================")->place(-x => 0, -y => 0);
$objects->Label(-text => "select object file:")->place(-x => 5, -y => 40);
$selectobo = $objects->JComboBox(-choices => \@obolist)->place(-x => 120, -y => 40);
$selectobo->setSelectedIndex(0);
$objects->Button(-text => 'select for configuration', -command => sub {&config($selectobo)} )->place(-x => 67, -y => 70);
$objects->Label(-text => '----------------------------------------------------------------------------')->place(-x => 5, -y => 92);
$objects->Label(-text => "configuration for")->place(-x => 5, -y => 110);
$objects->Entry(-relief => 'flat', -textvariable => \$cursel, -state => 'disabled', -width => 20)->place(-x => 95, -y => 110);
$rb1 = $objects->Radiobutton(-text => ' active', -value => "active", -variable => \$obomode, -command => \&modeselect)->place(-x => 45, -y => 140);
$rb2 = $objects->Radiobutton(-text => ' passive', -value => "passive", -variable => \$obomode, -command => \&modeselect)->place(-x => 45, -y => 160);
$can = $objects->Canvas(-relief => "raised", -borderwidth => 2, -width => 225, height => 150)->place(-x => 5, -y => 180);
foreach (sort keys %{$oo})
{
my $node = Tk::GraphItems::TextBox->new(canvas => $can, text => 'test', x => 50, y => 50);
}
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18
#!/usr/bin/perl use strict; use warnings; use Tk; use Tk::GraphItems; my $oo = { 1 => 'hallo', 2 => 'test', 3 => 'perl' }; my $mw = new MainWindow(-title => "Robot Control GUI", -height => 600, -width => 800); my $can = $mw->Canvas(-relief => "raised", -borderwidth => 2, -width => 225, height => 150)->place(-x => 5, -y => 180); # == foreach (sort keys %{$oo}) { my $node = Tk::GraphItems::TextBox->new(canvas => $can, text => 'test', x => 50, y => 50); } MainLoop;
|< 1 2 3 >| | 25 Einträge, 3 Seiten |