From 825842b41196b5e0017debc4dba85367f76b3c0c Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Tue, 27 Mar 2012 12:28:01 +0000 Subject: [PATCH] Make wxDC::Blit() and StretchBlit() documentation more useful. Enumerating the list of parameters in the method description is not especially helpful, don't do it. Explain the functions relationship instead. Also don't say that StretchBlit() is not implemented in wxGTK because it does work there (using the generic implementation using wxDC scale). git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@71027 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- interface/wx/dc.h | 25 +++++++++++++++---------- 1 file changed, 15 insertions(+), 10 deletions(-) diff --git a/interface/wx/dc.h b/interface/wx/dc.h index 4089c9e389..8d8547bb72 100644 --- a/interface/wx/dc.h +++ b/interface/wx/dc.h @@ -1118,10 +1118,12 @@ public: //@{ /** - Copy from a source DC to this DC, specifying the destination - coordinates, size of area to copy, source DC, source coordinates, - logical function, whether to use a bitmap mask, and mask source - position. + Copy from a source DC to this DC. + + With this method you can specify the destination coordinates and the + size of area to copy which will be the same for both the source and + target DCs. If you need to apply scaling while copying, use + StretchBlit(). @param xdest Destination device context x position. @@ -1185,10 +1187,15 @@ public: wxCoord xsrcMask = wxDefaultCoord, wxCoord ysrcMask = wxDefaultCoord); /** - Copy from a source DC to this DC, specifying the destination - coordinates, destination size, source DC, source coordinates, size of - source area to copy, logical function, whether to use a bitmap mask, - and mask source position. + Copy from a source DC to this DC possibly changing the scale. + + Unlike Blit(), this method allows to specify different source and + destination region sizes, meaning that it can stretch or shrink it + while copying. The same can be achieved by changing the scale of the + source or target DC but calling this method is simpler and can also be + more efficient if the platform provides a native implementation of it. + + The meaning of its other parameters is the same as with Blit(). @param xdest Destination device context x position. @@ -1248,8 +1255,6 @@ public: There is partial support for Blit() in wxPostScriptDC, under X. - StretchBlit() is only implemented under wxMAC and wxMSW. - See wxMemoryDC for typical usage. @since 2.9.0 -- 2.47.2