Skip to content

Commit

Permalink
Enhance docs
Browse files Browse the repository at this point in the history
  • Loading branch information
ppizarror committed Dec 23, 2024
1 parent 96f8a7a commit 9fa0330
Showing 1 changed file with 6 additions and 9 deletions.
15 changes: 6 additions & 9 deletions pygame_menu/widgets/core/widget.py
Original file line number Diff line number Diff line change
Expand Up @@ -2144,19 +2144,16 @@ def _scale_warn(
# noinspection PyUnresolvedReferences
if not self._verbose:
return
elif self._scale[0] and scale:
# Iterate each type and warn accordingly
if self._scale[0] and scale:
warn('widget already has a scaling factor applied. Scaling has '
'been disabled')
if self._max_width[0] is not None and maxwidth:
warn(
'widget max width is not None. Set widget.set_max_width(None) '
'for disabling such feature. This scaling will be ignored'
)
warn('widget max width is not None. Set widget.set_max_width(None) '
'for disabling such feature. This scaling will be ignored')
if self._max_height[0] is not None and maxheight:
warn(
'widget max height is not None. Set widget.set_max_height(None) '
'for disabling such feature. This scaling will be ignored'
)
warn('widget max height is not None. Set widget.set_max_height(None) '
'for disabling such feature. This scaling will be ignored')

def set_max_width(
self,
Expand Down

0 comments on commit 9fa0330

Please sign in to comment.