Connector Labels (Polyline Connection) [message #1059231] |
Fri, 17 May 2013 12:18 |
|
Hi,
In one diagram I have a figure element that is the representation of a Polyline and for it I attached a label with a text. The Label is the one that you can show/hide in the diagram view by Show/Hide Connector Labels. When the text that goes to the Label becomes long, I need to make it multiple line or have it multiple line from the beginning. I tried to change the type from a Label to a Custom Figure and set the CustomAttribute textWrap to true , but not possible to see this happening the moment the Label is displayed in the Diagram Editor.
Any idea is welcome.
|
|
|
|
Re: Connector Labels (Polyline Connection) [message #1061384 is a reply to message #1060445] |
Fri, 31 May 2013 12:13 |
|
Hi Thomas,
I know that setTextWrap could do the trick. Just to make the picture more detailed:
- I have this text for the label taken from two other properties, based on the user selection of a flag. So I am extracting the text to be displayed like this:
public String getUsedGuard()
{
if(this.isRuleFromGrammar == true){if(basicGetGuardRuleName() != null)
return basicGetGuardRuleName().getRuleName();
else
return "";
}
else{
return this.getGuard();
}
}
So finally I will have a string that will populate the label. So the label is not edited directly in the view, but managed through other properties. This is why I am searching another way of forcing the label to have itself more lines and to manage the text that comes within.
|
|
|
|
Powered by
FUDForum. Page generated in 0.03075 seconds