From f5e0076f043e1c550e633bb38f3b3a07ce7a2e61 Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Thu, 6 Jan 2022 23:45:28 +0100 Subject: [PATCH] Advise to skip wxDPIChangedEvent when handling them in the manual Not skipping them is almost invariably a bug, as shown by the grandparent commit. --- interface/wx/event.h | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/interface/wx/event.h b/interface/wx/event.h index 2744138c18..82106239fd 100644 --- a/interface/wx/event.h +++ b/interface/wx/event.h @@ -3426,6 +3426,11 @@ public: all program windows on the given display if its DPI changes due to a change in the system settings. + If you define an event handler for this event, you should almost always + call @c event.Skip() in it in order to allow the base class handler to + execute, as many controls rely on processing this event in order to update + their appearance when the DPI changes. + Currently this event is generated by wxMSW port if only and only if the MSW application runs under Windows 10 Creators Update (v1703) or later and is marked as being "per-monitor DPI aware", i.e. contains a @c dpiAwareness