lilypond-user
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: setting the font size for markups independently


From: Marc Hohl
Subject: Re: setting the font size for markups independently
Date: Wed, 06 Jul 2011 12:11:27 +0200
User-agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.2.17) Gecko/20110424 Thunderbird/3.1.10

Am 06.07.2011 11:58, schrieb -Eluze:

Marc Hohl wrote:
Am 05.07.2011 18:17, schrieb -Eluze:
[...]
i think Kieren's solution works if you override the property of the
TextScript in its real context which seems to be the Voice context:

\layout {
    \context {
      \Voice
      \override TextScript #'font-size = #-12
} }

hth
Eluze
No, it is still not working. Attached are two minimal files which don't
show any difference in the font size regardless of the value for
abs-fontsize.

\layout {
    \context {
       \Voice
       \override TextScript #'abs-fontsize = #100
    }
}
\version "2.15.5"

\include "myinclude.ily"

\markup {
   \wordwrap {
      This is a sample text.
   }
}

you cannot use abs-fontsize to override TextScript properties, it seems to
be reserved for text markups! (at least here i get an error or warning)

but then i don't understand what you're looking for - do you want the
markups in the scores (i.e. attached to notes) to have the same size or do
you want all markups between music parts to have the same size (or both)?
I want markups between music parts to have a fixed (absolute) font size,
whereas the music parts can be scaled according to my needs.

As far as I understand, Neil explained that this is only possible by
redefining the markup definition within scm/markup.scm:

 I don't think this is possible without redefining interpret-markup
 directly inside scm/makup.scm, i.e.,

 (define-public (interpret-markup layout props arg)
    (ly:text-interface::interpret-markup layout props
 (make-abs-fontsize-markup 12 arg)))

 It is possible to redefine interpret-markup inside a .ly file, but
 you'll find top-level markup ignores the new settings since
 interpret-markup-list will still use the original definition (it's
 defined directly following interpret-markup, and gets called from C++
 when generating paper-book output).

So I inserted \abs-fontsize everywhere, and now it works.
It is a bit clumsy, and I had to define my own
\hspace-mm, \vspace-mm, epsfile-mm and \with-dimensions-mm
as well, which work exactly like their normal counterparts, but expect
millimeters as units (and therefore don't scale with the staff spacing).

Regards,

Marc



cheers
Eluze




reply via email to

[Prev in Thread] Current Thread [Next in Thread]