Many apps have a button where you can get more information or help on the program. You may want to display credits about all the people who helped with the program, open source packages you used, or other legal information. For this example, we want to display a couple of paragraphs about how to play the game when the user presses the About button. The following screenshot shows what it will look like:
To implement this, we need to add a few lines to the fragment’s onCreateView() method. Before returning the rootView, add this code:
// Handle buttons ...