android: limit 10 znaków na linię TextView
Czytam wartość z EditText i zapisuję ją w TextView
editTitle1.addTextChangedListener(new TextWatcher() {
public void afterTextChanged(Editable s) {
}
public void beforeTextChanged(CharSequence s, int start, int count, int after) {
}
public void onTextChanged(CharSequence s, int start, int before, int count) {
s = editTitle1.getText().toString();
textTitle1.setText(s);
}
});
I chcę to w jednej linii - maksymalnie 10 znaków, więc jeśli wszystkie 20 znaków - to dwie linie w TextView z 10 znakami w linii. Jak mogę to zrobić? Próbuję android: maxLength = "10", ale to nie pomaga