Possible Duplicate:
How to change the Font Size in a whole Application programmatically, Android?
This is my Code : I have created Spinner with a list of FontSize options. If I click FontSize "26" then it should be able to change in that specific FontSize. Below I have an EditBox. So if I clicked Fontsize as 40 and in a Italic style than usual Bold. So I should be able to type inside EditBox with this selected "Font" : FontSize "40" and Italic style.
How could I do this programmatically in Android?
font=new Spinner(con);
option= new String[] {"Select Font Size","8","10","12","14","16","18","20",
"22","24","26","28","30","32","34","36","38","40","50"};
ArrayAdapter<String> adapter= new ArrayAdapter<String>(con,android.R.layout.simple_spinner_dropdown_item,option);
adapter.setDropDownViewResource(android.R.layout.simple_spinner_dropdown_item);
font.setOnItemSelectedListener(new OnItemSelectedListener() {
@Override
public void onItemSelected(AdapterView<?> arg0, View arg1,int position, long id) {
option[1]="8";
selectedItem= option[position];
}
@Override
public void onNothingSelected(AdapterView<?> arg0) {
}
});