Moveable Textview in Android

There is many Image editing or collage maker app have one simple functionality, which is move able Text. In out regular TextView, we don’t need it because our requirement is static text on TextView. Now in last week I need this functionality in one application ( My Quotes ) to put move able quote text in Relative layout for making Image. See below screenshot.

android-quote-my-move-able-textview-skynils

 

Move able TextView is simple with OnTouchListener(..) of TextView. A simple code make rock effect. Let’s see code.

out activity_main.xml .

Now code for moving in Java. See MainActivity.java below.

Here remember,

 Don’t miss to change return as true, other wise our functionality does’t work !!

Now run the project.  Out output look like below.

android-move-able-textview-gif-skynils

Have a nice code..!!