Is there a way to move tabs from TabbedPanel to the side of the layout?

57 views
Skip to first unread message

Atrian Wagner

unread,
Feb 8, 2016, 12:39:15 PM2/8/16
to Kivy users support
Using the following example code:
from kivy.uix.tabbedpanel import TabbedPanel
from kivy.app import App
from kivy.uix.floatlayout import FloatLayout
from kivy.lang import Builder
Builder.load_string("""
<Test>:
    size_hint: 1, 1
    pos_hint: {'center_x': .5, 'center_y': .5}
    do_default_tab: False
    TabbedPanelItem:
        text: 'Drives'
        Label:
            text: 'Drives Available'
    TabbedPanelItem:
        text: 'Tests'
        BoxLayout:
            Label:
                text: 'Tests'
            Button:
                text: 'Select Tests'
    TabbedPanelItem:
        text: 'Details'
        RstDocument:
            text:
                '\\n'.join(("Details", "-----------",
                "Model Number"))
TabbedPanelItem:
        text: 'Start'
        RstDocument:
            text:
                '\\n'.join(("Details", "-----------",
                "Progress"))
""")

class Test(TabbedPanel):
pass
class TabbedPanelApp(App):
def build(self):
return Test()
if __name__ == '__main__':
TabbedPanelApp().run()

If possible, how would I move the tabs of the TabbedPanel from the top to the side? If not possible with TabbedPanel, is there any kind of workaround that could be done with buttons and other layouts?

Atrian Wagner

unread,
Feb 8, 2016, 1:11:49 PM2/8/16
to Kivy users support
I have since found the TabbedPanel Showcase, which answers the part of my question as to whether it is possible. However, I am having trouble dissecting which specific piece of code would put the tabs specifically on the side (on the left side specifically is what I am looking for). Any pointers would be appreciated.

qua non

unread,
Feb 8, 2016, 3:30:45 PM2/8/16
to kivy-...@googlegroups.com
tab_pos: 'left_mid'


left_mid/left_top/left_bottom

--
You received this message because you are subscribed to the Google Groups "Kivy users support" group.
To unsubscribe from this group and stop receiving emails from it, send an email to kivy-users+...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply all
Reply to author
Forward
0 new messages