From 81a5bd977b3c3aaba5fe72ae76f07f48a42fa286 Mon Sep 17 00:00:00 2001 From: Seth Hillbrand Date: Sun, 24 Feb 2019 22:13:04 -0800 Subject: [PATCH] Force overlay when building GTK3 GTK3 does not provide the XOR method. We need to force the overlay to draw items in Page Layout editor when moving/dragging --- CMakeLists.txt | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 6c907176e0..c170e76bd5 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -64,7 +64,7 @@ option( USE_WX_GRAPHICS_CONTEXT "Use wxGraphicsContext for rendering (default OFF). Warning, this is experimental" ) option( USE_WX_OVERLAY - "Use wxOverlay: Always ON for MAC (default OFF). Warning, this is experimental" ) + "Use wxOverlay: Always ON for MAC and GTK3 (default OFF)." ) option( KICAD_SCRIPTING "Build the Python scripting support inside KiCad binaries (default ON)." @@ -781,6 +781,10 @@ find_package( wxWidgets ${wxWidgets_REQ_VERSION} COMPONENTS gl aui adv html core # Include wxWidgets macros. include( ${wxWidgets_USE_FILE} ) +# Check for GTK3 libraries - These do not have XOR, so we need overlay (Page layout editor) +if( wxWidgets_LIBRARIES MATCHES "gtk3" ) + add_definitions( -DUSE_WX_OVERLAY ) +endif() if( KICAD_SCRIPTING_WXPYTHON AND NOT KICAD_SCRIPTING_WXPYTHON_PHOENIX ) # wxPython appears to be installed and valid so make sure the headers are available.