Handle negative width size in GDI+ DrawRectangle() and document it
Apparently it's a common convention to allow width and/or height of a rectangle to be negative as both GDI and Cairo handle this natively, so also allow this for GDI+ and document this as the expected behaviour. Closes #17495.
This commit is contained in:
committed by
Vadim Zeitlin
parent
cb08b32f43
commit
bb2b48f2ba
@@ -523,8 +523,14 @@ public:
|
||||
wxPolygonFillMode fill_style = wxODDEVEN_RULE);
|
||||
|
||||
/**
|
||||
Draws a rectangle with the given top left corner, and with the given
|
||||
size. The current pen is used for the outline and the current brush
|
||||
Draws a rectangle with the given corner coordinate and size.
|
||||
|
||||
Normally, @a x and @a y specify the top left corner coordinates and
|
||||
both @a width and @a height are positive, however they are also allowed
|
||||
to be negative, in which case the corresponding corner coordinate
|
||||
refers to the right or bottom corner instead.
|
||||
|
||||
The current pen is used for the outline and the current brush
|
||||
for filling the shape.
|
||||
*/
|
||||
void DrawRectangle(wxCoord x, wxCoord y, wxCoord width, wxCoord height);
|
||||
|
Reference in New Issue
Block a user