]> git.donarmstrong.com Git - lilypond.git/commitdiff
* elisp/lilypond-mode.el (LilyPond-command-alist): remove 2midi
authorHan-Wen Nienhuys <hanwen@xs4all.nl>
Sun, 12 Jun 2005 18:42:49 +0000 (18:42 +0000)
committerHan-Wen Nienhuys <hanwen@xs4all.nl>
Sun, 12 Jun 2005 18:42:49 +0000 (18:42 +0000)
(LilyPond-command-alist): use -f ps (thanks to Pal Benko)

* input/sakura-sakura.ly: add \midi.

* buildscripts/mutopia-index.py (find): use /usr/bin/find
iso. python find.

* ttftool/test.c (main): cosmetics.

* ttftool/util.c (surely_lseek): use stdio FILE's for I/O

* ttftool/test.c: new file. If compiled with -DTEST_TTFTOOL,
create a ttf2ps binary.

* scm/backend-library.scm (postscript->png): set rename-page-1 to
true.

ChangeLog
buildscripts/mutopia-index.py
elisp/lilypond-mode.el
input/mutopia/W.A.Mozart/mozart-hrn3-allegro.ily
input/sakura-sakura.ly
scm/backend-library.scm
ttftool/ps.c
ttftool/test.c
ttftool/util.c

index 632d44d2f7bbaadf05878f19a4c1d809ba2b314a..4621c0302311043ca43e69ad683c5ace2435a4ee 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,15 @@
 2005-06-12  Han-Wen Nienhuys  <hanwen@xs4all.nl>
 
+       * elisp/lilypond-mode.el (LilyPond-command-alist): remove 2midi
+       (LilyPond-command-alist): use -f ps (thanks to Pal Benko)
+
+       * input/sakura-sakura.ly: add \midi.
+
+       * buildscripts/mutopia-index.py (find): use /usr/bin/find
+       iso. python find. 
+
+       * ttftool/test.c (main): cosmetics.
+
        * ttftool/util.c (surely_lseek): use stdio FILE's for I/O 
 
        * ttftool/test.c: new file. If compiled with -DTEST_TTFTOOL,
index 161151c691833c76a8dded9595a5d489f593d5a4..afaf45fdc2e18c13b604b952bcf8208b341de422 100644 (file)
@@ -9,30 +9,15 @@ import re
 import stat
 import sys
 
-_debug = 0
-_prune = ['(*)']
-
-def find (pattern, dir = os.curdir):
-        lst = []
-        names = os.listdir (dir)
-        names.sort ()
-        for name in names:
-                if name in (os.curdir, os.pardir):
-                        continue
-                fullname = os.path.join (dir, name)
-                if fnmatch.fnmatch (name, pattern):
-                        lst.append (fullname)
-                if os.path.isdir (fullname) and not os.path.islink (fullname):
-                        for p in _prune:
-                                if fnmatch.fnmatch (name, p):
-                                        if _debug:
-                                               print "skip", `fullname`
-                                        break
-                        else:
-                                if _debug:
-                                       print "descend into", `fullname`
-                                lst = lst + find (pattern, fullname)
-        return lst
+def find (pat, dir):
+       f = os.popen ('find %s -name "%s"'% (dir, pat))
+       lst = []
+       for a in f.readlines():
+               a = a[:-1]
+               lst.append (a)
+       return lst
+
+
 
 headertext= r"""
 
@@ -124,6 +109,8 @@ hr { border:0; height:1; color: #000000; background-color: #000000; }\n
                list.write (headertext_nopics)
 
        for ex in inputs:
+               print ex
+               
                (base, ext) = os.path.splitext (ex)
                (base, ext2) = os.path.splitext (base)          
                ext = ext2 + ext
@@ -163,13 +150,25 @@ hr { border:0; height:1; color: #000000; background-color: #000000; }\n
                                                   % (type, size))
                                pictures = ['jpeg', 'png', 'xpm']
                                lst.write ('\n')
+                       else:
+                               print "can't find" , `file_name`
 
                list_item (base + ext, 'The input', 'ASCII')
+
+               pages_found = 0
                for page in range (1, 100):
+                       pages_found += 1
                        f = base + '-page%d.png' % page
-                       if not os.path.isfile (f):
+                       
+                       if not os.path.isfile (f):
                                break
                        list_item (f, 'See a picture of page %d' % page, 'png')
+
+               if pages_found == 0 and os.path.exists (base + '.png'):
+                       list_item (base + ".png",
+                                  'See a picture', 'png')
+
+                       
                list_item (base + '.pdf', 'Print', 'PDF')
                list_item (base + '.midi', 'Listen', 'MIDI')
                list.write ('</ul>\n');
index 9330df71a528d35a41f3ab13b93697c9a8d07abd..39d15a3861eb52d78ab9e066c4b3cbca45c998f1 100644 (file)
@@ -425,8 +425,7 @@ in LilyPond-include-path."
     ("LilyPond" . (,(concat LilyPond-lilypond-command " %s") "%s" "%l" "View"))
     ("TeX" . ("tex '\\nonstopmode\\input %t'" "%t" "%d" "ViewDVI"))
     ("2Dvi" . (,(concat LilyPond-lilypond-command " -b tex %s") "%s" "%d" "LaTeX"))
-    ("2PS" . (,(concat LilyPond-lilypond-command "-b ps %s") "%s" "%p" "ViewPS"))
-    ("2Midi" . (,(concat LilyPond-lilypond-command " -m %s") "%s" "%m" "Midi"))
+    ("2PS" . (,(concat LilyPond-lilypond-command "-f ps %s") "%s" "%p" "ViewPS"))
     ("2Gnome" . (,(concat LilyPond-lilypond-command " -b gnome %s")))
 
     ("Book" . ("lilypond-book %x" "%x" "%l" "LaTeX"))
index 653f80e85b99bf2248472b42cefc2d31b047e452..e8e911d42247d24504f313bdaa67b64c0db45816 100644 (file)
@@ -127,7 +127,9 @@ allegro =
   \override Stem   #'stroke-style = #"grace"
    \longgrace d16( \endlonggrace 
   \revert Stem #'stroke-style }
- c8[) b16  c)]
+
+%% todo: should insert grace slur here.
+        c8[ b16  c)]
        \grace {
   \override Stem   #'stroke-style = #"grace"
    \longgrace c16 \endlonggrace 
index c3b0ea6ff3a19148e1c5f13eb4b5a3291e1bbc8b..f871be6a8358219eae9594748b2a706a33c55740 100644 (file)
@@ -7,30 +7,36 @@
   subtitle = "(Sakura, sakura)"
 }
 
-<<
-  \relative c'' {
-    %% Beams are melismata, no autobeams.
-    \set Staff.autoBeaming = ##f
 
-    | a4 a b2 | a4 a b2
-    | a4 b c b | a4 b8[ a] f2
-    | e4 c e f | e4 e8[ c] b2
-    | a'4 b c b | a4 b8[ a] f2
-    | e4 c e f | e4 e8[ c] b2
-    | a'4 a b2 | a4 a b2
-    | d,4 e b'8[ a] f4 | e1 \bar "|."
-  }
-  \addlyrics {
-    さ く ら さ く ら
-    の や ま も さ と も
-    み わ た す か ぎ り
-    か す み か く も か
-    あ さ ひ に に を う
-    さ く ら さ く ら
-    は な ざ か り
-  }
->>
+\score {
   
+  <<
+    \relative c'' {
+      %% Beams are melismata, no autobeams.
+      \set Staff.autoBeaming = ##f
+
+      | a4 a b2 | a4 a b2
+      | a4 b c b | a4 b8[ a] f2
+      | e4 c e f | e4 e8[ c] b2
+      | a'4 b c b | a4 b8[ a] f2
+      | e4 c e f | e4 e8[ c] b2
+      | a'4 a b2 | a4 a b2
+      | d,4 e b'8[ a] f4 | e1 \bar "|."
+    }
+    \addlyrics {
+      さ く ら さ く ら
+      の や ま も さ と も
+      み わ た す か ぎ り
+      か す み か く も か
+      あ さ ひ に に を う
+      さ く ら さ く ら
+      は な ざ か り
+    }
+  >>
+  \layout { }
+  \midi { \tempo 4=120 }
+  }
+
 %%% Local Variables:
 %%% coding: utf-8
 %%% End:
index 25b2ae9e7b3d427cd798467ba1a1af29a0779b1b..edd00941de9bfcb23d3998d71aef51fe05ed19f4 100644 (file)
@@ -94,7 +94,7 @@
     ;;     (string-append (basename name ".ps") "-page1.png" )))
   (let ((paper-size (sanitize-command-option paper-size-name))
        (verbose (ly:get-option 'verbose))
-       (rename-page-1 #t))
+       (rename-page-1 #f))
     (ly:message (_ "Converting to ~a...") "PNG")
     (make-ps-images name resolution paper-size rename-page-1 verbose)
     (ly:progress "\n")))
index 94104d7bdc9f24f6ca382243488ac8583bab8a7c..1fbf7d0b9ade3fe626b08d6b07d76e4ad3df0e5e 100644 (file)
@@ -8,7 +8,6 @@
 #include "proto.h"
 
 #include "ttftool.h"
-#include "libc-extension.hh"
 
 #define CHUNKSIZE 65534
 
index 76c18f5eb1382074df45241dde31ca1e2b48a944..49f653eafdf45362a5e02e94041de09c4183edd6 100644 (file)
@@ -12,7 +12,7 @@ main (int argc, char **argv)
   FILE *in, *out;
   if (argc != 3)
     {
-      fprintf (stderr, "test foo.ttf bar.pfa");
+      fprintf (stderr, "%s input.ttf output.pfa", argv[0]);
       exit (2);
     }
 
index 12f29da1f99b6cf11fd2f35e7e0b21efd0b7af62..d06a4fc7f8f3d36bee231b7db6b6583865d7f533 100644 (file)
@@ -9,7 +9,6 @@
 
 #include "types.h"
 #include "proto.h"
-#include "libc-extension.hh"
 #include "ttftool.h"