Some tweaks

This commit is contained in:
Ray
2019-02-14 17:56:02 +01:00
parent 1e730686c9
commit d51438d910

View File

@ -763,7 +763,7 @@ RAYGUIDEF void GuiGroupBox(Rectangle bounds, const char *text)
DrawRectangle(bounds.x, bounds.y + bounds.height - 1, bounds.width, GROUPBOX_LINE_THICK, Fade(GetColor(GuiGetStyle(DEFAULT, (state == GUI_STATE_DISABLED) ? BORDER_COLOR_DISABLED : LINE_COLOR)), guiAlpha));
DrawRectangle(bounds.x + bounds.width - 1, bounds.y, GROUPBOX_LINE_THICK, bounds.height, Fade(GetColor(GuiGetStyle(DEFAULT, (state == GUI_STATE_DISABLED) ? BORDER_COLOR_DISABLED : LINE_COLOR)), guiAlpha));
GuiLine((Rectangle){ bounds.x, bounds.y, bounds.width, GuiGetStyle(DEFAULT, TEXT_SIZE) }, text);
GuiLine((Rectangle){ bounds.x, bounds.y, bounds.width, 1 }, text);
//--------------------------------------------------------------------
}
@ -780,7 +780,7 @@ RAYGUIDEF void GuiLine(Rectangle bounds, const char *text)
// Draw control
//--------------------------------------------------------------------
if (text == NULL) DrawRectangle(bounds.x, bounds.y, bounds.width, 1, color);
if (text == NULL) DrawRectangle(bounds.x, bounds.y + bounds.height/2, bounds.width, 1, color);
else
{
Rectangle textBounds = { 0 };
@ -2889,7 +2889,7 @@ RAYGUIDEF void GuiLoadStyleDefault(void)
GuiSetStyle(DEFAULT, BASE_COLOR_DISABLED, 0xe6e9e9ff);
GuiSetStyle(DEFAULT, TEXT_COLOR_DISABLED, 0xaeb7b8ff);
GuiSetStyle(DEFAULT, BORDER_WIDTH, 1);
GuiSetStyle(DEFAULT, INNER_PADDING, 2);
GuiSetStyle(DEFAULT, INNER_PADDING, 1);
GuiSetStyle(DEFAULT, TEXT_ALIGNMENT, GUI_TEXT_ALIGN_CENTER);
// Populate all controls with default style
@ -2905,7 +2905,9 @@ RAYGUIDEF void GuiLoadStyleDefault(void)
GuiSetStyle(DEFAULT, LINE_COLOR, 0x90abb5ff); // DEFAULT specific property
GuiSetStyle(DEFAULT, BACKGROUND_COLOR, 0xf5f5f5ff); // DEFAULT specific property
GuiSetStyle(LABEL, TEXT_ALIGNMENT, GUI_TEXT_ALIGN_LEFT);
GuiSetStyle(BUTTON, BORDER_WIDTH, 2);
GuiSetStyle(BUTTON, INNER_PADDING, 4);
GuiSetStyle(TOGGLE, GROUP_PADDING, 2);
GuiSetStyle(SLIDER, SLIDER_WIDTH, 15);
GuiSetStyle(SLIDER, TEXT_PADDING, 5);