diff options
author | dante <dante19031999@gmail.com> | 2021-08-08 22:48:50 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2021-08-09 09:28:47 +0200 |
commit | 6daf48b50e1ff3bdd6a9f948c3e267e76b8a89d3 (patch) | |
tree | 0834cb96fdbfa538443096c701ced0095b7678ad /starmath | |
parent | 6d90916793ddd12dc2eade8fc1bac907dde07326 (diff) |
Corrections to starmath mathml definitions
Change-Id: I6f545ced857190ed4b0f4090c0d47611ff475b57
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/120183
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'starmath')
-rw-r--r-- | starmath/inc/mathml/def.hxx | 16 | ||||
-rw-r--r-- | starmath/source/mathml/attribute.cxx | 2 |
2 files changed, 5 insertions, 13 deletions
diff --git a/starmath/inc/mathml/def.hxx b/starmath/inc/mathml/def.hxx index 2db1612b4f0d..52cf70206b2f 100644 --- a/starmath/inc/mathml/def.hxx +++ b/starmath/inc/mathml/def.hxx @@ -30,10 +30,11 @@ enum class SmLengthUnit : uint_fast8_t MlPx, MlIn, MlCm, - MlMM, + MlMm, MlPt, MlPc, - MlP // Percent + MlP, // Percent + MlM // Multiplier }; struct SmLengthValue @@ -125,7 +126,7 @@ enum class SmMlAttributeValueFence : uint_fast8_t enum class SmMlAttributeValueHref : uint_fast8_t { NMlEmpty = 0x00, - NMlValie = 0x01 + NMlValid = 0x01 }; enum class SmMlAttributeValueLspace : uint_fast8_t @@ -164,7 +165,7 @@ enum class SmMlAttributeValueMathvariant : uint_fast16_t bold_fraktur = 0x001 | 0x010, bold_script = 0x001 | 0x008, bold_sans_serif = 0x001 | 0x020, - sans_serif_italic = 0x001 | 0x002 | 0x20, + sans_serif_italic = 0x002 | 0x20, sans_serif_bold_italic = 0x001 | 0x002 | 0x020, // Non english initial = 0x080, @@ -179,12 +180,6 @@ enum class SmMlAttributeValueMaxsize : uint_fast8_t MlFinite = 0x01 }; -enum class SmMlAttributeValueMinsize : uint_fast8_t -{ - MlInfinity = 0x00, - MlFinite = 0x01 -}; - /* * Specifies whether attached under- and overscripts move to sub- and superscript positions when displaystyle is false. * Source: https://developer.mozilla.org/en-US/docs/Web/MathML/Element/mo @@ -282,7 +277,6 @@ struct SmMlMaxsize struct SmMlMinsize { - SmMlAttributeValueMinsize m_aMinsize; SmLengthValue m_aLengthValue; }; diff --git a/starmath/source/mathml/attribute.cxx b/starmath/source/mathml/attribute.cxx index 754f3604a7a3..da7668417327 100644 --- a/starmath/source/mathml/attribute.cxx +++ b/starmath/source/mathml/attribute.cxx @@ -94,7 +94,6 @@ void SmMlAttribute::setDefaultAttributeValue() m_aAttributeValue.m_aMaxsize.m_aLengthValue.m_aOriginalText = new OUString(u"10000%"); break; case SmMlAttributeValueType::MlMinsize: - m_aAttributeValue.m_aMinsize.m_aMinsize = SmMlAttributeValueMinsize::MlInfinity; m_aAttributeValue.m_aMinsize.m_aLengthValue.m_aLengthUnit = SmLengthUnit::MlP; m_aAttributeValue.m_aMinsize.m_aLengthValue.m_aLengthValue = 1; m_aAttributeValue.m_aMinsize.m_aLengthValue.m_aOriginalText = new OUString(u"1%"); @@ -393,7 +392,6 @@ void SmMlAttribute::setMlMaxsize(const SmMlMaxsize* aMaxsize) void SmMlAttribute::setMlMinsize(const SmMlMinsize* aMinsize) { clearPreviousAttributeValue(); - m_aAttributeValue.m_aMinsize.m_aMinsize = aMinsize->m_aMinsize; m_aAttributeValue.m_aMinsize.m_aLengthValue.m_aLengthUnit = aMinsize->m_aLengthValue.m_aLengthUnit; m_aAttributeValue.m_aMinsize.m_aLengthValue.m_aLengthValue |