Skip to content

Conversation

alabuzhev
Copy link
Contributor

Summary of the Pull Request

Bold fonts support in GDI engine

References and Relevant Issues

#18919

Detailed Description of the Pull Request / Additional comments

Render SGR1 as bold in 256 and true colors, where "bold is intense" is not applicable.
Implemented by creating 2 extra fonts: bold for 1 and bold italic for 1 + 3.

No non-trivial changes, just extensions.
LOGFONT also supports Underline and StrikeOut, but they seem to be already covered by other means, so no combinatorial explosion of fonts expected.

Validation Steps Performed

PR Checklist

  • Tests added/passed
  • Documentation updated
  • Schema updated (if necessary)

@alabuzhev alabuzhev force-pushed the gh-18919-bold-fonts-support-in-gdi-engine branch from f61ca48 to be4a8eb Compare October 13, 2025 20:53
Copy link
Member

@lhecker lhecker 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 for doing this!

Comment on lines 105 to +108
HFONT _hfont;
HFONT _hfontBold;
HFONT _hfontItalic;
HFONT _hfontBoldItalic;
Copy link
Member

@lhecker lhecker Oct 14, 2025

Choose a reason for hiding this comment

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

I suppose at this point we could consider making this an HFONT[4] array so that we can replace things like the DeleteObject code with loops. FontType could be changed to map the 4 styles to 0-3.

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