grotty - groff driver for typewriter-like devices


   grotty [ -bBcdfhioruUv ] [ -Fdir ] [ files... ]

   It  is  possible  to  have  whitespace  between  the  -F option and its


   grotty translates the output of GNU troff  into  a  form  suitable  for
   typewriter-like  devices.   Normally  grotty should be invoked by using
   the groff command with a -Tascii, -Tlatin1 or -Tutf8  option  on  ASCII
   based  systems, and with -Tcp1047 and -Tutf8 on EBCDIC based hosts.  If
   no files are given, grotty reads the standard input.  A filename  of  -
   also  causes  grotty  to read the standard input.  Output is written to
   the standard output.

   By default, grotty emits SGR escape  sequences  (from  ISO  6429,  also
   called  ANSI  color  escapes)  to change text attributes (bold, italic,
   colors).  This makes it possible to have eight different background and
   foreground colors; additionally, bold and italic attributes can be used
   at the same time (by using the BI font).

   The following colors are defined in tty.tmac: black, white, red, green,
   blue,  yellow, magenta, cyan.  Unknown colors are mapped to the default
   color (which is dependent on the settings  of  the  terminal;  in  most
   cases, this is black for the foreground and white for the background).

   Use  the  -c  switch  to  revert  to the old behaviour, printing a bold
   character c with the sequence `c BACKSPACE c' and an italic character c
   by  the  sequence  `_  BACKSPACE c'.  At the same time, color output is
   disabled.  The same effect  can  be  achieved  by  setting  either  the
   GROFF_NO_SGR  environment  variable  or  using the 'sgr' X command (see

   For SGR support, it is necessary to use the -R  option  of  less(1)  to
   disable   the   interpretation   of   grotty's   old   output   format.
   Consequently, all programs which use less as the pager program have  to
   pass this option to it.  For man(1) in particular, either add -R to the
   $PAGER environment variable, e.g.

          PAGER="/usr/bin/less -R"
          export PAGER

   or use the -P option of  man  to  set  the  pager  executable  and  its
   options,  or modify the configuration file of man in a similar fashion.
   Note that with some man(1) versions, you  have  to  use  the  $MANPAGER
   environment variable instead.

   grotty's  old  output  format  can be displayed on a terminal by piping
   through ul(1).  Pagers such as more(1) or  less(1)  are  also  able  to
   display these sequences.  Use either -B or -U when piping into less(1);
   use -b when piping into more(1).  There is no need to filter the output
   through col(1) since grotty never outputs reverse line feeds.

   The font description file may contain a command

          internalname n

   where n is a decimal integer.  If the 01 bit in n is set, then the font
   is treated as an italic font; if the 02 bit is set, then it is  treated
   as a bold font.  The code field in the font description field gives the
   code which is used to output the character.  This code can also be used
   in the \N escape sequence in troff.

   If  the  DESC  file  contains the keyword unicode, grotty emits Unicode
   characters in UTF-8 encoding.  Otherwise,  it  emits  characters  in  a
   single-byte  encoding  depending  on  the  data in the font description
   files.  See the groff_font(5) man page for more details.


   -b     Suppress the use of overstriking for bold  characters.   Ignored
          if -c isn't used.

   -B     Use only overstriking for bold-italic characters.  Ignored if -c
          isn't used.

   -c     Use grotty's old output format (see above).  This also  disables
          color output.

   -d     Ignore  all  \D  commands.  Without this grotty renders \D'l...'
          commands that have at least one zero argument (and so are either
          horizontal  or  vertical)  using  -,  |, and + characters.  In a
          similar way, grotty  handles  \D'p...'  commands  which  consist
          entirely of horizontal and vertical lines.

   -f     Use  form feeds in the output.  A form feed is output at the end
          of each page that has no output on its last line.

   -Fdir  Prepend directory dir/devname to the search path  for  font  and
          device  description  files;  name  is  the  name  of the device,
          usually ascii, latin1, utf8, or cp1047.

   -h     Use horizontal tabs in the output.  Tabs are assumed to  be  set
          every 8 columns.

   -i     Use escape sequences to set the italic text attribute instead of
          the underline attribute for italic fonts ('I' and  'BI').   Note
          that  most  terminals  (including  xterm)  don't  support  this.
          Ignored if -c is active.

   -o     Suppress  overstriking  (other  than  for  bold  or   underlined
          characters in case the old output format has been activated with

   -r     Use escape sequences to set the reverse text  attribute  instead
          of  the  underline  attribute  for  italic fonts ('I' and 'BI').
          Ignored if -c is active.

   -u     Suppress the use of underlining for italic characters.   Ignored
          if -c isn't used.

   -U     Use  only underlining for bold-italic characters.  Ignored if -c
          isn't used.

   -v     Print the version number.


   grotty understands a single X command  produced  using  the  \X  escape

   \X'tty: sgr n'
          If  n  is  non-zero  or  missing, enable SGR output (this is the
          default), otherwise use the old  drawing  scheme  for  bold  and


          If set, the old drawing scheme for bold and underline (using the
          backspace character) is active.  Colors are disabled.

          A list of  directories  in  which  to  search  for  the  devname
          directory  in  addition  to  the default ones.  See troff(1) and
          groff_font(5) for more details.


          Device description file for ascii device.

          Font description file for font F of ascii device.

          Device description file for latin1 device.

          Font description file for font F of latin1 device.

          Device description file for utf8 device.

          Font description file for font F of utf8 device.

          Device description file for cp1047 device.

          Font description file for font F of cp1047 device.

          Macros for use with grotty.

          Additional kludgy character definitions for use with grotty.

   Note that on  EBCDIC  hosts,  only  files  for  the  cp1047  device  is


   grotty is intended only for simple documents.

   There is no support for fractional horizontal or vertical motions.

   There  is no support for \D commands other than horizontal and vertical

   Characters above the first line (i.e. with a vertical  position  of  0)
   cannot be printed.

   Color  handling  is different compared to grops(1).  \M doesn't set the
   fill color for closed graphic objects  (which  grotty  doesn't  support
   anyway)  but  changes  the  background  color  of  the  character cell,
   affecting all subsequent operations.


   groff(1), troff(1), groff_out(5), groff_font(5), groff_char(7),  ul(1),
   more(1), man(1), less(1)


   Copyright  1989-2014 Free Software Foundation, Inc.

   Permission  is  granted  to make and distribute verbatim copies of this
   manual provided the copyright notice and  this  permission  notice  are
   preserved on all copies.

   Permission  is granted to copy and distribute modified versions of this
   manual under the conditions for verbatim  copying,  provided  that  the
   entire  resulting  derived  work  is  distributed  under the terms of a
   permission notice identical to this one.

   Permission is granted to  copy  and  distribute  translations  of  this
   manual  into  another language, under the above conditions for modified
   versions, except  that  this  permission  notice  may  be  included  in
   translations approved by the Free Software Foundation instead of in the
   original English.


Personal Opportunity - Free software gives you access to billions of dollars of software at no cost. Use this software for your business, personal use or to develop a profitable skill. Access to source code provides access to a level of capabilities/information that companies protect though copyrights. Open source is a core component of the Internet and it is available to you. Leverage the billions of dollars in resources and capabilities to build a career, establish a business or change the world. The potential is endless for those who understand the opportunity.

Business Opportunity - Goldman Sachs, IBM and countless large corporations are leveraging open source to reduce costs, develop products and increase their bottom lines. Learn what these companies know about open source and how open source can give you the advantage.

Free Software

Free Software provides computer programs and capabilities at no cost but more importantly, it provides the freedom to run, edit, contribute to, and share the software. The importance of free software is a matter of access, not price. Software at no cost is a benefit but ownership rights to the software and source code is far more significant.

Free Office Software - The Libre Office suite provides top desktop productivity tools for free. This includes, a word processor, spreadsheet, presentation engine, drawing and flowcharting, database and math applications. Libre Office is available for Linux or Windows.

Free Books

The Free Books Library is a collection of thousands of the most popular public domain books in an online readable format. The collection includes great classical literature and more recent works where the U.S. copyright has expired. These books are yours to read and use without restrictions.

Source Code - Want to change a program or know how it works? Open Source provides the source code for its programs so that anyone can use, modify or learn how to write those programs themselves. Visit the GNU source code repositories to download the source.


Study at Harvard, Stanford or MIT - Open edX provides free online courses from Harvard, MIT, Columbia, UC Berkeley and other top Universities. Hundreds of courses for almost all major subjects and course levels. Open edx also offers some paid courses and selected certifications.

Linux Manual Pages - A man or manual page is a form of software documentation found on Linux/Unix operating systems. Topics covered include computer programs (including library and system calls), formal standards and conventions, and even abstract concepts.