]> git.eshelyaron.com Git - emacs.git/commitdiff
Make tutorial read-only
authorPhillip Lord <phillip.lord@russet.org.uk>
Mon, 8 May 2017 08:23:35 +0000 (09:23 +0100)
committerPhillip Lord <phillip.lord@russet.org.uk>
Mon, 8 May 2017 08:23:35 +0000 (09:23 +0100)
etc/tutorials-org/tutorial.org
lisp/tutorial-org.el

index 72533738bba87c715068c2eb07459c279ab50dd3..b179f454db1c9ed51ec05a7eb3d2eca710f6ec11 100644 (file)
@@ -184,11 +184,6 @@ In this section, we consider how Emacs allows you to view and to change text
 within Emacs. This is mostly straight-forward, but Emacs gives you a some
 extra options useful for changing text rapidly.
 
-** This is a copy!
-
-If you wish to practice on this tutorial, do not worry, you can change it
-freely as it is just a copy.
-
 ** Editing Text
 
 Changing text happens in Emacs as with most other applications. A blinking
index e74e7f57997554e8a92f56c158cd2f62b92c4540..bca3e349d57f10f3e6244605f5527097fe632d9d 100644 (file)
@@ -31,7 +31,8 @@
 (define-derived-mode tutorial-org-mode org-mode "Tutor"
   "A mode for displaying tutorials."
   (show-all)
-  (setq-local org-hide-emphasis-markers t))
+  (setq-local org-hide-emphasis-markers t)
+  (setq buffer-read-only t))
 
 (defun tutorial-org--display-buffer (tutorial-buffer-name)
   (when-let ((tutorial-buffer