<?xml version="1.0" encoding="UTF-8"?>
<rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns="http://purl.org/rss/1.0/" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:syn="http://purl.org/rss/1.0/modules/syndication/" xmlns:admin="http://webns.net/mvcb/">
  <channel rdf:about="http://blog.gmane.org/gmane.emacs.auctex.devel">
    <title>gmane.emacs.auctex.devel</title>
    <link>http://blog.gmane.org/gmane.emacs.auctex.devel</link>
    <description/>
    <syn:updatePeriod>hourly</syn:updatePeriod>
    <syn:updateFrequency>1</syn:updateFrequency>
    <syn:updateBase>1901-01-01T00:00+00:00</syn:updateBase>
    <items>
      <rdf:Seq>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.emacs.auctex.devel/3160"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.emacs.auctex.devel/3159"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.emacs.auctex.devel/3158"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.emacs.auctex.devel/3157"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.emacs.auctex.devel/3156"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.emacs.auctex.devel/3155"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.emacs.auctex.devel/3153"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.emacs.auctex.devel/3152"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.emacs.auctex.devel/3151"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.emacs.auctex.devel/3150"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.emacs.auctex.devel/3149"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.emacs.auctex.devel/3148"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.emacs.auctex.devel/3147"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.emacs.auctex.devel/3146"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.emacs.auctex.devel/3145"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.emacs.auctex.devel/3144"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.emacs.auctex.devel/3143"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.emacs.auctex.devel/3142"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.emacs.auctex.devel/3141"/>
        <rdf:li rdf:resource="http://permalink.gmane.org/gmane.emacs.auctex.devel/3140"/>
      </rdf:Seq>
    </items>
    <image rdf:resource="http://gmane.org/img/gmane-25t.png"/>
    <textinput rdf:resource=""/>
  </channel>
  <image rdf:about="http://gmane.org/img/gmane-25t.png">
    <title>Gmane</title>
    <url>http://gmane.org/img/gmane-25t.png</url>
    <link>http://gmane.org</link>
  </image>
  <item rdf:about="http://permalink.gmane.org/gmane.emacs.auctex.devel/3160">
    <title>Re: Regarding 1.2.7 Installation under MS Windows</title>
    <link>http://permalink.gmane.org/gmane.emacs.auctex.devel/3160</link>
    <description>&lt;pre&gt;Hi David,

the only problem with the AUCTeX package provided by ELPA is that it's
the 11.86 version, not the latest one.

Bye,
Mosè

2013/6/16 David Kastrup &amp;lt;dak&amp;lt; at &amp;gt;gnu.org&amp;gt;:

_______________________________________________
auctex-devel mailing list
auctex-devel&amp;lt; at &amp;gt;gnu.org
https://lists.gnu.org/mailman/listinfo/auctex-devel
&lt;/pre&gt;</description>
    <dc:creator>Mosè Giordano</dc:creator>
    <dc:date>2013-06-16T10:16:48</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.emacs.auctex.devel/3159">
    <title>Re: Regarding 1.2.7 Installation under MS Windows</title>
    <link>http://permalink.gmane.org/gmane.emacs.auctex.devel/3159</link>
    <description>&lt;pre&gt;

In
&amp;lt;URL:http://www.gnu.org/software/auctex/manual/auctex/Installation.html#Installation&amp;gt;
I read

    The simplest way of installing AUCTeX is by using the Emacs package
    manager integrated in Emacs 24 and greater (ELPA). Simply do M-x
    package-list-packages RET, mark the auctex package for installation
    with i, and hit x to execute the installation procedure. That’s all.

    The remainder of this section is about installing AUCTeX from a
    release tarball or from a checkout of the AUCTeX repository.

The question is why James would want to do the latter rather than the
former.

&lt;/pre&gt;</description>
    <dc:creator>David Kastrup</dc:creator>
    <dc:date>2013-06-16T09:58:57</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.emacs.auctex.devel/3158">
    <title>Re: Regarding 1.2.7 Installation under MS Windows</title>
    <link>http://permalink.gmane.org/gmane.emacs.auctex.devel/3158</link>
    <description>&lt;pre&gt;Hi James,

if you don't know how to compile AUCTeX under Windows you can install
the precompiled package:
http://www.gnu.org/software/auctex/download-for-windows.html

Bye,
Mosè


2013/6/16 James Yifan.Xu &amp;lt;yifan.james.xu&amp;lt; at &amp;gt;gmail.com&amp;gt;

_______________________________________________
auctex-devel mailing list
auctex-devel&amp;lt; at &amp;gt;gnu.org
https://lists.gnu.org/mailman/listinfo/auctex-devel
&lt;/pre&gt;</description>
    <dc:creator>Mosè Giordano</dc:creator>
    <dc:date>2013-06-16T09:45:27</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.emacs.auctex.devel/3157">
    <title>Regarding 1.2.7 Installation under MS Windows</title>
    <link>http://permalink.gmane.org/gmane.emacs.auctex.devel/3157</link>
    <description>&lt;pre&gt;Dear developers,

First of all, thank you very much for all the work you have done. I am very
grateful for the free software, packages.and instructions. I see that you
put much effort to make it accessible for everyone.

I am a biostatistician. I have been programming in R, and writing Latex for
5 years. Recently I started to use Emacs (with ESS &amp;amp; Auctex) on my Mac and
I loved it. However when I try to install it on my Windows 7 all kinds of
trouble occurred.

I have been reading the installation procedure of Auctex for Emacs.
http://www.gnu.org/software/auctex/manual/auctex/Installation-under-MS-Windows.html#Installation-under-MS-Windows

As a windows user who knows less than 5 commands in Linux, I have to say
that I find the page very intimidating. For example, I don't understand

"you can do this by typing the following statement at the shell prompt:


./configure --prefix='C:/Program Files/Emacs' \
  --infodir='C:/Program Files/Emacs/info' \
  --with-texmf-dir='C:/localtexmf'

"

or

" If there were no further error messages, type

make

"


I am not sure what a "shell prompt" is or where to "type" the word "make".
I am more used to giving orders by clicking mouse buttons. I admit I should
probably learn more background in order to understand the page, but is
there anyway that I can configure it without learning another operating
system? I just want to get it to work during the weekend.

Thank you very much for your time!

Best regards,

James

--
_______________________________________________
auctex-devel mailing list
auctex-devel&amp;lt; at &amp;gt;gnu.org
https://lists.gnu.org/mailman/listinfo/auctex-devel
&lt;/pre&gt;</description>
    <dc:creator>James Yifan.Xu</dc:creator>
    <dc:date>2013-06-16T03:37:13</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.emacs.auctex.devel/3156">
    <title>Re: [PATCH 2/2] Add tests for reftex.</title>
    <link>http://permalink.gmane.org/gmane.emacs.auctex.devel/3156</link>
    <description>&lt;pre&gt;

Indeed, committed, thanks!


Ah, good to know.

Bye,
Tassilo

_______________________________________________
auctex-devel mailing list
auctex-devel&amp;lt; at &amp;gt;gnu.org
https://lists.gnu.org/mailman/listinfo/auctex-devel
&lt;/pre&gt;</description>
    <dc:creator>Tassilo Horn</dc:creator>
    <dc:date>2013-06-12T14:47:26</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.emacs.auctex.devel/3155">
    <title>Re: [PATCH 2/2] Add tests for reftex.</title>
    <link>http://permalink.gmane.org/gmane.emacs.auctex.devel/3155</link>
    <description>&lt;pre&gt;Hi,

On Wednesday 12 June 2013 14:51:23 Tassilo Horn wrote:

sorry this was a problem caused by an uninitialised variable.  I guess that's 
why I didn't caught it.

Adding (reftex-ensure-compiled-variables) prior to the call to `reftex-parse-
from-file' fixes the issue.

--8&amp;lt;---------------------&amp;gt;8---
diff --git a/test/automated/reftex-tests.el b/test/automated/reftex-tests.el
index 5f5b008..de7f36d 100644
--- a/test/automated/reftex-tests.el
+++ b/test/automated/reftex-tests.el
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -115,6 +115,7 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; (ert-deftest reftex-parse-from-file-test ()
     (with-temp-buffer
       (insert "test\n")
       (write-region (point-min) (point-max) bib-file))
+    (reftex-ensure-compiled-variables)
     (let ((parsed (reftex-parse-from-file tex-file nil temp-dir)))
       (should (equal (car parsed) `(eof ,tex-file)))
       (pop parsed)
--8&amp;lt;---------------------&amp;gt;8---


In ert you can get the backtrace by pressing `b'.

Regards
Rüdiger


_______________________________________________
auctex-devel mailing list
auctex-devel&amp;lt; at &amp;gt;gnu.org
https://lists.gnu.org/mailman/listinfo/auctex-devel
&lt;/pre&gt;</description>
    <dc:creator>Rüdiger Sonderfeld</dc:creator>
    <dc:date>2013-06-12T13:57:47</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.emacs.auctex.devel/3153">
    <title>Re: [PATCH 1/2] Reftex: Convert comments todocstrings.</title>
    <link>http://permalink.gmane.org/gmane.emacs.auctex.devel/3153</link>
    <description>&lt;pre&gt;Hi Rüdiger,

thanks a lot, I've applied your change.  BTW: the ChangeLog entry should
include all functions/defvars you have touched.  I did that for you now.

Bye,
Tassilo


_______________________________________________
auctex-devel mailing list
auctex-devel&amp;lt; at &amp;gt;gnu.org
https://lists.gnu.org/mailman/listinfo/auctex-devel
&lt;/pre&gt;</description>
    <dc:creator>Tassilo Horn</dc:creator>
    <dc:date>2013-06-12T12:44:03</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.emacs.auctex.devel/3152">
    <title>[PATCH 1/2] Reftex: Convert comments to docstrings.</title>
    <link>http://permalink.gmane.org/gmane.emacs.auctex.devel/3152</link>
    <description>&lt;pre&gt;* lisp/textmodes/reftex-cite.el: Convert comments to docstrings.
* lisp/textmodes/reftex-parse.el: Convert comments to docstrings.

Signed-off-by: Rüdiger Sonderfeld &amp;lt;ruediger&amp;lt; at &amp;gt;c-plusplus.de&amp;gt;
---
 lisp/textmodes/reftex-cite.el  | 129 +++++++++++++++++-----------------
 lisp/textmodes/reftex-parse.el | 154 ++++++++++++++++++++---------------------
 2 files changed, 137 insertions(+), 146 deletions(-)

diff --git a/lisp/textmodes/reftex-cite.el b/lisp/textmodes/reftex-cite.el
index ca29709..6c10329 100644
--- a/lisp/textmodes/reftex-cite.el
+++ b/lisp/textmodes/reftex-cite.el
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -25,18 +25,16 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt;
 ;;; Code:
 
 (eval-when-compile (require 'cl))
-(provide 'reftex-cite)
-(require 'reftex)
-;;;
 
-;; Variables and constants
+(require 'reftex)
 
-;; The history list of regular expressions used for citations
-(defvar reftex-cite-regexp-hist nil)
+;;; Variables and constants
+(defvar reftex-cite-regexp-hist nil
+  "The history list of regular expressions used for citations")
 
-;; Prompt and help string for citation selection
 (defconst reftex-citation-prompt
-  "Select: [n]ext [p]revious [r]estrict [ ]full_entry [q]uit RET [?]Help+more")
+  "Select: [n]ext [p]revious [r]estrict [ ]full_entry [q]uit RET [?]Help+more"
+  "Prompt and help string for citation selection")
 
 (defconst reftex-citation-help
   " n / p      Go to next/previous entry (Cursor motion works as well).
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -51,8 +49,7 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; (defconst reftex-citation-help
  e / E      Create BibTeX file with all (marked/unmarked) entries
  a / A      Put all (marked) entries into one/many \\cite commands.")
 
-;; Find bibtex files
-
+;;; Find bibtex files
 (defmacro reftex-with-special-syntax-for-bib (&amp;amp;rest body)
   `(let ((saved-syntax (syntax-table)))
      (unwind-protect
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -62,8 +59,8 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; (defmacro reftex-with-special-syntax-for-bib (&amp;amp;rest body)
        (set-syntax-table saved-syntax))))
 
 (defun reftex-default-bibliography ()
-  ;; Return the expanded value of `reftex-default-bibliography'.
-  ;; The expanded value is cached.
+  "Return the expanded value of variable `reftex-default-bibliography'.
+The expanded value is cached."
   (unless (eq (get 'reftex-default-bibliography :reftex-raw)
               reftex-default-bibliography)
     (put 'reftex-default-bibliography :reftex-expanded
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -74,9 +71,8 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; (defun reftex-default-bibliography ()
   (get 'reftex-default-bibliography :reftex-expanded))
 
 (defun reftex-bib-or-thebib ()
-  ;; Tests if BibTeX or \begin{thebibliography} should be used for the
-  ;; citation
-  ;; Find the bof of the current file
+  "Test if BibTeX or \begin{thebibliography} should be used for the citation.
+Find the bof of the current file"
   (let* ((docstruct (symbol-value reftex-docstruct-symbol))
          (rest (or (member (list 'bof (buffer-file-name)) docstruct)
                    docstruct))
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -94,11 +90,11 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; (defun reftex-bib-or-thebib ()
       (if thebib 'thebib nil))))
 
 (defun reftex-get-bibfile-list ()
-  ;; Return list of bibfiles for current document.
-  ;; When using the chapterbib or bibunits package you should either
-  ;; use the same database files everywhere, or separate parts using
-  ;; different databases into different files (included into the mater file).
-  ;; Then this function will return the applicable database files.
+  "Return list of bibfiles for current document.
+When using the chapterbib or bibunits package you should either
+use the same database files everywhere, or separate parts using
+different databases into different files (included into the mater file).
+Then this function will return the applicable database files."
 
   ;; Ensure access to scanning info
   (reftex-access-scan-info)
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -115,16 +111,14 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; (defun reftex-get-bibfile-list ()
    (cdr (assq 'bib (symbol-value reftex-docstruct-symbol)))
    (error "\\bibliography statement missing or .bib files not found")))
 
-;; Find a certain reference in any of the BibTeX files.
-
+;;; Find a certain reference in any of the BibTeX files.
 (defun reftex-pop-to-bibtex-entry (key file-list &amp;amp;optional mark-to-kill
                                        highlight item return)
-  ;; Find BibTeX KEY in any file in FILE-LIST in another window.
-  ;; If MARK-TO-KILL is non-nil, mark new buffer to kill.
-  ;; If HIGHLIGHT is non-nil, highlight the match.
-  ;; If ITEM in non-nil, search for bibitem instead of database entry.
-  ;; If RETURN is non-nil, just return the entry and restore point.
-
+  "Find BibTeX KEY in any file in FILE-LIST in another window.
+If MARK-TO-KILL is non-nil, mark new buffer to kill.
+If HIGHLIGHT is non-nil, highlight the match.
+If ITEM in non-nil, search for bibitem instead of database entry.
+If RETURN is non-nil, just return the entry and restore point."
   (let* ((re
           (if item
               (concat "\\\\bibitem[ \t]*\\(\\[[^]]*\\]\\)?[ \t]*{"
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -178,12 +172,11 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; (defun reftex-end-of-bib-entry (item)
           (progn (forward-list 1) (point)))
       (error (min (point-max) (+ 300 (point)))))))
 
-;; Parse bibtex buffers
-
+;;; Parse bibtex buffers
 (defun reftex-extract-bib-entries (buffers)
-  ;; Extract bib entries which match regexps from BUFFERS.
-  ;; BUFFERS is a list of buffers or file names.
-  ;; Return list with entries."
+  "Extract bib entries which match regexps from BUFFERS.
+BUFFERS is a list of buffers or file names.
+Return list with entries."
   (let* (re-list first-re rest-re
                  (buffer-list (if (listp buffers) buffers (list buffers)))
                  found-list entry buffer1 buffer alist
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -309,6 +302,8 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; (defun reftex-extract-bib-entries (buffers)
      (t found-list))))
 
 (defun reftex-bib-sort-author (e1 e2)
+  "Compare bib entries E1 and E2 by author.
+The name of the first different author/editor is used."
   (let ((al1 (reftex-get-bib-names "author" e1))
         (al2 (reftex-get-bib-names "author" e2)))
     (while (and al1 al2 (string= (car al1) (car al2)))
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -320,15 +315,17 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; (defun reftex-bib-sort-author (e1 e2)
       (not (stringp (car al1))))))
 
 (defun reftex-bib-sort-year (e1 e2)
+  "Compare bib entries E1 and E2 by year in ascending order."
   (&amp;lt; (string-to-number (or (cdr (assoc "year" e1)) "0"))
      (string-to-number (or (cdr (assoc "year" e2)) "0"))))
 
 (defun reftex-bib-sort-year-reverse (e1 e2)
+  "Compare bib entries E1 and E2 by year in descending order."
   (&amp;gt; (string-to-number (or (cdr (assoc "year" e1)) "0"))
      (string-to-number (or (cdr (assoc "year" e2)) "0"))))
 
 (defun reftex-get-crossref-alist (entry)
-  ;; return the alist from a crossref entry
+  "Return the alist from a crossref ENTRY."
   (let ((crkey (cdr (assoc "crossref" entry)))
         start)
     (save-excursion
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -347,10 +344,9 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; (defun reftex-get-crossref-alist (entry)
 
 ;; Parse the bibliography environment
 (defun reftex-extract-bib-entries-from-thebibliography (files)
-  ;; Extract bib-entries from the \begin{thebibliography} environment.
-  ;; Parsing is not as good as for the BibTeX database stuff.
-  ;; The environment should be located in file FILE.
-
+  "Extract bib-entries from the \begin{thebibliography} environment.
+Parsing is not as good as for the BibTeX database stuff.
+The environment should be located in FILES."
   (let* (start end buf entries re re-list file default)
     (unless files
       (error "Need file name to find thebibliography environment"))
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -430,8 +426,8 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; (defun reftex-extract-bib-entries-from-thebibliography (files)
     entries))
 
 (defun reftex-get-bibkey-default ()
-  ;; Return the word before the cursor.  If the cursor is in a
-  ;; citation macro, return the word before the macro.
+  "Return the word before the cursor.
+If the cursor is in a citation macro, return the word before the macro."
   (let* ((macro (reftex-what-macro 1)))
     (save-excursion
       (if (and macro (string-match "cite" (car macro)))
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -439,10 +435,10 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; (defun reftex-get-bibkey-default ()
       (skip-chars-backward "^a-zA-Z0-9")
       (reftex-this-word))))
 
-;; Parse and format individual entries
-
+;;; Parse and format individual entries
 (defun reftex-get-bib-names (field entry)
-  ;; Return a list with the author or editor names in ENTRY
+  "Return a list with the author or editor names in ENTRY.
+If FIELD is empty try \"editor\" field."
   (let ((names (reftex-get-bib-field field entry)))
     (if (equal "" names)
         (setq names (reftex-get-bib-field "editor" entry)))
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -457,7 +453,9 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; (defun reftex-get-bib-names (field entry)
     (split-string names "\n")))
 
 (defun reftex-parse-bibtex-entry (entry &amp;amp;optional from to raw)
-  ; if RAW is non-nil, keep double quotes/curly braces delimiting fields
+  "Parse BibTeX ENTRY.
+If ENTRY is nil then parse the entry in current buffer between FROM and TO.
+If RAW is non-nil, keep double quotes/curly braces delimiting fields."
   (let (alist key start field)
     (save-excursion
       (save-restriction
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -518,7 +516,8 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; (defun reftex-parse-bibtex-entry (entry &amp;amp;optional from to raw)
     alist))
 
 (defun reftex-get-bib-field (fieldname entry &amp;amp;optional format)
-  ;; Extract the field FIELDNAME from an ENTRY
+  "Extract the field FIELDNAME from ENTRY.
+If FORMAT is non-nil `format' entry accordingly."
   (let ((cell (assoc fieldname entry)))
     (if cell
         (if format
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -527,7 +526,7 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; (defun reftex-get-bib-field (fieldname entry &amp;amp;optional format)
       "")))
 
 (defun reftex-format-bib-entry (entry)
-  ;; Format a BibTeX ENTRY so that it is nice to look at
+  "Format a BibTeX ENTRY so that it is nice to look at."
   (let*
       ((auth-list (reftex-get-bib-names "author" entry))
        (authors (mapconcat 'identity auth-list ", "))
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -570,7 +569,7 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; (defun reftex-format-bib-entry (entry)
     (concat key "\n     " authors " " year " " extra "\n     " title "\n\n")))
 
 (defun reftex-parse-bibitem (item)
-  ;; Parse a \bibitem entry
+  "Parse a \bibitem entry in ITEM."
   (let ((key "") (text ""))
     (when (string-match "\\`{\\([^}]+\\)}\\([^\000]*\\)" item)
       (setq key (match-string 1 item)
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -586,7 +585,7 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; (defun reftex-parse-bibitem (item)
      (cons "&amp;amp;entry" (concat key " " text)))))
 
 (defun reftex-format-bibitem (item)
-  ;; Format a \bibitem entry so that it is (relatively) nice to look at.
+  "Format a \bibitem entry in ITEM so that it is (relatively) nice to look at."
   (let ((text (reftex-get-bib-field "&amp;amp;text" item))
         (key  (reftex-get-bib-field "&amp;amp;key" item))
         (lines nil))
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -603,7 +602,7 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; (defun reftex-format-bibitem (item)
       (put-text-property 0 (length text) 'face reftex-bib-author-face text))
     (concat key "\n     " text "\n\n")))
 
-;; Make a citation
+;;; Make a citation
 
 ;;;###autoload
 (defun reftex-citation (&amp;amp;optional no-insert format-key)
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -627,7 +626,6 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; (defun reftex-citation (&amp;amp;optional no-insert format-key)
 Thus, `aaaa&amp;amp;&amp;amp;bbb' matches entries which contain both `aaaa' and `bbb'.
 While entering the regexp, completion on knows citation keys is possible.
 `=' is a good regular expression to match all entries in all files."
-
   (interactive)
 
   ;; check for recursive edit
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -645,8 +643,7 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; (defun reftex-citation (&amp;amp;optional no-insert format-key)
     (reftex-kill-temporary-buffers)))
 
 (defun reftex-do-citation (&amp;amp;optional arg no-insert format-key)
-  ;; This really does the work of reftex-citation.
-
+  "This really does the work of `reftex-citation'."
   (let* ((format (reftex-figure-out-cite-format arg no-insert format-key))
          (docstruct-symbol reftex-docstruct-symbol)
          (selected-entries (reftex-offer-bib-menu))
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -743,8 +740,8 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; (defun reftex-do-citation (&amp;amp;optional arg no-insert format-key)
     (mapcar 'car selected-entries)))
 
 (defun reftex-figure-out-cite-format (arg &amp;amp;optional no-insert format-key)
-  ;; Check if there is already a cite command at point and change cite format
-  ;; in order to only add another reference in the same cite command.
+  "Check if there is already a cite command at point and change cite format
+in order to only add another reference in the same cite command."
   (let ((macro (car (reftex-what-macro 1)))
         (cite-format-value (reftex-get-cite-format))
         key format)
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -802,8 +799,7 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; (defun reftex-citet ()
 
 (defvar reftex-select-bib-map)
 (defun reftex-offer-bib-menu ()
-  ;; Offer bib menu and return list of selected items
-
+  "Offer bib menu and return list of selected items."
   (let ((bibtype (reftex-bib-or-thebib))
         found-list rtn key data selected-entries)
     (while
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -917,7 +913,7 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; (defun reftex-offer-bib-menu ()
     selected-entries))
 
 (defun reftex-restrict-bib-matches (found-list)
-  ;; Limit FOUND-LIST with more regular expressions
+  "Limit FOUND-LIST with more regular expressions."
   (let ((re-list (split-string (read-string
                                 "RegExp [ &amp;amp;&amp;amp; RegExp...]: "
                                 nil 'reftex-cite-regexp-hist)
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -940,7 +936,7 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; (defun reftex-restrict-bib-matches (found-list)
       found-list)))
 
 (defun reftex-extract-bib-file (all &amp;amp;optional marked complement)
-  ;; Limit FOUND-LIST with more regular expressions
+  "Limit FOUND-LIST with more regular expressions."
   (let ((file (read-file-name "File to create: ")))
     (find-file-other-window file)
     (if (&amp;gt; (buffer-size) 0)
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -963,7 +959,7 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; (defun reftex-extract-bib-file (all &amp;amp;optional marked complement)
     (goto-char (point-min))))
 
 (defun reftex-insert-bib-matches (list)
-  ;; Insert the bib matches and number them correctly
+  "Insert the bib matches and number them correctly."
   (let ((mouse-face
          (if (memq reftex-highlight-selection '(mouse both))
              reftex-mouse-selected-face
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -996,8 +992,7 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; (defun reftex-format-names (namelist n)
        last)))))
 
 (defun reftex-format-citation (entry format)
-  ;; Format a citation from the info in the BibTeX ENTRY
-
+  "Format a citation from the info in the BibTeX ENTRY according to FORMAT."
   (unless (stringp format) (setq format "\\cite{%l}"))
 
   (if (and reftex-comment-citations
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -1064,7 +1059,7 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; (defun reftex-format-citation (entry format)
   format)
 
 (defun reftex-make-cite-echo-string (entry docstruct-symbol)
-  ;; Format a bibtex entry for the echo area and cache the result.
+  "Format a bibtex ENTRY for the echo area and cache the result."
   (let* ((key (reftex-get-bib-field "&amp;amp;key" entry))
          (string
           (let* ((reftex-cite-punctuation '(" " " &amp;amp; " " etal.")))
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -1088,9 +1083,9 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; (defun reftex-make-cite-echo-string (entry docstruct-symbol)
     string))
 
 (defun reftex-bibtex-selection-callback (data ignore no-revisit)
-  ;; Callback function to be called from the BibTeX selection, in
-  ;; order to display context.  This function is relatively slow and not
-  ;; recommended for follow mode.  It works OK for individual lookups.
+  "Callback function to be called from the BibTeX selection, in
+order to display context.  This function is relatively slow and not
+recommended for follow mode.  It works OK for individual lookups."
   (let ((win (selected-window))
         (key (reftex-get-bib-field "&amp;amp;key" data))
         bibfile-list item bibtype)
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -1157,7 +1152,7 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; (defun reftex-get-string-refs (alist)
       alist))))
 
 (defun reftex-create-bibtex-file (bibfile)
-  "Create a new BibTeX database file with all entries referenced in document.
+  "Create a new BibTeX database BIBFILE with all entries referenced in document.
 The command prompts for a filename and writes the collected
 entries to that file.  Only entries referenced in the current
 document with any \\cite-like macros are used.  The sequence in
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -1247,5 +1242,5 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; (defun reftex-create-bibtex-file (bibfile)
     (message "%d entries extracted and copied to new database"
              (length entries))))
 
-
+(provide 'reftex-cite)
 ;;; reftex-cite.el ends here
diff --git a/lisp/textmodes/reftex-parse.el b/lisp/textmodes/reftex-parse.el
index 3a64aad..a99791e 100644
--- a/lisp/textmodes/reftex-parse.el
+++ b/lisp/textmodes/reftex-parse.el
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -49,7 +49,8 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; (defun reftex-parse-all ()
   (reftex-access-scan-info '(16)))
 
 (defun reftex-do-parse (rescan &amp;amp;optional file)
-  "Do a document rescan.  When allowed, do only a partial scan from FILE."
+  "Do a document rescan.
+When allowed, do only a partial scan from FILE."
 
   ;; Normalize the rescan argument
   (setq rescan (cond ((eq rescan t) t)
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -191,7 +192,7 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; (defun reftex-all-document-files (&amp;amp;optional relative)
 (defvar index-tags)
 
 (defun reftex-parse-from-file (file docstruct master-dir)
-  ;; Scan the buffer for labels and save them in a list.
+  "Scan the buffer for labels and save them in a list."
   (let ((regexp (reftex-everything-regexp))
         (bound 0)
         file-found tmp include-file
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -350,8 +351,7 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; (defun reftex-parse-from-file (file docstruct master-dir)
     docstruct))
 
 (defun reftex-locate-bibliography-files (master-dir &amp;amp;optional files)
-  ;; Scan buffer for bibliography macro and return file list.
-
+  "Scan buffer for bibliography macro and return file list."
   (unless files
     (save-excursion
       (goto-char (point-min))
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -379,10 +379,10 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; (defun reftex-locate-bibliography-files (master-dir &amp;amp;optional files)
     (delq nil files)))
 
 (defun reftex-replace-label-list-segment (old insert &amp;amp;optional entirely)
-  ;; Replace the segment in OLD which corresponds to INSERT.
-  ;; Works with side effects, directly changes old.
-  ;; If entirely is t, just return INSERT.
-  ;; This function also makes sure the old toc markers do not point anywhere.
+  "Replace the segment in OLD which corresponds to INSERT.
+Works with side effects, directly changes old.
+If ENTIRELY is t, just return INSERT.
+This function also makes sure the old toc markers do not point anywhere."
 
   (cond
    (entirely
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -404,8 +404,8 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; (defun reftex-replace-label-list-segment (old insert &amp;amp;optional entirely)
         new))))
 
 (defun reftex-section-info (file)
-  ;; Return a section entry for the current match.
-  ;; Careful: This function expects the match-data to be still in place!
+  "Return a section entry for the current match.
+Careful: This function expects the match-data to be still in place!"
   (let* ((marker (set-marker (make-marker) (1- (match-beginning 3))))
          (macro (reftex-match-string 3))
          (prefix (save-match-data
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -440,9 +440,9 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; (defun reftex-section-info (file)
           literal (marker-position marker))))
 
 (defun reftex-ensure-index-support (&amp;amp;optional abort)
-  ;; When index support is turned off, ask to turn it on and
-  ;; set the current prefix argument so that `reftex-access-scan-info'
-  ;; will rescan the entire document.
+  "When index support is turned off, ask to turn it on and
+set the current prefix argument so that `reftex-access-scan-info'
+will rescan the entire document."
   (cond
    (reftex-support-index t)
    ((y-or-n-p "Turn on index support and rescan entire document? ")
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -460,8 +460,8 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; (defun reftex-index-info-safe (file)
 
 (defvar test-dummy)
 (defun reftex-index-info (file)
-  ;; Return an index entry for the current match.
-  ;; Careful: This function expects the match-data to be still in place!
+  "Return an index entry for the current match.
+Careful: This function expects the match-data to be still in place!"
   (catch 'exit
     (let* ((macro (reftex-match-string 10))
            (bom (match-beginning 10))
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -508,7 +508,7 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; (defun reftex-index-info (file)
       (list 'index index-tag context file bom arg key showkey sortkey key-end))))
 
 (defun reftex-short-context (env parse &amp;amp;optional bound derive)
-  ;; Get about one line of useful context for the label definition at point.
+  "Get about one line of useful context for the label definition at point."
 
   (if (consp parse)
       (setq parse (if derive (cdr parse) (car parse))))
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -568,9 +568,9 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; (defun reftex-short-context (env parse &amp;amp;optional bound derive)
      "INVALID VALUE OF PARSE"))))
 
 (defun reftex-where-am-I ()
-  ;; Return the docstruct entry above point.  Actually returns a cons
-  ;; cell in which the cdr is a flag indicating if the information is
-  ;; exact (t) or approximate (nil).
+  "Return the docstruct entry above point.
+Actually returns a cons cell in which the cdr is a flag indicating
+if the information is exact (t) or approximate (nil)."
 
   (let ((docstruct (symbol-value reftex-docstruct-symbol))
         (cnt 0) rtn rtn-if-no-other
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -748,10 +748,10 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; (defun reftex-notice-new (&amp;amp;optional n force)
   )
 
 (defsubst reftex-move-to-previous-arg (&amp;amp;optional bound)
-  ;; Assuming that we are in front of a macro argument,
-  ;; move backward to the closing parenthesis of the previous argument.
-  ;; This function understands the splitting of macros over several lines
-  ;; in TeX.
+  "Assuming that we are in front of a macro argument,
+move backward to the closing parenthesis of the previous argument.
+This function understands the splitting of macros over several lines
+in TeX."
   (cond
    ;; Just to be quick:
    ((memq (preceding-char) '(?\] ?\})))
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -764,28 +764,27 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; (defsubst reftex-move-to-previous-arg (&amp;amp;optional bound)
    (t nil)))
 
 (defun reftex-what-macro-safe (which &amp;amp;optional bound)
-  ;; reftex-what-macro with special syntax table.
+  "Call `reftex-what-macro' with special syntax table."
   (reftex-with-special-syntax
    (reftex-what-macro which bound)))
 
 (defun reftex-what-macro (which &amp;amp;optional bound)
-  ;; Find out if point is within the arguments of any TeX-macro.
-  ;; The return value is either ("\\macro" . (point)) or a list of them.
-
-  ;; If WHICH is nil, immediately return nil.
-  ;; If WHICH is 1, return innermost enclosing macro.
-  ;; If WHICH is t, return list of all macros enclosing point.
-  ;; If WHICH is a list of macros, look only for those macros and return the
-  ;;    name of the first macro in this list found to enclose point.
-  ;; If the optional BOUND is an integer, bound backwards directed
-  ;;    searches to this point.  If it is nil, limit to nearest \section -
-  ;;    like statement.
-
-  ;; This function is pretty stable, but can be fooled if the text contains
-  ;; things like \macro{aa}{bb} where \macro is defined to take only one
-  ;; argument.  As RefTeX cannot know this, the string "bb" would still be
-  ;; considered an argument of macro \macro.
-
+  "Find out if point is within the arguments of any TeX-macro.
+The return value is either (\"\\macro\" . (point)) or a list of them.
+
+If WHICH is nil, immediately return nil.
+If WHICH is 1, return innermost enclosing macro.
+If WHICH is t, return list of all macros enclosing point.
+If WHICH is a list of macros, look only for those macros and return the
+  name of the first macro in this list found to enclose point.
+If the optional BOUND is an integer, bound backwards directed
+  searches to this point.  If it is nil, limit to nearest \\section -
+  like statement.
+
+This function is pretty stable, but can be fooled if the text contains
+things like \\macro{aa}{bb} where \\macro is defined to take only one
+argument.  As RefTeX cannot know this, the string \"bb\" would still be
+considered an argument of macro \\macro."
   (unless reftex-section-regexp (reftex-compile-variables))
   (catch 'exit
     (if (null which) (throw 'exit nil))
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -832,20 +831,19 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; (defun reftex-what-macro (which &amp;amp;optional bound)
         (nreverse cmd-list)))))
 
 (defun reftex-what-environment (which &amp;amp;optional bound)
-  ;; Find out if point is inside a LaTeX environment.
-  ;; The return value is (e.g.) either ("equation" . (point)) or a list of
-  ;; them.
-
-  ;; If WHICH is nil, immediately return nil.
-  ;; If WHICH is 1, return innermost enclosing environment.
-  ;; If WHICH is t, return list of all environments enclosing point.
-  ;; If WHICH is a list of environments, look only for those environments and
-  ;;   return the name of the first environment in this list found to enclose
-  ;;   point.
-
-  ;; If the optional BOUND is an integer, bound backwards directed searches to
-  ;; this point.  If it is nil, limit to nearest \section - like statement.
-
+  "Find out if point is inside a LaTeX environment.
+The return value is (e.g.) either (\"equation\" . (point)) or a list of
+them.
+
+If WHICH is nil, immediately return nil.
+If WHICH is 1, return innermost enclosing environment.
+If WHICH is t, return list of all environments enclosing point.
+If WHICH is a list of environments, look only for those environments and
+  return the name of the first environment in this list found to enclose
+  point.
+
+If the optional BOUND is an integer, bound backwards directed searches to
+this point.  If it is nil, limit to nearest \\section - like statement."
   (unless reftex-section-regexp (reftex-compile-variables))
   (catch 'exit
     (save-excursion
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -870,18 +868,17 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; (defun reftex-what-environment (which &amp;amp;optional bound)
         (nreverse env-list)))))
 
 (defun reftex-what-special-env (which &amp;amp;optional bound)
-  ;; Run the special environment parsers and return the matches.
-  ;;
-  ;; The return value is (e.g.) either ("my-parser-function" . (point))
-  ;; or a list of them.
-
-  ;; If WHICH is nil, immediately return nil.
-  ;; If WHICH is 1, return innermost enclosing environment.
-  ;; If WHICH is t, return list of all environments enclosing point.
-  ;; If WHICH is a list of environments, look only for those environments and
-  ;;   return the name of the first environment in this list found to enclose
-  ;;   point.
+  "Run the special environment parsers and return the matches.
+
+The return value is (e.g.) either (\"my-parser-function\" . (point))
+or a list of them.
 
+If WHICH is nil, immediately return nil.
+If WHICH is 1, return innermost enclosing environment.
+If WHICH is t, return list of all environments enclosing point.
+If WHICH is a list of environments, look only for those environments and
+  return the name of the first environment in this list found to enclose
+  point."
   (unless reftex-section-regexp (reftex-compile-variables))
   (catch 'exit
     (save-excursion
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -911,10 +908,10 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; (defun reftex-what-special-env (which &amp;amp;optional bound)
           (car specials))))))
 
 (defsubst reftex-move-to-next-arg (&amp;amp;optional ignore)
-  ;; Assuming that we are at the end of a macro name or a macro argument,
-  ;; move forward to the opening parenthesis of the next argument.
-  ;; This function understands the splitting of macros over several lines
-  ;; in TeX.
+  "Assuming that we are at the end of a macro name or a macro argument,
+move forward to the opening parenthesis of the next argument.
+This function understands the splitting of macros over several lines
+in TeX."
   (cond
    ;; Just to be quick:
    ((memq (following-char) '(?\[ ?\{)))
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -930,8 +927,8 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; (defun reftex-nth-arg-wrapper (key)
     (reftex-nth-arg (nth 5 entry) (nth 6 entry))))
 
 (defun reftex-nth-arg (n &amp;amp;optional opt-args)
-  ;; Return the nth following {} or [] parentheses content.
-  ;; OPT-ARGS is a list of argument numbers which are optional.
+  "Return the Nth following {} or [] parentheses content.
+OPT-ARGS is a list of argument numbers which are optional."
 
   ;; If we are sitting at a macro start, skip to end of macro name.
   (and (eq (following-char) ?\\) (skip-chars-forward "a-zA-Z*\\\\"))
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -974,8 +971,8 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; (defun reftex-move-over-touching-args ()
     (error nil)))
 
 (defun reftex-context-substring (&amp;amp;optional to-end)
-  ;; Return up to 150 chars from point
-  ;; When point is just after a { or [, limit string to matching parenthesis
+  "Return up to 150 chars from point.
+When point is just after a { or [, limit string to matching parenthesis"
   (cond
    (to-end
     ;; Environment - find next \end
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -1007,8 +1004,7 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; (defun reftex-context-substring (&amp;amp;optional to-end)
 (defvar reftex-section-numbers (make-vector reftex-max-section-depth 0))
 
 (defun reftex-init-section-numbers (&amp;amp;optional toc-entry appendix)
-  ;; Initialize the section numbers with zeros or with what is found
-  ;; in the toc entry.
+  "Initialize the section numbers with zeros or with what is found in the TOC-ENTRY."
   (let* ((level  (or (nth 5 toc-entry) -1))
          (numbers (nreverse (split-string (or (nth 6 toc-entry) "") "\\.")))
          (depth (1- (length reftex-section-numbers)))
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -1026,8 +1022,8 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; (defun reftex-init-section-numbers (&amp;amp;optional toc-entry appendix)
   (put 'reftex-section-numbers 'appendix appendix))
 
 (defun reftex-section-number (&amp;amp;optional level star)
-  ;; Return a string with the current section number.
-  ;; When LEVEL is non-nil, increase section numbers on that level.
+  "Return a string with the current section number.
+When LEVEL is non-nil, increase section numbers on that level."
   (let* ((depth (1- (length reftex-section-numbers))) idx n (string "")
          (appendix (get 'reftex-section-numbers 'appendix))
          (partspecial (and (not reftex-part-resets-chapter)
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -1073,7 +1069,7 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt; (defun reftex-section-number (&amp;amp;optional level star)
         string))))
 
 (defun reftex-roman-number (n)
-  ;; Return as a string the roman number equal to N.
+  "Return as a string the roman number equal to N."
   (let ((nrest n)
         (string "")
         (list '((1000 . "M") ( 900 . "CM") ( 500 . "D") ( 400 . "CD")
&lt;/pre&gt;</description>
    <dc:creator>Rüdiger Sonderfeld</dc:creator>
    <dc:date>2013-06-11T19:46:00</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.emacs.auctex.devel/3151">
    <title>[PATCH 2/2] Add tests for reftex.</title>
    <link>http://permalink.gmane.org/gmane.emacs.auctex.devel/3151</link>
    <description>&lt;pre&gt;* test/automated/reftex-tests.el: New file.

Signed-off-by: Rüdiger Sonderfeld &amp;lt;ruediger&amp;lt; at &amp;gt;c-plusplus.de&amp;gt;
---
 test/automated/reftex-tests.el | 200 +++++++++++++++++++++++++++++++++++++++++
 1 file changed, 200 insertions(+)
 create mode 100644 test/automated/reftex-tests.el

diff --git a/test/automated/reftex-tests.el b/test/automated/reftex-tests.el
new file mode 100644
index 0000000..5f5b008
--- /dev/null
+++ b/test/automated/reftex-tests.el
&amp;lt; at &amp;gt;&amp;lt; at &amp;gt; -0,0 +1,200 &amp;lt; at &amp;gt;&amp;lt; at &amp;gt;
+;;; reftex-tests.el --- Test suite for reftex. -*- lexical-binding: t -*-
+
+;; Copyright (C) 2013 Free Software Foundation, Inc.
+
+;; Author: Rüdiger Sonderfeld &amp;lt;ruediger&amp;lt; at &amp;gt;c-plusplus.de&amp;gt;
+;; Keywords:       internal
+;; Human-Keywords: internal
+
+;; This file is part of GNU Emacs.
+
+;; GNU Emacs is free software: you can redistribute it and/or modify
+;; it under the terms of the GNU General Public License as published by
+;; the Free Software Foundation, either version 3 of the License, or
+;; (at your option) any later version.
+
+;; GNU Emacs is distributed in the hope that it will be useful,
+;; but WITHOUT ANY WARRANTY; without even the implied warranty of
+;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+;; GNU General Public License for more details.
+
+;; You should have received a copy of the GNU General Public License
+;; along with GNU Emacs.  If not, see &amp;lt;http://www.gnu.org/licenses/&amp;gt;.
+
+;;; Code:
+
+(require 'ert)
+
+;;; reftex
+(require 'reftex)
+
+;;; reftex-parse
+(require 'reftex-parse)
+
+(ert-deftest reftex-locate-bibliography-files ()
+  "Test `reftex-locate-bibliography-files'."
+  (let ((temp-dir (make-temp-file "reftex-bib" 'dir))
+        (files '("ref1.bib" "ref2.bib"))
+        (test '(("\\addbibresource{ref1.bib}\n" . ("ref1.bib"))
+                ("\\\\addbibresource[label=x]{ref2.bib}\\n" . ("ref2.bib"))
+                ("\\begin{document}\n\\bibliographystyle{plain}\n
+\\bibliography{ref1,ref2}\n\\end{document}" . ("ref1.bib" "ref2.bib"))))
+        (reftex-bibliography-commands
+         ;; Default value: See reftex-vars.el `reftex-bibliography-commands'
+         '("bibliography" "nobibliography" "setupbibtex\\[.*?database="
+           "addbibresource")))
+    (with-temp-buffer
+      (insert "test\n")
+      (mapc
+       (lambda (file)
+        (write-region (point-min) (point-max) (expand-file-name file
+                                                                temp-dir)))
+       files))
+    (mapc
+     (lambda (data)
+       (with-temp-buffer
+         (insert (car data))
+         (let ((res (mapcar #'file-name-nondirectory
+                            (reftex-locate-bibliography-files temp-dir))))
+           (should (equal res (cdr data))))))
+     test)
+    (delete-directory temp-dir 'recursive)))
+
+(ert-deftest reftex-what-environment-test ()
+  "Test `reftex-what-environment'."
+  (with-temp-buffer
+    (insert "\\begin{equation}\n  x=y^2\n")
+    (let ((pt (point))
+          pt2)
+      (insert "\\end{equation}\n")
+      (goto-char pt)
+
+      (should (equal (reftex-what-environment 1) '("equation" . 1)))
+      (should (equal (reftex-what-environment t) '(("equation" . 1))))
+
+      (insert "\\begin{something}\nxxx")
+      (setq pt2 (point))
+      (insert "\\end{something}")
+      (goto-char pt2)
+      (should (equal (reftex-what-environment 1) `("something" . ,pt)))
+      (should (equal (reftex-what-environment t) `(("something" . ,pt)
+                                                   ("equation" . 1))))
+      (should (equal (reftex-what-environment t pt) `(("something" . ,pt))))
+      (should (equal (reftex-what-environment '("equation"))
+                     '("equation" . 1))))))
+
+(ert-deftest reftex-roman-number-test ()
+  "Test `reftex-roman-number'."
+  (let ((hindu-arabic '(1     2    4   9    14   1050))
+        (roman        '("I" "II" "IV" "IX" "XIV" "ML")))
+    (while (and hindu-arabic roman)
+      (should (string= (reftex-roman-number (car hindu-arabic))
+                       (car roman)))
+      (pop roman)
+      (pop hindu-arabic))))
+
+(ert-deftest reftex-parse-from-file-test ()
+  "Test `reftex-parse-from-file'."
+  (let* ((temp-dir (make-temp-file "reftex-parse" 'dir))
+         (tex-file (expand-file-name "test.tex" temp-dir))
+         (bib-file (expand-file-name "ref.bib" temp-dir)))
+    (with-temp-buffer
+      (insert
+"\\begin{document}
+\\section{test}\\label{sec:test}
+\\subsection{subtest}
+
+\\begin{align*}\\label{eq:foo}
+  x &amp;amp;= y^2
+\\end{align*}
+
+\\bibliographystyle{plain}
+\\bibliography{ref}
+\\end{document}")
+      (write-region (point-min) (point-max) tex-file))
+    (with-temp-buffer
+      (insert "test\n")
+      (write-region (point-min) (point-max) bib-file))
+    (let ((parsed (reftex-parse-from-file tex-file nil temp-dir)))
+      (should (equal (car parsed) `(eof ,tex-file)))
+      (pop parsed)
+      (while parsed
+        (let ((entry (pop parsed)))
+         (cond
+          ((eq (car entry) 'bib)
+           (should (string= (cadr entry) bib-file)))
+          ((eq (car entry) 'toc)) ;; ...
+          ((string= (car entry) "eq:foo"))
+          ((string= (car entry) "sec:test"))
+          ((eq (car entry) 'bof)
+           (should (string= (cadr entry) tex-file))
+           (should (null parsed)))
+          (t (should-not t)))))
+      (delete-directory temp-dir 'recursive))))
+
+;;; reftex-cite
+(require 'reftex-cite)
+
+(ert-deftest reftex-parse-bibtex-entry-test ()
+  "Test `reftex-parse-bibtex-entry'."
+  (let ((entry "&amp;lt; at &amp;gt;Book{Stallman12,
+  author =    {Richard Stallman\net al.},
+  title =        {The Emacs Editor},
+  publisher =    {GNU Press},
+  year =         2012,
+  edition =   {17th},
+  note   =      {Updated for Emacs   Version 24.2}
+}")
+        (check (function
+                (lambda (parsed)
+                  (should (string= (reftex-get-bib-field "&amp;amp;key" parsed)
+                                   "Stallman12"))
+                  (should (string= (reftex-get-bib-field "&amp;amp;type" parsed)
+                                   "book"))
+                  (should (string= (reftex-get-bib-field "author" parsed)
+                                   "Richard Stallman et al."))
+                  (should (string= (reftex-get-bib-field "title" parsed)
+                                   "The Emacs Editor"))
+                  (should (string= (reftex-get-bib-field "publisher" parsed)
+                                   "GNU Press"))
+                  (should (string= (reftex-get-bib-field "year" parsed)
+                                   "2012"))
+                  (should (string= (reftex-get-bib-field "edition" parsed)
+                                   "17th"))
+                  (should (string= (reftex-get-bib-field "note" parsed)
+                                   "Updated for Emacs Version 24.2"))))))
+    (funcall check (reftex-parse-bibtex-entry entry))
+    (with-temp-buffer
+      (insert entry)
+      (funcall check (reftex-parse-bibtex-entry nil (point-min)
+                                                (point-max))))))
+
+(ert-deftest reftex-get-bib-names-test ()
+  "Test `reftex-get-bib-names'."
+  (let ((entry (reftex-parse-bibtex-entry "&amp;lt; at &amp;gt;article{Foo123,
+   author =   {Jane Roe and\tJohn Doe  and   W. Public},
+}")))
+    (should (equal (reftex-get-bib-names "author" entry)
+                   '("Jane Roe" "John Doe" "Public"))))
+  (let ((entry (reftex-parse-bibtex-entry "&amp;lt; at &amp;gt;article{Foo123,
+   editor =   {Jane Roe and\tJohn Doe  and   W. Public},
+}")))
+    (should (equal (reftex-get-bib-names "author" entry)
+                   '("Jane Roe" "John Doe" "Public")))))
+
+(ert-deftest reftex-format-citation-test ()
+  "Test `reftex-format-citation'."
+  (let ((entry (reftex-parse-bibtex-entry
+"&amp;lt; at &amp;gt;article{Foo13,
+  author =    {Jane Roe and John Doe and Jane Q. Taxpayer},
+  title =        {Some Article},
+  journal =    {Some Journal},
+  year =         2013,
+  pages = {1--333}
+}")))
+    (should (string= (reftex-format-citation entry nil) "\\cite{Foo13}"))
+    (should (string= (reftex-format-citation entry "%l:%A:%y:%t %j %P %a")
+                     "Foo13:Jane Roe:2013:Some Article Some Journal 1 Jane Roe, John Doe \\&amp;amp; Jane Taxpayer"))))
+
+(provide 'reftex-tests)
+;;; reftex-tests.el ends here.
&lt;/pre&gt;</description>
    <dc:creator>Rüdiger Sonderfeld</dc:creator>
    <dc:date>2013-06-11T19:46:11</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.emacs.auctex.devel/3150">
    <title>Re: Hooks for LaTeX-arg-usepackage andTeX-arg-document</title>
    <link>http://permalink.gmane.org/gmane.emacs.auctex.devel/3150</link>
    <description>&lt;pre&gt;

Ah, that makes sense.  But it's not completely kept up with even in
emacs itself.  At least you can find quite some occurences of:

  (run-hook-with-args '*-hook ...)

Bye,
Tassilo
&lt;/pre&gt;</description>
    <dc:creator>Tassilo Horn</dc:creator>
    <dc:date>2013-06-10T10:38:17</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.emacs.auctex.devel/3149">
    <title>Re: Hooks for LaTeX-arg-usepackage andTeX-arg-document</title>
    <link>http://permalink.gmane.org/gmane.emacs.auctex.devel/3149</link>
    <description>&lt;pre&gt;
Variables ending in -hook contain functions called with no argument and
whose return value is discarded. All other hooks end in -functions. See
(info "(elisp) Standard Hooks")

&lt;/pre&gt;</description>
    <dc:creator>Nicolas Richard</dc:creator>
    <dc:date>2013-06-10T09:21:42</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.emacs.auctex.devel/3148">
    <title>Re: Hooks for LaTeX-arg-usepackage andTeX-arg-document</title>
    <link>http://permalink.gmane.org/gmane.emacs.auctex.devel/3148</link>
    <description>&lt;pre&gt;
Hi Mosè,


Yes, but see the comments below.


Hook variables are usually called `*-hook' (singular) or `*-functions'.
I think one uses `hook' when it's meant for users to be customized, and
`functions' when it's more some internal implementation detail.  IMO,
here it's the latter, so I'd go with `TeX-arg-document-functions' (TeX
instead of LaTeX to match the corresponding function).


Here I'd use `LaTeX-arg-usepackage-functions'.

Bye,
Tassilo


_______________________________________________
auctex-devel mailing list
auctex-devel&amp;lt; at &amp;gt;gnu.org
https://lists.gnu.org/mailman/listinfo/auctex-devel
&lt;/pre&gt;</description>
    <dc:creator>Tassilo Horn</dc:creator>
    <dc:date>2013-06-10T06:33:29</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.emacs.auctex.devel/3147">
    <title>Hooks for LaTeX-arg-usepackage and TeX-arg-document</title>
    <link>http://permalink.gmane.org/gmane.emacs.auctex.devel/3147</link>
    <description>&lt;pre&gt;Hi all,

the attached patch adds hooks for `LaTeX-arg-usepackage' and
`TeX-arg-document'.  In this way we can remove babel specific code
from `LaTeX-arg-usepackage' and add hooks for other packages, if
needed.  For example, I'm developing a file style for polyglossia
package and I'd like to add a hook for loading possible polyglossia
languages style files.  Can I go?

Bye,
Mosè
_______________________________________________
auctex-devel mailing list
auctex-devel&amp;lt; at &amp;gt;gnu.org
https://lists.gnu.org/mailman/listinfo/auctex-devel
&lt;/pre&gt;</description>
    <dc:creator>Mosè Giordano</dc:creator>
    <dc:date>2013-06-09T22:38:21</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.emacs.auctex.devel/3146">
    <title>Re: Wrap dollars around active region</title>
    <link>http://permalink.gmane.org/gmane.emacs.auctex.devel/3146</link>
    <description>&lt;pre&gt;Hi Tassilo,

2013/6/7 Tassilo Horn &amp;lt;tsdh&amp;lt; at &amp;gt;gnu.org&amp;gt;:
Eh eh

Thanks for your help, done.  Of course I did forget to add reference
to the thread in ChangeLog :-(  I added it right now.

Bye,
Mosè

_______________________________________________
auctex-devel mailing list
auctex-devel&amp;lt; at &amp;gt;gnu.org
https://lists.gnu.org/mailman/listinfo/auctex-devel
&lt;/pre&gt;</description>
    <dc:creator>Mosè Giordano</dc:creator>
    <dc:date>2013-06-07T23:32:37</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.emacs.auctex.devel/3145">
    <title>Re: Wrap dollars around active region</title>
    <link>http://permalink.gmane.org/gmane.emacs.auctex.devel/3145</link>
    <description>&lt;pre&gt;

Let's see if there's someone relying on that behavior. :-)

  http://xkcd.com/1172/


Ahh, finally. :-)

Commit, push, and have a nice weekend!

Bye,
Tassilo

_______________________________________________
auctex-devel mailing list
auctex-devel&amp;lt; at &amp;gt;gnu.org
https://lists.gnu.org/mailman/listinfo/auctex-devel
&lt;/pre&gt;</description>
    <dc:creator>Tassilo Horn</dc:creator>
    <dc:date>2013-06-07T19:13:50</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.emacs.auctex.devel/3144">
    <title>Re: Wrap dollars around active region</title>
    <link>http://permalink.gmane.org/gmane.emacs.auctex.devel/3144</link>
    <description>&lt;pre&gt;Hi Tassilo,

2013/6/7 Tassilo Horn &amp;lt;tsdh&amp;lt; at &amp;gt;gnu.org&amp;gt;:
Because that's the current behavior of `TeX-insert-dollar' :-)

The attached patch finally removes `TeX-math-close-double-dollar'.  I
changed the behavior of `TeX-insert-dollar' in the texmathp case: if
point is right between a couple of dollars and `TeX-math-electric' is
non-nil (whatever its value), another couple of dollars is inserted
and point is placed between them.  Now I agree that your alternative
is preferable ;-)

Bye,
Mosè
_______________________________________________
auctex-devel mailing list
auctex-devel&amp;lt; at &amp;gt;gnu.org
https://lists.gnu.org/mailman/listinfo/auctex-devel
&lt;/pre&gt;</description>
    <dc:creator>Mosè Giordano</dc:creator>
    <dc:date>2013-06-07T19:06:25</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.emacs.auctex.devel/3143">
    <title>Re: Wrap dollars around active region</title>
    <link>http://permalink.gmane.org/gmane.emacs.auctex.devel/3143</link>
    <description>&lt;pre&gt;

Uh, why that?  IMO, pressing $$ should insert $$|$$ with | being
(point).


Usually, (at least in my docs) there's nothing right of a $$...$$
formula (except for a newline), so I don't count keystroke 4. ;-)


Well, I consider the $$ gives $$|$ a bug, or at least unexpected
behavior.

Bye,
Tassilo

_______________________________________________
auctex-devel mailing list
auctex-devel&amp;lt; at &amp;gt;gnu.org
https://lists.gnu.org/mailman/listinfo/auctex-devel
&lt;/pre&gt;</description>
    <dc:creator>Tassilo Horn</dc:creator>
    <dc:date>2013-06-07T14:38:37</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.emacs.auctex.devel/3142">
    <title>Re: Wrap dollars around active region</title>
    <link>http://permalink.gmane.org/gmane.emacs.auctex.devel/3142</link>
    <description>&lt;pre&gt;Hi Tassilo,

2013/6/6 Tassilo Horn &amp;lt;tsdh&amp;lt; at &amp;gt;gnu.org&amp;gt;:
I didn't consider your second alternative, but I still think the first
is better or at least equivalent.  Counting the keystrokes of the
first alternative they are:
  1. press $
  2. move right
  3. enter formula
  4. press $
For the second:
  1. press $ twice, but the second pressure will insert only one dollar sign
  2. enter formula
  3. press $
  4. move right
Thus, I'm inclined to keep `TeX-math-close-double-dollar'.  That said,
I've a reason to suspect there are really few AUCTeX users writing
regularly in plain TeX, if I'm right not many people will worry about
all this :-)

I'm submitting the (hopefully) definitive patch.  If there are no
objections I'll install it.

Bye,
Mosè
_______________________________________________
auctex-devel mailing list
auctex-devel&amp;lt; at &amp;gt;gnu.org
https://lists.gnu.org/mailman/listinfo/auctex-devel
&lt;/pre&gt;</description>
    <dc:creator>Mosè Giordano</dc:creator>
    <dc:date>2013-06-07T13:57:39</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.emacs.auctex.devel/3141">
    <title>Re: Wrap dollars around active region</title>
    <link>http://permalink.gmane.org/gmane.emacs.auctex.devel/3141</link>
    <description>&lt;pre&gt;

Well, after typing the initial dollar above, the inserted text with |
being (point) is $|$.  Why should a user prefer to type &amp;lt;right&amp;gt; or C-f
to jump over the second $ instead of quickly typing $$ resulting in
$$|$$?

I mean, the alternatives are

  1. $ &amp;lt;right&amp;gt; formula $
  2. $$ formula

and the first takes 3 special key presses of 2 different keys whereas
the second only takes 2 $-key presses.  So IMHO, the first approach
seems even worse than typing $$ formula $$ without electricity.

Ok, one benefit of alternative 1 is that point is after the math
afterwards whereas it is $$|$$ in alternative 2.  But then, such
formulas are usually written on their own line, so that doesn't make a
difference.


I don't have strong opinions, I just don't like having several quite
similar features that might confuse more than help.  But if you feel
that it's important, then we'll just keep it.

Bye,
Tassilo

_______________________________________________
auctex-devel mailing list
auctex-devel&amp;lt; at &amp;gt;gnu.org
https://lists.gnu.org/mailman/listinfo/auctex-devel
&lt;/pre&gt;</description>
    <dc:creator>Tassilo Horn</dc:creator>
    <dc:date>2013-06-06T15:03:45</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.emacs.auctex.devel/3140">
    <title>Re: Wrap dollars around active region</title>
    <link>http://permalink.gmane.org/gmane.emacs.auctex.devel/3140</link>
    <description>&lt;pre&gt;Hi David,

2013/6/6 David Kastrup &amp;lt;dak&amp;lt; at &amp;gt;gnu.org&amp;gt;:
In my code the regex search is bound from point to mark, I don't
believe it reaches the end of the buffer.  To verify this I carried
out some tests on a ~200 MiB file created with
    $ yes &amp;gt; verylargefile
It takes less than a second (`benchmark-run' actually says less than a
millisecond) to perform the regex search "[^z-a]*" when the search is
restricted to some thousands of characters, while it takes ~15 seconds
when the search is performed up to the end of the buffer.

BTW, rough tests with `benchmark-run' also say "[^z-a]*" is about
twice as fast as "\(?:.\|\n\)*", I suppose because "\(?:.\|\n\)*" has
to check two alternatives.

I hope no one will ever use `TeX-insert-dollar' on a region longer
than some dozens of characters, there should be no performance issues
whatever the length of the whole buffer.

Bye,
Mosè

_______________________________________________
auctex-devel mailing list
auctex-devel&amp;lt; at &amp;gt;gnu.org
https://lists.gnu.org/mailman/listinfo/auctex-devel
&lt;/pre&gt;</description>
    <dc:creator>Mosè Giordano</dc:creator>
    <dc:date>2013-06-06T13:25:05</dc:date>
  </item>
  <item rdf:about="http://permalink.gmane.org/gmane.emacs.auctex.devel/3139">
    <title>Re: Wrap dollars around active region</title>
    <link>http://permalink.gmane.org/gmane.emacs.auctex.devel/3139</link>
    <description>&lt;pre&gt;Hi Tassilo,

2013/6/6 Tassilo Horn &amp;lt;tsdh&amp;lt; at &amp;gt;gnu.org&amp;gt;:
No need of `C-q $' at all.  This is the `C-h l' log of the keystrokes
needed to write that:
    $ &amp;lt;right&amp;gt; SPC a + b = c SPC $
`(texmathp)' returns t before the third dollar and a single dollar is
inserted when `TeX-math-close-double-dollar' is nil, a couple of
dollars otherwise.  Can I keep `TeX-math-close-double-dollar'?

Yes, of course that was the error :-)

I'll probably mention in the manual the possibility to set it using hooks.

Ok.  I'll rename it.

Ok, thanks.

Bye,
Mosè

_______________________________________________
auctex-devel mailing list
auctex-devel&amp;lt; at &amp;gt;gnu.org
https://lists.gnu.org/mailman/listinfo/auctex-devel
&lt;/pre&gt;</description>
    <dc:creator>Mosè Giordano</dc:creator>
    <dc:date>2013-06-06T12:44:33</dc:date>
  </item>
  <textinput rdf:about="http://search.gmane.org/?group=$group=gmane.emacs.auctex.devel">
    <title>Search Engine</title>
    <description>Search the mailing list at Gmane</description>
    <name>query</name>
    <link>http://search.gmane.org/?group=$group=gmane.emacs.auctex.devel</link>
  </textinput>
</rdf:RDF>
