… | |
… | |
84 | |
84 | |
85 | Displays a digital clock using the built-in overlay. |
85 | Displays a digital clock using the built-in overlay. |
86 | |
86 | |
87 | =item mark-urls |
87 | =item mark-urls |
88 | |
88 | |
89 | Uses per-line display filtering (C<on_line_update>) to underline urls. |
89 | Uses per-line display filtering (C<on_line_update>) to underline urls and |
|
|
90 | make them clickable. When middle-clicked, the program specified in the |
|
|
91 | resource C<urlLauncher> (default C<x-www-browser>) will be started. |
90 | |
92 | |
91 | =item block-graphics-to-ascii |
93 | =item block-graphics-to-ascii |
92 | |
94 | |
93 | A not very useful example of filtering all text output to the terminal, |
95 | A not very useful example of filtering all text output to the terminal, |
94 | by replacing all line-drawing characters (U+2500 .. U+259F) by a |
96 | by replacing all line-drawing characters (U+2500 .. U+259F) by a |
… | |
… | |
494 | $msg .= "\n" |
496 | $msg .= "\n" |
495 | unless $msg =~ /\n$/; |
497 | unless $msg =~ /\n$/; |
496 | urxvt::warn ($msg); |
498 | urxvt::warn ($msg); |
497 | }; |
499 | }; |
498 | |
500 | |
|
|
501 | # %ENV is the original startup environment |
499 | delete $ENV{IFS}; |
502 | delete $ENV{IFS}; |
500 | delete $ENV{CDPATH}; |
503 | delete $ENV{CDPATH}; |
501 | delete $ENV{BASH_ENV}; |
504 | delete $ENV{BASH_ENV}; |
502 | $ENV{PATH} = "/bin:/sbin:/usr/bin:/usr/sbin:/usr/local/bin:/usr/local/sbin:/opt/bin:/opt/sbin"; |
505 | $ENV{PATH} = "/bin:/sbin:/usr/bin:/usr/sbin:/usr/local/bin:/usr/local/sbin:/opt/bin:/opt/sbin"; |
503 | } |
506 | } |
… | |
… | |
610 | # clear package |
613 | # clear package |
611 | %$TERM = (); |
614 | %$TERM = (); |
612 | } |
615 | } |
613 | |
616 | |
614 | $retval |
617 | $retval |
|
|
618 | } |
|
|
619 | |
|
|
620 | sub exec_async(@) { |
|
|
621 | my $pid = fork; |
|
|
622 | |
|
|
623 | return |
|
|
624 | if !defined $pid or $pid; |
|
|
625 | |
|
|
626 | %ENV = %{ $TERM->env }; |
|
|
627 | |
|
|
628 | exec @_; |
|
|
629 | _exit 255; |
615 | } |
630 | } |
616 | |
631 | |
617 | # urxvt::term::extension |
632 | # urxvt::term::extension |
618 | |
633 | |
619 | package urxvt::term::extension; |
634 | package urxvt::term::extension; |
… | |
… | |
860 | my ($self, $name) = (shift, shift); |
875 | my ($self, $name) = (shift, shift); |
861 | unshift @_, $self, $name, ($name =~ s/\s*\+\s*(\d+)$// ? $1 : 0); |
876 | unshift @_, $self, $name, ($name =~ s/\s*\+\s*(\d+)$// ? $1 : 0); |
862 | &urxvt::term::_resource |
877 | &urxvt::term::_resource |
863 | } |
878 | } |
864 | |
879 | |
|
|
880 | =item $value = $term->x_resource ($pattern) |
|
|
881 | |
|
|
882 | Returns the X-Resource for the given pattern, excluding the program or |
|
|
883 | class name, i.e. C<< $term->x_resource ("boldFont") >> should return the |
|
|
884 | same value as used by this instance of rxvt-unicode. Returns C<undef> if no |
|
|
885 | resource with that pattern exists. |
|
|
886 | |
|
|
887 | This method should only be called during the C<on_start> hook, as there is |
|
|
888 | only one resource database per display, and later invocations might return |
|
|
889 | the wrong resources. |
|
|
890 | |
865 | =item $success = $term->parse_keysym ($keysym_spec, $command_string) |
891 | =item $success = $term->parse_keysym ($keysym_spec, $command_string) |
866 | |
892 | |
867 | Adds a keymap translation exactly as specified via a resource. See the |
893 | Adds a keymap translation exactly as specified via a resource. See the |
868 | C<keysym> resource in the @@RXVT_NAME@@(1) manpage. |
894 | C<keysym> resource in the @@RXVT_NAME@@(1) manpage. |
869 | |
895 | |