├── .gitattributes ├── .gitignore ├── README.md └── TypeTextView ├── .classpath ├── .project ├── .settings └── org.eclipse.core.resources.prefs ├── AndroidManifest.xml ├── bin ├── AndroidManifest.xml ├── TypeTextView.apk ├── classes.dex ├── classes │ └── com │ │ └── uperone │ │ ├── typetext │ │ └── view │ │ │ ├── TypeTextView$1.class │ │ │ ├── TypeTextView$OnTypeViewListener.class │ │ │ ├── TypeTextView$TypeTimerTask$1.class │ │ │ ├── TypeTextView$TypeTimerTask.class │ │ │ └── TypeTextView.class │ │ └── typetextview │ │ ├── BaseActivity.class │ │ ├── BuildConfig.class │ │ ├── R$attr.class │ │ ├── R$drawable.class │ │ ├── R$id.class │ │ ├── R$layout.class │ │ ├── R$raw.class │ │ ├── R$string.class │ │ ├── R.class │ │ ├── TypeTextViewActivity$1.class │ │ └── TypeTextViewActivity.class ├── dexedLibs │ ├── android-support-v4-72f6caf5237504f63c425bd17b7894f6.jar │ └── annotations-e51552d4fbe0d7bd5d4bb1349e013f21.jar ├── res │ └── crunch │ │ ├── drawable-hdpi │ │ └── ic_launcher.png │ │ ├── drawable-mdpi │ │ └── ic_launcher.png │ │ ├── drawable-xhdpi │ │ └── ic_launcher.png │ │ └── drawable-xxhdpi │ │ └── ic_launcher.png └── resources.ap_ ├── gen └── com │ └── uperone │ └── typetextview │ ├── BuildConfig.java │ └── R.java ├── ic_launcher-web.png ├── libs └── android-support-v4.jar ├── proguard-project.txt ├── project.properties ├── res ├── drawable-hdpi │ └── ic_launcher.png ├── drawable-mdpi │ └── ic_launcher.png ├── drawable-xhdpi │ └── ic_launcher.png ├── drawable-xxhdpi │ └── ic_launcher.png ├── layout │ └── activity_type_text_view_layout.xml ├── raw │ └── type_in.wav └── values │ └── strings.xml └── src └── com └── uperone ├── typetext └── view │ └── TypeTextView.java └── typetextview ├── BaseActivity.java └── TypeTextViewActivity.java /.gitattributes: -------------------------------------------------------------------------------- 1 | # Auto detect text files and perform LF normalization 2 | * text=auto 3 | 4 | # Custom for Visual Studio 5 | *.cs diff=csharp 6 | 7 | # Standard to msysgit 8 | *.doc diff=astextplain 9 | *.DOC diff=astextplain 10 | *.docx diff=astextplain 11 | *.DOCX diff=astextplain 12 | *.dot diff=astextplain 13 | *.DOT diff=astextplain 14 | *.pdf diff=astextplain 15 | *.PDF diff=astextplain 16 | *.rtf diff=astextplain 17 | *.RTF diff=astextplain 18 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | # Windows image file caches 2 | Thumbs.db 3 | ehthumbs.db 4 | 5 | # Folder config file 6 | Desktop.ini 7 | 8 | # Recycle Bin used on file shares 9 | $RECYCLE.BIN/ 10 | 11 | # Windows Installer files 12 | *.cab 13 | *.msi 14 | *.msm 15 | *.msp 16 | 17 | # Windows shortcuts 18 | *.lnk 19 | 20 | # ========================= 21 | # Operating System Files 22 | # ========================= 23 | 24 | # OSX 25 | # ========================= 26 | 27 | .DS_Store 28 | .AppleDouble 29 | .LSOverride 30 | 31 | # Thumbnails 32 | ._* 33 | 34 | # Files that might appear on external disk 35 | .Spotlight-V100 36 | .Trashes 37 | 38 | # Directories potentially created on remote AFP share 39 | .AppleDB 40 | .AppleDesktop 41 | Network Trash Folder 42 | Temporary Items 43 | .apdisk 44 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | ## 说明 2 | 3 | **描述:**模仿打字机的效果,字一个一个地蹦出来,伴随打字机的声音。 4 | 5 | **效果:** 6 | 7 | ![TypeTextView](http://ww1.sinaimg.cn/large/6d17e381gw1eo0uvwrfo1g20hj0pwgpz.gif) 8 | 9 | ## 使用说明: 10 | 11 | 1. 在xml文件中定义: 12 | 13 | 18 | 19 | 2. 在代码中实例化: 20 | 21 | mTypeTextView = ( TypeTextView )findViewById(R.id.typeTxtId); 22 | mTypeTextView.setOnTypeViewListener( new OnTypeViewListener( ) { 23 | @Override 24 | public void onTypeStart() { 25 | print( "onTypeStart" ); 26 | } 27 | 28 | @Override 29 | public void onTypeOver() { 30 | print( "onTypeOver" ); 31 | } 32 | }); 33 | 34 | 3. 调用start方法: 35 | 36 | mTypeTextView.start( TEST_DATA ); 37 | 38 | ## 关于作者: 39 | 40 | **姓名:**张明云 41 | 42 | **博客:**[zmywly8866](http://zmywly8866.github.io/) 43 | 44 | **知乎:**[zmywly8866](http://www.zhihu.com/people/zhang-ming-yun-97) 45 | 46 | **简书:**[zmywly8866](http://www.jianshu.com/users/e6885381f7d4/latest_articles) -------------------------------------------------------------------------------- /TypeTextView/.classpath: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | -------------------------------------------------------------------------------- /TypeTextView/.project: -------------------------------------------------------------------------------- 1 | 2 | 3 | TypeTextView 4 | 5 | 6 | 7 | 8 | 9 | com.android.ide.eclipse.adt.ResourceManagerBuilder 10 | 11 | 12 | 13 | 14 | com.android.ide.eclipse.adt.PreCompilerBuilder 15 | 16 | 17 | 18 | 19 | org.eclipse.jdt.core.javabuilder 20 | 21 | 22 | 23 | 24 | com.android.ide.eclipse.adt.ApkBuilder 25 | 26 | 27 | 28 | 29 | 30 | com.android.ide.eclipse.adt.AndroidNature 31 | org.eclipse.jdt.core.javanature 32 | 33 | 34 | -------------------------------------------------------------------------------- /TypeTextView/.settings/org.eclipse.core.resources.prefs: -------------------------------------------------------------------------------- 1 | eclipse.preferences.version=1 2 | encoding/=UTF-8 3 | -------------------------------------------------------------------------------- /TypeTextView/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | 10 | 11 | 15 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | -------------------------------------------------------------------------------- /TypeTextView/bin/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | 10 | 11 | 15 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | -------------------------------------------------------------------------------- /TypeTextView/bin/TypeTextView.apk: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zmywly8866/TypeTextView/1333ca66d6e3fbff5527ea58d064da75ebee10f8/TypeTextView/bin/TypeTextView.apk -------------------------------------------------------------------------------- /TypeTextView/bin/classes.dex: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zmywly8866/TypeTextView/1333ca66d6e3fbff5527ea58d064da75ebee10f8/TypeTextView/bin/classes.dex -------------------------------------------------------------------------------- /TypeTextView/bin/classes/com/uperone/typetext/view/TypeTextView$1.class: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zmywly8866/TypeTextView/1333ca66d6e3fbff5527ea58d064da75ebee10f8/TypeTextView/bin/classes/com/uperone/typetext/view/TypeTextView$1.class -------------------------------------------------------------------------------- /TypeTextView/bin/classes/com/uperone/typetext/view/TypeTextView$OnTypeViewListener.class: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zmywly8866/TypeTextView/1333ca66d6e3fbff5527ea58d064da75ebee10f8/TypeTextView/bin/classes/com/uperone/typetext/view/TypeTextView$OnTypeViewListener.class -------------------------------------------------------------------------------- /TypeTextView/bin/classes/com/uperone/typetext/view/TypeTextView$TypeTimerTask$1.class: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zmywly8866/TypeTextView/1333ca66d6e3fbff5527ea58d064da75ebee10f8/TypeTextView/bin/classes/com/uperone/typetext/view/TypeTextView$TypeTimerTask$1.class -------------------------------------------------------------------------------- /TypeTextView/bin/classes/com/uperone/typetext/view/TypeTextView$TypeTimerTask.class: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zmywly8866/TypeTextView/1333ca66d6e3fbff5527ea58d064da75ebee10f8/TypeTextView/bin/classes/com/uperone/typetext/view/TypeTextView$TypeTimerTask.class -------------------------------------------------------------------------------- /TypeTextView/bin/classes/com/uperone/typetext/view/TypeTextView.class: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zmywly8866/TypeTextView/1333ca66d6e3fbff5527ea58d064da75ebee10f8/TypeTextView/bin/classes/com/uperone/typetext/view/TypeTextView.class -------------------------------------------------------------------------------- /TypeTextView/bin/classes/com/uperone/typetextview/BaseActivity.class: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zmywly8866/TypeTextView/1333ca66d6e3fbff5527ea58d064da75ebee10f8/TypeTextView/bin/classes/com/uperone/typetextview/BaseActivity.class -------------------------------------------------------------------------------- /TypeTextView/bin/classes/com/uperone/typetextview/BuildConfig.class: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zmywly8866/TypeTextView/1333ca66d6e3fbff5527ea58d064da75ebee10f8/TypeTextView/bin/classes/com/uperone/typetextview/BuildConfig.class -------------------------------------------------------------------------------- /TypeTextView/bin/classes/com/uperone/typetextview/R$attr.class: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zmywly8866/TypeTextView/1333ca66d6e3fbff5527ea58d064da75ebee10f8/TypeTextView/bin/classes/com/uperone/typetextview/R$attr.class -------------------------------------------------------------------------------- /TypeTextView/bin/classes/com/uperone/typetextview/R$drawable.class: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zmywly8866/TypeTextView/1333ca66d6e3fbff5527ea58d064da75ebee10f8/TypeTextView/bin/classes/com/uperone/typetextview/R$drawable.class -------------------------------------------------------------------------------- /TypeTextView/bin/classes/com/uperone/typetextview/R$id.class: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zmywly8866/TypeTextView/1333ca66d6e3fbff5527ea58d064da75ebee10f8/TypeTextView/bin/classes/com/uperone/typetextview/R$id.class -------------------------------------------------------------------------------- /TypeTextView/bin/classes/com/uperone/typetextview/R$layout.class: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zmywly8866/TypeTextView/1333ca66d6e3fbff5527ea58d064da75ebee10f8/TypeTextView/bin/classes/com/uperone/typetextview/R$layout.class -------------------------------------------------------------------------------- /TypeTextView/bin/classes/com/uperone/typetextview/R$raw.class: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zmywly8866/TypeTextView/1333ca66d6e3fbff5527ea58d064da75ebee10f8/TypeTextView/bin/classes/com/uperone/typetextview/R$raw.class -------------------------------------------------------------------------------- /TypeTextView/bin/classes/com/uperone/typetextview/R$string.class: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zmywly8866/TypeTextView/1333ca66d6e3fbff5527ea58d064da75ebee10f8/TypeTextView/bin/classes/com/uperone/typetextview/R$string.class -------------------------------------------------------------------------------- /TypeTextView/bin/classes/com/uperone/typetextview/R.class: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zmywly8866/TypeTextView/1333ca66d6e3fbff5527ea58d064da75ebee10f8/TypeTextView/bin/classes/com/uperone/typetextview/R.class -------------------------------------------------------------------------------- /TypeTextView/bin/classes/com/uperone/typetextview/TypeTextViewActivity$1.class: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zmywly8866/TypeTextView/1333ca66d6e3fbff5527ea58d064da75ebee10f8/TypeTextView/bin/classes/com/uperone/typetextview/TypeTextViewActivity$1.class -------------------------------------------------------------------------------- /TypeTextView/bin/classes/com/uperone/typetextview/TypeTextViewActivity.class: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zmywly8866/TypeTextView/1333ca66d6e3fbff5527ea58d064da75ebee10f8/TypeTextView/bin/classes/com/uperone/typetextview/TypeTextViewActivity.class -------------------------------------------------------------------------------- /TypeTextView/bin/dexedLibs/android-support-v4-72f6caf5237504f63c425bd17b7894f6.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zmywly8866/TypeTextView/1333ca66d6e3fbff5527ea58d064da75ebee10f8/TypeTextView/bin/dexedLibs/android-support-v4-72f6caf5237504f63c425bd17b7894f6.jar -------------------------------------------------------------------------------- /TypeTextView/bin/dexedLibs/annotations-e51552d4fbe0d7bd5d4bb1349e013f21.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zmywly8866/TypeTextView/1333ca66d6e3fbff5527ea58d064da75ebee10f8/TypeTextView/bin/dexedLibs/annotations-e51552d4fbe0d7bd5d4bb1349e013f21.jar -------------------------------------------------------------------------------- /TypeTextView/bin/res/crunch/drawable-hdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zmywly8866/TypeTextView/1333ca66d6e3fbff5527ea58d064da75ebee10f8/TypeTextView/bin/res/crunch/drawable-hdpi/ic_launcher.png -------------------------------------------------------------------------------- /TypeTextView/bin/res/crunch/drawable-mdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zmywly8866/TypeTextView/1333ca66d6e3fbff5527ea58d064da75ebee10f8/TypeTextView/bin/res/crunch/drawable-mdpi/ic_launcher.png -------------------------------------------------------------------------------- /TypeTextView/bin/res/crunch/drawable-xhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zmywly8866/TypeTextView/1333ca66d6e3fbff5527ea58d064da75ebee10f8/TypeTextView/bin/res/crunch/drawable-xhdpi/ic_launcher.png -------------------------------------------------------------------------------- /TypeTextView/bin/res/crunch/drawable-xxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zmywly8866/TypeTextView/1333ca66d6e3fbff5527ea58d064da75ebee10f8/TypeTextView/bin/res/crunch/drawable-xxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /TypeTextView/bin/resources.ap_: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zmywly8866/TypeTextView/1333ca66d6e3fbff5527ea58d064da75ebee10f8/TypeTextView/bin/resources.ap_ -------------------------------------------------------------------------------- /TypeTextView/gen/com/uperone/typetextview/BuildConfig.java: -------------------------------------------------------------------------------- 1 | /** Automatically generated file. DO NOT MODIFY */ 2 | package com.uperone.typetextview; 3 | 4 | public final class BuildConfig { 5 | public final static boolean DEBUG = true; 6 | } -------------------------------------------------------------------------------- /TypeTextView/gen/com/uperone/typetextview/R.java: -------------------------------------------------------------------------------- 1 | /* AUTO-GENERATED FILE. DO NOT MODIFY. 2 | * 3 | * This class was automatically generated by the 4 | * aapt tool from the resource data it found. It 5 | * should not be modified by hand. 6 | */ 7 | 8 | package com.uperone.typetextview; 9 | 10 | public final class R { 11 | public static final class attr { 12 | } 13 | public static final class drawable { 14 | public static final int ic_launcher=0x7f020000; 15 | } 16 | public static final class id { 17 | public static final int showBtnId=0x7f060001; 18 | public static final int typeTxtId=0x7f060000; 19 | } 20 | public static final class layout { 21 | public static final int activity_type_text_view_layout=0x7f030000; 22 | } 23 | public static final class raw { 24 | public static final int type_in=0x7f040000; 25 | } 26 | public static final class string { 27 | public static final int app_name=0x7f050000; 28 | public static final int hello_world=0x7f050001; 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /TypeTextView/ic_launcher-web.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zmywly8866/TypeTextView/1333ca66d6e3fbff5527ea58d064da75ebee10f8/TypeTextView/ic_launcher-web.png -------------------------------------------------------------------------------- /TypeTextView/libs/android-support-v4.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zmywly8866/TypeTextView/1333ca66d6e3fbff5527ea58d064da75ebee10f8/TypeTextView/libs/android-support-v4.jar -------------------------------------------------------------------------------- /TypeTextView/proguard-project.txt: -------------------------------------------------------------------------------- 1 | # To enable ProGuard in your project, edit project.properties 2 | # to define the proguard.config property as described in that file. 3 | # 4 | # Add project specific ProGuard rules here. 5 | # By default, the flags in this file are appended to flags specified 6 | # in ${sdk.dir}/tools/proguard/proguard-android.txt 7 | # You can edit the include path and order by changing the ProGuard 8 | # include property in project.properties. 9 | # 10 | # For more details, see 11 | # http://developer.android.com/guide/developing/tools/proguard.html 12 | 13 | # Add any project specific keep options here: 14 | 15 | # If your project uses WebView with JS, uncomment the following 16 | # and specify the fully qualified class name to the JavaScript interface 17 | # class: 18 | #-keepclassmembers class fqcn.of.javascript.interface.for.webview { 19 | # public *; 20 | #} 21 | -------------------------------------------------------------------------------- /TypeTextView/project.properties: -------------------------------------------------------------------------------- 1 | # This file is automatically generated by Android Tools. 2 | # Do not modify this file -- YOUR CHANGES WILL BE ERASED! 3 | # 4 | # This file must be checked in Version Control Systems. 5 | # 6 | # To customize properties used by the Ant build system edit 7 | # "ant.properties", and override values to adapt the script to your 8 | # project structure. 9 | # 10 | # To enable ProGuard to shrink and obfuscate your code, uncomment this (available properties: sdk.dir, user.home): 11 | #proguard.config=${sdk.dir}/tools/proguard/proguard-android.txt:proguard-project.txt 12 | 13 | # Project target. 14 | target=android-15 15 | -------------------------------------------------------------------------------- /TypeTextView/res/drawable-hdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zmywly8866/TypeTextView/1333ca66d6e3fbff5527ea58d064da75ebee10f8/TypeTextView/res/drawable-hdpi/ic_launcher.png -------------------------------------------------------------------------------- /TypeTextView/res/drawable-mdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zmywly8866/TypeTextView/1333ca66d6e3fbff5527ea58d064da75ebee10f8/TypeTextView/res/drawable-mdpi/ic_launcher.png -------------------------------------------------------------------------------- /TypeTextView/res/drawable-xhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zmywly8866/TypeTextView/1333ca66d6e3fbff5527ea58d064da75ebee10f8/TypeTextView/res/drawable-xhdpi/ic_launcher.png -------------------------------------------------------------------------------- /TypeTextView/res/drawable-xxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zmywly8866/TypeTextView/1333ca66d6e3fbff5527ea58d064da75ebee10f8/TypeTextView/res/drawable-xxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /TypeTextView/res/layout/activity_type_text_view_layout.xml: -------------------------------------------------------------------------------- 1 | 5 | 6 | 11 | 12 |