gabc gregoriocolor red notes?
  • probe
    Posts: 175
    Is it possible in gabc to colour the square notes rather than text red?
    fa <c>(f)</c> has no effect
    It might be a way in solfege teaching materials to highlight which notes are a half tone up or down from the previous note.
  • chonakchonak
    Posts: 9,283
    There is a way, but it requires hideous gabc coding with some low-level GregorioTeX macros inserted:

    %%
    (f3)DO(h)mi(h)n{e},(g[nv:\color{gregoriocolor}\GreGlyph{}{9}{\GreNextCustos{10}{}}{0}{}{}{}\color{black}])
    in(h) cæ(fe)lo(g)
    image

    And I don't claim to understand it, really.
    color-demo.jpg
    466 x 135 - 9K
    Thanked by 1probe
  • MatthewRoth
    Posts: 3,633
    It would be easier to make the semitone a punctum cavum and give the score a caption if necessary.
    Thanked by 1probe
  • joerg
    Posts: 144
    A hack like this would work:

    initial-style: 1;
    annotation: {\gdef\red{\pdfextension literal{1 0 0 rg}}\gdef\black{\pdfextension literal{0 0 0 rg}}};
    %%
    (c4) <v>\ </v>do(c) re(d) me(e) <v>{\red}</v>fa(f)<v>{\black}</v> so(g) la(h) ti(i) do(j)


    If you want just the note in red but not the text, the code would look like this:

    (c4) <v>\ </v>do(c) re(d) me(e) fa(f[nv:{\red}])<v>{\black}</v> so(g) la(h) ti(i) do(j)
    Thanked by 1probe
  • probe
    Posts: 175
    Thanks MatthewRoth, as I understand it that hollow shape is already used to mean a drone or tenor or chant tone held over more than one word so I don't want to give the learners the wrong idea. Same for my first idea of a diamond note.
    chonak offers a solution I'd need to be brave to try, so I might leave it at coloured lyrics.
    I've just seen joerg - I'll try that.
    Thanks all!

  • MatthewRoth
    Posts: 3,633
    I mean things can have two meanings. It’s not that big of a deal. It’s also clear in context and to a novice it looks like a white note.
  • Charles_Weaver
    Posts: 238
    I have used the hollow note for similar things in mode handouts precisely because gabc is not set up well for this. Joerg's solution looks pretty good though.

    Can I ask about the spelling of the solfège syllables though? I'm curious why you chose to spell them this way.
  • probe
    Posts: 175
    @Charles_Weaver I see it now - English getting in the way of Italian. I'll correct 'me' to 'mi'. Thanks!
  • Richard MixRichard Mix
    Posts: 2,992
    Not what was originally requested, but a more historical approach that also reinforces the idea of clefs was to use colored staff lines. Is this supported?
  • probe
    Posts: 175
    Going on from there, and picking up on Matthew's suggestion for white notes, this is what I have. I notice that gregorio creates a smaller gap after the half steps, causing uneven spacing. Can that be expanded? I tried two slashes but now it's too wide and it adds an unwanted hyphen. (EDIT: screenshot the gabc)




    Scales and Modes.png
    1384 x 538 - 60K
    Screenshot 2026-06-11 164338.png
    1322 x 218 - 159K
  • MatthewRoth
    Posts: 3,633
    The hyphen is because of the space.
  • Charles_Weaver
    Posts: 238
    Yes, take out the spaces in your example that appear before opening brackets (except the ones before barlines).
  • probe
    Posts: 175
    Well, that puzzled me because I put in the spaces to get rid of hyphens I got at first.
    Here is the gabc now and the output from both gregoriochant and source&summit, still with unwanted hyphens and irregular spacing. Now with screenshot of gabc as I notice the simple html editor ignores the c tags


    Scales and Modes with red.png
    1428 x 652 - 73K
    Scales and Modes with red S+S.png
    1112 x 352 - 28K
    Screenshot 2026-06-11 164150.png
    1360 x 348 - 72K
  • probe
    Posts: 175
    If I take away the tags it looks as expected, so I may have to give up on the red text idea if that introduces those artifacts.


    %%
    (c4).
    do(c) re(d) mi(e) fa(fr) so(g) la(h) ti(i) do(jr) (;)
    do(j) ti(ir) la(h) so(g) fa(f) mi(er) re(d) do(c) (:)(z)
    do(c) re(d) mi(e) fa(fr) so(g) la(h) ta(ixir) do(j) (;)
    do(j) ta(ixir) la(h) so(g) fa(f) mi(er) re(d) do(c) (::)(zz)


    Scales and Modes black.png
    1486 x 553 - 40K
  • igneusigneus
    Posts: 450
    Try changing <c>mi(er)</c> to <c>mi</c>(er) (etc.)