diff --git a/ChangeLog b/ChangeLog
index 645438eef1ddddbd45c43d69a52bc34a9a1419d0..3ce23af0a86c0fb056f536e2acbda62fb275deb9 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+2014-11-30  Benno Schulenberg  <bensberg@justemail.net>
+	* doc/syntax/spec.nanorc: Colorize %pretrans and %posttrans fully.
+	Original patch from Savannah patch #8573 by Daniel Vrátil.
+
 2014-09-21  Benno Schulenberg  <bensberg@justemail.net>
 	* doc/syntax/{perl,python,ruby,sh}.nanorc: Recognize also header
 	lines of the form "#!/usr/bin/env thing" besides "#!/bin/thing".
diff --git a/doc/syntax/spec.nanorc b/doc/syntax/spec.nanorc
index a0fff88ad915fb1eeff00639391552cb78b4f762..47de211aa4f6d9c3a199efb6b9d45324a3568198 100644
--- a/doc/syntax/spec.nanorc
+++ b/doc/syntax/spec.nanorc
@@ -24,8 +24,8 @@ color yellow start="%__" end="\ "
 color magenta start="%\{" end="\}"
 color yellow start="%\{__" end="\}"
 # Sections.
-color red "^%(build$|changelog|check$|clean$|description|files|install$|package|pre|prep$|preun|post|postun)"
-color red "^%(trigger|triggerin|triggerpostun|triggerun|verifyscript)"
+color red "^%(build$|changelog|check$|clean$|description|files|install$|package|pre|prep$|pretrans|preun)"
+color red "^%(post|posttrans|postun|trigger|triggerin|triggerpostun|triggerun|verifyscript)"
 # Conditionals and defines.
 color brightred "%(if|else|endif|define|global|undefine)"