diff options
-rw-r--r-- | pcl/pcpage.c | 14 | ||||
-rw-r--r-- | pcl/pcstate.h | 3 |
2 files changed, 3 insertions, 14 deletions
diff --git a/pcl/pcpage.c b/pcl/pcpage.c index c9e6e34d0..e59d04407 100644 --- a/pcl/pcpage.c +++ b/pcl/pcpage.c | |||
@@ -590,8 +590,6 @@ pcl_end_page( | |||
590 | code = (*pcs->end_page)(pcs, pcs->num_copies, true); | 590 | code = (*pcs->end_page)(pcs, pcs->num_copies, true); |
591 | if ( code < 0 ) | 591 | if ( code < 0 ) |
592 | return code; | 592 | return code; |
593 | /* allow the logical orientation command to be used again */ | ||
594 | pcs->orientation_set = false; | ||
595 | 593 | ||
596 | if ( pcs->end_page == pcl_end_page_top ) | 594 | if ( pcs->end_page == pcl_end_page_top ) |
597 | code = gs_erasepage(pcs->pgs); | 595 | code = gs_erasepage(pcs->pgs); |
@@ -658,13 +656,8 @@ set_page_size( | |||
658 | } | 656 | } |
659 | } | 657 | } |
660 | if ((psize != 0) && ((code = pcl_end_page_if_marked(pcs)) >= 0)) { | 658 | if ((psize != 0) && ((code = pcl_end_page_if_marked(pcs)) >= 0)) { |
661 | /* if the orientation flag is not set for this page we select | 659 | pcs->xfm_state.print_dir = 0; |
662 | a portrait page using the set paper size. Otherwise select | 660 | new_page_size(pcs, psize, false, false); |
663 | the paper using the current orientation. */ | ||
664 | if ( pcs->orientation_set == false ) | ||
665 | new_logical_page(pcs, 0, psize, false, false); | ||
666 | else | ||
667 | new_page_size(pcs, psize, false, false); | ||
668 | } | 661 | } |
669 | return code; | 662 | return code; |
670 | } | 663 | } |
@@ -759,7 +752,6 @@ set_logical_page_orientation( | |||
759 | 752 | ||
760 | /* If orientation is same as before ignore the command */ | 753 | /* If orientation is same as before ignore the command */ |
761 | if ( i == pcs->xfm_state.lp_orient ) { | 754 | if ( i == pcs->xfm_state.lp_orient ) { |
762 | pcs->orientation_set = true; | ||
763 | return 0; | 755 | return 0; |
764 | } | 756 | } |
765 | 757 | ||
@@ -770,7 +762,6 @@ set_logical_page_orientation( | |||
770 | pcs->hmi_cp = HMI_DEFAULT; | 762 | pcs->hmi_cp = HMI_DEFAULT; |
771 | pcs->vmi_cp = VMI_DEFAULT; | 763 | pcs->vmi_cp = VMI_DEFAULT; |
772 | new_logical_page(pcs, i, pcs->xfm_state.paper_size, false, false); | 764 | new_logical_page(pcs, i, pcs->xfm_state.paper_size, false, false); |
773 | pcs->orientation_set = true; | ||
774 | } | 765 | } |
775 | return code; | 766 | return code; |
776 | } | 767 | } |
@@ -1324,7 +1315,6 @@ pcpage_do_reset( | |||
1324 | } | 1315 | } |
1325 | 1316 | ||
1326 | if ((type & (pcl_reset_initial | pcl_reset_printer)) != 0) { | 1317 | if ((type & (pcl_reset_initial | pcl_reset_printer)) != 0) { |
1327 | pcs->orientation_set = false; | ||
1328 | pcs->paper_source = 0; /* ??? */ | 1318 | pcs->paper_source = 0; /* ??? */ |
1329 | pcs->xfm_state.left_offset_cp = 0.0; | 1319 | pcs->xfm_state.left_offset_cp = 0.0; |
1330 | pcs->xfm_state.top_offset_cp = 0.0; | 1320 | pcs->xfm_state.top_offset_cp = 0.0; |
diff --git a/pcl/pcstate.h b/pcl/pcstate.h index 25760c58e..e2be72439 100644 --- a/pcl/pcstate.h +++ b/pcl/pcstate.h | |||
@@ -148,8 +148,7 @@ struct pcl_state_s { | |||
148 | int perforation_skip; | 148 | int perforation_skip; |
149 | pcl_margins_t margins; /* relative to print_direction */ | 149 | pcl_margins_t margins; /* relative to print_direction */ |
150 | pcl_xfm_state_t xfm_state; | 150 | pcl_xfm_state_t xfm_state; |
151 | bool orientation_set; /* the orientation command can | 151 | |
152 | only be set once per page */ | ||
153 | /* Chapter 6 (pcursor.c) */ | 152 | /* Chapter 6 (pcursor.c) */ |
154 | coord hmi_cp; | 153 | coord hmi_cp; |
155 | coord vmi_cp; | 154 | coord vmi_cp; |