All Databases
Inside Mac - Basic Toolbox
GetWTitle
GetWTitle
Obtain the text of a window's title
#include <
Windows.h
>
Window Manager
void
GetWTitle
(
theWindow
,
theTitle
);
WindowPtr
theWindow
; window of interest
Str255
theTitle
; receives length-prefixed title string
GetWTitle
obtains the title of the specified window.
theWindow
is a
WindowPtr
obtained via
NewWindow
or
GetNewWindow
.
theTitle
is the address of a pointer to a
Str255
. Upon return, it will contain
a pointer to the text of the title.
Returns
: none
Example
#include <
Windows.h
>
WindowPtr
myWindow;
Str255
*theTitle;
/* ... */
GetWTitle
( myWindow, &theTitle );
PtoCstr( theTitle ); [TOKEN:12074]
ASCIIZ
for printf() */
printf("The current title is %s\n", theTitle );
Referenced by (6):
StringPtr (Inside Mac - Index)
Window Mgr (Inside Mac - Index)
Dot Printer (code) (MacTech Vol 05-1989)
Sprocket Menus 2 (MacTech Vol 11-1995)
Using Navigation Services (MacTech Vol 14-1998)
March 94 - Print Hints (develop - 1994)