ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/rxvt-unicode/src/rxvt.h
(Generate patch)

Comparing rxvt-unicode/src/rxvt.h (file contents):
Revision 1.11 by pcg, Tue Dec 16 23:04:13 2003 UTC vs.
Revision 1.24 by pcg, Thu Jan 29 21:35:58 2004 UTC

1/*
2 * $Id: rxvt.h,v 1.11 2003/12/16 23:04:13 pcg Exp $
3 */
4
5#ifndef _RXVT_H_ /* include once only */ 1#ifndef RXVT_H_ /* include once only */
6#define _RXVT_H_ 2#define RXVT_H_
7 3
8#include "rxvtlib.h" 4#include "rxvtlib.h"
9 5
10#include "feature.h" 6#include "feature.h"
11 7
15#include <X11/Xatom.h> 11#include <X11/Xatom.h>
16 12
17#include "defaultfont.h" 13#include "defaultfont.h"
18#include "rxvtcolor.h" 14#include "rxvtcolor.h"
19#include "iom.h" 15#include "iom.h"
16#include "salloc.h"
17
18#include <wchar.h>
20 19
21/* 20/*
22 ***************************************************************************** 21 *****************************************************************************
23 * SYSTEM HACKS 22 * SYSTEM HACKS
24 ***************************************************************************** 23 *****************************************************************************
315enum { 314enum {
316 PRIMARY = 0, 315 PRIMARY = 0,
317 SECONDARY 316 SECONDARY
318}; 317};
319 318
320enum {
321 SBYTE = 0,
322 WBYTE
323};
324
325
326#define RS_None 0 /* Normal */ 319#define RS_None 0 /* Normal */
327 320
328#define RS_fgMask 0x000001FFu /* 512 colors */ 321#define RS_fgMask 0x000001FFu /* 512 colors */
329#define RS_bgMask 0x0003FE00u /* 512 colors */ 322#define RS_bgMask 0x0003FE00u /* 512 colors */
330#define RS_Bold 0x00040000u /* bold */ 323#define RS_Bold 0x00040000u /* bold */
331#define RS_Blink 0x00080000u /* blink */ 324#define RS_Blink 0x00080000u /* blink */
332#define RS_RVid 0x00100000u /* reverse video */ 325#define RS_RVid 0x00100000u /* reverse video */
333#define RS_Uline 0x00200000u /* underline */ 326#define RS_Uline 0x00200000u /* underline */
334 327
335#define RS_wide 0x00400000u /* only multibyte characters */
336#define IS_WIDE(r) ((r) & RS_wide)
337
338#define RS_fontMask 0xff000000u /* plenty(?) of fonts */ 328#define RS_fontMask 0xffc00000u /* plenty(?) of fonts */
339#define RS_fontShift 24 329#define RS_fontShift 22
340 330
341#define RS_baseattrMask (RS_Bold|RS_Blink|RS_RVid|RS_Uline) 331#define RS_baseattrMask (RS_Bold|RS_Blink|RS_RVid|RS_Uline)
342#define RS_attrMask (RS_baseattrMask|RS_fontMask|RS_wide) 332#define RS_attrMask (RS_baseattrMask|RS_fontMask)
343 333
344#define Sel_none 0 /* Not waiting */ 334#define Sel_none 0 /* Not waiting */
345#define Sel_normal 0x01 /* normal selection */ 335#define Sel_normal 0x01 /* normal selection */
346#define Sel_incr 0x02 /* incremental selection */ 336#define Sel_incr 0x02 /* incremental selection */
347#define Sel_direct 0x00 337#define Sel_direct 0x00
348#define Sel_Primary 0x01 338#define Sel_Primary 0x01
349#define Sel_Secondary 0x02 339#define Sel_Secondary 0x02
350#define Sel_Clipboard 0x03 340#define Sel_Clipboard 0x03
351#define Sel_whereMask 0x0f 341#define Sel_whereMask 0x0f
352#define Sel_CompoundText 0x10 /* last request was Compound */ 342#define Sel_CompoundText 0x10 /* last request was COMPOUND_TEXT */
343#define Sel_UTF8String 0x20 /* last request was UTF8_STRING */
353 344
354enum { 345enum {
355 C0_NUL = 0x00, 346 C0_NUL = 0x00,
356 C0_SOH, C0_STX, C0_ETX, C0_EOT, C0_ENQ, C0_ACK, C0_BEL, 347 C0_SOH, C0_STX, C0_ETX, C0_EOT, C0_ENQ, C0_ACK, C0_BEL,
357 C0_BS , C0_HT , C0_LF , C0_VT , C0_FF , C0_CR , C0_SO , C0_SI , 348 C0_BS , C0_HT , C0_LF , C0_VT , C0_FF , C0_CR , C0_SO , C0_SI ,
452 TOTAL_COLORS = NRS_COLORS /* */ 443 TOTAL_COLORS = NRS_COLORS /* */
453#endif 444#endif
454}; 445};
455 446
456#define Color_Bits 9 447#define Color_Bits 9
457#define NPIXCLR_SETS 9 /* (256 + 14) bits / 32 bits */ 448#define NPIXCLR_SETS ((TOTAL_COLORS + 31) / 32)
458#define NPIXCLR_BITS 32 449#define NPIXCLR_BITS 32
459 450
460#define DEFAULT_RSTYLE (RS_None | (Color_fg) | (Color_bg<<Color_Bits)) 451#define DEFAULT_RSTYLE (RS_None | (Color_fg) | (Color_bg<<Color_Bits))
461 452
462/* 453/*
463 * Resource list 454 * Resource list
464 */ 455 */
465enum { 456enum {
480 Rs_backgroundPixmap, 471 Rs_backgroundPixmap,
481#endif 472#endif
482#if (MENUBAR_MAX) 473#if (MENUBAR_MAX)
483 Rs_menu, 474 Rs_menu,
484#endif 475#endif
485#ifndef NO_BOLDFONT
486 Rs_boldFont,
487#endif
488#ifdef GREEK_SUPPORT 476#ifdef GREEK_SUPPORT
489 Rs_greek_keyboard, 477 Rs_greek_keyboard,
490 Rs_greektoggle_key, 478 Rs_greektoggle_key,
491#endif 479#endif
492 Rs_loginShell, 480 Rs_loginShell,
551 Rs_answerbackstring, 539 Rs_answerbackstring,
552 Rs_tripleclickwords, 540 Rs_tripleclickwords,
553 Rs_cursorBlink, 541 Rs_cursorBlink,
554 Rs_pointerBlank, 542 Rs_pointerBlank,
555 Rs_pointerBlankDelay, 543 Rs_pointerBlankDelay,
544 Rs_imLocale,
556 NUM_RESOURCES 545 NUM_RESOURCES
557}; 546};
558 547
548// see init.C:xa_named, which must be kept in sync
559enum { 549enum {
550 XA_TEXT = 0,
560 XA_COMPOUND_TEXT = 0, 551 XA_COMPOUND_TEXT,
552 XA_UTF8_STRING,
561 XA_MULTIPLE, 553 XA_MULTIPLE,
562 XA_TARGETS, 554 XA_TARGETS,
563 XA_TEXT,
564 XA_TIMESTAMP, 555 XA_TIMESTAMP,
565 XA_VT_SELECTION, 556 XA_VT_SELECTION,
566 XA_INCR, 557 XA_INCR,
567 XA_WMDELETEWINDOW, 558 XA_WMDELETEWINDOW,
568#ifdef TRANSPARENT 559#ifdef TRANSPARENT
573 XA_DNDSELECTION, 564 XA_DNDSELECTION,
574#endif /* OFFIX_DND */ 565#endif /* OFFIX_DND */
575 XA_CLIPBOARD, 566 XA_CLIPBOARD,
576 NUM_XA 567 NUM_XA
577}; 568};
578
579/*
580 * number of graphics points
581 * divisible by 2 (num lines)
582 * divisible by 4 (num rect)
583 */
584#define NGRX_PTS 1000
585 569
586/* DEC private modes */ 570/* DEC private modes */
587#define PrivMode_132 (1LU<<0) 571#define PrivMode_132 (1LU<<0)
588#define PrivMode_132OK (1LU<<1) 572#define PrivMode_132OK (1LU<<1)
589#define PrivMode_rVideo (1LU<<2) 573#define PrivMode_rVideo (1LU<<2)
620#else 604#else
621# define PrivMode_Default \ 605# define PrivMode_Default \
622(PrivMode_Autowrap|PrivMode_aplKP|PrivMode_ShiftKeys|PrivMode_VisibleCursor) 606(PrivMode_Autowrap|PrivMode_aplKP|PrivMode_ShiftKeys|PrivMode_VisibleCursor)
623#endif 607#endif
624 608
625#ifdef PREFER_24BIT
626# define XDEPTH R->Xdepth 609#define XDEPTH R->Xdepth
627# define XCMAP R->Xcmap 610#define XCMAP R->Xcmap
628# define XVISUAL R->Xvisual 611#define XVISUAL R->Xvisual
629#else 612
630# ifdef DEBUG_DEPTH
631# define XDEPTH DEBUG_DEPTH
632# else
633# define XDEPTH DefaultDepth(R->Xdisplay,Xscreen)
634# define XCMAP DefaultColormap(R->Xdisplay,Xscreen)
635# define XVISUAL DefaultVisual(R->Xdisplay,Xscreen)
636# endif
637#endif
638#define IMBUFSIZ 128 /* input modifier buffer sizes */ 613#define IMBUFSIZ 128 /* input modifier buffer sizes */
639#ifndef BUFSIZ 614#ifndef BUFSIZ
640# define BUFSIZ 4096 615# define BUFSIZ 4096
641#endif 616#endif
642#define KBUFSZ 512 /* size of keyboard mapping buffer */ 617#define KBUFSZ 512 /* size of keyboard mapping buffer */
643 618
644/* 619/*
645 ***************************************************************************** 620 *****************************************************************************
646 * MACRO DEFINES 621 * MACRO DEFINES
647 ***************************************************************************** 622 *****************************************************************************
661#define STRLEN(x) strlen((const char *)(x)) 636#define STRLEN(x) strlen((const char *)(x))
662#define STRCHR(x, y) strchr((const char *)(x), (int)(y)) 637#define STRCHR(x, y) strchr((const char *)(x), (int)(y))
663#define STRRCHR(x, y) strrchr((const char *)(x), (int)(y)) 638#define STRRCHR(x, y) strrchr((const char *)(x), (int)(y))
664 639
665/* convert pixel dimensions to row/column values. Everything as int32_t */ 640/* convert pixel dimensions to row/column values. Everything as int32_t */
666#define Pixel2Col(x) Pixel2Width((int32_t)(x) - (int32_t)R->TermWin.int_bwidth) 641#define Pixel2Col(x) Pixel2Width((int32_t)(x) - (int32_t)TermWin.int_bwidth)
667#define Pixel2Row(y) Pixel2Height((int32_t)(y) - (int32_t)R->TermWin.int_bwidth) 642#define Pixel2Row(y) Pixel2Height((int32_t)(y) - (int32_t)TermWin.int_bwidth)
668#define Pixel2Width(x) ((int32_t)(x) / (int32_t)R->TermWin.fwidth) 643#define Pixel2Width(x) ((int32_t)(x) / (int32_t)TermWin.fwidth)
669#define Pixel2Height(y) ((int32_t)(y) / (int32_t)R->TermWin.fheight) 644#define Pixel2Height(y) ((int32_t)(y) / (int32_t)TermWin.fheight)
670#define Col2Pixel(col) ((int32_t)Width2Pixel(col) + (int32_t)R->TermWin.int_bwidth) 645#define Col2Pixel(col) ((int32_t)Width2Pixel(col) + (int32_t)TermWin.int_bwidth)
671#define Row2Pixel(row) ((int32_t)Height2Pixel(row) + (int32_t)R->TermWin.int_bwidth) 646#define Row2Pixel(row) ((int32_t)Height2Pixel(row) + (int32_t)TermWin.int_bwidth)
672#define Width2Pixel(n) ((int32_t)(n) * (int32_t)R->TermWin.fwidth) 647#define Width2Pixel(n) ((int32_t)(n) * (int32_t)TermWin.fwidth)
673#define Height2Pixel(n) ((int32_t)(n) * (int32_t)R->TermWin.fheight) 648#define Height2Pixel(n) ((int32_t)(n) * (int32_t)TermWin.fheight)
674 649
675#define TermWin_TotalWidth() ((int32_t)R->TermWin.width + 2 * (int32_t)R->TermWin.int_bwidth) 650#define TermWin_TotalWidth() ((int32_t)TermWin.width + 2 * (int32_t)TermWin.int_bwidth)
676#define TermWin_TotalHeight() ((int32_t)R->TermWin.height + 2 * (int32_t)R->TermWin.int_bwidth) 651#define TermWin_TotalHeight() ((int32_t)TermWin.height + 2 * (int32_t)TermWin.int_bwidth)
677 652
678#define Xscreen DefaultScreen(R->Xdisplay)
679#define Xroot DefaultRootWindow(R->Xdisplay) 653#define Xroot DefaultRootWindow(R->Xdisplay)
680 654
681/* how to build & extract colors and attributes */ 655/* how to build & extract colors and attributes */
682#define GET_BASEFG(x) (((x) & RS_fgMask)) 656#define GET_BASEFG(x) (((x) & RS_fgMask))
683#define GET_BASEBG(x) (((x) & RS_bgMask)>>Color_Bits) 657#define GET_BASEBG(x) (((x) & RS_bgMask)>>Color_Bits)
710#define SET_FGCOLOR(x,fg) (((x) & ~RS_fgMask) | (fg)) 684#define SET_FGCOLOR(x,fg) (((x) & ~RS_fgMask) | (fg))
711#define SET_BGCOLOR(x,bg) (((x) & ~RS_bgMask) | ((bg)<<Color_Bits)) 685#define SET_BGCOLOR(x,bg) (((x) & ~RS_bgMask) | ((bg)<<Color_Bits))
712#define SET_ATTR(x,a) (((x) & ~RS_attrMask)| (a)) 686#define SET_ATTR(x,a) (((x) & ~RS_attrMask)| (a))
713 687
714#define SET_PIXCOLOR(h, x) ((h)->pixcolor_set[(x) / NPIXCLR_BITS] |= (1 << ((x) % NPIXCLR_BITS))) 688#define SET_PIXCOLOR(h, x) ((h)->pixcolor_set[(x) / NPIXCLR_BITS] |= (1 << ((x) % NPIXCLR_BITS)))
715#define ISSET_PIXCOLOR(h, x) ((h)->pixcolor_set[(x) / NPIXCLR_BITS] & (1 << ((x) % NPIXCLR_BITS))) 689#define ISSET_PIXCOLOR(h, x) ((h)->pixcolor_set[(x) / NPIXCLR_BITS] & (1 << ((x) % NPIXCLR_BITS)))
716 690
717#ifdef HAVE_SCROLLBARS 691#ifdef HAVE_SCROLLBARS
718# define scrollbar_TotalWidth() (R->scrollBar.width + R->sb_shadow * 2) 692# define scrollbar_TotalWidth() (scrollBar.width + sb_shadow * 2)
719#else 693#else
720# define scrollbar_TotalWidth() (0) 694# define scrollbar_TotalWidth() (0)
721#endif 695#endif
722#define scrollbar_isMotion() (R->scrollBar.state == 'm') 696#define scrollbar_isMotion() (R->scrollBar.state == 'm')
723#define scrollbar_isUp() (R->scrollBar.state == 'U') 697#define scrollbar_isUp() (R->scrollBar.state == 'U')
724#define scrollbar_isDn() (R->scrollBar.state == 'D') 698#define scrollbar_isDn() (R->scrollBar.state == 'D')
725#define scrollbar_isUpDn() isupper (R->scrollBar.state) 699#define scrollbar_isUpDn() isupper (R->scrollBar.state)
726#define isScrollbarWindow(w) (R->scrollBar.state && (w) == R->scrollBar.win) 700#define isScrollbarWindow(w) (R->scrollBar.state && (w) == R->scrollBar.win)
727
728#define scrollbar_setIdle() R->scrollBar.state = 1
729#define scrollbar_setMotion() R->scrollBar.state = 'm'
730#define scrollbar_setUp() R->scrollBar.state = 'U'
731#define scrollbar_setDn() R->scrollBar.state = 'D'
732 701
733#define scrollbarnext_dnval() (R->scrollBar.end + (R->scrollBar.width + 1)) 702#define scrollbarnext_dnval() (R->scrollBar.end + (R->scrollBar.width + 1))
734#define scrollbarnext_upButton(y) ((y) > R->scrollBar.end \ 703#define scrollbarnext_upButton(y) ((y) > R->scrollBar.end \
735 && (y) <= scrollbarnext_dnval()) 704 && (y) <= scrollbarnext_dnval())
736#define scrollbarnext_dnButton(y) ((y) > scrollbarnext_dnval()) 705#define scrollbarnext_dnButton(y) ((y) > scrollbarnext_dnval())
749#define scrollbar_size() (R->scrollBar.end - R->scrollBar.beg \ 718#define scrollbar_size() (R->scrollBar.end - R->scrollBar.beg \
750 - scrollbar_minheight()) 719 - scrollbar_minheight())
751 720
752#if (MENUBAR_MAX > 1) 721#if (MENUBAR_MAX > 1)
753/* rendition style flags */ 722/* rendition style flags */
754# define menuBar_height() (R->TermWin.fheight + SHADOW) 723# define menuBar_height() (TermWin.fheight + SHADOW)
755# define menuBar_TotalHeight() (menuBar_height() + SHADOW + menuBar_margin) 724# define menuBar_TotalHeight() (menuBar_height() + SHADOW + menuBar_margin)
756# define isMenuBarWindow(w) ((w) == R->menuBar.win) 725# define isMenuBarWindow(w) ((w) == R->menuBar.win)
757#else 726#else
758# define menuBar_height() (0) 727# define menuBar_height() (0)
759# define menuBar_TotalHeight() (0) 728# define menuBar_TotalHeight() (0)
768 737
769#ifndef STRICT_FONT_CHECKING 738#ifndef STRICT_FONT_CHECKING
770# define rxvt_get_fontwidest(font) ((font)->max_bounds.width) 739# define rxvt_get_fontwidest(font) ((font)->max_bounds.width)
771#endif 740#endif
772 741
773#define rxvt_Gr_ButtonPress(x,y) rxvt_Gr_ButtonReport (r, 'P',(x),(y)) 742#define rxvt_Gr_ButtonPress(x,y) rxvt_Gr_ButtonReport (R, 'P',(x),(y))
774#define rxvt_Gr_ButtonRelease(x,y) rxvt_Gr_ButtonReport (r, 'R',(x),(y)) 743#define rxvt_Gr_ButtonRelease(x,y) rxvt_Gr_ButtonReport (R, 'R',(x),(y))
775 744
776#ifdef UTMP_SUPPORT 745#ifdef UTMP_SUPPORT
777# if !defined(RXVT_UTMPX_FILE) || !defined(HAVE_STRUCT_UTMPX) 746# if !defined(RXVT_UTMPX_FILE) || !defined(HAVE_STRUCT_UTMPX)
778# undef HAVE_UTMPX_H 747# undef HAVE_UTMPX_H
779# undef HAVE_STRUCT_UTMPX 748# undef HAVE_STRUCT_UTMPX
837#endif 806#endif
838 807
839#define BLINK_INTERVAL 0.5 808#define BLINK_INTERVAL 0.5
840 809
841struct mbstate { 810struct mbstate {
842 unsigned char orig; 811 mbstate_t mbs;
843 uint32_t reg;
844 int cnt;
845 812
846 mbstate () 813 mbstate ()
847 { 814 {
848 cnt = 0; 815 MEMSET (&mbs, 0, sizeof (mbs));
849 } 816 }
850}; 817};
851 818
852struct rxvt_term : rxvt_vars { 819struct rxvt_term : rxvt_vars {
853 struct mbstate mbstate; 820 struct mbstate mbstate;
865 num_scr_allow:1, 832 num_scr_allow:1,
866 bypass_keystate:1, 833 bypass_keystate:1,
867#ifdef CURSOR_BLINK 834#ifdef CURSOR_BLINK
868 hidden_cursor:1, 835 hidden_cursor:1,
869#endif 836#endif
837#ifdef TEXT_BLINK
838 hidden_text:1,
839#endif
870#ifdef POINTER_BLANK 840#ifdef POINTER_BLANK
871 hidden_pointer:1, 841 hidden_pointer:1,
872#endif 842#endif
873 parsed_geometry:1, 843 parsed_geometry:1,
874 seen_input:1; /* wether any input has been seen so far */ 844 seen_input:1, /* wether any input has been seen so far */
845 enc_utf8:1; /* wether terminal reads/writes utf-8 */
875 846
876 unsigned char refresh_type, 847 unsigned char refresh_type,
877#ifdef UTMP_SUPPORT 848#ifdef UTMP_SUPPORT
878 next_utmp_action, 849 next_utmp_action,
879#endif 850#endif
890#ifdef GREEK_SUPPORT 861#ifdef GREEK_SUPPORT
891 short greek_mode; /* greek keyboard mode */ 862 short greek_mode; /* greek keyboard mode */
892#endif 863#endif
893 short rvideo; 864 short rvideo;
894 int16_t num_scr; /* screen: number lines scrolled */ 865 int16_t num_scr; /* screen: number lines scrolled */
895 uint16_t prev_ncol, /* screen: previous number of columns */ 866 unsigned int prev_ncol, /* screen: previous number of columns */
896 prev_nrow; /* screen: previous number of rows */ 867 prev_nrow; /* screen: previous number of rows */
897#ifdef RXVT_GRAPHICS 868#ifdef RXVT_GRAPHICS
898 uint16_t gr_prev_start; 869 uint16_t gr_prev_start;
899#endif 870#endif
900/* ---------- */ 871/* ---------- */
901 rend_t rstyle; 872 rend_t rstyle;
902/* ---------- */ 873/* ---------- */
903 uint32_t pixcolor_set[NPIXCLR_SETS]; 874 uint32_t pixcolor_set[NPIXCLR_SETS];
904/* ---------- */ 875/* ---------- */
905#ifdef SELECTION_SCROLLING 876#ifdef SELECTION_SCROLLING
906 int scroll_selection_delay, 877 int scroll_selection_delay,
907 scroll_selection_lines; 878 scroll_selection_lines;
908 enum page_dirn scroll_selection_dir; 879 enum page_dirn scroll_selection_dir;
953#endif 924#endif
954 ttymode; 925 ttymode;
955 unsigned long PrivateModes, 926 unsigned long PrivateModes,
956 SavedModes; 927 SavedModes;
957/* ---------- */ 928/* ---------- */
958#ifdef PREFER_24BIT
959 Visual *Xvisual;
960#endif
961/* ---------- */
962 Atom xa[NUM_XA]; 929 Atom xa[NUM_XA];
963/* ---------- */ 930/* ---------- */
964#ifdef MENUBAR 931#ifdef MENUBAR
965 GC menubarGC; 932 GC menubarGC;
966#endif 933#endif
1072 char *env_display; /* environmental variable DISPLAY */ 1039 char *env_display; /* environmental variable DISPLAY */
1073 char *env_term; /* environmental variable TERM */ 1040 char *env_term; /* environmental variable TERM */
1074 char *env_colorfgbg; 1041 char *env_colorfgbg;
1075 char *buffer; 1042 char *buffer;
1076 char *locale; 1043 char *locale;
1044 char *codeset;
1077 char charsets[4]; 1045 char charsets[4];
1078 unsigned char *v_buffer; /* pointer to physical buffer */ 1046 unsigned char *v_buffer; /* pointer to physical buffer */
1079 unsigned int v_buflen; /* size of area to write */ 1047 unsigned int v_buflen; /* size of area to write */
1080 char *newfont[MAX_NFONTS]; 1048 char *newfont[MAX_NFONTS];
1081#ifdef KEYSYM_RESOURCE 1049#ifdef KEYSYM_RESOURCE
1083#endif 1051#endif
1084 const char *rs[NUM_RESOURCES]; 1052 const char *rs[NUM_RESOURCES];
1085/* command input buffering */ 1053/* command input buffering */
1086 unsigned char *cmdbuf_ptr, *cmdbuf_endp; 1054 unsigned char *cmdbuf_ptr, *cmdbuf_endp;
1087 unsigned char cmdbuf_base[BUFSIZ]; 1055 unsigned char cmdbuf_base[BUFSIZ];
1088 unsigned char kbuf[KBUFSZ]; 1056
1057 rxvt_salloc *ralloc;
1058 rxvt_salloc *talloc;
1089 1059
1090 void paste (const unsigned char *data, unsigned int len); 1060 void paste (const unsigned char *data, unsigned int len);
1091 1061
1092 void flush (); 1062 void flush ();
1093 1063
1126 bool pty_fill (); 1096 bool pty_fill ();
1127 void process_x_events (); 1097 void process_x_events ();
1128 1098
1129 void *operator new (size_t s); 1099 void *operator new (size_t s);
1130 void operator delete (void *p, size_t s); 1100 void operator delete (void *p, size_t s);
1101
1102 void init_secondary ();
1103 const char **init_resources (int argc, const char *const *argv);
1104 void init_env ();
1105 void set_locale (const char *locale);
1106 void init_xlocale ();
1107 void init_command (const char *const *argv);
1108 int run_command (const char *const *argv);
1109 int run_child (const char *const *argv);
1110
1111 void color_aliases(int idx);
1112 void recolour_cursor ();
1113 void create_windows (int argc, const char *const *argv);
1114 void resize_all_windows (unsigned int width, unsigned int height, int ignoreparent);
1115 void window_calc (unsigned int width, unsigned int height);
1116 void set_preedit_area (XRectangle * preedit_rect, XRectangle * status_rect, XRectangle * needed_rect);
1117
1118#if USE_XIM
1119 void set_size (XRectangle *size);
1120 void set_position (XPoint *pos);
1121 void set_color (unsigned long *fg, unsigned long *bg);
1122#endif
1123
1124 void resize_scrollbar ();
1125
1126 void pixel_position (int *x, int *y);
1127
1128 void selection_click (int clicks, int x, int y);
1129 void selection_extend (int x, int y, int flag);
1130 void selection_rotate (int x, int y);
1131
1132 /* screen(!) */
1133 void scr_blank_line (text_t *et, rend_t *er, unsigned int width, rend_t efs);
1134 void scr_blank_screen_mem (text_t **tp, rend_t **rp, unsigned int row, rend_t efs);
1135 int scr_scroll_text (int row1, int row2, int count, int spec);
1136 void scr_reset ();
1137 void scr_reset_realloc ();
1138 void scr_release ();
1139 void scr_clear ();
1140 void scr_refresh (unsigned char refresh_type);
1141 void scr_erase_screen (int mode);
1142 void scr_touch (bool refresh);
1143 void scr_expose (int x, int y, int width, int height, bool refresh);
1131}; 1144};
1145
1146#define SET_LOCALE(locale) rxvt_set_locale (locale)
1147extern void rxvt_set_locale (const char *locale);
1132 1148
1133#ifndef __attribute__ 1149#ifndef __attribute__
1134# ifdef __GNUC__ 1150# ifdef __GNUC__
1135# if (__GNUC__ == 2 && __GNUC_MINOR__ < 5) || (__GNUC__ < 2) 1151# if (__GNUC__ == 2 && __GNUC_MINOR__ < 5) || (__GNUC__ < 2)
1136# define __attribute__(x) 1152# define __attribute__(x)

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines