jDraw is a plug-in for DokuWiki. It allows to create and edit diagrams in a web browser and embed them to DokuWiki pages. jDraw also provides an off-line diagram editor with diagram file format compatible with the on-line editor.
Free for non-commercial use.
2010/06/16
jDraw is an applet. It was tested in FireFox 3.6 with Java 6 and DokuWiki 2009-12-25c.
Download and install the plugin using the Plugin Manager and the URL (http://www.hammurapi.com/products/jdraw/jdraw.zip) given above.
You should manually add mxe text/xml to mime.conf file.
/somenonexistingcodebase because the web server must return proper error code for the applet to work correctly. If this attribute is not set, codebase defaults to page location. In this case DokuWiki returns “Page does not exist” with status code 200 and the applet fails.
If your server doesn't return proper error codes for non-existing resources but rather some customized pages, you should configure some URL on the server to return proper error codes and point applet's codebase to that location.
DokuWiki Syntax:
{{jdraw>[namespace:]name}}
Examples:
{{jdraw>mynamespace:mydiagram}}
{{jdraw>mydiagram}}
For users with appropriate privileges a little [Edit] box appears next to the diagram image1).
The plug-in operates with two files in the media directory - <diagram name>.mxe file is the diagram file and <diagram name>.gif is the diagram image.
Currently the plug-in does not auto-refresh the page with diagram upon diagram saving - you should do it manually (F5).
The diagram below demonstrates how jDraw works. The diagram was created with jDraw.
The plug-in generates diagram image on save of the same size as it appears on screen. To change size of diagram images, scale diagram in the editor to appropriate size before saving.
The [Edit] button is available to users with Delete permission.
Although applet jars are signed, for some reason some permissions shall be explicitly granted.
The plug-in works through proxy if you grant
java.net.NetPermission), with target getProxySelector connect, resolve to <dokuwiki host>/<dokuwiki path>/lib/plugins/jdraw/lib//- 2) codebase with Java policytool.
On Java 6 update 20 the plug-in requires granting java.awt.AWTPermission accessClipboard. Some users reported Java.Security AccessControlException:access denied (java.lang.RuntimePermission accessDeclaredMembers). The solution, if you get a security exception, open policy tool and grant required permission. Some exceptions don't show up in error dialogs. If you think the applet doesn't work as it should - open Java Console and look for exceptions.
You can use off-line editor to create mxe and gif files and then upload these files to your Wiki with the Media Manager. After that you can include {{jdraw>...}} tag in you pages referencing the files and edit them in the applet. You can also download mxe file created by the applet, edit it in the offline editor and then upload the mxe file and image (gif) file to Wiki.
There are two ways to install and use the offline editor
policytool and grant all permissions to http://www.hammurapi.com/products/jdraw/lib/- codebase.jgrahpx-examples.jar from the lib folder by either double-clicking it or using java -jar jgraphx-examples.jar command line.