Appearance
hm5-types (source format) / ShapeElement
Interface: ShapeElement
Simple vector shape (Flash-like fills/strokes; UI chrome, masks, notes). No pen tool, no gradients — by design. Freehand exists as the VECTOR BRUSH: pressure→width, producing a filled outline like Flash's brush.
Extends
Properties
| Property | Type | Description | Inherited from |
|---|---|---|---|
anchors? | number[] | The REAL anchor points of the outline (owner 2026-11-05): flat [x, y, …] in the same space as rings — the points the user placed (Pen clicks, rectangle / PolyStar corners, an oval's four quarter points, points added with the Subselection tool). The Subselection tool shows these instead of guessing; a position that is no longer a vertex of rings is ignored. Absent = unknown (brush strokes, old files): the points are estimated (corners, ends, extremes). Baked / mapped together with the rings (bakePaint, mapPaint). | - |
bitmapFill? | BitmapFill | Flash bitmap fill: paints the fill area with an image (wins over gradient; fill stays the flat fallback colour) | - |
blendMode? | | "color" | "normal" | "multiply" | "screen" | "overlay" | "darken" | "lighten" | "add" | "difference" | "color-burn" | "color-dodge" | "linear-burn" | "hard-light" | "soft-light" | "exclusion" | "linear-light" | "pin-light" | "vivid-light" | "hard-mix" | "subtract" | "divide" | "saturation" | "luminosity" | "invert" | "layer" | "alpha" | "erase" | blend mode with what is under it; absent = normal. Switches at the next key of a classic tween. | ElementBase.blendMode |
colorEffect? | ColorEffect | Look (symbol instances, bitmaps, text, meshes, groups, video objects: hasLook; loose shapes ignore it). Flash Color Effect (alpha stays opacity); absent = none. Classic tweens interpolate it. | ElementBase.colorEffect |
fill? | string | RRGGBBAA; undefined = no fill. With a gradient it is the first stop. | - |
filters? | InstanceFilter[] | Filters (drop shadow, blur, glow, …), drawn in order on top of the instance; absent = none. Classic tweens interpolate them (see filter/catalog.ts). | ElementBase.filters |
gradient? | GradientFill | paints the fill area instead of the flat colour | - |
hidden? | boolean | Properties "Visible" off: not drawn in exports / publish (faint in the editor); a show action can still show it. Absent = drawn. | ElementBase.hidden |
id | string | - | ElementBase.id |
line? | boolean | this filled shape is an outline (a line turned into a band, or a line-tool line): "stroke colour" edits target it, fills never merge with it | - |
opacity | number | - | ElementBase.opacity |
open? | boolean | Lines: the rings are OPEN paths (centre lines drawn with stroke; no fill). A line is a separate object from any fill, like Flash; fills cut lines, lines never cut anything. | - |
primitive? | | { h: number; radius?: number; shape: "rect"; w: number; } | { rx: number; ry: number; shape: "ellipse"; } | { cx?: number; cy?: number; shape: "line"; width?: number; x2: number; y2: number; } | { points: number[]; shape: "brush"; size: number; } | Kept while the shape is untouched by the vector eraser, so the transform/properties panel can re-edit it parametrically. | - |
rings | number[][] | Authoritative render geometry: polygon rings (first = outer, rest = holes), flat [x,y,…]. Curves are polygonized. Brush outlines are computed from pressure points via perfect-freehand. The vector eraser does a boolean subtract on these and deletes primitive. | - |
slot? | SlotRef | SLOT ITEM (owner 2026-11-20, plan 2026-11-19-mesh-slot-bone-puppet-plan 流程二): this object shows item item (an element id) of the slot profile profile (a LibrarySymbol with slotProfile). Its content (everything but ElementBase fields and a mesh object's deform) is a copy of the item, kept current by document syncSlotItems; its transform, look and pulls are its own. Absent = an ordinary object. | ElementBase.slot |
slots? | SlotRule[] | DRESS-UP RULES (owner 2026-11-20 "整套換"): for this object and everything inside it; later rules win, an outer object's rules win over an inner one's. THE meaning: document slotRules.ts. Absent = none. | ElementBase.slots |
stroke? | Stroke | width is in the PARENT's units: the shape's own matrix never thickens it (owner 2026-11-05, shapeStroke.ts). join = how the line turns at its corners; absent = round (Flash's default). A line that is not round keeps its corners: it is not cut there by the drawing model, and lines meeting at a corner join into one. | - |
t3d? | Transform3D | 3D rotation / depth (owner 2026-10-30, Flash CS4 style): symbol instances, bitmaps, text and groups (loose shapes ignore it). The object is drawn as a flat card turned about its own X / Y axes and seen through a perspective (t3d.ts). Absent = flat. | ElementBase.t3d |
transform | Mat2D | 2D affine matrix [a,b,c,d,tx,ty] | ElementBase.transform |
type | "shape" | - | - |