Fix Help menu searching Vim doc not working with special chars #1455
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.
Previously Help menu's Vim doc search did not work with special key documentation like
<Down>
because when sending the input to Vim, Vim interpreted:h <Down>
as physically pressing down arrow instead of typing the literal text in. Fix this by a somewhat manual process of splitting the strings up and using:execute
and string concatenation. It's not pretty but works. Otherwise we would need to define another IPC call to be able to pass commands to Vim without escaping commands.Also fix up XCText utility so we don't use a predicate to wait for Vim open/close which was previously kind of slow. The new method of just using swizzling is much faster.