Commit Graph

3126 Commits

Author SHA1 Message Date
Vadim Zeitlin
4fce66a483 Don't document wxShowEvent as being for MSW and GTK only
It is also generated by at least wxMac and wxQt.
2019-01-18 05:26:22 +01:00
Chilau He
3aa6aec620 Add wxWebViewIE::MSWSetEmulationLevel()
This extends and replaces MSWSetModernEmulationLevel() by allowing a
more fine-grained choice of the emulation level used by wxWebViewIE.

Closes https://github.com/wxWidgets/wxWidgets/pull/1133
2019-01-14 23:25:14 +01:00
Vadim Zeitlin
e90c6e83dd Remove stray closing brace from Connect() documentation 2019-01-08 22:59:46 +01:00
ali kettab
36f6f8ad49 wxTextValidator improvements
Improve char inclusion/exclusion support; update the sample to show more
features of this class and add a unit test for it.

Closes https://github.com/wxWidgets/wxWidgets/pull/1093
2019-01-05 23:33:35 +01:00
Pavel Kalugin
659ab78c6d Add support for editing dates (without time) to wxGrid
Add wxGridCellDateRenderer and wxGridCellDateRenderer which can be used
for the grid cells containing only dates, without times.

Also add wxGrid::SetColFormatDate() convenience function.

Refactor wxGridCellDateTimeRenderer slightly to reuse its code.

Closes https://github.com/wxWidgets/wxWidgets/pull/1101
2019-01-04 14:14:01 +01:00
Vadim Zeitlin
7f63adde95 Merge branch 'select-after-delete'
Harmonize behaviour of wxItemContainer::Delete() for all controls and
ports when using single selection.

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

Closes #18267.
2019-01-04 14:01:02 +01:00
PB
0e0bf07888 Fix broken URL in wxICON_QUESTION documentation
The content on MSDN has moved, so the URL needs to be updated.

Closes https://github.com/wxWidgets/wxWidgets/pull/1107
2019-01-03 00:12:37 +01:00
Vadim Zeitlin
c9b240e893 Try to better explain what wxFIXED_MINSIZE does
Don't mention the non-existent GetAdjustedBestSize() function and do
explain what setting wxFIXED_MINSIZE achieves and how it can be done
without it.

Closes #18315.
2018-12-30 15:40:00 +01:00
Artur Wieczorek
a6570433b6 Change wxPGProperty::OnCustomPaint measure item call signature
Because horizontally scrolled wxPGProperty can have x-coordinate < 0 so there is a need to change measure item call signature from rect.x < 0 condition to something more specific to avoid misinterpretation of the calls.
2018-12-28 14:02:05 +01:00
Artur Wieczorek
3b6fcbab6d Update wxPGArrayEditorDialog docs 2018-12-24 00:05:23 +01:00
Vadim Zeitlin
270ad54abe Revert all recent changes to wxTranslations
The latest changes to wxTranslations::AddCatalog() behaviour were not
backwards-compatible and also had other problem, so revert them for now,
even if this means that #18227 has to be reopened.

This is a combination of the following commits:

----

Revert "Fix regression in wxTranslations::AddCatalog()"

This reverts commit 14e905858d.

See #18297.

----

Revert "Fix crash in translations code when no translations are found"

This reverts commit 80904d1bc7.

See #18299.

----

Revert "Rename new wxTranslations method to GetAcceptableTranslations()"

This reverts commit 20b02d6169.

----

Revert "Load catalogs for all preferred languages, if they exist"

This reverts commit 2d784da2ee.

----

Revert "Allow getting all usable translations languages"

This reverts commit 5d08e404c7.

----

See #18227, #18300.

Closes #18302.
2018-12-23 17:33:49 +01:00
Artur Wieczorek
b252d1660d Cleanup wxPGArrayEditorDialog docs 2018-12-23 11:04:03 +01:00
Artur Wieczorek
0fbc4cd6ab Allow setting custom tooltip text for "New" button in wxPGArrayEditorDialog
Ability to change the tooltip can be useful if standard text "New item" is not descriptive enough.
2018-12-23 11:03:46 +01:00
Vadim Zeitlin
622deec262 Replace wxSizer::RecalcSizes() with RepositionChildren()
The new method takes minimal size just computed by RecalcSizes() as its
argument making it unnecessary to store it as a member variable in the derived
classes such as wx{Box,FlexGrid}Sizer.

The old method can still be overridden for compatibility and by the derived
class that don't need minimal size when updating children.
2018-12-20 23:36:51 +01:00
Pavel Kalugin
7d9675472d Refine documentation related to wxTimePickerCtrl
Specify event types, corresponding to EVT_TIME_CHANGED and
EVT_DATE_CHANGED macros, and update 'see also' sections.
2018-12-20 19:00:42 +01:00
Vadim Zeitlin
50e098437d Document lack of custom editors in Mac wxDataViewCtrl
wxDataViewCustomRenderer::CreateEditorCtrl() is currently never called
there.
2018-12-17 14:07:12 +01:00
Vadim Zeitlin
5b2e992947 Document wxThread::Delete() behaviour more precisely
Delete() doesn't (and can't, under Unix) wait for the detached threads,
although it does do it under MSW (but arguably shouldn't), so it can't
retrieve the thread exit code there.

Document that its "rc" argument is only useful with joinable threads.

Closes #18240.
2018-12-16 00:02:07 +01:00
Vadim Zeitlin
b825c49c2e Document and test wxItemContainer::Delete() selection handling
Add test checking that selection is reset when deleting the selected
item or any item before, but not after, it.

Also explicitly document this behaviour.
2018-12-15 23:47:26 +01:00
Vadim Zeitlin
cdd0430b37 Remove hard TABs from documentation files
No real changes.
2018-12-15 23:45:19 +01:00
Vadim Zeitlin
0de31f03a1 Document that Enable() can be called before creating the window
Explicitly mention that calling Enable() for a window which hasn't been
created yet is allowed.
2018-12-09 19:21:51 +01:00
Pavel Kalugin
facb06a1b8 Fix wxSize member names in the documentation
wxSize members x and y were incorrectly mentioned as width and height in
the docs.

Closes https://github.com/vadz/wxWidgets/pull/6
2018-12-08 19:02:28 +01:00
Vadim Zeitlin
aa6a8fbdf0 Document that wxGCDC takes ownership of the provided context
This is a rather important detail which the documentation completely
forgot to mention.
2018-12-06 03:43:37 +01:00
Stefan Ziegler
974b7c0990 Add wxToolbook::EnablePage()
Add functions to enable or disable pages inside wxToolbook.

Using the new functions you can present disabled icons so that the user
can expect more functionality and you do not need to add/remove pages in
different states.

Closes https://github.com/wxWidgets/wxWidgets/pull/1038
2018-12-03 19:42:45 +01:00
Maarten Bent
39ff5b90e5 Replace wxDeprecatedGUIConstants enum values 2018-11-25 21:29:32 +01:00
Maarten Bent
86c49283f5 Remove trailing spaces 2018-11-25 20:22:25 +01:00
Vadim Zeitlin
20b02d6169 Rename new wxTranslations method to GetAcceptableTranslations()
This name seems to be more precise than a very generic "all good" one
used previously.
2018-11-18 01:47:12 +01:00
Lauri Nurmi
2d784da2ee Load catalogs for all preferred languages, if they exist
This way the first and only fallback language isn't necessarily the
msgid language (which is English most often). This is how GNU gettext
works -- it uses multiple fallback languages when multiple preferred
languages are set.

As a side effect, fixes #18227 in one possible way.
2018-11-18 01:47:12 +01:00
Lauri Nurmi
5d08e404c7 Allow getting all usable translations languages
Add a method to return the full list of translations that can be used,
generalizing the existing GetBestTranslation().
2018-11-18 01:47:12 +01:00
Vadim Zeitlin
5b891e9ffc Merge branch 'dvc-getitemrect'
Make wxDataViewCtrl::GetIremRect() work under all platforms and improve
tests, documentation and fix a couple of other problems in the same code
area.

See https://github.com/wxWidgets/wxWidgets/pull/1015
2018-11-10 22:38:05 +01:00
Vadim Zeitlin
463deb03c9 Merge branch 'gtk-dpi'
A bunch of improvements for per-monitor DPI support in wxGTK and
wxGraphicsContext more generally.

Closes https://github.com/wxWidgets/wxWidgets/pull/995
2018-11-10 12:15:27 +01:00
Artur Wieczorek
bf3cfe16d4 Remove irrelevant TODO note from documentation
Function is marked as deprecated so TODO note is no longer relevant.
2018-11-07 22:25:19 +01:00
Vadim Zeitlin
767639276f Disable failing wxDataViewCtrl::IsExpanded() test under Mac
For some unfathomable reason IsExpanded() returns wrong value for one of
the items. This should be fixed, but for now just leave a warning in the
test but don't fail it.

Also document this bug to at least spare people some surprises.
2018-11-06 04:03:34 +01:00
Vadim Zeitlin
5e53b22bd4 Add wxGraphicsContext::GetWindow()
This method allows to retrieve the window this context is associated
with, if any.

Add "wxWindow*" argument to wxGraphicsContext ctor and provide the
window pointer to it when available, i.e. when creating the context from
a wxWindow directly or from wxWindowDC, which is also associated with a
window, in platform-specific code.

No real changes yet.
2018-11-06 03:36:53 +01:00
Vadim Zeitlin
1c68979fb4 Move wxCTZ() documentation to the appropriate place
The documentation comment belongs to interface/wx/math.h, not the header
under include.

Also change the argument type to wxUint32 as the non-gcc version only
works for 32 bit values.
2018-11-05 19:27:53 +01:00
Vadim Zeitlin
4198107086 Fix wxJoystickEvent documentation after the last commit
Remove left over part of the old sentence.

Also add a link to GetButtonChange() to GetButtonOrdinal()
documentation.
2018-11-05 19:27:53 +01:00
Mick Phillips
291a880d0c Synchronize joystick events between all ports
Generate wxJoystickEvent with the same fields under all platforms by
making the Linux and macOS versions follow MSW convention of using
"1 << N" for the changed button.

Add GetButtonOrdinal() accessor which can be used to retrieve just N.

Closes #18233.
2018-11-05 19:27:36 +01:00
Vadim Zeitlin
1256695d46 Document that wxDataViewCtrl::GetItemRect() now works in wxGTK
Remove the note about it being non-implemented from the docs and mention
this in the change log.
2018-11-04 18:37:54 +01:00
Vadim Zeitlin
bf97715972 Support NULL column in wxDataViewCtrl::GetItemRect() in wxOSX
Emulate support for non-specified column by using the first and, if
necessary, last columns in this case.
2018-11-04 18:35:07 +01:00
Vadim Zeitlin
9460038b3f Return empty rectangle from GetItemRect() if item is not visible
This was already the case if the item was not visible because its parent
was not expanded, but now make it also true for the items which are not
visible due to the current scrollbar position.

Add unit tests checking for this and also verifying that GetItemRect()
returns the coordinates in the physical window coordinates.
2018-11-04 18:28:33 +01:00
Vadim Zeitlin
ada5de3d0d Fix wxDataViewCtrl::GetItemRect() for collapsed items
Calling GetItemRect() for an item which was not currently visible
because its parent was collapsed resulted in silently returning the
value for a wrong value before the recent fix to GetRowByItem() and in
a crash after it because GetTreeNodeByRow() returned null when passed
invalid row index.

Fix this by explicitly checking whether the item is shown and just
returning an empty rectangle instead.

Also document this behaviour and add a unit test for it.
2018-11-04 17:15:42 +01:00
Vadim Zeitlin
f57cb6c1d9 Add wxDisplay(wxWindow*) ctor with fall back on primary display
This is more convenient than calling GetFromWindow() and then checking
its return value.
2018-11-01 00:02:47 +01:00
Tobias Taschner
394b26bc36
Fix wxGetDiskSpace() documentation
The function is actually declared in utils.h and not in filefn.h
2018-10-31 10:26:11 +01:00
Stefan Csomor
9a05410470 Adding IsSolid to wxColour
Under macOS colors can be patterns, then accessors for RGB values are useless, IsSolid returns true if the color can be expressed in RGB values at all.
2018-10-30 20:53:35 +01:00
Vadim Zeitlin
5d5654742f Merge branch 'msw-popup'
Reimplement wxPopupWindow using WS_POPUP instead of WS_CHILD window in
wxMSW as the new approach allows using the controls inside the popup
normally, unlike the old one.

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

Closes #18243.
2018-10-27 15:08:22 +02:00
Vadim Zeitlin
79a37a2a65 Don't try to set focus outside of popup window in wxMSW
This will just hide the window immediately, so prefer to ignore the
"focus" argument of Popup() but show the popup instead.

Update the documentation to mention that setting focus outside of popup
is not supported under all platforms.
2018-10-27 15:06:42 +02:00
Vadim Zeitlin
f11849b7e8 Document not completely obvious wxRearrangeList::Set() behaviour
Calling Set() resets the existing items order, which makes sense from
the implementation point of view, but not necessarily expected by the
users.

See #18262.
2018-10-26 01:35:28 +02:00
Vadim Zeitlin
ea71ea1259 Check for non-null window in wxRendererNative::GetCheckBoxSize()
Instead of running normally under some platforms and crashing under MSW
(when using themes) when passing NULL to GetCheckBoxSize(), now
consistently assert and return zero size everywhere.

Closes #18241.
2018-10-11 00:01:00 +02:00
Robin Dunn
1a31420e92 Add wxACC_SELF and fix parameter name
(cherry picked from commit b75f473ea3e2ee081a4ce0038a3102fa7a000b34)
2018-10-10 10:59:32 -07:00
Vadim Zeitlin
54ef52fbd9 Merge branch 'display-funcs'
Implement all global functions in terms of wxDisplay and add
wxDisplay::GetPPI().

See https://github.com/wxWidgets/wxWidgets/pull/963
2018-10-09 16:31:54 +02:00
Vadim Zeitlin
11f80e3e34 Clarify wording of wxDataViewEvent::GetColumn() documentation
Just that the column is -1 if it's not available instead of speaking
about "event emitter" that people find confusing.
2018-10-09 15:10:11 +02:00