summaryrefslogtreecommitdiff
path: root/lib/glshape.cc
diff options
context:
space:
mode:
Diffstat (limited to 'lib/glshape.cc')
-rw-r--r--lib/glshape.cc12
1 files changed, 10 insertions, 2 deletions
diff --git a/lib/glshape.cc b/lib/glshape.cc
index 9257257..e1c1faf 100644
--- a/lib/glshape.cc
+++ b/lib/glshape.cc
@@ -40,10 +40,18 @@ void mogltk::glshape::hline(int x1, int x2, int y, ColorP c1, ColorP c2) {
box(x1, y, x2, y, c1, c2, c1, c2);
}
+void mogltk::glshape::hline(int x1, int x2, int y, ColorP c) {
+ box(x1, y, x2, y, c, c, c, c);
+}
+
void mogltk::glshape::vline(int x, int y1, int y2, ColorP c1, ColorP c2) {
box(x, y1, x, y2, c1, c1, c2, c2);
}
+void mogltk::glshape::vline(int x, int y1, int y2, ColorP c) {
+ box(x, y1, x, y2, c, c, c, c);
+}
+
void mogltk::glshape::pixel(int x, int y, ColorP c) {
box(x, y, x, y, c);
}
@@ -59,8 +67,8 @@ void mogltk::glshape::obox(int x1, int y1, int x2, int y2, ColorP c1, ColorP c2,
hline(x1, x2, y1, c1, c2);
hline(x1, x2, y2, c3, c4);
- vline(x1, y1, y2, c1, c3);
- vline(x2, y1, y2, c2, c4);
+ vline(x1, y1 + 1, y2 - 1, c1, c3);
+ vline(x2, y1 + 1, y2 - 1, c2, c4);
LEAVE;
}