musixlyr 中的换行符

musixlyr 中的换行符

musixlyr内部需要设置换行符,基本代码如下:

\documentclass[
    border={-8.1cm % Izquierda
            -7pt % Abajo
            -7.3cm % Derecha
            -3pt % Arriba
            },landscape,a1paper,10pt,class=scrartcl]{standalone}
\usepackage{musicography}
\usepackage{musixtex}
\input musixlyr
\usepackage{amsmath}
\usepackage{xcolor}
\xdefinecolor{red-undar}{RGB}{179,35,79}
\begin{document}
\begin{music}
    \resetlyrics
    \font\A=phvb8t at 6pt% added for letter type.
    \setlyrics{Jonico1}{{\color{red-undar}{Do Mayor}} {\color{red-undar}{Do Menor}}}
    \setlyrics{Dorico1}{{\color{red-undar}{Do Aumentado}} {\color{red-undar}{Do Disminuido}}}
    \setlyrics{Frigio1}{{\color{red-undar}{Do segunda suspendida}} {\color{red-undar}{Do cuarta suspendida}}}
    \setsongraise3{0.5mm}
    \setsongraise2{0.8mm}
    \setsongraise1{0.8mm}
    \hsize=20cm
    \parindent16mm
    %\setmaxinstruments{2}
    \instrumentnumber{3}
    \setstaffs1{1}
    \setstaffs2{1}
    \setstaffs3{1}
    \setclef3\treble
    \setclef2\treble
    \setclef1\treble
    \nobarnumbers
    \sepbarrules
    \nostartrule
    %\setemptybar
    \setinterstaff{1}{9}%Distancia entre sistemas del pentagrama
    \setinterstaff{2}{9}%Distancia entre sistemas del pentagrama
    \setinterstaff{3}{9}%Distancia entre sistemas del pentagrama
    \setbox\lyrstrutbox=\vbox to 1.3\Interligne{} % Distancia entre lyrics
    \resetlyrics % Se requiere reiniciar la configuración para habilitar el paso anterior
    \startextract
    \A\assignlyrics1{Frigio1}% added to place handindication
    \A\assignlyrics2{Dorico1}% added to place handindication
    \A\assignlyrics3{Jonico1}% added to place handindication
    \setdoublebar%
    \NOTEs\hsk\zw{c}\rw{d}\wh{g}&\hsk\zw{ce}\wh{^g}&\hsk\zw{ce}\wh{g}\en\bar
    %\setdoublebar
    \NOTEs\hsk\zw{c}\rw{g}\wh{f}&\hsk\zw{c}\lfl{e}\zw{e}\wh{_g}&\hsk\zw{c_e}\wh{g}\en%\bar
    \setdoubleBAR
    \nolyr
    \lyricsoff
    \endextract
\end{music}
\end{document}

当前输出如下: 当前的

期望的输出应该是: 期望

答案1

在这里,我只是使用一些堆栈,并调整边框来适应。

\documentclass[
    border={-8.1cm % Izquierda
            -4pt % Abajo
            -7.3cm % Derecha
            -3pt % Arriba
            },landscape,a1paper,10pt,class=scrartcl]{standalone}
\usepackage{musicography}
\usepackage{musixtex}
\input musixlyr
\usepackage{amsmath}
\usepackage{xcolor}
\usepackage{stackengine}
\renewcommand\stackalignment{l}
\setstackEOL{\\}
\setstackgap{L}{6pt}
\xdefinecolor{red-undar}{RGB}{179,35,79}
\begin{document}
\begin{music}
    \resetlyrics
    \font\A=phvb8t at 6pt% added for letter type.
    \setlyrics{Jonico1}{{\color{red-undar}{Do Mayor}} {\color{red-undar}{Do Menor}}}
    \setlyrics{Dorico1}{{\color{red-undar}{Do Aumentado}} {\color{red-undar}{Do Disminuido}}}
    \setlyrics{Frigio1}{%
      {\color{red-undar}%
        {\Longunderstack{Do segunda\\suspendida}}} 
      {\color{red-undar}%
       {\Longunderstack{Do cuarta\\suspendida}}}%
    }
    \setsongraise3{0.5mm}
    \setsongraise2{0.8mm}
    \setsongraise1{0.8mm}
    \hsize=20cm
    \parindent16mm
    %\setmaxinstruments{2}
    \instrumentnumber{3}
    \setstaffs1{1}
    \setstaffs2{1}
    \setstaffs3{1}
    \setclef3\treble
    \setclef2\treble
    \setclef1\treble
    \nobarnumbers
    \sepbarrules
    \nostartrule
    %\setemptybar
    \setinterstaff{1}{9}%Distancia entre sistemas del pentagrama
    \setinterstaff{2}{9}%Distancia entre sistemas del pentagrama
    \setinterstaff{3}{9}%Distancia entre sistemas del pentagrama
    \setbox\lyrstrutbox=\vbox to 1.3\Interligne{} % Distancia entre lyrics
    \resetlyrics % Se requiere reiniciar la configuración para habilitar el paso anterior
    \startextract
    \A\assignlyrics1{Frigio1}% added to place handindication
    \A\assignlyrics2{Dorico1}% added to place handindication
    \A\assignlyrics3{Jonico1}% added to place handindication
    \setdoublebar%
    \NOTEs\hsk\zw{c}\rw{d}\wh{g}&\hsk\zw{ce}\wh{^g}&\hsk\zw{ce}\wh{g}\en\bar
    %\setdoublebar
    \NOTEs\hsk\zw{c}\rw{g}\wh{f}&\hsk\zw{c}\lfl{e}\zw{e}\wh{_g}&\hsk\zw{c_e}\wh{g}\en%\bar
    \setdoubleBAR
    \nolyr
    \lyricsoff
    \endextract
\end{music}
\end{document}

在此处输入图片描述

相关内容