Andicons

Android library for using font-based glyphs as Bitmaps and Drawables

License

License

GroupId

GroupId

io.github.eddieringle.android.libs.andicons
ArtifactId

ArtifactId

andicons
Last Version

Last Version

2.1.0
Release Date

Release Date

Type

Type

jar
Description

Description

Andicons
Android library for using font-based glyphs as Bitmaps and Drawables
Project URL

Project URL

https://github.com/eddieringle/andicons
Source Code Management

Source Code Management

https://github.com/eddieringle/andicons

Download andicons

How to add to project

<!-- https://jarcasting.com/artifacts/io.github.eddieringle.android.libs.andicons/andicons/ -->
<dependency>
    <groupId>io.github.eddieringle.android.libs.andicons</groupId>
    <artifactId>andicons</artifactId>
    <version>2.1.0</version>
</dependency>
// https://jarcasting.com/artifacts/io.github.eddieringle.android.libs.andicons/andicons/
implementation 'io.github.eddieringle.android.libs.andicons:andicons:2.1.0'
// https://jarcasting.com/artifacts/io.github.eddieringle.android.libs.andicons/andicons/
implementation ("io.github.eddieringle.android.libs.andicons:andicons:2.1.0")
'io.github.eddieringle.android.libs.andicons:andicons:jar:2.1.0'
<dependency org="io.github.eddieringle.android.libs.andicons" name="andicons" rev="2.1.0">
  <artifact name="andicons" type="jar" />
</dependency>
@Grapes(
@Grab(group='io.github.eddieringle.android.libs.andicons', module='andicons', version='2.1.0')
)
libraryDependencies += "io.github.eddieringle.android.libs.andicons" % "andicons" % "2.1.0"
[io.github.eddieringle.android.libs.andicons/andicons "2.1.0"]

Dependencies

There are no dependencies for this project. It is a standalone project that does not depend on any other jars.

Project Modules

There are no modules declared in this project.

Andicons

A neat little Android library for using font-based glyphs as drawables and bitmaps in your Android applications!

Built-in Support

Currently, the Andicons library provides the AndiconView class as well as support for the following glyph sets:

  • OcticonsSet -> Octicons
    • Will look for octicons_regular.ttf in your application's assets directory
  • FontAwesomeSet -> Font Awesome
    • Will look for fontawesome.ttf in your application's assets directory
  • Font Awesome More Sets -> Font Awesome More
    • FontAwesomeMoreExtSet
      • Will look for fontawesome_more_ext.ttf in your application's assets directory
    • FontAwesomeMoreSocialSet
      • Will look for fontawesome_more_social.ttf in your application's assets directory
    • FontAwesomeMoreCorpSet
      • Will look for fontawesome_more_corp.ttf in your application's assets directory

Using & Such

I'm a fan of git submodules (and IntelliJ), so in order to use this library I recommend adding this repository as a submodule of your encompassing project's repository:

git submodule add git://github.com/eddieringle/andicons contrib/andicons

Now add the Andicons library as a module in IntelliJ and add that module as a dependency of your project. You're then ready to start using Andicons!

Andicons does not provide the actual TrueType font files per se. It's up to you to get permission (if needed) to use these sets as well as track down the file for inclusion in your application. See the above section titled "Built-in Support" to see more details on specific filenames and locations.

You can add Andicons programmatically, or directly into layouts, like so:

<com.github.eddieringle.android.libs.andicons.AndiconView
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:textColor="@color/android_green"
        android:textSize="64sp"
        app:andicon_set="fontawesome"
        app:andicon_id="@integer/fontawesome_leaf" />

You can also set the andicon used by the AndiconView programmatically, for example:

andiconView.setAndicon(AndiconView.SET_FONTAWESOME, FontAwesomeSet.IC_LEAF);

The above would result in this (don't mind the other bits, I just threw this example into another application I'm working on because I was lazy):

Layout result

Versions

Version
2.1.0