NPP_HexEdit icon indicating copy to clipboard operation
NPP_HexEdit copied to clipboard

A Bug Report: Display Error?

Open davidanger opened this issue 6 years ago • 4 comments

I'm using Th.HEX file to Tb.BIN file. Found this maybe a Bug. Th.HEX: :05000000744C7867F666 :00000001FF Tb.BIN(Should Be): 00000000 74 4C C7 78 67 F6 Tb.BIN(Display): 00000000 74 4C C7 78 67 C3 B6

So If you change or make a bin file in HEX mode, by end of F6. Than you save and reopen this file, you'll see display is C3 B6.

Thanks.

davidanger avatar Dec 19 '18 07:12 davidanger

N++: 7.6 64bit Nov 13 2018 Plug: 0.9.5.19

davidanger avatar Dec 19 '18 07:12 davidanger

Maybe a issue with the automatic detection of the encoding. Which one did you use for creating/modifying the file and which one is shown on reload? You could try to disable autodetect char encoding in preferences:

grafik

chcg avatar Dec 20 '18 20:12 chcg

The same problem occured when I opened a file with content F6 00 09 00 00 00 00 00 00 00, the F6 was "replaced" with C3 B6 and the last 4 bytes disappeared. It still occurs after I diasbled autodetect encoding. I created this file by using fwrite() in a C program, the encoding shown in NPP was UCS-2 Little Endian. I'm using NPP 7.5.9 64-bit and the plugin's version is 0.9.5.19.

TransparentLC avatar Apr 04 '19 11:04 TransparentLC

From https://github.com/notepad-plus-plus/notepad-plus-plus/issues/7818

Problem

1. I created a binary file use this C code

    uint32_t d = 0xf1f2f3f4;
    FILE* f = fopen("t.bin","wb");    
    fwrite(&d,1,4,f);
    fclose(f);

2. then open it with Notepad++

3. The status bar does not display correctly

  • Expected: length:4 lines:1
  • Actual: length:8 lines:1

4. click plugin menu of HEX-Editor -> View in Hex, it's also incorrect,

  • Expected: f1 f2 f3 f4
  • Actual: d1 84 d1 83 d1 82 d1 81

1

Debug Information

Notepad++ v7.8.2 (32-bit) Build time : Dec 4 2019 - 01:36:59 Path : C:\Program Files (x86)\Notepad++\notepad++.exe Admin mode : OFF Local Conf mode : OFF OS Name : Windows 10 Home China (64-bit) OS Version : 1903 OS Build : 18362.535 Plugins : DSpellCheck.dll HexEditor.dll mimeTools.dll NppConverter.dll NppExport.dll NppMarkdownPanel.dll

HEX-Editor version : 0.9.5

chcg avatar Jan 06 '20 17:01 chcg