Skip to main content

Elements as structured content

To create content in a topic or other component, you need to add structural elements and then insert your content inside those elements. The elements that are available to use are defined by the DocBook content model and when adding them, you need to follow the DocBook rules.

DocBook has many different elements in its content model and most are named to describe a type of content. For example, para for paragraph, procedure for a list of instructions, and step for each step in the list. Some elements are self-explanatory, while others are a little more obscure. When you create content in Paligo, you don't need to know the content model in great detail, but it will help to have an awareness of what's available. You can find out about DocBook elements at the official DocBook site.

Block elements and inline elements

There are many different elements that you can use, but they can all be categorized as either a block element or an inline element.

  • Block elements

    Block elements create structures that are on a new line and they are the main "building blocks" for the content inside a topic or component. Common examples of block elements are para and procedure. Paligo's editor is designed to hide the block elements from view, so that you can focus on the actual content. But you can see the block elements by looking at the XML tree view.

    A topic's structure as shown in the XML tree view. There is a section element at the top. Inside that there is a title element, a para element, and a procedure element. Inside the procedure element there are a series of step elements.

    For block elements, you position the cursor in the editor and then use the toolbar or Element Context Menu to add the element you want. You need to be careful with the cursor position and make sure that it is inside or outside the previous block element, depending on where you want the new element to go.

  • Inline elements

    Inline elements are designed for use inside a block element. They are for applying structure to a particular word or sequence of words. Common examples of inline elements are emphasis and guilabel.

    A line of text. The word "edit" is in bold black letters. A callout arrow points to it.

    For inline elements, highlight the text and then use the Element Context Menu to add the element.

Add structure elements

For most of the commonly-used elements, Paligo's Edit and Insert tabs have toolbar options for adding the structure. For example, there are toolbar options for adding a new paragraph, a numbered list, a bullet list, and a procedure, among others. This makes it easier for you to add the structure.

Two images. One is of the Edit menu and its toolbar options. The other is of the Insert menu and its toolbar options

You can also use the Element Context Menu to add individual elements for the structure.

Element context menu. It has a search and a list of elements that are valid at the current cursor position.

Complying with DocBook rules

When you add structure elements, you need to comply with the Docbook rules. For the most part, Paligo will guide you by only allowing you to insert elements where they are valid. If you want to add an element but Paligo won't let you, it is likely because the cursor position is incorrect. The most common reason is that the cursor is still inside the previous element or it is outside of the parent structure, for example, the cursor is outside of a procedure and you want to add a step.

Close up of Element Context Menu's search. The user has searched for the step element but the search returns no results. This is because the step element is not valid at the current cursor position.

Paligo will not allow the user to add a step element at the current position. It shows "Nothing found ..." in the search for step. This is because the current cursor position is outside a procedure and steps are only valid inside a procedure.