List of usage examples for android.text.style DynamicDrawableSpan ALIGN_BOTTOM
int ALIGN_BOTTOM
To view the source code for android.text.style DynamicDrawableSpan ALIGN_BOTTOM.
Click Source Link
From source file:com.vuze.android.remote.adapter.SideFilterAdapter.java
@Override public void onBindFlexibleViewHolder(SideFilterViewHolder holder, int position) { SideFilterInfo item = getItem(position); if (item.letters.equals(TorrentListFragment.LETTERS_BS)) { ImageSpan imageSpan = new ImageSpan(context, R.drawable.ic_backspace_white_24dp, DynamicDrawableSpan.ALIGN_BOTTOM); SpannableStringBuilder ss = new SpannableStringBuilder(","); ss.setSpan(imageSpan, 0, 1, 0);/*from w ww .j ava 2 s . c om*/ holder.tvText.setText(ss); } else { holder.tvText.setText(item.letters); int resID = item.letters.length() > 1 ? android.R.style.TextAppearance_Small : android.R.style.TextAppearance_Large; holder.tvText.setTextAppearance(context, resID); holder.tvText.setTextColor(ContextCompat.getColor(context, R.color.login_text_color)); } holder.tvCount.setText(item.count > 0 ? String.valueOf(item.count) : ""); }