Repository navigation
feat(text_editor): let a finger focus, place the caret and select - #67
Merged
Merged
Conversation
A finger now acts like the left mouse button: a tap, two or three quick taps, and a drag. Port of upstream `iced-rs#3442`. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
A finger does nothing in a
text_editor. On a touch laptop or a handheld, a tap in Slate's note body neither focuses it nor moves the caret, and there is no way to select text.text_inputalready handles touch.Fix
iced-rs/iced#3442. No API change.Testing
widget/tests/text_editor_touch.rs(5 tests, touch events through the simulator): all pass; all 5 fail onmaster.cargo lintandcargo fmt --checkpass.file_typesfails, on the same 21 pptx, pdf and mp4 capturesmaingets wrong on this machine (LibreOffice and poppler). On wgpu,goldensandfile_typesfailed under load in the full run and pass alone, as they do on icedmaster. No golden moved.To try it:
cargo test -p iced_widget --test text_editor_touch🤖 Generated with Claude Code