Skip to content

Enaium/xicons

Repository files navigation

XIcons

English | δΈ­ζ–‡

XIcons is a powerful Java icon library collection that provides Java implementations of multiple popular icon libraries, supporting both Swing and JavaFX UI frameworks.

✨ Features

  • 🎨 Multiple Icon Library Support: Includes popular icon libraries such as Fluent, Antd, Carbon, Font Awesome, Ionicons, Material Design, Tabler, and more
  • πŸ–₯️ Dual Framework Support: Supports both Swing and JavaFX applications

πŸ“š Supported Icon Libraries

Fluent Icons

  • Regular Icons
  • Filled Icons

Ant Design Icons

  • Filled Icons
  • Outlined Icons
  • Twotone Icons

Carbon Icons

  • Default Icons
  • Filled Icons
  • Round Icons

Font Awesome Icons

  • Default Icons
  • Regular Icons

Ionicons

  • Ionicons 4 Default Icons
  • Ionicons 5 Default Icons
  • Ionicons 5 Sharp Icons

Material Design Icons

  • Filled Icons
  • Outlined Icons
  • Round Icons
  • Sharp Icons
  • Twotone Icons

Tabler Icons

  • Default Icons
  • Filled Icons
  • Sharp Icons

πŸ–ΌοΈ Preview

swing jfx

πŸ“¦ Installation

You need to use the corresponding icon classifier:

  • all - All Icons
  • antd - Ant Design Icons
  • carbon - Carbon Icons
  • fa - Font Awesome Icons
  • fluent - Fluent Icons
  • ionicons4 - Ionicons 4
  • ionicons5 - Ionicons 5
  • material - Material Design Icons
  • tabler - Tabler Icons

Maven

Add the following dependencies to your pom.xml file:

Swing Version

<dependency>
    <groupId>cn.enaium.xicons</groupId>
    <artifactId>xicons-swing</artifactId>
    <version>1.0.0</version>
    <classifier>fluent</classifier>
</dependency>

JavaFX Version

<dependency>
    <groupId>cn.enaium.xicons</groupId>
    <artifactId>xicons-jfx</artifactId>
    <version>1.0.0</version>
    <classifier>fluent</classifier>
</dependency>

Gradle

Add the following dependencies to your build.gradle file:

Swing Version

implementation 'cn.enaium.xicons:xicons-swing:1.0.0:fluent'

JavaFX Version

implementation 'cn.enaium.xicons:xicons-jfx:1.0.0:fluent'

Or in Kotlin DSL (build.gradle.kts):

Swing Version

implementation("cn.enaium.xicons:xicons-swing:1.0.0:fluent")

JavaFX Version

implementation("cn.enaium.xicons:xicons-jfx:1.0.0:fluent")

🧩 Kotlin Multiplatform Support

XIcons also supports Kotlin Multiplatform projects. You can add the following dependency in your build.gradle.kts:

kotlin {
    sourceSets {
        val commonMain by getting {
            dependencies {
                implementation("cn.enaium.xicons:xicons-compose-fluent:1.0.0")
            }
        }
    }
}

πŸ’» Usage

In Swing Applications

import cn.enaium.xicons.swing.icons.FluentIcons;
import javax.swing.*;

// Using Regular icons
JLabel label = new JLabel(FluentIcons.Regular.AnimalDog);

// Using Filled icons
JButton button = new JButton(FluentIcons.Filled.AnimalDog);

In JavaFX Applications

import cn.enaium.xicons.jfx.icons.FluentIcons;
import javafx.scene.control.Label;

// Using Regular icons
Label label = new Label("Dog", FluentIcons.Regular.AnimalDog);

// Using Filled icons
Button button = new Button("Dog", FluentIcons.Filled.AnimalDog);

In Kotlin Multiplatform Applications

import cn.enaium.xicons.compose.FluentIcons
import cn.enaium.xicons.compose.fluent.AnimalDog

// Using Regular icons
Icon(FluentIcons.Regular.AnimalDog, contentDescription = null)

// Using Filled icons
Icon(FluentIcons.Filled.AnimalDog, contentDescription = null)

πŸ™ Acknowledgments

Thanks to the following open-source projects for providing icon resources:


⭐ If this project helps you, please give it a star!

About

Support fluentui system icons, ionicons, ant design icons, material design icons, font awesome, tabler icons and carbon icons.

Topics

Resources

License

Stars

3 stars

Watchers

0 watching

Forks

Releases

No releases published

Packages

 
 
 

Contributors