From mboxrd@z Thu Jan 1 00:00:00 1970 From: Lennart Borgman Subject: bug#5753: something, something, org-mode, shift-select, something Date: Sun, 9 Feb 2014 12:05:38 +0100 Message-ID: References: <87bnyhm60k.fsf@moondust.localdomain> Mime-Version: 1.0 Content-Type: multipart/alternative; boundary=047d7bf10a8463526404f1f73662 Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:50161) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WCSE8-0006kP-3I for emacs-orgmode@gnu.org; Sun, 09 Feb 2014 06:07:13 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1WCSE3-0001Vn-2f for emacs-orgmode@gnu.org; Sun, 09 Feb 2014 06:07:08 -0500 Received: from debbugs.gnu.org ([140.186.70.43]:45303) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WCSE2-0001Vj-Ux for emacs-orgmode@gnu.org; Sun, 09 Feb 2014 06:07:03 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.80) (envelope-from ) id 1WCSE2-00088b-FL for emacs-orgmode@gnu.org; Sun, 09 Feb 2014 06:07:02 -0500 Sender: "Debbugs-submit" Resent-Message-ID: In-Reply-To: <87bnyhm60k.fsf@moondust.localdomain> List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: "N. Jackson" Cc: 5753@debbugs.gnu.org --047d7bf10a8463526404f1f73662 Content-Type: text/plain; charset=UTF-8 On Sun, Feb 9, 2014 at 2:25 AM, N. Jackson wrote: > The following message is a courtesy copy of an article > that has been posted to gnu.emacs.bug as well. > > Lars Ingebrigtsen writes: > > > Lennart Borgman writes: > > > >> Shift-select in cua-mode does not work in org-mode although > >> org-replace-disputed-keys is t, org-disputed-keys are set for shift > >> arrow keys and org-support-shift-select is always > > > > Is this problem still present in Emacs 24.3? > > Naturally I can't answer for the OP (and I don't know about disputed > keys) but I can report that in general this problem persists in Emacs > 24.3. > > On GNU Emacs 24.3.1 [1], shift select does not work in org mode. I'm not > certain this is a bug, as my understanding is that the org authors did > not design it to work with shift select? > > In any case, I use a very simple workaround which makes shift select > work just fine in org mode; I've never had any problems with it. It > looks like this (Note: It is of unknown provenance, aside from the > attribution in the comment.): > > ;; This snippit from jisang-yoo on reddit to enable shift select in org > ;; mode when cua-mode is on. > (eval-after-load "org" > '(progn > (eval-after-load "cua-base" > '(progn > (defadvice org-call-for-shift-select (before > org-call-for-shift-select-cua activate) > (if (and cua-mode > org-support-shift-select (not (use-region-p))) > (cua-set-mark))))))) > ;; End jisang-yoo snippit > > With this in my org settings, I have no problems with shift select > except that you cannot start a selection on a timestamp (because shift > with cursor keys adjusts timestamps), but I've learnt to automatically > start my selection from the end of the line above the timestamp so I > don't have any problems. > > I hope this information is of some use. > > [1] GNU Emacs 24.3.1 (x86_64-redhat-linux-gnu, GTK+ Version 3.8.2) of > 2013-08-14 on buildvm-15.phx2.fedoraproject.org > > > Thanks Jason. I can't test now myself. I think this problem illustrates very well why cua-mode must be made a first class citizen in Emacs. Without that problems like this are showing up for beginners. --047d7bf10a8463526404f1f73662 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
On S= un, Feb 9, 2014 at 2:25 AM, N. Jackson <gentleundercurrent@gmail.com> w= rote:
The following message is a courtesy copy of = an article
that has been posted to gnu.emacs.bug as well.

Lars Ingebrigtsen <larsi@gnus.org> writes:

> Lennart Borgman <lennart.borgman@gmail.com> writes:
>
>> Shift-select in cua-mode does not work in org-mode although
>> org-replace-disputed-keys is t, org-disputed-keys are set for shif= t
>> arrow keys and org-support-shift-select is always
>
> Is this problem still present in Emacs 24.3?

Naturally I can't answer for the OP (and I don't know about dispute= d
keys) but I can report that in general this problem persists in Emacs
24.3.

On GNU Emacs 24.3.1 [1], shift select does not work in org mode. I'm no= t
certain this is a bug, as my understanding is that the org authors did
not design it to work with shift select?

In any case, I use a very simple workaround which makes shift select
work just fine in org mode; I've never had any problems with it. It
looks like this (Note: It is of unknown provenance, aside from the
attribution in the comment.):

;; This snippit from jisang-yoo on reddit to enable shift select in org
;; mode when cua-mode is on.
(eval-after-load "org"
=C2=A0 =C2=A0 '(progn
=C2=A0 =C2=A0 =C2=A0 =C2=A0(eval-after-load "cua-base"
=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0'(progn
=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 (defadvice org-call-for-shift-sel= ect (before
=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 org-call-for-shift-select-cua act= ivate)
=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 (if (and cua-mode
=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2= =A0 =C2=A0org-support-shift-select (not (use-region-p)))
=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 (cua-set-mar= k)))))))
;; End jisang-yoo snippit

With this in my org settings, I have no problems with shift select
except that you cannot start a selection on a timestamp (because shift
with cursor keys adjusts timestamps), but I've learnt to automatically<= br> start my selection from the end of the line above the timestamp so I
don't have any problems.

I hope this information is of some use.

[1] GNU Emacs 24.3.1 (x86_64-redhat-linux-gnu, GTK+ Version 3.8.2) of
2013-08-14 on
buildvm-15.phx2.fedoraproject.org


Thanks Jason. I can't test now myself.
I think this problem illustrates very well why cua-mode must be made a fir= st class citizen in Emacs. Without that problems like this are showing up f= or beginners.=C2=A0

--047d7bf10a8463526404f1f73662--