unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
From: Peter <pmc@citylink.dinoex.sub.org>
To: Yuri Khan <yuri.v.khan@gmail.com>
Cc: help-gnu-emacs@gnu.org
Subject: Re: How to set background-color without damaging cut&paste ?
Date: Wed, 4 Sep 2024 15:51:15 +0200	[thread overview]
Message-ID: <Zthl0_l7d5zI4f2R@disp.intra.daemon.contact> (raw)
In-Reply-To: <CAP_d_8VNSfE-Ltd6x7_jF4FU1gUF9kMqLQsmZb=KPv+QzZDT6w@mail.gmail.com>

On Wed, Sep 04, 2024 at 07:41:02PM +0700, Yuri Khan wrote:
! On Wed, 4 Sept 2024 at 06:37, Peter <pmc@citylink.dinoex.sub.org> wrote:
! 
! > However, after setting the background-color, the result is this:
! >
! > 00000000  46 69 72 73 74 20 4c 69  6e 65 20 20 20 20 20 20  |First Line      |
! > 00000010  20 20 20 20 20 20 20 20  20 20 20 20 20 20 20 20  |                |
! > 00000020  20 20 20 20 20 20 20 20  20 20 20 20 20 20 20 20  |                |
! > 00000030  20 20 20 20 20 20 20 20  20 20 20 20 20 20 20 20  |                |
! > 00000040  20 20 20 20 20 20 20 20  20 20 20 20 20 20 20 20  |                |
! 
! You’re getting the default mouse selection handling by your terminal
! emulator, which is not guaranteed to be correct for full-screen
! applications.

This sounds strange - why should the default mouse selection handling
be dependent on the individual text color?

The issue does not only happen with background-color. It does also
happen when using 'conf-mode' (and probably others with syntax
highlighting). In that case it depends on the actual color of the
text: some lines are filled with trailing spaces, some are not.

! Example: if you enable ‘toggle-truncate-lines’ and have several
! adjacent lines that are too wide for the terminal window, the terminal
! emulator will highlight and copy only the displayed parts of the
! lines.

This is known and accepted; overly long lines need manual treatment
with copy/paste. But dangling spaces on correctly formatted lines,
i.e. after a terminating backslash denoting a line continuation,
result in really bad malfunctions and are not easily detected.

! Consider enabling xterm-mouse-mode.

I tried this already. Sadly, either I don't understand it or it does
not work at all.
The usecase here is that I have dozens of nodes in different parts
of the world. All of them can be opened in xterms. So opening them
side by side, one can easily compare config files and copy/paste
snippets from one to another.



  reply	other threads:[~2024-09-04 13:51 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-09-03 23:28 How to set background-color without damaging cut&paste ? Peter
2024-09-04 11:40 ` Eli Zaretskii
2024-09-04 12:41 ` Yuri Khan
2024-09-04 13:51   ` Peter [this message]
2024-09-04 14:33   ` Peter
2024-09-04 14:43     ` Eli Zaretskii
2024-09-09 13:24 ` Stefan Monnier via Users list for the GNU Emacs text editor

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=Zthl0_l7d5zI4f2R@disp.intra.daemon.contact \
    --to=pmc@citylink.dinoex.sub.org \
    --cc=help-gnu-emacs@gnu.org \
    --cc=yuri.v.khan@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).