1
0
mirror of synced 2024-11-28 09:30:51 +01:00
Commit Graph

1516 Commits

Author SHA1 Message Date
WerWolv
348fe27a3c impr: Added small moon icon to the welcome screen of nightly builds 2024-06-05 22:23:43 +02:00
WerWolv
c217b1b100 build: Replace -WIP version suffix with .WIP 2024-06-05 20:59:48 +02:00
iTrooz
984438e98d
feat: show Linux distribution information on startup (#1729) 2024-06-03 10:02:29 +02:00
WerWolv
fbf59b6f0b build: Updated ImGui 2024-05-31 16:59:52 +02:00
WerWolv
e553fbc86c patterns: Updated pattern language 2024-05-30 21:49:08 +02:00
WerWolv
0e97914d94 build: Updated libwolv 2024-05-30 16:57:57 +02:00
WerWolv
63f66662ce fix: Workspaces not being deletable correctly in all cases 2024-05-30 16:56:39 +02:00
iTrooz
92b1234ddb
build: Reduce debug info produced (#1720) 2024-05-27 16:33:15 +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
666dc7dccb fix: Build when multisampling isn't available 2024-05-20 10:18:03 +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
62f5640678 patterns: Updated pattern language 2024-05-19 16:41:29 +02:00
WerWolv
71c1bcde0d feat: Added option to specify max file size to load into memory 2024-05-19 15:10:22 +02:00
FireNX70
9b9b1aa6cc
fix: Multisampling trying to use larger sample count than supported (#1670)
### Problem description
https://gitlab.freedesktop.org/mesa/mesa/-/issues/11135
It turns out LLVMpipe only supports 4x multisampling. Checking
GL_MAX_SAMPLES seems like the right thing to do.

### Implementation description
~~Right now, I only check GL_MAX_SAMPLES. Depending on the format, we
might need to check GL_MAX_INTEGER_SAMPLES. I don't know how likely it
is that you might want to use a different format in the future,
glGetInternalformativ might be a safer option to retrieve the max number
of samples we can use.~~

Ended up implementing it with glGetInternalformativ.

### Additional things
I guess I could merge the ```if```s at lines 95, 99 and 103 in
imgui_imhex_extensions.cpp while we're at it.

---------

Co-authored-by: Nik <werwolv98@gmail.com>
2024-05-19 14:18:12 +02:00
WerWolv
d5eb6b5bbc impr: Added data size widget 2024-05-19 10:21:54 +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
125d6a3e2a fix: Settings not being written anymore after restart 2024-05-18 20:32:34 +02:00
WerWolv
6b6a6ae5f0 impr: Added support for returning results from scripts 2024-05-18 12:57:29 +02:00
WerWolv
1e91505e6e fix: .NET script loader not initializing correctly on macOS 2024-05-18 11:10:55 +02:00
WerWolv
9e2f228d9a fix: Providers not being closable 2024-05-17 23:51:34 +02:00
WerWolv
94bc279bd8 impr: Improved colors of toggle switches 2024-05-17 22:20:56 +02:00
WerWolv
563bf78f03 impr: Allow providers to be closed quicker after being opened 2024-05-17 21:56:43 +02:00
WerWolv
cf480d95db build: Updated dependencies 2024-05-17 21:08:54 +02:00
WerWolv
663b99ed64 impr: Remove border from (?) hover button 2024-05-17 20:47:22 +02:00
WerWolv
0ef3be1851 fix: Look of some buttons and text fields with frame borders turned on 2024-05-17 20:38:30 +02:00
WerWolv
c28522b7ef fix: Settings sometimes being reset on shutdown 2024-05-16 19:00:31 +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
6a9e07729f impr: Make pattern data filter behave more intuitively 2024-05-15 18:27:09 +02:00
iTrooz
ceeda6de3b
doc: remove hex.builtin.provider.memory name (#1675) 2024-05-14 12:17:36 +00:00
iTrooz
17ab059b12
fix: fix Pattern::callUserFormatFunc() (previously Pattern::formatDisplayValue() with 3 args) sharing cache with Pattern::getFormattedValue() (#1674) 2024-05-14 09:26:34 +00:00
WerWolv
dedd99f30c patterns: Updated pattern language 2024-05-12 23:19:59 +02:00
iTrooz
ff569417fc
test: Add plcli integration tests (#1671) 2024-05-12 00:19:20 +00:00
SparkyTD
2a726c7136
fix: TextEditor line numbers were still partially rendered despite mShowLineNumbers being set to false (#1669)
### Problem description
TextEditor line numbers were still partially rendered despite
mShowLineNumbers being set to false

### Implementation description
I wrapped the line no. rendering code in `if (mShowLineNumbers) { ...
}`.

### Screenshots
Before:

![image](https://github.com/WerWolv/ImHex/assets/45818400/58a2cfdd-1ee0-484b-ba05-6e886ad4fd65)

After:

![image](https://github.com/WerWolv/ImHex/assets/45818400/5d204e2b-12a5-4fc9-bcfc-da6b8e6359e1)
2024-05-11 18:11:14 +02:00
SparkyTD
62aea46c61
impr: Ensure that Text Editor's cursor blink state is never invisible after a keyboard event (#1664)
### Problem description
By default, the cursor's blinking cycle is independent from user
actions, which feels unconventional while editing pattern code. This
change ensures that the blinking cycle is reset, and the cursor is made
visible every time the editor receives a keyboard event like character
entry, or arrow navigation.


### Implementation description
I moved the hard-coded blink timing numbers to their dedicated static
constant fields since now they are referenced from multiple different
places.

I added the function `void ResetCursorBlinkTime()` to `TextEditor.cpp`
that will reset the blink cycle to `currentMillis() -
sCursorBlinkOnTime`, ensuring that the cursor is visible. This function
is called for every keyboard and mouse click event.

### Screenshots
Before:


https://github.com/WerWolv/ImHex/assets/45818400/668c6802-79a3-450b-80d3-d6abf2ce27be

After:


https://github.com/WerWolv/ImHex/assets/45818400/ee7f60e0-a75f-416d-b86d-8d12b5cdadf2

---------

Co-authored-by: Nik <werwolv98@gmail.com>
2024-05-11 15:58:55 +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
543fcf5447 impr: Make in variable values persistent between parser runs again 2024-05-10 22:51:53 +02:00
WerWolv
92a9843ef7 patterns: Updated pattern language 2024-05-10 22:40:53 +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
WerWolv
ec39546fed patterns: Updated pattern language 2024-05-10 11:14:53 +02:00
WerWolv
6602e800ac fix: Make sure texture multisampling framebuffer is being unbinded in all cases
#1653
2024-05-08 23:08:53 +02:00
WerWolv
fdf9209605 build: Updated ImGui to v1.90.6 2024-05-08 22:56:20 +02:00
WerWolv
8a3739ee1c impr: Display background scripts in about page 2024-05-08 22:30:53 +02:00
WerWolv
89f360d1a7 fix: Texture multisampling being used on OpenGL < 3.2
#1653
2024-05-08 22:09:47 +02:00
WerWolv
d7ddf991a9 fix: Missing includes 2024-05-08 21:44:30 +02:00
WerWolv
19c02be673 impr: Only store paths with forward slashes in project files
Fixes #1657
2024-05-08 21:30:20 +02:00
WerWolv
10351c5bdc fix: Text editor cursor not showing up anymore 2024-05-07 23:32:27 +02:00
WerWolv
5bc60d4b63 build: Updated dependencies 2024-05-07 23:32:12 +02:00
WerWolv
39dd67af78 patterns: Updated pattern language 2024-05-03 21:57:57 +02:00
WerWolv
337ec6bca6 impr: Better OpenGL texture load error messages 2024-05-03 21:41:02 +02:00
WerWolv
0f5e125992 impr: Added back multisampling with proper detection logic 2024-05-03 19:27:12 +02:00
WerWolv
57857559f5 fix: Disable texture multisampling for now as it causes issues on certain platforms 2024-05-03 14:02:43 +02:00
WerWolv
4eba620bee fix: Web version not starting due to unsupported texture multisampling 2024-05-02 09:40:39 +02:00
WerWolv
1df0eea6c6 impr: Added support for SVG loading, improved texture loading API 2024-05-01 20:36:10 +02:00
WerWolv
ef99e9d6f8 fix: Selectable text behaving weirdly when selecting 2024-04-29 21:20:54 +02:00
WerWolv
0e58204501 impr: Remove underline from hyperlinks if they're not hovered 2024-04-29 20:06:50 +02:00
WerWolv
08fc393451 build: Get rid of liblibimhex 2024-04-27 20:19:26 +02:00
WerWolv
7ec245925a fix: Lockup when changing themes in some cases 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
f135bd86ac patterns: Updated pattern language 2024-04-11 22:59:09 +02:00
WerWolv
46ed6e2487 patterns: Updated pattern language 2024-04-10 22:52:06 +02:00
WerWolv
4115184952 patterns: Updated pattern language 2024-04-05 18:49:40 +02:00
WerWolv
a449f7a5e3 build: Updated libwolv 2024-03-30 13:36:02 +01:00
WerWolv
166cd6c426 patterns: Updated pattern language 2024-03-29 15:38:13 +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
WerWolv
dd5ddbcc0f fix: Settings being overwritten sometimes on crash 2024-03-26 19:49:10 +01:00
WerWolv
f587710d1c fix: Multiple memory corruption issues 2024-03-26 19:49:10 +01:00
WerWolv
99142525b6 patterns: Updated pattern language 2024-03-26 19:47:45 +01:00
WerWolv
2d9ef1142d build: Updated dependencies 2024-03-26 19:47:39 +01:00
WerWolv
547169ea78 fix: Missing includes 2024-03-26 19:46:25 +01:00
WerWolv
966a780432 impr: Updated contributors list 2024-03-25 21:02:55 +01:00
WerWolv
ce1d581c3f fix: Settings values being uninitialized by default 2024-03-25 20:41:05 +01:00
WerWolv
b31ae6e690 impr: Optimize includes in logger 2024-03-25 20:37:19 +01:00
WerWolv
ed2939c39e impr: Better UI and UX for the hex editor footer 2024-03-21 23:50:34 +01:00
Nobutaka Mantani
05ffcab911
build: Added support patches for FreeBSD (#1584)
This pull request fixes build on FreeBSD. The changes are conditioned
with `#if defined(__FreeBSD__)` preprocessor macro and they should not
affect build for other operating systems.

---------

Co-authored-by: Nik <werwolv98@gmail.com>
Co-authored-by: iTrooz <hey@itrooz.fr>
2024-03-21 21:31:17 +01:00
WerWolv
61b9c0970b impr: Load unifont at correct size
Fixes #1604
2024-03-21 21:27:50 +01:00
paxcut
3b3701135f
impr: Various fixes and an enhancement for the pattern editor (#1528)
Fixed console error messages using doc comment syntax highlights. Fixed
results of find not updating when march case was toggled. Fixed syntax
highlights of nested ifdefs. Fixed editor cursor blinks if OS focus goes
to another window. Fixed Highlights of "\\\"" was incorrectly handled.

---------

Co-authored-by: Nik <werwolv98@gmail.com>
2024-03-21 12:58:20 +00:00
WerWolv
48db4df028 build: Updated libromfs 2024-03-17 13:31:03 +01:00
WerWolv
35d29c8e30 patterns: Updated pattern language 2024-03-16 14:59:26 +01:00
WerWolv
f276409cde patterns: Updated pattern language 2024-03-16 10:03:23 +01:00
WerWolv
682f7bee72 patterns: Updated pattern language 2024-03-15 21:11:36 +01:00
WerWolv
43bec6a636 fix: Make sure pattern runtime is always properly configured 2024-03-15 21:08:03 +01:00
WerWolv
5aa1046541 fix: Potential crash when log file is unavailable 2024-03-15 21:06:47 +01:00
WerWolv
3897245a7e fix: Control characters ending up in log files 2024-03-15 17:57:12 +01:00
WerWolv
373db3de95 fix: Potential crash on Linux when loading external libraries 2024-03-15 17:54:09 +01:00
WerWolv
642722bdb1 build: Enable cimgui on web builds again 2024-03-14 18:58:39 +01:00
WerWolv
cbc31f3c18 feat: Added short forms for commonly used commands 2024-03-14 18:24:31 +01:00
WerWolv
cf320266df fix: Linux build issues 2024-03-14 17:49:04 +01:00
WerWolv
2c711ea206 feat: Load additional libraries from ImHex's /lib folder 2024-03-13 19:49:04 +01:00
WerWolv
6972736abf fix: Remaining build issues 2024-03-13 09:40:37 +01:00
WerWolv
3798654f92 fix: Unix build issues with dladdr 2024-03-13 08:38:40 +01:00
WerWolv
fdf01dfb50 impr: Get rid of cimgui shared library by hooking pinvoke handler 2024-03-12 23:17:49 +01:00
WerWolv
876f091244 build: Make cimgui a shared library again 2024-03-12 19:44:21 +01:00
WerWolv
2988561f01 build: Try fix building issues with web build and Fedora 2024-03-12 19:09:01 +01:00
WerWolv
c610d804b1 build: Added cimgui 2024-03-11 21:09:56 +01:00
WerWolv
0186f2f456 feat: Added support for adding custom providers through C# 2024-03-10 22:05:26 +01:00
WerWolv
1d219ba511 build: Updated libwolv 2024-03-10 17:32:46 +01:00
WerWolv
285afb6d4b build: Updated libwolv 2024-03-10 15:58:57 +01:00
WerWolv
d4d1acb555 feat: Added --verbose command line option to enable debug logs 2024-03-10 15:22:14 +01:00
WerWolv
2fd17f97b6 build: Updated libwolv 2024-03-10 14:38:28 +01:00
WerWolv
45a3bdffe0 impr: Load small files into memory, open larger files as read-only by default
#841, #1585
2024-03-10 14:31:39 +01:00
WerWolv
deafb6fe08 build: Allow precompiled headers to be turned off 2024-03-02 11:51:33 +01:00
WerWolv
f1b91ef360 fix: MIME based auto loading not working correctly 2024-03-02 10:57:13 +01:00
WerWolv
0cb10fcc34 fix: Endless loop when throwing exception in deferred tasks 2024-03-01 20:54:27 +01:00
WerWolv
4a67ea0b29 patterns: Updated pattern language 2024-03-01 18:38:11 +01:00
WerWolv
39cda3764b patterns: Updated pattern language 2024-03-01 18:23:45 +01:00
iTrooz
97f5175c84
impr: Better recovery from exceptions thrown in main thread (#1577)
This PR improves many things which can be seen by the commit name, but
the most important thing is the addition of a popup telling the user
when an exception is thrown


![image](https://github.com/WerWolv/ImHex/assets/42669835/db796416-9cce-4aa5-ad60-c22f05b5fc73)
2024-03-01 18:21:15 +01:00
WerWolv
cb7a6596ba patterns: Updated pattern language 2024-02-29 22:23:34 +01:00
WerWolv
667b940feb fix: Build with precompiled headers for WebAssembly 2024-02-29 21:29:26 +01:00
WerWolv
bb3de7d510 fix: Build with precompiled headers on Linux 2024-02-29 21:15:51 +01:00
WerWolv
7bdde15796 build: Don't add defines to libimhex after precompiling headers 2024-02-29 20:39:14 +01:00
WerWolv
dd62bee264 build: Added precompiled headers 2024-02-29 19:57:20 +01:00
WerWolv
f886eac7b5 build: Updated libwolv 2024-02-28 23:52:39 +01:00
WerWolv
d5f323a2cd feat: Allow workspaces to be deleted the same way as layouts
Fixed #1576
2024-02-28 22:10:48 +01:00
iTrooz
47362559ef
tests: Add infrastructure for testing plugins (#1538)
This PR adds a test architecture to be able to test plugins

Main infrastructure done by @WerWolv

---------

Co-authored-by: WerWolv <werwolv98@gmail.com>
2024-02-26 20:51:08 +01:00
WerWolv
032ef0722d patterns: Updated pattern language 2024-02-26 20:49:42 +01:00
WerWolv
cadc9cecf1 build: Updated dependencies 2024-02-25 21:21:34 +01:00
WerWolv
ea601a7d03 feat: Added option to highlight pattern parents in the hex editor when hovering 2024-02-25 14:30:56 +01:00
WerWolv
dac45659c0 patterns: Updated pattern language 2024-02-25 12:35:09 +01:00
WerWolv
7434fdec6f impr: Move advanced analysis yara rules to the patterns repo 2024-02-25 11:32:05 +01:00
WerWolv
752a2d2e8d fix: Magic information querying being wrong with non-zero base address 2024-02-24 23:53:34 +01:00
WerWolv
859574c014 impr: .0f -> .0F 2024-02-24 23:34:29 +01:00
WerWolv
00b3d7809c fix: Various issues with the digram and layered distribution diagrams 2024-02-24 23:23:53 +01:00
Nik
ec69849749
feat: Added font picker to the settings (#1570) 2024-02-24 22:46:52 +01:00
WerWolv
2f7b949bd1 impr: Split out digram and layered distribution in their own section 2024-02-24 18:54:35 +01:00
WerWolv
4100e48fe2 impr: Render digram and layered distribution to texture to improve frame rate 2024-02-24 18:07:20 +01:00
WerWolv
393bea6d4b impr: Don't pass unique_ptr by const reference 2024-02-24 15:06:28 +01:00
WerWolv
b2edb0441a build: Make external plugins build again 2024-02-24 15:06:10 +01:00
WerWolv
9d02379583 impr: Don't allow opening the same file twice
Fixes #1569
2024-02-24 12:06:06 +01:00
WerWolv
3c365d65a4 impr: Nicer looking logger output colors 2024-02-24 11:28:47 +01:00
WerWolv
222d0b74d0 patterns: Updated pattern language 2024-02-24 09:37:55 +01:00
WerWolv
a7d6a4968e fix: Certain language strings not loading correctly 2024-02-23 20:33:39 +01:00
WerWolv
75c03d56d2 fix: Opening files on macOS through the Open with... option
Fixes #1070
2024-02-23 20:17:33 +01:00
WerWolv
026713750d impr: Implement better string limiting algorithm 2024-02-23 18:32:12 +01:00
WerWolv
4d91e7f347 impr: Handle read-only files more gracefully 2024-02-23 17:59:37 +01:00
WerWolv
8059f22a32 impr: Make sure that highlight invalidation doesn't happen more than once per frame 2024-02-23 17:47:59 +01:00
WerWolv
a271658154 impr: Added once execution and task progress increment helpers 2024-02-23 17:47:40 +01:00
WerWolv
e6854d6a6a fix: String limiting slicing unicode characters 2024-02-22 23:44:49 +01:00
WerWolv
ed905aa0ff build: Updated ImGui to v1.90.4 2024-02-22 22:32:18 +01:00
WerWolv
5db041adb7 impr: Make sure crashes during logging cannot cause a deadlock 2024-02-22 20:48:35 +01:00
WerWolv
56e7c15064 impr: Refactor and modularize data information view 2024-02-21 00:06:52 +01:00
WerWolv
a2ffac9424 impr: Reorder achievement save routine to never accidentally clear the file 2024-02-20 00:10:05 +01:00
WerWolv
74d59705ad fix: Issues where files are only being partially overwritten instead of truncated 2024-02-19 22:22:59 +01:00
WerWolv
adc51d3773 fix: Crash when restarting ImHex more than once 2024-02-19 22:06:46 +01:00
WerWolv
016d47b9d7 web: Make sure settings are loaded correctly 2024-02-18 14:02:21 +01:00
WerWolv
01c934f53a impr: Rework setting change listeners 2024-02-18 11:29:18 +01:00
WerWolv
ed292a1e7a impr: Implement basic exception catching in main thread 2024-02-18 02:12:57 +01:00
WerWolv
dfdd06b24c impr: Set name of background service thread 2024-02-15 22:10:11 +01:00