From a3545635140c6b503d776c6374ca69188b54b31a Mon Sep 17 00:00:00 2001 From: Aaron LI Date: Mon, 15 Oct 2018 12:42:04 +0800 Subject: fontawesome5: Update the generation script a bit --- fontawesome5/make-fontawesome5.py | 23 +++++++++++++---------- 1 file changed, 13 insertions(+), 10 deletions(-) (limited to 'fontawesome5') diff --git a/fontawesome5/make-fontawesome5.py b/fontawesome5/make-fontawesome5.py index 88a8064..0c26f30 100755 --- a/fontawesome5/make-fontawesome5.py +++ b/fontawesome5/make-fontawesome5.py @@ -46,38 +46,41 @@ STY_TEMPLATE = """%% %% %% Usage %% ----- -%% 1. \\usepackage{fontawesome} %% default to *solid* style +%% 1. \\usepackage{fontawesome} %% Prefer *Solid* style by default %% or -%% \\usepackage[regular]{fontawesome} %% use *regular* style +%% \\usepackage[regular]{fontawesome} %% Prefer *Regular* style +%% +%% NOTE: +%% The *Solid* style has much more icons than the *Regular* style. +%% If one style doesn't have one icon, it fallbacks to the other style. +%% %% 2. use an icon, e.g., \\faGitHub %% \\NeedsTeXFormat{LaTeX2e}[1994/06/01] \\ProvidesPackage{fontawesome5}[%(date)s Font Awesome 5] -\\RequirePackage{fontspec} - \\DeclareOption{regular}{\\def\\FA@regular{true}} \\ProcessOptions\\relax +\\RequirePackage{fontspec} + %% Declare all variants %% Solid (default) \\newfontfamily\\FontAwesomeSolid[ - BoldFont=Font Awesome 5 Free Solid, + BoldFont={Font Awesome 5 Free Solid}, ]{Font Awesome 5 Free Solid} %% Regular \\newfontfamily\\FontAwesomeRegular[ - BoldFont=Font Awesome 5 Free, + BoldFont={Font Awesome 5 Free}, ]{Font Awesome 5 Free} %% Brands \\newfontfamily\\FontAwesomeBrands[ - BoldFont=Font Awesome 5 Brands, + BoldFont={Font Awesome 5 Brands}, ]{Font Awesome 5 Brands} %% Generic command displaying an icon by its name -\\newcommand*{\\faicon}[1]{{ - \FA\csname faicon@#1\endcsname -}} +%% \\newcommand*{\\faicon}[1]{{\FA\csname faicon@#1\endcsname}} %% Mappings %(mappings)s -- cgit v1.2.2