Skip to content

Undoing Ctrl+E leaves a large block of text selected #2084

@jonschz

Description

@jonschz

When I press Ctrl+E (\begin{<environment>}) in the middle of a document and then press Ctrl+Z (undo), a block of text is selected below the cursor. I would expect no selected text after these two steps.

Environment

  • TeXstudio: 4.2.0
  • Qt: 6.2.1
  • OS: Windows 10
  • TeX distribution: miktex

Expected behavior

No text should be selected after Ctrl+E, then Ctrl+Z.

Actual behavior

After Ctrl+E and Ctrl+Z, two full lines plus part of the third line below the cursor are selected.

How to reproduce

  • Generate three lines of text in a new document.
  • Move the cursor to the start of the document.
  • Press Ctrl+E
  • Press Ctrl+Z

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions