Skip to content

Conversation

@parasyte
Copy link
Contributor

@parasyte parasyte commented Jun 22, 2022

The goal of this PR is to turn the memory viewer into a fully functional memory editor.

  • Add edit cursor and commit with Enter.
  • Add selection ranges.
  • Copy as text.
  • Copy as binary.
  • Paste text or binary.
  • Basic navigation.
    • Follow pointer with ctrl+click.
    • Follow stack; Go back with ctrl+-.
    • Bookmarks.
  • Session storage.

The design for the editor will keep a buffer of user input that is shown in a different color until the buffer is committed with the Enter key. This will allow the edits to be applied atomically while a game is running.

@parasyte parasyte force-pushed the feature/memory-editor branch 2 times, most recently from 84541ff to cb64bd8 Compare June 22, 2022 20:11
@parasyte parasyte force-pushed the feature/memory-editor branch from cb64bd8 to 73cb5af Compare May 22, 2023 18:18
@parasyte parasyte force-pushed the feature/memory-editor branch from 73cb5af to 9c284ca Compare July 8, 2023 20:29
@parasyte parasyte force-pushed the feature/memory-editor branch 3 times, most recently from b46763e to 4503cbf Compare July 21, 2023 23:39
@parasyte parasyte force-pushed the feature/memory-editor branch 7 times, most recently from 3ab501b to 916cdd0 Compare July 31, 2023 00:30
@parasyte parasyte force-pushed the feature/memory-editor branch from 916cdd0 to 6bb9d9f Compare July 31, 2023 22:54
- This will allow us to draw with more precision. Especially for
  selection ranges and editing.
- The colors and underlines were only showing when a watchpoint was
  disabled.
- If the last hex byte in a row was underlined, the entire ASCII section
  would also be underlined on that row.
- Now colors always show when a watchpoint exists. And the byte is
  underlined only when the watchpoint is enabled.
- This bug prevented the last line of the memory view from being copied
  to the clipboard when the start of the selection was at a higher
  column number than the end of the selection.
- E.g. when address range 0x8000000c-0x80000023 was selected, it would
  only copy 0x8000000c-0x8000001f, truncating the last line and missing
  four selected bytes.
@parasyte parasyte force-pushed the feature/memory-editor branch from 6bb9d9f to de37944 Compare August 1, 2023 20:17
@parasyte parasyte marked this pull request as ready for review August 7, 2023 05:07
@parasyte
Copy link
Contributor Author

parasyte commented Aug 7, 2023

This isn't done yet, but I'm going to merge it because it's stable and I want to use the new session stuff in here for other things.

@parasyte parasyte merged commit 9d156da into pj64team:master Aug 7, 2023
@parasyte parasyte deleted the feature/memory-editor branch August 7, 2023 05:08
hacktarux pushed a commit that referenced this pull request Aug 7, 2023
* Switch hex editor to full CUSTOMDRAW

- This will allow us to draw with more precision. Especially for
  selection ranges and editing.

* Add basic hex selection

* Add ASCII column text selection

* Ctrl+C to copy selected memory

* Fix moving the window

* Fix minor bugs in memory viewer with watchpoints

- The colors and underlines were only showing when a watchpoint was
  disabled.
- If the last hex byte in a row was underlined, the entire ASCII section
  would also be underlined on that row.
- Now colors always show when a watchpoint exists. And the byte is
  underlined only when the watchpoint is enabled.

* Fix copying the last line of memory with some selection sizes

- This bug prevented the last line of the memory view from being copied
  to the clipboard when the start of the selection was at a higher
  column number than the end of the selection.
- E.g. when address range 0x8000000c-0x80000023 was selected, it would
  only copy 0x8000000c-0x8000001f, truncating the last line and missing
  four selected bytes.

* Add memory editor bookmarks

* Add missing session files to VS project filters
hacktarux pushed a commit that referenced this pull request Aug 19, 2023
* Switch hex editor to full CUSTOMDRAW

- This will allow us to draw with more precision. Especially for
  selection ranges and editing.

* Add basic hex selection

* Add ASCII column text selection

* Ctrl+C to copy selected memory

* Fix moving the window

* Fix minor bugs in memory viewer with watchpoints

- The colors and underlines were only showing when a watchpoint was
  disabled.
- If the last hex byte in a row was underlined, the entire ASCII section
  would also be underlined on that row.
- Now colors always show when a watchpoint exists. And the byte is
  underlined only when the watchpoint is enabled.

* Fix copying the last line of memory with some selection sizes

- This bug prevented the last line of the memory view from being copied
  to the clipboard when the start of the selection was at a higher
  column number than the end of the selection.
- E.g. when address range 0x8000000c-0x80000023 was selected, it would
  only copy 0x8000000c-0x8000001f, truncating the last line and missing
  four selected bytes.

* Add memory editor bookmarks

* Add missing session files to VS project filters
hacktarux pushed a commit that referenced this pull request Aug 19, 2023
* Switch hex editor to full CUSTOMDRAW

- This will allow us to draw with more precision. Especially for
  selection ranges and editing.

* Add basic hex selection

* Add ASCII column text selection

* Ctrl+C to copy selected memory

* Fix moving the window

* Fix minor bugs in memory viewer with watchpoints

- The colors and underlines were only showing when a watchpoint was
  disabled.
- If the last hex byte in a row was underlined, the entire ASCII section
  would also be underlined on that row.
- Now colors always show when a watchpoint exists. And the byte is
  underlined only when the watchpoint is enabled.

* Fix copying the last line of memory with some selection sizes

- This bug prevented the last line of the memory view from being copied
  to the clipboard when the start of the selection was at a higher
  column number than the end of the selection.
- E.g. when address range 0x8000000c-0x80000023 was selected, it would
  only copy 0x8000000c-0x8000001f, truncating the last line and missing
  four selected bytes.

* Add memory editor bookmarks

* Add missing session files to VS project filters
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.

1 participant