Input required -- font selection in the Math component

Attention 'Math' users! LibreOffice is very wonderful, but there are a few niggles with the Math editor, which I wanted to list here:

  * There is currently no way to change the font used for Greek letters
    in LibreOffice. Has this bothered you at all?
  * Did you notice that the default OpenSymbol font does quite a bad job
    with some expressions, such as {{1 over %alpha} + {1 over {%alpha +
    1}}} ?
  * Did you notice that the default for LibreOffice is now to have
    lower-case Greek letters in non-italics, even though basically every
    academic publication you'll ever see has lower-case greek letters in
    italics, and this can only be changed to 'normal' behaviour using a
    hidden 'advanced' setting?
  * Did you notice that if you set the default Math font size in Writer,
    it also changes in Impress? One size fits all! It would be great if
    the size setting were specific to the context in which the Math is
    being inserted.
  * Did you notice that sometimes you can over-type text on top of a
    Formula by typing F2 when a Formula is selected in Impress?

I reported a bug in relation to the first of these at the link below. I was asked there to raise the issue here on the users' list, so that community support for the related changes could be determined.
https://bugs.documentfoundation.org/show_bug.cgi?id=67152

Many of the above issues could be fixed by implementing a proper 'style' system for Math objects, which currently doesn't seem to exist in LibreOffice.

If you have a point of view on this stuff, or ideas on how it should work, please add a note to the above bug, and help to let the developers know what issues are niggling you.

Cheers
JP

Hi John,

John Pye schrieb:

Attention 'Math' users! LibreOffice is very wonderful, but there are a
few niggles

Yes.

  with the Math editor, which I wanted to list here:

* There is currently no way to change the font used for Greek letters
   in LibreOffice. Has this bothered you at all?

No. But if you like a different one, create an own symbol set. The advantage of OpenSymbol is, that all users of LibreOffice have got it. If you use a different font, the formula might look different on other PCs.

* Did you notice that the default OpenSymbol font does quite a bad job
   with some expressions, such as {{1 over %alpha} + {1 over {%alpha +
   1}}} ?

Do you have got the newest version? It should be 102.10.

In general the problem is the rendering engine, which is not able to use special features. In case of 1 over %alpha it is a bug, [https://bugs.documentfoundation.org/show_bug.cgi?id=48965] (and duplicates). Workaround 1 over {%alpha`} or 1 over {{}%alpha}

* Did you notice that the default for LibreOffice is now to have
   lower-case Greek letters in non-italics, even though basically every
   academic publication you'll ever see has lower-case greek letters in
   italics, and this can only be changed to 'normal' behaviour using a
   hidden 'advanced' setting?

Now there are two sets, one upright and one italic, so that you can write %beta and %ibeta and %BETA and %iBETA.

There exists an advanced setting GreekCharStyle with values 0,1 or 2.
Value 0 means: Write Greek symbols literal, those from set "Greek" upright, those from set "iGreek" in italic.
Value 1 means: Write all Greek symbols in italic
Value 2 means: Write large characters of set "Greek" upright and all others italic.
You need to restart LibreOffice after changing the value.

You can of cause force upright always with command nitalic, and force italic with command italic.

* Did you notice that if you set the default Math font size in Writer,
   it also changes in Impress? One size fits all!

Math is a separate module. It is always inserted as OLE.

  It would be great if

   the size setting were specific to the context in which the Math is
   being inserted.

That is not possible, because the default configuration does not know, in which context it will be used. There exists only one default configuration. I use macros to adapt the formula in Writer or Draw/Impress, or I change the size in the first formula I write and make that the new default.

It might be possible, that in case, the formula editor is called in-place in Writer or Draw/Impress, that the context information can be used instead of the default.

* Did you notice that sometimes you can over-type text on top of a
   Formula by typing F2 when a Formula is selected in Impress?

That is the text-box, which belongs to every OLE-object and every other object in Draw/Impress. You can use it to write a caption to the formula, which moves together with the formula. It does not belong to the formula itself but to the OLE representation of the formula. The position of this text is set in Format > Object and Shape > Text.

I reported a bug in relation to the first of these at the link below. I
was asked there to raise the issue here on the users' list, so that
community support for the related changes could be determined.
https://bugs.documentfoundation.org/show_bug.cgi?id=67152

Many of the above issues could be fixed by implementing a proper 'style'
system for Math objects, which currently doesn't seem to exist in
LibreOffice.

Math formulas are essentially MathML 2.0 [https://www.w3.org/TR/MathML2/]. ODF uses the original MathML 2.0 definition, but only a subset is yet implemented in LibreOffice. The same kind "style", that exists for paragraphs in Writer or drawing objects in Draw/Impress, are not possible inside the Math formula. You can only "style" the OLE-object, e.g. set a background or border. For MathML itself, CSS styling would be possible.

If you have a point of view on this stuff, or ideas on how it should
work, please add a note to the above bug, and help to let the developers
know what issues are niggling you.

My wish is, that LibreOffice becomes a very good MathML renderer and a good MathML editor. And that LibreOffice gets rid of the propriety "StarMath 5.0".

Kind regards
Regina

Hi Regina

* There is currently no way to change the font used for Greek letters
   in LibreOffice. Has this bothered you at all?

No. But if you like a different one, create an own symbol set. The advantage of OpenSymbol is, that all users of LibreOffice have got it. If you use a different font, the formula might look different on other PCs.

This is very slow and tedious. It would be really great if the default font could be changed for all symbols. Of course, the intention is for the formula to look different :slight_smile:

* Did you notice that the default OpenSymbol font does quite a bad job
   with some expressions, such as {{1 over %alpha} + {1 over {%alpha +
   1}}} ?

Do you have got the newest version? It should be 102.10.

Interesting. I have version 102.7, which is what I get from the Ubuntu 16.04 LibreOffice 5.2 PPA, deb-src http://ppa.launchpad.net/libreoffice/libreoffice-5-2/ubuntu xenial main

dpkg -l "*opensymbol*"

ii fonts-opensymbol 2:102.7+LibO5.2.5~rc1-0ubun

In general the problem is the rendering engine, which is not able to use special features. In case of 1 over %alpha it is a bug, [https://bugs.documentfoundation.org/show_bug.cgi?id=48965] (and duplicates). Workaround 1 over {%alpha`} or 1 over {{}%alpha}

I disagree. The problem is with the font. I have added another image to that bug report to clarify.

* Did you notice that the default for LibreOffice is now to have
   lower-case Greek letters in non-italics, even though basically every
   academic publication you'll ever see has lower-case greek letters in
   italics, and this can only be changed to 'normal' behaviour using a
   hidden 'advanced' setting?

Now there are two sets, one upright and one italic, so that you can write %beta and %ibeta and %BETA and %iBETA.

There exists an advanced setting GreekCharStyle with values 0,1 or 2.
Value 0 means: Write Greek symbols literal, those from set "Greek" upright, those from set "iGreek" in italic.
Value 1 means: Write all Greek symbols in italic
Value 2 means: Write large characters of set "Greek" upright and all others italic.
You need to restart LibreOffice after changing the value.

You can of cause force upright always with command nitalic, and force italic with command italic.

The default should be setting 2, consistent with normal publishing practice. But on new installs, last time I checked, the default was still 0 with is a poor choice for the default.

* Did you notice that if you set the default Math font size in Writer,
   it also changes in Impress? One size fits all!

Math is a separate module. It is always inserted as OLE.

It would be great if

   the size setting were specific to the context in which the Math is
   being inserted.

That is not possible, because the default configuration does not know, in which context it will be used. There exists only one default configuration. I use macros to adapt the formula in Writer or Draw/Impress, or I change the size in the first formula I write and make that the new default.

It might be possible, that in case, the formula editor is called in-place in Writer or Draw/Impress, that the context information can be used instead of the default.

This is a definite design problem. The 'default' size should not have to be changed every time one switches between Writer and Draw/Impress. This problem has been addressed quite nicely in Another Office Package.

* Did you notice that sometimes you can over-type text on top of a
   Formula by typing F2 when a Formula is selected in Impress?

That is the text-box, which belongs to every OLE-object and every other object in Draw/Impress. You can use it to write a caption to the formula, which moves together with the formula. It does not belong to the formula itself but to the OLE representation of the formula. The position of this text is set in Format > Object and Shape > Text.

This is a bad feature for something like a Math object, which inherently also contains text, in my view. I think this feature of being able to overlay text should be suppressed for most embdedded objects, and it will cause confusion to the majority of users.

Cheers
JP

John Pye wrote

* Did you notice that the default for LibreOffice is now to have
   lower-case Greek letters in non-italics, even though basically every
   academic publication you'll ever see has lower-case greek letters in
   italics, and this can only be changed to 'normal' behaviour using a
   hidden 'advanced' setting?

Now there are two sets, one upright and one italic, so that you can
write %beta and %ibeta and %BETA and %iBETA.

There exists an advanced setting GreekCharStyle with values 0,1 or 2.
Value 0 means: Write Greek symbols literal, those from set "Greek"
upright, those from set "iGreek" in italic.
Value 1 means: Write all Greek symbols in italic
Value 2 means: Write large characters of set "Greek" upright and all
others italic.
You need to restart LibreOffice after changing the value.

You can of cause force upright always with command nitalic, and force
italic with command italic.

The default should be setting 2, consistent with normal publishing
practice. But on new installs, last time I checked, the default was
still 0 with is a poor choice for the default.

Mode 2 for italic lower case greek symbols has been set as the default,
tdf#105483 <https://bugs.documentfoundation.org/show_bug.cgi?id=105483>
was resolved for 5.4 with
http://cgit.freedesktop.org/libreoffice/core/commit/?id=68155a68578a0f4066c1c566c2d378bbae05c216
but the patch to use value 2 by default was rejected for backport to the 5.3
release.

Until moving to a 5.4 build, users so inclined can set the "GreekCharStyle"
stanza with a simple search/edit in expert configuration.