Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 408959

Summary: [TSD][Client] Should return the real text width in case of provided wrapWidth and the text fits into a single line
Product: [RT] RAP Reporter: Ivan Furnadjiev <ivan>
Component: RWTAssignee: Project Inbox <rap-inbox>
Status: RESOLVED FIXED QA Contact:
Severity: enhancement    
Priority: P3    
Version: unspecified   
Target Milestone: 2.2 M1   
Hardware: All   
OS: All   
Whiteboard:

Description Ivan Furnadjiev CLA 2013-05-24 07:10:08 EDT
Currently, when the text fits into a single line and wrap width is provided (wrap width > real text width) client sends to the server the same wrap width as text width instead of real text width (see FontSizeCalculation.js#computeTextDimensions). In some cases this could lead to endless requests loop. 
One possible solution could be to have two measurement div one inside of another. The wrap width will be set on the outer div and the measured text on the inner div with width/height set to auto. In this case we will always have the real text dimensions from the inner div.
Comment 1 Ivan Furnadjiev CLA 2013-06-20 05:57:30 EDT
Fixed in master as suggested with commit aa339eace7e398014cfa39578c2d8031a5edb1b6.