@@ -41,7 +41,7 @@ class Line2(object):
41
41
42
42
def __init__ (self , start , end ):
43
43
"""
44
- Create a new line 2 from start to end.
44
+ Create a new line from start to end.
45
45
46
46
:param start: the start point
47
47
:type start: :class:`pygorithm.geometry.vector2.Vector2`
@@ -151,7 +151,8 @@ def slope(self):
151
151
The slope may be 0 (horizontal line) or positive or negative
152
152
infinity (vertical lines). It may be necessary to handle
153
153
these lines seperately, typically through checking the
154
- :py:attr:`~horizontal` and :py:attr:`~vertical` properties.
154
+ :py:attr:`~pygorithm.geometry.line2.Line2.horizontal` and
155
+ :py:attr:`~pygorithm.geometry.line2.Line2.vertical` properties.
155
156
156
157
157
158
:returns: the slope of this line (rise over run).
@@ -170,13 +171,14 @@ def y_intercept(self):
170
171
.. caution::
171
172
172
173
This function will return a y-intercept for non-vertical
173
- line segments that do not reach x=0.
174
+ line segments that do not reach :code:` x=0` .
174
175
175
176
.. caution::
176
177
177
178
The y-intercept will change based on the offset in a somewhat
178
- complex manner. :py:meth:`~calculate_y_intercept` accepts an
179
- offset parameter.
179
+ complex manner.
180
+ :py:meth:`~pygorithm.geometry.line2.Line2.calculate_y_intercept`
181
+ accepts an offset parameter.
180
182
181
183
:returns: the y-intercept of this line when unshifted
182
184
:rtype: :class:`numbers.Number` or None
@@ -202,7 +204,7 @@ def vertical(self):
202
204
Get if this line is vertical, lazily initialized.
203
205
204
206
A line is vertical if it has a slope of +inf or -inf. This
205
- also means that :code:` start.x == end.x`.
207
+ also means that `` start.x == end.x` `.
206
208
207
209
:returns: if this line is vertical
208
210
:rtype: bool
0 commit comments