Le 08/04/2022 à 19:12, Riad Abdel-Gawad a écrit :
Hello Lilypond Users,
It's great to be reading the community posts because I've learned a lot.
I wish to insert a semi-flat: it's the flat with a slash through it. I
have used \include "arabic.ly <http://arabic.ly>" and \include
"het-arabic.ly <http://het-arabic.ly>" for other files that have
[Arabic] maqam key signatures. But I wish to insert the semi-flat as
accidentals when the maqam modulates but keeps the "g minor" key
signature.
I did read the Notation.pdf which explains \dwn as a workaround for
inserting semi-flats. I'm not sure if it's because I've set the
instruments under a \global command (see all caps file for context
[code]).
I keep getting error messages and no result: I cannot seem to be able
to code the last two "ef" eighth notes (in the violin part) -- at the
very end of the example below (and attached)-- to "edb"s, (which would
make it semi-flat under the "het-arabic.ly <http://het-arabic.ly>"
command).
violin = \relative c''{
\global
% Music follows here.
d1~ d4 c8 d8 ef8 d8 c8 ef8
fs1 ~ fs4 a,8 bf c bf a c bf1~ bf4 fs8 g a g fs8 af |
g'f ef f ef d ef }
Please accept my highest respectful regards,
Riad Abdel-Gawad
If I have understood your request correctly, you could go for the
not-so-clean but functional:
\version "2.22.1"
\language "english"
\header {
title = "Quintet"
subtitle = "for Sout"
subsubtitle = "for Samir Bendimered and Jan Rzewski"
instrument = "soprano saxophone, percussion, piano, violin, contrabass"
composer = "Riad Abdel-Gawad"
copyright = "2022"
}
\layout {
\context {
\Score
\override Accidental.stencil =
#(lambda (grob)
(let ((alteration (ly:grob-property grob 'alteration)))
(if (eqv? alteration -1/4)
(begin
(ly:grob-set-property! grob 'restore-first #f)
(ly:stencil-add
(ly:accidental-interface::print grob)
(ly:line-interface::line grob -0.18 0.7 1.3 1.65)))
(ly:accidental-interface::print grob))))
}
}
global = {
\key g \minor
\time 8/4
\tempo 4=100
}
sopranoSax = \relative c'' {
\global
% Music follows here.
}
drum = \drummode {
\global
% Drums follow here.
}
right = \relative c' {
\global
% Music follows here.
}
left = \relative c' {
\global
% Music follows here.
}
violin = \relative c''{
\global
% Music follows here.
d1~ d4 c8 d8 ef8 d8 c8 ef8
fs1 ~ fs4 a,8 bf c bf a c bf1~ bf4 fs8 g a g fs8 af |
g'f ef f eqf d eqf }
contrabass = \relative c {
\global
% Music follows here.
}
sopranoSaxPart = \new Staff \with {
instrumentName = "Soprano Sax"
shortInstrumentName = "S. Sax"
midiInstrument = "soprano sax"
} \sopranoSax
drumsPart = \new DrumStaff \with {
\consists "Instrument_name_engraver"
instrumentName = "Drums"
shortInstrumentName = "Dr."
} \drum
pianoPart = \new PianoStaff \with {
instrumentName = "Piano"
shortInstrumentName = "P-no"
} <<
\new Staff = "right" \with {
midiInstrument = "acoustic grand"
} \right
\new Staff = "left" \with {
midiInstrument = "acoustic grand"
} { \clef bass \left }
>>
violinPart = \new Staff \with {
instrumentName = "Violin"
shortInstrumentName = "Vln."
midiInstrument = "violin"
} \violin
contrabassPart = \new Staff \with {
instrumentName = "Contrabass"
shortInstrumentName = "Contrabass"
midiInstrument = "contrabass"
} { \clef bass \contrabass }
\score {
<<
\sopranoSaxPart
\drumsPart
\pianoPart
\violinPart
\contrabassPart
>>
\layout { }
\midi { }
}
Best,
Jean