Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up

A SiderBar base on Android that has a beautiful anim

NotificationsYou must be signed in to change notification settings

AlexLiuSheng/AnimSideBar

Repository files navigation

A SiderBar base on Android that has a wave anim

update in 19/12/16

implementation this widget in a new way.

effect

use

include:

dependencies {       implementation 'com.github.AlexLiuSheng:AnimSideBar:1.0.0'}

alternatively,you can include it just copy the code into your project.

use

to use,you should write like this in your layout

  <com.allenliu.sidebar.SideBar    android:layout_alignParentRight="true"    android:textColor="@color/colorAccent"    android:textSize="12sp"    android:paddingRight="10dp"    android:layout_width="wrap_content"    android:id="@+id/bar"    android:layout_height="match_parent" />

after this ,you can add a setOnStrSelectCallBack,like this

bar.setOnStrSelectCallBack(new ISideBarSelectCallBack() {        @Override        public void onSelectStr(int index, String selectStr) {            Toast.makeText(SideBarDemoActivity.this,selectStr,Toast.LENGTH_SHORT).show();        }    });

there are some other methods to apply:

        <attr name="fontScale" format="float" />   //text Font scale  when scrolling ,defalut :1        <attr name="bigTextSize" format="float" /> // the big text size ,default is 3 times than text size        <attr name="openCount" format="integer" />  //the parabola opening size ,defalut 13,        <attr name="A" format="integer" />   // the size of amplitude,defalut is 100dp        <attr name="gapBetweenText" format="integer" /> // the distance between BigText and peak,defalut is 50dp

About

A SiderBar base on Android that has a beautiful anim

Topics

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages


[8]ページ先頭

©2009-2025 Movatter.jp