Adding notes/chords to songs and variations

This is a description how I created a text label/short note for a song/variation and a multi line chords label/widget.

An example is added to the song (variations) Basket Case and Blauw:

To do this, perform the following steps:

In the Edit Panel page, create a Tape Label, and assign the OSC/GPScript name to ReadmeWidget:

Change the font sizes to the maximum text you will use.

Do the same for the multi line Text Label for chords (and name it ChordsWidget):

Then set the script (ctrl-shift-1) to

Var
   ReadmeWidget : Widget
   ChordsWidget : Widget
   
function Set(readmeText : String, chordsText : String)
   SetWidgetLabel(ReadmeWidget, readmeText)
   SetWidgetLabel(ChordsWidget, chordsText)
end


function SetVariationSpecificItems()
   var name : String = GetVariationName(GetCurrentVariation())
   select
      name == "Blauw - The Scene" do
         Set("Start immediately", 
             <<<
INTRO   G   Csus4   G   G     
VERSE = Intro    G   Am7   Bm7   C6
CHORUS   Am   Csus4   G   G   (Am)
OUTTRO    (+El.Piano)  F/A   C/E   G   G
             >>>)


      name == "Basket Case - Greenday" do
         Set("Start at >",
             <<<
VERSE: Eb  Bb  Cm  Gm   Ab  Eb  Bb  Bb 2x 
CHORUS: Ab  Bb  Eb  Eb  2x  A  B 
> Eb_Db  Cm  Ab  Bb    INTERLUDE:  Eb   Bb   Cm   Bb 2x     
Verse    Chorus   Interlude  2x      BRIDGE:   Ab   Bb  NC  
Inst: Verse  Chorus  OUTTRO: Eb  Cm  Ab_Eb  Bb  4x   Ab   Eb    Bb
             >>>)
 
      true do
         Set("", "")
   end
end

on Activate
   SetVariationSpecificItems()
end

on Deactivate
   Set("", "")
end

on Variation(oldVaration : Integer, newVariation : Integer)
  SetVariationSpecificItems()
end

Make sure to use the correct variation names otherwise the widgets will be empty (as the True select statement will be used).

I use the same method for songs (without variations), except the Tape Label read me widget does not need to be automated, and the script for the chords widget is reduced to

Var
  ChordsWidget : Widget
  ChordsText: String = <<<
INTRO: C#m  C#m  E  F#     VERSE: ...
CHORUS1:  A   (B)   C#m   G#m  (G3m)   B 2x    BRIDGE: c#  d#  e  f#  g#
Verse  = bridge     Chorus2   Chorus2:    A   B   C#m   (E)   G#m   (G#m)   B 2x
'Keep':  E   E   B   C#m  8x    Chorus1    Chorus2  
OUTTRO:   A   C#m   G#m   Bsus2   4x   C#
>>>

initialization
  SetWidgetLabel(ChordsWidget, ChordsText)
End

The only disadvantage is that after changing the script and compiling, you need to move away from the song/alternative and return to see the updated text again.
If someone knows a solution for this, I would like to hear.