Coyote Graphics Routines

Date: Fri Mar 27 12:14:20 2015

single page | use frames     summary     class     fields     routine details     file attributes

.\

cgcentertlb.pro


top cgCenterTLB

Utilities

cgCenterTLB, tlb [, x] [, y] [, CenterOnTLB=long] [, /Device] [, /NoCenter]

This is a utility routine to position a widget program on the display at an arbitrary location. By default the widget is centered on the display.

Parameters

tlb in required type=long

The top-level base identifier of the widget program. This must be a valid widget ID.

x in optional type=integer

Set this equal to a normalized position for the center of the widget as measured from the left-hand side of the screen. The default value is 0.5 (the center) Setting this equal to 1.0 places the widget at the far right-hand side of the screen.

y in optional type=integer

Set this equal to a normalized position for the center of the widget as measured from the top of the screen. The default value is 0.5 (the center) Setting this equal to 1.0 places the widget at the bottom of the screen.

Keywords

CenterOnTLB in optional type=long

If provided, the center of the widget is positioned at the center of the widget whose ID is provided here.

Device in optional type=boolean default=0

Normally, the x and y parameters are specified in normalized coordinates. If this keyword is set, they are taken to be in device coordinates.

NoCenter in optional type=boolean default=0

By default, the center of the widget is positioned at the location specified by the x and y parameters. If NoCenter is set to a non-zero value, then the upper left corner of the widget is postioned at the specifed location.

Author information

Author:

FANNING SOFTWARE CONSULTING:

David W. Fanning 1645 Sheely Drive Fort Collins, CO 80526 USA Phone: 970-221-0438 E-mail: david@idlcoyote.com Coyote's Guide to IDL Programming: http://www.idlcoyote.com

Copyright:

Copyright (c) 2012, Fanning Software Consulting, Inc.

History:

Change History:

Written by: Dick Jackson, 12 Dec 98. Modified to use device-independent Get_Screen_Size function. 31 Jan 2000. DWF. Added x, y, NOCENTER and run-off protection. 26 Jan 2001. BT. Added a maximum value of 1280 for X screen size. This helps center the widget on a single monitor when using dual monitor settings with some graphics cards. 3 Feb 2003. DWF. Added DEVICE keyword. 4 January 2006. DWF. Added CenterOnTLB keyword. 7 March 2011. DJ. Renamed cgCenterTLB and retired the previous CenterTLB program. 29 Oct 2012. DWF. Fixed documention of y parameter. 1 Oct 2013. DWF.

File attributes

Modification date: Fri Mar 27 11:07:39 2015
Lines: 145
Docformat: rst rst