📄 xlm_codegen.h
字号:
showpage 5.26.4 Called Routines 1. restore 2. save 3. oprintf 5.26.5 Internal Variables And Storage******************************************************************/#define M$OUTPUT_SHOWPAGE() \ \ ps_str (str_showpage); \/* \ * M$SAVE() \ * ps_str (str_scale); \ */ /******************************************************************M$OUTPUT_VCHAR(m$attrs,m$width,m$drawerase,m$ulavp) 5.25.1 Generalities This routine prints one virtual character to the Postscript machine. 5.25.2 Input vchar 5.25.3 Output vchar 5.25.4 Called Routines 1. oprintf 2. line_ul 3. line_st 4. line_stul 5.25.5 Internal Variables And Storage******************************************************************/#define M$OUTPUT_VCHAR(m$attrs,m$width,m$drawerase,m$ulavp) \ \/*if (m$drawerase == VIR_CHAR_ERASE) oprintf (str_white);*/ /* set white ink*/ \/*else oprintf (str_black);*/ /*set black ink*/ \\oprintf (str_black); /*set black ink*/\\switch (m$attrs & (UL | STRIKE | DOU_UL | OVERLINE))\ {\ case UL : oprintf (str_line_ul, m$width, m$ulavp); break;\ case OVERLINE : oprintf (str_line_ol, m$width, m$ulavp); break;\ case (DOU_UL | UL) :\ case DOU_UL : oprintf (str_line_dul, m$width, m$ulavp); break;\ case STRIKE : oprintf (str_line_st, m$width, m$ulavp); break;\ case (UL | STRIKE) : oprintf (str_line_stul, m$width, m$ulavp); break;\ case (OVERLINE | STRIKE) : oprintf (str_line_stol, m$width, m$ulavp); break;\ case (DOU_UL | STRIKE | UL) :\ case (DOU_UL | STRIKE) : oprintf (str_line_stdul, m$width, m$ulavp); break;\ case (UL | OVERLINE) : oprintf (str_line_ulol, m$width, m$ulavp); break;\ case (DOU_UL | OVERLINE | UL) :\ case (DOU_UL | OVERLINE) : oprintf (str_line_dulol, m$width, m$ulavp); break;\ case (DOU_UL | OVERLINE | STRIKE | UL):\ case (UL | OVERLINE | STRIKE) : oprintf (str_line_stulol, m$width, m$ulavp); break;\ case (DOU_UL | OVERLINE | STRIKE) : oprintf (str_line_stdulol, m$width, m$ulavp); break;\ break;\ }\oprintf (str_black); /*set black ink*/ /******************************************************************M$OUTPUT_FONT(m$source_buffer,m$lrhalf) 5.21.1 Input 5.21.2 Output None 5.21.3 Called Routines None 5.21.4 Internal Variables And Storage 5.21.5 Error Handling None******************************************************************//* WORD * source_buffer, * lrhalf; */#define M$OUTPUT_FONT(m$source_buffer,m$lrhalf) \ \/* LONG m$i; */ \ \ \/* for (m$i = BIGIN; m$i =< END; m$i++) */ \ { \ /* Get data from Nick's stuff */ \ \ /* Put data to Mark's stuff */ \ } /******************************************************************M$CLOSE_DECVEC() 5.19.1 Generalities This will clear the decvec flag and restores the psstate. 5.19.2 Input 1. ps_state.decvec 2. ap 5.19.3 Output 1. ps_state.decvec 5.19.4 Called Routines 1. restore 5.19.5 Internal Variables And Storage******************************************************************/#define M$CLOSE_DECVEC() \ \cur_ps_st -> open = ALLCLOSED; \/* ps_str (str_closepath); */ \ps_str (str_stroke); \ \M$RESTORE(); \/******************************************************************M$OPEN_DECVEC() 5.18.1 Generalities Sets the decvec flag and saves ps_state. 5.18.2 Input 1. ps_state.decvec 2. ap 5.18.3 Output 1. ps_state.decvec 5.18.4 Called Routines 1. save 5.18.5 Internal Variables And Storage******************************************************************/#define M$OPEN_DECVEC() \ \M$SAVE(); \/* ps_str (str_newpath); */ \cur_ps_st -> open = DECVECOPEN; /* not needed in the code */ /******************************************************************M$CLOSE_SIXEL() 5.17.1 Generalities This clears the sixel flag and restores ps_state 5.17.2 Input ps_state.sixel 5.17.3 Output ps_state.sixel 5.17.4 Called Routines 1. restore 5.17.5 Internal Variables And Storage******************************************************************/#define M$CLOSE_SIXEL() \ \cur_ps_st -> open = ALLCLOSED; /* not needed in code */ \M$RESTORE(); \/******************************************************************M$OPEN_SIXEL() 5.16.1 Generalities Set sixel flag to open and saves ps_state. 5.16.2 Input 1. psstate.sixel 2. count 3. ap 5.16.3 Output 1. ps_state.sixel 2. prints (str_sixel_preamble) 5.16.4 Called Routines 1. save 2. output_sixel 5.16.5 Internal Variables And Storage******************************************************************//* print (str_sixel_preamble) */#define M$OPEN_SIXEL() \ \M$SAVE(); \cg_st.cgst_first_row = TRUE; \cur_ps_st -> open = SIXELOPEN; /* set sixel flag to open */ /******************************************************************M$REPLACE(m$box_number)******************************************************************//* WORD box_number; */#define M$REPLACE(m$box_number) \ \/*** stub ***/ /******************************************************************M$OPEN_SPACING()******************************************************************/#define M$OPEN_SPACING() \ \cur_ps_st -> open = SPACINGOPEN; /* The state that was restored \ better be all closed or else \ MERDDE!!! */ \while (stack_ptr > SPACED_LEVEL) { M$RESTORE(); } \/******************************************************************M$CLOSE_SPACING()******************************************************************/#define M$CLOSE_SPACING() \ \M$SAVE(); \cur_ps_st -> open = ALLCLOSED; \/* ps_str (str_scale); *//******************************************************************M$OPEN_FONT() 5.15.1 Generalities 5.15.2 Input 5.15.3 Output 5.15.4 Called Routines 1. restore 2. replace 5.15.5 Internal Variables And Storage******************************************************************/#define M$OPEN_FONT() \ \cur_ps_st -> open = FONTOPEN; /* The state that was restored \ better be all closed or else \ MERDDE!!! */ \while (stack_ptr > DLL_LEVEL) { M$RESTORE(); } \/******************************************************************M$CLOSE_FONT() 5.14.1 Generalities 5.14.2 Input 5.14.3 Output 5.14.4 Called Routines 1. save 2. get_box 3. output_box 5.14.5 Internal Variables And Storage******************************************************************//* WORD box_number; */#define M$CLOSE_FONT() \ \M$SAVE(); \M$SAVE(); \/* get_box (); */ \cur_ps_st -> open = ALLCLOSED; /******************************************************************M$CLOSE_SHOW()******************************************************************/#define M$CLOSE_SHOW() \\ps_char ('\)'); \if (cur_ps_st -> curchar.font_data.algorithmic_attributes & (UL | OVERLINE | DOU_UL)) \oprintf (" %d", (cur_ps_st -> curchar.attr_data.attr_baseline_offset - \ cur_ps_st -> curchar.ap.yval)); \\ps_str (close_show_str [(cur_ps_st -> curchar.font_data.algorithmic_attributes & (UL | OVERLINE | DOU_UL | ITALIC | BOLD | STRIKE))]); \M$RESTORE(); /* ps_str (str_restore); */ \/* update_show (); */ \cur_ps_st -> open = ALLCLOSED; /******************************************************************M$OPEN_SHOW() 5.12.1 Generalities This routine is used by ALL shows. 5.12.2 Input 5.12.3 Output 5.12.4 Called Routines 1. close_all 2. output_show 3. update_show 5.12.5 Internal Variables And Storage *** (Don't forget to add to xlv__state module) *** str_open_show [] = {"("}; ******************************************************************/#define M$OPEN_SHOW(m$attrs) \ \M$SAVE(); \ps_str (str_open_show); \/* cur_ps_st -> curchar.font_data.algorithmic_attributes = (SHOWOPEN | (m$attrs & (UL | OVERLINE | DOU_UL | ITALIC | BOLD | STRIKE))); */ \cur_ps_st -> curchar.font_data.algorithmic_attributes = (m$attrs ); \cur_ps_st -> open = SHOWOPEN; /******************************************************************M$CLOSE_ALL() 5.20.1 Generalities 5.20.2 Input 5.20.3 Output 5.20.4 Called Routines None 5.20.5 Internal Variables And Storage******************************************************************/#define M$CLOSE_ALL() \ \if (cur_ps_st -> open != ALLCLOSED) \ \ switch (cur_ps_st -> open) \ { \ case SHOWOPEN : M$CLOSE_SHOW(); break; \ case FONTOPEN : M$CLOSE_FONT(); break; \ case SPACINGOPEN : M$CLOSE_SPACING(); break; \ case DECVECOPEN : M$CLOSE_DECVEC(); break; \ case SIXELOPEN : M$CLOSE_SIXEL(); break; \
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -