all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: don@donarmstrong.com (Emacs bug Tracking System)
To: Glenn Morris <rgm@gnu.org>
Subject: bug#1239: marked as done (PATCH: Fix corner case of  texinfo-insert-quote)
Date: Mon, 1 Dec 2008 19:45:04 -0800	[thread overview]
Message-ID: <handler.1239.D1239.122818908424809.ackdone@emacsbugs.donarmstrong.com> (raw)
In-Reply-To: 4902089E.9030302@garden.org

[-- Attachment #1: Type: text/plain, Size: 870 bytes --]


Your message dated Mon, 01 Dec 2008 22:37:34 -0500
with message-id <nkk5ajw8ld.fsf@fencepost.gnu.org>
and subject line Re: bug#1239: PATCH: Fix corner case of texinfo-insert-quote
has caused the Emacs bug report #1239,
regarding PATCH: Fix corner case of texinfo-insert-quote
to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact don@donarmstrong.com
immediately.)


-- 
1239: http://emacsbugs.donarmstrong.com/cgi-bin/bugreport.cgi?bug=1239
Emacs Bug Tracking System
Contact don@donarmstrong.com with problems

[-- Attachment #2: Type: message/rfc822, Size: 6259 bytes --]

[-- Attachment #2.1.1: Type: text/plain, Size: 1810 bytes --]

Patch is attached and in-line.  It would be nice to have this, in case 
one tries to do quotation mark manipulation with with-temp-buffer.

Thanks for Emacs,
/a

Index: ChangeLog
===================================================================
RCS file: /sources/emacs/emacs/lisp/ChangeLog,v
retrieving revision 1.14668
diff -u -r1.14668 ChangeLog
--- ChangeLog	24 Oct 2008 09:39:28 -0000	1.14668
+++ ChangeLog	24 Oct 2008 17:29:37 -0000
@@ -1,3 +1,8 @@
+2008-10-24  Aaron S. Hawley  <aaronh@garden.org>
+
+	* textmodes/texinfo.el (texinfo-insert-quote): Handle corner
+	 case where point is at the beginning of the buffer.
+
  2008-10-24  Juanma Barranquero  <lekktu@gmail.com>

  	* subr.el (locate-user-emacs-file): New function.
Index: textmodes/texinfo.el
===================================================================
RCS file: /sources/emacs/emacs/lisp/textmodes/texinfo.el,v
retrieving revision 1.122
diff -u -r1.122 texinfo.el
--- textmodes/texinfo.el	6 May 2008 04:33:13 -0000	1.122
+++ textmodes/texinfo.el	24 Oct 2008 17:29:37 -0000
@@ -682,7 +682,9 @@
      (if (or arg
  	    (= (preceding-char) ?\\)
  	    (save-excursion
-	      (backward-char (length texinfo-open-quote))
+	      (if (> (point) (length texinfo-open-quote))
+		  (backward-char (length texinfo-open-quote))
+		(goto-char (point-min)))
  	      (when (or (looking-at texinfo-open-quote)
  			(looking-at texinfo-close-quote))
  		(delete-char (length texinfo-open-quote))
@@ -694,7 +696,8 @@
  		    (setq in-env t)))))
  	(self-insert-command (prefix-numeric-value arg))
        (insert
-       (if (memq (char-syntax (preceding-char)) '(?\( ?> ?\s))
+       (if (or (bobp) ;; (eq (preceding-char) 0)
+	       (memq (char-syntax (preceding-char)) '(?\( ?> ?\s)))
  	   texinfo-open-quote
  	 texinfo-close-quote)))))


[-- Attachment #2.1.2: texinfo.el-bobp.diff --]
[-- Type: text/plain, Size: 1637 bytes --]

Index: ChangeLog
===================================================================
RCS file: /sources/emacs/emacs/lisp/ChangeLog,v
retrieving revision 1.14668
diff -u -r1.14668 ChangeLog
--- ChangeLog	24 Oct 2008 09:39:28 -0000	1.14668
+++ ChangeLog	24 Oct 2008 17:29:37 -0000
@@ -1,3 +1,8 @@
+2008-10-24  Aaron S. Hawley  <aaronh@garden.org>
+
+	* textmodes/texinfo.el (texinfo-insert-quote): Handle corner
+	 case where point is at the beginning of the buffer.
+
 2008-10-24  Juanma Barranquero  <lekktu@gmail.com>
 
 	* subr.el (locate-user-emacs-file): New function.
Index: textmodes/texinfo.el
===================================================================
RCS file: /sources/emacs/emacs/lisp/textmodes/texinfo.el,v
retrieving revision 1.122
diff -u -r1.122 texinfo.el
--- textmodes/texinfo.el	6 May 2008 04:33:13 -0000	1.122
+++ textmodes/texinfo.el	24 Oct 2008 17:29:37 -0000
@@ -682,7 +682,9 @@
     (if (or arg
 	    (= (preceding-char) ?\\)
 	    (save-excursion
-	      (backward-char (length texinfo-open-quote))
+	      (if (> (point) (length texinfo-open-quote))
+		  (backward-char (length texinfo-open-quote))
+		(goto-char (point-min)))
 	      (when (or (looking-at texinfo-open-quote)
 			(looking-at texinfo-close-quote))
 		(delete-char (length texinfo-open-quote))
@@ -694,7 +696,8 @@
 		    (setq in-env t)))))
 	(self-insert-command (prefix-numeric-value arg))
       (insert
-       (if (memq (char-syntax (preceding-char)) '(?\( ?> ?\s))
+       (if (or (bobp) ;; (eq (preceding-char) 0)
+	       (memq (char-syntax (preceding-char)) '(?\( ?> ?\s)))
 	   texinfo-open-quote
 	 texinfo-close-quote)))))
 

[-- Attachment #3: Type: message/rfc822, Size: 1653 bytes --]

From: Glenn Morris <rgm@gnu.org>
To: 1239-done@emacsbugs.donarmstrong.com
Subject: Re: bug#1239: PATCH: Fix corner case of texinfo-insert-quote
Date: Mon, 01 Dec 2008 22:37:34 -0500
Message-ID: <nkk5ajw8ld.fsf@fencepost.gnu.org>


OK; installed.

2008-12-02  Aaron S. Hawley  <aaronh@garden.org>

  * textmodes/texinfo.el (texinfo-insert-quote): Handle
  corner case where point is at the beginning of the buffer.  (Bug#1239)


      reply	other threads:[~2008-12-02  3:45 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <nkk5ajw8ld.fsf@fencepost.gnu.org>
2008-10-24 17:40 ` bug#1239: PATCH: Fix corner case of texinfo-insert-quote Aaron S. Hawley
2008-12-02  3:45   ` Emacs bug Tracking System [this message]

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

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

  git send-email \
    --in-reply-to=handler.1239.D1239.122818908424809.ackdone@emacsbugs.donarmstrong.com \
    --to=don@donarmstrong.com \
    --cc=rgm@gnu.org \
    /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.
Code repositories for project(s) associated with this external index

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

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.