Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 4 Aug 2022 17:33:05 +0300
From:      Toomas Soome <tsoome@me.com>
To:        Ivan Quitschal <tezeka@hotmail.com>
Cc:        Hans Petter Selasky <hps@selasky.org>, "freebsd-current@freebsd.org" <freebsd-current@freebsd.org>
Subject:   Re: RES: vt newcons 3 clicks mouse paste issue FIXED
Message-ID:  <B366100D-6FA7-40F4-8BCA-335F07A43422@me.com>
In-Reply-To: <CP6P284MB190086D2AD26A14E0C5DA002CB9F9@CP6P284MB1900.BRAP284.PROD.OUTLOOK.COM>
References:  <CP6P284MB1900CA1ED5B5BADE054ECB34CBB29@CP6P284MB1900.BRAP284.PROD.OUTLOOK.COM> <f6c1ee1c-bdd9-c8d6-1385-145022e6765d@selasky.org> <CP6P284MB1900CC7B7F6343DAB1D1E5BCCBB29@CP6P284MB1900.BRAP284.PROD.OUTLOOK.COM> <41ef5c38-515f-739a-cb47-7cab0e609526@selasky.org> <CP6P284MB1900DD3D6F41CBAF38CF2CA4CBB29@CP6P284MB1900.BRAP284.PROD.OUTLOOK.COM> <20220623014847.067b18a5ba388639cf6009ce@dec.sakura.ne.jp> <fd0f9de9-98ac-87b4-2c9d-5fdc27bdb3c4@selasky.org> <CP6P284MB1900DD45138428B4612DF7ACCB9D9@CP6P284MB1900.BRAP284.PROD.OUTLOOK.COM> <CP6P284MB190086D2AD26A14E0C5DA002CB9F9@CP6P284MB1900.BRAP284.PROD.OUTLOOK.COM>

next in thread | previous in thread | raw e-mail | index | archive | help

--Apple-Mail=_45F67029-A3A2-41BC-9F27-53F8BB6CE4C3
Content-Transfer-Encoding: quoted-printable
Content-Type: text/plain;
	charset=utf-8



> On 4. Aug 2022, at 17:04, Ivan Quitschal <tezeka@hotmail.com> wrote:
>=20
> Hi Hans
>=20
> D36042 created
> How can I include more patch files in the same defect number? D36042
> https://reviews.freebsd.org/D36042
>=20
> Its missing the vt.h.diff and vt_core.diff
> Both attached
>=20
> Should i have put all three in the raw patch creation combo box when I =
was creating the defect?
> Sorry my dumbness  , never used that phabricator=20
>=20
> --tzk

You may want to check =E2=80=98git arc=E2=80=99 =
(https://freebsdfoundation.org/wp-content/uploads/2021/11/FreeBSD-Code-Rev=
iew-with-git-arc.pdf =
<https://freebsdfoundation.org/wp-content/uploads/2021/11/FreeBSD-Code-Rev=
iew-with-git-arc.pdf>)

rgds,
toomas

>=20
>=20
>=20
>=20
>=20
>> -----Mensagem original-----
>> De: Ivan Quitschal <tezeka@hotmail.com>
>> Enviada em: ter=C3=A7a-feira, 2 de agosto de 2022 09:34
>> Para: Hans Petter Selasky <hps@selasky.org>
>> Cc: Tomoaki AOKI <junchoon@dec.sakura.ne.jp>; Ivan Quitschal
>> <tezeka@hotmail.com>; freebsd-current@freebsd.org; Kurt Jaeger
>> <pi@freebsd.org>
>> Assunto: vt newcons 3 clicks mouse paste issue FIXED
>>=20
>>=20
>> Hi guys
>>=20
>> Currently , if you click 3 times in order to select the entire row, =
its just not
>> working as it should.
>> i fixed that please find below and attached the patches
>>=20
>> With this change now we can do a 3 clicks and paste , i dont know, in =
some
>> command, and it will be executed just fine, like it was in syscons, =
and still is in
>> xterm/ linux etc
>>=20
>> now if the event is a 3 mouse clickss select, the space trim is made =
on the right
>> and an <enter> is included
>>=20
>> thanks
>>=20
>> --tzk
>>=20
>>=20
>> --------------------
>> --- sys/dev/vt/vt_buf.c.orig    2022-08-02 08:44:27.229782000 -0300
>> +++ sys/dev/vt/vt_buf.c 2022-08-02 08:45:02.703697000 -0300
>> @@ -771,7 +771,7 @@
>>  }
>>=20
>>  void
>> -vtbuf_extract_marked(struct vt_buf *vb, term_char_t *buf, int sz)
>> +vtbuf_extract_marked(struct vt_buf *vb, term_char_t *buf, int sz, =
int
>> +mark)
>>  {
>>         int i, j, r, c, cs, ce;
>>         term_pos_t s, e;
>> @@ -799,7 +799,7 @@
>>                         buf[i++] =3D vb->vb_rows[r][c];
>>=20
>>                 /* For all rows, but the last one. */
>> -               if (r !=3D e.tp_row) {
>> +               if (r !=3D e.tp_row || mark =3D=3D VTB_MARK_ROW) {
>>                         /* Trim trailing word separators, if any. */
>>                         for (; i !=3D j; i--) {
>>                                 if (!tchar_is_word_separator(buf[i - =
1]))
>> --------------------
>>=20
>> --- sys/dev/vt/vt_core.c.orig   2022-08-02 08:43:15.436415000 -0300
>> +++ sys/dev/vt/vt_core.c        2022-08-02 08:43:49.120096000 -0300
>> @@ -2287,7 +2287,7 @@
>>                         VD_PASTEBUFSZ(vd) =3D len;
>>                 }
>>                 /* Request copy/paste buffer data, no more than `len' =
*/
>> -               vtbuf_extract_marked(&vw->vw_buf, VD_PASTEBUF(vd), =
len);
>> +               vtbuf_extract_marked(&vw->vw_buf, VD_PASTEBUF(vd), =
len,
>> + mark);
>>=20
>>                 VD_PASTEBUFLEN(vd) =3D len;
>>=20
>> ---------------------
>>=20
>> --- sys/dev/vt/vt.h.orig        2022-08-02 08:41:23.888584000 -0300
>> +++ sys/dev/vt/vt.h     2022-08-02 08:41:54.504309000 -0300
>> @@ -238,7 +238,7 @@
>>  #ifndef SC_NO_CUTPASTE
>>  int vtbuf_set_mark(struct vt_buf *vb, int type, int col, int row);
>>  int vtbuf_get_marked_len(struct vt_buf *vb); -void
>> vtbuf_extract_marked(struct vt_buf *vb, term_char_t *buf, int sz);
>> +void vtbuf_extract_marked(struct vt_buf *vb, term_char_t *buf, int =
sz,
>> +int
>> mark);
>>  #endif
>>=20
>>  #define        VTB_MARK_NONE           0
>> --------------------------
> <vt.h.diff><vt_core.diff>


--Apple-Mail=_45F67029-A3A2-41BC-9F27-53F8BB6CE4C3
Content-Transfer-Encoding: quoted-printable
Content-Type: text/html;
	charset=utf-8

<html><head><meta http-equiv=3D"Content-Type" content=3D"text/html; =
charset=3Dutf-8"></head><body style=3D"word-wrap: break-word; =
-webkit-nbsp-mode: space; line-break: after-white-space;" class=3D""><br =
class=3D""><div><br class=3D""><blockquote type=3D"cite" class=3D""><div =
class=3D"">On 4. Aug 2022, at 17:04, Ivan Quitschal &lt;<a =
href=3D"mailto:tezeka@hotmail.com" class=3D"">tezeka@hotmail.com</a>&gt; =
wrote:</div><br class=3D"Apple-interchange-newline"><div class=3D""><div =
class=3D"">Hi Hans<br class=3D""><br class=3D"">D36042 created<br =
class=3D"">How can I include more patch files in the same defect number? =
D36042<br class=3D""><a href=3D"https://reviews.freebsd.org/D36042" =
class=3D"">https://reviews.freebsd.org/D36042</a><br class=3D""><br =
class=3D"">Its missing the vt.h.diff and vt_core.diff<br class=3D"">Both =
attached<br class=3D""><br class=3D"">Should i have put all three in the =
raw patch creation combo box when I was creating the defect?<br =
class=3D"">Sorry my dumbness &nbsp;, never used that phabricator <br =
class=3D""><br class=3D"">--tzk<br =
class=3D""></div></div></blockquote><div><br class=3D""></div><div>You =
may want to check =E2=80=98git arc=E2=80=99 (<a =
href=3D"https://freebsdfoundation.org/wp-content/uploads/2021/11/FreeBSD-C=
ode-Review-with-git-arc.pdf" =
class=3D"">https://freebsdfoundation.org/wp-content/uploads/2021/11/FreeBS=
D-Code-Review-with-git-arc.pdf</a>)</div><div><br =
class=3D""></div><div>rgds,</div><div>toomas</div><br =
class=3D""><blockquote type=3D"cite" class=3D""><div class=3D""><div =
class=3D""><br class=3D""><br class=3D""><br class=3D""><br class=3D""><br=
 class=3D""><blockquote type=3D"cite" class=3D"">-----Mensagem =
original-----<br class=3D"">De: Ivan Quitschal &lt;<a =
href=3D"mailto:tezeka@hotmail.com" =
class=3D"">tezeka@hotmail.com</a>&gt;<br class=3D"">Enviada em: =
ter=C3=A7a-feira, 2 de agosto de 2022 09:34<br class=3D"">Para: Hans =
Petter Selasky &lt;<a href=3D"mailto:hps@selasky.org" =
class=3D"">hps@selasky.org</a>&gt;<br class=3D"">Cc: Tomoaki AOKI &lt;<a =
href=3D"mailto:junchoon@dec.sakura.ne.jp" =
class=3D"">junchoon@dec.sakura.ne.jp</a>&gt;; Ivan Quitschal<br =
class=3D"">&lt;<a href=3D"mailto:tezeka@hotmail.com" =
class=3D"">tezeka@hotmail.com</a>&gt;; <a =
href=3D"mailto:freebsd-current@freebsd.org" =
class=3D"">freebsd-current@freebsd.org</a>; Kurt Jaeger<br =
class=3D"">&lt;<a href=3D"mailto:pi@freebsd.org" =
class=3D"">pi@freebsd.org</a>&gt;<br class=3D"">Assunto: vt newcons 3 =
clicks mouse paste issue FIXED<br class=3D""><br class=3D""><br =
class=3D"">Hi guys<br class=3D""><br class=3D"">Currently , if you click =
3 times in order to select the entire row, its just not<br =
class=3D"">working as it should.<br class=3D"">i fixed that please find =
below and attached the patches<br class=3D""><br class=3D"">With this =
change now we can do a 3 clicks and paste , i dont know, in some<br =
class=3D"">command, and it will be executed just fine, like it was in =
syscons, and still is in<br class=3D"">xterm/ linux etc<br class=3D""><br =
class=3D"">now if the event is a 3 mouse clickss select, the space trim =
is made on the right<br class=3D"">and an &lt;enter&gt; is included<br =
class=3D""><br class=3D"">thanks<br class=3D""><br class=3D"">--tzk<br =
class=3D""><br class=3D""><br class=3D"">--------------------<br =
class=3D"">--- sys/dev/vt/vt_buf.c.orig &nbsp;&nbsp;&nbsp;2022-08-02 =
08:44:27.229782000 -0300<br class=3D"">+++ sys/dev/vt/vt_buf.c =
2022-08-02 08:45:02.703697000 -0300<br class=3D"">@@ -771,7 +771,7 @@<br =
class=3D""> &nbsp;}<br class=3D""><br class=3D""> &nbsp;void<br =
class=3D"">-vtbuf_extract_marked(struct vt_buf *vb, term_char_t *buf, =
int sz)<br class=3D"">+vtbuf_extract_marked(struct vt_buf *vb, =
term_char_t *buf, int sz, int<br class=3D"">+mark)<br class=3D""> =
&nbsp;{<br class=3D""> =
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;int i, j, r, c, cs, =
ce;<br class=3D""> =
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;term_pos_t s, e;<br =
class=3D"">@@ -799,7 +799,7 @@<br class=3D""> =
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&n=
bsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;buf[=
i++] =3D vb-&gt;vb_rows[r][c];<br class=3D""><br class=3D""> =
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&n=
bsp;&nbsp;&nbsp;&nbsp;/* For all rows, but the last one. */<br =
class=3D"">- =
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&n=
bsp;&nbsp;if (r !=3D e.tp_row) {<br class=3D"">+ =
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&n=
bsp;&nbsp;if (r !=3D e.tp_row || mark =3D=3D VTB_MARK_ROW) {<br =
class=3D""> =
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&n=
bsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;/* =
Trim trailing word separators, if any. */<br class=3D""> =
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&n=
bsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;for =
(; i !=3D j; i--) {<br class=3D""> =
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&n=
bsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbs=
p;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;if =
(!tchar_is_word_separator(buf[i - 1]))<br =
class=3D"">--------------------<br class=3D""><br class=3D"">--- =
sys/dev/vt/vt_core.c.orig &nbsp;&nbsp;2022-08-02 08:43:15.436415000 =
-0300<br class=3D"">+++ sys/dev/vt/vt_core.c =
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;2022-08-02 08:43:49.120096000 =
-0300<br class=3D"">@@ -2287,7 +2287,7 @@<br class=3D""> =
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&n=
bsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;VD_P=
ASTEBUFSZ(vd) =3D len;<br class=3D""> =
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&n=
bsp;&nbsp;&nbsp;&nbsp;}<br class=3D""> =
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&n=
bsp;&nbsp;&nbsp;&nbsp;/* Request copy/paste buffer data, no more than =
`len' */<br class=3D"">- =
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&n=
bsp;&nbsp;vtbuf_extract_marked(&amp;vw-&gt;vw_buf, VD_PASTEBUF(vd), =
len);<br class=3D"">+ =
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&n=
bsp;&nbsp;vtbuf_extract_marked(&amp;vw-&gt;vw_buf, VD_PASTEBUF(vd), =
len,<br class=3D"">+ mark);<br class=3D""><br class=3D""> =
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&n=
bsp;&nbsp;&nbsp;&nbsp;VD_PASTEBUFLEN(vd) =3D len;<br class=3D""><br =
class=3D"">---------------------<br class=3D""><br class=3D"">--- =
sys/dev/vt/vt.h.orig =
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;2022-08-02 08:41:23.888584000 =
-0300<br class=3D"">+++ sys/dev/vt/vt.h =
&nbsp;&nbsp;&nbsp;&nbsp;2022-08-02 08:41:54.504309000 -0300<br =
class=3D"">@@ -238,7 +238,7 @@<br class=3D""> &nbsp;#ifndef =
SC_NO_CUTPASTE<br class=3D""> &nbsp;int vtbuf_set_mark(struct vt_buf =
*vb, int type, int col, int row);<br class=3D""> &nbsp;int =
vtbuf_get_marked_len(struct vt_buf *vb); -void<br =
class=3D"">vtbuf_extract_marked(struct vt_buf *vb, term_char_t *buf, int =
sz);<br class=3D"">+void vtbuf_extract_marked(struct vt_buf *vb, =
term_char_t *buf, int sz,<br class=3D"">+int<br class=3D"">mark);<br =
class=3D""> &nbsp;#endif<br class=3D""><br class=3D""> &nbsp;#define =
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;VTB_MARK_NONE =
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;0<br =
class=3D"">--------------------------<br class=3D""></blockquote><span =
id=3D"cid:BE185786-4184-47E3-8FBD-3555117B6711">&lt;vt.h.diff&gt;</span><s=
pan =
id=3D"cid:DE0214D2-DD61-4736-8FE7-A278B3A583C3">&lt;vt_core.diff&gt;</span=
></div></div></blockquote></div><br class=3D""></body></html>=

--Apple-Mail=_45F67029-A3A2-41BC-9F27-53F8BB6CE4C3--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?B366100D-6FA7-40F4-8BCA-335F07A43422>