Skip to content
Myr

tweak textedit sample fix

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 · parent 885b1b7 · Browse files · 1 file+1 added−1 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+1 added−1 removed

  • tests:+1 added−1 removed

1 file+1 added−1 removed

modified:tests/textedit_sample.c+1 added-1 removed
30 unmodified lines
31}3233int delete_chars(STB_TEXTEDIT_STRING *str, int pos, int num)34{35 memmove(&str->string[pos], &str->string[pos+num], str->stringlen - pos - num);35 memmove(&str->string[pos], &str->string[pos+num], str->stringlen - (pos+num));36 str->stringlen -= num;37 return 1; // always succeeds38}39
44 unmodified lines