Changing the underline color of a text tag



I am trying to figure out how to change the color of an underline in a
Gtk::TextTag.  I'm writing this in Ruby, and on the Ruby/Gtk+ website I
saw the Pango::AttrUnderlineColor, but I've no idea how to apply this
anywhere.  When defining a tag, I typically use the create tag function
on a TextBuffer.

tag = tbuffer.create_tag(nil,
{'underline'=>Pango::AttrUnderline::SINGLE})
tbuffer.apply_tag(tag, tbuffer.get_iter_at_mark(bmark),
tbuffer.get_iter_at_mark(emark))

I've tried changing the color by using the key 'underline-color',
'underline color' or 'underlinecolor', none of which work, and I'm not
sure where one would use the Pango::AttrUnderlineColor class.




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]