def _method_to_html(self, uid): """ Dodgy redirect hack. """ str = "<html><head>\n" '<meta http-equiv=refresh content="0; url=%s#%s">\n' "</head></html>\n" str = str % (self._uid_to_uri(uid.parent()), uid.shortname()) return str
def _uid_to_uri(self, uid): if uid.is_module() or uid.is_class(): return uid.name() + ".html" parent = uid.parent() if parent is None: return uid.name() + ".html" return parent.name() + ".html#" + uid.shortname()