emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* org-copy-visible does not work with x-select-enable-primary
@ 2018-09-02 13:37 Alain.Cochard
  2018-09-02 19:25 ` Nicolas Goaziou
  0 siblings, 1 reply; 4+ messages in thread
From: Alain.Cochard @ 2018-09-02 13:37 UTC (permalink / raw)
  To: emacs-orgmode


Hello.


I use

   emacs -Q -l ~/.emacs.debug

with the ~/.emacs.debug file containing only

   (add-to-list 'load-path "/home/cochard/Org/Coch-git/org-mode/lisp")

I tried 2 versions of emacs, giving:

   Emacs : GNU Emacs 24.5.1 (x86_64-redhat-linux-gnu, GTK+ Version
   3.18.9) of 2016-04-11 on buildvm-25.phx2.fedoraproject.org Package:
   Org mode version 9.1.14 (release_9.1.14-908-gf1269e @
   /home/cochard/Org/Coch-git/org-mode/lisp/)

   Emacs : GNU Emacs 26.1 (build 1, x86_64-pc-linux-gnu, GTK+ Version
   3.18.9) of 2018-05-30 Package: Org mode version 9.1.14
   (release_9.1.14-908-gf1269e @
   /home/cochard/Org/Coch-git/org-mode/lisp/)

In both cases, org-copy-visible works as I expect: if I select region
containing a folded tree, use 'M-x org-copy-visible', then put the
cursor elsewhere and use 'M-x org-yank', only the visible part is
copied.

Now, if I append the line

   (setq x-select-enable-primary t) 

to ~/.emacs.debug, the whole tree is copied instead of the expected
result, that is, including the invisible parts, also for the two emacs
versions.

NB: For emacs 26, as the manual says that 

   [x-select-enable-primary] is an alias for ‘select-enable-primary’.
   This variable is obsolete since 25.1; use ‘select-enable-primary’
   instead.

I have also tried (setq select-enable-primary t) but this fails in the
same way.

Regards


-- 
EOST (École et Observatoire des Sciences de la Terre) 
IPG (Institut de Physique du Globe) | alain.cochard@unistra.fr
5 rue René Descartes   [bureau 106] | Phone: +33 (0)3 68 85 50 44 
F-67084 Strasbourg Cedex, France    | Fax:   +33 (0)3 68 85 01 25     

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: org-copy-visible does not work with x-select-enable-primary
  2018-09-02 13:37 org-copy-visible does not work with x-select-enable-primary Alain.Cochard
@ 2018-09-02 19:25 ` Nicolas Goaziou
  2018-09-11  7:05   ` Alain.Cochard
  0 siblings, 1 reply; 4+ messages in thread
From: Nicolas Goaziou @ 2018-09-02 19:25 UTC (permalink / raw)
  To: Alain.Cochard; +Cc: emacs-orgmode

Hello,

Alain.Cochard@unistra.fr writes:

> Hello.
>
>
> I use
>
>    emacs -Q -l ~/.emacs.debug
>
> with the ~/.emacs.debug file containing only
>
>    (add-to-list 'load-path "/home/cochard/Org/Coch-git/org-mode/lisp")
>
> I tried 2 versions of emacs, giving:
>
>    Emacs : GNU Emacs 24.5.1 (x86_64-redhat-linux-gnu, GTK+ Version
>    3.18.9) of 2016-04-11 on buildvm-25.phx2.fedoraproject.org Package:
>    Org mode version 9.1.14 (release_9.1.14-908-gf1269e @
>    /home/cochard/Org/Coch-git/org-mode/lisp/)
>
>    Emacs : GNU Emacs 26.1 (build 1, x86_64-pc-linux-gnu, GTK+ Version
>    3.18.9) of 2018-05-30 Package: Org mode version 9.1.14
>    (release_9.1.14-908-gf1269e @
>    /home/cochard/Org/Coch-git/org-mode/lisp/)
>
> In both cases, org-copy-visible works as I expect: if I select region
> containing a folded tree, use 'M-x org-copy-visible', then put the
> cursor elsewhere and use 'M-x org-yank', only the visible part is
> copied.
>
> Now, if I append the line
>
>    (setq x-select-enable-primary t) 
>
> to ~/.emacs.debug, the whole tree is copied instead of the expected
> result, that is, including the invisible parts, also for the two emacs
> versions.
>
> NB: For emacs 26, as the manual says that 
>
>    [x-select-enable-primary] is an alias for ‘select-enable-primary’.
>    This variable is obsolete since 25.1; use ‘select-enable-primary’
>    instead.
>
> I have also tried (setq select-enable-primary t) but this fails in the
> same way.

You may want to report it to Emacs Devel instead. Since it works in some
cases, it may not be related to Org.

Regards,

-- 
Nicolas Goaziou

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: org-copy-visible does not work with x-select-enable-primary
  2018-09-02 19:25 ` Nicolas Goaziou
@ 2018-09-11  7:05   ` Alain.Cochard
  2018-09-11 10:07     ` Nicolas Goaziou
  0 siblings, 1 reply; 4+ messages in thread
From: Alain.Cochard @ 2018-09-11  7:05 UTC (permalink / raw)
  To: Nicolas Goaziou; +Cc: emacs-orgmode

Nicolas Goaziou writes on Sun  2 Sep 2018 21:25:

 > You may want to report it to Emacs Devel instead. Since it works in
 > some cases, it may not be related to Org.

So I did report to Emacs Devel -- see thread
https://lists.gnu.org/archive/html/emacs-devel/2018-09/msg00476.html

Eli Zaretskii argues that the problem comes from Org.

Stefan Monnier provides a patch, which, for me, solves the problem.

Thank you very much and regards.

-- 
EOST (École et Observatoire des Sciences de la Terre) 
IPG (Institut de Physique du Globe) | alain.cochard@unistra.fr
5 rue René Descartes   [bureau 106] | Phone: +33 (0)3 68 85 50 44 
F-67084 Strasbourg Cedex, France    | Fax:   +33 (0)3 68 85 01 25     

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: org-copy-visible does not work with x-select-enable-primary
  2018-09-11  7:05   ` Alain.Cochard
@ 2018-09-11 10:07     ` Nicolas Goaziou
  0 siblings, 0 replies; 4+ messages in thread
From: Nicolas Goaziou @ 2018-09-11 10:07 UTC (permalink / raw)
  To: Alain.Cochard; +Cc: emacs-orgmode

Hello,

Alain.Cochard@unistra.fr writes:

> Nicolas Goaziou writes on Sun  2 Sep 2018 21:25:
>
>  > You may want to report it to Emacs Devel instead. Since it works in
>  > some cases, it may not be related to Org.
>
> So I did report to Emacs Devel -- see thread
> https://lists.gnu.org/archive/html/emacs-devel/2018-09/msg00476.html
>
> Eli Zaretskii argues that the problem comes from Org.
>
> Stefan Monnier provides a patch, which, for me, solves the problem.

Applied. Thank you.

Regards,

-- 
Nicolas Goaziou                                                0x80A93738

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2018-09-11 10:13 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-09-02 13:37 org-copy-visible does not work with x-select-enable-primary Alain.Cochard
2018-09-02 19:25 ` Nicolas Goaziou
2018-09-11  7:05   ` Alain.Cochard
2018-09-11 10:07     ` Nicolas Goaziou

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

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).