Commit Graph

63499 Commits

Author SHA1 Message Date
Václav Slavík
fd9e71afb7 Fix rendering artifacts in wxSplitterWindow sash
SizeWindows() optimized rendering calls to DrawSash() too aggressively
and wouldn't repaint e.g. slowly moving sash with wxSP_LIVE_UPDATE
enabled, even though child windows were repositioned.

Fix by always painting the sash from SizeWindows().
2016-11-14 20:07:27 +01:00
Paul Cornett
d3497d32ec Size text sample to it's contents, rather than using fixed arbitrary size 2016-11-14 10:43:56 -08:00
Paul Cornett
5fb89cb86e Support setting initial position for TLW with GTK3 2016-11-14 10:39:58 -08:00
Paul Cornett
27d218a1f3 Set a minimal size for GtkEntry preferred size
This overrides the default minimum size of 150+ pixels, avoiding swarms of
GTK3 debug warnings about "attempt to underallocate wxPizza's child GtkEntry"
2016-11-14 10:38:46 -08:00
Paul Cornett
9bb5d0435a Fix non-default window background color with GTK+ >= 3.20
GTK+ no longer automatically paints non-default window background. See #17586
2016-11-09 20:06:26 -08:00
Václav Slavík
b1a19e6b6c Improve wxChoice::GetBestSize on macOS
Better match native sizing to fit the content by reducing the extra spacing.
2016-11-07 17:52:44 +01:00
Paul Cornett
b47319d515 Avoid calling ScreenToClient() on invisible window while processing wxSetCursorEvent 2016-11-05 19:44:45 -07:00
Paul Cornett
9c3900e40d Cleaner fix for using deleted widget in idle callback
Use a slightly higher idle priority so callback runs before TLW is deleted,
and ref the widget just to make sure it doesn't disappear. Avoids accessing
de-allocated memory.
2016-11-05 17:27:57 -07:00
Paul Cornett
e3f117c4f3 Avoid assert dialog in ClientToScreen()/ScreenToClient(), it's just too annoying 2016-11-03 09:38:39 -07:00
Paul Cornett
ebfa5a4128 Make sure all pointers to destructed window are removed from size revalidate list 2016-11-03 09:22:34 -07:00
Paul Cornett
bca7313499 Fix paint clipping region with GTK+ >= 3.20
Apparently the clip is no longer set properly. Fixes wxDC::Clear() overwriting
areas outside the window. Problem can be seen in the Audacity toolbars.
2016-11-03 09:14:30 -07:00
Václav Slavík
095c958525 Fix ~wxDataViewCtrl assert when running under JAWS
Accessible object must be destroyed as soon as possible, because
otherwise a screen reader may try to query it before wxWindow destructor
removed it, but after ~wxDataViewCtrl destructor finished. The
wxACC_EVENT_OBJECT_DESTROY notification causes exactly that under JAWS.
2016-11-03 16:27:28 +01:00
Paul Cornett
101c43d0aa Partial workaround for stale styling information with GTK3
We can trigger size events when we know the style cache has been updated.
See #16088
2016-11-01 23:18:26 -07:00
Paul Cornett
3b4ee5a031 Fix some sizing problems with GTK3
A change in size-allocate handling with GTK+ 3.20 exposed a flaw in our method for
deferring queue-resize requests. Using an idle callback to process the requests
did not work well with the GdkFrameClock-based system used since GTK+ 3.8. Using
the "check-resize" signal works better. Also with GTK+ >= 3.20, it seems necessary
to manually work the queue-resize up to the TLW, as otherwise the resized widgets
don't get updated without an external size-allocate event.
See #17585
2016-10-31 11:12:37 -07:00
Paul Cornett
83012dc082 avoid uninitialized result from size_request with Ubuntu, see #17707 2016-10-31 09:32:20 -07:00
Václav Slavík
c146103c64 Make wxStatusBar look (more) native on macOS
Significantly improve the appearance of wxStatusBar on macOS, both the
modern flat look since 10.10 and older versions. Increase the size to
match native bottom bars, center the text inside it, use appropriate
background and border colors and the same gray for the text as Finder
uses, correctly change the appearance for inactive windows.

This is still far from ideal - that would be using
setContentBorderThickness:forEdge: and rendering the text atop it. But
that seems to be much easier said than done due to interference from
other parts of wx. This is much better than the previous state.
2016-10-31 14:31:11 +01:00
Lauri Nurmi
9a90816f0b Remove false information about static arrays and wxTRANSLATE
It is not forbidden to have function calls in static initializers, and
such code compiles fine, contrary to claims made by the text. Explain the
real reason why wxTRANSLATE is necessary.
2016-10-31 09:34:41 +01:00
Lauri Nurmi
49137ba1e1 Use a better example for wxTRANSLATE
Since even the text itself acknowledged the example is bad, use another
example that is not bad.
2016-10-31 09:34:41 +01:00
Václav Slavík
d3924b7d41 Report value as percent in wxDataViewProgressRenderer
GetAccessibleDescription() should return the value as percents, not a
raw number, because that's what m_value means.
2016-10-31 09:29:21 +01:00
Paul Cornett
240f826185 Fix a sizing problem with GTK3 when wxPizza is the child of a native GTK widget
See #17704
2016-10-30 17:33:28 -07:00
Artur Wieczorek
9b8f46df36 Implement wxDataViewCustomRenderer::GetAccessibleDescription()
This is a default description of the renderer content (for accessibility purposes).
Thanks to this implementation there is not necessary to override GetAccessibleDescription() in the renderers derived from wxDataViewCustomRenderer.
2016-10-30 20:59:51 +01:00
Artur Wieczorek
fb219aaf35 Add accessibility event notifications to wxDVC 2016-10-30 20:49:56 +01:00
Artur Wieczorek
eeaa613705 Fix wxDataViewCtrlAccessible::DoDefaultAction
Calling wxDataViewTreeNode::ToggleOpen() is not sufficient to actually expand/collapse the item.
Calls to wxDataViewMainWindow::Expand()/Collapse() are necessary to do so.
2016-10-30 20:41:08 +01:00
Artur Wieczorek
da370db5ed Return S_OK from wxIAccessible::accDoDefaultAction() if operation succeeded
S_OK should be returned (not E_FAIL) if wxAccessible::DoDefaultAction() returns wxACC_OK.
2016-10-30 20:40:24 +01:00
Václav Slavík
db0f4efb4f Fix unused variable warning in wxFontPanelDelegate 2016-10-28 13:59:40 +02:00
Robin Dunn
107d6551c0 Revert "WX_CLEAR_LIST in wxHtmlWindow::CleanUpStatics is hard-crashing"
The issue was an incorrect ownership transfer in wxPython.

This reverts commit b2ae25fc6a.
2016-10-26 09:33:37 -07:00
Paul Cornett
3b27f7cebc Fix memory leaks of cairo_t caused by ca7670d2fc, see #17697 2016-10-24 14:20:13 -07:00
Artur Wieczorek
fa4b077421 Remove wxDataViewTreeCtrlAccessibilty class
Since wxDataViewCtrlAccessible::GetName() calls to wxDataViewIconTextRenderer::GetAccessibleDescription() to directly retrieve the content of the renderer, there is no need to override wxDataViewCtrlAccessible::GetName() in order to get a proper content of the renderer in wxDataViewTreeCtrl.
2016-10-24 22:22:31 +02:00
Artur Wieczorek
dbb2781199 Fix wxDataViewCtrlAccessible::GetName() and GetDescription()
Call wxDataViewRenderer::GetAccessibleDescription() to retrieve the content of the renderer instead of using a raw item value taken from wxDataViewModel. GetAccessibleDescription() returns a renderer-aware text dedicated for accessibility purposes and hence text presented in GetName() and GetDescription() is accurate in contrary to the text deduced from the item value.
2016-10-24 22:12:53 +02:00
Artur Wieczorek
bc8728b901 Implement MyCustomRenderer::GetAccessibleDescription() in dataview sample
If wxUSE_ACCESSIBILITY is set to 1, this method has to be overridden for all custom renderers.
2016-10-24 21:55:10 +02:00
Artur Wieczorek
d9fbde805b Implement wxDataViewRenderer::GetAccessibleDescription() method
The purpose of this method is to provide a textual description of the renderer's content to the class implementing accessibility framework in wxDVC (wxDataViewCtrlAccessible).
It is exposed if wxUSE_ACCESSIBILITY is set to 1.
2016-10-24 21:52:22 +02:00
Robin Dunn
60aa5d8e41 fix code snippet 2016-10-21 20:17:38 -07:00
Robin Dunn
6b335c8ca4 Add missing wxPropertySheetDialog methods and fix a typo. 2016-10-21 20:16:53 -07:00
Robin Dunn
ec0a91464e Add missing ctors and dtor for wxPropertyGridManager 2016-10-21 20:15:50 -07:00
Robin Dunn
8557172cb5 Add SetFlag and ClearFlag 2016-10-21 20:12:56 -07:00
Robin Dunn
6988758648 Add missing methods in wxGridCellAttr 2016-10-21 20:09:28 -07:00
Robin Dunn
17bb46299e Fix wxPropertyGridPage declaration 2016-10-21 20:09:16 -07:00
Robin Dunn
12f9b8b7e4 SetValueToUnspecified is not pure virtual 2016-10-21 20:08:30 -07:00
Robin Dunn
af9a0f6734 Change ~wxPGChoicesData from private to protected 2016-10-21 20:08:20 -07:00
Robin Dunn
774f37d0a3 Add more missing classes 2016-10-21 19:54:22 -07:00
Robin Dunn
c8c02a1bf2 Add wxPGPaintData and wxPGCellRenderer 2016-10-21 19:54:22 -07:00
Robin Dunn
bf13c0af22 Remove wxDEPRECATED decorator from doc 2016-10-21 19:53:57 -07:00
Robin Dunn
0be4a6d919 some formatting tweaks for propgrid 2016-10-21 16:54:35 -07:00
Robin Dunn
a5fe9de656 Add missing methods 2016-10-21 16:54:35 -07:00
Robin Dunn
cbbf8fe9d8 wxPalette::Create should return true 2016-10-21 16:54:34 -07:00
Robin Dunn
2fab4c4fc1 Add setter methods to wxListEvent 2016-10-21 16:54:34 -07:00
Robin Dunn
5301cbd845 Fix typo 2016-10-21 16:54:33 -07:00
Robin Dunn
cf8aa0b2d7 Change parameter name to reduce confusion in wxPython docs. 2016-10-21 16:54:33 -07:00
Robin Dunn
3243436ff7 Add lots of missing methods in wxAboutDialogInfo 2016-10-21 16:54:32 -07:00
Robin Dunn
b2ae25fc6a WX_CLEAR_LIST in wxHtmlWindow::CleanUpStatics is hard-crashing in wxHtmlWindow::CleanUpStatics, perhaps due to a different cleanup order?? Anyway, switching to .Clear() avoids the crash and does nearly the same. Since it is in code that is called on exit it shouldn't matter either way. 2016-10-21 16:54:31 -07:00