citro2d
citro2d copied to clipboard
multicolor text support
adds support for drawing multicolor text in one call to C2D_DrawText using a new flag C2D_MultiColor
a u32 array must also be passed to C2D_DrawText formatted like: {start_idx0, color0, start_idx1, color1, ...} where the start_idx is the index of the character where the corresponding color starts in the string. This is kind of similar to the coloredtext format in the text drawing calls Love2D.
a u32 with the length of that array must be passed as well.
Good work, although indentation is a bit screwed up. This project uses hard tabs, not spaces.
I must've messed it up with autoformatting, oops, thanks tho!
Can you fix the formatting, please?
done! (assuming the only issue was the spaces instead of tabs) sorry, i got busy w/ other stuff
i think those should be fixed now, anything else?
Looks fine to me now, but I think cur-> charNo > colors[0] should be cur->charNo >= colors[0].
No space between the dereference and the field name (style problem), and imagining you start the range at character index 1, having greater than instead of greater or equal would make the if only be true at index 2 or more (logic problem).
fixed
Hey! Any news about the pr?