Skip to content
Myr

Merge branch 'working'

Before adoption: this commit came in with the history the project adopted, so no landing records it.

authored by Sean Barrett · committed by Sean Barrett · parents f4d348d, 094e8e9 · Browse files · 1 file+2 added−3 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

1 file+2 added−3 removed

  • other:+2 added−3 removed

1 file+2 added−3 removed

modified:stb_textedit.h+2 added-3 removed
415 unmodified lines
416417 // check if it's before the end of the line418 if (x < r.x1) {419 // search characters in row for one that straddles 'x'420 k = i;420 prev_x = r.x0;422 for (i=0; i < r.num_chars; ++i) {423 float w = STB_TEXTEDIT_GETWIDTH(str, k, i);421 for (k=0; k < r.num_chars; ++k) {422 float w = STB_TEXTEDIT_GETWIDTH(str, i, k);423 if (x < prev_x+w) {424 if (x < prev_x+w/2)425 return k+i;426 else
877 unmodified lines