AutoTypingTextView


Source link: https://github.com/krsticdragan/AutoTypingTextView

AutoTypeTextView

AutoTypeTextView is simple android library which is extending TextView with several auto typing animations. It simulate typing, encrypting a text and decrypting a text animation. You can define a speed of every animation and in the case of typing with mistakes, you can define a precision.

There are 4 type of animations:

  • Auto typing with mistakes
  • Auto typing without mistakes
  • Encrypit animation
  • Decrypt animation

Installation

Installation of AutoTypeTextView is preety simple. Just add in build.gradle

compile 'com.krsticdragan:autotypetextview:1.1' 

Usage

XML

Add a new namespace which you will use for adding AutoTypeTextView and using its tags.

xmlns:attv="http://schemas.android.com/apk/res-auto" 

So your root layout will look something like this.

<?xml version="1.0" encoding="utf-8"?> <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
  xmlns:tools="http://schemas.android.com/tools"
  xmlns:attv="http://schemas.android.com/apk/res-auto" 

After that you will need to define AutoTypeTextView by adding it in your XML. Now you can use a namespace which are we already defined.

<com.dragankrstic.autotypetextview.AutoTypeTextView

android:id="@+id/lblTextWithoutMistakes"

android:layout_width="wrap_content"

android:layout_height="wrap_content"

attv:animateTextTypeWithoutMistakes="Hello World!" /> 

Animations

Defining animation speed

Typing speed, Encryption speed and Decryption speed can be defined in XML by using:

attv:encryptionSpeed = 50 attv:decryptionSpeed = 50 attv:typingSpeed = 80 

or programmatically by defining a speed in ms.

lblTextWithoutMistakes.setTypingSpeed(100);
 lblTextDecryption.setDecryptionSpeed(30);
 lblTextEncryption.setEncryptionSpeed(30);
 

When you are using TypingWithMistakes, you need to setup precision in order to define how many mistakes you will animate.

attv:typingPrecision=8 

AutoTypingWithoutMistakes

Setup Auto Typing Animation without mistakes in XML by using:

attv:typingSpeed="100" attv:animateTextTypeWithoutMistakes="Hello World!" 

or programmatically by using a function

lblTextWithoutMistakes.setTypingSpeed(100);
 lblTyping.setTextAutoTyping("Hello World!");
 

AutoTypingWithMistake

Setup Auto Typing animation in XML by defining:

attv:animateTextTypeWithMistakes="Hello World!" attv:typingPrecision=8 

Precision can be set programatically by defining it using AutoTypeTextView.PRECISSION_LOW, AutoTypeTextView.PRECISSION_MED, AutoTypeTextView.PRECISSION_HIGH.

lblTextWithMistakes.setTextAutoTypingWithMistakes("Hello World! This is AutoTypeTextView.", AutoTypeTextView.PRECISSION_MED);
 

animateEncryption

Setup Encryption animation in XML by defining:

attv:animateEncryption="Hello World!" attv:encryptionSpeed="20" 

or programmatically

lblTextEncryption.setEncryptionSpeed(20);
 lblTextEncryption.animateEncryption("Hello World!");
 

animateDecryption

Setup Decryption animation:

attv:decryptionSpeed="50" attv:animateDecryption="Hello World!"  

or programmatically

lblTextDecryption.setDecryptionSpeed(50);
 lblTextDecryption.animateDecryption("Hello World! This is AutoTypeTextView");
 

Resources

ViewPager with tabs without the usage of fragments (simpler lifecycle).

ZoomLayout is a well documented, high-level View container that supports zooming and panning of View hierarchies and more.

  • ZoomLayout, to zoom and pan view hierarchies
  • ZoomImageView, a pinch-and-scale image container
  • Access to the inner ZoomEngine if interested

Supports animated transitions and an automatic center inside scaleType.

Library that allows you to scale, rotate, crop, alter aspect ratios, change brightness and contrast.

CacheManage for Android.

Beautiful Fancy Button on endorphins.

Icons, Borders, Radius for Android buttons with selectable 16 Icon Fonts precompiled! No need to manually using &#xf087; for icon font character anymore!

An Android Library that help you to customize views (Button, EditText, ImageView), by adding border with the size and color that you want, and give it the corner radius that you seems cool, and you can also make an imageview looks like a circle.

Topics


2D Engines   3D Engines   9-Patch   Action Bars   Activities   ADB   Advertisements   Analytics   Animations   ANR   AOP   API   APK   APT   Architecture   Audio   Autocomplete   Background Processing   Backward Compatibility   Badges   Bar Codes   Benchmarking   Bitmaps   Bluetooth   Blur Effects   Bread Crumbs   BRMS   Browser Extensions   Build Systems   Bundles   Buttons   Caching   Camera   Canvas   Cards   Carousels   Changelog   Checkboxes   Cloud Storages   Color Analysis   Color Pickers   Colors   Comet/Push   Compass Sensors   Conferences   Content Providers   Continuous Integration   Crash Reports   Credit Cards   Credits   CSV   Curl/Flip   Data Binding   Data Generators   Data Structures   Database   Database Browsers   Date &   Debugging   Decompilers   Deep Links   Dependency Injections   Design   Design Patterns   Dex   Dialogs   Distributed Computing   Distribution Platforms   Download Managers   Drawables   Emoji   Emulators   EPUB   Equalizers &   Event Buses   Exception Handling   Face Recognition   Feedback &   File System   File/Directory   Fingerprint   Floating Action   Fonts   Forms   Fragments   FRP   FSM   Functional Programming   Gamepads   Games   Geocaching   Gestures   GIF   Glow Pad   Gradle Plugins   Graphics   Grid Views   Highlighting   HTML   HTTP Mocking   Icons   IDE   IDE Plugins   Image Croppers   Image Loaders   Image Pickers   Image Processing   Image Views   Instrumentation   Intents   Job Schedulers   JSON   Keyboard   Kotlin   Layouts   Library Demos   List View   List Views   Localization   Location   Lock Patterns   Logcat   Logging   Mails   Maps   Markdown   Mathematics   Maven Plugins   MBaaS   Media   Menus   Messaging   MIME   Mobile Web   Native Image   Navigation   NDK   Networking   NFC   NoSQL   Number Pickers   OAuth   Object Mocking   OCR Engines   OpenGL   ORM   Other Pickers   Parallax List   Parcelables   Particle Systems   Password Inputs   PDF   Permissions   Physics Engines   Platforms   Plugin Frameworks   Preferences   Progress Indicators   ProGuard   Properties   Protocol Buffer   Pull To   Purchases   Push/Pull   QR Codes   Quick Return   Radio Buttons   Range Bars   Ratings   Recycler Views   Resources   REST   Ripple Effects   RSS   Screenshots   Scripting   Scroll Views   SDK   Search Inputs   Security   Sensors   Services   Showcase Views   Signatures   Sliding Panels   Snackbars   SOAP   Social Networks   Spannable   Spinners   Splash Screens   SSH   Static Analysis   Status Bars   Styling   SVG   System   Tags   Task Managers   TDD &   Template Engines   Testing   Testing Tools   Text Formatting   Text Views   Text Watchers   Text-to   Toasts   Toolkits For   Tools   Tooltips   Trainings   TV   Twitter   Updaters   USB   User Stories   Utils   Validation   Video   View Adapters   View Pagers   Views   Watch Face   Wearable Data   Wearables   Weather   Web Tools   Web Views   WebRTC   WebSockets   Wheel Widgets   Wi-Fi   Widgets   Windows   Wizards   XML   XMPP   YAML   ZIP Codes