diff options
| author | Michael R Sweet <michael.r.sweet@gmail.com> | 2005-08-08 01:35:29 +0000 |
|---|---|---|
| committer | Michael R Sweet <michael.r.sweet@gmail.com> | 2005-08-08 01:35:29 +0000 |
| commit | afbd833c04cbde1dbb04f390d394635fad8ae5e2 (patch) | |
| tree | a82eaf9264f1596c0490b970332a50a6e559f94b /src | |
| parent | eaaae8b05e78c85f9046d64b1bc400596fc8df82 (diff) | |
Fixed some plastic drawing artifacts (STR #906)
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@4479 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
Diffstat (limited to 'src')
| -rw-r--r-- | src/fl_plastic.cxx | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/src/fl_plastic.cxx b/src/fl_plastic.cxx index 6a88e2788..b07ab65b0 100644 --- a/src/fl_plastic.cxx +++ b/src/fl_plastic.cxx @@ -167,7 +167,7 @@ static void shade_rect(int x, int y, int w, int h, const char *c, Fl_Color bc) { for (i = 0, j = 0; j < chalf; i ++, j += cstep) { // Draw the top line and points... fl_color(shade_color(g[c[i]], bc)); - fl_xyline(x + 1, y + i, x + w - 1); + fl_xyline(x + 1, y + i, x + w - 2); fl_color(shade_color(g[c[i] - 2], bc)); fl_point(x, y + i + 1); @@ -175,7 +175,7 @@ static void shade_rect(int x, int y, int w, int h, const char *c, Fl_Color bc) { // Draw the bottom line and points... fl_color(shade_color(g[c[clen - i]], bc)); - fl_xyline(x + 1, y + h - i, x + w - 1); + fl_xyline(x + 1, y + h - i, x + w - 2); fl_color(shade_color(g[c[clen - i] - 2], bc)); fl_point(x, y + h - i); @@ -202,26 +202,26 @@ static void shade_rect(int x, int y, int w, int h, const char *c, Fl_Color bc) { fl_color(shade_color(g[c[i] - 2], bc)); fl_point(x + i + 1, y); - fl_point(x + i + 1, y + h - 1); + fl_point(x + i + 1, y + h); // Draw the right line and points... fl_color(shade_color(g[c[clen - i]], bc)); fl_yxline(x + w - 1 - i, y + 1, y + h - 1); fl_color(shade_color(g[c[clen - i] - 2], bc)); - fl_point(x + w - 1 - i, y); - fl_point(x + w - 1 - i, y + h - 1); + fl_point(x + w - 2 - i, y); + fl_point(x + w - 2 - i, y + h); } // Draw the interior, top, and bottom... i = chalf / cstep; fl_color(shade_color(g[c[chalf]], bc)); - fl_rectf(x + i, y + 1, w - 2 * i, h - 2); + fl_rectf(x + i, y + 1, w - 2 * i, h - 1); fl_color(shade_color(g[c[chalf] - 2], bc)); fl_xyline(x + i, y, x + w - i); - fl_xyline(x + i, y + h - 1, x + w - i); + fl_xyline(x + i, y + h, x + w - i); } } |
