]> git.donarmstrong.com Git - lilypond.git/blobdiff - input/test/title-markup.ly
* input/regression/new-markup-scheme.ly: oops. font-family=music
[lilypond.git] / input / test / title-markup.ly
index 9abe85dfbac45c8b1bc5bf229bcb29d55f14f995..bbfc6447df5848b0f2f464dafc6327a8617cdfd7 100644 (file)
@@ -1,14 +1,43 @@
-\version "2.1.29"
+\version "2.5.2"
+
 %{
-   \markup in titles is WIP.
+   Markup titles also available for direct PostScript output:
+
+   export GS_LIB=$(pwd)/mf/out:/usr/share/texmf/fonts/type1/bluesky/cm
+   lilypond-bin -fps input/title/title-markup.ly
+
+  PostScript fonts: WIP.
+
+  * Nonstandardised install directory / how to locate a ps font?
+  * Nonstandardised filenames?
+
+
+For century schoolbook font:
+
+  Debian:
+    cp -pv /usr/share/fonts/type1/gsfonts/c*.{afm,pfb} mf/out
+
+  Red Hat (untested):
 
-   only available when compiled with PAGE_LAYOUT is #define'd
-   see include/paper-book.hh
+    cp -pv /usr/share/fonts/afms/adobe/c*.{afm,pfb} mf/out/
+
+    cp -pv /usr/share/fonts/default/Type1/c*.{pfb,afm} mf/out
 
 %}
 
+\layout{
+    #(define page-breaking ly:optimal-page-breaks)
+    %% Ughr, this breaks TeX output...
+    %% fonts = #(make-century-schoolbook-tree 1.0)
+    inputencoding = #"latin1"
+}
+
+latinTest = \markup {
+    "Hellö"
+}
+    
 sizeTest = \markup {
-       \column <
+       \column {
             { \normalsize "normalsize"
               \hspace #5
               \smaller "smaller"
@@ -26,16 +55,22 @@ sizeTest = \markup {
               \hspace #5
               \bigger \bigger \bigger "bigger"
             }
-       >
+       }
 }
 
+
 spaceTest = \markup { "two space chars" }
 \header {
-    texidoc = "Make titles using markup (WIP)."
+    texidoc = "Make titles using markup.  Only in direct PostScript output."
+
+    tagline = "my tagline for "
     
     %dedication = "För my dør Lily"
     % ugh: encoding char-size
-    dedication = "For my öòóôõø so dear Lily"
+    %dedication = "For my öòóôõø so dear Lily"
+    dedication = \markup { "For my "
+%                         "öòóôõø"
+                          " so dear Lily" }
     title = "Title"
     subtitle = "(and (the) subtitle)"
     subsubtitle = "Sub sub title"
@@ -46,72 +81,43 @@ spaceTest = \markup { "two space chars" }
     meter = "Meter (huh?)"
     arranger = "Arranger"
     instrument = "Instrument"
-    piece = "piece"
+    piece = "Piece"
 
-%{
-    makeConditionalTitle = \markup {
-       \column <
-            #(if (defined? 'title)
-             (markup* #:fill-line (#:huge #:bigger #:bigger #:bold title))
-             (markup* ""))
-            #(if (defined? 'subtitle)
-             (markup* #:fill-line ( #:large #:bold subtitle))
-             (markup* ""))
-            #(if (defined? 'subsubtitle)
-             (markup* #:fill-line (subsubtitle))
-             (markup* ""))
-        >
-    }
-%}
-    bookTitle = \markup {
-       \column <
-           %\fill-line #linewidth < \huge \bigger \bold \title >
-            \override #'(baseline-skip . 4) \column <
-               \fill-line < \latin-i \dedication >
-               \fill-line < \huge\bigger\bigger\bigger\bigger \bold \title >
-                \override #'(baseline-skip . 3) \column <
-                    \fill-line < \large\bigger\bigger \bold \subtitle >
-                    \fill-line < \bigger\bigger \bold \subsubtitle >
-                >
-                \override #'(baseline-skip . 5) \column <
-                " "
-                >
-                \override #'(baseline-skip . 2.5) \column <
-                   \fill-line < \bigger \poet
-                                 \large\bigger \caps \composer >
-                   \fill-line < \bigger \texttranslator
-                                \bigger \opus >
-                   \fill-line < \bigger \meter
-                                \bigger \arranger >
-                    " "
-                   \fill-line < \large\bigger \instrument >
-                    " "
-                   \fill-line < \large\bigger \caps \piece  " ">
-                >
-            >
-        >    
-    }
-
-%{
-     foe = \sizeTest
-     baar = \spaceTest
-%}
+    %% Override automatic book title
+    %% bookTitle = \markup { \fill-line { \huge\bold \title } }
 }
 
-\score {
-    \context Staff \notes \relative c' {
-       c2-\sizeTest c2-\spaceTest
-       % \break c2 c2
+\book {
+    
+    \score {
+       \context Staff  \relative c' {
+           c2-\sizeTest c2-\spaceTest
+       }
+       \layout {
+           #(layout-set-staff-size (* 11.0 pt)) 
+       }
     }
-}
-
-\header {
-    scoreTitle = \markup { "Tweetje" }
-}
-
-\score {
-    \context Staff \notes \relative c' {
-       c2-\sizeTest c2-\spaceTest
-       % \break c2 c2
+    
+    \score {
+       \context Staff  \relative c' {
+           %% stress page breaking:
+           %% 35 keep on 3 pages
+           %% 36 spread evenly over 4 pages
+           \repeat unfold 6 { a b c d \break }
+           
+           %% FIXME: TODO factor \pagebreak \noPagebreak into regtest
+           %% Without this, page breaks are better, after measure: 12
+           \noPageBreak
+           \repeat unfold 30 { a b c d \break }
+           c1
+       }
+       \header {
+           %% Override automatic score title
+           %% scoreTitle = \markup { "Tweetje" }
+           opus = "opus 1"
+           piece = "Second"
+       }
+       \layout {
+       }
     }
 }