Today I present IDA WaitBoxEx:
A full featured IDA Pro SDK wait box replacement with progress bar and customization options.
Determinate style progress box:
I do a lot of IDA Pro plug-in work so I find fixes and workarounds for some of IDA’s little idiosyncrasies, plus I like to add additional helpful features as I go along.
The worst of the wait box problems is that IDA’s cancel button check function wasBreak() barely works if at all. You want to allow users to cancel your plug-in while in process?..tough luck.
In the past I added various hacks to the old IDA UI like a progress bar to the wait box, a windows hook to solve the unresponsibe “Cancel” button problem, and then modifying some key dialogs to faciliate multiple selections, etc.
When the VCL version was depreciated I really had to sit down and figure out how to properly do the same stuff with the new Qt version.
Now Python already has a setup to make your own Qt dialogs, and there are two C++ official plug-in samples using Qt in the IDA SDK but apparently there are few of us going this route.
This is the first of my plan to release some C/C++ UI customization/facility plug-in projects.
This wait box is a complete replacement for the default one that adds several features and fixes.
1) A “determinate” or “indeterminate” type progress bar.
2) A minimize button.
3) Facilitates Qt CSS style sheets application for customization. Here one can change colors, the font, positions, labels, add texture, etc.
4) Facilitates the changing of the titlebar icon for yet more customization.
5) A Windows 7 style taskbar progress indicator.
6) Low “cancel-check” overhead functionality using an isUpdateTime() method.
1) Fixes the IDA wait box and main window freeze/stall/hangup issue.
2) Wait box works as a direct child of the main window; avoiding the odd separate window you see when you tab/switched the default one.
3) Working “Cancel” button, minimizes the parent window, that instantly responds to user input.
4) The close ‘X’ button is enabled, acting as an alternate to the “Cancel” button.
It’s pretty much the same setup as you would using IDA’s show_wait_box() function:
// Check if cancel pressed, if not update progress
if (WaitBox::updateAndCancelCheck((int) percentage of work done))
There is also a “indeterminate” type too for when you don’t have or don’t care to determine the progress scope:
You can also get some fancy customization using Qt Style Sheets allowing you to change the font, colors, icon, add a background texture , etc.
Here’s an example..au natural:
Since it’s a Visual Studio built library you don’t need the Qt SDK installed to use it; only if want to modify it and rebuild.
Although if you want to do customization where you change the icon or have a background texture then it really helps to have the Qt setup so you can use the Qt resource system.
Example loading the style sheet and icon using the Qt resource setup:
WaitBox::show("Progress", "Please wait..", "url(:/myres/style.qss)", ":/myres/icon.png");
Get the latest source, library, and example plug-in, go here: