entry: Use a scrolled window
This ensures all entries are reachable even with the OSK unfolded
This commit is contained in:
@ -46,6 +46,7 @@ class App(Gtk.Application):
|
|||||||
|
|
||||||
def do_activate(self):
|
def do_activate(self):
|
||||||
w = Gtk.ApplicationWindow(application=self)
|
w = Gtk.ApplicationWindow(application=self)
|
||||||
|
w.set_default_size (300, 500)
|
||||||
notebook = Gtk.Notebook()
|
notebook = Gtk.Notebook()
|
||||||
def add_purpose(entry, purpose):
|
def add_purpose(entry, purpose):
|
||||||
entry.set_input_purpose(purpose)
|
entry.set_input_purpose(purpose)
|
||||||
@ -54,7 +55,10 @@ class App(Gtk.Application):
|
|||||||
purpose_grid = new_grid(self.purposes, add_purpose)
|
purpose_grid = new_grid(self.purposes, add_purpose)
|
||||||
hint_grid = new_grid(self.hints, add_hint)
|
hint_grid = new_grid(self.hints, add_hint)
|
||||||
|
|
||||||
notebook.append_page(purpose_grid, Gtk.Label(label="Purposes"))
|
purpose_scroll = Gtk.ScrolledWindow()
|
||||||
|
purpose_scroll.set_policy(Gtk.PolicyType.NEVER, Gtk.PolicyType.AUTOMATIC)
|
||||||
|
purpose_scroll.add(purpose_grid)
|
||||||
|
notebook.append_page(purpose_scroll, Gtk.Label(label="Purposes"))
|
||||||
notebook.append_page(hint_grid, Gtk.Label(label="Hints"))
|
notebook.append_page(hint_grid, Gtk.Label(label="Hints"))
|
||||||
w.add(notebook)
|
w.add(notebook)
|
||||||
w.show_all()
|
w.show_all()
|
||||||
|
|||||||
Reference in New Issue
Block a user