Using Windows 7 to open a file in HxD using the "open with" (or read-only) shell context menu entry I get the following:
A rectangle is drawn over the first character in the file. I haven't been able to figure out whether this is an option or how to disable it.
If the same file is opened via the shell using drag&drop to an open HxD window or via the file browser dialogs in HxD the rectangles do not appear.
What are these rectangles?
Rectangle over first character (open with)
Re: Rectangle over first character (open with)
Since the data is displayed twice, once as text interpretation(2nd column), once as hexadecimal numbers (1st column), there are two carets.
A caret, also called insertion mark, is the vertical line showing you where characters will be inserted in the file.
The rectangle is the ghost caret, which highlights the data in the "inactive" column corresponding to the data in the active one.
If you press the tab key you will see that the ghost and normal caret will be exchanged.
P.S.: No worries about the duplicate posts. I had the same issue, it was due to an updated PHP version.
A caret, also called insertion mark, is the vertical line showing you where characters will be inserted in the file.
The rectangle is the ghost caret, which highlights the data in the "inactive" column corresponding to the data in the active one.
If you press the tab key you will see that the ghost and normal caret will be exchanged.
P.S.: No worries about the duplicate posts. I had the same issue, it was due to an updated PHP version.
Re: Rectangle over first character (open with)
I now see that both sides have a rectangle.
This first looked like a drawing bug, but it is due to the datainspector overlaying another rectangle (of a different color) around the bytes that are interpreted in the data inspector. The active row in the data inspector is what determines the length of that rectangle. Change the active row in the data inspector to see how it changes.
The rectangle appears if the datainspector has the focus. Seems opening through the windows explorer context menu focuses the data inspector, instead of the hex editor. It's a minor bug, but you can simply click the datainspector, then the hex editor, and it should be fine again.
P.S.:Please attach the image, instead of linking to imgur.
This first looked like a drawing bug, but it is due to the datainspector overlaying another rectangle (of a different color) around the bytes that are interpreted in the data inspector. The active row in the data inspector is what determines the length of that rectangle. Change the active row in the data inspector to see how it changes.
The rectangle appears if the datainspector has the focus. Seems opening through the windows explorer context menu focuses the data inspector, instead of the hex editor. It's a minor bug, but you can simply click the datainspector, then the hex editor, and it should be fine again.
P.S.:Please attach the image, instead of linking to imgur.
Re: Rectangle over first character (open with)
Here is an additional screenshot:
This appears to be some sort of drawing bug or initialization issue. I haven't been able to test whether this only occurs on Windows 7 or not but it is possible the current code sets up the caret rectangle (GDI functions?) in a way which fails under specific versions of the OS. The only thing I can think is perhaps there is a missing DeleteObject() or mismatched BeginPaint() EndPaint() calls?
Yes the caret functionality works fine. This is a redundant fixed black rectangle that only appears when HxD is launched with a file path parameter. If a file is opened using any other method it never appears, although the caret functionality always works correctly. This appears to be some sort of drawing bug or initialization issue. I haven't been able to test whether this only occurs on Windows 7 or not but it is possible the current code sets up the caret rectangle (GDI functions?) in a way which fails under specific versions of the OS. The only thing I can think is perhaps there is a missing DeleteObject() or mismatched BeginPaint() EndPaint() calls?
Re: Rectangle over first character (open with)
I just noticed that after I posted, then edited my post.
Here is the relevant part:
Here is the relevant part:
So it's a kind of focusing issue.The rectangle appears if the datainspector has the focus. Seems opening through the windows explorer context menu focuses the data inspector, instead of the hex editor. It's a minor bug, but you can simply click the datainspector, then the hex editor, and it should be fine again.
Re: Rectangle over first character (open with)
The cursor remains fixed at the first [0] byte of the file. If the file is scrolled (display offset/index is incremented) beyond the first row the extra rectangle does not appear.
Re: Rectangle over first character (open with)
For me this works: Open as readonly (Explorer), then click on a row in the datainspector, then the hexeditor.
Re: Rectangle over first character (open with)
Ah right, yes if I activate the data inspector regardless of how, the rectangle immediately disappears. Is it possible this is an initialization bug?
The code which opens a file from the parameter string must not behave the same way the dialogs or drag&drop do. They seem to initialize the window (inspector object?) parameters correctly.
The code which opens a file from the parameter string must not behave the same way the dialogs or drag&drop do. They seem to initialize the window (inspector object?) parameters correctly.
Re: Rectangle over first character (open with)
It's a focusing issue, what it is idk yet. But the creation order can be different sometimes, Windows is not that deterministic (for example due to PostMessage), and the VCL/Delphi neither. I'll have to see what is causing that.