the width of an entry



Hi,

I tried to create a entry with the width of n chars.
My first idea was to do this:

(gtk-widget-set-usize entry
		      (gdk-string-width (gtk-style-get-font (gtk-widget-get-style (gtk-entry-new)))
					"M")
		      0)

But that sets the outer width to the width of the char.
How can I set the inner width?
Best would be to have two functions like:

gtk_entry_set_width_from_string(entry, "a string");
gtk_entry_set_width_from_chars(entry, 4, "0"); 

-- http://www.ping.de/sites/aibon/



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