Rename a local variable to avoid clashing with the same name in an outer
scope, fixing a warning introduced in f41564a3e2 (Add
wxRegEx::ConvertFromBasic() helper, 2021-06-18).
Restore the use of c_str() replaced with wx_str() in 4dd77dabe8 (Check
for WXREGEX_CONVERT_TO_MB when calling regcomp() too, 2021-07-16), as
it's still necessary when wxUSE_UNICODE_UTF8==1.
Simplify wxComboCtrl code by always using wxPopupTransientWindow if it's
available instead of various platform-specific workarounds that
shouldn't be needed any longer.
See https://github.com/wxWidgets/wxWidgets/pull/2423
Make code more consistent by using the same approach as in the other
places where conversion is necessary in some builds and define temporary
variables for clarity.
Also use wx_str() when the conversion is not necessary rather than
c_str() as this is more efficient and allows to address an existing
FIXME comment.
Define wx_regexec() wrapper so that we can just drop the length if it's
not supported in one place, instead of having to use this ugly macro in
several places.
No real changes.
When using system regex functions in Unicode build, convert to UTF-8 and
not the current locale encoding, as this should work just as well if the
conversion doesn't fail and even better if it would fail when converting
to the current locale encoding because conversion to UTF-8 never does.
Don't prevent the remaining CheckMatch() tests from running if one of
them fails by using CHECK() rather than REQUIRE().
This is a bit awkward and we probably ought to use sections here
instead, but this change is more minimal.
This commit is best viewed ignoring whitespace-only changes.
It's useless to continue with testing the given regex if compiling it
has unexpectedly succeeded, all the rest of the tests will fail anyhow.
Also explain that REQUIRE() can't be used here, which is why we need to
use CHECK() and then check the same condition again before returning to
avoid the temptation to "simplify" things.
buildbot is not used since a long time, so don't bother checking for it
in IsAutomaticTest().
This commit is best viewed ignoring whitespace-only changes.
Move definitions of wxTE_XXX flags that can be used with the controls
other than wxTextCtrl to wx/defs.h, as wxFormBuilder generates code
using them without including wx/textctrl.h, so that this code doesn't
compile.
This was already addressed in 2970f22a89 (Include <wx/textctrl.h> from
<wx/combobox.h> for compatibility., 2012-03-25) for wxComboBox, but it
also happened for wxSpinCtrl, so fix it once and for all by always
defining these styles.
This partially reverts the changes done in c57e33394c ([...] moved
wxTextCtrl-specific stuff from defs.h/event.h to textctrl.h, 2001-07-29)
as it turns out, 20 years later, that this wasn't such a great idea.
See #14132.
Closes#19225.
No real changes, just use RAII wrapper instead of doing manual memory
management in wxMSW printing code.
We still use a raw pointer for m_devMode, but changing this would be
more involved, so leave it be for now.
Use the same scaling function as elsewhere instead of using
ceil/floor().
Provide wxRescaleCoordWithFrom specialization for int to allow using it
with just single coordinates too.
They're probably not that useful in application code, which should just
use wxDPIChangedEvent::Scale() instead, so move them to a private
header instead of making them part of the public API.
This is more concise and less error-prone than multiplying/dividing DPI
values manually.
No real changes except, maybe, in wxSlider code where the rounding was
done differently before for some reason.