(a: u64, b: u64) -> u64
macOSLinuxWindows
#import "GetRect";
Procedures#
UI geometry#
(loc: Source_Code_Location, identifier: s64) -> u64
is_visible_in_scissor2 overloads
(x: float, y: float) -> bool
(r: Rect)
(_rect: Rect)
()
(color: $T/interface VBase3, t: float) -> T
(color: $T/interface VBase3, t: float) -> T
(color: $T/interface VBase3, value: float) -> T
(r: Rect) -> float
rescale2 overloads
(r: Rect, shape: Rectangle_Shape, color: Vector4, frame_color: Vector4, frame_thickness_override := FLOAT32_INFINITY) -> (frame_pixels: float, actual_roundedness: float)
UI widgets#
(theme: *Button_Theme, state: *Button_State) -> (surface_color: Vector4, frame_color: Vector4, frame_thickness: float)
(r: Rect, text: string, state: *Button_State, status: Status_Flags, theme: *Button_Theme, texture: *Texture)
(r: Rect, text: string, theme: *Button_Theme = null, identifier: s64 = 0, loc := #caller_location, texture: *Texture = null, disable_over := false, disable_press := false) -> (was_just_pressed: bool, state: *Button_State, was_just_released: bool)
(_r: Rect, text: string, selected: bool, theme: *Checkbox_Theme = null, identifier: s64 = 0, loc := #caller_location) -> (changed: bool, checkbox_state: Checkbox_State)
radio_button2 overloads
(r: Rect, text: string, current_value: *$Enum, button_value: Enum, theme: *Checkbox_Theme = null, identifier: s64 = 0, loc := #caller_location) -> (changed: bool, checkbox_state: Checkbox_State)
checkbox_flags2 overloads
(r: Rect, text: string, current_value: *$Enum, button_value: Enum, theme: *Checkbox_Theme = null, identifier: s64 = 0, loc := #caller_location) -> (changed: bool, checkbox_state: Checkbox_State)
(r: Rect, choices: [] string, current_value_pointer: *s32, theme: *Dropdown_Theme = null, identifier: s64 = 0, z: s32 = 100, loc := #caller_location) -> (changed: bool, Dropdown_State)
(_state: *void)
(widget: *Active_Widget)
()
(r: Rect, theme: *Scrollable_Region_Theme = null, identifier: s64 = 0, loc := #caller_location) -> (state: *Scrollable_Region_State, inside: Rect)
end_scrollable_region2 overloads
(r: Rect, theme: *Slidable_Region_Theme = null, identifier: s64 = 0, loc := #caller_location) -> (state: *Slidable_Region_State, left_or_top_rect: Rect, right_or_bottom_rect: Rect, divider_rect: Rect)
(state: *Slidable_Region_State)
(state: *Slidable_Region_State)
(state: *Slidable_Region_State)
(state: *Slidable_Region_State)
(state: *Slidable_Region_State)
(state: *Slidable_Region_State)
(state: *Slidable_Region_State)
(state: *Slider_State, value: $T)
(state: *Slider_State, $T: Type) -> T
(new_value: $ValueType, pointer: *$T, min_value: T, max_value: T, clamp_low: bool, clamp_high: bool)
(_r: Rect, value: *$T, min_value: T, max_value: T, spinbox_step: T, theme: *Slider_Theme, prefix := "", suffix := "", identifier: s64 = 0, loc := #caller_location) -> (changed: bool, entered: bool)
(prefix: string, suffix: string, value: float64, theme: *Slider_Theme, state: *Slider_State, mode: Slider_Format_Text_Mode) -> string
(prefix: string, suffix: string, value: s64, theme: *Slider_Theme, state: *Slider_State, mode: Slider_Format_Text_Mode) -> string
(_r: Rect, text: string, value: *$T, min_value: T, max_value: T, theme: *Number_Input_Theme, identifier: s64 = 0, loc := #caller_location, parse_proc: (string) -> (T, bool) = null) -> bool
UI text#
(font: *Font, text: string, effect: Font_Effects, text_x: float, start_character: int, end_character: int) -> (x0: float, x1: float)
(state: *Text_Input_State, font: *Font, text: string, current_frame_text_x: float, cursor_x: int, effect: Font_Effects, glyphs_prepped := false) -> int
(s: string) -> string
(s: string, _point: int) -> int
(s: string, point: int) -> int
(s: string, point: int) -> int
(s: string, between_lines_string := "") -> [] string
(state: *Text_Input_State)
(state: *Text_Input_State, _s: string)
(state: *Text_Input_State, s: string, replace_pre_modification_text := true)
(state: *Text_Input_State)
(state: *Text_Input_State, s: string)
(state: *Text_Input_State) -> string
(state: *Text_Input_State)
(state: *Text_Input_State)
(state: *Text_Input_State, text: string)
(state: *Text_Input_State)
(selection: *Selection)
(selection: *Selection)
(state: *Text_Input_State)
(state: *Text_Input_State, cut := false)
(state: *Text_Input_State)
(state: *Text_Input_State, want_selection := false)
(state: *Text_Input_State, want_selection := false)
(state: *Text_Input_State, want_selection := false)
(state: *Text_Input_State, want_selection := false)
(state: *Text_Input_State, want_selection := false)
(state: *Text_Input_State, want_selection := false)
(state: *Text_Input_State)
(state: *Text_Input_State)
(state: *Text_Input_State)
backspace_from_cursor2 overloads
(state: *Text_Input_State, by_word := false)
delete_from_cursor2 overloads
(state: *Text_Input_State, by_word := false)
(state: *Text_Input_State, shift_pressed := false)
(state: *Text_Input_State)
(state: *Text_Input_State, shift_pressed := false)
(widget: *Active_Widget)
(widget: *Active_Widget, event: Event) -> bool
(widget: *Active_Widget, events: [] Event)
(state: *Text_Input_State, event: Event)
(_r: Rect, inert_text: string, theme: *Text_Input_Theme, identifier: s64 = 0, loc := #caller_location, input_action: Text_Input_Action = 0, auto_complete: Auto_Complete = .{}) -> (result_action: Text_Result_Action, new_string: string, state: *Text_Input_State)
(state: *Text_Input_State, r: Rect, theme: *Text_Input_Theme = null, identifier: s64 = 0, loc := #caller_location)
UI editor#
get_desired_aspect_ratio2 overloads
(theme: *Color_Picker_Theme) -> float
(state: *Color_Picker_State, hsv: Vector3, update_zoom_hue := true)
(state: *Color_Picker_State, rgb: Vector3)
(state: *Color_Picker_State, theme: *Color_Picker_Theme, rgb: Vector3, update_hsv := true, maintain_h := FLOAT32_INFINITY, update_disc_point := true)
(r: Rect, input_and_output_color_rgb: *Vector3, theme: *Color_Picker_Theme = null, identifier: s64 = 0, loc := #caller_location) -> (applied: bool, still_dragging: bool, state: *Color_Picker_State)
(state: *Color_Animation_Editor_State, frames: [] Color_Keyframe)
(state: *Color_Animation_Editor_State) -> [] Color_Keyframe
(state: *Color_Animation_Editor_State) -> Interpolation
(state: *Color_Animation_Editor_State, interp: Interpolation)
(state: *Color_Animation_Editor_State, index_to_ignore := -1) -> [] *Augmented_Keyframe
(sorted: [] *Augmented_Keyframe, t: float) -> index: int
(r: Rect, theme: *Color_Animation_Editor_Theme = null, identifier: s64 = 0, loc := #caller_location) -> state: *Color_Animation_Editor_State
(area: Rect, theme: *Color_Animation_Editor_Theme, state: *Color_Animation_Editor_State, top_margin: float)
(index: int, rect: Rect, theme: *Color_Animation_Editor_Theme, state: *Color_Animation_Editor_State)
(rect: Rect, alpha: float, theme: *Color_Animation_Editor_Theme, state: *Color_Animation_Editor_State) -> changed: bool
(state: *Color_Animation_Editor_State, keyframe_index: int)
(theme: *Color_Animation_Editor_Theme, state: *Color_Animation_Editor_State, keyframe_index: int, bar_rect: Rect)
(theme: *Color_Animation_Editor_Theme, state: *Color_Animation_Editor_State)
(theme: *Color_Animation_Editor_Theme, state: *Color_Animation_Editor_State)
(state: *Color_Animation_Editor_State)
(state: *Color_Animation_Editor_State, output_type: Output_Type)
(info: *Subwindow_Info, theme: *Subwindow_Theme = null, identifier: s64 = 0, loc := #caller_location, z: s32 = 0) -> state: *Subwindow_State
(state: *Subwindow_State)
(state: *Subwindow_State)
(state: *Subwindow_State, full: *Rect)
(flag: Resize_Controls, x: float, w: float, margin: float, low: Resize_Controls, high: Resize_Controls, mouse: float) -> Resize_Controls
(state: *Subwindow_State, f: Rect)
(flags: Resize_Controls) -> Pointer_Image
(state: *Subwindow_State, new_y1: float)
Types#
Rectstruct
:: struct
Occlusion_Recordstruct
:: struct
VBase3struct
:: struct
Status_Flagsenum flags
:: enum_flags
Status_Flags_Ignoreenum flags
:: enum_flags
Marginenum flags
:: enum_flags
Text_Alignmentenum
:: enum
Pointer_Imageenum
:: enum
Size_Computationenum
:: enum
Default_Themesenum
:: enum
Color_Pick_Modeenum
:: enum
:: enum
Scrollable_Region_Flagsenum flags
:: enum_flags
Subwindow_Flagsenum flags
:: enum_flags
Resize_Controlsenum flags
:: enum_flags
Text_Input_Actionenum flags
:: enum_flags
Text_Result_Actionenum flags
:: enum_flags
Selectionstruct
:: struct
Auto_Completestruct
:: struct
Tooltipstruct
:: struct
Draw_Procsstruct
:: struct
Rectangle_Shapestruct
:: struct
Label_Themestruct
:: struct
Background_Themestruct
:: struct
Button_Themestruct
:: struct
Checkbox_Themestruct
:: struct
Text_Input_Themestruct
:: struct
Number_Input_Themestruct
:: struct
Slider_Themestruct
:: struct
Dropdown_Themestruct
:: struct
Scrollable_Region_Themestruct
:: struct
Slidable_Region_Themestruct
:: struct
Subwindow_Themestruct
:: struct
Color_Picker_Themestruct
:: struct
:: struct
Overall_Themestruct
:: struct
Button_Statestruct
:: struct
Checkbox_Statestruct
:: struct
Text_Input_Statestruct
:: struct
Number_Input_Statestruct
:: struct
Slider_Statestruct
:: struct
Dropdown_Statestruct
:: struct
Scrollable_Region_Statestruct
:: struct
Slidable_Region_Statestruct
:: struct
Subwindow_Infostruct
:: struct
Subwindow_Statestruct
:: struct
Color_Picker_Statestruct
:: struct
:: struct
Constants#
:: 11400714819323198485
:: 10
:: 0.0001