lualatexja-preset, baselineshift has no effect when used in LibreOffice TexMath

14 views Asked by At

I use TexMath and laulatexja-preset to insert more complex pieces of text in LibreOffice writer. In itself this works well but the only drawback is that in TexMath the option \ltjsetparameter{yjabaselineshift=0pt} has no effect. In TexStudio the following code gives this (correct) result:

\documentclass{article}
\usepackage{amsmath,amsthm, amsfonts,amssymb}

\usepackage{mathtools,array,booktabs} 
\usepackage[noto,fontspec,match]{luatexja-preset}
\usepackage{cancel}
\usepackage{tcolorbox}
\tcbuselibrary{theorems}
\usepackage[]{mdframed}
\usepackage[sfdefault]{noto}
\ltjsetparameter{yjabaselineshift=0pt}
\renewcommand*\familydefault{\sfdefault}


\usepackage{fontspec}
\usepackage{lualatex-math}

\begin{document}
    \sffamily
    \begin{equation*}
        \tcboxmath[size=small, colback=white, sharp corners=all]{
            \text{い-adj(\sim}\cancel{\text{い}})\to\text{\sim}\text{さ}\\ 
        } 
    \end{equation*}
\end{document}

enter image description here

In LO Writer, the same code gives this result

enter image description here

As you can see, the Japanese characters do not align with the other characters. Changing the value for yjabaselineshift has no effect in Writer.

Some time ago I asked in the LibreOffice forums if someone knew how to fix this but I didn't get answer.

I would appreciate any help from this forum.

0

There are 0 answers