changeset 377:bf4c9c4190b0

CheckTranslation: render nonexistent pagelinks in RED
author Thomas Waldmann <tw AT waldmann-edv DOT de>
date Sun, 19 Apr 2009 16:04:24 +0200
parents 2425d9e491dc
children 929a932ea415
files data/plugin/action/CheckTranslation.py
diffstat 1 files changed, 8 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/data/plugin/action/CheckTranslation.py	Sun Apr 19 15:39:00 2009 +0200
+++ b/data/plugin/action/CheckTranslation.py	Sun Apr 19 16:04:24 2009 +0200
@@ -18,7 +18,13 @@
 from MoinMoin.util.dataset import TupleDataset, Column
 from MoinMoin.widget.browser import DataBrowserWidget
 
-            
+# for this action's output, we want everything RED that does not exist
+css_style_defs = """
+<style type="text/css">
+a.nonexistent:link, a.nonexistent:visited, a.nonexistent:hover { color: red; }
+</style>
+"""
+
 def execute(pagename, request):
     _ = request.getText
 
@@ -94,6 +100,7 @@
 
     title = _("Checking translation '%s' for page set '%s'") % (lang, pageset_name)
     request.theme.send_title(title, page=request.page, pagename=pagename)
+    request.write(request.formatter.rawHTML(css_style_defs))
     request.write(request.formatter.startContent("content"))
     request.write(lang_selector)
     request.write(pageset_selector)