BBjImage::getWidth

Description

In BBj 15.0 and higher, this method returns the width in pixels of a BBjImage.

Syntax

Return Value

Method

int

getWidth()

Parameters

None.

Return Value

Returns the width in pixels of the BBjImage.

Remarks

None.

Example

rem ' BBjImage::getWidth

image$ = "https://www.basis.cloud/images/basislogo.jpg"
print "Image: ",image$
sysgui = unt
open (sysgui)"X0"
sysgui! = bbjapi().getSysGui()
imagemanager! = sysgui!.getImageManager()
image! = javax.imageio.ImageIO.read(new java.net.URL(image$))
os! = new java.io.ByteArrayOutputStream()
javax.imageio.ImageIO.write(image!,"jpg",os!)
bytes! = os!.toByteArray()
image! = imagemanager!.loadImageFromBytes(bytes!)
print "Image width:",image!.getWidth()
print "Image height:",image!.getHeight()

See Also

BBjAPI

BBjSysGui

BBjControl

BBjWindow

See the BBj Object Diagram for an illustration of the relationship between BBj Objects.