[9477] in The GTK GIMP ToolKit mailing list archive

home help back first fref pref prev next nref lref last post

[gtk-list] gtk_text problems...

daemon@ATHENA.MIT.EDU (Scott Stone)
Thu Oct 22 02:39:06 1998

Date: Thu, 22 Oct 1998 15:39:04 +0900 (JST)
From: Scott Stone <sstone@ume.pht.co.jp>
To: GTK List <gtk-list@redhat.com>
Resent-From: gtk-list@redhat.com
Reply-To: gtk-list@redhat.com


OK, I have a gtk_text widget, into which I'm loading data.  However, no
matter what I do, when it shows up it's always displaying the very LAST
page of the contents (ie, the scrollbar's all the way at the bottom).  I
want it to start at the top.  How?  gtk_text_set_point is completely
ignored, it seems.. basically, I'm doing things in this order:

gtk_text_new
gtk_text_set_editable (TRUE)
gtk_text_set_word_wrap (TRUE)
gtk_table_attach (attach gtk_text to my packing table)
gtk_vscrollbar_new(GTK_TEXT(textwidget)->vadj)
gtk_table_attach (attach scrollbar to packing table)
gtk_widget_show(scrollbar)
gtk_widget_realize(textbox)
.. insert text from file ..
gtk_text_set_point( to 0, and I've also tried 1 and GTK_POS_TOP)
gtk_text_set_editable (FALSE)
gtk_widget_show(textbox)
gtk_widget_show(packing table)

Is this correct?  Why won't it default to the top of the textbox..?

--------------------------------------------------
Scott M. Stone <sstone@pht.com, sstone@turbolinux.com>
               <sstone@pht.co.jp>
Head of TurboLinux Development/Systems Administrator
Pacific HiTech, Inc (USA) / Pacific HiTech, KK (Japan)
http://www.pht.com		http://armadillo.pht.co.jp
http://www.pht.co.jp	        http://www.turbolinux.com


-- 
To unsubscribe: mail -s unsubscribe gtk-list-request@redhat.com < /dev/null


home help back first fref pref prev next nref lref last post