• Home
  • Raw
  • Download

Lines Matching refs:env

228   static void rmoveto (ENV &env, PARAM& param) {}  in rmoveto()
229 static void hmoveto (ENV &env, PARAM& param) {} in hmoveto()
230 static void vmoveto (ENV &env, PARAM& param) {} in vmoveto()
231 static void rlineto (ENV &env, PARAM& param) {} in rlineto()
232 static void hlineto (ENV &env, PARAM& param) {} in hlineto()
233 static void vlineto (ENV &env, PARAM& param) {} in vlineto()
234 static void rrcurveto (ENV &env, PARAM& param) {} in rrcurveto()
235 static void rcurveline (ENV &env, PARAM& param) {} in rcurveline()
236 static void rlinecurve (ENV &env, PARAM& param) {} in rlinecurve()
237 static void vvcurveto (ENV &env, PARAM& param) {} in vvcurveto()
238 static void hhcurveto (ENV &env, PARAM& param) {} in hhcurveto()
239 static void vhcurveto (ENV &env, PARAM& param) {} in vhcurveto()
240 static void hvcurveto (ENV &env, PARAM& param) {} in hvcurveto()
241 static void moveto (ENV &env, PARAM& param, const point_t &pt) {} in moveto()
242 static void line (ENV &env, PARAM& param, const point_t &pt1) {} in line()
243 …static void curve (ENV &env, PARAM& param, const point_t &pt1, const point_t &pt2, const point_t &… in curve()
244 static void hflex (ENV &env, PARAM& param) {} in hflex()
245 static void flex (ENV &env, PARAM& param) {} in flex()
246 static void hflex1 (ENV &env, PARAM& param) {} in hflex1()
247 static void flex1 (ENV &env, PARAM& param) {} in flex1()
253 static void process_op (op_code_t op, ENV &env, PARAM& param) in process_op()
258 env.return_from_subr (); in process_op()
261 OPSET::check_width (op, env, param); in process_op()
262 env.set_endchar (true); in process_op()
263 OPSET::flush_args_and_op (op, env, param); in process_op()
267 env.argStack.push_fixed_from_substr (env.str_ref); in process_op()
271 env.call_subr (env.localSubrs, CSType_LocalSubr); in process_op()
275 env.call_subr (env.globalSubrs, CSType_GlobalSubr); in process_op()
280 OPSET::check_width (op, env, param); in process_op()
281 OPSET::process_hstem (op, env, param); in process_op()
285 OPSET::check_width (op, env, param); in process_op()
286 OPSET::process_vstem (op, env, param); in process_op()
290 OPSET::check_width (op, env, param); in process_op()
291 OPSET::process_hintmask (op, env, param); in process_op()
294 OPSET::check_width (op, env, param); in process_op()
295 PATH::rmoveto (env, param); in process_op()
296 OPSET::process_post_move (op, env, param); in process_op()
299 OPSET::check_width (op, env, param); in process_op()
300 PATH::hmoveto (env, param); in process_op()
301 OPSET::process_post_move (op, env, param); in process_op()
304 OPSET::check_width (op, env, param); in process_op()
305 PATH::vmoveto (env, param); in process_op()
306 OPSET::process_post_move (op, env, param); in process_op()
309 PATH::rlineto (env, param); in process_op()
310 process_post_path (op, env, param); in process_op()
313 PATH::hlineto (env, param); in process_op()
314 process_post_path (op, env, param); in process_op()
317 PATH::vlineto (env, param); in process_op()
318 process_post_path (op, env, param); in process_op()
321 PATH::rrcurveto (env, param); in process_op()
322 process_post_path (op, env, param); in process_op()
325 PATH::rcurveline (env, param); in process_op()
326 process_post_path (op, env, param); in process_op()
329 PATH::rlinecurve (env, param); in process_op()
330 process_post_path (op, env, param); in process_op()
333 PATH::vvcurveto (env, param); in process_op()
334 process_post_path (op, env, param); in process_op()
337 PATH::hhcurveto (env, param); in process_op()
338 process_post_path (op, env, param); in process_op()
341 PATH::vhcurveto (env, param); in process_op()
342 process_post_path (op, env, param); in process_op()
345 PATH::hvcurveto (env, param); in process_op()
346 process_post_path (op, env, param); in process_op()
350 PATH::hflex (env, param); in process_op()
351 OPSET::process_post_flex (op, env, param); in process_op()
355 PATH::flex (env, param); in process_op()
356 OPSET::process_post_flex (op, env, param); in process_op()
360 PATH::hflex1 (env, param); in process_op()
361 OPSET::process_post_flex (op, env, param); in process_op()
365 PATH::flex1 (env, param); in process_op()
366 OPSET::process_post_flex (op, env, param); in process_op()
370 SUPER::process_op (op, env); in process_op()
375 static void process_hstem (op_code_t op, ENV &env, PARAM& param) in process_hstem()
377 env.hstem_count += env.argStack.get_count () / 2; in process_hstem()
378 OPSET::flush_args_and_op (op, env, param); in process_hstem()
381 static void process_vstem (op_code_t op, ENV &env, PARAM& param) in process_vstem()
383 env.vstem_count += env.argStack.get_count () / 2; in process_vstem()
384 OPSET::flush_args_and_op (op, env, param); in process_vstem()
387 static void process_hintmask (op_code_t op, ENV &env, PARAM& param) in process_hintmask()
389 env.determine_hintmask_size (); in process_hintmask()
390 if (likely (env.str_ref.avail (env.hintmask_size))) in process_hintmask()
392 OPSET::flush_hintmask (op, env, param); in process_hintmask()
393 env.str_ref.inc (env.hintmask_size); in process_hintmask()
397 static void process_post_flex (op_code_t op, ENV &env, PARAM& param) in process_post_flex()
399 OPSET::flush_args_and_op (op, env, param); in process_post_flex()
402 static void check_width (op_code_t op, ENV &env, PARAM& param) in check_width()
405 static void process_post_move (op_code_t op, ENV &env, PARAM& param) in process_post_move()
407 if (!env.seen_moveto) in process_post_move()
409 env.determine_hintmask_size (); in process_post_move()
410 env.seen_moveto = true; in process_post_move()
412 OPSET::flush_args_and_op (op, env, param); in process_post_move()
415 static void process_post_path (op_code_t op, ENV &env, PARAM& param) in process_post_path()
417 OPSET::flush_args_and_op (op, env, param); in process_post_path()
420 static void flush_args_and_op (op_code_t op, ENV &env, PARAM& param) in flush_args_and_op()
422 OPSET::flush_args (env, param); in flush_args_and_op()
423 OPSET::flush_op (op, env, param); in flush_args_and_op()
426 static void flush_args (ENV &env, PARAM& param) in flush_args()
428 env.pop_n_args (env.argStack.get_count ()); in flush_args()
431 static void flush_op (op_code_t op, ENV &env, PARAM& param) in flush_op()
435 static void flush_hintmask (op_code_t op, ENV &env, PARAM& param) in flush_hintmask()
437 OPSET::flush_args_and_op (op, env, param); in flush_hintmask()
465 static void rmoveto (ENV &env, PARAM& param) in rmoveto()
467 point_t pt1 = env.get_pt (); in rmoveto()
468 const number_t &dy = env.pop_arg (); in rmoveto()
469 const number_t &dx = env.pop_arg (); in rmoveto()
471 PATH::moveto (env, param, pt1); in rmoveto()
474 static void hmoveto (ENV &env, PARAM& param) in hmoveto()
476 point_t pt1 = env.get_pt (); in hmoveto()
477 pt1.move_x (env.pop_arg ()); in hmoveto()
478 PATH::moveto (env, param, pt1); in hmoveto()
481 static void vmoveto (ENV &env, PARAM& param) in vmoveto()
483 point_t pt1 = env.get_pt (); in vmoveto()
484 pt1.move_y (env.pop_arg ()); in vmoveto()
485 PATH::moveto (env, param, pt1); in vmoveto()
488 static void rlineto (ENV &env, PARAM& param) in rlineto()
490 for (unsigned int i = 0; i + 2 <= env.argStack.get_count (); i += 2) in rlineto()
492 point_t pt1 = env.get_pt (); in rlineto()
493 pt1.move (env.eval_arg (i), env.eval_arg (i+1)); in rlineto()
494 PATH::line (env, param, pt1); in rlineto()
498 static void hlineto (ENV &env, PARAM& param) in hlineto()
502 for (; i + 2 <= env.argStack.get_count (); i += 2) in hlineto()
504 pt1 = env.get_pt (); in hlineto()
505 pt1.move_x (env.eval_arg (i)); in hlineto()
506 PATH::line (env, param, pt1); in hlineto()
507 pt1.move_y (env.eval_arg (i+1)); in hlineto()
508 PATH::line (env, param, pt1); in hlineto()
510 if (i < env.argStack.get_count ()) in hlineto()
512 pt1 = env.get_pt (); in hlineto()
513 pt1.move_x (env.eval_arg (i)); in hlineto()
514 PATH::line (env, param, pt1); in hlineto()
518 static void vlineto (ENV &env, PARAM& param) in vlineto()
522 for (; i + 2 <= env.argStack.get_count (); i += 2) in vlineto()
524 pt1 = env.get_pt (); in vlineto()
525 pt1.move_y (env.eval_arg (i)); in vlineto()
526 PATH::line (env, param, pt1); in vlineto()
527 pt1.move_x (env.eval_arg (i+1)); in vlineto()
528 PATH::line (env, param, pt1); in vlineto()
530 if (i < env.argStack.get_count ()) in vlineto()
532 pt1 = env.get_pt (); in vlineto()
533 pt1.move_y (env.eval_arg (i)); in vlineto()
534 PATH::line (env, param, pt1); in vlineto()
538 static void rrcurveto (ENV &env, PARAM& param) in rrcurveto()
540 for (unsigned int i = 0; i + 6 <= env.argStack.get_count (); i += 6) in rrcurveto()
542 point_t pt1 = env.get_pt (); in rrcurveto()
543 pt1.move (env.eval_arg (i), env.eval_arg (i+1)); in rrcurveto()
545 pt2.move (env.eval_arg (i+2), env.eval_arg (i+3)); in rrcurveto()
547 pt3.move (env.eval_arg (i+4), env.eval_arg (i+5)); in rrcurveto()
548 PATH::curve (env, param, pt1, pt2, pt3); in rrcurveto()
552 static void rcurveline (ENV &env, PARAM& param) in rcurveline()
555 for (; i + 6 <= env.argStack.get_count (); i += 6) in rcurveline()
557 point_t pt1 = env.get_pt (); in rcurveline()
558 pt1.move (env.eval_arg (i), env.eval_arg (i+1)); in rcurveline()
560 pt2.move (env.eval_arg (i+2), env.eval_arg (i+3)); in rcurveline()
562 pt3.move (env.eval_arg (i+4), env.eval_arg (i+5)); in rcurveline()
563 PATH::curve (env, param, pt1, pt2, pt3); in rcurveline()
565 for (; i + 2 <= env.argStack.get_count (); i += 2) in rcurveline()
567 point_t pt1 = env.get_pt (); in rcurveline()
568 pt1.move (env.eval_arg (i), env.eval_arg (i+1)); in rcurveline()
569 PATH::line (env, param, pt1); in rcurveline()
573 static void rlinecurve (ENV &env, PARAM& param) in rlinecurve()
576 unsigned int line_limit = (env.argStack.get_count () % 6); in rlinecurve()
579 point_t pt1 = env.get_pt (); in rlinecurve()
580 pt1.move (env.eval_arg (i), env.eval_arg (i+1)); in rlinecurve()
581 PATH::line (env, param, pt1); in rlinecurve()
583 for (; i + 6 <= env.argStack.get_count (); i += 6) in rlinecurve()
585 point_t pt1 = env.get_pt (); in rlinecurve()
586 pt1.move (env.eval_arg (i), env.eval_arg (i+1)); in rlinecurve()
588 pt2.move (env.eval_arg (i+2), env.eval_arg (i+3)); in rlinecurve()
590 pt3.move (env.eval_arg (i+4), env.eval_arg (i+5)); in rlinecurve()
591 PATH::curve (env, param, pt1, pt2, pt3); in rlinecurve()
595 static void vvcurveto (ENV &env, PARAM& param) in vvcurveto()
598 point_t pt1 = env.get_pt (); in vvcurveto()
599 if ((env.argStack.get_count () & 1) != 0) in vvcurveto()
600 pt1.move_x (env.eval_arg (i++)); in vvcurveto()
601 for (; i + 4 <= env.argStack.get_count (); i += 4) in vvcurveto()
603 pt1.move_y (env.eval_arg (i)); in vvcurveto()
605 pt2.move (env.eval_arg (i+1), env.eval_arg (i+2)); in vvcurveto()
607 pt3.move_y (env.eval_arg (i+3)); in vvcurveto()
608 PATH::curve (env, param, pt1, pt2, pt3); in vvcurveto()
609 pt1 = env.get_pt (); in vvcurveto()
613 static void hhcurveto (ENV &env, PARAM& param) in hhcurveto()
616 point_t pt1 = env.get_pt (); in hhcurveto()
617 if ((env.argStack.get_count () & 1) != 0) in hhcurveto()
618 pt1.move_y (env.eval_arg (i++)); in hhcurveto()
619 for (; i + 4 <= env.argStack.get_count (); i += 4) in hhcurveto()
621 pt1.move_x (env.eval_arg (i)); in hhcurveto()
623 pt2.move (env.eval_arg (i+1), env.eval_arg (i+2)); in hhcurveto()
625 pt3.move_x (env.eval_arg (i+3)); in hhcurveto()
626 PATH::curve (env, param, pt1, pt2, pt3); in hhcurveto()
627 pt1 = env.get_pt (); in hhcurveto()
631 static void vhcurveto (ENV &env, PARAM& param) in vhcurveto()
635 if ((env.argStack.get_count () % 8) >= 4) in vhcurveto()
637 point_t pt1 = env.get_pt (); in vhcurveto()
638 pt1.move_y (env.eval_arg (i)); in vhcurveto()
640 pt2.move (env.eval_arg (i+1), env.eval_arg (i+2)); in vhcurveto()
642 pt3.move_x (env.eval_arg (i+3)); in vhcurveto()
645 for (; i + 8 <= env.argStack.get_count (); i += 8) in vhcurveto()
647 PATH::curve (env, param, pt1, pt2, pt3); in vhcurveto()
648 pt1 = env.get_pt (); in vhcurveto()
649 pt1.move_x (env.eval_arg (i)); in vhcurveto()
651 pt2.move (env.eval_arg (i+1), env.eval_arg (i+2)); in vhcurveto()
653 pt3.move_y (env.eval_arg (i+3)); in vhcurveto()
654 PATH::curve (env, param, pt1, pt2, pt3); in vhcurveto()
657 pt1.move_y (env.eval_arg (i+4)); in vhcurveto()
659 pt2.move (env.eval_arg (i+5), env.eval_arg (i+6)); in vhcurveto()
661 pt3.move_x (env.eval_arg (i+7)); in vhcurveto()
663 if (i < env.argStack.get_count ()) in vhcurveto()
664 pt3.move_y (env.eval_arg (i)); in vhcurveto()
665 PATH::curve (env, param, pt1, pt2, pt3); in vhcurveto()
669 for (; i + 8 <= env.argStack.get_count (); i += 8) in vhcurveto()
671 pt1 = env.get_pt (); in vhcurveto()
672 pt1.move_y (env.eval_arg (i)); in vhcurveto()
674 pt2.move (env.eval_arg (i+1), env.eval_arg (i+2)); in vhcurveto()
676 pt3.move_x (env.eval_arg (i+3)); in vhcurveto()
677 PATH::curve (env, param, pt1, pt2, pt3); in vhcurveto()
680 pt1.move_x (env.eval_arg (i+4)); in vhcurveto()
682 pt2.move (env.eval_arg (i+5), env.eval_arg (i+6)); in vhcurveto()
684 pt3.move_y (env.eval_arg (i+7)); in vhcurveto()
685 if ((env.argStack.get_count () - i < 16) && ((env.argStack.get_count () & 1) != 0)) in vhcurveto()
686 pt3.move_x (env.eval_arg (i+8)); in vhcurveto()
687 PATH::curve (env, param, pt1, pt2, pt3); in vhcurveto()
692 static void hvcurveto (ENV &env, PARAM& param) in hvcurveto()
696 if ((env.argStack.get_count () % 8) >= 4) in hvcurveto()
698 point_t pt1 = env.get_pt (); in hvcurveto()
699 pt1.move_x (env.eval_arg (i)); in hvcurveto()
701 pt2.move (env.eval_arg (i+1), env.eval_arg (i+2)); in hvcurveto()
703 pt3.move_y (env.eval_arg (i+3)); in hvcurveto()
706 for (; i + 8 <= env.argStack.get_count (); i += 8) in hvcurveto()
708 PATH::curve (env, param, pt1, pt2, pt3); in hvcurveto()
709 pt1 = env.get_pt (); in hvcurveto()
710 pt1.move_y (env.eval_arg (i)); in hvcurveto()
712 pt2.move (env.eval_arg (i+1), env.eval_arg (i+2)); in hvcurveto()
714 pt3.move_x (env.eval_arg (i+3)); in hvcurveto()
715 PATH::curve (env, param, pt1, pt2, pt3); in hvcurveto()
718 pt1.move_x (env.eval_arg (i+4)); in hvcurveto()
720 pt2.move (env.eval_arg (i+5), env.eval_arg (i+6)); in hvcurveto()
722 pt3.move_y (env.eval_arg (i+7)); in hvcurveto()
724 if (i < env.argStack.get_count ()) in hvcurveto()
725 pt3.move_x (env.eval_arg (i)); in hvcurveto()
726 PATH::curve (env, param, pt1, pt2, pt3); in hvcurveto()
730 for (; i + 8 <= env.argStack.get_count (); i += 8) in hvcurveto()
732 pt1 = env.get_pt (); in hvcurveto()
733 pt1.move_x (env.eval_arg (i)); in hvcurveto()
735 pt2.move (env.eval_arg (i+1), env.eval_arg (i+2)); in hvcurveto()
737 pt3.move_y (env.eval_arg (i+3)); in hvcurveto()
738 PATH::curve (env, param, pt1, pt2, pt3); in hvcurveto()
741 pt1.move_y (env.eval_arg (i+4)); in hvcurveto()
743 pt2.move (env.eval_arg (i+5), env.eval_arg (i+6)); in hvcurveto()
745 pt3.move_x (env.eval_arg (i+7)); in hvcurveto()
746 if ((env.argStack.get_count () - i < 16) && ((env.argStack.get_count () & 1) != 0)) in hvcurveto()
747 pt3.move_y (env.eval_arg (i+8)); in hvcurveto()
748 PATH::curve (env, param, pt1, pt2, pt3); in hvcurveto()
754 static void moveto (ENV &env, PARAM& param, const point_t &pt) in moveto()
755 { env.moveto (pt); } in moveto()
757 static void line (ENV &env, PARAM& param, const point_t &pt1) in line()
758 { PATH::moveto (env, param, pt1); } in line()
760 …static void curve (ENV &env, PARAM& param, const point_t &pt1, const point_t &pt2, const point_t &… in curve()
761 { PATH::moveto (env, param, pt3); } in curve()
763 static void hflex (ENV &env, PARAM& param) in hflex()
765 if (likely (env.argStack.get_count () == 7)) in hflex()
767 point_t pt1 = env.get_pt (); in hflex()
768 pt1.move_x (env.eval_arg (0)); in hflex()
770 pt2.move (env.eval_arg (1), env.eval_arg (2)); in hflex()
772 pt3.move_x (env.eval_arg (3)); in hflex()
774 pt4.move_x (env.eval_arg (4)); in hflex()
776 pt5.move_x (env.eval_arg (5)); in hflex()
779 pt6.move_x (env.eval_arg (6)); in hflex()
781 curve2 (env, param, pt1, pt2, pt3, pt4, pt5, pt6); in hflex()
784 env.set_error (); in hflex()
787 static void flex (ENV &env, PARAM& param) in flex()
789 if (likely (env.argStack.get_count () == 13)) in flex()
791 point_t pt1 = env.get_pt (); in flex()
792 pt1.move (env.eval_arg (0), env.eval_arg (1)); in flex()
794 pt2.move (env.eval_arg (2), env.eval_arg (3)); in flex()
796 pt3.move (env.eval_arg (4), env.eval_arg (5)); in flex()
798 pt4.move (env.eval_arg (6), env.eval_arg (7)); in flex()
800 pt5.move (env.eval_arg (8), env.eval_arg (9)); in flex()
802 pt6.move (env.eval_arg (10), env.eval_arg (11)); in flex()
804 curve2 (env, param, pt1, pt2, pt3, pt4, pt5, pt6); in flex()
807 env.set_error (); in flex()
810 static void hflex1 (ENV &env, PARAM& param) in hflex1()
812 if (likely (env.argStack.get_count () == 9)) in hflex1()
814 point_t pt1 = env.get_pt (); in hflex1()
815 pt1.move (env.eval_arg (0), env.eval_arg (1)); in hflex1()
817 pt2.move (env.eval_arg (2), env.eval_arg (3)); in hflex1()
819 pt3.move_x (env.eval_arg (4)); in hflex1()
821 pt4.move_x (env.eval_arg (5)); in hflex1()
823 pt5.move (env.eval_arg (6), env.eval_arg (7)); in hflex1()
825 pt6.move_x (env.eval_arg (8)); in hflex1()
826 pt6.y = env.get_pt ().y; in hflex1()
828 curve2 (env, param, pt1, pt2, pt3, pt4, pt5, pt6); in hflex1()
831 env.set_error (); in hflex1()
834 static void flex1 (ENV &env, PARAM& param) in flex1()
836 if (likely (env.argStack.get_count () == 11)) in flex1()
841 d.move (env.eval_arg (i), env.eval_arg (i+1)); in flex1()
843 point_t pt1 = env.get_pt (); in flex1()
844 pt1.move (env.eval_arg (0), env.eval_arg (1)); in flex1()
846 pt2.move (env.eval_arg (2), env.eval_arg (3)); in flex1()
848 pt3.move (env.eval_arg (4), env.eval_arg (5)); in flex1()
850 pt4.move (env.eval_arg (6), env.eval_arg (7)); in flex1()
852 pt5.move (env.eval_arg (8), env.eval_arg (9)); in flex1()
857 pt6.move_x (env.eval_arg (10)); in flex1()
858 pt6.y = env.get_pt ().y; in flex1()
862 pt6.x = env.get_pt ().x; in flex1()
863 pt6.move_y (env.eval_arg (10)); in flex1()
866 curve2 (env, param, pt1, pt2, pt3, pt4, pt5, pt6); in flex1()
869 env.set_error (); in flex1()
873 static void curve2 (ENV &env, PARAM& param, in curve2()
877 PATH::curve (env, param, pt1, pt2, pt3); in curve2()
878 PATH::curve (env, param, pt4, pt5, pt6); in curve2()
887 SUPER::env.set_endchar (false); in interpret()
890 OPSET::process_op (SUPER::env.fetch_op (), SUPER::env, param); in interpret()
891 if (unlikely (SUPER::env.in_error ())) in interpret()
893 if (SUPER::env.is_endchar ()) in interpret()