Commit graph

75441 commits

Author SHA1 Message Date
Vadim Zeitlin
e4f2b1eaac Clarify description of archive contents in wxMSW binaries docs
Don't say that the directory where the archives are unpacked shouldn't
contain anything else than include and lib directories, as it can/does
contain other files, such as wxwidgets.props.

Closes #24098.

Co-Authored-By: Bill Forster <billforsternz@gmail.com>
2023-11-30 02:43:52 +01:00
Vadim Zeitlin
5318637839 Merge branch 'fix_SVG_premultiply' of https://github.com/teliseo/wxWidgets
Fix wxBitmapBundle::FromSVG(), which renders incorrectly on GTK and add
wxHAS_PREMULTIPLIED_ALPHA to make the code dealing with alpha more clear
and correct.

See #24097.
2023-11-30 02:35:20 +01:00
Lauri Nurmi
2b0ee48ef7 Fix double negatives used with 'neither'
Replace most 'neither' words introduced after 66916c74a3 (Fix double
negatives used with 'neither' in docs and comments, 2022-08-15) with
'either'.

All changes are to comments only.

Closes #24090.
2023-11-30 02:31:42 +01:00
Ian McInerney
97cba7c0ca Restore ToCDouble compatibility with leading spaces/+ and hex
The previous ToCDouble() function accepted leading spaces, a starting +
sign, and hex strings. std::from_chars() does not accept spaces or +,
and requires a special flag to convert hex strings, so handle this
manually to preserve the old behaviour of this function.

This is similar to the changes done for ToCULong() in #24022.

Closes #24089.
2023-11-30 02:29:58 +01:00
Randalphwa
b5fea3cbf6 Fix crash in wxLogGui when wxUSE_LOG_DIALOG==0
This fixes a crash when DoShowMultipleLogMessages() is called with
wxUSE_LOG_DIALOG set to 0. The code after the #else statement gets the
size of the wxArrayString but then instead of accessing that array, it
tried to access the m_aMessages array which is empty, resulting in a
crash in the C runtime. This commit simply gets the strings from the
correct array.

Closes #24087.
2023-11-30 02:24:30 +01:00
Blake-Madden
2c1cdf9c02 Fix typos and repeated words in comments and documentation
Closes #24085.
2023-11-30 02:21:34 +01:00
Stefan Csomor
bcbc31e97f Fix clipping of scrolled windows under macOS Sonoma
We need to use a native clip view for things to behave correctly under
this OS version, otherwise scrollbars can be overdrawn by the window
contents.

Closes #24067.

Closes #24073.
2023-11-30 02:16:04 +01:00
Vadim Zeitlin
8ca312b17c Use RAII helper for cleanup in wxTIFFHandler::SaveFile()
No real changes, just put cleanup code in a single place.
2023-11-30 02:08:49 +01:00
Vadim Zeitlin
70710a7656 Remove unnecessary cast of TIFFClose() return value
It doesn't have any, so explicitly casting it to "void" is useless and
misleading.
2023-11-30 01:59:48 +01:00
BrianDelalex
614135da5b Improve error checking when saving images in TIFF format
Use TIFFFlush() in wxTIFFHandler::SaveFile() in order to check for
success when saving TIFF images, as TIFFClose() doesn't have any error
code to do it.

Closes #23214.

Closes #24072.
2023-11-30 01:58:08 +01:00
Blake-Madden
49ddc51007 Add bullet number and style support to MSW wxTextCtrl
Make bullet style-related functions in wxTextAttr work for the native
(rich) text controls too.

Closes #24069.
2023-11-30 01:53:50 +01:00
taler21
7a1c8d39f8 Fix references to wxEventLoop::YieldFor() in the documentation
It was incorrectly called wxAppConsole::YieldFor() but the function was
moved from wxAppConsole to wxEventLoopBase back in dde19c2180 (second
part of #10320: move wxApp event handling functions to wxEventLoopBase
(in particular move Yield() functions); add backward compatible
redirections to wxApp; update docs; remove global lists wxPendingEvents
and wxPendingEventsLocker, 2009-02-15).

Closes #24095.
2023-11-29 22:16:03 +01:00
Tim Eliseo
06e3e26ead Add checks to BitmapBundle::FromSVG-alpha test to catch lack of SVG premultiply. 2023-11-28 13:36:06 -08:00
Paul Cornett
8cd33455fe Fix generic wxDataViewCtrl drag hint size with GTK
Some WMs initially report incorrect frame extents for the hint window,
then correct it to 0x0 later. This interacts badly with the deferred
show mechanism, causing the hint window height to be much too small.
Issues with TLW decoration sizes can be avoided by setting the client
size rather than the overall size.
2023-11-27 23:27:43 -08:00
Paul Cornett
d2140993de Fix generic wxDataViewCtrl drag hint transparency with GTK
wxGTK requires SetTransparent() be called before Show().
See #24084
2023-11-27 23:08:22 -08:00
Paul Cornett
175237119b Fix wxCheckBox undetermined state showing as checked with some themes
Simplify the code some and ensure that "inconsistent" and "active"
are not set at the same time.
See #24074
2023-11-27 12:51:41 -08:00
Tim Eliseo
d21d54b42f Document new symbol wxHAS_PREMULTIPLIED_ALPHA. 2023-11-27 10:06:47 -08:00
Tim Eliseo
a160e788ae Add test BitmapBundle::FromSVG-alpha to verify SVG alpha premultiply fix.
See #24064.
2023-11-26 13:29:41 -08:00
Tim Eliseo
fce4941404 Add wxHAS_PREMULTIPLIED_ALPHA to abstract if wxBitmap pixels are premultiplied.
All previous relevant platform-specific tests have been changed to use this
symbol. Also, samples/image now premultiplies conditionally, correcting a
visual anomaly on wxGTK.
2023-11-26 13:23:52 -08:00
Tim Eliseo
17c34d41ba Don't premultiply pixels from wxBitmapBundle::FromSVG() on wxGTK.
See #24064.
2023-11-26 13:23:52 -08:00
Paul Cornett
8ea22b5e92 Avoid crash with GTK3 if console program is using a GUI wxApp class
See #24081
2023-11-23 15:12:08 -08:00
Paul Cornett
978fa7ed06 Avoid a few fallthrough warnings 2023-11-23 09:42:59 -08:00
Paul Cornett
4030f3b90c Remove extraneous semicolons 2023-11-23 09:25:03 -08:00
Paul Cornett
222883d98f Avoid Clang -Wcomma warnings
For the few cases that are not trivially avoidable,
use a cast to void to silence the warning.
2023-11-23 09:17:21 -08:00
Paul Cornett
4e679c4649 Fix wxDropSource::GiveFeedback() for Wayland
"configure-event" does not occur for window movement with Wayland,
so use event loop activity as a substitute.
See #24051
2023-11-22 15:56:41 -08:00
Paul Cornett
134e15f8f7 Avoid potential negative width in wxChoice::DoGetSizeFromTextSize() 2023-11-22 14:54:36 -08:00
Paul Cornett
ae7c13a031 Fix wxDropSource::GiveFeedback() with GTK >= 3.20
Also fixes showing the drag icon.
Note that feedback still does not work for Wayland.
See #24051
2023-11-22 14:52:26 -08:00
Paul Cornett
14f6f82e46 Fix for incorrect preferred size from empty wxChoice with GTK3
See #23382
2023-11-21 22:42:01 -08:00
Paul Cornett
edd1d758de Fix wxCheckBox::SetValue() when in undetermined state with GTK
State becomes determined when SetValue() is called.
See #24074
2023-11-20 08:50:05 -08:00
Paul Cornett
f587ef7c88 Make wxDisplay::GetDepth() specific to each display with GTK 2023-11-19 17:42:49 -08:00
Paul Cornett
6857dc8e63 Make wxGC offsetting consistent across scales
In order to avoid drawing anomalies with wxGCDC on HiDPI displays, the shift
must be half a logical unit rather than half a device unit, and it needs to be
applied regardless of the scale factor. An exception is made for the zero-width
(one logical pixel) pen, which uses a half logical pixel shift. This reverts
d43b2862c3 (Fix drawing rectangle with width 1 pen using wxGCDC and HiDPI, 2023-04-25)
See #23485
2023-11-19 17:37:22 -08:00
Vadim Zeitlin
dede4b9326 Use "= default" for all trivial default ctors and dtors
Replace user-specified empty constructors and destructors with the
compiler-generated versions, which has a number of advantages for code
generation, in addition to being more clear.

Closes #22965.

Closes #24058.
2023-11-17 01:33:32 +01:00
Stefan Csomor
16cca70f8f Restore correct activation for out-of-bundle Mac executables
This restores old activation logic for Mac applications, while still
preserving the fix for #23893 from #24003.

Closes #24056.

Closes #24062.
2023-11-17 01:24:00 +01:00
Martin Corino
e64118658d Add documentation for wxSizerFlags::HorzBorder()
Closes #24059.
2023-11-17 01:22:53 +01:00
Vadim Zeitlin
aa8c95645b Merge branch 'improve-bug-report'
Try to make bug report instructions even more clear.

See #24055.
2023-11-17 01:22:08 +01:00
Stefan Csomor
991a74caad Set to wx-expected clipping behavior of drawRect
This corrects wxAUI appearance, which was totally broken when using
Sonoma SDK/Xcode 15.

See

https://developer.apple.com/documentation/macos-release-notes/appkit-release-notes-for-macos-14#NSView

https://developer.apple.com/forums/thread/737838

Closes #23916.

Closes #24054.
2023-11-17 01:15:59 +01:00
Stefan Csomor
21da0e128d Change wxRendererNative to use NSCell-based methods under Mac
Use wxOSX_USE_NSCELL_RENDERER to allow setting it to 0 to revert to the
old code.

Note that the new version is Objective C++, so the old .cpp file had to
be renamed to have .mm extension.

Closes #24053.

Co-Authored-By: Vadim Zeitlin <vadim@wxwidgets.org>
2023-11-17 01:12:49 +01:00
Blake-Madden
1d7f2becd4 Add line spacing support to MSW wxTextCtrl
Also expand and improve wxTextAttr documentation by mentioning where is
each attribute supported.

Closes #24046.
2023-11-17 01:11:14 +01:00
Vadim Zeitlin
7a73044fd2 Merge branch 'tree-search'
Don't find hidden items when using incremental tree search.

See #24041.
2023-11-17 01:08:19 +01:00
Vadim Zeitlin
ba9fe3481d Merge branch 'gtk-dpi-changed'
Generate DPI changed event in wxGTK too.

See #24040.
2023-11-17 01:06:54 +01:00
Vadim Zeitlin
5a184d423b Merge branch 'qt-uiaction-tests' of https://github.com/AliKet/wxWidgets
Enable automatic tests using wxUIActionSimulator under wxQt.

See #24015.
2023-11-17 01:05:56 +01:00
Vadim Zeitlin
ef4fecc186 Merge branches 'tree-state-bmpbundle' and 'imglist-scalefactor'
Refactor wxImageList and convert it to use physical pixels and
add support for high DPI state images wxTreeCtrl using the new
wxImageList.

See #24000, #24033.
2023-11-17 01:03:27 +01:00
Vadim Zeitlin
46feaf2066 Ignore NULL to nullptr change in git blame output
This commit touched a lot of file without really changing anything.
2023-11-17 00:38:33 +01:00
Paul Cornett
56303c6236 Document wxDisplay::GetDepth()
Should have been part of
24b5e256df (Add wxDisplay::GetDepth() and use it for wxDisplayDepth(), 2018-10-06)
2023-11-16 10:06:57 -08:00
Paul Cornett
6210c622f7 Add minimal wxVideoMode support for Wayland
See #24021
2023-11-16 09:47:37 -08:00
Paul Cornett
86a0456bc4 Build fix for wxUSE_CONFIG==0 2023-11-15 20:36:21 -08:00
Paul Cornett
67090e61d2 Improve wxSystemSettings::GetMetric() scrollbar width calculation for GTK3
See #24057
2023-11-15 20:31:24 -08:00
Vadim Zeitlin
12984a0ceb Ask to specify the build system used in build problem template
Also ask for any unusual compiler options.
2023-11-13 01:55:46 +01:00
Vadim Zeitlin
17d7cbe315 Try to make bug report instructions even more clear 2023-11-13 01:48:09 +01:00
Paul Cornett
2d07dd25b4 Improve desktop environment detection
Add code that works for Wayland, and any DE
2023-11-10 11:23:24 -08:00