대학 생활/Android

[Android]setText()에 개행(엔터), 태그 넣기

opid 2014. 6. 10. 08:18

자바코드(activity)에서 setText()로 값 변경시 태그넣기

TextView t1 = (TextView)findViewById(R.id.t1);
t1.setText(Html.fromHtml("1번째줄" + "<br />" + "2번째줄"));