Commits

Georg Brandl committed 90ae82c Merge

merge with trunk

Comments (0)

Files changed (9)

 Release 0.6.6 (in development)
 ==============================
 
+* #387: Fix the display of search results in ``dirhtml`` output.
+
+* #376: In autodoc, fix display of parameter defaults containing
+  backslashes.
+
+* #370: Fix handling of complex list item labels in LaTeX output.
+
+* #374: Make the ``doctest_path`` config value of the doctest
+  extension actually work.
+
 * Fix the handling of multiple toctrees when creating the global
   TOC for the ``toctree()`` template function.
 
    :confval:`language`), relative to the source directory.  The directories on
    this path are searched by the standard :mod:`gettext` module for a text
    domain of ``sphinx``; so if you add the directory :file:`./locale` to this
-   settting, the message catalogs must be in
+   settting, the message catalogs (compiled from ``.po`` format using
+   :program:`msgfmt`) must be in
    :file:`./locale/{language}/LC_MESSAGES/sphinx.mo`.
 
    The default is ``[]``.

doc/ext/tutorial.rst

        def run(self):
            env = self.state.document.settings.env
 
-           targetid = "todo-%s" % env.new_serialno('todo')
+           targetid = "todo-%d" % env.new_serialno('todo')
            targetnode = nodes.target('', '', ids=[targetid])
 
            ad = make_admonition(todo, self.name, [_('Todo')], self.options,

sphinx/ext/autodoc.py

                 argspec = inspect.getargspec(self.object.__init__)
                 if argspec[0]:
                     del argspec[0][0]
-        return inspect.formatargspec(*argspec)
+        args = inspect.formatargspec(*argspec)
+        # escape backslashes for reST
+        args = args.replace('\\', '\\\\')
+        return args
 
     def document_members(self, all_members=False):
         pass

sphinx/ext/doctest.py

         # that code nevertheless, we monkey-patch the "compile" it uses.
         doctest.compile = self.compile
 
+        sys.path[0:0] = self.config.doctest_path
+
         self.type = 'single'
 
         self.total_failures = 0
         if self.total_failures or self.setup_failures:
             self.app.statuscode = 1
 
-        sys.path[0:0] = self.config.doctest_path
-
     def write(self, build_docnames, updated_docnames, method='update'):
         if build_docnames is None:
             build_docnames = sorted(self.env.all_docs)

sphinx/texinputs/sphinx.sty

 % Include hyperref last.
 \RequirePackage[colorlinks,breaklinks,
                 linkcolor=InnerLinkColor,filecolor=OuterLinkColor,
-                menucolor=OuterLinkColor,urlcolor=OuterLinkColor]{hyperref}
+                menucolor=OuterLinkColor,urlcolor=OuterLinkColor,
+                citecolor=InnerLinkColor]{hyperref}
 
 % From docutils.writers.latex2e
 \providecommand{\DUspan}[2]{%

sphinx/themes/basic/layout.html

 {%- set reldelim2 = reldelim2 is not defined and ' |' or reldelim2 %}
 {%- set render_sidebar = (not embedded) and (not theme_nosidebar|tobool) and
                          (not sidebars == []) %}
+{%- set url_root = pathto('', 1) %}
+{%- if url_root == '#' %}{% set url_root = '' %}{% endif %}
 
 {%- macro relbar() %}
     <div class="related">
     {%- if not embedded %}
     <script type="text/javascript">
       var DOCUMENTATION_OPTIONS = {
-        URL_ROOT:    '{{ pathto("", 1) }}',
+        URL_ROOT:    '{{ url_root }}',
         VERSION:     '{{ release|e }}',
         COLLAPSE_INDEX: false,
         FILE_SUFFIX: '{{ file_suffix }}',

sphinx/themes/basic/static/searchtools.js

             displayNextItem();
           });
         } else if (DOCUMENTATION_OPTIONS.HAS_SOURCE) {
-          $.get('_sources/' + item[0] + '.txt', function(data) {
+          $.get(DOCUMENTATION_OPTIONS.URL_ROOT + '_sources/' +
+                item[0] + '.txt', function(data) {
             listItem.append($.makeSearchSummary(data, searchterms, hlterms));
             Search.output.append(listItem);
             listItem.slideDown(5, function() {

sphinx/writers/latex.py

         pass
 
     def visit_term(self, node):
-        ctx = '] \\leavevmode'
+        ctx = '}] \\leavevmode'
         if node.has_key('ids') and node['ids']:
             ctx += self.hypertarget(node['ids'][0])
-        self.body.append('\\item[')
+        self.body.append('\\item[{')
         self.context.append(ctx)
     def depart_term(self, node):
         self.body.append(self.context.pop())