danoz73 / RecyclerViewFastScroller

A Fast Scroller for the RecyclerView world!
Other
1.13k stars 211 forks source link

Character is not shows in bubble #53

Closed naitikvithlani closed 6 years ago

naitikvithlani commented 8 years ago

I have used code as follow, but I don't able to see the character in bubble.

In JavaFile:

RecyclerView recyclerView = (RecyclerView) findViewById(R.id.rvAddColorMarkUserLists); VerticalRecyclerViewFastScroller fastScroller =(VerticalRecyclerViewFastScroller) findViewById(R.id.fast_scroller); SectionTitleIndicator sectionTitleIndicator =(SectionTitleIndicator) findViewById(R.id.fast_scroller_section_title_indicator); fastScroller.setRecyclerView(recyclerView);

recyclerView.setAdapter(usersAdapter); recyclerView.setItemAnimator(new DefaultItemAnimator()); // Connect the scroller to the recycler (to let the recycler scroll the scroller's handle)

// Connect the section indicator to the scroller fastScroller.setSectionIndicator(sectionTitleIndicator); recyclerView.setOnScrollListener(fastScroller.getOnScrollListener()); setRecyclerViewLayoutManager(recyclerView);

In xml file

<android.support.v7.widget.RecyclerView android:id="@+id/rvAddColorMarkUserLists" style="@style/recyclerViewListView" android:visibility="visible" android:paddingTop="10dp" />

    <xyz.danoz.recyclerviewfastscroller.vertical.VerticalRecyclerViewFastScroller
        android:id="@+id/fast_scroller"
        android:layout_width="24dp"
        android:layout_height="match_parent"
        android:layout_alignParentRight="true"
        android:layout_alignParentEnd="true"
        android:paddingRight="@dimen/margin_small"
        android:paddingEnd="@dimen/margin_small"
        recyclerviewfastscroller:rfs_barColor="@color/white"
        recyclerviewfastscroller:rfs_handleBackground="@drawable/fast_scroller_handle_rounded"
        />
    <xyz.danoz.recyclerviewfastscroller.sectionindicator.ui.ColorGroupSectionTitleIndicator
        android:id="@+id/fast_scroller_section_title_indicator"
        android:layout_width="wrap_content"
        android:layout_height="@dimen/list_item_height"
        android:layout_toLeftOf="@id/fast_scroller"
        android:layout_toStartOf="@id/fast_scroller"
        recyclerviewfastscroller:rfs_backgroundColor="@color/red"
        recyclerviewfastscroller:rfs_textColor="@android:color/white"
        />
patelawp commented 8 years ago

I'm also having the same problem.

patelawp commented 8 years ago

I got this. You have to implement SectionIndexer to your Adapter.

naitikvithlani commented 6 years ago

@patelawp Thanks !