Usage (signatures)
board.create('minorsector', [center, p1, p2]);
A minor sector is a sector of a circle around center spanning an angle of less than or equal to
180 degrees (π radians) and starts at p1. The radius is determined by p1, the angle by p2.
Parameters
| Name | Type | Description |
|---|---|---|
center |
PointLike | |
p1 |
PointLike | |
p2 |
PointLike |
Examples
// Create sector out of three free points
var center = board.create('point', [2.0, 2.0]);
var p1 = board.create('point', [1.0, 0.5]);
var p2 = board.create('point', [3.5, 1.0]);
var a = board.create('minorsector', [center, p1, p2]);
var A = board.create('point', [3, -2]),
B = board.create('point', [-2, -2]),
C = board.create('point', [0, 4]);
var angle = board.create('minorsector', [B, A, C], {
strokeWidth: 0,
arc: {
visible: true,
strokeWidth: 3,
lastArrow: {size: 4},
firstArrow: {size: 4}
}
});
// angle.arc.setAttribute({firstArrow: false});
angle.arc.setAttribute({lastArrow: false});
Throws
-
If the element cannot be constructed with the given parent objects an exception is thrown.
- Type
- Error
Details
- Type
- JXG.Curve
- Source
- element/sector.js, line 1053