5.2 KiB
LibFile: quotes.scad
To use, add the following lines to the beginning of your file:
include <BOSL2/std.scad>;
include <quotes.scad>;
File Contents
quote()
– Draws a dimension line with optional text labeling the length.arrowed_line()
– Draws a straight line with arrowheads at both ends.ext_line()
– Draws a straight extruded line between two points.
Module: quote()
Synopsis: Draws a dimension line with optional text labeling the length.
Topics: Dimensioning, Annotation
Description:
Creates a labeled dimension line with extension lines and an optional length label. The dimension can be customized in terms of placement, orientation, text formatting, and appearance.
Arguments:
By Position | What it does |
---|---|
length |
The length of the dimension line. |
textSize |
Size of the text label [default: 60]. |
offsetFromOrigin |
Distance of the dimension line from the reference [default: textSize]. |
extendBeyondDimLines |
Length beyond the extension lines [default: textSize / 5]. |
textOffset |
Offset of the text from the dimension line [default: textSize / 3]. |
color |
Color of the dimension line and text [default: "Red"]. |
placement |
Position relative to the model (TOP or BOTTOM) [default: TOP]. |
strokeWidth |
Thickness of the lines [default: 1]. |
font |
Font used for text [default: "Saira Stencil One"]. |
orient |
Text orientation (TOP or BOTTOM) [default: TOP]. |
anchor |
Text alignment reference (CENTER, LEFT, RIGHT) [default: CENTER]. |
spin |
Spin. |
Example 1: Simple quote

include <BOSL2/std.scad>;
include <quotes.scad>;
quote(length=100, textSize=50);
Example 2: Spin -90

include <BOSL2/std.scad>;
include <quotes.scad>;
quote(length=100, textSize=50,spin=-90);
Example 3: Orient FRONT

include <BOSL2/std.scad>;
include <quotes.scad>;
quote(length=100, textSize=50,orient=FRONT);
Example 4: Orient TOP

include <BOSL2/std.scad>;
include <quotes.scad>;
quote(length=100, orient=TOP);
Example 5: offsetFromOrigin 20

include <BOSL2/std.scad>;
include <quotes.scad>;
quote(length=100, offsetFromOrigin=20);
Example 6: extendBeyondDimLines 20

include <BOSL2/std.scad>;
include <quotes.scad>;
quote(length=100, extendBeyondDimLines=20);
Module: arrowed_line()
Synopsis: Draws a straight line with arrowheads at both ends.
Topics: Geometry, Arrows, Lines
Description:
Creates a linear extrusion representing a line with arrowheads at both ends. The line thickness, length, and arrow size can be customized.
Arguments:
By Position | What it does |
---|---|
point1 |
[x, y] start point of the line. |
point2 |
[x, y] end point of the line. |
width |
Thickness of the line [default: 0.1]. |
endcap_width |
Width of the arrowhead at each end [default: 15]. |
Example 1:

include <BOSL2/std.scad>;
include <quotes.scad>;
arrowed_line([0,0], [50,50], width=0.5, endcap_width=5);
Module: ext_line()
Synopsis: Draws a straight extruded line between two points.
Description:
Creates a linear extrusion representing a straight line segment with a specified width between two given points.
Arguments:
By Position | What it does |
---|---|
point1 |
[x, y] start point of the line. |
point2 |
[x, y] end point of the line. |
width |
Thickness of the line [default: 0.1]. |
Example 1:

include <BOSL2/std.scad>;
include <quotes.scad>;
ext_line([0,0], [50,50], width=0.5);