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

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

License

NotificationsYou must be signed in to change notification settings

vipulasri/TicketView

Repository files navigation

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

Specs

APIMaven CentralLicense

Badges/Featured In

TicketViewAndroid ArsenalAndroidDev Digest

showcase

Sample Project

For information : checkoutSample 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.

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.TicketViewandroid: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 NameDefault ValueDescription
    app:ticketOrientation="vertical"horizontalsets orientation of divider and scallop
    app:ticketBackgroundColor="@android:color/black"whitesets background color
    app:ticketScallopRadius="10dp"20dpsets scallop radius
    app:ticketScallopPositionPercent="50"50sets position of scallop and divider
    app:ticketShowBorder="false"falseshows border if `true`
    app:ticketBorderWidth="4dp"2dpsets border width
    app:ticketBorderColor="@color/grey"blacksets border color
    app:ticketShowDivider="true"falseshows divider if `true`
    app:ticketDividerType="dash"normalsets type of divider ie `normal` or `dash`
    app:ticketDividerColor="@color/colorAccent"dark graysets divider color
    app:ticketDividerWidth="2dp"2dpsets divider width
    app:ticketDividerPadding="0dp"10dpsets divider padding
    app:ticketDividerDashGap="4dp"4dpsets divider dash gap
    app:ticketDividerDashLength="8dp"8dpsets divider dash length
    app:ticketCornerType="rounded"normalsets type of corner ie `normal` or `rounded` or `scallop`
    app:ticketCornerRadius="15dp"4dpsets corner radius if corner rounder or scallop
    app:ticketElevation="14dp"0dpsets elevation to ticket view on android jellybean and above
    app:ticketBackgroundBeforeDividernonesets background to ticket view before divider
    app:ticketBackgroundAfterDividernonesets background to ticket view after divider
    app:ticketShadowColorblacksets 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 viaemail,pull requests orissues.

Special Thanks

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

License

Copyright 2017 Vipul AsriLicensed 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.0Unless required by applicable law or agreed to in writing, softwaredistributed 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 andlimitations under the License.

About

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

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages


[8]ページ先頭

©2009-2025 Movatter.jp