SetImageBorderType

SetImageBorderType — Draw a border around the image

Synopsis

$plot->SetImageBorderType($sibt)

Description

SetImageBorderType controls the drawing of a border around the entire image. By default, no border is drawn.

Parameters

$sibt

A string indicating the desired border type: 'raised', 'plain', 'solid', or 'none'. Use 'none' to revert to the default of no border. Use 'solid' for a border drawn with the specified color. Use 'plain' for a border drawn with a darker shade of the specified color. Use 'raised' for a border that appears to raise the image, by drawing the top and left sides with the specified color and the bottom and right sides with a darker shade of the specified color.

Notes

The base color for the image border is set with SetImageBorderColor. Either that color, a darker shade of that color, or both are used to draw the border, as described above.

The image border width can be set with SetImageBorderWidth. The default width is 1 pixel for types 'plain' and 'solid', and 2 pixels for 'raised'.

It can be useful to have a border drawn around images when embedded in an HTML page. An alternative to this function is to use the BORDER attribute in the IMG tag when embedding the image.

History

Through PHPlot-5.1.1, the choices were 'none', 'plain' for a 1 pixel wide border using the darker shade, or 'raised' for a 2 pixel wide border using the specified color for the top and left sides and a darker shade for the bottom and right. There was no way to control the border width. Starting with PHPlot-5.1.2, a new choice 'solid' was added to use the exact color specified with SetImageBorderColor rather than using the darker shade like 'plain' uses (which may have been a bug). A new function SetImageBorderWidth was added to control the border width.

Use of 'none' to turn the border off was added in PHPlot-5.1.0.

SourceForge.net Logo

This version of the manual was produced for the PHPlot Sourceforge project web service site, which requires the logo on each page.

To download a logo-free copy of the manual, see the PHPlot project downloads area.