Android

Fancy toast in android library + Source Code

Fancy toast in android library
Android Toasts Fancy. A library that takes the standard Android toast to the next level with a variety of styling options.

Prerequisites

Add this in your root build.gradle file (not your module build.gradle file):

allprojects {
	repositories {
		...
		maven { url "https://jitpack.io" }
	}
}

Dependency

Add this to your code build.gradle file (make sure the version matches the JitPack badge above.

dependencies {
	...
	implementation 'com.github.Shashank02051997:FancyToast-Android:0.1.6'
}

Usage

Each method always returns a Toast object, so you can customize the Toast much more.

To display an default Toast:

FancyToast.makeText(this,"Hello World !",FancyToast.LENGTH_LONG,FancyToast.DEFAULT,true);

To display a success Toast:

FancyToast.makeText(this,"Hello World !",FancyToast.LENGTH_LONG,FancyToast.SUCCESS,true);

To display an info Toast:

FancyToast.makeText(this,"Hello World !",FancyToast.LENGTH_LONG,FancyToast.INFO,true);

To display a warning Toast:

FancyToast.makeText(this,"Hello World !",FancyToast.LENGTH_LONG,FancyToast.WARNING,true);

To display the error Toast:

FancyToast.makeText(this,"Hello World !",FancyToast.LENGTH_LONG,FancyToast.ERROR,true);

To display the confusing Toast:

FancyToast.makeText(this,"Hello World !",FancyToast.LENGTH_LONG,FancyToast.CONFUSING,true);

You can also remove the android icon on top-right corner by passing last parameter false.

FancyToast.makeText(yourContext, "I'm a Toast", duration, type, boolean value).show();

You can also create your custom Toasts with passing your image with or without android icon(top-right corner):

FancyToast.makeText(yourContext, "I'm a custom Toast", duration, type, yourimage, boolean value).show();

To display the custom Toast with no android icon:

FancyToast.makeText(this, "This is Custom Toast with no android icon", FancyToast.LENGTH_LONG, FancyToast.CONFUSING, R.

Related Articles

52 Comments

  1. Mү namе is Sergey and I’m the founder οf Creative Bear Tech, а
    lead generation and computger software business founded іn London, UK.
    I havе fоund your busness on Facebook and thoughjt thɑt you and pakacademy79.ϲom couuld seriouѕly benefit from oᥙr products аѕ we worк with extremely comparable organisations.
    Ԝe curгently һave oνer 15,000 customers and I аm in tthe
    process oof growing our offering bby opening business offices іn tһe USᎪ and
    thе Baltic Ѕtates.

    I would really love to᧐ see yoᥙ annd pakacademy79.ϲom
    becomе our next customer!

    Beⅼow aгe a feѡ of our moѕt popular services tһat yoս migyt loocate beneficial fօr your business.

    1. Ηigh Quality Β2Ᏼ Databases and E-mail Marketing Аnd Advertising Lists fоr over 7,000 niches аnd micro partіcular niches
    (m᧐st popular with businesses tһat hаνe a wholesale offering).

    2. ONLINE MARKETING ϲomputer software. Ӏf you are technology savvy,
    уou can makе uѕe of our Internet searc engine Scraper and Е-Mail Extractor
    tto scrape уour own salss lead fоr your niche.

    Ꮇany clients employ іt for identifying guest pposting opportunities fоr their web site Search Engine Optimisation (іn excess of 2,000 active սsers).

    3. Instagram Management Tool fоr organic Instgram followers, likes ɑnd comments.
    Ꭲhis is the absolute moѕt famous tool at the oment and has mօrе than 7,
    000 active ᥙsers.

    4. Searcch Engine Optimization Services. Ꮤe aso offer Search Engine Optimisatgion services ᧐n Sweaty Quid Freelance Marketplace (sweatyquid.ⅽom).
    Ԝe mainly offfer link building ɑѕ wе have а massive PBN ⲟf more than 25,000 sites.

    I ѡant tߋ offer yօu 25% оff youir next purchase with us ɑѕ a
    wway of wedlcoming you onboard.

    Рlease սse discount code HᎬLLO2020 for your 25% off any purchase.
    Valid fߋr 7 Ԁays only.

    If you ԝould like tօ speak to mе, pⅼease
    contact me via https://creativebeartech.com/content/contact-us. My personnal е-mail plays up sօmetimes
    ѕo contact form enquhiry ᴡould be best. You can aloso talk t᧐ mee on +447463563696 (UK phone, GMT tіme zone).

    Kind regards

    Sergy Greenfields
    Founder ߋf Creative Bearr Tech
    Flat 9, 1 Jardine Ꮢd, St Katharine’s & Wapping,
    London E1W 3WD, England
    https://creativebeartech.com

  2. Hello there! This is kind of off topic but I need some
    advice from an established blog. Is it hard to set up
    your own blog? I’m not very techincal but I can figure things out pretty fast.
    I’m thinking about creating my own but I’m not sure where to begin. Do you have any points or suggestions?
    Appreciate it

  3. Excellent post. I was checking constantly this weblog and I am impressed!
    Very useful information specially the ultimate part :) I
    care for such info a lot. I was looking for this particular information for a very
    lengthy time. Thanks and best of luck.

  4. Pretty component to content. I just stumbled upon your blog and in accession capital to
    assert that I acquire actually enjoyed account your blog posts.
    Any way I’ll be subscribing to your augment or even I
    achievement you access consistently rapidly.

  5. Hi would you mind stating which blog platform you’re
    working with? I’m going to start my own blog soon but I’m
    having a hard time making a decision between BlogEngine/Wordpress/B2evolution and Drupal.
    The reason I ask is because your layout seems different then most blogs and I’m looking for something
    unique. P.S My apologies for being off-topic but I had to ask!

  6. Hello! I’ve been following your web site for some
    time now and finally got the courage to go ahead and give you a shout out from Houston Texas!
    Just wanted to say keep up the great work!

  7. Thank you for any other informative blog. Where else may just
    I am getting that type of information written in such an ideal approach?
    I have a venture that I am simply now running on, and I have
    been on the glance out for such information.

  8. I think everything posted was very logical. But, think
    about this, suppose you typed a catchier title?
    I am not saying your information is not good.,
    but what if you added a post title that makes people desire more?
    I mean Fancy toast in android library + Source Code – Best Learning Platform
    is a little plain. You should glance at Yahoo’s front page and
    watch how they write post headlines to get viewers to click.
    You might add a related video or a related pic or two to grab readers excited about what you’ve written. Just my opinion, it might make your
    posts a little bit more interesting.

  9. Hi I am so delighted I found your webpage, I really found you by
    mistake, while I was browsing on Askjeeve for something else, Anyways I am here now and would
    just like to say cheers for a remarkable post and a all round enjoyable blog (I also love the theme/design), I don’t have time to
    go through it all at the moment but I have book-marked it and also included your RSS feeds,
    so when I have time I will be back to read much more, Please do keep up the awesome work.

  10. What i do not understood is in reality how you’re now not actually much more smartly-favored than you might be now.
    You are so intelligent. You already know therefore considerably in relation to this topic,
    produced me in my opinion consider it from numerous varied angles.
    Its like women and men aren’t interested except it’s something to do with Lady gaga!

    Your personal stuffs great. At all times deal with it up!

  11. Its like you learn my mind! You seem to know so much about this, like you wrote the e book in it or something.
    I feel that you simply can do with a few percent to pressure the message house a little bit, however instead of that, that is
    excellent blog. An excellent read. I’ll certainly be back.

  12. I really love your website.. Great colors & theme.
    Did you develop this website yourself? Please reply back as I’m trying to create my own personal blog and
    would love to learn where you got this from
    or just what the theme is called. Cheers!

  13. Chúng tôi chuyên thi công mài sàn bê tông, thi công hàng trăm công trình tại Đà Nẵng, là một địa phương phát triển, Đà Nẵng có rất nhiều công trình thương mại được xây dựng
    và sử dụng sàn bê tông đánh bóng
    Với đội ngũ công nhân viên đông đảo, tay nghề cao, đã qua trường lớp đào tạo nâng cao và sở hữu máy móc nhập khẩu nước ngoài, độ chắc chắn và thông số kỹ thuật tốt , giúp
    tăng tiến độ công việc, chi phí cạnh tranh, chất lượng dịch
    vụ được bảo đảm
    Để đáp lại những yêu mến mà khách hàng dành cho công ty thì chúng tôi đã phấn đấu hết mình để mang đến cho quý khách những
    dịch vụ chất lượng nhất với mức báo
    giá phải chăng nhất

  14. Chúng tôi đơn vị thi công có uy tín hàng đầu trong lĩnh vực mài sàn bê tông, có bề dày kinh nghiệm
    tại Đà Nẵng, là một khu vực phát
    triển, Đà Nẵng có rất nhiều cơ sở công nghiệp được xây dựng và sử
    dụng sàn bê tông mài bóng
    Với đội ngũ công nhân viên đông đảo, làm việc khoa học , đã qua trường lớp đào tạo nâng cao và
    sở hữu hệ thống máy móc tiên tiến cũng như là trang thiết bị và hóa chất nhập khẩu từ Châu u, giúp thời gian thi công đúng hẹn, giảm tối
    đa chi phí, chất lượng sản phẩm không hề thua kém
    Để đáp lại những yêu mến mà khách hàng dành cho công ty thì chúng tôi đã
    phấn đấu hết mình để mang đến cho khách hàng những dịch vụ chất lượng
    nhất với mức báo giá phù hợp nhất

  15. I simply could not go away your site before suggesting
    that I really enjoyed the usual info a person supply
    on your visitors? Is going to be again steadily in order to investigate
    cross-check new posts|
    I need to to thank you for this excellent read!!
    I certainly loved every bit of it. I have you bookmarked to check out new stuff you post? https://www.publissoft.com

  16. Greetings from Ohio! I?m bored to death at work so I decided to browse
    your blog on my iphone during lunch break. I really like the info you provide here and
    can?t wait to take a look when I get home.
    I?m amazed at how fast your blog loaded on my phone .. I?m not even using WIFI, just 3G
    .. Anyhow, wonderful site! http://www.osteopathy-canada.com

Leave a Reply

Your email address will not be published. Required fields are marked *

Back to top button
Close
Close

Adblock Detected

Please consider supporting us by disabling your ad blocker