]> git.donarmstrong.com Git - lilypond.git/commitdiff
patch::: 1.3.94.jcn3
authorJan Nieuwenhuizen <janneke@gnu.org>
Tue, 10 Oct 2000 17:36:50 +0000 (19:36 +0200)
committerJan Nieuwenhuizen <janneke@gnu.org>
Tue, 10 Oct 2000 17:36:50 +0000 (19:36 +0200)
1.3.94.jcn3
===========

* Added Arpeggio and Trill elements to feta font.

* Yet another bugfix for output-property (Han-Wen)

---
Generated by janneke@gnu.org,
From = lilypond-1.3.94.jcn2, To = lilypond-1.3.94.jcn3

usage

    cd lilypond-source-dir; patch -E -p1 < lilypond-1.3.94.jcn3.diff

Patches do not contain automatically generated files
or (urg) empty directories,
i.e., you should rerun autoconf, configure

17 files changed:
CHANGES
VERSION
buildscripts/clean-fonts.sh
input/bugs/assigned-output-property.ly [deleted file]
input/les-nereides.ly
input/test/arpeggio.ly
lily/arpeggio-engraver.cc
lily/arpeggio.cc
lily/include/musical-request.hh
lily/include/output-property.hh
lily/my-lily-lexer.cc
lily/parser.yy
lily/span-arpeggio-engraver.cc
lily/span-arpeggio.cc
ly/engraver.ly
mf/feta-generic.mf
mf/feta-schrift.mf

diff --git a/CHANGES b/CHANGES
index bd7dbb932be4cfd782d7d3812adcfe74e8760ebb..3f4b565714317237c2046b963c8420c0bab32dd4 100644 (file)
--- a/CHANGES
+++ b/CHANGES
@@ -1,4 +1,16 @@
---- ../lilypond-1.3.94/CHANGES Sun Oct  8 10:27:38 2000
+--- ../lilypond-1.3.94.jcn2/CHANGES    Tue Oct 10 15:50:19 2000
+++ b/CHANGES   Tue Oct 10 19:36:50 2000
+@@ -1,3 +1,10 @@
+1.3.94.jcn3
+===========
+
+* Added Arpeggio and Trill elements to feta font.
+
+* Yet another bugfix for output-property (Han-Wen)
+
+ 1.3.94.jcn2
+ ===========
+ --- ../lilypond-1.3.94/CHANGES        Sun Oct  8 10:27:38 2000
 ++ b/CHANGES   Tue Oct 10 17:28:55 2000
 @@ -1,3 +1,13 @@
 1.3.94.lec1
diff --git a/VERSION b/VERSION
index 8e9ce4adc7ea3fd0f2d5f449f696e83390bb2db0..91886aae3be82b40adf809da56ec694b59915308 100644 (file)
--- a/VERSION
+++ b/VERSION
@@ -2,7 +2,7 @@ PACKAGE_NAME=LilyPond
 MAJOR_VERSION=1
 MINOR_VERSION=3
 PATCH_LEVEL=94
-MY_PATCH_LEVEL=lec1
+MY_PATCH_LEVEL=jcn3
 
 # use the above to send patches: MY_PATCH_LEVEL is always empty for a
 # released version.
index 597efa90327c4190b95ee21b06e134730ce00e3d..09ad8f13c658c1e5b0279639834e3e6364006b8b 100755 (executable)
@@ -9,17 +9,27 @@ esac
 
 # should use kpsepath 
 
+TEXDIRS=.
 if [ -d /var/lib/texmf ]; then
-    TEXDIR=/var/lib/texmf
-elif [ -d /var/texfonts ]; then
-    TEXDIR=/var/texfonts
+    TEXDIRS="$TEXDIRS /var/lib/texmf"
+fi
+if [ -d /var/spool/texmf ]; then
+    TEXDIRS="$TEXDIRS /var/tmp/texmf"
+fi
+if [ -d /var/tmp/texfonts ]; then
+    TEXDIRS="$TEXDIRS /var/spool/texfonts"
+fi
+if [ -d /var/texfonts ]; then
+    TEXDIRS="$TEXDIRS /var/texfonts"
+fi
+if [ -z $TEXDIR ]; then
+    TEXDIRS=". /var"
 else
-    TEXDIR=/var/
+    TEXDIRS=". $TEXDIRS"
 fi
 
 # remove possibly stale .pk/.tfm files 
-echo> /tmp/cleaning-font-dummy
-FILES=`find .  $TEXDIR -name "feta*$WHAT*tfm" -or -name "feta*$WHAT*pk"`
+FILES=`find $TEXDIRS -name "feta*$WHAT*tfm" -or -name "feta*$WHAT*pk"`
 
 echo removing $FILES
 rm  -f $FILES /tmp/cleaning-font-dummy
diff --git a/input/bugs/assigned-output-property.ly b/input/bugs/assigned-output-property.ly
deleted file mode 100644 (file)
index 5805f37..0000000
+++ /dev/null
@@ -1,30 +0,0 @@
-
-%
-% Using music-variable breaks output property
-%
-
-foo = \notes\relative c''{
-    \outputproperty #(make-type-checker 'note-head-interface) 
-       #'extra-offset = #'(2 . 3)
-    c2
-    c
-}
-
-\score{
-    <
-       \context Staff=a\notes\relative c''{
-           \outputproperty #(make-type-checker 'note-head-interface) 
-               #'extra-offset = #'(2 . 3)
-           c2
-           c
-       }
-        \context Staff=b \foo
-    >
-    \paper{
-       linewidth=-1.0;
-       \translator {
-           \ScoreContext
-           \consists "Mark_engraver";
-       }
-    }
-}
index 59a1cc1a746463ab731cdf52cb1e734edd824201..29a797ac7fde51f61b1ae447555ed35d922f17af 100644 (file)
@@ -8,7 +8,7 @@ cpp -P -traditional -o l-fake.ly  -DFAKE_GRACE les-nereides.ly
     title =      "LES N\\'ER\\'EIDES";
     subtitle =   "THE NEREIDS";
     enteredby =  "JCN";
-    piece =      "Allegretto scherzando";
+    %piece =      "Allegretto scherzando";
     copyright =  "public domain";
     description = "Natiest piece of competition at http://www.orphee.com/comparison/study.html, see http://www.orphee.com/comparison/gray.pdf";
     comment =     "LilyPond (1.3.93) can't really do this yet, I guess";
@@ -38,13 +38,15 @@ global = \notes{
 treble = \context Voice=treble \notes\relative c''{
     % Broken?
     \property Voice.NoteColumn \push #'horizontal-shift = #0
-    r2
+    \outputproperty #(make-type-checker 'text-item-interface) 
+           #'extra-offset = #'(-6 . 2)
+    r2^"Allegretto scherzando"
     %2
     \property Voice.Stem \pop #'direction
     \property Voice.Stem \push #'direction = #1
-    r4 <cis eis a cis> r2
+    r4 <cis\arpeggio eis a cis> r2
     %3
-    r4 <cis fis a cis> r8.
+    r4 <cis\arpeggio fis a cis> r8.
     \translator Staff=bass
     cis,16^2^"m.d."( <fis8 fis,> <e! e,!>
     %4
@@ -53,7 +55,8 @@ treble = \context Voice=treble \notes\relative c''{
     \property Voice.Slur \pop #'direction
     \property Voice.Slur \push #'direction = #1
     %% 8va
-    cis''''4^"m.g." (
+    \property PianoStaff.connectArpeggios = ##t
+    cis''''4^"m.g."\arpeggio (
 
 #ifndef FAKE_GRACE
 
@@ -115,7 +118,7 @@ trebleTwo = \context Voice=trebleTwo \notes\relative c''{
     s4
     \property Voice.Stem \pop #'direction
     \property Voice.Stem \push #'direction = #-1
-    <cis4 a fis dis>
+    <cis4\arpeggio a fis dis>
 
 #ifdef FAKE_GRACE
     s32*16
@@ -152,7 +155,7 @@ bass = \context Voice=bass \notes\relative c{
     \property Voice.Stem \pop #'direction
     \property Voice.Stem \push #'direction = #-1
     \property Voice.slurEndAttachment = #'stem
-    <)a''4 eis cis> 
+    <)a''4\arpeggio eis cis> 
     %\stemboth
     \property Voice.slurEndAttachment = ##f
     \translator Staff=bass
@@ -168,7 +171,7 @@ bass = \context Voice=bass \notes\relative c{
     \property Voice.Stem \pop #'length
     \property Voice.Stem \pop #'direction
     \property Voice.Stem \push #'direction = #-1
-    <)a' fis cis>
+    <)a'\arpeggio fis cis>
     \translator Staff=bass
     \property Voice.Stem \pop #'direction
     r2
@@ -184,7 +187,7 @@ bass = \context Voice=bass \notes\relative c{
     \property Voice.Stem \push #'direction = #0
     <
         %urg: staff-change: ! on dis
-        <cis'' a fis dis!>
+        <cis''\arpeggio a fis dis!>
 %      { s8. \clef bass;}
     >
 
@@ -242,16 +245,23 @@ middleDynamics = \context Dynamics=middle \notes{
 
 #ifdef FAKE_GRACE
     s32*12
+    \outputproperty #(make-type-checker 'dynamic-interface) 
+           #'extra-offset = #'(0 . 1.5)
     s32\> s s \!s
 #endif
-
-    s32 s-"rall." s s
+    s32 
+    \outputproperty #(make-type-checker 'text-item-interface) 
+           #'extra-offset = #'(0 . 1.5)
+    s-"rall." s s
     s8 s4
 
     \outputproperty #(make-type-checker 'dynamic-interface) 
-           #'extra-offset = #'(0 . 10)
+           #'extra-offset = #'(0 . 3.5)
     s1\mf-"a tempo"
-    s8 s8\mf s4 s4 s8\> s32 s s \!s
+    s8
+    \outputproperty #(make-type-checker 'dynamic-interface) 
+           #'extra-offset = #'(-1 . 3.5)
+    s8\mf s4 s4 s8\> s32 s s \!s
 }
 
 lowerDynamics = \context Dynamics=lower \notes{
@@ -299,11 +309,10 @@ lowerDynamics = \context Dynamics=lower \notes{
            \treble
            \trebleTwo
         >
-       %\context Dynamics=middle <
-       %    \global
-       %    \middleDynamics
-       %>
-       \middleDynamics
+       \context Dynamics=middle <
+           \global
+           \middleDynamics
+       >
         \context Staff=bass <
            \clef bass;
            \global
@@ -328,7 +337,9 @@ lowerDynamics = \context Dynamics=lower \notes{
            %Generic_property_list = #generic-lyrics-properties
            \consists "Property_engraver";
            DynamicsMinimumVerticalExtent = #(cons -3 -3)
-           VerticalAlignment \push #'threshold = #'(8 . 8) 
+           %VerticalAlignment \push #'threshold = #'(8 . 8) 
+           %VerticalAlignment \push #'threshold = #'(10 . 10) 
+           VerticalAlignment \push #'threshold = #'(9 . 9) 
 
            startSustain = #"Ped."
            stopSustain = #"*"
@@ -352,12 +363,17 @@ lowerDynamics = \context Dynamics=lower \notes{
 
        \translator {
            \VoiceContext
-           TextScript \push #'style = #"italic"
+           %TextScript \push #'style = #"italic"
+           %TextScript \push #'font-size = #3
+           TextScript \push #'size = #"Large"
+           TextScript \push #'font-size = #"Large"
         }
        \translator {
            \PianoStaffContext
            \accepts Dynamics;
-           VerticalAlignment \push #'threshold = #'(8 . 8) 
+           %VerticalAlignment \push #'threshold = #'(8 . 8) 
+           %VerticalAlignment \push #'threshold = #'(6 . 6)
+           VerticalAlignment \push #'threshold = #'(7 . 7)
         }
        \translator {
            \GraceContext
index 8b81878ad4e9b869c4c19b291799d962911aba46..9e7f930acec09ef6553909d73cf70533ffd8d9a9 100644 (file)
@@ -1,20 +1,15 @@
 \score{
-    \context StaffGroup < 
-    %< 
-         \context Staff=one \notes\relative c''{
-             f,
-             <f, a c>
-         }
-         \context Staff=two \notes\relative c{
-             \clef bass;
-             g
-             <g b d>
+    \context PianoStaff < 
+        \context Staff=one \notes\relative c''{
+            fis,\arpeggio
+            %%\property PianoStaff.SpanArpeggio \push #'connect = ##t
+            \property PianoStaff.connectArpeggios = ##t
+            <fis,\arpeggio a c>
          }
+        \context Staff=two \notes\relative c{
+            \clef bass;
+            g
+            <g\arpeggio b d>
+        }
     >
-    \paper{
-       \translator{
-           \StaffContext
-           \consists Arpeggio_engraver;
-       }
-    }
 }
index dccb27e6bac92a6ac2e4afc8ee4a5517ac1684a9..3c9504512ef84492d0eaf3c33329ba0b9954b379 100644 (file)
@@ -9,8 +9,13 @@
 #include "engraver.hh"
 #include "group-interface.hh"
 #include "item.hh"
+#include "musical-request.hh"
 #include "arpeggio.hh"
 #include "stem.hh"
+#include "local-key-item.hh"
+#include "rhythmic-head.hh"
+#include "side-position-interface.hh"
+#include "staff-symbol-referencer.hh"
 
 class Arpeggio_engraver : public Engraver
 {
@@ -22,23 +27,49 @@ protected:
   virtual void acknowledge_element (Score_element_info);
   virtual void process_acknowledged ();
   virtual void do_pre_move_processing ();
+  virtual bool do_try_music (Music *);
 
 private:
   Item* arpeggio_; 
+  Arpeggio_req *arpeggio_req_;
   Link_array <Score_element> stems_;
+  Link_array<Score_element> supports_;
 };
 
 Arpeggio_engraver::Arpeggio_engraver ()
 {
   arpeggio_ = 0;
+  arpeggio_req_ = 0;
+}
+
+bool
+Arpeggio_engraver::do_try_music (Music* m)
+{
+  if (!arpeggio_req_)
+    {
+      if (Arpeggio_req *a = dynamic_cast<Arpeggio_req*> (m))
+       {
+         arpeggio_req_ = a;
+         return true;
+       }
+    }
+  return false;
 }
 
 void
 Arpeggio_engraver::acknowledge_element (Score_element_info info)
 {
-  if (Stem::has_interface (info.elem_l_))
+  if (arpeggio_req_)
     {
-      stems_.push (info.elem_l_);
+      if (Stem::has_interface (info.elem_l_))
+       {
+         stems_.push (info.elem_l_);
+       }
+      else if (Rhythmic_head::has_interface (info.elem_l_)
+              || Local_key_item::has_interface (info.elem_l_))
+       {
+         supports_.push (info.elem_l_);
+       }
     }
 }
 
@@ -48,13 +79,20 @@ Arpeggio_engraver::process_acknowledged ()
   if (!arpeggio_ && !stems_.empty ())
     {
       arpeggio_ = new Item (get_property ("Arpeggio"));
+      arpeggio_->set_parent (stems_[0], Y_AXIS);
+      Side_position::set_axis (arpeggio_, X_AXIS);
+      Side_position::set_direction (arpeggio_, LEFT);
       Pointer_group_interface pgi (arpeggio_, "stems");
       for (int i = 0; i < stems_.size (); i++)
        {
          pgi.add_element (stems_[i]);
-         arpeggio_->add_dependency (stems_[i]);
+         Side_position::add_support (arpeggio_, stems_[i]);
+       }
+      for (int i = 0; i < supports_.size (); i++)
+       {
+         Side_position::add_support (arpeggio_, supports_[i]);
        }
-      announce_element (arpeggio_, 0);
+      announce_element (arpeggio_, arpeggio_req_);
     }
 }
 
@@ -66,7 +104,9 @@ Arpeggio_engraver::do_pre_move_processing ()
       typeset_element (arpeggio_);
       arpeggio_ = 0;
     }
+  arpeggio_req_ = 0;
   stems_.clear ();
+  supports_.clear ();
 }
 
 
index 7500ef844b707cb23fbe73c645114e92ef873671..b05187d8050e5f032defccc062a3a9eafa0121a5 100644 (file)
@@ -34,15 +34,15 @@ Arpeggio::brew_molecule (SCM smob)
     }
 
   Molecule mol;
-  Molecule dot = me->paper_l ()->lookup_l (0)->afm_find ("dots-dot");
-  Real half_space = Staff_symbol_referencer::staff_space (me) / 2;
-  for (Real i = iv[MIN]; i <= iv[MAX]; i++)
+  Molecule arpeggio = me->paper_l ()->lookup_l (0)->afm_find ("scripts-arpeggio");
+  Real staff_space = Staff_symbol_referencer::staff_space (me);
+  for (int i = (int)iv[MIN]/ 2; i < (int)(iv[MAX] - 1)/ 2; i++)
     {
-      Molecule d (dot);
-      d.translate_axis (i * half_space, Y_AXIS);
-      mol.add_molecule (d);
+      Molecule a (arpeggio);
+      a.translate_axis (i * staff_space, Y_AXIS);
+      mol.add_molecule (a);
     }
-  mol.translate (Offset (-3, 0));
+  mol.translate (Offset (-2 * staff_space, 0);
 
   return mol.create_scheme (); 
 }
index 0c2d6f928dd3c925434307227503c64ca8a1a394..e928984f3b89fa96dd849543204b8e421e56c682 100644 (file)
@@ -176,4 +176,11 @@ class Melisma_playing_req : public Request
 public:
   VIRTUAL_COPY_CONS (Music);
 };
+
+class Arpeggio_req : public Request
+{
+public:
+  VIRTUAL_COPY_CONS (Music);
+};
+
 #endif // MUSICALREQUESTS_HH
index 8590868d81664b5e4ccda4b4892efd6845a4310a..bea2e0e2d662705d832fbd8cb9f227a48f52204d 100644 (file)
@@ -11,8 +11,7 @@
 #define OUTPUT_PROPERTY_HH
 
 #include "music.hh"
-#include "protected-scm.hh"
-
+//#include "protected-scm.hh"
 
 /*
   
@@ -24,7 +23,8 @@ props:
 class Output_property : public Music
 {
 public:
-  Output_property(SCM, SCM, SCM);
+  VIRTUAL_COPY_CONS (Music);
+  Output_property (SCM, SCM, SCM);
 };
 
 #endif /* OUTPUT_PROPERTY_HH */
index e394708996916d363c30cd15ba411f7b039d6c3c..c85b0a398e3b66f2ca2ac41e56452279384e5ce9 100644 (file)
@@ -24,6 +24,7 @@
 
 static Keyword_ent the_key_tab[]={
   {"autochange", AUTOCHANGE},
+  {"arpeggio", ARPEGGIO },
   {"spanrequest", SPANREQUEST},
   {"commandspanrequest", COMMANDSPANREQUEST},  
   {"simultaneous", SIMULTANEOUS},
index 701f5c363b24a1e0556a33739b63722257c24907..0fd6d6d14b63db0ea0e0cc7ece2ca0d8e10d8b78 100644 (file)
@@ -127,6 +127,7 @@ yylex (YYSTYPE *s,  void * v_l)
 
 /* tokens which are not keywords */
 %token AUTOCHANGE
+%token ARPEGGIO
 %token TEXTSCRIPT
 %token ACCEPTS
 %token ALTERNATIVE
@@ -1070,6 +1071,11 @@ verbose_request:
                a->set_spot (THIS->here_input ());
                $$ = a;
        }
+       | ARPEGGIO {
+               Arpeggio_req *a = new Arpeggio_req;
+               a->set_spot (THIS->here_input ());
+               $$ = a;
+       }
        ;
 
 sup_quotes:
index 8fb13aeb93cdca8f98194f8d81899a0d8de01fa3..90b0767e67feaffaa15acd0852fc7c3a79868778 100644 (file)
@@ -7,10 +7,13 @@
 */
 
 #include "engraver.hh"
+#include "lily-guile.hh"
 #include "item.hh"
 #include "arpeggio.hh"
 #include "span-arpeggio.hh"
 #include "group-interface.hh"
+#include "side-position-interface.hh"
+#include "staff-symbol-referencer.hh"
 
 
 /** 
@@ -53,9 +56,12 @@ Span_arpeggio_engraver::acknowledge_element (Score_element_info info)
 void
 Span_arpeggio_engraver::process_acknowledged ()
 {
-  if (arpeggios_.size () > 1 && !span_arpeggio_) 
+  if (!span_arpeggio_ && arpeggios_.size () > 1
+      && to_boolean (get_property ("connectArpeggios")))
     {
       span_arpeggio_ = new Item (get_property ("SpanArpeggio"));
+      span_arpeggio_->set_parent (arpeggios_[0], Y_AXIS);
+      Side_position::set_axis (span_arpeggio_, X_AXIS);
       Pointer_group_interface pgi (span_arpeggio_, "arpeggios");
       for (int i = 0; i < arpeggios_.size () ; i++)
        {
@@ -63,9 +69,6 @@ Span_arpeggio_engraver::process_acknowledged ()
          span_arpeggio_->add_dependency (arpeggios_[i]);
        }
       
-      span_arpeggio_->set_parent (arpeggios_[0], Y_AXIS);
-      span_arpeggio_->set_parent (arpeggios_[0], X_AXIS);
-      
       announce_element (span_arpeggio_, 0);
     }
 }
index 5a574a8eb84e1696962f4ff94e5544e070fc5241..ce588cea2bd86cccd088f831062d39a0ed88d0d3 100644 (file)
@@ -40,7 +40,7 @@ Span_arpeggio::brew_molecule (SCM smob)
       common = arpeggio->common_refpoint (common, Y_AXIS);
     }
   // Hmm, nothing in common?
-  if (0) //(common)
+  if (0) //common)
     for (SCM s = me->get_elt_property ("arpeggios"); gh_pair_p (s); s = gh_cdr (s))
       {
        Score_element *arpeggio = unsmob_element (gh_car (s));
@@ -52,17 +52,16 @@ Span_arpeggio::brew_molecule (SCM smob)
     iv = Interval (-23, 5);
 
   Molecule mol;
-  Molecule dot = me->paper_l ()->lookup_l (0)->afm_find ("dots-dot");
-  Real half_space = Staff_symbol_referencer::staff_space (me) / 2;
-  for (Real i = iv[MIN]; i < iv[MAX]; i++)
+  Molecule arpeggio = me->paper_l ()->lookup_l (0)->afm_find ("scripts-arpeggio");
+  Real staff_space = Staff_symbol_referencer::staff_space (me);
+  for (int i = (int)iv[MIN]/ 2; i < (int)(iv[MAX] - 1)/ 2; i++)
     {
-      Molecule d (dot);
-      d.translate_axis (i * half_space, Y_AXIS);
-      mol.add_molecule (d);
+      Molecule a (arpeggio);
+      a.translate_axis (i * staff_space, Y_AXIS);
+      mol.add_molecule (a);
     }
-  mol.translate (Offset (-6, 0));
+  mol.translate (Offset (-2 * staff_space, 0);
 
   return mol.create_scheme (); 
 }
 
-
index de43a4918ed506889abaa129ee57b3c3538dbbd6..7ec843a289c2be4cc0951404b38f276315fbe04e 100644 (file)
@@ -31,10 +31,8 @@ StaffContext=\translator {
        \consists "Collision_engraver";
        \consists "Rest_collision_engraver";
        \consists "Local_key_engraver";
-
        \consists "Piano_pedal_engraver";
-
-%      \consists "Arpeggio_engraver";
+       \consists "Arpeggio_engraver";
 
        \consistsend "Axis_group_engraver";
 
@@ -202,15 +200,16 @@ GrandStaffContext=\translator{
        \accepts "Staff";
 }
 
-PianoStaffContext = \translator{\GrandStaffContext
-       alignmentReference = \center;
+PianoStaffContext = \translator{
+       \GrandStaffContext
+       \name "PianoStaff";
 
        \consists "Vertical_align_engraver";
 
+       alignmentReference = \center;
        VerticalAlignment \push #'threshold = #'(12 . 12) 
 
 %      \consistsend "Axis_group_engraver";
-       \name "PianoStaff";
 }
 
 StaffGroupContext= \translator {
index 4b53e941bf08ce5b93063ae02e62322061c925cd..365f26c54cecbca0e6d55e3756e464dbfd5a0516 100644 (file)
@@ -39,9 +39,9 @@ else:
 %      input feta-bolletjes;   
 %      input feta-banier;
 %      input feta-eindelijk;
-       input feta-klef;
+%      input feta-klef;
 %      input feta-toevallig;
-%      input feta-schrift;
+       input feta-schrift;
 %      input feta-haak;
 %      input feta-timesig;
 %      input feta-pendaal;
index 481e378e501d2b81d860d94a778ce696b2eb807e..f4fc744a2792bd7579a8212ae00d70b89cfc325e 100644 (file)
@@ -11,7 +11,6 @@
 
 fet_begingroup("scripts")
 
-
 def draw_fermata =
   save alpha, radius, crook_thinness, crook_fatness, dot_diam;
   
@@ -698,6 +697,70 @@ fet_beginchar("Coda", "coda", "coda")
 
 fet_endchar;
 
+thick#:=1/24designsize;
+define_blacker_pixels(thick);
+
+rthin:=1/8*staff_space;
+rthick:=2thick+rthin;
+
+def draw_arpeggio =
+       save alpha;
+       alpha:=-40;
+       save ne,nw,se,sw; pair ne,nw,se,sw;
+       save x,y;
+       
+       se=dir alpha; nw=dir (alpha+180);
+       ne=dir (alpha+90); sw=dir (alpha-90);
+       penpos1(rthin,alpha+90);
+       penpos2(5/4rthick,alpha);
+       penpos4(5/4rthick,alpha);
+       penpos5(rthin,alpha+90);
+       penpos3(3/4rthick,alpha);
+
+       z1=(width/2, height) - overshoot*se;
+       z2=2[z4,(width/2,height/2)];
+       z3=1/2[z2,z4];
+       x4=2/8staff_space;
+       y4=rthin;
+
+       z5=2[z1,(width/2,height/2)];
+       z6=z2l+1/2rthin*sw;
+       z7=z4l+1/2rthin*sw+1/2rthin*se;
+       z8=2[z6,(width/2,height/2)];
+       z9=2[z7,(width/2,height/2)];
+       
+       fill z1l{se}..{se}z6..z3l..z7{se}..{se}z5l..z5r{nw}..{nw}z8..z3r..z9{nw}..{nw}z1r.. cycle;
+       penlabels(1,2,3,4,5,6,7,8,9);
+       enddef;
+
+fet_beginchar("Arpeggio","arpeggio","arpeggio");
+       %draw_staff (-2, 2, 0.0);       
+       save height, overshoot, width;
+       height# = staff_space#;
+       width# = 0.8height#;
+        overshoot# = 0.25 staff_space#;
+       define_pixels (height,overshoot,width);
+       set_char_box(0, width#, 0, height#);
+       draw_arpeggio;
+       fet_endchar;
+
+% Extendable Trill symbol.
+% Not yet used
+% Rename me to Trill, rename Trill to Tr?
+fet_beginchar("Trill-element","trill-element","trill-element");
+       save height, overshoot;
+       height# = staff_space#;
+       width# = 0.8height#;
+        overshoot# = 0.25 staff_space#;
+       define_pixels (height,overshoot,width);
+       set_char_box(0, height#, 0, width#);
+       draw_arpeggio;
+       currentpicture := currentpicture shifted -(width/2, height/2);
+       currentpicture := currentpicture rotated 90;
+       currentpicture := currentpicture shifted (height/2, width/2);
+       fet_endchar;
+
+% Hmm
 input feta-slag;
 
 fet_endgroup("scripts");