#
# CommCareHQ documentation build configuration file, created by
# sphinx-quickstart on Wed Sep  3 09:42:11 2014.
#
# This file is execfile()d with the current directory set to its containing dir.
#
# Note that not all possible configuration values are present in this
# autogenerated file.
#
# All configuration values have a default; values that are commented out
# serve to show the default.

import django
import sys, os
from mock import MagicMock
import sphinx_rtd_theme
from recommonmark.parser import CommonMarkParser

sys.path.insert(0, os.path.abspath('..'))
from manage import init_hq_python_path

init_hq_python_path()
os.environ.setdefault("DJANGO_SETTINGS_MODULE", "settings")
django.setup()

# -- Custom configuration -----------------------------------------------------

# mock out stubborn modules that are hard to pip install
# https://docs.readthedocs.org/en/latest/faq.html#i-get-import-errors-on-libraries-that-depend-on-c-modules
MOCK_MODULES = ["PIL.Image", "PIL"]
sys.modules.update((mod_name, MagicMock()) for mod_name in MOCK_MODULES)


# Support including markdown files in the documentation
source_parsers = {
    '.md': CommonMarkParser,
}

# The suffix of source filenames.
source_suffix = ['.rst', '.md']


# -- General configuration -----------------------------------------------------

# If your documentation needs a minimal Sphinx version, state it here.
#needs_sphinx = '1.0'

# Add any Sphinx extension module names here, as strings. They can be extensions
# coming with Sphinx (named 'sphinx.ext.*') or your custom ones.
extensions = ['sphinx.ext.autodoc', 'sphinx.ext.viewcode', 'sphinxcontrib_django']

# Add any paths that contain templates here, relative to this directory.
templates_path = ['_templates']

# The master toctree document.
master_doc = 'index'

# General information about the project.
project = 'CommCareHQ'
copyright = '2014, Dimagi'

version = '1.0'
release = '1.0'

# List of patterns, relative to source directory, that match files and
# directories to ignore when looking for source files.
exclude_patterns = ['_build']

# The name of the Pygments (syntax highlighting) style to use.
pygments_style = 'sphinx'

# -- Options for HTML output ---------------------------------------------------

# The theme to use for HTML and HTML Help pages.  See the documentation for
# a list of builtin themes.
#  html_theme = 'default'
html_theme = "sphinx_rtd_theme"

# Add any paths that contain custom themes here, relative to this directory.
#html_theme_path = []
html_theme_path = [sphinx_rtd_theme.get_html_theme_path()]

# Output file base name for HTML help builder.
htmlhelp_basename = 'CommCareHQdoc'


# -- Options for LaTeX output --------------------------------------------------

latex_elements = {
}

# Grouping the document tree into LaTeX files. List of tuples
# (source start file, target name, title, author, documentclass [howto/manual]).
latex_documents = [
  ('index', 'CommCareHQ.tex', 'CommCareHQ Documentation',
   'Dimagi', 'manual'),
]

# -- Options for manual page output --------------------------------------------

# One entry per manual page. List of tuples
# (source start file, name, description, authors, manual section).
man_pages = [
    ('index', 'commcarehq', 'CommCareHQ Documentation',
     ['Dimagi'], 1)
]

# -- Options for Texinfo output ------------------------------------------------

# Grouping the document tree into Texinfo files. List of tuples
# (source start file, target name, title, author,
#  dir menu entry, description, category)
texinfo_documents = [
  ('index', 'CommCareHQ', 'CommCareHQ Documentation',
   'Dimagi', 'CommCareHQ', 'One line description of project.',
   'Miscellaneous'),
]

@@ -1876,18 +1876,18 @@
 ht = '20
-14
+20
 , Dimagi

Update conf.py