안드로이드 개발 질문/답변
(글 수 45,052)
안녕하세요.
아래와 같이 TextSwitcher 의 색상을 변경하려고 하면,,, TextSwitcher 가 안 나옵니다.
t.setTextColor 를 빼면 정상적으로 TextSwitcher 값이 나옵니다.
원인을 모르겠어요.. 도움 부탁드립니다.
public class CurrentView extends View implements ViewSwitcher.ViewFactory {
Context c;
public CurrentView(Context context) {
super(context);
// TODO Auto-generated constructor stub
c = context;
}
public View makeView() {
TextView t = new TextView(c);
t.setGravity(Gravity.CENTER | Gravity.CENTER_HORIZONTAL);
t.setTextSize(66);
// t.setTextColor(0x11792e); // 이거 넣으면 TextSwitcher 가 안 나온다.
return t;
}
}