Skip to content

Latest commit

 

History

History
389 lines (326 loc) · 12.3 KB

API.md

File metadata and controls

389 lines (326 loc) · 12.3 KB

Table of contents


(run {:keys [name width height frame-rate], :or {name "", width 200, height 200}} app)

Function.

Source


(begin {:keys [name pos size collapsed? min-size max-size bg-alpha window-flags], :or {name ""}})

Function.

Push a new window to the stack.

Source

(begin-child {:keys [name size child-flags window-flags], :or {name "", size [0.0 0.0]}, :as attrs})

Function.

Source

(begin-combo {:keys [label preview-value], :or {preview-value ""}})

Function.

Source

(bullet)

Function.

Source

(button {:keys [label size on-click], :or {label "", size [0.0 0.0]}})

Function.

Source

(calc-text-size s)

Function.

Source

(checkbox {:keys [label checked?]})

Function.

Source

(content-region-avail)

Function.

Source

(cursor-screen-pos)

Function.

Source

(display-size)

Function.

Source

(dummy size)

Function.

Source

(end)

Function.

Pop the current window from the stack.

Source

(end-child)

Function.

Source

(end-combo)

Function.

Source

(input-text label text)

Function.

Source

(input-text-multiline label text)

Function.

Source

(new-line)

Function.

Source

(pop-id)

Function.

Source

(pop-style-color)
(pop-style-color n)

Function.

Source

(pop-style-var)
(pop-style-var n)

Function.

Source

(progress-bar fraction)

Function.

Source

(push-id id)

Function.

Source

(push-style-color var value)

Function.

Source

(push-style-var var value)

Function.

Source

(radio-button {:keys [label active?], :or {active? false}})

Function.

Source

(same-line)

Function.

Source

(selectable label selected?)

Function.

Source

(separator)
(separator text)

Function.

Source

(set-cursor-pos v)

Function.

Source

(set-cursor-pos-x x)

Function.

Source

(set-cursor-pos-y y)

Function.

Source

(small-button {:keys [label]})

Function.

Source

(text s)

Function.

Source

(text-link label)
(text-link label url)

Function.

Source

(vec2 xy)
(vec2 x y)

Macro.

Coerce to ImVec2.

Source

(vec2-> v)

Macro.

Source

(vec4 xyzw)
(vec4 x y z w)

Macro.

Coerce to ImVec4.

Source

(vec4-> v)

Macro.

Source

(with-child attrs & body)

Macro.

Source

(with-combo attrs & body)

Macro.

Source

(with-scope attrs & body)

Macro.

Supported keys are are :id (see push-id), :style (see push-style-var for options), :color (see push-style-color for options), etc.

Source

(with-window attrs & body)

Macro.

Wrap an expression inside a new window.

If the window is closed then the body will not be evaluated. Prefer this over manual calls to begin and end. See begin for allowed options.

Returns true/false to indicate the window is open/closed.

Source