Skip to content

Commit

Permalink
Remove STYLE_ defines as we have the style dropdown
Browse files Browse the repository at this point in the history
  • Loading branch information
RobLoach committed Apr 25, 2024
1 parent 2f2474a commit 4cfea49
Show file tree
Hide file tree
Showing 21 changed files with 1 addition and 284 deletions.
14 changes: 0 additions & 14 deletions demo/allegro5/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -114,20 +114,6 @@ int main(void)

ctx = nk_allegro5_init(font, display, WINDOW_WIDTH, WINDOW_HEIGHT);

/* style.c */
#ifdef INCLUDE_STYLE
/* ease regression testing during Nuklear release process; not needed for anything else */
#ifdef STYLE_WHITE
set_style(ctx, THEME_WHITE);
#elif defined(STYLE_RED)
set_style(ctx, THEME_RED);
#elif defined(STYLE_BLUE)
set_style(ctx, THEME_BLUE);
#elif defined(STYLE_DARK)
set_style(ctx, THEME_DARK);
#endif
#endif

while(1)
{
bool get_event;
Expand Down
14 changes: 0 additions & 14 deletions demo/d3d11/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -208,20 +208,6 @@ int main(void)
/*nk_style_load_all_cursors(ctx, atlas->cursors);*/
/*nk_style_set_font(ctx, &droid->handle)*/;}

/* style.c */
#ifdef INCLUDE_STYLE
/* ease regression testing during Nuklear release process; not needed for anything else */
#ifdef STYLE_WHITE
set_style(ctx, THEME_WHITE);
#elif defined(STYLE_RED)
set_style(ctx, THEME_RED);
#elif defined(STYLE_BLUE)
set_style(ctx, THEME_BLUE);
#elif defined(STYLE_DARK)
set_style(ctx, THEME_DARK);
#endif
#endif

bg.r = 0.10f, bg.g = 0.18f, bg.b = 0.24f, bg.a = 1.0f;
while (running)
{
Expand Down
14 changes: 0 additions & 14 deletions demo/d3d12/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -300,20 +300,6 @@ int main(void)
/* Now we can cleanup all resources consumed by font stashing that are no longer used */
nk_d3d12_font_stash_cleanup();

/* style.c */
#ifdef INCLUDE_STYLE
/* ease regression testing during Nuklear release process; not needed for anything else */
#ifdef STYLE_WHITE
set_style(ctx, THEME_WHITE);
#elif defined(STYLE_RED)
set_style(ctx, THEME_RED);
#elif defined(STYLE_BLUE)
set_style(ctx, THEME_BLUE);
#elif defined(STYLE_DARK)
set_style(ctx, THEME_DARK);
#endif
#endif

bg.r = 0.10f, bg.g = 0.18f, bg.b = 0.24f, bg.a = 1.0f;
while (running)
{
Expand Down
14 changes: 0 additions & 14 deletions demo/d3d9/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -214,20 +214,6 @@ int main(void)
/*nk_style_load_all_cursors(ctx, atlas->cursors);*/
/*nk_style_set_font(ctx, &droid->handle)*/;}

/* style.c */
#ifdef INCLUDE_STYLE
/* ease regression testing during Nuklear release process; not needed for anything else */
#ifdef STYLE_WHITE
set_style(ctx, THEME_WHITE);
#elif defined(STYLE_RED)
set_style(ctx, THEME_RED);
#elif defined(STYLE_BLUE)
set_style(ctx, THEME_BLUE);
#elif defined(STYLE_DARK)
set_style(ctx, THEME_DARK);
#endif
#endif

bg.r = 0.10f, bg.g = 0.18f, bg.b = 0.24f, bg.a = 1.0f;
while (running)
{
Expand Down
14 changes: 0 additions & 14 deletions demo/gdi/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -113,20 +113,6 @@ int main(void)
font = nk_gdifont_create("Arial", 14);
ctx = nk_gdi_init(font, dc, WINDOW_WIDTH, WINDOW_HEIGHT);

/* style.c */
#ifdef INCLUDE_STYLE
/* ease regression testing during Nuklear release process; not needed for anything else */
#ifdef STYLE_WHITE
set_style(ctx, THEME_WHITE);
#elif defined(STYLE_RED)
set_style(ctx, THEME_RED);
#elif defined(STYLE_BLUE)
set_style(ctx, THEME_BLUE);
#elif defined(STYLE_DARK)
set_style(ctx, THEME_DARK);
#endif
#endif

while (running)
{
/* Input */
Expand Down
14 changes: 0 additions & 14 deletions demo/gdip/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -109,20 +109,6 @@ int main(void)
font = nk_gdipfont_create("Arial", 12);
nk_gdip_set_font(font);

/* style.c */
#ifdef INCLUDE_STYLE
/* ease regression testing during Nuklear release process; not needed for anything else */
#ifdef STYLE_WHITE
set_style(ctx, THEME_WHITE);
#elif defined(STYLE_RED)
set_style(ctx, THEME_RED);
#elif defined(STYLE_BLUE)
set_style(ctx, THEME_BLUE);
#elif defined(STYLE_DARK)
set_style(ctx, THEME_DARK);
#endif
#endif

while (running)
{
/* Input */
Expand Down
13 changes: 0 additions & 13 deletions demo/glfw_opengl2/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -120,19 +120,6 @@ int main(void)
/*nk_style_load_all_cursors(ctx, atlas->cursors);*/
/*nk_style_set_font(ctx, &droid->handle);*/}

#ifdef INCLUDE_STYLE
/* ease regression testing during Nuklear release process; not needed for anything else */
#ifdef STYLE_WHITE
set_style(ctx, THEME_WHITE);
#elif defined(STYLE_RED)
set_style(ctx, THEME_RED);
#elif defined(STYLE_BLUE)
set_style(ctx, THEME_BLUE);
#elif defined(STYLE_DARK)
set_style(ctx, THEME_DARK);
#endif
#endif

bg.r = 0.10f, bg.g = 0.18f, bg.b = 0.24f, bg.a = 1.0f;

#ifdef INCLUDE_FILE_BROWSER
Expand Down
13 changes: 0 additions & 13 deletions demo/glfw_opengl3/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -125,19 +125,6 @@ int main(void)
/*nk_style_load_all_cursors(ctx, atlas->cursors);*/
/*nk_style_set_font(ctx, &droid->handle);*/}

#ifdef INCLUDE_STYLE
/* ease regression testing during Nuklear release process; not needed for anything else */
#ifdef STYLE_WHITE
set_style(ctx, THEME_WHITE);
#elif defined(STYLE_RED)
set_style(ctx, THEME_RED);
#elif defined(STYLE_BLUE)
set_style(ctx, THEME_BLUE);
#elif defined(STYLE_DARK)
set_style(ctx, THEME_DARK);
#endif
#endif

bg.r = 0.10f, bg.g = 0.18f, bg.b = 0.24f, bg.a = 1.0f;
while (!glfwWindowShouldClose(win))
{
Expand Down
13 changes: 0 additions & 13 deletions demo/glfw_opengl4/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -125,19 +125,6 @@ int main(void)
/*nk_style_load_all_cursors(ctx, atlas->cursors);*/
/*nk_style_set_font(ctx, &droid->handle);*/}

#ifdef INCLUDE_STYLE
/* ease regression testing during Nuklear release process; not needed for anything else */
#ifdef STYLE_WHITE
set_style(ctx, THEME_WHITE);
#elif defined(STYLE_RED)
set_style(ctx, THEME_RED);
#elif defined(STYLE_BLUE)
set_style(ctx, THEME_BLUE);
#elif defined(STYLE_DARK)
set_style(ctx, THEME_DARK);
#endif
#endif

/* Create bindless texture.
* The index returned is not the opengl resource id.
* IF you need the GL resource id use: nk_glfw3_get_tex_ogl_id() */
Expand Down
14 changes: 0 additions & 14 deletions demo/glfw_vulkan/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -2104,20 +2104,6 @@ int main(void) {
/*nk_style_load_all_cursors(ctx, atlas->cursors);*/
/*nk_style_set_font(ctx, &droid->handle);*/}

#ifdef INCLUDE_STYLE
/* ease regression testing during Nuklear release process; not needed for
* anything else */
#ifdef STYLE_WHITE
set_style(ctx, THEME_WHITE);
#elif defined(STYLE_RED)
set_style(ctx, THEME_RED);
#elif defined(STYLE_BLUE)
set_style(ctx, THEME_BLUE);
#elif defined(STYLE_DARK)
set_style(ctx, THEME_DARK);
#endif
#endif

img = nk_image_ptr(demo.demo_texture_image_view);
bg.r = 0.10f, bg.g = 0.18f, bg.b = 0.24f, bg.a = 1.0f;
while (!glfwWindowShouldClose(demo.win)) {
Expand Down
13 changes: 0 additions & 13 deletions demo/rawfb/x11/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -193,19 +193,6 @@ main(void)
rawfb = nk_rawfb_init(fb, tex_scratch, xw.width, xw.height, xw.width * 4, pl);
if (!rawfb) running = 0;

#ifdef INCLUDE_STYLE
/* ease regression testing during Nuklear release process; not needed for anything else */
#ifdef STYLE_WHITE
set_style(&rawfb->ctx, THEME_WHITE);
#elif defined(STYLE_RED)
set_style(&rawfb->ctx, THEME_RED);
#elif defined(STYLE_BLUE)
set_style(&rawfb->ctx, THEME_BLUE);
#elif defined(STYLE_DARK)
set_style(&rawfb->ctx, THEME_DARK);
#endif
#endif

while (running) {
/* Input */
XEvent evt;
Expand Down
13 changes: 0 additions & 13 deletions demo/sdl_opengl2/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -116,19 +116,6 @@ main(int argc, char *argv[])
/*nk_style_load_all_cursors(ctx, atlas->cursors);*/
/*nk_style_set_font(ctx, &roboto->handle)*/;}

#ifdef INCLUDE_STYLE
/* ease regression testing during Nuklear release process; not needed for anything else */
#ifdef STYLE_WHITE
set_style(ctx, THEME_WHITE);
#elif defined(STYLE_RED)
set_style(ctx, THEME_RED);
#elif defined(STYLE_BLUE)
set_style(ctx, THEME_BLUE);
#elif defined(STYLE_DARK)
set_style(ctx, THEME_DARK);
#endif
#endif

bg.r = 0.10f, bg.g = 0.18f, bg.b = 0.24f, bg.a = 1.0f;
while (running)
{
Expand Down
14 changes: 0 additions & 14 deletions demo/sdl_opengl3/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -126,20 +126,6 @@ int main(int argc, char *argv[])
/*nk_style_load_all_cursors(ctx, atlas->cursors);*/
/*nk_style_set_font(ctx, &roboto->handle);*/}

/* style.c */
#ifdef INCLUDE_STYLE
/* ease regression testing during Nuklear release process; not needed for anything else */
#ifdef STYLE_WHITE
set_style(ctx, THEME_WHITE);
#elif defined(STYLE_RED)
set_style(ctx, THEME_RED);
#elif defined(STYLE_BLUE)
set_style(ctx, THEME_BLUE);
#elif defined(STYLE_DARK)
set_style(ctx, THEME_DARK);
#endif
#endif

bg.r = 0.10f, bg.g = 0.18f, bg.b = 0.24f, bg.a = 1.0f;
while (running)
{
Expand Down
14 changes: 0 additions & 14 deletions demo/sdl_opengles2/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -209,20 +209,6 @@ int main(int argc, char* argv[])
/*nk_style_load_all_cursors(ctx, atlas->cursors);*/
/*nk_style_set_font(ctx, &roboto->handle)*/;}

/* style.c */
#ifdef INCLUDE_STYLE
/* ease regression testing during Nuklear release process; not needed for anything else */
#ifdef STYLE_WHITE
set_style(ctx, THEME_WHITE);
#elif defined(STYLE_RED)
set_style(ctx, THEME_RED);
#elif defined(STYLE_BLUE)
set_style(ctx, THEME_BLUE);
#elif defined(STYLE_DARK)
set_style(ctx, THEME_DARK);
#endif
#endif

#if defined(__EMSCRIPTEN__)
#include <emscripten.h>
emscripten_set_main_loop_arg(MainLoop, (void*)ctx, 0, nk_true);
Expand Down
14 changes: 1 addition & 13 deletions demo/sdl_renderer/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@
/*#define INCLUDE_CALCULATOR */
/*#define INCLUDE_OVERVIEW */
/*#define INCLUDE_NODE_EDITOR */
/*#define INCLUDE_STYLE */

#ifdef INCLUDE_ALL
#define INCLUDE_STYLE
Expand Down Expand Up @@ -154,19 +155,6 @@ main(int argc, char *argv[])
nk_style_set_font(ctx, &font->handle);
}

#ifdef INCLUDE_STYLE
/* ease regression testing during Nuklear release process; not needed for anything else */
#ifdef STYLE_WHITE
set_style(ctx, THEME_WHITE);
#elif defined(STYLE_RED)
set_style(ctx, THEME_RED);
#elif defined(STYLE_BLUE)
set_style(ctx, THEME_BLUE);
#elif defined(STYLE_DARK)
set_style(ctx, THEME_DARK);
#endif
#endif

bg.r = 0.10f, bg.g = 0.18f, bg.b = 0.24f, bg.a = 1.0f;
while (running)
{
Expand Down
14 changes: 0 additions & 14 deletions demo/sfml_opengl2/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -96,20 +96,6 @@ int main(void)
/*nk_style_load_all_cursors(ctx, atlas->cursors);*/
/*nk_style_set_font(ctx, &droid->handle);*/

/* style.c */
#ifdef INCLUDE_STYLE
/* ease regression testing during Nuklear release process; not needed for anything else */
#ifdef STYLE_WHITE
set_style(ctx, THEME_WHITE);
#elif defined(STYLE_RED)
set_style(ctx, THEME_RED);
#elif defined(STYLE_BLUE)
set_style(ctx, THEME_BLUE);
#elif defined(STYLE_DARK)
set_style(ctx, THEME_DARK);
#endif
#endif

struct nk_colorf bg;
bg.r = 0.10f, bg.g = 0.18f, bg.b = 0.24f, bg.a = 1.0f;
while (win.isOpen())
Expand Down
14 changes: 0 additions & 14 deletions demo/sfml_opengl3/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -102,20 +102,6 @@ int main(void)
/*nk_style_load_all_cursors(ctx, atlas->cursors);*/
/*nk_style_set_font(ctx, &droid->handle);*/

/* style.c */
#ifdef INCLUDE_STYLE
/* ease regression testing during Nuklear release process; not needed for anything else */
#ifdef STYLE_WHITE
set_style(ctx, THEME_WHITE);
#elif defined(STYLE_RED)
set_style(ctx, THEME_RED);
#elif defined(STYLE_BLUE)
set_style(ctx, THEME_BLUE);
#elif defined(STYLE_DARK)
set_style(ctx, THEME_DARK);
#endif
#endif

struct nk_colorf bg;
bg.r = 0.10f, bg.g = 0.18f, bg.b = 0.24f, bg.a = 1.0f;
while (win.isOpen())
Expand Down
13 changes: 0 additions & 13 deletions demo/x11/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -152,19 +152,6 @@ main(void)
xw.font = nk_xfont_create(xw.dpy, "fixed");
ctx = nk_xlib_init(xw.font, xw.dpy, xw.screen, xw.win, xw.width, xw.height);

#ifdef INCLUDE_STYLE
/* ease regression testing during Nuklear release process; not needed for anything else */
#ifdef STYLE_WHITE
set_style(ctx, THEME_WHITE);
#elif defined(STYLE_RED)
set_style(ctx, THEME_RED);
#elif defined(STYLE_BLUE)
set_style(ctx, THEME_BLUE);
#elif defined(STYLE_DARK)
set_style(ctx, THEME_DARK);
#endif
#endif

while (running)
{
/* Input */
Expand Down
13 changes: 0 additions & 13 deletions demo/x11_opengl2/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -256,19 +256,6 @@ int main(void)
/*nk_style_load_all_cursors(ctx, atlas->cursors);*/
/*nk_style_set_font(ctx, &droid->handle);*/}

#ifdef INCLUDE_STYLE
/* ease regression testing during Nuklear release process; not needed for anything else */
#ifdef STYLE_WHITE
set_style(ctx, THEME_WHITE);
#elif defined(STYLE_RED)
set_style(ctx, THEME_RED);
#elif defined(STYLE_BLUE)
set_style(ctx, THEME_BLUE);
#elif defined(STYLE_DARK)
set_style(ctx, THEME_DARK);
#endif
#endif

bg.r = 0.10f, bg.g = 0.18f, bg.b = 0.24f, bg.a = 1.0f;
while (running)
{
Expand Down
Loading

0 comments on commit 4cfea49

Please sign in to comment.