1. Scroll by visual lines instead of disassembly lines (see #3604)
Previously whenever a scroll happened, cutter cleared all of the disassembled
lines it had and queried rizin again, even if the scroll was only for one
instruction. This causes two problems:
* All of the lines have to be queried again making scrolling slow.
* Since an instruction can have multiple metadata lines attached to it, it meant
that whenever a user scrolled a single instruction all of the metadata lines
will also be scrolled - making scrolling feel choppy.
To solve this we keep a buffer of "max visible lines * 5" which is filled in as
user scrolls, meaning at first only "max visible lines" are queried from rizin,
if user scrolls upwards the entire "max visible lines" above the current top
instruction is fetched and prepended to our "lines" buffer. Since the previous
lines are still saved - if the user scrolls back down we can just show those
specific lines from our buffer instead of querying again.
Lines are erased from start or end based on scroll direction if the buffer
exceeds the size cap of "max visible lines * 5" The "lines" buffer is fully
cleared if user seeks to some address using some external signal - like the
Visual nav bar at the top (basically seeking using any method other than
directly clicking on the instruction line itself)
2. Adds infinite selection via mouse and keyboard
There was no way in cutter to select more lines than whats currently shown on
screen and there was also no way to select text via keyboard. This is done via
manually handling the selection instead of letting Qt handle it. The selection
is preserved no matter how far user scrolls up or down.
3. Fixes empty space at the bottom of disassembly widget viewport
Whenever "max visible lines" were calculated it didn't account for the fact that
the last line might be partially visible meaning there is not enough space to
display it fully, which created empty space at the bottom
4. Adds a visible/blinking cursor to the disassembly panel
Avoids the issue of not knowing which line we are on, if the line contains
similar text that is highlighted. Also helps to know where selection will start
using physical keys
Regression introduced in 4e53fd64 for the macOS application bundle:
rz_path_set_prefix() is only applied to the core-global RzPath instance,
but the ColorThemeWorker created its own instance, ignoring this
setting.
This led to the message box saying "The Rizin standard themes could not
be found in..." on startup.
* Fix namespace alias DH conflict with OpenSSL typedef
OpenSSL 3.x includes openssl/types.h (via openssl/bn.h pulled in
transitively through rizin headers) which declares:
typedef struct dh_st DH;
This conflicts with the namespace alias:
namespace DH = DisassemblyHelper;
The C++ standard does not allow a namespace alias and a typedef to
share the same identifier in the same declarative region. The compiler
resolves DH as the OpenSSL struct, causing build failures when using
rizin built with SSL support.
Rename the alias from DH to DisHlp to eliminate the collision.
* Limit CPU's width and add tooltips for it
* Add columns displaying asm plugin capabilities
* Handle number of bits of 27 and none
* Fix: make sure that all the values coming to html are escaped
* Use rz_analysis_get_plugins to get the plugin list
* Added support for adding debuginfod servers in InitialOptionsDialog
* added new function applyDwarf to CutterCore
* Added sepearted dialogue under preferences->Analysis->SymbolServers to configure the symbol Servers as a unified approach didn't test for PDB files tested for Dwarf servers
* Resolved changes: added Icons, PreferenceDialog will allways have MainWindow as parent,added MainWindow passing to PreferencesDialog
* fixed icon coloring issue while theme changing for shortcuts and symbol servers
* Added pdb servers to the dialogue
* Add new class `ItemCountLineEdit`
* Create a parent class `AbstractFilterView` for `QuickFilterView` and `ComboQuickFilterView`
* Remove `CutterTreeWidget`
* Add new tab in preferences (`Interface`) for interface related options
* Add the options to hide item count by default or on overflow (saved in config)
* Add the option to hide item count by default or on overflow for an individual view (not saved)
* Decrease height for Header view sections
* Seek to other widgets if the address type matches
* Open the correct widget on undo or redo actions
* Don't seek to the last on Unknown
* Only switch to other widgets from Graph
* Create getSectionAddressAt(RVA addr)
* Remove on_core_seekChanged
* Use virtual address in rz_bin_get_section_at
* Move address == RVA_INVALID check to the correct place
* Fix build due to rzheap as subproject
* Fix build due to RzAsm public struct removal
* Fix build due to move to RzCoreDecodedBytes
* Fix build due to RzBin feature refactor
* Fix build due to RzAnalysis refactor
* Update rizin to latest dev
* Allow sub-register values in tooltips
* Allow previewing non-memory values in brackets
* fix: also check for variables within the brackets
* Move the resolving logic to the DissassemblyHelper::resolveTarget
* Fix: remove the additional DH::Variables filter
* Minor refactoring for TargetFilter enum
* Add filter to resolveTarget
* Add defaults to suppress the warning
* Refactor bracket finding into DisassemblyHelper::findBracketRange
* Use the findBracketRange in DisassemblyGraphView
* Pass correct pos to findBracketRange
* Introduce isValidInputNumValue()
* Pass core to the rz_is_valid_input_num_value
* Check if both values (with and without brackets) are valid
* Only show tooltips during debugging or emulating sessions
---------
Co-authored-by: Premade <128969155+PremadeS@users.noreply.github.com>
* Fix incorrect preview and seek on XREF comment
* Add token nullptr check
* DisassemblerGraphView: Use trimmed() on inst->plainText
* Ignore flags + improve comment
* Use rizin API function for xref comment comparison
* Compare address instead of raw strings + xref config check
* Update rizin to latest stable.
* Remove: use_swift_demangler in `BundledRizin.cmake`
* Remove: `rz_bp` in `BundledRizin.cmake`
* Fix: use sys_path
* Bump `Rizin_VERSION` to 0.9
* Specify parrent window for popups.
Message boxes without parent are almost always a mistake. Such message boxes
* Aren't properly position on top of current window, instead they get placed in the corner of screen possibly away from main window.
* They get treated as separate window by window manager, but they still prevent proper interaction with main window. If you alt tab the message box can get lost, resulting in confusing behavior where you don't know why you can't interact with main window.
* partially revert #3193 - printing the terminal escape sequences directly to text widget causes more issues than the tab problem it tried to fix
* move the conversation to html from command task to the console widget
* add hack converting tab to multiple spaces
This commit adds support for a `topOffset` history (on top of the
rizin-managed history), that keeps track of the offset of the top
instruction in the disassembly widget.
closes#2970
Adds Quick Filter and generic address-based context menu entries to the
existing ClassesWidget. The original ClassesWidget.ui is not used
anymore as the layout is provided by ListDockWidget and only adjusted.
The AddressableItemContextMenu may now also optionally be shown when
there no currently selected item by using
setShowItemContextMenuWithoutAddress(). This is used e.g. to display the
"Create Class" option when nothing is present in the list.
Fixes#2237
Co-authored-by: Tristan Crawford <tristanthtcrawford@gmail.com>
Crash dumps generated with breakpad were not made use of to an extent
that would justify the extra maintenance overhead that it comes with. As
Windows builds have recently been broken by it, now is a good time to
retire it.