1
0
mirror of synced 2024-11-24 07:40:17 +01:00
ImHex/plugins
paxcut 866b956680
feat: Added per provider cursor position for the Pattern editor (#1861)
### Problem description
Currently, the pattern editor does not remember where the cursor is
located in each provider. For example, suppose you have 2 providers in
your project, and you scrolled down to line 200 in the first pattern to
make some changes and remembered that the code you want to insert is in
the second provider. Then you switch to the second provider, look for
the code and find it in line 235. Switch back to the first one, and you
are at the beginning of the file. So you again look for the line to edit
paste it to realize that it needs code a few lines before the place you
found it. You switch to the second provider, and you are at the top
again. This gets annoying very fast.

### Implementation description

This PR ensures that, when you return to the pattern in the editor for
any of the opened providers, the cursor will still be at the same place
it was when you switched to a different one. Each provider pattern saves
its cursor position and returns to it when you switch to that provider.
It does that by creating a PerProvider variable and using it when
providers are first opened to set it to the origin and when switching
providers it first saves the position of the old provider and then loads
and sets the saved position of the new provider.

---------

Co-authored-by: Nik <werwolv98@gmail.com>
2024-09-15 15:28:37 +02:00
..
builtin feat: Added per provider cursor position for the Pattern editor (#1861) 2024-09-15 15:28:37 +02:00
decompress fix: LZMA decompressor memory errors (#1873) 2024-09-15 15:20:17 +02:00
diffing lang: Update Chinese (Simplified) translations (#1894) 2024-09-15 15:17:25 +02:00
disassembler fix: Task names not displaying correctly anymore 2024-07-27 14:09:52 +02:00
fonts fix: Crash on exit when using custom font from file (#1815) 2024-07-15 22:22:02 +02:00
hashes fix: Segfault when hashing regions spanning multiple MiBs (#1804) 2024-07-21 20:35:38 +02:00
script_loader lang: Update Chinese (Simplified) translations (#1894) 2024-09-15 15:17:25 +02:00
ui lang: Update Chinese (Simplified) translations (#1894) 2024-09-15 15:17:25 +02:00
visualizers fix: Unable to resize 3d-visualizer window in x-direction (#1860) 2024-09-15 15:27:39 +02:00
windows lang: Update Chinese (Simplified) translations (#1894) 2024-09-15 15:17:25 +02:00
yara_rules fix: Task names not displaying correctly anymore 2024-07-27 14:09:52 +02:00