Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to show layout moving from left to right with slow speed

How to animate a layout moving from

left to right

on a button click. initially it should be invisible but on button click it should come out from left direction to cover the screen

like image 336
Shubham Avatar asked May 10 '13 13:05

Shubham


People also ask

How do I speed up layout?

Layout is lagging and way to slow. How do I speed it up? When LayOut is experiencing freezing or lagging, you can increase the program’s performance by changing your rendering settings.

How to change the monitor settings to left to right?

To change the monitor settings to left to right or right to left refer to the following steps: a. Right click a blank area on the desktop. b. Select the option Personalize and then Display settings. c. In the Monitor window that opens you should see your two monitors. d.

Why is MY layout freezing or lagging?

When LayOut is experiencing freezing or lagging, you can increase the program’s performance by changing your rendering settings. You’ll want to set the rendering settings to Raster while editing the file, and once edited you can switch back to Vector or Hybrid for any exporting or printing purposes you might have.

How do I fix the lag in layout?

You’ll want to set the rendering settings to Raster while editing the file, and once edited you can switch back to Vector or Hybrid for any exporting or printing purposes you might have. This should help with the lag time that you’re seeing within LayOut. Layout is lagging and way to slow.


Video Answer


1 Answers

You are going to want to layout your view's xml how you'd want it to show in it's final stage. Then set the visibility to gone. Then you will create a TranslateAnimation

TranslateAnimation anim = new TranslateAnimation(-100f, 0f, 0f, 0f);  // might need to review the docs
anim.setDuration(1000); // set how long you want the animation

ViewYouWantToAnimate.setAnimation(anim);
ViewYouWantToAnimate.setVisibility(View.VISIBLE);
like image 161
Jim Baca Avatar answered Oct 24 '22 20:10

Jim Baca