Apache OpenOffice (AOO) Bugzilla – Full Text Issue Listing |
Summary: | Charts with empty cells change aftercopy/paste from Calc to Writer | ||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Product: | General | Reporter: | malinalda <generals_> | ||||||||||
Component: | chart | Assignee: | kla <thomas.klarhoefer> | ||||||||||
Status: | CLOSED FIXED | QA Contact: | issues@graphics <issues> | ||||||||||
Severity: | Trivial | ||||||||||||
Priority: | P3 | CC: | IngridvdM, issues, thomas.klarhoefer, weizhao | ||||||||||
Version: | 3.3.0 or older (OOo) | ||||||||||||
Target Milestone: | --- | ||||||||||||
Hardware: | All | ||||||||||||
OS: | All | ||||||||||||
Issue Type: | DEFECT | Latest Confirmation in: | --- | ||||||||||
Developer Difficulty: | --- | ||||||||||||
Issue Depends on: | |||||||||||||
Issue Blocks: | 72764 | ||||||||||||
Attachments: |
|
Description
malinalda
2008-04-22 13:47:37 UTC
Please attach a sample document Created attachment 53228 [details]
just see
Yes, from the document I can see that the empty data fields are filled with zero values. I need to replicate the way to this result. Could you please attach you ods (spreadsheet) document to this issue? When I create something similar with my own test files the empty cells will remain - and not be filled with zero's... Created attachment 53240 [details]
4x4 data sets all with the same problem. data ranges for diagrams were created manually
Thanks malinalda for the quick response. With the attached document this is reproducible. MRU->IHA: The empty cells of the spreadsheet are transferred as zero values to the Chart when it is copied into Writer. See attached ods file. On the table "Graphen" copy the first chart from Calc into Writer and see that the chart lines flow back into the origin. @weiz, please analyze where the empty values are wrongly replaced with zero *** Issue 89427 has been marked as a duplicate of this issue. *** ->iha: The patch for this issue is finished. Please let me know if you have any suggestions. Thank you! Created attachment 53833 [details]
patch_080522
@weiz, I compiled and tested the patch but the problem still exists. Did you maybe attach not the complete patch? ->iha: It's the complete patch, and it's OK in my test cases. If you use the example document "Messwerte E103.ods" to test the patch, you should click into the chart before you copy it, as the empty values are already replaced with zero in file "content.xml", so we need to rewrite the values to empty. The step above is unnecessary for the charts that new create. Ah yes great, it works fine! :-) . And its good to mention here that a special handling is needed for older documents. Cool that you found that place where the problem is caused! And the patch is absolute correct. Only there is a possibility to make the fix more elegant. Instead of setting a default value to each element of a vector after resizing it, you can use the resize method with two parameters where the second parameter is the value with which inserted elements are initialized. I have changed the code accordingly and will attach a patch. Created attachment 54249 [details]
patch2
Fixed in CWS chart27. @Thomas, please verify in CWS chart27. For all old files including the attached one it is necessary to double click the chart once before copying. Updateing the charts via F9 before copying works also. Newly created charts should behave fine directly now. seen ok in cws chart27 -> verified seen ok in current master -> closed |