Founding sponsorYour name here
Untitled
closeminimizezoom

Hover the controls — the symbols only appear on hover

Traffic Lights (Window Controls)

/ NSWindow.standardWindowButton(_:) · NSWindow.ButtonType /

also called window controls, title bar buttons, close minimize zoom buttons

Traffic lights are the red close, yellow minimize, and green window controls at the top-left of a macOS window. Their symbols appear when the pointer hovers over the group. The green control normally enters full screen and also exposes system window-arrangement choices; macOS still identifies it through NSWindow.ButtonType.zoomButton.

If you called it…

the three colored dots in the corner of a mac windowred yellow and green buttons at the top leftlittle x minus and arrows that appear when you hovermac window close minimize and full screen buttonsgreen window button that makes the window biggerthe macos traffic light buttons on a window

…you meant a traffic lights (window controls).

Anatomy — every part, named

  1. 1
    Close buttonNSWindow.ButtonType.closeButton

    The red control shows an x on group hover and closes the window rather than necessarily quitting the app.

  2. 2
    Minimize buttonNSWindow.ButtonType.miniaturizeButton

    The yellow control shows a minus on hover and miniaturizes the window into the Dock.

  3. 3
    Zoom / full-screen buttonNSWindow.ButtonType.zoomButton

    The green control normally enters full screen; Option-click invokes the traditional window Zoom behavior instead.

  4. 4
    Dirty-document dotNSWindow.isDocumentEdited

    The dark dot replacing the close button's x marks a document with unsaved changes.

Prompt — paste into your agent

Use the standard Traffic Lights from NSWindow.standardWindowButton(_:), preserving their native spacing, hover symbols, and the green button’s system-provided full-screen and window-arrangement behavior. Obtain the green control as .zoomButton and use NSWindow.toggleFullScreen(_:) only when explicitly invoking full screen; do not substitute custom circles.

Debug prompt — when it misbehaves

Paste this, then describe what you’re seeing — it hands your agent the classic failure modes to rule out first.

Debug my macOS traffic lights (NSWindow.standardWindowButton). Rule out: buttons missing after changing styleMask or using borderless windows; hover glyphs gone because a custom titlebar accessory intercepts tracking; the green button zooming when you expected full screen (option-click zooms); repositioned buttons drifting after full-screen transitions because the themed frame re-lays them out. The symptom:

In code

The exact names this thing goes by in code — each row is one framework’s word for it. Use the row that matches your project (or paste it into your prompt).

AppKitNSWindow.standardWindowButton(_:)
AppKitNSWindow.ButtonTypecloseButton, miniaturizeButton, and zoomButton
AppKitNSWindow.toggleFullScreen(_:)enters or exits a Space-filling full-screen window

See also

Search

Describe the UI element you're thinking of