[PATCH][weston] terminal: allow copy-paste when selection is scrolled out
Bryce Harrington
bryce at osg.samsung.com
Tue Sep 22 18:37:58 PDT 2015
On Wed, Sep 23, 2015 at 03:31:04AM +0200, Manuel Bachmann wrote:
> Hi Bryce, and thanks a lot for the review !
>
> Of course I have tested it :) ; the steps are the following :
> Copy some text in weston-terminal, scroll it out (by pressing [Enter]
> repeatedly e.g.), try to paste.
> It does work with the patch only.
Excellent, thanks for confirming. Patch landed and pushed:
remote: I: patch #59931 updated using rev e54cee17a717db2bee5225beaaaf28c288fc2c41
remote: I: 1 patch(es) updated to state Accepted.
To ssh://git.freedesktop.org/git/wayland/weston
a1f3f3c..e54cee1 master -> master
> 2015-09-23 2:10 GMT+02:00 Bryce Harrington <bryce at osg.samsung.com>:
>
> > On Sat, Sep 19, 2015 at 01:51:05PM +0200, Manuel Bachmann wrote:
> > > We could not paste text when its source went outside the
> > > visible part of the buffer ; this is because we were
> > > incorrectly assuming that our iterator should start at
> > > row 0, while it could very well be negative.
> > >
> > > Signed-off-by: Manuel Bachmann <manuel.bachmann at iot.bzh>
> >
> > Interesting find. I assume this patch has been tested to verify it
> > fixes the problem?
> >
> > Reviewed-by: Bryce Harrington <bryce at osg.samsung.com>
> >
> > > ---
> > > clients/terminal.c | 2 +-
> > > 1 file changed, 1 insertion(+), 1 deletion(-)
> > >
> > > diff --git a/clients/terminal.c b/clients/terminal.c
> > > index c5d5d60..7406f50 100644
> > > --- a/clients/terminal.c
> > > +++ b/clients/terminal.c
> > > @@ -942,7 +942,7 @@ terminal_send_selection(struct terminal *terminal,
> > int fd)
> > > close(fd);
> > > return;
> > > }
> > > - for (row = 0; row < terminal->height; row++) {
> > > + for (row = terminal->selection_start_row; row < terminal->height;
> > row++) {
> > > p_row = terminal_get_row(terminal, row);
> > > for (col = 0; col < terminal->width; col++) {
> > > if (p_row[col].ch == 0x200B) /* space glyph */
> > > --
> > > 1.8.3.1
> > >
> > > _______________________________________________
> > > wayland-devel mailing list
> > > wayland-devel at lists.freedesktop.org
> > > http://lists.freedesktop.org/mailman/listinfo/wayland-devel
> >
>
>
>
> --
> Regards,
>
> *Manuel Bachmann, Graphics Engineer www.iot.bzh <http://iot.bzh> *
More information about the wayland-devel
mailing list