Index: work/scripts/ruler.awk =================================================================== --- work/scripts/ruler.awk (revision 19322) +++ work/scripts/ruler.awk (revision 19323) @@ -2,25 +2,22 @@ function ruler(user_input) { setunits("mm") - setvalue("grid, 0.5, mm") - #grid ("grid, 0.5, mm") + grid ("set", "0.5mm") + selectlayer("silk") for (x=0; x < user_input+0 + 1 ; x++){ - if (x != 0 && x % 10 == 0 ){ + if (x % 10 == 0){ ddraft("line from " x "mm,1mm to " x "mm,3.5mm") - message("x is " x ); - createtext( "#8" , 0, x - 0.6 "mm", "4.0mm", 0 , 100, x "") + if (x != 0){ + createtext( "#8" , 0, x - 0.6 "mm", "4.0mm", 0 , 100, x "") + } } - else{ - ddraft("line from " x "mm,1mm to " x "mm,2mm") - } + else { + ddraft("line from " x "mm,1mm to " x "mm,2.0mm") + } } return 0 } - BEGIN { fgw_func_reg("ruler") } - -#oneliner -#for (x=0; x < 150, x++){if (x % 10 == 0) ddraft("line from " x "mm,0 to " x "mm,10mm") else ddraft("line from " x "mm,0 to " x "mm,1mm")}