diff options
author | Michal Nazarewicz <mina86@mina86.com> | 2014-11-16 17:38:15 +0100 |
---|---|---|
committer | Michal Nazarewicz <mina86@mina86.com> | 2014-11-18 00:46:50 +0100 |
commit | b8104090075eb28dd6680cc9f8b0a49674ca369a (patch) | |
tree | 6a4cb090a7ac881eb370edc8ac53938f3d291329 /test | |
parent | 07556b0299b33b52cf352581bfdd6554819eea30 (diff) | |
download | emacs-b8104090075eb28dd6680cc9f8b0a49674ca369a.tar.gz |
tildify.el: introduce a `tildify-space-string' variable
* textmodes/tildify.el (tildify-space-string): New variable for
specifying representation of a hard space -- a no-break space by
default. Being a buffer-local variable it is much easier to
handle than `tildify-string-alist' that has been used so far. It
also works better with derived modes.
(tildify-string-alist): Mark as obsolete.
* textmodes/tex-mode.el (tex-common-initialization): Set
`tildify-space-string' variable in all variants of TeX mode since
`tildify-string-alist' is now empty by default.
* nxml/nxml-mode.el (nxml-mode): Ditto in `nxml-mode'. If
encoding supports it use no-break space instead of character
entity; this changes previous default which used a numeric
reference.
* textmodes/sgml-mode.el (sgml-mode): ditto in `sgml-mode'. If
encoding does not support no-break space, use numeric reference;
this changes previous default which used named entity (“ ”)
in HTML mode.
Diffstat (limited to 'test')
-rw-r--r-- | test/ChangeLog | 5 | ||||
-rw-r--r-- | test/automated/tildify-tests.el | 4 |
2 files changed, 7 insertions, 2 deletions
diff --git a/test/ChangeLog b/test/ChangeLog index 2dfd5151f09..1c739d456ac 100644 --- a/test/ChangeLog +++ b/test/ChangeLog @@ -1,3 +1,8 @@ +2014-11-17 Michal Nazarewicz <mina86@mina86.com> + + * automated/tildify-tests.el (tildify-test-html, tildify-test-xml): + HTML and XML now use no-break space as hard space. Update tests. + 2014-11-17 Glenn Morris <rgm@gnu.org> * automated/occur-tests.el (occur-test-case, occur-test-create): diff --git a/test/automated/tildify-tests.el b/test/automated/tildify-tests.el index 53c2e620195..e532cf00686 100644 --- a/test/automated/tildify-tests.el +++ b/test/automated/tildify-tests.el @@ -73,7 +73,7 @@ after `tildify-buffer' is run." (ert-deftest tildify-test-html () "Tests tildification in an HTML document" (let* ((sentence (tildify-test--example-sentence " ")) - (with-nbsp (tildify-test--example-sentence " "))) + (with-nbsp (tildify-test--example-sentence " "))) (tildify-test--test '(html-mode sgml-mode) (tildify-test--example-html sentence sentence) (tildify-test--example-html sentence with-nbsp)))) @@ -81,7 +81,7 @@ after `tildify-buffer' is run." (ert-deftest tildify-test-xml () "Tests tildification in an XML document" (let* ((sentence (tildify-test--example-sentence " ")) - (with-nbsp (tildify-test--example-sentence " "))) + (with-nbsp (tildify-test--example-sentence " "))) (tildify-test--test '(nxml-mode) (tildify-test--example-html sentence sentence t) (tildify-test--example-html sentence with-nbsp t)))) |