mirror of
https://github.com/raysan5/raygui.git
synced 2026-04-27 09:07:26 -04:00
Some code tweaks
This commit is contained in:
@ -1908,17 +1908,15 @@ RAYGUIDEF float GuiProgressBar(Rectangle bounds, const char *text, float value,
|
||||
|
||||
// Status Bar control
|
||||
RAYGUIDEF void GuiStatusBar(Rectangle bounds, const char *text)
|
||||
{
|
||||
#define STATUSBAR_TEXT_OFFSETX 10
|
||||
|
||||
GuiControlState state = guiState;
|
||||
{
|
||||
GuiControlState state = guiState;
|
||||
|
||||
// Draw control
|
||||
//--------------------------------------------------------------------
|
||||
DrawRectangleLinesEx(bounds, GuiGetStyle(DEFAULT, BORDER_WIDTH), Fade(GetColor(GuiGetStyle(DEFAULT, (state != GUI_STATE_DISABLED) ? BORDER_COLOR_NORMAL : BORDER_COLOR_DISABLED)), guiAlpha));
|
||||
DrawRectangleRec((Rectangle){ bounds.x + GuiGetStyle(DEFAULT, BORDER_WIDTH), bounds.y + GuiGetStyle(DEFAULT, BORDER_WIDTH), bounds.width - GuiGetStyle(DEFAULT, BORDER_WIDTH)*2, bounds.height - GuiGetStyle(DEFAULT, BORDER_WIDTH)*2 }, Fade(GetColor(GuiGetStyle(DEFAULT, (state != GUI_STATE_DISABLED) ? BASE_COLOR_NORMAL : BASE_COLOR_DISABLED)), guiAlpha));
|
||||
|
||||
GuiDrawText(text, bounds, GUI_TEXT_ALIGN_LEFT, Fade(GetColor(GuiGetStyle(DEFAULT, (state != GUI_STATE_DISABLED) ? TEXT_COLOR_NORMAL : TEXT_COLOR_DISABLED)), guiAlpha));
|
||||
GuiDrawText(text, GetTextBounds(DEFAULT, bounds), GUI_TEXT_ALIGN_LEFT, Fade(GetColor(GuiGetStyle(DEFAULT, (state != GUI_STATE_DISABLED) ? TEXT_COLOR_NORMAL : TEXT_COLOR_DISABLED)), guiAlpha));
|
||||
//--------------------------------------------------------------------
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user