Top "Android-layout" questions

A layout defines the visual structure for a user interface, such as the UI for an activity, fragment or app widget.

Android How to adjust layout in Full Screen Mode when softkeyboard is visible

I have researched a lot to adjust the layout when softkeyboard is active and I have successfully implemented it but …

android android-layout android-widget android-softkeyboard
Add ripple effect to my button with button background color?

I created a button and I want to add ripple effect to that button! I created a button bg XML …

android android-layout android-drawable rippledrawable
Android Image View Pinch Zooming

I am using code sample from Making Sense of Multitouch for zooming image view. On ScaleListener I added ScaleGestureDetector.getFocusX() …

android android-layout android-intent android-widget
How to change the color of a button?

I'm new to android programming. How do I change the color of a button? <Button android:id="@+id/btn" …

android android-layout android-button
LinearLayout not expanding inside a ScrollView

I have a LinearLayout inside a ScrollView that has android:layout_height="fill_parent", but it doesn't expand to the …

android android-layout
How to set RelativeLayout layout params in code not in xml?

For example I want to add 3 buttons on screen: one align left, one align center, last one align right. How …

android android-layout android-relativelayout
This view is not constrained vertically. At runtime it will jump to the left unless you add a vertical constraint

New Layout editor in Android Studio 2.2 keeps showing this error on views like EditText and Buttons. kindly help.Also, any …

android-layout android-studio android-edittext layout-editor
Remove icon/logo from action bar on android

I've been trying to find some way of removing the icon/logo from the action bar but the only thing …

android xml android-layout android-actionbar titlebar
Differences between ConstraintLayout and RelativeLayout

I am confused about the difference between ConstraintLayout and RelativeLayout. Could someone please tell me the exact differences between them?

android android-layout android-relativelayout android-constraintlayout
Android button with different background colors

i want to change the background-color of a button using a selector-xml-file. My approach is basically the one from the …

android android-layout android-xml