fg_color and bg_color not set in gtk_text_iter_get_attributes
- Date: Sun, 04 Sep 2016 21:21:34 -0700
- From: Timothy Johnson <timothy@xxxxxxxxxxxxxx>
- Subject: fg_color and bg_color not set in gtk_text_iter_get_attributes
I'm attempting to get the foreground and background color of text at an GtkTextIter using the gtk_text_get_attributes function, but it doesn't seem to set the appearance field. For example, the code below prints "#9393a1a1a1a1 #000000000000" (The default colors) when the text is rendered red. Note: Example code is in vala, but it's should be the same in C.
buffer.get_iter_at_line(out iter, 0);
var attrs = text_view.get_default_attributes();
message("%s %s", attrs.appearance.fg_color.to_string(), attrs.appearance.bg_color.to_string());
Other properties such as weight and style are set correctly, it seems to be just the appearance field that is ignored. Any idea what is going on?
_______________________________________________ gtk-list mailing list gtk-list@xxxxxxxxx https://mail.gnome.org/mailman/listinfo/gtk-list
- Prev by Date: Versioning and long term stability promise in GTK+
- Next by Date: Sore eyes
- Previous by thread: Versioning and long term stability promise in GTK+
- Next by thread: Sore eyes