How to use vertical GtkScale in GtkGrid with Gtk.jl

kogad
Thu, 17 Sep 2020 05:59:20 +0000
General Usage

Hi. I am trying to use a vertical slider (GtkScale) in a grid , but this code does not work well.

using Gtk

win = GtkWindow()
c = GtkScale(false, -1:0.1:1)
oc = GtkOrientable(c)
GAccessor.orientation(oc, 1)
b1 = GtkButton("Button1")
b2 = GtkButton("Button2")
g = GtkGrid()
g[1, 1] = c
g[2, 1] = b1
g[2, 2] = b2
push!(win, g)
showall(win)

I get:

It seems the slider is too short.
Horizontal one can be used by this sample code in the doc (Layout · Gtk.jl) and it works well.
Is there a way to put a vertical slider which has enough length into a grid?

4 posts - 3 participants