![]() ![]() |
The image element describes an image item having any of the following formats:
The Image element properties determine the display size of the image in one of the two following ways:
You can get an image into a report in any of the following ways:
The Image element supports line images. A line image is an image that is repeated to form a line. For example, a slice of an image can repeat to form a custom border along the top or side of a report. Repetition can occur in both the horizontal and vertical directions.
The image element provides a number of options for handling images that are larger or smaller than the size of the element itself, including the following options
The following table shows which properties apply to each image source type.
Property
|
Embedded
|
File
|
URL
|
Computed
|
---|---|---|---|---|
Image name
|
Y
|
N
|
N
|
N
|
URI
|
N
|
Y
|
Y
|
N
|
Value Expression
|
N
|
N
|
N
|
Y
|
Type expression
|
N
|
N
|
N
|
Y
|
Size
|
Y
|
Y
|
Y
|
Y
|
DesignElement->ReportElement->ReportItem
comments, customXml, dataSet, extends, height, name, paramBindings, propertyMasks, style
backgroundColor, borderBottomColor, borderBottomStyle, borderBottomWidth, borderLeftColor, borderLeftStyle, borderLeftWidth, borderRightColor, borderRightStyle, borderRightWidth, borderTopColor, borderTopStyle, borderTopWidth, color, display, fontFamily, fontSize, fontStyle, fontVariant, fontWeight, marginBottom, marginLeft, marginRight, marginTop, masterPage, paddingBottom, paddingLeft, paddingRight, paddingTop, pageBreakAfter, pageBreakBefore, showIfBlank, textAlign, textLineThrough, textOverline, textUnderline, verticalAlign
The following sections describe the properties of the Image element.
An optional hyperlink for this image.
An optional text message to display in place of the image in a web browser.
Resource key that allows externalizing and localizing the value of the altText property.
An optional help text for the image. The help text can contain HTML formatting and can be externalized. The web viewer shows this as balloon help.
A resource ID for this value, used for externalizing the value of this string.
The name of an embedded image if the Source type is Embedded.
The scale at which the image is displayed.
The method of managing the relationship between image and item size. The following table itemizes the choices for this property.
Name
|
Display name
|
Value
|
---|---|---|
size-to-image
|
Size to image
|
size-to-image
|
scale-to-item
|
Scale to Item
|
scale-to-item
|
clip
|
Clip
|
clip
|
The kind of image reference. The image can be a number of formats. This choice determines which of the other properties BIRT must consider when obtaining the image value.
The following table itemizes the choices for this property.
An expression that returns the type of the image expressed as a MIME type, including the following types:
If omitted, BIRT attempts to infer the image type from the data in the image.
The identifier for the image if the type is File or URL. The type of image is inferred from the image file content or HTTP response.
An expression that returns the image contents.
The following sections describe the methods of the Image element.
The method that BIRT executes to handle the onCreate event for this element. The onCreate method executes every time the element is generated. Use the onCreate method to perform tasks that are data dependent.
The method that BIRT executes to handle the onPrepare event for this element. the onPrepare method executes once prior to the generation of the report. Use onPrepare method to perform tasks that affect the appearance of the element for every occurrence in the report.
The method that BIRT executes to handle the onRender event for this element. The onRender method executes at run time and not at generation time. Use the onRender method to perform tasks that are dependent on the run time details. Examples of run time factors that might require special handling include the run time environment, the user requesting the report, the parameter values in effect when the report is run, and whether the report is produced in HTML or PDF format.
![]() ![]() |