[Gtk-sharp-list] Fonts in TreeView
Anyware Electronics
any at anyelec.com
Sun Apr 21 07:02:49 UTC 2013
Very useful, thank you!
Paolo
------- Messaggio originale -------
Da: Jeha <j-halverson at rr.em-net.ne.jp>
A: gtk-sharp-list at lists.ximian.com
Oggetto: Re: [Gtk-sharp-list] Fonts in TreeView
Data: Fri, 19 Apr 2013 18:59:24 -0700 (PDT)
Did you ever find out how to get your bold text in the header?
Here is how I do this in my application, by using a different "widget" in
header you can do just about anything:
TreeViewColumn Col0=new TreeViewColumn();
Pango.FontDescription titleFont =
BundleSelectionComboBox.Style.FontDescription;
titleFont.Size = (int)(9 * Pango.Scale.PangoScale);
Gtk.Label aLabel = new Gtk.Label ();
aLabel.Markup = "*" + Catalog.GetString("TITLE HEADER") + "*";
aLabel.UseMarkup = true;
aLabel.ModifyFont (titleFont);
aLabel.Show ();
Col0.Widget = aLabel;
Col0.Alignment = 1;
This does more than you need, but shows some of the things you can do to get
your headers to look just right for your purposes. I have strunk the font
down to 90% standard size, used markup to make it bold, aligned it, and used
getstring around the title itself to ensure you can allow for
multilingualization of your header titles.
Hope that helps.
Jeff
--
View this message in context: http://mono.1490590.n4.nabble.com/Fonts-in-TreeView-tp4659209p4659426.html
Sent from the Mono - Gtk# mailing list archive at Nabble.com.
_______________________________________________
Gtk-sharp-list maillist - Gtk-sharp-list at lists.ximian.com
http://lists.ximian.com/mailman/listinfo/gtk-sharp-list
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.ximian.com/pipermail/gtk-sharp-list/attachments/20130421/84c4699c/attachment.html>
More information about the Gtk-sharp-list
mailing list