aboutsummaryrefslogtreecommitdiff
path: root/sandbox
diff options
context:
space:
mode:
Diffstat (limited to 'sandbox')
-rw-r--r--sandbox/local.pl6
-rw-r--r--sandbox/testarc.tcl5
2 files changed, 8 insertions, 3 deletions
diff --git a/sandbox/local.pl b/sandbox/local.pl
index b66f179..d56e708 100644
--- a/sandbox/local.pl
+++ b/sandbox/local.pl
@@ -3,6 +3,7 @@
use Tk;
use Tk::Zinc;
use Controls;
+use Tk::Photo;
require Tk::PNG;
$mw = MainWindow->new();
@@ -12,7 +13,7 @@ $penguin = $mw->Photo(-format => 'png',
-file => "xpenguin.png");
$top = 1;
-$zinc = $mw->Zinc(-render => 0,
+$zinc = $mw->Zinc(-render => 1,
-borderwidth => 0,
-relief => 'sunken',
-tile => $papier);
@@ -28,7 +29,8 @@ $clip = $zinc->add('rectangle', $gr1, [50, 50, 399, 399],
$gr2 = $zinc->add('group', $gr1);
$clip2 = $zinc->add('rectangle', $gr2, [200, 200, 450, 450],
-filled => 1,
- -fillcolor => 'white:100|white:0',
+# -fillcolor => 'white:100|white:0',
+ -fillcolor => 'white:100 0|black:0 100',
# -fillcolor => 'white 0 |blue 20|blue 80|black:0 100/270',
-linewidth => 0);
#$zinc->itemconfigure($gr2, -clip => $clip2);
diff --git a/sandbox/testarc.tcl b/sandbox/testarc.tcl
index 0d52f6f..09a9c88 100644
--- a/sandbox/testarc.tcl
+++ b/sandbox/testarc.tcl
@@ -32,10 +32,13 @@ set arc [.r add arc $view "50 -10 200 -100" -filled t -closed t -pieslice t \
#.r add icon $view2 -image penguin
set cliparc [.r add arc $view "-100 100 100 -100" -filled t \
- -fillcolor tan -fillalpha 200]
+ -fillcolor tan ]
.r lower $cliparc
#.r rotate $cliparc 20 0 0
#.r translate $cliparc 100 -40
#.r itemconfigure $view2 -clip $cliparc
bind .r <1> ".r rotate $cliparc [expr 3.14/3] 0 0"
source "controls.tcl"
+.r bind $cliparc <1> {puts a}
+puts "[ .r bind $cliparc <1> ]\n"
+