2016-09-19 54 views
0

我嘗試寫一些程序我需要使用caruosel在滾動視圖,使滑塊,走左,右頁裏面去頂到底 沒有複雜的程序只是喜歡這幅畫如何在滾動視圖kivy添加carosel

enter image description here

我嘗試這一點,但轉盤無法正常工作,並嘗試由兩個滾動視圖,滾動型做,但這種飛機也沒有工作 這是我.kv代碼

<page1>: 
    ScrollView: 
     size_hint:1,1 
     GridLayout: 
      cols:1 
      size_hint_y:None 
      height: self.minimum_height 
      Carousel: 
       size_hint_y:None 
       Button: 
        text: 'Slide one' 
       Button: 
        text: 'Slide two' 

,並嘗試這樣的:

<page1>: 
    ScrollView: 
     FloatLayout: 
      size_hint_y:1.5 
      ScrollView: 
       FloatLayout: 
        size_hint_x:1.5 

怎麼能讓圖片變成類似的東西? 感謝ü每一個答案

+0

我一直想了一會兒,似乎什麼是錯的與此添加旋轉木馬scrollview。也許你應該在github上打開一個問題。 – Juggernaut

回答

0

我做這個代碼,但滑塊是很難移動:)

<page1>: 
     ScrollView: 
      size_hint:1,1 
      GridLayout: 
       cols:1 
       spacing:5 
       size_hint_y:None 
       height: self.minimum_height 
       FloatLayout: 
        size_hint_y:None 
        height:200 
        Carousel: 
         size_hint_y:None 
         loop:True 
         direction:'right' 
         Button: 
          text: 'Slide one' 
         Button: 
          text: 'Slide two' 
         Button: 
          text: 'Slide three 

'