> ## Documentation Index
> Fetch the complete documentation index at: https://docs.ploterr.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Room and opening labels

> Choose which labels a plan shows and keep them apart.

## Import

```typescript theme={null}
import {
  filterRoomLabels,
  tagOpenings,
  declutterText,
  ROOM_LABEL_NAME,
  ROOM_LABEL_DETAIL,
} from '@opengeometry/floorkit';
```

## filterRoomLabels

Return the primitives with the room label lines this mode does not draw removed.

```typescript theme={null}
function filterRoomLabels(
  primitives: ReadonlyArray<DrawingPrimitive>,
  mode?: RoomLabelMode,
): DrawingPrimitive[];
```

## tagOpenings

Append a tag per door and per window, at the centre of what that opening drew.

```typescript theme={null}
function tagOpenings(
  primitives: DrawingPrimitive[],
  mode?: OpeningTagMode,
  {
    labels,
    heightM,
  }?: {
    labels?: Map<string, string>;
    heightM?: number;
  },
): DrawingPrimitive[];
```

## declutterText

Return the primitives with colliding labels removed.

```typescript theme={null}
function declutterText(primitives: ReadonlyArray<DrawingPrimitive>): DrawingPrimitive[];
```

## ROOM\_LABEL\_NAME

The `style.subId` values `Space.toDrawing` tags its two label lines with.

```typescript theme={null}
const ROOM_LABEL_NAME = 'label:name';
```

## ROOM\_LABEL\_DETAIL

```typescript theme={null}
const ROOM_LABEL_DETAIL = 'label:detail';
```

## Types

### RoomLabelMode

`full` = name + `number · area`; `name` = name only; `none` = neither.

```typescript theme={null}
type RoomLabelMode = 'full' | 'name' | 'none';
```

### OpeningTagMode

Whether a plan carries door and window tags.

```typescript theme={null}
type OpeningTagMode = 'none' | 'auto';
```

## Related

* [`DrawingPrimitive`](/floorkit/api/drawings/draw-project-view#drawingprimitive)


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.