mirror of https://github.com/kivy/kivy.git
Added overlap and bgcolor control to efw example
This commit is contained in:
parent
e71f8381fc
commit
34327e0670
|
@ -74,17 +74,57 @@ example = Builder.load_string('''
|
||||||
#:import Vector kivy.vector.Vector
|
#:import Vector kivy.vector.Vector
|
||||||
BoxLayout:
|
BoxLayout:
|
||||||
orientation: 'vertical'
|
orientation: 'vertical'
|
||||||
BoxLayout:
|
FloatLayout:
|
||||||
ComparisonWidget:
|
ComparisonWidget:
|
||||||
|
pos_hint: {'x': 0, 'y': 0}
|
||||||
|
size_hint: 0.5, 1
|
||||||
id: effect1
|
id: effect1
|
||||||
ComparisonWidget:
|
ComparisonWidget:
|
||||||
|
pos_hint: {'x': pos_slider.value, 'y': 0}
|
||||||
|
size_hint: 0.5, 1
|
||||||
id: effect2
|
id: effect2
|
||||||
|
background_color: (rs.value, gs.value, bs.value, als.value)
|
||||||
SpinnerRow:
|
SpinnerRow:
|
||||||
effectwidget: effect1
|
effectwidget: effect1
|
||||||
text: 'left effects'
|
text: 'left effects'
|
||||||
SpinnerRow:
|
SpinnerRow:
|
||||||
effectwidget: effect2
|
effectwidget: effect2
|
||||||
text: 'right effects'
|
text: 'right effects'
|
||||||
|
BoxLayout:
|
||||||
|
size_hint_y: None
|
||||||
|
height: sp(40)
|
||||||
|
Label:
|
||||||
|
text: 'control overlap:'
|
||||||
|
Slider:
|
||||||
|
min: 0
|
||||||
|
max: 0.5
|
||||||
|
value: 0.5
|
||||||
|
id: pos_slider
|
||||||
|
BoxLayout:
|
||||||
|
size_hint_y: None
|
||||||
|
height: sp(40)
|
||||||
|
Label:
|
||||||
|
text: 'right bg r,g,b,a'
|
||||||
|
Slider:
|
||||||
|
min: 0
|
||||||
|
max: 1
|
||||||
|
value: 0
|
||||||
|
id: rs
|
||||||
|
Slider:
|
||||||
|
min: 0
|
||||||
|
max: 1
|
||||||
|
value: 0
|
||||||
|
id: gs
|
||||||
|
Slider:
|
||||||
|
min: 0
|
||||||
|
max: 1
|
||||||
|
value: 0
|
||||||
|
id: bs
|
||||||
|
Slider:
|
||||||
|
min: 0
|
||||||
|
max: 1
|
||||||
|
value: 0
|
||||||
|
id: als
|
||||||
|
|
||||||
|
|
||||||
<ComparisonWidget>:
|
<ComparisonWidget>:
|
||||||
|
|
Loading…
Reference in New Issue