bugpyFormex - Bugs: bug #43954, drawText does not support newlines

 
 

bug #43954: drawText does not support newlines

Submitter:  Benedict Verhegghe <bverheg>
Submitted:  Thu 08 Jan 2015 04:46:31 PM UTC
   
 
Category:  Rendering Severity:  4 - Important
Item Group:  Functionality error Status:  Fixed
Privacy:  Public Assigned to:  bverheg
Open/Closed:  Closed
* Mandatory Fields

Add a New Comment Rich Markup
   

Sun 22 Feb 2015 03:32:44 PM UTC, comment #4: 

I think the issue is fixed in d46aafb.

Please test and close if ok.

Benedict Verhegghe <bverheg>
Group administrator
Sun 22 Feb 2015 03:10:19 PM UTC, comment #3: 

No, we should not revert, we should fix it.

a4bea54 already fixes the exception, by testing length of text[0] instead of text. Now it seems that only alignment is wrong. I think because of the grid: we should make that identical to the
old one in case of multidimensional pos. I think we should not consider the possibility of multiline text in TextArray.


Benedict Verhegghe <bverheg>
Group administrator
Sun 22 Feb 2015 02:01:33 PM UTC, comment #2: 

I reopened this bug as the changes in the commit broke the opengl.textext Text and TextArray, so now eg drawNubers does not work anymore (try to run the Curves example).
I tried to figure out how to fix it but there is a matrioska of calls in which I got lost.

Some tips for the fixing
1 Text split with '/n' , Textarray concatenate strings with ''
2 one problem is in the multiplexing of pos in TextArray, eg the when using drawNumbers, the numbers are converted to strings , with different lengths (eg '1' , '1000') this will give lengths of variable nc which is used for the multiplexing, so variable pos will be will be multiplexed with n=1 for numbers 1-9, n=2 for numbers 10-99, n= 3 for 100-999 etc.

Shall we revert the commit before a soultion is found. This change broke too many things

francesco <francio>
Group Member
Tue 17 Feb 2015 05:48:07 PM UTC, comment #1: 

Fixed in e01cbc8

Benedict Verhegghe <bverheg>
Group administrator
Thu 08 Jan 2015 04:46:31 PM UTC, original submission:  

The drawText function in the GL2 engine does not support newlines in the text (it was supported in the GL1 engine).
See the RotoTranslate example.

Benedict Verhegghe <bverheg>
Group administrator

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach Files:
   
   
Comment:
   

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by francio (Posted a comment)
  • -email is unavailable- added by bverheg (Submitted the item)
  •  

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

    Only logged-in users can vote.

     

    Follow 9 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2015-02-24 bverheg StatusWorks For Me Fixed
        Open/ClosedOpen Closed
    2015-02-22 bverheg StatusIn Progress Works For Me
    2015-02-22 bverheg StatusNone In Progress
    2015-02-22 francio Severity3 - Normal 4 - Important
        StatusFixed None
        Open/ClosedClosed Open
    2015-02-17 bverheg StatusNone Fixed
        Open/ClosedOpen Closed

    Back to the top

    Powered by Savane 3.13-aa77.
    Corresponding source code