issue with color and font scheme with the text of option men

News, information, contests and special event announcements from members of the anddev.org community.

issue with color and font scheme with the text of option men

Postby Muqeem » Tue Feb 02, 2010 6:54 am

Hi All,


I am facing issue with color and font scheme with the text of option menus. I am creating options from xml file using MenuInflater. Its not showing text of menus with the defined color. If the way which I am doing is not applicable, plz tell me alternate.

Below is the code:
Activity Class:

public class Settings extends Activity{

@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
Log.i("Settings ", "Settings............");
TextView view = new TextView(this);
view.append("Menu demo");
setContentView(view);
Log.i("Settings ", "Settings11111111111............");
}

@Override
public boolean onCreateOptionsMenu(Menu menu) {
MenuInflater inflator = getMenuInflater();
inflator.inflate(R.layout.menus, menu);
return true;
}
}



XML File:

<?xml version="1.0" encoding="UTF-8"?>
<menu xmlns:android="http://schemas.android.com/apk/res/android">
<item android:id="@+id/new_game"
android:title="New Game"
android:textColor="#ff0000"/>
<item android:id="@+id/quit"
android:title="Quit"
android:textColor="#0000FF"/>
</menu>


Plz help on this.


Thanks in advance!

Regards,
Muqeem
Muqeem
Once Poster
Once Poster
 
Posts: 1
Joined: Mon Feb 01, 2010 12:27 pm

Top

Return to Open News

Who is online

Users browsing this forum: No registered users and 3 guests