hwIPage SetLayout

Sets the page layout type.

Syntax

hwIPage_handle SetLayouttype

Application

HyperWorks Desktop Tcl Modify

Description

This command sets the page layout type.

Inputs

type
The page layout type:
-1
Indicates an error
0
One window
1
Two windows (left and right)
2
Two windows (top and bottom)
3
Three windows (one left and two right)
4
Three windows (two left and one right)
5
Three windows (two top and one bottom)
6
Three windows (one top and two bottom)
7
Three windows (left, middle, and right)
8
Three windows (top, middle, and bottom)
9
Four windows
10
Six windows (three rows of two)
11
Six windows (two rows of three)
12
Nine windows
13
Twelve windows (four rows of three)
14
Twelve windows (three rows of four)
15
Sixteen windows
16
Four windows (four rows of one)
17
Eight windows (four rows of two)
18
Four windows (one row of four)
19
Eight windows (two rows of four)

Example

# Changes the Page layout type to the next higher type, or back to 0
# Prints to the tk console the previous layout type
hwi OpenStack
hwi GetSessionHandle session
session GetProjectHandle project
project GetPageHandle page [project GetActivePage]
set prevLayout [page GetLayout]
puts "The previous layout was $prevLayout"
set newLayout [expr "$prevLayout + 1"]
if {$newLayout > 19} {
set newLayout 0;
}
page SetLayout $newLayout
hwi CloseStack

Error

Negative one (-1) indicates an error.