Guest User

Untitled

a guest
Jul 19th, 2018
79
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.05 KB | None | 0 0
  1. <?xml version="1.0" encoding="utf-8"?>
  2.  
  3. <application
  4. android:allowBackup="true"
  5. android:icon="@mipmap/ic_launcher"
  6.  
  7. **android:label="@string/app_name"**
  8.  
  9. android:roundIcon="@mipmap/ic_launcher_round"
  10. android:supportsRtl="true"
  11. android:theme="@style/AppTheme">
  12. <activity android:name=".MainActivity">
  13. <intent-filter>
  14. <action android:name="android.intent.action.MAIN" />
  15.  
  16. <category android:name="android.intent.category.LAUNCHER" />
  17. </intent-filter>
  18. </activity>
  19. </application>
  20.  
  21. ActionBar actionbar = getActionBar();
  22. TextView textview = new TextView(getApplicationContext());
  23.  
  24. LayoutParams lps = new RelativeLayout.LayoutParams(LayoutParams.MATCH_PARENT,
  25. LayoutParams.WRAP_CONTENT);
  26.  
  27. textview.setLayoutParams(lps);
  28.  
  29. textview.setText("CAIN");
  30.  
  31. textview.setTextColor(Color.WHITE);
  32. textview.setGravity(Gravity.CENTER);
  33. textview.setTextSize(22);
  34. actionbar.setDisplayOptions(ActionBar.DISPLAY_SHOW_CUSTOM);
  35. actionbar.setCustomView(textview);
Add Comment
Please, Sign In to add comment