use of com.alexvasilkov.android.commons.texts.SpannableBuilder in project GestureViews by alexvasilkov.
the class RecyclerAdapter method onBindViewHolder.
@Override
public void onBindViewHolder(ViewHolder holder, int position) {
final Painting painting = paintings[position];
// Storing item position for click handler
holder.itemView.setTag(R.id.tag_item, position);
GlideHelper.loadThumb(holder.image, painting.thumbId);
CharSequence text = new SpannableBuilder(holder.title.getContext()).createStyle().setFont(Typeface.DEFAULT_BOLD).apply().append(painting.author).append("\n").clearStyle().append(painting.title).build();
holder.title.setText(text);
}
Aggregations