rezaali / ofxUI

[DEPRECATED] UI Addon for openFrameworks
http://www.syedrezaali.com/#/ofxui-project-showcase/
518 stars 202 forks source link

ofxUITextInput triggers std::out_of_range: basic_string::insert #213

Closed pusnik closed 10 years ago

pusnik commented 10 years ago

When setting empty string on ofxUITextInput: setTextString(""); (auto clear disabled) followed by clicking on the same ofxUITextInput and entering new text triggers std::out_of_range: basic_string::insert. The problem is that cursorPosition doesn't get reseted to 0.

Setting cursorPositon = 0 in void ofxUITextInput::setTextString(string s) resolves that issue.

pusnik commented 10 years ago

My bad. I saw that the issue is already noted- issue #191 Closing it!