QPR Knowledge Base 2017.1

Text Box Properties for Model Elements Dialog

Text Box Properties for Model Elements Dialog

Previous topic Next topic No directory for this topic  

Text Box Properties for Model Elements Dialog

Previous topic Next topic Topic directory requires JavaScript Mail us feedback on this topic!  

This dialog is accessible through the graphical properties dialogs of different model elements. In this dialog you can define the settings for a text box (e.g. name, description or measure value fields) inside a model element. This allows perfect customization of the appearance of the diagram. This dialog contains two tabs and the configurable settings are described below.

 

Shown attribute

This section is visible above the regular sections only when adding a new text field to be shown. Select the shown attribute from the drop-down menu.  You can choose to show Name, Description, Owner, Icon container, Diagram contents, Instance icon, Number of instances, Related element name or any custom attribute types that have been defined for the element or a related element. Note that for an "All element types" relation custom attribute, only the value can be shown.

 

If the "Instance icon" option is selected, an icon is drawn if more than one instance of the element exists in the model. If the "Number of instances" option is selected, the number of element instances the model holds is shown.

 

 

Size and Position Tab

The following settings are available in the Size and Position tab:

 

Position

The fields define the margin between the corresponding borders and the text box in pixels.

 

Size

This field allows you to define the width and height of the text box in pixels.

 

Behavior

This field allows you to define how the text box behaves. The following options are available:

 

Resize with element

When the model element is resized, the text box is resized relatively with the model element.

Do not resize with element

When the model element is resized, the text box remains anchored to the top left corner and keeps its original size even if the model element becomes smaller than the text box.

Left band

The text box appears in the left band. Note that selecting this option toggles the "Vertical orientation" option on by default.

Right band

The text box appears in the right band. Note that selecting this option toggles the "Vertical orientation" option on by default.

Top band

The text box appears in the top band.

Bottom band

The text box appears in the bottom band.

Custom resize

With this option you can customize the size in the Width and Height fields on the Size section.

 

Band Properties

This field allows you to define the band properties. The options are:

 

Show multiple values as separate bands

When selected, borders are drawn around each separate item inside the band.

Resize band with content

When selected, the height or the width of the band item is adjusted automatically based on the content. For horizontal bands, the height is adjusted, and for vertical bands, the width is adjusted.

Resize shape with band

When selected, the shape of the element is resized according to the band. The horizontal band will resize the height and the vertical band will resize the width. If the shape has a vertical band with this property enabled, it cannot have horizontal band with this shape enabled and vice versa.

Show empty band

When selected, the band is still drawn even though it doesn't have any values.

 

Width

This field allows you to define how the width of the text box behaves when the model element is resized. Select the Do not resize option to have the text box retain its width even if the element symbol becomes narrower than the text box. Select the Resize with element option to have the text box change its width according to the anchoring settings when the element is resized. The following anchoring settings are available:

Width

The text box keeps its relative width when the element is resized

Left

Distance to the left border of the element remains always the same.

Right

Distance to the right border of the element remains always the same.

 

Height

This field allows you to define how the height of the text box behaves when the model element is resized. Select the Do not resize option to have the text box retain its height even if the element symbol becomes smaller than the text box. Select the Resize with element option to have the text box change its height according to the anchoring settings when the element is resized. The following anchoring settings are available:

Height

The text box keeps its relative height when the element is resized

Top

Distance to the top border of the element remains always the same.

Bottom

Distance to the bottom border of the element remains always the same.

 

 

Properties Tab

The following settings are available in the Properties tab:

 

Diagram content properties

This is visible only if Diagram contents is selected as the shown attribute. If you want to enable collapsing of the diagram contents in the diagram view, select the option "Can be collapsed". If this option is selected, a [+] or [-] symbol is shown inside the diagram content element. Clicking the [+] symbol shows the diagram contents whereas clicking the [-] symbol hides the diagram contents. To enable easier scrolling of the diagram contents, select the option "Show scrollbars". Then scrollbars are used when viewing the diagram in the diagram view if the content of the diagram does not completely fit inside the element.

 

Properties

Here you can modify the orientation and alignment of text. If you want to change the text orientation to vertical, select the "Vertical orientation" option. In the text alignment fields you can use the drop-down menus to define how the text is aligned horizontally and vertically (this selection is not available if the shown attribute is Icon container or Diagram contents). To select how the text is aligned horizontally, select left, center, or right from the drop-down menu in the Horizontal field. To select how the text is aligned vertically, select top, middle, or bottom from the drop-down menu in the Vertical field. The Font button opens a menu where you can define the font and its properties.

 

Appearance

For attributes such as name, description and owner, or for custom attribute types for which you are not using an image, you can define borders to be drawn around the attribute by selecting the option "Draw border".

 

Select the "Clip to shape" option to prevent the text box from exceeding the symbol area. This option allows e.g. rounded corners for the bottom band in an element with rounded corners.

 

The Graphical Properties button opens the Graphical Properties Dialog where you can control the appearance of the text.

 

Value format

For custom attributes of the enumerated type, you can select the enumerated value to be shown as an image in the diagram view by selecting the "Show enumerated value as image" option. To enable this, the image has to be defined in the properties of the enumerated attribute value (see Creating and Modifying Custom Attribute Types). If there are multiple enumerated attributes in the band, the "Show enumerated value as image" setting affects them all.

 

If you selected the enumerated value to be shown as an image, you can also define that the image is shown within an icon container by selecting the "Show image in icon container" option. Then if there are several enumerated values which are defined to be shown as images, they are all shown within the icon container side by side. Thus, by using the icon container, you do not have to define the position for each value separately, you can only define the position of the icon container which will then display all the images in an easily organized manner.

 

For relation attribute values you can select various display options:

Show value as name: Displays the name(s) of the related item(s)

Show value as icon: Element type icon(s) of the related item(s) is shown

Show value as shape: Element symbol(s) of the related item(s) is shown. Select also the "Maintain aspect ratio" option to maintain the symbol's aspect ratio regardless of the shape of the text box. Note that the shape used here is the actual symbol of the element, which can be different from the default element type symbol.