« Back

Text field with limited amount of characters, but extendeded in notebook

Combination View Flat View Tree View
Threads [ Previous | Next ]
toggle
Text field with limited amount of characters, but extendeded in notebook
community graphrep attrrep documentation
Answer
3/27/14 11:41 AM
Is it possible to build a standard text field at an object type, which only allows for a limited
amount of characters while modeling, however when opening the Notebook (by left click) offers
an extended amount of space?

RE: Text field with limited amount of characters, but extendeded in noteboo
Answer
8/27/13 1:29 PM as a reply to Endrju S. & Sobhi A..
Yes this is possible in ADOxx. You can define a LONGSTRING attribute for the notebook and display only a limited number of characters in the notation implementation (i.e. GRAPHREP).
The command ATTR is used to display attribute values in the GRAPHREP. The parameter "w:" of the command defines the horizontal alignment of the attribute (left, right, center) and the maximum length of the text. The parameter "h": defined the vertical alignment of the text as well as the text height. The parameter "line-break:" defines the rules for breaking the text up into lines.
The example below defines an attribute "Description" of type LONGSTRING and breaks the text up on the representation of the object.
1
2GRAPHREP
3SHADOW off
4FILL color:lightblue
5RECTANGLE x:-2cm y:-1cm w:4cm h:2cm
6ATTR "Description" line-break: words x:-2cm y:1.5cm w:l:4cm h:b:10pt

RE: Text field with limited amount of characters, but extendeded in noteboo
Answer
3/8/14 6:34 PM as a reply to Wilfrid Utz.
Thanks very much Wilfrid. We realized the requirement with your help.
It was relevant for "Comment" / "Constraint" fields. The main attribute of those concepts can be formulated in natural language. So, within the model, the Comments/Constraints are being cut, but within the notebook, the whole text is displayed and can be edited.

Enclosed you can see the first test.
Attachment

Attachments: Comment.PNG (6.3k)