Commit Graph

368 Commits

Author SHA1 Message Date
utelle
1a4a0eee48 Update German translation of internat sample
See https://github.com/wxWidgets/wxWidgets/pull/2594
2021-11-27 17:44:20 +01:00
Vadim Zeitlin
5216d97f08 Use arch suffix consistently in all directories names
For some reason, we used "vc_x64_lib" as the output directory for the
libraries, but "vc_mswu_x64" as the output directory for the samples.

Place the arch suffix, i.e. "_x64" part, always after the compiler
prefix (possibly including version), for consistency with both the
library output directories and with MSBuild project files, as
build/msw/wx_setup.props uses $(wxCompilerPrefix)$(wxArchSuffix)_...
as wxIntRootDir value.
2021-08-26 23:12:40 +02:00
Vadim Zeitlin
e307945170 Merge branch 'ui-locale'
Add wxUILocale class providing functionality which can be implemented
portably for all major platforms, including macOS, and doesn't force
the change of the global C locale, unlike wxLocale.

See https://github.com/wxWidgets/wxWidgets/pull/2464
2021-08-26 15:49:57 +02:00
Vadim Zeitlin
9205209099 Demonstrate the thousands separator in internat sample too
Use a number > 1000 to show the difference between the locales.
2021-08-20 23:37:28 +02:00
Vadim Zeitlin
8373b14280 Add a wxGrid with numbers and dates to the internat sample
Show that the numbers and dates in wxGrid use the expected formats.
2021-08-20 23:37:28 +02:00
Vadim Zeitlin
b9cbe6770f Add wxUILocale with minimal functionality
Use it in the sample to show what (little) it can do right now.
2021-08-20 22:02:46 +02:00
Vadim Zeitlin
a69af310ad Use CFBundleLocalizations in internant sample Info.plist only
Remove this bundle key from the generic Info.plist files as it's not
really useful there because none of our samples except "internat" is
localized.

So just add a special Info.plist for this sample and add values
corresponding to all the languages for which we have translations to its
CFBundleLocalizations.
2021-08-15 18:39:34 +02:00
Vadim Zeitlin
81c4fa449b Use CMake-compatible variable names in configure Info.plist files
This will allow reusing them for CMake as well, and is required in order
to be able to do it as CMake variables names are fixed.
2021-08-15 18:39:34 +02:00
Vadim Zeitlin
b12961f992 Display locale information directly in the main sample frame
This is more convenient than having to open the "About" dialog to see
the details of the locale being used.

It also makes it unnecessary to store wxLocale reference in the frame
class, simplifying the sample code.
2021-08-14 19:22:29 +02:00
Vadim Zeitlin
afe04f7c4a Add internat sample command line option to skip the locale dialog
Getting this dialog all the time is annoying when testing, so add
another command line option to set the locale unconditionally.

This commit is best viewed ignoring whitespace-only changes.
2021-08-14 18:55:43 +02:00
Vadim Zeitlin
31677e597d Don't load translations when setting the locale is disabled too
It makes more sense to skip loading the translations too, if the user
decided not to use the current locale.

This commit is best viewed ignoring whitespace-only changes.
2021-08-14 18:55:43 +02:00
Vadim Zeitlin
eb5bffd3ca Stop allowing to select the language in the internat sample
Restrict the choice to using the current system locale or not using it,
as setting any other language doesn't, and can't, work under macOS.
2021-08-14 18:55:43 +02:00
Vadim Zeitlin
4adb58b7ea Add an option to skip changing locale in the internat sample
Show that we can use the translations to the user language even without
changing the locale.
2021-08-14 18:55:43 +02:00
Vadim Zeitlin
e0cd2c637d Use a panel in internat sample to make it look better under MSW
Creating the controls directly on wxFrame is not recommended and looks
ugly under MSW due to the wrong background being used, so add an
intermediate panel.
2021-08-14 18:55:43 +02:00
Vadim Zeitlin
4db5de9cdb Use wxTranslations directly instead of passing by wxLocale
This is slightly more verbose, but more clear and allows to separate the
translations-related part from locale-changing one.
2021-08-14 18:55:43 +02:00
Vadim Zeitlin
7dc6462561 Show using wxNumberFormatter in the internat sample too
This shows that C and UI (or OS) locales can be different.
2021-08-14 18:55:43 +02:00
Vadim Zeitlin
1f74e7cd1b Show more locale-dependent controls in the internat sample
Show that file dialogs, spin and calendar controls also respect the
selected locale conventions.
2021-08-07 18:04:22 +02:00
Vadim Zeitlin
93190d6263 Interpret empty language as "default" in the internat sample
This provides a more convenient way of testing wxLANGUAGE_DEFAULT than
selecting it from the dialog shown on startup.

This commit is best viewed ignoring whitespace-only changes.
2021-08-07 18:04:22 +02:00
Vadim Zeitlin
ebec1ff9f6 Rebake after removing shaped-ld-sh from bakefile
Simply remove the not existent any longer shared-ld-sh from clean
targets in all makefile.

This should have been done in e663d9af2b (Stop using shared-ld wrapper
script under Mac, 2021-07-06).
2021-08-06 21:51:40 +02:00
Vadim Zeitlin
aabfa8806b Show translation from coreutils message catalog string
Actually test using the coreutils catalog, as this was broken for many
years due to using a wrong catalog name and not adding /usr/share/locale
as a search prefix, but went unnoticed.

So add a menu item to show translation of a string in this catalog to
make testing that this works simpler.
2021-06-15 14:43:38 +02:00
Vadim Zeitlin
c880cf9872 Test for USE_COREUTILS_MO in the internat sample
This is more clear than testing for Linux and will allow enabling this
code under other systems later (as there doesn't seem to be any real
reason not to do it under other Unix systems too).

No real changes.
2021-06-15 14:42:48 +02:00
Vadim Zeitlin
bef4ccede4 Remove unnecessary wxLogNull from internat sample
There is no need to suppress wxLog messages from AddCatalog() because it
doesn't log any errors even if the catalog is not found, while tracing
messages (given only if WXTRACE is set) from it can be useful.
2021-06-15 14:32:44 +02:00
redtide
a71b3d2cd6 Update the standard catalog name used in the internat sample
What used to be called "fileutils" is called "coreutils" since many
years now, so use it to demonstrate loading of the standard catalog.

Closes https://github.com/wxWidgets/wxWidgets/pull/2395
2021-06-15 14:21:15 +02:00
Vadim Zeitlin
8b854d2f92 Remove MSVC 7 project files and support for generating them
This compiler is not supported any longer.
2021-04-26 16:24:02 +02:00
Vadim Zeitlin
1dfc18a004 Link with ws2_32.lib rather than obsolete wsock32.lib
Winsock 2 provided by ws2_32.lib is available since 1994, it should be
fine to use it even for wx in 2021.

See #15562.
2021-04-18 22:13:45 +02:00
Vadim Zeitlin
dc5f1711f2 Upgrade version to 3.1.6
Run misc/scripts/inc_release, bakefile_gen and autoconf.
2021-04-14 17:57:27 +02:00
Vadim Zeitlin
e539cb69bb Remove platform-specific translations support
As shown by the fact that no other platform-specific translations were
ever added since the initial version of locale/msw/it.po added way back
in 4d931bcca0 (Translate '&Help' to '&' for italian Windows only,
2005-08-12), this is not especially useful, so just handle this
particular case specially in wxGetStockLabel() and remove support for
platform-specific translations.

This allows to simplify the makefiles and the catalog loading code as
there is no need to deal with the files in subdirectories any more.
2021-02-07 00:06:21 +01:00
Vadim Zeitlin
94ee588e76 Add an almost empty message catalog with Georgian translations
Surprisingly, we had Georgian translations for the internat sample, but
not for wx itself.

Extract a couple of strings that were present in the sample catalog for
the string defined in wx into the main catalog for tidiness.
2021-02-06 14:58:10 +01:00
Vadim Zeitlin
aafed05b12 Use wxGetStockLabel() in internat sample
This allows to reuse "&File" translation already available in wxstd
catalog rather than translating it again in the sample catalogs for all
languages, so remove the now unnecessary translations from them.
2021-02-06 14:58:09 +01:00
Vadim Zeitlin
426a0ed527 Remove HAVE_W32API_H definition and checks
All still supported versions of MinGW/Cygwin provide w32api.h file, so
there is no need to test for it.

This allows to simplify the code, but also remove the definition of
HAVE_W32API_H from bake- and makefiles and this, in turn, allows to get
rid of extra flags in MinGW format entirely, as we don't support gcc
2.95 for which they were originally needed neither.
2020-10-20 01:47:47 +02:00
PB
be7e68605e Remove BCC make and project files 2020-10-13 18:54:01 +02:00
PB
f57f214122 Remove BCC-specific hdrstop pragma from everywhere 2020-10-12 21:58:37 +02:00
Maarten Bent
53a2c8c7fb Rebake after manifest changes 2020-07-31 01:53:43 +02:00
Vadim Zeitlin
d1aa3d5663 Update the version to 3.1.5
This was done by running misc/scripts/inc_release, bakefile_gen and
autoconf.
2020-07-23 16:25:39 +02:00
Vadim Zeitlin
f5001e728c Rebake with bakefile 0.2.12
No real changes, just synchronize with the bakefile release used now.
2020-05-02 17:02:36 +02:00
Vadim Zeitlin
47d881b683 Fix order of -L options in autoconf makefiles
Put linker flags determined by configure after -L$(LIBDIRNAME) option
pointing to the directory containing the libraries being built, to
ensure that we link with these libraries rather than any wx libraries
globally installed in the system, as could be the case since the changes
of ec091c9f2b (Don't override CFLAGS etc in configure-generated
makefile, 2020-02-02).

See #18729.
2020-04-15 02:33:53 +02:00
Maarten Bent
343bd89b63 Rebake after changes 2020-03-27 23:15:03 +01:00
Vadim Zeitlin
ec091c9f2b Don't override CFLAGS etc in configure-generated makefile
CPPFLAGS, CFLAGS, CXXFLAGS and LDFLAGS are supposed to be under
user-control and putting configure-determined options in them broke
something as simple as running "make CXXFLAGS=-Wno-some-extra-warning"
because this overrode the CXXFLAGS set by configure and required for
build.

Improve this by using WX_*FLAGS in the generated makefile and leaving
the user-controlled FLAGS alone. This is still not ideal as running
"configure CFLAGS=-DFOO" and then "make CFLAGS=-DBAR" will define both
FOO and BAR, as configure copies CFLAGS to WX_CFLAGS, and so setting it
on make command line won't override it, as it should, but this should be
a much more rare and also much less severe problem, so we should be able
to live with it for now.

Normally this commit shouldn't result in any user-visible changes, i.e.
it shouldn't break any previously working scenarios and only make some
previously broken ones work.
2020-02-11 23:19:31 +01:00
Maarten Bent
083f4b3c32 Rename manifests to use underscores 2019-12-13 21:44:26 +01:00
Maarten Bent
bed8cd7b52 Rebake after adding DPI awareness option 2019-11-30 22:52:48 +01:00
Vadim Zeitlin
349e73994b Merge branch 'dpi-awareness-option' of https://github.com/MaartenBent/wxWidgets
Add wxUSE_DPI_AWARE_MANIFEST option allowing to choose to use a manifest
specifying per-monitor DPI awareness.

See https://github.com/wxWidgets/wxWidgets/pull/1622
2019-10-30 21:25:45 +01:00
Maarten Bent
a72c9b6dbc Run autoconf and rebake after adding wxUSE_DPI_AWARE_MANIFEST 2019-10-30 00:02:08 +01:00
Vadim Zeitlin
0a02f4c190 Increment version number to 3.1.4
Done by running misc/scripts/inc_release, manually updating version.bkl,
rebaking and rerunning autoconf.

Also a header for the next version to the change log.
2019-10-28 14:11:00 +01:00
Vadim Zeitlin
86fab39ac9 Regenerate MinGW makefiles using response files
This avoids errors due to overflowing MSW command line length when
linking monolithic library.

Closes #18135.
2019-10-06 23:04:21 +02:00
Vadim Zeitlin
96422fde4d Also use wx-translators@wxwidgets.org instead of @wxwindows.org
As with the previous commit, the old email address is not available any
more since a long time, so replace all mentions of it.
2019-04-22 14:14:10 +02:00
Vadim Zeitlin
e1185d8bf0 Increment version number to 3.1.3
Done by running misc/scripts/inc_release, manually updating version.bkl,
rebaking and rerunning autoconf.
2018-12-10 19:06:18 +01:00
Blake Eryx
65827a0572 Remove unnecessary c_str() calls from the samples
Pass wxStrings directly to wxString::Format("%s") and similar
pseudo-vararg functions, there is no need for c_str() there since
wxWidgets 2.9.

Closes https://github.com/wxWidgets/wxWidgets/pull/1009
2018-11-03 22:52:57 +01:00
Blake Eryx
b70ed2d8c8 Remove more wxT() macros from samples
Also use wxString instead of wxChar* strings.

Closes https://github.com/wxWidgets/wxWidgets/pull/950
2018-09-29 17:16:12 +02:00
Blake-Eryx
f58ea62596 Remove (most) occurrences of wxT() macro from the samples
Also replace wxChar* with wxString.

Closes https://github.com/wxWidgets/wxWidgets/pull/945
2018-09-23 01:15:08 +02:00
Vadim Zeitlin
f69dbaa1ae Introduce MSW ARM64 support
This is a preliminary ARM64 platform support for wxWidgets at "it
compiles" stage. This will allow building and testing wxWidgets based
apps for oncoming Windows 10 ARM64.

Requirements:
- Visual Studio 2017 Update 4 or later with Visual C++ compilers and
  libraries for ARM64 component installed

Building:
1. Open command prompt.
2. Change directory to build\msw subfolder.
3. Run "C:\Program Files (x86)\Microsoft Visual
   Studio\2017\Community\VC\Auxiliary\Build\vcvarsamd64_arm64.bat" once.
4. Use `nmake TARGET_CPU=ARM64 ...` to build required flavor of wxWidget
   libraries.

Notes:
1. Building of *.sln/*.vcxproj files does not support ARM64 yet. This
   requires to hardcode Windows SDK to 10.0.15063.0 or later in
   *.vcxproj files, which would render them non-compilable in older
   Visual Studio versions. Microsoft is aware of this issue and is
   planning a fix in the next version of Visual Studio.
2. wxmsw31ud_gl.dll does not build yet. Awaiting Microsoft to deliver
   missing opengl32.lib for ARM64. Please, specify USE_OPENGL=0.

Closes https://github.com/wxWidgets/wxWidgets/pull/923
2018-09-17 22:34:32 +02:00