2009-06-04 07:01:16 +00:00
|
|
|
<!DOCTYPE html>
|
2009-02-06 08:58:39 +00:00
|
|
|
<html>
|
|
|
|
<head>
|
2009-06-05 14:02:34 +00:00
|
|
|
<link rel="stylesheet" href="jpicker/jpicker.css" type="text/css"/>
|
2009-06-01 15:55:21 +00:00
|
|
|
<link rel="stylesheet" href="svg-editor.css" type="text/css"/>
|
2009-06-10 12:32:24 +00:00
|
|
|
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.3/jquery.min.js"></script>
|
2009-06-17 02:04:10 +00:00
|
|
|
<script type="text/javascript" src="js-hotkeys/jquery.hotkeys.min.js"></script>
|
2009-06-05 14:02:34 +00:00
|
|
|
<script type="text/javascript" src="jpicker/jpicker.js"></script>
|
2009-06-07 00:17:21 +00:00
|
|
|
<script type="text/javascript" src="svgcanvas.js"></script>
|
2009-06-10 12:32:24 +00:00
|
|
|
<script type="text/javascript" src="svg-editor.js"></script>
|
2009-06-01 17:35:22 +00:00
|
|
|
<title>SVG-edit demo</title>
|
2009-02-06 08:58:39 +00:00
|
|
|
</head>
|
|
|
|
<body>
|
|
|
|
|
2009-06-03 13:03:10 +00:00
|
|
|
<div id="svg_editor">
|
|
|
|
|
2009-06-05 14:02:34 +00:00
|
|
|
<div id="color_picker" class="tools_flyout"></div>
|
2009-06-02 12:52:44 +00:00
|
|
|
|
2009-06-04 10:42:01 +00:00
|
|
|
<div id="tools_rect" class="tools_flyout">
|
2009-06-04 07:01:16 +00:00
|
|
|
<div id="tool_square" title="Square"></div>
|
2009-06-04 10:42:01 +00:00
|
|
|
<div id="tool_rect" title="Rectangle"></div>
|
2009-06-04 07:01:16 +00:00
|
|
|
<div id="tool_fhrect" title="Free-Hand Rectangle"></div>
|
2009-06-03 13:03:10 +00:00
|
|
|
</div>
|
|
|
|
|
2009-06-04 10:42:01 +00:00
|
|
|
<div id="tools_ellipse" class="tools_flyout">
|
2009-06-04 07:01:16 +00:00
|
|
|
<div id="tool_circle" title="Circle"></div>
|
2009-06-04 10:42:01 +00:00
|
|
|
<div id="tool_ellipse" title="Ellipse"></div>
|
2009-06-04 07:01:16 +00:00
|
|
|
<div id="tool_fhellipse" title="Free-Hand Ellipse"></div>
|
2009-06-03 13:03:10 +00:00
|
|
|
</div>
|
2009-02-06 08:58:39 +00:00
|
|
|
|
2009-06-10 04:44:59 +00:00
|
|
|
<div id="context_tools" class="tools_panel">
|
|
|
|
<!-- File-like buttons: New, Save -->
|
2009-06-17 20:08:53 +00:00
|
|
|
<div>
|
2009-06-10 04:44:59 +00:00
|
|
|
<img class="tool_button" id="tool_clear" src="images/clear.png" title="New Image [N]" alt="Clear" />
|
|
|
|
<img class="tool_button" id="tool_save" src="images/save.png" title="Save Image [S]" alt="Save"/>
|
2009-06-17 20:08:53 +00:00
|
|
|
</div>
|
2009-06-10 04:44:59 +00:00
|
|
|
|
2009-06-17 20:08:53 +00:00
|
|
|
<!-- Buttons when something is selected -->
|
|
|
|
<div id="selected_panel">
|
|
|
|
<img class="tool_sep" src="images/sep.png" alt="|"/>
|
2009-06-23 21:18:23 +00:00
|
|
|
<img class="tool_button" id="tool_delete" src="images/delete.png" title="Delete Element [Delete/Backspace]" alt="Delete"/>
|
|
|
|
<img class="tool_button" id="tool_move_top" src="images/move_top.png" title="Move to Top [Shift+Up]" alt="Top"/>
|
|
|
|
<img class="tool_button" id="tool_move_bottom" src="images/move_bottom.png" title="Move to Bottom [Shift+Down]" alt="Bottom"/>
|
2009-06-17 20:08:53 +00:00
|
|
|
</div>
|
2009-06-10 04:44:59 +00:00
|
|
|
|
2009-06-11 15:18:46 +00:00
|
|
|
<div id="rect_panel">
|
2009-06-17 20:08:53 +00:00
|
|
|
<img class="tool_sep" src="images/sep.png" alt="|"/>
|
2009-06-23 17:20:21 +00:00
|
|
|
<label class="rect_tool">Radius:</label>
|
2009-06-11 15:18:46 +00:00
|
|
|
<!-- TODO: turn this into a spinner control! -->
|
2009-06-23 17:20:21 +00:00
|
|
|
<select id="rect_radius" class="rect_tool" title="Change rectangle corner radius" alt="Corner Radius">
|
2009-06-11 15:18:46 +00:00
|
|
|
<option selected="selected" value="0">0</option>
|
|
|
|
<option value="1">1</option>
|
|
|
|
<option value="2">2</option>
|
|
|
|
<option value="3">3</option>
|
|
|
|
<option value="5">5</option>
|
|
|
|
<option value="7">7</option>
|
|
|
|
<option value="10">10</option>
|
|
|
|
<option value="15">15</option>
|
|
|
|
<option value="20">20</option>
|
|
|
|
</select>
|
2009-06-24 04:17:35 +00:00
|
|
|
<label class="rect_tool">x:</label>
|
2009-06-24 04:33:09 +00:00
|
|
|
<input id="rect_x" class="rect_tool attr_changer" title="Change rectangle X coordinate" alt="x" size="5"/>
|
2009-06-24 04:17:35 +00:00
|
|
|
<label class="rect_tool">y:</label>
|
2009-06-24 04:33:09 +00:00
|
|
|
<input id="rect_y" class="rect_tool attr_changer" title="Change rectangle Y coordinate" alt="y" size="5"/>
|
2009-06-24 04:17:35 +00:00
|
|
|
<label class="rect_tool">width:</label>
|
2009-06-24 04:33:09 +00:00
|
|
|
<input id="rect_w" class="rect_tool attr_changer" title="Change rectangle width" alt="width" size="5"/>
|
2009-06-24 04:17:35 +00:00
|
|
|
<label class="rect_tool">height:</label>
|
2009-06-24 04:33:09 +00:00
|
|
|
<input id="rect_h" class="rect_tool attr_changer" title="Change rectangle height" alt="height" size="5"/>
|
2009-06-11 15:18:46 +00:00
|
|
|
</div>
|
2009-06-17 20:08:53 +00:00
|
|
|
|
2009-06-24 04:17:35 +00:00
|
|
|
<div id="circle_panel">
|
|
|
|
<img class="tool_sep" src="images/sep.png" alt="|"/>
|
|
|
|
<label class="circle_tool">cx:</label>
|
2009-06-24 04:33:09 +00:00
|
|
|
<input id="circle_cx" class="circle_tool attr_changer" title="Change circle's cx coordinate" alt="cx" size="5"/>
|
2009-06-24 04:17:35 +00:00
|
|
|
<label class="circle_tool">cy:</label>
|
2009-06-24 04:33:09 +00:00
|
|
|
<input id="circle_cy" class="circle_tool attr_changer" title="Change circle's cy coordinate" alt="cy" size="5"/>
|
2009-06-24 04:17:35 +00:00
|
|
|
<label class="circle_tool">r:</label>
|
2009-06-24 04:33:09 +00:00
|
|
|
<input id="circle_r" class="circle_tool attr_changer" title="Change circle's radius" alt="r" size="5"/>
|
2009-06-24 04:17:35 +00:00
|
|
|
</div>
|
|
|
|
|
|
|
|
<div id="ellipse_panel">
|
|
|
|
<img class="tool_sep" src="images/sep.png" alt="|"/>
|
|
|
|
<label class="ellipse_tool">cx:</label>
|
2009-06-24 04:33:09 +00:00
|
|
|
<input id="ellipse_cx" class="ellipse_tool attr_changer" title="Change ellipse's cx coordinate" alt="cx" size="5"/>
|
2009-06-24 04:17:35 +00:00
|
|
|
<label class="ellipse_tool">cy:</label>
|
2009-06-24 04:33:09 +00:00
|
|
|
<input id="ellipse_cy" class="ellipse_tool attr_changer" title="Change ellipse's cy coordinate" alt="cy" size="5"/>
|
2009-06-24 04:17:35 +00:00
|
|
|
<label class="ellipse_tool">rx:</label>
|
2009-06-24 04:33:09 +00:00
|
|
|
<input id="ellipse_rx" class="ellipse_tool attr_changer" title="Change ellipse's x radius" alt="rx" size="5"/>
|
2009-06-24 04:17:35 +00:00
|
|
|
<label class="ellipse_tool">ry:</label>
|
2009-06-24 04:33:09 +00:00
|
|
|
<input id="ellipse_ry" class="ellipse_tool attr_changer" title="Change ellipse's y radius" alt="ry" size="5"/>
|
2009-06-24 04:17:35 +00:00
|
|
|
</div>
|
|
|
|
|
|
|
|
<div id="line_panel">
|
|
|
|
<img class="tool_sep" src="images/sep.png" alt="|"/>
|
|
|
|
<label class="line_tool">x1:</label>
|
2009-06-24 04:33:09 +00:00
|
|
|
<input id="line_x1" class="line_tool attr_changer" title="Change line's starting x coordinate" alt="x1" size="5"/>
|
2009-06-24 04:17:35 +00:00
|
|
|
<label class="line_tool">y1:</label>
|
2009-06-24 04:33:09 +00:00
|
|
|
<input id="line_y1" class="line_tool attr_changer" title="Change line's starting y coordinate" alt="y1" size="5"/>
|
2009-06-24 04:17:35 +00:00
|
|
|
<label class="line_tool">x2:</label>
|
2009-06-24 04:33:09 +00:00
|
|
|
<input id="line_x2" class="line_tool attr_changer" title="Change line's ending x coordinate" alt="x2" size="5"/>
|
2009-06-24 04:17:35 +00:00
|
|
|
<label class="line_tool">y2:</label>
|
2009-06-24 04:33:09 +00:00
|
|
|
<input id="line_y2" class="line_tool attr_changer" title="Change line's ending y coordinate" alt="x1" size="5"/>
|
2009-06-24 04:17:35 +00:00
|
|
|
</div>
|
2009-06-11 15:18:46 +00:00
|
|
|
|
2009-06-10 04:44:59 +00:00
|
|
|
<div id="text_panel">
|
2009-06-17 20:08:53 +00:00
|
|
|
<img class="tool_sep" src="images/sep.png" alt="|"/>
|
2009-06-10 04:44:59 +00:00
|
|
|
<select id="font_family" class="text_tool" title="Change Font Family">
|
|
|
|
<option selected="selected" value="serif">serif</option>
|
|
|
|
<option value="sans-serif">sans-serif</option>
|
|
|
|
<option value="cursive">cursive</option>
|
|
|
|
<option value="fantasy">fantasy</option>
|
|
|
|
<option value="monospace">monospace</option>
|
|
|
|
</select>
|
|
|
|
<select id="font_size" class="text_tool" title="Change Font Size">
|
|
|
|
<option value="6pt">6pt</option>
|
|
|
|
<option value="8pt">8pt</option>
|
|
|
|
<option value="10pt">10pt</option>
|
|
|
|
<option selected="selected" value="12pt">12pt</option>
|
|
|
|
<option value="14pt">14pt</option>
|
|
|
|
<option value="16pt">16pt</option>
|
|
|
|
<option value="20pt">20pt</option>
|
|
|
|
<option value="24pt">24pt</option>
|
|
|
|
<option value="32pt">32pt</option>
|
|
|
|
<option value="48pt">48pt</option>
|
|
|
|
<option value="64pt">64pt</option>
|
2009-06-10 08:59:08 +00:00
|
|
|
<option value="72pt">72pt</option>
|
2009-06-10 04:44:59 +00:00
|
|
|
<option value="80pt">80pt</option>
|
2009-06-10 08:59:08 +00:00
|
|
|
<option value="96pt">96pt</option>
|
|
|
|
<option value="120pt">120pt</option>
|
2009-06-10 04:44:59 +00:00
|
|
|
</select>
|
2009-06-24 22:07:58 +00:00
|
|
|
<input id="text" class="text_tool" type="text" title="Change text contents" size="35"/>
|
2009-06-10 04:44:59 +00:00
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
2009-06-10 03:12:19 +00:00
|
|
|
<div id="tools" class="tools_panel">
|
2009-02-06 08:58:39 +00:00
|
|
|
|
2009-06-17 17:36:00 +00:00
|
|
|
<img class="tool_button_current" id="tool_select" src="images/select.png" title="Select Tool [1]" alt="Select"/><br/>
|
|
|
|
<img class="tool_button" id="tool_path" src="images/path.png" title="Pencil Tool [2]" alt="Pencil"/><br/>
|
2009-06-09 13:28:37 +00:00
|
|
|
<img class="tool_button" id="tool_line" src="images/line.png" title="Line Tool [3]" alt="Line"/><br/>
|
2009-06-17 20:08:53 +00:00
|
|
|
<img class="tool_button" id="tools_rect_show" src="images/square.png" title="Square/Rect Tool [4/Shift+4]" alt="Square"/><br/>
|
2009-06-17 02:04:10 +00:00
|
|
|
<img class="tool_button" id="tools_ellipse_show" src="images/circle.png" title="Ellipse/Circle Tool [5/Shift+5]" alt="Circle"/><br/>
|
2009-06-10 08:59:08 +00:00
|
|
|
<img class="tool_button" id="tool_text" src="images/text.png" title="Text Tool [6]" alt="Text"/>
|
|
|
|
|
|
|
|
<hr/>
|
|
|
|
|
|
|
|
<div>opacity<br/>
|
|
|
|
<select id="group_opacity" title="Change group opacity">
|
|
|
|
<option selected="selected" value="1">100 %</option>
|
|
|
|
<option value="0.9">90 %</option>
|
|
|
|
<option value="0.8">80 %</option>
|
|
|
|
<option value="0.7">70 %</option>
|
|
|
|
<option value="0.6">60 %</option>
|
|
|
|
<option value="0.5">50 %</option>
|
|
|
|
<option value="0.4">40 %</option>
|
|
|
|
<option value="0.3">30 %</option>
|
|
|
|
<option value="0.2">20 %</option>
|
|
|
|
<option value="0.1">10 %</option>
|
|
|
|
</select>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<hr/>
|
|
|
|
|
2009-06-03 13:03:10 +00:00
|
|
|
<div>fill
|
2009-06-04 07:01:16 +00:00
|
|
|
<div id="fill_color" title="Change fill color"></div>
|
2009-06-04 13:43:58 +00:00
|
|
|
<select id="fill_opacity" title="Change fill opacity">
|
|
|
|
<option selected="selected" value="1">100 %</option>
|
|
|
|
<option value="0.9">90 %</option>
|
|
|
|
<option value="0.8">80 %</option>
|
|
|
|
<option value="0.7">70 %</option>
|
|
|
|
<option value="0.6">60 %</option>
|
|
|
|
<option value="0.5">50 %</option>
|
|
|
|
<option value="0.4">40 %</option>
|
|
|
|
<option value="0.3">30 %</option>
|
|
|
|
<option value="0.2">20 %</option>
|
|
|
|
<option value="0.1">10 %</option>
|
|
|
|
</select>
|
2009-06-01 15:55:21 +00:00
|
|
|
</div>
|
2009-02-06 08:58:39 +00:00
|
|
|
|
2009-06-03 13:03:10 +00:00
|
|
|
<hr/>
|
|
|
|
|
|
|
|
<div>stroke
|
2009-06-04 07:01:16 +00:00
|
|
|
<div id="stroke_color" title="Change stroke color"></div>
|
2009-06-03 13:03:10 +00:00
|
|
|
<div>
|
2009-06-04 07:01:16 +00:00
|
|
|
<select id="stroke_width" title="Change stroke width">
|
2009-06-02 16:40:33 +00:00
|
|
|
<option selected="selected" value="1">1</option>
|
|
|
|
<option value="2">2</option>
|
|
|
|
<option value="3">3</option>
|
|
|
|
<option value="5">5</option>
|
|
|
|
<option value="7">7</option>
|
2009-02-06 08:58:39 +00:00
|
|
|
</select>
|
2009-06-03 13:03:10 +00:00
|
|
|
</div><div>
|
2009-06-04 07:01:16 +00:00
|
|
|
<select id="stroke_style" title="Change stroke dash style">
|
2009-06-03 13:03:10 +00:00
|
|
|
<option selected="selected" value="none">---</option>
|
|
|
|
<option value="2,2">...</option>
|
|
|
|
<option value="5,5">- -</option>
|
|
|
|
<option value="5,2,2,2">- .</option>
|
|
|
|
<option value="5,2,2,2,2,2">- ..</option>
|
2009-06-01 22:01:07 +00:00
|
|
|
</select>
|
2009-06-03 13:03:10 +00:00
|
|
|
</div>
|
2009-06-04 13:43:58 +00:00
|
|
|
<div>
|
|
|
|
<select id="stroke_opacity" title="Change stroke opacity">
|
|
|
|
<option selected="selected" value="1">100 %</option>
|
|
|
|
<option value="0.9">90 %</option>
|
|
|
|
<option value="0.8">80 %</option>
|
|
|
|
<option value="0.7">70 %</option>
|
|
|
|
<option value="0.6">60 %</option>
|
|
|
|
<option value="0.5">50 %</option>
|
|
|
|
<option value="0.4">40 %</option>
|
|
|
|
<option value="0.3">30 %</option>
|
|
|
|
<option value="0.2">20 %</option>
|
|
|
|
<option value="0.1">10 %</option>
|
|
|
|
</select>
|
|
|
|
</div>
|
2009-02-06 08:58:39 +00:00
|
|
|
</div>
|
2009-02-13 08:53:35 +00:00
|
|
|
|
2009-06-01 15:55:21 +00:00
|
|
|
</div>
|
2009-02-13 08:53:35 +00:00
|
|
|
|
2009-06-01 15:55:21 +00:00
|
|
|
<div id="workarea">
|
2009-02-13 08:53:35 +00:00
|
|
|
|
2009-06-08 02:55:15 +00:00
|
|
|
<style id="styleoverrides" type="text/css"></style>
|
2009-06-03 13:03:10 +00:00
|
|
|
<div id="svgcanvas">
|
2009-06-01 15:55:21 +00:00
|
|
|
</div>
|
2009-02-13 08:53:35 +00:00
|
|
|
|
2009-06-01 15:55:21 +00:00
|
|
|
<div id="palette_holder">
|
2009-06-17 02:17:22 +00:00
|
|
|
<div id="palette" title="Click to change fill color, shift-click to change stroke color">
|
2009-06-01 15:55:21 +00:00
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
2009-06-10 12:32:24 +00:00
|
|
|
<div id="footer" class="tools_panel">
|
2009-06-18 04:32:10 +00:00
|
|
|
SVG-edit v2.2-preAlpha @ <a href="http://svg-edit.googlecode.com/">http://svg-edit.googlecode.com/</a>
|
2009-06-10 12:32:24 +00:00
|
|
|
</div>
|
|
|
|
|
2009-06-01 15:55:21 +00:00
|
|
|
</div>
|
2009-02-13 08:53:35 +00:00
|
|
|
|
2009-06-07 13:11:01 +00:00
|
|
|
<script type="text/javascript">
|
|
|
|
$(document).ready(svg_edit_setup);
|
|
|
|
</script>
|
|
|
|
|
2009-02-06 08:58:39 +00:00
|
|
|
</body>
|
|
|
|
</html>
|