You are viewing the documentation for Blueriq 17. Documentation for other versions is available in our documentation directory.

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 2 Next »

Content items

You can think of content items as a kind of sub-document. A content item contains both structure and content, just like a document. But, you cannot ‘generate’ a content item as you can a document. Content items can only be used as part of other content items or documents. In fact, reuse of content and structure is the sole purpose of a content item.

Both parts of the content item are visible in the content item editor:

  1. In the form of a tree, that shows the structure of the content items in a document.
  2. In a preview, the preview shows the content items in a document in a linear textual form.

Whenever a content node is selected in the tree, its content is highlighted in the document preview and vice versa.

The structure of a content item consists of:

  • content nodes of type text,
  • other content items or
  • content nodes of type image.

A content node can have the following properties:

  • Pre-condition, specifies under what conditions the content of the node should be displayed.
  • Repetition, specifies for which instances to display the content of the node, e.g. repeat a paragraph for all products in your application.
  • Content style, defines the layout of the content in the node, e.g. a chapter is always preceded by a page break.
  • Presentation style, defines the formatting of the content in a node, e.g. the font face, colour, etc.

Create a new content item

There are two ways to create a new content item, creating it from scratch or turn a content node into a content item. A content item is in fact a reusable content node.

To create a new content item:

  1. On the Document tab, in the document group, click the New content item icon.
  2. Or open the content item’s list view and use keyboard shortcut CTRL + N.
  3. Enter the content item’s name.
  4. Click Save or Save and close.

To turn a content node into a content item:

  1. Open a document or Content item.
  2. Select the node that you want to turn in to a Content item from the tree-view.
  3. Select Make reusable – as Content item from the shortcut menu.
  4. Click Save or Save and close.

The new content item will not be saved until you save the entire document or content item that contains this new content item.

Move a content node

  1. Select the node you want to move.
  2. On the documents tab, in the outline tools group, click one of the move icons. Or use one of the keyboard shortcuts ALT+I (up), ALT+K (down), ALT+J (left) or ALT+L (right).Or use one of the keyboard shortcuts CTRL+I (up), CTRL+K (down), CTRL+J (left) or CTRL+L (right).
  3. Or select one of the Move options from the shortcut menu. Repeat this until the node is in the desired position.

If you are not allowed to move a node to a specific location, either that specific move option will be read-only in the menu and ribbon or the not allowed icon will appear when you drag the node on such a target node.

Split the text in a content node

To split the text:

  1. Open the text in your document or content item.
  2. Select the text that you want to place in a separate node. Or position the cursor where you want to split your text.
  3. Select split text from the shortcut menu or the document tab, in the outline tools group. Or use the keyboard shortcut ALT+ENTER

You are not allowed to split reusable text items, this would affect multiple documents or content items. In these cases the “split text” option will be read-only.

Merge text from several content nodes

To merge text via the content tree:

  1. Select adjacent text content nodes in the tree.
  2. Select merge text from the shortcut menu or the document tab, in the outline tools group. Or use the keyboard shortcuts ALT+PAGE UP or ALT+PAGE DOWN.

To merge text via the content tree:

  1. Select a text content node in the tree that you want to merge with the previous or with the next text content node on the same level.
  2. Select Merge with next or Merge with previous from the shortcut menu or the document tab, in the outline tools group. Or use the keyboard shortcuts ALT+PAGE UP or ALT+PAGE DOWN.

To merge text via the text editor:

  1. Open a text in your document or content item.
    • Select Merge with previous from the document tab, in the outline tools group. Or use the keyboard shortcut ALT+PAGE UP.
    • Select Merge with next from the document tab, in the outline tools group. Or use the keyboard shortcut ALT+PAGE DOWN.

You are not allowed to merge reusable text or content items, since this would affect multiple documents or content items. In these cases the merge option will be disabled.

When you merge, be aware that properties of the top content node are preserved, while properties of the other node are lost. Any conditions and styles within the text are preserved. ‘Soft’ line breaks are inserted between previous paragraphs.

Set a condition on a content node

Click on the condition icon in the tree or in the pre-viewer. The condition editor will pop up in which the condition can be edited. The colour of the border around the condition icon indicates if the condition expression is a valid expression.

Apply a content style or presentation style to a content node

A content item can have a content style and a presentation style. These can be added to a content item in the context item tree, using a resource-centric menu or buttons on the Document Ribbon.

Insert a text item node

A (reusable) text item can be inserted as a child of a content item by dragging the text item onto the content item. A text item cannot be inserted as a child of an image.

Insert an image node

An image can be inserted as a child of a content item by dragging the image onto the content item. When an image is dragged onto an image that is a child of a content item, the current image will be replaced.

Set image width and height

The image width and height are set using the width and height text boxes on the Document Ribbon. The width and height have to be specified using a floating point number, using a period as decimal indicator. The unit is centimetres, and does not have to be specified. Neither width nor height is required. The scaling of the picture depends on the document renderer.

Documents

A document is started by creating a Blueriq Studio Document element. The contents of a document is stored in a tree of content items. Content items are the nodes in the tree that represents the document. This means that content items can contain other content items. In addition, each content item can contain text or images.

A document is shown in two ways: as a tree of content items at the left hand side, and as text on the right hand side.

The two display forms are linked: when a node is selected in the tree on the left, the text is also selected at the right. In addition, the text of the nodes “inside” the content item is also selected.

The formatting of the text in a document is done by setting content styles and presentation styles to the content items. A content style determines the type of the content item, for example Paragraph, List, or Table. The presentation style determines the sub styling, for example RightAligned, TextEmphasis, or ListBullet (for a list).

Presentation styles can also be applied to parts of the text of the content item.

Editing a document

A document is edited by manipulating the content items the document is composed of.

Tree view

The actions for editing the structure of the document have to be performed in the tree view. Actions can be chosen from the context menu (right mouse button), or by using the keyboard (see the list of keyboard shortcuts). The icon that represents the content item looks different depending on what is set on the content item:

: generic icon for a content item;

: a content item with a condition;

: a content item with a repetition;

: a content item on which a content style is set;

: a content item on which a presentation style is set;

: a content item on which a content and a presentation style is set;

: a content item on which a condition, a content style and a presentation style is set.

Edit a content item

The properties of a content item can be edited in the editor as shown below. Once a property of the content item is changed, the icon representing the content item in the tree view will change accordingly.

Repetition on a content item

A repetition can be set on a content item. This allows the content item, which might contain a sub tree, to be shown multiple times. The repetition is over the instances of one entity. The expression for the repetition is any expression that can evaluate to a set of instances. This could be:

  • The name of an entity (Car);
  • A relation path, starting with a singleton and ending with a relation name (Car FROM Person.owns_car);
  • One of the two expressions above, with a restriction added (Car WHERE Car.price < 10000).

Reusable items

Content items can be made reusable. Reusable means that the content item can be used in multiple documents, or more than once in the same document. The text part of a content item can be made reusable as well, this is called a text item. Text items can be used in multiple documents, and more than once in the same document. (Reusable) content items and text items are autonomous items, and can also be created and maintained separate from a document.

Text view

The text view allows editing individual texts within the document.

At the top, the name of the content item is shown. With the green tick mark or the red cancel button the changes to the content item can either be committed or discarded. Both buttons close the text view.

Images

An image can be used in a content item in place of a text item. The image first has to be imported into Blueriq Studio.

Use the following editor:


The Image button can be used to upload an image to Blueriq Studio. Supported file formats are: jpg, gif and bmp. .svg images are also supported (svg images do not work in IE8).

The imported image is shown in the editor:

A place holder is shown for svg images.

The presentation of the image on the page, including the width and height are specified when the image is used in a content item.

Text items

Text items are small indivisible blocks of formatted text. They are indivisible in the sense that only a whole text item is reusable, not a part of the text item. You can use a text item on pages and in documents. A text item can consist of multiple pieces of text, each of which can have a condition.

Create a new text item

To create a text item:

  1. On the Home tab, in the document group, click the New text item icon.
  2. Or activate the text item’s list view and use keyboard shortcut CTRL + N.
  3. Fill out the required fields. It is possible to set the text for each language set in the Global elements. To add text for different language than the default one, select the language just above the text area editor and click the new item button. A tab will be added to the text area for the selected language.
  4. Click Save or Save & close.

Edit text in the item

To add or edit text in a text item:

  1. Select the language tab in which you want to add text.
  2. Type your text in the text field. The lines you edit will be marked by a yellow block at the left of the text area.
the first language tab displayed in the text item editor is that of the specification language. You can change the specification language in your user profile. For more information, see user profile

Add or edit a condition in the text

You can add a condition to a part of your text, in order to display or hide this part under certain conditions.

Always consider reusability of your text item when you decide to add a condition to your text item. An alternative is to divide your text over several text items and use a content item to add your conditions. For more information on using content items, see Reusable items.

To add a condition to a text item:

  1. Select the text to which you want to apply the condition.
  2. Select the add condition button just above the text area.
  3. Enter your condition in the expression editor that appears.
  4. Click OK to save your expression.

As a result, the conditional text is highlighted and a button with the condition’s number is placed behind the highlighted text.

To edit the condition:

  1. Click the condition button just in front of the conditional text.
  2. Click Edit condition
  3. Change the condition in the expression editor.
  4. Click OK to save your changes.

To remove the condition:

  1. Click the condition icon just in front of the conditional text.
  2. Click remove condition.

Using fields in your text

In Blueriq Studio text items, you can refer to information from your domain model. You can do this by inserting fields in your text. A field can contain an expression or a reference to an attribute. On generating your document, these fields are substituted by their actual values.

To add an attribute or expression field to your text:

  1. Select the Field button just above the text area.
  2. Create an expression using the expression editor.
  3. Click OK to insert the expression.
  • No labels