]> git.donarmstrong.com Git - lilypond.git/commitdiff
lilypond-1.1.2
authorfred <fred>
Tue, 26 Mar 2002 21:28:42 +0000 (21:28 +0000)
committerfred <fred>
Tue, 26 Mar 2002 21:28:42 +0000 (21:28 +0000)
35 files changed:
Documentation/tex/feta.tex
Documentation/tex/refman.yo
Documentation/tex/tutorial.yo
TODO
dstreamrc
init/GNUmakefile
init/declarations.ly
init/paper16.ly
init/paper20.ly
input/test/accid.fly [new file with mode: 0644]
input/test/keys.ly
input/test/time.fly
lily/command-request.cc
lily/include/command-request.hh
lily/include/lily-guile.hh
lily/include/lookup.hh
lily/include/musical-pitch.hh
lily/include/musical-request.hh
lily/include/time-signature.hh
lily/key-engraver.cc
lily/key-item.cc
lily/lily-guile.cc
lily/local-key-engraver.cc
lily/local-key-item.cc
lily/midi-walker.cc
lily/musical-pitch.cc
lily/musical-request.cc
lily/paper-def.cc
lily/paper-outputter.cc
lily/parser.yy
lily/time-signature-engraver.cc
lily/time-signature.cc
mf/feta-toevallig.mf
mutopia/gallina.ly
tex/lilyponddefs.tex

index cf2f881c9474327cc06d847fbb28d85382b56008..032c1dcf69c47585d2f817faf9d7ee383a44f517 100644 (file)
 \font\fetanumber = feta-nummer12
 \font\fetafinger = feta-nummer5
 \font\fetadyn = feta-din10 scaled \magstep 2
+\font\title = cmbx12 scaled \magstep 4
+\font\subtitle = cmr9
 
-\def\setchar#1#2{\hbox to\charwidth{\hss{#1\char#2}}}
+\def\lilyfooter{Lily was here, 1.1.0}
+\def\setchar#1#2{\hbox to\charwidth{\hss{#1\char#2}\hss}}
 
 \def\charsperline{6}
 \def\charheight{55pt}
         \loop\ifnum\n<#3
        \advance\n by\charsperline
        \i=0
-       \vbox to\charheight{\vss\hbox{
+       {\vbox to\charheight{\vss\centerline{
        {\loop\ifnum\i<\charsperline
        \advance\i by1
        \advance\n by1
         {\setchar{#1}{\number\n}}
-       \repeat}}}\repeat}
+       \repeat}}}}\repeat}
+
+
+\centerline{\title FETA}
+
+\centerline{\subtitle (definately not an abbreviation for Font-En-Tja)}
+
+\vskip5mm
 
 \listfont{\fetatwenty}{0}{78}
 % urg
@@ -43,4 +53,6 @@
 \listfont{\fetadyn}{0}{6}
 \vskip-\charheight
 
+\lilyfooter
+
 \bye
index ae08ad2d24ae9172ea474776291a992b5d82c753..7a2e4ec17a0f575602658950b3197a47b4a7f0c1 100644 (file)
@@ -347,7 +347,7 @@ label(notedesc)
 subsect(Basic Note Specification)
 
 A note specification has the form 
-var(pitch)[var(octavespec)][code(!)][var(duration)].
+var(pitch)[var(octavespec)][code(!)][code(?)][var(duration)].
 The pitch of the note is specified by the note's name.  
 
 LilyPond has predefined note names for various languages.  The default
@@ -395,9 +395,11 @@ will determine what accidentals to  typeset  depending on the  key and
 context.   
 A reminder accidental can be forced by
 using the  optional exclamation mark `code(!)'
-on a pitch.
+on the pitch.
+A cautionary accidental, i.e., an accidental within paranthesis
+can be obtained using the optional question mark `code(?)' on the pitch.
 mudela(fragment,verbatim,center)(
-cis' d' e' cis'  c'! d' e' c' 
+cis' d' e' cis'  c'? d' e' c'!  
 )
 
 
@@ -951,8 +953,14 @@ argument var(file) is a string.  The full filename including the
 file(.ly) extension must be given, and the filename must be quoted.
 (An unquoted string will not work here.)
 
-dit(code(\key) var(pitch)code(;)) Change key signature to that of
-var(pitch)-major.
+dit(code(\key) var(pitch) var(type) code(;)) Change the key signature. 
+var(type) should be code(\major) or code(\minor) to get
+var(pitch)-major or var(pitch)-minor, respectively. The second
+argument is optional, the default is major keys. 
+The var(\type) argument can also be given as an integer, which tells
+the number of semitones that should be added to the pitch given in the
+subsequent code(\key) commands to get the corresponding major key,
+e.g. code(\minor) is defined as 3.
 
 dit(code(\keysignature) var(pitchseq)code(;))
 Specify an arbitrary key signature.  The pitches from var(pitch) will
@@ -1295,9 +1303,6 @@ dit(code(barAlways)) If set to 1 a bar line is drawn after each note.
 dit(code(defaultBarType)) Sets the default type of bar line.  See
 code(\bar) keyword.
 
-
-
-
 dit(code(keyoctaviation)) If set to 1, then keys are the same in all
 octaves.  If set to 0 then the key signature for different octaves can
 be different and is specified independently: code(\keysignature bes
@@ -1323,16 +1328,16 @@ default) if you do not want key signatures printed.
 dit(code(timeSignatureStyle)) Changes the default two-digit layout
    for time signatures. The following values are recognized:
    description(
-      dit(code(C)): 4/4 and 2/2 are typeset as C and struck C,
+      dit(code(C)) 4/4 and 2/2 are typeset as C and struck C,
       respectively. All other time signatures are written with two digits.
-      dit(code(old)): 2/2, 3/2, 3/4, 4/4, 6/4 and 9/4 are typeset with
+      dit(code(old)) 2/2, 3/2, 3/4, 4/4, 6/4 and 9/4 are typeset with
       old-style mensuration marks. All other time signatures are 
       written with two digits.
-      dit(code(1)): All time signatures are typeset with a single
+      dit(code(1)) All time signatures are typeset with a single
       digit, e.g. 3/2 is written as 3.
       dit(code(C2/2), code(C4/4), code(old2/2), code(old3/2),
       code(old3/4), code(old4/4), code(old6/4) or
-      code(old9/4)): Tells Lilypond to use a specific symbol as time
+      code(old9/4)) Tells Lilypond to use a specific symbol as time
       signature.
    )
 The different time signature characters are shown below with
@@ -1439,6 +1444,10 @@ code(castingalgorithm).  Is equal to 1.0.
 dit(code(\infinity)) Used for setting the Score.beamslopedamping
 property.  Is actually equal to 10000.  
 dit(code(\left)) Used for setting textalignment property.  Is equal to -1.
+dit(code(\major)) Used as the second argument of the code(\key)
+command to get a major key.
+dit(code(\minor)) Used as the second argument of the code(\key)
+command to get a minor key.
 dit(code(\mf)) Print mezzoforte symbol on preceeding note. 
 dit(code(\mp)) Print mezzopiano symbol on preceeding note. 
 dit(code(\nobreak)) Prevent a line break in music by using a large
index 02bdaaf9a340b4405bbb9fc30cb9dc88af1c32d9..cf2e0e53499804319bdd9efad473e1e1204a51f5 100644 (file)
@@ -696,10 +696,12 @@ dit(code(\clef) var(clefname)) This command sets the current clef for notation,
     \clef "treble"; c'4
     \clef "alto"; c'4    
   )
-dit(code(\key) var(pitch)) This command changes the current key signature.  The
-  key signature is printed at the start of every line.  The argument
-  is the name of the corresponding major key.  The key of C-minor can 
-  thus be specified as `code(\key es)'.
+dit(code(\key) var(pitch) var(type)) This command changes the current
+  key signature.  The key signature is printed at the start of every
+  line. The var(type) argument is set to code(\major) or code(\minor)
+  to get major or minor keys, respectively. Omitting the second
+  argument gives major keys. The key of C-minor can thus be specified
+  as `code(\key es)' or `code(\key \c minor)'. 
   
 dit(code(\keysignature) var(pitchlist))
 
diff --git a/TODO b/TODO
index b22fe9a2447bc07bb0e6d4b811dd15d83969a889..b6ac7d37bcfdcaa0371a0acf25330701db5c29fc 100644 (file)
--- a/TODO
+++ b/TODO
@@ -9,7 +9,7 @@ grep for TODO and ugh/ugr/urg
 
 
 BUGS:
-       * disallow backslashes
+       * --safe:  disallow backslashes, disallow \include.
 
        * \breathmark TeX macro 
 
@@ -269,8 +269,6 @@ ydirection and hshift preset
 
        * integrate midi-elts from mi2mu and lily?
 
-       * cautionary accidental
-
        * score-bar-scripts
        FMR: Free memory read:
          * This is occurring while in:
@@ -487,7 +485,6 @@ PROJECTS
 
        * Keys:
        - merge key{item} & localkey{item}?
-       - Major/Minor
        - spacing, national styles?
 
        * Support for TAB
index 2d4ef5938b01b201462caa6f74584755fdc9be6a..330a276b849e50b650c0bf9e728d138cfc09face 100644 (file)
--- a/dstreamrc
+++ b/dstreamrc
@@ -41,9 +41,8 @@ Clef_item             1
 Clef_change_req                1
 Col_configuration      1
 Col_hpositions         1
-Colinfo                        1
-Colinfo                        1
 Collision              1
+Column_info            1
 Column_rod             1
 Duration_identifier    1
 Engraver               0
@@ -92,7 +91,7 @@ Rhythmic_req          1
 Scope                  1
 Score                  0
 Score_column           0
-Score_elem             0
+Score_element          0
 Score_engraver         0
 Score_performer                1
 Script_column          1
index 7b213816c7ecb249bcc69d7fa5252ae069d624a2..105ca5fc69c748d693f27e1e625dd065a15b8eb9 100644 (file)
@@ -3,7 +3,8 @@
 depth = ..
 
 INI_FILES = $(FLY_FILES) $(LY_FILES)
-# DIST_FILES = Makefile $(INI_FILES)
+SCM_FILES = $(wildcard *.scm)
+EXTRA_DIST_FILES = $(SCM_FILES)
 
 INSTALLATION_DIR=$(datadir)/ly/
 INSTALLATION_FILES=$(INI_FILES)
index c1bc0fd333b3e8ac2e9f5ee5944390a40fd266f1..352dc96a890ceefe08562e69994201c42ae314fa 100644 (file)
@@ -33,6 +33,9 @@ center=0
 break = { \penalty = 10000; }
 nobreak = { \penalty = -10000; }
 
+major = 0
+minor = 3
+
 \include "property.ly"
 
 \include "scm.ly"
index 11aa7a8fd218bbd1712960269b9fdec886de000a..53ab49363decf4e4ebb986a094916579f1bcd086 100644 (file)
@@ -20,6 +20,8 @@ paper_sixteen = \paper {
         arithmetic_multiplier = 4.8\pt;
        texsetting = "\\input lilyponddefs \\musixsixteendefs ";
        pssetting = "(lilyponddefs.ps) findlibfile {exch pop //systemdict /run get exec} { /undefinedfilename signalerror } ifelse\n";
+       scmsetting = "(display \"(lilyponddefs.ps) findlibfile {exch pop //systemdict /run get exec} { /undefinedfilename signalerror } ifelse\");\n";
+       scmsetting = "(display \"\\\\input lilyponddefs \\\\musixsixteendefs\");\n";
 
        0 = \symboltables { \table_sixteen }
        -1 = \symboltables { \table_thirteen }
index 226cfb6a7414adfa7e84d1ab4fb259c1adfaed1d..e799f529bc36b463ac7425bb20587c34c6bc7b2f 100644 (file)
@@ -20,7 +20,8 @@ paper_twenty = \paper {
        texsetting = "\\input lilyponddefs \\musixtwentydefs ";
        pssetting = "(lilyponddefs.ps) findlibfile {exch pop //systemdict /run get exec} { /undefinedfilename signalerror } ifelse\n";
        % urg, debugging only
-       scmsetting = "(lilyponddefs.ps) findlibfile {exch pop //systemdict /run get exec} { /undefinedfilename signalerror } ifelse\n";
+       scmsetting = "(display \"(lilyponddefs.ps) findlibfile {exch pop //systemdict /run get exec} { /undefinedfilename signalerror } ifelse\");\n";
+       scmsetting = "(display \"\\\\input lilyponddefs \\\\musixtwentydefs\");\n";
 
        -2 = \symboltables { \table_thirteen }  
        -1 = \symboltables { \table_sixteen }
diff --git a/input/test/accid.fly b/input/test/accid.fly
new file mode 100644 (file)
index 0000000..d7a7775
--- /dev/null
@@ -0,0 +1,6 @@
+\time 3/4;
+cisis'' cisis! cisis? |
+cis cis! cis? | 
+c c! c? |
+ces ces! ces? |
+ceses ceses! ceses? |
index 211c7c1e20b1cf9cb0abf6c3e70437f052a23f7e..aa12b97e65746bea333ff78add984b8cbadef421 100644 (file)
@@ -6,8 +6,8 @@ test key itemv breaking
 \score {
   \notes
   {
-    \key bes; c1 \key c;  c1
+    \key bes; c1 \key c \minor;  c1
     \break
-    \key bes; c1 \key d;\break c1
+    \key bes \major; c1 \key d;\break c1
   }
 }
index 3908c4cf641ad7fffcdec22a55304d5a64058362..a7fd1d68b3dfef894f415d078f20f63b7535ad6a 100644 (file)
 \property Staff.timeSignatureStyle = "C"
 \time 1/1;
-c''1^"timeSignatureStyle = \"C\"" |
-\time 2/2;
-c1 |
-\time 3/4;
-c2. |
-\time 4/4;
-c1 |
-\time 5/4;
-c2. c2 |
-\time 6/4;
-c1. |
-\time 3/2;
-c1. |
-\time 7/4;
-c1 c2. |
-\time 8/4;
-c\breve |
-\time 9/4;
-c2. c2. c2. |
+c''1^"timeSignatureStyle = \"C\"" 
+\time 2/2; 
+c1 
+\time 3/4; 
+c2. 
+\time 4/4; 
+c1 
+\time 5/4; 
+c2. c2 
+\time 6/4; 
+c1. 
+\time 3/2; 
+c1. 
+\time 7/4; 
+c1 c2. 
+\time 8/4; 
+c\breve
+\time 9/4; 
+c2. c2. c2. 
 \break
 \property Staff.timeSignatureStyle = "old"
-\time 1/1;
-c1^"timeSignatureStyle = \"old\"" |
-\time 2/2;
-c1 |
-\time 3/4;
-c2. |
-\time 4/4;
-c1 |
-\time 5/4;
-c2. c2 |
-\time 6/4;
-c1. |
-\time 3/2;
-c1. |
-\time 7/4;
-c1 c2. |
-\time 8/4;
-c\breve |
-\time 9/4;
-c2. c2. c2. |
+\time 1/1; 
+c1^"timeSignatureStyle = \"old\"" 
+\time 2/2; 
+c1 
+\time 3/4; 
+c2. 
+\time 4/4; 
+c1 
+\time 5/4; 
+c2. c2 
+\time 6/4; 
+c1. 
+\time 3/2; 
+c1. 
+\time 7/4; 
+c1 c2. 
+\time 8/4; 
+c\breve 
+\time 9/4; 
+c2. c2. c2. 
 \break
 \property Staff.timeSignatureStyle = ""
-\time 1/1;
-c1^"timeSignatureStyle = \"\"" |
-\time 2/2;
-c1 |
-\time 3/4;
-c2. |
-\time 4/4;
-c1 |
-\time 5/4;
-c2. c2 |
-\time 6/4;
-c1. |
-\time 3/2;
-c1. |
-\time 7/4;
-c1 c2. |
-\time 8/4;
-c\breve |
-\time 9/4;
-c2. c2. c2. |
+\time 1/1; 
+c1^"timeSignatureStyle = \"\"" 
+\time 2/2; 
+c1
+\time 3/4; 
+c2.
+\time 4/4; 
+c1
+\time 5/4; 
+c2. c2
+\time 6/4; 
+c1.
+\time 3/2; 
+c1.
+\time 7/4; 
+c1 c2.
+\time 8/4; 
+c\breve 
+\time 9/4; 
+c2. c2. c2.
 \break
 \property Staff.timeSignatureStyle = "1"
-\time 1/1;
-c1^"timeSignatureStyle = \"1\"" |
-\time 2/2;
-c1 |
-\time 3/4;
-c2. |
-\time 4/4;
-c1 |
-\time 5/4;
-c2. c2 |
-\time 6/4;
-c1. |
-\time 3/2;
-c1. |
-\time 7/4;
-c1 c2. |
-\time 8/4;
-c\breve |
-\time 9/4;
-c2. c2. c2. |
+\time 1/1; 
+c1^"timeSignatureStyle = \"1\""
+\time 2/2; 
+c1
+\time 3/4; 
+c2.
+%{   % Error if these lines are uncommented:
+     % Line ... [0guile: Wrong type to apply: #<unknown-type (0x7f . 0x4026a148) @ 0x4026a150>
+\time 4/4; 
+c1
+%}
+\time 5/4; 
+c2. c2
+\time 6/4; 
+c1.
+\time 3/2; 
+c1.
+\time 7/4; 
+c1 c2.
+\time 8/4; 
+c\breve 
+\time 9/4; 
+c2. c2. c2. 
 \break
 \property Staff.timeSignatureStyle = "old9/4"
 \property Staff.textalignment = \center
-\time 1/1;
-c1^"old9/4" |
-\property Staff.timeSignatureStyle = "old6/4"
-\time 2/2;
-c1^"old6/4" |
+\time 1/1; 
+c1^"old9/4" 
+\property Staff.timeSignatureStyle = "old6/4" 
+\time 2/2; 
+c1^"old6/4" 
 \property Staff.timeSignatureStyle = "old3/2"
-\time 3/4;
-c2.^"old3/2" |
+\time 3/4; 
+c2.^"old3/2" 
 \property Staff.timeSignatureStyle = "old4/4"
-\time 4/4;
-c1^"old4/4" |
+\time 4/4; 
+c1^"old4/4" 
 \property Staff.timeSignatureStyle = "old2/2"
-\time 5/4;
-c2.^"old2/2" c2 |
+\time 5/4; 
+c2.^"old2/2" c2
 \property Staff.timeSignatureStyle = "C4/4"
-\time 6/4;
-c1.^"C4/4" |
+\time 6/4; 
+c1.^"C4/4" 
 \property Staff.timeSignatureStyle = "C2/2"
-\time 3/2;
-c1.^"C2/2" |
-
+\time 3/2; 
+c1.^"C2/2" 
index 5a67560e45f16c8fd3ac7935ddbcbe16ed4a64fc..9255f63cfb60ea1b05f52ea80d698351c381cf0e 100644 (file)
@@ -322,7 +322,7 @@ Key_change_req::do_print() const
 
 Key_change_req::Key_change_req()
 {
-  minor_b_ = false;
+  modality_i_ = 0;
   ordinary_key_b_= false;
 }
 
@@ -366,7 +366,7 @@ Key_change_req::flats_i()
 bool
 Key_change_req::minor_b() const
 {
-  return minor_b_;
+  return modality_i_ == 3;
 }
 
 int
index 96c010322bcd41aad7502fc8415861d733ac6309..c03ff6eb543d7bd5f78b83446f35e2005c212a48 100644 (file)
@@ -132,7 +132,7 @@ public:
 class Key_change_req  : public Command_req  {
 public:
   Array<Musical_pitch> pitch_arr_;
-  bool minor_b_;
+  int modality_i_;
   bool ordinary_key_b_;
 
   Key_change_req();
@@ -147,7 +147,6 @@ public:
   int sharps_i();
 
   void transpose (Musical_pitch  d);
-  /// is minor key?
   bool minor_b() const;
 };
 
index c4479cb5674d50c31baff8c1b4ec36ba9a2e43bf..f4c468c65e57f0443bf7050f3a53715b9ff7b1e6 100644 (file)
@@ -37,6 +37,7 @@ SCM ly_quote ();
 
 #include "array.hh"
 #include "scalar.hh"
+SCM lambda_scm (String str, Array<int> args_arr);
 SCM lambda_scm (String str, Array<Real> args_arr);
 SCM lambda_scm (String str, Array<Scalar> args_arr);
 
index 1781679920ecb921bf60429097ef6b1816603221..9b006156228e3489145355f1b9d60e85449022f7 100644 (file)
@@ -11,6 +11,7 @@
 #define LOOKUP_HH
 
 #include "atom.hh"
+#include "molecule.hh"
 #include "fproto.hh"
 #include "scalar.hh"
 #include "direction.hh"
@@ -29,9 +30,9 @@ public:
   Lookup (Symtables const&);
   ~Lookup ();
   
-  Atom accidental (int) const;
+  Molecule accidental (int, bool cautionary) const;
   void add (String, Symtable*);
-  Atom afm_find (String) const;
+  Atom afm_find (String, bool warn=true) const;
   Atom ball (int) const;
   Atom bar (String, Real height) const;
   Atom beam (Real, Real, Real) const;
@@ -53,8 +54,8 @@ public:
   Atom text (String style, String text) const;
   Atom vbrace (Real &dy) const;
   Atom vbracket (Real &dy) const;
-  Atom special_time_signature (String, Array<Real>) const;
-  Atom time_signature (Array<Real>) const;
+  Atom special_time_signature (String, Array<int>) const;
+  Atom time_signature (Array<int>) const;
 
   Paper_def * paper_l_;
   Symtables *symtables_p_;
index 2c4f1a55de1f3390efb63c18d7f3d776cdff1162..a46471fd61d5f35b5514a51f1f17dba0ce7710a0 100644 (file)
@@ -29,6 +29,8 @@ struct Musical_pitch : public Input
   int octave_i_;
   /// 0 natural, 1 sharp, etc
   int accidental_i_;
+  /// Used for cautionary accidentals
+  bool cautionary_b_;
 
   void init () ;
   Musical_pitch to_relative_octave (Musical_pitch);
index d280d158acab436876ceee114b4b70db9a8280b8..3f79b0b45b6b7015a3d519e96f7039c54f55d9b6 100644 (file)
@@ -110,6 +110,8 @@ public:
     
   /// force/supress printing of accidental.
   bool forceacc_b_;
+  /// Cautionary, i.e. parenthesized accidental.
+  bool cautionary_b_;
   Note_req();
   bool do_equal_b (Request*) const;
   REQUESTMETHODS(Note_req);
index 55c8133d3885da3314dc40017509950f51c40fd5..a2d09022b525ee1fc97ad14a521ece05abbbd407 100644 (file)
@@ -26,7 +26,7 @@ protected:
   virtual Molecule*brew_molecule_p() const;
 public:
   Time_signature () ;
-  Array<Real> args_;
+  Array<int> args_;
   String time_sig_type_str_;
   
   DECLARE_MY_RUNTIME_TYPEINFO;
index 77a29425f55ea91ea0da7ea0dae7c8e13c548393..e2152e224545fcd89d368dbc6397e044c925d1da 100644 (file)
@@ -114,8 +114,7 @@ Key_engraver::read_req (Key_change_req const * r)
       else
        {
          p = r->pitch_arr_[0].semitone_pitch ();
-         if (r->minor_b ())
-           p += 3;
+         p += r->modality_i_;
        }
       /* Solve the equation 7*no_of_acc mod 12 = p, -6 <= no_of_acc <= 5 */
       int no_of_acc = (7*p) % 12;
index 80e470f10fd734e9d2416d948a359b8e70223920..7d519d3b97a025ec6399f33927a21ee0f6c92e3b 100644 (file)
@@ -133,9 +133,8 @@ Key_item::brew_molecule_p() const
              || (old_pitch_arr_[i] == pitch_arr_[j]
                  && old_acc_arr_[i] != acc_arr_[j]))
             {
-              Atom a =lookup_l ()->accidental (0);
-              a.translate_axis (calculate_position(old_pitch_arr_[i], old_acc_arr_[i]) * inter, Y_AXIS);
-              Molecule m (a);
+              Molecule m =lookup_l ()->accidental (0,false);
+              m.translate_axis (calculate_position(old_pitch_arr_[i], old_acc_arr_[i]) * inter, Y_AXIS);
               output->add_at_edge (X_AXIS, RIGHT, m);  
             }
         }
@@ -153,9 +152,8 @@ Key_item::brew_molecule_p() const
  
   for (int i =0; i < pitch_arr_.size(); i++) 
     {
-      Atom a =lookup_l ()->accidental (acc_arr_[i]);
-      a.translate_axis (calculate_position(pitch_arr_[i], acc_arr_[i]) * inter, Y_AXIS);
-      Molecule m (a);
+      Molecule m =lookup_l ()->accidental (acc_arr_[i],false);
+      m.translate_axis (calculate_position(pitch_arr_[i], acc_arr_[i]) * inter, Y_AXIS);
       output->add_at_edge (X_AXIS, RIGHT, m);  
     }
   if (pitch_arr_.size()) 
index 375ff4635952c945e3eafb18b2441cf1cb3973f7..e4be91228884f7b5d70ce481bbc78d9a73e8faab 100644 (file)
@@ -63,6 +63,23 @@ ly_func_o (char const* name)
 }
 #endif
 
+SCM
+lambda_scm (String str, Array<int> args_arr)
+{
+  if (str.empty_b ())
+    {
+      str = "empty";
+      args_arr.clear ();
+    }
+  SCM args_scm = SCM_EOL;
+  for (int i = args_arr.size () - 1; i >= 0; i--)
+    args_scm = gh_cons (gh_int2scm (args_arr[i]), args_scm);
+  SCM scm =
+    ly_append (ly_lambda_o (), 
+    ly_list1 (ly_append (ly_func_o (str.ch_l ()), args_scm)));
+  return scm;
+}
+
 SCM
 lambda_scm (String str, Array<Scalar> args_arr)
 {
index 9b0658b6473e7c85a6bfd1e002361ef5a631564b..4edb8b874682720a6c5dd29e1daf3ccc38c3be7d 100644 (file)
@@ -67,6 +67,11 @@ Local_key_engraver::process_acknowledged ()
              key_item_p_ = new Local_key_item;
              announce_element (Score_element_info (key_item_p_, 0));         
            }
+         if (note_l->cautionary_b_)
+           {
+             note_l->pitch_.cautionary_b_ = true;
+           }
+
          key_item_p_->add (note_l->pitch_);
          key_item_p_->add_support (support_l);
          local_key_.set (note_l->pitch_);
index a0dc2907a6b4f72326b8d1c2fe4bc1b9b5cef7b1..a78ec7a371f9cc4012ab5ea668281f64bbed7adb 100644 (file)
@@ -70,10 +70,10 @@ Local_key_item::brew_molecule_p() const
       Real dy =
        (c0_position_i_ + accidental_pitch_arr_[i].notename_i_)
        * paper()->internote_f ();
-      Atom a (lookup_l ()->accidental (accidental_pitch_arr_[i].accidental_i_));
+      Molecule m (lookup_l ()->accidental (accidental_pitch_arr_[i].accidental_i_, 
+             accidental_pitch_arr_[i].cautionary_b_));
 
-      a.translate_axis (dy, Y_AXIS);
-      Molecule m(a);
+      m.translate_axis (dy, Y_AXIS);
       octave_mol_p->add_at_edge (X_AXIS, RIGHT, m);
     }
 
index 90477a3009ac19e3702807b5e1ede691f4275d72..1af44cd1fb65ee70d441b6c628aa1b97f1cd8ef2 100644 (file)
@@ -111,7 +111,7 @@ Midi_walker::process()
     return;
   p->channel_i_ = track_l_->number_i_;
   
-  if (Midi_item *mi = dynamic_cast<Midi_note*>(p))
+  if (Midi_note *mi = dynamic_cast<Midi_note*>(p))
     do_start_note (mi);
   else
     output_event (ptr()->audio_column_l_->at_mom (), p);
index e7ffbd7014b1beeb45ec034c93da3bf76ae21274..9603e025d9a6397108665b87c33b5813b5006a59 100644 (file)
@@ -21,6 +21,7 @@ Musical_pitch::init ()
   notename_i_ = 0;
   octave_i_ = 0;
   accidental_i_ = 0;
+  cautionary_b_ = false;
 }
 
 void
index c12cd16c29ab476e27dd9c02a4c5f93daf8aa701..4538a1d3b2dcb4c9e9281a9841ae6b6d6e25ee1c 100644 (file)
@@ -185,6 +185,7 @@ Note_req::do_equal_b (Request*r) const
 
 Note_req::Note_req ()
 {
+  cautionary_b_ = false;
   forceacc_b_ = false;
 }
 
@@ -195,7 +196,11 @@ Note_req::do_print () const
 {
 #ifndef NPRINT
   Melodic_req::do_print ();
-  if (forceacc_b_)
+  if (cautionary_b_)
+    {
+       DOUT << " force cautionary accidental\n";
+    }
+  else if (forceacc_b_)
     {
        DOUT << " force accidental\n";
     }
index 85abdd931b075e7b7dc7a0c7036bc86106ed9437..c94fe3e8d9389112f87654ca5b0e68d4d218fb0c 100644 (file)
@@ -269,8 +269,11 @@ Paper_def::paper_outputter_p (Paper_stream* os_p, Header* header_l, String origi
   Paper_outputter* p = new Paper_outputter (os_p);
 
   output_header (p, header_global_p);
+#if 0
+  // for now; breaks -fscm output
   p->output_comment (_ ("outputting Score, defined at: "));
   p->output_comment (origin_str);
+#endif
 
   output_header (p, header_l);
 
index 033fbf3f06dcc24cbdebbeca0bdf21856958e0f0..487b3d2b9ae3d6a6d9f1118e73812c5685bf5980 100644 (file)
@@ -8,6 +8,7 @@
 */
 
 #include <time.h>
+#include <fstream.h>
 #include "paper-outputter.hh"
 #include "paper-stream.hh"
 #include "molecule.hh"
@@ -94,6 +95,7 @@ Paper_outputter::output_molecule (Molecule const*m, Offset o, char const *nm)
 #ifndef NPRINT
       if (check_debug && !monitor->silent_b ("Guile"))
        {
+         DOUT << i->str_ << "\n";
          gh_display (i->lambda_); gh_newline ();
        }
 #endif
@@ -139,10 +141,29 @@ Paper_outputter::output_scheme (SCM scm)
   // urg; temporary hack to debug scheme error #unknown
   if (String (output_global_ch) == "scm")
     {
-//      char* c = gh_scm2newstr (scm, NULL);
-//      *outstream_l_ << c << "\n";
-//      free (c);
-       gh_display (scm); gh_newline ();
+      static SCM port = 0;
+      // urg
+      if (!port)
+        {
+         int fd = 1;
+         ofstream * of = dynamic_cast <ofstream*> (outstream_l_->os);
+         if (of)
+           fd = of->rdbuf()->fd();
+         FILE *file = fdopen (fd, "a");
+         port = scm_standard_stream_to_port (file, "a", "");
+         scm_display (gh_str02scm ("(load 'lily.scm)\n"), port);
+       }
+#if 0
+      *outstream_l_ << "(display ((eval ";
+      scm_write (scm, port);
+      *outstream_l_ << ") 'tex))\n";
+#else
+      scm_display (gh_str02scm ("(display ((eval "), port);
+      scm_write (scm, port);
+      scm_display (gh_str02scm (") 'tex))\n"), port);
+      scm_newline (port);
+      scm_fflush (port);
+#endif
       return;
     }
   SCM str_scm = gh_call1 (ly_eval (scm), gh_eval_str (o.ch_l ()));
index bc0680a3010ba5927cf7b260accd248bd1c67bcd..72e14708f53db987b0d596d2ad7d33a80053f7ca 100644 (file)
@@ -248,6 +248,7 @@ yylex (YYSTYPE *s,  void * v_l)
 %type <i>      abbrev_type
 %type <i>      int unsigned
 %type <i>      script_dir
+%type <i>      optional_modality
 %type <id>     identifier_init simple_identifier_init block_identifier
 %type <duration> steno_duration notemode_duration
 %type <duration> entered_notemode_duration explicit_duration
@@ -910,10 +911,11 @@ verbose_command_req:
                $$ = new Clef_change_req (*$2);
                delete $2;
        }
-       | KEY NOTENAME_PITCH    {
+       | KEY NOTENAME_PITCH optional_modality  {
                Key_change_req *key_p= new Key_change_req;
                key_p->pitch_arr_.push(*$2);
                key_p->ordinary_key_b_ = true;
+               key_p->modality_i_ = $3;
                $$ = key_p;
                delete $2;
        }
@@ -970,6 +972,15 @@ post_request:
        }
        ;
 
+optional_modality:
+       /* empty */     {
+               $$ = 0;
+       }
+       | int   {
+               $$ = $1;
+       }
+       ;
+
 sup_quotes:
        '\'' {
                $$ = 1;
@@ -1028,6 +1039,10 @@ steno_notepitch:
        | steno_notepitch  '!'          {
                $$->forceacc_b_ = ! $$->forceacc_b_;
        }
+       | steno_notepitch  '?'          {
+               $$->forceacc_b_ = ! $$->forceacc_b_;
+               $$->cautionary_b_ = ! $$->cautionary_b_;
+       }
        ;
 
 
index 35743ad24f253c9bcd48f5ed55fffae61897d625..a5ff8b4595fddd3e403af491520ff7de3443ae68 100644 (file)
@@ -35,7 +35,7 @@ Time_signature_engraver::do_process_requests()
   Time_signature_change_req *req = timing_grav_l->time_signature_req_l();
   if (req)
     {
-      Array<Real> args;
+      Array<int> args;
       args.push (req->beats_i_);
       args.push (req->one_beat_i_);
        
index edee3d9fbee96cdb15e18722995dc7566b82970c..a1330d55a4d5fc23a0cca9f6b48123c92de5a8ca 100644 (file)
@@ -26,7 +26,7 @@ Time_signature::brew_molecule_p () const
     {
       if (time_sig_type_str_[0]=='1')
        {
-         Array<Real> tmparr = args_;
+         Array<int> tmparr = args_;
          tmparr[1]= 0;
          s = lookup_l ()->time_signature (tmparr);
        }
index b9c9a0ebbee69c6eb3111bbddcb62a98d9165502..d4f94c536281dca98ce7e7cf4d43f1c8d0a43249 100644 (file)
@@ -247,7 +247,38 @@ fet_beginchar("Double sharp", "2", "sharpsharp")
        currentpicture := currentpicture  shifted (w/2,0);
 
 
-       fet_endchar;
+
+fet_endchar;
+
+
+def draw_paren =
+       save leftindent;
+       leftindent# := .2 interline#;
+       define_pixels(leftindent);
+       set_char_box(0, .5 interline#+stafflinethickness#,
+         interline#, interline#);
+       z1 = (leftindent,h);
+       z2 = (w-stafflinethickness,0);
+       z3 = (leftindent,-d);
+
+       penpos1(stafflinethickness, 35);
+       penpos2(2 stafflinethickness, 0);
+       penpos3(stafflinethickness, -35);
+
+       penlabels(1,2,3);
+       fill z2l{down} .. simple_serif(z3l, z3r, 90) .. z2r{up}
+       .. simple_serif(z1r, z1l, 90) .. z2l{down} -- cycle;
+enddef;
+  
+fet_beginchar("Right paranthesis", ")", "rightparen")
+       draw_paren;
+fet_endchar;
+
+fet_beginchar("Left paranthesis", "(", "leftparen")
+       draw_paren;
+        currentpicture := currentpicture xscaled -1;
+        set_char_box(charwd, charbp, chardp, charht);
+fet_endchar;
 
 
 fet_endgroup("accidentals");
index b6936163370ef5f394a93717dda14fb5fb5b82e2..ffaa8941cd97f9f4ed944c7e3fb0b63ce310e5c0 100644 (file)
@@ -29,8 +29,8 @@ either.
 
       /Mats
 
-
-Tested Features: Note placement, multipart score, figured base, \breve
+Tested Features: Note placement, multipart score, figured base, \breve,
+       time signature styles
 
 %}
 %{
@@ -47,8 +47,28 @@ definition below. --MB
 
 \version "1.0.7";
 
-vi1=\notes \relative c'' {
+global = \notes {
+  \property StaffGroup.timeSignatureStyle = "old"
+  \time 4/4;
+  \tempo 4=80;
+  \skip 1*31;
+  \property StaffGroup.timeSignatureStyle = "1"
+  \time 3/2;
+  \bar ":|:";
+  \tempo 2=140;
+  \skip 1.*15;
+  \property StaffGroup.timeSignatureStyle = "old"
   \time 4/4;
+  \tempo 4=80;
+  \skip 1;
+  \bar ":|:";
+  \skip 1*13;
+  \bar "|.";
+}
+
+vi1=\type Staff = vi1 <
+\global
+\notes \relative c'' {
 
   [d8 d d d] d4 [a16 b c a] |
   [b8 g ][ g g16 a][ b8 g ][ g g16 a] | 
@@ -80,9 +100,8 @@ vi1=\notes \relative c'' {
   [c8 g ][ g g16 f] e4 d |
   r8 g [g g16 f] e4 d |
   r8 [d16 a ][ b8 b16 c] a2 |
-  b1 |
-  \time 3/2;
-  \tempo 2=140;
+  b1 | 
+
   r4 d d d d d |
   e1. |
   r4 c c c c c |
@@ -98,8 +117,7 @@ vi1=\notes \relative c'' {
   a4 [c8 b] a4 [b8 c] f,4 [g8 a] |
   d,4 g g g g g |
   a [d,8 c] b4 [c8 d] a2 |
-  \time 4/4;
-  \tempo 4=80;
+
   b1 |
   [d8 d d d] d4 [a16 b c a] |
   [b8 g ][ g g16 a] [b8 g ][ g g16 a] | 
@@ -114,11 +132,11 @@ vi1=\notes \relative c'' {
   fis4 g2 fis!4 |
   \cadenza 1;
   g\breve
-  \bar "|.";
-}
+}>
 
-vi2=\notes \relative c'' {
-  \time 4/4;
+vi2=\type Staff = vi2 <
+\global
+\notes \relative c'' {
 
   r1 | r | r | 
   [d8 d d d] d4 [a16 b c a] |
@@ -149,7 +167,7 @@ vi2=\notes \relative c'' {
   e4 d r8 [c16 g ][ b8 b16 c] |
   a4 g2 fis4 |
   g1 |
-  \time 3/2;
+
   r1. |
   r4 [g'8 f] e4 [f8 g] c,4 [d8 e] |
   a,1. |
@@ -165,7 +183,7 @@ vi2=\notes \relative c'' {
   c,4 a a a a a |
   b [d8 c] b4 [c8 d] d,4 e |
   fis2 g fis! |
-  \time 4/4;
+
   g1 |
   r1 | r1 |
   [g'8 g g g] g4 [d16 e f d] |
@@ -179,13 +197,13 @@ vi2=\notes \relative c'' {
   [a d c b ][ a g fis e] d4 d' |
   \cadenza 1;
   b\breve
-  \bar "|.";
-}
+}>
 
 
-bc=\notes\transpose c'{
+bc=\type Staff = bc <
+\global
+\notes\transpose c'{
   \clef "bass";
-  \time 4/4;
 
   G2 d^"4 3" | G1 |
   g2 c4 G | d1^"3 4 3" |
@@ -203,7 +221,7 @@ bc=\notes\transpose c'{
   G1^"3 4 3" | c4 B c g |
   c B c G | d1^"3 4 3" |
   G1 |
-  \time 3/2;
+
   g1. | c |
   f | d^"\\textsharp" |
   g | c |
@@ -212,8 +230,9 @@ bc=\notes\transpose c'{
   d^"\\textsharp" | e |
   f | g1 B2 |
   d1.^"3 4 3" |
-  \time 4/4;
+
   G1 |
+  \bar ":|:";
   g2 fis | g G |
   g1^"3 4 3" | c |
   G^"3 4 3" | c2 G |
@@ -222,12 +241,10 @@ bc=\notes\transpose c'{
   ) d^"3 4 3" | 
   \cadenza 1;
   G\breve 
-  \bar "|.";
-}
+}>
 
 \score{
   \type StaffGroup <
-    \property StaffGroup.timeSignatureStyle = "old"
     \vi1
     \vi2
     \bc
index 38ea9553e81458f7a8192a9f7f3db5f9c9d1595e..4312a117a8fb2beda1d4d27d5e21c52a579faefb 100644 (file)
 
 %compatibility
 %urg
-\fetdef\repeatcolon{18}
+\fetdef\repeatcolon{20}
 \def\repeatbar{\repeatstopbar}
 \def\startrepeat{\repeatstartbar}
 \def\repeatbarstartrepeat{\repeatstopstart}