Make wxBitmap ctors consistent wrt passing scale for conversion from wxImage; HiDPI adaptation for propgrid buffer and wxRTC images
This commit is contained in:
@@ -31,7 +31,7 @@ public:
|
||||
wxBitmap(const wxString &filename, wxBitmapType type = wxBITMAP_DEFAULT_TYPE);
|
||||
wxBitmap(const char* const* bits);
|
||||
#if wxUSE_IMAGE
|
||||
wxBitmap(const wxImage& image, int depth = -1);
|
||||
wxBitmap(const wxImage& image, int depth = -1, double WXUNUSED(scale) = 1.0);
|
||||
#endif
|
||||
|
||||
bool Create(const wxIDirectFBSurfacePtr& surface);
|
||||
|
@@ -79,7 +79,7 @@ public:
|
||||
#endif
|
||||
wxBitmap( const wxString &filename, wxBitmapType type = wxBITMAP_DEFAULT_TYPE );
|
||||
#if wxUSE_IMAGE
|
||||
wxBitmap(const wxImage& image, int depth = wxBITMAP_SCREEN_DEPTH);
|
||||
wxBitmap(const wxImage& image, int depth = wxBITMAP_SCREEN_DEPTH, double scale = 1.0);
|
||||
#endif // wxUSE_IMAGE
|
||||
wxBitmap(GdkPixbuf* pixbuf, int depth = 0);
|
||||
wxEXPLICIT wxBitmap(const wxCursor& cursor);
|
||||
|
@@ -76,7 +76,7 @@ public:
|
||||
}
|
||||
#endif
|
||||
wxBitmap( const wxString &filename, wxBitmapType type = wxBITMAP_DEFAULT_TYPE );
|
||||
wxBitmap( const wxImage& image, int depth = -1 ) { (void)CreateFromImage(image, depth); }
|
||||
wxBitmap( const wxImage& image, int depth = -1, double WXUNUSED(scale) = 1.0 ) { (void)CreateFromImage(image, depth); }
|
||||
virtual ~wxBitmap();
|
||||
|
||||
bool Create(int width, int height, int depth = wxBITMAP_SCREEN_DEPTH);
|
||||
|
@@ -81,7 +81,7 @@ public:
|
||||
|
||||
#if wxUSE_IMAGE
|
||||
// Convert from wxImage
|
||||
wxBitmap(const wxImage& image, int depth = -1)
|
||||
wxBitmap(const wxImage& image, int depth = -1, double WXUNUSED(scale) = 1.0)
|
||||
{ (void)CreateFromImage(image, depth); }
|
||||
|
||||
// Create a DDB compatible with the given DC from wxImage
|
||||
|
@@ -28,7 +28,7 @@ public:
|
||||
wxBitmap(const wxSize& sz, int depth = wxBITMAP_SCREEN_DEPTH);
|
||||
wxBitmap(const char* const* bits);
|
||||
wxBitmap(const wxString &filename, wxBitmapType type = wxBITMAP_TYPE_XPM);
|
||||
wxBitmap(const wxImage& image, int depth = wxBITMAP_SCREEN_DEPTH);
|
||||
wxBitmap(const wxImage& image, int depth = wxBITMAP_SCREEN_DEPTH, double scale = 1.0);
|
||||
|
||||
// Convert from wxIcon / wxCursor
|
||||
wxBitmap(const wxIcon& icon) { CopyFromIcon(icon); }
|
||||
|
@@ -2499,6 +2499,12 @@ public:
|
||||
|
||||
bool GetDelayedImageLoading() const { return m_enableDelayedImageLoading; }
|
||||
|
||||
/**
|
||||
Returns the buffer pointer.
|
||||
*/
|
||||
|
||||
wxRichTextBuffer* GetBuffer() const { return m_buffer; }
|
||||
|
||||
wxRichTextBuffer* m_buffer;
|
||||
bool m_enableVirtualAttributes;
|
||||
bool m_enableImages;
|
||||
@@ -5064,7 +5070,7 @@ public:
|
||||
/**
|
||||
Do the loading and scaling
|
||||
*/
|
||||
virtual bool LoadAndScaleImageCache(wxImage& image, const wxSize& sz, bool delayLoading, bool& changed);
|
||||
virtual bool LoadAndScaleImageCache(wxImage& image, const wxSize& sz, wxRichTextDrawingContext& context, bool& changed);
|
||||
|
||||
/**
|
||||
Gets the original image size.
|
||||
|
@@ -100,7 +100,7 @@ public:
|
||||
int GetDepth() const;
|
||||
|
||||
#if wxUSE_IMAGE
|
||||
wxBitmap( const wxImage& image, int depth = -1 ) { (void)CreateFromImage(image, depth); }
|
||||
wxBitmap( const wxImage& image, int depth = -1, double WXUNUSED(scale) = 1.0 ) { (void)CreateFromImage(image, depth); }
|
||||
wxImage ConvertToImage() const;
|
||||
bool CreateFromImage(const wxImage& image, int depth = -1);
|
||||
#endif // wxUSE_IMAGE
|
||||
|
Reference in New Issue
Block a user