1 | /* |
1 | /* |
2 | * $Id: rxvt.h,v 1.3 2003/11/25 11:52:42 pcg Exp $ |
2 | * $Id: rxvt.h,v 1.19 2003/12/19 09:41:09 pcg Exp $ |
3 | */ |
3 | */ |
4 | |
4 | |
5 | #ifndef _RXVT_H_ /* include once only */ |
5 | #ifndef _RXVT_H_ /* include once only */ |
6 | #define _RXVT_H_ |
6 | #define _RXVT_H_ |
7 | |
7 | |
… | |
… | |
15 | #include <X11/Xatom.h> |
15 | #include <X11/Xatom.h> |
16 | |
16 | |
17 | #include "defaultfont.h" |
17 | #include "defaultfont.h" |
18 | #include "rxvtcolor.h" |
18 | #include "rxvtcolor.h" |
19 | #include "iom.h" |
19 | #include "iom.h" |
|
|
20 | #include "salloc.h" |
|
|
21 | |
|
|
22 | #include <wchar.h> |
20 | |
23 | |
21 | /* |
24 | /* |
22 | ***************************************************************************** |
25 | ***************************************************************************** |
23 | * SYSTEM HACKS |
26 | * SYSTEM HACKS |
24 | ***************************************************************************** |
27 | ***************************************************************************** |
… | |
… | |
480 | Rs_backgroundPixmap, |
483 | Rs_backgroundPixmap, |
481 | #endif |
484 | #endif |
482 | #if (MENUBAR_MAX) |
485 | #if (MENUBAR_MAX) |
483 | Rs_menu, |
486 | Rs_menu, |
484 | #endif |
487 | #endif |
485 | #ifndef NO_BOLDFONT |
|
|
486 | Rs_boldFont, |
|
|
487 | #endif |
|
|
488 | #ifdef GREEK_SUPPORT |
488 | #ifdef GREEK_SUPPORT |
489 | Rs_greek_keyboard, |
489 | Rs_greek_keyboard, |
490 | Rs_greektoggle_key, |
490 | Rs_greektoggle_key, |
491 | #endif |
491 | #endif |
492 | Rs_loginShell, |
492 | Rs_loginShell, |
… | |
… | |
551 | Rs_answerbackstring, |
551 | Rs_answerbackstring, |
552 | Rs_tripleclickwords, |
552 | Rs_tripleclickwords, |
553 | Rs_cursorBlink, |
553 | Rs_cursorBlink, |
554 | Rs_pointerBlank, |
554 | Rs_pointerBlank, |
555 | Rs_pointerBlankDelay, |
555 | Rs_pointerBlankDelay, |
|
|
556 | Rs_imLocale, |
556 | NUM_RESOURCES |
557 | NUM_RESOURCES |
557 | }; |
|
|
558 | |
|
|
559 | enum { |
|
|
560 | TIMEOUT_INCR = 0, |
|
|
561 | NUM_TIMEOUTS |
|
|
562 | }; |
558 | }; |
563 | |
559 | |
564 | enum { |
560 | enum { |
565 | XA_COMPOUND_TEXT = 0, |
561 | XA_COMPOUND_TEXT = 0, |
566 | XA_MULTIPLE, |
562 | XA_MULTIPLE, |
… | |
… | |
666 | #define STRLEN(x) strlen((const char *)(x)) |
662 | #define STRLEN(x) strlen((const char *)(x)) |
667 | #define STRCHR(x, y) strchr((const char *)(x), (int)(y)) |
663 | #define STRCHR(x, y) strchr((const char *)(x), (int)(y)) |
668 | #define STRRCHR(x, y) strrchr((const char *)(x), (int)(y)) |
664 | #define STRRCHR(x, y) strrchr((const char *)(x), (int)(y)) |
669 | |
665 | |
670 | /* convert pixel dimensions to row/column values. Everything as int32_t */ |
666 | /* convert pixel dimensions to row/column values. Everything as int32_t */ |
671 | #define Pixel2Col(x) Pixel2Width((int32_t)(x) - (int32_t)R->TermWin.int_bwidth) |
667 | #define Pixel2Col(x) Pixel2Width((int32_t)(x) - (int32_t)TermWin.int_bwidth) |
672 | #define Pixel2Row(y) Pixel2Height((int32_t)(y) - (int32_t)R->TermWin.int_bwidth) |
668 | #define Pixel2Row(y) Pixel2Height((int32_t)(y) - (int32_t)TermWin.int_bwidth) |
673 | #define Pixel2Width(x) ((int32_t)(x) / (int32_t)R->TermWin.fwidth) |
669 | #define Pixel2Width(x) ((int32_t)(x) / (int32_t)TermWin.fwidth) |
674 | #define Pixel2Height(y) ((int32_t)(y) / (int32_t)R->TermWin.fheight) |
670 | #define Pixel2Height(y) ((int32_t)(y) / (int32_t)TermWin.fheight) |
675 | #define Col2Pixel(col) ((int32_t)Width2Pixel(col) + (int32_t)R->TermWin.int_bwidth) |
671 | #define Col2Pixel(col) ((int32_t)Width2Pixel(col) + (int32_t)TermWin.int_bwidth) |
676 | #define Row2Pixel(row) ((int32_t)Height2Pixel(row) + (int32_t)R->TermWin.int_bwidth) |
672 | #define Row2Pixel(row) ((int32_t)Height2Pixel(row) + (int32_t)TermWin.int_bwidth) |
677 | #define Width2Pixel(n) ((int32_t)(n) * (int32_t)R->TermWin.fwidth) |
673 | #define Width2Pixel(n) ((int32_t)(n) * (int32_t)TermWin.fwidth) |
678 | #define Height2Pixel(n) ((int32_t)(n) * (int32_t)R->TermWin.fheight) |
674 | #define Height2Pixel(n) ((int32_t)(n) * (int32_t)TermWin.fheight) |
679 | |
675 | |
680 | #define TermWin_TotalWidth() ((int32_t)R->TermWin.width + 2 * (int32_t)R->TermWin.int_bwidth) |
676 | #define TermWin_TotalWidth() ((int32_t)TermWin.width + 2 * (int32_t)TermWin.int_bwidth) |
681 | #define TermWin_TotalHeight() ((int32_t)R->TermWin.height + 2 * (int32_t)R->TermWin.int_bwidth) |
677 | #define TermWin_TotalHeight() ((int32_t)TermWin.height + 2 * (int32_t)TermWin.int_bwidth) |
682 | |
678 | |
683 | #define Xscreen DefaultScreen(R->Xdisplay) |
679 | #define Xscreen DefaultScreen(R->Xdisplay) |
684 | #define Xroot DefaultRootWindow(R->Xdisplay) |
680 | #define Xroot DefaultRootWindow(R->Xdisplay) |
685 | |
681 | |
686 | /* how to build & extract colors and attributes */ |
682 | /* how to build & extract colors and attributes */ |
… | |
… | |
718 | |
714 | |
719 | #define SET_PIXCOLOR(h, x) ((h)->pixcolor_set[(x) / NPIXCLR_BITS] |= (1 << ((x) % NPIXCLR_BITS))) |
715 | #define SET_PIXCOLOR(h, x) ((h)->pixcolor_set[(x) / NPIXCLR_BITS] |= (1 << ((x) % NPIXCLR_BITS))) |
720 | #define ISSET_PIXCOLOR(h, x) ((h)->pixcolor_set[(x) / NPIXCLR_BITS] & (1 << ((x) % NPIXCLR_BITS))) |
716 | #define ISSET_PIXCOLOR(h, x) ((h)->pixcolor_set[(x) / NPIXCLR_BITS] & (1 << ((x) % NPIXCLR_BITS))) |
721 | |
717 | |
722 | #ifdef HAVE_SCROLLBARS |
718 | #ifdef HAVE_SCROLLBARS |
723 | # define scrollbar_TotalWidth() (R->scrollBar.width + R->sb_shadow * 2) |
719 | # define scrollbar_TotalWidth() (scrollBar.width + sb_shadow * 2) |
724 | #else |
720 | #else |
725 | # define scrollbar_TotalWidth() (0) |
721 | # define scrollbar_TotalWidth() (0) |
726 | #endif |
722 | #endif |
727 | #define scrollbar_isMotion() (R->scrollBar.state == 'm') |
723 | #define scrollbar_isMotion() (R->scrollBar.state == 'm') |
728 | #define scrollbar_isUp() (R->scrollBar.state == 'U') |
724 | #define scrollbar_isUp() (R->scrollBar.state == 'U') |
729 | #define scrollbar_isDn() (R->scrollBar.state == 'D') |
725 | #define scrollbar_isDn() (R->scrollBar.state == 'D') |
730 | #define scrollbar_isUpDn() isupper (R->scrollBar.state) |
726 | #define scrollbar_isUpDn() isupper (R->scrollBar.state) |
731 | #define isScrollbarWindow(w) (R->scrollBar.state && (w) == R->scrollBar.win) |
727 | #define isScrollbarWindow(w) (R->scrollBar.state && (w) == R->scrollBar.win) |
732 | |
|
|
733 | #define scrollbar_setIdle() R->scrollBar.state = 1 |
|
|
734 | #define scrollbar_setMotion() R->scrollBar.state = 'm' |
|
|
735 | #define scrollbar_setUp() R->scrollBar.state = 'U' |
|
|
736 | #define scrollbar_setDn() R->scrollBar.state = 'D' |
|
|
737 | |
728 | |
738 | #define scrollbarnext_dnval() (R->scrollBar.end + (R->scrollBar.width + 1)) |
729 | #define scrollbarnext_dnval() (R->scrollBar.end + (R->scrollBar.width + 1)) |
739 | #define scrollbarnext_upButton(y) ((y) > R->scrollBar.end \ |
730 | #define scrollbarnext_upButton(y) ((y) > R->scrollBar.end \ |
740 | && (y) <= scrollbarnext_dnval()) |
731 | && (y) <= scrollbarnext_dnval()) |
741 | #define scrollbarnext_dnButton(y) ((y) > scrollbarnext_dnval()) |
732 | #define scrollbarnext_dnButton(y) ((y) > scrollbarnext_dnval()) |
… | |
… | |
754 | #define scrollbar_size() (R->scrollBar.end - R->scrollBar.beg \ |
745 | #define scrollbar_size() (R->scrollBar.end - R->scrollBar.beg \ |
755 | - scrollbar_minheight()) |
746 | - scrollbar_minheight()) |
756 | |
747 | |
757 | #if (MENUBAR_MAX > 1) |
748 | #if (MENUBAR_MAX > 1) |
758 | /* rendition style flags */ |
749 | /* rendition style flags */ |
759 | # define menuBar_height() (R->TermWin.fheight + SHADOW) |
750 | # define menuBar_height() (TermWin.fheight + SHADOW) |
760 | # define menuBar_TotalHeight() (menuBar_height() + SHADOW + menuBar_margin) |
751 | # define menuBar_TotalHeight() (menuBar_height() + SHADOW + menuBar_margin) |
761 | # define isMenuBarWindow(w) ((w) == R->menuBar.win) |
752 | # define isMenuBarWindow(w) ((w) == R->menuBar.win) |
762 | #else |
753 | #else |
763 | # define menuBar_height() (0) |
754 | # define menuBar_height() (0) |
764 | # define menuBar_TotalHeight() (0) |
755 | # define menuBar_TotalHeight() (0) |
… | |
… | |
773 | |
764 | |
774 | #ifndef STRICT_FONT_CHECKING |
765 | #ifndef STRICT_FONT_CHECKING |
775 | # define rxvt_get_fontwidest(font) ((font)->max_bounds.width) |
766 | # define rxvt_get_fontwidest(font) ((font)->max_bounds.width) |
776 | #endif |
767 | #endif |
777 | |
768 | |
778 | #define rxvt_Gr_ButtonPress(x,y) rxvt_Gr_ButtonReport (r, 'P',(x),(y)) |
769 | #define rxvt_Gr_ButtonPress(x,y) rxvt_Gr_ButtonReport (R, 'P',(x),(y)) |
779 | #define rxvt_Gr_ButtonRelease(x,y) rxvt_Gr_ButtonReport (r, 'R',(x),(y)) |
770 | #define rxvt_Gr_ButtonRelease(x,y) rxvt_Gr_ButtonReport (R, 'R',(x),(y)) |
780 | |
771 | |
781 | #ifdef UTMP_SUPPORT |
772 | #ifdef UTMP_SUPPORT |
782 | # if !defined(RXVT_UTMPX_FILE) || !defined(HAVE_STRUCT_UTMPX) |
773 | # if !defined(RXVT_UTMPX_FILE) || !defined(HAVE_STRUCT_UTMPX) |
783 | # undef HAVE_UTMPX_H |
774 | # undef HAVE_UTMPX_H |
784 | # undef HAVE_STRUCT_UTMPX |
775 | # undef HAVE_STRUCT_UTMPX |
… | |
… | |
839 | */ |
830 | */ |
840 | #ifdef MENUBAR |
831 | #ifdef MENUBAR |
841 | # include "menubar.h" |
832 | # include "menubar.h" |
842 | #endif |
833 | #endif |
843 | |
834 | |
|
|
835 | #define BLINK_INTERVAL 0.5 |
|
|
836 | |
844 | struct mbstate { |
837 | struct mbstate { |
845 | unsigned char orig; |
838 | mbstate_t mbs; |
846 | uint32_t reg; |
|
|
847 | int cnt; |
|
|
848 | |
839 | |
849 | mbstate () |
840 | mbstate () |
850 | { |
841 | { |
851 | cnt = 0; |
842 | MEMSET (&mbs, 0, sizeof (mbs)); |
852 | } |
843 | } |
853 | }; |
844 | }; |
854 | |
845 | |
855 | struct rxvt_term : rxvt_vars { |
846 | struct rxvt_term : rxvt_vars { |
856 | struct mbstate mbstate; |
847 | struct mbstate mbstate; |
857 | #ifdef __GNUC__ |
848 | |
858 | unsigned char want_refresh:1, |
849 | unsigned char want_refresh:1, |
859 | want_full_refresh:1, |
850 | #ifdef TRANSPARENT |
860 | am_transparent:1, |
851 | want_full_refresh:1, /* awaiting full screen refresh */ |
861 | am_pixmap_trans:1, |
852 | #endif |
862 | current_screen:1, |
853 | #if defined(XPM_BACKGROUND) || defined(TRANSPARENT) |
863 | hate_those_clicks:1, |
854 | am_transparent:1, /* is a transparent term */ |
|
|
855 | am_pixmap_trans:1, /* transparency w/known root pixmap */ |
|
|
856 | #endif |
|
|
857 | current_screen:1, /* primary or secondary */ |
|
|
858 | hate_those_clicks:1, /* a.k.a. keep mark position */ |
864 | num_scr_allow:1, |
859 | num_scr_allow:1, |
865 | bypass_keystate:1; |
860 | bypass_keystate:1, |
866 | unsigned char chstat:1, |
861 | #ifdef CURSOR_BLINK |
867 | lost_multi:1, |
|
|
868 | multi_byte:1, |
|
|
869 | hidden_cursor:1, |
862 | hidden_cursor:1, |
|
|
863 | #endif |
|
|
864 | #ifdef POINTER_BLANK |
870 | hidden_pointer:1, |
865 | hidden_pointer:1, |
|
|
866 | #endif |
871 | parsed_geometry:1; |
867 | parsed_geometry:1, |
872 | #else |
868 | seen_input:1, /* wether any input has been seen so far */ |
873 | unsigned char want_refresh, |
869 | enc_utf8:1; /* wether terminal reads/writes utf-8 */ |
874 | # ifdef TRANSPARENT |
|
|
875 | want_full_refresh, /* awaiting full screen refresh */ |
|
|
876 | # endif |
|
|
877 | # if defined(XPM_BACKGROUND) || defined(TRANSPARENT) |
|
|
878 | am_transparent, /* is a transparent term */ |
|
|
879 | am_pixmap_trans, /* transparency w/known root pixmap */ |
|
|
880 | # endif |
|
|
881 | current_screen, /* primary or secondary */ |
|
|
882 | hate_those_clicks, /* a.k.a. keep mark position */ |
|
|
883 | num_scr_allow, |
|
|
884 | bypass_keystate, |
|
|
885 | # ifdef MULTICHAR_SET |
|
|
886 | chstat, |
|
|
887 | lost_multi, /* set ==> we only got half a glyph */ |
|
|
888 | multi_byte, /* set ==> currently using 2 bytes per glyph */ |
|
|
889 | # endif |
|
|
890 | # ifdef CURSOR_BLINK |
|
|
891 | hidden_cursor, |
|
|
892 | # endif |
|
|
893 | # ifdef POINTER_BLANK |
|
|
894 | hidden_pointer, |
|
|
895 | # endif |
|
|
896 | parsed_geometry; |
|
|
897 | #endif /* !__GNUC__ */ |
|
|
898 | |
870 | |
899 | unsigned char refresh_type, |
871 | unsigned char refresh_type, |
900 | #ifdef UTMP_SUPPORT |
872 | #ifdef UTMP_SUPPORT |
901 | next_utmp_action, |
873 | next_utmp_action, |
902 | #endif |
874 | #endif |
… | |
… | |
913 | #ifdef GREEK_SUPPORT |
885 | #ifdef GREEK_SUPPORT |
914 | short greek_mode; /* greek keyboard mode */ |
886 | short greek_mode; /* greek keyboard mode */ |
915 | #endif |
887 | #endif |
916 | short rvideo; |
888 | short rvideo; |
917 | int16_t num_scr; /* screen: number lines scrolled */ |
889 | int16_t num_scr; /* screen: number lines scrolled */ |
918 | uint16_t prev_ncol, /* screen: previous number of columns */ |
890 | uint16_t prev_ncol, /* screen: previous number of columns */ |
919 | prev_nrow; /* screen: previous number of rows */ |
891 | prev_nrow; /* screen: previous number of rows */ |
920 | #ifdef RXVT_GRAPHICS |
892 | #ifdef RXVT_GRAPHICS |
921 | uint16_t gr_prev_start; |
893 | uint16_t gr_prev_start; |
922 | #endif |
894 | #endif |
923 | /* ---------- */ |
895 | /* ---------- */ |
924 | rend_t rstyle; |
896 | rend_t rstyle; |
925 | /* ---------- */ |
897 | /* ---------- */ |
926 | uint32_t pixcolor_set[NPIXCLR_SETS]; |
898 | uint32_t pixcolor_set[NPIXCLR_SETS]; |
927 | /* ---------- */ |
899 | /* ---------- */ |
928 | #ifdef SELECTION_SCROLLING |
900 | #ifdef SELECTION_SCROLLING |
929 | int scroll_selection_delay, |
901 | int scroll_selection_delay, |
930 | scroll_selection_lines; |
902 | scroll_selection_lines; |
931 | enum page_dirn scroll_selection_dir; |
903 | enum page_dirn scroll_selection_dir; |
… | |
… | |
954 | currmaxcol, |
926 | currmaxcol, |
955 | #ifdef MENUBAR |
927 | #ifdef MENUBAR |
956 | menu_readonly, /* okay to alter menu? */ |
928 | menu_readonly, /* okay to alter menu? */ |
957 | Arrows_x, |
929 | Arrows_x, |
958 | #endif |
930 | #endif |
959 | #if (MENUBAR_MAX > 1) |
931 | #if MENUBAR_MAX > 1 |
960 | Nbars, |
932 | Nbars, |
961 | #endif |
933 | #endif |
962 | window_vt_x, |
934 | window_vt_x, |
963 | window_vt_y, |
935 | window_vt_y, |
964 | window_sb_x, |
936 | window_sb_x, |
… | |
… | |
1016 | #if (defined(HAVE_SETEUID) || defined(HAVE_SETREUID)) && !defined(__CYGWIN32__) |
988 | #if (defined(HAVE_SETEUID) || defined(HAVE_SETREUID)) && !defined(__CYGWIN32__) |
1017 | uid_t euid; |
989 | uid_t euid; |
1018 | gid_t egid; |
990 | gid_t egid; |
1019 | #endif |
991 | #endif |
1020 | /* ---------- */ |
992 | /* ---------- */ |
1021 | Cursor pointer_leftptr; |
993 | Cursor leftptr_cursor; |
1022 | #ifdef POINTER_BLANK |
994 | #ifdef POINTER_BLANK |
1023 | Cursor pointer_blank; |
995 | Cursor blank_cursor; |
1024 | #endif |
996 | #endif |
1025 | /* ---------- */ |
997 | /* ---------- */ |
1026 | const char *ttydev; /* pty/tty name */ |
998 | const char *ttydev; /* pty/tty name */ |
1027 | #ifndef NO_BACKSPACE_KEY |
999 | #ifndef NO_BACKSPACE_KEY |
1028 | const char *key_backspace; |
1000 | const char *key_backspace; |
… | |
… | |
1087 | struct timeval lastcursorchange; |
1059 | struct timeval lastcursorchange; |
1088 | #endif |
1060 | #endif |
1089 | #ifdef POINTER_BLANK |
1061 | #ifdef POINTER_BLANK |
1090 | struct timeval lastmotion; |
1062 | struct timeval lastmotion; |
1091 | #endif |
1063 | #endif |
1092 | struct timeval timeout[NUM_TIMEOUTS]; |
|
|
1093 | |
1064 | |
1094 | /* these three don't need to be kept but do so to placate some mem checkers */ |
1065 | /* these three don't need to be kept but do so to placate some mem checkers */ |
1095 | char *env_windowid; /* environmental variable WINDOWID */ |
1066 | char *env_windowid; /* environmental variable WINDOWID */ |
1096 | char *env_display; /* environmental variable DISPLAY */ |
1067 | char *env_display; /* environmental variable DISPLAY */ |
1097 | char *env_term; /* environmental variable TERM */ |
1068 | char *env_term; /* environmental variable TERM */ |
1098 | char *env_colorfgbg; |
1069 | char *env_colorfgbg; |
1099 | char *buffer; |
1070 | char *buffer; |
1100 | char *locale; |
1071 | char *locale; |
|
|
1072 | char *codeset; |
1101 | char charsets[4]; |
1073 | char charsets[4]; |
1102 | unsigned char *v_buffer; /* pointer to physical buffer */ |
1074 | unsigned char *v_buffer; /* pointer to physical buffer */ |
1103 | unsigned char *v_bufstr; /* beginning of area to write */ |
|
|
1104 | unsigned char *v_bufptr; /* end of area to write */ |
1075 | unsigned int v_buflen; /* size of area to write */ |
1105 | unsigned char *v_bufend; /* end of physical buffer */ |
|
|
1106 | char *newfont[MAX_NFONTS]; |
1076 | char *newfont[MAX_NFONTS]; |
1107 | #ifdef KEYSYM_RESOURCE |
1077 | #ifdef KEYSYM_RESOURCE |
1108 | const unsigned char *Keysym_map[256]; |
1078 | const unsigned char *Keysym_map[256]; |
1109 | #endif |
1079 | #endif |
1110 | const char *rs[NUM_RESOURCES]; |
1080 | const char *rs[NUM_RESOURCES]; |
1111 | /* command input buffering */ |
1081 | /* command input buffering */ |
1112 | unsigned char *cmdbuf_ptr, *cmdbuf_endp; |
1082 | unsigned char *cmdbuf_ptr, *cmdbuf_endp; |
1113 | unsigned char cmdbuf_base[BUFSIZ]; |
1083 | unsigned char cmdbuf_base[BUFSIZ]; |
1114 | unsigned char kbuf[KBUFSZ]; |
1084 | |
|
|
1085 | rxvt_salloc *ralloc; |
|
|
1086 | rxvt_salloc *talloc; |
|
|
1087 | |
|
|
1088 | void paste (const unsigned char *data, unsigned int len); |
|
|
1089 | |
|
|
1090 | void flush (); |
|
|
1091 | |
|
|
1092 | void check_cb (check_watcher &w); check_watcher check_ev; |
|
|
1093 | void destroy_cb (time_watcher &w); time_watcher destroy_ev; |
1115 | |
1094 | |
1116 | void pty_cb (io_watcher &w, short revents); io_watcher pty_ev; |
1095 | void pty_cb (io_watcher &w, short revents); io_watcher pty_ev; |
1117 | void x_cb (io_watcher &w, short revents); io_watcher x_ev; |
1096 | void x_cb (io_watcher &w, short revents); io_watcher x_ev; |
1118 | |
1097 | |
|
|
1098 | void incr_cb (time_watcher &w); time_watcher incr_ev; |
|
|
1099 | |
|
|
1100 | #ifdef CURSOR_BLINK |
|
|
1101 | void blink_cb (time_watcher &w); time_watcher blink_ev; |
|
|
1102 | #endif |
|
|
1103 | |
|
|
1104 | #ifdef POINTER_BLANK |
|
|
1105 | void pointer_cb (time_watcher &w); time_watcher pointer_ev; |
|
|
1106 | void pointer_blank (); |
|
|
1107 | void pointer_unblank (); |
|
|
1108 | #endif |
|
|
1109 | |
|
|
1110 | void tt_printf (const char *fmt,...); |
|
|
1111 | void tt_write (const unsigned char *data, unsigned int len); |
|
|
1112 | |
|
|
1113 | void tt_winch (); |
|
|
1114 | |
1119 | rxvt_term (); |
1115 | rxvt_term (); |
1120 | ~rxvt_term (); |
1116 | ~rxvt_term (); |
|
|
1117 | void destroy (); |
1121 | |
1118 | |
|
|
1119 | bool init (int argc, const char *const *argv); |
|
|
1120 | bool init_vars (); |
|
|
1121 | |
|
|
1122 | uint32_t next_char (); |
|
|
1123 | |
|
|
1124 | bool pty_fill (); |
1122 | void process_x_events (); |
1125 | void process_x_events (); |
1123 | |
1126 | |
1124 | void *operator new (size_t s); |
1127 | void *operator new (size_t s); |
1125 | void operator delete (void *p, size_t s); |
1128 | void operator delete (void *p, size_t s); |
|
|
1129 | |
|
|
1130 | void init_secondary (); |
|
|
1131 | const char **init_resources (int argc, const char *const *argv); |
|
|
1132 | void init_env (); |
|
|
1133 | void set_locale (const char *locale); |
|
|
1134 | void init_xlocale (); |
|
|
1135 | void init_command (const char *const *argv); |
|
|
1136 | int run_command (const char *const *argv); |
|
|
1137 | int run_child (const char *const *argv); |
|
|
1138 | |
|
|
1139 | void color_aliases(int idx); |
|
|
1140 | void recolour_cursor (); |
|
|
1141 | void create_windows (int argc, const char *const *argv); |
|
|
1142 | void resize_all_windows (unsigned int width, unsigned int height, int ignoreparent); |
|
|
1143 | void window_calc (unsigned int width, unsigned int height); |
|
|
1144 | void set_preedit_area (XRectangle * preedit_rect, XRectangle * status_rect, XRectangle * needed_rect); |
|
|
1145 | |
|
|
1146 | #if USE_XIM |
|
|
1147 | void set_size (XRectangle *size); |
|
|
1148 | void set_position (XPoint *pos); |
|
|
1149 | void set_color (unsigned long *fg, unsigned long *bg); |
|
|
1150 | #endif |
|
|
1151 | |
|
|
1152 | void resize_scrollbar (); |
|
|
1153 | |
|
|
1154 | void pixel_position (int *x, int *y); |
|
|
1155 | |
|
|
1156 | void selection_click (int clicks, int x, int y); |
|
|
1157 | void selection_extend (int x, int y, int flag); |
|
|
1158 | void selection_rotate (int x, int y); |
|
|
1159 | |
|
|
1160 | /* screen(!) */ |
|
|
1161 | void scr_blank_line (text_t *et, rend_t *er, unsigned int width, rend_t efs); |
|
|
1162 | void scr_blank_screen_mem (text_t **tp, rend_t **rp, unsigned int row, rend_t efs); |
|
|
1163 | int scr_scroll_text (int row1, int row2, int count, int spec); |
|
|
1164 | void scr_reset (); |
|
|
1165 | void scr_reset_realloc (); |
|
|
1166 | void scr_release (); |
|
|
1167 | void scr_clear (); |
|
|
1168 | void scr_refresh (unsigned char refresh_type); |
|
|
1169 | void scr_erase_screen (int mode); |
|
|
1170 | void scr_touch (bool refresh); |
|
|
1171 | void scr_expose (int x, int y, int width, int height, bool refresh); |
1126 | }; |
1172 | }; |
|
|
1173 | |
|
|
1174 | #define SET_LOCALE(locale) rxvt_set_locale (locale) |
|
|
1175 | extern void rxvt_set_locale (const char *locale); |
1127 | |
1176 | |
1128 | #ifndef __attribute__ |
1177 | #ifndef __attribute__ |
1129 | # ifdef __GNUC__ |
1178 | # ifdef __GNUC__ |
1130 | # if (__GNUC__ == 2 && __GNUC_MINOR__ < 5) || (__GNUC__ < 2) |
1179 | # if (__GNUC__ == 2 && __GNUC_MINOR__ < 5) || (__GNUC__ < 2) |
1131 | # define __attribute__(x) |
1180 | # define __attribute__(x) |
… | |
… | |
1149 | #ifdef DEBUG_malloc |
1198 | #ifdef DEBUG_malloc |
1150 | # include "dmalloc.h" /* This comes last */ |
1199 | # include "dmalloc.h" /* This comes last */ |
1151 | #endif |
1200 | #endif |
1152 | |
1201 | |
1153 | #endif /* _RXVT_H_ */ |
1202 | #endif /* _RXVT_H_ */ |
|
|
1203 | |