[tooltalk.txt 6/97 Digital Insight] Robochart Tooltalk interface (Robochart version OL8.1, XM2.1) 1. Tooltalk messages handled by Robochart Where scope is not specified, either SESSION or FILE scope is allowed. The currently joined file is set by the Display, Empty, and SaveAs request messages. Some requests have multiple names, which are equivalent. session Display(void) session Edit(void) session Open(void) Open file (TT message file) for editing, start new application if none running without unsaved changes. Deiconifies window if necessary. Joins file. Empty(/* in integer force */) Start new empty document, start new application if none running without unsaved changes. Set optional integer argument to nonzero to permit discarding unsaved changes. Joins file if specified. Revert(void) Revert to disk version of current file. Okay to discard edits. Save(void) Save diagram to current filename. SaveAs(in string newname) Save diagram to specified new filename, joins new file. Set_Iconified(in integer iconic) Iconify (iconic=1) or deiconify (iconic=0) diagram editor window. Close(/* in integer force */) Quit(/* in integer force */) Quit application. If optional integer argument is missing or zero, and there are unsaved changes, request is denied. Load_Cfg(in string cfgfile) Load configuration data from file. Print(/* in string printer, in integer startpg, in integer endpg */) Output diagram to printer. First argument, if present, is Printer name (or pipe command if starts with '|'). Second and third arguments are optional page range; if missing, only the current level is printed. If one given, print all of that page. Otherwise, print all pages from startpg through endpg. Use Load_Cfg to set print options. Export(/* in string filename, in integer startpg, in integer endpg */) Export diagram to file. Export name is required. Optional Page range is same as Print request. Use Load_Cfg to set print options. Goto(in integer page_number) Display the specified diagram page. Adds a new page if page_number is one past the current last page number, and the current page isn't empty. Zoom_In(in integer objectID) Zoom in on the specified object. Zoom_Out(void) Zoom out one level. Set_View(/* in integer xleft, in integer ytop, in integer width, in integer height */) Sets scrolled position of upper left corner of the view window, and (optionally) the size of the view window. Get_View(out integer xleft, out integer ytop, out integer width, out integer height) Gets the current position and size of the view window. file Batch(in integer on) If "on" is non-zero, turns on batch update mode, preventing redraws during tooltalk object and flow edits. If "on" is zero, turns off batch update mode and redraws the window. file Find_Obj(/* out integer objectID, in attr value... */) file Find_Flow(/* out integer flowID, in attr value... */) Get ID of object or flow matching specified attributes (see below). Fails if no match or more than one match. First (output) parameter is required. file Sel_Obj(/* in integer reset, in attr value... */) file Sel_Flow(/* in integer reset, in attr value... */) Select all objects or flows matching specified attributes. If optional integer arg "reset" is present and non-zero, selections are cleared first, otherwise matches are added to existing selections. If no arguments are given, selects all objects or flows. If only "reset" is given, clears selections. file Edit_Sel(/* in attr value... */) Modify attributes of selected objects and flows. file Edit_Obj(/* in integer objectID, in attr value... */) file Edit_Flow(/* in integer flowID, in attr value... */) Modify attributes of specific object or flow (given [required] ID returned from Find_Obj, Find_Flow, Create_Obj, Create_Flow). file Create_Obj(/* out integer objectID, in attr value... */) file Create_Flow(/* out integer flowID, in attr value... */) Create object/flow with specified attributes. Unspecified attributes are given current default values. Returns object or flow ID in required first argument. Some input parameters are required: type and posn for objects, sobj and dobj for flows. file Del_Obj(in integer objectID) file Del_Flow(in integer flowID) file Del_Sel(void) Delete specified object/flow, or all selected objects/flows file Add_Vertex(in integer flowID, in integer position, in integer x, in integer y) Add flow vertex at specified coordinates. Any existing vertices from on (0=first) are moved after new vertex. file Move_Vertex(in integer flowID, in integer position, in integer x, in integer y) Move specified flow vertex (0=first) to specified coordinates. file Del_Vertex(in integer flowID, in integer position) Delete specified flow vertex (0=first). 2. Object and flow attributes Object and flow attributes have the following types, with string values: type - object type (shape) 0-255 stype - flow source type (arrow) 0-29 dtype - flow destination type (arrow) 0-29 ltype - line type (flow line or object border); S=thin solid, D=thin dashed, s=thick solid, d=thick dashed, N=none lcolor - line color (flow line or object border) 0-7 tcolor - text color 0-7 fcolor - object fill color 0-7 or N=none sobj - flow source object ID dobj - flow destination object ID curved - 0=straight flow, 1=curved flow label - string (substring for search). To change font in label, insert "\fxx", where xx is the hex font code (index of font entry in rcfonts file). Use "\\" to insert backslash. For searches, start with '^' to limit match to labels starting with search substring. posn - object position as xleft,ytop,width,height (for matching, xleft/ytop must be in object region) laboff - label offset as x,y