How to use vertical GtkScale in GtkGrid with Gtk.jl

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?

I think you put the scale in the upper left corner of your grid, so it cannot expand lower than the lower edge of button1. Try packing the buttons in a VBox and scale and VBox together in a HBox. btw: for experimenting with layout options use glade.

I got the same result by using Vboxes in a Hbox, but it worked well with Glade! I’m not sure why it worked, but it’s probably some property issues :thinking:
Thank you!

A possible non-Glade solution:

using Gtk 

c = GtkScale(true, -1:0.1:1)
set_gtk_property!(c, :vexpand, true)

oc = GtkOrientable(c)
set_gtk_property!(oc, :orientation, 1)

b1 = GtkButton("Button1")
b2 = GtkButton("Button2")

ph = GtkLabel("") # placeholder
set_gtk_property!(ph, :hexpand, true)

g = GtkGrid()
g[1, 1:2] = c

g[2, 1:2] = ph

g[3, 1] = b1
g[3, 2] = b2

win = GtkWindow()
push!(win, g)
showall(win)