Changeset 341 for SH_SHM/trunk/source/newgraph
- Timestamp:
- 03/09/2011 04:55:49 PM (12 years ago)
- Location:
- SH_SHM/trunk/source/newgraph
- Files:
-
- 22 deleted
- 7 edited
Legend:
- Unmodified
- Added
- Removed
-
SH_SHM/trunk/source/newgraph/Makefile
r200 r341 16 16 LIB_GRAPH = $(SH_LIB)libgraph.a 17 17 18 LOCAL_SRCS = graphch.c hpch.cmemch.c memfile.c psch.c xwch.c18 LOCAL_SRCS = graphch.c memch.c memfile.c psch.c xwch.c 19 19 #LOCAL_OBJS = $(LOCAL_SRCS:%.c=%.o) 20 20 LOCAL_OBJS = $(LOCAL_SRCS:.c=.o) -
SH_SHM/trunk/source/newgraph/gcusrdef.h
r16 r341 21 21 22 22 /* channel bits */ 23 #define GCF_GEM 0x10024 23 #define GCF_MEM 0x200 25 24 #define GCF_PSF 0x400 26 #define GCF_DJ 0x80027 #define GCF_BGI 0x000028 #define GCF_CALCOMP 0x400029 #define GCF_TEK 0x800030 #define GCF_VWS 0x8031 25 #define GCF_XWDW 0x2000 32 #define GCF_HPGL 0x2033 26 #define GCF_STDCH 0x10 /* standard text channel */ 34 27 #define GCF_FILE 0x00 /* text file channel */ 35 28 #define GCF_NOECHO 0x40 /* no echo bit */ 36 29 #define GCF_EXTERN 0x1000 /* external routine */ 37 #define GCF_ALLCHAN (GCF_ GEM|GCF_MEM|GCF_PSF|GCF_DJ|GCF_BGI|GCF_CALCOMP|GCF_TEK|GCF_VWS|GCF_XWDW|GCF_HPGL) /* all channels */30 #define GCF_ALLCHAN (GCF_MEM|GCF_PSF|GCF_XWDW) /* all channels */ 38 31 #define GCF_NUMMASK 7 39 32 … … 487 480 /*------------------------------------------------------------------------*/ 488 481 489 #ifdef BC_KS_PRIVATE490 #ifdef BC_G_GEM491 void gm_pixhardcopy( int wdw, int mag, char outfile[] );492 #define gc_pixhardcopy(w,m,f) gm_pixhardcopy(w&GCF_NUMMASK,m,f)493 #else494 #define gc_pixhardcopy(w,m,f)495 #endif496 #endif497 498 /*------------------------------------------------------------------------*/499 500 482 #endif /* __GCUSRDEF */ -
SH_SHM/trunk/source/newgraph/graphch.c
r16 r341 16 16 #include BC_SYSBASE 17 17 #include "graphbas.h" 18 #include "gmusrdef.h"19 18 #include "mmusrdef.h" 20 19 #include "psusrdef.h" 21 #include "ccusrdef.h"22 #include "tkusrdef.h"23 #include "hpusrdef.h"24 #include "djusrdef.h"25 #include "bgusrdef.h"26 20 #include "xwusrdef.h" 27 #include "vwusrdef.h"28 21 #include BC_GCUSRDEF 29 22 … … 79 72 } /*endif*/ 80 73 81 if (GCF_GEM & map) {82 gm_init( map & WDWMASK, attribs, xlo, ylo, width, height, status );83 if (Severe(status)) return;84 gcv_initmap |= GCF_GEM;85 } /*endif*/86 87 74 if (GCF_XWDW & map) { 88 75 xw_init( map & WDWMASK, attribs, xlo, ylo, width, height, status ); … … 91 78 } /*endif*/ 92 79 93 if (GCF_BGI & map) {94 bg_init( map & WDWMASK, attribs, xlo, ylo, width, height, status );95 if (Severe(status)) return;96 gcv_initmap |= GCF_BGI;97 } /*endif*/98 99 80 if (GCF_MEM & map) { 100 81 mm_init( map & WDWMASK, status ); … … 109 90 } /*endif*/ 110 91 111 if (GCF_CALCOMP & map) {112 cc_init( attribs, xlo, ylo, width, height, status );113 if (Severe(status)) return;114 gcv_initmap |= GCF_CALCOMP;115 } /*endif*/116 117 if (GCF_TEK & map) {118 tk_init( attribs, xlo, ylo, width, height, status );119 if (Severe(status)) return;120 gcv_initmap |= GCF_TEK;121 } /*endif*/122 123 if (GCF_HPGL & map) {124 hp_init( attribs, xlo, ylo, width, height, status );125 if (Severe(status)) return;126 gcv_initmap |= GCF_HPGL;127 } /*endif*/128 129 if (GCF_DJ & map) {130 dj_init( attribs, xlo, ylo, width, height, status );131 if (Severe(status)) return;132 gcv_initmap |= GCF_DJ;133 } /*endif*/134 135 if (GCF_VWS & map) {136 vw_init( map & WDWMASK, attribs, xlo, ylo, width, height, status );137 if (Severe(status)) return;138 gcv_initmap |= GCF_VWS;139 } /*endif*/140 141 92 } /* end of gc_init */ 142 93 … … 157 108 /* executable code */ 158 109 159 if (GCF_GEM & map)160 gm_exit( map & WDWMASK );161 162 110 if (GCF_XWDW & map) 163 111 xw_exit( map & WDWMASK ); 164 165 if (GCF_BGI & map)166 bg_exit( map & WDWMASK );167 112 168 113 if (GCF_MEM & map) … … 172 117 ps_exit(); 173 118 174 if (GCF_CALCOMP & map)175 cc_exit();176 177 if (GCF_TEK & map)178 tk_exit();179 180 if (GCF_HPGL & map)181 hp_exit();182 183 if (GCF_DJ & map)184 dj_exit();185 186 if (GCF_VWS & map)187 vw_exit( map & WDWMASK );188 189 119 } /* end of gc_exit */ 190 120 … … 204 134 /* executable code */ 205 135 206 gm_finish();207 136 xw_finish(); 208 bg_finish();209 137 mm_finish(); 210 138 ps_finish(); 211 cc_finish();212 tk_finish();213 hp_finish();214 dj_finish();215 vw_finish();216 139 gcv_initmap = 0; 217 140 … … 238 161 /* executable code */ 239 162 240 if (GCF_GEM & map) {241 gm_resizewdw( map & WDWMASK, xpos, ypos, width, height, status );242 if (Severe(status)) return;243 } /*endif*/244 245 163 if (GCF_XWDW & map) { 246 164 xw_resizewdw( map & WDWMASK, xpos, ypos, width, height, status ); … … 248 166 } /*endif*/ 249 167 250 if (GCF_BGI & map) {251 bg_resizewdw( map & WDWMASK, xpos, ypos, width, height, status );252 if (Severe(status)) return;253 } /*endif*/254 255 168 if (GCF_PSF & map) { 256 169 ps_resize( xpos, ypos, width, height, status ); … … 258 171 } /*endif*/ 259 172 260 if (GCF_CALCOMP & map) {261 cc_resize( xpos, ypos, width, height, status );262 if (Severe(status)) return;263 } /*endif*/264 265 if (GCF_TEK & map) {266 tk_resize( xpos, ypos, width, height, status );267 if (Severe(status)) return;268 } /*endif*/269 270 if (GCF_HPGL & map) {271 hp_resize( xpos, ypos, width, height, status );272 if (Severe(status)) return;273 } /*endif*/274 275 if (GCF_DJ & map) {276 dj_resize( xpos, ypos, width, height, status );277 if (Severe(status)) return;278 } /*endif*/279 280 if (GCF_VWS & map) {281 vw_resizewdw( map & WDWMASK, xpos, ypos, width, height, status );282 if (Severe(status)) return;283 } /*endif*/284 285 173 } /* end of gc_resizewdw */ 286 174 … … 301 189 /* executable code */ 302 190 303 if (GCF_GEM & map)304 gm_popwdw( map & WDWMASK );305 306 191 if (GCF_XWDW & map) 307 192 xw_popwdw( map & WDWMASK ); 308 309 if (GCF_VWS & map)310 vw_popwdw( map & WDWMASK );311 193 312 194 } /* end of gc_popwdw */ … … 329 211 /* executable code */ 330 212 331 if (GCF_GEM & map)332 gm_setwdwname( map & WDWMASK, name );333 334 213 if (GCF_XWDW & map) 335 214 xw_setwdwname( map & WDWMASK, name ); 336 337 if (GCF_BGI & map)338 bg_setwdwname( map & WDWMASK, name );339 340 if (GCF_VWS & map)341 vw_setwdwname( map & WDWMASK, name );342 215 343 216 } /* end of gc_setwdwname */ … … 364 237 /* executable code */ 365 238 366 if (GCF_GEM & map) {367 gm_setstyle( map & WDWMASK, style, item, value, status );368 if (Severe(status)) return;369 } /*endif*/370 371 239 if (GCF_XWDW & map) { 372 240 xw_setstyle( map & WDWMASK, style, item, value, status ); … … 374 242 } /*endif*/ 375 243 376 if (GCF_BGI & map) {377 bg_setstyle( map & WDWMASK, style, item, value, status );378 if (Severe(status)) return;379 } /*endif*/380 381 if (GCF_MEM & map) {382 mm_setstyle( map & WDWMASK, style, item, value, status );383 if (Severe(status)) return;384 } /*endif*/385 386 244 if (GCF_PSF & map) { 387 245 ps_setstyle( style, item, value, status ); 388 if (Severe(status)) return;389 } /*endif*/390 391 if (GCF_CALCOMP & map) {392 cc_setstyle( style, item, value, status );393 if (Severe(status)) return;394 } /*endif*/395 396 if (GCF_TEK & map) {397 tk_setstyle( style, item, value, status );398 if (Severe(status)) return;399 } /*endif*/400 401 if (GCF_HPGL & map) {402 hp_setstyle( style, item, value, status );403 if (Severe(status)) return;404 } /*endif*/405 406 if (GCF_DJ & map) {407 dj_setstyle( style, item, value, status );408 if (Severe(status)) return;409 } /*endif*/410 411 if (GCF_VWS & map) {412 vw_setstyle( map & WDWMASK, style, item, value, status );413 246 if (Severe(status)) return; 414 247 } /*endif*/ … … 439 272 CSWAP(w,h) 440 273 441 if (GCF_GEM & map) {442 gm_setcoo( map & WDWMASK, x, y, w, h, status );443 if (Severe(status)) return;444 } /*endif*/445 446 274 if (GCF_XWDW & map) { 447 275 xw_setcoo( map & WDWMASK, x, y, w, h, status ); … … 449 277 } /*endif*/ 450 278 451 if (GCF_BGI & map) {452 bg_setcoo( map & WDWMASK, x, y, w, h, status );453 if (Severe(status)) return;454 } /*endif*/455 456 279 if (GCF_MEM & map) { 457 280 mm_setcoo( map & WDWMASK, x, y, w, h, status ); … … 464 287 } /*endif*/ 465 288 466 if (GCF_CALCOMP & map) {467 cc_setcoo( x, y, w, h, status );468 if (Severe(status)) return;469 } /*endif*/470 471 if (GCF_TEK & map) {472 tk_setcoo( x, y, w, h, status );473 if (Severe(status)) return;474 } /*endif*/475 476 if (GCF_HPGL & map) {477 hp_setcoo( x, y, w, h, status );478 if (Severe(status)) return;479 } /*endif*/480 481 if (GCF_DJ & map) {482 dj_setcoo( x, y, w, h, status );483 if (Severe(status)) return;484 } /*endif*/485 486 if (GCF_VWS & map) {487 vw_setcoo( map & WDWMASK, x, y, w, h, status );488 if (Severe(status)) return;489 } /*endif*/490 491 289 } /* end of gc_setcoo */ 492 290 … … 508 306 /* executable code */ 509 307 510 if (GCF_GEM & map)511 return gm_aspectratio( map & WDWMASK );512 513 308 if (GCF_XWDW & map) 514 309 return xw_aspectratio( map & WDWMASK ); 515 516 if (GCF_BGI & map)517 return bg_aspectratio( map & WDWMASK );518 310 519 311 if (GCF_PSF & map) 520 312 return ps_aspectratio(); 521 313 522 if (GCF_CALCOMP & map)523 return cc_aspectratio();524 525 if (GCF_TEK & map)526 return tk_aspectratio();527 528 if (GCF_HPGL & map)529 return hp_aspectratio();530 531 if (GCF_DJ & map)532 return dj_aspectratio();533 534 if (GCF_VWS & map)535 return vw_aspectratio( map & WDWMASK );536 537 314 return 1.0; 538 315 … … 558 335 CSWAP(x,y) 559 336 560 if (GCF_GEM & map)561 gm_moveto( map & WDWMASK, x, y );562 563 337 if (GCF_XWDW & map) 564 338 xw_moveto( map & WDWMASK, x, y ); 565 566 if (GCF_BGI & map)567 bg_moveto( map & WDWMASK, x, y );568 339 569 340 if (GCF_MEM & map) … … 572 343 if (GCF_PSF & map) 573 344 ps_moveto( x, y ); 574 575 if (GCF_CALCOMP & map)576 cc_moveto( x, y );577 578 if (GCF_TEK & map)579 tk_moveto( x, y );580 581 if (GCF_HPGL & map)582 hp_moveto( x, y );583 584 if (GCF_DJ & map)585 dj_moveto( x, y );586 587 if (GCF_VWS & map)588 vw_moveto( map & WDWMASK, x, y );589 345 590 346 } /* end of gc_moveto */ … … 610 366 CSWAP(x,y) 611 367 612 if (GCF_GEM & map)613 gm_drawto( map & WDWMASK, style, x, y );614 615 368 if (GCF_XWDW & map) 616 369 xw_drawto( map & WDWMASK, style, x, y ); 617 618 if (GCF_BGI & map)619 bg_drawto( map & WDWMASK, style, x, y );620 370 621 371 if (GCF_MEM & map) … … 624 374 if (GCF_PSF & map) 625 375 ps_drawto( style, x, y ); 626 627 if (GCF_CALCOMP & map)628 cc_drawto( style, x, y );629 630 if (GCF_TEK & map)631 tk_drawto( style, x, y );632 633 if (GCF_HPGL & map)634 hp_drawto( style, x, y );635 636 if (GCF_DJ & map)637 dj_drawto( style, x, y );638 639 if (GCF_VWS & map)640 vw_drawto( map & WDWMASK, style, x, y );641 376 642 377 } /* end of gc_drawto */ … … 661 396 662 397 CSWAP(x,y) 663 664 if (GCF_GEM & map)665 gm_setpixel( map & WDWMASK, style, x, y );666 398 667 399 if (GCF_MEM & map) … … 698 430 if (cnt < 2) return; 699 431 700 if (GCF_GEM & map) {701 gm_arrayplot( map & WDWMASK, style, cnt, red, xoff, xinc,702 yoff, yarr, yzoom, status );703 if (Severe(status)) return;704 } /*endif*/705 706 432 if (GCF_XWDW & map) { 707 433 xw_arrayplot( map & WDWMASK, style, cnt, red, xoff, xinc, … … 710 436 } /*endif*/ 711 437 712 if (GCF_BGI & map) {713 bg_arrayplot( map & WDWMASK, style, cnt, red, xoff, xinc,714 yoff, yarr, yzoom, status );715 if (Severe(status)) return;716 } /*endif*/717 718 438 if (GCF_MEM & map) { 719 439 mm_arrayplot( map & WDWMASK, style, cnt, red, xoff, xinc, … … 728 448 } /*endif*/ 729 449 730 if (GCF_CALCOMP & map) {731 cc_arrayplot( style, cnt, red, xoff, xinc, yoff, yarr,732 yzoom, status );733 if (Severe(status)) return;734 } /*endif*/735 736 if (GCF_TEK & map) {737 tk_arrayplot( style, cnt, red, xoff, xinc, yoff, yarr,738 yzoom, status );739 if (Severe(status)) return;740 } /*endif*/741 742 if (GCF_HPGL & map) {743 hp_arrayplot( style, cnt, red, xoff, xinc, yoff, yarr,744 yzoom, status );745 if (Severe(status)) return;746 } /*endif*/747 748 if (GCF_DJ & map) {749 dj_arrayplot( style, cnt, red, xoff, xinc, yoff, yarr,750 yzoom, status );751 if (Severe(status)) return;752 } /*endif*/753 754 if (GCF_VWS & map) {755 vw_arrayplot( map & WDWMASK, style, cnt, red, xoff, xinc,756 yoff, yarr, yzoom, status );757 if (Severe(status)) return;758 } /*endif*/759 760 450 } /* end of gc_arrayplot */ 761 451 … … 776 466 /* executable code */ 777 467 778 if (GCF_GEM & map)779 gm_erase( map & WDWMASK );780 781 468 if (GCF_XWDW & map) 782 469 xw_erase( map & WDWMASK ); 783 784 if (GCF_BGI & map)785 bg_erase( map & WDWMASK );786 470 787 471 if (GCF_MEM & map) … … 790 474 if (GCF_PSF & map) 791 475 ps_erase(); 792 793 if (GCF_CALCOMP & map)794 cc_erase();795 796 if (GCF_TEK & map)797 tk_erase();798 799 if (GCF_HPGL & map)800 hp_erase();801 802 if (GCF_DJ & map)803 dj_erase();804 805 if (GCF_VWS & map)806 vw_erase( map & WDWMASK );807 476 808 477 } /* end of gc_erase */ … … 829 498 CSWAP(x,y) 830 499 831 if (GCF_GEM & map)832 gm_text( map & WDWMASK, style, x, y, text );833 834 500 if (GCF_XWDW & map) 835 501 xw_text( map & WDWMASK, style, x, y, text ); 836 837 if (GCF_BGI & map)838 bg_text( map & WDWMASK, style, x, y, text );839 502 840 503 if (GCF_MEM & map) … … 844 507 ps_text( style, x, y, text ); 845 508 846 if (GCF_CALCOMP & map)847 cc_text( style, x, y, text );848 849 if (GCF_TEK & map)850 tk_text( style, x, y, text );851 852 if (GCF_HPGL & map)853 hp_text( style, x, y, text );854 855 if (GCF_DJ & map)856 dj_text( style, x, y, text );857 858 if (GCF_VWS & map)859 vw_text( map & WDWMASK, style, x, y, text );860 861 509 } /* end of gc_text */ 862 510 … … 878 526 /* executable code */ 879 527 880 if (GCF_GEM & map)881 gm_write( map & WDWMASK, text );882 883 528 if (GCF_XWDW & map) 884 529 xw_write( map & WDWMASK, text ); 885 886 if (GCF_BGI & map)887 bg_write( map & WDWMASK, text );888 530 889 531 if (GCF_STDCH & map) 890 532 printf( "%s", text ); 891 533 892 if (GCF_VWS & map)893 vw_write( map & WDWMASK, text );894 895 if (GCF_TEK & map)896 tk_write( text );897 898 534 if (GCF_EXTERN & map && gcv_writeext != NULL) 899 535 (*gcv_writeext)( text ); … … 918 554 /* executable code */ 919 555 920 if (GCF_GEM & map)921 gm_wrtch( map & WDWMASK, ch );922 923 556 if (GCF_XWDW & map) 924 557 xw_wrtch( map & WDWMASK, ch ); 925 926 if (GCF_BGI & map)927 bg_wrtch( map & WDWMASK, ch );928 558 929 559 if (GCF_STDCH & map) 930 560 printf( "%c", ch ); 931 561 932 if (GCF_VWS & map)933 vw_wrtch( map & WDWMASK, ch );934 935 if (GCF_TEK & map)936 tk_wrtch( ch );937 938 562 } /* end of gc_wrtch */ 939 563 … … 953 577 { 954 578 /* executable code */ 955 956 if (GCF_GEM & map)957 return gm_txtwidth( map & WDWMASK );958 959 if (GCF_BGI & map)960 return bg_txtwidth( map & WDWMASK );961 579 962 580 if (GCF_STDCH & map) … … 983 601 /* executable code */ 984 602 985 if (GCF_GEM & map)986 return gm_txtheight( map & WDWMASK );987 988 if (GCF_BGI & map)989 return bg_txtheight( map & WDWMASK );990 991 603 if (GCF_STDCH & map) 992 604 return 24; … … 1012 624 /* executable code */ 1013 625 1014 if (GCF_GEM & map)1015 return gm_chheight( map & WDWMASK );1016 1017 626 if (GCF_XWDW & map) 1018 627 return xw_chheight( map & WDWMASK ); 1019 1020 if (GCF_BGI & map)1021 return bg_chheight( map & WDWMASK );1022 628 1023 629 return 0.0; … … 1043 649 /* executable code */ 1044 650 1045 if (GCF_GEM & map) {1046 gm_read( map & WDWMASK, maxlth, text );1047 return;1048 } /*endif*/1049 1050 651 if (GCF_XWDW & map) { 1051 652 xw_read( map & WDWMASK, maxlth, text ); … … 1053 654 } /*endif*/ 1054 655 1055 if (GCF_BGI & map) {1056 bg_read( map & WDWMASK, maxlth, text );1057 return;1058 } /*endif*/1059 1060 if (GCF_VWS & map) {1061 vw_read( map & WDWMASK, maxlth, text );1062 return;1063 } /*endif*/1064 1065 656 fgets( text, maxlth, stdin ); 1066 657 … … 1084 675 { 1085 676 /* executable code */ 1086 1087 if (GCF_GEM & map) {1088 gm_getloc( map & WDWMASK, x, y, ch );1089 CSWAP(*x,*y)1090 return;1091 } /*endif*/1092 677 1093 678 if (GCF_XWDW & map) { … … 1097 682 } /*endif*/ 1098 683 1099 if (GCF_BGI & map) {1100 bg_getloc( map & WDWMASK, x, y, ch );1101 CSWAP(*x,*y)1102 return;1103 } /*endif*/1104 1105 if (GCF_VWS & map) {1106 vw_getloc( map & WDWMASK, x, y, ch );1107 CSWAP(*x,*y)1108 return;1109 } /*endif*/1110 1111 if (GCF_TEK & map) {1112 tk_getloc( x, y, ch );1113 CSWAP(*x,*y)1114 return;1115 } /*endif*/1116 1117 684 } /* end of gc_getloc */ 1118 685 … … 1134 701 /* executable code */ 1135 702 1136 gm_set_outputdir( dir, status );1137 if (Severe(status)) return;1138 bg_set_outputdir( dir, status );1139 if (Severe(status)) return;1140 703 ps_set_outputdir( dir, status ); 1141 if (Severe(status)) return;1142 cc_set_outputdir( dir, status );1143 if (Severe(status)) return;1144 tk_set_outputdir( dir, status );1145 if (Severe(status)) return;1146 hp_set_outputdir( dir, status );1147 if (Severe(status)) return;1148 dj_set_outputdir( dir, status );1149 704 if (Severe(status)) return; 1150 705 xw_set_outputdir( dir, status ); 1151 706 if (Severe(status)) return; 1152 vw_set_outputdir( dir, status );1153 if (Severe(status)) return;1154 707 1155 708 } /* end of gc_set_outputdir */ … … 1172 725 /* executable code */ 1173 726 1174 gm_set_inputdir( dir, status );1175 if (Severe(status)) return;1176 bg_set_inputdir( dir, status );1177 if (Severe(status)) return;1178 727 ps_set_inputdir( dir, status ); 1179 728 if (Severe(status)) return; 1180 cc_set_inputdir( dir, status );1181 if (Severe(status)) return;1182 tk_set_inputdir( dir, status );1183 if (Severe(status)) return;1184 hp_set_inputdir( dir, status );1185 if (Severe(status)) return;1186 dj_set_inputdir( dir, status );1187 if (Severe(status)) return;1188 729 xw_set_inputdir( dir, status ); 1189 if (Severe(status)) return;1190 vw_set_inputdir( dir, status );1191 730 if (Severe(status)) return; 1192 731 … … 1212 751 /* executable code */ 1213 752 1214 if (GCF_GEM & map) {1215 gm_setpar( item, value, status );1216 if (Severe(status)) return;1217 } /*endif*/1218 1219 if (GCF_BGI & map) {1220 bg_setpar( item, value, status );1221 if (Severe(status)) return;1222 } /*endif*/1223 1224 753 if (GCF_PSF & map) { 1225 754 ps_setpar( item, value, status ); 1226 if (Severe(status)) return;1227 } /*endif*/1228 1229 if (GCF_CALCOMP & map) {1230 cc_setpar( item, value, status );1231 if (Severe(status)) return;1232 } /*endif*/1233 1234 if (GCF_TEK & map) {1235 tk_setpar( item, value, status );1236 if (Severe(status)) return;1237 } /*endif*/1238 1239 if (GCF_HPGL & map) {1240 hp_setpar( item, value, status );1241 if (Severe(status)) return;1242 } /*endif*/1243 1244 if (GCF_DJ & map) {1245 dj_setpar( item, value, status );1246 if (Severe(status)) return;1247 } /*endif*/1248 1249 if (GCF_VWS & map) {1250 vw_setpar( item, value, status );1251 755 if (Severe(status)) return; 1252 756 } /*endif*/ … … 1314 818 1315 819 /* executable code */ 1316 1317 # ifdef BC_G_GEM1318 if (GCF_GEM & dst) {1319 pb.wpb.pbtype = GBC_WPAINT;1320 pb.wpb.prepare = gm_prepare;1321 pb.wpb.moveto = gm_moveto;1322 pb.wpb.drawto = gm_drawto;1323 pb.wpb.arrayplot = gm_arrayplot;1324 pb.wpb.text = gm_text;1325 pb.wpb.setstyle = gm_setstyle;1326 pb.wpb.setcoo = gm_setcoo;1327 pb.wpb.cleanup = gm_cleanup;1328 mm_playback( src & WDWMASK, dst & WDWMASK, &pb, outf, status );1329 if (Severe(status)) return;1330 } /*endif*/1331 # endif /* BC_G_GEM */1332 820 1333 821 # ifdef BC_G_XWDW … … 1347 835 # endif /* BC_G_XWDW */ 1348 836 1349 # ifdef BC_G_BGI1350 if (GCF_BGI & dst) {1351 pb.wpb.pbtype = GBC_WPAINT;1352 pb.wpb.prepare = bg_prepare;1353 pb.wpb.moveto = bg_moveto;1354 pb.wpb.drawto = bg_drawto;1355 pb.wpb.arrayplot = bg_arrayplot;1356 pb.wpb.text = bg_text;1357 pb.wpb.setstyle = bg_setstyle;1358 pb.wpb.setcoo = bg_setcoo;1359 pb.wpb.cleanup = bg_cleanup;1360 mm_playback( src & WDWMASK, dst & WDWMASK, &pb, outf, status );1361 if (Severe(status)) return;1362 } /*endif*/1363 # endif /* BC_G_BGI */1364 1365 837 # ifdef BC_G_POSTSCRIPT 1366 838 if (GCF_PSF & dst) { … … 1379 851 # endif /* BC_G_POSTSCRIPT */ 1380 852 1381 # ifdef BC_G_CALCOMP1382 if (GCF_CALCOMP & dst) {1383 pb.ppb.pbtype = GBC_PPAINT;1384 pb.ppb.prepare = cc_prepare;1385 pb.ppb.moveto = cc_moveto;1386 pb.ppb.drawto = cc_drawto;1387 pb.ppb.arrayplot = cc_arrayplot;1388 pb.ppb.text = cc_text;1389 pb.ppb.setstyle = cc_setstyle;1390 pb.ppb.setcoo = cc_setcoo;1391 pb.ppb.cleanup = cc_cleanup;1392 mm_playback( src & WDWMASK, dst & WDWMASK, &pb, outf, status );1393 if (Severe(status)) return;1394 } /*endif*/1395 # endif /* BC_G_CALCOMP */1396 1397 # ifdef BC_G_TEK1398 if (GCF_TEK & dst) {1399 pb.ppb.pbtype = GBC_PPAINT;1400 pb.ppb.prepare = tk_prepare;1401 pb.ppb.moveto = tk_moveto;1402 pb.ppb.drawto = tk_drawto;1403 pb.ppb.arrayplot = tk_arrayplot;1404 pb.ppb.text = tk_text;1405 pb.ppb.setstyle = tk_setstyle;1406 pb.ppb.setcoo = tk_setcoo;1407 pb.ppb.cleanup = tk_cleanup;1408 mm_playback( src & WDWMASK, dst & WDWMASK, &pb, outf, status );1409 if (Severe(status)) return;1410 } /*endif*/1411 # endif /* BC_G_TEK */1412 1413 # ifdef BC_G_HPGL1414 if (GCF_HPGL & dst) {1415 pb.ppb.pbtype = GBC_PPAINT;1416 pb.ppb.prepare = hp_prepare;1417 pb.ppb.moveto = hp_moveto;1418 pb.ppb.drawto = hp_drawto;1419 pb.ppb.arrayplot = hp_arrayplot;1420 pb.ppb.text = hp_text;1421 pb.ppb.setstyle = hp_setstyle;1422 pb.ppb.setcoo = hp_setcoo;1423 pb.ppb.cleanup = hp_cleanup;1424 mm_playback( src & WDWMASK, dst & WDWMASK, &pb, outf, status );1425 if (Severe(status)) return;1426 } /*endif*/1427 # endif /* BC_G_HPGL */1428 1429 # ifdef BC_G_DESKJET1430 if (GCF_DJ & dst) {1431 pb.ppb.pbtype = GBC_PPAINT;1432 pb.ppb.prepare = dj_prepare;1433 pb.ppb.moveto = dj_moveto;1434 pb.ppb.drawto = dj_drawto;1435 pb.ppb.arrayplot = dj_arrayplot;1436 pb.ppb.text = dj_text;1437 pb.ppb.setstyle = dj_setstyle;1438 pb.ppb.setcoo = dj_setcoo;1439 pb.ppb.cleanup = dj_cleanup;1440 mm_playback( src & WDWMASK, dst & WDWMASK, &pb, outf, status );1441 if (Severe(status)) return;1442 } /*endif*/1443 # endif /* BC_G_DESKJET */1444 1445 # ifdef BC_G_VWS1446 if (GCF_VWS & dst) {1447 vw_cleanup( src & WDWMASK, outf, status );1448 } /*endif*/1449 # endif /* BC_G_VWS */1450 1451 853 } /* end of gc_playback */ 1452 854 … … 1494 896 } /*endif*/ 1495 897 1496 if (GCF_CALCOMP & map) {1497 cc_cleanup( outf, status );1498 if (Severe(status)) return;1499 } /*endif*/1500 1501 if (GCF_HPGL & map) {1502 hp_cleanup( outf, status );1503 if (Severe(status)) return;1504 } /*endif*/1505 1506 if (GCF_DJ & map) {1507 dj_cleanup( outf, status );1508 if (Severe(status)) return;1509 } /*endif*/1510 1511 if (GCF_VWS & map) {1512 vw_cleanup( map & WDWMASK, outf, status );1513 if (Severe(status)) return;1514 } /*endif*/1515 1516 898 } /* end of gc_closeplot */ 1517 899 1518 900 1519 901 1520 902 /*------------------------------------------------------------------------*/ 1521 903 … … 1539 921 ps_arrayswap( on_off ); 1540 922 # endif 1541 # ifdef BC_G_CALCOMP1542 cc_arrayswap( on_off );1543 # endif1544 # ifdef BC_G_TEK1545 tk_arrayswap( on_off );1546 # endif1547 # ifdef BC_G_HPGL1548 hp_arrayswap( on_off );1549 # endif1550 # ifdef BC_G_BGI1551 bg_arrayswap( on_off );1552 # endif1553 # ifdef BC_G_GEM1554 gm_arrayswap( on_off );1555 # endif1556 # ifdef BC_G_DESKJET1557 dj_arrayswap( on_off );1558 # endif1559 # ifdef BC_G_VWS1560 vw_arrayswap( on_off );1561 # endif1562 923 1563 924 } /* end of gc_swap */ -
SH_SHM/trunk/source/newgraph/memfile.c
r16 r341 357 357 sy_fbwrite( &r, (int)sizeof(MFC_REAL), 1L, mfv_file[id] ); 358 358 } else { 359 #ifdef XXX360 mf_open( id, mfv_defswitch, "a", status );361 if (*status != MFE_NOERROR) return;362 mf_writereal( id, r, status );363 #endif364 359 /* fprintf( stderr, "mf_writereal: ignored output for chan %d\n", id ); */ 365 360 } /*endif*/ … … 403 398 sy_fbwrite( &i, (int)sizeof(int), 1L, mfv_file[id] ); 404 399 } else { 405 #ifdef XXX406 mf_open( id, mfv_defswitch, "a", status );407 if (*status != MFE_NOERROR) return;408 mf_writeint( id, i, status );409 #endif410 400 /* fprintf( stderr, "mf_writeint: ignored output for chan %d\n", id ); */ 411 401 } /*endif*/ … … 449 439 sy_fbwrite( &l, (int)sizeof(long), 1L, mfv_file[id] ); 450 440 } else { 451 #ifdef XXX452 mf_open( id, mfv_defswitch, "a", status );453 if (*status != MFE_NOERROR) return;454 mf_writelong( id, l, status );455 #endif456 441 /* fprintf( stderr, "mf_writelong: ignored output for chan %d\n", id ); */ 457 442 } /*endif*/ -
SH_SHM/trunk/source/newgraph/psch.c
r16 r341 73 73 static int psv_strokenum=5000; /* max number of lineto's between stroke's */ 74 74 static char psv_headerfile[BC_FILELTH+1]=PSHEADER; /* PS header file */ 75 #ifdef XXX76 static char psv_printfmt[BC_LINELTH+1]= /* print command */77 {"lpr -P lj %s"};78 #endif79 75 80 76 /* prototypes of local routines */ … … 641 637 if (outf != NULL) strcpy( outf, str ); 642 638 643 # ifdef XXX644 /* send it to the printer */645 if (*psv_printfmt != '\0') {646 sprintf( cmd, psv_printfmt, str );647 sy_system( cmd, status );648 } /*endif*/649 # endif650 651 639 /* open PostScript file */ 652 640 psv_pf = sy_fopen( psv_currpsf, "w" ); -
SH_SHM/trunk/source/newgraph/psusrdef.h
r16 r341 222 222 223 223 #define ps_charsize(s,x,t) 224 #ifdef XXX225 void ps_charsize( int style, float size, STATUS *status );226 227 /* sets character size in units of display height228 *229 * parameters of routine230 * int style; input; style number231 * float size; input; size of character in units of display height232 * STATUS *status; output; return status233 */234 #endif235 236 /*----------------------------------------------------------------------------*/237 238 224 239 225 #define ps_linestyle(s,l,t) 240 #ifdef XXX241 void ps_linestyle( int style, int linestyle, STATUS *status );242 243 /* sets line linestyle in style block number "style"244 *245 * parameters of routine246 * int style; input; style block number247 * int linestyle; input; number of line style248 * STATUS *status; output; return status249 */250 #endif251 226 252 227 #define ps_linewidth(s,l,t) 253 228 254 /*----------------------------------------------------------------------------*/255 256 257 229 #define ps_color(s,r,g,b,t) 258 #ifdef XXX259 void ps_color( int style, float red, float green, float blue, STATUS *status );260 261 /* sets color of style block "style"262 *263 * parameters of routine264 * int style; input; style block number265 * float red, green, blue; input; red, green and blue intensities (0..1)266 * STATUS *status; output; return status267 */268 #endif269 230 270 231 /*----------------------------------------------------------------------------*/ … … 286 247 287 248 #define ps_aspectratio() 1.0 288 #ifdef XXX289 float ps_aspectratio();290 291 /* returns ratio of width to height of output292 * no parameters293 */294 #endif295 296 /*----------------------------------------------------------------------------*/297 249 298 250 -
SH_SHM/trunk/source/newgraph/xwch.c
r48 r341 13 13 #include <ctype.h> 14 14 #include BASECNST 15 #ifdef BC_VAX16 #include <decw$include:xlib.h>17 #include <decw$include:xutil.h>18 #include <decw$include:xatom.h>19 #include <decw$include:cursorfont.h>20 #endif21 #ifdef BC_SUN22 15 #include <X11/Xlib.h> 23 16 #include <X11/Xatom.h> 24 17 #include <X11/cursorfont.h> 25 /* typedef char *caddr_t; */ /* I really don't know why this is necessary on HP */26 18 #include <X11/Xutil.h> 27 #endif28 19 #include BC_SYSBASE 29 20 #include "graphbas.h" … … 155 146 int i; /* counter */ 156 147 XSetWindowAttributes xswa; /* set attribute block */ 157 XSizeHints xsh; /* size hints */ 148 XSizeHints xsh; /* size hints */ 158 149 XWMHints xwmh; /* window manager hints */ 159 150 char str[MAXSTRLTH+1]; /* scratch string */ … … 1798 1789 &exact_color ); 1799 1790 } /*endif*/ 1800 #ifdef XXX1801 if (xstatus == 0) {1802 *status = XWE_COLALLOC;1803 return;1804 } /*endif*/1805 #endif1806 1791 XSetForeground( xwv_dsp, xwv_gc[style], screen_color.pixel ); 1807 1792
Note: See TracChangeset
for help on using the changeset viewer.