forked from pool/emacs-auctex
Further changes for dinbrief.patch
OBS-URL: https://build.opensuse.org/package/show/editors/emacs-auctex?expand=0&rev=68
This commit is contained in:
parent
3af79b47b7
commit
040cd9169d
@ -3,11 +3,9 @@ to dinbrief class.
|
|||||||
|
|
||||||
Signed-off-by: Werner Fink <werner@suse.de>
|
Signed-off-by: Werner Fink <werner@suse.de>
|
||||||
---
|
---
|
||||||
style/dinbrief.el | 46 +++++++++++++++++++++++++++++++++++-----------
|
style/dinbrief.el | 67 +++++++++++++++++++++++++++++++++++++++---------------
|
||||||
1 file changed, 35 insertions(+), 11 deletions(-)
|
1 file changed, 49 insertions(+), 18 deletions(-)
|
||||||
|
|
||||||
diff --git a/style/dinbrief.el b/style/dinbrief.el
|
|
||||||
index c3108466..bdfaba47 100644
|
|
||||||
--- style/dinbrief.el
|
--- style/dinbrief.el
|
||||||
+++ style/dinbrief.el
|
+++ style/dinbrief.el
|
||||||
@@ -32,14 +32,26 @@
|
@@ -32,14 +32,26 @@
|
||||||
@ -23,7 +21,7 @@ index c3108466..bdfaba47 100644
|
|||||||
+ '("10pt" "11pt" "12pt" "norm" "a4paper" "a5paper" "b5paper"
|
+ '("10pt" "11pt" "12pt" "norm" "a4paper" "a5paper" "b5paper"
|
||||||
+ "letterpaper" "legalpaper" "executivepaper" "twoside"
|
+ "letterpaper" "legalpaper" "executivepaper" "twoside"
|
||||||
+ "addresshigh" "addressstd" "onecolumn" "twocolumn")
|
+ "addresshigh" "addressstd" "onecolumn" "twocolumn")
|
||||||
+ "Package options for the letter class.")
|
+ "Class options for the dinbrief class.")
|
||||||
+
|
+
|
||||||
(TeX-add-style-hook
|
(TeX-add-style-hook
|
||||||
"dinbrief"
|
"dinbrief"
|
||||||
@ -39,7 +37,7 @@ index c3108466..bdfaba47 100644
|
|||||||
(TeX-add-symbols
|
(TeX-add-symbols
|
||||||
'("address" "Absender")
|
'("address" "Absender")
|
||||||
'("postremark" "Postvermerk")
|
'("postremark" "Postvermerk")
|
||||||
@@ -61,7 +73,22 @@
|
@@ -61,12 +73,28 @@
|
||||||
'("backaddress" "Retouradresse")
|
'("backaddress" "Retouradresse")
|
||||||
'("signature" "Unterschrift")
|
'("signature" "Unterschrift")
|
||||||
'("opening" "Anrede")
|
'("opening" "Anrede")
|
||||||
@ -63,7 +61,14 @@ index c3108466..bdfaba47 100644
|
|||||||
TeX-dialect)
|
TeX-dialect)
|
||||||
|
|
||||||
(defmacro LaTeX-dinbrief-insert (&rest args)
|
(defmacro LaTeX-dinbrief-insert (&rest args)
|
||||||
@@ -77,17 +104,14 @@
|
"Insert text ignoring active markers."
|
||||||
|
- `(progn (if mark-active (deactivate-mark))
|
||||||
|
+ `(progn
|
||||||
|
+ (if (TeX-active-mark) (deactivate-mark))
|
||||||
|
(insert ,@args)))
|
||||||
|
|
||||||
|
(defun LaTeX-dinbrief-style ()
|
||||||
|
@@ -77,17 +105,14 @@
|
||||||
(beginning-of-line 1))
|
(beginning-of-line 1))
|
||||||
(open-line 2)
|
(open-line 2)
|
||||||
(indent-relative-first-indent-point)
|
(indent-relative-first-indent-point)
|
||||||
@ -85,7 +90,42 @@ index c3108466..bdfaba47 100644
|
|||||||
|
|
||||||
(defun LaTeX-dinbrief-env-recipient (environment)
|
(defun LaTeX-dinbrief-env-recipient (environment)
|
||||||
"Insert ENVIRONMENT and prompt for recipient and address."
|
"Insert ENVIRONMENT and prompt for recipient and address."
|
||||||
@@ -246,7 +270,7 @@
|
@@ -118,8 +143,10 @@
|
||||||
|
(newline-and-indent)
|
||||||
|
(if (not (zerop (length retouradr)))
|
||||||
|
(progn
|
||||||
|
- (if mark-active (deactivate-mark))
|
||||||
|
- (LaTeX-dinbrief-insert TeX-esc "backaddress" TeX-grop retouradr TeX-grcl)
|
||||||
|
+ (if (TeX-active-mark) (deactivate-mark))
|
||||||
|
+ (LaTeX-dinbrief-insert TeX-esc
|
||||||
|
+ "backaddress"
|
||||||
|
+ TeX-grop retouradr TeX-grcl)
|
||||||
|
(newline-and-indent)))))
|
||||||
|
(LaTeX-dinbrief-insert TeX-esc "enabledraftstandard")
|
||||||
|
(newline-and-indent)
|
||||||
|
@@ -205,8 +232,8 @@
|
||||||
|
"Read and write the senders address."
|
||||||
|
(interactive)
|
||||||
|
(let ((name (TeX-read-string "Absender: " (user-full-name)))
|
||||||
|
- (str (TeX-read-string "Meine Strasse: "))
|
||||||
|
- (ort (TeX-read-string "Mein Wohnort: ")))
|
||||||
|
+ (str (TeX-read-string "Meine Strasse: "))
|
||||||
|
+ (ort (TeX-read-string "Mein Wohnort: ")))
|
||||||
|
(if (not (zerop (length name)))
|
||||||
|
(progn
|
||||||
|
(goto-char (point-min)) ; insert before \end{document}
|
||||||
|
@@ -231,8 +258,8 @@
|
||||||
|
(defun LaTeX-dinbrief-recipient ()
|
||||||
|
"Read and return the recipient address."
|
||||||
|
(interactive)
|
||||||
|
- (let ((str (TeX-read-string "Wohnhaft in Strasse: "))
|
||||||
|
- (ort (TeX-read-string "Aus der Ortschaft: ")))
|
||||||
|
+ (let ((str (TeX-read-string "Wohnhaft in Strasse: "))
|
||||||
|
+ (ort (TeX-read-string "Aus der Ortschaft: ")))
|
||||||
|
(if (not (zerop (length str)))
|
||||||
|
(if (not (zerop (length ort)))
|
||||||
|
(concat str " " TeX-esc TeX-esc " " ort)
|
||||||
|
@@ -246,7 +273,7 @@
|
||||||
(let ((ctime-string (current-time-string))
|
(let ((ctime-string (current-time-string))
|
||||||
(month-alist '(("Jan" . "Januar")
|
(month-alist '(("Jan" . "Januar")
|
||||||
("Feb" . "Februar")
|
("Feb" . "Februar")
|
||||||
@ -94,5 +134,12 @@ index c3108466..bdfaba47 100644
|
|||||||
("Apr" . "April")
|
("Apr" . "April")
|
||||||
("May" . "Mai")
|
("May" . "Mai")
|
||||||
("Jun" . "Juni")
|
("Jun" . "Juni")
|
||||||
--
|
@@ -270,4 +297,8 @@
|
||||||
2.43.0
|
(setq day (concat "0" day)))))
|
||||||
|
(format "%s, den %s. %s %s" place day month year))))
|
||||||
|
|
||||||
|
+;; Local Variables:
|
||||||
|
+;; coding: utf-8-unix
|
||||||
|
+;; End:
|
||||||
|
+
|
||||||
|
;;; dinbrief.el ends here
|
||||||
|
@ -1,3 +1,8 @@
|
|||||||
|
-------------------------------------------------------------------
|
||||||
|
Thu May 16 13:27:12 UTC 2024 - Dr. Werner Fink <werner@suse.de>
|
||||||
|
|
||||||
|
- Merge changes from upstream for patch dinbrief.patch
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Thu May 16 11:13:22 UTC 2024 - Dr. Werner Fink <werner@suse.de>
|
Thu May 16 11:13:22 UTC 2024 - Dr. Werner Fink <werner@suse.de>
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user