BBjTopLevelWindow::setMaximumSize

Description

In BBj 15.0 and higher, this method sets the maximum outer size of the BBjTopLevelWindow, including the width and height required for any title bar, menu bar, status bar, and docked child windows.

Syntax

Return Value

Method

void

setMaximumSize(int maximumWidth, int maximumHeight)

Parameters

Variable

Description

maximumWidth

Specifies the maximum outer width of the BBjTopLevelWindow, including the width required for any docked child windows.

maximumHeight

Specifies the maximum outer height of the BBjTopLevelWindow, including the height required for any title bar, menu bar, status bar, and docked child windows.

Return Value

None.

Remarks

The default maximum size is defined by the platform look and feel.

Example

rem ' setMaximumSize

sysgui = unt
open (sysgui)"X0"
sysgui! = bbjapi().getSysGui()
window! = sysgui!.addWindow(100,100,150,100,"",$00090003$)
title$ = str(window!.getWidth())+","+str(window!.getHeight())
window!.setTitle(title$)
window!.setCallback(window!.ON_CLOSE,"eoj")
window!.setCallback(window!.ON_RESIZE,"resize")
print "getMaximumWidth:",window!.getMaximumWidth()
print "getMaximumHeight:",window!.getMaximumHeight()
window!.setMaximumSize(350,300)
print "getMaximumWidth:",window!.getMaximumWidth()
print "getMaximumHeight:",window!.getMaximumHeight()
process_events

eoj:
release

resize:
    event! = sysgui!.getLastEvent()
    title$ = str(event!.getWidth())+","+str(event!.getHeight())
    window!.setTitle(title$)
return

See Also

BBjAPI

BBjSysGui

BBjWindow

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