Category "android-layout"

How to have EditText with border in Android Lollipop

I am developing an Android app. I need to know how we can have a EditText with border. In Lolipop they have completely changed the EditText style. Can we do it

How to align to right on the same column in android layout

I have 2 text view and i want them to align horizontally at the same column. I tried to android:layout_toRightOf="@id/textName" but it seem like it goes to t

Error inflating class com.andexert.expandablelayout.library.ExpandableLayout

Im getting this error android.view.InflateException: Binary XML file line #12: Error inflating class com.andexert.expandablelayout.library.ExpandableLayout E/A

how to make full screen activity with status bar on top of it while scrollbar is not scrolling full in Activity when it focus on editText?

Issue is that when I enter text in EditText then ScrollView does not work and does not scroll in my activity fun statusBarColor(activity: Activity) {

how to make full screen activity with status bar on top of it while scrollbar is not scrolling full in Activity when it focus on editText?

Issue is that when I enter text in EditText then ScrollView does not work and does not scroll in my activity fun statusBarColor(activity: Activity) {

View in the view pager overlap between previous and next view

I am using ViewPager for sliding effect in my app. I have pager.setPageMargin() to make next and previous views visibility, unfortunately my next view is over

How to use wrap_content with a maximum width?

I am trying to layout a view that should wrap its content, but it shouldn't be more than ~100dp less than its parent width. How can I do that using a RelativeLa

How to add Toolbar on Translucent imageview

I need to know, How we can create an toolbar on this imageview just with back button(getSupportActionBar().setDisplayHomeAsUpEnabled(true);). Here is the exampl

Android button position fixed to bottom until scroll to its parent layout position

I want to add a button to my layout which is fixed to bottom in the screen until user scroll and come to its proper location in the parent layout. Here the butt

Change color of Floating Action Button from Appcompat 22.2.0 programmatically

I would like to know how to change the Floating Action Button color from the Support library 22.2.0 ? I've tried button.setBackgroundColor(color); but clear

RecyclerView: Inconsistency detected. Invalid item position

Our QA has detected a bug: when rotating the Android device (Droid Turbo), the following RecyclerView-related crash happened: java.lang.IndexOutOfBoundsExce

Android Nougat: TextureView doesn't support displaying a background drawable

I have been using a TextureView in my android app, and it was working fine. Just recently I tested my code on an Android device with Android API 25 (7.1.2). Sam

Svg not visible in device but visible in android xml

I have used SVG's for these icons, the icons are visible in xml but not visible in device . following is my code : ` <LinearLayout

How to build a horizontal ListView with RecyclerView

I need to implement a horizontal listview in my Android application. I did a bit of research and came across How can I make a horizontal ListView in Android? an

How can I change default dialog button text color in android 5

I have many alert dialogs in my app. It is a default layout but I am adding positive and negative buttons to the dialog. So the buttons get the default text col

How to remove ripple effect from MaterialCardVew?

How can I disable touch ripple effect of MaterialCardView? Setting clickable attribute to false or playing with foreground and background attributes had no effe

Fragments show before Views finish rendering in Android

I have a problem in my Android app: lately, when I switch between fragments, their layout shows as XML before children views are shown correctly. For example, i

How to know if Text is visible on Jetpack Compose?

I have a scrollable screen and I would like to do action when a specific text appears/disappears in that screen. Is there any way to do that? Thanks

When using Immersive Mode with dialogs, nav. bar reappears and resizes my layout

I'm using Immersive Mode in my app when it's running on Android 4.4+. (http://developer.android.com/training/system-ui/immersive.html) My activity indeed shows

Error when trying to use a PieChart (hellocharts) on an Activity

I'm trying to use the external library "hellocharts" in my project. I have linked the library to my project already, but when the activity that has the chart st