diff --git a/links/main.css b/links/main.css index 84a15c6..5ef8ddc 100644 --- a/links/main.css +++ b/links/main.css @@ -8,4 +8,8 @@ body { background:#fff; padding:50px;} #dotgrid #cursor_to { width:6px; height:6px; background:white; margin-top:-5px; margin-left:-5px; position:absolute; z-index:25; border-radius:10px; left:-100px; border:2px solid black;} input { padding:2px 5px; border-radius:20px; margin:0px auto; display:none;} .vector { position:relative; z-index:900; } -pre { font-family:courier; font-size:11px; position:fixed; left:0px; bottom:20px;} \ No newline at end of file +pre { font-family:courier; font-size:11px; color:#000; position:fixed; bottom:20px;} +.reference { left:0; } +.settings { right:20px; text-align:right; } +.settings input { display:inline; background:#fff; width:4em; } +.settings select { display:inline; background:#fff; } \ No newline at end of file diff --git a/scripts/dotgrid.js b/scripts/dotgrid.js index 72d2472..e6b5d9e 100644 --- a/scripts/dotgrid.js +++ b/scripts/dotgrid.js @@ -227,4 +227,16 @@ function Dotgrid(width,height,grid_x,grid_y,block_x,block_y,thickness = 3,lineca y = parseInt(y/this.grid_height) * this.grid_height + (this.grid_height/2); return [parseInt(x),parseInt(y)]; } + + // Settings + + this.update_style = function(attribute, value) { + switch(attribute) { + case "strokeWidth": + vector_element.style.strokeWidth = value; + break; + case "strokeLinecap": + vector_element.style.strokeLinecap = value; + } + } } \ No newline at end of file diff --git a/template.interface.html b/template.interface.html index 281cecf..599499f 100644 --- a/template.interface.html +++ b/template.interface.html @@ -9,7 +9,8 @@ Dotgrid(Interface) -
+    
+    
       q  CLEAR
       w  DELETE LAST
       e  EXPORT
@@ -23,6 +24,18 @@
       x  CIRCLE
       c  --
     
+ +
+      THICKNESS 
+      LINECAP 
+    
+