Apache OpenOffice (AOO) Bugzilla – Issue 80431
Auto-resized fonts of axes and data labels are exported in the original size
Last modified: 2013-02-24 21:19:44 UTC
1. Create a chart out of some numbers 2. Insert/Data Labels, Insert/Title/Main Title 3. Set "Scale Text" on (toolbar icon with the capital "A") 4. Enlarge the chart 5. Save 6. Reload, update with F9 => The fonts of the axis and data labels springs back to the small sized before the re-size of the chart. or (1-5)'. load the attached bugdoc
Created attachment 47367 [details] Bugdoc. Note that the document is incorrect, so when the bug is fixed, it will still be loaded incorrectly
setting regression keyword
The same applies to data point labels. ->IHA: weiz has evaluated this issue and found out a possible fix. But I am not sure about the implications. It looks like you know more about the code involved to judge whether it is safe to fix it this way. The reason for the bug seems to be quite simply that the code for using the reference diagram size in the chart API wrapper is commented out for axes and data points. Commenting the code back in helps to write the correct sizes into the file. ->IHA: The commented-out code was checked in with a comment referring to issue 63008. I don't know if enabling this code re-introduces this bug maybe? Also, another thing is that on loading, when the font-sizes are set via xmloff, the WrappedCharacterHeightProperty always sets a reference size. Do we really want this? As we don't support auto-scale after loading yet, we should set no reference size in this case. Or is it needed for another place? For the title and legend it works, as they use the page size, but for the diagram size it doesn't work.
Created attachment 47666 [details] Patch for fixing this issue, but with unknown side-effects
changed target and accepted
Fixed in CWS chart16. I only changed the method getReferenceSize for Axis and Labels. That is sufficient to fix this export bug. The other changes from the patch does influence import and they are to hot to be changed here for OOo 2.3.1. Furthermore some control of the reference size must happen when setting the font size, otherwise the result might be a wrong size.
->KLA, please verify in CWS chart16.
verified
seen ok in current master -> closed