[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [AUCTeX-devel] paragraph-start in modes other than latex
From: |
Ikumi Keita |
Subject: |
Re: [AUCTeX-devel] paragraph-start in modes other than latex |
Date: |
Mon, 03 Apr 2017 23:50:38 +0900 |
Hi Marcin and Arash,
Thank you very much for your replies! Taking into account the two's
comments, I suppose that a reasonable change for plain-tex.el would be
to remove anchor "^", to leave bunch of macros, not to add "\b" and
remove "\[" and "\]".
If this is appropriate, `paragraph-separate' of plain-tex.el needs no
modification.
Regarding texinfo, I realized that
>> ----------------------------------------------------------------------
>> (set (make-local-variable 'paragraph-start)
>> (concat "\b\\|address@hidden \n]\\|" paragraph-start))
>> ----------------------------------------------------------------------
is just copied from Emacs' standard texinfo.el and almost the same
except the anchor "^".
Here is my tentative proposal:
diff -r 32ce25988565 plain-tex.el
--- a/plain-tex.el Sat Feb 04 18:21:44 2017 +0900
+++ b/plain-tex.el Mon Apr 03 23:46:44 2017 +0900
@@ -152,19 +152,18 @@
(set (make-local-variable 'TeX-style-hook-dialect) plain-TeX-dialect)
(setq paragraph-start
(concat
- "\\(^[ \t]*$"
+ "\\([ \t]*$"
"\\|" (regexp-quote TeX-esc) "par\\|"
- "^[ \t]*"
+ "[ \t]*"
(regexp-quote TeX-esc)
"\\("
"begin\\|end\\|part\\|chapter\\|"
"section\\|subsection\\|subsubsection\\|"
"paragraph\\|include\\|includeonly\\|"
- "tableofcontents\\|appendix\\|label\\|caption\\|"
- "\\[\\|\\]" ; display math delimitors
+ "tableofcontents\\|appendix\\|label\\|caption"
"\\)"
"\\|"
- "^[ \t]*\\$\\$" ; display math delimitor
+ "[ \t]*\\$\\$" ; display math delimitor
"\\)" ))
(setq paragraph-separate
(concat
diff -r 32ce25988565 tex-info.el
--- a/tex-info.el Sat Feb 04 18:21:44 2017 +0900
+++ b/tex-info.el Mon Apr 03 23:46:44 2017 +0900
@@ -618,9 +618,9 @@
(set (make-local-variable 'require-final-newline) t)
(set (make-local-variable 'indent-tabs-mode) nil)
(set (make-local-variable 'paragraph-separate)
- (concat "\b\\|address@hidden \n]\\|" paragraph-separate))
+ (concat "\b\\|@[a-zA-Z]*[ \n]\\|" paragraph-separate))
(set (make-local-variable 'paragraph-start)
- (concat "\b\\|address@hidden \n]\\|" paragraph-start))
+ (concat "\b\\|@[a-zA-Z]*[ \n]\\|" paragraph-start))
(set (make-local-variable 'fill-column) 72)
(set (make-local-variable 'comment-start) "@c ")
(set (make-local-variable 'comment-start-skip) "@c +\\|@comment +")
Bye,
Ikumi Keita