homeworkText = (EditText) getActivity().findViewById(R.id.homeworkText);
homeworkText.setFilters(new InputFilter[]{new InputFilter.LengthFilter(300)});
In this code I wanna limited count of input chars. But when I paste to field text over limit (for example, in field has 200 chars and I paste text with 150 chars) app just finish without errors in run-console
How make safe limit to inputed chars?