Re: Fixed, tight staff spacing

2008-02-20 Thread Marcus Macauley
Trevor Baca wrote:

 Hi Marcus,

 You can set #'line-break-system-details alignment-offsets independently and
 score-globally.

 For example:


 %%% BEGIN %%%

 \version 2.11.34

 \layout {
\context {
   \Score
   \override NonMusicalPaperColumn
   #'line-break-system-details = #'((alignment-offsets . (0 -6 -12 -18)))
}
 }

 \new GrandStaff 
\new Staff { \repeat unfold 128 f'8 }
\new Staff { \repeat unfold 128 f'8 }
\new Staff { \repeat unfold 128 f'8 }
\new Staff { \repeat unfold 128 f'8 }


 %%% END %%%


 This will force 6 staffspaces of vertical distance between the center
 stafflines of staves of all four staves. Collisions and even overprint are
 possible here, which sounds like exactly what you'll need for the type of
 conglomerate staff you're assembling.

 Let me know if this is the sorta thing you're looking for. I neglected to
 add this fact -- that alignment-offsets is globally settable, and also that
 the various #'line-break-system-details settings can all set independently
 of one another -- to 11.4.4 Explicit staff and system positioning; if this
 is what your project needs then I'll add a section to either 11.4.4 or the
 LSR, as Graham specifies.


This looks just about perfect! (The numbers I need are actually (0 -7
-13 -20).) My only gripe is that I'd rather specify the spacing between
some of the staves in a score, but leave others to be calculated
automatically. (I mentioned the four staves which I want to be fixed
relative to each other. Above those four staves will be a few more which
don't need to be fixed relative to each other, or relative to the top of
these four. If necessary, I'll arbitrarily fix those staves' positions
too -- e.g. (20 10 0 -7 -13 -20) -- but I'd prefer to let Lilypond
decide on the appropriate spacing, adjusting it where necessary to avoid
collisions.)

Thanks,
Marcus



___
lilypond-user mailing list
lilypond-user@gnu.org
http://lists.gnu.org/mailman/listinfo/lilypond-user


Fixed, tight staff spacing

2008-02-18 Thread Marcus Macauley
Hello,

In Lilypond 2.10.33, I want to have four staves per system, connected by a 
piano-style brace, with exactly enough space for two ledger lines between the 
upper two staves, one ledger line between the middle two staves, and two ledger 
lines between the lower two staves. (Measured from center line to center line, 
that works out to 7, 6, and 7 staff spaces, respectively.)

I tried the various methods described in section 11.4 of the manual (with and 
without PianoStaff), but I couldn't get the staves tight enough. (There are 
some notes which are supposed to overlap or collide with the staves above/
below.) It seems the only option left is 11.4.4 Explicit staff and system 
positioning, but I don't want to specify the position of each new system, just 
the amount of space between the staves within a system -- and this spacing 
should apply to every system throughout the score.

Any suggestions?

Thanks in advance,
Marcus Macauley



___
lilypond-user mailing list
lilypond-user@gnu.org
http://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Repositioning \tempo, and one other question

2006-10-23 Thread Marcus Macauley

OnionRingOfDoom wrote:

Like the subject says, is there any way to reposition the \tempo mark?  
I'd

love to be able to move it a bit to the left.


First, here's the fish:

\once \override Score.MetronomeMark #'X-offset = #-2

right before your first tempo mark to move it 2 spaces to the left. To  
move all of them the same way, omit \once.


Now, here's an example how to fish for this solution yourself: ;)

Go to the Documentation page for your version of Lilypond;
Click on User manual;
Scroll down, click on Appendix H LilyPond index
Find \tempo, and follow the link to Metronome marks
Notice the \override example at the bottom:
  \override Score.MetronomeMark #'padding = #2.5
To see what other settings (besides padding) are available,
Click on Program reference: MetronomeMark;
Notice the Standard settings listed;
Click on this-interface and that-interface at the bottom to see more  
available settings;
If you didn't know whether to use Score.MetronomeMark (rather than  
Staff.MetronomeMark or whatever), you could click on:

MetronomeMark objects are created by: Metronome_mark_engraver
and see at the bottom of that page:
Metronome_mark_engraver is part of contexts: Score
which would tell you what to use for Context in Context.MetronomeMark.
If the context is Voice, then you can usually omit it, e.g.:
\override TextScript ...
instead of
\override Voice.TextScript

Hope that helps!

Marcus

P.S. I don't know about your second question, concerning instrument names.  
I would try removing '= Soprano' and see if that helps, but that's just  
a guess.



___
lilypond-user mailing list
lilypond-user@gnu.org
http://lists.gnu.org/mailman/listinfo/lilypond-user


Re: \transpose within a Scheme function?

2006-10-21 Thread Marcus Macauley

Han-Wen Nienhuys wrote:


Marcus Macauley schreef:
I'm trying to figure out how to include a Lilypond \transpose function  
within a Scheme function. I'm not even sure if it makes sense to do


try (ly:music-transpose musicobject pitch)


Wow, there it is, right in front of my nose. I actually searched the  
Scheme functions page and was surprised not to find anything about  
transposition. I must have mistyped transpose when I searched for it;  
either that, or it was playing hide-and-seek with me -- and won ;)


Anyway, thanks for the tip.

Marcus


___
lilypond-user mailing list
lilypond-user@gnu.org
http://lists.gnu.org/mailman/listinfo/lilypond-user


\transpose within a Scheme function?

2006-10-20 Thread Marcus Macauley
I'm trying to figure out how to include a Lilypond \transpose function  
within a Scheme function. I'm not even sure if it makes sense to do that,  
but I haven't thought of a better way. Here's an example of what I'm  
trying to do:


overtones = #(define-music-function (parser location numbers fundamental)  
(list? ly:music?)

; For each of the numbers in the given list,
(for-each (lambda (number)
; transpose the given fundamental by a certain amount,
; and append that new note to a list called notes.
(case number
  ; (Currently, it only checks for the first overtone,  
which is trivial.)
  ((1) (append notes (ly:export \transpose c c  
{ $fundamental } 

  numbers)
)

This is incomplete, but eventually I want to be able to type something  
like:

\overtones #'(1 5 6) {b,,}

And have it return:
\transpose c c {b,,} \transpose c e'' {b,,} \tranpspose c g'' {b,,}

...i.e., the 1st, 5th, and 6th overtones of the given note.

The case function would be expanded to accomodate whichever overtones I  
wanted to be able to use (here, 1 5 and 6); the notes variable would be  
a list of notes (as \transpose functions) which I would then combine into  
a chord and export to Lilypond for inclusion in the score.


Hopefully I can figure out the rest, but can someone at least give me a  
tip on how to use the \tranpose function within Scheme (currently it  
complains that transpose is an unbound variable), or if there's a  
better way to do tranposition from within Scheme?


I also tried surrounding it with #{ #}, but then it complained about an  
Unknown # object.


Thanks in advance,
Marcus


___
lilypond-user mailing list
lilypond-user@gnu.org
http://lists.gnu.org/mailman/listinfo/lilypond-user


Re: parenthesize

2006-10-20 Thread Marcus Macauley

Julian Peterson wrote:

I seem to be unable to parenthesize notes using the method explained in  
the manual.  Even this simple example fails:


{c d \parenthesize e f g}

Am I misunderstanding that the output of the above should include a  
parenthesized e ?



I'm not sure why, but \parenthesize seems to require angle brackets, like  
this:


{c d \parenthesize e f g}

If you had a chord within the angle brackets, the \parenthesize would  
still apply only to the immediately following note, not to the whold  
chord, thus:


{c d \parenthesize e g f g}
% only the e is parenthesized

Marcus


___
lilypond-user mailing list
lilypond-user@gnu.org
http://lists.gnu.org/mailman/listinfo/lilypond-user


Re: parenthesize

2006-10-20 Thread Marcus Macauley

Whoops. I didn't see that Rick had already responded.

Marcus


___
lilypond-user mailing list
lilypond-user@gnu.org
http://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Making an object not take up vertical space?

2006-10-18 Thread Marcus Macauley

Kieren MacMillan wrote:

In order to make Lilypond think an object has no horizontal or vertical  
size, respectively, use


 \once \override ObjectName #'X-extent = #'(0 . 0)

or

 \once \override ObjectName #'Y-extent = #'(0 . 0),

where the \once is optional (as always) and ObjectName is replaced with  
the actual name of the object (e.g., RehearsalMark or TextScript or...).


Perfect -- thank you!

Marcus



___
lilypond-user mailing list
lilypond-user@gnu.org
http://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Making an object not take up vertical space?

2006-10-18 Thread Marcus Macauley

Kieren MacMillan wrote:
In order to make Lilypond think an object has no horizontal or vertical  
size, respectively, use


 \once \override ObjectName #'X-extent = #'(0 . 0)

or

 \once \override ObjectName #'Y-extent = #'(0 . 0),

where the \once is optional (as always) and ObjectName is replaced with  
the actual name of the object (e.g., RehearsalMark or TextScript or...).



P.S. Two things follow from this, the first obvious, the second less  
obvious (at least to me).


First, to make an object take up *some* vertical space, say, 2 staff  
spaces, one can do, e.g.:


\once \override ObjectName #'Y-extent = #'(0 . 2)
or
\once \override ObjectName #'Y-extent = #'(-2 . 0)
or
\once \override ObjectName #'Y-extent = #'(-8 . -6)

The difference between the two numbers, of course, being 2 staff spaces,  
which determines how much vertical space the object will get.


Second, the three examples above result in three different vertical  
positions of the object. In this case, lower numbers cause the object to  
be placed higher (regardless of whether it's above or below the staff).


Thus, it's unnecessary to do both an override Y-extent AND both an  
override extra-offset, if one wants to change both the amount of vertical  
space an object takes up AND shift its vertical position. The two tweaks  
can be combined in the Y-extent pair: the difference between the numbers  
represents the amount of vertical space the object takes up, and the value  
of the numbers inversely affects their position (i.e., as the numbers  
increase, the object moves down).


Marcus


___
lilypond-user mailing list
lilypond-user@gnu.org
http://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Scheme Question

2006-10-17 Thread Marcus Macauley

Eduardo Vieira [EMAIL PROTECTED] wrote:

I don't know why this e-mail didn't make it to the Lilypond list, but,  
anyhow, have you ever checked the program FOMUS  
(http://common-lisp.net/project/fomus/doc/)? If you think of  
algorithimic composition and working with Lisp and Scheme, that might be  
interesting.
Personally, Scheme and Common Lisp are still Greek to me, but I just  
came across that link and thought would be useful, as the program offers  
Lilypond and MusicXML output.


It looks very interesting, Eduardo. Thanks for the link.

While we're on the topic of Scheme/Lisp, does anyone have any recommended  
tutorials, especially for non-/novice programmers?


I've found these two resources to be helpful so far:

Revised(5) Report on the Algorithmic Language Scheme
http://www.swiss.ai.mit.edu/ftpdir/scheme-reports/r5rs-html/r5rs_toc.html

Teach Yourself Scheme in Fixnum Days
by Dorai Sitaram, 1998-9
http://gd.tuwien.ac.at/languages/scheme/tutorial-dsitaram/t-y-scheme.html

...but I'm new to all of this, and would appreciate any suggestions.

The Lilypond documentation (Appendix B: Scheme tutorial) links to
http://www.schemers.org/
, but that site doesn't reveal much online documentation.

(Maybe one of the printed textbooks --
http://www.schemers.org/Documents/#all-texts
-- would be useful? Any recommendations?)

Would documentation on Guile or Lisp be relevant? I'm not clear on what  
the differences are.


Thanks in advance,
Marcus


___
lilypond-user mailing list
lilypond-user@gnu.org
http://lists.gnu.org/mailman/listinfo/lilypond-user


Making an object not take up vertical space?

2006-10-17 Thread Marcus Macauley
Is it possible to make an object (e.g., a text markup) not take up any  
vertical space?


I've been using Mats' tip for inserting extra vertical space, to good  
effect, e.g. (customized):


pushup = #(define-music-function (parser location padding) (number?)
#{
s1*0^\markup { \pad-markup #$(* 0.5 padding) \null }
#})

pushdown = #(define-music-function (parser location padding) (number?)
#{
s1*0_\markup { \pad-markup #$(* 0.5 padding) \null }
#})

and then
\pushup #3
wherever I want to insert 3 staff spaces of vertical space above a staff,  
or

\pushdown #4
to insert 4 staff spaces of vertical space below a staff.

But there's one place in the score I'm working on where Lilypond makes  
unnecessary vertical space for a text markup (I reported this to  
bug-lilypond), and I wish I could do the opposite, like:


\pulldown #3
or
\pushup #-3

to insert -3 staff spaces of vertical space above a staff, thus pulling  
down the staff above it.


I tried changing 0.5 in the above definition to -0.5, but it didn't work,  
even with very large numbers.


So the thing to do would be to prevent the offending text markup from  
being accounted for in Lilypond's vertical spacing routines.


Is this possible?

Marcus


___
lilypond-user mailing list
lilypond-user@gnu.org
http://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Making notes in Scheme?

2006-10-15 Thread Marcus Macauley

Nicolas Sceaux wrote:


Marcus Macauley [EMAIL PROTECTED] writes:


I see that there are basically two ways to make notes (music) from
within  a Scheme block. As far as I can tell, one way is powerful but
cumbersome,  and the other way is simple but not very powerful. I'm
hoping maybe  there's a third way that I haven't discovered yet, or
that the second way  is more powerful than I know.


May I ask what is exactly what you try to achieve? It might be easier to
advice you then.

BTW, have you tried using \displayMusic? its output can be
copy-and-pasted to build music expressions in scheme.


I tried it briefly, and I've seen its use demonstrated in the  
documentation, but it seems to require an abundance of information for  
each note, which I'm hoping to avoid.


What I'm trying to do is create a music function whereby one can input  
certain starting values, like:


\makeinfinityseries #2 #7 #1 #13

Those values would be used to generate a pitch series; and then that pitch  
series would be printed in the score.


I've got a working version where I specify those values at the top of the  
file, e.g.:


firstNote = #2
secondNote = #7
octave = #1
modulus = #13

and those definitions are followed by the Scheme code, which ends with a  
(make-music) thing that prints the music, without any \score block (or  
which is assigned to an identifier that I call from within the \score  
block).


The problem with that is I can only use one set of variables within the  
score -- I can only print one such pitch series. Of course, I could add  
another set of variables at the beginning, and process those separately,  
but I think it would be easiest and most flexible if I could do something  
like:


\score {
\makeinfinityseries #2 #7 #1 #13
\bar |
\makeinfinityseries #2 #9 #2 #13
\break
\makeinfinityseries #4 #5 #1 #13
}

...et cetera.

But I keep getting stuck with the (make-music) thing not printing music,  
or the variables being unbound at the point where they're used, or  
various other problems, and so I keep thinking there must be a simpler way  
to print notes from Scheme.


If Lilypond can do:

{ c'4 d' e' }

Surely, I would hope, Scheme can do something simpler than:

(make-music
  'SequentialMusic
  'elements
  (list (make-music
  'EventChord
  'elements
  (list (make-music
  'NoteEvent
  'duration
  (ly:make-duration 2 0 1 1)
  'pitch
  (ly:make-pitch 0 0 0
(make-music
  'EventChord
  'elements
  (list (make-music
  'NoteEvent
  'duration
  (ly:make-duration 2 0 1 1)
  'pitch
  (ly:make-pitch 0 1 0
(make-music
  'EventChord
  'elements
  (list (make-music
  'NoteEvent
  'duration
  (ly:make-duration 2 0 1 1)
  'pitch
  (ly:make-pitch 0 2 0))

or even:

(seq-music-list
 (list (make-note (list (make-note-req (ly:make-pitch 1 0 0)  
(ly:make-duration 2 0
   (make-note (list (make-note-req (ly:make-pitch 1 1 0)  
(ly:make-duration 2 0
   (make-note (list (make-note-req (ly:make-pitch 1 2 0)  
(ly:make-duration 2 0))


...especially as all I want, in this case, is pitches.

And because it's possible to manually type notes within a music function  
in Scheme, e.g.:


function =
#(define-music-function (parser location var1) (integer?)
#{
 c'4 d' e'
#})

It seems like it should also be possible to substitute variables for those  
notes, such as:


#(define-music-function (parser location var1) (integer?)
#{
 $firstnote #(list-ref notes 1) #(list-ref notes 2)
#})


From what I can tell, the key is the ly:music data type, but I don't  
know how to to use that from within Scheme, if it's even possible, much  
less how (if possible) to convert e.g. strings to ly:music.


The ly:export function may also have something to do with it, but if so,  
I haven't figured out quite what.


Thanks for your help,
Marcus


___
lilypond-user mailing list
lilypond-user@gnu.org
http://lists.gnu.org/mailman/listinfo/lilypond-user


Why are variables received by #(define-music-function) unbound in #{ #(scheme code here?) #}

2006-10-15 Thread Marcus Macauley
Either I've found a bug, or (more likely) I don't understand how variables  
are passed between Lilypond and Scheme.


Below is an example, where a #(define-music-function...) block receives a  
variable, stringone. That variable seems to be accessible (i.e. bound, if  
I have my terminology straight) in two places, but not accesible (i.e.  
unbound) in the third place.


1. Accesible by Scheme code within #(define-music-function) but outside of  
#{ #} block

2. Accessible by Lilypond input within #{ #} block
3. Not accesible by Scheme code within #{ #} block

Why is this, and is there any way to pass a variable, received by  
define-music-function, to Scheme code within the #{ #} block?


Thanks in advance,
Marcus



\version 2.9.23

function = #(define-music-function
  (parser location stringone)
  (string?)
  (let ((stringone (string-append stringone  foo)))
   #{
% uncommenting the following line yields ERROR: Unbound variable:  
stringone

%#(string-append stringone  bar)
c1^\markup { $stringone }
   #}))

\relative c'' { \function #one }


___
lilypond-user mailing list
lilypond-user@gnu.org
http://lists.gnu.org/mailman/listinfo/lilypond-user


Making notes in Scheme?

2006-10-14 Thread Marcus Macauley
I see that there are basically two ways to make notes (music) from within  
a Scheme block. As far as I can tell, one way is powerful but cumbersome,  
and the other way is simple but not very powerful. I'm hoping maybe  
there's a third way that I haven't discovered yet, or that the second way  
is more powerful than I know.


Here's an example of the first way:
(from http://lsr.dsi.unimi.it/LSR/Item?id=122 )

% FIRST WAY: %%
#(define (make-note-req p d)
   (make-music 'NoteEvent
'duration d
'pitch p))

#(define (make-note elts)
   (make-music 'EventChord
'elements elts))

#(define (seq-music-list elts)
   (make-music 'SequentialMusic
'elements elts))

fooMusic = #(seq-music-list
 (list (make-note (list (make-note-req (ly:make-pitch 1 0 0)  
(ly:make-duration 2 0
   (make-note (list (make-note-req (ly:make-pitch 1 1 0)  
(ly:make-duration 2 0))


\score { \fooMusic
}

(This is actually a simplification of the full Scheme code. It works, but  
the (make-note) block is still still a lot to type for each note.)




Here's an example of the second way, based on chapter 12.1.1 in the  
documentation:


 SECOND WAY: 
function =
#(define-music-function (parser location string1 string2 firstnote)
(string? string? ly:music?)
#{
  $firstnote d'_\markup { $string1 $string2 }
#})

\score { \function #foo #bar c'4
\layout { ragged-right = ##t }
}



What the second way is missing (or I haven't figured out how to use it) is  
the ability to choose pitches, durations, etc. using Scheme code. As far  
as I can tell, they must be manually typed within the #{ #} block (e.g.  
d') or provided as an argument to the music-function (e.g. c'4); they  
can't be generated from Scheme code, without resorting to the long and  
cumbersome (make-music) block demonstrated in way one.


Am I wrong? Is there a way to, for example, define a ly:music variable  
in Scheme, or convert a string variable to a ly:music variable, and  
then use that ly:music variable either within a the #{ #} block of a  
music function, or within the main \score block? And if so, is this  
documented somewhere?


Below is an example of the closest I've come to maybe figuring this out,  
but I'd appreciate any help.


Marcus


 Perhaps I'm getting warm here: %%
\version 2.9.23

thirdnote = { e' }

SomehowThisIdentifierMakesTheNextLineErrorFree = #(ly:export thirdnote)

#(define fourthnote thirdnote)

% This next line doesn't cause an error, but it doesn't seem to do  
anything either:

#(define fifthnote (ly:export #{ g' #}))

function =
#(define-music-function (parser location string1 string2 firstnote)
(string? string? ly:music?)
#{
	  $firstnote d'_\markup { $string1 $string2 } $thirdnote $fourthnote  
$fifthnote

#})

\score { \function #foo #bar c'4
\layout { ragged-right = ##t }
}
%


___
lilypond-user mailing list
lilypond-user@gnu.org
http://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Trying to set next-padding to 0

2006-10-14 Thread Marcus Macauley

Stephen Torri wrote:

Below is my attempt at setting the next-padding value to 0 in a score so
that the individual measure lines are moving closer to each other. With
the annotate-spacing set to true I don't see next-padding changing to
zero.

What is the proper way to set next-padding?

Stephen

\score {

\overrideProperty #Score.NonMusicalPaperColumn
#'line-break-system-details
#'((next-padding . 0))

\chords { \global \harmonies }
\new Voice {  \global \voices  }
\lyricsto People \new Lyrics \firstVerse
\lyricsto People \new Lyrics \secondVerse
\lyricsto People \new Lyrics \thirdVerse
\lyricsto Chorus \new Lyrics \chorusVerse

}


I think I spot a typo:

\overrideProperty should be \outputProperty

(based on  
http://lilypond.org/doc/v2.8/Documentation/user/lilypond/Difficult-tweaks.html  
)


Marcus


___
lilypond-user mailing list
lilypond-user@gnu.org
http://lists.gnu.org/mailman/listinfo/lilypond-user


Scheme question

2006-10-13 Thread Marcus Macauley
I've read in the Lilypond documentation chapter 11, Interfaces for  
programmers, Appendix B, Scheme tutorial, and the beginning of the  
Scheme manual at:

http://www.swiss.ai.mit.edu/ftpdir/scheme-reports/r5rs-html/r5rs_toc.html

But I'm stuck on a simple problem which probably has a simple answer.

In the Lilypond Snippet Repository, there's an example titled, Engraving  
music using Scheme expressions:

http://lsr.dsi.unimi.it/LSR/Item?id=122

That works fine on my system (Lilypond 2.9.17, Linux).

But I'm trying to make a tiny addition to that code, and it isn't working.

Here is their example, which outputs the notes C and D:


#(define (make-note-req p d)
   (make-music 'NoteEvent
'duration d
'pitch p))

#(define (make-note elts)
   (make-music 'EventChord
'elements elts))

#(define (seq-music-list elts)
   (make-music 'SequentialMusic
'elements elts))

fooMusic = #(seq-music-list
 (list (make-note (list (make-note-req (ly:make-pitch 1 0 0)  
(ly:make-duration 2 0
   (make-note (list (make-note-req (ly:make-pitch 1 1 0)  
(ly:make-duration 2 0))


\score { \fooMusic
}


I want to define a variable and plug it into, say, the second number of  
(ly:make-pitch 1 0 0).


So I would expect that I could simply put one of these lines at the  
beginning of the file:


mypitch = #0
#(define mypitch 0)

and then change the expression:
(ly:make-pitch 1 0 0)

to:
(ly:make-pitch 1 $mypitch 0)

but when I do that, it complains:
ERROR: Unbound variable: $mypitch

Why doesn't this work?

Marcus


___
lilypond-user mailing list
lilypond-user@gnu.org
http://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Scheme question

2006-10-13 Thread Marcus Macauley

Mats Bengtsson wrote:

Quoting Marcus Macauley [EMAIL PROTECTED]:


mypitch = #0
#(define mypitch 0)


One of them is enough!


That's why I said I put one of these lines at the beginning of the file.  
When I got the error, I tried defining the variable in Scheme (second line  
above) instead of Lilypond (first line above), since I didn't know what  
else to try. Not surprisingly, it didn't make any difference.




(ly:make-pitch 1 $mypitch 0)

but when I do that, it complains:
ERROR: Unbound variable: $mypitch


Did you try to remove the $?


That's it - thanks!

I was confused by the use of the dollar sign ($) in, e.g., 12.1.2 Simple  
substitution functions, which I now see is necessary because it's within  
a #{ #} block which takes normal LilyPond input, using variables as  
#$var1 (12.1.1), as opposed to Scheme input (my example), in which  
variables are referred to simply by their name, e.g., var1.


I still don't understand, though, why sometimes #$var1 is used and  
sometimes $var1 is used in the examples, including those on the 12.1.2  
Simple substitution functions page. I notice that in the bottom example  
on that page, $padding can be replaced with #$padding, but $marktext  
cannot be replaced with #$marktext, without generating an error. Surely  
there's a reason for this, but it's not obvious from the documentation.


Marcus


___
lilypond-user mailing list
lilypond-user@gnu.org
http://lists.gnu.org/mailman/listinfo/lilypond-user


Re: never mind Re: The file changes; lilypond doesn't notice

2006-10-11 Thread Marcus Macauley

Mats Bengtsson wrote:

If you can isolate the problem, please send a bug report,
a segmentation fault is always a serious bug!


OK, I posted a bug report to bug-lilypond.

(The problem, in short, was that \addquote couldn't handle a \new Voice.  
The documentation mentions this limitation, but says nothing about a  
segmentation fault.)


Marcus


___
lilypond-user mailing list
lilypond-user@gnu.org
http://lists.gnu.org/mailman/listinfo/lilypond-user


The file changes; lilypond doesn't notice

2006-10-10 Thread Marcus Macauley
I'm using Lilypond 2.9.17 on Gentoo Linux, with jEdit 4.3pre6 and  
LilypondTool 2.8.


Sometimes when I make a change or a few changes to the score (and save the  
file, of course) and then run Lilypond again (from within jEdit, using  
LilypondTool), it doesn't notice my changes, and simply outputs the  
following:


Processing `/my/lilypond/file.ly'
Parsing...
Interpreting music...
Processing time: 1 seconds

When this happens, I can often force it to take another look by adding  
or commenting out a line which makes a major change, or causes a syntax  
error, or something like that. But sometimes (like now) I find myself just  
stuck. I'll add fourteen open braces to the beginning in the middle of the  
score block, run Lilypond again, and it acts as if nothing has changed and  
everything is normal.


Has anyone else experienced this problem? Is it a Lilypond problem or a  
LilypondTool problem? Any suggestions for how to fix it, or how to  
circumvent it, i.e. how to refresh Lilypond (short of saving my file  
under a new name)?


BTW, I've noticed that sometimes the .ly file I'm working on also has a  
.log file in the same directory, so deleting that refreshes Lilypond.  
But sometimes (like now) there is no .log file to be found.


And also, BTW, I haven't changed any of the LilypondTool configuration  
settings in jEdit. The Lilypond command is listed simply as lilypond.


Thanks,
Marcus


___
lilypond-user mailing list
lilypond-user@gnu.org
http://lists.gnu.org/mailman/listinfo/lilypond-user


why doesn't Y-offset work for Hairpins?

2006-10-08 Thread Marcus Macauley

The documentation page for Hairpin --
http://lilypond.org/doc/v2.9/Documentation/user/lilypond-internals/Hairpin.html
-- lists Y-offset as one of the standard settings. It also says that  
Hairpin supports grob-interface, and the grob-interface page --

http://lilypond.org/doc/v2.9/Documentation/user/lilypond-internals/grob_002dinterface.html
-- also lists Y-offset as one of the User settable properties.

So I would assume that putting

\once \override Score.Hairpin #'Y-offset = #6

before a hairpin object would shift it up or down, in this case by 6 staff  
spaces.


But in fact, the following example moves the hairpin not at all:

\version 2.9.17
\layout { ragged-right = ##t }
{
\once \override Score.Hairpin #'Y-offset = #6
\relative c' {c1\ c1\!}
}

Am I missing something, or is this a bug?

BTW, X-offset works just fine. And extra-offset works too, but I don't  
think that's what I want (because it doesn't create any extra space).


Marcus


___
lilypond-user mailing list
lilypond-user@gnu.org
http://lists.gnu.org/mailman/listinfo/lilypond-user


Re: why doesn't Y-offset work for Hairpins?

2006-10-08 Thread Marcus Macauley

Kieren MacMillan wrote:

In the meantime, you can use
\once \override DynamicLineSpanner #'padding = #6
which is what I *always* use anyway!  =)


Mats Bengtsson wrote:
The explanation may be something similar as the explanation in the  
section on Text Markup on why \left-align doesn't have any effect

for RehearsalMark objects.


It seems you are both right.

Kieren, your suggestion works perfectly.

And I now notice at the bottom of the Dynamics page --
http://lilypond.org/doc/v2.9/Documentation/user/lilypond/Dynamics.html
-- the following note under See also:

Program reference: DynamicText, Hairpin. Vertical positioning of these  
symbols is handled by DynamicLineSpanner.


That should have clued me in. But I wonder why Hairpin even has a  
Y-offset setting -- listed at

http://lilypond.org/doc/v2.9/Documentation/user/lilypond-internals/Hairpin.html
-- if it doesn't do anything. As part of grob-interface, sure. But to have  
it listed separately on the Hairpin page, seems unnecessary and confusing  
to me. There are many other grobs which have no such setting listed.


Anyway, thanks to both of you for your quick and helpful responses!

Marcus


___
lilypond-user mailing list
lilypond-user@gnu.org
http://lists.gnu.org/mailman/listinfo/lilypond-user


Horizontal beams (automatically)?

2006-10-08 Thread Marcus Macauley

I know this has been asked before, but I haven't found an answer:

Is there a way to automatically make all beams flat, or to automatically  
make a certain beam flat?


Searching the documentation and lilypond-user, I found two methods,  
neither of them sufficient.


The first method,
   \override Beam #'damping = #10
, should make the beams horizontal, according to the documentation --
http://lilypond.org/doc/v2.9/Documentation/user/lilypond-internals/Beam.html
and
http://lilypond.org/doc/v2.9/Documentation/user/lilypond-internals/beam_002dinterface.html
-- but in fact they remain slightly slanted. (For example, one end of the  
beam sits on the staff line, while the other end of the beam straddles it.)


The second method (as suggested recently by Trevor Baca on this list),
   \override Beam #'positions = #'(4 . 4)
, works fine for individual beams, but is impractical for a whole piece;  
you'd have to manually set the position of each beam.


Any other ideas?

Marcus


___
lilypond-user mailing list
lilypond-user@gnu.org
http://lists.gnu.org/mailman/listinfo/lilypond-user


Re: To hide a time signature

2006-10-02 Thread Marcus Macauley

Mats,

I wrote:
I'm trying to hide the first time signature, but display any which come  
later. So here's a snippet:


\version 2.9.17
{
\once \override Staff.TimeSignature #'break-visibility = ##(#f #f #f)
\time 4/4 c'1 \time 3/4 c'2.
}

The tweak is based on this page:
http://lilypond.org/doc/v2.9/Documentation/user/lilypond-internals/TimeSignature.html


You replied:
If you had followed the link at the bottom of that page to  
item-interface, you
would have found the solution much quicker. Always remember that the  
information
presented for each graphical object is just a subset of the full  
documentation of all
the available properties. To see it all, you need to browse through all  
the links to the

interfaces.


Indeed, I discovered those links soon after I posted. But the particular  
link you mention, item-interface, doesn't seem to offer much help here.  
It mentions the break-visibility setting, but so does the TimeSignature  
page itself, and it didn't take me long to find it on the TimeSignature  
page. True, the item-interface page explains it at greater length,  
though.


What I still don't understand is the stencil setting (which Kieren  
suggested as an alternative), which I now see is listed on the  
grob-interface page (linked from the bottom of the TimeSignature page),  
but there it appears under Internal properties and not under User  
settable properties. That seems to imply that stencil is not user  
settable, though Kieren's example suggests that it is. Also, whether or  
not stencil is user settable, the grob-interface page offers no clue  
as to what values/syntax it might take. The entry reads:


stencil (unknown)
   The symbol to print.

BUT, now I notice something I didn't see before. At the bottom of the list  
of user settable properties is:


transparent (boolean)
   This makes the grob invisible.

transparent: That sounds awfully familiar! It's wonder I couldn't see it  
before -- it's like I was looking right through it.


Sure enough, the following line works like a charm:

\once \override Staff.TimeSignature #'transparent = ##t

Seeing as grobs are ubiquitous in Lilypond (judging from, e.g., the list  
at the bottom of

http://lilypond.org/doc/v2.9/Documentation/user/lilypond-internals/grob_002dinterface.html
), I imagine I won't have too much trouble the next time I want to hide  
something.


(My stencil query remains unresolved, but it's not so pressing.)

Thanks, Mats and Kieren, for the help.

Marcus


___
lilypond-user mailing list
lilypond-user@gnu.org
http://lists.gnu.org/mailman/listinfo/lilypond-user


Re: To hide a time signature

2006-10-02 Thread Marcus Macauley

Mats,

If you search the index of the manual for transparent objects,  
removing objects,
hiding objects or invisible objects you will find a link to some  
more information

on the transparent property in the manual.


Thanks. I don't know how I missed that before.



\once \override Staff.TimeSignature #'transparent = ##t
As is explained in the manual, this will not do exactly the same thing  
as your
previous solution, since the transparent time signature will still  
occupy some

space (which is usually not desirable for this situation).


Good point. So my original solution, or Kieren's, was probably best.

Marcus


___
lilypond-user mailing list
lilypond-user@gnu.org
http://lists.gnu.org/mailman/listinfo/lilypond-user


Re: instrument names for GrandStaff, etc.

2006-10-01 Thread Marcus Macauley
On Sat, 30 Sep 2006 20:39:09 -0400, Kieren MacMillan  
[EMAIL PROTECTED] wrote:



Hi, Marcus:


Just a quick suggestion. Why not let a GrandStaff have an instrumentName
(and a shortInstrumentName), just like a Staff and a PianoStaff already  
do?


Just in case you don't know, you can always add this feature to your own  
scores with


\context
{
 \GrandStaff
 \consists Instrument_name_engraver
}

For more information, see the example at http://www.lilypond.org/doc/ 
v2.9/input/test/lily-473581812.ly.



Kieren,

That's just what I was looking for! I now see that the example in  
question, instrument-name-grandstaff.ly, resides in the Tips and Tricks  
section of documentation:

http://www.lilypond.org/doc/v2.9/input/test/collated-files.html

The same trick works for ChoirStaff or StaffGroup, too, adding a new  
\context block for each.


Perhaps this should be mentioned in the documentation, under:

8.2.5 Instrument names
http://lilypond.org/doc/v2.9/Documentation/user/lilypond/Instrument-names.html

Or are we expected to search the main documentation, and failing that,  
Regression Tests, Tips and Tricks, and Examples, and failing that, the  
email archives, and failing that, a message to lilypond-user? It seems to  
me, a link wouldn't hurt. And if I knew how to edit the documentation, I'd  
add it myself.


Anyway, thanks for the tip!

(BTW, I still don't see why the Instrument_name_engraver isn't part of the  
GrandStaff, if not the ChoirStaff and StaffGroup, *automatically*, but at  
least there's an easy enough workaround for now, so I won't complain.)


Marcus


___
lilypond-user mailing list
lilypond-user@gnu.org
http://lists.gnu.org/mailman/listinfo/lilypond-user


Re: To hide a time signature

2006-10-01 Thread Marcus Macauley

Hi Kieren,


I don't claim it's necessarily better, but another way
[to hide the initial time signature but not subsequent ones]
would be

\version 2.9.17
{
\once \override Staff.TimeSignature #'stencil = ##f
\time 4/4 c'1 \time 3/4 c'2.
}


Indeed, that works too. But where is the stencil setting documented? And  
why isn't it mentioned on:

http://lilypond.org/doc/v2.9/Documentation/user/lilypond-internals/TimeSignature.html
?

In other words, how did you learn that tweak, and how might I have  
discovered one like that myself, without asking the mailing list?


(Searching Google for stencil site:lilypond.org didn't yield any obvious  
answers. Nor did the Lilypond index, in which stencil links to 8.1.6  
Overview of text markup commands --

http://lilypond.org/doc/v2.9/Documentation/user/lilypond/Overview-of-text-markup-commands.html
-- which explains the \stencil command, but not the #'stencil setting.)

Thanks,
Marcus


___
lilypond-user mailing list
lilypond-user@gnu.org
http://lists.gnu.org/mailman/listinfo/lilypond-user


instrument names for GrandStaff, etc.

2006-09-30 Thread Marcus Macauley

Hi,

Just a quick suggestion. Why not let a GrandStaff have an instrumentName  
(and a shortInstrumentName), just like a Staff and a PianoStaff already do?


Instrument names could even be allowed for a ChoirStaff or a StaffGroup,  
though I imagine the need to use it in those cases would be less common.


As I see it, any group of staves should be able to be named, as a group,  
with the name appearing to the left of the vertical midpoint between the  
two (or more) staves.


Also, whether these extra instrumentNames are implemented sooner or later,  
I think the documentation should explain which ones are available. These  
are the sections where such an explanation would seem to be most helpful:


8.2.5 Instrument names
http://lilypond.org/doc/v2.9/Documentation/user/lilypond/Instrument-names.html

6.4.7 System start delimiters
http://lilypond.org/doc/v2.9/Documentation/user/lilypond/System-start-delimiters.html

2.17 Piano staves
http://lilypond.org/doc/v2.9/Documentation/user/lilypond/Piano-staves.html

Cheers,
Marcus


___
lilypond-user mailing list
lilypond-user@gnu.org
http://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Accidentals tied over a line break

2006-08-25 Thread Marcus Macauley
Markus: That's a way to manually suppress accidentals after a line break; 
thanks. But I need a way to do it automatically.


 Is the example in Section 9.3.7: Difficult Tweaks of any help?

Kieren: That looks like it might be helpful, but I don't understand the syntax 
well enough to adapt the tweak on that page.
( 
http://lilypond.org/doc/v2.9/Documentation/user/lilypond/Difficult-tweaks.html )

It seems like it might be possible to modify that tweak with Markus's 
accidental-suppression --
\once \override Staff.Accidental #'transparent = ##t
-- but I can't figure out how to do this.

Any tips?

Thanks,
Marcus

P.S. Actually, I'm not sure that will be enough. It looks like transparent 
accidentals still take up space; I'd rather suppress the accidental *and* its 
allotted space. Surely there should be an easier way, even if it's possible to 
hack it somehow in the meantime.


___
lilypond-user mailing list
lilypond-user@gnu.org
http://lists.gnu.org/mailman/listinfo/lilypond-user


Accidentals tied over a line break

2006-08-23 Thread Marcus Macauley
Hello,

Currently, if a note with an accidental is tied over a line break, the 
accidental is repeated on the new line. Is there any way to turn off this 
behavior?

I looked in the manual; 9.1.1 Automatic accidentals would seem to be the 
relevant section, but it doesn't say anything about tied accidentals. There's a 
regression test called accidental-tie.ly, but it merely explains that an 
accidental is present if the line is broken at the tie, which happens for the G 
sharp, without mentioning any way of turning off this behavior.

It took me a while to find an instance of a note with accidental tied over a 
line break in the Henle edition of the Bach Well-Tempered Clavier, but when I 
eventually found one, the accidental was not repeated after the line break. 
(Book I, Fugue in B minor, measures 56-57. It happens to be a G-sharp.) So if 
my own desire to not repeat the accidental isn't enough, there's an example 
from G. Henle Verlag.*

Thanks,
Marcus

(In fairness, the second instance I found did repeat the accidental: Book I, 
Fugue in C-sharp minor, measures 40-41, an A-sharp. Anyway, I think the user 
should be able to choose whether or not accidentals are displayed in these 
situations. And if they are repeated, the ties should not collide, as the 
currently do. The aforementioned A-sharp provides a good example of how a tie 
can avoid an accidental in such a case.)


___
lilypond-user mailing list
lilypond-user@gnu.org
http://lists.gnu.org/mailman/listinfo/lilypond-user


Re: al niente / de niente - was Re: (no subject)

2006-03-17 Thread Marcus Macauley

Mats Bengtsson wrote:


Quoting Marcus Macauley [EMAIL PROTECTED]:

As an alternative to the second method -- and a perhaps more  
conventional  one, recommended by Kurt Stone -- niente can be notated  
not with the  dynamic letter n but with the italic n. (this time  
with a period).  This should be possible to do now, but I can't figure  
out how to switch  off the boldface:


n = #(make-dynamic-script (markup #:text #:italic n. ) ) % This  
makes  the text bold-italic.


n = #(make-dynamic-script (markup #:text n. ) ) % In fact, even this   
makes it bold-italic, as if that's the default text font style. Why?  
And  how to switch it off?


The simple reason is that dynamics by default have bold face turned on.  
For situations like these, where you want tobe sure
to first reset all font related properties before starting applying your  
own preferences, the markup command \normal-text was introduced

in version 2.7. So you should be able to do something like
n = #(make-dynamic-script (markup #:normal-text #:italic n. ) )


Ah, yes, that works. The last thing I saw on in the email list archives  
about it was a comment, by you, I think, that a command like \normal-text  
would be useful (it presumably hadn't been implemented at the time).


Another way to do it, I've found, is...

n = #(make-dynamic-script (markup #:text #:medium #:italic n.) )

...where #:medium is the regular (not-bold) weight of the font. (Likewise,  
as Han-Wen pointed out on lilypond-devel, you can use #:upright to cancel  
#:italic). I like your solution better, though - it could conceivably be  
used where you're unsure of what the default font style is, and you just  
want to clear all formatting and then specify only what you want.


Thanks for the tip.

Marcus


___
lilypond-user mailing list
lilypond-user@gnu.org
http://lists.gnu.org/mailman/listinfo/lilypond-user


Re: al niente / de niente - was Re: (no subject)

2006-03-16 Thread Marcus Macauley
On Thu, 16 Mar 2006 14:27:24 -0800, Trevor Bača [EMAIL PROTECTED]  
wrote:



On 3/16/06, Marcus Macauley [EMAIL PROTECTED] wrote:


Another way of notating this, which I prefer, but also I think needs to  
be

implemented, is to follow the decresc. (or precede the cresc.) with a
bold/italic n or n., for niente.


Does #(make-dynamic-script n.) not help? (As in the examples in 8.1.8?)


At least for me (Lilypond 2.7.38 on Windows, not cygwin), doing that  
prints the n. in a giant sans-serif font -- very inappropriate. I assume  
it does that because the dynamic-script font lacks an n character, so it  
substitutes the letter from another font.


Marcus


___
lilypond-user mailing list
lilypond-user@gnu.org
http://lists.gnu.org/mailman/listinfo/lilypond-user


Tabloid paper size - how I got it working

2005-02-15 Thread Marcus Macauley
), but since it worked that way I didn't bother
to go back and change it.

So I made similar changes to the gs_statd.ps files for the other
ghostscript versions.

Then I edited the Lilypond file, specifying tabloid/landscape (which is
what I really wanted), ran Lilypond on it again, and it generated no
errors about PS or PDF, as it had before (just some musical warnings - bar
checks, etc.).

Then, trying to open each file (PS and PDF) with KGhostView, KPDF, GGV,
and GPDF, here's what worked/didn't work:

- KGhostView opened the PS file, but displayed it incorrectly (music at
the bottom of the page, overflowing, etc). Choosing View - Paper Size -
11x17 fixed it; now it displayed tabloid landscape, with the music
formatted correctly. However, I couldn't get it to display the PDF without
getting the orientation wrong in one way or another.

- KPDF displayed the PDF correctly upon opening it - no modifications
necessary!

- GGV refused to open the PS, complaining File is not a valid PostScript
document. However, it displayed the PDF just fine, except that the whole
page was rotated. In other words, the music fit, spanning the length (17
inches) of the page, but the page was displayed in portrait orientation
with the staff lines vertical. Choosing View - Orientation - Landscape
rotated it correctly, but the music was cut off past 11 inches wide.

- GPDF, like KPDF, displayed the PDF correctly the first time!

Hopefully that helps, and if there's an easier/more reliable way to make
this work, I'd be happy to hear about it!

BTW, I'm still not sure which version of Ghostscript Lilypond is using;
all I know is that typing gs --version at a command prompt displays
8.15, while typing ghostscript --version displays 7.07. I suppose I
could make symbolic links in the /usr/bin or /usr/local/bin directories to
choose which version I wanted to use, but now that it's at least working I
feel more like leaving it alone!

Marcus Macauley


___
lilypond-user mailing list
lilypond-user@gnu.org
http://lists.gnu.org/mailman/listinfo/lilypond-user


Re: compiling ec-fonts-mftraced

2004-12-01 Thread Marcus Macauley
Hi Scott/others,

I am having the same problem. I'm running the latest version of Gentoo
(2004.3-r1, kernel 2.6.9), and have tried compiling each version of
ec-fonts-mtraced, using make or make all install, and it generates
the same error every time (as Scott copied below).

Actually, I thought I had tetex installed, but I just now noticed that I
don't. So maybe that's the problem? I'll try compiling ec-fonts-mftraced
again after installing tetex, and report what happens.

FWIW, I emerged (installed from source with Gentoo) Lilypond, which
happens to be version 2.0.3 (which I think doesn't require
ec-fonts.mftraced).

Marcus


Scott wrote:
---
Hi All,

I am trying to compile ec-fonts-mftraced-1.0.8, and am getting the
following error:

Tracing bitmaps... Invoking `gf2pbm -n 0 -o char.pbm ecbx10.7227gf'

Opening pipe  `gf2pbm -n 0 -s ecbx10.7227gf'
Traceback (most recent call last):
  File /usr/bin/mftrace, line 1184, in ?
trace_font (basename, gf_fontname, metric, glyph_range, encoding,
magnification)
  File /usr/bin/mftrace, line 636, in trace_font
success = trace_one (char.pbm, '(null)--1216699596' %
(gf_fontname, a))
  File /usr/bin/mftrace, line 355, in trace_one
status = system (trace_command (pbmfile, ''), 1)
TypeError: 'NoneType' object is not callable
make: *** [pfa/ecbx10.pfa] Error 1

Could anyone help me out?

Also, I am experiencing alot of:

/var/cache/fonts/ls-R: Permission denied

errors.  Has anyone successfully compiled ec-fonts-mftraced-1.0.8,
perhaps even on a gentoo box?  Thanks for any assistance.

Best,
Scott

-- 
Oh, people can come up with statistics to prove anything. 14% of people
know that. -- Homer Simpson
---



___
lilypond-user mailing list
[EMAIL PROTECTED]
http://lists.gnu.org/mailman/listinfo/lilypond-user