Skip to content

MadLadSquad/UntitledImGuiTextUtils

Repository files navigation

UntitledImGuiTextUtils

MIT license trello Discord

A bunch of small utility functions to make marking down text in ImGui easier. We have the following rendering features:

  • Bold
  • Italic
  • Bold Italic
  • Monospace
  • Small
  • Link
  • Underline
  • Strikethrough
  • Blockquote
  • Code blocks
  • Inline code
  • Subscript
  • Superscript
  • Highlighted text
  • Ruby text

Learning

All information can be found on the wiki.

Showcase

Easy typeface rendering

Rendering Normal, Bold, Italic, BoldItalic and Monospace text all in 5 lines of code:

image

Underline, strikethrough, links and text highlighting

Rendering Underline, Strikethrough, Link and highlighted text with and without word wrapping, all with configurable colours:

image

Blockquotes

Blockquotes, with an additional function to render only the rectangle to enable for nesting:

image

Code blocks

Code blocks with monospaced text and custom background:

image

Inline code

Inline code with monospaced text and custom background:

image

Ruby annotations

Ruby annotations for use with logographic writing systems like Hanzi(Only Kanji is ruby text in this example):

image

Subscripts and superscripts

Subscript and superscript text rendered in 1 function call, both starting from the same X position:

image