Skip to content

feat(ui): added header and margin for print Emails#10932

Merged
wmontwe merged 5 commits intothunderbird:mainfrom
saisafe:print-header-margin
Apr 30, 2026
Merged

feat(ui): added header and margin for print Emails#10932
wmontwe merged 5 commits intothunderbird:mainfrom
saisafe:print-header-margin

Conversation

@saisafe
Copy link
Copy Markdown
Contributor

@saisafe saisafe commented Apr 21, 2026

Summary

Solves #10567
Wrap content in a structured HTML document

PDF Outputs (Final)

a_redacted.pdf
2_redacted.pdf

Pending tasks:

  • Adding Email-ID of sender
  • Removing Hyperlinks

@github-actions

This comment was marked as resolved.

@wmontwe wmontwe added the report: include Include changes in user-facing reports. label Apr 22, 2026
saisafe added 2 commits April 22, 2026 18:41
This worked well stripping Hyperlinks and buttons under <a> HTML tag. I tested this on my Google Activity mail and worked well.
Added "<" ">" checks to subject.
Replaced <$email> in `from:`
Replaced <p> to .page-wrapper with checks
@saisafe
Copy link
Copy Markdown
Contributor Author

saisafe commented Apr 22, 2026

@rafaeltonholo I've tried to make this print Email similar to thunderbird-desktop. Kindly let me know if any changes needed.

@wmontwe
Copy link
Copy Markdown
Member

wmontwe commented Apr 24, 2026

@saisafe Thanks for your contribution. Could you please run ./gradlew spotlessApply and ./gradlew detekt to check for code style and code issues.

@wmontwe wmontwe requested review from wmontwe and removed request for rafaeltonholo April 24, 2026 07:36
@wmontwe wmontwe assigned wmontwe and unassigned rafaeltonholo Apr 24, 2026
@saisafe
Copy link
Copy Markdown
Contributor Author

saisafe commented Apr 25, 2026

I should have read the docs more (and PR notes). Sorry for not catching this.

@wmontwe wmontwe changed the title feat(ui): Added header and margin for print Emails feat(ui): added header and margin for print Emails Apr 29, 2026
Copy link
Copy Markdown
Member

@wmontwe wmontwe left a comment

Choose a reason for hiding this comment

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

Thank you! Way better print results now!

I think the MessageViewFragment is already very large. Could you extract the print related functionality to a dedicated class and inject it instead? This would greatly help!

Copy link
Copy Markdown
Member

@wmontwe wmontwe left a comment

Choose a reason for hiding this comment

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

Thank you!

@wmontwe wmontwe merged commit 37b20c7 into thunderbird:main Apr 30, 2026
16 checks passed
@thunderbird-botmobile thunderbird-botmobile Bot added this to the Thunderbird 20 milestone Apr 30, 2026
@saisafe saisafe deleted the print-header-margin branch April 30, 2026 09:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

report: include Include changes in user-facing reports.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants