MantisBT - ParaView
View Issue Details
0006669ParaView(No Category)public2008-03-27 18:022016-08-12 09:57
Kent Eschenberg 
Utkarsh Ayachit 
normalfeaturealways
closedmoved 
 
 
0006669: Text Justificaton Ignored in Python
In pvpython 3.2.1 the text is always left justified.
Attached file illustrates
No tags attached.
? tjusti.py (476) 2008-03-27 18:02
https://www.vtk.org/Bug/file/6370/tjusti.py
? tjusti.corrected.py (618) 2008-03-31 16:27
https://www.vtk.org/Bug/file/6378/tjusti.corrected.py
Issue History
2008-03-27 18:02Kent EschenbergNew Issue
2008-03-27 18:02Kent EschenbergFile Added: tjusti.py
2008-03-31 16:27Utkarsh AyachitFile Added: tjusti.corrected.py
2008-03-31 16:29Utkarsh AyachitStatusbacklog => @80@
2008-03-31 16:29Utkarsh AyachitResolutionopen => no change required
2008-03-31 16:29Utkarsh AyachitAssigned To => Utkarsh Ayachit
2008-03-31 16:29Utkarsh AyachitNote Added: 0010999
2008-03-31 17:15Kent EschenbergStatus@80@ => @20@
2008-03-31 17:15Kent EschenbergResolutionno change required => reopened
2008-03-31 17:15Kent EschenbergNote Added: 0011005
2008-04-01 12:01Utkarsh AyachitNote Added: 0011017
2008-04-01 12:03Utkarsh AyachitStatus@20@ => @30@
2008-04-10 17:47Ken MorelandStatus@30@ => tabled
2008-04-10 17:48Ken MorelandSeveritymajor => feature
2008-04-10 17:48Ken MorelandCategory3.4 => 3.6
2009-03-24 11:42Utkarsh AyachitCategory3.6 => 3.8
2009-05-13 13:39Utkarsh AyachitTarget Version => 3.8
2011-06-16 13:10Zack GalbreathCategory => (No Category)
2016-08-12 09:57Kitware RobotNote Added: 0037560
2016-08-12 09:57Kitware RobotStatusexpired => closed
2016-08-12 09:57Kitware RobotResolutionreopened => moved

Notes
(0010999)
Utkarsh Ayachit   
2008-03-31 16:29   
Justification comes into play only when the text has more than 1 line. tjusti.corrected.py illustrates justification on a multi-line text.
(0011005)
Kent Eschenberg   
2008-03-31 17:15   
This does not work as I would expect. Left justification is fine because both the text "box" (the area occupied by the text) as well as the text inside the box is left-justified relative to the given position. However, center justification only justifies the text within the text box - the text box is still left justified relative to the given position. I would expect the text box to also be centered on the given position.

For example, lets say I wanted to center several items around a vertical line (this is an actual case): some text, a color legend, then some more text. I know the location of the line but I don't know how wide the text will be. If center justification worked as I expected I would just set the horizontal coordinate of the text position to the location of the vertical line.

I cannot think of any real-world situation where one would want justification to work the way it is now. Perhaps there should be two justification parameters - one for the box relative to the position, and one for text within the box.

Maybe this should be changed from a bug to an enhancement request. I don't know how to do that.
(0011017)
Utkarsh Ayachit   
2008-04-01 12:01   
Note for developers:
vtkTextRepresentation is setting the "ScaledText" and "BorderAlign" property on the vtkTextActor. If both are set to 0, then the justification works as wanted. However, the rectangle shown to move the text is still position incorrectly.

May be vtkTextWidget/vtkTextRepresentation should have a mode to adjust the "anchor" point with justification.
(0037560)
Kitware Robot   
2016-08-12 09:57   
Resolving issue as `moved`.

This issue tracker is no longer used. Further discussion of this issue may take place in the current ParaView Issues page linked in the banner at the top of this page.