Multicolor TextView for Android

Android TextView is capable of showing text in your Android app and previously we discuss how to add rotating animation with TextView. This tutorial explains how to use MultiColor TextView in Android application.
Multicolor TextView in Android

This is a simple library to display text with multicolor. Let see some demo of Multicolor TextView library:


How to Install Multicolor TextView?

Add to your app module build.gradle
compile ''
For gradle 3.x
implementation ''
For maven add to your pom file:





Source: How to Add Multicolor TextView in Android? 

Nothing Type in Kotlin

A colleague approached me a while ago and asked me a question about Kotlin. What was this “Nothing type”, and what was it used for? I did not really have a good answer for him at the time.
Since then, I’ve found my answer.
In mathematics, bottom (often denoted as _|_) represents the absolute minimum value something can hold.
Nothing type has no instances. You can use Nothing to represent “a value that never exists”: for example, if a function has the return type of Nothing, it means that it never returns (always throws an exception).
Previously shared Kotlin post:
  1. Top 12 Advanced Kotlin Tips For Pro Developers
  2. Kotlin Parcelize – Developer need to know
  3. Create Firefox Extension Using KotlinJS
When we’re talking about types, we can think of Nothing as being the absolute bottom (leaf) object of any type hierarchy.
What we can see in this diagram (figure 1) is that Nothing is the opposite of Any. While every object you will work with in Kotlin implicitly extends Any, so to does Nothing implicity extend any object that exists. This makes Nothing the ‘dual’ or opposite of Any.
So, why is this useful?

See full article >>

Advanced Kotlin Tips

Advanced Kotlin Tips on writing good Kotlin code and using what the language has to offer. There are many benefits of using Kotlin; it is concise, safe and most importantly it is 100% interoperable with Java. It also tries to solve some of the limitations of Java.
Top 12 Advanced Kotlin Tips For Pro Developers
Now is a good time to consider Kotlin for your next big feature or project, because Google finally announced it to be a first-class language for writing Android apps in Google I/O 17.

So here are some advanced Kotlin tips to help you start making use of what the language has to offer and writing good Kotlin code.

1. Singleton

Implementing lazy loaded and thread-safe singletons in Kotlin is really easy, unlike Java where you would have to rely on the complex double-checked locking pattern. And although Java enum singletons are thread-safe, they are not lazy loaded.
  1. object Singleton {
  2. var s: String? = null
  3. }
Contrary to a Kotlinclass, an object can’t have any constructor, but initblocks can be used if some initialization code is required.
  1. Singleton.s = “test” // class is initialized at this point
The object will be instantiated and its init blocks will be executed lazily upon first access, in a thread-safe way.

Awesome Kotlin Parcelize Feature - Need to Know

You are going to delete lots of lines of code! Yes, it is not a clickbait!
Kotlin Parcelize - Developer need to know
How do you pass your model between activities?
  • Serializable?
  • EventBus / Otto ?
  • Parcelable?
Serializable = Reflection! Run Forest Run!!! It is terrible for Android performance.
Bus libraries like EventBus or Otto are easy to use and have good performance but after some time they cause too much complexity in your code.
Parcelable interface is great for Android performance but it has too much boilerplate.

Parcelize 😍

Kotlin added parcelable support in version 1.1.4.
Android Extensions plugin now includes an automatic Parcelable implementation generator. Declare the serialized properties in a primary constructor and add a @Parcelize annotation, and writeToParcel()/createFromParcel() methods will be created automatically.

Create Food Order Tracking app using Android Timeline View Library

Food Tracking Android Timeline View Example
Food Tracking Android Timeline View Example

Android Timeline View Library (Using RecyclerView) is simple implementation used to display view like Tracking of shipment/order, steppers etc. Previously we discuss Android Vertical Steppers library which may display a transient feedback message after a step is saved.
Demo : Vertical Stepper Form Library
And today we’re going to see a cool library which help you to implement that Android Timeline View in your applications.
Android Timeline View
Android Timeline View