Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: silent printing default dpi on Windows #41811

Merged
merged 1 commit into from
Apr 11, 2024
Merged

Conversation

codebytere
Copy link
Member

@codebytere codebytere commented Apr 9, 2024

Description of Change

Closes #39179.
Closes #40714.

Fixes an issue on Windows where silent printing resulted in comically tiny renderer output unless the dpi was overridden on the user side. This is fixed by pulling the dpi before calling print and using the printer default unless it's been explicitly overridden by the user. This PR also pulls printing utility functions into a new folder for cleanliness and simplicity.

Tested with https://gist.github.com/053de2471f74277e60fb908aaa3685ff

PDF Sample Before

PDF Sample After

Checklist

Release Notes

Notes: Fixes an issue on Windows where silent printing resulted in comically tiny renderer output.

@codebytere codebytere added semver/patch backwards-compatible bug fixes target/28-x-y PR should also be added to the "28-x-y" branch. target/29-x-y PR should also be added to the "29-x-y" branch. target/30-x-y PR should also be added to the "30-x-y" branch. labels Apr 9, 2024
@electron-cation electron-cation bot added the new-pr 🌱 PR opened in the last 24 hours label Apr 9, 2024
@codebytere codebytere force-pushed the fix-silent-print-dpi-win branch 2 times, most recently from dc34139 to ea727b5 Compare April 10, 2024 09:12
@electron-cation electron-cation bot removed the new-pr 🌱 PR opened in the last 24 hours label Apr 10, 2024
@jkleinsc jkleinsc merged commit db11090 into main Apr 11, 2024
17 checks passed
@jkleinsc jkleinsc deleted the fix-silent-print-dpi-win branch April 11, 2024 23:56
Copy link

release-clerk bot commented Apr 11, 2024

Release Notes Persisted

Fixes an issue on Windows where silent printing resulted in comically tiny renderer output.

@trop
Copy link
Contributor

trop bot commented Apr 11, 2024

I have automatically backported this PR to "29-x-y", please check out #41836

@trop trop bot added in-flight/29-x-y and removed target/29-x-y PR should also be added to the "29-x-y" branch. labels Apr 11, 2024
@trop
Copy link
Contributor

trop bot commented Apr 11, 2024

I have automatically backported this PR to "28-x-y", please check out #41837

@trop
Copy link
Contributor

trop bot commented Apr 11, 2024

I have automatically backported this PR to "30-x-y", please check out #41838

@trop trop bot removed the target/28-x-y PR should also be added to the "28-x-y" branch. label Apr 11, 2024
@trop trop bot added in-flight/30-x-y merged/29-x-y PR was merged to the "29-x-y" branch. merged/30-x-y PR was merged to the "30-x-y" branch. merged/28-x-y PR was merged to the "28-x-y" branch. and removed target/30-x-y PR should also be added to the "30-x-y" branch. in-flight/29-x-y in-flight/30-x-y in-flight/28-x-y labels Apr 11, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
merged/28-x-y PR was merged to the "28-x-y" branch. merged/29-x-y PR was merged to the "29-x-y" branch. merged/30-x-y PR was merged to the "30-x-y" branch. semver/patch backwards-compatible bug fixes
Projects
None yet
2 participants