python gtk - How to define the size of gtk.textview? -


i have constructed texview this:

#textview self.fd = gtk.scrolledwindow() tableau2.attach(self.fd, 0, 2, 0, 4, xpadding=10, ypadding=5) self.fd.set_policy(gtk.policy_automatic, gtk.policy_automatic)  self.textview = gtk.textview() self.textview.set_editable(false) self.textview.set_wrap_mode(gtk.wrap_word) self.textview.set_cursor_visible(true) self.textview.set_justification(gtk.justify_left) self.buffertexte = self.textview.get_buffer() self.edition = self.textview.get_editable() self.iterdebut = self.buffertexte.get_end_iter() self.buffertexte.set_text("") self.fd.add(self.textview) self.fd.show() self.textview.show() 

but height little in unity3d: enter image description here

how modify size?

thanks

you can call set_size_request on textview:

self.textview.set_size_request(-1, desired_min_height) 

Comments

Popular posts from this blog

matlab - "Contour not rendered for non-finite ZData" -

delphi - Indy UDP Read Contents of Adata -

javascript - Any ideas when Firefox is likely to implement lengthAdjust and textLength? -