Skip to content

cupertino-files / DrawableStyleHandle

Class: DrawableStyleHandle

Defined in: src/tsd/drawables.ts:243

A live view of one drawable's visual style.

Constructors

Constructor

new DrawableStyleHandle(store, object): DrawableStyleHandle

Defined in: src/tsd/drawables.ts:247

Parameters

store

ObjectStore

object

IwaObject

Returns

DrawableStyleHandle

Properties

object

readonly object: IwaObject

Defined in: src/tsd/drawables.ts:245


store

readonly store: ObjectStore

Defined in: src/tsd/drawables.ts:244

Accessors

id

Get Signature

get id(): bigint

Defined in: src/tsd/drawables.ts:252

Returns

bigint


isMedia

Get Signature

get isMedia(): boolean

Defined in: src/tsd/drawables.ts:265

True for images and movies, whose property bag omits fill and so numbers every later field one lower.

Decided by declared type where known, and structurally otherwise: field 2 is a stroke message in a shape bag but the float opacity in a media bag, so its wire type settles the question for wrapper types the registry does not name.

Returns

boolean

Methods

read()

read(): DrawableStyle

Defined in: src/tsd/drawables.ts:283

Everything this style sets, in one object.

Returns

DrawableStyle


set()

set(style): this

Defined in: src/tsd/drawables.ts:315

Merge visual properties into this style.

null removes a property outright; omitting it leaves whatever was there. Note that a shadow with enabled: false is how the apps store "shadow configured but switched off" — removing the archive and disabling it are different states, and both are expressible.

Parameters

style

DrawableStyle

Returns

this


setShadowEnabled()

setShadowEnabled(enabled): this

Defined in: src/tsd/drawables.ts:351

Turn a shadow on or off without discarding its parameters.

Parameters

enabled

boolean

Returns

this


shadow()

shadow(): Shadow | undefined

Defined in: src/tsd/drawables.ts:303

Returns

Shadow | undefined

MIT licensed. Independently made — not by Apple in California. Not affiliated with or endorsed by Apple Inc.