I have made my button transparent so I would like to have the button text color change when the button is pressed. Is it possible to do this using just xml files?
You have to do it in your code. Try this:
mBtn = ((Button) findViewById( R.id.button1 )); mBtn.setOnClickListener( new OnClickListener() { @Override public void onClick(View v) { mBtn.setTextColor( Color.RED ); } });
Declare:
private Button mBtn;