패키지, 저장소 및 앱 카테고리 검색

GitHub 저장소priyomukul/icofont_flutter

icofont_flutter

Flutter용으로 바로 사용할 수 있는 IconData 상수로 2,105개의 IcoFont 아이콘. null 안전, Dart 3 대응, Flutter 외에 의존성 없음.

icofont_flutter 프로젝트 이미지
스타
15
포크
4
최근 푸시(UTC)
2026. 9. 14.
프로젝트 상태
활성

원본 README

아래는 영문 원문 스냅샷입니다. 최신 내용은 GitHub에서 확인하세요.

icofont_flutter

pub package CI license: MIT

The IcoFont icon pack as a Flutter icon pack — 2,105 icons exposed as IconData constants, usable anywhere Flutter takes an icon.

No dependencies beyond Flutter itself. The font ships with the package, so there is nothing to declare in your own pubspec.yaml beyond the package.

Installation

flutter pub add icofont_flutter

Or add it to the dependencies: section of your pubspec.yaml:

dependencies:
  icofont_flutter: ^1.5.0

Usage

Every icon is a static const IconData on IcoFontIcons, so it works with any widget that accepts an IconData:

import 'package:flutter/material.dart';
import 'package:icofont_flutter/icofont_flutter.dart';

class MyWidget extends StatelessWidget {
  const MyWidget({Key? key}) : super(key: key);

  @override
  Widget build(BuildContext context) {
    return IconButton(
      icon: const Icon(IcoFontIcons.brandIcofont),
      onPressed: () => debugPrint('Pressed'),
    );
  }
}

Size and color come from the usual Icon properties:

const Icon(IcoFontIcons.rocket, size: 48, color: Colors.indigo)
Finding an icon

Browse the pack at icofont.com/icons. An icon's name there maps to a constant by camel casing it:

IcoFont name Constant
angry-monster IcoFontIcons.angryMonster
brand-icofont IcoFontIcons.brandIcofont
ui-calculator IcoFontIcons.uiCalculator
500px IcoFontIcons.fiveHundredpx

Names that would start with a digit are spelled out, since Dart identifiers cannot. lib/icofont_flutter.dart lists every constant with its IcoFont name in a comment above it.

The 324 duotone icons are not currently available — they are drawn as pairs of stacked glyphs, which the single-IconData API here cannot express.

Requirements

Dart >=2.12.0 <4.0.0, Flutter >=1.17.0. Works on Dart 2 and Dart 3.

Example

See example/ for a small app that renders icons from the pack:

cd example
flutter run

Updating the icons

lib/icofont_flutter.dart is generated from lib/fonts/icofont.ttf — do not edit it by hand. After replacing the font, regenerate:

dart run tool/generate_icons.dart

The generator reads glyph names from the font's post table and code points from its cmap table. It refuses to guess a name it cannot derive, so if it reports a problem, add the icon to nameOverrides in the script rather than editing the output. CI runs dart run tool/generate_icons.dart --check to verify the committed file still matches the font.

Credits

Icons by the IcoFont team, who made this wonderful pack free for everyone. This package only wraps their work for Flutter.

License

MIT — see LICENSE.

Priyo Mukul GitHub avatar
GitHub 작성자

Priyo Mukul ↗

Programmer with a Mysterious Lazy Mind!

@CoderExpert, @WPDevelopersDhaka, Bangladesh공식 웹사이트 ↗
언어DartObjective-CJava

분류

이 저장소가 배포한 패키지

사용 중인 의존성

의존성 목록 1 개

  • flutter{"sdk":"flutter"}

프로젝트에 맞는 저장소를 선택하려면?

사용 목적에 따라 검색하고 개발 활동을 비교한 뒤 원본 저장소에서 요구 사항을 확인하세요.

  1. 이름, 작성자 또는 설명으로 검색하고 기술 주제로 범위를 좁힙니다.
  2. 스타, 포크, 최근 푸시를 함께 비교하세요. 스타는 관심의 지표이며 품질을 보장하지 않습니다.
  3. 사용하기 전에 GitHub에서 README, 라이선스, Issues를 확인하세요.

출처 및 관리

“A repository is the most basic element of GitHub.”

GitHub Docs — About repositories ↗