[Gtk-sharp-list] How do I control the text appearance of a Gtk.Entry widget ?

Walter Kempf gtk-sharp at indicium.za.net
Thu Mar 13 15:23:53 EDT 2008


Hi,

In my experience I find RC files much easier to work with. Not to
mention no compilation needed while debugging/getting it just right.

<code>
Gtk.Rc.Parse("rcfile.gtkrc");
Gtk.Rc.ResetStyles( Gtk.Settings.GetForScreen(Gdk.Screen.Default) );
</code>

Now if only I could find a complete reference for RC files. :/


Brad Langhorst wrote:
> On Sun, 2008-03-09 at 09:10 +0100, Jesper K. Pedersen wrote:
>
>   
>> I did also manage after several hours of trial and error figure out
>> that it is somewhat cumbersome changing size of the displayed font in
>> the entry.
>>
>> <-- excerpt from my code -->
>> Gtk.Style entstyle = entry_winWoDetail_wo.Style;
>>
>> entstyle.FontDescription.Size = (int) ( entstyle.FontDescription.Size *
>>                                         Pango.Scale.Large );
>> entry_winWoDetail_wo.ModifyFont(entstyle.FontDescription);
>> entry_winWoDetail_ac.ModifyFont(entstyle.FontDescription);
>> entry_winWoDetail_description.ModifyFont(entstyle.FontDescription);
>> entry_winWoDetail_opened.ModifyFont(entstyle.FontDescription);
>>     
>
> I understand what you mean by trial and error, I've been experiencing
> that myself.  I'm glad to hear that I'm not the only one who finds Gtk
> un-intuitive... it is getting better for me now.
>
> Keep in mind that you can also use the "usemarkup" feature on some
> controls for a bit of text formatting, but only for non-dynamic stuff I
> think (not gtkEntry)
>
>
> I've found that looking at other applications is helpful. Especially I
> use the demo apps and the f-spot (the photo editor).
>
> best wishes!
>
> brad
>
>
>
>
>
>
> _______________________________________________
> Gtk-sharp-list maillist  -  Gtk-sharp-list at lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/gtk-sharp-list
>
>
>   


More information about the Gtk-sharp-list mailing list