All Projects → jsaman19 → easyCountDownTimer

jsaman19 / easyCountDownTimer

Licence: Apache-2.0 license
A simple android library to countdown timer textview for api 14+

Programming Languages

java
68154 projects - #9 most used programming language

Projects that are alternatives of or similar to easyCountDownTimer

Parallaxrecyclerview
Parallax effect on every item of your RecyclerView.
Stars: ✭ 237 (+288.52%)
Mutual labels:  custom-view
ScaleView
ArcScaleView,ScaleView,刻度尺选择器,包括弧形刻度尺选择器和直尺形刻度尺选择器
Stars: ✭ 53 (-13.11%)
Mutual labels:  custom-view
CountdownTimer-TeLeTiPs
The very first powerful Telegram bot to countdown to your important events in any group chat. Live countdown timer (days : hours : minutes : seconds)
Stars: ✭ 122 (+100%)
Mutual labels:  countdown-timer
Colorseekbar
A colorful SeekBar for picking color
Stars: ✭ 249 (+308.2%)
Mutual labels:  custom-view
CountDownTextView
A count down widget for verify code
Stars: ✭ 22 (-63.93%)
Mutual labels:  countdown-timer
XCPullToLoadMoreListView
XCPullToLoadMoreListView-下拉加载更多ListView控件(仿QQ、微信聊天对话列表控件)
Stars: ✭ 24 (-60.66%)
Mutual labels:  custom-view
Android Youtube Player
YouTube Player library for Android and Chromecast, stable and customizable.
Stars: ✭ 2,510 (+4014.75%)
Mutual labels:  custom-view
Circular-Progress-View
A customisable circular progress view for android.
Stars: ✭ 39 (-36.07%)
Mutual labels:  custom-view
IconDotTextView
Convenient to add a View which contains icon, text and red dot.
Stars: ✭ 22 (-63.93%)
Mutual labels:  custom-view
ProgressableImageView
Change your users progress capability with ProgressableImageView
Stars: ✭ 86 (+40.98%)
Mutual labels:  custom-view
Bezierseekbar
Beautiful custom View, SeekBar selector, easy to use, and rich in customization.漂亮的区间选择器,贝塞尔曲线优雅实现
Stars: ✭ 252 (+313.11%)
Mutual labels:  custom-view
RatioLayouts
A collection of ViewGroups which can have a constant width to height ratio.
Stars: ✭ 19 (-68.85%)
Mutual labels:  custom-view
vuejs-countdown-timer
⏱ Vue 2 event countdown and timer component
Stars: ✭ 47 (-22.95%)
Mutual labels:  countdown-timer
Apporder
骚操作之改造TabLayout,修改指示线宽增加切Tab过渡动画
Stars: ✭ 246 (+303.28%)
Mutual labels:  custom-view
WechatPopupWindow
高仿微信聊天界面长按弹框样式
Stars: ✭ 71 (+16.39%)
Mutual labels:  custom-view
Jpagerslidingtabstrip
🔥A useful tablayout modify from astuetz/PagerSlidingTabStrip
Stars: ✭ 233 (+281.97%)
Mutual labels:  custom-view
CustomView
custom view
Stars: ✭ 13 (-78.69%)
Mutual labels:  custom-view
react-timer-wrapper
Composable React Timer component that passes status props to children, in addition to some basic callbacks. Can be used at a countdown timer ⏲ or as stopwatch ⏱ to track time while active.
Stars: ✭ 14 (-77.05%)
Mutual labels:  countdown-timer
XCArcProgressView
Android开口圆环比例进度View(高仿猎豹清理大师内存占用比例View)
Stars: ✭ 28 (-54.1%)
Mutual labels:  custom-view
android-thinkmap-treeview
Tree View; Mind map; Think map; tree map; custom view; 自定义;关系图;树状图;思维导图;组织机构图;层次图
Stars: ✭ 314 (+414.75%)
Mutual labels:  custom-view

easyCountDownTimer

A simple android library to countdown timer textview for api 14+

Screan shot

screan_shot

screan_shot

Setup

The simplest way to use easyCountDownTimer is to add the library as aar dependency to your build.

Maven

<dependency>
  <groupId>ir.samanjafari.easycountdowntimer</groupId>
  <artifactId>easycountdowntimer</artifactId>
  <version>2.5.0</version>
  <type>aar</type>
</dependency>

Gradle

buildscript {
    repositories {
        google()
        jcenter()
        mavenCentral() // Add this Line
    }
    dependencies {
        classpath "com.android.tools.build:gradle:4.1.3"
    }
}

allprojects {
    repositories {
        google()
        jcenter()
        mavenCentral() // Add this line
    }
}

dependencies {
    implementation 'ir.samanjafari.easycountdowntimer:easycountdowntimer:2.5.0'
}

Usage

Add the following code to your view

<ir.samanjafari.easycountdowntimer.EasyCountDownTextview
        android:id="@+id/easyCountDownTextview"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:layout_centerInParent="true"
        app:hours="0"
        app:minute="1"
        app:second="10"
        app:showHours="true"
        app:textSize="12sp"
        app:digitBackground="@android:color/transparent"
        app:textColor="#9c9c9c"
        app:setAnimation="true"
        app:colonColor="#000"
        app:showDays="true"
        app:daysLabel="D"
        app:days="1"
        app:start_automatically="false"
        app:useFarsiNumeral="true"
        />

whit the following code you can listen to onFinish or onTick timer

EasyCountDownTextview countDownTextview = (EasyCountDownTextview) findViewById(R.id.easyCountDownTextview);
easyCountDownTextview.setTime(1, 1, 1, 1);
        easyCountDownTextview.setOnTick(new CountDownInterface() {
            @Override
            public void onTick(long time) {
                
            }

            @Override
            public void onFinish() {

            }
        });

how to set time programmatically ?

EasyCountDownTextview easyCountDownTextview = (EasyCountDownTextview) findViewById(R.id.easyCountDownTextview);
easyCountDownTextview.setTime(1,1, 30, 15);// setTime(days, hours, minute, second)

how to set custom font

Typeface typeface = ResourcesCompat.getFont(this, R.font.my_font);
easyCountDownTextview.setTypeFace(typeface);

how to pause and resume timer

easyCountDownTextview.pause();

easyCountDownTextview.resume();

Licence

Copyright 2017 Saman Jafari

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Author

Saman Jafari

email: [email protected]

github: https://github.com/jsaman19

site : http://samanjafari.ir

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].