From: erg Date: Tue, 15 Apr 2008 17:20:25 +0000 (+0000) Subject: Add source for info pages to CVS X-Git-Tag: LAST_LIBGRAPH~32^2~4311 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=4ca96b5e0c83f0d2cbff4bdc56354e8cb6109752;p=graphviz Add source for info pages to CVS --- diff --git a/doc/infosrc/html.2 b/doc/infosrc/html.2 new file mode 100644 index 000000000..b75f13349 --- /dev/null +++ b/doc/infosrc/html.2 @@ -0,0 +1,329 @@ + +

+Above, a string is any collection of printable characters, including +all spaces. Note that outside of the body of a <TD> element, +whitespace characters are ignored; within a <TD> element, spaces +are preserved but all other white space characters are discarded. +HTML comments are allowed within an HTML string. They can occur anywhere +provided that, if they contain part of an HTML element, they must contain +the entire element. +

+As is obvious from the above description, the interpretation of white space +characters is one place where HTML-like labels is very different from +standard HTML. In HTML, any sequence of white space characters is +collapsed to a single space, If the user does not want this to happen, the +input must use non-breaking spaces "&nbsp;". This makes sense in +HTML, where text layout depends dynamically on the space available. In +Graphviz, the layout is statically determined by the input, so it is +reasonable to treat ordinary space characters as non-breaking. In addition, +ignoring tabs and newlines allows the input text to be formatted for +easier reading. +

+Each of the HTML elements has a set of optional attributes. +Attribute values must appear in double quotes. +

<TABLE
+  ALIGN="CENTER|LEFT|RIGHT"
+  BGCOLOR="color"
+  BORDER="value"
+  CELLBORDER="value"
+  CELLPADDING="value"
+  CELLSPACING="value"
+  FIXEDSIZE="FALSE|TRUE"
+  HEIGHT="value"
+  HREF="value"
+  PORT="portName"
+  TARGET="value"
+  TITLE="value"
+  TOOLTIP="value"
+  VALIGN="MIDDLE|BOTTOM|TOP"
+  WIDTH="value"
+>
+
+

+

<TD
+  ALIGN="CENTER|LEFT|RIGHT|TEXT"
+  BALIGN="CENTER|LEFT|RIGHT"
+  BGCOLOR="color"
+  BORDER="value"
+  CELLPADDING="value"
+  CELLSPACING="value"
+  COLSPAN="value"
+  FIXEDSIZE="FALSE|TRUE"
+  HEIGHT="value"
+  HREF="value"
+  PORT="portName"
+  ROWSPAN="value"
+  TARGET="value"
+  TITLE="value"
+  TOOLTIP="value"
+  VALIGN="MIDDLE|BOTTOM|TOP"
+  WIDTH="value"
+>
+
+ +

+

<FONT
+  COLOR="color"
+  FACE="fontname"
+  POINT-SIZE="value"
+>
+
+ +

+

<BR
+  ALIGN="CENTER|LEFT|RIGHT"
+>
+
+ +

+

<IMG
+  SCALE="FALSE|TRUE|WIDTH|HEIGHT|BOTH"
+  SRC="value"
+>
+
+ +

+ALIGN +

+specifies horizontal placement. When an object is allocated +more space than required, this value determines where the extra space +is placed left and right of the object. +

+

+

+The contents of a cell are normally aligned as a block. In particular, +lines of text are first aligned as a text block based on the width of +the widest line and the corresponding <BR> elements. Then, +the entire text block is aligned within a cell. If, however, the +cell's ALIGN value is "TEXT", and the cell contains +lines of text, then the lines are justified using the entire available +width of the cell. If the cell does not contain text, then the contained +image or table is centered. +

+ +BALIGN +
+specifies the default alignment of <BR> elements contained +in the cell. That is, if a <BR> element has no +explicit ALIGN attribute, the attribute value is specified +by the value of BALIGN. +
+ +BGCOLOR="color" +
+sets the color of the background. This color can be +overridden by a BGCOLOR attribute in descendents. +
+ +BORDER="value" +
+specifies the width of the border around the object in points. +A value of zero indicates no border. The default is 1. +The maximum value is 255. +If set in a table, and CELLBORDER is not set, +this value is also used for all cells in the table. +It can be overridden by a BORDER tag in a cell. +
+ +CELLBORDER="value" +
+specifies the width of the border for all cells in a table. +It can be overridden by a BORDER tag in a cell. +The maximum value is 255. +
+ +CELLPADDING="value" +
+specifies the space, in points, between a cell's border and its content. +The default is 2. +The maximum value is 255. +
+ +CELLSPACING="value" +
+specifies the space, in points, between cells in a table and between +a cell and the table's border. The default is 2. +The maximum value is 127. +
+ +COLOR="color" +
+sets the color of the font within the scope of +<FONT>...</FONT>. +This color can be +overridden by a COLOR attribute in descendents. +By default, the font color is determined by the +fontcolor attribute of +the corresponding node, edge or graph. +
+ +COLSPAN="value" +
+specifies the number of columns spanned by the cell. The default is 1. +The maximum value is 65535. +
+ +FACE="fontname" +
+specifies the font to use within the scope of +<FONT>...</FONT>. +This can be +overridden by a FACE attribute in descendents. +By default, the font name is determined by the +fontname attribute of the corresponding +node, edge or graph. +
+ +FIXEDSIZE +
+specifies whether the values given by the WIDTH +and HEIGHT attributes are enforced. +

+

+
+ +HEIGHT="value" +
+specifies the mininum height, in points, of the object. The height +includes the contents, any spacing and the border. Unless +FIXEDSIZE is true, the height will be expanded to allow +the contents to fit. +The maximum value is 65535. +
+ +HREF="value" +
+attaches a URL to the object. +
+ +POINT-SIZE="value" +
+sets the size of the font, in points, used within the scope of +<FONT>...</FONT>. +This can be +overridden by a POINT-SIZE attribute in descendents. +By default, the font name is determined by the +fontsize attribute of the corresponding +node, edge or graph. +
+ +PORT="value" +
+attaches a portname to the object. +(See portPos.) +This can be used to modify the head +or tail of an edge, so that the end attaches directly to the object. +
+ +ROWSPAN="value" +
+specifies the number of rows spanned by the cell. The default is 1. +The maximum value is 65535. +
+ +SCALE +
+specifies how an image will use any extra space available in its cell. +Allowed values are + +If this attribute is undefined, +the image inherits the imagescale +attribute of the graph object being drawn. +As with the imagescale +attribute, if the cell has a fixed size and the image is too large, +any offending dimension will be shrunk to fit the space, the +scaling being uniform in width and height if SCALE="true". +
+ +SRC="value" +
+specifies the image file to be displayed in the cell. +Note that if the software is used as a web server, file system access +to images is more restricted. See GV_FILE_PATH +and SERVER_NAME. +
+ +TARGET="value" +
+determines which window of the browser is used for the URL if the object +has one. +See W3C documentation. +
+ +TITLE="value" +
+sets the tooltip annotation attached to the element. +This is used only if the element has a HREF attribute. +
+ +TOOLTIP="value" +
+is an alias for TITLE. +
+ +

+VALIGN +

+specifies vertical placement. When an object is allocated +more space than required, this value determines where the extra space +is placed above and below the object. +

+

+
+ +WIDTH="value" +
+specifies the mininum width, in points, of the object. The width +includes the contents, any spacing and the border. Unless +FIXEDSIZE is true, the width will be expanded to allow +the contents to fit. +The maximum value is 65535. +
+ +

+There is some inheritance among the attributes. If a table specifies +a CELLPADDING, CELLBORDER or BORDER +value, this value is used by the table's +cells unless overridden. If a cell or table specifies a BGCOLOR, +this will be the background color for all of its descendents. +Of course, if a background or fill color is specified for the +graph object owning the label, this will be the original +background for the label. +The object's fontname, fontcolor and fontsize attributes +are the default for drawing text. These can be overridden by using +FONT to set new values. The new font values will hold +until overridden by an enclosed FONT element. +Finally, the pencolor or color of the graph object will be used as +the border color. +

+Because of certain limitations in handling tables in a device-independent +manner, when BORDER is 1 and both table and cell borders +are on and CELLSPACING is less than 2, anomalies can arise +in the output, such as gaps between sides of borders which should be +abutting or even collinear. The user can usual get around this by increasing +the border size or the spacing, or turning off the table border. +

+As an example of HTML labels, the dot input +