[ 
https://issues.apache.org/jira/browse/PIVOT-623?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13044941#comment-13044941
 ] 

Greg Brown commented on PIVOT-623:
----------------------------------

Makes sense. What confused me was how this might be an alternative to the 
ellipsis style. If ellipses were supported, text would never wrap - it would 
always be truncated with a trailing "...". 

What you are proposing is a means for breaking on non-whitespace characters, 
which I can definitely see the value of. TextArea currently tries to break on 
whitespace first, but failing that, will break on any character. Should Label 
behave the same way? Alternatively, maybe it could break on (isWhitespace() | 
Character.DASH_PUNCTUATION | Character.CONNECTOR_PUNCTUATION).

What do you think?


> ellipsis style on labels
> ------------------------
>
>                 Key: PIVOT-623
>                 URL: https://issues.apache.org/jira/browse/PIVOT-623
>             Project: Pivot
>          Issue Type: Wish
>          Components: wtk, wtk-terra
>            Reporter: Sandro Martini
>            Assignee: Sandro Martini
>            Priority: Minor
>             Fix For: 2.1
>
>         Attachments: label.diff
>
>
> Add an ellipsis style on labels (default off), to trim the drawn label if 
> it's too long in respect of the space assigned.
> Depending on the chosen style, ellipsis chars could go at end of the label, 
> at center, at start, etc ... 
> Could be useful in some cases to have also "strange" behaviors, like for URLs 
> or file paths where for example could be useful to trim some parts of the 
> string but near the end of the path, but keeping the filename part full (if 
> possible).
> Verify if enable user defined behaviors also (for example giving in a 
> sub-style attribute the full classname of a custom implementation, but maybe 
> this could be too complex or not in line with other parts in Pivot.
> Verify if add also a sub-style attribute to set a different char to use for 
> the ellipsis (instead of the default "...").

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

Reply via email to