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

Comparing rxvt-unicode/src/urxvt.pm (file contents):
Revision 1.236 by root, Sat May 17 17:12:29 2014 UTC vs.
Revision 1.240 by sf-exg, Fri Oct 10 14:32:32 2014 UTC

675 @TERM_EXT = (); 675 @TERM_EXT = ();
676 $TERM->register_package ($_) for @pkg; 676 $TERM->register_package ($_) for @pkg;
677 } 677 }
678 678
679 for ( 679 for (
680 @{ delete $TERM->{perl_ext_3} },
681 grep $_, map { split /,/, $TERM->resource ("perl_ext_$_") } 1, 2 680 grep $_, map { split /,/, $TERM->resource ("perl_ext_$_") } 1, 2
682 ) { 681 ) {
683 if ($_ eq "default") { 682 if ($_ eq "default") {
684 683
685 $ext_arg{$_} ||= [] 684 $ext_arg{$_} = []
686 for 685 for
687 qw(selection option-popup selection-popup readline), 686 qw(selection option-popup selection-popup readline),
687 @{ delete $TERM->{perl_ext_3} },
688 map $_->[0], values %{ $TERM->{meta}{binding} }; 688 map $_->[0], values %{ $TERM->{meta}{binding} };
689
690 for ($TERM->_keysym_resources) {
691 next if /^(?:string|command|builtin|builtin-string|perl)/;
692 next unless /^([A-Za-z0-9_\-]+):/;
693
694 my $ext = $1;
695
696 $ext_arg{$ext} = [];
697 }
689 698
690 } elsif (/^-(.*)$/) { 699 } elsif (/^-(.*)$/) {
691 delete $ext_arg{$1}; 700 delete $ext_arg{$1};
692 701
693 } elsif (/^([^<]+)<(.*)>$/) { 702 } elsif (/^([^<]+)<(.*)>$/) {
697 $ext_arg{$_} ||= []; 706 $ext_arg{$_} ||= [];
698 } 707 }
699 } 708 }
700 709
701 # now register default key bindings 710 # now register default key bindings
711 for my $ext (sort keys %ext_arg) {
702 while (my ($k, $v) = each %{ $TERM->{meta}{binding} }) { 712 while (my ($k, $v) = each %{ $TERM->{meta}{ext}{$ext}{binding} }) {
703 $TERM->bind_action ($k, "$v->[0]:$v->[1]"); 713 $TERM->bind_action ($k, "$v->[0]:$v->[1]");
714 }
704 } 715 }
705 716
706 for my $ext (sort keys %ext_arg) { 717 for my $ext (sort keys %ext_arg) {
707 my @files = grep -f $_, map "$_/$ext", @dirs; 718 my @files = grep -f $_, map "$_/$ext", @dirs;
708 719
1487to the locale-specific encoding using C<< $term->locale_encode >>. 1498to the locale-specific encoding using C<< $term->locale_encode >>.
1488 1499
1489=item $term->tt_write_user_input ($octets) 1500=item $term->tt_write_user_input ($octets)
1490 1501
1491Like C<tt_write>, but should be used when writing strings in response to 1502Like C<tt_write>, but should be used when writing strings in response to
1492the user pressing a key, to invokes the additional actions requested by 1503the user pressing a key, to invoke the additional actions requested by
1493the user for that case (C<tt_write> doesn't do that). 1504the user for that case (C<tt_write> doesn't do that).
1494 1505
1495The typical use case would be inside C<on_action> hooks. 1506The typical use case would be inside C<on_action> hooks.
1496 1507
1497=item $term->tt_paste ($octets) 1508=item $term->tt_paste ($octets)

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines