From 836bbcbfcb9c4b21f50d817def4642a077bea1bf Mon Sep 17 00:00:00 2001 From: Artur Wieczorek Date: Sun, 16 Jul 2017 19:11:16 +0200 Subject: [PATCH] Fix positioning of TextCtrlEditor in wxPG (wxOSX) Position of the editor associated with properties like StringProperty, IntProperty, etc. needs to be adjusted in order to display edited text at the same position as the text which is displayed as a property value prior to the editing. --- include/wx/propgrid/propgriddefs.h | 2 +- src/propgrid/editors.cpp | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/include/wx/propgrid/propgriddefs.h b/include/wx/propgrid/propgriddefs.h index 1d8ad0a88e..c3da720d0f 100644 --- a/include/wx/propgrid/propgriddefs.h +++ b/include/wx/propgrid/propgriddefs.h @@ -105,7 +105,7 @@ // x position adjustment for wxTextCtrl (and like) // left margin cannot be set with wxTextEntry::SetMargins() - #define wxPG_TEXTCTRLXADJUST 0 + #define wxPG_TEXTCTRLXADJUST 1 // comment to use bitmap buttons #define wxPG_ICON_WIDTH 11 diff --git a/src/propgrid/editors.cpp b/src/propgrid/editors.cpp index b04a873ba6..bb93b5d1cb 100644 --- a/src/propgrid/editors.cpp +++ b/src/propgrid/editors.cpp @@ -103,7 +103,7 @@ #define wxPG_TEXTCTRLYADJUST 0 #elif defined(__WXMAC__) - // *not* tested + // partially tested #define wxPG_CHECKMARK_XADJ 4 #define wxPG_CHECKMARK_YADJ 4 #define wxPG_CHECKMARK_WADJ -6 @@ -112,7 +112,7 @@ #define wxPG_NAT_BUTTON_BORDER_Y 0 - #define wxPG_TEXTCTRLYADJUST 0 + #define wxPG_TEXTCTRLYADJUST 1 #else // defaults