|
Trouver une ressource
Vous ne trouvez pas de réponse à votre problème ? Alors posez la question dans le forum. Souvenez-vous qu'il n'y a jamais de question bête, mais rester dans l'ignorance parce que l'on n'ose pas poser une question, ça c'est une erreur !
CALCULATRICE EN PICWIN
Information sur la source
Description
Une calculatice en PicWin pour changer :) Pour l'ouvrir tapez : /calc
Source
- alias calc {
- unset %calc
- unset %calc2
- window -BCdg0k0pRz +dl @Calc 0 0 327 134
- drawfill -r @calc $rgb(218,240,252) 1 10 10
- drawrect -f @calc 2 2 0 0 327 15
- drawtext -roc @calc $rgb(250,250,250) Tahoma 10 5 3 200 20 Calculatrice par atlantisfr
- drawrect @calc 2 2 0 15 327 119
- drawrect @calc 2 2 0 15 337 129
- drawrect -f @calc 4 2 314 3 11 11
- drawrect @calc 0 1 314 3 11 11
- drawrect -f @calc 3 2 301 3 11 11
- drawrect @calc 0 1 301 3 11 11
- drawrect -f @calc 15 2 5 20 156 17
- drawrect @calc 2 2 5 20 156 17
- drawrect -f @calc 15 2 5 40 156 17
- drawrect @calc 2 2 5 40 156 17
- drawrect -f @calc 15 2 5 60 50 15
- drawrect @calc 2 2 5 60 50 15
- drawtext -oc @calc 2 Tahoma 10 27 61 60 20 9
- drawrect -f @calc 15 2 58 60 50 15
- drawrect @calc 2 2 58 60 50 15
- drawtext -oc @calc 2 Tahoma 10 80 61 60 20 8
- drawrect -f @calc 15 2 111 60 50 15
- drawrect @calc 2 2 111 60 50 15
- drawtext -oc @calc 2 Tahoma 10 133 61 60 20 7
- drawrect -f @calc 15 2 5 78 50 15
- drawrect @calc 2 2 5 78 50 15
- drawtext -oc @calc 2 Tahoma 10 27 79 60 20 6
- drawrect -f @calc 15 2 58 78 50 15
- drawrect @calc 2 2 58 78 50 15
- drawtext -oc @calc 2 Tahoma 10 80 79 60 20 5
- drawrect -f @calc 15 2 111 78 50 15
- drawrect @calc 2 2 111 78 50 15
- drawtext -oc @calc 2 Tahoma 10 133 79 60 20 4
- drawrect -f @calc 15 2 5 96 50 15
- drawrect @calc 2 2 5 96 50 15
- drawtext -oc @calc 2 Tahoma 10 27 97 60 20 3
- drawrect -f @calc 15 2 58 96 50 15
- drawrect @calc 2 2 58 96 50 15
- drawtext -oc @calc 2 Tahoma 10 80 97 60 20 2
- drawrect -f @calc 15 2 111 96 50 15
- drawrect @calc 2 2 111 96 50 15
- drawtext -oc @calc 2 Tahoma 10 133 97 60 20 1
- drawrect -f @calc 15 2 5 114 50 15
- drawrect @calc 2 2 5 114 50 15
- drawtext -oc @calc 2 Tahoma 10 27 115 60 20 0
- drawrect -f @calc 15 2 58 114 50 15
- drawrect @calc 2 2 58 114 50 15
- drawtext -oc @calc 2 Tahoma 10 77 115 60 20 00
- drawrect -f @calc 15 2 111 114 50 15
- drawrect @calc 2 2 111 114 50 15
- drawtext -oc @calc 2 Tahoma 10 135 112 60 20 ,
- drawline @calc 2 2 165 20 165 128
- drawrect -f @calc 15 2 169 20 75 15
- drawrect @calc 2 2 169 20 75 15
- drawtext -oc @calc 2 Tahoma 10 203 21 60 20 +
- drawrect -f @calc 15 2 247 20 75 15
- drawrect @calc 2 2 247 20 75 15
- drawtext -oc @calc 2 Tahoma 10 282 21 60 20 -
- drawrect -f @calc 15 2 169 38 75 15
- drawrect @calc 2 2 169 38 75 15
- drawtext -oc @calc 2 Tahoma 10 204 39 60 20 x
- drawrect -f @calc 15 2 247 38 75 15
- drawrect @calc 2 2 247 38 75 15
- drawtext -oc @calc 2 Tahoma 10 280 39 60 20 ÷
- drawrect -f @calc 15 2 169 56 36 15
- drawrect @calc 2 2 169 56 36 15
- drawtext -oc @calc 2 Tahoma 9 185 58 60 20 (
- drawrect -f @calc 15 2 208 56 36 15
- drawrect @calc 2 2 208 56 36 15
- drawtext -oc @calc 2 Tahoma 9 224 58 60 20 )
- drawrect -f @calc 15 2 247 56 75 15
- drawrect @calc 2 2 247 56 75 15
- drawtext -oc @calc 2 Tahoma 10 280 57 60 20 %
- drawrect -f @calc 15 2 169 74 75 15
- drawrect @calc 2 2 169 74 75 15
- drawtext -oc @calc 2 Tahoma 10 185 75 60 20 Au carré
- drawrect -f @calc 15 2 247 74 76 15
- drawrect @calc 2 2 247 74 75 15
- drawtext -oc @calc 2 Tahoma 10 280 75 60 20 Pi
- drawrect -f @calc 15 2 169 92 76 15
- drawrect @calc 2 2 169 92 76 15
- drawtext -oc @calc 2 Tahoma 10 202 93 60 20 =
- drawrect -f @calc 15 2 247 92 76 15
- drawrect @calc 2 2 247 92 75 15
- drawtext -oc @calc 2 Tahoma 10 267 93 60 20 Effacer
- drawline @calc 2 2 169 111 321 111
- drawrect -f @calc 15 2 169 114 153 15
- drawrect @calc 2 2 169 114 153 15
- drawtext -oc @calc 2 Tahoma 10 228 115 60 20 Fermer
- }
-
- alias -l calc.move {
- if ($window(@calc)) window @calc $calc($mouse.dx - $1) $calc($mouse.dy - $2)
- if ($mouse.key & 1) .timer $+ $ticks -m 1 0 calc.move $1-
- }
-
- menu @calc {
- sclick {
- if ($mouse.y < 15) { calc.move $calc($mouse.dx - $window($active).x) $calc($mouse.dy - $window($active).y) }
- if $inrect($mouse.x,$mouse.y,314,3,11,11) { window -c @calc }
- if $inrect($mouse.x,$mouse.y,301,3,11,11) { window -n @calc }
- if ($inrect($mouse.x,$mouse.y,5,60,50,15)) { set %calc %calc $+ 9 | drawrect -f @calc 15 2 5 20 156 17 | drawrect @calc 2 2 5 20 156 17 | drawtext -oc @calc 2 Tahoma 10 10 22 150 20 $replace(%calc,*,x,/,÷) }
- if ($inrect($mouse.x,$mouse.y,58,60,50,15)) { set %calc %calc $+ 8 | drawrect -f @calc 15 2 5 20 156 17 | drawrect @calc 2 2 5 20 156 17 | drawtext -oc @calc 2 Tahoma 10 10 22 150 20 $replace(%calc,*,x,/,÷) }
- if ($inrect($mouse.x,$mouse.y,111,60,50,15)) { set %calc %calc $+ 7 | drawrect -f @calc 15 2 5 20 156 17 | drawrect @calc 2 2 5 20 156 17 | drawtext -oc @calc 2 Tahoma 10 10 22 150 20 $replace(%calc,*,x,/,÷) }
- if ($inrect($mouse.x,$mouse.y,5,78,50,15)) { set %calc %calc $+ 6 | drawrect -f @calc 15 2 5 20 156 17 | drawrect @calc 2 2 5 20 156 17 | drawtext -oc @calc 2 Tahoma 10 10 22 150 20 $replace(%calc,*,x,/,÷) }
- if ($inrect($mouse.x,$mouse.y,58,78,50,15)) { set %calc %calc $+ 5 | drawrect -f @calc 15 2 5 20 156 17 | drawrect @calc 2 2 5 20 156 17 | drawtext -oc @calc 2 Tahoma 10 10 22 150 20 $replace(%calc,*,x,/,÷) }
- if ($inrect($mouse.x,$mouse.y,111,78,50,15)) { set %calc %calc $+ 4 | drawrect -f @calc 15 2 5 20 156 17 | drawrect @calc 2 2 5 20 156 17 | drawtext -oc @calc 2 Tahoma 10 10 22 150 20 $replace(%calc,*,x,/,÷) }
- if ($inrect($mouse.x,$mouse.y,5,96,50,15)) { set %calc %calc $+ 3 | drawrect -f @calc 15 2 5 20 156 17 | drawrect @calc 2 2 5 20 156 17 | drawtext -oc @calc 2 Tahoma 10 10 22 150 20 $replace(%calc,*,x,/,÷) }
- if ($inrect($mouse.x,$mouse.y,58,96,50,15)) { set %calc %calc $+ 2 | drawrect -f @calc 15 2 5 20 156 17 | drawrect @calc 2 2 5 20 156 17 | drawtext -oc @calc 2 Tahoma 10 10 22 150 20 $replace(%calc,*,x,/,÷) }
- if ($inrect($mouse.x,$mouse.y,111,96,50,15)) { set %calc %calc $+ 1 | drawrect -f @calc 15 2 5 20 156 17 | drawrect @calc 2 2 5 20 156 17 | drawtext -oc @calc 2 Tahoma 10 10 22 150 20 $replace(%calc,*,x,/,÷) }
- if ($inrect($mouse.x,$mouse.y,5,114,50,15)) { set %calc %calc $+ 0 | drawrect -f @calc 15 2 5 20 156 17 | drawrect @calc 2 2 5 20 156 17 | drawtext -oc @calc 2 Tahoma 10 10 22 150 20 $replace(%calc,*,x,/,÷) }
- if ($inrect($mouse.x,$mouse.y,58,114,50,15)) { set %calc %calc $+ 00 | drawrect -f @calc 15 2 5 20 156 17 | drawrect @calc 2 2 5 20 156 17 | drawtext -oc @calc 2 Tahoma 10 10 22 150 20 $replace(%calc,*,x,/,÷) }
- if ($inrect($mouse.x,$mouse.y,111,114,50,15)) { set %calc %calc $+ . | drawrect -f @calc 15 2 5 20 156 17 | drawrect @calc 2 2 5 20 156 17 | drawtext -oc @calc 2 Tahoma 10 10 22 150 20 $replace(%calc,*,x,/,÷) }
- if ($inrect($mouse.x,$mouse.y,169,20,75,15)) { set %calc %calc $+ + | drawrect -f @calc 15 2 5 20 156 17 | drawrect @calc 2 2 5 20 156 17 | drawtext -oc @calc 2 Tahoma 10 10 22 150 20 $replace(%calc,*,x,/,÷) }
- if ($inrect($mouse.x,$mouse.y,247,20,75,15)) { set %calc %calc $+ - | drawrect -f @calc 15 2 5 20 156 17 | drawrect @calc 2 2 5 20 156 17 | drawtext -oc @calc 2 Tahoma 10 10 22 150 20 $replace(%calc,*,x,/,÷) }
- if ($inrect($mouse.x,$mouse.y,169,38,75,15)) { set %calc %calc $+ * | drawrect -f @calc 15 2 5 20 156 17 | drawrect @calc 2 2 5 20 156 17 | drawtext -oc @calc 2 Tahoma 10 10 22 150 20 $replace(%calc,*,x,/,÷) }
- if ($inrect($mouse.x,$mouse.y,247,38,75,15)) { set %calc %calc $+ / | drawrect -f @calc 15 2 5 20 156 17 | drawrect @calc 2 2 5 20 156 17 | drawtext -oc @calc 2 Tahoma 10 10 22 150 20 $replace(%calc,*,x,/,÷) }
- if ($inrect($mouse.x,$mouse.y,169,56,36,15)) { set %calc %calc $+ ( | drawrect -f @calc 15 2 5 20 156 17 | drawrect @calc 2 2 5 20 156 17 | drawtext -oc @calc 2 Tahoma 10 10 22 150 20 $replace(%calc,*,x,/,÷) }
- if ($inrect($mouse.x,$mouse.y,208,56,36,15)) { set %calc %calc $+ ) | drawrect -f @calc 15 2 5 20 156 17 | drawrect @calc 2 2 5 20 156 17 | drawtext -oc @calc 2 Tahoma 10 10 22 150 20 $replace(%calc,*,x,/,÷) }
- if ($inrect($mouse.x,$mouse.y,247,56,75,15)) { set %calc %calc $+ *10/100 | drawrect -f @calc 15 2 5 20 156 17 | drawrect @calc 2 2 5 20 156 17 | drawtext -oc @calc 2 Tahoma 10 10 22 150 20 $replace(%calc,*,x,/,÷) }
- if ($inrect($mouse.x,$mouse.y,169,74,75,15)) { set %calc2 %calc | set %calc2 $sqrt(%calc2) | drawrect -f @calc 15 2 5 20 156 17 | drawrect @calc 2 2 5 20 156 17 | drawtext -oc @calc 2 Tahoma 10 10 22 150 20 %calc | drawrect -f @calc 15 2 5 40 156 17 | drawrect @calc 2 2 5 40 156 17 | drawtext -oc @calc 2 Tahoma 10 10 42 60 20 %calc2 }
- if ($inrect($mouse.x,$mouse.y,169,92,76,15)) { set %calc2 %calc | set %calc2 $calc(%calc2) | drawrect -f @calc 15 2 5 40 156 17 | drawrect @calc 2 2 5 40 156 17 | drawtext -oc @calc 2 Tahoma 10 10 42 60 20 %calc2 }
- if ($inrect($mouse.x,$mouse.y,247,92,76,15)) { drawrect -f @calc 15 2 5 20 156 17 | drawrect @calc 2 2 5 20 156 17 | drawrect -f @calc 15 2 5 40 156 17 | drawrect @calc 2 2 5 40 156 17 | unset %calc | unset %calc2 }
- if ($inrect($mouse.x,$mouse.y,169,114,153,15)) { window -c @calc }
- }
- mouse {
- if $inrect($mouse.x,$mouse.y,301,3,11,11) { drawdot -f @calc 0 4 308 10 | drawrect @calc 0 1 301 3 11 11 }
- else { drawrect -f @calc 3 2 301 3 11 11 | drawrect @calc 0 1 301 3 11 11 }
- if $inrect($mouse.x,$mouse.y,314,3,11,11) { drawdot -f @calc 0 4 321 10 | drawrect @calc 0 1 314 3 11 11 }
- else { drawrect -f @calc 4 2 314 3 11 11 | drawrect @calc 0 1 314 3 11 11 }
- if ($inrect($mouse.x,$mouse.y,5,60,50,15)) { drawtext -oc @calc 14 Tahoma 10 27 61 60 20 9 }
- else { drawtext -oc @calc 2 Tahoma 10 27 61 60 20 9 }
- if ($inrect($mouse.x,$mouse.y,58,60,50,15)) { drawtext -oc @calc 14 Tahoma 10 80 61 60 20 8 }
- else { drawtext -oc @calc 2 Tahoma 10 80 61 60 20 8 }
- if ($inrect($mouse.x,$mouse.y,111,60,50,15)) { drawtext -oc @calc 14 Tahoma 10 133 61 60 20 7 }
- else { drawtext -oc @calc 2 Tahoma 10 133 61 60 20 7 }
- if ($inrect($mouse.x,$mouse.y,5,78,50,15)) { drawtext -oc @calc 14 Tahoma 10 27 79 60 20 6 }
- else { drawtext -oc @calc 2 Tahoma 10 27 79 60 20 6 }
- if ($inrect($mouse.x,$mouse.y,58,78,50,15)) { drawtext -oc @calc 14 Tahoma 10 80 79 60 20 5 }
- else { drawtext -oc @calc 2 Tahoma 10 80 79 60 20 5 }
- if ($inrect($mouse.x,$mouse.y,111,78,50,15)) { drawtext -oc @calc 14 Tahoma 10 133 79 60 20 4 }
- else { drawtext -oc @calc 2 Tahoma 10 133 79 60 20 4 }
- if ($inrect($mouse.x,$mouse.y,5,96,50,15)) { drawtext -oc @calc 14 Tahoma 10 27 97 60 20 3 }
- else { drawtext -oc @calc 2 Tahoma 10 27 97 60 20 3 }
- if ($inrect($mouse.x,$mouse.y,58,96,50,15)) { drawtext -oc @calc 14 Tahoma 10 80 97 60 20 2 }
- else { drawtext -oc @calc 2 Tahoma 10 80 97 60 20 2 }
- if ($inrect($mouse.x,$mouse.y,111,96,50,15)) { drawtext -oc @calc 14 Tahoma 10 133 97 60 20 1 }
- else { drawtext -oc @calc 2 Tahoma 10 133 97 60 20 1 }
- if ($inrect($mouse.x,$mouse.y,5,114,50,15)) { drawtext -oc @calc 14 Tahoma 10 27 115 60 20 0 }
- else { drawtext -oc @calc 2 Tahoma 10 27 115 60 20 0 }
- if ($inrect($mouse.x,$mouse.y,58,114,50,15)) { drawtext -oc @calc 14 Tahoma 10 77 115 60 20 00 }
- else { drawtext -oc @calc 2 Tahoma 10 77 115 60 20 00 }
- if ($inrect($mouse.x,$mouse.y,111,114,50,15)) { drawtext -oc @calc 14 Tahoma 10 135 112 60 20 , }
- else { drawtext -oc @calc 2 Tahoma 10 135 112 60 20 , }
- if ($inrect($mouse.x,$mouse.y,169,20,75,15)) { drawtext -oc @calc 14 Tahoma 10 203 21 60 20 + }
- else { drawtext -oc @calc 2 Tahoma 10 203 21 60 20 + }
- if ($inrect($mouse.x,$mouse.y,247,20,75,15)) { drawtext -oc @calc 14 Tahoma 10 282 21 60 20 - }
- else { drawtext -oc @calc 2 Tahoma 10 282 21 60 20 - }
- if ($inrect($mouse.x,$mouse.y,169,38,75,15)) { drawtext -oc @calc 14 Tahoma 10 204 39 60 20 x }
- else { drawtext -oc @calc 2 Tahoma 10 204 39 60 20 x }
- if ($inrect($mouse.x,$mouse.y,247,38,75,15)) { drawtext -oc @calc 14 Tahoma 10 280 39 60 20 ÷ }
- else { drawtext -oc @calc 2 Tahoma 10 280 39 60 20 ÷ }
- if ($inrect($mouse.x,$mouse.y,169,56,36,15)) { drawtext -oc @calc 14 Tahoma 9 185 58 60 20 ( }
- else { drawtext -oc @calc 2 Tahoma 9 185 58 60 20 ( }
- if ($inrect($mouse.x,$mouse.y,208,56,36,15)) { drawtext -oc @calc 14 Tahoma 9 224 58 60 20 ) }
- else { drawtext -oc @calc 2 Tahoma 9 224 58 60 20 ) }
- if ($inrect($mouse.x,$mouse.y,247,56,75,15)) { drawtext -oc @calc 14 Tahoma 10 280 57 60 20 % }
- else { drawtext -oc @calc 2 Tahoma 10 280 57 60 20 % }
- if ($inrect($mouse.x,$mouse.y,169,74,75,15)) { drawtext -oc @calc 14 Tahoma 10 185 75 60 20 Au carré }
- else { drawtext -oc @calc 2 Tahoma 10 185 75 60 20 Au carré }
- if ($inrect($mouse.x,$mouse.y,247,74,76,15)) { drawtext -oc @calc 14 Tahoma 10 280 75 60 20 Pi }
- else { drawtext -oc @calc 2 Tahoma 10 280 75 60 20 Pi }
- if ($inrect($mouse.x,$mouse.y,169,92,76,15)) { drawtext -oc @calc 14 Tahoma 10 202 93 60 20 = }
- else { drawtext -oc @calc 2 Tahoma 10 202 93 60 20 = }
- if ($inrect($mouse.x,$mouse.y,247,92,76,15)) { drawtext -oc @calc 14 Tahoma 10 267 93 60 20 Effacer }
- else { drawtext -oc @calc 2 Tahoma 10 267 93 60 20 Effacer }
- if ($inrect($mouse.x,$mouse.y,169,114,153,15)) { drawtext -oc @calc 14 Tahoma 10 228 115 60 20 Fermer }
- else { drawtext -oc @calc 2 Tahoma 10 228 115 60 20 Fermer }
- }
- Fermer la fenêtre:window -c @calc
- Minimiser la fenêtre:window -n @calc
- }
alias calc {
unset %calc
unset %calc2
window -BCdg0k0pRz +dl @Calc 0 0 327 134
drawfill -r @calc $rgb(218,240,252) 1 10 10
drawrect -f @calc 2 2 0 0 327 15
drawtext -roc @calc $rgb(250,250,250) Tahoma 10 5 3 200 20 Calculatrice par atlantisfr
drawrect @calc 2 2 0 15 327 119
drawrect @calc 2 2 0 15 337 129
drawrect -f @calc 4 2 314 3 11 11
drawrect @calc 0 1 314 3 11 11
drawrect -f @calc 3 2 301 3 11 11
drawrect @calc 0 1 301 3 11 11
drawrect -f @calc 15 2 5 20 156 17
drawrect @calc 2 2 5 20 156 17
drawrect -f @calc 15 2 5 40 156 17
drawrect @calc 2 2 5 40 156 17
drawrect -f @calc 15 2 5 60 50 15
drawrect @calc 2 2 5 60 50 15
drawtext -oc @calc 2 Tahoma 10 27 61 60 20 9
drawrect -f @calc 15 2 58 60 50 15
drawrect @calc 2 2 58 60 50 15
drawtext -oc @calc 2 Tahoma 10 80 61 60 20 8
drawrect -f @calc 15 2 111 60 50 15
drawrect @calc 2 2 111 60 50 15
drawtext -oc @calc 2 Tahoma 10 133 61 60 20 7
drawrect -f @calc 15 2 5 78 50 15
drawrect @calc 2 2 5 78 50 15
drawtext -oc @calc 2 Tahoma 10 27 79 60 20 6
drawrect -f @calc 15 2 58 78 50 15
drawrect @calc 2 2 58 78 50 15
drawtext -oc @calc 2 Tahoma 10 80 79 60 20 5
drawrect -f @calc 15 2 111 78 50 15
drawrect @calc 2 2 111 78 50 15
drawtext -oc @calc 2 Tahoma 10 133 79 60 20 4
drawrect -f @calc 15 2 5 96 50 15
drawrect @calc 2 2 5 96 50 15
drawtext -oc @calc 2 Tahoma 10 27 97 60 20 3
drawrect -f @calc 15 2 58 96 50 15
drawrect @calc 2 2 58 96 50 15
drawtext -oc @calc 2 Tahoma 10 80 97 60 20 2
drawrect -f @calc 15 2 111 96 50 15
drawrect @calc 2 2 111 96 50 15
drawtext -oc @calc 2 Tahoma 10 133 97 60 20 1
drawrect -f @calc 15 2 5 114 50 15
drawrect @calc 2 2 5 114 50 15
drawtext -oc @calc 2 Tahoma 10 27 115 60 20 0
drawrect -f @calc 15 2 58 114 50 15
drawrect @calc 2 2 58 114 50 15
drawtext -oc @calc 2 Tahoma 10 77 115 60 20 00
drawrect -f @calc 15 2 111 114 50 15
drawrect @calc 2 2 111 114 50 15
drawtext -oc @calc 2 Tahoma 10 135 112 60 20 ,
drawline @calc 2 2 165 20 165 128
drawrect -f @calc 15 2 169 20 75 15
drawrect @calc 2 2 169 20 75 15
drawtext -oc @calc 2 Tahoma 10 203 21 60 20 +
drawrect -f @calc 15 2 247 20 75 15
drawrect @calc 2 2 247 20 75 15
drawtext -oc @calc 2 Tahoma 10 282 21 60 20 -
drawrect -f @calc 15 2 169 38 75 15
drawrect @calc 2 2 169 38 75 15
drawtext -oc @calc 2 Tahoma 10 204 39 60 20 x
drawrect -f @calc 15 2 247 38 75 15
drawrect @calc 2 2 247 38 75 15
drawtext -oc @calc 2 Tahoma 10 280 39 60 20 ÷
drawrect -f @calc 15 2 169 56 36 15
drawrect @calc 2 2 169 56 36 15
drawtext -oc @calc 2 Tahoma 9 185 58 60 20 (
drawrect -f @calc 15 2 208 56 36 15
drawrect @calc 2 2 208 56 36 15
drawtext -oc @calc 2 Tahoma 9 224 58 60 20 )
drawrect -f @calc 15 2 247 56 75 15
drawrect @calc 2 2 247 56 75 15
drawtext -oc @calc 2 Tahoma 10 280 57 60 20 %
drawrect -f @calc 15 2 169 74 75 15
drawrect @calc 2 2 169 74 75 15
drawtext -oc @calc 2 Tahoma 10 185 75 60 20 Au carré
drawrect -f @calc 15 2 247 74 76 15
drawrect @calc 2 2 247 74 75 15
drawtext -oc @calc 2 Tahoma 10 280 75 60 20 Pi
drawrect -f @calc 15 2 169 92 76 15
drawrect @calc 2 2 169 92 76 15
drawtext -oc @calc 2 Tahoma 10 202 93 60 20 =
drawrect -f @calc 15 2 247 92 76 15
drawrect @calc 2 2 247 92 75 15
drawtext -oc @calc 2 Tahoma 10 267 93 60 20 Effacer
drawline @calc 2 2 169 111 321 111
drawrect -f @calc 15 2 169 114 153 15
drawrect @calc 2 2 169 114 153 15
drawtext -oc @calc 2 Tahoma 10 228 115 60 20 Fermer
}
alias -l calc.move {
if ($window(@calc)) window @calc $calc($mouse.dx - $1) $calc($mouse.dy - $2)
if ($mouse.key & 1) .timer $+ $ticks -m 1 0 calc.move $1-
}
menu @calc {
sclick {
if ($mouse.y < 15) { calc.move $calc($mouse.dx - $window($active).x) $calc($mouse.dy - $window($active).y) }
if $inrect($mouse.x,$mouse.y,314,3,11,11) { window -c @calc }
if $inrect($mouse.x,$mouse.y,301,3,11,11) { window -n @calc }
if ($inrect($mouse.x,$mouse.y,5,60,50,15)) { set %calc %calc $+ 9 | drawrect -f @calc 15 2 5 20 156 17 | drawrect @calc 2 2 5 20 156 17 | drawtext -oc @calc 2 Tahoma 10 10 22 150 20 $replace(%calc,*,x,/,÷) }
if ($inrect($mouse.x,$mouse.y,58,60,50,15)) { set %calc %calc $+ 8 | drawrect -f @calc 15 2 5 20 156 17 | drawrect @calc 2 2 5 20 156 17 | drawtext -oc @calc 2 Tahoma 10 10 22 150 20 $replace(%calc,*,x,/,÷) }
if ($inrect($mouse.x,$mouse.y,111,60,50,15)) { set %calc %calc $+ 7 | drawrect -f @calc 15 2 5 20 156 17 | drawrect @calc 2 2 5 20 156 17 | drawtext -oc @calc 2 Tahoma 10 10 22 150 20 $replace(%calc,*,x,/,÷) }
if ($inrect($mouse.x,$mouse.y,5,78,50,15)) { set %calc %calc $+ 6 | drawrect -f @calc 15 2 5 20 156 17 | drawrect @calc 2 2 5 20 156 17 | drawtext -oc @calc 2 Tahoma 10 10 22 150 20 $replace(%calc,*,x,/,÷) }
if ($inrect($mouse.x,$mouse.y,58,78,50,15)) { set %calc %calc $+ 5 | drawrect -f @calc 15 2 5 20 156 17 | drawrect @calc 2 2 5 20 156 17 | drawtext -oc @calc 2 Tahoma 10 10 22 150 20 $replace(%calc,*,x,/,÷) }
if ($inrect($mouse.x,$mouse.y,111,78,50,15)) { set %calc %calc $+ 4 | drawrect -f @calc 15 2 5 20 156 17 | drawrect @calc 2 2 5 20 156 17 | drawtext -oc @calc 2 Tahoma 10 10 22 150 20 $replace(%calc,*,x,/,÷) }
if ($inrect($mouse.x,$mouse.y,5,96,50,15)) { set %calc %calc $+ 3 | drawrect -f @calc 15 2 5 20 156 17 | drawrect @calc 2 2 5 20 156 17 | drawtext -oc @calc 2 Tahoma 10 10 22 150 20 $replace(%calc,*,x,/,÷) }
if ($inrect($mouse.x,$mouse.y,58,96,50,15)) { set %calc %calc $+ 2 | drawrect -f @calc 15 2 5 20 156 17 | drawrect @calc 2 2 5 20 156 17 | drawtext -oc @calc 2 Tahoma 10 10 22 150 20 $replace(%calc,*,x,/,÷) }
if ($inrect($mouse.x,$mouse.y,111,96,50,15)) { set %calc %calc $+ 1 | drawrect -f @calc 15 2 5 20 156 17 | drawrect @calc 2 2 5 20 156 17 | drawtext -oc @calc 2 Tahoma 10 10 22 150 20 $replace(%calc,*,x,/,÷) }
if ($inrect($mouse.x,$mouse.y,5,114,50,15)) { set %calc %calc $+ 0 | drawrect -f @calc 15 2 5 20 156 17 | drawrect @calc 2 2 5 20 156 17 | drawtext -oc @calc 2 Tahoma 10 10 22 150 20 $replace(%calc,*,x,/,÷) }
if ($inrect($mouse.x,$mouse.y,58,114,50,15)) { set %calc %calc $+ 00 | drawrect -f @calc 15 2 5 20 156 17 | drawrect @calc 2 2 5 20 156 17 | drawtext -oc @calc 2 Tahoma 10 10 22 150 20 $replace(%calc,*,x,/,÷) }
if ($inrect($mouse.x,$mouse.y,111,114,50,15)) { set %calc %calc $+ . | drawrect -f @calc 15 2 5 20 156 17 | drawrect @calc 2 2 5 20 156 17 | drawtext -oc @calc 2 Tahoma 10 10 22 150 20 $replace(%calc,*,x,/,÷) }
if ($inrect($mouse.x,$mouse.y,169,20,75,15)) { set %calc %calc $+ + | drawrect -f @calc 15 2 5 20 156 17 | drawrect @calc 2 2 5 20 156 17 | drawtext -oc @calc 2 Tahoma 10 10 22 150 20 $replace(%calc,*,x,/,÷) }
if ($inrect($mouse.x,$mouse.y,247,20,75,15)) { set %calc %calc $+ - | drawrect -f @calc 15 2 5 20 156 17 | drawrect @calc 2 2 5 20 156 17 | drawtext -oc @calc 2 Tahoma 10 10 22 150 20 $replace(%calc,*,x,/,÷) }
if ($inrect($mouse.x,$mouse.y,169,38,75,15)) { set %calc %calc $+ * | drawrect -f @calc 15 2 5 20 156 17 | drawrect @calc 2 2 5 20 156 17 | drawtext -oc @calc 2 Tahoma 10 10 22 150 20 $replace(%calc,*,x,/,÷) }
if ($inrect($mouse.x,$mouse.y,247,38,75,15)) { set %calc %calc $+ / | drawrect -f @calc 15 2 5 20 156 17 | drawrect @calc 2 2 5 20 156 17 | drawtext -oc @calc 2 Tahoma 10 10 22 150 20 $replace(%calc,*,x,/,÷) }
if ($inrect($mouse.x,$mouse.y,169,56,36,15)) { set %calc %calc $+ ( | drawrect -f @calc 15 2 5 20 156 17 | drawrect @calc 2 2 5 20 156 17 | drawtext -oc @calc 2 Tahoma 10 10 22 150 20 $replace(%calc,*,x,/,÷) }
if ($inrect($mouse.x,$mouse.y,208,56,36,15)) { set %calc %calc $+ ) | drawrect -f @calc 15 2 5 20 156 17 | drawrect @calc 2 2 5 20 156 17 | drawtext -oc @calc 2 Tahoma 10 10 22 150 20 $replace(%calc,*,x,/,÷) }
if ($inrect($mouse.x,$mouse.y,247,56,75,15)) { set %calc %calc $+ *10/100 | drawrect -f @calc 15 2 5 20 156 17 | drawrect @calc 2 2 5 20 156 17 | drawtext -oc @calc 2 Tahoma 10 10 22 150 20 $replace(%calc,*,x,/,÷) }
if ($inrect($mouse.x,$mouse.y,169,74,75,15)) { set %calc2 %calc | set %calc2 $sqrt(%calc2) | drawrect -f @calc 15 2 5 20 156 17 | drawrect @calc 2 2 5 20 156 17 | drawtext -oc @calc 2 Tahoma 10 10 22 150 20 %calc | drawrect -f @calc 15 2 5 40 156 17 | drawrect @calc 2 2 5 40 156 17 | drawtext -oc @calc 2 Tahoma 10 10 42 60 20 %calc2 }
if ($inrect($mouse.x,$mouse.y,169,92,76,15)) { set %calc2 %calc | set %calc2 $calc(%calc2) | drawrect -f @calc 15 2 5 40 156 17 | drawrect @calc 2 2 5 40 156 17 | drawtext -oc @calc 2 Tahoma 10 10 42 60 20 %calc2 }
if ($inrect($mouse.x,$mouse.y,247,92,76,15)) { drawrect -f @calc 15 2 5 20 156 17 | drawrect @calc 2 2 5 20 156 17 | drawrect -f @calc 15 2 5 40 156 17 | drawrect @calc 2 2 5 40 156 17 | unset %calc | unset %calc2 }
if ($inrect($mouse.x,$mouse.y,169,114,153,15)) { window -c @calc }
}
mouse {
if $inrect($mouse.x,$mouse.y,301,3,11,11) { drawdot -f @calc 0 4 308 10 | drawrect @calc 0 1 301 3 11 11 }
else { drawrect -f @calc 3 2 301 3 11 11 | drawrect @calc 0 1 301 3 11 11 }
if $inrect($mouse.x,$mouse.y,314,3,11,11) { drawdot -f @calc 0 4 321 10 | drawrect @calc 0 1 314 3 11 11 }
else { drawrect -f @calc 4 2 314 3 11 11 | drawrect @calc 0 1 314 3 11 11 }
if ($inrect($mouse.x,$mouse.y,5,60,50,15)) { drawtext -oc @calc 14 Tahoma 10 27 61 60 20 9 }
else { drawtext -oc @calc 2 Tahoma 10 27 61 60 20 9 }
if ($inrect($mouse.x,$mouse.y,58,60,50,15)) { drawtext -oc @calc 14 Tahoma 10 80 61 60 20 8 }
else { drawtext -oc @calc 2 Tahoma 10 80 61 60 20 8 }
if ($inrect($mouse.x,$mouse.y,111,60,50,15)) { drawtext -oc @calc 14 Tahoma 10 133 61 60 20 7 }
else { drawtext -oc @calc 2 Tahoma 10 133 61 60 20 7 }
if ($inrect($mouse.x,$mouse.y,5,78,50,15)) { drawtext -oc @calc 14 Tahoma 10 27 79 60 20 6 }
else { drawtext -oc @calc 2 Tahoma 10 27 79 60 20 6 }
if ($inrect($mouse.x,$mouse.y,58,78,50,15)) { drawtext -oc @calc 14 Tahoma 10 80 79 60 20 5 }
else { drawtext -oc @calc 2 Tahoma 10 80 79 60 20 5 }
if ($inrect($mouse.x,$mouse.y,111,78,50,15)) { drawtext -oc @calc 14 Tahoma 10 133 79 60 20 4 }
else { drawtext -oc @calc 2 Tahoma 10 133 79 60 20 4 }
if ($inrect($mouse.x,$mouse.y,5,96,50,15)) { drawtext -oc @calc 14 Tahoma 10 27 97 60 20 3 }
else { drawtext -oc @calc 2 Tahoma 10 27 97 60 20 3 }
if ($inrect($mouse.x,$mouse.y,58,96,50,15)) { drawtext -oc @calc 14 Tahoma 10 80 97 60 20 2 }
else { drawtext -oc @calc 2 Tahoma 10 80 97 60 20 2 }
if ($inrect($mouse.x,$mouse.y,111,96,50,15)) { drawtext -oc @calc 14 Tahoma 10 133 97 60 20 1 }
else { drawtext -oc @calc 2 Tahoma 10 133 97 60 20 1 }
if ($inrect($mouse.x,$mouse.y,5,114,50,15)) { drawtext -oc @calc 14 Tahoma 10 27 115 60 20 0 }
else { drawtext -oc @calc 2 Tahoma 10 27 115 60 20 0 }
if ($inrect($mouse.x,$mouse.y,58,114,50,15)) { drawtext -oc @calc 14 Tahoma 10 77 115 60 20 00 }
else { drawtext -oc @calc 2 Tahoma 10 77 115 60 20 00 }
if ($inrect($mouse.x,$mouse.y,111,114,50,15)) { drawtext -oc @calc 14 Tahoma 10 135 112 60 20 , }
else { drawtext -oc @calc 2 Tahoma 10 135 112 60 20 , }
if ($inrect($mouse.x,$mouse.y,169,20,75,15)) { drawtext -oc @calc 14 Tahoma 10 203 21 60 20 + }
else { drawtext -oc @calc 2 Tahoma 10 203 21 60 20 + }
if ($inrect($mouse.x,$mouse.y,247,20,75,15)) { drawtext -oc @calc 14 Tahoma 10 282 21 60 20 - }
else { drawtext -oc @calc 2 Tahoma 10 282 21 60 20 - }
if ($inrect($mouse.x,$mouse.y,169,38,75,15)) { drawtext -oc @calc 14 Tahoma 10 204 39 60 20 x }
else { drawtext -oc @calc 2 Tahoma 10 204 39 60 20 x }
if ($inrect($mouse.x,$mouse.y,247,38,75,15)) { drawtext -oc @calc 14 Tahoma 10 280 39 60 20 ÷ }
else { drawtext -oc @calc 2 Tahoma 10 280 39 60 20 ÷ }
if ($inrect($mouse.x,$mouse.y,169,56,36,15)) { drawtext -oc @calc 14 Tahoma 9 185 58 60 20 ( }
else { drawtext -oc @calc 2 Tahoma 9 185 58 60 20 ( }
if ($inrect($mouse.x,$mouse.y,208,56,36,15)) { drawtext -oc @calc 14 Tahoma 9 224 58 60 20 ) }
else { drawtext -oc @calc 2 Tahoma 9 224 58 60 20 ) }
if ($inrect($mouse.x,$mouse.y,247,56,75,15)) { drawtext -oc @calc 14 Tahoma 10 280 57 60 20 % }
else { drawtext -oc @calc 2 Tahoma 10 280 57 60 20 % }
if ($inrect($mouse.x,$mouse.y,169,74,75,15)) { drawtext -oc @calc 14 Tahoma 10 185 75 60 20 Au carré }
else { drawtext -oc @calc 2 Tahoma 10 185 75 60 20 Au carré }
if ($inrect($mouse.x,$mouse.y,247,74,76,15)) { drawtext -oc @calc 14 Tahoma 10 280 75 60 20 Pi }
else { drawtext -oc @calc 2 Tahoma 10 280 75 60 20 Pi }
if ($inrect($mouse.x,$mouse.y,169,92,76,15)) { drawtext -oc @calc 14 Tahoma 10 202 93 60 20 = }
else { drawtext -oc @calc 2 Tahoma 10 202 93 60 20 = }
if ($inrect($mouse.x,$mouse.y,247,92,76,15)) { drawtext -oc @calc 14 Tahoma 10 267 93 60 20 Effacer }
else { drawtext -oc @calc 2 Tahoma 10 267 93 60 20 Effacer }
if ($inrect($mouse.x,$mouse.y,169,114,153,15)) { drawtext -oc @calc 14 Tahoma 10 228 115 60 20 Fermer }
else { drawtext -oc @calc 2 Tahoma 10 228 115 60 20 Fermer }
}
Fermer la fenêtre:window -c @calc
Minimiser la fenêtre:window -n @calc
}
Historique
- 23 août 2006 01:03:38 :
- Correction du bug de la touche "Au carré"
Sources du même auteur
Sources de la même categorie
Sources en rapport avec celle ci
Commentaires et avis
Discussions en rapport avec ce code source dans le forum
Aide: Picwin et Calculatrice [ par Mc_AbBeR ]
Bonjour,Je cherche comment faire une zone de texte (disable) en picwin, et un bouton. Puis comment calculer (calculatrice).Merci d'Avance
Combo picwin ? [ par Lestat_2070 ]
Bonjour à tous, Voilà j'ai enfin décidé de me lancer dans les picwins , j'ai d'ailleurs lut attentivement les deux tutos de Kinder
Aider Moi!!!! [ par Bencall ]
Bonjour, Je programme normalement en vb, mais mon probleme est que la seule formule que j'ai trouvé pour mon prog ce trouve en IRC: >if ($prop == len
Variable Long -> int [ par S333 ]
Voilà, c'est à mon tour de poser une question ^^ Alors, je suis en train de refaire, et améliorer HLirc, mais je suis devant un probl&#
Aide: PicWin !!! (mouse.x mouse.y) [ par Mc_AbBeR ]
Voila mon code:alias -l apw.text drawtext @A-PICWIN 1 Tahoma 11 $1-alias -l apw.rect drawrect @A-PICWIN $1-alias apicwin { window -adpBCf +d @A-
PicWin: List et Réduction [ par Mc_AbBeR ]
Bon, je suis en train de faire une petite source en picwin mais j'ai besoin d'une list (comme en dialog). J'ai fait un rectangle mais euh a
PicWin: list en picwin [ par Mc_AbBeR ]
Bon j'voudrais bien faire une liste en picwin (comme sur un dialog) avec les scroll pis tout...
PicWin: supprimer un drawdot [ par Mc_AbBeR ]
Bon j'ai réussi a faire ma list, mais ya juste un petit problème: comment fait-on pour supprimer le drawdot?Quand je fait le mouse ya 100000
Pour ceux qui aiment écouter la musique en tchattant [ par Bestdoud ]
Cela fait quelque temps que je réalise un lecteur mp3 en picwin. venez le découvrir à l'adresse suivante: http://amigagaamp.free.fr voici ces caract
PicWin Multi-Fonctions : Un p'tit coup de pub [ par RCA ArKanis ]
J'osais pas créer une nouvelle source pour ça, étant donné que le remote pour lequel je pubbe a déjà été envoy
|
Téléchargements
Logiciels à télécharger sur le même thème :
|