Home
Categories
Dictionary
Download
Project Details
Changes Log
What Links Here
How To
Syntax
FAQ
License

Editor tutorial



This article is a tutorial to explaining how to use the editor.

You will:
  • Open the editor
  • Create an index article
  • Create a first article
  • Create a second article

The content of the wiki we will create in the editor will be the same as for the first tutorial.

Open the editor

Choose an empty directory to put your articles, and another to put the result of the wiki generation.

Now double-click on the jar file of the application and:
  • Input directories: Set your directory (with only the index.xml file for the moment)
  • Output directory: there is no need to select any directory for now

tutoeditor1
Click on Editor => Open Editor:
tutoeditor2
The window of the editor will appear. The only element in the tree is the name of the source directory for the wiki:
tutoeditor3

Create the index

We will now create the index article in the editor.

Right-click on the source directory element in the tree and choose the "Add Index" sub-menu:
tutoeditor4
Now we will have to specify the name of the index file in the popup dialog window:
editortree-addindex
Click on the button at the right of the "File" field and type "index":
tutoeditor5
We will create an index article named "index.xml" just under the input directory:
tutoeditor6
Type "Yes": an empty index article has now been created and the tree has been updated:
tutoeditor7
Now if we select the index in the tree, the left panel show an empty html content because the index is empty for the moment:
tutoeditor8

Edit the index article

If we click on the editor-content-edit button, we will enter the edition mode, and we see an XML content which we can edit:
tutoeditor9
Now type the following content: "The index for the tutorial wiki." in the editor area:
tutoeditor10
And lastly click on the editor-content-save button to save the html content on the disk.

Now we can click again on the editor-content-view button to go back to the view mode. We will see the following html content:
tutoeditor11

Create the first article

We will now create a regular article in the editor.

Select the index article we just created in the tree and choose the "Add Article" sub-menu:
editortree-addafter
Now we will have to specify the name of the article file and its name in the popup dialog window:
editortree-addarticle
Click on the button at the right of the "File" field and type "article1":
tutoeditor12
JNow type "first article" for the name field:
tutoeditor13
Type "Yes": an empty regular article has now been created and the tree has been updated:
tutoeditor14
Now if we select the article in the tree, the left panel show a default html content for the article:
tutoeditor15

Edit the first article

If we click on the editor-content-edit button, we will enter the edition mode, and we see an XML content which we can edit:
tutoeditor16
Now type the following content: "The content of the first article." in the editor area:
tutoeditor17
And lastly click on the editor-content-save button to save the html content on the disk.

Now we can click again on the editor-content-view button to go back to the view mode. We will see the following html content:
tutoeditor18

Add a link to the first article in the index

We will also add an internal wikilink to this article in our index file. Select the index again, and go in the edit edition mode:
tutoeditor10
We will type the following content: "The index for the tutorial wiki. A link to the <ref id="first article" />.":
tutoeditor19
And now click on the editor-content-save button to save the html content on the disk.

Now we can click again on the editor-content-view button to go back to the view mode. We will see the following html content:
tutoeditor20
If we click on the hyperlink, we go to the second article.

Add an image

We will add an image in the source director, use this image in an image definition file, and use it in an article.

Add an image in the source directory

We will add an image in the source directory. To do that, Right-click on the source directory element in the tree and choose the "Shown in Desktop" sub-menu:
tutoeditor21
The directory is opened in the file system:
tutoeditor22
Copy an image in this directory:
tutoeditor23
Now we can refresh the content of the source directory to see the image in the tree:
tutoeditor24
The tree is updated:
tutoeditor25

Create an image definition file

We will now create an image definition file and use this image.

First select the source directory and choose the "Add Images Definition" sub-menu:
tutoeditor26
We will call the images file "images.xml"[1]
Any other name would work
:
tutoeditor27
The tree is updated:
tutoeditor28
Now select the new file in the tree:
tutoeditor29
We now have to add the image definition in this file. Add the <imgage id="ball" url="ball.jpg" /> line:
tutoeditor30
And now click on the editor-content-save button to save the file.

Use the image in the first article

Select again the first article and click on the editor-content-edit button:

Add the <img id="ball" /> line:
tutoeditor31
And now click on the editor-content-save button to save the html content on the disk.

Now we can click again on the editor-content-view button to go back to the view mode. We will see the following html content:
tutoeditor32

Notes

  1. ^ Any other name would work

See also


Categories: tutorials

docJGenerator Copyright (c) 2016-2023 Herve Girod. All rights reserved.