Commit Graph
260 Commits
Author SHA1 Message Date
Lauri Nurmi 87c1aae252 Fix double negatives used with 'neither'
Replace most 'neither' words introduced after 2b0ee48ef7
(Fix double negatives used with 'neither', 2023-11-25)
with 'either'.

All changes are to comments only.

Closes #24999.
2024-12-11 17:57:46 +01:00
Vadim Zeitlin db9adea6e4 Stop using checkout and other actions for Ubuntu 18.04 CI builds
Even actions/checkout@v3 doesn't work in the container any longer,
because none of JS actions can run on Ubuntu 18.04 which doesn't have a
new enough glibc version any longer, so perform the checkout manually.

Disable ccache for the builds using this OS too for the same reason:
even though we could install ccache itself manually too, we don't have
any easy way to save and restore its cache without this action.

Also disable wxWebRequest tests using httpbin which can't be easily
installed.

The diff to httpbin.sh is best viewed ignoring whitespace-only changes.

(cherry picked from commit 9d1c5b108c)

See #24983.
2024-12-02 01:17:07 +01:00
Vadim Zeitlin 9eda19f643 Merge branch 'samples-vcxproj'
Add MSVC projects for all samples.

See #24937.
2024-11-27 01:08:34 +01:00
Ulrich Telle 57e1c9e1ee Update wxWidgets language database and improve locale matching
This commit improves the best locale match algorithm by prioritizing
closer matches and add many new tests verifying that this works as
expected.

In order to do this, new information had to be added to the language
database, which was extended with it and updated to use the latest
Unicode CLDR data and latest Windows 11 locale list.

Further, add a set of scripts for maintaining the language database up
to date and a GitHub workflow `genlangdb.yml` which can be run manually
to regenerate the wxWidgets language-related source and header files
from the underlying Windows and Unicode data. It produces 2 artifacts:

- wxLanguageDatabaseDist.zip allows to easily update the
  language-related files in the wxWidgets repository by simply copying
  all files.
- the normal workflow log and wxLanguageDatabaseLog.zip allow to check
  all temporary files of the regeneration process and to detect
  potential issues, before the language-related files are actually
  replaced by the new ones.

Finally, fix wxUILocaleImplName::GetPreferredUILanguages: Under Windows
10 and above the Windows API function ::GetUserPreferredUILanguages()
returns only the primary UI language plus US English. Additional
preferred UI languages installed by the user are ignored, so instead of
using this function read the list of user preferred languages from the
Windows registry.

Closes #24855.
2024-11-18 16:46:25 +01:00
Vadim Zeitlin 606abaec97 Build all samples in non-ARM GitHub MSW CI job
We can't do this when targeting ARM because all projects don't have ARM
configurations in them. To add them would require making the same
changes to all the 100+ projects as were done in f825661df1 (Improve
ARM64 support in wxMSW, 2024-06-14) in minimal.vcxproj, which will have
to wait until someone has time to automate it.
2024-11-03 21:34:43 +01:00
Vadim Zeitlin 6323109829 Exclude generated Perl scripts from whitespace checks
App::FatPacker adds a lot of extra whitespace but we don't really care
about it in the generated files, so just skip them in the corresponding
check.
2024-11-03 20:11:44 +01:00
Vadim Zeitlin 7a1bfc4f30 Exit with error if UBSAN detects any failures
By default, UBSAN doesn't stop the program and so the exit code is still
0 even if errors are detected, so set halt_on_error=1 in UBSAN_OPTIONS
to change this.

But also still rerun the tests normally, without halting, to detect all
UB occurrences if there is more than one instance of it.
2024-10-21 21:23:07 +02:00
Vadim Zeitlin 4875fa30b1 Add a CI job using UBSAN
Reuse one of the existing builds to enable UBSAN.
2024-10-20 17:29:24 +02:00
Vadim Zeitlin 8d234aa5e9 Run macOS CI builds using macos-14 GitHub image
"macos-12" one is deprecated and will be removed soon.
2024-10-18 19:37:49 +02:00
Vadim Zeitlin 053eddb48a Install Go 1.21 or later as it is required by go-httpbin
The latest go-httpbin version uses log/slog library only available
starting from this Go version, so ensure that we have it on our
self-hosted runner used for Mac CI builds.
2024-09-05 16:13:10 +02:00
Vadim Zeitlin 8e19550692 Fix wxExecute() tests exclusion in cross-MSW CI job
It would be good to find out which test exactly hangs and, ideally,
understand why does it happen but for now just exclude them as we did
before the CppUnit cleanup in the test.
2024-08-05 13:18:22 +02:00
Jon Kunkee f825661df1 Improve ARM64 support in wxMSW
Add ARM64 and ARM64EC platforms to MSVS projects and solutions.

Improve ARM-related documentation.

Closes #24615.
2024-07-07 01:17:22 +02:00
ali kettab 8567dfd08c Added SelectItemMultiInteractive test case to TreeCtrlTestCase
Selecting multiple items (in wxTreeCtrl with wxTR_MULTIPLE flag) and then
deselecting them by clicking on the current item that is also part of the
selection should deselect everything but the current item without starting
to edit that item.
2024-07-06 20:31:49 +01:00
ali kettab 6bcac8e481 Get rid of CppUnit boilerplate in wxTreeCtrl unit tests
Exclude UI tests dependent on wxUIActionSimulator (i.e. those added with
WXUISIM_TEST), they were previously ignored under wxOSX anyway.

Also, exclude only LabelEdit testcase instead of the entire TreeCtrlTestCase
when running under Wine.
2024-07-06 20:31:48 +01:00
Vadim Zeitlin 3dcec41ed3 Update configure CI jobs to use macOS 12 runners too
See #24684.
2024-07-06 15:28:07 +02:00
Alex Contreras e0509604d4 Update macos-11 runners to macos-12
Github has deprecated macos-11 runners; update to use the oldest
supported runners for CI

Closes #24684.
2024-07-06 15:27:58 +02:00
Vadim Zeitlin 40432a2d0a Try to work around not being able to use Ubuntu 18.04 any more
Set the magic environment variable supposed to allow to still use Node
12 for now.
2024-07-05 01:37:40 +02:00
Blake-Madden 881488b3e5 Check for wxMEMBER_DELETE and __WXFUNCTION__ in code checks
These have modern equivalents.

Closes #24612.
2024-06-16 00:12:41 +02:00
Vadim Zeitlin 6f4f244947 Merge branch 'macos-cursor' of https://github.com/MaartenBent/wxWidgets
Implement loading cursor from macOS resources.

See #24374.
2024-04-08 19:53:57 +02:00
Bryan Petty 72d5cf6ffd Update online docs to use GA4 2024-04-03 08:35:11 -06:00
Maarten Bent a8bc35f6f1 Run test_gui from app bundle
So it is able to find the resources
2024-03-27 20:13:18 +01:00
Vadim Zeitlin ced23e24d6 Work around ASAN crashes with latest Ubuntu 22.04 image
Decrease kernel entropy to work around incompatibility between ASAN and
the latest kernel as recommended in the discussion of
https://github.com/actions/runner-images/issues/9491

This fixes crashes when running configure tests.
2024-03-16 09:55:01 +01:00
Vadim Zeitlin d13aba4bba Revert disk clean up in GitHub Actions CI workflow
This reverts the actual change of db65742dbc (Remove some files on
GitHub Action runner to free up some space, 2024-03-16), while keeping
the "df" command just in case, as we were not really running out of disk
space and the error messages about it were a red herring.

The real problem will be fixed by the next commit.
2024-03-16 09:52:22 +01:00
Vadim Zeitlin db65742dbc Remove some files on GitHub Action runner to free up some space
Our CI jobs constantly fail due to the lack of disk space, so free up
some space by removing unnecessary directories following suggestions at
https://github.com/actions/runner-images/issues/2840
2024-03-16 01:09:53 +01:00
Vadim Zeitlin b03c3416c8 Disable caching in setup-go GitHub Action
The cache is enabled by default but just results in a warning message
when using the action without any actual Go stuff to cache (that we
don't have).

See #23398.
2024-03-13 16:03:00 +01:00
Maarten Bent abaeec23bf Use go-httpbin instead of python httpbin for the tests
Python version is too fragile and gets constantly broken by the changes
in Python ecosystem, so switch to the hopefully more stable Go version.

Closes #23398.
2024-03-13 14:13:51 +01:00
Vadim Zeitlin 8e0c9512ab Update actions/checkout version in all GitHub Actions workflows
Stop using actions using deprecated node 16 and update to the version
using node 20.

See #24270, #24377.
2024-03-13 14:09:35 +01:00
Bill Su 509cc0f2f9 Use node20 instead of deprecated node16 for GitHub Actions CI
This can't be done for Ubuntu 18.04 because its libc version is too old
for node20 to run there.

Update version of all the actions we use to use node20 in them too.

Closes #24377.
2024-03-09 20:26:46 +01:00
Vadim Zeitlin 0352fe1fbd Don't set LD_LIBRARY_PATH for CI workflows
This shouldn't be necessary any longer, after the fix in the grandparent
commit.
2024-01-29 01:20:52 +01:00
Vadim Zeitlin 3de719d68c Don't set LD_LIBRARY_PATH in Mac CI workflow unnecessarily
This variable is not used under macOS anyhow.
2024-01-29 01:20:12 +01:00
Vadim Zeitlin a79759d999 Switch wxMSW 32 bit cross build workflow to Debian Stable
Debian Testing doesn't have 32-bit support any more.
2023-12-31 18:03:22 +01:00
ali kettab 28cf04036d Enable tests using wxUIActionSimulator under wxQt 2023-11-01 01:06:39 +01:00
Vadim Zeitlin c07a1ec718 Check running the GUI test without GUI in Unix CI builds
This just checks that launching a GUI program and not initializing GUI
in it works as expected and, notably, does not crash.
2023-10-24 01:21:22 +02:00
ali kettab b231522fef Enable automatic tests for wxQt running on GitHub
Also build without wxUIActionSimulator support for now as it is currently
broken under wxQt and causes the tests to instantly crash if enabled.
2023-10-10 10:51:26 +01:00
Vadim Zeitlin 6a41d8a486 Relax code style check for NULL
This is fine tuned to allow the string in the last commit to pass this
check, but still generally makes sense too.
2023-10-01 17:05:28 +02:00
Maarten Bent 38504acac6 Don't ignore CMake files for msw clang build in CI 2023-08-24 16:28:39 +02:00
Scott Talbert 8b83e45f0e Check building samples out of tree in a CI job
Fixes: #23722

Closes #23723.
2023-07-21 20:38:37 +02:00
Vadim Zeitlin 2e22666db8 Compile Cocoa control example in Unix "widgets" sample makefile
Previously this was never done, as we couldn't determine if we were
using Cocoa or not at generation time, but we can determine it in the
makefile itself.
2023-07-11 13:40:21 +02:00
Vadim Zeitlin c9c213553a Exclude some bakefiles from Whitespace code check too
Add a couple of .bkl files containing TABs in the embedded make
fragments to the list of files skipped by the whitespace check.
2023-07-11 13:39:13 +02:00
Vadim Zeitlin 78760c3538 Enable -Wextra for the CI builds
Try detecting more warnings that can be useful when building the
library.

Don't use -Wextra with gcc 4.8 which generates several completely
spurious warnings not generated by later compiler versions and which are
not worth fixing/working around.
2023-07-04 02:19:14 +02:00
Vadim Zeitlin fe66c0e38c Exclude a couple of makefile-like files from whitespace checks
It's require to use TAB for indentation in these files.
2023-06-20 15:12:34 +02:00
Vadim Zeitlin 6bba7055aa Exclude descrip.mms files everywhere from the whitespace check
Previously only the top-level one was excluded, but others use TABs too.
2023-06-03 21:07:40 +02:00
Vadim Zeitlin 5f5e5c27dd Merge branch 'keep-on-same-display'
Keep window on the same display when its client size is changed.

See #23533.
2023-05-10 22:45:02 +01:00
Vadim Zeitlin a0e3f1e1ab Use grep instead of fgrep and egrep
The latter are deprecated and shouldn't be used any longer.

No real changes.

Closes #23537.
2023-05-10 23:44:17 +02:00
Vadim Zeitlin 438da9c99a Avoid mis-detecting NULL as part of other identifiers
Tighten the search for NULL in the code style check to avoid flagging
the use of MONITOR_DEFAULTTONULL (Win32 API constant) as violation.
2023-05-08 23:40:51 +01:00
Vadim Zeitlin 544353e940 Add CI build of wxUniv/MSW
As long as this build is still supported, it must be tested, as it was
broken for a long time without anybody noticing.
2023-04-22 16:39:42 +02:00
Vadim Zeitlin a0ea27cccf Restrict check for obsolete macros to C++ code
Only check for the use of NULL in C++ code, not C, for example, where
it still can, and should, be used.

Also allow using "NULL" as part of a larger macro name (where it would
be followed by "_") or at the beginning/end of a string.
2023-04-17 18:33:16 +02:00
Vadim Zeitlin 35c35c235e Remove wxUSE_STL which is not really used any longer
wxString is always based on std::[w]string since 2c0c727f49 (Remove wx
own wxStringImpl implementation, 2022-11-16) and all containers use
standard containers by default too now -- and there is a separate
wxUSE_STD_CONTAINERS for this anyhow.

The only remaining use of wxUSE_STL was as the default value for
wxUSE_STD_STRING_CONV_IN_WXSTRING option, but it's not really needed
for this neither, and this option can just be set to 0 by default.

Also add wxUSE_CHAR_CONV_IN_WXSTRING which can now be set to 0 too to
disable all unwanted implicit conversions (even "safe" ones, to wide
strings, in addition to the unsafe ones to narrow strings that could be
already disabled with wxUSE_UNSAFE_WXSTRING_CONV) to allow people who
don't want to have any implicit conversions at all to do it.

Keep --enable-stl configure option for compatibility, but warn if it is
used to tell people that it is not needed any longer.
2023-04-15 17:22:09 +02:00
Vadim Zeitlin 0964b93ccd Add a CI build using wx implementation of container classes
As long as we support building with wxUSE_STD_CONTAINERS==0, we need to
test that this build still works.
2023-04-10 20:40:00 +01:00
Scott Talbert 04326551fd CI: ignore CircleCI config files from all other CIs
Avoid spurious rebuilds when modifying CircleCI config files.

Closes #23405.
2023-04-04 15:28:34 +02:00