[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Issue 1482 in lilypond: \caps and \smallCaps don't work with \frompr
From: |
lilypond |
Subject: |
Re: Issue 1482 in lilypond: \caps and \smallCaps don't work with \fromproperty |
Date: |
Sun, 10 Jul 2011 21:28:11 +0000 |
Comment #3 on issue 1482 by address@hidden: \caps and \smallCaps don't
work with \fromproperty
http://code.google.com/p/lilypond/issues/detail?id=1482
This problem comes from the font you are using in your markups. There are
currently no native small-caps capabilities in the default font for markups
(Century Schoolbook from the PS font suite), which means that LilyPond
can't typeset it from \fromproperty. If you choose a font that has small
caps, then you should use the command \fontCaps instead of \smallCaps and
you'll get the result you're after.
Alternatively, you can make a slightly more involved function to get the
result you're after with the default font:
#(define-markup-command (frompropertysmallcaps layout props symbol
smallcaps)
(symbol? boolean?)
(let ((m (chain-assoc-get symbol props)))
(if (markup? m)
(interpret-markup layout props (if smallcaps (markup #:smallCaps m)
m))
empty-stencil)))
\paper {
line-width = 80\mm
bookTitleMarkup = \markup {
\column {
\fill-line {
\line { \sans "Sans" }
\line { \caps "Caps" }
\line { \smallCaps "SmallCaps" }
\line { \italic "Italic" }
\line { \bold "Bold" }
}
\fill-line {
\line { \sans \frompropertysmallcaps #'header:title ##f }
\line { \caps \frompropertysmallcaps #'header:title ##t }
\line { \fontCaps \frompropertysmallcaps #'header:title ##t }
\line { \italic \frompropertysmallcaps #'header:title ##f }
\line { \bold \frompropertysmallcaps #'header:title ##f }
}
}
}
}
\header {
title = "Title"
tagline = ##f
}
\markup \null
Re: Issue 1482 in lilypond: \caps and \smallCaps don't work with \fromproperty, Colin Campbell, 2011/07/10