Skip to content

NathanGuilhot/Raylib_DrawTextStyle

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

DrawTextStyle( )

a stylish markdown-like DrawText function for Raylib!

Example

Usage

You can use basic markdown syntax to style your text :

*italic*
**Bold**
~wave animation~
~~crossed~~
__underline__

Of course, you can easily combine these effects with each other; maybe even all at once!

DrawTextStyle("~Hellooo~ :D", 100,100, DARKGRAY)

You can also use this function to specify the line spacing to use in your multi-line text (something you can't do by default in Raylib)

I really recommend tweaking this function to your liking! I hope I wrote something clear enough. Have fun!

How to setup

  • You need to load your font, with variations (normal, italic, bold, bold+italic)
  • Create a timer variable to animate the waaave (and add the delta-time each frame)
  • Include the header file
  • Customize the DrawTextStyle() wrapper to use your favorite settings
  • You're good to go!

Thank Raysan for making such a lovely framework <3

About

An alternative DrawText function with basic markdown and custom line spacing

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published