Home > Class Reference > ENSLIB namespace > %ZEN.Component.image
Private  Storage   

%ZEN.Component.image


class %ZEN.Component.image extends control

Simple image control.
This can be used to display an image within a page or it can serve as a button by specifying an onclick event.
There is no submitted value associated with this control.
There are several different ways to specify the image to display:

  1. If provided, src is the URI of the image to display.
  2. If provided, streamId is the OID value for a binary stream object containing the image. This OID value will be encrypted and the image will be served via the CSP stream server.
  3. If provided, value is an encrypted stream OID value for a binary stream object containing the image. The image will be served via the CSP stream server. This is used when the image is bound to a property within a dataController that contains binary stream data.
Note that the controlClass does not apply to the image component.

Inventory


Parameters Properties Methods Queries Indices ForeignKeys Triggers
6 7


Summary


Properties
%condition %import %includeFiles %page
%resource align alt aux
clientType composite containerStyle controlClass
controlStyle dataBinding disabled dragEnabled
dropEnabled enclosingClass enclosingStyle error
height hidden hint hintClass
hintStyle id index invalid
invalidMessage label labelClass labelDisabledClass
labelStyle name onafterdrag onbeforedrag
onblur onchange onclick ondblclick
ondrag ondrop onfocus onhide
onkeydown onkeypress onkeyup onmousedown
onmouseout onmouseover onmouseup onrefresh
onshow onsubmit ontouchend ontouchmove
ontouchstart onupdate onvalidate originalValue
parent readOnly required requiredMessage
showLabel slice src srcDisabled
srcMissing streamId tabIndex text
title tuple valign value
visible width window

Methods
%AddToSaveSet %Attr %BindExport %ClassIsLatestVersion
%ClassName %ConstructClone %DispatchClassMethod %DispatchGetModified
%DispatchGetProperty %DispatchMethod %DispatchSetModified %DispatchSetMultidimProperty
%DispatchSetProperty %DrawComponentHTML %DrawHTML %DrawJSStrings
%EnclosingDivId %Eval %EvalC %Extends
%ForceClientRender %GetEventHandlers %GetForm %GetParameter
%GetXMLName %IsA %IsModified %MakeId
%Name %New %NormalizeObject %ObjectModified
%OnAddToPageAfter %OnAddToPageBefore %OnDrawEnclosingDiv %OnDrawObjectProperties
%OnObjectSynch %OnZENDeserialize %OriginalNamespace %PackageName
%QuoteValue %QuoteValueL10N %RemoveFromSaveSet %Self
%SerializeObject %SetDefaultValues %SetModified %ValidateObject
XMLDTD XMLExport XMLExportToStream XMLExportToString
XMLNew XMLSchema XMLSchemaNamespace XMLSchemaType
dragFinishHandler dragHandler dragNotifyHandler dragStartHandler
dropHandler dropStartHandler exposeComponent findElement
fireOnUpdateEvent focus formatValue getDisabled
getDragData getEnclosingDiv getForm getHidden
getHintElement getInvalidReason getLabelElement getProperty
getReadOnly getSettings getType getValue
imageClick invokeSuper isModified isOfType
isValid makeId normalizeValue onCreate
onDelete onDisplayHandler onEndModalHandler onPopupAction
onRefreshContents onSerialize onStartModalHandler onchangeHandler
onloadHandler onunloadHandler onupdateHandler refreshContents
render renderContents renderSVG select
setDisabled setHidden setOverlayMode setProperty
setReadOnly setValue startProgressBar stopProgressBar
sysName unformatValue validationHandler


Properties


• property alt as %ZEN.Datatype.caption;
Alternate text for this image; This is used for the alt attribute of the HTML img element used for this component.
• property src as %ZEN.Datatype.uri;
URI of image to display.
• property srcDisabled as %ZEN.Datatype.uri;
If defined, URI of image to display when this image is disabled.
• property srcMissing as %ZEN.Datatype.uri;
If defined, URI of image to display when a value for this image is missing; This is used when this image is bound to a property of a dataController and there is no value for the bound property.
• property streamId as %ZEN.Datatype.string(ZENENCRYPT=1);
If defined, this is the stream id of a binary stream object on the server that will provide data for this image. This supercedes src if present.
• property text as %ZEN.Datatype.string;
If defined, this is an optional text value associated with this image. By default, this is used as a value when this image is the source of a drag and drop operation.

Methods


• method %DrawHTML()
Static HTML display method: draw the BODY of this component as HTML.
Subclasses implement this in order to render the static HTML contents of a component.
• method %SetDefaultValues()
This method fills in reasonable default values for this control. Used by tools (such as the Control Tester) to dynamically create controls.
• method getDragData(dragData) [ Language = javascript ]
Override default drag behavior.
• method imageClick(evt) [ Language = javascript ]
User click on image; Invoke callback if button is enabled.
• method setProperty(property, value, value2) [ Language = javascript ]
Set the value of a named property.