• Stars
    star
    1,283
  • Rank 35,190 (Top 0.8 %)
  • Language
    Java
  • License
    Apache License 2.0
  • Created over 6 years ago
  • Updated almost 2 years ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

An Android library to implement TicketView in android with normal, rounded and scallop corners

TicketView

An Android Library used to implement TicketView in android with normal, rounded and scallop corners.

Specs

API Maven Central License

Badges/Featured In

TicketView Android Arsenal AndroidDev Digest

showcase

Sample Project

For information : checkout Sample App Code in repository.

Download

TicketView on Google Play

Quick Setup

1. Include library

Using Gradle

dependencies {
    implementation 'com.vipulasri:ticketview:1.1.2'
}

What's New

See the project's Releases page for a list of versions with their change logs.

View Releases

If you Watch this repository, GitHub will send you an email every time I publish an update.

2. Usage

  • In XML Layout :
<com.vipulasri.ticketview.TicketView
        android:layout_width="match_parent"
        android:layout_height="160dp"
        android:layout_marginTop="60dp"
        android:layout_marginLeft="20dp"
        android:layout_marginRight="20dp"
        android:id="@+id/ticketView"
        app:ticketOrientation="vertical"
        app:ticketScallopRadius="10dp"
        app:ticketShowBorder="false"
        app:ticketScallopPositionPercent="50"
        app:ticketShowDivider="true"
        app:ticketDividerType="dash"
        app:ticketDividerPadding="0dp"
        app:ticketElevation="14dp"/>
  • Configure using xml attributes or setters in code:

    Attribute Name Default Value Description
    app:ticketOrientation="vertical" horizontal sets orientation of divider and scallop
    app:ticketBackgroundColor="@android:color/black" white sets background color
    app:ticketScallopRadius="10dp" 20dp sets scallop radius
    app:ticketScallopPositionPercent="50" 50 sets position of scallop and divider
    app:ticketShowBorder="false" false shows border if `true`
    app:ticketBorderWidth="4dp" 2dp sets border width
    app:ticketBorderColor="@color/grey" black sets border color
    app:ticketShowDivider="true" false shows divider if `true`
    app:ticketDividerType="dash" normal sets type of divider ie `normal` or `dash`
    app:ticketDividerColor="@color/colorAccent" dark gray sets divider color
    app:ticketDividerWidth="2dp" 2dp sets divider width
    app:ticketDividerPadding="0dp" 10dp sets divider padding
    app:ticketDividerDashGap="4dp" 4dp sets divider dash gap
    app:ticketDividerDashLength="8dp" 8dp sets divider dash length
    app:ticketCornerType="rounded" normal sets type of corner ie `normal` or `rounded` or `scallop`
    app:ticketCornerRadius="15dp" 4dp sets corner radius if corner rounder or scallop
    app:ticketElevation="14dp" 0dp sets elevation to ticket view on android jellybean and above
    app:ticketBackgroundBeforeDivider none sets background to ticket view before divider
    app:ticketBackgroundAfterDivider none sets background to ticket view after divider
    app:ticketShadowColor black sets shadow to ticket view

Apps that use this library

Apps using Ticket View, via AppBrain Stats

If you're using this library in your app and you'd like to list it here, Please let me know via email, pull requests or issues.

Special Thanks

Nick Butcher for helping me out with TicketView Shadow/Elevation.

License

Copyright 2017 Vipul Asri

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.

More Repositories

1

Timeline-View

Android Timeline View is used to display views like Tracking of shipment/order, steppers etc.
Kotlin
3,774
star
2

JetInstagram

JetInstagram is an Instagram UI clone app built with Jetpack Compose.
Kotlin
748
star
3

JetDelivery

JetDelivery is a sample food delivery app, built with Jetpack Compose
Kotlin
367
star
4

ComposeSlackDesktop

A Slack demo app for desktop using Jetpack Compose UI toolkit
Kotlin
279
star
5

flutter_bubble_tab_indicator

A Flutter library to add bubble tab indicator to TabBar
Dart
189
star
6

Layout-to-Image

Android Layout (Relative Layout, Linear Layout etc) to Image
Java
165
star
7

Serene

Serene is a white noise app developed with Flutter. It helps you meditate, sleep better, focus, relax and be calm.
Dart
97
star
8

Multiple-Backstack-Navigation

Handling multiple backstack histories for each tab in Bottom Navigation using Navigation Component.
Kotlin
63
star
9

Toolbar-Elevation-Pre-Lollipop

Toolbar Elevation on Pre-lollipop devices
54
star
10

Artisto_capstone

This is Capstone Project of Android Developer Nanodegree program.
Java
36
star
11

Udacity-Popular-Movies

This is an android app which I made from scratch as a part of Android Developer Nanodegree program.
Java
33
star
12

LocationUpdates

A service running in background gives location updates and displays a notification.
Java
32
star
13

kachetor

Kachetor adds support for persistent HTTP caching for Ktor (Kotlin Multiplatform)
Kotlin
14
star
14

PuppyCo

Kotlin
4
star
15

Staggered-View-Native-Advanced-Ads

Native Advanced Ads implementation in Staggered RecyclerView
Java
4
star
16

Posty

A sample app that showcases the use of the latest technologies following MVVM with Clean Architecture.
Kotlin
4
star
17

Expense-Manager

Kotlin
3
star
18

BintrayHelper

2
star
19

XYZ-Reader

Java
1
star
20

Streamer

Kotlin
1
star
21

vipulasri

1
star
22

Pelm

Kotlin
1
star
23

Build-It-Bigger

Build It Bigger is a joke telling app having free & paid version and configured with google cloud endpoints.
Java
1
star
24

Inshorts-Challenge

This code was developed for Inshorts Android App Development Hiring Challenge on HackerEarth.
Java
1
star
25

Bottom-Navigation-View-Sample

Its Bottom Navigation View Sample introduced in Android Support Library v25.0.0
Java
1
star