# `GSFlowView`

*Class*

A view that arranges its managed subviews in a left-to-right, wrapping flow layout — similar to NSStackView but multi-line. The view sizes itself to the height required to fit all subviews at the current width.

## Declaration

```swift
class GSFlowView
```

```objc
@interface GSFlowView : NSView
```

```python
class GSFlowView(NSView)
```

## Overview

Pin the view’s width with a constraint (or let a parent dictate it). The height will be driven by intrinsicContentSize automatically.

Subviews can be added either programmatically via -addArrangedSubview: or directly in Interface Builder. IB-added subviews are picked up automatically in -awakeFromNib in the order they appear in the XIB.

All subviews must have a fixed size either via their own intrinsicContentSize or via explicit width/height constraints attached to the subview itself.

## Topics

### Instance Properties

- [`GSFlowView.arrangedSubviews`](/Core/GlyphsKit/GSFlowView/arrangedSubviews) — The subviews currently managed by the flow layout. Use -addArrangedSubview: / -removeArrangedSubview: rather than the raw NSView add/remove methods when managing subviews programmatically.
- [`GSFlowView.contentInsetBottom`](/Core/GlyphsKit/GSFlowView/contentInsetBottom) — Bottom inset applied inside the view’s bounds before layout. Default: 0.
- [`GSFlowView.contentInsetLeft`](/Core/GlyphsKit/GSFlowView/contentInsetLeft) — Left inset applied inside the view’s bounds before layout. Default: 0.
- [`GSFlowView.contentInsetRight`](/Core/GlyphsKit/GSFlowView/contentInsetRight) — Right inset applied inside the view’s bounds before layout. Default: 0.
- [`GSFlowView.contentInsetTop`](/Core/GlyphsKit/GSFlowView/contentInsetTop) — Top inset applied inside the view’s bounds before layout. Default: 0.
- [`GSFlowView.contentInsets`](/Core/GlyphsKit/GSFlowView/contentInsets) — Convenience accessor that aggregates the four inset properties. Setting this updates all four individual inset properties.
- [`GSFlowView.flowAlignment`](/Core/GlyphsKit/GSFlowView/flowAlignment) — Typed convenience wrapper around flowAlignmentValue.
- [`GSFlowView.flowAlignmentValue`](/Core/GlyphsKit/GSFlowView/flowAlignmentValue) — How subviews are aligned horizontally within each row. Default: FlowViewAlignmentLeading. IBInspectable surfaces this as an integer: 0 = Leading, 1 = Center, 2 = Justified.
- [`GSFlowView.horizontalSpacing`](/Core/GlyphsKit/GSFlowView/horizontalSpacing) — Horizontal gap between subviews on the same row. Default: 8.
- [`GSFlowView.verticalSpacing`](/Core/GlyphsKit/GSFlowView/verticalSpacing) — Vertical gap between rows. Default: 8.

### Instance Methods

- [`GSFlowView addArrangedSubview:`](/Core/GlyphsKit/GSFlowView/addArrangedSubview:)
- [`GSFlowView insertArrangedSubview:atIndex:`](/Core/GlyphsKit/GSFlowView/insertArrangedSubview:atIndex:)
- [`GSFlowView removeArrangedSubview:`](/Core/GlyphsKit/GSFlowView/removeArrangedSubview:)

## Relationships

### Inherits From

- `NSView`

### Inherited By

- [`GSFlowSegmentedControl`](/Core/GlyphsKit/GSFlowSegmentedControl)

