Re: Certain accidentals

2014-04-19 Thread David Kastrup
Urs Liska  writes:

> I find that very annoying, but he insists that it is in no way
> ambiguous (because you always _see_ the score fragment you're working
> on and the editor also always shows you the effective key). And he
> insists that it is much more efficient simply because he has to type
> less.

It's rather error-prone since it means that you cannot ever use
copy-and-paste for any piece of music since its meaning will change
depending on where you copy it.  I assume that you are _not_ typing what
gets typeset but instead a version relative to the current key in
effect.  If you are _indeed_ typing what gets typeset, the meaning of a
phrase would change even when just repeating it displaced by non-whole
measures.  Irrespective of that, you cannot copy into a different key,
or move a key change across some passage to make it scan better.

-- 
David Kastrup

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


Re: Certain accidentals

2014-04-19 Thread Christ van Willegen
On Fri, Apr 18, 2014 at 3:48 PM, Urs Liska  wrote:
> Actually I'm currently in a discussion with a (highly) professional engraver
> using Amadeus (a Unix/Linux program that has been out of development for 15
> years now but is still used by a number of professionals). Amadeus is a
> text-compiling program that has a number of striking similarities to
> LilyPond, but also a number of striking differences.
> Among others, in Amadeus you'll write the pitch you _see_ and not the one
> you hear. That is when you're in D major you'll write "F" to get a fis,
> you'd only write fis if you want an extra accidental.

And if you'd life to get an F-natural in the key of D major, how would
you write that?

Christ van Willegen
-- 
09 F9 11 02 9D 74 E3 5B D8 41 56 C5 63 56 88 C0

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


Re: Certain accidentals

2014-04-19 Thread Urs Liska
I'll look that up, I have got the manual.

Christ van Willegen  schrieb am 19.04.2014:
>On Fri, Apr 18, 2014 at 3:48 PM, Urs Liska  wrote:
>> Actually I'm currently in a discussion with a (highly) professional
>engraver
>> using Amadeus (a Unix/Linux program that has been out of development
>for 15
>> years now but is still used by a number of professionals). Amadeus is
>a
>> text-compiling program that has a number of striking similarities to
>> LilyPond, but also a number of striking differences.
>> Among others, in Amadeus you'll write the pitch you _see_ and not the
>one
>> you hear. That is when you're in D major you'll write "F" to get a
>fis,
>> you'd only write fis if you want an extra accidental.
>
>And if you'd life to get an F-natural in the key of D major, how would
>you write that?
>
>Christ van Willegen

-- 
Diese Nachricht wurde mit https://play.google.com/store/apps/details?id=com.onegravity.k10.pro2";>K-@
 Mail gesendet.___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Certain accidentals

2014-04-19 Thread Brian Barker

At 15:41 19/04/2014 +0200, Christ van Willegen wrote:
And if you'd life to get an F-natural in the key of D major, how 
would you write that?


Clearly, following normal musical notation, you'd annotate the F in 
some way as being not the expected F in D major (F#) - using 
something such as fn.


Brian Barker  



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


Re: Certain accidentals

2014-04-19 Thread Kieren MacMillan
Hi Brian,

Since you are [ostensibly] sitting on the fence…  ;)
This is my “+1” for the cut-and-pastability (and, by extension, 
variable-referencibility, etc.) of Lily-code as noted by David K.
Having engraved hundreds of Lilypond scores in the past 11 years — many with 
dozens of movements, 50+ staves, etc., and perhaps half of which include 
transposing instruments — I can’t imagine the nightmare that would ensue if the 
code was entered without explicit alteration(s).

All the best,
Kieren.

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


voice solfege sequence

2014-04-19 Thread MING TSANG
Hi, lilyponders:
The attach .ly file show the sequencing of solfege above the staff behaves 
inconsistent.
How can this be resolved?  I am also hoping it will be the same if it is 
sequencing below the staff. The color solfege will be showing on the lower 
stack in both case.
Help is appreciated.
Emmanuel,
Ming\version "2.19.4"
\language "english"

%%%\include "include_solfege-engraver.ly"
#(define syllables '("do" "re" "mi" "fa" "so" "la" "ti"))
#(define syls '("d" "r" "m" "f" "s" "l" "t"))
#(define numR➀ '("➀" "➁" "➂" "➃" "➄" "➅" "➆"))
#(define number '("1" "2" "3" "4" "5" "6" "7"))
#(define numR➑ '("➊" "➋" "➌" "➍" "➎" "➏" "➐"))

#(define (solfege-engraver lst dir)
   (make-engraver 
 (acknowledgers
  ((note-head-interface engraver grob source)
   (let* (
  (context (ly:translator-context engraver))
  (tonic-pitch (ly:context-property context 'tonic))
  (tonic-index (ly:pitch-notename tonic-pitch))
  (event (ly:grob-property grob 'cause))
  (grob-pitch (ly:event-property event 'pitch))
  (grob-index (ly:pitch-notename grob-pitch))
  (delta (modulo (- grob-index tonic-index) 7))
  (name (list-ref lst delta))
  (newgrob (ly:engraver-make-grob engraver 'TextScript event)))
 (if (string= name "Hb")  (set! name "B"))
 (set! (ly:grob-property newgrob 'text) name)
 (set! (ly:grob-property newgrob 'direction) dir) )


xup = \with { \consists #(solfege-engraver syllables UP) }
xdown = \with { \consists #(solfege-engraver syllables DOWN) }
zup= \with { \consists #(solfege-engraver syls UP) }
zdown= \with { \consists #(solfege-engraver syls DOWN) }
nup= \with { \consists #(solfege-engraver number  UP) }
ndown= \with { \consists #(solfege-engraver number  DOWN) }
rup= \with { \consists #(solfege-engraver numR➀ UP) }
rdown= \with { \consists #(solfege-engraver numR➀ DOWN) }
sup= \with { \consists #(solfege-engraver numR➑ UP) }
sdown= \with { \consists #(solfege-engraver numR➑ DOWN) }
%end
clors =
#(define-music-function (parser location which color music)
((procedure? car) color? ly:music?)
  (music-map
(lambda (mus)
  (if (music-is-of-type? mus 'event-chord)
  (let* ((evt-chrd-nts (event-chord-notes mus)))
   (if (> (length evt-chrd-nts) 1)
   (let ((first-nh (which evt-chrd-nts)))
 #{ \tweak #'color #color #first-nh #})
   mus)
mus)
  mus))
music)) % default #first #last is the top notehead 
%
 boo =
#(define-music-function
  (parser location color the-music)
  (color? ly:music?)
#{
  \temporary \override NoteHead.color = #color
 
  #the-music
  \revert NoteHead.color
  
#})%\boo#blue {..}

SA = {d''4. d''8 d''8  8 8 f'8 |%m73
  <<{\voiceOne a'2 a'4 f'8 e'8}\new Voice{\voiceTwo \boo#red {c'4 d'4 f'4 f'4} }>> \oneVoice |%m74
  d'4. 8 8 8 q4 |%m75
}

verseA = \lyricmode {
  re re re mi re fa la la fa mi re so so so re  
}


<<
\new Staff \with { \xup

  } <<
\new Voice = "soprano"  { \voiceOne \clors #first #red \SA }
  >>
  \new Lyrics 
\lyricsto "soprano" \verseA
>>

<<
\new Staff \with { \xdown

  } <<
\new Voice = "soprano"  { \voiceOne \clors #first #blue \SA }
  >>
  \new Lyrics 
\lyricsto "soprano" \verseA
>>

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


Re: voice solfege sequence

2014-04-19 Thread Thomas Morley
2014-04-19 23:25 GMT+02:00 MING TSANG :
> Hi, lilyponders:
> The attach .ly file show the sequencing of solfege above the staff behaves
> inconsistent.
> How can this be resolved?  I am also hoping it will be the same if it is
> sequencing below the staff. The color solfege will be showing on the lower
> stack in both case.
> Help is appreciated.
> Emmanuel,
> Ming



Hi Ming,

the solfege-engraver creates a new TextScript-grob, I think the
properties are (partly) taken from the NoteHead.
Meaning that color persists in some cases and, if the NoteHeads part
of a chord, two TextSript-grobs are created with the same
outside-staff-priority. How they are printed is more or less
unpredictable.

Below I try to assign each Textscript a different
outside-staff-priority according to the staff-position of the
NoteHead.
I found no convincing method to set the color for the TextScript, though.
I used a workaround, hoping someone else comes up with a better solution.

#(define (solfege-engraver lst dir)
   (make-engraver
 (acknowledgers
  ((note-head-interface engraver grob source)
   (let* (
  (context (ly:translator-context engraver))
  (tonic-pitch (ly:context-property context 'tonic))
  (tonic-index (ly:pitch-notename tonic-pitch))
  (event (ly:grob-property grob 'cause))
  (grob-pitch (ly:event-property event 'pitch))
  (grob-index (ly:pitch-notename grob-pitch))
  (delta (modulo (- grob-index tonic-index) 7))
  (name (list-ref lst delta))
  (newgrob (ly:engraver-make-grob engraver 'TextScript event)))

 (if (string= name "Hb")  (set! name "B"))
 ;; Give newgrob 'outside-staff-priority depending on
 ;; grob 'staff-position
 (set! (ly:grob-property newgrob 'outside-staff-priority)
   (+ (ly:grob-property newgrob 'outside-staff-priority)
  (* dir (ly:grob-property grob 'staff-position
 (set! (ly:grob-property newgrob 'text)
   ;; Ugh, color is taken from grob in some cases.
   ;; How to clear for newgrob?
   ;; workaround:
   (markup #:with-color black name))
 (set! (ly:grob-property newgrob 'direction) dir) )

HTH,
  Harm

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