Book Image

Android Studio 4.1 Development Essentials – Kotlin Edition

By : Neil Smyth
Book Image

Android Studio 4.1 Development Essentials – Kotlin Edition

By: Neil Smyth

Overview of this book

Android 11 has a ton of new capabilities. It comes up with three foci: a people-centric approach to communication, controls to let users quickly access and manage all of their smart devices, and privacy to give users more ways to control how data on devices is shared. This book starts off with the steps necessary to set up an Android development and testing environment, followed by an introduction to programming in Kotlin. An overview of Android Studio and its architecture is provided, followed by an in-depth look at the design of Android applications and user interfaces using the Android Studio environment. You will also learn about the Android architecture components along with some advanced topics such as touch screen handling, gesture recognition, the recording and playback of audio, app links, dynamic delivery, the AndroidStudio profiler, Gradle build configuration, and submitting apps to the Google Play Developer Console. The concepts of material design are also covered in detail. This edition of the book also covers printing, transitions, and cloud-based file storage; foldable device support is the cherry on the cake. By the end of this course, you will be able to develop Android 11 Apps using Android Studio 4.1, Kotlin, and Android Jetpack. The code files for the book can be found here: https://www.ebookfrenzy.com/retail/as41kotlin/index.php
Table of Contents (95 chapters)
95
Index

26.17 Widget Group Alignment and Distribution

The Android Studio Layout Editor tool provides a range of alignment and distribution actions that can be performed when two or more widgets are selected in the layout. Simply shift-click on each of the widgets to be included in the action, right-click on the layout and make a selection from the many options displayed in the Align menu:

Figure 26-41

As shown in Figure 26-42 below, these options are also available as buttons in the Layout Editor toolbar:

Figure 26-42

Similarly, the Pack menu (Figure 26-43) can be used to collectively reposition the selected widgets so that they are packed tightly together either vertically or horizontally. It achieves this by changing the absolute x and y coordinates of the widgets but does not apply any constraints. The two distribution options in the Pack menu, on the other hand, move the selected widgets so that they are spaced evenly apart in either vertical or horizontal axis and...