Table of Contents

Preparing the documentation

Graphics for DokuWiki

Direct insertion of SVG

When inserting SVG images in DokuWiki with Scalable SVG Insert Plugin use the following scale factors:

SVG to PNG conversion

When exporting SVG graphics as PNG in Inkscape for inserting into DokuWiki, use the following DPI settings:

Screenshot dimensions

The maximum screenshot size for DokuWiki should be 900×600. This dimensions of Workcraft window can be set via ~/.config/workcraft/config.xml (note the height is set 28 pixel less to accommodate for the title bar):

...
<var name="main.maximised" value="false"/>
<var name="main.height" value="572"/>
<var name="main.width" value="900"/>
...

For fullscreen screenshots the good dimensions seem to be 1900×1000 (minus 28 pixel for the title bar):

...
<var name="main.maximised" value="false"/>
<var name="main.height" value="972"/>
<var name="main.width" value="1900"/>
...

Offline documentation

Tutorial materials and help files

We use a tweaked version of dokuwiki-light template for generating offline pages. See DokuWiki setup for instructions of how to produce this template.

Handouts

The best margins for printout of handouts:

SVG diagrams can be reduced up to the following scale:

This is mostly to avoid wide SVG files that do not fit the page width and have side effect on the scale of all the document, including text.

Using work files in LyX

This feature requires Workcraft v3.2.3(alpha) or newer.

Register Workcraft with Lyx via Tools→Preferences→File Handling menu as follows:

  1. Add Work to the File Formats section
    • Format: Work
    • Document format: true
    • Show in export menu: false
    • Vector graphics format: true
    • Short name: work
    • Extension: work
    • MIME: application/workcraft
    • Editor: (Custom) workcraft
    • Viewer: (Custom) workcraft
  2. Add Work → SVG to the Converters section
    • From format: Work
    • To format: SVG
    • Converter: workcraft -nogui -dir:$$p -exec:"exportSvg(load(args[0]), args[1]); exit();" $$i $$o

Note that Workcraft runner script is assumed to be in the search path. Otherwise you would have to use the full path.