chiark
/
gitweb
/
~ian
/
sgt-puzzles.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
draw_thick_line: Bound thickness by 1.0 below
[sgt-puzzles.git]
/
drawing.c
diff --git
a/drawing.c
b/drawing.c
index 7f4a6cf6746eabdea9fba7a63f6d9b9900ef35d0..a10a7f06d68553c827347c7e249c704cc8fea272 100644
(file)
--- a/
drawing.c
+++ b/
drawing.c
@@
-90,6
+90,8
@@
void draw_line(drawing *dr, int x1, int y1, int x2, int y2, int colour)
void draw_thick_line(drawing *dr, float thickness,
float x1, float y1, float x2, float y2, int colour)
{
void draw_thick_line(drawing *dr, float thickness,
float x1, float y1, float x2, float y2, int colour)
{
+ if (thickness < 1.0)
+ thickness = 1.0;
if (dr->api->draw_thick_line) {
dr->api->draw_thick_line(dr->handle, thickness,
x1, y1, x2, y2, colour);
if (dr->api->draw_thick_line) {
dr->api->draw_thick_line(dr->handle, thickness,
x1, y1, x2, y2, colour);