The old code in wxToolBarBase::AdjustToolBitmapSize() forced the use of
the exact value of the requested bitmap size multiplied by the current
scale factor, which resulted in ugly bitmaps whenever fractional scaling
factor was used. It also used not immediately clear IncTo() call.
Simplify and improve it by handling the cases when we have a requested
bitmap size and we don't have it differently: if we do have it, just use
it directly, but only with an integer scale factor. And if we don't,
then simply use the bitmap size suitable for the current scale factor.
This seems to result in the most expected behaviour and, notably,
doesn't break the toolbar sample where the bitmap size can still be
toggled between small and big bitmaps on both normal and high DPI
monitors.
Also update the documentation: still recommend not to use
SetToolBitmapSize() at all, but don't claim that it forces fractional
scaling, as this is not the case any longer.
3-state checkboxes can have their initial value set to checked
or undetermined -- this adds support for the undetermined
state to the handler (only allowed if the style includes wxCHK_3STATE).
Closes#22468.
The alphabetical order for this handler was wrong, affecting not
only it's placement in the main HTML page, but also the list of
handlers on the right side.
This commit is best viewed with git --color-moved option.
Closes#22478.
This commit fixes a formatting problem with these two files
when built with Doxygen version 1.9.3.
The correct encoding is to escape the quotes and the backslash.
While the older style encoding used to work, it is no longer
supported due to a fix with how a single quote gets handled
by Doxygen. The escaped version works with Doxygen 1.8.17
so this will work fine with the current build version as well as
in more recent versions (tested with 1.9.3).
Closes#22461.
This is just to make all the version information consistent within this
file. This is primarily for properties that were added in a specific
wxWidgets version.
Closes#22456.
Add support for the missing wxBU_NOTEXT style, bitmaps for the other
than default states (pressed, focus, disabled and current) and margins
to wxBitmapXmlHandler.
Note that the images for the other states were previously already
supported by wxBitmapButton XRC handler, but not by the wxBitmap one,
even though both bitmap classes support them.
Closes#22451.
Change "order" to "reverse order" in "... dynamically bound handlers
are searched in order of their registration ...".
Use better check for C++11 in a code example.
Unify whitespace usage in code examples.
This is the version available in Ubuntu 20.04 which is currently used
both on docs.wxwidgets.org and in GitHub Actions Ubuntu environment, so
it looks like a reasonable choice, even though the latest version is
1.9.3.
Note that the versions earlier than 1.8.14 can't be used any longer
since the changes in the previous commit because "^^" in the aliases
definition don't work in them and result in garbled output.
Removing "docs/doxygen" and "interface" was both ambiguous (because it
wasn't immediately clear which file the message was referring to) and
insufficient because there are now Markdown files in the other other
directories used as Doxygen input too, and they still appeared with the
full paths.
Fix both problems by removing just the top level directory from all
paths and keeping all the rest.
The new name, recently introduced in 94716fd801 (Add
wxBitmap::CreateWithLogicalSize(), 2022-01-22), was perhaps more clear,
but also misleading and confusing because the postcondition
CreateWithLogicalSize(size, 2).GetLogicalSize() == size
was not satisfied under MSW, so rename it once again, and hopefully
finally, because the new name is consistent with GetDIPSize() returning
the same size.
Also try to improve the documentation a bit more.
SetIncrement() was already available in wxSpinCtrlDouble and GTK version
of wxSpinCtrl, now implement support for it in wxMSW and wxOSX as well.
In fact, in wxMSW, implement it at wxSpinButton level, so that both this
class and wxSpinCtrl inheriting from it (in wxMSW only) support setting
custom increment now.
Also add support for it to XRC, show it in the sample and add a unit
test verifying that it works.
Closes#2597.
Vcpkg defaults to installing packages for x86-windows, and from the
perspective of x64 builds, the packages installed just cannot be
found -- and the reason is not very obvious.
Having an example with commands that will install both x86 and x64 is
probably the right thing to do in this day and age -- and if somebody
only wants one and not the other, seeing a package name with architecture
specified helps with guessing how to achieve that.
Closes#22075.
We often need the logical bitmap size when using it in size computations
involving window size, so add a function returning it directly to
wxBitmapBundle, similarly to wxBitmap::GetLogicalSize(), to avoid using
FromPhys() everywhere.
Also rename the existing wxBitmapBundle::GetPreferredSizeFor() to
GetPreferredBitmapSizeFor() to make it more clear that this is similar
to wxBitmap::GetSize() and so returns the size in physical units.
Closes#22056.
These functions have better names than the existing GetScaledXXX() ones,
so add them to be able to use them in the new code, even if we still
keep the old ones for compatibility.
Also add a diagram showing the functions to use to convert between them,
perhaps this can be more clear than textual description.
Co-Authored-By: Stefan Csomor <csomor@advancedconcepts.ch>