[pygtk] scaling in slider

CJ Kucera pez at apocalyptech.com
Tue Mar 24 22:43:13 WST 2009


Sibtey Mehdi wrote:
>             i am newbie to pygtk i am trying to add the slider in my
>    application. i want the increment shuold be like 

I actually had a somewhat similar need the other day, and what I did
about it was:

  1) Set the slider's update policy to "Discontinuous"
  2) Attach the "value-changed" signal to the *Adjustment,* not the
     Scale itself

Once I did that, things started working like I had hoped that they
would.  From what I've seen, btw, if you want the slider to visually
"snap" to your limited values, you *have* to have it draw that value
somewhere; you can't *just* have the slider.  If I'm wrong about that,
I'd like to hear about it.  :)

-CJ

-- 
WOW: Flemmy            |   "Happiness isn't good enough for me!  I
pez at apocalyptech.com   |              demand euphoria!"
24.24.2.3171           |                  - Calvin


More information about the pygtk mailing list