Click here to Skip to main content
15,894,825 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
hi everyone. I m newly started to learn android studio. i just made a small app using one button and a textview. when i run it those button and textview going to up and existing one on one. its happening ever time where ever those are. please help me to fix this and go ahead.. thank you!

What I have tried:

i reinstalled android studio but its happening again and again
Posted
Updated 22-Jun-17 10:42am
Comments
wseng 23-Jun-17 0:29am    
The problem not related with Android Studio. Please post the xml layout.

1 solution

What you are facing is the problem with ConstraintLayout in Android Studio. Personally, this is the worst thing that Google has ever added to Android OS or Android Studio for Android development, it makes Android UI design more painful, than helpful. What happens is, that you create a layout and you constrain the layout to at least 2 sides (right, left, top, bottom) and add the elements that control the view, and other views in the view.

You would need to add constraints, please see the following link as it explains a bit about this layout. Also, in almost all of the new layouts you are provided with a ConstraintLayout, you can change that as well in the Android Layout.

Build a Responsive UI with ConstraintLayout | Android Developers[^]
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900