Re: Entering Chords using Nashville Number System

2022-01-13 Thread Tim's Bitstream
There was a thread earlier this year on that very topic:

https://mail.gnu.org/archive/html/lilypond-user/2021-06/msg00023.html




> On Jan 13, 2022, at 8:48 PM, Sam Gibson  wrote:
> 
> 
> Good day.
> 
> I wish to use the Nashville Number System, using numbers in place of chord 
> names, for a simple lead sheet or chord chart. While it is possible to simply 
> enter and position chords using \lyricmode, I do not know of a way to include 
> the superscripts such as maj7 or sus4. Is there a way to use '\chords' and 
> replace the letter chord names with numbers?
> 
> I am entering chords in the following way:
> 
> \version "2.22.1"
> \chords { c1 f:sus4 }
> 
> I appreciate any assistance.
> 
> Samuel Gibson


Entering Chords using Nashville Number System

2022-01-13 Thread Sam Gibson
Good day.

I wish to use the Nashville Number System, using numbers in place of chord
names, for a simple lead sheet or chord chart. While it is possible to
simply enter and position chords using \lyricmode, I do not know of a way
to include the superscripts such as maj7 or sus4. Is there a way to use
'\chords' and replace the letter chord names with numbers?

I am entering chords in the following way:

\version "2.22.1"
\chords { c1 f:sus4 }

I appreciate any assistance.

Samuel Gibson


Display Question Mark at center of a measure

2022-01-13 Thread Rajesh Baskar

Hi,

I'm tying to display a question mark at the center of the 1st measure in 
a 2 measure score.


I have got this working with hard-coding the offset (3 . 4.5) but this 
will not work when the number of notes in a measure is larger than 3. Is 
there a way to get this to work dynamically where the question mark 
moves to the center of the measure irrespective of the length of a measure.


Thanks for all the help.
Dav.


\version "2.22.0"
boxify =
#(define-music-function
  (grob-path) (key-list?)
  (define proc (grob-transformer 'stencil
   (lambda (grob orig) (grob-interpret-markup grob #{
    \markup \override #'(box-padding . 1.25)
    \override #'(thickness . 1)
    \box \stencil #orig #}
  #{ \override $grob-path . stencil = #proc #})

\include "english.ly" \header {tagline = "" }
\score {\new Staff {
  \override Score.SpacingSpanner.strict-note-spacing = ##t
  \set Score.proportionalNotationDuration = #(ly:make-moment 1/4)
  \set Staff.midiInstrument = #"Acoustic Grand Piano"
  \key c \major \numericTimeSignature
  \time 4/4
  \clef bass
  \override TextScript.font-size = #7
 -\markup {\with-color "#6A00F4" "?" }
  \override TextScript.extra-offset = #'(3 . 4.5)

  \override Staff.MeasureCounter.staff-padding = #4.5
  \startMeasureCount
  \hideNotes b2 c
  \unHideNotes a c'4 g
   \stopMeasureCount
  \bar "||"}
    \layout {
  \context {
 \Staff
 \consists Measure_counter_engraver
 \boxify MeasureCounter
    }
    }
    \midi { \tempo 4 =92}
}




Re: Lilypond's English Horn MIDI instrument is non-transposing?

2022-01-13 Thread H. S. Teoh
On Thu, Jan 13, 2022 at 04:40:17PM -0500, James B. Wilkinson wrote:
[...]
> If I make it with the English horn part correctly transposed, the MIDI
> sounds terrible. If I make it with the English horn part untransposed,
> it sounds fine. My conclusion is that the midiInstrument "english
> horn" reads its part in C rather than in F. Shouldn't it play the
> notes that a real English horn would?
[...]

Lilypond actually doesn't know what an "english horn" is. As far as it's
concerned, that's just an arbitrary name for a particular program number
in the General Midi standard.  It does not assign any meaning to the
name beyond mapping it to that program number.[*]

To get the right transposition, you need to use the \transposition
directive (see the documentation for details) to tell Lilypond how the
pitches are supposed to be interpreted.


[*] In fact, I've used Lilypond to make MIDI performances of orchestras
with instruments that don't exist in the General Midi standard -- by
remapping program numbers to custom assignments. Lilypond is completely
unaware of this, however, and still expects General Midi names for
instruments. So what Lilypond thinks is an "english horn" in my score
could be, for example, a bass clarinet or Wagner horn in the final
output.  The identifier "english horn" is just a stand-in for midi
program #70.  How that program is actually rendered is not controlled by
Lilypond, but by the midi player (and how you configured it) downstream.


T

-- 
Heads I win, tails you lose.



Re: Lilypond's English Horn MIDI instrument is non-transposing?

2022-01-13 Thread David Kastrup
"James B. Wilkinson"  writes:

> I'm working on an arrangement fordable-reed quartet. Here's the score block:
>
> \score
> {
>   \new StaffGroup
><<
>  \new Staff = "oboe1" \with { instrumentName = "oboe1" midiInstrument = 
> "oboe" }
>{ \clef "treble" \soprano }
>  \new Staff = "oboe2" \with { instrumentName = "oboe2" midiInstrument = 
> "oboe" }
>{ \clef "treble" \alto }
>  \new Staff = "EngHrn" \with { instrumentName = "enghrn" midiInstrument = 
> "english horn" }   %"english horn"
>{ \clef "treble" \transpose f c \tenor }   %the correct 
> transposition for EH sounds terrible
> %   { \clef "treble" \transpose c c, \tenor }  % temporarily down one 
> octave; sounds fine
>  \new Staff = "bassoon" \with { instrumentName = "bassoon" midiInstrument 
> = "bassoon" }
>{ \clef "bass" \bass }
>>>
>   \layout { \context { \Staff \consists "Ambitus_engraver" } }  
>   \midi {  \tempo 4 = 80   }
> }
>
>
> If I make it with the English horn part correctly transposed, the MIDI
> sounds terrible. If I make it with the English horn part untransposed,
> it sounds fine. My conclusion is that the midiInstrument "english
> horn" reads its part in C rather than in F. Shouldn't it play the
> notes that a real English horn would?




Instrument transpositions
.

When typesetting scores that involve transposing instruments, some parts
can be typeset in a different pitch than the concert pitch.  In these
cases, the key of the transposing instrument should be specified;
otherwise the MIDI output and cues in other parts will produce incorrect
pitches.  For more information about quotations, see *note Quoting other
voices::.

 \transposition PITCH

   The pitch to use for ‘\transposition’ should correspond to the real
sound heard when a ‘c'’ written on the staff is played by the
transposing instrument.  This pitch is entered in absolute mode, so an
instrument that produces a real sound which is one tone higher than the
printed music should use ‘\transposition d'’.  ‘\transposition’ should
_only_ be used if the pitches are _not_ being entered in concert pitch.

   Here are a few notes for violin and B-flat clarinet where the parts
have been entered using the notes and key as they appear in each part of
the conductor’s score.  The two instruments are playing in unison.

 \new GrandStaff <<
   \new Staff = "violin" \with {
 instrumentName = "Vln"
 midiInstrument = "violin"
   }
   \relative c'' {
 % not strictly necessary, but a good reminder
 \transposition c'
 \key c \major
 g4( c8) r c r c4
   }
   \new Staff = "clarinet" \with {
 instrumentName = \markup { Cl (B\flat) }
 midiInstrument = "clarinet"
   }
   \relative c'' {
 \transposition bes
 \key d \major
 a4( d8) r d r d4
   }
 >>

-- 
David Kastrup



Lilypond's English Horn MIDI instrument is non-transposing?

2022-01-13 Thread James B. Wilkinson
I'm working on an arrangement fordable-reed quartet. Here's the score block:

\score
{
  \new StaffGroup
   <<
 \new Staff = "oboe1" \with { instrumentName = "oboe1" midiInstrument = 
"oboe" }
   { \clef "treble" \soprano }
 \new Staff = "oboe2" \with { instrumentName = "oboe2" midiInstrument = 
"oboe" }
   { \clef "treble" \alto }
 \new Staff = "EngHrn" \with { instrumentName = "enghrn" midiInstrument = 
"english horn" }   %"english horn"
   { \clef "treble" \transpose f c \tenor }   %the correct 
transposition for EH sounds terrible
%   { \clef "treble" \transpose c c, \tenor }  % temporarily down one 
octave; sounds fine
 \new Staff = "bassoon" \with { instrumentName = "bassoon" midiInstrument = 
"bassoon" }
   { \clef "bass" \bass }
   >>
  \layout { \context { \Staff \consists "Ambitus_engraver" } }  
  \midi {  \tempo 4 = 80   }
}


If I make it with the English horn part correctly transposed, the MIDI sounds 
terrible. If I make it with the English horn part untransposed, it sounds fine. 
My conclusion is that the midiInstrument "english horn" reads its part in C 
rather than in F. Shouldn't it play the notes that a real English horn would?


thanks


Re: Transposing pitches in the lilypond file itself?

2022-01-13 Thread David Kastrup
Alasdair McAndrew  writes:

>> On Thursday 13 January 2022 01:02:17 (+11:00), David Kastrup wrote:
>>
>>> Emacs' LilyPond-mode is an abomination in desperate need of
>>> maintenance or possibly rewriting from scratch. There is no reason
>>> to use it unless you are one of those people who use Emacs for
>>> everything (in contrast, the mail/news client I am writing this in
>>> would be a reason to switch to Emacs rather than vice versa. As are
>>> the LaTeX modes). However, it probably has the only useable MIDI
>>> pitch recognition for polyphonic entry like those of accordions.
>>>
>>> If I needed to batch-convert some input regarding relative/absolute
>>> or transpose, I'd likely start up Frescobaldi. Never mind that it
>>> isn't the one editor to bring them all and in the darkness bind
>>> them.
>
> Thanks, David - for the heads up about Emacs Lilypond mode!  I don't
> use Emacs for everything, but I do use it for a lot of things; and
> certainly for anything involving text (like Lilypond) it's my standard
> go-to.  But what is it about the Lilypond mode which is so abominable?

It has comparatively fragile indentation that gets thrown off for
indiscernible reasons, it does not indent Scheme fragments well, it does
not allow for more than a single process under its control (which
frequently kills its viewer since it does not start it in the
background), it cannot do any manipulation interpreting pitches or
lengths (transposing, augmenting, relative/absolute conversion), it
doesn't offer support for writing mixed LaTeX/LilyPond stuff (like
lilypond-book), it does not offer contextual help even if you have the
Info files installed (which nevertheless beat the HTML docs hollow in
terms of usability).

> I just use it really for note-entering, and for each new piece I start
> off with one of my templates.  The font-lock minor mode (coloring) is
> very helpful. (Also, I'm curious - which Emacs mail system are you
> using?  I've tried several, but none of them really appealed to me.

Gnus.
 
> I'm now using the inbuilt mail system which is part of the Vivaldi
> browser.  I also agree about LaTeX: I've installed Emacs on my Windows
> machine as well because Emacs+auctex works for me better than any
> other editor or LaTeX IDE.)

Particularly when using preview-latex...

-- 
David Kastrup



Re: Transposing pitches in the lilypond file itself?

2022-01-13 Thread ebenezer

This made me smile - a lot. Thank you.


On 2022-01-12 14:02, David Kastrup wrote:


Emacs' LilyPond-mode is an abomination in desperate need of maintenance
or possibly rewriting from scratch.  There is no reason to use it unless
you are one of those people who use Emacs for everything (in contrast,
the mail/news client I am writing this in would be a reason to switch to
Emacs rather than vice versa.  As are the LaTeX modes).  However, it
probably has the only useable MIDI pitch recognition for polyphonic
entry like those of accordions.

If I needed to batch-convert some input regarding relative/absolute or
transpose, I'd likely start up Frescobaldi.  Never mind that it isn't
the one editor to bring them all and in the darkness bind them.