--- share/moin/htdocs/modern/css/screen.css.orig	Thu Apr  5 18:26:32 2007
+++ share/moin/htdocs/modern/css/screen.css	Thu Apr  5 18:26:37 2007
@@ -251,6 +251,55 @@
     background: #81BBF2; /* url(../img/tab-selected.png) repeat-x; */
 }
 
+
+#langbar {
+    display: block;
+    margin: 0;
+    padding: 0 10px;
+    font-size: 0.82em;
+    zoom: 1; /* for avoiding a gap between navibar and pageline on IE */
+}
+
+#langbar li {
+    float: right;
+    display: inline;
+    margin: 0 2px;
+    padding: 2px 5px;
+    border: 1px solid #9C9C9C;
+    border-bottom: none;
+    white-space: nowrap;
+}
+
+*[dir="rtl"] #langbar li {
+    float: left;
+}
+
+#langbar li.wikilink {
+    background: white; /*url(../img/tab-wiki.png) repeat-x;*/
+}
+
+#langbar li.userlink {
+    background: #E6EAF0; /*url(../img/tab-user.png) repeat-x;*/
+}
+
+#langbar a, #langbar a:visited {
+    color: black;
+    text-decoration: none;    
+}
+
+#langbar li.current a {
+    font-weight: bold;
+}
+
+#langbar li:hover {
+    background: #CCCCCC;
+}
+
+#langbar li.current, #langbar li.current:hover {
+    background: #81BBF2; /* url(../img/tab-selected.png) repeat-x; */
+}
+
+
 #pageline {
     clear: both;
     margin: 0;
--- lib/python2.4/site-packages/MoinMoin/theme/modern.py.orig	Thu Apr  5 18:28:26 2007
+++ lib/python2.4/site-packages/MoinMoin/theme/modern.py	Thu Apr  5 18:27:59 2007
@@ -34,6 +34,7 @@
             u'</div>',
             self.trail(d),
             self.navibar(d),
+            self.langbar(d),
             #u'<hr id="pageline">',
             u'<div id="pageline"><hr style="display:none;"></div>',
             self.msg(d),
@@ -47,6 +48,56 @@
             self.startPage(),
         ]
         return u'\n'.join(html)
+
+    def langbar(self, d):
+        """ Create language panel """
+	from MoinMoin.Page import Page
+        from MoinMoin import i18n
+        from MoinMoin.i18n import _unformatted_text_cache
+        from types import *
+        _ = self.request.getText
+
+        page_title = d['page_name']
+        lang_links = []
+        request = self.request
+        for l in i18n.languages:
+                trans = i18n.getText(page_title, self.request, l, False)
+                if trans == page_title:
+                        lang = Page(self.request, page_title).language
+                        if lang is None:
+                                # this is a hack: the page should always have a lang, and the default should not be .fr
+                                lang = 'fr'
+                        ## costly hideous operation to find the root page name in english
+                        global _unformatted_text_cache
+                        if not lang in _unformatted_text_cache:
+                                (texts, unformatted) = i18n.loadLanguage(request, lang)
+                                # XXX add error handling
+                                _unformatted_text_cache[lang] = unformatted
+                        for k, v in _unformatted_text_cache[lang].iteritems():
+                                if v == page_title:
+                                        trans = i18n.getText(k, self.request, l, False)
+                                        en = i18n.getText(k, self.request, 'en', False)
+                                        if trans == en and l != 'en':
+                                                trans = page_title # false translation
+                else:
+                        en = i18n.getText(page_title, self.request, 'en', False)
+                        if trans == en and l != 'en':
+                                trans = page_title # false translation
+
+                if trans != page_title:
+                        translated_page = Page(self.request, trans)
+                        if translated_page.exists():
+                                lang_links.append(translated_page.link_to(request, l))
+
+        if lang_links:
+                html = [
+			u'<ul id="langbar"><li>',
+                        u'</li>\n<li>'.join(lang_links),
+                        u'</li></ul>'
+                        ]
+                return u'\n'.join(html)
+        else:
+                return u''
 
     def editorheader(self, d, **kw):
         """ Assemble wiki header for editor
