packages feed

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

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

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

module DearImGui.Raw.Enums.ImGuiHoveredFlags
  ( ImGuiHoveredFlags
  , pattern AllowWhenBlockedByActiveItem
  , pattern AllowWhenBlockedByPopup
  , pattern AllowWhenDisabled
  , pattern AllowWhenOverlapped
  , pattern AllowWhenOverlappedByItem
  , pattern AllowWhenOverlappedByWindow
  , pattern AnyWindow
  , pattern ChildWindows
  , pattern DelayNone
  , pattern DelayNormal
  , pattern DelayShort
  , pattern DockHierarchy
  , pattern ForTooltip
  , pattern NoNavOverride
  , pattern NoPopupHierarchy
  , pattern NoSharedDelay
  , pattern None
  , pattern RectOnly
  , pattern RootAndChildWindows
  , pattern RootWindow
  , pattern Stationary
  ) where

import Foreign.C.Types

#include "dcimgui_nodefaultargfunctions.h"

-- typedefs

-- | Flags for ImGui::IsItemHovered(), ImGui::IsWindowHovered()
-- Note: if you are trying to check whether your mouse should be dispatched to Dear ImGui or to your app, you should use 'io.WantCaptureMouse' instead! Please read the FAQ!
-- Note: windows with the ImGuiWindowFlags_NoInputs flag are ignored by IsWindowHovered() calls.
type ImGuiHoveredFlags = CInt

-- enums

-- | Return true if directly over the item/window, not obstructed by another window, not obstructed by an active popup or modal blocking inputs under them.
pattern None :: ImGuiHoveredFlags
pattern None = #{const ImGuiHoveredFlags_None}

-- | IsWindowHovered() only: Return true if any children of the window is hovered
pattern ChildWindows :: ImGuiHoveredFlags
pattern ChildWindows = #{const ImGuiHoveredFlags_ChildWindows}

-- | IsWindowHovered() only: Test from root window (top most parent of the current hierarchy)
pattern RootWindow :: ImGuiHoveredFlags
pattern RootWindow = #{const ImGuiHoveredFlags_RootWindow}

-- | IsWindowHovered() only: Return true if any window is hovered
pattern AnyWindow :: ImGuiHoveredFlags
pattern AnyWindow = #{const ImGuiHoveredFlags_AnyWindow}

-- | IsWindowHovered() only: Do not consider popup hierarchy (do not treat popup emitter as parent of popup) (when used with _ChildWindows or _RootWindow)
pattern NoPopupHierarchy :: ImGuiHoveredFlags
pattern NoPopupHierarchy = #{const ImGuiHoveredFlags_NoPopupHierarchy}

-- | IsWindowHovered() only: Consider docking hierarchy (treat dockspace host as parent of docked window) (when used with _ChildWindows or _RootWindow)
pattern DockHierarchy :: ImGuiHoveredFlags
pattern DockHierarchy = #{const ImGuiHoveredFlags_DockHierarchy}

-- | Return true even if a popup window is normally blocking access to this item/window
pattern AllowWhenBlockedByPopup :: ImGuiHoveredFlags
pattern AllowWhenBlockedByPopup = #{const ImGuiHoveredFlags_AllowWhenBlockedByPopup}

-- | ImGuiHoveredFlags_AllowWhenBlockedByModal     = 1 << 6,   // Return true even if a modal popup window is normally blocking access to this item/window. FIXME-TODO: Unavailable yet.
-- Return true even if an active item is blocking access to this item/window. Useful for Drag and Drop patterns.
pattern AllowWhenBlockedByActiveItem :: ImGuiHoveredFlags
pattern AllowWhenBlockedByActiveItem = #{const ImGuiHoveredFlags_AllowWhenBlockedByActiveItem}

-- | IsItemHovered() only: Return true even if the item uses AllowOverlap mode and is overlapped by another hoverable item.
pattern AllowWhenOverlappedByItem :: ImGuiHoveredFlags
pattern AllowWhenOverlappedByItem = #{const ImGuiHoveredFlags_AllowWhenOverlappedByItem}

-- | IsItemHovered() only: Return true even if the position is obstructed or overlapped by another window.
pattern AllowWhenOverlappedByWindow :: ImGuiHoveredFlags
pattern AllowWhenOverlappedByWindow = #{const ImGuiHoveredFlags_AllowWhenOverlappedByWindow}

-- | IsItemHovered() only: Return true even if the item is disabled
pattern AllowWhenDisabled :: ImGuiHoveredFlags
pattern AllowWhenDisabled = #{const ImGuiHoveredFlags_AllowWhenDisabled}

-- | IsItemHovered() only: Disable using keyboard/gamepad navigation state when active, always query mouse
pattern NoNavOverride :: ImGuiHoveredFlags
pattern NoNavOverride = #{const ImGuiHoveredFlags_NoNavOverride}

pattern AllowWhenOverlapped :: ImGuiHoveredFlags
pattern AllowWhenOverlapped = #{const ImGuiHoveredFlags_AllowWhenOverlapped}

pattern RectOnly :: ImGuiHoveredFlags
pattern RectOnly = #{const ImGuiHoveredFlags_RectOnly}

pattern RootAndChildWindows :: ImGuiHoveredFlags
pattern RootAndChildWindows = #{const ImGuiHoveredFlags_RootAndChildWindows}

-- | Tooltips mode
-- - typically used in IsItemHovered() + SetTooltip() sequence.
-- - this is a shortcut to pull flags from 'style.HoverFlagsForTooltipMouse' or 'style.HoverFlagsForTooltipNav' where you can reconfigure desired behavior.
--   e.g. 'HoverFlagsForTooltipMouse' defaults to 'ImGuiHoveredFlags_Stationary | ImGuiHoveredFlags_DelayShort | ImGuiHoveredFlags_AllowWhenDisabled'.
-- - for frequently actioned or hovered items providing a tooltip, you want may to use ImGuiHoveredFlags_ForTooltip (stationary + delay) so the tooltip doesn't show too often.
-- - for items which main purpose is to be hovered, or items with low affordance, or in less consistent apps, prefer no delay or shorter delay.
-- Shortcut for standard flags when using IsItemHovered() + SetTooltip() sequence.
pattern ForTooltip :: ImGuiHoveredFlags
pattern ForTooltip = #{const ImGuiHoveredFlags_ForTooltip}

-- | (Advanced) Mouse Hovering delays.
-- - generally you can use ImGuiHoveredFlags_ForTooltip to use application-standardized flags.
-- - use those if you need specific overrides.
-- Require mouse to be stationary for style.HoverStationaryDelay (~0.15 sec) _at least one time_. After this, can move on same item/window. Using the stationary test tends to reduces the need for a long delay.
pattern Stationary :: ImGuiHoveredFlags
pattern Stationary = #{const ImGuiHoveredFlags_Stationary}

-- | IsItemHovered() only: Return true immediately (default). As this is the default you generally ignore this.
pattern DelayNone :: ImGuiHoveredFlags
pattern DelayNone = #{const ImGuiHoveredFlags_DelayNone}

-- | IsItemHovered() only: Return true after style.HoverDelayShort elapsed (~0.15 sec) (shared between items) + requires mouse to be stationary for style.HoverStationaryDelay (once per item).
pattern DelayShort :: ImGuiHoveredFlags
pattern DelayShort = #{const ImGuiHoveredFlags_DelayShort}

-- | IsItemHovered() only: Return true after style.HoverDelayNormal elapsed (~0.40 sec) (shared between items) + requires mouse to be stationary for style.HoverStationaryDelay (once per item).
pattern DelayNormal :: ImGuiHoveredFlags
pattern DelayNormal = #{const ImGuiHoveredFlags_DelayNormal}

-- | IsItemHovered() only: Disable shared delay system where moving from one item to the next keeps the previous timer for a short time (standard for tooltips with long delays)
pattern NoSharedDelay :: ImGuiHoveredFlags
pattern NoSharedDelay = #{const ImGuiHoveredFlags_NoSharedDelay}