packages feed

dear-imgui-raw-1.0.0: src/DearImGui/Raw/Enums/ImGuiChildFlags.hsc

{-# LANGUAGE CApiFFI #-}
{-# LANGUAGE PatternSynonyms #-}

-- This file was generated by dear-bindings-ffi. Do not edit by hand.

module DearImGui.Raw.Enums.ImGuiChildFlags
  ( ImGuiChildFlags
  , pattern AlwaysAutoResize
  , pattern AlwaysUseWindowPadding
  , pattern AutoResizeX
  , pattern AutoResizeY
  , pattern Borders
  , pattern FrameStyle
  , pattern NavFlattened
  , pattern None
  , pattern ResizeX
  , pattern ResizeY
  ) where

import Foreign.C.Types

#include "dcimgui_nodefaultargfunctions.h"

-- typedefs

-- | Flags for ImGui::BeginChild()
-- (Legacy: bit 0 must always correspond to ImGuiChildFlags_Borders to be backward compatible with old API using 'bool border = false'.)
-- About using AutoResizeX/AutoResizeY flags:
-- - May be combined with SetNextWindowSizeConstraints() to set a min/max size for each axis (see "Demo->Child->Auto-resize with Constraints").
-- - Size measurement for a given axis is only performed when the child window is within visible boundaries, or is just appearing.
--   - This allows BeginChild() to return false when not within boundaries (e.g. when scrolling), which is more optimal. BUT it won't update its auto-size while clipped.
--     While not perfect, it is a better default behavior as the always-on performance gain is more valuable than the occasional "resizing after becoming visible again" glitch.
--   - You may also use ImGuiChildFlags_AlwaysAutoResize to force an update even when child window is not in view.
--     HOWEVER PLEASE UNDERSTAND THAT DOING SO WILL PREVENT BeginChild() FROM EVER RETURNING FALSE, disabling benefits of coarse clipping.
type ImGuiChildFlags = CInt

-- enums

pattern None :: ImGuiChildFlags
pattern None = #{const ImGuiChildFlags_None}

-- | Show an outer border and enable WindowPadding. (IMPORTANT: this is always == 1 == true for legacy reason)
pattern Borders :: ImGuiChildFlags
pattern Borders = #{const ImGuiChildFlags_Borders}

-- | Pad with style.WindowPadding even if no border are drawn (no padding by default for non-bordered child windows because it makes more sense)
pattern AlwaysUseWindowPadding :: ImGuiChildFlags
pattern AlwaysUseWindowPadding = #{const ImGuiChildFlags_AlwaysUseWindowPadding}

-- | Allow resize from right border (layout direction). Enable .ini saving (unless ImGuiWindowFlags_NoSavedSettings passed to window flags)
pattern ResizeX :: ImGuiChildFlags
pattern ResizeX = #{const ImGuiChildFlags_ResizeX}

-- | Allow resize from bottom border (layout direction). "
pattern ResizeY :: ImGuiChildFlags
pattern ResizeY = #{const ImGuiChildFlags_ResizeY}

-- | Enable auto-resizing width. Read "IMPORTANT: Size measurement" details above.
pattern AutoResizeX :: ImGuiChildFlags
pattern AutoResizeX = #{const ImGuiChildFlags_AutoResizeX}

-- | Enable auto-resizing height. Read "IMPORTANT: Size measurement" details above.
pattern AutoResizeY :: ImGuiChildFlags
pattern AutoResizeY = #{const ImGuiChildFlags_AutoResizeY}

-- | Combined with AutoResizeX/AutoResizeY. Always measure size even when child is hidden, always return true, always disable clipping optimization! NOT RECOMMENDED.
pattern AlwaysAutoResize :: ImGuiChildFlags
pattern AlwaysAutoResize = #{const ImGuiChildFlags_AlwaysAutoResize}

-- | Style the child window like a framed item: use FrameBg, FrameRounding, FrameBorderSize, FramePadding instead of ChildBg, ChildRounding, ChildBorderSize, WindowPadding.
pattern FrameStyle :: ImGuiChildFlags
pattern FrameStyle = #{const ImGuiChildFlags_FrameStyle}

-- | [BETA] Share focus scope, allow keyboard/gamepad navigation to cross over parent border to this child or between sibling child windows.
pattern NavFlattened :: ImGuiChildFlags
pattern NavFlattened = #{const ImGuiChildFlags_NavFlattened}