annotate data/plugin/action/SvgEditor.py @ 399:74b81223475a

SvgEditor: fixes empty content for not existing svg image
author Reimar Bauer <rb.proj AT googlemail DOT com>
date Tue, 25 Aug 2009 07:36:23 +0200
parents 3bf5061ffc30
children a33628b071b2
rev   line source
389
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
1 # -*- coding: iso-8859-1 -*-
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
2 """
396
42af39088fd4 renamed SVG-editor to SvgEditor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents: 395
diff changeset
3 MoinMoin - SvgEditor
389
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
4
391
6747c16172a2 action SVG-editor: save on pagename and target. uri parameter target added. default is example.svg.
Reimar Bauer <rb.proj AT googlemail DOT com>
parents: 389
diff changeset
5 This action is used to call svg-edit, (http://code.google.com/p/svg-edit/)
389
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
6 it is just a thin wrapper around it.
396
42af39088fd4 renamed SVG-editor to SvgEditor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents: 395
diff changeset
7
42af39088fd4 renamed SVG-editor to SvgEditor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents: 395
diff changeset
8 svg-edit pre alpha is called
42af39088fd4 renamed SVG-editor to SvgEditor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents: 395
diff changeset
9 this action needs moin-1.9 and is currently a mockup for an implementation in moin-2.0
389
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
10
391
6747c16172a2 action SVG-editor: save on pagename and target. uri parameter target added. default is example.svg.
Reimar Bauer <rb.proj AT googlemail DOT com>
parents: 389
diff changeset
11 @copyright: 2009 by MoinMoin:ReimarBauer
389
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
12 @license: GNU GPL, see COPYING for details.
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
13 """
395
7c95f95f03fd SVG-editor: reading data back from a given file principle implemented.
Reimar Bauer <rb.proj AT googlemail DOT com>
parents: 392
diff changeset
14 from MoinMoin import config, wikiutil
391
6747c16172a2 action SVG-editor: save on pagename and target. uri parameter target added. default is example.svg.
Reimar Bauer <rb.proj AT googlemail DOT com>
parents: 389
diff changeset
15 from MoinMoin.action import AttachFile
6747c16172a2 action SVG-editor: save on pagename and target. uri parameter target added. default is example.svg.
Reimar Bauer <rb.proj AT googlemail DOT com>
parents: 389
diff changeset
16
6747c16172a2 action SVG-editor: save on pagename and target. uri parameter target added. default is example.svg.
Reimar Bauer <rb.proj AT googlemail DOT com>
parents: 389
diff changeset
17
389
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
18 def execute(pagename, request):
391
6747c16172a2 action SVG-editor: save on pagename and target. uri parameter target added. default is example.svg.
Reimar Bauer <rb.proj AT googlemail DOT com>
parents: 389
diff changeset
19 target = request.values.get('target', 'example.svg')
392
d858f942a1f6 action SVG-editor: prepared for feeding svg data into SVGcanvas
Reimar Bauer <rb.proj AT googlemail DOT com>
parents: 391
diff changeset
20 filecontent = ''
d858f942a1f6 action SVG-editor: prepared for feeding svg data into SVGcanvas
Reimar Bauer <rb.proj AT googlemail DOT com>
parents: 391
diff changeset
21 if AttachFile.exists(request, pagename, target):
d858f942a1f6 action SVG-editor: prepared for feeding svg data into SVGcanvas
Reimar Bauer <rb.proj AT googlemail DOT com>
parents: 391
diff changeset
22 fpath = AttachFile.getFilename(request, pagename, target).encode(config.charset)
d858f942a1f6 action SVG-editor: prepared for feeding svg data into SVGcanvas
Reimar Bauer <rb.proj AT googlemail DOT com>
parents: 391
diff changeset
23 filecontent = file(fpath, 'r').readlines()
395
7c95f95f03fd SVG-editor: reading data back from a given file principle implemented.
Reimar Bauer <rb.proj AT googlemail DOT com>
parents: 392
diff changeset
24 filecontent = ''.join(filecontent[1:])
398
3bf5061ffc30 SvgEditor: adds the decoded svg data to div id="svgdata"
Reimar Bauer <rb.proj AT googlemail DOT com>
parents: 396
diff changeset
25
391
6747c16172a2 action SVG-editor: save on pagename and target. uri parameter target added. default is example.svg.
Reimar Bauer <rb.proj AT googlemail DOT com>
parents: 389
diff changeset
26 do = request.values.get('do', '')
6747c16172a2 action SVG-editor: save on pagename and target. uri parameter target added. default is example.svg.
Reimar Bauer <rb.proj AT googlemail DOT com>
parents: 389
diff changeset
27 if do == 'save':
6747c16172a2 action SVG-editor: save on pagename and target. uri parameter target added. default is example.svg.
Reimar Bauer <rb.proj AT googlemail DOT com>
parents: 389
diff changeset
28 filecontent = request.values.get('svg_data', '')
6747c16172a2 action SVG-editor: save on pagename and target. uri parameter target added. default is example.svg.
Reimar Bauer <rb.proj AT googlemail DOT com>
parents: 389
diff changeset
29 target = request.values.get('target', 'example.svg')
6747c16172a2 action SVG-editor: save on pagename and target. uri parameter target added. default is example.svg.
Reimar Bauer <rb.proj AT googlemail DOT com>
parents: 389
diff changeset
30 if filecontent:
6747c16172a2 action SVG-editor: save on pagename and target. uri parameter target added. default is example.svg.
Reimar Bauer <rb.proj AT googlemail DOT com>
parents: 389
diff changeset
31 # get directory, and possibly create it
6747c16172a2 action SVG-editor: save on pagename and target. uri parameter target added. default is example.svg.
Reimar Bauer <rb.proj AT googlemail DOT com>
parents: 389
diff changeset
32 attach_dir = AttachFile.getAttachDir(request, pagename, create=1)
6747c16172a2 action SVG-editor: save on pagename and target. uri parameter target added. default is example.svg.
Reimar Bauer <rb.proj AT googlemail DOT com>
parents: 389
diff changeset
33 # save file
6747c16172a2 action SVG-editor: save on pagename and target. uri parameter target added. default is example.svg.
Reimar Bauer <rb.proj AT googlemail DOT com>
parents: 389
diff changeset
34 fpath = AttachFile.getFilename(request, pagename, target).encode(config.charset)
6747c16172a2 action SVG-editor: save on pagename and target. uri parameter target added. default is example.svg.
Reimar Bauer <rb.proj AT googlemail DOT com>
parents: 389
diff changeset
35 file(fpath, 'w').write(filecontent.decode('base_64'))
6747c16172a2 action SVG-editor: save on pagename and target. uri parameter target added. default is example.svg.
Reimar Bauer <rb.proj AT googlemail DOT com>
parents: 389
diff changeset
36 return None, None
6747c16172a2 action SVG-editor: save on pagename and target. uri parameter target added. default is example.svg.
Reimar Bauer <rb.proj AT googlemail DOT com>
parents: 389
diff changeset
37
6747c16172a2 action SVG-editor: save on pagename and target. uri parameter target added. default is example.svg.
Reimar Bauer <rb.proj AT googlemail DOT com>
parents: 389
diff changeset
38
389
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
39 url = request.getQualifiedURL()
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
40 htdocs = "%s%s" % (request.cfg.url_prefix_static, '/svg-edit/editor')
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
41
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
42 meta = """
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
43 <meta http-equiv="Content-type" content="text/html;charset=UTF-8" />
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
44 <link rel="icon" type="image/png" href="images/logo.png">
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
45 <link rel="stylesheet" href="%(htdocs)s/jgraduate/css/jPicker-1.0.9.css" type="text/css"/>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
46 <link rel="stylesheet" href="%(htdocs)s/jgraduate/css/jGraduate-0.2.0.css" type="text/css"/>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
47 <link rel="stylesheet" href="%(htdocs)s/svg-editor.css" type="text/css"/>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
48 <link rel="stylesheet" href="%(htdocs)s/spinbtn/JQuerySpinBtn.css" type="text/css"/>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
49 <script type="text/javascript" src="%(htdocs)s/jquery.js"></script>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
50 <!--script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.3/jquery.min.js"></script-->
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
51 <script type="text/javascript" src="%(htdocs)s/js-hotkeys/jquery.hotkeys.min.js"></script>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
52 <!--script type="text/javascript" src="%(htdocs)s/js-hotkeys/jquery.hotkeys-0.7.9.js"></script-->
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
53 <script type="text/javascript" src="%(htdocs)s/jgraduate/jpicker-1.0.9.min.js"></script>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
54 <script type="text/javascript" src="%(htdocs)s/jgraduate/jquery.jgraduate.js"></script>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
55 <script type="text/javascript" src="%(htdocs)s/spinbtn/JQuerySpinBtn.js"></script>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
56 <!--script type="text/javascript" src="%(htdocs)s/spinbtn/JQuerySpinBtn.min.js"></script-->
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
57 <!--script type="text/javascript" src="%(htdocs)s/jgraduate/jquery.jgraduate.min.js"></script-->
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
58 <script type="text/javascript" src="%(htdocs)s/svgcanvas.js"></script>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
59 <!--script type="text/javascript" src="%(htdocs)s/svgcanvas.min.js"></script-->
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
60 <script type="text/javascript" src="%(htdocs)s/svg-editor.js"></script>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
61 <!--script type="text/javascript" src="%(htdocs)s/svg-editor.min.js"></script-->
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
62 """ % {"htdocs": htdocs}
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
63
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
64 html = """
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
65 <div id="svg_editor">
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
66 <div id="workarea">
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
67 <style id="styleoverrides" type="text/css"></style>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
68 <div id="svgcanvas"></div>
399
74b81223475a SvgEditor: fixes empty content for not existing svg image
Reimar Bauer <rb.proj AT googlemail DOT com>
parents: 398
diff changeset
69 <div id="svgdata">%(filecontent)s</div>
389
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
70 </div>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
71
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
72 <div id="logo">
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
73 <a href="http://svg-edit.googlecode.com/" target="_blank" title="SVG-edit Home Page">
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
74 <img src="%(htdocs)s/images/logo.png" width="32" height="32"/>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
75 </a>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
76 </div>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
77
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
78 <div id="tools_top" class="tools_panel">
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
79 <!-- File-like buttons: New, Save, Source -->
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
80 <div>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
81 <img class="tool_sep" src="%(htdocs)s/images/sep.png" alt="|"/>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
82 <img class="tool_button" id="tool_clear" src="%(htdocs)s/images/clear.png" title="New Image [N]" alt="Clear" />
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
83 <img class="tool_button" id="tool_save" src="%(htdocs)s/images/save.png" title="Save Image [S]" alt="Save"/>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
84 <img class="tool_button" id="tool_source" src="%(htdocs)s/images/source.png" title="Edit Source [U]" alt="Source"/>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
85 </div>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
86
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
87 <!-- History buttons -->
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
88 <div>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
89 <img class="tool_sep" src="%(htdocs)s/images/sep.png" alt="|"/>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
90 <img class="tool_button tool_button_disabled" id="tool_undo" src="%(htdocs)s/images/undo.png" title="Undo [Z]" alt="Undo" />
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
91 <img class="tool_button tool_button_disabled" id="tool_redo" src="%(htdocs)s/images/redo.png" title="Redo [Y]" alt="Redo"/>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
92 </div>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
93
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
94 <!-- Buttons when something a single element is selected -->
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
95 <div id="selected_panel">
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
96 <img class="tool_sep" src="%(htdocs)s/images/sep.png" alt="|"/>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
97 <img class="tool_button" id="tool_clone" src="%(htdocs)s/images/copy.png" title="Clone Element [C]" alt="Copy"/>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
98 <img class="tool_button" id="tool_delete" src="%(htdocs)s/images/delete.png" title="Delete Element [Delete/Backspace]" alt="Delete"/>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
99 <img class="tool_button" id="tool_move_top" src="%(htdocs)s/images/move_top.png" title="Move to Top [Shift+Up]" alt="Top"/>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
100 <img class="tool_button" id="tool_move_bottom" src="%(htdocs)s/images/move_bottom.png" title="Move to Bottom [Shift+Down]" alt="Bottom"/>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
101 <select id="group_opacity" class="selected_tool" title="Change selected item opacity">
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
102 <option selected="selected" value="1">100 %%</option>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
103 <option value="0.9">90 %%</option>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
104 <option value="0.8">80 %%</option>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
105 <option value="0.7">70 %%</option>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
106 <option value="0.6">60 %%</option>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
107 <option value="0.5">50 %%</option>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
108 <option value="0.4">40 %%</option>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
109 <option value="0.3">30 %%</option>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
110 <option value="0.2">20 %%</option>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
111 <option value="0.1">10 %%</option>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
112 </select>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
113 <span class="selected_tool">angle:</span>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
114 <input id="angle" class="selected_tool" title="Change rotation angle" alt="Rotation Angle" size="2" value="0" type="text"/>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
115 </div>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
116
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
117 <!-- Buttons when something a single element is selected -->
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
118 <div id="multiselected_panel">
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
119 <img class="tool_sep" src="%(htdocs)s/images/sep.png" alt="|"/>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
120 <img class="tool_button" id="tool_clone_multi" src="%(htdocs)s/images/copy.png" title="Clone Elements [C]" alt="Clone"/>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
121 <img class="tool_button" id="tool_delete_multi" src="%(htdocs)s/images/delete.png" title="Delete Selected Elements [Delete/Backspace]" alt="Delete"/>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
122 </div>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
123
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
124 <div id="rect_panel">
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
125 <img class="tool_sep" src="%(htdocs)s/images/sep.png" alt="|"/>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
126 <label class="rect_tool">x:</label>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
127 <input id="rect_x" class="rect_tool attr_changer" title="Change rectangle X coordinate" alt="x" size="3"/>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
128 <label class="rect_tool">y:</label>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
129 <input id="rect_y" class="rect_tool attr_changer" title="Change rectangle Y coordinate" alt="y" size="3"/>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
130 <label class="rect_tool">width:</label>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
131 <input id="rect_w" class="rect_tool attr_changer" title="Change rectangle width" alt="width" size="3"/>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
132 <label class="rect_tool">height:</label>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
133 <input id="rect_h" class="rect_tool attr_changer" title="Change rectangle height" alt="height" size="3"/>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
134 <label class="rect_tool">Corner Radius:</label>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
135 <input id="rect_radius" size="3" value="0" class="rect_tool" type="text" title="Change Rectangle Corner Radius" alt="Corner Radius"/>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
136 </div>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
137
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
138 <div id="circle_panel">
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
139 <img class="tool_sep" src="%(htdocs)s/images/sep.png" alt="|"/>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
140 <label class="circle_tool">cx:</label>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
141 <input id="circle_cx" class="circle_tool attr_changer" title="Change circle's cx coordinate" alt="cx" size="3"/>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
142 <label class="circle_tool">cy:</label>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
143 <input id="circle_cy" class="circle_tool attr_changer" title="Change circle's cy coordinate" alt="cy" size="3"/>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
144 <label class="circle_tool">r:</label>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
145 <input id="circle_r" class="circle_tool attr_changer" title="Change circle's radius" alt="r" size="3"/>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
146 </div>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
147
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
148 <div id="ellipse_panel">
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
149 <img class="tool_sep" src="%(htdocs)s/images/sep.png" alt="|"/>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
150 <label class="ellipse_tool">cx:</label>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
151 <input id="ellipse_cx" class="ellipse_tool attr_changer" title="Change ellipse's cx coordinate" alt="cx" size="3"/>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
152 <label class="ellipse_tool">cy:</label>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
153 <input id="ellipse_cy" class="ellipse_tool attr_changer" title="Change ellipse's cy coordinate" alt="cy" size="3"/>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
154 <label class="ellipse_tool">rx:</label>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
155 <input id="ellipse_rx" class="ellipse_tool attr_changer" title="Change ellipse's x radius" alt="rx" size="3"/>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
156 <label class="ellipse_tool">ry:</label>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
157 <input id="ellipse_ry" class="ellipse_tool attr_changer" title="Change ellipse's y radius" alt="ry" size="3"/>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
158 </div>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
159
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
160 <div id="line_panel">
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
161 <img class="tool_sep" src="%(htdocs)s/images/sep.png" alt="|"/>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
162 <label class="line_tool">x1:</label>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
163 <input id="line_x1" class="line_tool attr_changer" title="Change line's starting x coordinate" alt="x1" size="3"/>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
164 <label class="line_tool">y1:</label>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
165 <input id="line_y1" class="line_tool attr_changer" title="Change line's starting y coordinate" alt="y1" size="3"/>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
166 <label class="line_tool">x2:</label>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
167 <input id="line_x2" class="line_tool attr_changer" title="Change line's ending x coordinate" alt="x2" size="3"/>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
168 <label class="line_tool">y2:</label>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
169 <input id="line_y2" class="line_tool attr_changer" title="Change line's ending y coordinate" alt="x1" size="3"/>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
170 </div>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
171
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
172 <div id="text_panel">
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
173 <img class="tool_sep" src="%(htdocs)s/images/sep.png" alt="|"/>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
174 <label class="text_tool">x:</label>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
175 <input id="text_x" class="text_tool attr_changer" title="Change text X coordinate" alt="x" size="3"/>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
176 <label class="text_tool">y:</label>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
177 <input id="text_y" class="text_tool attr_changer" title="Change text Y coordinate" alt="y" size="3"/>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
178 <img class="tool_button" id="tool_bold" src="%(htdocs)s/images/bold.png" title="Bold Text [B]" alt="Bold"/>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
179 <img class="tool_button" id="tool_italic" src="%(htdocs)s/images/italic.png" title="Italic Text [I]" alt="Italic"/>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
180 <select id="font_family" class="text_tool" title="Change Font Family">
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
181 <option selected="selected" value="serif">serif</option>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
182 <option value="sans-serif">sans-serif</option>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
183 <option value="cursive">cursive</option>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
184 <option value="fantasy">fantasy</option>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
185 <option value="monospace">monospace</option>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
186 </select>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
187 <select id="font_size" class="text_tool" title="Change Font Size">
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
188 <option value="6pt">6pt</option>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
189 <option value="8pt">8pt</option>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
190 <option value="10pt">10pt</option>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
191 <option selected="selected" value="12pt">12pt</option>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
192 <option value="14pt">14pt</option>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
193 <option value="16pt">16pt</option>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
194 <option value="20pt">20pt</option>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
195 <option value="24pt">24pt</option>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
196 <option value="32pt">32pt</option>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
197 <option value="48pt">48pt</option>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
198 <option value="64pt">64pt</option>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
199 <option value="72pt">72pt</option>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
200 <option value="80pt">80pt</option>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
201 <option value="96pt">96pt</option>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
202 <option value="120pt">120pt</option>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
203 </select>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
204 <input id="text" class="text_tool" type="text" title="Change text contents" size="35"/>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
205 </div>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
206 </div> <!-- tools_top -->
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
207
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
208 <div id="tools_left" class="tools_panel">
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
209 <img class="tool_button_current" id="tool_select" src="%(htdocs)s/images/select.png" title="Select Tool [1]" alt="Select"/><br/>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
210 <img class="tool_button" id="tool_path" src="%(htdocs)s/images/path.png" title="Pencil Tool [2]" alt="Pencil"/><br/>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
211 <img class="tool_button" id="tool_line" src="%(htdocs)s/images/line.png" title="Line Tool [3]" alt="Line"/><br/>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
212 <img class="tool_button" id="tools_rect_show" src="%(htdocs)s/images/square.png" title="Square/Rect Tool [4/Shift+4]" alt="Square"/><br/>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
213 <img class="tool_button" id="tools_ellipse_show" src="%(htdocs)s/images/circle.png" title="Ellipse/Circle Tool [5/Shift+5]" alt="Circle"/><br/>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
214 <img class="tool_button" id="tool_text" src="%(htdocs)s/images/text.png" title="Text Tool [6]" alt="Text"/>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
215 <img class="tool_button" id="tool_poly" src="%(htdocs)s/images/polygon.png" title="Poly Tool [7]" alt="Poly"/>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
216 </div> <!-- tools_left -->
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
217
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
218 <div id="tools_bottom" class="tools_panel">
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
219
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
220 <div id="tools_bottom_1">
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
221 <select id="resolution">
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
222 <option selected="selected">640x480</option>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
223 <option>800x600</option>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
224 <option>1024x768</option>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
225 <option>1280x960</option>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
226 <option>1600x1200</option>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
227 </select>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
228 </div>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
229
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
230 <div id="tools_bottom_2">
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
231 <table>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
232 <tr>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
233 <td>fill:</td>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
234 <td><div id="fill_color" class="color_block" title="Change fill color"></div></td>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
235 <td><div id="fill_opacity">100 %%</div></td>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
236 </tr><tr>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
237 <td>stroke:</td>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
238 <td><div id="stroke_color" class="color_block" title="Change stroke color"></div></td>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
239 <td><div id="stroke_opacity">100 %%</div></td>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
240 <td>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
241 <input id="stroke_width" title="Change stroke width" alt="Stroke Width" size="2" value="5" type="text"/>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
242 </td>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
243 <td>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
244 <select id="stroke_style" title="Change stroke dash style">
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
245 <option selected="selected" value="none">---</option>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
246 <option value="2,2">...</option>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
247 <option value="5,5">- -</option>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
248 <option value="5,2,2,2">- .</option>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
249 <option value="5,2,2,2,2,2">- ..</option>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
250 </select>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
251 </td>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
252 </tr>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
253 </table>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
254 </div>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
255
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
256 <div id="tools_bottom_3">
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
257 <div id="palette_holder"><div id="palette" title="Click to change fill color, shift-click to change stroke color"></div></div>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
258 <div id="copyright">Powered by <a href="http://svg-edit.googlecode.com/" target="_blank">SVG-edit v2.3-preAlpha</a></div>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
259 </div>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
260 </div>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
261
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
262 <!-- hidden divs -->
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
263 <div id="color_picker"></div>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
264
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
265 <div id="tools_rect" class="tools_flyout">
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
266 <div id="tool_square" class="tool_flyout_button" title="Square"></div>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
267 <div id="tool_rect" class="tool_flyout_button" title="Rectangle"></div>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
268 <div id="tool_fhrect" class="tool_flyout_button" title="Free-Hand Rectangle"></div>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
269 </div>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
270
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
271 <div id="tools_ellipse" class="tools_flyout">
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
272 <div id="tool_circle" class="tool_flyout_button" title="Circle"></div>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
273 <div id="tool_ellipse" class="tool_flyout_button" title="Ellipse"></div>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
274 <div id="tool_fhellipse" class="tool_flyout_button" title="Free-Hand Ellipse"></div>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
275 </div>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
276
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
277 <div id="tools_stacking" class="tools_flyout_v">
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
278 <div id="tool_stacktop" class="tool_flyout_button" title="Move to Top [Shift+Up]"></div>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
279 <div id="tool_stackbottom" class="tool_flyout_button" title="Move to Bottom [Shift+Down]"></div>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
280 </div>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
281
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
282 <div id="tools_align" class="tools_flyout_v">
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
283 <div id="tool_aligntop" class="tool_flyout_button" title="Align to Top"></div>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
284 <div id="tool_alignbottom" class="tool_flyout_button" title="Align to Bottom"></div>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
285 <div id="tool_alignmiddle" class="tool_flyout_button" title="Align to Middle"></div>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
286 <div id="tool_alignleft" class="tool_flyout_button" title="Align to Left"></div>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
287 <div id="tool_alignright" class="tool_flyout_button" title="Align to Right"></div>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
288 <div id="tool_aligncenter" class="tool_flyout_button" title="Align to Center"></div>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
289 </div>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
290
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
291 </div> <!-- svg_editor -->
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
292
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
293 <div id="svg_source_editor">
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
294 <div id="svg_source_overlay"></div>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
295 <div id="svg_source_container">
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
296 <div id="tool_source_back" class="toolbar_button"></div>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
297 <form>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
298 <textarea id="svg_source_textarea"></textarea>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
299 </form>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
300 </div>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
301 </div>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
302
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
303 <script type="text/javascript">
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
304 $(document).ready(svg_edit_setup);
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
305 </script>
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
306
391
6747c16172a2 action SVG-editor: save on pagename and target. uri parameter target added. default is example.svg.
Reimar Bauer <rb.proj AT googlemail DOT com>
parents: 389
diff changeset
307 """ % {"htdocs": htdocs,
392
d858f942a1f6 action SVG-editor: prepared for feeding svg data into SVGcanvas
Reimar Bauer <rb.proj AT googlemail DOT com>
parents: 391
diff changeset
308 "filecontent": filecontent,
391
6747c16172a2 action SVG-editor: save on pagename and target. uri parameter target added. default is example.svg.
Reimar Bauer <rb.proj AT googlemail DOT com>
parents: 389
diff changeset
309 }
389
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
310
391
6747c16172a2 action SVG-editor: save on pagename and target. uri parameter target added. default is example.svg.
Reimar Bauer <rb.proj AT googlemail DOT com>
parents: 389
diff changeset
311 title = "%s:%s" % (pagename, target)
389
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
312 request.theme.send_title(title, page=request.page, pagename=pagename)
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
313 request.write(request.formatter.startContent("content"))
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
314 request.write(request.formatter.rawHTML(meta))
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
315
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
316 request.write(request.formatter.rawHTML(html))
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
317 request.write(request.formatter.endContent())
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
318 request.theme.send_footer(pagename)
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
319 request.theme.send_closing_html()
764834d3a461 initial version of svg-edit Revision r448 and action SVG-editor
Reimar Bauer <rb.proj AT googlemail DOT com>
parents:
diff changeset
320 return None,None