From 6de38c1f0e479c0dd227f100935a9ed8e9ed8e13 Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Thu, 9 Jul 2015 19:18:44 +0200 Subject: [PATCH] Document wxDC::{Set,Get}Logical{Scale,Origin}() functions. They are relatively important, especially the origin-related ones as SetUserScale() can (should?) be used instead of SetLogicalScale(), but SetLogicalOrigin() can be more convenient than SetDeviceOrigin(), so provide at least skeletal documentation for them. (cherry picked from commit 394b04b7e48c5857633236058c344529405f8e33) --- interface/wx/dc.h | 26 +++++++++++++++++++++++++- 1 file changed, 25 insertions(+), 1 deletion(-) diff --git a/interface/wx/dc.h b/interface/wx/dc.h index 9df4640a17..b59e3db013 100644 --- a/interface/wx/dc.h +++ b/interface/wx/dc.h @@ -1590,12 +1590,36 @@ public: wxBitmap GetAsBitmap(const wxRect *subrect = NULL) const; + /** + Set the scale to use for translating wxDC coordinates to the physical + pixels. + + The effect of calling this function is similar to that of calling + SetUserScale(). + */ void SetLogicalScale(double x, double y); + + /** + Return the scale set by the last call to SetLogicalScale(). + */ void GetLogicalScale(double *x, double *y) const; + + /** + Change the offset used for translating wxDC coordinates. + + @see SetLogicalOrigin(), SetDeviceOrigin() + */ void SetLogicalOrigin(wxCoord x, wxCoord y); + + //@{ + /** + Return the coordinates of the logical point (0, 0). + + @see SetLogicalOrigin() + */ void GetLogicalOrigin(wxCoord *x, wxCoord *y) const; wxPoint GetLogicalOrigin() const; - + //@} };