diff options
| author | Daniel Mendler <mail@daniel-mendler.de> | 2023-01-20 19:19:07 +0100 |
|---|---|---|
| committer | Daniel Mendler <mail@daniel-mendler.de> | 2023-01-20 19:28:38 +0100 |
| commit | adcbf00d7740e44ea997c06ce89473b5824674d8 (patch) | |
| tree | 9eee6872bb9e5cd120c0118fad1ea92d113cf1f2 /compat-28.el | |
| parent | 5988ede6867fc9e85bf9b0064b709676e68b0e2b (diff) | |
compat-29: Add substitute-quotes
Diffstat (limited to 'compat-28.el')
| -rw-r--r-- | compat-28.el | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/compat-28.el b/compat-28.el index 953ce2e..a4b494d 100644 --- a/compat-28.el +++ b/compat-28.el @@ -783,5 +783,23 @@ are 30 days long." (* (or (decoded-time-month time) 0) 60 60 24 30) (* (or (decoded-time-year time) 0) 60 60 24 365))) +;;;; Defined in doc.c + +(compat-defun text-quoting-style () ;; <compat-tests:text-quoting-style> + "Return the current effective text quoting style. +If the variable `text-quoting-style' is `grave', `straight' or +`curve', just return that value. If it is nil (the default), return +`grave' if curved quotes cannot be displayed (for instance, on a +terminal with no support for these characters), otherwise return +`quote'. Any other value is treated as `grave'. + +Note that in contrast to the variable `text-quoting-style', this +function will never return nil." + (cond + ((memq text-quoting-style '(grave straight curve)) + text-quoting-style) + ((not text-quoting-style) 'grave) + (t 'curve))) + (provide 'compat-28) ;;; compat-28.el ends here |
