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

Comparing rxvt-unicode/src/xdefaults.C (file contents):
Revision 1.194 by root, Tue Sep 17 20:38:53 2019 UTC vs.
Revision 1.200 by root, Fri Dec 23 21:46:46 2022 UTC

134#endif 134#endif
135#ifdef MOUSE_WHEEL 135#ifdef MOUSE_WHEEL
136 BOOL (Rs_mouseWheelScrollPage, "mouseWheelScrollPage", NULL, Opt_mouseWheelScrollPage, 0, NULL), 136 BOOL (Rs_mouseWheelScrollPage, "mouseWheelScrollPage", NULL, Opt_mouseWheelScrollPage, 0, NULL),
137#endif 137#endif
138#if ENABLE_FRILLS 138#if ENABLE_FRILLS
139 BOOL (Rs_disablePasteBrackets, "disablePasteBrackets", "dpb", Opt_disablePasteBrackets, 0, "paste bracket suppression"),
139 BOOL (Rs_tripleclickwords, "tripleclickwords", "tcw", Opt_tripleclickwords, 0, "triple click word selection"), 140 BOOL (Rs_tripleclickwords, "tripleclickwords", "tcw", Opt_tripleclickwords, 0, "triple click word selection"),
140 BOOL (Rs_insecure, "insecure", "insecure", Opt_insecure, 0, "enable possibly insecure escape sequences"), 141 BOOL (Rs_insecure, "insecure", "insecure", Opt_insecure, 0, "enable possibly insecure escape sequences"),
141 BOOL (Rs_cursorUnderline, "cursorUnderline", "uc", Opt_cursorUnderline, 0, "underline cursor"), 142 BOOL (Rs_cursorUnderline, "cursorUnderline", "uc", Opt_cursorUnderline, 0, "underline cursor"),
142#endif 143#endif
143#if CURSOR_BLINK 144#if CURSOR_BLINK
219#endif 220#endif
220#if XFT 221#if XFT
221 BOOL (Rs_buffered, "buffered", NULL, Opt_buffered, 0, NULL), 222 BOOL (Rs_buffered, "buffered", NULL, Opt_buffered, 0, NULL),
222#endif 223#endif
223#if ENABLE_FRILLS 224#if ENABLE_FRILLS
225 STRG (Rs_refreshRate, "refreshRate", "fps", "number", "refresh rate / frames per second"),
224 STRG (Rs_depth, "depth", "depth", "number", "depth of visual to request"), 226 STRG (Rs_depth, "depth", "depth", "number", "depth of visual to request"),
225 STRG (Rs_visual, "visual", "visual", "number", "visual id to request"), 227 STRG (Rs_visual, "visual", "visual", "number", "visual id to request"),
226 RSTRG (Rs_transient_for, "transient-for", "windowid"), 228 RSTRG (Rs_transient_for, "transient-for", "windowid"),
227 BOOL (Rs_override_redirect, "override-redirect", "override-redirect", Opt_override_redirect, 0, "set override-redirect on the terminal window"), 229 BOOL (Rs_override_redirect, "override-redirect", "override-redirect", Opt_override_redirect, 0, "override-redirect on the terminal window"),
228 STRG (Rs_pty_fd, NULL, "pty-fd", "fileno", "file descriptor of pty to use"), 230 STRG (Rs_pty_fd, NULL, "pty-fd", "fileno", "file descriptor of pty to use"),
229 BOOL (Rs_hold, "hold", "hold", Opt_hold, 0, "retain window after shell exit"), 231 BOOL (Rs_hold, "hold", "hold", Opt_hold, 0, "retain window after shell exit"),
230 STRG (Rs_ext_bwidth, "externalBorder", "w", "number", "external border in pixels"), 232 STRG (Rs_ext_bwidth, "externalBorder", "w", "number", "external border in pixels"),
231 STRG (Rs_ext_bwidth, NULL, "bw", NULL, NULL), 233 STRG (Rs_ext_bwidth, NULL, "bw", NULL, NULL),
232 STRG (Rs_ext_bwidth, NULL, "borderwidth", NULL, NULL), 234 STRG (Rs_ext_bwidth, NULL, "borderwidth", NULL, NULL),
234 BOOL (Rs_borderLess, "borderLess", "bl", Opt_borderLess, 0, "borderless window"), 236 BOOL (Rs_borderLess, "borderLess", "bl", Opt_borderLess, 0, "borderless window"),
235 STRG (Rs_lineSpace, "lineSpace", "lsp", "number", "number of extra pixels between rows"), 237 STRG (Rs_lineSpace, "lineSpace", "lsp", "number", "number of extra pixels between rows"),
236 STRG (Rs_letterSpace, "letterSpace", "letsp", "number", "letter spacing adjustment"), 238 STRG (Rs_letterSpace, "letterSpace", "letsp", "number", "letter spacing adjustment"),
237#endif 239#endif
238#ifdef BUILTIN_GLYPHS 240#ifdef BUILTIN_GLYPHS
239 BOOL (Rs_skipBuiltinGlyphs, "skipBuiltinGlyphs", "sbg", Opt_skipBuiltinGlyphs, 0, "do not use internal glyphs"), 241 BOOL (Rs_skipBuiltinGlyphs, "skipBuiltinGlyphs", "sbg", Opt_skipBuiltinGlyphs, 0, "use of font glyphs instead of internal glyphs"),
240#endif 242#endif
241#ifdef POINTER_BLANK 243#ifdef POINTER_BLANK
242 RSTRG (Rs_pointerBlankDelay, "pointerBlankDelay", "number"), 244 RSTRG (Rs_pointerBlankDelay, "pointerBlankDelay", "number"),
243#endif 245#endif
244#ifndef NO_BACKSPACE_KEY 246#ifndef NO_BACKSPACE_KEY
252#endif 254#endif
253 STRG (Rs_modifier, "modifier", "mod", "modifier", "meta modifier = alt|meta|hyper|super|mod1|...|mod5"), 255 STRG (Rs_modifier, "modifier", "mod", "modifier", "meta modifier = alt|meta|hyper|super|mod1|...|mod5"),
254 RSTRG (Rs_cutchars, "cutchars", "string"), 256 RSTRG (Rs_cutchars, "cutchars", "string"),
255 RSTRG (Rs_answerbackstring, "answerbackString", "string"), 257 RSTRG (Rs_answerbackstring, "answerbackString", "string"),
256#ifndef NO_SECONDARY_SCREEN 258#ifndef NO_SECONDARY_SCREEN
257 BOOL (Rs_secondaryScreen, "secondaryScreen", "ssc", Opt_secondaryScreen, 0, "enable secondary screen"), 259 BOOL (Rs_secondaryScreen, "secondaryScreen", "ssc", Opt_secondaryScreen, 0, "secondary screen"),
258 BOOL (Rs_secondaryScroll, "secondaryScroll", "ssr", Opt_secondaryScroll, 0, "enable secondary screen scroll"), 260 BOOL (Rs_secondaryScroll, "secondaryScroll", "ssr", Opt_secondaryScroll, 0, "secondary screen scroll"),
261#endif
262#if ENABLE_FRILLS
263 STRG (Rs_rewrapMode, "rewrapMode", "rm", "string", "rewrap mode (auto, always, never)"),
259#endif 264#endif
260#if ENABLE_PERL 265#if ENABLE_PERL
261 RSTRG (Rs_perl_lib, "perl-lib", "string"), //, "colon-separated directories with extension scripts"),TODO 266 RSTRG (Rs_perl_lib, "perl-lib", "string"), //, "colon-separated directories with extension scripts"),TODO
262 RSTRG (Rs_perl_eval, "perl-eval", "perl-eval"), // "string", "code to be evaluated after all extensions have been loaded"),TODO 267 RSTRG (Rs_perl_eval, "perl-eval", "perl-eval"), // "string", "code to be evaluated after all extensions have been loaded"),TODO
263 RSTRG (Rs_perl_ext_1, "perl-ext-common", "string"), //, "colon-separated list of perl extensions to enable"),TODO 268 RSTRG (Rs_perl_ext_1, "perl-ext-common", "string"), //, "colon-separated list of perl extensions to enable"),TODO
843{ 848{
844 const rxvt_enumerate_closure *data = (const rxvt_enumerate_closure *)closure; 849 const rxvt_enumerate_closure *data = (const rxvt_enumerate_closure *)closure;
845 850
846 if (*quarks == NULLQUARK) return False; 851 if (*quarks == NULLQUARK) return False;
847 852
848 // if the quark list starts with a tighly bound quark, we skip it, 853 // if the quark list starts with a tightly bound quark, we skip it,
849 // as it is the exactly matched the prefix. Otherwise, it matched because 854 // as it exactly matched the prefix. Otherwise, it matched because
850 // it started with "*", in which case we assuime the prefix is part 855 // it started with "*", in which case we assume the prefix is part
851 // of the "*". 856 // of the "*".
852 if (*bindings == XrmBindTightly) 857 if (*bindings == XrmBindTightly)
853 { 858 {
854 ++quarks, ++bindings; // skip if this is a fixed prefix, rather than a *-match 859 ++quarks, ++bindings; // skip if this is a fixed prefix, rather than a *-match
855 if (*quarks == NULLQUARK) return False; 860 if (*quarks == NULLQUARK) return False;
860 // component, as well as all generic prefixes 865 // component, as well as all generic prefixes
861 // this is a bit of a hack, ideally, keysym (the only user) should use its 866 // this is a bit of a hack, ideally, keysym (the only user) should use its
862 // own iteration function, but this ought to be less bloated 867 // own iteration function, but this ought to be less bloated
863 if (data->specific) 868 if (data->specific)
864 { 869 {
865 if (*bindings != XrmBindTightly) 870 ++quarks, ++bindings;
866 return False;
867
868 ++quarks, ++bindings; // skip if this is a fixed prefix, rather than a *-match
869 if (*quarks == NULLQUARK) return False; 871 if (*quarks == NULLQUARK) return False;
870 } 872 }
871 873
872 char *pattern; 874 char *pattern;
873 if (quarks[1] == NULLQUARK) 875 if (quarks[1] == NULLQUARK)
874 pattern = XrmQuarkToString (quarks[0]); // single component, fats path 876 pattern = XrmQuarkToString (quarks[0]); // single component, fast path
875 else 877 else
876 { 878 {
877 // multiple components, slow path - should be rare, to don't optimize for speed 879 // multiple components, slow path - should be rare, don't optimize for speed
878 int size = 0; 880 int size = 0;
879 881
880 for (int i = 0; quarks[i] != NULLQUARK; ++i) 882 for (int i = 0; quarks[i] != NULLQUARK; ++i)
881 size += strlen (XrmQuarkToString (quarks[i])) + 1; 883 size += strlen (XrmQuarkToString (quarks[i])) + 1;
882 884

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines