Re: System in different colors

2012-04-11 Thread uunail


I tried \once \override but it didn't work.

As far as I understand the BarLine is a part of the staff context which
cannot be changed from one occurence to the other (that is why you have to
use the /startStaff and /stopStaff). And in my example it is changed for the
whole staff (or the three parts).

My problem however is, that the barline between my part 2 and three is
already shown in the color of the part 3 where I think it is defined and
belongs to part 2.

Regards

Uwe
-- 
View this message in context: 
http://old.nabble.com/System-in-different-colors-tp33660259p33668611.html
Sent from the Gnu - Lilypond - User mailing list archive at Nabble.com.


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


Re: System in different colors

2012-04-11 Thread David Nalesnik
Hi,

I tried \once \override but it didn't work.


It should.  You can also move the override of BarLine later as I do below.


 My problem however is, that the barline between my part 2 and three is
 already shown in the color of the part 3 where I think it is defined and
 belongs to part 2.


I believe the issue here is that the barline is considered to _begin_ the
new measure rather than end the old one.  I can't think of a way around
this except what James suggests.  (Then there's the issue of the staff
lines underneath the bar line, to which I don't have a ready answer.)

BTW, your bars don't all add up.

\version 2.14.2
#(set-global-staff-size 18.65)

\header {
   title = System in different colors
}

\language deutsch

staffVoice = \new Staff {
   \set Score.tempoHideNote = ##t
   \time 2/2
   \key f \major
   \clef treble
   \tempo 2=78
   \relative c' {
   \context Voice {
   \override Staff.Clef #'color = #red
   \override Staff.TimeSignature #'color = #red
   \override Staff.KeySignature #'color = #red
   \override NoteHead #'color = #red
   \override Staff.StaffSymbol #'color = #red
   \override Stem #'color = #red
   \override DynamicText #'color = #red
   \override Tie #'color = #red
   \override TextScript #'color = #red
   \override Staff.BarLine #'color = #red
   \override Staff.LedgerLineSpanner #'color = #red
   \partial 4*3
   d' b4^\markup{ \larger {Part 1}}_\f  c a
   f4
   \stopStaff
   }
   \context Voice = melodyVoi {
   \dynamicUp
%\partial 4*3
   \startStaff
   \revert Staff.Clef #'color
   \revert Staff.KeySignature #'color
   \revert Staff.BarLine #'color
   \revert Staff.LedgerLineSpanner #'color
   \revert Staff.StaffSymbol #'color
   \revert NoteHead #'color
   \revert Stem #'color
   \revert Tie #'color
   \revert DynamicText #'color
   c4\(_\mf h c\)
   \bar ||
   f c f c f c f c
   f c f c f c f c
   f c f c f c f c
   f c %% ?
   }
   \context Voice = melodyRep {
   f1 R1
   \bar |.
   \stopStaff
   }
   \context Voice = interlude {
   \startStaff
   \override Staff.VerticalAxisGroup #'remove-first = ##t
   \override SystemStartBar #'color = #black
   \override Staff.StaffSymbol #'color = #red
   \override NoteHead #'color = #red
   \override Stem #'color = #red
   \override DynamicText #'color = #red
   \override Tie #'color = #red
   \override TextScript #'color = #red
   \override Accidental #'color = #red
   \override Rest #'color = #red
   \override Staff.LedgerLineSpanner #'color = #red
   f4^\markup { \larger {Part 3 }} e f g
   \override Staff.BarLine #'color = #red %% I moved this
   c,4 r h f' g r
   \bar ||
   }
 }
}



\score {
   \staffVoice
   \layout {}
   }

\paper {}

Hope this helps,
David
___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: System in different colors

2012-04-11 Thread Thomas Morley
Am 11. April 2012 16:16 schrieb David Nalesnik david.nales...@gmail.com:

 I believe the issue here is that the barline is considered to _begin_ the
 new measure rather than end the old one.  I can't think of a way around this
 except what James suggests.  (Then there's the issue of the staff lines
 underneath the bar line, to which I don't have a ready answer.)

Hi David,

how about inserting: \override Staff.BarLine #'layer = #10 in the \layout and
\once \override Staff.BarLine #'X-extent = #'(-0 . 0.5) for the
problematic BarLine.

Think it should do the trick:

\version 2.14.2
#(set-global-staff-size 18.65)

\header {
   title = System in different colors
}

\language deutsch

staffVoice = \new Staff {
   \set Score.tempoHideNote = ##t
   \time 2/2
   \key f \major
   \clef treble
   \tempo 2=78
   \relative c' {
   \context Voice {
   \override Staff.Clef #'color = #red
   \override Staff.TimeSignature #'color = #red
   \override Staff.KeySignature #'color = #red
   \override NoteHead #'color = #red
   \override Staff.StaffSymbol #'color = #red
   \override Stem #'color = #red
   \override DynamicText #'color = #red
   \override Tie #'color = #red
   \override TextScript #'color = #red
   \override Staff.BarLine #'color = #red
   \override Staff.LedgerLineSpanner #'color = #red
   \partial 4*3
   d' b4^\markup{ \larger {Part 1}}_\f  c a
   f4
   \stopStaff
   }
   \context Voice = melodyVoi {
   \dynamicUp
%\partial 4*3
   \startStaff
   \revert Staff.Clef #'color
   \revert Staff.KeySignature #'color
   \revert Staff.BarLine #'color
   \revert Staff.LedgerLineSpanner #'color
   \revert Staff.StaffSymbol #'color
   \revert NoteHead #'color
   \revert Stem #'color
   \revert Tie #'color
   \revert DynamicText #'color
   c4\(_\mf h c\)
   \bar ||
   f c f c f c f c
   f c f c f c f c
   f c f c f c f c
   f c %% ?
   }
   \context Voice = melodyRep {
   f1 R1
   \bar |.
   \stopStaff
   }
   \context Voice = interlude {
   \startStaff
   \once \override Staff.BarLine #'X-extent = #'(-0 . 0.5) %% added
   \override Staff.VerticalAxisGroup #'remove-first = ##t
   \override SystemStartBar #'color = #black
   \override Staff.StaffSymbol #'color = #red
   \override NoteHead #'color = #red
   \override Stem #'color = #red
   \override DynamicText #'color = #red
   \override Tie #'color = #red
   \override TextScript #'color = #red
   \override Accidental #'color = #red
   \override Rest #'color = #red
   \override Staff.LedgerLineSpanner #'color = #red
   f4^\markup { \larger {Part 3 }} e f g
   \override Staff.BarLine #'color = #red %% I moved this
   c,4 r h f' g r
   \bar ||
   }
 }
}



\score {
   \staffVoice
   \layout {
%% added
   \context {
   \Staff
   \override BarLine #'layer = #10
   }
   }
}

\paper {}

Best,
  Harm

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


Re: System in different colors

2012-04-11 Thread -Eluze


David Nalesnik-2 wrote:
 
 Hi,
 
 I tried \once \override but it didn't work.

 
 It should.  You can also move the override of BarLine later as I do below.
 
 
 My problem however is, that the barline between my part 2 and three is
 already shown in the color of the part 3 where I think it is defined and
 belongs to part 2.


 I believe the issue here is that the barline is considered to _begin_ the
 new measure rather than end the old one.  I can't think of a way around
 this except what James suggests.  (Then there's the issue of the staff
 lines underneath the bar line, to which I don't have a ready answer.)
 
 

I don't think it's an issue.

it's a question of timing - both voices define a bar at the same time (part
3 the initial bar which usually is not displayed at the beginning of a
system) and its properties and - as usual - the latest wins.

Eluze
-- 
View this message in context: 
http://old.nabble.com/System-in-different-colors-tp33660259p33669429.html
Sent from the Gnu - Lilypond - User mailing list archive at Nabble.com.


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


Re: System in different colors

2012-04-11 Thread uunail

Thanks to everybody who replied.

I now learned that you can really change the color of each barline in the
score.

As I was defining the colors of the following part at the beginning, the
definition was taken directly from there on with the consequence of the
timing issue eluze described.

By moving the \override behind the first notes in the last part (as David
suggested), the override only worked for the then following barline which is
how I wanted it to be.

Thanks again
=)
Uwe
-- 
View this message in context: 
http://old.nabble.com/System-in-different-colors-tp33660259p33670406.html
Sent from the Gnu - Lilypond - User mailing list archive at Nabble.com.


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


Re: System in different colors

2012-04-11 Thread David Nalesnik
Hi Harm,


 how about inserting: \override Staff.BarLine #'layer = #10 in the \layout
 and
 \once \override Staff.BarLine #'X-extent = #'(-0 . 0.5) for the
 problematic BarLine.

 Think it should do the trick:


Aha!  Works beautifully.

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


Re: System in different colors

2012-04-11 Thread David Nalesnik
Hi Eluze,


  I believe the issue here is that the barline is considered to _begin_ the
  new measure rather than end the old one.  I can't think of a way around
  this except what James suggests.  (Then there's the issue of the staff
  lines underneath the bar line, to which I don't have a ready answer.)
 
 

 I don't think it's an issue.

 it's a question of timing - both voices define a bar at the same time (part
 3 the initial bar which usually is not displayed at the beginning of a
 system) and its properties and - as usual - the latest wins.


Yes, good point.  I didn't realize that \startStaff is actually creating a
new staff, in this case joined to the one before on the same line.

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


System in different colors

2012-04-10 Thread uunail

Hi everybody

Using this wonderful tool I again have a problem.

I want to use different colors in a piece to illustrate that they are played
by different people (and not using multiple systems).

The snippet below works almost fine with only one little thing that I want
to have changed:

\version 2.14.2
#(set-global-staff-size 18.65)

\header {
title = System in different colors 
}

\language deutsch

staffVoice = \new Staff {
\set Score.tempoHideNote = ##t
\time 2/2
\key f \major
\clef treble
\tempo 2=78
\relative c' {
\context Voice {
\override Staff.Clef #'color = #red
\override Staff.TimeSignature #'color = #red
\override Staff.KeySignature #'color = #red
\override NoteHead #'color = #red
\override Staff.StaffSymbol #'color = #red
\override Stem #'color = #red
\override DynamicText #'color = #red
\override Tie #'color = #red
\override TextScript #'color = #red
\override Staff.BarLine #'color = #red
\override Staff.LedgerLineSpanner #'color = #red
\partial 4*3
d' b4^\markup{ \larger {Part 1}}_\f  c a 
f4
\stopStaff
}
\context Voice = melodyVoi {
\dynamicUp
%\partial 4*3
\startStaff 
\revert Staff.Clef #'color
\revert Staff.KeySignature #'color
\revert Staff.BarLine #'color
\revert Staff.LedgerLineSpanner #'color
\revert Staff.StaffSymbol #'color
\revert NoteHead #'color
\revert Stem #'color
\revert Tie #'color
\revert DynamicText #'color
c4\(_\mf h c\)
\bar ||
f c f c f c f c
f c f c f c f c
f c f c f c f c
}
\context Voice = melodyRep {
f1 R1
\bar |. 
\stopStaff
}
\context Voice = interlude {
\startStaff
\override Staff.VerticalAxisGroup #'remove-first = ##t
\override SystemStartBar #'color = #black
\override Staff.StaffSymbol #'color = #red
\override NoteHead #'color = #red
\override Stem #'color = #red
\override DynamicText #'color = #red
\override Tie #'color = #red
\override TextScript #'color = #red
\override Accidental #'color = #red
\override Rest #'color = #red
\override Staff.BarLine #'color = #red
\override Staff.LedgerLineSpanner #'color = #red
f4^\markup { \larger {Part 3 }} e f g
c,4 r h f' g r
\bar ||
}
  }
}



\score {
\staffVoice
\layout {}
}

\paper {}

The double bar in front of part 3 is printed in red but I want to have it in
black as it belongs to part 2.

So the color change obviously works fine within a bar (as in bar 2). However
when the color change is done on a bar the behaviour is different and not
the way I want it to be.

Can someone help me.

Best regards

Uwe


-- 
View this message in context: 
http://old.nabble.com/System-in-different-colors-tp33660259p33660259.html
Sent from the Gnu - Lilypond - User mailing list archive at Nabble.com.


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


Re: System in different colors

2012-04-10 Thread James
Hello,

On 10 April 2012 10:41, uunail uwena...@kabelmail.de wrote:

 Hi everybody

 Using this wonderful tool I again have a problem.

 I want to use different colors in a piece to illustrate that they are played
 by different people (and not using multiple systems).

 The snippet below works almost fine with only one little thing that I want
 to have changed:

 \version 2.14.2
 #(set-global-staff-size 18.65)

 \header {
        title = System in different colors
 }

 \language deutsch

 staffVoice = \new Staff {
        \set Score.tempoHideNote = ##t
        \time 2/2
        \key f \major
        \clef treble
        \tempo 2=78
        \relative c' {
        \context Voice {
                \override Staff.Clef #'color = #red
                \override Staff.TimeSignature #'color = #red
                \override Staff.KeySignature #'color = #red
                \override NoteHead #'color = #red
                \override Staff.StaffSymbol #'color = #red
                \override Stem #'color = #red
                \override DynamicText #'color = #red
                \override Tie #'color = #red
                \override TextScript #'color = #red
                \override Staff.BarLine #'color = #red
                \override Staff.LedgerLineSpanner #'color = #red
                \partial 4*3
                d' b4^\markup{ \larger {Part 1}}_\f  c a
                f4
                \stopStaff
        }
        \context Voice = melodyVoi {
            \dynamicUp
 %            \partial 4*3
            \startStaff
            \revert Staff.Clef #'color
            \revert Staff.KeySignature #'color
            \revert Staff.BarLine #'color
            \revert Staff.LedgerLineSpanner #'color
            \revert Staff.StaffSymbol #'color
            \revert NoteHead #'color
            \revert Stem #'color
            \revert Tie #'color
            \revert DynamicText #'color
            c4\(_\mf h c\)
            \bar ||
            f c f c f c f c
            f c f c f c f c
            f c f c f c f c
        }
        \context Voice = melodyRep {
            f1 R1
            \bar |.
            \stopStaff
        }
        \context Voice = interlude {
                \startStaff
                \override Staff.VerticalAxisGroup #'remove-first = ##t
                \override SystemStartBar #'color = #black
                \override Staff.StaffSymbol #'color = #red
                \override NoteHead #'color = #red
                \override Stem #'color = #red
                \override DynamicText #'color = #red
                \override Tie #'color = #red
                \override TextScript #'color = #red
                \override Accidental #'color = #red
                \override Rest #'color = #red
                \override Staff.BarLine #'color = #red
                \override Staff.LedgerLineSpanner #'color = #red
                f4^\markup { \larger {Part 3 }} e f g
                c,4 r h f' g r
                \bar ||
        }
  }
 }



 \score {
        \staffVoice
        \layout {}
        }

 \paper {}

 The double bar in front of part 3 is printed in red but I want to have it in
 black as it belongs to part 2.

Can't you just use \once \override and then pick the colour you want?

James

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