Implementation is a hack, using a magic pointer value because just
storing this in wxTextAutoCompleteData is not simple, as any flag added
to it would need to be reset in several different places.
This is not used yet, but will be in the upcoming commits.
The new function has more clear semantics than GetOrCreateCompleter()
which both returned the completer value and set m_autoCompleteData to it
as a side effect. MSWEnsureHasAutoCompleteData() still does the latter,
but returns just a boolean indicating whether it succeeded or failed,
making using it more straightforward.
No real changes.
Make wxAppTraitsBase::GetAssertStackTrace() and reuse it in the assert
handler defined in the test to show more information about the asserts,
especially those failing in worker threads, if possible.
Don't use SetAllowSort() in one class and {Allow,Forbid}Sort() in
another one, both could be fine on their own but not together.
Also simplify code by forbidding sorting only if necessary (and add a
comment explaining why do we do it), which removes the need for
re-allowing it from two different places.
Avoid resorting the tree on each insertion, this results in horrible
performance even with a few thousand items. Instead, sort all the new
items only once at the end.
Catch all the exceptions when processing this event from the keyboard
hook as they must not escape from it and outside of the application.
Closes#19133.
Previously, splitting a string obtained by joining together array
with (any but last) elements ending in the escape character (normally
the backslash), didn't recover the original array because the separator
character following it in the resulting string was considered to be
escaped by wxSplit().
Fix this by escaping the trailing escape character itself.
Add a test confirming that this works as expected now, document this
behaviour and also slightly simplify wxSPlit() logic.
See https://github.com/wxWidgets/wxWidgets/pull/2311Closes#19131.
Just add a call to SetTextColoursAndFont() now that it is present in
this renderer base class (see the parent commit) to ensure that the
correct, i.e. corresponding to the column attribute, colour is used for
the stars.
Send a wxFullScreenEvent when the user enters or exits full screen on
macOS. EnableFullScreenView() has to be used to enable the native
full screen API.
Closes https://github.com/wxWidgets/wxWidgets/pull/2284
As explained in 0a5be41f8a (Avoid using uninitialized static wxString in
wxOSX code, 2021-04-04), the usual "auto&" can't be used to iterate over
wxString and modify its contents because of proxy-like nature of
wxUniCharRef returned by wxString iterators.
But using "auto&&" as that commit did wasn't especially clear (even with
the explanations in the commit message) and gave -Wrange-loop-analysis
when using clang.
So replace it with "wxUniCharRef", which should be both more clear (it
is a value, which is still a bit confusing, but its name hopefully
indicates that it's also some kind of a reference) and warning-free.
Emulate a 1-pixel pen width as closely as possible.
This reverts:
334cf1cc91 (Take HiDPI scale into account for wxGCDC 0-width pen, 2021-04-03)
0d80050057 (Make wxGCDC behavior with 0-width wxPen consistent with MSW wxDC, 2021-03-02)
See #19077, #19115
Python package hosting seems to randomly decide which version of the
package to return to pip running under Trusty: in addition to werkzeug
(see last commit), the version of flask has spontaneously changed from
1.0 to 1.2 in the latest build too.
Just hardcode the versions of all dependencies in the last successful
build and hope they keep working for longer than a day.
Crazily, pip installs seem to be non-deterministic as installing httpbin
in https://travis-ci.org/github/wxWidgets/wxWidgets/jobs/765946720
pulled in werkzeug 0.16.1 which works with Python 3.4, but doing it
again tries to use werkzeug 1.x which isn't.
Fix the version explicitly to work around this.
Trying to use Python 2 under Trusty is hopeless, as pythonhosted.org has
already started dropping support for non-SNI clients and will drop it
completely soon, see https://status.python.org/incidents/hzmjhqsdjqgb
and https://github.com/pypa/pypi-support/issues/978, and SNI is not
available in the system Python 2 version (2.7.6, which is less than
2.7.9 in which it was added).
Note that we still can't use Python 3 everywhere as long as we have
macOS 11 builds as it's not available there.
Replace it with a private DoRefreshLabels() and call it ourselves from
SetMenuPathStyle() to make the class simpler (and less error-prone, as
it's now impossible to forget to call RefreshLabels() any more) to use.
It seems useful to have the word "Path" in the name of this enum to
indicate that it applies to the paths shown in the menu labels.
Also rename the methods using this enum.