-+-+-+-+-+-+-+-+ START OF PART 243 -+-+-+-+-+-+-+-+ X writelimit3(PTKEINFORM, &state.e_area); X writepickrec(PTKEINFORM, dev, state.pet, &state.record); X phinprintf(PTKEINFORM, "path order = "); X writephigsenum(PTKEINFORM, PTKEPATHORDER,`20 X state.path_order); X#endif X `7D X else X phigserror(PTKEINFORM, err); X `7D X free(buffer); X`7D /* do_pinqpickst3 */ X X/*-------------------------------------------------------------------------- V*/ X Xstatic void do_pinqpostedstruct() X`7B X Pint ws, start, err, totlength, i; X Pstructpostlst list; X X ws = readinteger("workstation identifier ? "); X start = readinteger("starting position ? "); X pinqpostedstruct(ws, 0, start, &err, &list, &totlength); X list.postings = (Pstructpost *)calloc(totlength, sizeof(Pstructpost)); X list.number = totlength; X pinqpostedstruct(ws, totlength, start, &err, &list, &totlength); X if (writeinform) X `7B X phinprintf(PTKEINFORM, "--- %s ---\n", phigsnamelist`5Bactivefunction`5D V); X if (err == 0) X `7B X phinprintf(PTKEINFORM, "number of posted structures = "); X writeinteger(PTKEINFORM, list.number); X for (i = 0; i < list.number; i++) X `7B X phinprintf(PTKEINFORM, "structure identifier = "); X writeintvalue(PTKEINFORM, list.postings`5Bi`5D.id, PTKESTRUCTID); X phinprintf(PTKEINFORM, "priority = %f\n", i,`20 X list.postings`5Bi`5D.priority); X `7D X `7D X else X phigserror(PTKEINFORM, err); X `7D X free(list.postings); X`7D /* do_pinqpostedstruct */ X X/*-------------------------------------------------------------------------- V*/ X Xstatic void do_pinqpredcolourrep() X`7B X Pwstype wstype; X Pint index, err; X Pcobundl bundle; X X readwstype(&wstype); X index = readintvalue("predefined index ? ", PTKECOLOURIND); X pinqpredcolourrep(wstype, index, &err, &bundle); X if (writeinform) X `7B X phinprintf(PTKEINFORM, "--- %s ---\n", phigsnamelist`5Bactivefunction`5D V); X if (err == 0) X `7B X phinprintf(PTKEINFORM,`20 X "predefined colour representation:\n"); X writecobundl(PTKEINFORM, &bundle); X `7D X else X phigserror(PTKEINFORM, err); X `7D X`7D /* do_pinqpredcolourrep */ X X/*-------------------------------------------------------------------------- V*/ X Xstatic void do_pinqprededgerep() X`7B X Pwstype wstype; X Pint index, err; X Pedgebundl bundle; X X readwstype(&wstype); X index = readinteger("predefined index ? "); X pinqprededgerep(wstype, index, &err, &bundle); X if (writeinform) X `7B X phinprintf(PTKEINFORM, "--- %s ---\n", phigsnamelist`5Bactivefunction`5D V); X if (err == 0) X `7B X phinprintf(PTKEINFORM, "predefined edge representation:\n"); X writeedgebundl(PTKEINFORM, &bundle); X `7D X else X phigserror(PTKEINFORM, err); X `7D X`7D /* do_pinqprededgerep */ X X/*-------------------------------------------------------------------------- V*/ X Xstatic void do_pinqpredintrep() X`7B X Pwstype wstype; X Pint index, err; X Pinterbundl bundle; X X readwstype(&wstype); X index = readinteger("predefined index ? "); X pinqpredintrep(wstype, index, &err, &bundle); X if (writeinform) X `7B X phinprintf(PTKEINFORM, "--- %s ---\n", phigsnamelist`5Bactivefunction`5D V); X if (err == 0) X `7B X phinprintf(PTKEINFORM,`20 X "predefined interior representation:\n"); X writeinterbundl(PTKEINFORM, &bundle); X `7D X else X phigserror(PTKEINFORM, err); X `7D X`7D /* do_pinqpredintrep */ X X/*-------------------------------------------------------------------------- V*/ X Xstatic void do_pinqpredpatrep() X`7B X#ifdef SUN X Pwstype wstype; X Pint index, err, totsize, numcols, i; X Pptbundl rep; X Pchar *buffer; X X readwstype(&wstype); X index = readinteger("pattern index ? "); X pinqpredpatrep(wstype, index, 0, &err, buffer, &totsize, &rep); X buffer = (Pchar *)malloc(totsize); X pinqpredpatrep(wstype, index, totsize, &err, buffer, &totsize, &rep); X if (writeinform) X `7B X phinprintf(PTKEINFORM, "--- %s ---\n", phigsnamelist`5Bactivefunction`5D V); X if (err == 0) X `7B X phinprintf(PTKEINFORM, "predefined pattern representation:\n"); X phinprintf(PTKEINFORM, "dimensions, x = %d, y = %d\n", X rep.dim.x_dim, rep.dim.y_dim); X numcols = rep.dim.x_dim * rep.dim.y_dim; X phinprintf(PTKEINFORM, "colour indicies:\n"); X writeintarray(PTKEINFORM, numcols, rep.array, PTKECOLOURIND); X `7D X else X phigserror(PTKEINFORM, err); X `7D X free(buffer); X#endif X#ifdef VMS X phintererror(1, (Pchar *)NULL, INFORM); X#endif X`7D /* do_pinqpredpatrep */ X X/*-------------------------------------------------------------------------- V*/ X Xstatic void do_pinqpredlinerep() X`7B X Pwstype wstype; X Pint index, err; X Plnbundl bundle; X X readwstype(&wstype); X index = readinteger("predefined index ? "); X pinqpredlinerep(wstype, index, &err, &bundle); X if (writeinform) X `7B X phinprintf(PTKEINFORM, "--- %s ---\n", phigsnamelist`5Bactivefunction`5D V); X if (err == 0) X `7B X phinprintf(PTKEINFORM, "predefined line representation:\n"); X writelnbundl(PTKEINFORM, &bundle); X `7D X else X phigserror(PTKEINFORM, err); X `7D X`7D /* do_pinqpredlinerep */ X X/*-------------------------------------------------------------------------- V*/ X Xstatic void do_pinqpredmarkerrep() X`7B X Pwstype wstype; X Pint index, err; X Pmkbundl bundle; X X readwstype(&wstype); X index = readinteger("predefined index ? "); X pinqpredmarkerrep(wstype, index, &err, &bundle); X if (writeinform) X `7B X phinprintf(PTKEINFORM, "--- %s ---\n", phigsnamelist`5Bactivefunction`5D V); X if (err == 0) X `7B X phinprintf(PTKEINFORM, "predefined marker representation:\n"); X writemkbundl(PTKEINFORM, &bundle); X `7D X else X phigserror(PTKEINFORM, err); X `7D X`7D /* do_pinqpredmarkerrep */ X X/*-------------------------------------------------------------------------- V*/ X Xstatic void do_pinqpredtextrep() X`7B X Pwstype wstype; X Pint index, err; X Ptxbundl bundle; X X readwstype(&wstype); X index = readinteger("predefined index ? "); X pinqpredtextrep(wstype, index, &err, &bundle); X if (writeinform) X `7B X phinprintf(PTKEINFORM, "--- %s ---\n", phigsnamelist`5Bactivefunction`5D V); X if (err == 0) X `7B X phinprintf(PTKEINFORM, "predefined text representation:\n"); X writetxbundl(PTKEINFORM, &bundle); X `7D X else X phigserror(PTKEINFORM, err); X `7D X`7D /* do_pinqpredtextrep */ X X/*-------------------------------------------------------------------------- V*/ X Xstatic void do_pinqpredviewrep() X`7B X Pwstype wstype; X Pint index, err; X Pviewrep3 rep; X X readwstype(&wstype); X index = readintvalue("predefined index ? ", PTKEVIEWIND); X pinqpredviewrep(wstype, index, &err, &rep); X if (writeinform) X `7B X phinprintf(PTKEINFORM, "--- %s ---\n", phigsnamelist`5Bactivefunction`5D V); X if (err == 0) X `7B X phinprintf(PTKEINFORM, "predefined view representation:\n"); X phinprintf(PTKEINFORM, "orientation matrix:\n"); X writematrix3(PTKEINFORM, rep.orientation_matrix); X phinprintf(PTKEINFORM, "mapping matrix:\n"); X writematrix3(PTKEINFORM, rep.mapping_matrix); X phinprintf(PTKEINFORM, "clipping limits:\n"); X writelimit3(PTKEINFORM, &rep.clip_limit); X phinprintf(PTKEINFORM, "x-y clipping = "); X writephigsenum(PTKEINFORM, PTKECLIP, rep.clip_xy); X phinprintf(PTKEINFORM, "back clipping = "); X writephigsenum(PTKEINFORM, PTKECLIP, rep.clip_back); X phinprintf(PTKEINFORM, "front clipping = "); X writephigsenum(PTKEINFORM, PTKECLIP, rep.clip_front); X `7D X else X phigserror(PTKEINFORM, err); X `7D X`7D /* do_pinqpredviewrep */ X X/*-------------------------------------------------------------------------- V*/ X Xstatic void do_pinqsetopenws() X`7B X Pint start, err, totlength, i; X Pintlst wsids; X X start = readinteger("starting position ? "); X pinqsetopenws(0, start, &err, &wsids, &totlength); X wsids.integers = (Pint *)calloc(totlength, sizeof(Pint)); X wsids.number = totlength; X pinqsetopenws(totlength, start, &err, &wsids, &totlength); X if (writeinform) X `7B X phinprintf(PTKEINFORM, "--- %s ---\n", phigsnamelist`5Bactivefunction`5D V); X if (err == 0) X `7B X phinprintf(PTKEINFORM, "open workstations:\n"); X writeintlst(PTKEINFORM, &wsids, PTKENOTABLE); X `7D X else X phigserror(PTKEINFORM, err); X `7D X free(wsids.integers); X`7D /* do_pinqsetopenws */ X X/*-------------------------------------------------------------------------- V*/ X Xstatic void do_pinqsetwsposted() X`7B X Pint stid, start, err, totlength, i; X Pintlst wsids; X X stid = readintvalue("structure identifier ? ", PTKESTRUCTID); X start = readinteger("starting position ? "); X pinqsetwsposted(stid, 0, start, &err, &wsids, &totlength); X wsids.integers = (Pint *)calloc(totlength, sizeof(Pint)); X wsids.number = totlength; X pinqsetwsposted(stid, totlength, start, &err, &wsids, &totlength); X if (writeinform) X `7B X phinprintf(PTKEINFORM, "--- %s ---\n", phigsnamelist`5Bactivefunction`5D V); X if (err == 0) X `7B X phinprintf(PTKEINFORM, "workstation identifiers:\n"); X writeintlst(PTKEINFORM, &wsids, PTKENOTABLE); X `7D X else X phigserror(PTKEINFORM, err); X `7D X free(wsids.integers); X`7D /* do_pinqsetwsposted */ X X/*-------------------------------------------------------------------------- V*/ X Xstatic void do_pinqstringst() X`7B X Pint ws, dev, err, totsize; X Pchar *buffer; X Pstringst state; X X ws = readinteger("workstation identifier ? "); X dev = readinteger("string device number ? "); X pinqstringst(ws, dev, 0, &err, buffer, &totsize, &state); X buffer = (Pchar *)malloc(totsize); X pinqstringst(ws, dev, totsize, &err, buffer, &totsize, &state); X if (writeinform) X `7B X phinprintf(PTKEINFORM, "--- %s ---\n", phigsnamelist`5Bactivefunction`5D V); X if (err == 0) X `7B X phinprintf(PTKEINFORM, "current state of string device %d:\n", dev); X phinprintf(PTKEINFORM, "operating mode = "); X writephigsenum(PTKEINFORM, PTKEIMODE, state.mode); X phinprintf(PTKEINFORM, "echo switch = "); X writephigsenum(PTKEINFORM, PTKEESW, state.esw); X phinprintf(PTKEINFORM, "initial string = \"%s\"\n",`20 X state.string); `20 X phinprintf(PTKEINFORM, "prompt/echo type = "); X writeinteger(PTKEINFORM, state.pet); X phinprintf(PTKEINFORM, "limits:\n"); X writelimit(PTKEINFORM, &state.e_area); X writestringrec(PTKEINFORM, dev, state.pet, &state.record); X `7D X else X phigserror(PTKEINFORM, err); X `7D X free(buffer); X`7D /* do_pinqstringst */ X X/*-------------------------------------------------------------------------- V*/ X Xstatic void do_pinqstringst3() X`7B X Pint ws, dev, err, totsize; X Pchar *buffer; X Pstringst3 state; X X ws = readinteger("workstation identifier ? "); X dev = readinteger("string device number ? "); X pinqstringst3(ws, dev, 0, &err, buffer, &totsize, &state); X buffer = (Pchar *)malloc(totsize); X pinqstringst3(ws, dev, totsize, &err, buffer, &totsize, &state); X if (writeinform) X `7B X phinprintf(PTKEINFORM, "--- %s ---\n", phigsnamelist`5Bactivefunction`5D V); X if (err == 0) X `7B X phinprintf(PTKEINFORM, "current state of string 3 device %d:\n", dev); X phinprintf(PTKEINFORM, "operating mode = "); X writephigsenum(PTKEINFORM, PTKEIMODE, state.mode); X phinprintf(PTKEINFORM, "echo switch = "); X writephigsenum(PTKEINFORM, PTKEESW, state.esw); X phinprintf(PTKEINFORM, "initial string = \"%s\"\n",`20 X state.string); `20 X phinprintf(PTKEINFORM, "prompt/echo type = "); X writeinteger(PTKEINFORM, state.pet); X phinprintf(PTKEINFORM, "limits:\n"); X#ifdef SUN X writelimit3(PTKEINFORM, &state.e_volume); X#endif X#ifdef VMS X writelimit3(PTKEINFORM, &state.e_area); X#endif X writestringrec(PTKEINFORM, dev, state.pet, &state.record); X `7D X else X phigserror(PTKEINFORM, err); X `7D X free(buffer); X`7D /* do_pinqstringst3 */ X X/*-------------------------------------------------------------------------- V*/ X Xstatic void do_pinqstrokest() X`7B X Pint ws, dev, err, totsize, i; X Pchar *buffer; X Pstrokest state; X Pinqtype type; X X ws = readinteger("workstation identifier ? "); X dev = readinteger("stroke device number ? "); X type = readphigsenum(PTKEINQTYPE, "value type ? "); X pinqstrokest(ws, dev, type, 0, &err, buffer, &totsize, &state); X buffer = (Pchar *)malloc(totsize); X pinqstrokest(ws, dev, type, totsize, &err, buffer, &totsize, &state); X if (writeinform) X `7B X phinprintf(PTKEINFORM, "--- %s ---\n", phigsnamelist`5Bactivefunction`5D V); X if (err == 0) X `7B X phinprintf(PTKEINFORM, "current state of stroke device %d:\n", dev); X phinprintf(PTKEINFORM, "operating mode = "); X writephigsenum(PTKEINFORM, PTKEIMODE, state.mode); X phinprintf(PTKEINFORM, "echo switch = "); X writephigsenum(PTKEINFORM, PTKEESW, state.esw); X phinprintf(PTKEINFORM, "initial view index = "); X writeintvalue(PTKEINFORM, state.stroke.view_index, PTKEVIEWIND); X phinprintf(PTKEINFORM, "points:\n"); X writepointarray(PTKEINFORM, state.stroke.n_points, X state.stroke.points); X phinprintf(PTKEINFORM, "prompt/echo type = "); X writeinteger(PTKEINFORM, state.pet); X phinprintf(PTKEINFORM, "limits:\n"); X writelimit(PTKEINFORM, &state.e_area); X writestrokerec(PTKEINFORM, dev, state.pet, &state.record); X `7D X else X phigserror(PTKEINFORM, err); X `7D X free(buffer); X`7D /* do_pinqstrokest */ X X/*-------------------------------------------------------------------------- V*/ X Xstatic void do_pinqstrokest3() X`7B X Pint ws, dev, err, totsize, i; X Pchar *buffer; X Pstrokest3 state; X Pinqtype type; X +-+-+-+-+-+-+-+- END OF PART 243 +-+-+-+-+-+-+-+-