ImHex icon indicating copy to clipboard operation
ImHex copied to clipboard

[Feature] Shortcuts for toggling line comments ( CTRL+/ and )

Open slimeinacloak opened this issue 1 year ago • 2 comments

What feature would you like to see?

Shortcut for toggling line comments and block comments in the pattern editor in the same way VS code works

Toggling single lines comments (adds // to the start of each line): Windows: Ctrl + / Linux: Ctrl + / macOS: Command + /

Toggling block comments (add /* to the start of the first selected line, indents the rest and adds */ to the end of the last selected line): Windows: Shift + Alt + A Linux: Shift + Ctrl + A macOS: Shift + Option + A

How will this feature be useful to you and others?

When writting patterns quickly disabling sections is helpful

Request Type

  • [ ] I can provide a PoC for this feature or am willing to work on it myself and submit a PR

Additional context?

No response

slimeinacloak avatar May 10 '25 02:05 slimeinacloak

this has been discussed before but there are more comment types to deal with. Besides line and block comments pattern language also supports line, block and global doc comments that would also need shortcuts and i don't think VS supports those.

paxcut avatar May 10 '25 02:05 paxcut