Re: Not really understand on subclassing
- From: Tadej BorovÅak <tadeboro gmail com>
- To: Xi Yang <jiandingzhe msn com>
- Cc: gtk-perl-list gnome org
- Subject: Re: Not really understand on subclassing
- Date: Wed, 14 Apr 2010 14:45:28 +0200
Hi.
I never really used GooCanvas, but I think this code:
######################################
my $elem = test::CanvasExpand->new(
ÂÂÂ $root, 100, 100, 400, 400,
ÂÂÂ 'line-width'ÂÂ => 10,
ÂÂÂ 'radius-x'ÂÂÂÂ => 20,
ÂÂÂ 'radius-y'ÂÂÂÂ => 10,
ÂÂÂ 'stroke-color' => 'yellow',
ÂÂÂ 'fill-color'ÂÂ => 'red'
);
######################################
should look something like this:
#######################################
my $elem = test::CanvasExpand->new(
'x' => 100,
'y' => 100,
'width' => 400,
'height' => 400,
'radius-x' => 20,
'radius-y' => 10,
'stroke-color' => 'yellow',
'fill-color' => 'red',
'parent' => $root
);
#######################################
Not sure what your $root variable stands for there, so I assumed that
this is parent of your item.
Tadej
--
Tadej BorovÅak
tadeboro.blogspot.com
tadeboro gmail com
tadej borovsak gmail com
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]