use of io.praveen.typenote.SQLite.AboutAdapter in project Android-NotesApp by HelloPraveenIO.
the class ContributorsActivity method onCreate.
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_contributors);
CalligraphyConfig.initDefault(new CalligraphyConfig.Builder().setDefaultFontPath("fonts/whitney.ttf").setFontAttrId(R.attr.fontPath).build());
Typeface font2 = Typeface.createFromAsset(getAssets(), "fonts/whitney.ttf");
SpannableStringBuilder SS = new SpannableStringBuilder("Contributors");
SS.setSpan(new CustomTypefaceSpan("", font2), 0, SS.length(), Spanned.SPAN_EXCLUSIVE_INCLUSIVE);
if (getSupportActionBar() != null) {
getSupportActionBar().setTitle(SS);
getSupportActionBar().setDisplayHomeAsUpEnabled(true);
}
List<String> l = new ArrayList<>();
l.add("Praveen Thirumurugan");
l.add("Srikar Nanduri");
l.add("Bharath Raj Kumar");
l.add("Keerthana Ravichandran");
final RecyclerView recyclerView = findViewById(R.id.contributorsRecyclerView);
AboutAdapter mAdapter = new AboutAdapter(l);
RecyclerView.LayoutManager mLayoutManager = new LinearLayoutManager(getApplicationContext());
recyclerView.setLayoutManager(mLayoutManager);
recyclerView.setItemAnimator(new DefaultItemAnimator());
recyclerView.addItemDecoration(new DividerItemDecoration(this, LinearLayoutManager.VERTICAL));
recyclerView.setAdapter(mAdapter);
}
Aggregations