]> git.donarmstrong.com Git - lilypond.git/commitdiff
Some minor changes and moving Text stuff into Advaned notation.
authorgpercival <gpercival>
Tue, 3 May 2005 08:49:23 +0000 (08:49 +0000)
committergpercival <gpercival>
Tue, 3 May 2005 08:49:23 +0000 (08:49 +0000)
ChangeLog
Documentation/user/advanced-notation.itely
Documentation/user/changing-defaults.itely
Documentation/user/instrument-notation.itely

index 02595ee83f55e37361d55fc6e701b0e1f9d21bc3..11fa9664cdfb5c3991989e4e3c4864c0f114a0b1 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -7,6 +7,12 @@
        advanced-notation.itely, instrument-notation.itely: minor
        fixes.
 
+       * ly/property-init.ly: add textSpanner{Up,Down,Neutral}.
+
+       * Documentation/user/advanced-notation.itely,
+       changing-defaults.itely: consolidate Text stuff in
+       advanced notation.
+
 2005-05-03  Han-Wen Nienhuys  <hanwen@xs4all.nl>
 
        * scm/framework-ps.scm (write-preamble): extract CFF from OTF
index 0c0844a530e5795b1ccff9c67cce44ab06e909c8..e22b0272d7a9930bc377eeba33ca096284ae3fd1 100644 (file)
@@ -12,6 +12,7 @@
 This chapter deals with rarely-used and advanced notation.
 
 @menu
+* Text::                        
 * Even more than notes::        
 * Preparing parts::             
 * Orchestral music::            
@@ -21,17 +22,21 @@ This chapter deals with rarely-used and advanced notation.
 @end menu
 
 
-@c  really bad section name.  :(
-@node Even more than notes
-@section Even more than notes
+@node Text
+@section Text
+
+This section explains how to include text (with various formatting) in
+your scores.
 
 @menu
 * Text scripts::                
 * Text spanners::               
-* Transpose::                   
-* Ottava brackets::             
-* Multi measure rests::         
-* Time administration::         
+* Text markup::                 
+* Text encoding::               
+* Nested scores::               
+* Overview of text markup commands::  
+* New dynamic marks::           
+* Other text markup issues::    
 @end menu
 
 
@@ -91,11 +96,19 @@ properties
 
 @lilypond[quote,raggedright,fragment,relative=1,verbatim]
 c1
-\override TextSpanner #'direction = #-1
+\textSpannerDown
 \override TextSpanner #'edge-text = #'("rall " . "")
 c2\startTextSpan b c\stopTextSpan a
 @end lilypond
 
+@refcommands
+
+@cindex{textSpannerUp}
+@code{textSpannerUp},
+@cindex{textSpannerDown}
+@code{textSpannerDown},
+@cindex{textSpannerNeutral}
+@code{textSpannerNeutral}.
 
 @seealso
 
@@ -105,6 +118,220 @@ Internals @internalsref{TextSpanEvent},
 Examples: @inputfileref{input/@/regression,text@/-spanner@/.ly}.
 
 
+@node Text markup
+@subsection Text markup
+@cindex text markup
+@cindex markup text
+
+@cindex typeset text
+
+The internal mechanism to typeset texts is accessed with the keyword
+@code{\markup}.  Within markup mode, you can enter texts similar to
+lyrics.  They are simply entered, while commands use the backslash @code{\}.
+@cindex markup
+
+@lilypond[quote,verbatim,fragment,relative=1]
+c1^\markup { hello }
+c1_\markup { hi there }
+c1^\markup { hi \bold there, is \italic anyone home? }
+@end lilypond
+
+@cindex font switching
+
+The markup in the example demonstrates font switching commands.  The
+command @code{\bold} and @code{\italic} apply to the first following 
+word only; enclose a set of texts with braces to apply a command
+to more words:
+@example
+\markup @{ \bold @{ hi there @} @}
+@end example
+
+@noindent
+For clarity, you can also do this for single arguments, e.g.,
+
+@example
+\markup @{ is \italic @{ anyone @} home @}
+@end example
+
+@cindex font size, texts
+
+
+In markup mode you can compose expressions, similar to mathematical
+expressions, XML documents, and music expressions.  You can stack
+expressions grouped vertically with the command @code{\column}.
+Similarly, @code{\center-align} aligns texts by their center lines:
+
+@lilypond[quote,verbatim,fragment,relative=1]
+c1^\markup { \column { a bbbb \line { c d } } }
+c1^\markup { \center-align { a bbbb c } }
+c1^\markup { \line { a b c } }
+@end lilypond
+
+
+Markups can be stored in variables and these variables
+may be attached to notes, like
+@example
+allegro = \markup @{ \bold \large @{ Allegro @} @}
+ @{ a^\allegro b c d @}
+@end example
+
+
+Some objects have alignment procedures of their own, which cancel out
+any effects of alignments applied to their markup arguments as a
+whole.  For example, the @internalsref{RehearsalMark} is horizontally
+centered, so using @code{\mark \markup @{ \left-align .. @}} has no
+effect.
+
+
+@seealso
+
+Init files: @file{scm/@/new@/-markup@/.scm}.
+
+
+@refbugs
+
+Kerning or generation of ligatures is only done when the @TeX{}
+backend is used.  In this case, LilyPond does not account for them so
+texts will be spaced slightly too wide.
+
+Syntax errors for markup mode are confusing.
+
+
+@node Text encoding
+@subsection Text encoding
+
+LilyPond uses the Pango library to format multi-lingual texts, and
+does not perform any input-encoding conversions.  This means that any
+text, be it title, lyric text, or musical instruction containing
+non-ASCII characters, must be utf-8.  Easiest to enter such texts is
+by using a Unicode-aware editor, and save using utf-8 encoding.  Most
+popular modern editors have utf-8 support, for example, vim, Emacs,
+jEdit, and GEdit do.
+
+Depending on the fonts installed, the following fragment shows Hebrew
+and Cyrillic lyrics,
+
+@cindex Cyrillic
+@cindex Hebrew
+@cindex ASCII, non
+
+@lilypondfile[fontload]{utf-8.ly}
+
+
+The @TeX{} backend does not handle encoding specially at all.  Strings
+in the input are put in the output as-is.  Extents of text items in the
+@TeX{} backend, are determined by reading a file created via the
+@file{texstr} backend,
+
+@example
+lilypond -b texstr input/les-nereides.ly
+latex les-nereides.texstr
+@end example
+
+The last command produces @file{les-nereides.textmetrics}, which is
+read when you execute
+
+@example
+lilypond -b tex input/les-nereides.ly
+@end example
+
+Both @file{les-nereides.texstr} and @file{les-nereides.tex} need
+suitable LaTeX wrappers to load appropriate La@TeX{} packages for
+interpreting non-ASCII strings.
+
+@seealso
+
+@inputfileref{input/regression,utf-8.ly}
+
+
+@node Nested scores
+@subsection Nested scores
+
+It is possible to nest music inside markups, by adding a @code{\score}
+block to a markup expression.  Such a score must contain a @code{\layout}
+block.
+
+@lilypond[quote,verbatim,raggedright]
+\relative {
+  c4 d^\markup {
+    \score {
+      \relative { c4 d e f }
+      \layout { }
+    }
+  }
+  e f
+}
+@end lilypond
+
+
+@node Overview of text markup commands
+@subsection Overview of text markup commands
+
+The following commands can all be used inside @code{\markup @{ @}}.
+
+@include markup-commands.tely
+
+
+@node New dynamic marks
+@subsection New dynamic marks
+
+It is possible to print new dynamic marks or text that should be aligned
+with dynamics.  Use @code{make-dynamic-script} to create these marks.
+
+@cindex make-dynamic-script
+
+@lilypond[quote,verbatim,raggedright]
+sfzp = #(make-dynamic-script "sfzp")
+\relative c' {
+  c4 c c\sfzp c
+}
+@end lilypond
+
+@cindex Dynamics, editorial
+@cindex Dynamics, parenthesis
+
+It is also possible to print dynamics in round parenthesis or square
+brackets.  These are often used for adding editorial dynamics.
+
+@lilypond[quote,verbatim,raggedright]
+\version "2.4.2"
+rndf = \markup{ \center-align {\line { \bold{\italic (}
+  \dynamic f \bold{\italic )} }} }
+boxf = \markup{ \bracket { \dynamic f } }
+{ c'1_\rndf c'1_\boxf }
+@end lilypond
+
+
+@node Other text markup issues
+@subsection Other text markup issues
+
+To use a normal font within a title, you must define it manually
+
+@example
+#(def-markup-command (normal-font layout props arg) (markup?)
+  "Switch to normal text font"
+  (interpret-markup layout (cons '((font-series . 'medium) (font-shape . 'upright)) props) arg))
+
+\header@{
+  title = \markup@{ ABCD \normal-font ABCD @}
+@}
+@end example
+
+
+@c  really bad section name.  :(
+@node Even more than notes
+@section Even more than notes
+
+@menu
+* Transpose::                   
+* Ottava brackets::             
+* Multi measure rests::         
+* Time administration::         
+@end menu
+
+
+
 @node Transpose
 @subsection Transpose
 @cindex Transpose
index 797ca0b796bbb72e41aeca2c011b4c19bfcfbabf..4fcfbcc450b4c7390607b95cc0ba940d3344e46e 100644 (file)
@@ -61,7 +61,6 @@ on entering numbers, lists, strings, and symbols in Scheme.}
 * Interpretation contexts::     
 * The \override command::       
 * Fonts::                       
-* Text markup::                 
 @end menu
 
  
@@ -1475,230 +1474,4 @@ fonts may be added to LilyPond.
 
 
 
-@node Text markup
-@section Text markup
-@cindex text markup
-@cindex markup text
-
-
-@cindex typeset text
-
-The internal mechanism to typeset texts is accessed with the keyword
-@code{\markup}.  Within markup mode, you can enter texts similar to
-lyrics.  They are simply entered, while commands use the backslash @code{\}.
-@cindex markup
-
-@lilypond[quote,verbatim,fragment,relative=1]
-c1^\markup { hello }
-c1_\markup { hi there }
-c1^\markup { hi \bold there, is \italic anyone home? }
-@end lilypond
-
-@cindex font switching
-
-The markup in the example demonstrates font switching commands.  The
-command @code{\bold} and @code{\italic} apply to the first following 
-word only; enclose a set of texts with braces to apply a command
-to more words:
-@example
-\markup @{ \bold @{ hi there @} @}
-@end example
-
-@noindent
-For clarity, you can also do this for single arguments, e.g.,
-
-@example
-\markup @{ is \italic @{ anyone @} home @}
-@end example
-
-@cindex font size, texts
-
-
-In markup mode you can compose expressions, similar to mathematical
-expressions, XML documents, and music expressions.  You can stack
-expressions grouped vertically with the command @code{\column}.
-Similarly, @code{\center-align} aligns texts by their center lines:
-
-@lilypond[quote,verbatim,fragment,relative=1]
-c1^\markup { \column { a bbbb \line { c d } } }
-c1^\markup { \center-align { a bbbb c } }
-c1^\markup { \line { a b c } }
-@end lilypond
-
-
-Markups can be stored in variables and these variables
-may be attached to notes, like
-@example
-allegro = \markup @{ \bold \large @{ Allegro @} @}
- @{ a^\allegro b c d @}
-@end example
-
-
-Some objects have alignment procedures of their own, which cancel out
-any effects of alignments applied to their markup arguments as a
-whole.  For example, the @internalsref{RehearsalMark} is horizontally
-centered, so using @code{\mark \markup @{ \left-align .. @}} has no
-effect.
-
-Similarly, for moving whole texts over notes with
-@code{\raise}, use the following trick:
-@lilypond[quote,verbatim]
-{
-  c'^\markup { \raise #0.5 not-raised }
-  c'^\markup { "" \raise #0.5 raised }
-}
-@end lilypond
-
-On the second note, the text @code{raised} is moved relative to the
-empty string @code{""} which is not visible.  Alternatively, complete
-objects can be moved with layout properties such as @code{padding} and
-@code{extra-offset}.
-
-
-
-
-@seealso
-
-Init files: @file{scm/@/new@/-markup@/.scm}.
-
-
-@refbugs
-
-Kerning or generation of ligatures is only done when the @TeX{}
-backend is used.  In this case, LilyPond does not account for them so
-texts will be spaced slightly too wide.
-
-Syntax errors for markup mode are confusing.
-
-
-@menu
-* Text encoding::               
-* Nested scores::               
-* Overview of text markup commands::  
-* New dynamic marks::           
-* Other text markup issues::    
-@end menu
-
-@node Text encoding
-@subsection Text encoding
-
-LilyPond uses the Pango library to format multi-lingual texts, and
-does not perform any input-encoding conversions.  This means that any
-text, be it title, lyric text, or musical instruction containing
-non-ASCII characters, must be utf-8.  Easiest to enter such texts is
-by using a Unicode-aware editor, and save using utf-8 encoding.  Most
-popular modern editors have utf-8 support, for example, vim, Emacs,
-jEdit, and GEdit do.
-
-Depending on the fonts installed, the following fragment shows Hebrew
-and Cyrillic lyrics,
-
-@cindex Cyrillic
-@cindex Hebrew
-@cindex ASCII, non
-
-@lilypondfile[fontload]{utf-8.ly}
-
-
-The @TeX{} backend does not handle encoding specially at all.  Strings
-in the input are put in the output as-is.  Extents of text items in the
-@TeX{} backend, are determined by reading a file created via the
-@file{texstr} backend,
-
-@example
-lilypond -b texstr input/les-nereides.ly
-latex les-nereides.texstr
-@end example
-
-The last command produces @file{les-nereides.textmetrics}, which is
-read when you execute
-
-@example
-lilypond -b tex input/les-nereides.ly
-@end example
-
-Both @file{les-nereides.texstr} and @file{les-nereides.tex} need
-suitable LaTeX wrappers to load appropriate La@TeX{} packages for
-interpreting non-ASCII strings.
-
-@seealso
-
-@inputfileref{input/regression,utf-8.ly}
-
-
-@node Nested scores
-@subsection Nested scores
-
-It is possible to nest music inside markups, by adding a @code{\score}
-block to a markup expression.  Such a score must contain a @code{\layout}
-block.
-
-@lilypond[quote,verbatim,raggedright]
-\relative {
-  c4 d^\markup {
-    \score {
-      \relative { c4 d e f }
-      \layout { }
-    }
-  }
-  e f
-}
-@end lilypond
-
-
-@node Overview of text markup commands
-@subsection Overview of text markup commands
-
-The following commands can all be used inside @code{\markup @{ @}}.
-
-@include markup-commands.tely
-
-
-@node New dynamic marks
-@subsection New dynamic marks
-
-It is possible to print new dynamic marks or text that should be aligned
-with dynamics.  Use @code{make-dynamic-script} to create these marks.
-
-@cindex make-dynamic-script
-
-@lilypond[quote,verbatim,raggedright]
-sfzp = #(make-dynamic-script "sfzp")
-\relative c' {
-  c4 c c\sfzp c
-}
-@end lilypond
-
-@cindex Dynamics, editorial
-@cindex Dynamics, parenthesis
-
-It is also possible to print dynamics in round parenthesis or square
-brackets.  These are often used for adding editorial dynamics.
-
-@lilypond[quote,verbatim,raggedright]
-\version "2.4.2"
-rndf = \markup{ \center-align {\line { \bold{\italic (}
-  \dynamic f \bold{\italic )} }} }
-boxf = \markup{ \bracket { \dynamic f } }
-{ c'1_\rndf c'1_\boxf }
-@end lilypond
-
-
-@node Other text markup issues
-@subsection Other text markup issues
-
-To use a normal font within a title, you must define it manually
-
-@example
-#(def-markup-command (normal-font layout props arg) (markup?)
-  "Switch to normal text font"
-  (interpret-markup layout (cons '((font-series . 'medium) (font-shape . 'upright)) props) arg))
-
-\header@{
-  title = \markup@{ ABCD \normal-font ABCD @}
-@}
-@end example
-
-
 
index 1b6c0c5c95eac4a3aabfcbff605fb785173f0770..ae42159724db082ac38ce2370ed25b006a6715ef 100644 (file)
@@ -1317,7 +1317,7 @@ There is no collision handling in the case of multiple per-voice
 ambitus.
 
 @node Other vocal issues
-@subsection Other vocal issue
+@subsection Other vocal issues
 
 @ignore
 yeah, I'm giving up somewhat by stuffing a bunch of things in
@@ -1838,6 +1838,11 @@ Details about the property interface to fret diagrams are found at
 Examples: @inputfileref{input/@/test,fret@/-diagram@/.ly}
 
 
+@node Other guitar issues
+@subsection Other guitar issues
+
+FIXME: insert guitar fret number example here.
+
 
 @node Ancient notation
 @section Ancient notation