I have a series of data fields laid out in a Vbox, the size needs to vary, some need to be two lines high, others four lines or more.
The code creating the fields is:- def __init__(self, multiline=0): self.multiline = multiline if (self.multiline): self.buffer = gtk.TextBuffer() self.view = gtk.TextView(self.buffer) self.widget = gtk.ScrolledWindow() self.widget.add(self.view) self.widget.set_policy(gtk.POLICY_AUTOMATIC, gtk.POLICY_AUTOMATIC) self.widget.set_shadow_type(gtk.SHADOW_ETCHED_IN) else: self.widget = gtk.Entry() As can be seen there are single line boxes and multiline ones, what I want to be able to do is to have a parameter (or just use multiline) to set the initial number of lines in the TextView fields. Is it a matter of using gtk.Widget.set_size_request() or is there an easier way? -- Chris Green ยท -- https://mail.python.org/mailman/listinfo/python-list