I'm trying to use match case when checking the value in event loop. However break
not only break the match case, but break the event loop too.
This is the code
while True:
# Some code stuff here
if event == "#PassSign":
# Some code stuff again to check password strength
# Display the password strength
match strength_pass:
case 0:
window["#StatusPassSign"].update("No Password", visible=True)
break
case 1:
window["#StatusPassSign"].update("Password Strength: Low", visible=True)
break
case 2:
window["#StatusPassSign"].update("Password Strength: Medium", visible=True)
break
case 3:
window["#StatusPassSign"].update("Password Strength: High", visible=True)
break
How to break/stop the match case, without stop the event loop?