2017-2018-2 20165236 Experimental Report on the fundamentals of Android developmentFirst, the experimental report coverCourse : Java Programming Class : 1652 class name : Guo Jintao No. : 20165236 Instructor: Lou Jia Peng experiment Date : May 14, 2018Experiment Time : 15:35-17:15 Experiment number : fourExperiment name : Android Development BasicsIi. contents of
://github.com/sharish/ShimmerRecyclerViewAndroid-switchicon这是个自定义的switch控件。扩展自AppCompatImageView,允许使用vector和image。The effect is as follows:GitHub Address: Https://github.com/zagum/Android-SwitchIconCounterfab该库针对FloatingActionButton的扩展,可以显示角标。The effect is as follows:GitHub Address: Https://github.com/andremion/CounterFabFadingtextview该控件可以让TextView每隔一定时间通过淡入淡出动画效果切换文本The effect is as follows:GitHub Address: Https://github.com/rosenpin/FadingTextViewB
Android development dialog box advanced application, android development dialog box
Android development dialog box advanced application
It is easy to create and display a dialog box, b
Layout animation effectAdd a simple animation effect to a layout Public classMainactivityextendsappcompatactivity {@Overrideprotected voidonCreate (Bundle savedinstancestate) {Super. OnCreate (savedinstancestate); Setcontentview (Activity_main); //set an animation effectScaleanimation SA =NewScaleanimation (0,1,0,1, animation.relative_to_self,0.5f,animation.relative_to_self,0.5f); Sa.setduration (1000); //set up a layout animation controller, configure animation, and delay (latency)//A de
Android custom AlertDialog dialog box (loading prompt box) and Android alertdialog
AlertDialog has the following six usage methods:
1. Simple AlertDialog (only a simple piece of information is displayed)
Ii. AlertDialog with buttons (display prompt information for user operation)
Iii. AlertDialog (display content) simi
Android login interface implementation-supports clear input box and vibration effect, android input boxDemo Effect
The main code is as follows:
A custom EditText, used to display clear buttons when there is text:
Import android. content. context; import android. graphics. dr
Android advanced component ----- automatically edit text box, Android ----- text box
The AutoCompleteTextView is inherited from EditText and can be input and edited by users. However, it has its own feature: after a certain number of characters are entered, a drop-down list prompt is displayed for users to choose from,
Custom title of the Android dialog box and the title of the android dialog box
The title of the dialog box that comes with Android is not easy to understand. If you need to set a custom title for the pop-up dialog
Android official recommendation: DialogFragment dialog box, android creation dialog box
Reprinted please indicate the source: http://blog.csdn.net/lmj623565791/article/details/378154131. Overview DialogFragment was introduced when android 3.0 was launched. Is a Special Fragm
How does android make the pop-up dialog box disappear? android dialog box
Builder builder = new AlertDialog. Builder (this );Builder. setTitle (android. R. string. dialog_alert_title). SetIcon (android. R. drawable. ic_dialog_info
// XML
// In anroidmainifest
Android: theme = "@ style/demo"
// JavaCodeIn
// Click a place other than the input box to hide the input method addfoodweight. setonfocuschangelistener (New onfocuschangelistener () {@ overridepublic void onfocuschange (view V, Boolean hasfocus) {// todo auto-generated method stubif (! Hasfocus) {system. out. println ("lost focus"); // lost focus addfoodweight. clearfoc
We all know that EditText and TextView are Android text input boxes and text display boxes, but based on the size of the phone screen, if you need to enter more text or display more content, the phone screen is far from enough, So the text box has a scroll bar function is necessary on the phone, to add a scroll bar, in fact, is very simple, just want to be in the text input
Notes on text in the android get dialog box. The android get dialog box
1. Set View to final type, for example, final View layout =...
2. Format EditText e = (EditText) layout. findViewById (R. id) when obtaining the text box object. // remember that layout is the final View
Android Common Dialog Box and android dialog box1. Dialog Box Notification)
You can use a dialog box to display a progress bar or confirm the information of your application.
The following code opens a dialog box:
Public void clic
Android-click the button in the dialog box to not close the dialog box. android button
Sometimes I do not need to click the button for some detection, but do not want to close the dialog box (the system click any button by default to close the dialog
Single box and multi box is usually used in setting up user profile, choose gender, hobbies, etc., do not need the user directly input, choose directly in the alternative options, simple and convenient.Look directly at the code:XML version= "1.0" encoding= "Utf-8"?>Tablelayoutxmlns:android= "Http://schemas.android.com/apk/res/android"android:orientation= "vertica
Android implements the search function by entering a certain number of words in the text box. android text box
(1) Implement the text box automatic search function:
Et_phone is an editText input box control.
Et_phone.addTextCh
Android drop-down box, and android drop-down box
What is a spinner? A drop-down menu is actually a pop-up window, but it can be further operated. Click the triangle symbol to bring up a window, usually a list, and then perform operations.
Its definition in the xml file is no different from that in other controls,
1
H
Android is similar to the implementation of QQ account login drop-down box (with source code), android drop-down box
Some source code
// Set downArroImageView for popupWindow. setOnClickListener (new OnClickListener () {@ Override public void onClick (View arg0) {// defines popupWindow = new PopupWindow (MainAct
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.