Reputation: 43168
All of the hexl-insert-
commands overwrite the byte at point. It makes no difference whether overwrite-mode
is on.
I need to actually insert a new byte at point, moving everything else down.
How can I do this in emacs?
Upvotes: 14
Views: 5277
Reputation: 576
I can't insert characters directly in nhexl-mode either. I have to follow such approach:
M-x nhexl-mode
then M-x nhexl-nibble-edit-mode
C-y
to yank this character and adjust file formatFor example, If I want to insert 5300
to represent S
, I need to press C-y
to get 5353
, then edit it into 5300
I'm using GNU Emacs 26.1 (build 1, x86_64-w64-mingw32) on Windows 10 and nhexl 1.2
Upvotes: 0
Reputation: 28531
You might prefer nhexl-mode
, which lets you edit the file as if it was not hexlified (basically, the hexlification in nhexl-mode is done on-the-fly during redisplay), so you can insert/remove text without any difficulty.
Upvotes: 7