Skip to content

Commit f1d9711

Browse files
committed
fix: use same default alignment for FillBar base/fill
Fixes #53
1 parent 75d0b59 commit f1d9711

File tree

2 files changed

+17
-0
lines changed

2 files changed

+17
-0
lines changed

glooey/themes/golden.py

+2
Original file line numberDiff line numberDiff line change
@@ -211,6 +211,7 @@ class Base(glooey.Background):
211211
custom_left = assets.image('fill_bars/basic/base_left.png')
212212
custom_center = assets.texture('fill_bars/basic/base_center.png')
213213
custom_right = assets.image('fill_bars/basic/base_right.png')
214+
custom_alignment = 'fill horz'
214215
custom_htile = True
215216

216217
class Fill(glooey.Background):
@@ -244,6 +245,7 @@ class Base(glooey.Background):
244245
custom_left = assets.image('fill_bars/fancy/base_left.png')
245246
custom_center = assets.texture('fill_bars/fancy/base_center.png')
246247
custom_right = assets.image('fill_bars/fancy/base_right.png')
248+
custom_alignment = 'fill horz'
247249
custom_htile = True
248250

249251
class Fill(glooey.Background):

tests/issues/53.py

+15
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
#!/usr/bin/env python3
2+
3+
import pyglet
4+
import glooey.themes.golden as golden
5+
6+
print("Fill should be superimposed on base, not separated.")
7+
8+
window = pyglet.window.Window()
9+
gui = golden.Gui(window)
10+
bar = golden.FancyFillBar()
11+
gui.add(bar)
12+
13+
bar.fraction_filled = .5
14+
15+
pyglet.app.run()

0 commit comments

Comments
 (0)