Skip to content

docs(layouting): fix code blocks#916

Open
TomJGooding wants to merge 1 commit intoImmediate-Mode-UI:masterfrom
TomJGooding:docs-layouting-fix-code-blocks
Open

docs(layouting): fix code blocks#916
TomJGooding wants to merge 1 commit intoImmediate-Mode-UI:masterfrom
TomJGooding:docs-layouting-fix-code-blocks

Conversation

@TomJGooding
Copy link

While browsing the documentation I noticed that the code blocks are currently broken on the Layouting page.

I confess I'm not familiar with Doxygen, but simply removing a space from the indentation seems to fix the issue!

Fixes #915

While browsing the documentation I noticed that the code blocks are
currently broken on the Layouting page.

I confess I'm not familiar with Doxygen, but simply removing a space
from the indentation seems to fix the issue!

Fixes Immediate-Mode-UI#915
@TomJGooding
Copy link
Author

Screenshot for comparison:

image

Copy link
Contributor

@sleeptightAnsiC sleeptightAnsiC left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks! Tested locally and it does work.

I've taken a quick look into all code blocks and found one that lacks proper syntax highlight:

Nuklear/src/nuklear.h

Lines 5623 to 5637 in 987c8b8

* back from the stack:
*
* nk_style_push_style_item(ctx, &ctx->style.button.normal, nk_style_item_color(nk_rgb(255,0,0)));
* nk_style_push_style_item(ctx, &ctx->style.button.hover, nk_style_item_color(nk_rgb(255,0,0)));
* nk_style_push_style_item(ctx, &ctx->style.button.active, nk_style_item_color(nk_rgb(255,0,0)));
* nk_style_push_vec2(ctx, &cx->style.button.padding, nk_vec2(2,2));
*
* nk_button(...);
*
* nk_style_pop_style_item(ctx);
* nk_style_pop_style_item(ctx);
* nk_style_pop_style_item(ctx);
* nk_style_pop_vec2(ctx);
*
* Nuklear has a stack for style_items, float properties, vector properties,

^ no need to do anything, but if you're already interested in contributing to docs, you can probably submit another PR for this one too (or even fix it here, it wouldn't be a big deal).

EDIT: tried to fix it myself, but coloring does not seem to change no matter what I do. I'm not super familiar with doxygen neither.

@TomJGooding
Copy link
Author

Thanks for the review. I think the problem in the Stack docs should really be a separate PR - this fixes a borked code block rather than just missing syntax highlighting.

Copy link
Contributor

@RobLoach RobLoach left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks. Would like to touch up all the doxygen docs for sure. Make them consistent, and maybe even tweak the config itself.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Code blocks broken in Layouting docs

3 participants