Subversion Repositories wimsdev

Rev

Rev 18609 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 18609 Rev 18612
Line 621... Line 621...
621
 if( dx == 0 || dy == 0 ){alert(\"increment is zero !!! \");return;};\
621
 if( dx == 0 || dy == 0 ){alert(\"increment is zero !!! \");return;};\
622
 var fc = %d+canvas_type;\
622
 var fc = %d+canvas_type;\
623
 var obj = create_canvas%d(fc,xsize,ysize);\
623
 var obj = create_canvas%d(fc,xsize,ysize);\
624
 var ctx = obj.getContext('2d');\
624
 var ctx = obj.getContext('2d');\
625
 var x,y;\
625
 var x,y;\
626
 ctx.fillStyle='rgba(255,255,255,0.002)';\
626
 ctx.fillStyle='rgba(255,255,255,0.01)';\
627
 ctx.rect(0,0,xsize,ysize);\
627
 ctx.rect(0,0,xsize,ysize);\
628
 ctx.fill();\
628
 ctx.fill();\
629
 ctx.lineWidth = linewidth;\
629
 ctx.lineWidth = linewidth;\
630
 ctx.strokeStyle=\"rgba(\"+color+\",0.002)\";\
630
 ctx.strokeStyle=\"rgba(\"+color+\",0.01)\";\
631
 for( x = 0 ; x <= xsize ; x = x + dx ){\
631
 for( x = 0 ; x <= xsize ; x = x + dx ){\
632
  ctx.beginPath();\
632
  ctx.beginPath();\
633
  ctx.moveTo(x,0);\
633
  ctx.moveTo(x,0);\
634
  ctx.lineTo(x,ysize);\
634
  ctx.lineTo(x,ysize);\
635
  ctx.closePath();\
635
  ctx.closePath();\
Line 683... Line 683...
683
if( dx == 0 || dy == 0 ){alert(\"increment is zero !!! \");return;};\
683
if( dx == 0 || dy == 0 ){alert(\"increment is zero !!! \");return;};\
684
var fc = %d+canvas_type;\
684
var fc = %d+canvas_type;\
685
 var obj = create_canvas%d(fc,xsize,ysize);\
685
 var obj = create_canvas%d(fc,xsize,ysize);\
686
 var ctx = obj.getContext('2d');\
686
 var ctx = obj.getContext('2d');\
687
 var x,y;\
687
 var x,y;\
688
 ctx.fillStyle='rgba(255,255,255,0.002)';\
688
 ctx.fillStyle='rgba(255,255,255,0.01)';\
689
 ctx.rect(0,0,xsize,ysize);\
689
 ctx.rect(0,0,xsize,ysize);\
690
 ctx.fill();\
690
 ctx.fill();\
691
 ctx.fillStyle=\"rgba(\"+color+\",0.002)\";\
691
 ctx.fillStyle=\"rgba(\"+color+\",0.01)\";\
692
 ctx.strokeStyle=\"rgba(\"+color+\",0.002)\";\
692
 ctx.strokeStyle=\"rgba(\"+color+\",0.01)\";\
693
 for( x = 0 ; x < xsize ; x = x + dx ){\
693
 for( x = 0 ; x < xsize ; x = x + dx ){\
694
  for( y = 0 ; y < ysize ; y = y + dy ){\
694
  for( y = 0 ; y < ysize ; y = y + dy ){\
695
   ctx.beginPath();\
695
   ctx.beginPath();\
696
   ctx.arc(x,y,radius,0,2*Math.PI,false);\
696
   ctx.arc(x,y,radius,0,2*Math.PI,false);\
697
   ctx.closePath();\
697
   ctx.closePath();\
Line 762... Line 762...
762
var obj = create_canvas%d(fc,xsize,ysize);\
762
var obj = create_canvas%d(fc,xsize,ysize);\
763
var ctx = obj.getContext('2d');\
763
var ctx = obj.getContext('2d');\
764
ctx.font = fontfamily;\
764
ctx.font = fontfamily;\
765
var dx = 2+(ctx.measureText(txt)).width;\
765
var dx = 2+(ctx.measureText(txt)).width;\
766
var dy = 2+(ctx.measureText('MI')).width;\
766
var dy = 2+(ctx.measureText('MI')).width;\
767
ctx.fillStyle='rgba(255,255,255,0.002)';\
767
ctx.fillStyle='rgba(255,255,255,0.01)';\
768
ctx.rect(0,0,xsize,ysize);\
768
ctx.rect(0,0,xsize,ysize);\
769
ctx.fill();\
769
ctx.fill();\
770
ctx.fillStyle=\"rgba(\"+color+\",0.002)\";\
770
ctx.fillStyle=\"rgba(\"+color+\",0.01)\";\
771
ctx.strokeStyle=\"rgba(\"+color+\",0.002)\";\
771
ctx.strokeStyle=\"rgba(\"+color+\",0.01)\";\
772
for(var x = 0 ; x <= xsize ; x = x + dx ){\
772
for(var x = 0 ; x <= xsize ; x = x + dx ){\
773
 for(var y = 0 ; y <= ysize ; y = y + dy ){\
773
 for(var y = 0 ; y <= ysize ; y = y + dy ){\
774
  ctx.fillText(txt, x, y);\
774
  ctx.fillText(txt, x, y);\
775
 };\
775
 };\
776
};\
776
};\
Line 793... Line 793...
793
let i,m = (nx > ny) ? nx : ny;\
793
let i,m = (nx > ny) ? nx : ny;\
794
var fc = %d+canvas_type;\
794
var fc = %d+canvas_type;\
795
var obj = create_canvas%d(fc,xsize,ysize);\
795
var obj = create_canvas%d(fc,xsize,ysize);\
796
var ctx = obj.getContext('2d');\
796
var ctx = obj.getContext('2d');\
797
ctx.lineWidth = linewidth;\
797
ctx.lineWidth = linewidth;\
798
ctx.fillStyle='rgba(255,255,255,0.002)';\
798
ctx.fillStyle='rgba(255,255,255,0.01)';\
799
ctx.rect(0,0,xsize,ysize);\
799
ctx.rect(0,0,xsize,ysize);\
800
ctx.fill();\
800
ctx.fill();\
801
ctx.strokeStyle=\"rgba(\"+color+\",0.002)\";\
801
ctx.strokeStyle=\"rgba(\"+color+\",0.01)\";\
802
ctx.beginPath();\
802
ctx.beginPath();\
803
  for(i = -2*m ; i<=m ; ++i){\
803
  for(i = -2*m ; i<=m ; ++i){\
804
    ctx.moveTo(0,i*dy);\
804
    ctx.moveTo(0,i*dy);\
805
    ctx.lineTo(m*dx,(i+m)*dy);\
805
    ctx.lineTo(m*dx,(i+m)*dy);\
806
    ctx.moveTo(0,-i*dy);\
806
    ctx.moveTo(0,-i*dy);\
Line 827... Line 827...
827
let nx = Math.ceil(xsize/dx), ny = Math.ceil(ysize/Math.abs(dy));\
827
let nx = Math.ceil(xsize/dx), ny = Math.ceil(ysize/Math.abs(dy));\
828
let i,m = (nx > ny) ? nx : ny;\
828
let i,m = (nx > ny) ? nx : ny;\
829
var fc = %d+canvas_type;\
829
var fc = %d+canvas_type;\
830
var obj = create_canvas%d(fc,xsize,ysize);\
830
var obj = create_canvas%d(fc,xsize,ysize);\
831
var ctx = obj.getContext('2d');\
831
var ctx = obj.getContext('2d');\
832
ctx.fillStyle='rgba(255,255,255,0.002)';\
832
ctx.fillStyle='rgba(255,255,255,0.01)';\
833
ctx.rect(0,0,xsize,ysize);\
833
ctx.rect(0,0,xsize,ysize);\
834
ctx.fill();\
834
ctx.fill();\
835
ctx.strokeStyle=\"rgba(\"+color+\",0.002)\";\
835
ctx.strokeStyle=\"rgba(\"+color+\",0.01)\";\
836
ctx.lineWidth = linewidth;\
836
ctx.lineWidth = linewidth;\
837
ctx.beginPath();\
837
ctx.beginPath();\
838
  for(i = -2*m ; i<=m ; ++i){\
838
  for(i = -2*m ; i<=m ; ++i){\
839
    ctx.moveTo(0,i*dy);\
839
    ctx.moveTo(0,i*dy);\
840
    ctx.lineTo(m*dx,(i+m)*dy);\
840
    ctx.lineTo(m*dx,(i+m)*dy);\