Top "Android-xml" questions

Android projects use XML in several ways: defining the project and components, building layouts, defining animations, creating menus and specifying resources (static and dynamic) for the project.

RecyclerView adapter showing wrong images

I have a RecyclerView adapter that looks like this: public class RecyclerAdapter extends RecyclerView.Adapter<RecyclerAdapter.ViewHolder> { private …

android android-layout android-xml android-recyclerview
Unable to use LayoutInflater in custom adapter

I'm looking into writing a custom adapter to populate a listview with 3 textviews per line. I've found quite a bit …

android android-layout listview android-xml android-adapter
Using an array reference as an XML attribute for custom android view

This problem has been solved, see comments for details. I am extending an existing Android View and loading some custom …

android custom-attributes android-xml android-custom-view
Custom Dialog size to match Theme.Holo.Light.Dialog

If I have an Activity that has it's theme set to Theme.Holo.Light.Dialog, it will scale great. It …

android android-layout dialog android-xml android-dialog
Android Cannot resolve symbol '?attr/selectableItemBackground'

<android.support.v7.widget.CardView android:id="@+id/card_view" android:layout_width="match_parent" android:layout_height="wrap_…

android android-xml
View with Solid Background and Top+Bottom Inner Shadows

Essentially, I am trying to create the following background: The traditional gradient which use in the drawable that I use …

android android-xml android-background
XmlPullParserException Binary XML file line #17<vector> tag requires viewportWidth > 0

This is a follow up question to this question: Update Android Support Library to 23.2.0 cause error: XmlPullParserException Binary XML file …

android android-xml android-xmlpullparser
How to remove border only from one side of the element?

I have: <stroke android:width="1px" android:color="#A6ACB1"/> I'd like to remove this border from the …

android border android-xml android-drawable
match_parent not performing as expected

I imagine this should be a fairly easy one to answer, if you understand XML Layouts better than I do …

android android-linearlayout android-xml xml-layout
How to Increase the size of Image View in Android

I am working on a project that requires me to implement two horizontal scroll views with an image view in …

java android android-xml android-gallery galleryview