Quick Navigator

Search Site

Unix VPS
A - Starter
B - Basic
C - Preferred
D - Commercial
MPS - Dedicated
Previous VPSs
* Sign Up! *

Contact Us
Online Help
Domain Status
Man Pages

Virtual Servers

Topology Map

Server Agreement
Year 2038

USA Flag



Man Pages

Manual Reference Pages  -  TEXT::FIGLET (3)

.ds Aq ’


Text::FIGlet - provide FIGlet abilities, akin to banner i.e; ASCII art



 my $font = Text::FIGlet-E<gt>new(-f=>"doh");
 $font->figify(-A=>"Hello World");


Text::FIGlet reproduces its input using large characters made up of other characters; usually ASCII, but not necessarily. The output is similar to that of many banner programs—although it is not oriented sideways—and reminiscent of the sort of signatures many people like to put at the end of e-mail and UseNet messages.

Text::FIGlet can print in a variety of fonts, both left-to-right and right-to-left, with adjacent characters kerned and smushed together in various ways. FIGlet fonts are stored in separate files, which can be identified by the suffix .flf. Most FIGlet font files will be stored in FIGlet’s default font directory /usr/local/share/figlet. Support for TOIlet fonts *.tlf, which are typically in the same location, has also been added.

Text::FIGlet can also use control files, which tell it to map input characters to others, similar to the Unix tr command. Control files can be identified by the suffix .flc. Most control files will be stored with the system fonts, as some fonts use control files to provide access to foreign character sets.


<B>-C=>B>controlfile Creates a control object. Text::File::Control for control object specific options to new, and how to use the object.
<B>-f=>B>fontfile | \@fonts | \%fonts Loads fontfile if specified, and creates a font object. Text::File::Font for font object specific options to new, and how to use the object.

With the other forms of <B>-fB>, a number of fonts can be loaded and blended into a single font as a Text::FIGlet::Ransom object.

<B>-d=>B>fontdir Whence to load files.

Defaults to /usr/local/share/figlet

fontfile and controlfile can be the (absolute or relative) path to the specified file, or simply the name of a file (with or without an extension) present in <B>-dB>.

new with no options will create a font object using the default font.


  perl -MText::FIGlet -e print ~~Text::FIGlet->new()->figify(-A=>"Hello World")

To generate headings for webserver directory listings, for that warm and fuzzy BBS feeling.

Text based clocks or counters at the bottom of web pages.

Anti-bot obfuscation a la AUTHOR.

    Other Things to Try

A variety of interesting effects can be obtained from dot-matrix-like fonts such as lean and block by passing them through tr. Hare are some to try:

  tr[ _/][ ()]
  tr[ _/][./\\]
  tr[ _/][ //]
  tr[ _/][/  ]

If you’re using FIGlet as some sort of CAPTCHA, or you’d just like a starry background for your text, you might consider adding noise to the results of figify e.g;

  #50% chance of replacing a space with an x
  s/( )/rand()>.5?$1:x/eg

  #50% chance of replacing a space with an entry from @F
  @F = qw/. x */; s/( )/$F[scalar@F*2*rand()]||$1/eg;

  #5% chance of substituting a random ASCII character
  #Note that this may yield unpleasant results if UTF is involved


<B>Text::FIGletB> will make use of these environment variables if present
FIGFONT The default font to load. If undefined the default is standard.flf. It should reside in the directory specified by FIGLIB.
FIGLIB The default location of fonts. If undefined the default is /usr/local/share/figlet


FIGlet font files and control files are available at


Module architecture: <>

Animated FIGlet: Acme::Curses::Marquee::Extensions

Ancestors: figlet(6) <>, banner(6), Text::Banner


If you are using perl 5.005 and wish to try to acces Unicode characters programatically, or are frustrated by perl 5.6’s Unicode support, you may try importing UTF8chr from this module.

This module also offers UTF8ord and UTF8len, which are used internally, but may be of general use. To import all three functions, use the <B>:EncodeB> import tag. UTF8len does not count control characters (0x00-0x19)!


Jerrad Pierce

                **                                    />>
     _         //                         _  _  _    / >>>
    (_)         **  ,adPPYba,  >< ><<<  _(_)(_)(_)  /   >>>
    | |        /** a8P_____88   ><<    (_)         >>    >>>
    | |  |~~\  /** 8PP"""""""   ><<    (_)         >>>>>>>>
   _/ |  |__/  /** "8b,   ,aa   ><<    (_)_  _  _  >>>>>>>
  |__/   |     /**  `"Ybbd8"  ><<<      (_)(_)(_) >>
               //                                  >>>>    /

Search for    or go to Top of page |  Section 3 |  Main Index

perl v5.20.3 TEXT::FIGLET (3) 2016-04-03

Powered by GSP Visit the GSP FreeBSD Man Page Interface.
Output converted with manServer 1.07.