GDI+ nk_gdip_fill_rect background fix

1. Main background area was filled by 2 big overlapping rectangles. It works good on solid but not on semi-transparent themes. Just replaced 2 big rectangles with 1 big and 2 small.
2. There is no need in [nk_gdip_fill_rect filled pies fix](7ab7327fa4) anymore. It disturbs semi-transparent themes too.
This commit is contained in:
Dmitry Hrabrov 2017-10-01 13:33:52 +03:00 committed by GitHub
parent 708a7ebbc3
commit d0ed8bc3cf

View File

@ -458,8 +458,9 @@ nk_gdip_fill_rect(short x, short y, unsigned short w,
GdipFillRectangleI(gdip.memory, gdip.brush, x, y, w, h);
} else {
INT d = 2 * r;
GdipFillRectangleI(gdip.memory, gdip.brush, x + r - 1, y, w - d + 2, h);
GdipFillRectangleI(gdip.memory, gdip.brush, x, y + r - 1, w, h - d + 2);
GdipFillRectangleI(gdip.memory, gdip.brush, x + r, y, w - d, h);
GdipFillRectangleI(gdip.memory, gdip.brush, x, y + r, r, h - d);
GdipFillRectangleI(gdip.memory, gdip.brush, x + w - r, y + r, r, h - d);
GdipFillPieI(gdip.memory, gdip.brush, x, y, d, d, 180, 90);
GdipFillPieI(gdip.memory, gdip.brush, x + w - d, y, d, d, 270, 90);
GdipFillPieI(gdip.memory, gdip.brush, x + w - d, y + h - d, d, d, 0, 90);