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

Comparing rxvt-unicode/src/perl/searchable-scrollback (file contents):
Revision 1.2 by root, Mon Jan 9 23:00:07 2006 UTC vs.
Revision 1.3 by root, Mon Jan 9 23:03:13 2006 UTC

59} 59}
60 60
61sub idle { 61sub idle {
62 my ($self) = @_; 62 my ($self) = @_;
63 63
64 $self->msg ("scrollback search, escape=exit, enter=accept, /=start search, n=next, p=previous"); 64 $self->msg ("scrollback search, escape=exit, enter=accept, /=start search, n=next, p=previous, G=bottom");
65 65
66 delete $self->{in_search}; 66 delete $self->{in_search};
67} 67}
68 68
69sub search { 69sub search {
92 92
93 $row = $line->beg - 1; 93 $row = $line->beg - 1;
94 } 94 }
95 95
96 $self->msg ("enter/type/backspace: /$self->{search}_" 96 $self->msg ("enter/type/backspace: /$self->{search}_"
97 . ($self->{found} ? " (not found)" : "")); 97 . ($self->{found} ? "" : " (not found)"));
98 $self->scr_bell unless $self->{found}; 98 $self->scr_bell unless $self->{found};
99} 99}
100 100
101sub refresh { 101sub refresh {
102 my ($self) = @_; 102 my ($self) = @_;
139 } elsif ($keysym == 0xff54) { 139 } elsif ($keysym == 0xff54) {
140 $self->view_start ($self->view_start - 1); 140 $self->view_start ($self->view_start - 1);
141 } elsif ($string eq "/") { 141 } elsif ($string eq "/") {
142 $self->{in_search} = $self->view_start; 142 $self->{in_search} = $self->view_start;
143 $self->search; 143 $self->search;
144 } elsif ($string eq "G") {
145 $self->view_start (0);
144 } elsif ($string eq "n") { 146 } elsif ($string eq "n") {
145 $self->search; 147 $self->search;
146 } elsif ($string eq "p") { 148 } elsif ($string eq "p") {
149 # TODO
147 } elsif ($string ne "") { 150 } elsif ($string ne "") {
148 $self->scr_bell; 151 $self->scr_bell;
149 } 152 }
150 } 153 }
151 154

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines