Skip to content

Auto-completing using Scintilla wrapper creates 2 separate Undo events #31

@WheelsNotRound

Description

@WheelsNotRound

Using the Scintilla Wrapper, during the completion of the auto-complete cycle, 2 separate Undo events are created on the scintilla undo stack.

This leads to a slightly strange experience when undoing an auto-complete. From and end users point of view, if they undo an auto-complete, the 'auto-completed' characters should be removed, leaving the initially types characters alone.
What we see is the entire word is removed on the first undo, and then on a second undo must be invoked for the initially typed characters to be restored.

I believe the issue is in the 'SelectedText' property of the ScintillaWrapper class , where two separate scintilla text methods are used to first clear the typed characters, and then second to insert the full match text.

If these 2 calls were surround by a call to 'BeginUndoAction' and a call to 'EndUndoAction' on the scintilla control, this would resolve the issue.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions