I've been working on an App since I'm practically finishing it, but I want to remove that part of the project name
There are several ways to do it, but one of them would be to call setDisplayShowTitleEnabled within the onCreate method your activity after calling setContentView (...) .
If your Activity is downloaded from AppCompatActivity :
getSupportActionBar().setDisplayShowTitleEnabled(false);
Or if you're coming down from Activity :
getActionBar().setDisplayShowTitleEnabled(false);
If it is only the Text you can set an Empty String to the Toolbar. Assuming you have the Toolbar defined in your ActivityMain.
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_mi_perfil);
Toolbar toolbar = (Toolbar) findViewById(R.id.toolbar);
toolbar.setTitle("");
}
I could use this in your activity:
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
getWindow().setFlags(WindowManager.LayoutParams.FLAG_FULLSCREEN, WindowManager.LayoutParams.FLAG_FULLSCREEN);
requestWindowFeature(Window.FEATURE_NO_TITLE);
setContentView(R.layout.activity);
}
WindowManager.LayoutParams.FLAG_FULLSCREEN This statement will make the layout occupy all your screen, that is, the notification bar will hide, if you only want to delete the title, do not place this sentence.
requestWindowFeature (Window.FEATURE_NO_TITLE) , This statement is the one that will hide the title of your activity.