Don't let a page header or footer paint over the page body (PR #26915)

12 views
Skip to first unread message

Gunter Königsman

unread,
Aug 25, 2026, 7:54:40 AM (2 days ago) Aug 25
to wx-...@googlegroups.com, Subscribed

When porting wxWidgets to GTK4 Claude reckons to have found 6 bugs in wxWidgets that hinder samples, example applications or tests from working. To me as a casual outsider the patches look like actually resolving existing bugs. I currently push them as separate pull requests so they can be individually reviewed.

wxHtmlPrintout::RenderPage() renders the body first and then the header and footer through m_RendererHdr, calling

m_RendererHdr.Render(x, y);

which leaves wxHtmlDCRenderer::Render()'s "to" parameter at its INT_MAX default. The header is therefore free to draw the full height of its HTML, not just the header area -- and an HTML background colour drawn by the header covers the body that was rendered underneath it.

Pass the header and footer heights, which RenderPage() already knows, as the bound.

The test renders a page with a body background colour and a header into a wxMemoryDC and checks that a pixel well inside the body still has the body's colour.

(cherry picked from commit 7775a75)


You can view, comment on, or merge this pull request online at:

  https://github.com/wxWidgets/wxWidgets/pull/26915

Commit Summary

  • 4f947fe Don't let a page header or footer paint over the page body

File Changes

(2 files)

Patch Links:


Reply to this email directly, view it on GitHub, or unsubscribe.
Triage notifications, keep track of coding agent tasks and review pull requests on the go with GitHub Mobile for iOS and Android. Download it today!
You are receiving this because you are subscribed to this thread.Message ID: <wxWidgets/wxWidgets/pull/26915@github.com>

VZ

unread,
Aug 26, 2026, 11:11:50 AM (20 hours ago) Aug 26
to wx-...@googlegroups.com, Subscribed
vadz left a comment (wxWidgets/wxWidgets#26915)

This looks good to me too, so I'll merge it soon, thanks.

Please don't use "cherry picked from private commit", this is not useful.


Reply to this email directly, view it on GitHub, or unsubscribe.
Triage notifications, keep track of coding agent tasks and review pull requests on the go with GitHub Mobile for iOS and Android. Download it today!

You are receiving this because you are subscribed to this thread.Message ID: <wxWidgets/wxWidgets/pull/26915/c5427350105@github.com>

VZ

unread,
Aug 26, 2026, 1:29:19 PM (18 hours ago) Aug 26
to wx-...@googlegroups.com, Subscribed

Closed #26915 via 0fbb475.


Reply to this email directly, view it on GitHub, or unsubscribe.
Triage notifications, keep track of coding agent tasks and review pull requests on the go with GitHub Mobile for iOS and Android. Download it today!

You are receiving this because you are subscribed to this thread.Message ID: <wxWidgets/wxWidgets/pull/26915/issue_event/30058102771@github.com>

Reply all
Reply to author
Forward
0 new messages