1
0
mirror of synced 2024-09-24 11:38:26 +02:00
Commit Graph

1828 Commits

Author SHA1 Message Date
WerWolv
2ef256ee74 impr: Show full error message for custom data inspector row errors 2024-06-08 13:40:39 +02:00
WerWolv
041bf47ff4 fix: Title bar height on non-macOS platforms 2024-06-08 00:56:52 +02:00
WerWolv
53ced98529 impr: Enable auto project backup by default 2024-06-08 00:52:27 +02:00
WerWolv
bf82690c80 fix: Build and drawing of title bar buttons on macOS 2024-06-08 00:28:17 +02:00
WerWolv
18e2b0eaa2 fix: Regex crashes with too long input strings 2024-06-07 23:12:18 +02:00
WerWolv
b80a6152b3 fix: Unifont being blurry again 2024-06-07 22:50:47 +02:00
WerWolv
ffe3dae7b2 build: Updated ImGui to v1.90.8 2024-06-07 22:12:50 +02:00
WerWolv
af59b9d2ca fix: Infinite loop when doing forwards/backwards searches in some cases
Fixes #1734
2024-06-07 21:00:55 +02:00
WerWolv
6fb32d20b3 fix: Don't try to compile process memory provider into Web build 2024-06-07 20:32:04 +02:00
WerWolv
ea09bfe8ea feat: Highlight patterns in pattern data view that are fully selected
Fixes #1741
2024-06-07 19:59:11 +02:00
WerWolv
c0dde570e4 feat: Highlight patterns in hex editor when hovering over pattern data row
Fixes #1742
2024-06-07 19:48:10 +02:00
WerWolv
6fd3fa77ed impr: Don't scroll hex editor view when jumping to a region that's on-screen already
Fixes #1743
2024-06-07 19:29:55 +02:00
WerWolv
ff20f81cfd impr: Added back selection size in hex to the footer 2024-06-07 19:21:38 +02:00
WerWolv
de8465a8f4 feat: Added limited support for the process memory provider to macOS 2024-06-07 19:17:14 +02:00
WerWolv
348fe27a3c impr: Added small moon icon to the welcome screen of nightly builds 2024-06-05 22:23:43 +02:00
WerWolv
cf34c4bd95 fix: The font atlas does not own the custom font data 2024-06-01 13:55:06 +02:00
WerWolv
bab1d2e27e fix: Loading custom fonts from paths with unicode characters not working
Fixes #1727
2024-06-01 13:52:41 +02:00
WerWolv
d1b6a21e86 fix: Missing localization 2024-05-31 17:06:18 +02:00
WerWolv
3049590b68 feat: Added full pattern path to hex editor hover tooltip 2024-05-31 17:02:46 +02:00
WerWolv
7a81fa7ac5 fix: Mutliple potential nullptr derefes with shortcuts 2024-05-31 17:02:08 +02:00
WerWolv
0ab200f77f fix: Hex editor popups closing when opening sub-popups 2024-05-30 22:01:18 +02:00
WerWolv
a91e40d731 lang: Fixed typo 2024-05-30 21:49:40 +02:00
WerWolv
a5c250c811 fix: Byte type annotations not being reset correctly 2024-05-30 16:57:28 +02:00
WerWolv
08c2f3fc15 impr: Make window less prone to flickering during resizes on Windows 2024-05-30 16:57:07 +02:00
David Mentler
751eff0edf
impr: Restore native macOS title bar double click gesture in borderless mode (#1689)
### Problem description

#### Problem 1
In borderless mode ImHex disables the standard macOS titlebar rendering
and input processing. As a result double clicking the titlebar does not
trigger the native macOS behavior set in `System Settings -> Desktop &
Dock -> Double-click a window's title bar to [Zoom/Minimize/Do
nothing]`.

#### Problem 2
The ImHex window shows up as blank/transparent when de-minimizing it
from the dock.

#### Problem 3
Widgets experience ghost hover inputs from the past position of the
cursor during live resizing.

### Implementation description
ImGui elements consume input events in the order they are drawn. As a
result by "drawing" an `InvisibleButton` over the content area of the
titlebar we can catch unprocessed clicks in the titlebar area.
Connecting this button's double clicks to the native window is then a
trivial endeavour.

The blank windows was caused by the rendering stack clearing the GL
buffer, but proceeding to draw nothing in it. I have short circuited
this path.

Ghost hover inputs were squelched by consistently moving the ImGui
cursor to `0, 0` during a live resize. The OS will dispatch a cursor
positioning event once the resizing ends, restoring normal behavior.

### Screenshots
N/A

### Additional things
N/A

---------

Co-authored-by: Nik <werwolv98@gmail.com>
2024-05-20 11:27:57 +02:00
WerWolv
a172e89620 fix: Don't restore toolbar items when they're empty 2024-05-20 10:16:14 +02:00
WerWolv
bba4cf9578 impr: Keep a safety backup of the last crash backup around 2024-05-19 23:13:46 +02:00
WerWolv
bfdb9b4019 impr: Allow views to opt out of having their open state saved 2024-05-19 21:51:55 +02:00
WerWolv
bad37d0940 fix: Crash when having path set in user folder settings page 2024-05-19 21:41:18 +02:00
WerWolv
71c1bcde0d feat: Added option to specify max file size to load into memory 2024-05-19 15:10:22 +02:00
SparkyTD
e9b492a287
lang: Added Hungarian translations (#1683)
### Problem description
ImHex didn't support Hungarian :(

### Implementation description
I translated ImHex to Hungarian :)

### Translation Coverage
| Plugin        | Percentage |
|---------------|------------|
| builtin       | 99%        |
| diffing       | 100%       |
| disassembler  | 100%       |
| hashes        | 95%        |
| script_loader | 100%       |
| ui            | 100%       |
| visualizers   | 100%       |
| windows       | 100%       |
| yara_rules    | 100%       |

### Additional Notes
There are four Hungarian "special" characters that fall outside the
default Unicode ranges loaded by ImHex, resulting in them being replaced
with the "�" character. These letters are Ő (U+0150), ő (U+0151), Ű
(U+0170) and ű (U+0171), all included in the Latin Extended-A Unicode
block.

The easy fix for this is to include the "Unicode Latin Extended-A" range
when loading the font glyphs in
[init_tasks.cpp:189](99abc4e78a/plugins/builtin/source/content/init_tasks.cpp (L189)).
This change would also unlock the full character range of Bosnian,
Croatian, Czech, Estonian, Latvian, Lithuanian, Maltese, Polish,
Romanian, Slovak, Slovene and Turkish. I can add the commit to this PR
if maintainers are okay with it. **EDIT:** Added a commit that loads
Latin Extended-A by default.

Also note that some words are longer than their English counterparts,
resulting in certain UI labels overflowing from their parent containers,
and being cut off. I might change some of the longer labels to be more
compact in the future, but the container size limitations will have to
be addressed eventually (e.g. with horizontal scrollbars).

---------

Co-authored-by: Nik <werwolv98@gmail.com>
2024-05-19 14:33:33 +02:00
WerWolv
d5eb6b5bbc impr: Added data size widget 2024-05-19 10:21:54 +02:00
WerWolv
1e48277566 impr: Removed [Project] prefix from recent project entries 2024-05-19 10:21:30 +02:00
WerWolv
ec748f4a64 impr: Allow full magic analysis, removed unidentified data from magic report 2024-05-19 10:21:02 +02:00
WerWolv
f0e135530a impr: Add warning about using fractional scaling with default font 2024-05-18 20:32:57 +02:00
WerWolv
d078f9d847 fix: Icon size being off when using fractional scaling with default font 2024-05-18 19:39:29 +02:00
WerWolv
1d6676f059 fix: Empty tooltip showing when hovering over search bar in welcome screen 2024-05-18 11:58:25 +02:00
WerWolv
22e717d778 fix: Don't capture the editor pointer by reference 2024-05-17 23:19:28 +02:00
WerWolv
2546c042dc fix: Crash when clicking on Advanced search in find popup 2024-05-17 23:16:49 +02:00
WerWolv
2f7c2e79d2 impr: Remove ugly dark edges around light theme backdrop image 2024-05-17 22:18:44 +02:00
WerWolv
2ed5381f5a impr: Make menu bar items collapse less quickly 2024-05-17 22:14:15 +02:00
WerWolv
964d98dd7b impr: Remove frame borders in more cases 2024-05-17 22:05:32 +02:00
WerWolv
0571dae9b7 impr: Added frame borders in light theme 2024-05-17 21:58:16 +02:00
WerWolv
563bf78f03 impr: Allow providers to be closed quicker after being opened 2024-05-17 21:56:43 +02:00
WerWolv
f6953fd829 impr: Merge in script loader structure improvements from python branch 2024-05-17 21:01:35 +02:00
WerWolv
a6277533e8 impr: Better Intel GPU log warning 2024-05-17 09:26:41 +02:00
WerWolv
1426424899 fix: Window scaling defaulting to 1.0x instead of Native 2024-05-17 09:26:28 +02:00
WerWolv
d90a04990b fix: Section button tooltips being visible even when not hovering buttons 2024-05-15 18:31:27 +02:00
WerWolv
027ff793ed fix: Icon text input boxes being wider than expected 2024-05-15 18:27:09 +02:00
WerWolv
ca17054a1e impr: Store settings and achievements immediately 2024-05-15 18:27:09 +02:00
WerWolv
add94c5926 fix: Loading of custom data processor nodes 2024-05-12 23:19:39 +02:00
WerWolv
a239edc759 fix: Locking layout not working correctly 2024-05-12 23:19:29 +02:00
iTrooz
240bb299f0
fix: Fix CI failure with ImGui::SetTooltip() (#1672) 2024-05-11 21:52:33 +02:00
SparkyTD
09bffb6745
impr: Add a link to the "Find" view in the search popup (#1665)
### Problem description
This PR adds a shortcut link on the Search (Ctrl+F) popup to the more
advanced "Find" view that is normally accessible at the `View > Find`
menu.

### Implementation description
I added a simple `ImGuiExt::IconHyperlink` link to the `draw()` function
of the `PopupFind` class to display the hyperlink. Clicking the link
will open the Find view, bring it into focus and close the current
popup.

### Screenshots
Before:

![image](https://github.com/WerWolv/ImHex/assets/45818400/0961f594-0548-426a-8622-20093d4a165e)

After:

![image](https://github.com/WerWolv/ImHex/assets/45818400/d40d78f4-1a5d-4bf6-97a4-ff7ab40d0cef)


### Additional things
- Localization keys were added to all .json files, but only `en_US` is
populated for now.
2024-05-11 10:15:17 +02:00
SparkyTD
3c91cb09e3
fix: Crash caused by missing ImGui::BeginDisabled() (#1667)
### Problem description
Merging my previous PRs, #1660 and #1658 has resulted in a conflict
causing an application crash due to a missing `ImGui::BeginDisabled();`
in the `PopupSelect` class. Specifically, none of the code related to
offset validation made it into the final merge. This PR fixes the crash
by reintroducing the deleted lines.

### Additional things
The nightly release build seems to be unaffected by the crash, most
likely because ImGui's `DisabledStack` assertions are only enforced in
Debug mode. The offset validation was still missing before this fix.
2024-05-11 00:52:43 +02:00
WerWolv
881a379fb4 fix: Compile error due to un-unpacked expected value 2024-05-10 23:02:39 +02:00
WerWolv
90a67af887 impr: Added better error messages to intel hex and motorola srec providers 2024-05-10 23:01:36 +02:00
WerWolv
d727100304 impr: Added tooltips for section view and export buttons 2024-05-10 22:54:55 +02:00
WerWolv
543fcf5447 impr: Make in variable values persistent between parser runs again 2024-05-10 22:51:53 +02:00
WerWolv
e9b140b75c impr: Make out variable values selectable and copyable in pattern editor 2024-05-10 22:41:12 +02:00
WerWolv
8fae55487a fix: Closing providers not clearing selection correctly 2024-05-10 22:10:59 +02:00
SparkyTD
973af4650c
impr: Convert all hex editor popups to floating, movable windows (#1658)
### Problem description
In previous versions of ImHex, all tool windows were implemented as
static popups fixed in the upper left position of the hex view. This PR
refactors all tool popups to use floating windows that can be dragged
around by the user, or closed with a dedicated close button on the title
bar. These popup also support a stylable transparency when the user is
not hovering their mouse over the window.

### Implementation description
I rewrote the logic in `ViewHexEditor::drawPopup()` to use a custom
`ImGuiExt::BeginHoveringPopup` function for rendering the popup windows.
This new function is an almost exact replica of the built-in
`ImGui::BeginPopupModal`, except it does also displays the default
window title bar with a close button.

A second custom function, `ImGuiExt::PopupTitleBarButton` was also added
for rendering small icon-based buttons into the title bar of the parent
popup window. This new function was used to implement an optional
"Pinning" feature that individual popup implementations can specify. If
a window is pinned, it won't close automatically when its main action is
executed. For example, the "Select" button on the Select dialog will
close the popup by default, unless the window is pinned.

### Screenshots
Popup dialogs before:

![image](https://github.com/WerWolv/ImHex/assets/45818400/7c253181-8284-4076-a066-089403554f0f)

Popup dialogs after:


https://github.com/WerWolv/ImHex/assets/45818400/99d1a628-8ac1-40ac-9146-9062091bb0db



### Additional things
- When the user stops hovering their mouse over a popup window, it
becomes semi-transparent, making it easier to see the content behind it
- This PR also introduces the `styles.imhex.popup-alpha` style, making
the transparency effect configurable, including the ability to disable
the effect completely by setting `popup-alpha` to `1.0`.
- Fixed a bug that caused some popup windows to ignore the Enter and the
KeypadEnter keys. With this PR, all tool windows will execute their main
action when the user presses either one of the two Enter keys, and will
also close automatically unless the window is pinned.

### Possible changes and improvements
- Should the transparency effect be disabled if a window is pinned?
- Should the transparency factor be modifiable on the Settings/Interface
page?
- A keyboard shortcut could be added for quickly pinning / unpinning the
current window.
- Can the pin icon stay on the left, or should it be moved next to the
close button, with a similar circular background?

---------

Co-authored-by: WerWolv <werwolv98@gmail.com>
2024-05-10 21:21:19 +02:00
SparkyTD
5f192d5dc7
impr: Don't move hex editor scroll position when jumping to address that's on-screen (#1660)
### Problem description
This PR offers two improvements:
1) When selecting / jumping to an offset that falls within the current
viewport of the scroll view, the scroll offset will no longer force the
selected byte to the top of the view. Instead, the scroll offset will
only be changed if the selected byte is outside the current view.

2) In case a wrong offset is entered into the Select or Goto dialog
(e.g. and offset beyond EoF), the dialog's button will be disabled.

### Implementation description
For the first change, I modified the logic that recalculates the
`m_scrollPosition ` based on the current byte offset.

For the second change, I added validation logic to both popups to ensure
that the entered offsets are valid (using `provider->getActualSize()`).
In case of the Select popup, I wrapped the button into an
`ImGui::Begin/EndDisabled` to enforce the validation check.
2024-05-10 21:20:10 +02:00
WerWolv
978fa17932 impr: Make accept pattern popup open faster and close correctly 2024-05-08 23:54:09 +02:00
WerWolv
19c02be673 impr: Only store paths with forward slashes in project files
Fixes #1657
2024-05-08 21:30:20 +02:00
SparkyTD
adbcc48de7
fix: Multiple file reload popups stacking on top of each other (#1654)
<!--
Please provide as much information as possible about what your PR aims
to do.
PRs with no description will most likely be closed until more
information is provided.
If you're planing on changing fundamental behaviour or add big new
features, please open a GitHub Issue first before starting to work on
it.
If it's not something big and you still want to contact us about it,
feel free to do so !
-->

### Problem description
This PR aims to address #1645 that caused the built in file provider's
change monitor to trigger the notification popup dialog multiple times
in a row after multiple external file changes.

### Implementation description
I added an additional boolean field
`m_changeEventAcknowledgementPending` that tracks whether there are any
pending or unacknowledged change notification dialogs to prevent further
dialogs from being opened. The flag is only reset to its initial value
once the user has acknowledged the first `PopupQuestion` dialog.

Since the file is reloaded only after the user clicks 'Yes', it is
unnecessary to ensure that only the latest popup is acknowledged.
2024-05-07 23:43:20 +02:00
WerWolv
32a659a477 fix: Command palette losing focus when pressing Alt
Fixes #1651
2024-05-04 21:30:21 +02:00
WerWolv
40c4dbc20e impr: Make main menu bar not collapse completely when there's not enough space 2024-05-04 21:23:18 +02:00
WerWolv
f2b4e49ff3 fix: Crash when loading oobe screen 2024-05-04 19:54:57 +02:00
WerWolv
49987b8793 impr: Indent license information in about page slightly 2024-05-03 21:38:35 +02:00
WerWolv
761bc941a8 impr: Make right click menus open faster 2024-05-01 20:50:35 +02:00
xtex
aa5a3ed080
lang: Refactored langtool, updated chinese translation (#1623)
- Better argument parsing
- Allow processing all language folders at the same time
- Allow an optional reference language when translating
- Save translations on KeyboardInterrupt
- Fixes a ooold input issues by importing readline
(https://github.com/kovidgoyal/kitty/issues/6560)
- Add untranslate mode to remove translations by a key regex

---------

Co-authored-by: Nik <werwolv98@gmail.com>
2024-05-01 20:49:55 +02:00
WerWolv
1df0eea6c6 impr: Added support for SVG loading, improved texture loading API 2024-05-01 20:36:10 +02:00
WerWolv
a685d2e97d impr: Make integer node accept math expressions 2024-04-29 21:20:38 +02:00
WerWolv
df04acc1b9 impr: Allow specifying buffer size in integer to buffer cast node 2024-04-29 21:20:22 +02:00
WerWolv
f510faa1da impr: Make integer, float and buffer visualizers selectable, added more radixes to integer node 2024-04-29 21:19:54 +02:00
WerWolv
3ad2c74519 impr: Make right click menu in data processor feel less sluggish 2024-04-29 20:43:25 +02:00
WerWolv
f847807df5 fix: Buffer display data processor node being way too wide
#1644
2024-04-29 19:48:02 +02:00
WerWolv
3794aa425d feat: Display destination address in goto popup 2024-04-23 23:26:58 +02:00
WerWolv
79e1df1af2 fix: Exporting selection doesn't export last byte 2024-04-23 21:02:16 +02:00
WerWolv
fd61e757f0 impr: Make unsaved changes popup behave more like in other applications 2024-04-23 21:02:16 +02:00
WerWolv
f913cd742f impr: Added new ImHex Banners 2024-04-23 21:02:16 +02:00
WerWolv
e9ebfe36b0 build: Updated ImGui to v1.90.5 2024-04-12 22:56:10 +02:00
WerWolv
43149498cf fix: Main window being hard to resize when bytes are selected in the hex editor view 2024-04-12 22:55:54 +02:00
WerWolv
9de10df90d fix: Store hanging when updating all entries in some cases 2024-04-10 22:52:21 +02:00
WerWolv
5d08499d20 impr: Use sidebar for settings categories instead of tabs 2024-04-10 19:55:37 +02:00
WerWolv
696612385a fix: Use std::ranges::find instead of std::ranges::contains for now 2024-03-29 16:34:01 +01:00
WerWolv
edf047dde8 impr: Cleanup bookmark UI 2024-03-29 15:40:15 +01:00
WerWolv
51010096bb feat: Added provider information to search bar hover tooltip 2024-03-29 15:38:03 +01:00
WerWolv
4e5a7ba483 fix: Closing providers still appearing in the provider list 2024-03-29 15:37:34 +01:00
WerWolv
92803c1536 feat: Added simple insert mode to hex editor 2024-03-29 13:22:28 +01:00
RoboSchmied
cc593fb6c4
fix: Misspelling of Endianness (#1609)
### Problem description
fix 40 typos

### Implementation description
`endianess` => `endianness`

Signed-off-by: RoboSchmied <github@roboschmie.de>
2024-03-28 22:25:28 +01:00
York Waugh
aeabc0c436
lang: Updated Simplified Chinese translation (#1610)
Thank you for an outstanding program! I have updated the Simplified
Chinese translation. Hope you can adopt it.
2024-03-28 22:24:51 +01:00
WerWolv
f084bc4147 fix: View registers causing crashes when being deleted 2024-03-28 22:21:00 +01:00
WerWolv
cb1dcc2c9f impr: Disable achievement popups if tutorial is skipped 2024-03-28 22:15:48 +01:00
WerWolv
8d08ab20ec fix: Added missing ImHex paths to about page 2024-03-26 19:18:34 +01:00
WerWolv
966a780432 impr: Updated contributors list 2024-03-25 21:02:55 +01:00
WerWolv
99abc4e78a fix: Unifont characters being scaled wrongly
Fixes #1616
2024-03-25 20:41:39 +01:00
WerWolv
ce1d581c3f fix: Settings values being uninitialized by default 2024-03-25 20:41:05 +01:00
WerWolv
e984fde966 fix: Crash on some platforms due to empty main menu bar
#1600
2024-03-23 12:26:23 +01:00