Apache OpenOffice (AOO) Bugzilla – Issue 119607
[From Symphony] Text font spacing in comments doesn't expand/condense by the expected value
Last modified: 2017-05-20 10:31:57 UTC
Created attachment 77824 [details] wrong font spacing in commont Steps: 1. Open the attached docx files. 2. Check text font spacing in the comments. Defect: Their font spacing in sym20 don't expand/condense to the value set in office2010.
Created attachment 77825 [details] screenshot of wrong font spacing in comment
confirmed,change its status
Created attachment 79175 [details] patch for font spacing in comments for docx The font spacing in comments is calculated in different way from that out of comments. Thus, the patch includes below changes: 1. add related token id in model.xml to ensure comments will be detected 2. add a flag to indicate whether the font spacing is for comments or not.
This solution isn't good enough. Working on a better one. (In reply to comment #3) > Created attachment 79175 [details] > patch for font spacing in comments for docx > > The font spacing in comments is calculated in different way from that out of > comments. > > Thus, the patch includes below changes: > 1. add related token id in model.xml to ensure comments will be detected > 2. add a flag to indicate whether the font spacing is for comments or not.
(In reply to comment #4) > This solution isn't good enough. Working on a better one. > > (In reply to comment #3) > > Created attachment 79175 [details] > > patch for font spacing in comments for docx > > > > The font spacing in comments is calculated in different way from that out of > > comments. > > > > Thus, the patch includes below changes: > > 1. add related token id in model.xml to ensure comments will be detected > > 2. add a flag to indicate whether the font spacing is for comments or not. Yes, aggree. It's not so good to justify the properties by add the special flag for detect of in-comments or not, because for docx import, the import filter work as state machine, and the state will be chaos if we add more and more special flag. I think better way is to separate the properties for different use scenario by definition through parent-child relationship in OOXML.
Thanks for your comments. I tried to work out a solution by tracking tokens' parent and change the spacing to use different token from that in document.xml, however, it doesn't work so well in this case. In model.xml, it will be necessary to re-write the whole comments part since it shares same structure with that in document. In order to use a different token for spacing in comments, I don't think it's worthwhile the effort. But I do agree with you on that it's bad to add some non-existing token id. In new patch, I move the flag into DomainMapper_Impl, and set it to true in PushAnnotation and to false in PopAnnotation. (In reply to comment #5) > (In reply to comment #4) > > This solution isn't good enough. Working on a better one. > > > > (In reply to comment #3) > > > Created attachment 79175 [details] > > > patch for font spacing in comments for docx > > > > > > The font spacing in comments is calculated in different way from that out of > > > comments. > > > > > > Thus, the patch includes below changes: > > > 1. add related token id in model.xml to ensure comments will be detected > > > 2. add a flag to indicate whether the font spacing is for comments or not. > > Yes, aggree. > It's not so good to justify the properties by add the special flag for > detect of in-comments or not, because for docx import, the import filter > work as state machine, and the state will be chaos if we add more and more > special flag. > I think better way is to separate the properties for different use scenario > by definition through parent-child relationship in OOXML.
Created attachment 79280 [details] patch for font spacing in comments for docx The font spacing in comments is calculated in different way from that out of comments. Add related flag to ensure comments will be detected
Created attachment 79282 [details] patch for font spacing in comments for docx Re-upload new clean patch.
"zhangjf" committed SVN revision 1380481 into trunk: #i119607#, text font spacing in comments doesn't expand/condense by the expec...
Comment on attachment 79282 [details] patch for font spacing in comments for docx The patch works fine, thanks.
Committed to 3.5 trunk and change to resolved state.
verified on the build Aoo3.5_r1387482