Compare commits
2 Commits
1afd4100b4
...
453d9dad7f
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
453d9dad7f | ||
|
|
757c817855 |
@ -87,7 +87,7 @@ glm::vec2 gui::Context::MeasureText(std::string_view text)
|
|||||||
|
|
||||||
glm::vec2 cursor(0.0f);
|
glm::vec2 cursor(0.0f);
|
||||||
|
|
||||||
while (cp = DecodeUTF8Codepoint(p, end))
|
while ((cp = DecodeUTF8Codepoint(p, end)))
|
||||||
{
|
{
|
||||||
if (cp == ' ')
|
if (cp == ' ')
|
||||||
{
|
{
|
||||||
@ -146,9 +146,12 @@ void gui::Context::DrawText(std::string_view text, const glm::vec2& pos, uint32_
|
|||||||
|
|
||||||
glm::vec2 cursor = pos;
|
glm::vec2 cursor = pos;
|
||||||
|
|
||||||
|
if (scale == 1.0f)
|
||||||
|
cursor = glm::floor(cursor);
|
||||||
|
|
||||||
uint32_t curr_color = color;
|
uint32_t curr_color = color;
|
||||||
|
|
||||||
while (cp = DecodeUTF8Codepoint(p, end))
|
while ((cp = DecodeUTF8Codepoint(p, end)))
|
||||||
{
|
{
|
||||||
if (cp == ' ')
|
if (cp == ' ')
|
||||||
{
|
{
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user