반응형 텍스트뷰5 깜빡이기 Button btnNotice = (Button)findViewById(R.id.btn_notice); Animation mAnimation = new AlphaAnimation(1, 0); mAnimation.setDuration(1000); mAnimation.setInterpolator(new LinearInterpolator()); mAnimation.setRepeatCount(Animation.INFINITE); mAnimation.setRepeatMode(Animation.REVERSE); //애니메이션 시작 btnNotice.startAnimation(mAnimation); btnNotice.setOnClickListener(new OnClickListener() { @Override pub.. 2019. 3. 19. textview 현재 글자색 가져오기 textview.getCurrentTextColor() 2019. 3. 19. 버튼id값으로 텍스트색바꾸기 @Override public void onClick(View v) { // TODO Auto-generated method stub switch(v.getId()) { case R.id.btn_red : txt.setTextColor(Color.RED); break; case R.id.btn_blue : txt.setTextColor(Color.BLUE); break; case R.id.btn_green : txt.setTextColor(Color.GREEN); break; } } 2019. 3. 13. 글자색값으로 조건걸기 if (textview.getTextColors().getDefaultColor() == Color.rgb( ) ) 2019. 3. 13. 이전 1 2 다음 반응형