Skip to content

settings: expose message_zoom to control web view zoom factor#131

Open
klement wants to merge 1 commit intoakissinger:masterfrom
klement:message-zoom
Open

settings: expose message_zoom to control web view zoom factor#131
klement wants to merge 1 commit intoakissinger:masterfrom
klement:message-zoom

Conversation

@klement
Copy link
Copy Markdown
Contributor

@klement klement commented Apr 10, 2026

Summary

Adds a message_zoom setting (default 1.0) that lets users scale the zoom level of the HTML message viewer and the compose view.

This is useful on HiDPI displays or when the system font size differs from what the web engine assumes.

Usage in config.py:

dodo.settings.message_zoom = 1.5

Test plan

  • Without setting, zoom level unchanged from current behaviour
  • Set message_zoom = 1.5 and verify message text is larger in thread and compose views

The message body and compose panels use QWebEngineView, which renders
CSS pt sizes larger than QFont point sizes in native Qt widgets like
QTreeView — especially on macOS Retina displays. This causes the
message body to appear noticeably larger than the thread list and
header panels even when font sizes match.

Extract the hardcoded setZoomFactor(1.2) into a configurable
message_zoom setting so users can compensate for this discrepancy.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Copy link
Copy Markdown
Collaborator

@laarmen laarmen left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good idea, however I think the documentation needs some work.

Comment thread dodo/settings.py
Retina displays. This means the message body appears bigger than the thread
list and header panels even when the configured font sizes match. Adjust
this factor to compensate — values below 1.0 shrink the web view to better
match the surrounding Qt widgets.
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

issue: most of this isn't relevant for documenting a config knob.

The user doesn't care about QTreeView vs QWebEngineView, they just want to know what will change when they turn this knob in a given direction — that would be the last sentence, except for web view being an implementation detail. You might want to mention instead that this is useful for HTML payloads since they don't necessarily take message_font_size into account.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants