Testing for absence of Alt modifier is wrong as it could be specified for the
events generated by AltGr-letter key combinations (AltGr is Alt+Ctrl), so this
commit broke the validation of any such symbols entered from non-US keyboard.
This is worse than the problem it was trying to fix, so revert this for now.
The real fix will need to ensure that the mnemonics are checked first, i.e.
before generating EVT_CHAR, in wxGTK, just as it already happens in wxMSW.
This reverts r75453.
See #15777.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@75521 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This fixes the build with some versions of MinGW which depend on UNICODE being
defined correctly in _mingw.h which is included from wx/compiler.h, so that
before this change the build was broken as inconsistent definitions of UNICODE
were used there and in windows.h included later.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@75520 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This avoids g++ warning about HAVE_VARIADIC_MACROS redefinition in setup.h if
wx/cpp.h happens to be included before it.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@75519 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
Drawing on a wxBitmap via wxMemoryDC modified its pixmap representation in
wxGTK and even if its pixbuf representation was later changed using direct
access to the bitmap pixels, the out of date pixmap continued to be used,
creating the illusion of direct access being completely ignored.
Fix this by purging the old pixmap representation when locking the bitmap for
raw access.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@75517 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
Typical wxScopedArray initialization uses "new T[n]" expression, allow to omit
most of it and specify just n, the number of elements to allocate.
Use the new shorter form in the places where wxScopedArray(new ...) was used
(which is in almost all of them)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@75504 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
Key events with modifiers shouldn't be filtered by the validator as they are
used as accelerators and not for the text entry at all.
Closes#15777.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@75453 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
Saying that "something is invalid" really doesn't help much at all, so try to
be at least a bit more informative.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@75450 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
Calling wxMenuItem::Check() before appending the item to a menu didn't have
any effect, fix this by checking the item state when actually attaching it.
Closes#15748.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@75448 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
Don't delay the TLW destruction if it has a parent and its parent is already
being deleted: we can't delay the inevitable in this case and only succeed in
making the program crash if we try.
Closes#15743.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@75447 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
The minimal size wasn't respected when auto-sizing rows/columns in
Set{Row,Col}Size() which was called in response to double clicking the
separator line, which resulted in clearly wrong behaviour as the user was
prevented from resizing the row/column to a smaller size by dragging them but
not by double clicking, so fix this to respect the minimal size as well.
Closes#15627.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@75446 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
Update the script generating stc.cpp to put the symbolic constants names and
not their raw numeric values into the generated code. This makes it much
easier to read and understand.
Closes#15783.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@75443 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
The code could crash if m_overflowVisible was true but m_overflowSizerItem was
NULL. Ideally this shouldn't happen in the first place, but it did, so at
least fix the crash for now -- and hopefully this code will be refactored to
make it more clear later.
Closes#15747.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@75400 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
Previously, when reading files with completely nonstandard - but
occurring in the wild thanks to broken Notepad - files with CRCRLF, all
content would be replaced with empty lines.
Fix the code to do what many editors do with such files: treat this as
data line followed by an empty one. This is not ideal, but it is better
than discarding data - and arguably, silently cleaning up the endings
wouldn't be great either (and would add extra complications for what is
an obscure and broken case).
See http://stackoverflow.com/questions/6998506/text-file-with-0d-0d-0a-line-breaks
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@75387 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
Move keyboard focus between columns with Tab and Shift-Tab. Works
similarly to left and right arrows, but wraps around to go to the next
or previous line and doesn't collapse tree nodes.
If focus reaches the last or first cell, the key event is skipped,
allowing normal Tab handling for moving to another control.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@75386 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775