Skip to content

Fix swallowed Tab after raw ANSI Shift+Tab in ted#141

Merged
tig merged 6 commits into
developfrom
copilot/fix-tab-keypress-issue
May 17, 2026
Merged

Fix swallowed Tab after raw ANSI Shift+Tab in ted#141
tig merged 6 commits into
developfrom
copilot/fix-tab-keypress-issue

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented May 17, 2026

ted could suppress the first Tab after handling raw ANSI Shift+Tab (ESC [ Z), so re-indenting required pressing Tab twice. Existing key-injection tests missed this because they bypassed the raw ANSI parser path.

  • Input state handling

    • Clear Terminal.Gui’s one-shot ANSI printable suppression after Editor handles Command.Unindent.
    • Scope the workaround to AnsiInputProcessor and make it a no-op if the internal TG field changes.
  • Regression coverage

    • Added a raw ANSI ted integration test that exercises:
      Tab → Shift+Tab (ESC [ Z) → Tab
      
    • Verifies the first post-unindent Tab immediately inserts indentation.

Warning

Firewall rules blocked me from connecting to one or more addresses (expand for details)

I tried to connect to the following addresses, but was blocked by firewall rules:

  • www.jetbrains.com
    • Triggering command: /usr/share/dotnet/dotnet /usr/share/dotnet/dotnet exec --runtimeconfig /home/REDACTED/.nuget/packages/jetbrains.resharper.globaltools/2026.1.1/tools/net8.0/any/cleanupcode.unix.runtimeconfig.json /home/REDACTED/.nuget/packages/jetbrains.resharper.globaltools/2026.1.1/tools/net8.0/any/cleanupcode.exe Terminal.Gui.Editor.slnx --profile=TG.Editor Full Cleanup (dns block)
    • Triggering command: /usr/share/dotnet/dotnet /usr/share/dotnet/dotnet exec --runtimeconfig /home/REDACTED/.nuget/packages/jetbrains.resharper.globaltools/2026.1.1/tools/net8.0/any/cleanupcode.unix.runtimeconfig.json /home/REDACTED/.nuget/packages/jetbrains.resharper.globaltools/2026.1.1/tools/net8.0/any/cleanupcode.exe Terminal.Gui.Editor.slnx (dns block)
    • Triggering command: /usr/share/dotnet/dotnet /usr/share/dotnet/dotnet exec --runtimeconfig /home/REDACTED/.nuget/packages/jetbrains.resharper.globaltools/2026.1.1/tools/net8.0/any/cleanupcode.unix.runtimeconfig.json /home/REDACTED/.nuget/packages/jetbrains.resharper.globaltools/2026.1.1/tools/net8.0/any/cleanupcode.exe Terminal.Gui.Editor.slnx --include=src/Terminal.Gui.Editor/AnsiInputProcessorState.cs;src/Terminal.Gui.Editor/Editor.Indentation.cs;tests/Terminal.Gui.Editor.IntegrationTests/EditorTabTests.cs (dns block)

If you need me to access, download, or install something from one of these locations, you can either:

Copilot AI changed the title [WIP] Fix first Tab keypress issue after Shift+Tab in ted Fix swallowed Tab after raw ANSI Shift+Tab in ted May 17, 2026
Copilot finished work on behalf of tig May 17, 2026 07:38
Copilot AI requested a review from tig May 17, 2026 07:38
@tig tig marked this pull request as ready for review May 17, 2026 07:40
@tig tig assigned Copilot and unassigned tig and Copilot May 17, 2026
@tig
Copy link
Copy Markdown
Member

tig commented May 17, 2026

@YourRobotOverlord does this fix for you?

@YourRobotOverlord
Copy link
Copy Markdown
Collaborator

Yes it does, thanks!

@tig tig merged commit b7a3684 into develop May 17, 2026
8 checks passed
@tig tig deleted the copilot/fix-tab-keypress-issue branch May 17, 2026 18:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Bug: first Tab after Shift+Tab sometimes does nothing in ted

3 participants