#include "ObjectStructure.h"Include dependency graph for drawMarks.h:

This graph shows which files directly or indirectly include this file:

Go to the source code of this file.
Functions | |
| int | DrawNewMarks (sciPointObj *pobj, int n1, int *xm, int *ym, int *DPI) |
| void | DrawMarks3D (sciPointObj *pobj, int n1, int *xm, int *ym, int *DPI) |
| void | drawPolyMarks (sciPointObj *pObj, int nbMarks, int xCoord[], int yCoord[], int DPI[2]) |
| int | DrawMark_FullDot (int xmi, int ymi, double size, int foreground, int background, int pixel_offset) |
| int | DrawMark_Plus (int xmi, int ymi, int size, int foreground, int pixel_offset) |
| int | DrawMark_Cross (int xmi, int ymi, int size, int foreground, int pixel_offset) |
| int | DrawMark_FullDiamond (int xmi, int ymi, int size, int foreground, int background) |
| int | DrawMark_FullTriangleUp (int xmi, int ymi, int size, int foreground, int background) |
| int | DrawMark_FullTriangleDown (int xmi, int ymi, int size, int foreground, int background) |
| int | DrawMark_Asterisk (int xmi, int ymi, int size, int foreground, int pixel_offset) |
| int | DrawMark_FullSquare (int xmi, int ymi, int size, int foreground, int background, int pixel_offset) |
| int | DrawMark_FullTriangleRight (int xmi, int ymi, int size, int foreground, int background) |
| int | DrawMark_FullTriangleLeft (int xmi, int ymi, int size, int foreground, int background) |
| int | DrawMark_FullPentagram (int xmi, int ymi, int size, int foreground, int background) |
| int | CheckPixelStatus (void) |
| int CheckPixelStatus | ( | void | ) |
This function is used to determine how the pixel data is given to Xt method (like XDrawLines) 0 : pixel itself 1 : pixel's interval Explanation : i.e.in X11 (same thing using Win32 driver), with x2=x1+1 and y1=y2, we have : XDrawLine(x1,y1,x1,y1) does nothing (no pixel lit) XDrawLine(x1,y1,x2,y2) ONE pixel lit BUT the corresponding function with driver Gif (and others?) give us: for now (and only for marks), I make a trick using a pixel_offset set to 0 or 1 depending on the driver.
Definition at line 713 of file drawMarks.c.
References GetDriverId().
00714 { 00715 if( GetDriverId() == 0 ) /* X11 or Win32 driver */ 00716 { 00717 return 1 ; 00718 } 00719 else 00720 { 00721 return 0 ; 00722 } 00723 }
Here is the call graph for this function:

Definition at line 476 of file drawMarks.c.
References C2F, dr(), int, L, PD0, PI0, and v.
Referenced by DrawNewMarks().
00477 { 00478 int two = 2; 00479 int xmasterix[2]; 00480 int ymasterix[2]; 00481 int sizecross = (int)(0.8*size); 00482 int v = 0 ; 00483 int closeflag = 0; 00484 double dv = 0.0 ; 00485 00486 C2F (dr) ("xset", "dashes", &foreground, &foreground, &v, &v, &v, &v, &dv, 00487 &dv, &dv, &dv, 5L, 4096); 00488 C2F (dr) ("xset", "foreground", &foreground, &foreground, &v, &v, &v, &v, 00489 &dv, &dv, &dv, &dv, 5L, 4096); 00490 00491 /* the "+" */ 00492 xmasterix[0] = xmi - size; 00493 xmasterix[1] = xmi + size +pixel_offset; 00494 ymasterix[0] = ymasterix[1] = ymi; 00495 C2F (dr) ("xlines", "xv", &two, xmasterix, ymasterix, &closeflag, PI0, PI0, PD0, PD0, PD0, PD0,6L,2L); 00496 00497 xmasterix[0] = xmasterix[1] = xmi; 00498 ymasterix[0] = ymi - size; 00499 ymasterix[1] = ymi + size +pixel_offset; 00500 C2F (dr) ("xlines", "xv", &two, xmasterix, ymasterix, &closeflag, PI0, PI0, PD0, PD0, PD0, PD0,6L,2L); 00501 /* end */ 00502 00503 /* the "/" */ 00504 xmasterix[0] =(int)( xmi - ceil(sizecross)); 00505 xmasterix[1] =(int)( xmi + ceil(sizecross)+pixel_offset); 00506 ymasterix[0] = (int)(ymi + ceil(sizecross)); 00507 ymasterix[1] = (int)(ymi - ceil(sizecross)-pixel_offset); 00508 C2F (dr) ("xlines", "xv", &two, xmasterix, ymasterix, &closeflag, PI0, PI0, PD0, PD0, PD0, PD0,6L,2L); 00509 /* end */ 00510 00511 /* the "\" */ 00512 xmasterix[0] = (int)(xmi - ceil(sizecross)); 00513 xmasterix[1] = (int)(xmi + ceil(sizecross)+pixel_offset); 00514 ymasterix[0] = (int)(ymi - ceil(sizecross)); 00515 ymasterix[1] = (int)(ymi + ceil(sizecross)+pixel_offset); 00516 C2F (dr) ("xlines", "xv", &two, xmasterix, ymasterix, &closeflag, PI0, PI0, PD0, PD0, PD0, PD0,6L,2L); 00517 /* end */ 00518 00519 return 0; 00520 }
Here is the call graph for this function:

Here is the caller graph for this function:

Definition at line 329 of file drawMarks.c.
References C2F, dr(), int, L, PD0, PI0, and v.
Referenced by DrawNewMarks().
00330 { 00331 int two = 2; 00332 int xmasterix[2]; 00333 int ymasterix[2]; 00334 int v = 0 ; 00335 int closeflag=0; 00336 double dv = 0.0 ; 00337 00338 C2F (dr) ("xset", "dashes", &foreground, &foreground, &v, &v, &v, &v, &dv, 00339 &dv, &dv, &dv, 5L, 4096); 00340 C2F (dr) ("xset", "foreground", &foreground, &foreground, &v, &v, &v, &v, 00341 &dv, &dv, &dv, &dv, 5L, 4096); 00342 00343 /* the "/" */ 00344 xmasterix[0] = (int) (xmi - size); 00345 xmasterix[1] = (int) (xmi + size + pixel_offset); 00346 ymasterix[0] = (int) (ymi + size); 00347 ymasterix[1] = (int) (ymi - size - pixel_offset); 00348 00349 C2F (dr) ("xlines", "xv", &two, xmasterix, ymasterix, &closeflag, PI0, PI0, PD0, PD0, PD0, PD0,6L,2L); 00350 /* end */ 00351 00352 /* the "\" */ 00353 xmasterix[0] = (int) (xmi - size); 00354 xmasterix[1] = (int) (xmi + size + pixel_offset); 00355 ymasterix[0] = (int) (ymi - size); 00356 ymasterix[1] = (int) (ymi + size + pixel_offset); 00357 C2F (dr) ("xlines", "xv", &two, xmasterix, ymasterix, &closeflag, PI0, PI0, PD0, PD0, PD0, PD0,6L,2L); 00358 /* end */ 00359 00360 return 0; 00361 }
Here is the call graph for this function:

Here is the caller graph for this function:

Definition at line 365 of file drawMarks.c.
References C2F, dr(), L, PD0, PI0, and v.
Referenced by DrawNewMarks().
00366 { 00367 int four = 4 ; 00368 int one = 1 ; 00369 int xmdiamond[4]; 00370 int ymdiamond[4]; 00371 int v = 0 ; 00372 double dv = 0.0 ; 00373 00374 xmdiamond[0] = xmi - size; 00375 xmdiamond[1] = xmi; 00376 xmdiamond[2] = xmi + size; 00377 xmdiamond[3] = xmi; 00378 00379 ymdiamond[0] = ymi; 00380 ymdiamond[1] = ymi + size; 00381 ymdiamond[2] = ymi; 00382 ymdiamond[3] = ymi - size; 00383 00384 C2F (dr) ("xset", "dashes", &background, &background, &v, &v, &v, &v, &dv, 00385 &dv, &dv, &dv, 5L, 4096); 00386 C2F (dr) ("xset", "foreground", &background, &background, &v, &v, &v, &v, 00387 &dv, &dv, &dv, &dv, 5L, 4096); 00388 00389 C2F (dr) ("xarea", "v", &four, xmdiamond, ymdiamond, &one, PI0, PI0, PD0, PD0, PD0, PD0, 5L,0L); 00390 00391 if ( foreground != background ) 00392 { 00393 C2F (dr) ("xset", "dashes", &foreground, &foreground, &v, &v, &v, &v, &dv, 00394 &dv, &dv, &dv, 5L, 4096); 00395 C2F (dr) ("xset", "foreground", &foreground, &foreground, &v, &v, &v, &v, 00396 &dv, &dv, &dv, &dv, 5L, 4096); 00397 00398 C2F (dr) ("xlines", "xv", &four, xmdiamond, ymdiamond, &one, PI0, PI0, PD0, PD0, PD0, PD0,6L,2L); 00399 } 00400 00401 return 0; 00402 }
Here is the call graph for this function:

Here is the caller graph for this function:

| int DrawMark_FullDot | ( | int | xmi, | |
| int | ymi, | |||
| double | size, | |||
| int | foreground, | |||
| int | background, | |||
| int | pixel_offset | |||
| ) |
Definition at line 267 of file drawMarks.c.
References C2F, dr(), int, L, PD0, and v.
Referenced by DrawNewMarks().
00268 { 00269 int x1 = (int) (xmi - size/2); 00270 int yy1= (int) (ymi - size/2); 00271 int w1 = (int) size+pixel_offset; 00272 int h1 = (int) size+pixel_offset; 00273 integer v = 0; 00274 double dv = 0.0 ; 00275 00276 integer angle1 = 0; 00277 integer angle2 = 64*360; 00278 00279 C2F (dr) ("xset", "dashes", &background, &background, &v, &v, &v, &v, &dv, 00280 &dv, &dv, &dv, 5L, 4096); 00281 C2F (dr) ("xset", "foreground", &background, &background, &v, &v, &v, &v, 00282 &dv, &dv, &dv, &dv, 5L, 4096); 00283 00284 C2F (dr) ("xfarc", "xv", &x1, &yy1, &w1, &h1, &angle1, &angle2, PD0, PD0, PD0,PD0, 5L, 0L); 00285 00286 C2F (dr) ("xset", "dashes", &foreground, &foreground, &v, &v, &v, &v, &dv, 00287 &dv, &dv, &dv, 5L, 4096); 00288 C2F (dr) ("xset", "foreground", &foreground, &foreground, &v, &v, &v, &v, 00289 &dv, &dv, &dv, &dv, 5L, 4096); 00290 00291 C2F (dr) ("xarc", "xv", &x1, &yy1, &w1, &h1, &angle1, &angle2, PD0, PD0, PD0,PD0, 5L, 0L); 00292 00293 return 0; 00294 }
Here is the call graph for this function:

Here is the caller graph for this function:

Definition at line 619 of file drawMarks.c.
References C2F, DEG2RAD, dr(), int, L, PD0, PI0, r2, and v.
Referenced by DrawNewMarks().
00620 { 00621 int ten = 10, one = 1; 00622 int xmpoints1[5],ympoints1[5]; 00623 int xmpoints2[5],ympoints2[5]; 00624 int xmpoints[10], ympoints[10]; 00625 int v = 0 ; 00626 double dv = 0.0 ; 00627 double angle72 = DEG2RAD(72) ; 00628 double angle54 = DEG2RAD(54) ; 00629 double angle36 = DEG2RAD(36) ; 00630 00631 double r2 = size*cos( angle72 )/cos( angle36 ); 00632 00633 xmpoints1[0] = (int)(xmi - size*cos(angle54)); 00634 ympoints1[0] = (int)(ymi + size*sin(angle54)); 00635 00636 xmpoints1[1] = (int)(xmi + size*cos(angle54)); 00637 ympoints1[1] = (int)(ymi + size*sin(angle54)); 00638 00639 xmpoints1[2] = (int)(xmi + (xmpoints1[1] - xmi) *cos(angle72) + (ympoints1[1] - ymi) *sin(angle72)); 00640 ympoints1[2] = (int)(ymi - (xmpoints1[1] - xmi) *sin(angle72) + (ympoints1[1] - ymi) *cos(angle72)); 00641 00642 xmpoints1[3] = xmi; 00643 ympoints1[3] = ymi - size; 00644 00645 xmpoints1[4] = (int)(xmi + (xmpoints1[0] - xmi) *cos(-angle72) + (ympoints1[0] - ymi) *sin(-angle72)); 00646 ympoints1[4] = (int)(ymi - (xmpoints1[0] - xmi) *sin(-angle72) + (ympoints1[0] - ymi) *cos(-angle72)); 00647 00648 00649 xmpoints2[0] = (int)( xmi - r2*sin(angle36)); 00650 ympoints2[0] = (int)(ymi - size*cos(angle72)); 00651 00652 xmpoints2[1] = (int)(xmi + r2*sin(angle36)); 00653 ympoints2[1] = (int)(ymi - size*cos(angle72)); 00654 00655 xmpoints2[2] = (int)(xmi + (xmpoints2[1] - xmi)*cos(-angle72) + (ympoints2[1] - ymi) *sin(-angle72)); 00656 ympoints2[2] = (int)(ymi - (xmpoints2[1] - xmi)*sin(-angle72) + (ympoints2[1] - ymi) *cos(-angle72)); 00657 00658 xmpoints2[3] = xmi; 00659 ympoints2[3] = (int)(ymi + r2); 00660 00661 xmpoints2[4] = (int)(xmi + (xmpoints2[0] - xmi)*cos(angle72) + (ympoints2[0] - ymi) *sin(angle72)); 00662 ympoints2[4] = (int)(ymi - (xmpoints2[0] - xmi)*sin(angle72) + (ympoints2[0] - ymi) *cos(angle72)); 00663 00664 00665 xmpoints[0] = xmpoints2[4]; 00666 ympoints[0] = ympoints2[4]; 00667 00668 xmpoints[1] = xmpoints1[0]; 00669 ympoints[1] = ympoints1[0]; 00670 00671 xmpoints[2] = xmpoints2[3]; 00672 ympoints[2] = ympoints2[3]; 00673 00674 xmpoints[3] = xmpoints1[1]; 00675 ympoints[3] = ympoints1[1]; 00676 00677 xmpoints[4] = xmpoints2[2]; 00678 ympoints[4] = ympoints2[2]; 00679 00680 xmpoints[5] = xmpoints1[2]; 00681 ympoints[5] = ympoints1[2]; 00682 00683 xmpoints[6] = xmpoints2[1]; 00684 ympoints[6] = ympoints2[1]; 00685 00686 xmpoints[7] = xmpoints1[3]; 00687 ympoints[7] = ympoints1[3]; 00688 00689 xmpoints[8] = xmpoints2[0]; 00690 ympoints[8] = ympoints2[0]; 00691 00692 xmpoints[9] = xmpoints1[4]; 00693 ympoints[9] = ympoints1[4]; 00694 00695 00696 C2F (dr) ("xset", "dashes", &background, &background, &v, &v, &v, &v, &dv, 00697 &dv, &dv, &dv, 5L, 4096); 00698 C2F (dr) ("xset", "foreground", &background, &background, &v, &v, &v, &v, 00699 &dv, &dv, &dv, &dv, 5L, 4096); 00700 00701 C2F (dr) ("xarea", "v", &ten, xmpoints, ympoints, &one, PI0, PI0, PD0, PD0, PD0, PD0, 5L,0L); 00702 00703 C2F (dr) ("xset", "dashes", &foreground, &foreground, &v, &v, &v, &v, &dv, 00704 &dv, &dv, &dv, 5L, 4096); 00705 C2F (dr) ("xset", "foreground", &foreground, &foreground, &v, &v, &v, &v, 00706 &dv, &dv, &dv, &dv, 5L, 4096); 00707 00708 C2F (dr) ("xlines", "xv", &ten, xmpoints, ympoints, &one, PI0, PI0, PD0, PD0, PD0, PD0,6L,2L); 00709 00710 return 0; 00711 }
Here is the call graph for this function:

Here is the caller graph for this function:

| int DrawMark_FullSquare | ( | int | xmi, | |
| int | ymi, | |||
| int | size, | |||
| int | foreground, | |||
| int | background, | |||
| int | pixel_offset | |||
| ) |
Definition at line 522 of file drawMarks.c.
References C2F, dr(), L, PD0, PI0, and v.
Referenced by DrawNewMarks().
00523 { 00524 int x1 = xmi - size/2; 00525 int yy1= ymi - size/2; 00526 int w1 = size; 00527 int h1 = size; 00528 int v = 0 ; 00529 double dv = 0.0 ; 00530 00531 C2F (dr) ("xset", "dashes", &background, &background, &v, &v, &v, &v, &dv, 00532 &dv, &dv, &dv, 5L, 4096); 00533 C2F (dr) ("xset", "foreground", &background, &background, &v, &v, &v, &v, 00534 &dv, &dv, &dv, &dv, 5L, 4096); 00535 00536 C2F (dr) ("xfrect", "xv", &x1, &yy1, &w1, &h1, PI0, PI0, PD0, PD0, PD0,PD0, 5L, 0L); 00537 00538 C2F (dr) ("xset", "dashes", &foreground, &foreground, &v, &v, &v, &v, &dv, 00539 &dv, &dv, &dv, 5L, 4096); 00540 C2F (dr) ("xset", "foreground", &foreground, &foreground, &v, &v, &v, &v, 00541 &dv, &dv, &dv, &dv, 5L, 4096); 00542 00543 C2F (dr) ("xrect", "xv", &x1, &yy1, &w1, &h1, PI0, PI0, PD0, PD0, PD0,PD0, 5L, 0L); 00544 00545 00546 return 0; 00547 }
Here is the call graph for this function:

Here is the caller graph for this function:

Definition at line 442 of file drawMarks.c.
References C2F, dr(), int, L, PD0, PI0, and v.
Referenced by DrawNewMarks().
00443 { 00444 int three = 3 ; 00445 int one = 1; 00446 int xmtriangle[3]; 00447 int ymtriangle[3]; 00448 int v = 0 ; 00449 double dv = 0.0 ; 00450 00451 xmtriangle[0] = (int) (xmi - size/2); 00452 xmtriangle[1] = (int) (xmi + size/2); 00453 xmtriangle[2] = (int) (xmi); 00454 00455 ymtriangle[0] = (int) (ymi - size/3); 00456 ymtriangle[1] = (int) (ymi - size/3); 00457 ymtriangle[2] = (int) (ymi + 2*size/3); 00458 00459 C2F (dr) ("xset", "dashes", &background, &background, &v, &v, &v, &v, &dv, 00460 &dv, &dv, &dv, 5L, 4096); 00461 C2F (dr) ("xset", "foreground", &background, &background, &v, &v, &v, &v, 00462 &dv, &dv, &dv, &dv, 5L, 4096); 00463 00464 C2F (dr) ("xarea", "v", &three, xmtriangle, ymtriangle, &one, PI0, PI0, PD0, PD0, PD0, PD0, 5L,0L); 00465 00466 C2F (dr) ("xset", "dashes", &foreground, &foreground, &v, &v, &v, &v, &dv, 00467 &dv, &dv, &dv, 5L, 4096); 00468 C2F (dr) ("xset", "foreground", &foreground, &foreground, &v, &v, &v, &v, 00469 &dv, &dv, &dv, &dv, 5L, 4096); 00470 00471 C2F (dr) ("xlines", "xv", &three, xmtriangle, ymtriangle, &one, PI0, PI0, PD0, PD0, PD0, PD0,6L,2L); 00472 00473 return 0; 00474 }
Here is the call graph for this function:

Here is the caller graph for this function:

Definition at line 583 of file drawMarks.c.
References C2F, dr(), int, L, PD0, PI0, and v.
Referenced by DrawNewMarks().
00584 { 00585 00586 int three = 3 ; 00587 int one = 1; 00588 int xmtriangle[3]; 00589 int ymtriangle[3]; 00590 int v = 0 ; 00591 double dv = 0.0 ; 00592 00593 xmtriangle[0] = (int) (xmi + size/3); 00594 xmtriangle[1] = (int) (xmi + size/3); 00595 xmtriangle[2] = (int) (xmi - 2*size/3); 00596 00597 ymtriangle[0] = (int) (ymi - size/2); 00598 ymtriangle[1] = (int) (ymi + size/2); 00599 ymtriangle[2] = ymi; 00600 00601 C2F (dr) ("xset", "dashes", &background, &background, &v, &v, &v, &v, &dv, 00602 &dv, &dv, &dv, 5L, 4096); 00603 C2F (dr) ("xset", "foreground", &background, &background, &v, &v, &v, &v, 00604 &dv, &dv, &dv, &dv, 5L, 4096); 00605 00606 C2F (dr) ("xarea", "v", &three, xmtriangle, ymtriangle, &one, PI0, PI0, PD0, PD0, PD0, PD0, 5L,0L); 00607 00608 C2F (dr) ("xset", "dashes", &foreground, &foreground, &v, &v, &v, &v, &dv, 00609 &dv, &dv, &dv, 5L, 4096); 00610 C2F (dr) ("xset", "foreground", &foreground, &foreground, &v, &v, &v, &v, 00611 &dv, &dv, &dv, &dv, 5L, 4096); 00612 00613 C2F (dr) ("xlines", "xv", &three, xmtriangle, ymtriangle, &one, PI0, PI0, PD0, PD0, PD0, PD0,6L,2L); 00614 00615 00616 return 0; 00617 }
Here is the call graph for this function:

Here is the caller graph for this function:

Definition at line 549 of file drawMarks.c.
References C2F, dr(), int, L, PD0, PI0, and v.
Referenced by DrawNewMarks().
00550 { 00551 int three = 3 ; 00552 int one = 1; 00553 int xmtriangle[3]; 00554 int ymtriangle[3]; 00555 int v = 0 ; 00556 double dv = 0.0 ; 00557 00558 xmtriangle[0] = (int) (xmi - size/3); 00559 xmtriangle[1] = (int) (xmi - size/3); 00560 xmtriangle[2] = (int) (xmi + 2*size/3); 00561 00562 ymtriangle[0] = (int) (ymi - size/2); 00563 ymtriangle[1] = (int) (ymi + size/2); 00564 ymtriangle[2] = ymi; 00565 00566 C2F (dr) ("xset", "dashes", &background, &background, &v, &v, &v, &v, &dv, 00567 &dv, &dv, &dv, 5L, 4096); 00568 C2F (dr) ("xset", "foreground", &background, &background, &v, &v, &v, &v, 00569 &dv, &dv, &dv, &dv, 5L, 4096); 00570 00571 C2F (dr) ("xarea", "v", &three, xmtriangle, ymtriangle, &one, PI0, PI0, PD0, PD0, PD0, PD0, 5L,0L); 00572 00573 C2F (dr) ("xset", "dashes", &foreground, &foreground, &v, &v, &v, &v, &dv, 00574 &dv, &dv, &dv, 5L, 4096); 00575 C2F (dr) ("xset", "foreground", &foreground, &foreground, &v, &v, &v, &v, 00576 &dv, &dv, &dv, &dv, 5L, 4096); 00577 00578 C2F (dr) ("xlines", "xv", &three, xmtriangle, ymtriangle, &one, PI0, PI0, PD0, PD0, PD0, PD0,6L,2L); 00579 00580 return 0; 00581 }
Here is the call graph for this function:

Here is the caller graph for this function:

Definition at line 404 of file drawMarks.c.
References C2F, dr(), int, L, PD0, PI0, and v.
Referenced by DrawNewMarks().
00405 { 00406 int three = 3; 00407 int one=1; 00408 int xmtriangle[3]; 00409 int ymtriangle[3]; 00410 int v = 0 ; 00411 double dv = 0.0 ; 00412 00413 xmtriangle[0] = (int) (xmi - size/2); 00414 xmtriangle[1] = (int) (xmi + size/2); 00415 xmtriangle[2] = xmi; 00416 00417 ymtriangle[0] = (int) (ymi + size/3); 00418 ymtriangle[1] = (int) (ymi + size/3); 00419 ymtriangle[2] = (int) (ymi - 2*size/3); 00420 00421 C2F (dr) ("xset", "dashes", &background, &background, &v, &v, &v, &v, &dv, 00422 &dv, &dv, &dv, 5L, 4096); 00423 C2F (dr) ("xset", "foreground", &background, &background, &v, &v, &v, &v, 00424 &dv, &dv, &dv, &dv, 5L, 4096); 00425 00426 C2F (dr) ("xarea", "v", &three, xmtriangle, ymtriangle, &one, PI0, PI0, PD0, PD0, PD0, PD0, 5L,0L); 00427 00428 C2F (dr) ("xset", "dashes", &foreground, &foreground, &v, &v, &v, &v, &dv, 00429 &dv, &dv, &dv, 5L, 4096); 00430 00431 if( foreground != background ) 00432 { 00433 C2F (dr) ("xset", "foreground", &foreground, &foreground, &v, &v, &v, &v, 00434 &dv, &dv, &dv, &dv, 5L, 4096); 00435 00436 C2F (dr) ("xlines", "xv", &three, xmtriangle, ymtriangle, &one, PI0, PI0, PD0, PD0, PD0, PD0,6L,2L); 00437 } 00438 00439 return 0; 00440 }
Here is the call graph for this function:

Here is the caller graph for this function:

Definition at line 298 of file drawMarks.c.
References C2F, dr(), int, L, PD0, PI0, and v.
Referenced by DrawNewMarks().
00299 { 00300 int two = 2 ; 00301 int xmasterix[2]; 00302 int ymasterix[2]; 00303 int closeflag=0; 00304 int v = 0 ; 00305 double dv = 0.0; 00306 00307 C2F (dr) ("xset", "dashes", &foreground, &foreground, &v, &v, &v, &v, &dv, 00308 &dv, &dv, &dv, 5L, 4096); 00309 C2F (dr) ("xset", "foreground", &foreground, &foreground, &v, &v, &v, &v, 00310 &dv, &dv, &dv, &dv, 5L, 4096); 00311 00312 /* the "+" */ 00313 xmasterix[0] = xmi -((int) size) ; 00314 xmasterix[1] = xmi +(int) size + pixel_offset; 00315 ymasterix[0] = ymasterix[1] = ymi; 00316 C2F (dr) ("xlines", "xv", &two, xmasterix, ymasterix, &closeflag, PI0, PI0, PD0, PD0, PD0, PD0,6L,2L); 00317 00318 00319 xmasterix[0] = xmasterix[1] = xmi; 00320 ymasterix[0] = ymi - (int) size; 00321 ymasterix[1] = ymi + (int) size + pixel_offset; 00322 C2F (dr) ("xlines", "xv", &two, xmasterix, ymasterix, &closeflag, PI0, PI0, PD0, PD0, PD0, PD0,6L,2L); 00323 00324 return 0; 00325 }
Here is the call graph for this function:

Here is the caller graph for this function:

| void DrawMarks3D | ( | sciPointObj * | pobj, | |
| int | n1, | |||
| int * | xm, | |||
| int * | ym, | |||
| int * | DPI | |||
| ) |
Definition at line 243 of file drawMarks.c.
References C2F, dr(), DrawNewMarks(), L, PD0, PI0, sciGetIsMark(), sciGetMarkForeground(), sciGetMarkSize(), sciGetMarkStyle(), and v.
Referenced by DrawMerge3d(), fac3dn(), and plot3dn().
00244 { 00245 if ( sciGetIsMark(pobj) ) 00246 { 00247 integer v = 0 ; 00248 double dv = 0.0 ; 00249 int markForeground = sciGetMarkForeground(pobj); 00250 int markStyle = sciGetMarkStyle( pobj ) ; 00251 int markSize = sciGetMarkSize( pobj ) ; 00252 00253 C2F (dr) ("xset", "dashes", &markForeground, &markForeground, &v, &v, &v, &v, &dv, 00254 &dv, &dv, &dv, 5L, 4096); 00255 C2F (dr) ("xset", "foreground", &markForeground, &markForeground, &v, &v, &v, &v, 00256 &dv, &dv, &dv, &dv, 5L, 4096); 00257 00258 C2F (dr) ("xset", "mark", &markStyle, &markSize, PI0, PI0, PI0, PI0, PD0, PD0, 00259 PD0, PD0, 0L, 0L) ; 00260 00261 DrawNewMarks(pobj,n1,xm,ym,DPI); 00262 } 00263 }
Here is the call graph for this function:

Here is the caller graph for this function:

Definition at line 14 of file drawMarks.c.
References C2F, CheckPixelStatus(), dr(), DrawMark_Asterisk(), DrawMark_Cross(), DrawMark_FullDiamond(), DrawMark_FullDot(), DrawMark_FullPentagram(), DrawMark_FullSquare(), DrawMark_FullTriangleDown(), DrawMark_FullTriangleLeft(), DrawMark_FullTriangleRight(), DrawMark_FullTriangleUp(), DrawMark_Plus(), flagx, i, int, L, PD0, PI0, sciGetLineWidth(), sciGetMarkBackground(), sciGetMarkForeground(), sciGetMarkSize(), sciGetMarkSizeUnit(), sciGetMarkStyle(), size, style, and v.
Referenced by DrawMarks3D(), DrawMerge3d(), drawPolylineEntity(), drawPolyMarks(), and drawRectangleEntity().
00015 { 00016 int style = sciGetMarkStyle(pobj); 00017 double size = (double) sciGetMarkSize(pobj); 00018 int foreground = sciGetMarkForeground(pobj); 00019 int background = sciGetMarkBackground(pobj); 00020 int i; 00021 00022 int v = 0 ; 00023 double dv = 0.0 ; 00024 int flagx = 0; 00025 int old_foreground; 00026 00027 int thick; 00028 int linestyle[6]; 00029 int tabulated_marksize[] = {8,10,12,14,18,24}; 00030 00031 integer verbose = 0,old_thick, old_linestyle[6],narg = 0; 00032 int ixres = DPI[0]; /* only the x DPI is used here : */ 00033 00034 int pixel_offset = CheckPixelStatus() ; 00035 double size_plus_one = 0.; 00036 double size_minus_one = 0.; 00037 00038 00039 linestyle[0] = 1; 00040 00041 if( sciGetMarkSizeUnit(pobj) == 2 ) 00042 { 00043 /* tabulated */ /* size is given relative to the array tabulated_marksize */ 00044 if( (int) size <= 5) 00045 { 00046 if(style == 0 && size == 0) 00047 { 00048 size = 1; /* Singularity : To allow the drawing of a single pixel in old mode (tabulated) */ 00049 } 00050 else 00051 { 00052 size = tabulated_marksize[(int) size] ; 00053 } 00054 } 00055 else 00056 { 00057 size = tabulated_marksize[5]; 00058 } 00059 } 00060 00061 size_plus_one = size + 1.; 00062 size_minus_one = size - 1.; 00063 00064 /* We get the DPIs value : only the x DPI is used here : */ 00065 /* we assum we have a square pixel (i.e. xDPI == yDPI or almost) */ 00066 size = size * (ixres/72.); 00067 size_minus_one = size_minus_one * (ixres/72.); 00068 size_plus_one = size_plus_one * (ixres/72.); 00069 00070 C2F (dr) ("xget", "foreground", &flagx, &old_foreground, &v, &v, &v, 00071 &v, &dv, &dv, &dv, &dv, 5L, 4096); 00072 00073 C2F(dr)("xget","thickness",&verbose,&old_thick,&narg,PI0,PI0,PI0,PD0,PD0,PD0,PD0,0L,0L); 00074 00075 C2F(dr)("xget","line style",&verbose,old_linestyle,&narg,&v,&v,&v,&dv,&dv,&dv,&dv,0L,0L); 00076 00077 for( i = 1 ; i < 6 ; i++ ) { linestyle[i] = old_linestyle[i] ; } 00078 00079 /* My default for marks drawing */ 00080 C2F (dr) ("xset", "line style", linestyle, PI0, PI0, PI0, PI0, PI0, PD0, 00081 PD0, PD0, PD0, 0L, 0L); 00082 00083 thick = sciGetLineWidth(pobj) ; /* to answer the request from newsgroup to have marks thickness == line thickness every time */ 00084 if( thick < 1 ) { thick = 1 ; } 00085 00086 C2F(dr)("xset","thickness",&thick,PI0,PI0,PI0,PI0,PI0,PD0,PD0,PD0,PD0,0L,0L); 00087 /* end of default*/ 00088 00089 if( size < 2 ) 00090 { 00091 /* represents a . (pixel) with editable foreground */ 00092 for( i = 0 ; i < n1 ; i++ ) 00093 { 00094 int two = 2 ; 00095 int closeflag = 0 ; 00096 int xmasterix[2]; 00097 int ymasterix[2]; 00098 00099 C2F (dr) ("xset", "dashes", &foreground, &foreground, &v, &v, &v, &v, &dv, 00100 &dv, &dv, &dv, 5L, 4096); 00101 C2F (dr) ("xset", "foreground", &foreground, &foreground, &v, &v, &v, &v, 00102 &dv, &dv, &dv, &dv, 5L, 4096); 00103 00104 xmasterix[0] = xm[i]; 00105 xmasterix[1] = xm[i] + pixel_offset; 00106 ymasterix[0] = ym[i] ; 00107 ymasterix[1] = ym[i] ; 00108 C2F (dr) ("xlines", "xv", &two, xmasterix, ymasterix, &closeflag, PI0, PI0, PD0, PD0, PD0, PD0,6L,2L); 00109 } 00110 return 0; 00111 } 00112 00113 /* foreground = sciGetMarkForeground(pobj); 00114 background = sciGetMarkBackground(pobj);*/ 00115 00116 switch( style ) 00117 { 00118 case 0: 00119 /* represents a simple full dot with editable foreground */ 00120 for(i=0;i<n1;i++) 00121 { 00122 DrawMark_FullDot(xm[i], ym[i], size_minus_one, foreground, foreground, pixel_offset); 00123 } 00124 break; 00125 case 1: 00126 /* represents a plus with editable foreground */ 00127 for(i=0;i<n1;i++) 00128 { 00129 DrawMark_Plus(xm[i], ym[i], (int)(size/2), foreground, pixel_offset); 00130 } 00131 break; 00132 case 2: 00133 /* represents a cross with editable foreground */ 00134 for(i=0;i<n1;i++) 00135 { 00136 DrawMark_Cross(xm[i], ym[i], (int)(size/2), foreground, pixel_offset); 00137 } 00138 break; 00139 case 3: 00140 00141 /* represents a circle AND a plus within this circle with editable foreground and background */ 00142 for(i=0;i<n1;i++) 00143 { 00144 DrawMark_FullDot(xm[i], ym[i], size_minus_one, foreground, background, pixel_offset); 00145 DrawMark_Plus(xm[i], ym[i], (int)(size/2), foreground, pixel_offset); 00146 } 00147 break; 00148 case 4: 00149 /* represents a diamond with background == foreground */ 00150 for(i=0;i<n1;i++) 00151 { 00152 DrawMark_FullDiamond(xm[i], ym[i], (int)(size/2), foreground, foreground); 00153 } 00154 break; 00155 case 5: 00156 /* represents a diamond with both editable foreground and background */ 00157 for(i=0;i<n1;i++) 00158 { 00159 DrawMark_FullDiamond(xm[i], ym[i], (int)(size/2), foreground, background); 00160 } 00161 break; 00162 case 6: 00163 /* represents an upward-pointing triangle with both editable foreground and background */ 00164 for(i=0;i<n1;i++) 00165 { 00166 DrawMark_FullTriangleUp(xm[i], ym[i], (int)size, foreground, background); 00167 } 00168 break; 00169 case 7: 00170 /* represents a downward-pointing triangle with both editable foreground and background */ 00171 for(i=0;i<n1;i++) 00172 { 00173 DrawMark_FullTriangleDown(xm[i], ym[i], (int)size, foreground, background); 00174 } 00175 break; 00176 case 8: 00177 /* represents a diamond with a plus inside with both editable foreground and background */ 00178 for(i=0;i<n1;i++) 00179 { 00180 DrawMark_FullDiamond(xm[i], ym[i], (int)(size/2), foreground, background); 00181 DrawMark_Plus(xm[i], ym[i], (int)(size/2), foreground, pixel_offset); 00182 } 00183 break; 00184 case 9: 00185 /* represents a circle with editable foreground and background */ 00186 for(i=0;i<n1;i++) 00187 { 00188 DrawMark_FullDot(xm[i], ym[i], size_minus_one, foreground, background, pixel_offset); 00189 } 00190 break; 00191 case 10: 00192 /* Asterix case : we can modify only the foreground (background changes have no impact) */ 00193 for(i=0;i<n1;i++) 00194 { 00195 DrawMark_Asterisk(xm[i], ym[i],(int) (size/2), foreground, pixel_offset); 00196 } 00197 break; 00198 case 11: 00199 /* represents a square with editable foreground and background */ 00200 for(i=0;i<n1;i++) 00201 { 00202 DrawMark_FullSquare(xm[i], ym[i],(int) size_minus_one, foreground, background, pixel_offset); 00203 } 00204 break; 00205 case 12: 00206 /* represents a right-pointing triangle with both editable foreground and background */ 00207 for(i=0;i<n1;i++) 00208 { 00209 DrawMark_FullTriangleRight(xm[i], ym[i],(int) size, foreground, background); 00210 } 00211 break; 00212 case 13: 00213 /* represents a left-pointing triangle with both editable foreground and background */ 00214 for(i=0;i<n1;i++) 00215 { 00216 DrawMark_FullTriangleLeft(xm[i], ym[i],(int) size, foreground, background); 00217 } 00218 break; 00219 case 14: 00220 /* represents a pentagram with both editable foreground and background */ 00221 for(i=0;i<n1;i++) 00222 { 00223 DrawMark_FullPentagram(xm[i], ym[i], (int)(size/2), foreground, background); 00224 } 00225 break; 00226 default: 00227 break; 00228 } 00229 00230 C2F (dr) ("xset", "line style", old_linestyle, PI0, PI0, PI0, PI0, PI0, PD0, 00231 PD0, PD0, PD0, 0L, 0L); 00232 00233 C2F(dr)("xset","thickness",&old_thick,PI0,PI0,PI0,PI0,PI0,PD0,PD0,PD0,PD0,0L,0L); 00234 00235 C2F (dr) ("xset", "dashes", &old_foreground, &old_foreground, &v, &v, &v, &v, &dv, 00236 &dv, &dv, &dv, 5L, 4096); 00237 C2F (dr) ("xset", "foreground", &old_foreground, &old_foreground, &v, &v, &v, &v, 00238 &dv, &dv, &dv, &dv, 5L, 4096); 00239 00240 return 0; 00241 }
Here is the call graph for this function:

Here is the caller graph for this function:

| void drawPolyMarks | ( | sciPointObj * | pObj, | |
| int | nbMarks, | |||
| int | xCoord[], | |||
| int | yCoord[], | |||
| int | DPI[2] | |||
| ) |
draw the marks at the vertices of a polyline.
| [in] | pObj | Object on which the marks will be drawn. Might be a polyline, a segs or rectangle object. |
| [in] | nbMarks | Number of marks to draw. |
| [in] | xCoord | X coordinates of the marks in pixels. |
| [in] | yCoord | Y coordinates of the marks in pixels. |
| DPI | ??? |
Definition at line 725 of file drawMarks.c.
References C2F, dr(), DrawNewMarks(), L, PD0, PI0, sciGetMarkForeground(), sciGetMarkSize(), sciGetMarkStyle(), and v.
Referenced by drawSegsEntity().
00726 { 00727 int foreground = sciGetMarkForeground( pObj ) ; 00728 int v = 0 ; 00729 double dv = 0.0 ; 00730 int markIdSize[2] ; 00731 00732 markIdSize[0] = sciGetMarkStyle( pObj ) ; 00733 markIdSize[1] = sciGetMarkSize( pObj ) ; 00734 00735 C2F (dr) ("xset", "dashes", &foreground, &foreground, &v, &v, &v, &v, &dv, 00736 &dv, &dv, &dv, 5L, 4096); 00737 C2F (dr) ("xset", "foreground", &foreground, &foreground, &v, &v, &v, &v, 00738 &dv, &dv, &dv, &dv, 5L, 4096); 00739 00740 C2F (dr) ("xset", "mark", &markIdSize[0], &markIdSize[1], PI0, PI0, PI0, PI0, PD0, PD0, 00741 PD0, PD0, 0L, 0L); 00742 00743 DrawNewMarks( pObj, nbMarks, xCoord, yCoord, DPI ) ; 00744 }
Here is the call graph for this function:

Here is the caller graph for this function:

1.5.1