5

Is it possible to remove/change color of the delimiter in AutoCompleteTextView's popup ? In ListView I get use of the "delimiter" parameter, but I haven't found any similar in AutoCompleteTextView.

Thanks.

midnight
  • 3,420
  • 3
  • 36
  • 58
  • see http://stackoverflow.com/questions/11777912/customize-divider-separator-in-dropdown-of-an-autocompletetextview. It should solve the problem of divider styling. – Mark Sep 18 '12 at 11:15
  • I've solved it. there's an Android array called styleable or something like that R.styleable.delimiter_autocomplete bla bla bla – midnight Sep 18 '12 at 17:52
  • @midnight can you explain your solution in more detail? – cottonBallPaws Mar 08 '13 at 21:58
  • 1
    @littlefluffykitty sorry, I dont have code at hand atm - I remember I was looking through the source code http://grepcode.com/file/repository.grepcode.com/java/ext/com.google.android/android/1.5_r4/android/widget/AutoCompleteTextView.java where I found http://developer.android.com/reference/android/R.attr.html#autoCompleteTextViewStyle where you can actually override one of the properties, which corresponds to the delimiter color. – midnight Mar 11 '13 at 07:26

2 Answers2

0

Use an Adapter for your AutoCompleteTextView. Then, you can do something like this :

adapter.setDropDownViewResource(R.layout.spinner_dropdown_item);

The layout can be configured by you.

cosmincalistru
  • 1,283
  • 9
  • 20
0

A quick fix solution, for removing the divider, might be writing a custom XML to override the style for each cell (Through the SetDropDownViewResource). After that you can change the android:popupBackground property on the autocompletetextview to match it to the color of your item's background.

Ailon V
  • 31
  • 2