@@ -272,7 +272,7 @@ def DisplayProgressBar(self, x: int, y: int, width: int, height: int, min_value:
272
272
273
273
self .DisplayPILImage (bar_image , x , y )
274
274
275
- def DisplayRadialProgressBar (self , xc : int , yc : int , radius : int , barwidth : int ,
275
+ def DisplayRadialProgressBar (self , xc : int , yc : int , radius : int , bar_width : int ,
276
276
min_value : int = 0 ,
277
277
max_value : int = 100 ,
278
278
angle_start : int = 0 ,
@@ -303,7 +303,7 @@ def DisplayRadialProgressBar(self, xc: int, yc: int, radius: int, barwidth: int,
303
303
assert yc <= self .get_height (), 'Progress bar Y coordinate must be <= display height'
304
304
assert xc + radius <= self .get_width (), 'Progress bar width exceeds display width'
305
305
assert yc + radius <= self .get_height (), 'Progress bar height exceeds display height'
306
- assert barwidth > 0 , 'Progress bar linewidth must be > 0'
306
+ assert 0 < bar_width <= radius , 'Progress bar linewidth must be > 0 and <= radius '
307
307
assert angle_end % 361 != angle_start % 361 , 'Change angles values'
308
308
309
309
# Don't let the set value exceed our min or max value, this is bad :)
@@ -353,7 +353,7 @@ def DisplayRadialProgressBar(self, xc: int, yc: int, radius: int, barwidth: int,
353
353
angleE = angle_start
354
354
355
355
draw .arc ([0 , 0 , diameter - 1 , diameter - 1 ], angleS , angleE ,
356
- fill = bar_color , width = barwidth )
356
+ fill = bar_color , width = bar_width )
357
357
358
358
# Draw text
359
359
if with_text :
0 commit comments