diff options
author | wl <wl> | 2007-11-19 09:28:44 +0000 |
---|---|---|
committer | wl <wl> | 2007-11-19 09:28:44 +0000 |
commit | 5291a235c550b0b9304a0b8db5069f9045b6dbf4 (patch) | |
tree | 492b16e8fc3ad23fdeaf75372cf17952c2c2fe4b /doc | |
parent | 2bfcebf32711adf0f7579ca08b3ad843e6145ce9 (diff) | |
download | groff-5291a235c550b0b9304a0b8db5069f9045b6dbf4.tar.gz |
* src/groff/preproc/pic/lex.cpp (table): Add box attributes
`xslanted' and `yslanted'.
* src/groff/preproc/pic/object.cpp (object_spec::object_spec):
Initialize `xslanted' and `yslanted'.
(graphic_object): Add methods `set_xlanted' and `set_yslanted'.
(closed_object): Ditto.
Add members `xslanted' and `yslanted'.
(box_object::print): Use them.
(object_spec::make_object): Handle slant values.
* src/groff/preproc/pic/object.h (IS_XSLANTED, IS_YSLANTED): New
constants.
(object_spec): Add members `xslanted' and `yslanted'.
* src/groff/preproc/pic/pic.y (XSLANTED, YSLANTED): New left-valued
tokens.
Add rules for them.
* src/groff/preproc/pic/pic.man, NEWS, doc/pic.ms: Document above
changes.
Diffstat (limited to 'doc')
-rw-r--r-- | doc/pic.ms | 28 |
1 files changed, 24 insertions, 4 deletions
@@ -31,7 +31,7 @@ .\" Eric S. Raymond <esr@thyrsus.com> in August 1995. It has been put .\" under the GPL in March 2006. .\" -.\" $Id: pic.ms,v 1.35 2007/03/21 13:30:59 wl Exp $ +.\" $Id: pic.ms,v 1.36 2007/11/19 09:28:44 wl Exp $ . . .\" Set a proper TeX and LaTeX @@ -635,6 +635,24 @@ Radius values higher than half the minimum box dimension are silently truncated to that value. . .NH 2 +Slanted Boxes +.PP +GNU \fBgpic\fP supports slanted boxes: +.KS +.PS +box wid 1.2 xslanted 0.1 "xslanted 0.1"; +move; +box wid 1.2 yslanted -0.1 "yslanted -0.1"; +move; +box wid 1.2 xslanted -0.2 yslanted 0.1 "xslanted -0.2" "yslanted 0.1"; +.PE +.CE "4: Various slanted boxes. +.PP +The \fBxslanted\fP and \fByslanted\fP attributes specify the x and +y\~offset, respectively, of the box's upper right corner from its default +position. +. +.NH 2 Arrowheads .PP Lines and arcs can be decorated as well. Any line or arc (and any @@ -644,7 +662,7 @@ as modifiers: .PS line <- -> .PE -.CE "4: Double-headed line made with \fBline <- ->\fP" +.CE "5: Double-headed line made with \fBline <- ->\fP" .PP In fact, the \fBarrow\fP command is just shorthand for \fBline ->\fP. And there is a double-head modifier <->, so the figure above could have been made @@ -710,7 +728,7 @@ values are darker; GNU \fBfillval\fP uses 0 for white and 1 for black. .PS circle fill; move; circle fill 0.4; move; circle fill 0.9; .PE -.CE "5: \fBcircle fill; move; circle fill 0.4; move; circle fill 0.9;\fR" +.CE "6: \fBcircle fill; move; circle fill 0.4; move; circle fill 0.9;\fR" .PP GNU \fBgpic\fP makes some additional guarantees. A fill value greater than 1 can also be used: this means fill with the shade of gray that @@ -735,7 +753,7 @@ suffix specifying the color. Example: .PS box color "yellow"; arrow color "cyan"; circle shaded "green" outline "black"; .PE -.CE "6: \fBbox color ""yellow""; arrow color ""cyan""; \ +.CE "7: \fBbox color ""yellow""; arrow color ""cyan""; \ circle shaded ""green"" outline ""black"";\fR" .PP Alternative spellings are \fBcolour\fP, \fBcolored\fP, \fBcoloured\fP, @@ -2673,6 +2691,8 @@ direction on the block's bounding box. invis[ible] \fR# make primitive invisible\fP solid \fR# make closed figure solid\fP fill[ed] [<expr>] \fR# set fill density for figure\fP + xscaled <expr> \fR# slant box into x direction\fP + yscaled <expr> \fR# slant box into y direction\fP colo[u]r[ed] TEXT \fR# set fill and outline color for figure\fP outline[d] TEXT \fR# set outline color for figure\fP shaded TEXT \fR# set fill color for figure\fP |