Commit Graph

65356 Commits

Author SHA1 Message Date
Vadim Zeitlin
e0e4f16282 Fix a typo in ItemContainerTestCase comment
No real changes, just fix a copy-and-pasto.
2018-12-15 23:04:30 +01:00
Vadim Zeitlin
4ed28f681f Add a common tag for wxItemContainer-derived classes tests
This makes it possible to run the tests for all controls implementing
wxItemContainer interface by just passing "[item-container]" on the test
command line.
2018-12-15 23:04:30 +01:00
Graham Dawes
8fa32a40a9 Fix m_qtPainter not being initialised in wxCairoContext ctor
For some reason one of the overloads of the c'tor left the m_qtPainter
field set to NULL rather than asking the wxDC for it's painter.

The rest of the class assumes the painter is not NULL.

Closes https://github.com/wxWidgets/wxWidgets/pull/1075
2018-12-14 17:41:55 +01:00
Graham Dawes
db15e99884 Fix wxBitmap::GetRawData() in wxQt
This method used to return a dangling pointer to a temporary buffer,
which resulted in a crash when using it, e.g. in the unit test.

Fix this by keeping a QImage as a member in wxBitmapRefData, so that the
pointer to its data remain valid until UngetRawData() is called.

Also check that GetRawData() returns a non-null pointer in the test.

Closes https://github.com/wxWidgets/wxWidgets/pull/1067
2018-12-13 15:24:54 +01:00
Vadim Zeitlin
013c6a6b6a Speed up inserting many items in sorted wxChoice in wxQt
Only sort the combobox once instead of doing it for every item.

See https://github.com/wxWidgets/wxWidgets/pull/1054
2018-12-13 15:17:18 +01:00
chris2oph
89e4ee1ec0 Ensure items are sorted when added to wxChoice in wxQt
Call sort() to resort the model after inserting a new item.

Closes https://github.com/wxWidgets/wxWidgets/pull/1054
2018-12-13 15:10:59 +01:00
Vadim Zeitlin
5189781072 Move wxDataViewCtrl incompatibility note to the correct section
3a24beca62 added this in a wrong place, as
this change does not result in any build errors.

See #18295.
2018-12-13 15:09:13 +01:00
Vadim Zeitlin
b9fe8ca10c Try to use pkg-config for detecting libtiff in configure
This is more reliable than checking whether we can link with the library
manually and may work even if it's installed in a non-standard location.

It also allows the user to specify PKG_CONFIG_PATH='pkg-config --static'
when running configure to link with all transitional dependencies when
linking statically.

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

See #18293.
2018-12-13 03:53:44 +01:00
Vadim Zeitlin
c95f668b21 Fix use of dangling pointer in ButtonTestCase::Disabled()
Fix the test added in dfec7aa0c0 which
deleted the button pointer used by EventCounter by simply moving
EventCounter initialization after the button re-creation.

See #16385.
2018-12-13 00:39:25 +01:00
Vadim Zeitlin
141f0cb0e4 Suppress harmless gcc missing initializers warnings in a test
Suppressing the warnings is ugly but less ugly than explicitly
specifying all the omitted elements in the array.
2018-12-12 23:45:09 +01:00
Vadim Zeitlin
cf25bbbf9a Merge branch 'window-create-disabled'
Make calling wxWindow::Disable() before wxWindow::Create() work.

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

Closes #16385.
2018-12-12 18:24:10 +01:00
Graham Dawes
ac55d06bc1 Fix a crash when setting a menu icon to a null bitmap in wxQt
Previous implementation didn't take into account that
wxBitmap::GetHandle() could return NULL for wxQt. Specifically when
wxBitmap::IsNull returns true.

Closes https://github.com/wxWidgets/wxWidgets/pull/1071
2018-12-12 18:14:45 +01:00
Graham Dawes
331dc1fdfe Change wxFont::GetEncoding to return UTF8 for wxQt
QT doesn't have the concept of font encoding and is generally Unicode
aware throughout. The previous implementation of wxFont::GetEncoding for
wxQT returned a nonsensical value.

Closes https://github.com/wxWidgets/wxWidgets/pull/1070
2018-12-12 18:13:54 +01:00
Graham Dawes
6c5c9e578b wxCarioContext:Flush now draws back to the QT image
wxCairoContext::Flush was flushing back to the internal image but this
image wasn't drawn back to the QPainter until the wxCarioContext
instance was destroyed.

This fix ensure that after a call to Flush, anything drawn by Cario is
drawn back to the QImage.

Closes https://github.com/wxWidgets/wxWidgets/pull/1068
2018-12-12 18:12:36 +01:00
Vadim Zeitlin
3a24beca62 Document that wxDataViewCtrl now always expands its last column
This has been changed back in 4156e1a5c9
and is a (mildly) incompatible change, so document it in the appropriate
change log section.

See #18295.
2018-12-12 18:01:41 +01:00
Liam Treacy
e7260cffe0 Fix wxRadioBox::Show() behaviour in wxQt
If a QGroupBox is not visible, then you cannot set any of items to be
visible. Update the implementation to match that expected by wx.

Closes https://github.com/wxWidgets/wxWidgets/pull/1065
2018-12-12 03:23:24 +01:00
Liam Treacy
418a1b747e Select first item of wxRadioBox by default in wxQt too
Follow the other ports and select the first radio box item when it's
created, to ensure that it always has selection.

See https://github.com/wxWidgets/wxWidgets/pull/1065
2018-12-12 03:21:17 +01:00
Liam Treacy
2a64b65149 Fix enabling radiobox buttons in wxQt
If a QGroupBox is disabled, then you cannot set any of its items to be
enabled without first enabling it. Enabling/disabling it will set that
value (true/false) on all of its items, although setting the QGroupBox
to an enabled state which it already has does not result in this
behaviour.

Fix wxQt to match the expected wxRadioBox behaviour and allow the unit
test to pass.

Closes https://github.com/wxWidgets/wxWidgets/pull/1064
2018-12-10 19:52:22 +01:00
Liam Treacy
91a87e765b Don't omit "int" in wxQt wxRadioBox::GetCount() signature
No real changes, just use "unsigned int" instead of just "unsigned".

See https://github.com/wxWidgets/wxWidgets/pull/1064
2018-12-10 19:51:52 +01:00
Stefan Ziegler
0c2956be09 Fix wxInfoBar close button size in high DPI
Don't apply the scaling factor twice when dynamically creating the close
button bitmap.

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

Closes #18283.
2018-12-10 19:48:04 +01:00
Vadim Zeitlin
8ec8a0cf66 Define WX_WEB_EXTENSIONS_DIRECTORY in static builds too
This definition is needed when building both shared and static webview
library when using WebKit 2, but for some reason wasn't included for the
latter.

Closes https://github.com/wxWidgets/wxWidgets/pull/1061
2018-12-10 19:31:40 +01:00
Graham Dawes
611f678b51 Implement of wxFontEnumerator::EnumerateFacenames() in wxQt
Closes https://github.com/wxWidgets/wxWidgets/pull/1056
2018-12-10 19:25:21 +01:00
Vadim Zeitlin
251561172a Remove mentions of non-existent docs/$toolkit/install.txt
Don't include these files in "make dist" (which seems completely unused
anyhow, and probably broken because of this).
2018-12-10 19:06:18 +01:00
Vadim Zeitlin
cf28473d9f Mention that wx.bkl doesn't need to be updated for micro releases
Only WX_VERSION_DEFAULT value, which doesn't include the micro version
component, needs to be updated in this file.
2018-12-10 19:06:18 +01:00
Vadim Zeitlin
ea7926ad8d Remove the list of changes since 3.1.1 from the README
This will hopefully make things less confusing when preparing for the
next release.
2018-12-10 19:06:18 +01: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
Vadim Zeitlin
c0cb5cacd9 Don't try updating version in non-existent docs/msw/install.txt
This file doesn't exist any more and install.md which replaced it
doesn't contain any references to the version.
2018-12-10 19:06:18 +01:00
Vadim Zeitlin
d8a41187ed Update "How to make releases" instructions
Remove update steps for wxBlog (because it's redundant with the news
post on www.wxwidgets.org now that both are hosted at the same site),
Google+ (because of its extinction) and Buildbot (because we're going to
stop using it soon anyhow).

Add a step for updating the list of compilers used for building
binaries.
2018-12-10 18:35:48 +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
Vadim Zeitlin
96f3832d52 Override DoEnable() instead of Enable() in wxGTK controls
This is slightly simpler, as it doesn't require checking whether the
control state really changes or not (it always does if DoEnable() is
called) and allows disabling the controls before creating them, e.g.
code like

    wxButton* const b = new wxButton();
    b->Disable();
    b->Create(this, wxID_OK);

works as expected now instead of spewing GTK+ errors.
2018-12-09 19:21:51 +01:00
Vadim Zeitlin
5ba1ba1162 Fix creating disabled windows in wxGTK too
Don't forbid calling Enable() before creating the window and just do
nothing in this case and do disable the window when it's actually
created if it's supposed to be disabled.

Note that this doesn't work for classes overriding Enable() directly,
such as wxButton or wxCheckBox, currently.
2018-12-09 19:20:50 +01:00
Vadim Zeitlin
dfec7aa0c0 Make disabling the window before creating it actually work
Disabling a window before actually creating it ought to work, similarly
to hiding a window before creating it which can be used to avoid showing
the window on screen at all, even briefly. However it didn't under MSW
where the window was disabled from wxWidgets point of view, but not at
the MSW level.

Fix this by accounting for the enabled state in MSWGetStyle().

Closes #16385.
2018-12-09 19:20:50 +01:00
Vadim Zeitlin
edbee125f9 Slightly improve instructions for updating docs/release.md
It makes more sense to update it manually once and then run the script
rather than partially updating it manually first, then updating it again
and then running the script.
2018-12-09 16:55:42 +01:00
Vadim Zeitlin
d06720d4c9 Update SHA-1 sums for 3.1.2 release source archives
This is the result of running ./build/tools/post-release.sh
2018-12-09 16:53:25 +01:00
Vadim Zeitlin
b8f791877e Fix SHA-1 update script to work with the current release.md
Change the regex used to find the lines to update to actually find them.
2018-12-09 16:52:40 +01:00
Vadim Zeitlin
2b612603d3 Give an error from build/tools/post-release.sh if it didn't work
The script gave a misleading success message even if it didn't find
anything to update.
2018-12-09 16:51:29 +01:00
Vadim Zeitlin
33cb18f5e1 Link to the installation instructions from the main manual page
Installation is traditionally the worst (or at least the first) problem
for new wxWidgets users, so make it simpler to find these instructions.
2018-12-09 16:40:08 +01:00
Vadim Zeitlin
f456f52493 Add a text file to be shown after finishing wxMSW installation
We used docs/msw/install.txt for this previously, but it was too long to
be comfortably viewed in the installation wizard and also incidentally
doesn't exist any more, so add a new, short file just referring the user
to its replacement.
2018-12-09 16:40:08 +01:00
Vadim Zeitlin
653f9b14f0 Don't reference inexistent docs/msw/install.txt in wxwidgets.iss
Use install.md which is probably not ideal, but it at least allows Inno
Setup to successfully build the installer.
2018-12-09 16:18:06 +01:00
Vadim Zeitlin
a18fc6ce96 Normalize line endings in wxwidgets.iss
This file was a mix of DOS and Unix EOLs, convert it entirely to the
former.

No real changes.
2018-12-09 16:10:51 +01:00
Vadim Zeitlin
61320731e9 Merge branch 'pre-3.1.2-updates'
Update release-related files for 3.1.2.

See https://github.com/wxWidgets/wxWidgets/pull/1057
2018-12-09 15:55:49 +01:00
Sebastian Walderich
ab1fd56977 Implement wxAuiNotebook::HitTest()
Check if point is on window or a certain tab.

Closes https://github.com/wxWidgets/wxWidgets/pull/1059
2018-12-09 15:52:30 +01:00
Vadim Zeitlin
f170ab3b61 Remove duplicate words
s/new new/new/
2018-12-09 00:35:27 +01:00
Vadim Zeitlin
089eeea3ef Fix wxMSW build with wxUSE_UXTHEME==0
Make wxUxThemeIsActive() available even in this case to fix compilation
in some places and add the unavoidable preprocessor checks in other
ones.

Closes #18207.
2018-12-08 20:24:05 +01:00
oleksii.vorobiov
fd5c62bc41 Make updating the value in wxEVT_SPINCTRL work in wxMSW
In wxMSW, the value of the control was modified after executing the
user-defined wxEVT_SPINCTRL handler which meant that any calls to
SetValue() there were effectively ignored.

Fix this and add a unit test checking for the described scenario.

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

Closes #18187.
2018-12-08 19:51:56 +01:00
Vadim Zeitlin
b408e4c630 Update the release notes for 3.1.2
Change the version and update the list of MinGW compilers for which the
binaries are provided in this release.
2018-12-08 19:16:49 +01:00
Vadim Zeitlin
aef36f912a Fix 3.1.2 release date in the change log and the manual 2018-12-08 19:16:49 +01:00
Vadim Zeitlin
2e007cb3ec Update the list of changes before 3.1.2 release
Update both the (more detailed) README and the (shorter) announcement
message.

Also update the statistics and the cumulated changes since 3.0.
2018-12-08 19:16:27 +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
36aa63f2fd Slightly improve README wording
Also add direct links to the installation instructions.
2018-12-08 18:53:36 +01:00