Commit Graph

3649 Commits

Author SHA1 Message Date
Vadim Zeitlin
451ed78dcd Mark wxImageAlphaBlendMode as being new since 3.1.5
It doesn't matter much, but it, and the corresponding parameter, will be
available in this version and not (only) in 3.2.0.
2020-09-25 01:12:24 +02:00
Eric Raijmakers
6e8da8641c Add alpha blending for wxImage::Paste
Add test cases for wxImage::Paste.

Closes #12458.

Co-Authored-By: Rachel Mark <kramdar@gmail.com>
2020-09-25 01:04:49 +02:00
PB
8ae9987a29 Improve code examples in wxDataViewModel documentation
Fix variable name for the model.

Make the code using wxObjectDataPtr have the same flow as the
code using a raw pointer.

Format the code to be in accordance with the official guidelines.

Closes #18924.
2020-09-24 00:12:37 +02:00
Vadim Zeitlin
1f1a9d52d6 Merge branch 'expose-radiogroup'
Add public functions for navigating in radio button groups.

Also introduce wxRadioButtonBase defining wxRadioButton API for all
ports.

See https://github.com/wxWidgets/wxWidgets/pull/2052
2020-09-24 00:11:15 +02:00
Vadim Zeitlin
9e51389676 Improve radio button navigation functions documentation
Correct the previously wrong described behaviour for wxRB_SINGLE buttons
and also mention that Get{First,Last}InGroup() never return NULL.
2020-09-21 16:02:40 +02:00
Vadim Zeitlin
1a4f628e40 Make radio button navigation functions const
This requires adding a couple of const_cast<>s in their implementation
in order to still allow them returning non-const wxRadioButton pointers,
but this seems preferable to not being able to call them on a const
wxRadioButton in the first place.
2020-09-21 15:36:41 +02:00
Vadim Zeitlin
3ccbee2e1c Mark radio button group navigation functions as new in 3.1.5
Just add the missing "@since" lines.
2020-09-21 15:05:35 +02:00
Vadim Zeitlin
dfd1638f39 Improve radio button groups documentation
Explain the role of wxRB_SINGLE better, it's useful not only for
avoiding wxMSW bugs (which, besides, shouldn't exist any more).
2020-09-21 15:02:47 +02:00
Stefan Csomor
7bf00e1161 Added info about wxRB_SINGLE 2020-09-21 09:02:06 +02:00
Stefan Csomor
02b3b9d745 Adding docs 2020-09-20 19:44:16 +02:00
Vadim Zeitlin
9abe63333d Merge branch 'im/docadditions' of https://github.com/imciner2/wxWidgets
Various documentation fixes and improvements.

See https://github.com/wxWidgets/wxWidgets/pull/2047
2020-09-20 18:14:02 +02:00
Ian McInerney
d33a393ed8 Docs: Remove wxTB_FLAT from the default style
This style was removed from the default previously,
so this was just a remnant in the documentation.

Fixes #17542
2020-09-14 21:46:41 +01:00
Ian McInerney
5e73cf3612 Document styles for the AUI toolbar 2020-09-14 21:41:56 +01:00
Robin Dunn
16ab09208f Add missing dock art Clone methods 2020-09-10 12:39:05 -07:00
Ian McInerney
b4a50b1ea7 Document return types in wxAuiToolBarItem better
These functions return only specific flags inside an integer,
so in order to use the functions we need to know the flags.

Fixes #14972
2020-09-04 18:25:41 +01:00
Ian McInerney
55f80941bf Mention that wxFD_OVERWRITE_PROMPT is always enabled on OSX
This style is ignored on OSX because there is no way to disable
the overwrite prompt from showing.

Fixes #13541
2020-09-04 18:25:41 +01:00
Vadim Zeitlin
e4333fdeac Fix recurrent typo in "usable"
This word has a single "e".
2020-09-02 20:49:39 +02:00
Vadim Zeitlin
bf71a70a12 Merge branch 'updateui-ischeckable'
Add a flag to wxUpdateUIEvent to tell if the item supports the check
action.

See https://github.com/wxWidgets/wxWidgets/pull/2027
2020-09-02 19:34:05 +02:00
Vadim Zeitlin
7be693212c Improve documentation of wxUpdateUIEvent::IsCheckable()
Explain when this method can be useful.
2020-09-02 19:33:39 +02:00
Vadim Zeitlin
ed4b9e5f97 Merge branch 'mac-native-focus-ring' of https://github.com/vslavik/wxWidgets
Draw wxTextCtrl focus ring natively on Mac.

Add wxWindow::EnableVisibleFocus() to explicitly control the focus ring
visibility if necessary.

See https://github.com/wxWidgets/wxWidgets/pull/2037
2020-09-01 14:59:42 +02:00
Vadim Zeitlin
be2a61519b Merge branch 'grid-selected'
Split the wxGrid RANGE_SELECT event into separate SELECTING and SELECTED
events.

See https://github.com/wxWidgets/wxWidgets/pull/2028
2020-08-31 14:55:56 +02:00
Vadim Zeitlin
82f7cb6e9b Merge branch 'art-ids-literals'
Revert art ids changes and make them `char*` literals again.

See https://github.com/wxWidgets/wxWidgets/pull/2031
2020-08-31 14:51:52 +02:00
Ian McInerney
7f7a0bfa81 Fix documentation for wxSYS_COLOUR_INACTIVECAPTIONTEXT
Just s/active/inactive/ in the description.

Closes https://github.com/wxWidgets/wxWidgets/pull/2039
2020-08-31 14:49:45 +02:00
Václav Slavík
9f66b03c5c Allow configuring visible focus on Mac
Add wxWindow::EnableVisibleFocus() for changing focus ring behavior on
macOS (currently not implemented elsewhere, although GTK+ has a
discouraged option to do it).
2020-08-31 10:38:59 +02:00
Vadim Zeitlin
29a2b481a5 Fix documented type of wxART_XXX constants
They're (now, and had always been before the recent changes) string
literals, i.e. of type "const char *", rather than "wxString".
2020-08-25 16:49:24 +02:00
Vadim Zeitlin
873e028ffa Document wxASCII_STR() macro
Also improve wxString::FromAscii() documentation slightly.
2020-08-25 16:49:05 +02:00
Vadim Zeitlin
30b37b610d Revert "Merge branch 'string-art-ids'"
This reverts commit 8c9ba23eae, reversing
changes made to 5192feb38e.

Upcoming commits will try to work around the issues with art IDs related
to wxNO_IMPLICIT_WXSTRING_ENCODING in a different way.
2020-08-24 16:47:37 +02:00
Vadim Zeitlin
3df9d772a4 Merge branch 'display-ppi-from-scaling-factor'
Determine display DPI from scaling factor instead of trying to compute
it from the physical display dimensions.

See https://github.com/wxWidgets/wxWidgets/pull/2015

Closes #18855.
2020-08-24 00:14:27 +02:00
Ian McInerney
afbb334a26 Make IsCheckable true by default and switch to explicitly disallowing it
Also add a new accessor to wxAuiToolBarItem to make it easier to
determine when a tool can be checked.
2020-08-21 23:15:38 +01:00
Vadim Zeitlin
6d6c01ff2a Make wxKeyboardState ctor explicit
Avoid accidental conversions of e.g. int to wxKeyboardState.
2020-08-21 11:49:34 +02:00
KT
b50aca9596 Inherit art provider in wxAuiFloatingFrame by default
Use the same art provider for a floating frame detached from an existing
wxAuiManager as was used by the original wxAuiManager itself, to ensure
that the appearance of this frame is consistent with the appearance of
its parent.

Implementing this required adding wxAuiDockArt::Clone() to allow copying
it in the new frame and this patch also adds GetAuiManager() to
wxAuiFloatingFrame, similar to the existing method in wxAuiNotebook, in
order to allow changing the dock art from the application code if
desired.

Closes https://github.com/wxWidgets/wxWidgets/pull/2022

Closes #18882.
2020-08-21 02:43:28 +02:00
Vadim Zeitlin
126c976f5b Merge branch 'taskbar-icon-get-menu'
Add wxTaskBarIcon::GetPopupMenu() allowing to avoid recreating the menu
every time.

See https://github.com/wxWidgets/wxWidgets/pull/2020
2020-08-21 02:42:13 +02:00
Vadim Zeitlin
8c9ba23eae Merge branch 'string-art-ids'
Make the wxART_* constants const wxStrings to improve compatibility with
pre-3.1.4 code and, in particular, allow taking the address of these
constants.

See https://github.com/wxWidgets/wxWidgets/pull/1996
2020-08-21 02:39:12 +02:00
Ian McInerney
65e124bb64 Add a flag to wxUpdateUIEvent to tell if the item supports the check action
Not all items support check being set in an UpdateUIEvent handler,
so it is nice to provide an API to find out if the item supports it.

Fixes #13369
2020-08-20 23:30:19 +01:00
Vadim Zeitlin
9e27efb2cb Further improve wxEVT_GRID_RANGE_SELECT{ED,ING} documentation
Explain when it is preferable to handle events of each kind.
2020-08-20 16:56:23 +02:00
Vadim Zeitlin
e2f316b19d Mention that wxEVT_GRID_RANGE_SELECT{ED,ING} are new in 3.1.5
Also explained that SELECTED is just the new spelling of SELECT.
2020-08-20 16:56:03 +02:00
Daniel Kulp
415f080c80 Split wxGrid RANGE_SELECT event into SELECTING and SELECTED
This will allow the applications that are only interested in the final
selection to ignore the intermediate SELECTING events, which are now
sent as soon as the selection changes while dragging the mouse, and only
handle the final SELECTED ones, when the drag is over.
2020-08-20 16:56:03 +02:00
Vadim Zeitlin
f04c904b60 Improve wxTaskBarIcon::Create/GetPopupMenu() documentation
Try to make the text more clear and prescriptive.

Also add a "@since" tag.
2020-08-14 19:48:29 +02:00
Andreas Falkenhahn
c70a8261cb Add wxTaskBarIcon::GetPopupMenu()
This is similar to CreatePopupMenu(), but the menu pointer returned by
the new function won't be deleted by wxWidgets, allowing it to return
the same pointer every time it is called.

Closes #18886.
2020-08-14 19:33:38 +02:00
PB
a4647825cb Do not use wxRegEx in wxCmpNaturalGeneric()
Using wxRegEx in wxCmpNaturalGeneric() introduced a dependency of the
base library on the regex library.

Replace wxRegEx with character classification functions wxIsspace(),
wxIspunct(), and wxIsdigit() to remove this rather unnecessary
dependency.

Closes https://github.com/wxWidgets/wxWidgets/pull/2014
2020-08-14 19:26:33 +02:00
Vadim Zeitlin
8e2aad2621 Merge branch 'webview_ie-js' of https://github.com/MaartenBent/wxWidgets
Fix using JavaScript in wxWebViewIE with custom scheme.

This repairs a regression in 3.1.4 due to the changes of 6787b0548b
(Merge branch 'webview-ie-fixes', 2020-07-23).

See https://github.com/wxWidgets/wxWidgets/pull/2004
2020-08-14 19:23:27 +02:00
Vadim Zeitlin
19fd0fcfd7 Add wxDisplay::GetScaleFactor()
This is conceptually the same as the ratio of the current DPI to the
standard one, but can be implemented more directly for wxGTK3 and wxOSX
(although the latter doesn't implement it yet).
2020-08-14 16:09:27 +02:00
Vadim Zeitlin
52b25211c8 Add wxDisplay::GetStdPPIValue() and GetStdPPI()
Provide public way to access the default platform DPI, which was
previously a constant private to src/common/wincmn.cpp.
2020-08-14 16:09:27 +02:00
Vadim Zeitlin
e96155fece Fix and improve wxDC background mode documentation
Use wxBRUSHSTYLE_SOLID/TRANSPARENT constants instead of wxPENSTYLE_XXX
ones, as even though they have the same values, using brush style for
the background makes more sense.

Also document that the default background mode is transparent.
2020-08-13 23:08:58 +02:00
Vadim Zeitlin
d3cab1bd54 Don't document wxImageList::Replace() as being MSW-only
This method is implemented in the generic version used under the other
platforms as well, but was documented as being MSW-only in 89bb3f0244
(interface revisions, 2008-10-17) for some reason.

Just remove the note added by that commit.
2020-08-13 21:57:18 +02:00
Stefan Brüns
128e3ff123 Make the wxART_* constants const wxStrings with static storage duration
The pre-3.1.4 definitions of the constants were just string literals,
while the type were wxString typedefs. To avoid implicit conversion
these were converted to actual wxStrings.

While the interface now matched the implementation, this has several
drawbacks:
- every use of the "constant" now is a string construction at runtime
- the constant now is an rvalue, i.e. it is impossible to take its
  address.

The latter breaks its use from wxPython.

The IDs are moved to a separate file which can be included multiple
times, once from the header to have the declarations in place, and once
to instantiate the wxStrings. Using a common file avoids the declaration
and definition going out of sync.
2020-08-06 12:31:37 +02:00
Vadim Zeitlin
aa2d159e8c Use more reasonable length for wxSlider in wxGTK by default
Use the same 100 DIPs as in wxMSW, to make the default behaviour more
useful.

Also update documentation to explain which size component should, and
should not, be specified when creating the slider.

Closes https://github.com/wxWidgets/wxWidgets/pull/2012
2020-08-05 00:01:50 +02:00
Maarten Bent
300fe1a6f9 Add option to wxWebViewHandler to set a custom security URL
This will be used by wxWebViewIE to modify the security URL and domain when
parsing a URL.
2020-07-28 21:22:21 +02:00
Vadim Zeitlin
2f450733d4 Merge branch 'dpi-scaling-factor'
Add DPI scaling factor and revert content scaling factor behaviour in
wxMSW and other ports not using logical pixels to be 3.0 compatible.

See https://github.com/wxWidgets/wxWidgets/pull/1985
2020-07-20 15:55:23 +02:00
Vadim Zeitlin
4dd009136c Merge branch 'aui-auto-uninit'
Call wxAuiManager::UnInit() automatically.

Closes #14145.
2020-07-20 15:49:05 +02:00