X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/cf6e951cf203ace5f8cffb91ece08f18f23ccac2..ecd69fb6e90d50981b109a6ea965b0d097988eb0:/src/msw/textctrl.cpp diff --git a/src/msw/textctrl.cpp b/src/msw/textctrl.cpp index 6e285fabad..882a6f60e9 100644 --- a/src/msw/textctrl.cpp +++ b/src/msw/textctrl.cpp @@ -362,6 +362,10 @@ void wxTextCtrl::AdoptAttributesFromHWND() m_windowStyle |= wxTE_READONLY; if (style & ES_WANTRETURN) m_windowStyle |= wxTE_PROCESS_ENTER; + if (style & ES_CENTER) + m_windowStyle |= wxTE_CENTRE; + if (style & ES_RIGHT) + m_windowStyle |= wxTE_RIGHT; } WXDWORD wxTextCtrl::MSWGetStyle(long style, WXDWORD *exstyle) const @@ -410,6 +414,12 @@ WXDWORD wxTextCtrl::MSWGetStyle(long style, WXDWORD *exstyle) const if ( style & wxTE_NOHIDESEL ) msStyle |= ES_NOHIDESEL; + if ( style & wxTE_CENTRE ) + msStyle |= ES_CENTER; + + if ( style & wxTE_RIGHT ) + msStyle |= ES_RIGHT; + return msStyle; }