mandiant / mandiant/capa

Add adjustable font size for HiDPI monitors for IDA plugin

Open
#2,570 4 comments 0 reactions 0 assignees View on GitHub
enhancement ida-explorer
Dominant language
Python
Stars
6.2k
Forks
726
Avg merge
11d 11h
Merged PRs (30d)
7

Description

### Summary

Add a font option similar to IDA's font adjustment menu.

### Motivation

At the moment, the capa window is rendered within IDA using a fixed font size or the default QFont size (see https://github.com/mandiant/capa/blob/master/capa/ida/plugin/form.py#L421, https://github.com/mandiant/capa/blob/master/capa/ida/plugin/model.py#L137, https://github.com/mandiant/capa/blob/master/capa/ida/plugin/view.py#L185, etc.) This is fine for users on a decently sized 1080p monitors where scaling is a non-issue. However, the font becomes unreadable on higher DPI monitors where some amount of scaling is required.

### Describe alternatives you've considered

At the moment, the current workaround I've been using for a few months now is to manually call `QFont.setPointSize` after every font declaration to a fixed value. This does not scale between resolution and is not ideal. I do not expect a feature where the font size is automatically adjusted of course, but a menu adjusting the size would be preferred at the very least.

## Additional context

Contributor guide

Open the contributing guide

Research direction

Start by reading capa/ida/plugin/form.py around line 421, then inspect the font declarations referenced in model.py around line 137 and view.py around line 185. Trace how the IDA plugin constructs its interface and determine where a font-size control belongs. Done means users can adjust the plugin font size through a menu without manually changing each declaration.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
desktop, reverse-engineering
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.