Labs-Windows
Labs-Windows copied to clipboard
Enable pausing/resuming MarqueeText
From https://github.com/CommunityToolkit/Labs-Windows/issues/426:
Hi, I'm using this control in my project currently, I want to implement a feature that when the pointer entered the text start animation, and when pointer exited, the text should be re-placed at the very begin place. is there any way to programmatically achieve this? Or should this be a feature request?
Originally posted by @Lightczx in https://github.com/CommunityToolkit/Labs-Windows/issues/426#issuecomment-1696754039
The
resume
parameter is for when the speed or control size changes while the animation is running. It is not supposed to be used for pausing or resuming the animation.In design I intended for the Marquee to not play until
StartMarquee
is called. This is not the behavior because of line 56 isMarqueeText.Events
link, which automatically begins the animation when the container size is changed. I should have left this behavior up to the user.@Arlodotexe Should I release a patch? It's a technically a small breaking change.
Originally posted by @Avid29 in https://github.com/CommunityToolkit/Labs-Windows/issues/426#issuecomment-1791218986
This is a reasonable scenario to support for MarqueeText. We should look into implementing pause/resume functionality.
@Avid29 Since you're most familiar with the codebase, would you like to submit a PR for this?
@Avid29 Since you're most familiar with the codebase, would you like to submit a PR for this?
Can do