From: root Date: Mon, 2 Jan 2006 17:17:02 +0000 (+0000) Subject: *** empty log message *** X-Git-Url: http://git.openbox.org/?a=commitdiff_plain;h=e34d279139015b0dc391002fb0f73287a1081f3b;p=dana%2Furxvt.git *** empty log message *** --- diff --git a/MANIFEST b/MANIFEST index f3a6b1f6..25be7362 100644 --- a/MANIFEST +++ b/MANIFEST @@ -98,6 +98,7 @@ src/rxvtfont.C src/rxvtfont.h src/rxvt.C src/rxvt.h +src/rsinc.h src/rxvtc.C src/rxvtd.C src/rxvtdaemon.C diff --git a/doc/rxvtperl.3.html b/doc/rxvtperl.3.html index bb91b270..f23d159f 100644 --- a/doc/rxvtperl.3.html +++ b/doc/rxvtperl.3.html @@ -24,6 +24,12 @@
  • The urxvt::iow Class
  • +
  • ENVIRONMENT
  • + +
  • AUTHOR
  • @@ -205,6 +211,48 @@ Returns the ``current time'' (as per the event loop).

    The urxvt::term Class

    +
    $value = $term->resource ($name[, $newval])
    +
    +
    +Returns the current resource value associated with a given name and +optionally sets a new value. Setting values is most useful in the init +hook. Unset resources are returned and accepted as undef. +
    +
    +

    The new value must be properly encoded to a suitable character encoding +before passing it to this method. Similarly, the returned value may need +to be converted from the used encoding to text.

    +
    +
    +

    Resource names are as defined in src/rsinc.h. Colours can be specified +as resource names of the form color+<index>, e.g. color+5. (will +likely change).

    +
    +
    +

    Please note that resource strings will currently only be freed when the +terminal is destroyed, so changing options frequently will eat memory.

    +
    +
    +

    Here is a a likely non-exhaustive list of resource names, not all of which +are supported in every build, please see the source to see the actual +list:

    +
    +
    +
    +  answerbackstring backgroundPixmap backspace_key boldFont boldItalicFont
    +  borderLess color cursorBlink cursorUnderline cutchars delete_key
    +  display_name embed ext_bwidth fade font geometry hold iconName
    +  imFont imLocale inputMethod insecure int_bwidth intensityStyles
    +  italicFont jumpScroll lineSpace loginShell mapAlert menu meta8
    +  modifier mouseWheelScrollPage name pastableTabs path pointerBlank
    +  pointerBlankDelay preeditType print_pipe pty_fd reverseVideo saveLines
    +  scrollBar scrollBar_align scrollBar_floating scrollBar_right
    +  scrollBar_thickness scrollTtyKeypress scrollTtyOutput scrollWithBuffer
    +  scrollstyle secondaryScreen secondaryScroll selectstyle shade term_name
    +  title transparent transparent_all tripleclickwords utmpInhibit
    +  visualBell
    +
    +

    ($row, $col) = $term->selection_mark ([$row, $col])
    ($row, $col) = $term->selection_beg ([$row, $col])
    @@ -382,6 +430,23 @@ Stop watching for events on the given filehandle.


    +

    ENVIRONMENT

    +

    +

    +

    URXVT_PERL_VERBOSITY

    +

    This variable controls the verbosity level of the perl extension. Higher +numbers indicate more verbose output.

    +
      +
    1. - only fatal messages
      +
    2. +
    3. - script loading and management
      +
    4. +
    5. - all events received
      +
    6. +
    +

    +

    +

    AUTHOR

      Marc Lehmann <pcg@goof.com>
    diff --git a/doc/rxvtperl.3.man.in b/doc/rxvtperl.3.man.in
    index e607e055..df2fc6e9 100644
    --- a/doc/rxvtperl.3.man.in
    +++ b/doc/rxvtperl.3.man.in
    @@ -267,6 +267,42 @@ Returns the \*(L"current time\*(R" (as per the event loop).
     .ie n .Sh "The ""urxvt::term"" Class"
     .el .Sh "The \f(CWurxvt::term\fP Class"
     .IX Subsection "The urxvt::term Class"
    +.ie n .IP "$value = $term\fR\->resource ($name[, \f(CW$newval])" 4
    +.el .IP "$value = \f(CW$term\fR\->resource ($name[, \f(CW$newval\fR])" 4
    +.IX Item "$value = $term->resource ($name[, $newval])"
    +Returns the current resource value associated with a given name and
    +optionally sets a new value. Setting values is most useful in the \f(CW\*(C`init\*(C'\fR
    +hook. Unset resources are returned and accepted as \f(CW\*(C`undef\*(C'\fR.
    +.Sp
    +The new value must be properly encoded to a suitable character encoding
    +before passing it to this method. Similarly, the returned value may need
    +to be converted from the used encoding to text.
    +.Sp
    +Resource names are as defined in \fIsrc/rsinc.h\fR. Colours can be specified
    +as resource names of the form \f(CW\*(C`color+\*(C'\fR, e.g. \f(CW\*(C`color+5\*(C'\fR. (will
    +likely change).
    +.Sp
    +Please note that resource strings will currently only be freed when the
    +terminal is destroyed, so changing options frequently will eat memory.
    +.Sp
    +Here is a a likely non-exhaustive list of resource names, not all of which
    +are supported in every build, please see the source to see the actual
    +list:
    +.Sp
    +.Vb 12
    +\&  answerbackstring backgroundPixmap backspace_key boldFont boldItalicFont
    +\&  borderLess color cursorBlink cursorUnderline cutchars delete_key
    +\&  display_name embed ext_bwidth fade font geometry hold iconName
    +\&  imFont imLocale inputMethod insecure int_bwidth intensityStyles
    +\&  italicFont jumpScroll lineSpace loginShell mapAlert menu meta8
    +\&  modifier mouseWheelScrollPage name pastableTabs path pointerBlank
    +\&  pointerBlankDelay preeditType print_pipe pty_fd reverseVideo saveLines
    +\&  scrollBar scrollBar_align scrollBar_floating scrollBar_right
    +\&  scrollBar_thickness scrollTtyKeypress scrollTtyOutput scrollWithBuffer
    +\&  scrollstyle secondaryScreen secondaryScroll selectstyle shade term_name
    +\&  title transparent transparent_all tripleclickwords utmpInhibit
    +\&  visualBell
    +.Ve
     .ie n .IP "($row, $col\fR) = \f(CW$term\fR\->selection_mark ([$row, \f(CW$col])" 4
     .el .IP "($row, \f(CW$col\fR) = \f(CW$term\fR\->selection_mark ([$row, \f(CW$col\fR])" 4
     .IX Item "($row, $col) = $term->selection_mark ([$row, $col])"
    @@ -402,6 +438,20 @@ Start watching for requested events on the given handle.
     .el .IP "$iow = \f(CW$iow\fR\->stop" 4
     .IX Item "$iow = $iow->stop"
     Stop watching for events on the given filehandle.
    +.SH "ENVIRONMENT"
    +.IX Header "ENVIRONMENT"
    +.Sh "\s-1URXVT_PERL_VERBOSITY\s0"
    +.IX Subsection "URXVT_PERL_VERBOSITY"
    +This variable controls the verbosity level of the perl extension. Higher
    +numbers indicate more verbose output.
    +.IP "0 \- only fatal messages" 4
    +.IX Item "0 - only fatal messages"
    +.PD 0
    +.IP "3 \- script loading and management" 4
    +.IX Item "3 - script loading and management"
    +.IP "10 \- all events received" 4
    +.IX Item "10 - all events received"
    +.PD
     .SH "AUTHOR"
     .IX Header "AUTHOR"
     .Vb 2
    diff --git a/reconf b/reconf
    index fb5bed9f..a561e7ad 100755
    --- a/reconf
    +++ b/reconf
    @@ -10,6 +10,6 @@ if [ "x$HOSTNAME" = xcerebro -o "x$HOSTNAME" = xfuji ]; then
        export CC CXX
     fi
     
    -./configure --prefix=/opt/rxvt --with-name=rxvt \
    +./configure --prefix=/opt/rxvt --with-name=rxvt --enable-perl \
                 --enable-transparency --enable-menubar --enable-xpm-background --enable-xgetdefault \
                 "$@"
    diff --git a/src/Makefile.in b/src/Makefile.in
    index e404bb99..695c0168 100644
    --- a/src/Makefile.in
    +++ b/src/Makefile.in
    @@ -123,7 +123,8 @@ depend:
     
     command.o: ../config.h rxvt.h rxvtlib.h ptytty.h feature.h encoding.h
     command.o: rxvtfont.h rxvtutil.h rxvttoolkit.h iom.h iom_conf.h callback.h
    -command.o: salloc.h menubar.h rxvtperl.h version.h command.h keyboard.h
    +command.o: salloc.h rsinc.h menubar.h rxvtperl.h version.h command.h
    +command.o: keyboard.h
     encoding.o: ../config.h encoding.h table/iso8859_1.h table/iso8859_15.h
     encoding.o: table/iso8859_2.h table/iso8859_3.h table/iso8859_4.h
     encoding.o: table/iso8859_5.h table/iso8859_6.h table/iso8859_7.h
    @@ -141,82 +142,83 @@ encoding.o: table/jis0212_1990_0.h table/jis0213_1.h table/jis0213_2.h
     encoding.o: table/compose.h table/category.h
     fdpass.o: ../config.h fdpass.h
     init.o: ../config.h rxvt.h rxvtlib.h ptytty.h feature.h encoding.h rxvtfont.h
    -init.o: rxvtutil.h rxvttoolkit.h iom.h iom_conf.h callback.h salloc.h
    +init.o: rxvtutil.h rxvttoolkit.h iom.h iom_conf.h callback.h salloc.h rsinc.h
     init.o: menubar.h init.h
     iom.o: iom.h iom_conf.h rxvtutil.h callback.h
     keyboard.o: ../config.h rxvt.h rxvtlib.h ptytty.h feature.h encoding.h
     keyboard.o: rxvtfont.h rxvtutil.h rxvttoolkit.h iom.h iom_conf.h callback.h
    -keyboard.o: salloc.h menubar.h keyboard.h command.h
    +keyboard.o: salloc.h rsinc.h menubar.h keyboard.h command.h
     logging.o: ../config.h rxvt.h rxvtlib.h ptytty.h feature.h encoding.h
     logging.o: rxvtfont.h rxvtutil.h rxvttoolkit.h iom.h iom_conf.h callback.h
    -logging.o: salloc.h menubar.h logging.h
    +logging.o: salloc.h rsinc.h menubar.h logging.h
     main.o: ../config.h rxvt.h rxvtlib.h ptytty.h feature.h encoding.h rxvtfont.h
    -main.o: rxvtutil.h rxvttoolkit.h iom.h iom_conf.h callback.h salloc.h
    +main.o: rxvtutil.h rxvttoolkit.h iom.h iom_conf.h callback.h salloc.h rsinc.h
     main.o: menubar.h keyboard.h rxvtperl.h
     menubar.o: ../config.h rxvt.h rxvtlib.h ptytty.h feature.h encoding.h
     menubar.o: rxvtfont.h rxvtutil.h rxvttoolkit.h iom.h iom_conf.h callback.h
    -menubar.o: salloc.h menubar.h version.h
    +menubar.o: salloc.h rsinc.h menubar.h version.h
     misc.o: ../config.h rxvt.h rxvtlib.h ptytty.h feature.h encoding.h rxvtfont.h
    -misc.o: rxvtutil.h rxvttoolkit.h iom.h iom_conf.h callback.h salloc.h
    +misc.o: rxvtutil.h rxvttoolkit.h iom.h iom_conf.h callback.h salloc.h rsinc.h
     misc.o: menubar.h
     netdisp.o: ../config.h rxvt.h rxvtlib.h ptytty.h feature.h encoding.h
     netdisp.o: rxvtfont.h rxvtutil.h rxvttoolkit.h iom.h iom_conf.h callback.h
    -netdisp.o: salloc.h menubar.h
    +netdisp.o: salloc.h rsinc.h menubar.h
     ptytty.o: ../config.h rxvt.h rxvtlib.h ptytty.h feature.h encoding.h
     ptytty.o: rxvtfont.h rxvtutil.h rxvttoolkit.h iom.h iom_conf.h callback.h
    -ptytty.o: salloc.h menubar.h
    +ptytty.o: salloc.h rsinc.h menubar.h
     rxvt.o: ../config.h rxvt.h rxvtlib.h ptytty.h feature.h encoding.h rxvtfont.h
    -rxvt.o: rxvtutil.h rxvttoolkit.h iom.h iom_conf.h callback.h salloc.h
    +rxvt.o: rxvtutil.h rxvttoolkit.h iom.h iom_conf.h callback.h salloc.h rsinc.h
     rxvt.o: menubar.h
     rxvtc.o: ../config.h rxvtdaemon.h rxvtutil.h fdpass.h rxvt.h rxvtlib.h
     rxvtc.o: ptytty.h feature.h encoding.h rxvtfont.h rxvttoolkit.h iom.h
    -rxvtc.o: iom_conf.h callback.h salloc.h menubar.h
    +rxvtc.o: iom_conf.h callback.h salloc.h rsinc.h menubar.h
     rxvtd.o: ../config.h rxvt.h rxvtlib.h ptytty.h feature.h encoding.h
     rxvtd.o: rxvtfont.h rxvtutil.h rxvttoolkit.h iom.h iom_conf.h callback.h
    -rxvtd.o: salloc.h menubar.h rxvtdaemon.h fdpass.h
    +rxvtd.o: salloc.h rsinc.h menubar.h rxvtdaemon.h fdpass.h
     rxvtdaemon.o: rxvtdaemon.h rxvtutil.h
     rxvtfont.o: ../config.h rxvt.h rxvtlib.h ptytty.h feature.h encoding.h
     rxvtfont.o: rxvtfont.h rxvtutil.h rxvttoolkit.h iom.h iom_conf.h callback.h
    -rxvtfont.o: salloc.h menubar.h table/linedraw.h
    +rxvtfont.o: salloc.h rsinc.h menubar.h table/linedraw.h
     rxvtperl.o: ../config.h rxvt.h rxvtlib.h ptytty.h feature.h encoding.h
     rxvtperl.o: rxvtfont.h rxvtutil.h rxvttoolkit.h iom.h iom_conf.h callback.h
    -rxvtperl.o: salloc.h menubar.h rxvtperl.h perlxsi.c
    +rxvtperl.o: salloc.h rsinc.h menubar.h rxvtperl.h perlxsi.c
     rxvttoolkit.o: ../config.h rxvt.h rxvtlib.h ptytty.h feature.h encoding.h
     rxvttoolkit.o: rxvtfont.h rxvtutil.h rxvttoolkit.h iom.h iom_conf.h
    -rxvttoolkit.o: callback.h salloc.h menubar.h
    +rxvttoolkit.o: callback.h salloc.h rsinc.h menubar.h
     rxvtutil.o: rxvtutil.h
     salloc.o: salloc.h
     screen.o: ../config.h rxvt.h rxvtlib.h ptytty.h feature.h encoding.h
     screen.o: rxvtfont.h rxvtutil.h rxvttoolkit.h iom.h iom_conf.h callback.h
    -screen.o: salloc.h menubar.h rxvtperl.h salloc.C
    +screen.o: salloc.h rsinc.h menubar.h rxvtperl.h salloc.C
     scrollbar-next.o: ../config.h rxvt.h rxvtlib.h ptytty.h feature.h encoding.h
     scrollbar-next.o: rxvtfont.h rxvtutil.h rxvttoolkit.h iom.h iom_conf.h
    -scrollbar-next.o: callback.h salloc.h menubar.h
    +scrollbar-next.o: callback.h salloc.h rsinc.h menubar.h
     scrollbar-plain.o: ../config.h rxvt.h rxvtlib.h ptytty.h feature.h encoding.h
     scrollbar-plain.o: rxvtfont.h rxvtutil.h rxvttoolkit.h iom.h iom_conf.h
    -scrollbar-plain.o: callback.h salloc.h menubar.h
    +scrollbar-plain.o: callback.h salloc.h rsinc.h menubar.h
     scrollbar-rxvt.o: ../config.h rxvt.h rxvtlib.h ptytty.h feature.h encoding.h
     scrollbar-rxvt.o: rxvtfont.h rxvtutil.h rxvttoolkit.h iom.h iom_conf.h
    -scrollbar-rxvt.o: callback.h salloc.h menubar.h
    +scrollbar-rxvt.o: callback.h salloc.h rsinc.h menubar.h
     scrollbar-xterm.o: ../config.h rxvt.h rxvtlib.h ptytty.h feature.h encoding.h
     scrollbar-xterm.o: rxvtfont.h rxvtutil.h rxvttoolkit.h iom.h iom_conf.h
    -scrollbar-xterm.o: callback.h salloc.h menubar.h
    +scrollbar-xterm.o: callback.h salloc.h rsinc.h menubar.h
     scrollbar.o: ../config.h rxvt.h rxvtlib.h ptytty.h feature.h encoding.h
     scrollbar.o: rxvtfont.h rxvtutil.h rxvttoolkit.h iom.h iom_conf.h callback.h
    -scrollbar.o: salloc.h menubar.h
    +scrollbar.o: salloc.h rsinc.h menubar.h
     strings.o: ../config.h rxvt.h rxvtlib.h ptytty.h feature.h encoding.h
     strings.o: rxvtfont.h rxvtutil.h rxvttoolkit.h iom.h iom_conf.h callback.h
    -strings.o: salloc.h menubar.h
    +strings.o: salloc.h rsinc.h menubar.h
     xdefaults.o: ../config.h rxvt.h rxvtlib.h ptytty.h feature.h encoding.h
     xdefaults.o: rxvtfont.h rxvtutil.h rxvttoolkit.h iom.h iom_conf.h callback.h
    -xdefaults.o: salloc.h menubar.h version.h keyboard.h
    +xdefaults.o: salloc.h rsinc.h menubar.h version.h keyboard.h
     xpm.o: ../config.h rxvt.h rxvtlib.h ptytty.h feature.h encoding.h rxvtfont.h
    -xpm.o: rxvtutil.h rxvttoolkit.h iom.h iom_conf.h callback.h salloc.h
    +xpm.o: rxvtutil.h rxvttoolkit.h iom.h iom_conf.h callback.h salloc.h rsinc.h
     xpm.o: menubar.h
     
     command.lo: ../config.h rxvt.h rxvtlib.h ptytty.h feature.h encoding.h
     command.lo: rxvtfont.h rxvtutil.h rxvttoolkit.h iom.h iom_conf.h callback.h
    -command.lo: salloc.h menubar.h rxvtperl.h version.h command.h keyboard.h
    +command.lo: salloc.h rsinc.h menubar.h rxvtperl.h version.h command.h
    +command.lo: keyboard.h
     encoding.lo: ../config.h encoding.h table/iso8859_1.h table/iso8859_15.h
     encoding.lo: table/iso8859_2.h table/iso8859_3.h table/iso8859_4.h
     encoding.lo: table/iso8859_5.h table/iso8859_6.h table/iso8859_7.h
    @@ -235,74 +237,74 @@ encoding.lo: table/compose.h table/category.h
     fdpass.lo: ../config.h fdpass.h
     init.lo: ../config.h rxvt.h rxvtlib.h ptytty.h feature.h encoding.h
     init.lo: rxvtfont.h rxvtutil.h rxvttoolkit.h iom.h iom_conf.h callback.h
    -init.lo: salloc.h menubar.h init.h
    +init.lo: salloc.h rsinc.h menubar.h init.h
     iom.lo: iom.h iom_conf.h rxvtutil.h callback.h
     keyboard.lo: ../config.h rxvt.h rxvtlib.h ptytty.h feature.h encoding.h
     keyboard.lo: rxvtfont.h rxvtutil.h rxvttoolkit.h iom.h iom_conf.h callback.h
    -keyboard.lo: salloc.h menubar.h keyboard.h command.h
    +keyboard.lo: salloc.h rsinc.h menubar.h keyboard.h command.h
     logging.lo: ../config.h rxvt.h rxvtlib.h ptytty.h feature.h encoding.h
     logging.lo: rxvtfont.h rxvtutil.h rxvttoolkit.h iom.h iom_conf.h callback.h
    -logging.lo: salloc.h menubar.h logging.h
    +logging.lo: salloc.h rsinc.h menubar.h logging.h
     main.lo: ../config.h rxvt.h rxvtlib.h ptytty.h feature.h encoding.h
     main.lo: rxvtfont.h rxvtutil.h rxvttoolkit.h iom.h iom_conf.h callback.h
    -main.lo: salloc.h menubar.h keyboard.h rxvtperl.h
    +main.lo: salloc.h rsinc.h menubar.h keyboard.h rxvtperl.h
     menubar.lo: ../config.h rxvt.h rxvtlib.h ptytty.h feature.h encoding.h
     menubar.lo: rxvtfont.h rxvtutil.h rxvttoolkit.h iom.h iom_conf.h callback.h
    -menubar.lo: salloc.h menubar.h version.h
    +menubar.lo: salloc.h rsinc.h menubar.h version.h
     misc.lo: ../config.h rxvt.h rxvtlib.h ptytty.h feature.h encoding.h
     misc.lo: rxvtfont.h rxvtutil.h rxvttoolkit.h iom.h iom_conf.h callback.h
    -misc.lo: salloc.h menubar.h
    +misc.lo: salloc.h rsinc.h menubar.h
     netdisp.lo: ../config.h rxvt.h rxvtlib.h ptytty.h feature.h encoding.h
     netdisp.lo: rxvtfont.h rxvtutil.h rxvttoolkit.h iom.h iom_conf.h callback.h
    -netdisp.lo: salloc.h menubar.h
    +netdisp.lo: salloc.h rsinc.h menubar.h
     ptytty.lo: ../config.h rxvt.h rxvtlib.h ptytty.h feature.h encoding.h
     ptytty.lo: rxvtfont.h rxvtutil.h rxvttoolkit.h iom.h iom_conf.h callback.h
    -ptytty.lo: salloc.h menubar.h
    +ptytty.lo: salloc.h rsinc.h menubar.h
     rxvt.lo: ../config.h rxvt.h rxvtlib.h ptytty.h feature.h encoding.h
     rxvt.lo: rxvtfont.h rxvtutil.h rxvttoolkit.h iom.h iom_conf.h callback.h
    -rxvt.lo: salloc.h menubar.h
    +rxvt.lo: salloc.h rsinc.h menubar.h
     rxvtc.lo: ../config.h rxvtdaemon.h rxvtutil.h fdpass.h rxvt.h rxvtlib.h
     rxvtc.lo: ptytty.h feature.h encoding.h rxvtfont.h rxvttoolkit.h iom.h
    -rxvtc.lo: iom_conf.h callback.h salloc.h menubar.h
    +rxvtc.lo: iom_conf.h callback.h salloc.h rsinc.h menubar.h
     rxvtd.lo: ../config.h rxvt.h rxvtlib.h ptytty.h feature.h encoding.h
     rxvtd.lo: rxvtfont.h rxvtutil.h rxvttoolkit.h iom.h iom_conf.h callback.h
    -rxvtd.lo: salloc.h menubar.h rxvtdaemon.h fdpass.h
    +rxvtd.lo: salloc.h rsinc.h menubar.h rxvtdaemon.h fdpass.h
     rxvtdaemon.lo: rxvtdaemon.h rxvtutil.h
     rxvtfont.lo: ../config.h rxvt.h rxvtlib.h ptytty.h feature.h encoding.h
     rxvtfont.lo: rxvtfont.h rxvtutil.h rxvttoolkit.h iom.h iom_conf.h callback.h
    -rxvtfont.lo: salloc.h menubar.h table/linedraw.h
    +rxvtfont.lo: salloc.h rsinc.h menubar.h table/linedraw.h
     rxvtperl.lo: ../config.h rxvt.h rxvtlib.h ptytty.h feature.h encoding.h
     rxvtperl.lo: rxvtfont.h rxvtutil.h rxvttoolkit.h iom.h iom_conf.h callback.h
    -rxvtperl.lo: salloc.h menubar.h rxvtperl.h perlxsi.c
    +rxvtperl.lo: salloc.h rsinc.h menubar.h rxvtperl.h perlxsi.c
     rxvttoolkit.lo: ../config.h rxvt.h rxvtlib.h ptytty.h feature.h encoding.h
     rxvttoolkit.lo: rxvtfont.h rxvtutil.h rxvttoolkit.h iom.h iom_conf.h
    -rxvttoolkit.lo: callback.h salloc.h menubar.h
    +rxvttoolkit.lo: callback.h salloc.h rsinc.h menubar.h
     rxvtutil.lo: rxvtutil.h
     salloc.lo: salloc.h
     screen.lo: ../config.h rxvt.h rxvtlib.h ptytty.h feature.h encoding.h
     screen.lo: rxvtfont.h rxvtutil.h rxvttoolkit.h iom.h iom_conf.h callback.h
    -screen.lo: salloc.h menubar.h rxvtperl.h salloc.C
    +screen.lo: salloc.h rsinc.h menubar.h rxvtperl.h salloc.C
     scrollbar-next.lo: ../config.h rxvt.h rxvtlib.h ptytty.h feature.h encoding.h
     scrollbar-next.lo: rxvtfont.h rxvtutil.h rxvttoolkit.h iom.h iom_conf.h
    -scrollbar-next.lo: callback.h salloc.h menubar.h
    +scrollbar-next.lo: callback.h salloc.h rsinc.h menubar.h
     scrollbar-plain.lo: ../config.h rxvt.h rxvtlib.h ptytty.h feature.h
     scrollbar-plain.lo: encoding.h rxvtfont.h rxvtutil.h rxvttoolkit.h iom.h
    -scrollbar-plain.lo: iom_conf.h callback.h salloc.h menubar.h
    +scrollbar-plain.lo: iom_conf.h callback.h salloc.h rsinc.h menubar.h
     scrollbar-rxvt.lo: ../config.h rxvt.h rxvtlib.h ptytty.h feature.h encoding.h
     scrollbar-rxvt.lo: rxvtfont.h rxvtutil.h rxvttoolkit.h iom.h iom_conf.h
    -scrollbar-rxvt.lo: callback.h salloc.h menubar.h
    +scrollbar-rxvt.lo: callback.h salloc.h rsinc.h menubar.h
     scrollbar-xterm.lo: ../config.h rxvt.h rxvtlib.h ptytty.h feature.h
     scrollbar-xterm.lo: encoding.h rxvtfont.h rxvtutil.h rxvttoolkit.h iom.h
    -scrollbar-xterm.lo: iom_conf.h callback.h salloc.h menubar.h
    +scrollbar-xterm.lo: iom_conf.h callback.h salloc.h rsinc.h menubar.h
     scrollbar.lo: ../config.h rxvt.h rxvtlib.h ptytty.h feature.h encoding.h
     scrollbar.lo: rxvtfont.h rxvtutil.h rxvttoolkit.h iom.h iom_conf.h callback.h
    -scrollbar.lo: salloc.h menubar.h
    +scrollbar.lo: salloc.h rsinc.h menubar.h
     strings.lo: ../config.h rxvt.h rxvtlib.h ptytty.h feature.h encoding.h
     strings.lo: rxvtfont.h rxvtutil.h rxvttoolkit.h iom.h iom_conf.h callback.h
    -strings.lo: salloc.h menubar.h
    +strings.lo: salloc.h rsinc.h menubar.h
     xdefaults.lo: ../config.h rxvt.h rxvtlib.h ptytty.h feature.h encoding.h
     xdefaults.lo: rxvtfont.h rxvtutil.h rxvttoolkit.h iom.h iom_conf.h callback.h
    -xdefaults.lo: salloc.h menubar.h version.h keyboard.h
    +xdefaults.lo: salloc.h rsinc.h menubar.h version.h keyboard.h
     xpm.lo: ../config.h rxvt.h rxvtlib.h ptytty.h feature.h encoding.h rxvtfont.h
    -xpm.lo: rxvtutil.h rxvttoolkit.h iom.h iom_conf.h callback.h salloc.h
    +xpm.lo: rxvtutil.h rxvttoolkit.h iom.h iom_conf.h callback.h salloc.h rsinc.h
     xpm.lo: menubar.h
    diff --git a/src/rsinc.h b/src/rsinc.h
    new file mode 100644
    index 00000000..b66b36bc
    --- /dev/null
    +++ b/src/rsinc.h
    @@ -0,0 +1,105 @@
    +// all resource indices, used by rxvt.h anf rxvtperl.xs
    +
    +  Rs_def(display_name)
    +  Rs_def(term_name)
    +  Rs_def(iconName)
    +  Rs_def(geometry)
    +  Rs_def(reverseVideo)
    +  Rs_def(color)
    +  Rs_reserve(color, NRS_COLORS)
    +  Rs_def(font)
    +#if ENABLE_STYLES
    +  Rs_def(boldFont)
    +  Rs_def(italicFont)
    +  Rs_def(boldItalicFont)
    +  Rs_def(intensityStyles)
    +#endif
    +  Rs_def(name)
    +  Rs_def(title)
    +#if defined (XPM_BACKGROUND) || (MENUBAR_MAX)
    +  Rs_def(path)
    +#endif
    +#ifdef XPM_BACKGROUND
    +  Rs_def(backgroundPixmap)
    +#endif
    +#if (MENUBAR_MAX)
    +  Rs_def(menu)
    +#endif
    +  Rs_def(loginShell)
    +  Rs_def(jumpScroll)
    +#ifdef HAVE_SCROLLBARS
    +  Rs_def(scrollBar)
    +  Rs_def(scrollBar_right)
    +  Rs_def(scrollBar_floating)
    +  Rs_def(scrollBar_align)
    +  Rs_def(scrollstyle)
    +  Rs_def(scrollBar_thickness)
    +#endif
    +  Rs_def(scrollTtyOutput)
    +  Rs_def(scrollTtyKeypress)
    +  Rs_def(scrollWithBuffer)
    +  Rs_def(saveLines)
    +  Rs_def(utmpInhibit)
    +  Rs_def(visualBell)
    +#if ! defined(NO_MAPALERT) && defined(MAPALERT_OPTION)
    +  Rs_def(mapAlert)
    +#endif
    +#ifdef META8_OPTION
    +  Rs_def(meta8)
    +#endif
    +#ifdef MOUSE_WHEEL
    +  Rs_def(mouseWheelScrollPage)
    +#endif
    +#ifndef NO_BACKSPACE_KEY
    +  Rs_def(backspace_key)
    +#endif
    +#ifndef NO_DELETE_KEY
    +  Rs_def(delete_key)
    +#endif
    +  Rs_def(selectstyle)
    +#ifdef PRINTPIPE
    +  Rs_def(print_pipe)
    +#endif
    +#ifdef USE_XIM
    +  Rs_def(preeditType)
    +  Rs_def(inputMethod)
    +#endif
    +#ifdef TRANSPARENT
    +  Rs_def(transparent)
    +  Rs_def(transparent_all)
    +#endif
    +#if ENABLE_FRILLS
    +  Rs_def(pty_fd)
    +  Rs_def(hold)
    +  Rs_def(ext_bwidth)
    +  Rs_def(int_bwidth)
    +  Rs_def(borderLess)
    +  Rs_def(lineSpace)
    +  Rs_def(cursorUnderline)
    +#endif
    +#if CURSOR_BLINK
    +  Rs_def(cursorBlink)
    +#endif
    +#if ENABLE_XEMBED
    +  Rs_def(embed)
    +#endif
    +  Rs_def(cutchars)
    +  Rs_def(modifier)
    +  Rs_def(answerbackstring)
    +  Rs_def(tripleclickwords)
    +  Rs_def(insecure)
    +  Rs_def(pointerBlank)
    +  Rs_def(pointerBlankDelay)
    +  Rs_def(imLocale)
    +  Rs_def(imFont)
    +  Rs_def(pastableTabs)
    +#ifndef NO_SECONDARY_SCREEN
    +  Rs_def(secondaryScreen)
    +  Rs_def(secondaryScroll)
    +#endif
    +#ifdef OFF_FOCUS_FADING
    +  Rs_def(fade)
    +#endif
    +#ifdef TINTING
    +  Rs_def(shade)
    +#endif
    diff --git a/src/rxvt.h b/src/rxvt.h
    index 6610d48f..9f91482f 100644
    --- a/src/rxvt.h
    +++ b/src/rxvt.h
    @@ -557,109 +557,11 @@ enum colour_list {
      * Resource list
      */
     enum {
    -  Rs_display_name = 0,
    -  Rs_term_name,
    -  Rs_iconName,
    -  Rs_geometry,
    -  Rs_reverseVideo,
    -  Rs_color,
    -  _Rs_color = Rs_color + NRS_COLORS - 1,
    -  Rs_font,
    -#if ENABLE_STYLES
    -  Rs_boldFont,
    -  Rs_italicFont,
    -  Rs_boldItalicFont,
    -  Rs_intensityStyles,
    -#endif
    -  Rs_name,
    -  Rs_title,
    -#if defined (XPM_BACKGROUND) || (MENUBAR_MAX)
    -  Rs_path,
    -#endif
    -#ifdef XPM_BACKGROUND
    -  Rs_backgroundPixmap,
    -#endif
    -#if (MENUBAR_MAX)
    -  Rs_menu,
    -#endif
    -  Rs_loginShell,
    -  Rs_jumpScroll,
    -#ifdef HAVE_SCROLLBARS
    -  Rs_scrollBar,
    -  Rs_scrollBar_right,
    -  Rs_scrollBar_floating,
    -  Rs_scrollBar_align,
    -  Rs_scrollstyle,     /* Rs_scrollBar_style */
    -  Rs_scrollBar_thickness,
    -#endif
    -  Rs_scrollTtyOutput,
    -  Rs_scrollTtyKeypress,
    -  Rs_scrollWithBuffer,
    -  Rs_saveLines,
    -  Rs_utmpInhibit,
    -  Rs_visualBell,
    -#if ! defined(NO_MAPALERT) && defined(MAPALERT_OPTION)
    -  Rs_mapAlert,
    -#endif
    -#ifdef META8_OPTION
    -  Rs_meta8,
    -#endif
    -#ifdef MOUSE_WHEEL
    -  Rs_mouseWheelScrollPage,
    -#endif
    -#ifndef NO_BACKSPACE_KEY
    -  Rs_backspace_key,
    -#endif
    -#ifndef NO_DELETE_KEY
    -  Rs_delete_key,
    -#endif
    -  Rs_selectstyle,
    -#ifdef PRINTPIPE
    -  Rs_print_pipe,
    -#endif
    -#ifdef USE_XIM
    -  Rs_preeditType,
    -  Rs_inputMethod,
    -#endif
    -#ifdef TRANSPARENT
    -  Rs_transparent,
    -  Rs_transparent_all,
    -#endif
    -#if ENABLE_FRILLS
    -  Rs_pty_fd,
    -  Rs_hold,
    -  Rs_ext_bwidth,
    -  Rs_int_bwidth,
    -  Rs_borderLess,
    -  Rs_lineSpace,
    -  Rs_cursorUnderline,
    -#endif
    -#if CURSOR_BLINK
    -  Rs_cursorBlink,
    -#endif
    -#if ENABLE_XEMBED
    -  Rs_embed,
    -#endif
    -  Rs_cutchars,
    -  Rs_modifier,
    -  Rs_answerbackstring,
    -  Rs_tripleclickwords,
    -  Rs_insecure,
    -  Rs_pointerBlank,
    -  Rs_pointerBlankDelay,
    -  Rs_imLocale,
    -  Rs_imFont,
    -  Rs_pastableTabs,
    -#ifndef NO_SECONDARY_SCREEN
    -  Rs_secondaryScreen,
    -  Rs_secondaryScroll,
    -#endif
    -#ifdef OFF_FOCUS_FADING
    -  Rs_fade,
    -#endif
    -#ifdef TINTING
    -  Rs_shade,
    -#endif
    +#define Rs_def(name) Rs_ ## name,
    +#define Rs_reserve(name,count) Rs_ ## name ## _ = Rs_ ## name + (count) - 1,
    +#include "rsinc.h"
    +#undef Rs_def
    +#undef Rs_reserve
       NUM_RESOURCES
     };
     
    diff --git a/src/rxvtperl.xs b/src/rxvtperl.xs
    index 8ebd0790..23945bd5 100644
    --- a/src/rxvtperl.xs
    +++ b/src/rxvtperl.xs
    @@ -346,6 +346,46 @@ NOW ()
     
     MODULE = urxvt             PACKAGE = urxvt::term
     
    +void
    +rxvt_term::_resource (char *name, int index, SV *newval = 0)
    +	PPCODE:
    +{
    +	struct resval { const char *name; int value; } rslist [] = {
    +#	  define Rs_def(name) { # name, Rs_ ## name },
    +#	  define Rs_reserve(name,count)
    +#	  include "rsinc.h"
    +#	  undef Rs_def
    +#	  undef Rs_reserve
    +        };
    +
    +        struct resval *rs = rslist + sizeof (rslist) / sizeof (rslist [0]);
    +
    +        do {
    +          if (rs-- == rslist)
    +            croak ("no such resource '%s', requested", name);
    +        } while (strcmp (name, rs->name));
    +
    +        index += rs->value;
    +
    +        if (!IN_RANGE_EXC (index, 0, NUM_RESOURCES))
    +          croak ("requested out-of-bound resource %s+%d,", name, index - rs->value);
    +
    +        if (GIMME_V != G_VOID)
    +          XPUSHs (THIS->rs [index] ? sv_2mortal (newSVpv (THIS->rs [index], 0)) : &PL_sv_undef);
    +
    +        if (newval)
    +          {
    +            if (SvOK (newval))
    +              {
    +                char *str = strdup (SvPVbyte_nolen (newval));
    +                THIS->rs [index] = str;
    +                THIS->allocated.push_back (str);
    +              }
    +            else
    +              THIS->rs [index] = 0;
    +          }
    +}
    +
     void
     rxvt_term::selection_mark (...)
     	PROTOTYPE: $;$$
    diff --git a/src/urxvt.pm b/src/urxvt.pm
    index 3eb2c441..5f20d721 100644
    --- a/src/urxvt.pm
    +++ b/src/urxvt.pm
    @@ -252,6 +252,23 @@ likely change).
     Please note that resource strings will currently only be freed when the
     terminal is destroyed, so changing options frequently will eat memory.
     
    +Here is a a likely non-exhaustive list of resource names, not all of which
    +are supported in every build, please see the source to see the actual
    +list:
    +
    +  answerbackstring backgroundPixmap backspace_key boldFont boldItalicFont
    +  borderLess color cursorBlink cursorUnderline cutchars delete_key
    +  display_name embed ext_bwidth fade font geometry hold iconName
    +  imFont imLocale inputMethod insecure int_bwidth intensityStyles
    +  italicFont jumpScroll lineSpace loginShell mapAlert menu meta8
    +  modifier mouseWheelScrollPage name pastableTabs path pointerBlank
    +  pointerBlankDelay preeditType print_pipe pty_fd reverseVideo saveLines
    +  scrollBar scrollBar_align scrollBar_floating scrollBar_right
    +  scrollBar_thickness scrollTtyKeypress scrollTtyOutput scrollWithBuffer
    +  scrollstyle secondaryScreen secondaryScroll selectstyle shade term_name
    +  title transparent transparent_all tripleclickwords utmpInhibit
    +  visualBell
    +
     =cut
     
     sub urxvt::term::resource($$;$) {