BBjDrawPanel::drawEllipse

Description

In BBj 16.0 and higher, this method draws a closed curve (ellipse or circle) on the BBjDrawPanel that fits just inside a rectangle delimited by the coordinates given.

Syntax

Return Value

Method

void

drawEllipse(number x, number y, number width, int height)

Parameters

Variable

Description

x

Horizontal position of upper left corner of the rectangle.

y

Vertical position of the upper left corner of the rectangle.

width

The width of the rectangle.

height

The height of the rectangle.

Return Value

None.

Remarks

When converting from the 'ELLIPSE' mnemonic, note that these method parameters are specified differently.

Example

rem ' BBjDrawPanel::drawEllipse

sysgui = unt
open (sysgui)"X0"
sysgui! = bbjapi().getSysGui()
title$ = "BBjDrawPanel::drawEllipse"
window! = sysgui!.addWindow(25,25,1150,375,title$,$00090003$)
window!.setCallback(window!.ON_CLOSE,"eoj")
window!.setTrack(0)
window!.setFont(sysgui!.makeFont("Arial",8,0))
drawpanel! = window!.getDrawPanel()
drawpanel!.setPenColor(BBjColor.BLUE)
drawpanel!.setTextColor(BBjColor.BLUE)
drawpanel!.setFillColor(BBjColor.GREEN)
for i = 0 to 10
    x = i * 100 + 25
    w = (i+1) * 0.25
    drawpanel!.setFillType(i)
    drawpanel!.setPattern(i)
    drawpanel!.setPenWidth(w)
    drawpanel!.drawText(x,25,"setPenWidth("+str(w)+")")
    drawpanel!.drawText(x,50,"setPattern("+str(i)+")")
    drawpanel!.drawText(x,75,"setFillType("+str(i)+")")
    drawpanel!.drawEllipse(x,100,75,75)
    drawpanel!.drawEllipse(x,200,50,75)
    drawpanel!.drawEllipse(x,300,75,50)
next i
process_events

eoj:
release

See Also

BBjAPI

BBjSysGui

BBjWindow

BBjDrawPanel

ELLIPSE Mnemonic - Draw Ellipse (SYSGUI)

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