def __init__(self, **kwargs):
super(UiowaScreen, self).__init__(**kwargs)
self.layout = FloatLayout()
self.layout.width = Window.width
self.layout.height = Window.height
self.layout.x = Window.width/2 - self.layout.width/2
self.layout.y = Window.height/2 - self.layout.height/2
self.add_widget(self.layout)
self.img = Image(source = self.uiowaImage)
self.img.size = (Window.width*1.0, Window.height*1.0)
self.img.pos = (-Window.width*0.0, -Window.height*0.0)
self.img.opacity = 0.4
self.add_widget(self.img)
self.aboutText = Label(text= 'UIOWA INFO HERE')
self.aboutText.pos = (.25, .25)
self.add_widget(self.aboutText)
tmpBtn1 = MyButton(text = 'BACK') #start button
tmpBtn1.size_hint = (.1, .1)
tmpBtn1.pos_hint ={'x': 0, 'y': .9}
tmpBtn1.background_color = [.4, .4, .4, 1]
tmpBtn1.bind(on_release = self.backButton) #when the button is released the backButton function is called
self.layout.add_widget(tmpBtn1)
评论列表
文章目录