I\'m quite new to Android Development and just came across Preferences.
I found PreferenceScreen and wanted to create a login functionality with it. The only pr         
        
For the xml:
Then for the java in your onCreate()
Preference button = findPreference(getString(R.string.myCoolButton));
button.setOnPreferenceClickListener(new Preference.OnPreferenceClickListener() {
    @Override
    public boolean onPreferenceClick(Preference preference) { 
        //code for what you want it to do 
        return true;
    }
});
This will appear like a normal Preference, with just a title and a summary, so it will look like it belongs.