Skip to content

Commit

Permalink
REVIEWED: Load default style before loading a custom style raysan5/rg…
Browse files Browse the repository at this point in the history
…uistyler#8

Make sure default style has been loaded to avoid overwriting new style properties due to the lazy initialization of default style.
  • Loading branch information
raysan5 committed Apr 3, 2024
1 parent c0d0578 commit e3f67f3
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/raygui.h
Original file line number Diff line number Diff line change
Expand Up @@ -3937,6 +3937,7 @@ void GuiLoadStyle(const char *fileName)
#define MAX_LINE_BUFFER_SIZE 256

bool tryBinary = false;
if (!guiStyleLoaded) GuiLoadStyleDefault();

// Try reading the files as text file first
FILE *rgsFile = fopen(fileName, "rt");
Expand Down

0 comments on commit e3f67f3

Please sign in to comment.