Add wxBitmap::SetScaleFactor()

We need to be able to change the scale factor of the bitmaps returned by
wxBitmapBundle::GetBitmap(), so add a function allowing to do this.

Also add wxHAS_BITMAP_SCALE_FACTOR allowing to check whether this
function actually does something non-trivial and explain in the docs
that GetScaleFactor() always returns 1 on the platforms where this
symbol is not defined.
This commit is contained in:
Vadim Zeitlin
2021-10-23 21:18:37 +02:00
parent c8f76dea8e
commit 2c1f4c002d
8 changed files with 66 additions and 4 deletions

View File

@@ -167,6 +167,9 @@ Currently the following symbols exist:
have an efficient (CPU-specific) implementation. Notice that the functions
themselves are always available but can be prohibitively slow to use when
implemented in a generic way, using a critical section.}
@itemdef{wxHAS_BITMAP_SCALE_FACTOR, Defined in @c wx/bitmap.h if bitmaps
actually use scale factor under the current platform, see
wxBitmap::SetScaleFactor().}
@itemdef{wxHAS_BITMAPTOGGLEBUTTON, Defined in @c wx/tglbtn.h if
wxBitmapToggleButton class is available in addition to wxToggleButton.}
@itemdef{wxHAS_CONFIG_TEMPLATE_RW, Defined if the currently used compiler