Skip to content

Interface: OrientationLabelOptions ​

Defined in: src/display/OrientationLabelLayer.ts:13

Options for orientation labels.

Properties ​

fontSize? ​

ts
optional fontSize?: number;

Defined in: src/display/OrientationLabelLayer.ts:15

Font size in screen pixels (labels do NOT scale with the image).


color? ​

ts
optional color?: number;

Defined in: src/display/OrientationLabelLayer.ts:17

Fill color of the letters (PIXI numeric color).


fontFamily? ​

ts
optional fontFamily?: string;

Defined in: src/display/OrientationLabelLayer.ts:19

Font family.


margin? ​

ts
optional margin?: number;

Defined in: src/display/OrientationLabelLayer.ts:21

Distance from the viewport edge, in screen pixels.


strokeColor? ​

ts
optional strokeColor?: number;

Defined in: src/display/OrientationLabelLayer.ts:23

Outline color drawn around the letters for contrast over bright/dark anatomy.


strokeWidth? ​

ts
optional strokeWidth?: number;

Defined in: src/display/OrientationLabelLayer.ts:25

Outline width in pixels. Set to 0 to disable.


fontWeight? ​

ts
optional fontWeight?: 
  | "normal"
  | "bold"
  | "100"
  | "200"
  | "300"
  | "400"
  | "500"
  | "600"
  | "700"
  | "800"
  | "900";

Defined in: src/display/OrientationLabelLayer.ts:27

CSS font weight. Default 'bold'.


letterSpacing? ​

ts
optional letterSpacing?: number;

Defined in: src/display/OrientationLabelLayer.ts:29

Letter spacing in pixels. Default 0.


alpha? ​

ts
optional alpha?: number;

Defined in: src/display/OrientationLabelLayer.ts:31

Fill opacity in [0, 1]. Default 1.


shadowAlpha? ​

ts
optional shadowAlpha?: number;

Defined in: src/display/OrientationLabelLayer.ts:33

Soft shadow for legibility over bright anatomy; alpha 0 disables. Default 0.


shadowBlur? ​

ts
optional shadowBlur?: number;

Defined in: src/display/OrientationLabelLayer.ts:35

Shadow blur radius in pixels. Default 2.


anchor? ​

ts
optional anchor?: "viewport" | "image";

Defined in: src/display/OrientationLabelLayer.ts:41

What the labels are pinned to: the viewport edges ('viewport', default) or just outside the rendered image's edges ('image', clamped to the viewport), which keeps labels of neighbouring views apart.

Released under the MIT License.