Re: hscale width with value_pos = GTK_POS_RIGHT



Oliver Rauch <oliver rauch rauch-domain de> writes:

I want to create several hscales, packed vertically.

I define the width of the hscales with
gtk_widget_set_size_request(scale, 201, -1)

When I set gtk_scale_set_value_pos(GTK_SCALE(scale), GTK_POS_TOP)
then all the scales have the same width. But this builds to
high widows. So I would like to use GTK_POS_RIGHT instead.

But then gtk_widget_set_size_request(scale, 201, -1) defines
the width of scale + value and because the value ranges
and representations of the values (number of digits) are
different the scales itself have different withs what looks
bad.

I would prefer that the scales all have the same width,
is there a way to make the scales look common with GTK_POS_RIGHT?


The best way of doing this I can think of is to disable the 
scale value label (set_show_value or something?) and then just have
your own labels that watch the values. GTK_POS_RIGHT is sort of
useless in many cases for this reason.

Havoc



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]