<triangle>
<triangle>
is a Graphical
component that renders a triangle when nested inside a <graph>
component.
Attributes and Properties
Attribute | Type | Values |
---|---|---|
allowDilation = "…" | boolean | "true" "false" |
allowRotation = "…" | boolean | "true" "false" |
allowTranslation = "…" | boolean | "true" "false" |
applyStyleToLabel = "…" | boolean | "true" "false" |
displayDecimals = "…" | integer | |
displayDigits = "…" | integer | |
displaySmallAsZero = "…" | number | |
draggable = "…" | boolean | "true" "false" |
filled = "…" | boolean | "true" "false" |
labelIsName = "…" | boolean | "true" "false" |
layer = "…" | integer | |
minShrink = "…" | ||
padZeros = "…" | boolean | "true" "false" |
preserveSimilarity = "…" | boolean | "true" "false" |
rigid = "…" | boolean | "true" "false" |
rotateAround = "…" | "centroid" "vertex" "point" | |
rotationCenter = "…" | ||
rotationHandleVertices = "…" | ||
rotationVertex = "…" | ||
showCoordsWhenDragging = "…" | boolean | "true" "false" |
vertices = "…" | [ math ] | |
verticesDraggable = "…" | boolean | "true" "false" |
Property | Type |
---|---|
$t.allowDilation | boolean |
$t.allowRotation | boolean |
$t.allowTranslation | boolean |
$t.applyStyleToLabel | boolean |
$t.area | number |
$t.borderStyleDescription | text |
$t.disabled | boolean |
$t.displayDecimals | integer |
$t.displayDigits | integer |
$t.displaySmallAsZero | number |
$t.draggable | boolean |
$t.filled | boolean |
$t.fillStyleDescription | text |
$t.fixed | boolean |
$t.fixLocation | boolean |
$t.hidden | boolean |
$t.label | label |
$t.labelIsName | boolean |
$t.layer | integer |
$t.numDimensions | number |
$t.numSides | number |
$t.numVertices | number |
$t.padZeros | boolean |
$t.perimeter | number |
$t.preserveSimilarity | boolean |
$t.rigid | boolean |
$t.showCoordsWhenDragging | boolean |
$t.styleDescription | text |
$t.styleDescriptionWithNoun | text |
$t.vertices | [ math ] |
$t.verticesDraggable | boolean |
Example: Default <triangle>
The default <triangle>
has vertices at and
Example: <triangle>
constrained to a grid
The vertices of a <triangle>
are predefined as constrained points, thereby constraining the triangle to a grid as well.
Attribute Example: vertices
The vertices
attribute takes a list of points as its input.
Attribute Example: filled
The filled
attribute renders the triangle with default shading to match the styleNumber.
Attribute Example: draggable
The draggable
attribute determines whether the <triangle>
can be dragged around the <graph>
. All graphical objects are draggable by default.
Attribute Example: verticesDraggable
Vertices are draggable by default. Use the verticesDraggable
attribute set to false to disable users from changing the proportions of the <triangle>
. The triangle as a whole can still be repositioned on the <graph>
.
Attribute Example: Standard graphical attributes
The uses of the following standard graphical attributes are illustrated: hide
, fixLocation
, layer
, styleNumber
, applyStyleToLabel
and labelIsName
.
Properthy Example: Style properties
The styleDescription
, styleDescriptionWithNoun
, fillStyleDescription
, and borderStyleDescription
properties render a text description corresponding to the styleNumber
of the component.