Skip to main content

ColorId

Enum ColorId 

Source
#[repr(i32)]
pub enum ColorId {
Show 63 variants Text = 0, TextDisabled = 1, WindowBg = 2, ChildBg = 3, PopupBg = 4, Border = 5, BorderShadow = 6, FrameBg = 7, FrameBgHovered = 8, FrameBgActive = 9, TitleBg = 10, TitleBgActive = 11, TitleBgCollapsed = 12, MenuBarBg = 13, ScrollbarBg = 14, ScrollbarGrab = 15, ScrollbarGrabHovered = 16, ScrollbarGrabActive = 17, CheckMark = 18, CheckboxSelectedBg = 19, SliderGrab = 20, SliderGrabActive = 21, Button = 22, ButtonHovered = 23, ButtonActive = 24, Header = 25, HeaderHovered = 26, HeaderActive = 27, Separator = 28, SeparatorHovered = 29, SeparatorActive = 30, ResizeGrip = 31, ResizeGripHovered = 32, ResizeGripActive = 33, InputTextCursor = 34, TabHovered = 35, Tab = 36, TabSelected = 37, TabSelectedOverline = 38, TabDimmed = 39, TabDimmedSelected = 40, TabDimmedSelectedOverline = 41, DockingPreview = 42, DockingEmptyBg = 43, PlotLines = 44, PlotLinesHovered = 45, PlotHistogram = 46, PlotHistogramHovered = 47, TableHeaderBg = 48, TableBorderStrong = 49, TableBorderLight = 50, TableRowBg = 51, TableRowBgAlt = 52, TextLink = 53, TextSelectedBg = 54, TreeLines = 55, DragDropTarget = 56, DragDropTargetBg = 57, UnsavedMarker = 58, NavCursor = 59, NavWindowingHighlight = 60, NavWindowingDimBg = 61, ModalWindowDimBg = 62,
}
Expand description

Dear ImGui (ImGuiCol): Color identifier for styling

Variants§

§

Text = 0

Dear ImGui (ImGuiCol_Text): Text

§

TextDisabled = 1

Dear ImGui (ImGuiCol_TextDisabled): Text disabled

§

WindowBg = 2

Dear ImGui (ImGuiCol_WindowBg): Background of normal windows

§

ChildBg = 3

Dear ImGui (ImGuiCol_ChildBg): Background of child windows

§

PopupBg = 4

Dear ImGui (ImGuiCol_PopupBg): Background of popups, menus, tooltips windows

§

Border = 5

Dear ImGui (ImGuiCol_Border): Border

§

BorderShadow = 6

Dear ImGui (ImGuiCol_BorderShadow): Border shadow

§

FrameBg = 7

Dear ImGui (ImGuiCol_FrameBg): Background of checkbox, radio button, plot, slider, text input

§

FrameBgHovered = 8

Dear ImGui (ImGuiCol_FrameBgHovered): Frame background hovered

§

FrameBgActive = 9

Dear ImGui (ImGuiCol_FrameBgActive): Frame background active

§

TitleBg = 10

Dear ImGui (ImGuiCol_TitleBg): Title bar

§

TitleBgActive = 11

Dear ImGui (ImGuiCol_TitleBgActive): Title bar when focused

§

TitleBgCollapsed = 12

Dear ImGui (ImGuiCol_TitleBgCollapsed): Title bar when collapsed

§

MenuBarBg = 13

Dear ImGui (ImGuiCol_MenuBarBg): Menu bar background

§

ScrollbarBg = 14

Dear ImGui (ImGuiCol_ScrollbarBg): Scrollbar background

§

ScrollbarGrab = 15

Dear ImGui (ImGuiCol_ScrollbarGrab): Scrollbar grab

§

ScrollbarGrabHovered = 16

Dear ImGui (ImGuiCol_ScrollbarGrabHovered): Scrollbar grab hovered

§

ScrollbarGrabActive = 17

Dear ImGui (ImGuiCol_ScrollbarGrabActive): Scrollbar grab active

§

CheckMark = 18

Dear ImGui (ImGuiCol_CheckMark): Checkbox tick and RadioButton circle

§

CheckboxSelectedBg = 19

Dear ImGui (ImGuiCol_CheckboxSelectedBg): Checkbox background when selected

§

SliderGrab = 20

Dear ImGui (ImGuiCol_SliderGrab): Slider grab

§

SliderGrabActive = 21

Dear ImGui (ImGuiCol_SliderGrabActive): Slider grab active

§

Button = 22

Dear ImGui (ImGuiCol_Button): Button

§

ButtonHovered = 23

Dear ImGui (ImGuiCol_ButtonHovered): Button hovered

§

ButtonActive = 24

Dear ImGui (ImGuiCol_ButtonActive): Button active

§

Header = 25

Dear ImGui (ImGuiCol_Header): Header colors for CollapsingHeader, TreeNode, Selectable, MenuItem

§

HeaderHovered = 26

Dear ImGui (ImGuiCol_HeaderHovered): Header hovered

§

HeaderActive = 27

Dear ImGui (ImGuiCol_HeaderActive): Header active

§

Separator = 28

Dear ImGui (ImGuiCol_Separator): Separator

§

SeparatorHovered = 29

Dear ImGui (ImGuiCol_SeparatorHovered): Separator hovered

§

SeparatorActive = 30

Dear ImGui (ImGuiCol_SeparatorActive): Separator active

§

ResizeGrip = 31

Dear ImGui (ImGuiCol_ResizeGrip): Resize grip

§

ResizeGripHovered = 32

Dear ImGui (ImGuiCol_ResizeGripHovered): Resize grip hovered

§

ResizeGripActive = 33

Dear ImGui (ImGuiCol_ResizeGripActive): Resize grip active

§

InputTextCursor = 34

Dear ImGui (ImGuiCol_InputTextCursor): InputText cursor/caret

§

TabHovered = 35

Dear ImGui (ImGuiCol_TabHovered): Tab background, when hovered

§

Tab = 36

Dear ImGui (ImGuiCol_Tab): Tab background, when tab-bar is focused & tab is unselected

§

TabSelected = 37

Dear ImGui (ImGuiCol_TabSelected): Tab background, when tab-bar is focused & tab is selected

§

TabSelectedOverline = 38

Dear ImGui (ImGuiCol_TabSelectedOverline): Tab horizontal overline, when tab-bar is focused & tab is selected

§

TabDimmed = 39

Dear ImGui (ImGuiCol_TabDimmed): Tab background, when tab-bar is unfocused & tab is unselected

§

TabDimmedSelected = 40

Dear ImGui (ImGuiCol_TabDimmedSelected): Tab background, when tab-bar is unfocused & tab is selected

§

TabDimmedSelectedOverline = 41

Dear ImGui (ImGuiCol_TabDimmedSelectedOverline): Tab horizontal overline, when tab-bar is unfocused & tab is selected

§

DockingPreview = 42

Dear ImGui (ImGuiCol_DockingPreview): Preview overlay color when about to docking something

§

DockingEmptyBg = 43

Dear ImGui (ImGuiCol_DockingEmptyBg): Background color for empty node

§

PlotLines = 44

Dear ImGui (ImGuiCol_PlotLines): Plot lines

§

PlotLinesHovered = 45

Dear ImGui (ImGuiCol_PlotLinesHovered): Plot lines hovered

§

PlotHistogram = 46

Dear ImGui (ImGuiCol_PlotHistogram): Plot histogram

§

PlotHistogramHovered = 47

Dear ImGui (ImGuiCol_PlotHistogramHovered): Plot histogram hovered

§

TableHeaderBg = 48

Dear ImGui (ImGuiCol_TableHeaderBg): Table header background

§

TableBorderStrong = 49

Dear ImGui (ImGuiCol_TableBorderStrong): Table outer and header borders

§

TableBorderLight = 50

Dear ImGui (ImGuiCol_TableBorderLight): Table inner borders

§

TableRowBg = 51

Dear ImGui (ImGuiCol_TableRowBg): Table row background (even rows)

§

TableRowBgAlt = 52

Dear ImGui (ImGuiCol_TableRowBgAlt): Table row background (odd rows)

Dear ImGui (ImGuiCol_TextLink): Hyperlink color

§

TextSelectedBg = 54

Dear ImGui (ImGuiCol_TextSelectedBg): Selected text inside an InputText

§

TreeLines = 55

Dear ImGui (ImGuiCol_TreeLines): Tree node hierarchy outlines

§

DragDropTarget = 56

Dear ImGui (ImGuiCol_DragDropTarget): Rectangle border highlighting a drop target

§

DragDropTargetBg = 57

Dear ImGui (ImGuiCol_DragDropTargetBg): Rectangle background highlighting a drop target

§

UnsavedMarker = 58

Dear ImGui (ImGuiCol_UnsavedMarker): Unsaved marker color

§

NavCursor = 59

Dear ImGui (ImGuiCol_NavCursor): Navigation cursor

§

NavWindowingHighlight = 60

Dear ImGui (ImGuiCol_NavWindowingHighlight): Navigation windowing highlight

§

NavWindowingDimBg = 61

Dear ImGui (ImGuiCol_NavWindowingDimBg): Navigation windowing dim background

§

ModalWindowDimBg = 62

Dear ImGui (ImGuiCol_ModalWindowDimBg): Modal window dim background

Implementations§

Source§

impl ColorId

Source

pub fn bits(self) -> i32

Source

pub fn from_bits(bits: i32) -> Option<Self>

Trait Implementations§

Source§

impl Clone for ColorId

Source§

fn clone(&self) -> ColorId

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Copy for ColorId

Source§

impl Debug for ColorId

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Eq for ColorId

Source§

impl Ord for ColorId

Source§

fn cmp(&self, other: &ColorId) -> Ordering

This method returns an Ordering between self and other. Read more
1.21.0 (const: unstable) · Source§

fn max(self, other: Self) -> Self
where Self: Sized,

Compares and returns the maximum of two values. Read more
1.21.0 (const: unstable) · Source§

fn min(self, other: Self) -> Self
where Self: Sized,

Compares and returns the minimum of two values. Read more
1.50.0 (const: unstable) · Source§

fn clamp(self, min: Self, max: Self) -> Self
where Self: Sized,

Restrict a value to a certain interval. Read more
Source§

impl PartialEq for ColorId

Source§

fn eq(&self, other: &ColorId) -> bool

Equality operator ==. Read more
1.0.0 (const: unstable) · Source§

fn ne(&self, other: &Rhs) -> bool

Inequality operator !=. Read more
Source§

impl PartialOrd for ColorId

Source§

fn partial_cmp(&self, other: &ColorId) -> Option<Ordering>

This method returns an ordering between self and other values if one exists. Read more
1.0.0 (const: unstable) · Source§

fn lt(&self, other: &Rhs) -> bool

Tests less than (for self and other) and is used by the < operator. Read more
1.0.0 (const: unstable) · Source§

fn le(&self, other: &Rhs) -> bool

Tests less than or equal to (for self and other) and is used by the <= operator. Read more
1.0.0 (const: unstable) · Source§

fn gt(&self, other: &Rhs) -> bool

Tests greater than (for self and other) and is used by the > operator. Read more
1.0.0 (const: unstable) · Source§

fn ge(&self, other: &Rhs) -> bool

Tests greater than or equal to (for self and other) and is used by the >= operator. Read more
Source§

impl StructuralPartialEq for ColorId

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> IntoEither for T

Source§

fn into_either(self, into_left: bool) -> Either<Self, Self>

Converts self into a Left variant of Either<Self, Self> if into_left is true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
Source§

fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
where F: FnOnce(&Self) -> bool,

Converts self into a Left variant of Either<Self, Self> if into_left(&self) returns true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.