Re: GtkTextView Vs GtkText



22 feb 2008 kl. 11.28 skrev Dharmosoth Seetharam:

Hi,

I can't really comment on why something work in one but not the other. However, you can disregard GtkText as that widget has long been deprecated and should not be used in new code and all code using it should be ported to GtkTextView.

Cheers,
  Mikael Hallendal

Hi,

I am little aware of these two widget. But got struck
at setting font and setting style to GtkText.

1)
I understand how to set font to the GtkTextView
 [  PangoFontDescription *font_desc;
    font_desc = pango_font_description_from_string
                      ("Courier,Medium 12");
    gtk_widget_modify_font (textview, font_desc);
    pango_font_description_free (font_desc);
 ]

But, the same is not working for GtkText.


2)

 Applying style to GtkTextView is
 [  rc_style = gtk_rc_style_new ();
    rc_style->bg_pixmap_name[GTK_STATE_NORMAL] =
                           gx.bg_pixmap_filename;
    gtk_widget_modify_style (textview, rc_style);
  ]

This one is working for GtkText and Not working for
GtkTextView.


Can anybody please help to understand why it working
for one widget and *not working for another widget* ?

thanks in advannce

RAM



     Explore your hobbies and interests. Go to http://in.promos.yahoo.com/groups

_______________________________________________
gtk-app-devel-list mailing list
gtk-app-devel-list gnome org
http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list



--
Imendio AB, http://www.imendio.com






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