Re: small caps

2015-01-16 Thread Craig Dabelstein
Hi Shane,

\version "2.19.11"

Even with \smallCaps (how did I miss that!?!!?) the test stays the same.
Bold and Large are both working but not the small caps.

Craig


On Fri Jan 16 2015 at 4:39:22 PM Shane Brandes  wrote:

> Which version are you using? and is it not \smallcaps that you need to
> issue? Also does the font actually have small caps natively?
>
> Shane
>
> On Fri, Jan 16, 2015 at 12:54 AM, Craig Dabelstein
>  wrote:
> > Hi List,
> >
> > Can anyone tell me why I can't get small caps working with this code?
> >
> > Many thanks,
> >
> > Craig
> >
> > scoreTitleMarkup = \markup {
> > \column {
> >   \on-the-fly \print-all-headers { \bookTitleMarkup \hspace #1 }
> >   \fill-line {
> > \large \bold \caps \fromproperty #'header:piece
> >  }
> > }
> >   }
> > }
> >
> > ___
> > lilypond-user mailing list
> > lilypond-user@gnu.org
> > https://lists.gnu.org/mailman/listinfo/lilypond-user
> >
>
___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Understanding Lilypond

2015-01-16 Thread David Sumbler
As I start to gain experience in setting music in Lilypond I am trying
to understand more about how it works internally.  As well as personal
satisfaction, this obviously has a practical aim: it will make it easier
for me to modify or correct things without having to ask so many
questions on this forum, and will also perhaps eventually mean that I
can help by answering others' questions.

However, despite having read the documentation - some of it several
times - I do find understanding some aspects of the structure of
Lilypond extremely difficult.  One of the manuals likens a Lilypond file
to source code in a computer language, but I find that understanding the
structure of a coding language is perfectly straightforward compared to
getting my head around Lilypond.  (I have learnt several languages over
the years, although not, I admit, Lisp or Scheme; however, I have no
reason to suppose that understanding their structure is any more
difficult than other languages).

For instance, in Lilypond there is a sensible difference in the default
handling of time- and key-signatures.  Using the \key command a key is
defined for the current Staff.  But using the \time command sets the
time signature for every staff.  If a different time signature is
required for a particular staff, then timeSignatureFraction has to be
changed.

>From the Internals Reference I see that the 2 layout objects
KeySignature and TimeSignature both exist, by default, in a Staff
context, which makes perfect sense.

Clearly, though, when the \time command is used, then not only is
Staff.timeSignatureFraction set, but so also is some other variable in a
higher context.

What I can't seem to find (although it may well be in the documentation
somewhere) is a clear explanation of this.  Can somebody point me in the
right direction?

David


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


Re: Re:bottom of EPS output cut off (+ size of PDF files)

2015-01-16 Thread Jayaratna
I found a couple of instances in which this crop method too fails:

a) the stem of a b flat;
b) the 8 at the bottom of an octavated clef.

See attached files.

esempio3033-crop.pdf
  
esempio3064-crop.pdf
  



--
View this message in context: 
http://lilypond.1069038.n5.nabble.com/Re-bottom-of-EPS-output-cut-off-size-of-PDF-files-tp170524p170551.html
Sent from the User mailing list archive at Nabble.com.

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


Re: small caps

2015-01-16 Thread tisimst
Craig,

\caps is just a short-hand command for \smallCaps, but this situation 
is obviously a code bug. You CAN put the \caps or \smallCaps in the 
header variable itself:

piece = \markup \smallCaps "Piece"

and then it works, but since it seems that you are trying to create a 
custom title that does this automatically, this solution may not be 
suitable for you. I'm forwarding this small example to the bugs-list 
for extermination:

%<

\version "2.19.11"

\paper {
  scoreTitleMarkup = \markup {
\column {
  \on-the-fly \print-all-headers { \bookTitleMarkup \hspace #1 }
  \fill-line {
\large \bold \smallCaps \fromproperty #'header:piece
  }
}
  }
}

\header {
  title = "Title"
  piece = "Piece"  % put the \smallCaps in here and it works
}

{ \repeat unfold 3 { s1 \break } }

%<--

- Abraham

On Fri, Jan 16, 2015 at 2:00 AM, Craig Dabelstein [via Lilypond] 
 wrote:
> Hi Shane,
> 
> \version "2.19.11"
> 
> Even with \smallCaps (how did I miss that!?!!?) the test stays the 
> same. Bold and Large are both working but not the small caps. 
> 
> Craig
> 
> 
> On Fri Jan 16 2015 at 4:39:22 PM Shane Brandes <[hidden email]> wrote:
>> Which version are you using? and is it not \smallcaps that you need 
>> to
>> issue? Also does the font actually have small caps natively?
>> 
>> Shane
>> 
>> On Fri, Jan 16, 2015 at 12:54 AM, Craig Dabelstein
>> <[hidden email]> wrote:
>> > Hi List,
>> >
>> > Can anyone tell me why I can't get small caps working with this 
>> code?
>> >
>> > Many thanks,
>> >
>> > Craig
>> >
>> > scoreTitleMarkup = \markup {
>> > \column {
>> >   \on-the-fly \print-all-headers { \bookTitleMarkup \hspace #1 
>> }
>> >   \fill-line {
>> > \large \bold \caps \fromproperty #'header:piece
>> >  }
>> > }
>> >   }
>> > }
>> >
>> > ___
>> > lilypond-user mailing list
>> > [hidden email]
>> > https://lists.gnu.org/mailman/listinfo/lilypond-user
>> >
> 
> ___ 
> lilypond-user mailing list 
> [hidden email] 
> https://lists.gnu.org/mailman/listinfo/lilypond-user
> 
> 
> If you reply to this email, your message will be added to the 
> discussion below:
> http://lilypond.1069038.n5.nabble.com/small-caps-tp170540p170544.html
> To start a new topic under User, email 
> ml-node+s1069038n...@n5.nabble.com 
> To unsubscribe from Lilypond, click here.
> NAML




--
View this message in context: 
http://lilypond.1069038.n5.nabble.com/small-caps-tp170540p170552.html
Sent from the User mailing list archive at Nabble.com.___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Understanding Lilypond

2015-01-16 Thread Urs Liska


Am 16.01.2015 um 13:35 schrieb David Sumbler:

As I start to gain experience in setting music in Lilypond I am trying
to understand more about how it works internally.  As well as personal
satisfaction, this obviously has a practical aim: it will make it easier
for me to modify or correct things without having to ask so many
questions on this forum, and will also perhaps eventually mean that I
can help by answering others' questions.

However, despite having read the documentation - some of it several
times - I do find understanding some aspects of the structure of
Lilypond extremely difficult.  One of the manuals likens a Lilypond file
to source code in a computer language, but I find that understanding the
structure of a coding language is perfectly straightforward compared to
getting my head around Lilypond.  (I have learnt several languages over
the years, although not, I admit, Lisp or Scheme; however, I have no
reason to suppose that understanding their structure is any more
difficult than other languages).

For instance, in Lilypond there is a sensible difference in the default
handling of time- and key-signatures.  Using the \key command a key is
defined for the current Staff.  But using the \time command sets the
time signature for every staff.  If a different time signature is
required for a particular staff, then timeSignatureFraction has to be
changed.

 From the Internals Reference I see that the 2 layout objects
KeySignature and TimeSignature both exist, by default, in a Staff
context, which makes perfect sense.


Yes, that makes sense because they are used to *engrave* the visual 
objects at staff level.




Clearly, though, when the \time command is used, then not only is
Staff.timeSignatureFraction set, but so also is some other variable in a
higher context.


The timing aspects are controlled by the Timing_translator, and this 
engraver by default lives in the Score context.
Which also makes perfect sense because usually the timing is uniform in 
a score from top to bottom.


But this construct is what makes polymetrics so easy to do in LilyPond. 
You can move the Timing_translator from the Score to Staff level to get 
independent timing in the different staves.
But you should not forget to also move the Default_bar_line_engraver 
that should live at the same level as Timing_translator.


With key signatures it is much more common that different instruments 
*show* different keys.
Nevertheless it *is* sort of an inconsistency that you *always* have to 
specify the key for each staff separately (or in a global variable, 
which is not much better). It would be more consistent to have the key 
also live in the Score context by default and give the ability to 
sepcify contexts with different keys through their context properties.

I think this has been discussed recently.

HTH
Urs



What I can't seem to find (although it may well be in the documentation
somewhere) is a clear explanation of this.  Can somebody point me in the
right direction?

David


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



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


Re: small caps

2015-01-16 Thread Kevin Barry
Dear Craig,

Can you provide an example that compiles on its own? A simplified version
of your code is working for me. Also, what font are you using?

Kevin

On Fri, Jan 16, 2015 at 9:00 AM, Craig Dabelstein <
craig.dabelst...@gmail.com> wrote:

> Hi Shane,
>
> \version "2.19.11"
>
> Even with \smallCaps (how did I miss that!?!!?) the test stays the same.
> Bold and Large are both working but not the small caps.
>
> Craig
>
>
> On Fri Jan 16 2015 at 4:39:22 PM Shane Brandes 
> wrote:
>
>> Which version are you using? and is it not \smallcaps that you need to
>> issue? Also does the font actually have small caps natively?
>>
>> Shane
>>
>> On Fri, Jan 16, 2015 at 12:54 AM, Craig Dabelstein
>>  wrote:
>> > Hi List,
>> >
>> > Can anyone tell me why I can't get small caps working with this code?
>> >
>> > Many thanks,
>> >
>> > Craig
>> >
>> > scoreTitleMarkup = \markup {
>> > \column {
>> >   \on-the-fly \print-all-headers { \bookTitleMarkup \hspace #1 }
>> >   \fill-line {
>> > \large \bold \caps \fromproperty #'header:piece
>> >  }
>> > }
>> >   }
>> > }
>> >
>> > ___
>> > lilypond-user mailing list
>> > lilypond-user@gnu.org
>> > https://lists.gnu.org/mailman/listinfo/lilypond-user
>> >
>>
>
> ___
> lilypond-user mailing list
> lilypond-user@gnu.org
> https://lists.gnu.org/mailman/listinfo/lilypond-user
>
>
___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


if/then/else in Lilypond with config file

2015-01-16 Thread cpf
> Is there a possibility to do something like this?
 >
 > if( custom_cfg_flag)
 > {
 > % default score combination
 > % (e.g. with header and chords)
 > }
 > else
 > {
 > % some other combination
 > % (e.g. only melody)
 > }

 I have also always wanted LilyPond to provide me with
 the code-writing niceties which C offers. Here is a
 method which enables me to use blocks of preprocessor
 directives in the manner which I am used to:

 #define BEGRIFF

 #ifdef BEGRIFF
   #define INTEGER_CONSTANT 1
 #else
   #define INTEGER_CONSTANT 43
 #endif

 My operating system is Linux. For its GNU Compiler Suite
 there is the preprocessor ``gpp''. This preprocessor can
 be invoked with the ``-T'' option, to instruct it to
 understand macros which are written in the style that
 TeX (and LilyPond) use.

 The first shell script processes a the file
 ``if-else-1a-input.ly''.

 -if-else-1a-input.ly-
 % Within a region which is commented, you can embed your
 % macro definitions.
 % \define{conditionalPackage}
 % \ifdef{conditionalPackage}
 %   \define{musicPassage}{\musicPassageAlpha}
 % \else
 %   \define{musicPassage}{\musicPassageBeta}
 % \endif
 \version "2.12.3"
 \header { title = "Using if/else Constructs by Means of GPP" }
 musicPassageAlpha = { c'4 d' e' f' }
 musicPassageBeta = { b,4 a, g, f, }
 \score {
   <<
     \new Staff \musicPassage
   >>
   \layout { }
 }
 % EOF
 ---

 Here is the shell script that does the work:

 -if-else-1a.sh-
 #! /bin/bash
 # Invokes ``[[gpp]]'' in order to process an input file
 # which has a macro definition in it formatted in the
 # manner which TeX formats things.
 INPUT_FILE=if-else-1a-input.ly
 OUTPUT_FILE=if-else-1a-output.ly
 gpp -T -o $OUTPUT_FILE $INPUT_FILE && \
   echo 'Output file "'$OUTPUT_FILE'" successfully written.'
 # EOF
 ---

 The second shell script processes a the file
 ``if-else-1b-input.ly''. This document has an ``undef''
 preprocessor directive in it.

 -if-else-1b-input.ly-
 % Within a region which is commented, you can embed your
 % macro definitions.
 % This version puts an ``undef'' preprocessor
 % directive in the macro definition.
 % \define{conditionalPackage}
 % \undef{conditionalPackage}
 % \ifdef{conditionalPackage}
 %   \define{musicPassage}{\musicPassageAlpha}
 % \else
 %   \define{musicPassage}{\musicPassageBeta}
 % \endif
 \version "2.12.3"
 \header { title="Using if/else Constructs by Means of GPP" }
 musicPassageAlpha = { c'4 d' e' f' }
 musicPassageBeta = { b'''4 a''' g''' f''' }
 \score {
   <<
     \new Staff \musicPassage
   >>
   \layout { }
 }
 % EOF
 ---

 Here is the shell script that does the work:

 -if-else-1b.sh-
 #! /bin/bash
 # Invokes ``[[gpp]]'' in order to process an input file
 # which has a macro definition in it formatted in the
 # manner which TeX formats things.
 INPUT_FILE=if-else-1b-input.ly
 OUTPUT_FILE=if-else-1b-output.ly
 gpp -T -o $OUTPUT_FILE $INPUT_FILE && \
   echo 'Output file "'$OUTPUT_FILE'" successfully written.'
 # EOF
 ---___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: small caps

2015-01-16 Thread tisimst
Kevin,

"\caps" and "\smallCaps" should work with any font since they simply 
iterate through the string and reduce the font size by a scaling factor 
-2 for all characters except those already in upper-case.

The only function, related to this conversation thread, that cares 
about the actual font is "\fontCaps", in which it actually sets a font 
property 'font-shape to 'caps. If the offending font has no such 
property, it reverts to the default normal, non-bold, non-italic font.

- Abraham

On Fri, Jan 16, 2015 at 6:32 AM, Kevin Barry [via Lilypond] 
 wrote:
> Dear Craig,
> 
> Can you provide an example that compiles on its own? A simplified 
> version of your code is working for me. Also, what font are you using?
> 
> Kevin
> 
> On Fri, Jan 16, 2015 at 9:00 AM, Craig Dabelstein <[hidden email]> 
> wrote:
>> Hi Shane,
>> 
>> \version "2.19.11"
>> 
>> Even with \smallCaps (how did I miss that!?!!?) the test stays the 
>> same. Bold and Large are both working but not the small caps. 
>> 
>> Craig
>> 
>> 
>> On Fri Jan 16 2015 at 4:39:22 PM Shane Brandes <[hidden email]> 
>> wrote:
>>> Which version are you using? and is it not \smallcaps that you need 
>>> to
>>> issue? Also does the font actually have small caps natively?
>>> 
>>> Shane
>>> 
>>> On Fri, Jan 16, 2015 at 12:54 AM, Craig Dabelstein
>>> <[hidden email]> wrote:
>>> > Hi List,
>>> >
>>> > Can anyone tell me why I can't get small caps working with this 
>>> code?
>>> >
>>> > Many thanks,
>>> >
>>> > Craig
>>> >
>>> > scoreTitleMarkup = \markup {
>>> > \column {
>>> >   \on-the-fly \print-all-headers { \bookTitleMarkup \hspace 
>>> #1 }
>>> >   \fill-line {
>>> > \large \bold \caps \fromproperty #'header:piece
>>> >  }
>>> > }
>>> >   }
>>> > }
>>> >
>>> > ___
>>> > lilypond-user mailing list
>>> > [hidden email]
>>> > https://lists.gnu.org/mailman/listinfo/lilypond-user
>>> >
>> 
>> ___
>> lilypond-user mailing list
>> [hidden email]
>> https://lists.gnu.org/mailman/listinfo/lilypond-user
>> 
> 
> 
> ___ 
> lilypond-user mailing list 
> [hidden email] 
> https://lists.gnu.org/mailman/listinfo/lilypond-user
> 
> 
> If you reply to this email, your message will be added to the 
> discussion below:
> http://lilypond.1069038.n5.nabble.com/small-caps-tp170540p170555.html
> To start a new topic under User, email 
> ml-node+s1069038n...@n5.nabble.com 
> To unsubscribe from Lilypond, click here.
> NAML




--
View this message in context: 
http://lilypond.1069038.n5.nabble.com/small-caps-tp170540p170558.html
Sent from the User mailing list archive at Nabble.com.___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


RE: Understanding Lilypond

2015-01-16 Thread Peter Gentry
 David

Join the club - many of us have struggled for many months to get to grips with 
the structure and philosophy of Lilypond. Some of the
enlightened have often poured scorn on these attempts or became very defensive 
of any suggestion that the documentation
(comprehensive as it is) does not greatly help new comers to become familiar 
with the program.

The many many "tweaks" sometimes fairly incomprehensible (without a grouding in 
the structure and philosophy of the code) are also
daunting. This is not a critiscism of either the code or the documentation.

Just one small example many/all the \overide options are bizarre and not easily 
(if at all) found in the documentation.

Maybe the originators have all moved on and left this wonderful legacy to us 
lesser mortals.

So best of luck david if you do manage to penetrate the fog and demystify it 
for us many will be very grateful.

>-Original Message-
>From: 
>lilypond-user-bounces+peter.gentry=sunscales.co...@gnu.org 
>[mailto:lilypond-user-bounces+peter.gentry=sunscales.co.uk@gnu.
org] On Behalf Of lilypond-user-requ...@gnu.org
>Sent: Friday, January 16, 2015 1:32 PM
>To: lilypond-user@gnu.org
>Subject: [SPAM] lilypond-user Digest, Vol 146, Issue 77
>
>Send lilypond-user mailing list submissions to
>   lilypond-user@gnu.org
>
>To subscribe or unsubscribe via the World Wide Web, visit
>   https://lists.gnu.org/mailman/listinfo/lilypond-user
>or, via email, send a message with subject or body 'help' to
>   lilypond-user-requ...@gnu.org
>
>You can reach the person managing the list at
>   lilypond-user-ow...@gnu.org
>
>When replying, please edit your Subject line so it is more 
>specific than "Re: Contents of lilypond-user digest..."
>
>
>Today's Topics:
>
>   1. Understanding Lilypond (David Sumbler)
>   2. Re:Re:bottom of EPS output cut off (+ size of PDF files)
>  (Jayaratna)
>   3. Re:small caps (tisimst)
>   4. Re:Understanding Lilypond (Urs Liska)
>   5. Re:small caps (Kevin Barry)
>
>
>--
>
>Message: 1
>Date: Fri, 16 Jan 2015 12:35:55 +
>From: David Sumbler 
>To: lilypond-user@gnu.org
>Subject: Understanding Lilypond
>Message-ID: <1421411755.2409.25.camel@vesta>
>Content-Type: text/plain; charset="UTF-8"
>
>As I start to gain experience in setting music in Lilypond I 
>am trying to understand more about how it works internally.  
>As well as personal satisfaction, this obviously has a 
>practical aim: it will make it easier for me to modify or 
>correct things without having to ask so many questions on this 
>forum, and will also perhaps eventually mean that I can help 
>by answering others' questions.
>
>However, despite having read the documentation - some of it 
>several times - I do find understanding some aspects of the 
>structure of Lilypond extremely difficult.  One of the manuals 
>likens a Lilypond file to source code in a computer language, 
>but I find that understanding the structure of a coding 
>language is perfectly straightforward compared to getting my 
>head around Lilypond.  (I have learnt several languages over 
>the years, although not, I admit, Lisp or Scheme; however, I 
>have no reason to suppose that understanding their structure 
>is any more difficult than other languages).
>
>For instance, in Lilypond there is a sensible difference in 
>the default handling of time- and key-signatures.  Using the 
>\key command a key is defined for the current Staff.  But 
>using the \time command sets the time signature for every 
>staff.  If a different time signature is required for a 
>particular staff, then timeSignatureFraction has to be changed.
>
>>From the Internals Reference I see that the 2 layout objects
>KeySignature and TimeSignature both exist, by default, in a 
>Staff context, which makes perfect sense.
>
>Clearly, though, when the \time command is used, then not only 
>is Staff.timeSignatureFraction set, but so also is some other 
>variable in a higher context.
>
>What I can't seem to find (although it may well be in the documentation
>somewhere) is a clear explanation of this.  Can somebody point 
>me in the right direction?
>
>David
>
>
>
>
>--
>
>Message: 2
>Date: Fri, 16 Jan 2015 06:15:18 -0700 (MST)
>From: Jayaratna 
>To: lilypond-user@gnu.org
>Subject: Re: Re:bottom of EPS output cut off (+ size of PDF files)
>Message-ID: <1421414118453-170551.p...@n5.nabble.com>
>Content-Type: text/plain; charset=us-ascii
>
>I found a couple of instances in which this crop method too fails:
>
>a) the stem of a b flat;
>b) the 8 at the bottom of an octavated clef.
>
>See attached files.
>
>esempio3033-crop.pdf
>-crop.pdf>
>esempio3064-crop.pdf
>-crop.pdf>  
>
>
>
>--
>View this message in context: 
>http://lilypond.1069038.n5.nabble.com/Re-bottom-of-EPS-output-c
ut-off-size-

Re: small caps

2015-01-16 Thread Kevin Barry
>
> "\caps" and "\smallCaps" should work with any font since they simply
> iterate through the string and reduce the font size by a scaling factor -2
> for all characters except those already in upper-case.
>

Does this mean that lilypond doesn't use the true small caps that many
fonts include?
___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Understanding Lilypond

2015-01-16 Thread Urs Liska


Am 16.01.2015 um 14:46 schrieb Peter Gentry:

  David

Join the club - many of us have struggled for many months to get to grips with 
the structure and philosophy of Lilypond. Some of the
enlightened have often poured scorn on these attempts or became very defensive 
of any suggestion that the documentation
(comprehensive as it is) does not greatly help new comers to become familiar 
with the program.

The many many "tweaks" sometimes fairly incomprehensible (without a grouding in 
the structure and philosophy of the code) are also
daunting. This is not a critiscism of either the code or the documentation.

Just one small example many/all the \overide options are bizarre and not easily 
(if at all) found in the documentation.

Maybe the originators have all moved on and left this wonderful legacy to us 
lesser mortals.

So best of luck david if you do manage to penetrate the fog and demystify it 
for us many will be very grateful.


Just let me repeat something I wrote a number of times here.
If you manage to understand something with the help of this list that 
you think could be a not-so-uncommon issue for many please consider 
sharing your experience with a (little or big) tutorial, for which we 
have always "free space" on the Scores of Beauty blog.


Urs



-Original Message-
From:
lilypond-user-bounces+peter.gentry=sunscales.co...@gnu.org
[mailto:lilypond-user-bounces+peter.gentry=sunscales.co.uk@gnu.

org] On Behalf Of lilypond-user-requ...@gnu.org

Sent: Friday, January 16, 2015 1:32 PM
To: lilypond-user@gnu.org
Subject: [SPAM] lilypond-user Digest, Vol 146, Issue 77

Send lilypond-user mailing list submissions to
lilypond-user@gnu.org

To subscribe or unsubscribe via the World Wide Web, visit
https://lists.gnu.org/mailman/listinfo/lilypond-user
or, via email, send a message with subject or body 'help' to
lilypond-user-requ...@gnu.org

You can reach the person managing the list at
lilypond-user-ow...@gnu.org

When replying, please edit your Subject line so it is more
specific than "Re: Contents of lilypond-user digest..."


Today's Topics:

   1. Understanding Lilypond (David Sumbler)
   2. Re:Re:bottom of EPS output cut off (+ size of PDF files)
  (Jayaratna)
   3. Re:small caps (tisimst)
   4. Re:Understanding Lilypond (Urs Liska)
   5. Re:small caps (Kevin Barry)


--

Message: 1
Date: Fri, 16 Jan 2015 12:35:55 +
From: David Sumbler 
To: lilypond-user@gnu.org
Subject: Understanding Lilypond
Message-ID: <1421411755.2409.25.camel@vesta>
Content-Type: text/plain; charset="UTF-8"

As I start to gain experience in setting music in Lilypond I
am trying to understand more about how it works internally.
As well as personal satisfaction, this obviously has a
practical aim: it will make it easier for me to modify or
correct things without having to ask so many questions on this
forum, and will also perhaps eventually mean that I can help
by answering others' questions.

However, despite having read the documentation - some of it
several times - I do find understanding some aspects of the
structure of Lilypond extremely difficult.  One of the manuals
likens a Lilypond file to source code in a computer language,
but I find that understanding the structure of a coding
language is perfectly straightforward compared to getting my
head around Lilypond.  (I have learnt several languages over
the years, although not, I admit, Lisp or Scheme; however, I
have no reason to suppose that understanding their structure
is any more difficult than other languages).

For instance, in Lilypond there is a sensible difference in
the default handling of time- and key-signatures.  Using the
\key command a key is defined for the current Staff.  But
using the \time command sets the time signature for every
staff.  If a different time signature is required for a
particular staff, then timeSignatureFraction has to be changed.

>From the Internals Reference I see that the 2 layout objects
KeySignature and TimeSignature both exist, by default, in a
Staff context, which makes perfect sense.

Clearly, though, when the \time command is used, then not only
is Staff.timeSignatureFraction set, but so also is some other
variable in a higher context.

What I can't seem to find (although it may well be in the documentation
somewhere) is a clear explanation of this.  Can somebody point
me in the right direction?

David




--

Message: 2
Date: Fri, 16 Jan 2015 06:15:18 -0700 (MST)
From: Jayaratna 
To: lilypond-user@gnu.org
Subject: Re: Re:bottom of EPS output cut off (+ size of PDF files)
Message-ID: <1421414118453-170551.p...@n5.nabble.com>
Content-Type: text/plain; charset=us-ascii

I found a couple of instances in which this crop method too fails:

a) the stem of a b flat;
b) the 8 at the bottom of an octavated clef.

See attached files.

esempio3033-crop.pdf


Re: Adjusting the position of tempo indications

2015-01-16 Thread Kevin Barry
Dear David,

> > \score {
> > > \new StaffGroup <<
> > > \override Score.MetronomeMark.padding = #2
> > > \topLine
> > > \bottomLine
> > > >>
> > > }
>

Here if you replace the `padding' property with `outside-staff-padding' it
should work, i.e.
\override Score.MetronomeMark.outside-staff-padding = #2

hth,
Kevin
___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re:bottom of EPS output cut off (+ size of PDF files)

2015-01-16 Thread Andrew Cashner
I revised lilycrop.sh with two new features:
 1.  invoke with -e option for EPS output
 2.  invoke with -l option to write output file names to log file (use
-el for both options)

The script now includes better error checking of command-line arguments.

I don't know how to make it accept shell wildcards, though.

Andrew

https://github.com/andrewacashner/lilypond/

>
> Message: 2
> Date: Thu, 15 Jan 2015 20:04:18 -0700 (MST)
> From: Jayaratna 
> To: lilypond-user@gnu.org
> Subject: Re: Re:bottom of EPS output cut off (+ size of PDF files)
> Message-ID: <1421377458283-170538.p...@n5.nabble.com>
> Content-Type: text/plain; charset=us-ascii
>
> Hi Andrew,
>
> thanks a lot. I am not a programmer so I couldn't have taken the workaround
> to this level, you can't imagine how much work this is going to spare me.
>
> May I request a feature? Is there a way to insert an option for getting eps
> output?
>
> Thanks again,
> Andrea
>
>

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


Re: small caps

2015-01-16 Thread Shane Brandes
\fontCaps attempts to access the fonts smcp flavor the other two
methods are hocus pocus relying on scaling as apposed to a true small
caps set.

Shane

On Fri, Jan 16, 2015 at 8:52 AM, Kevin Barry  wrote:
>> "\caps" and "\smallCaps" should work with any font since they simply
>> iterate through the string and reduce the font size by a scaling factor -2
>> for all characters except those already in upper-case.
>
>
> Does this mean that lilypond doesn't use the true small caps that many fonts
> include?
>
> ___
> lilypond-user mailing list
> lilypond-user@gnu.org
> https://lists.gnu.org/mailman/listinfo/lilypond-user
>

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


Re: box around notes

2015-01-16 Thread Klaus Blum
Hi David, 
thanks again. You're my hero: now it works.


I've added a few things so far:

- "thickness" property can be used to control frame thickness, can even be
set to zero ("color" property and "layer" property work by default)
- "filled" property (boolean) controls whether the box is to be filled with
a colored rectangle whose color can be set by "fill-color" property.

I've also added two global boolean variables "acknowledge-finger-interface"
and "acknowledge-script-interface" to control whether the boxes take care of
fingerings and dynamics. For example, if you want to mark themes and motifs,
you might only want to consider the notes and rests.
Unfortunately, these settings are valid for the whole score and therefore
cannot change during a piece. I'd prefer to use properties, because this
would allow \once \override etc. But I don't know how to access these
properties from within musicBoxerEngraver.
If a box is split due to a line break, it would be cool to have those two
boxes open at the right/left side. For this, musicBoxerEngraver would need
to tell if a box is started/stopped by a line break instead of a manual
command. 
Dear list members, can anybody help how to achieve that? Sorry for always
coming up with crazy ideas that go far beyond my scheme knowledge.  ;-)

Cheers, 
Klaus

boxer-attempt2.ly
  


David Nalesnik-2 wrote
> 
> You need to make LilyPond aware of the new property: what type does it
> have? does it have a documentation string?  (The latter is important
> because the documentation in the Internals Reference is generated
> automatically.)
> 
> Add the following lines above the stencil function (make-box):
> 
> %%%
> #(define (define-grob-property symbol type? description)
>   (if (not (equal? (object-property symbol 'backend-doc) #f))
>   (ly:error (_ "symbol ~S redefined") symbol))
> 
>   (set-object-property! symbol 'backend-type? type?)
>   (set-object-property! symbol 'backend-doc description)
>   symbol)
> 
> #(map
>   (lambda (x)
> (apply define-grob-property x))
> 
>   `(
> (filled ,boolean?
>   "Should we fill in this box?")
> ; add more properties here
>   ))
> 
> %





--
View this message in context: 
http://lilypond.1069038.n5.nabble.com/box-around-notes-tp35581p170575.html
Sent from the User mailing list archive at Nabble.com.

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


Fwd: Re: small caps

2015-01-16 Thread Nick Payne

Accidentally sent this only to the OP rather than to the list...
 Forwarded Message 
Subject:Re: small caps
Date:   Fri, 16 Jan 2015 20:55:30 +1100
From:   Nick Payne 
To: Craig Dabelstein 



I think you have encountered bug #1482: 
https://code.google.com/p/lilypond/issues/detail?id=1482


On 16/01/2015 20:00, Craig Dabelstein wrote:

Hi Shane,

\version "2.19.11"

Even with \smallCaps (how did I miss that!?!!?) the test stays the 
same. Bold and Large are both working but not the small caps.


Craig


On Fri Jan 16 2015 at 4:39:22 PM Shane Brandes > wrote:


Which version are you using? and is it not \smallcaps that you need to
issue? Also does the font actually have small caps natively?

Shane

On Fri, Jan 16, 2015 at 12:54 AM, Craig Dabelstein
mailto:craig.dabelst...@gmail.com>>
wrote:
> Hi List,
>
> Can anyone tell me why I can't get small caps working with this
code?
>
> Many thanks,
>
> Craig
>
> scoreTitleMarkup = \markup {
> \column {
>   \on-the-fly \print-all-headers { \bookTitleMarkup \hspace #1 }
>   \fill-line {
> \large \bold \caps \fromproperty #'header:piece
>  }
> }
>   }
> }
>
> ___
> lilypond-user mailing list
> lilypond-user@gnu.org 
> https://lists.gnu.org/mailman/listinfo/lilypond-user
>



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




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


Re: box around notes

2015-01-16 Thread David Nalesnik
Hi Klaus,

On Fri, Jan 16, 2015 at 11:35 AM, Klaus Blum  wrote:

> Hi David,
> thanks again. You're my hero: now it works.
>
>
> I've added a few things so far:
>
> - "thickness" property can be used to control frame thickness, can even be
> set to zero ("color" property and "layer" property work by default)
> - "filled" property (boolean) controls whether the box is to be filled with
> a colored rectangle whose color can be set by "fill-color" property.
>
> I've also added two global boolean variables "acknowledge-finger-interface"
> and "acknowledge-script-interface" to control whether the boxes take care
> of
> fingerings and dynamics. For example, if you want to mark themes and
> motifs,
> you might only want to consider the notes and rests.
> Unfortunately, these settings are valid for the whole score and therefore
> cannot change during a piece. I'd prefer to use properties, because this
> would allow \once \override etc. But I don't know how to access these
> properties from within musicBoxerEngraver.
>

In the attached, I simply added new properties:
acknowledge-finger-interface and acknowledge-script-interface.  In the
engraver, I used ly:grob-property to read the setting.  You'll notice that
if something is ignored it doesn't get pushed out of the way, though.

Adding properties like this would get cumbersome.  It would be nice to have
a property which takes a flexible list of interfaces to include (over and
above interfaces which need to be acknowledged, like note-column-interface).


> If a box is split due to a line break, it would be cool to have those two
> boxes open at the right/left side. For this, musicBoxerEngraver would need
> to tell if a box is started/stopped by a line break instead of a manual
> command.
>

This is not a problem.  I use the function ly:item-break-status on the
spanner bounds to determine the state of "brokenness," then add in the left
or right vertical only if that bound has a break-status of 0 (indicating an
unbroken bound).

I tried to keep music-boxer-stencil and make-box separate.  In so doing, I
had to add two more parameters to make-box.  (You may decide to merge the
two functions in the end.)

Hope this is helpful,

David
\version "2.19.15"

\header {
  tagline = ##f
}

%#(define acknowledge-finger-interface #t)
%#(define acknowledge-script-interface #t)

#(define-event-class 'music-boxer-event 'span-event)

#(define-event-class 'box-event 'music-event)

#(define (add-grob-definition grob-name grob-entry)
   (let* ((meta-entry   (assoc-get 'meta grob-entry))
  (class(assoc-get 'class meta-entry))
  (ifaces-entry (assoc-get 'interfaces meta-entry)))
 ;; change ly:grob-properties? to list? to work from 2.19.12 back to at least 2.18.2
 (set-object-property! grob-name 'translation-type? ly:grob-properties?)
 (set-object-property! grob-name 'is-grob? #t)
 (set! ifaces-entry (append (case class
  ((Item) '(item-interface))
  ((Spanner) '(spanner-interface))
  ((Paper_column) '((item-interface
 paper-column-interface)))
  ((System) '((system-interface
   spanner-interface)))
  (else '(unknown-interface)))
  ifaces-entry))
 (set! ifaces-entry (uniq-list (sort ifaces-entry symbol thick 0)
  (set! temp-stil-outer
(ly:stencil-add
 (make-filled-box-stencil (cons (- (car xext) thick) (+ (cdr xext) thick)) (cons (- (car yext) thick) (car yext) )) ; modified by KB
 (make-filled-box-stencil (cons (- (car xext) thick) (+ (cdr xext) thick)) (cons (cdr yext) (+ (cdr yext) thick)))  ; modified by KB
 (if (not open-on-right)
 (make-filled-box-stencil (cons (cdr xext) (+ (cdr xext) thick)) yext)
 empty-stencil)
 (if (not open-on-left)
 (make-filled-box-stencil (cons (- (car xext) thick) (car xext)) yext)
 empty-stencil)
 )))
 (ly:stencil-add
  temp-stil-inner
  temp-stil-outer
  )
 )
   )

#(define (music-boxer-stencil grob)
   (let* ((elts (ly:grob-object grob 'elements))
  (refp-X (ly:grob-common-refpoint-of-array grob elts X))
  (X-ext (ly:relative-group-extent elts refp-X X))
  (refp-Y (ly:grob-common-refpoint-of-array grob elts Y))
  (Y-ext (ly:relative-group-extent elts refp-Y Y))
  (padding (ly:grob-property grob 'padding 0.3))
  (thick (ly:grob-property grob 'thickness 0.1)) ; added by KB
  (filled (ly:grob-property grob 'filled #t)); added by KB
  (fill-color (ly:grob-property grob 'fill-color grey)); added by KB
  (offset (ly:grob-relative-coordinate grob refp-X X))
  (left-bound (ly:spanner-bound grob LEFT))

RE: Understanding Lilypond

2015-01-16 Thread Peter Gentry
 
>Just let me repeat something I wrote a number of times here.
>If you manage to understand something with the help of this 
>list that you think could be a not-so-uncommon issue for many 
>please consider sharing your experience with a (little or big) 
>tutorial, for which we have always "free space" on the Scores 
>of Beauty blog.
>
>Urs
>
>
First of all apologies for not cutting the bulk of the list posting on the 
previous message.

Scores of beauty is admirable and if I had something to contribute I would - 
problem is having something worthy of posting there.

I love Lilypond and use it weekly (maybe weakly)...


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


Re: Understanding Lilypond

2015-01-16 Thread Kieren MacMillan
Hi Peter,

> many of us have struggled for many months to get to grips with the structure 
> and philosophy of Lilypond.

1. Regarding the structure, what are you struggling with exactly?

2. Regarding the philosophy, what are you struggling with exactly?

Hope I can help!
Kieren.

___

Kieren MacMillan, composer
www:  
email:  i...@kierenmacmillan.info


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


Getting pitch out of a pair

2015-01-16 Thread and...@andis59.se

I store two pitches in a pair variable
x = #'(b . cis')

But then I want to retrieve each one as a  pitch in a music-function
foo = #(define-music-function (parser location bar) (ly:music?)
(define from (car x))
(define to (cdr x))
#{
\transpose $from $to $bar
#}

but when I use this
\foo a

I get Expecting pitch, found (quote b)

So what am I doing wrong and how can I do it right?

// Anders
PS! The foo function is just a snippet the real function does a bit more...
--
English isn't my first language.
So any error or strangeness is due to the translation.
Please correct my English so that I may become better.

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


Re: Understanding Lilypond

2015-01-16 Thread Noeck
Dear David,

as a small addition and a partly similar answer to Urs’, I think the point is:
LilyPond tries to suggest (or even enforce as a default) conventions of classic
music notation. This comprises for example that clefs are repeated for each line
but the time signature isn’t.

In your case, that means: The key signature can depend on the instrument and can
be different for each staff. But in most cases, the time signature is the same
within a score (across staves). You can have polyrhythmical music in LilyPond
but it is not the default. So while this looks inconsistent from the purely
programmatical point of view, it makes sense for most music.

Cheers,
Joram

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


Re: Getting pitch out of a pair

2015-01-16 Thread Jay Anderson
On Fri, Jan 16, 2015 at 4:02 PM, and...@andis59.se  wrote:
> I store two pitches in a pair variable
> x = #'(b . cis')
>
> But then I want to retrieve each one as a  pitch in a music-function
> foo = #(define-music-function (parser location bar) (ly:music?)
> (define from (car x))
> (define to (cdr x))
> #{
> \transpose $from $to $bar
> #}
>
> but when I use this
> \foo a
>
> I get Expecting pitch, found (quote b)
>
> So what am I doing wrong and how can I do it right?
>
> // Anders
> PS! The foo function is just a snippet the real function does a bit more...

pitches = #(cons #{ b #} #{ cis' #})
#(display (ly:pitch? (car pitches)))  => #t

Notes:
- It needs to be lilypond and not scheme which interprets the pitches.
The #{ #} do that inside a scheme expression.
- It won't work within a quoted list (e.g. #'(#{ b #} . #{ cis' #})
won't get you pitches.)

-Jay

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


Re: Getting pitch out of a pair

2015-01-16 Thread and...@andis59.se

On 2015-01-17 00:16, Jay Anderson wrote:

On Fri, Jan 16, 2015 at 4:02 PM, and...@andis59.se  wrote:

I store two pitches in a pair variable
x = #'(b . cis')



pitches = #(cons #{ b #} #{ cis' #})
#(display (ly:pitch? (car pitches)))  => #t



Ok that works but looks really bad
I liked the clean way the #'(b . cis') looks.

Is there some other way of storing two pitches and accessing each one in 
a music-function?


// Anders

--
English isn't my first language.
So any error or strangeness is due to the translation.
Please correct my English so that I may become better.

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


Re: Getting pitch out of a pair

2015-01-16 Thread Urs Liska


Am 17.01.2015 um 00:21 schrieb and...@andis59.se:

On 2015-01-17 00:16, Jay Anderson wrote:
On Fri, Jan 16, 2015 at 4:02 PM, and...@andis59.se 
 wrote:

I store two pitches in a pair variable
x = #'(b . cis')



pitches = #(cons #{ b #} #{ cis' #})
#(display (ly:pitch? (car pitches)))  => #t



Ok that works but looks really bad
I liked the clean way the #'(b . cis') looks.

Is there some other way of storing two pitches and accessing each one 
in a music-function?


You can encapsulate the ugliness in one more function:

#(define x #f)

setTransposition =
#(define-void-function (parser location a b)
   (ly:pitch? ly:pitch?)
   (set! x (cons #{ #a #} #{ #b #})))

foo =
#(define-music-function (parser location bar) (ly:music?)
   (define from (car x))
   (define to (cdr x))
   #{
 \transpose $from $to $bar
   #})

{
  \setTransposition a b
  \foo a
}


HTH
Urs


// Anders




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


Re: Getting pitch out of a pair

2015-01-16 Thread Thomas Morley
2015-01-17 0:21 GMT+01:00 and...@andis59.se :
> On 2015-01-17 00:16, Jay Anderson wrote:
>>
>> On Fri, Jan 16, 2015 at 4:02 PM, and...@andis59.se 
>> wrote:
>>>
>>> I store two pitches in a pair variable
>>> x = #'(b . cis')
>>>
>>
>> pitches = #(cons #{ b #} #{ cis' #})
>> #(display (ly:pitch? (car pitches)))  => #t
>>
>
> Ok that works but looks really bad
> I liked the clean way the #'(b . cis') looks.
>
> Is there some other way of storing two pitches and accessing each one in a
> music-function?
>
> // Anders


How about:

#(display (event-chord-pitches #{ < b cis' > #}))

Cheers,
  Harm

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


Re: Getting pitch out of a pair

2015-01-16 Thread Thomas Morley
2015-01-17 1:20 GMT+01:00 Thomas Morley :
> 2015-01-17 0:21 GMT+01:00 and...@andis59.se :
>> On 2015-01-17 00:16, Jay Anderson wrote:
>>>
>>> On Fri, Jan 16, 2015 at 4:02 PM, and...@andis59.se 
>>> wrote:

 I store two pitches in a pair variable
 x = #'(b . cis')

>>>
>>> pitches = #(cons #{ b #} #{ cis' #})
>>> #(display (ly:pitch? (car pitches)))  => #t
>>>
>>
>> Ok that works but looks really bad
>> I liked the clean way the #'(b . cis') looks.
>>
>> Is there some other way of storing two pitches and accessing each one in a
>> music-function?
>>
>> // Anders
>
>
> How about:
>
> #(display (event-chord-pitches #{ < b cis' > #}))
>
> Cheers,
>   Harm

#(display (event-chord-pitches #{  b cis'  #}))
works as well

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


Re: arpeggioArrowUp

2015-01-16 Thread Thomas Morley
2015-01-16 1:42 GMT+01:00 Thomas Morley :
> 2015-01-16 0:26 GMT+01:00 Thomas Morley :
>> 2015-01-15 15:02 GMT+01:00 tisimst :
>>> On Wed, Jan 14, 2015 at 11:47 PM, Schneidy [via Lilypond] <[hidden email]>
>>> wrote:
>>>
>>> Hi Harm,
>>>
>>> 2015-01-15 3:22 GMT+01:00 Thomas Morley <[hidden email]>:
>>>

 foo =
 #(define-music-function (parser location mus)(ly:music?)
   (music-map
 (lambda (m)
   (if (music-is-of-type? m 'arpeggio-event)
   (make-music
  'ArpeggioEvent
  'tweaks
  (list
(cons 'arpeggio-direction
  (ly:music-property m 'direction
   m))
 mus))


 \foo
 \relative c'' {
   \mark "sort of post-processing"
   4\arpeggio
   4^\arpeggio
   4_\arpeggio
 }
>>>
>>>
>>> I like this one.
>>> Cheers,
>>> Pierre
>>>
>>>
>>> +1!
>>>
>>> However, I'd rather not have to use another function (\foo) to do this.
>>> Otherwise, I don't think there's any benefit over what is currently required
>>> with \arpeggioArrowUp. Can't it be put directly into a command that supports
>>> the direction indicators? I can't seem to find in the documentation where
>>> the post-fix syntax is described.
>>>
>>> -Abraham
>>
>>
>>
>> The direction indicators _ and ^ are setting the 'direction, as their
>> name suggests ;).
>> Though the arpeggio-arrow is printed, if the _'arpeggio-direction_ is set!
>> Currently those are two different things. It may be discussable, if it
>> _should_ be this way, but it has some logic, if you think about it.
>> Nevertheless my 'foo'-function iterated through the music, setting
>> 'arpeggio-direction to the value of 'direction.
>> This is not very cheap, maybe better to use an engraver for this duty:
>>
>> \version "2.19.15"
>>
>> direction-to-arpeggio-direction-engraver =
>> #(lambda (context)
>>  (let ((dir '()))
>>   `((listeners
>>  (arpeggio-event
>>.
>>,(lambda (engraver event)
>>  ;; Not sure about following 'set!'
>>  ;; Is it save?
>>  (set! dir (ly:event-property event 'direction)
>> (acknowledgers
>>  (arpeggio-interface
>>.
>>,(lambda (engraver grob source-engraver)
>>   (set! (ly:grob-property grob 'arpeggio-direction) dir)
>>   (set! dir '(
>>
>
>
>
> %% c/p error, here the whole example:
>
> 
> %% EXAMPLE
> 
>
> \layout {
>   \context {
> \Score
> \consists #direction-to-arpeggio-direction-engraver
>   }
> }
>
> \relative c'' {
>   4\arpeggio
>   4^\arpeggio
>   4_\arpeggio
> }

Here an improved version, works cross-context as well:

\version "2.19.15"

\paper { indent = 0 }

direction-to-arpeggio-direction-engraver =
#(lambda (context)
 (let ((dir '()))
  `((listeners
 (arpeggio-event
   .
   ,(lambda (engraver event)
 ;; Not sure about following 'set!'
 ;; Is it save?
 (set! dir (ly:event-property event 'direction))
 ;; Is this needed?
 ;(ly:event-set-property! event 'direction '())
 )))
(acknowledgers
 (arpeggio-interface
   .
   ,(lambda (engraver grob source-engraver)
  (set! (ly:grob-property grob 'arpeggio-direction) dir)))


%% EXAMPLES


\new Staff \with { \consists #direction-to-arpeggio-direction-engraver }
\relative c'' {
  4\arpeggio
  4^\arpeggio
  4_\arpeggio
}

%% Note:
%% If used cross-context, only the last direction-indicator
%% for each time-step counts
\new Staff
  \with {
\consists "Span_arpeggio_engraver"
\consists #direction-to-arpeggio-direction-engraver
  }
  \relative c' {
\set Staff.connectArpeggios = ##t
<<
  \new Voice { \voiceOne 4\arpeggio  2\arpeggio }
  \new Voice { \voiceTwo 2^\arpeggio 2_\arpeggio }
>>
  }

\new PianoStaff
\with {
\consists #direction-to-arpeggio-direction-engraver
  }
  <<
\set PianoStaff.connectArpeggios = ##t
\new Staff {
  \relative c' {
\key b \major
\time 6/8
b8-.(^\arpeggio fis'-.\> cis-. e-. gis-. b-.)\!\fermata^\laissezVibrer
\bar "||"
  }
}
\new Staff {
  \relative c' {
\clef bass
\key b \major
<<
  {
2\arpeggio
  }
  \\
  {
2.^\arpeggio
  }
>>
  }
}
  >>

\score {
  \relative c'' {
\markLengthOn

<>^"default"
4\arpeggio

<>^"^ indicator"
4^\arpeggio

<>^"direction-tweak"
4-\tweak #'direction #RIGHT \arpeggio

<>^"direction-override"
\once \override Arpeggio.direction = #RIGHT
4\arpeggio
  }
  \layout {
ragged-right = ##f
  }
}


Cheers,
  Harm

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


Re: arpeggioArrowUp

2015-01-16 Thread Thomas Morley
2015-01-17 1:59 GMT+01:00 Thomas Morley :
> 2015-01-16 1:42 GMT+01:00 Thomas Morley :
>> 2015-01-16 0:26 GMT+01:00 Thomas Morley :
>>> 2015-01-15 15:02 GMT+01:00 tisimst :
 On Wed, Jan 14, 2015 at 11:47 PM, Schneidy [via Lilypond] <[hidden email]>
 wrote:

 Hi Harm,

 2015-01-15 3:22 GMT+01:00 Thomas Morley <[hidden email]>:

>
> foo =
> #(define-music-function (parser location mus)(ly:music?)
>   (music-map
> (lambda (m)
>   (if (music-is-of-type? m 'arpeggio-event)
>   (make-music
>  'ArpeggioEvent
>  'tweaks
>  (list
>(cons 'arpeggio-direction
>  (ly:music-property m 'direction
>   m))
> mus))
>
>
> \foo
> \relative c'' {
>   \mark "sort of post-processing"
>   4\arpeggio
>   4^\arpeggio
>   4_\arpeggio
> }


 I like this one.
 Cheers,
 Pierre


 +1!

 However, I'd rather not have to use another function (\foo) to do this.
 Otherwise, I don't think there's any benefit over what is currently 
 required
 with \arpeggioArrowUp. Can't it be put directly into a command that 
 supports
 the direction indicators? I can't seem to find in the documentation where
 the post-fix syntax is described.

 -Abraham
>>>
>>>
>>>
>>> The direction indicators _ and ^ are setting the 'direction, as their
>>> name suggests ;).
>>> Though the arpeggio-arrow is printed, if the _'arpeggio-direction_ is set!
>>> Currently those are two different things. It may be discussable, if it
>>> _should_ be this way, but it has some logic, if you think about it.
>>> Nevertheless my 'foo'-function iterated through the music, setting
>>> 'arpeggio-direction to the value of 'direction.
>>> This is not very cheap, maybe better to use an engraver for this duty:
>>>
>>> \version "2.19.15"
>>>
>>> direction-to-arpeggio-direction-engraver =
>>> #(lambda (context)
>>>  (let ((dir '()))
>>>   `((listeners
>>>  (arpeggio-event
>>>.
>>>,(lambda (engraver event)
>>>  ;; Not sure about following 'set!'
>>>  ;; Is it save?
>>>  (set! dir (ly:event-property event 'direction)
>>> (acknowledgers
>>>  (arpeggio-interface
>>>.
>>>,(lambda (engraver grob source-engraver)
>>>   (set! (ly:grob-property grob 'arpeggio-direction) dir)
>>>   (set! dir '(
>>>
>>
>>
>>
>> %% c/p error, here the whole example:
>>
>> 
>> %% EXAMPLE
>> 
>>
>> \layout {
>>   \context {
>> \Score
>> \consists #direction-to-arpeggio-direction-engraver
>>   }
>> }
>>
>> \relative c'' {
>>   4\arpeggio
>>   4^\arpeggio
>>   4_\arpeggio
>> }
>
> Here an improved version, works cross-context as well:
>
> \version "2.19.15"
>
> \paper { indent = 0 }
>
> direction-to-arpeggio-direction-engraver =
> #(lambda (context)
>  (let ((dir '()))
>   `((listeners
>  (arpeggio-event
>.
>,(lambda (engraver event)
>  ;; Not sure about following 'set!'
>  ;; Is it save?
>  (set! dir (ly:event-property event 'direction))
>  ;; Is this needed?
>  ;(ly:event-set-property! event 'direction '())
>  )))
> (acknowledgers
>  (arpeggio-interface
>.
>,(lambda (engraver grob source-engraver)
>   (set! (ly:grob-property grob 'arpeggio-direction) dir)))
>
> 
> %% EXAMPLES
> 
>
> \new Staff \with { \consists #direction-to-arpeggio-direction-engraver }
> \relative c'' {
>   4\arpeggio
>   4^\arpeggio
>   4_\arpeggio
> }
>
> %% Note:
> %% If used cross-context, only the last direction-indicator
> %% for each time-step counts
> \new Staff
>   \with {
> \consists "Span_arpeggio_engraver"
> \consists #direction-to-arpeggio-direction-engraver
>   }
>   \relative c' {
> \set Staff.connectArpeggios = ##t
> <<
>   \new Voice { \voiceOne 4\arpeggio  2\arpeggio }
>   \new Voice { \voiceTwo 2^\arpeggio 2_\arpeggio }
> >>
>   }
>
> \new PianoStaff
> \with {
> \consists #direction-to-arpeggio-direction-engraver
>   }
>   <<
> \set PianoStaff.connectArpeggios = ##t
> \new Staff {
>   \relative c' {
> \key b \major
> \time 6/8
> b8-.(^\arpeggio fis'-.\> cis-. e-. gis-. b-.)\!\fermata^\laissezVibrer
> \bar "||"
>   }
> }
> \new Staff {
>   \relative c' {
> \clef bass
> \key b \major
> <<
>   {
> 2\arpeggio
>   }
>   \\
>   {
> 2.^\arpeggio
>   }
> >>
>   }
> }
>   >>

Delete the following. It's some syntax-testing, copied by accident

> \score {
>   \relative c'' {
> \markLengthOn
>
> <>^"default"
> 4\arpeggio
>
> <>^"^ indicator"
> 4^\arpeggio
>
> <>

Re: lilypond-user Digest, Vol 146, Issue 81

2015-01-16 Thread David Sumbler
> From: Noeck 
> To: lilypond-user@gnu.org
> Subject: Re: Understanding Lilypond
> Date: Sat, 17 Jan 2015 00:04:34 +0100
> 
> Dear David,
> 
> as a small addition and a partly similar answer to Urs’, I think the point is:
> LilyPond tries to suggest (or even enforce as a default) conventions of 
> classic
> music notation. This comprises for example that clefs are repeated for each 
> line
> but the time signature isn’t.
> 
> In your case, that means: The key signature can depend on the instrument and 
> can
> be different for each staff. But in most cases, the time signature is the same
> within a score (across staves). You can have polyrhythmical music in LilyPond
> but it is not the default. So while this looks inconsistent from the purely
> programmatical point of view, it makes sense for most music.
> 
> Cheers,
> Joram

With respect, as a professional (mainly classical) musician for half a
century I totally understand why key signatures and time signatures are
handled differently.

My query - evidently not very well expressed - was not "why does
Lilypond handle them differently", but "how does one discover the
internal mechanism by which it does this".  Peter clearly understood
this, and although he could not provide an answer to how to find an
answer in the documentation, he has apparently felt the same frustration
in the past.

If or when I ever get to a comprehensive understanding of how Lilypond
handles things, I might well take Urs up on his suggestion of writing
something on the subject for Scores of Beauty - a site I was not aware
of until this evening.

David


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


Re: Re:bottom of EPS output cut off (+ size of PDF files)

2015-01-16 Thread Jayaratna
for i in *.ly; do lilycrop  "$i"; done



--
View this message in context: 
http://lilypond.1069038.n5.nabble.com/Re-bottom-of-EPS-output-cut-off-size-of-PDF-files-tp170572p170591.html
Sent from the User mailing list archive at Nabble.com.

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