This is not completely true, but the changes in the versions 9 and 10 of g++
ABI don't (seem to?) affect wxWidgets, so allow using later versions of the
compiler for building the code using the libraries created using earlier ones.
This allows a bitmap to scale with the size of the wxStaticBitmap control.
Scaling can be controlled to fill the control with or without changing the
bitmaps aspect ratio.
These constants were defined in the middle of the wxKeyCode enum, value-wise,
which made it difficult to end new elements to the enum as they could clash
with the existing ones if they were simply added at the end.
Include wx/defs.h to get wxUSE_DIRDLG value from it, otherwise it could be
undefined, and hence evaluate to 0 (unfortunately without even a warning with
some compilers), if this header was the first wx header to be included.
This symbol can now be predefined to avoid conflicts with mode_t definition in
wx/filefn.h when wxWidgets is used in applications also using another library
which also defines mode_t.
Closes https://github.com/wxWidgets/wxWidgets/pull/165
This symbol was wrongly added to include/wx/msw/setup0.h directly in
075ef6551e, so it didn't work when
cross-compiling from Unix (which doesn't use this file) and would have been
lost after any future modification of include/wx/setup_inc.h where it should
have been added in the first place.
Do this now and also make the check for this symbol in wx/progdlg.h a bit more
readable.
Don't use __STRICT_ANSI__ to determine whether a function is available or not
as its value can be different when building the library and the application,
resulting in mysterious link errors.
Instead use the same approach as in aa30a2f97ade6fe019f2f288917296b009bf4221
and just declare the functions that are available but just not declared in
strict ANSI mode manually.
Closes#15793.
If padding value (stored in m_toolPacking) has been assigned prior to creating the toolbar (with SetToolPacking) then apply this padding to just created toolbar.
Otherwise initialize this variable with current padding retrieved from the toolbar to let GetToolPacking return proper padding value.
Implemented new method MSWSetPadding() to set padding for native toolbar.
Allow automatically converting lower-case letters entered into wxTextCtrl to
upper-case equivalents. Provide generic fallback and implement the method
natively for all the major platforms.
Also update the text sample to show it in action.
Calling Unbind() on another handler from the currently executing handler which
had been bound after (and hence executed before) the handler being unbound
resulted in a crash previously as the iterators used in the loop over all
dynamic event handlers became invalid.
Fix this by storing the dynamic event table entries in a vector instead of a
list (which is also more memory and speed efficient anyhow) and null the
deleted entries instead of removing them to avoid invalidating the iterators
and only really remove them once we finish iterating.
Closes#17229.
This method was confusing and dangerous as it didn't actually initialize the
wxColour object because it didn't set its m_cgColour and so attempting to use
wxColour "initialized" using this method resulted in a crash whenever its
GetPixel(), GetCGColor() or CreateCGColor() methods were called.
Just merge this function with InitCGColorRef() which is the only remaining
place where it's used after rewriting wxColour(NSColor) ctor.
wxColour ctor from NSColor added in b478f24288
didn't work correctly as it didn't initialize wxColour::m_cgColour and so any
attempts to use the colour created by it resulted in an immediate crash (so
the code added in 16671f229a likely didn't work
neither).
It also assumed that the NSColor given to it was always in the RGBA colorspace
and crashed if it wasn't (so 56ebe6dfac fixed
compilation at the price of making the code crash at run-time). Now explicitly
request the RGBA colorspace and leave the colour uninitialized, which is
better than crashing, if it can't be obtained.
After making this ctor safe to use, there is no reason to reproduce its logic
in wxColourDialog and wxFontDialog, so just use it from there.
Also make the ctor explicit as it's a non-trivial operation which shouldn't be
performed implicitly and document that it doesn't take ownership of NSColor,
unlike the similar ctor from CGColorRef.