Noob: Going Vertical! Slider orientation

Hello again all,

How does one orient a DirectSliderBar to go vertical.

According to the manual, one should be able to do something like either of the following:

self.sliderX = DirectSliderBar(pos = Vec3(0,0,0.7), value = .5, orientation='VERTICAL', command = self.PanX)

— or —


Neither of these work - I get undefined / unknown option when I try.

I have scoured the code and in for the DirectSliderBar class — optiondefs … orientation is not defined.

Related question: Is it possible and / or reasonable to place tkwidgets / pmw widgets directly into the panda window as a 2d layer so that I can go directly to these resources rather than use the panda directgui stuff?

I seem to be able to make the tkwidgets/pmw widgets do what I want / need but I am having difficulty with the Panda3d widget implementation.


My bet is that this wasn’t functional in 1.0.5

As of version 1.1, this does work. Hoever, you need to give it the value at setup time


This value is used when the internal setup is called.

I downloaded and installed 1.1 and still cannot get a slider to go vertical. I get the same error message as before.

Surely this can be done… I’ve seen vertical sliders in the screenshots on this site.

Any suggestions?

You could always try rotating it, using setH or setR.

Thanks Josh, I did try HPR(0,90,0) and that did make the slider go vertical. THe two end buttons worked but the middle drag-button did not.

I think I’ll devise some kind of clever work around for now and avoid the vertical slider.

It is frustrating because I see vertical sliders in the screenshots!!!

I think the key here is to use VERTICAL, not ‘VERTICAL’ (no quote marks). There is a Python variable called VERTICAL which you import when you import DirectGUI. It happens to be defined to the string ‘vertical’ (all lowercase). But the string ‘VERTICAL’ (quote marks, all uppercase) doesn’t mean anything.