Platforms to show: All Mac Windows Linux Cross-Platform

Back to CGSWindowMBS class.

CGSWindowMBS.AffineTransform as CGAffineTransformMBS

Type Topic Plugin Version macOS Windows Linux iOS Targets
property CoreGraphics MBS MacCG Plugin 7.4 ✅ Yes ❌ No ❌ No ❌ No Desktop, Console & Web
The transformation of this window.
Example
// rotates the window.
dim a as CGAffineTransformMBS

a=CGAffineTransformMBS.MakeRotation(1)

a=a.Translate(-Width,-Height)

dim co as CGSConnectionMBS
dim cw as CGSWindowMBS

co=new CGSConnectionMBS
cw=co.CGSWindow(window1)

cw.AffineTransform=a

Lasterror is set.
(Read and Write computed property)

CGSWindowMBS.Alpha as single

Type Topic Plugin Version macOS Windows Linux iOS Targets
property CoreGraphics MBS MacCG Plugin 7.4 ✅ Yes ❌ No ❌ No ❌ No Desktop, Console & Web
The alpha value for this window.
Example
dim cw as CGSWindowMBS
dim co as new CGSConnectionMBS

cw=co.CGSWindow(window1)
cw.Alpha=0.2

// same as:

// self.TransparencyMBS=0.2

0 is invisible and 1.0 is visible.

You may prefer to use the window TransparencyMBS property instead as it uses documented APIs.
(Read and Write computed property)

CGSWindowMBS.EventMask as Integer

Type Topic Plugin Version macOS Windows Linux iOS Targets
property CoreGraphics MBS MacCG Plugin 7.4 ✅ Yes ❌ No ❌ No ❌ No Desktop, Console & Web
The event mask of this window.

(Read and Write computed property)

CGSWindowMBS.Flush

Type Topic Plugin Version macOS Windows Linux iOS Targets
method CoreGraphics MBS MacCG Plugin 7.4 ✅ Yes ❌ No ❌ No ❌ No Desktop, Console & Web
Flushes this window.
Example
dim co as CGSConnectionMBS
dim cw as CGSWindowMBS

co=new CGSConnectionMBS
cw=co.CGSWindow(window1)

cw.Flush

Lasterror is set.

CGSWindowMBS.Height as Double

Type Topic Plugin Version macOS Windows Linux iOS Targets
method CoreGraphics MBS MacCG Plugin 7.4 ✅ Yes ❌ No ❌ No ❌ No Desktop, Console & Web
The height of this window.
Example
dim co as CGSConnectionMBS
dim cw as CGSWindowMBS

co=new CGSConnectionMBS
cw=co.CGSWindow(window1)

MsgBox str(cw.height)

CGSWindowMBS.Left as Double

Type Topic Plugin Version macOS Windows Linux iOS Targets
method CoreGraphics MBS MacCG Plugin 7.4 ✅ Yes ❌ No ❌ No ❌ No Desktop, Console & Web
The left position of this window.
Example
dim co as CGSConnectionMBS
dim cw as CGSWindowMBS

co=new CGSConnectionMBS
cw=co.CGSWindow(window1)

MsgBox str(cw.left)

CGSWindowMBS.Level as Integer

Type Topic Plugin Version macOS Windows Linux iOS Targets
method CoreGraphics MBS MacCG Plugin 7.4 ✅ Yes ❌ No ❌ No ❌ No Desktop, Console & Web
The window level of this window.

See WindowGroupMBS.level or OverlayWindow.Level for details.

CGSWindowMBS.Move(byref x as single, byref y as single)

Type Topic Plugin Version macOS Windows Linux iOS Targets
method CoreGraphics MBS MacCG Plugin 7.4 ✅ Yes ❌ No ❌ No ❌ No Desktop, Console & Web
Moves the window.

CGSWindowMBS.Order(mode as Integer, relativeToWindow as CGSWindowMBS=nil)

Type Topic Plugin Version macOS Windows Linux iOS Targets
method CoreGraphics MBS MacCG Plugin 7.4 ✅ Yes ❌ No ❌ No ❌ No Desktop, Console & Web
Reorders the window.

Lasterror is set.
Mode must be kCGSOrderAbove, kCGSOrderBelow or kCGSOrderOut.

CGSWindowMBS.Title as string

Type Topic Plugin Version macOS Windows Linux iOS Targets
method CoreGraphics MBS MacCG Plugin 8.1 ✅ Yes ❌ No ❌ No ❌ No Desktop, Console & Web
The window title.

CGSWindowMBS.Top as Double

Type Topic Plugin Version macOS Windows Linux iOS Targets
method CoreGraphics MBS MacCG Plugin 7.4 ✅ Yes ❌ No ❌ No ❌ No Desktop, Console & Web
The top position of this window.
Example
dim co as CGSConnectionMBS
dim cw as CGSWindowMBS

co=new CGSConnectionMBS
cw=co.CGSWindow(window1)

MsgBox str(cw.top)

In Pixel from the top of the screen.

CGSWindowMBS.Uncover

Type Topic Plugin Version macOS Windows Linux iOS Targets
method CoreGraphics MBS MacCG Plugin 7.4 ✅ Yes ❌ No ❌ No ❌ No Desktop, Console & Web
Uncovers the window.

Lasterror is set.

CGSWindowMBS.Warp(w as Integer, h as Integer, value as memoryblock)

Type Topic Plugin Version macOS Windows Linux iOS Targets
method CoreGraphics MBS MacCG Plugin 7.4 ✅ Yes ❌ No ❌ No ❌ No Desktop, Console & Web
Sets the wrap of a window.
Example
dim w,h as Integer
dim m as memoryblock
dim localx,localy, gobalx,gobaly as Integer
dim offset as Integer

m=newmemoryblock(w*h*16)
// for each row
// for each point in row
m.SingleValue(offset)=localx
offset=offset+4
m.SingleValue(offset)=localy
offset=offset+4
m.SingleValue(offset)=gobalx
offset=offset+4
m.SingleValue(offset)=gobaly
offset=offset+4

the memoryblock must be of size w*h*sizeof(single)*4.
a single is 4 bytes, so this is 16*w*h
w is the number of horizontal points you define.
h is the number of vertical points you define.

Basicly you define for a local point in the window the point onscreen where it is moved to. See the example project for more details.

CGSWindowMBS.Width as Double

Type Topic Plugin Version macOS Windows Linux iOS Targets
method CoreGraphics MBS MacCG Plugin 7.4 ✅ Yes ❌ No ❌ No ❌ No Desktop, Console & Web
The width of this window.
Example
dim co as CGSConnectionMBS
dim cw as CGSWindowMBS

co=new CGSConnectionMBS
cw=co.CGSWindow(window1)

MsgBox str(cw.width)

CGSWindowMBS.Workspace as CGSWorkspaceMBS

Type Topic Plugin Version macOS Windows Linux iOS Targets
method CoreGraphics MBS MacCG Plugin 7.4 ✅ Yes ❌ No ❌ No ❌ No Desktop, Console & Web
The workspace where this window is part of.

The items on this page are in the following plugins: MBS MacCG Plugin.


The biggest plugin in space...