Commit Graph

433 Commits

Author SHA1 Message Date
WerWolv
e353802e9f impr: Added more OpenGL version information to logs 2025-08-27 23:34:01 +02:00
WerWolv
130055af22 fix: Crash when force-exiting on macOS 2025-08-27 23:33:44 +02:00
Nik
df2448e121 fix: Web version not starting anymore due to WebGL only supporting OpenGL 3.0 2025-08-25 07:29:36 +02:00
WerWolv
254bd88e6b fix: macOS initialising very low OpenGL version by default 2025-08-24 16:10:13 +02:00
WerWolv
5c2309bcf7 fix: OpenGL detection not working correctly 2025-08-23 11:04:41 +02:00
WerWolv
cfe3c5b6df fix: Still do minimum OpenGL version verification 2025-08-20 22:42:04 +02:00
WerWolv
b49e2eeac4 fix: Too new OpenGL version getting requested on Windows 2025-08-20 22:31:40 +02:00
WerWolv
b5bf9f1486 fix: Don't close modals on focus change 2025-08-18 20:49:27 +02:00
WerWolv
b602fcc485 fix: Popups sometimes not opening until clicking on the window again 2025-08-18 20:37:12 +02:00
WerWolv
441dcea705 impr: Cleanup popup creation handling 2025-08-18 20:06:42 +02:00
WerWolv
c5e0951def fix: Crash if platform backend doesn't have GetWindowFocus function defined yet 2025-08-18 20:06:06 +02:00
WerWolv
3c9aa97f6c feat: Added function to show toast messages, moved native error message function to libimhex 2025-08-17 22:46:38 +02:00
WerWolv
cf5b9da45e fix: Disable focus handling on the web version since the GLFW_FOCUSED attribute doesn't work 2025-08-17 20:21:36 +02:00
WerWolv
89b94ebbf9 fix: Buttons near the edges of the Window not reacting correctly to clicks
#2413
2025-08-17 10:33:26 +02:00
WerWolv
8b72ea81c0 fix: More window focus event issues 2025-08-16 16:47:23 +02:00
WerWolv
0ebe4150ae fix: ImHex getting stuck in unlocked FPS mode when some events are blocking 2025-08-15 19:25:25 +02:00
WerWolv
f921742dcc fix: Window not being properly resizable from the top right on Windows 2025-08-15 17:30:23 +02:00
WerWolv
1c54e7e38b fix: Focus loss getting triggered when a popup was selected 2025-08-15 17:29:49 +02:00
WerWolv
165d00dad3 build: Fix more missing includes 2025-08-14 22:22:32 +02:00
WerWolv
babd9584a6 build: Fix a few remaining build errors 2025-08-14 21:58:07 +02:00
WerWolv
fbde2942de build: Refactor ContentRegistry into multiple separate files 2025-08-14 21:22:03 +02:00
WerWolv
d920718b44 build: Refactor ImHexAPI into multiple separate files 2025-08-14 20:16:40 +02:00
WerWolv
4ca429e389 impr: Allow post-processing shaders to be set dynamically 2025-08-14 17:11:37 +02:00
WerWolv
09b2e20a3d impr: Save most of the hex editor settings
#2398
2025-08-11 21:03:18 +02:00
WerWolv
3616c3ad7b fix: Move jthread include 2025-08-10 22:41:06 +02:00
WerWolv
23d673f920 fix: Multiple FreeBSD build and run errors 2025-08-10 22:38:12 +02:00
WerWolv
12785c00bd impr: Condense and modernize data inspector view 2025-08-10 18:25:06 +02:00
WerWolv
5028b354cc impr: Clean up window setup code 2025-08-10 12:34:03 +02:00
kur$
6b4fef806c fix: Added protection against deleting symlinks (#2288)
This PR improves the safety and reliability of the deleteOldFiles()
function by:

Preventing symlink attacks

Uses std::filesystem::canonical() to resolve all paths, eliminating ./..
and symlinks
Verifies each file is actually inside the target directory before
deletion
Safer file operations
Explicitly skips non-regular files (directories/symlinks)

---------

Co-authored-by: Nik <werwolv98@gmail.com>
2025-08-09 19:58:36 +02:00
WerWolv
d925c8216d impr: Allow ImHex to be used without subpixel rendering on Windows if only OpenGL 3 is available 2025-08-09 19:13:45 +02:00
WerWolv
45b08b6010 impr: Enable some of the new ImGui configs 2025-08-09 16:22:07 +02:00
WerWolv
c88fc43032 fix: Crash on exit if update folder doesn't exist 2025-08-09 16:21:51 +02:00
WerWolv
411e971ba7 impr: Properly delete old update files 2025-08-09 14:28:48 +02:00
Ivor Wanders
93a71120d4 fix: Initialise splash window with correct size (#2390)
With an initial Window size of 1 by 1, the program aborts during launch
on my Debian 12 (bookworm) system running the Mate Desktop environment
on X11.


The exception from X is the following:
```
$ ./imhex
[18:36:33] [INFO]  [main | Main]                Welcome to ImHex 1.38.0.WIP!
[18:36:33] [INFO]  [main | Main]                Compiled using commit master@59c6d30
[18:36:33] [INFO]  [main | Main]                Running on Linux 6.1.0-37-amd64 #1 SMP PREEMPT_DYNAMIC Debian 6.1.140-1 (2025-05-22) (x86_64)
[18:36:33] [INFO]  [main | Main]                Linux distribution: Debian GNU/Linux 12 (bookworm). Version: 12
X Error of failed request:  BadWindow (invalid Window parameter)
  Major opcode of failed request:  18 (X_ChangeProperty)
  Resource id in failed request:  0x5400009
  Serial number of failed request:  152
  Current serial number in output stream:  163
```

The culprit is in `hex::init::WindowSplash::initGLFW()`, specifically
the `glfwCreateWindow` call with a window size of 1 by 1, that's the
last call in the ImHex codebase, after that it's libglfw and libX11.

The issue can be worked around by inhibiting the splash screen using the
`IMHEX_SKIP_SPLASH_SCREEN=1` environment variable, setting the window to
be a size larger than 1 by 1 also seems to resolve the situation.

My hunch is that an underflow occurs somewhere with the smaller values,
but I did no further investigation into analysing the root cause.

----
Above the line is the commit message.

### Problem description
See https://github.com/WerWolv/ImHex/issues/2215, which I think is the
same problem, and commit description above. Edit; I did another search
in the issues, I wouldn't be surprised if #2233 is a duplicate of the
2215 issue.

### Implementation description
Please see the commit message.

Analysis was done by setting an X11 error handler, making that throw and
running it in a debugger. This is available in this dev commit;
4a24e16a2ef100a9417e572f6b16c4a95711e94e.

### Screenshots
No apparent glitches if I make the splash window stick around with
`return std::nullopt;` in the `loop()` function. I don't know if there's
an issue at the beginning, but given that the window is set to
transparent before it is created and resized I don't expect any.

Here's a compulsory screenshot of the splash screen over an editor;

<img width="1247" height="666" alt="image"
src="https://github.com/user-attachments/assets/8ce05565-f207-4134-892d-9c074c4c840c"
/>


### Additional things
> Anything else you would like to say

Yes! I don't use ImHex often, but it's really useful when I do, thank
you!
2025-08-09 14:12:22 +02:00
aoqia194
cf87294a8c feat: Add EventViewClosed event (#2377)
Where one door opens, another one closes (said someone) and in this
situation i mean view, because there's no event for closing a view only
opening one, so please add this :c

### Problem description
Simply adds an **EventViewClosed** to match the pre-existing
**EventViewOpened**. Also fixes the issue where EventViewOpened wouldn't
trigger for windows that were popups (even if they are technically a
View.

### Implementation description
I mirrored the current functionality of EventViewOpened for closing.

---------

Co-authored-by: paxcut <53811119+paxcut@users.noreply.github.com>
2025-08-06 22:22:46 +02:00
WerWolv
dda32ef0f9 fix: Build issues due to bad log calls 2025-08-06 20:09:27 +02:00
WerWolv
9cff9043ee impr: Remove hex::format, improve format and logging type safety 2025-08-06 20:02:23 +02:00
WerWolv
baebfe96ba impr: Make banners easier to read 2025-08-05 22:19:04 +02:00
WerWolv
388f5354a1 fix: ImHex being displayed as "Main" in some task managers on Linux 2025-08-05 17:57:26 +02:00
WerWolv
9fc9eb1425 fix: EventViewOpened only getting called for undocked windows 2025-08-03 17:57:46 +02:00
WerWolv
71a39ff2fd build: Remove legacy GL emulation in web build 2025-08-03 17:56:01 +02:00
WerWolv
2db85ced59 fix: High background GPU usage on Windows if window is minimized 2025-08-02 23:35:47 +02:00
WerWolv
b81328ac1a fix: Web build not properly starting up anymore 2025-08-02 23:07:20 +02:00
WerWolv
7b6d5d2686 impr: Cleanup splash screen, make hex highlights look nicer 2025-07-31 20:33:55 +02:00
WerWolv
ac98e4e0b5 fix: Use after free when checking for frame render condition 2025-07-30 22:33:59 +02:00
WerWolv
6fcc3e8cb3 build: Move all demangler uses into the trace library 2025-07-30 20:57:53 +02:00
WerWolv
4c930b190e fix: Last character of font names being missing on Windows 2025-07-30 17:43:45 +02:00
WerWolv
4c89a79dc3 feat: Added full-screen views for use with subcommands in the future 2025-07-30 17:42:56 +02:00
WerWolv
2c3d8d4c0b fix: CppCheck issues 2025-07-30 17:41:45 +02:00
WerWolv
f239b0c6d7 fix: Incorrect progress bar on splash screen 2025-07-28 18:02:33 +02:00