Android Programming The Big Nerd Ranch Guide by Bill Phillips, Chris Stewart, Kristin Marsicano (z-lib.org)
Binding List Items Listing 8.21 Pulling out views in the constructor (CrimeListFragment.java) private class CrimeHolder extends ...
Chapter 8 Displaying Lists with RecyclerView Run CriminalIntent one more time, and every visible CrimeHolder should now display ...
For the More Curious: ListView and GridView Listing 8.24 Detecting presses in CrimeHolder (CrimeListFragment.java) private clas ...
Chapter 8 Displaying Lists with RecyclerView Singletons are often used in Android because they outlive a single fragment or act ...
9. Creating User Interfaces with Layouts and Widgets In this chapter, you will learn more about layouts and widgets while adding ...
Chapter 9 Creating User Interfaces with Layouts and Widgets Using the Graphical Layout Tool So far, you have created layouts by ...
Introducing ConstraintLayout Introducing ConstraintLayout With ConstraintLayout, instead of using nested layouts you add a serie ...
Chapter 9 Creating User Interfaces with Layouts and Widgets Using ConstraintLayout Now, convert list_item_crime.xml to use a Co ...
Using ConstraintLayout Finally, you will be asked to add the constraint layout dependency to your project (Figure 9.7). Constrai ...
Chapter 9 Creating User Interfaces with Layouts and Widgets The graphical editor Look to the toolbar near the top of the previe ...
The graphical editor Select the ConstraintLayout view in the component tree, then choose the Clear All Constraints option from F ...
Chapter 9 Creating User Interfaces with Layouts and Widgets Making room You need to make some room. Your two TextViews are taki ...
Making room Table 9.1 View size setting types Setting type Setting value Usage fixed Xdp Specifies an explicit size (that will ...
Chapter 9 Creating User Interfaces with Layouts and Widgets Repeat the process with the crime_date widget to set its width and ...
Adding widgets In the pop-up, choose ic_solved as the resource for the ImageView (Figure 9.15). This image will be used to indic ...
Chapter 9 Creating User Interfaces with Layouts and Widgets You want the ImageView to be anchored in the right side of the view ...
Adding widgets Do the same for the bottom constraint handle, dragging it from the ImageView to the bottom of the root view, also ...
Chapter 9 Creating User Interfaces with Layouts and Widgets ConstraintLayout’s inner workings Any edits that you make with the ...
Editing properties Editing properties Your ImageView is now positioned correctly. Next up: Position and size the title TextView. ...
Chapter 9 Creating User Interfaces with Layouts and Widgets Now that the constraints are set up, you can restore the title Text ...
«
6
7
8
9
10
11
12
13
14
15
»
Free download pdf