line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package Draft::TkGui::Drawing; |
2
|
|
|
|
|
|
|
|
3
|
|
|
|
|
|
|
=head1 NAME |
4
|
|
|
|
|
|
|
|
5
|
|
|
|
|
|
|
Draft::TkGui::Drawing - Tk drawing type |
6
|
|
|
|
|
|
|
|
7
|
|
|
|
|
|
|
=head1 SYNOPSIS |
8
|
|
|
|
|
|
|
|
9
|
|
|
|
|
|
|
A container for multiple drawing entities. |
10
|
|
|
|
|
|
|
|
11
|
|
|
|
|
|
|
=head1 DESCRIPTION |
12
|
|
|
|
|
|
|
|
13
|
|
|
|
|
|
|
Code for displaying a drawing on screen. |
14
|
|
|
|
|
|
|
|
15
|
|
|
|
|
|
|
=cut |
16
|
|
|
|
|
|
|
|
17
|
1
|
|
|
1
|
|
5
|
use strict; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
30
|
|
18
|
1
|
|
|
1
|
|
4
|
use warnings; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
153
|
|
19
|
|
|
|
|
|
|
|
20
|
|
|
|
|
|
|
# FIXME should subclass Draft::Drawing, not the other way around |
21
|
|
|
|
|
|
|
|
22
|
|
|
|
|
|
|
#use vars qw(@ISA); |
23
|
|
|
|
|
|
|
#@ISA = qw(Draft::Drawing); |
24
|
|
|
|
|
|
|
|
25
|
|
|
|
|
|
|
sub Draw |
26
|
|
|
|
|
|
|
{ |
27
|
0
|
|
|
0
|
0
|
|
my $self = shift; |
28
|
0
|
|
|
|
|
|
my ($canvas, $offset, $parents, $ignore) = @_; |
29
|
|
|
|
|
|
|
|
30
|
0
|
|
|
|
|
|
$self->Read; |
31
|
|
|
|
|
|
|
|
32
|
0
|
|
|
|
|
|
foreach my $key (keys %{$self}) |
|
0
|
|
|
|
|
|
|
33
|
|
|
|
|
|
|
{ |
34
|
0
|
0
|
|
|
|
|
next if ($key =~ /^_/); |
35
|
0
|
0
|
|
|
|
|
next if grep (/^$key$/, @{$ignore}); |
|
0
|
|
|
|
|
|
|
36
|
|
|
|
|
|
|
|
37
|
0
|
|
|
|
|
|
$self->{$key}->Draw ($canvas, $offset, $parents, $ignore); |
38
|
|
|
|
|
|
|
} |
39
|
|
|
|
|
|
|
} |
40
|
|
|
|
|
|
|
|
41
|
|
|
|
|
|
|
1; |