home *** CD-ROM | disk | FTP | other *** search
- /***************************************************************************************
- *
- * ScrollDialog.c- A useful library for implementing scrollable text boxes in
- * a dialog. Can be used for elaborate about boxes, etc.
- *
- * ©1993 by Graham Cox. All Rights Reserved.
- *
- * 20/3/93 Modified to allow edit operations if required.
- * 31/8/93 changed to pascal calling conventions for greater utility
- * 13/7/94 converted to MetroWerks CodeWarrior project and compiled for PowerPC
- *
- ***************************************************************************************/
-
-
- typedef struct
- {
- ControlHandle TDControl; // the scrollbar
- TEHandle TDText; // the TextEdit record
- long reserved; // reserved for future use- do not use
- short lineHeight; // default lineHeight
- short pageHeight; // height of a page
- Boolean editable; // is the text editable?
- }
- TDRecord, *TDRecPtr, **TDRecHdl;
-
- #define NIL nil
-
- pascal void TDUserItem(DialogPtr theDialog,short theItem);
- pascal void TDScrollProc(ControlHandle theControl,short partCode);
- pascal Boolean TDFilter(DialogPtr theDialog,EventRecord *theEvent,short *itemHit);
- pascal Boolean ModelessText(DialogPtr theDialog,short theItem,EventRecord *theEvent);
- pascal DialogPtr GetTextDialog(short dialogID,short textUserItem,short textResourceID,Boolean canWrite);
- pascal void ModalTDDialog(short *theItem);
- pascal void DisposeTDDialog(DialogPtr theDialog);
- pascal short ScrollTextDialog(short dialogID,short textUserItem,short textResourceID);
- pascal void TDSetText(DialogPtr theDialog,Ptr text,long tLength,StScrpHandle stInfo);
- pascal void TDSetResourceText(DialogPtr theDialog,short textResID);
- pascal TEHandle GetTDTextHdl(DialogPtr theDialog);
- pascal void RecalTDBar(DialogPtr theDialog);
- pascal void UpdateTDBar(TEHandle theText,ControlHandle theBar);
- pascal void RecalTDBar(DialogPtr theDialog);
-