Bug 46447

Summary: Applying style with big font does not update row height attributes
Product: POI Reporter: Antti Koskimäki <antti.koskimaki>
Component: HSSFAssignee: POI Developers List <dev>
Status: NEW ---    
Severity: normal    
Priority: P2    
Version: 3.5-dev   
Target Milestone: ---   
Hardware: PC   
OS: Windows XP   
Attachments: source and excel to re-produce the bug

Description Antti Koskimäki 2008-12-29 23:24:02 UTC
Created attachment 23062 [details]
source and excel to re-produce the bug

If I apply style with large font to cell, i.e. "insert large text", the resulting excel does have row tall enough to contain the text (font) but row.getHeight() still returns original height value.

This happens even after reading the excel back (so it's consistent, nothing magic there either :=)

But, after saving the resulted excel with Excel (2003) and reading THAT back to POI, the height-attributes are set to match the font, as expected.

Tested with latest r729456. Source and excels to reproduce attached.
Comment 1 Antti Koskimäki 2009-01-07 01:38:39 UTC
> resulting excel does have row tall enough to contain the text (font) but
> row.getHeight() still returns original height value.

Another case related to here; if I have cell having "wrap text" option set, and row was therefore stretched, the getHeight() returns that stretched size, even after replacing the row contents with something that fits in "single height".

I.e. the height value is not (re-)set here either.