Adobe have announced the official EOL for flash is 2020 so we're
now at the point where support for flash just isn't interesting
any more.
It doesn't make sense to support it for the upcoming 3.2.x release
series, and the sample .swf files are lacking source code.
Closes https://github.com/wxWidgets/wxWidgets/pull/1427Closes#15886.
Set the "printer" PPI explicitly for wxMemoryDC used in the test to
ensure that it's the same in all ports: currently wxGTK3 stands out
because it uses 72 DPI unlike wxMSW and wxGTK2, which use 96.
There seems to be something wrong with the vertical offset returned by
gtk_entry_get_layout_offsets() in GTK 3, so just don't use it at all, as
we don't need it anyhow.
For some reason, the control does lose focus there, even if it doesn't
happen when using a normal X11 server.
Just disable the test in this environment.
This will allow disabling some tests which fail when running only under
Xvfb.
The new function doesn't work automatically because there doesn't seem
to be any way to distinguish it from the usual server, so it just checks
whether wxUSE_XVFB=1 is set in the environment, as is done by Travis CI
build script.
Older versions of the server default to 8bpp, which breaks some of our
tests (admittedly, this shouldn't be the case, but it's probably better
to test in the same configuration as is used by 99.99% of the users
rather than adjusting or disabling tests in the remaining 0.01%).
The tests are known to fail for the other tested ports, so don't enable
them for now.
Also, using a special environment variable allows to detect when the
test is being run under Xvfb, which behaves differently from the normal
X server in some cases.
The fix for visual artefacts when resizing columns with comctl32.dll v6
introduced them when using v5 of the DLL, so apply it only conditionally
now.
See #18032, #18441.
LVS_EX_DOUBLEBUFFER doesn't seem to work correctly with comctl32.dll v5,
and results in artefacts when the control is resized, so don't enable it
for it.
Closes#18441.
This parameter is not modified by wxColourDialog (this might have been
the case, or at least the plan, some long time ago) and so has no reason
not to be "const".
Just add the qualifier to ctor and Create() in all ports.
Closes https://github.com/wxWidgets/wxWidgets/pull/1421Closes#12511.
We need to wait until wxDataViewCtrl is realized for its columns widths
to be actually set, as calling gtk_tree_view_column_set_fixed_width()
just queues a resize that will take effect later, as documented in the
previous commit.
It may be surprising that calling GetWidth() after SetWidth(100) still
returns 0, so at least document this behaviour (fixing it doesn't seem
to be easily possible).
Add wxGrid::FreezeTo() method which allows to freeze the given number of
columns and/or rows at the beginning of the grid, i.e. keep them pinned
in place while the rest of the grid is scrolled.
The main wxGridWindow (m_gridWin) now corresponds to the non-frozen part
of the grid, with up to 3 new similar windows for the frozen
rows/columns and the frozen corner cells (which only exist if both rows
and columns are frozen) being additionally used.
Doing this involved adding "wxGridWindow*" parameter to many functions
that previously only worked with m_gridWin itself and addressing
additional complications, such as mouse events that can now cross
different windows.
See https://github.com/wxWidgets/wxWidgets/pull/952 for the original
version of the changes.
Instead of doing it in overridden wxGridWindow::ScrollWindow(), do it
from wxGrid::ScrollWindow() itself, this makes more sense and will make
it easier to generalize it to scroll more windows.
No real changes yet.
Add two simple helpers: SetNativeHeaderColCount() and
SetNativeHeaderColOrder() and call the latter from the former to ensure
that the columns order is always correct when switching to the native
control.
This simple function combines BlockToDeviceRect() and
wxWindow::Refresh() calls and allows to avoid the ugly casts in
wxGridSelection code as well as making the code slightly shorter and
more clear.
No real changes.
This method can be overridden to indicate that the scrolled window
doesn't want its children to be scrolled into view when they're focused,
which is the default behaviour.
Also reuse this method for Mac-specific scrollbar workaround.
Reading native font info strings in v0 format, used by the previous
wxWidgets versions, resulted in creation of fonts with 0 point size,
which resulted in suboptimal user experience when such a font was used
to display text.
Fix this by initializing point size to the value corresponding to the
font height in pixels using the default DPI, just as we already do when
creating wxNativeFontInfo from a LOGFONT.
No real changes, just refactor the code previously present in both
wxNativeFontInfo ctor and SetPixelSize() in a single function and reuse
it in both places.
This not only cuts down on its size, but will make it simpler to skip
this test in the environments where web access is unavailable in the
upcoming commit.
Don't lose window position when the window is iconized, as this prevents
it from being correctly saved by wxPersitentTLW, for example, resulting
in failures in the corresponding unit test.
Unfortunately there doesn't seem to be any simple way to just ignore the
bogus (0, 0) configure events that we get from GTK when the window is
iconized, as explained in the comment, so we're reduced to remembering
the last position and restoring it when we realize that the window got
minimized and not moved, after all. This is obviously not ideal, as
there is still a lapse of time when (0, 0) is returned, but there just
doesn't seem to be anything better to do.
Add default ctor for this struct as it was too easy to forget to
initialize it otherwise, ending up with bogus values in it, as it
happened with wxTLWGeometry::m_decorSize, which resulted in a failure in
wxPersistTLW unit test and, probably, real code too.