Making Pictures With GNU PIC
Eric S. Raymond
〈******@snark.〉
ABSTRACT
The pic language is a troff extension that makes it easy to create and alter box-and-
arrowdiagrams of the kind frequently used in technical papers and textbooks. This paper
is both an introduction to and reference for gpic(1), the implementation distributed by the
Free Software Foundation for use with groff (1). It also catalogs other implementations
and explains the differences among them.
1. Introduction to PIC
. WhyPIC?
The pic language provides an easy way to write procedural box-and-arrowdiagrams to be included in
troff documents. The language is sufficiently flexible to be quite useful for state charts, diagrams,
flowcharts, simple circuit schematics, jumper layouts, and other kinds of illustration involving repetitive
uses of simple geometric forms and splines. Because these descriptions are procedural and object-based,
theyare pact and easy to modify.
The phrase “GNU pic” may refer to either of two pic implementations distributed by the Free Soft-
ware Foundation and intended to accept the same input language. The gpic(1) implementation is for use
with the groff (1) implementation of pic2plot(1) implementation runs standalone and is part of
the plotutils package. Because both implementations are widely available in source form for free, theyare
good bets for writing very portable documentation.
. PIC Versions
The original 1984 pre-ditroff (1) version of pic is long obsolete. The rewritten 1991 version is still
available as part of the Documenter’sWork Bench module of System V.
Where differences between Documenter’sWork Bench (1991) pic and GNU pic need to be
described, original pic is referred to as “DWB pic”. Details on the history of the program are givenatthe
end of this document.
The pic2plot program does not require the rest of the groff (1) toolchain to render graphics. It can
display pic diagrams in a X window, orgenerate outp
pic--古老而有用的画图工具 来自淘豆网www.taodocs.com转载请标明出处.