mirror of
https://github.com/nicbarker/clay.git
synced 2025-05-03 17:08:06 +00:00
Compare commits
4 Commits
1b419ecbbd
...
05cd3b7a46
Author | SHA1 | Date | |
---|---|---|---|
|
05cd3b7a46 | ||
|
9e7595b873 | ||
|
32d1a31dfe | ||
|
4c02bd08a7 |
1
.gitignore
vendored
1
.gitignore
vendored
@ -1,6 +1,5 @@
|
|||||||
cmake-build-debug/
|
cmake-build-debug/
|
||||||
cmake-build-release/
|
cmake-build-release/
|
||||||
build/
|
|
||||||
.DS_Store
|
.DS_Store
|
||||||
.idea/
|
.idea/
|
||||||
node_modules/
|
node_modules/
|
||||||
|
4
clay.h
4
clay.h
@ -1390,7 +1390,7 @@ struct Clay_Context {
|
|||||||
bool externalScrollHandlingEnabled;
|
bool externalScrollHandlingEnabled;
|
||||||
uint32_t debugSelectedElementId;
|
uint32_t debugSelectedElementId;
|
||||||
uint32_t generation;
|
uint32_t generation;
|
||||||
uint64_t arenaResetOffset;
|
uintptr_t arenaResetOffset;
|
||||||
Clay_Arena internalArena;
|
Clay_Arena internalArena;
|
||||||
// Layout Elements / Render Commands
|
// Layout Elements / Render Commands
|
||||||
Clay_LayoutElementArray layoutElements;
|
Clay_LayoutElementArray layoutElements;
|
||||||
@ -3615,7 +3615,7 @@ uint32_t Clay_MinMemorySize(void) {
|
|||||||
.maxMeasureTextCacheWordCount = Clay__defaultMaxMeasureTextWordCacheCount,
|
.maxMeasureTextCacheWordCount = Clay__defaultMaxMeasureTextWordCacheCount,
|
||||||
.internalArena = {
|
.internalArena = {
|
||||||
.capacity = SIZE_MAX,
|
.capacity = SIZE_MAX,
|
||||||
.memory = (char*)&fakeContext,
|
.memory = NULL,
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
Clay_Context* currentContext = Clay_GetCurrentContext();
|
Clay_Context* currentContext = Clay_GetCurrentContext();
|
||||||
|
Binary file not shown.
@ -220,7 +220,7 @@ int main(void) {
|
|||||||
Clay_Arena clayMemory = Clay_CreateArenaWithCapacityAndMemory(totalMemorySize, malloc(totalMemorySize));
|
Clay_Arena clayMemory = Clay_CreateArenaWithCapacityAndMemory(totalMemorySize, malloc(totalMemorySize));
|
||||||
Clay_SetMeasureTextFunction(Raylib_MeasureText);
|
Clay_SetMeasureTextFunction(Raylib_MeasureText);
|
||||||
Clay_Initialize(clayMemory, (Clay_Dimensions) { (float)GetScreenWidth(), (float)GetScreenHeight() }, (Clay_ErrorHandler) { HandleClayErrors });
|
Clay_Initialize(clayMemory, (Clay_Dimensions) { (float)GetScreenWidth(), (float)GetScreenHeight() }, (Clay_ErrorHandler) { HandleClayErrors });
|
||||||
Clay_Raylib_Initialize(1024, 768, "Clay - Raylib Renderer Example", FLAG_VSYNC_HINT | FLAG_WINDOW_RESIZABLE | FLAG_WINDOW_HIGHDPI | FLAG_MSAA_4X_HINT);
|
Clay_Raylib_Initialize(1024, 768, "Clay - Raylib Renderer Example", FLAG_VSYNC_HINT | FLAG_WINDOW_RESIZABLE | FLAG_MSAA_4X_HINT);
|
||||||
profilePicture = LoadTextureFromImage(LoadImage("resources/profile-picture.png"));
|
profilePicture = LoadTextureFromImage(LoadImage("resources/profile-picture.png"));
|
||||||
Raylib_fonts[FONT_ID_BODY_24] = (Raylib_Font) {
|
Raylib_fonts[FONT_ID_BODY_24] = (Raylib_Font) {
|
||||||
.font = LoadFontEx("resources/Roboto-Regular.ttf", 48, 0, 400),
|
.font = LoadFontEx("resources/Roboto-Regular.ttf", 48, 0, 400),
|
||||||
|
Loading…
Reference in New Issue
Block a user