🌐 AI搜索 & 代理 主页
Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
41 commits
Select commit Hold shift + click to select a range
5d97877
docs: document Bookmarks analysis
Nov 15, 2017
5478945
acpt: Add scenario for document.bookmarks
Aug 25, 2018
aaddf07
rfctr: blacken docs/conf.py
scanny Jul 13, 2019
758c98d
doc: add Document.bookmarks
Aug 25, 2018
efbf649
acpt: add scenario for Bookmarks
Aug 31, 2018
9b9e427
bmk: add Bookmarks.__len__()
scanny Sep 9, 2018
d4cb2ed
bmk: add Bookmarks._finder
scanny Sep 9, 2018
354a765
bmk: add _DocumentBookmarkFinder.bookmark_pairs
scanny Sep 9, 2018
09400f6
bmk: Add DocumentPart.iter_story_parts()
Dec 24, 2018
fff3b0c
opc: add Part.iter_parts_related_by()
Dec 24, 2018
a13848b
pep8: fixes for latest version of flake8
Dec 26, 2018
d4059d1
rfctr: upgrade mock helpers to autospec by default
Dec 26, 2018
cc9c487
bmk: add _PartBookmarkFinder.iter_start_end_pairs()
Dec 27, 2018
155ed51
bmk: Add _PartBookmarkFinder._iter_start_end_pairs()
Dec 27, 2018
a6726c0
bmk: add _PartBookmarkFinder._iter_starts()
Dec 27, 2018
a2df446
bmk: add _PartBookmarkFinder._all_starts_and_ends
Dec 27, 2018
125a0df
bmk: add _PartBookmarkFinder._name_already_used()
Dec 27, 2018
45b5fd1
bmk: add _PartBookmarkFinder._names_so_far
Dec 27, 2018
d631756
parts: add EndnotesPart
Dec 27, 2018
654d8f6
parts: add FootnotesPart
Dec 27, 2018
a1ac389
bmk: add Bookmarks.__getitem__() and .__iter__()
Dec 28, 2018
367afac
test: update tox and fix py3 failures
scanny Dec 28, 2018
13c3b8d
acpt: Add scenario for named bookmark access
Dec 29, 2018
25af26b
bmk: Add Bookmarks.get()
Jan 6, 2019
b514ea3
bmk: Add _Bookmark.name
Jul 14, 2019
c58ac35
bmk: Add _Bookmark.id
Jan 6, 2019
a6fde18
acpt: add Document.start_bookmark() scenario
scanny Jul 14, 2019
3b924ce
bmk: add Document.start_bookmark()
scanny Jul 14, 2019
f6734b3
blkcntnr: add BlockItemContainer.start_bookmark()
scanny Sep 2, 2019
de1297b
blkcntnr: add BlockItemContainer._bookmarks
scanny Sep 2, 2019
fbb0639
bmk: add Bookmarks.__contains__()
scanny Sep 2, 2019
c39cf5f
bmk: add Bookmarks.next_id
scanny Sep 3, 2019
e5af3e4
rfctr: modernize selected feature files
scanny Sep 3, 2019
2ff98dc
acpt: add remaining start_bookmark() scenarios
scanny Sep 3, 2019
19c38e5
parts: add BaseStoryPart.bookmarks
scanny Sep 3, 2019
dc793d3
acpt: add scenario for Document.end_bookmark()
scanny Sep 8, 2019
7bc7728
doc: add Document.end_bookmark()
scanny Sep 8, 2019
99778bb
bmk: add BlockItemContainer.end_bookmark()
scanny Sep 8, 2019
9be433b
bmk: add _Bookmark.is_closed
scanny Sep 8, 2019
e65ec0d
bmk: add _Bookmark.close()
scanny Sep 8, 2019
a53a6bb
bmk: add _Bookmark.__eq__()
scanny Sep 8, 2019
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
/dist/
/docs/.build/
/*.egg-info
.pytest_cache/
*.pyc
.pytest_cache/
_scratch/
Expand Down
69 changes: 40 additions & 29 deletions docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
# If extensions (or modules to document with autodoc) are in another directory,
# add these directories to sys.path here. If the directory is relative to the
# documentation root, use os.path.abspath to make it absolute, like shown here.
sys.path.insert(0, os.path.abspath('..'))
sys.path.insert(0, os.path.abspath(".."))

from docx import __version__ # noqa

Expand All @@ -31,28 +31,28 @@
# 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.intersphinx',
'sphinx.ext.todo',
'sphinx.ext.coverage',
'sphinx.ext.viewcode'
"sphinx.ext.autodoc",
"sphinx.ext.intersphinx",
"sphinx.ext.todo",
"sphinx.ext.coverage",
"sphinx.ext.viewcode",
]

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

# The suffix of source filenames.
source_suffix = '.rst'
source_suffix = ".rst"

# The encoding of source files.
# source_encoding = 'utf-8-sig'

# The master toctree document.
master_doc = 'index'
master_doc = "index"

# General information about the project.
project = u'python-docx'
copyright = u'2013, Steve Canny'
project = u"python-docx"
copyright = u"2013, Steve Canny"

# The version info for the project you're documenting, acts as replacement for
# |version| and |release|, also used in various other places throughout the
Expand All @@ -77,6 +77,10 @@

.. |_Body| replace:: :class:`._Body`

.. |Bookmark| replace:: :class:`.Bookmark`

.. |Bookmarks| replace:: :class:`.Bookmarks`

.. |_Cell| replace:: :class:`._Cell`

.. |_CharacterStyle| replace:: :class:`._CharacterStyle`
Expand All @@ -89,6 +93,8 @@

.. |_Columns| replace:: :class:`._Columns`

.. |CommentsPart| replace:: :class:`.CommentsPart`

.. |CoreProperties| replace:: :class:`.CoreProperties`

.. |datetime| replace:: :class:`.datetime.datetime`
Expand All @@ -101,6 +107,8 @@

.. |Emu| replace:: :class:`.Emu`

.. |EndnotesPart| replace:: :class:`.EndnotesPart`

.. |False| replace:: :class:`False`

.. |float| replace:: :class:`.float`
Expand All @@ -111,6 +119,8 @@

.. |FooterPart| replace:: :class:`.FooterPart`

.. |FootnotesPart| replace:: :class:`.FootnotesPart`

.. |_Header| replace:: :class:`._Header`

.. |HeaderPart| replace:: :class:`.HeaderPart`
Expand Down Expand Up @@ -193,7 +203,7 @@

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

# The reST default role (used for this markup: `text`) to use for all
# documents.
Expand All @@ -211,7 +221,7 @@
# show_authors = False

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

# A list of ignored prefixes for module index sorting.
# modindex_common_prefix = []
Expand All @@ -221,15 +231,15 @@

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

# Theme options are theme-specific and customize the look and feel of a theme
# further. For a list of options available for each theme, see the
# documentation.
# html_theme_options = {}

# Add any paths that contain custom themes here, relative to this directory.
html_theme_path = ['_themes']
html_theme_path = ["_themes"]

# The name for this set of Sphinx documents. If None, it defaults to
# "<project> v<release> documentation".
Expand All @@ -250,7 +260,7 @@
# Add any paths that contain custom static files (such as style sheets) here,
# relative to this directory. They are copied after the builtin static files,
# so a file named "default.css" will overwrite the builtin "default.css".
html_static_path = ['_static']
html_static_path = ["_static"]

# If not '', a 'Last updated on:' timestamp is inserted at every page bottom,
# using the given strftime format.
Expand All @@ -263,8 +273,7 @@
# Custom sidebar templates, maps document names to template names.
# html_sidebars = {}
html_sidebars = {
'**': ['localtoc.html', 'relations.html', 'sidebarlinks.html',
'searchbox.html']
"**": ["localtoc.html", "relations.html", "sidebarlinks.html", "searchbox.html"]
}

# Additional templates that should be rendered to pages, maps page names to
Expand Down Expand Up @@ -298,18 +307,16 @@
# html_file_suffix = None

# Output file base name for HTML help builder.
htmlhelp_basename = 'python-docxdoc'
htmlhelp_basename = "python-docxdoc"


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

latex_elements = {
# The paper size ('letterpaper' or 'a4paper').
# 'papersize': 'letterpaper',

# The font size ('10pt', '11pt' or '12pt').
# 'pointsize': '10pt',

# Additional stuff for the LaTeX preamble.
# 'preamble': '',
}
Expand All @@ -321,8 +328,7 @@
# author,
# documentclass [howto/manual]).
latex_documents = [
('index', 'python-docx.tex', u'python-docx Documentation',
u'Steve Canny', 'manual'),
("index", "python-docx.tex", u"python-docx Documentation", u"Steve Canny", "manual")
]

# The name of an image file (relative to this directory) to place at the top of
Expand Down Expand Up @@ -351,8 +357,7 @@
# One entry per manual page. List of tuples
# (source start file, name, description, authors, manual section).
man_pages = [
('index', 'python-docx', u'python-docx Documentation',
[u'Steve Canny'], 1)
("index", "python-docx", u"python-docx Documentation", [u"Steve Canny"], 1)
]

# If true, show URL addresses after external links.
Expand All @@ -365,9 +370,15 @@
# (source start file, target name, title, author,
# dir menu entry, description, category)
texinfo_documents = [
('index', 'python-docx', u'python-docx Documentation',
u'Steve Canny', 'python-docx', 'One line description of project.',
'Miscellaneous'),
(
"index",
"python-docx",
u"python-docx Documentation",
u"Steve Canny",
"python-docx",
"One line description of project.",
"Miscellaneous",
)
]

# Documents to append as an appendix to all manuals.
Expand All @@ -381,4 +392,4 @@


# Example configuration for intersphinx: refer to the Python standard library.
intersphinx_mapping = {'http://docs.python.org/3/': None}
intersphinx_mapping = {"http://docs.python.org/3/": None}
Loading