comparison src/shape_path.c @ 707:594827d0f3e5

Fix issue of relative path data. A absolutely location, that is used to computed respective absolutely location of relative location, must be updated after parsing every segment of a path. But, it does not. It is fixed, now.
author Thinker K.F. Li <thinker@branda.to>
date Fri, 13 Aug 2010 17:26:25 +0800
parents e95598916dfb
children 920c9e6e4214
comparison
equal deleted inserted replaced
706:fdd68e69c59f 707:594827d0f3e5
624 old = p; 624 old = p;
625 SKIP_NUM(p); 625 SKIP_NUM(p);
626 if(p == old) 626 if(p == old)
627 return ERR; 627 return ERR;
628 *pnts = TO_ABSX; 628 *pnts = TO_ABSX;
629 x = *pnts;
629 pnts++; 630 pnts++;
630 631
631 SKIP_SPACE(p); 632 SKIP_SPACE(p);
632 old = p; 633 old = p;
633 SKIP_NUM(p); 634 SKIP_NUM(p);
634 if(p == old) 635 if(p == old)
635 return ERR; 636 return ERR;
636 *pnts = TO_ABSY; 637 *pnts = TO_ABSY;
638 y = *pnts;
637 pnts++; 639 pnts++;
638 640
639 *cmds++ = toupper(cmd); 641 *cmds++ = toupper(cmd);
640 } 642 }
641 break; 643 break;
665 old = p; 667 old = p;
666 SKIP_NUM(p); 668 SKIP_NUM(p);
667 if(p == old) 669 if(p == old)
668 return ERR; 670 return ERR;
669 *pnts = TO_ABSX; 671 *pnts = TO_ABSX;
672 x = *pnts;
670 pnts++; 673 pnts++;
671 674
672 SKIP_SPACE(p); 675 SKIP_SPACE(p);
673 old = p; 676 old = p;
674 SKIP_NUM(p); 677 SKIP_NUM(p);
675 if(p == old) 678 if(p == old)
676 return ERR; 679 return ERR;
677 *pnts = TO_ABSY; 680 *pnts = TO_ABSY;
681 y = *pnts;
678 pnts++; 682 pnts++;
679 683
680 *cmds++ = toupper(cmd); 684 *cmds++ = toupper(cmd);
681 } 685 }
682 break; 686 break;
692 old = p; 696 old = p;
693 SKIP_NUM(p); 697 SKIP_NUM(p);
694 if(p == old) 698 if(p == old)
695 break; 699 break;
696 *pnts = TO_ABSX; 700 *pnts = TO_ABSX;
701 x = *pnts;
697 pnts++; 702 pnts++;
698 703
699 SKIP_SPACE(p); 704 SKIP_SPACE(p);
700 old = p; 705 old = p;
701 SKIP_NUM(p); 706 SKIP_NUM(p);
702 if(p == old) 707 if(p == old)
703 return ERR; 708 return ERR;
704 *pnts = TO_ABSY; 709 *pnts = TO_ABSY;
710 y = *pnts;
705 pnts++; 711 pnts++;
706 712
707 *cmds++ = toupper(cmd); 713 *cmds++ = toupper(cmd);
708 } 714 }
709 break; 715 break;