ANDRIOD Application Development Knowledge Collection 2

Source: Internet
Author: User

1, commonly used five kinds of layout:

LinearLayout, Relativelayout, Framelayout, Absolutelayout, Tablelayout

Linear layout relative layout frame layout absolute layout table layout

the main use of linear layout and relative layout in development.
Table layouts for computer layouts and more!
Frame layout is mainly used for page loading, neon, etc.
Absolute layout doesn't work.

2. Set the Gravity property of the control in TextView--means: The control's text is relative to the position of the control (text content is arranged)

For example: Set TextView gravity= "right"--means: TextView text is displayed relative to the TextView

3. Common UI components:

#TextView及其子类:TextView, EditText, Button,

Single button RadioButton, check box checkbox,

Status Switch Button ToggleButton, switching switch,

Clock analogclock,digitalclock,

Timer chronometer

#ImageView及其子类

#AdapterView及其子类: List View ListView, listactivity,

Adapter interface and implementation class,

Auto-complete text box Autocompletetextview,

Grid view GridView,

Expandable List Component Expandablelistview,

Spinner,

Gallery View Gallery,

Adapterviewflipper,

StackView

#ProgressBar及其子类: progress bar ProgressBar, drag bar SeekBar,

Star rating Bar Ratingbar

#ViewAnimator及其子类:viewswitcher, image switcher Imageswitcher,

Text switcher Textswitcher,

Viewflipper

#杂项组件:Toast displays a prompt message box,

Calendar view Component CalendarView,

Date, time selector DatePicker, timepicker,

Value selector Numberpicker,

Search box Searchview,

tab Tabhost,

Scrolling view ScrollView,

Notification

#对话框: Creating a dialog box with Alertdialog

Dialog-style window

Using Popupwindow

Using Datepickerdialog, Timepickerdialog

To create a progress dialog box using ProgressDialog

#菜单: Options Menu and Submenu submenu

Using listeners to listen for menu events

Create a check menu item and a single-selection menu item

Set activity associated with a menu item

Context Menu

defining menus using XML files

Create a pop-up menu using PopupMenu

#使用活动条 (ActionBar): Enable ActionBar

Using Actionbar to display the Options menu

Enable program icon Navigation

Add Action View

Using Actionbar to implement tab navigation

Using Actionbar for navigation

ANDRIOD Application Development Knowledge Collection 2

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.