Apache OpenOffice (AOO) Bugzilla – Issue 118050
Bad refresh and bad height of formula with some operators
Last modified: 2013-01-29 21:43:15 UTC
Symbols widetilde and widehat don't update the height of formula properly. So the symbols are truncated (on ubuntu 9.10) This problem doesn't occur on WindowsXP/OOo3.4 beta1 To see the problem, run this macro step by step and read the comments. sub badHeight param=ThisComponent.createInstance("com.sun.star.document.Settings") param.MathBaselineAlignment=true obj=ThisComponent.CreateInstance("com.sun.star.text.TextEmbeddedObject") obj.CLSID="078B7ABA-54FC-457F-8551-6147e776a997" obj.AnchorType=com.sun.star.text.TextContentAnchorType.AS_CHARACTER oViewCursor = ThisComponent.getCurrentController().getViewCursor() oTextCursor=oViewCursor.Text.createTextCursorByRange(oViewCursor) oTextCursor.Text.insertString(oTextCursor,"a formula : ",false) oTextCursor.Text.insertTextContent(oTextCursor, obj, true) obj.Model.leftMargin=0 obj.Model.rightMargin=0 obj.Model.bottomMargin=0 obj.Model.topMargin=0 obj.Model.formula="widetilde{ABC}" 'good alignment but has not the good height (hat is truncated). obj.Model.topMargin=100 'Now good height but bad alignment because of bug 118043. obj.Model.formula="widehat{ABC}" 'no refresh of formula obj.Model.setmodified(TRUE) 'no refresh despite setmodified(True) obj.Model.topMargin=0 ' now good refresh of formula but not the good height, tilde is truncated. Good alignment. obj.Model.formula="widevec{AB}" 'good refresh of formula without changing the top or bottom margins. Good height. Good alignment. end sub
I'm have only Windows, so I cannot test it, but in my macros I use oXCOEO = oEmbeddedObject.ExtendedControlOverEmbeddedObject oXCOEO.update()
(In reply to comment #1) > I'm have only Windows, so I cannot test it, but in my macros I use > oXCOEO = oEmbeddedObject.ExtendedControlOverEmbeddedObject > oXCOEO.update() it's OK for refresh on ubuntu with : obj.Model.formula="widehat{ABC}" 'no refresh of formula obj.ExtendedControlOverEmbeddedObject.update() 'refresh the formula Thanks. But formulae still have bad height.
the bug is still there (AOO 3.4) Run this macro step by step in a blank writer document to see the problem : sub badHeight param=ThisComponent.createInstance("com.sun.star.document.Settings") param.MathBaselineAlignment=true obj=ThisComponent.CreateInstance("com.sun.star.text.TextEmbeddedObject") obj.CLSID="078B7ABA-54FC-457F-8551-6147e776a997" obj.AnchorType=com.sun.star.text.TextContentAnchorType.AS_CHARACTER oViewCursor = ThisComponent.getCurrentController().getViewCursor() oTextCursor=oViewCursor.Text.createTextCursorByRange(oViewCursor) oTextCursor.Text.insertString(oTextCursor,"a formula : ",false) oTextCursor.Text.insertTextContent(oTextCursor, obj, true) obj.Model.leftMargin=0 obj.Model.rightMargin=0 obj.Model.bottomMargin=0 obj.Model.topMargin=0 obj.Model.formula="widetilde{ABC}" 'bad refresh of formula obj.ExtendedControlOverEmbeddedObject.update() 'good refresh, good alignment but has not the good height (tilde is truncated). obj.Model.formula="widehat{ABC}" obj.ExtendedControlOverEmbeddedObject.update() ' not the good height, hat is truncated. Good alignment. obj.Model.formula="widevec{AB}" 'good refresh of formula. Good height. Good alignment. end sub
getting rid of value "enhancement" for field "severity". For enhancement the field "issue type" shall be used.