]> git.donarmstrong.com Git - lilypond.git/commitdiff
* lily/ledger-line-spanner.cc (print): swap linear_combination
authorHan-Wen Nienhuys <hanwen@xs4all.nl>
Fri, 29 Oct 2004 15:09:04 +0000 (15:09 +0000)
committerHan-Wen Nienhuys <hanwen@xs4all.nl>
Fri, 29 Oct 2004 15:09:04 +0000 (15:09 +0000)
arguments, effectively shortens ledger line.

* Documentation/user/GNUmakefile
($(outdir)/lilypond/lilypond.html): use find to remove files.

* lily/main.cc: --no-pages option.

ChangeLog
Documentation/user/GNUmakefile
Documentation/user/invoking.itely
debian/control
lily/include/main.hh
lily/ledger-line-spanner.cc
lily/main.cc
lily/paper-book.cc
make/lilypond.fedora.spec.in

index 699cb234e6bc84774a3e0fa6fbe0378a8a8fde12..934572469fa3775f261d1e6758db225cfb822ad7 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,13 @@
+2004-10-29  Han-Wen Nienhuys  <hanwen@xs4all.nl>
+
+       * lily/ledger-line-spanner.cc (print): swap linear_combination
+       arguments, effectively shortens ledger line. 
+
+       * Documentation/user/GNUmakefile
+       ($(outdir)/lilypond/lilypond.html): use find to remove files.
+
+       * lily/main.cc: --no-pages option.
+
 2004-10-28  Carl Sorensen  <carldsorensen@comcast.net>
 
        * Documentation/user/notation.itely (Fret diagrams): add extra
index 675608ff48417de375a2244f8cff799eb8432ec5..073924a74ba3326ad0cf85f9c0f1b600c576be16 100644 (file)
@@ -99,7 +99,7 @@ $(outdir)/lilypond/lilypond.html: $(outdir)/lilypond.texi
        $(MAKEINFO) -I$(outdir) --output=$(outdir)/lilypond --css-include=$(abs-srcdir)/Documentation/texinfo.css --html $<
        $(MAKEINFO) -I$(outdir) --output=$@ --css-include=$(abs-srcdir)/Documentation/texinfo.css --html --no-split --no-headers $<
        perl -i~ -pe 's!../lilypond-internals!lilypond-internals/!g' $(outdir)/lilypond.html
-       rm -f $(outdir)/lilypond/*.png $(outdir)/lilypond/*.ly
+       find $(outdir)/lilypond/ -name '*'.png -o -name '*'.ly | xargs rm -f
 # symbolic links to save space 
        (cd $(outdir)/lilypond/ ; ln -sf ../*.png ../*.ly . )
 
index d0005ebde0744f6f39f31e09bb0cfdac60415507..9bdbc0b22c81b41bd8b7b0e96f1aa7fab3b8e500 100644 (file)
@@ -90,8 +90,9 @@ Set init file to @var{file} (default: @file{init.ly}).
     Generate PDF.  This implies @code{--ps}.
 @item --preview
     Generate an output file containing the titles and the first system
-of the score.
-
+@item --no-pages
+    Do not generate the full pages. Useful in combination with
+@code{--preview}.
 @item -s,--safe
 Do not trust the @code{.ly} input. 
 
index 5cccf89d89572ad428709f29c3f022202c4f3a6f..f64a3eb59bbe5f7f36015ce691c1fa22c970631e 100644 (file)
@@ -12,6 +12,7 @@ Architecture: any
 Replaces: lilypond1.3
 Provides: lilypond1.3
 Depends: ${shlibs:Depends}, tetex-bin (>= 1.0.5-1), tetex-extra (>= 1.0-1), python, guile-1.6 | guile, ${misc:Depends}, lilypond-data (= ${Source-Version})
+# , ec-fonts-mftraced (>= 1.0.5-1)
 Recommends: lilypond-doc
 Conflicts: lilypond1.3 (<= 1.3.132-1), musixtex-fonts
 Description: A program for typesetting sheet music
index 3e055091acb6e8059356a03ec550796c20e82509..bd71147357061c070f5c3ab7e80d3656544c9b55 100644 (file)
@@ -45,6 +45,7 @@ extern bool make_ps;
 extern bool make_pdf;
 extern bool make_tex;
 extern bool make_preview;
+extern bool make_pages;
 
 /* misc */
 extern Array<String> failed_files;
index 200c1d91764a5bfdc6f6a19987833ca3594ce3fc..d2eda9a07eb0b2d1df7f6a5f2e8ad5919243779e 100644 (file)
@@ -207,7 +207,8 @@ Ledger_line_spanner::print (SCM smob)
       int pos = Staff_symbol_referencer::get_rounded_position (h);
       if (abs (pos) > interspaces + 1)
        {
-         Interval ledger_size = h->extent (common[X_AXIS], X_AXIS);
+         Interval head_size = h->extent (common[X_AXIS], X_AXIS);
+         Interval ledger_size = head_size;
          ledger_size.widen (ledger_size.length ()* length_fraction);
 
          Interval max_size = reqs[Paper_column::get_rank (h->get_column ())][Direction (sign(pos))].ledger_extent_;
@@ -216,11 +217,11 @@ Ledger_line_spanner::print (SCM smob)
          Real left_shorten =0.0;
          if (Grob * g = unsmob_grob (h->get_property ("accidental-grob")))
            {
+             Interval accidental_size = g->extent (common[X_AXIS], X_AXIS);
              Real d =
-               linear_combination (Drul_array<Real> (h->extent (common[X_AXIS], X_AXIS)[LEFT],
-                                                     g->extent (common[X_AXIS], X_AXIS)[RIGHT]),
-                               
-                                   0.5);
+               linear_combination (Drul_array<Real> (accidental_size[RIGHT],
+                                                     head_size[LEFT]),                         
+                                   0.0);
 
              left_shorten =  (-ledger_size[LEFT] + d) >?  0 ;
 
index aeeaa51997b7f7dba4f5d2d38779c1eab2fcbb50..46dcf7e9792954c79cdaf8be454868388fb6639c 100644 (file)
@@ -68,6 +68,7 @@ bool make_dvi = false;
 bool make_ps = false;
 bool make_png = false;
 bool make_preview = false;
+bool make_pages = true;
 bool make_tex = false;
 
 /*
@@ -135,6 +136,7 @@ static Long_option_init options_static[] =
     {0, "no-layout", 'm',  _i ("produce MIDI output only")},
     {_i ("FILE"), "output", 'o',  _i ("write output to FILE")},
     {0, "preview", 'p',  _i ("generate a preview")},
+    {0, "no-pages", 0,  _i ("don't generate full pages")},
     {0, "png", 0,  _i ("generate PNG")},
     {0, "ps", 0,  _i ("generate PostScript")},
     {0, "dvi", 0,  _i ("generate DVI")},
@@ -386,6 +388,8 @@ parse_argv (int argc, char **argv)
            make_tex = true;
          else if (String (opt->longname_str0_) == "preview")
            make_preview = true;
+         else if (String (opt->longname_str0_) == "no-pages")
+           make_pages = false;
          break;
          
        case 'v':
index 8a62290fc178d40265de171a7d855a9b1ed08468..f7ead445a93b2483ad6afe0ffc2b45ec8f26c0f1 100644 (file)
@@ -170,21 +170,23 @@ Paper_book::output (String outname)
        scopes = scm_cons (header_, scopes);
   
       String mod_nm = "scm framework-" + format;
-      
-      SCM mod = scm_c_resolve_module (mod_nm.to_str0 ());
-      SCM func = scm_c_module_lookup (mod, "output-framework");
 
-      func = scm_variable_ref (func);
-      scm_apply_0 (func, scm_list_n (out->self_scm (),
-                                    self_scm (),
-                                    scopes,
-                                    dump_fields (),
-                                    scm_makfrom0str (outname.to_str0 ()),
-                                    SCM_UNDEFINED));
-      out->close ();
-      scm_gc_unprotect_object (out->self_scm ());
+      SCM mod = scm_c_resolve_module (mod_nm.to_str0 ());
+      if (make_pages)
+       {
+         SCM func = scm_c_module_lookup (mod, "output-framework");
 
-      post_processing (mod, scm_makfrom0str (file_name.to_str0 ()));
+         func = scm_variable_ref (func);
+         scm_apply_0 (func, scm_list_n (out->self_scm (),
+                                        self_scm (),
+                                        scopes,
+                                        dump_fields (),
+                                        scm_makfrom0str (outname.to_str0 ()),
+                                        SCM_UNDEFINED));
+         out->close ();
+         scm_gc_unprotect_object (out->self_scm ());
+         post_processing (mod, scm_makfrom0str (file_name.to_str0 ()));
+       }
       
       if (make_preview)
        {
index b843977b2b322af079599f3720cbb19fec8b954f..b51f0a6de6e9a391844c3ab64f34a148864e6c8d 100644 (file)
@@ -18,7 +18,7 @@ Buildrequires: t1utils bison flex mftrace ImageMagick
 Buildrequires: texinfo >= 4.6
 Buildrequires: guile-devel >= 1.6.4-8
 Requires: tetex  tetex-latex libstdc++ python  tetex-dvips tetex-latex
-Requires: guile >= 1.6.4-8 ec-fonts-mftraced >= 1.0.4
+Requires: guile >= 1.6.4-8 ec-fonts-mftraced >= 1.0.5
 
 %description
 LilyPond lets you create music notation.  It produces