The behavior is definitely inconsistent, but neither is really wrong.
Whether a widget should send out a signal when it is programmatically changed is debatable. On one hand, having setText send the TextChanged signal allows you to manually set a value which would be processed in the same way as what the user would have typed. On the other hand, if your TextChanged callback checks whether the text is valid or not and calls setText again when invalid, you probably wouldn't want that to trigger another callback.
I've discussed this topic with people in the past with CheckBox and in the end I removed the callback from the setChecked function. So it is possible that if I start looking into this, I would remove the callback from EditBox::setText instead of adding a callback in TextBox::setText.
Whether a widget should send out a signal when it is programmatically changed is debatable. On one hand, having setText send the TextChanged signal allows you to manually set a value which would be processed in the same way as what the user would have typed. On the other hand, if your TextChanged callback checks whether the text is valid or not and calls setText again when invalid, you probably wouldn't want that to trigger another callback.
I've discussed this topic with people in the past with CheckBox and in the end I removed the callback from the setChecked function. So it is possible that if I start looking into this, I would remove the callback from EditBox::setText instead of adding a callback in TextBox::setText.