tig
tig

Reputation: 27830

Lock GTK3 Paned interface from allowing resizing

Is there any way to lock GTK3 Paned, so that user can't even attempt to resize the panes/children?

Reason for the question is interacting on a not very big touch screen with 3 panes containing 4 scrollable lists in quodlibet, and as a wide area of ±50px around the handles for touch events starts the resizing, there is not really much space left to interact with the widgets inside. Is there any simpler way than replacing the Paned widget with Box widget and moving all children to lock resizing and back with Paned to unlock?

Upvotes: 0

Views: 77

Answers (1)

Kripto
Kripto

Reputation: 474

I don't know if I understand exactly what you want, but it seems to me that you want to prevent the user from moving the Gtk.Paned separator. If that's the case, one way is to set a minimum size for child widgets of Gtk.Paned using Gtk.Widget.set_size_request().

Thus, the user can still move the separator when there is enough space, but will not be able to move it when the space reaches the defined minimum limit.

Upvotes: 0

Related Questions