Re: How to change color of Gtk::RadioButton's label?



Sorry Marco,

Your code doesn't work;  it compiles, but I end up with a check button
that has no label at all, unless I create one in the CheckButton
constructor itself.    Then, that label has not got the background color
specified in the set_markup string.

I have been trying to get a Pango::Layout for a checkbutton, and the
code to get it seems to compile and run, but the attribute list returned
by the layout is NULL, hence my change to the background color attribute
is fruitless.  A call to modify_bg for the checkbutton widget merely
changes the frame color of the check box itself.  The label remains
unfazed.  Can anyone point me to a URL that has a good Pango tutorial? 
Maybe I can dig through that and finally come up with an answer to
Volosatov's original question.

Bob

Marco Scholten wrote:

> ----- Original Message ----- From: "Volosatov Alexander"
> <rope-walker yandex ru>
> To: <gtkmm-list gnome org>
> Sent: Monday, December 19, 2005 2:07 PM
> Subject: Re: How to change color of Gtk::RadioButton's label?
>
>
>> As I understand nobody know how to do this?
>> Attach screenshot of my idea.
>> Maybe someone find answer?
>
>
> something like this:
>   Gtk::CheckButton check;
>   Gtk::Label* l=Gtk::manage(new Gtk::Label);
>   l->set_markup("<span color = \"blue\"> blue text </span>");
>   check.add(*l);
>
> -- 
> Marco
> _______________________________________________
> gtkmm-list mailing list
> gtkmm-list gnome org
> http://mail.gnome.org/mailman/listinfo/gtkmm-list
>



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