File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed
src/main/java/technology/tabula Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -102,23 +102,23 @@ public boolean clip(Line2D.Float line) {
102
102
103
103
if ((c & LEFT ) != INSIDE ) {
104
104
qx = xMin ;
105
- qy = (qx -p1x )*slope + p1y ;
105
+ qy = (Utils . feq ( qx , p1x ) ? 0 : qx -p1x )*slope + p1y ;
106
106
}
107
107
else if ((c & RIGHT ) != INSIDE ) {
108
108
qx = xMax ;
109
- qy = (qx -p1x )*slope + p1y ;
109
+ qy = (Utils . feq ( qx , p1x ) ? 0 : qx -p1x )*slope + p1y ;
110
110
}
111
111
else if ((c & BOTTOM ) != INSIDE ) {
112
112
qy = yMin ;
113
113
qx = vertical
114
114
? p1x
115
- : (qy -p1y )/slope + p1x ;
115
+ : (Utils . feq ( qy , p1y ) ? 0 : qy -p1y )/slope + p1x ;
116
116
}
117
117
else if ((c & TOP ) != INSIDE ) {
118
118
qy = yMax ;
119
119
qx = vertical
120
120
? p1x
121
- : (qy -p1y )/slope + p1x ;
121
+ : (Utils . feq ( qy , p1y ) ? 0 : qy -p1y )/slope + p1x ;
122
122
}
123
123
124
124
if (c == c1 ) {
You can’t perform that action at this time.
0 commit comments