Struct imgui_sys::ImGuiDragDropFlags [−]
#[repr(C)]pub struct ImGuiDragDropFlags { /* fields omitted */ }
Flags for igBeginDragDropSource(), igAcceptDragDropPayload()
Methods
impl ImGuiDragDropFlags
impl ImGuiDragDropFlagspub const SourceNoPreviewTooltip: ImGuiDragDropFlags
SourceNoPreviewTooltip: ImGuiDragDropFlags = ImGuiDragDropFlags{bits: 1 << 0,}
By default, a successful call to igBeginDragDropSource opens a tooltip so you can display a preview or description of the source contents. This flag disable this behavior.
pub const SourceNoDisableHover: ImGuiDragDropFlags
SourceNoDisableHover: ImGuiDragDropFlags = ImGuiDragDropFlags{bits: 1 << 1,}
By default, when dragging we clear data so that igIsItemHovered() will return true, to avoid subsequent user code submitting tooltips. This flag disable this behavior so you can still call igIsItemHovered() on the source item.
pub const SourceNoHoldToOpenOthers: ImGuiDragDropFlags
SourceNoHoldToOpenOthers: ImGuiDragDropFlags = ImGuiDragDropFlags{bits: 1 << 2,}
Disable the behavior that allows to open tree nodes and collapsing header by holding over them while dragging a source item.
pub const SourceAllowNullID: ImGuiDragDropFlags
SourceAllowNullID: ImGuiDragDropFlags = ImGuiDragDropFlags{bits: 1 << 3,}
Allow items such as igText(), igImage() that have no unique identifier to be used as drag source, by manufacturing a temporary identifier based on their window-relative position. This is extremely unusual within the dear imgui ecosystem and so we made it explicit.
pub const SourceExtern: ImGuiDragDropFlags
SourceExtern: ImGuiDragDropFlags = ImGuiDragDropFlags{bits: 1 << 4,}
External source (from outside of imgui), won't attempt to read current item/window info. Will always return true. Only one Extern source can be active simultaneously.
pub const AcceptBeforeDelivery: ImGuiDragDropFlags
AcceptBeforeDelivery: ImGuiDragDropFlags = ImGuiDragDropFlags{bits: 1 << 10,}
igAcceptDragDropPayload() will returns true even before the mouse button is released. You can then call igIsDelivery() to test if the payload needs to be delivered.
pub const AcceptNoDrawDefaultRect: ImGuiDragDropFlags
AcceptNoDrawDefaultRect: ImGuiDragDropFlags = ImGuiDragDropFlags{bits: 1 << 11,}
Do not draw the default highlight rectangle when hovering over target.
pub const AcceptPeekOnly: ImGuiDragDropFlags
AcceptPeekOnly: ImGuiDragDropFlags = ImGuiDragDropFlags{bits: <ImGuiDragDropFlags>::AcceptBeforeDelivery.bits | <ImGuiDragDropFlags>::AcceptNoDrawDefaultRect.bits,}
For peeking ahead and inspecting the payload before delivery.
pub fn empty() -> ImGuiDragDropFlags
pub fn empty() -> ImGuiDragDropFlagsReturns an empty set of flags.
pub fn all() -> ImGuiDragDropFlags
pub fn all() -> ImGuiDragDropFlagsReturns the set containing all flags.
pub fn bits(&self) -> c_int
pub fn bits(&self) -> c_intReturns the raw value of the flags currently stored.
pub fn from_bits(bits: c_int) -> Option<ImGuiDragDropFlags>
pub fn from_bits(bits: c_int) -> Option<ImGuiDragDropFlags>Convert from underlying bit representation, unless that representation contains bits that do not correspond to a flag.
pub fn from_bits_truncate(bits: c_int) -> ImGuiDragDropFlags
pub fn from_bits_truncate(bits: c_int) -> ImGuiDragDropFlagsConvert from underlying bit representation, dropping any bits that do not correspond to flags.
pub fn is_empty(&self) -> bool
pub fn is_empty(&self) -> boolReturns true if no flags are currently stored.
pub fn is_all(&self) -> bool
pub fn is_all(&self) -> boolReturns true if all flags are currently set.
pub fn intersects(&self, other: ImGuiDragDropFlags) -> bool
pub fn intersects(&self, other: ImGuiDragDropFlags) -> boolReturns true if there are flags common to both self and other.
pub fn contains(&self, other: ImGuiDragDropFlags) -> bool
pub fn contains(&self, other: ImGuiDragDropFlags) -> boolReturns true all of the flags in other are contained within self.
pub fn insert(&mut self, other: ImGuiDragDropFlags)
pub fn insert(&mut self, other: ImGuiDragDropFlags)Inserts the specified flags in-place.
pub fn remove(&mut self, other: ImGuiDragDropFlags)
pub fn remove(&mut self, other: ImGuiDragDropFlags)Removes the specified flags in-place.
pub fn toggle(&mut self, other: ImGuiDragDropFlags)
pub fn toggle(&mut self, other: ImGuiDragDropFlags)Toggles the specified flags in-place.
pub fn set(&mut self, other: ImGuiDragDropFlags, value: bool)
pub fn set(&mut self, other: ImGuiDragDropFlags, value: bool)Inserts or removes the specified flags depending on the passed value.
Trait Implementations
impl Copy for ImGuiDragDropFlags
impl Copy for ImGuiDragDropFlagsimpl PartialEq for ImGuiDragDropFlags
impl PartialEq for ImGuiDragDropFlagsfn eq(&self, other: &ImGuiDragDropFlags) -> bool
fn eq(&self, other: &ImGuiDragDropFlags) -> boolThis method tests for self and other values to be equal, and is used by ==. Read more
fn ne(&self, other: &ImGuiDragDropFlags) -> bool
fn ne(&self, other: &ImGuiDragDropFlags) -> boolThis method tests for !=.
impl Eq for ImGuiDragDropFlags
impl Eq for ImGuiDragDropFlagsimpl Clone for ImGuiDragDropFlags
impl Clone for ImGuiDragDropFlagsfn clone(&self) -> ImGuiDragDropFlags
fn clone(&self) -> ImGuiDragDropFlagsReturns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)1.0.0[src]
fn clone_from(&mut self, source: &Self)Performs copy-assignment from source. Read more
impl PartialOrd for ImGuiDragDropFlags
impl PartialOrd for ImGuiDragDropFlagsfn partial_cmp(&self, other: &ImGuiDragDropFlags) -> Option<Ordering>
fn partial_cmp(&self, other: &ImGuiDragDropFlags) -> Option<Ordering>This method returns an ordering between self and other values if one exists. Read more
fn lt(&self, other: &ImGuiDragDropFlags) -> bool
fn lt(&self, other: &ImGuiDragDropFlags) -> boolThis method tests less than (for self and other) and is used by the < operator. Read more
fn le(&self, other: &ImGuiDragDropFlags) -> bool
fn le(&self, other: &ImGuiDragDropFlags) -> boolThis method tests less than or equal to (for self and other) and is used by the <= operator. Read more
fn gt(&self, other: &ImGuiDragDropFlags) -> bool
fn gt(&self, other: &ImGuiDragDropFlags) -> boolThis method tests greater than (for self and other) and is used by the > operator. Read more
fn ge(&self, other: &ImGuiDragDropFlags) -> bool
fn ge(&self, other: &ImGuiDragDropFlags) -> boolThis method tests greater than or equal to (for self and other) and is used by the >= operator. Read more
impl Ord for ImGuiDragDropFlags
impl Ord for ImGuiDragDropFlagsfn cmp(&self, other: &ImGuiDragDropFlags) -> Ordering
fn cmp(&self, other: &ImGuiDragDropFlags) -> OrderingThis method returns an Ordering between self and other. Read more
fn max(self, other: Self) -> Self1.21.0[src]
fn max(self, other: Self) -> SelfCompares and returns the maximum of two values. Read more
fn min(self, other: Self) -> Self1.21.0[src]
fn min(self, other: Self) -> SelfCompares and returns the minimum of two values. Read more
impl Hash for ImGuiDragDropFlags
impl Hash for ImGuiDragDropFlagsfn hash<__H: Hasher>(&self, state: &mut __H)
fn hash<__H: Hasher>(&self, state: &mut __H)Feeds this value into the given [Hasher]. Read more
fn hash_slice<H>(data: &[Self], state: &mut H) where
H: Hasher, 1.3.0[src]
fn hash_slice<H>(data: &[Self], state: &mut H) where
H: Hasher, Feeds a slice of this type into the given [Hasher]. Read more
impl Debug for ImGuiDragDropFlags
impl Debug for ImGuiDragDropFlagsimpl Binary for ImGuiDragDropFlags
impl Binary for ImGuiDragDropFlagsimpl Octal for ImGuiDragDropFlags
impl Octal for ImGuiDragDropFlagsimpl LowerHex for ImGuiDragDropFlags
impl LowerHex for ImGuiDragDropFlagsimpl UpperHex for ImGuiDragDropFlags
impl UpperHex for ImGuiDragDropFlagsimpl BitOr for ImGuiDragDropFlags
impl BitOr for ImGuiDragDropFlagstype Output = ImGuiDragDropFlags
The resulting type after applying the | operator.
fn bitor(self, other: ImGuiDragDropFlags) -> ImGuiDragDropFlags
fn bitor(self, other: ImGuiDragDropFlags) -> ImGuiDragDropFlagsReturns the union of the two sets of flags.
impl BitOrAssign for ImGuiDragDropFlags
impl BitOrAssign for ImGuiDragDropFlagsfn bitor_assign(&mut self, other: ImGuiDragDropFlags)
fn bitor_assign(&mut self, other: ImGuiDragDropFlags)Adds the set of flags.
impl BitXor for ImGuiDragDropFlags
impl BitXor for ImGuiDragDropFlagstype Output = ImGuiDragDropFlags
The resulting type after applying the ^ operator.
fn bitxor(self, other: ImGuiDragDropFlags) -> ImGuiDragDropFlags
fn bitxor(self, other: ImGuiDragDropFlags) -> ImGuiDragDropFlagsReturns the left flags, but with all the right flags toggled.
impl BitXorAssign for ImGuiDragDropFlags
impl BitXorAssign for ImGuiDragDropFlagsfn bitxor_assign(&mut self, other: ImGuiDragDropFlags)
fn bitxor_assign(&mut self, other: ImGuiDragDropFlags)Toggles the set of flags.
impl BitAnd for ImGuiDragDropFlags
impl BitAnd for ImGuiDragDropFlagstype Output = ImGuiDragDropFlags
The resulting type after applying the & operator.
fn bitand(self, other: ImGuiDragDropFlags) -> ImGuiDragDropFlags
fn bitand(self, other: ImGuiDragDropFlags) -> ImGuiDragDropFlagsReturns the intersection between the two sets of flags.
impl BitAndAssign for ImGuiDragDropFlags
impl BitAndAssign for ImGuiDragDropFlagsfn bitand_assign(&mut self, other: ImGuiDragDropFlags)
fn bitand_assign(&mut self, other: ImGuiDragDropFlags)Disables all flags disabled in the set.
impl Sub for ImGuiDragDropFlags
impl Sub for ImGuiDragDropFlagstype Output = ImGuiDragDropFlags
The resulting type after applying the - operator.
fn sub(self, other: ImGuiDragDropFlags) -> ImGuiDragDropFlags
fn sub(self, other: ImGuiDragDropFlags) -> ImGuiDragDropFlagsReturns the set difference of the two sets of flags.
impl SubAssign for ImGuiDragDropFlags
impl SubAssign for ImGuiDragDropFlagsfn sub_assign(&mut self, other: ImGuiDragDropFlags)
fn sub_assign(&mut self, other: ImGuiDragDropFlags)Disables all flags enabled in the set.
impl Not for ImGuiDragDropFlags
impl Not for ImGuiDragDropFlagstype Output = ImGuiDragDropFlags
The resulting type after applying the ! operator.
fn not(self) -> ImGuiDragDropFlags
fn not(self) -> ImGuiDragDropFlagsReturns the complement of this set of flags.
impl Extend<ImGuiDragDropFlags> for ImGuiDragDropFlags
impl Extend<ImGuiDragDropFlags> for ImGuiDragDropFlagsfn extend<T: IntoIterator<Item = ImGuiDragDropFlags>>(&mut self, iterator: T)
fn extend<T: IntoIterator<Item = ImGuiDragDropFlags>>(&mut self, iterator: T)Extends a collection with the contents of an iterator. Read more
impl FromIterator<ImGuiDragDropFlags> for ImGuiDragDropFlags
impl FromIterator<ImGuiDragDropFlags> for ImGuiDragDropFlagsfn from_iter<T: IntoIterator<Item = ImGuiDragDropFlags>>(
iterator: T
) -> ImGuiDragDropFlags
fn from_iter<T: IntoIterator<Item = ImGuiDragDropFlags>>(
iterator: T
) -> ImGuiDragDropFlagsCreates a value from an iterator. Read more
Auto Trait Implementations
impl Send for ImGuiDragDropFlags
impl Send for ImGuiDragDropFlagsimpl Sync for ImGuiDragDropFlags
impl Sync for ImGuiDragDropFlags