Commit Graph

12787 Commits

Author SHA1 Message Date
Takeshi KOMIYA
d4ace4cd63 Fix wrong indentation 2019-02-17 22:43:58 +09:00
Takeshi KOMIYA
fa022fa377
Merge pull request #6086 from tk0miya/separate_serializinghtml
Separate json and pickle to sphinxcontrib package
2019-02-17 22:40:12 +09:00
Takeshi KOMIYA
8a391d1781 Merge branch '1.8' 2019-02-17 22:37:23 +09:00
Takeshi KOMIYA
1437dff4e1
Merge pull request #6042 from tk0miya/simplify_conf.py_html
quickstart: Simplify generated conf.py (HTML)
2019-02-17 22:32:59 +09:00
Takeshi KOMIYA
1ca210aab1 Separate json and pickle to sphinxcontrib package 2019-02-17 22:31:50 +09:00
Takeshi KOMIYA
527e955405
Merge pull request #6085 from tk0miya/refactor_tests_unpickle
test: Use get_doctree() to load doctree files
2019-02-17 20:58:32 +09:00
Takeshi KOMIYA
90bf81bd37 test: Use get_doctree() to load doctree files 2019-02-17 20:27:48 +09:00
Takeshi KOMIYA
836d65f04c
Merge pull request #6083 from tk0miya/6047_autofunction_warns_for_methods
Fix #6047: autodoc: ``autofunction`` emits a warning for method objects
2019-02-17 19:17:07 +09:00
Takeshi KOMIYA
fcb22f2074
Merge pull request #5832 from stephenfin/bindep-integration
Add bindep integration
2019-02-17 18:25:26 +09:00
Takeshi KOMIYA
08cd23a0bb Fix #6047: autodoc: `autofunction` emits a warning for method objects 2019-02-17 18:23:14 +09:00
James Knight
3858a62814 test: verify linenothreshold usage
Adding a unit test to verify the use of the `linenothreshold` option
provided by the `highlight` directive [1]. The included document to test
will introduce two sets of `code-block` and `literalinclude` directives
where the first entry generates contents using line numbers and the
second entry generates contents not using line numbers, respectfully.

[1]: https://github.com/sphinx-doc/sphinx/blob/v1.8.4/sphinx/transforms/post_transforms/code.py#L85

Signed-off-by: James Knight <james.d.knight@live.com>
2019-02-16 22:14:30 -05:00
James Knight
0ded648c1a directive-code: do not force linenos value on run
Now that `highlightlang` directive is deprecated [1], the
`linenothreshold` option is to be used via the `highlight` directive.
The `highlight` directive will walk-through literal blocks to apply a
`linenos` value if:

 1) The literal block has not been explicitly configured with the
     `linenos` option.
 2) If there is enough content (when comparing literal block's line
     count to `linenothreshold`) that `linenos` should be explicitly
     enabled or disabled [2].

While the `hightlight` directive should be able to explicitly define if
a literal block needs to enable line numbers, the logic is always
ignored since the code block and literal include directives already
configures `linenos` when checking for line number-specific options on
the node [3][4]. This effectively prevents `linenothreshold` from being
used.

To allow `linenothreshold` to be used in literal blocks, this commit
disables the explicit configuration `linenos` on a literal block
instance when the `CodeBlock` and `LiteralInclude` directives are
processed.

[1]: b35198d847
[2]: https://github.com/sphinx-doc/sphinx/blob/v1.8.1/sphinx/transforms/post_transforms/code.py#L95-L97
[3]: https://github.com/sphinx-doc/sphinx/blob/v1.8.1/sphinx/directives/code.py#L156-L157
[4]: https://github.com/sphinx-doc/sphinx/blob/v1.8.1/sphinx/directives/code.py#L442-L444

Signed-off-by: James Knight <james.d.knight@live.com>
2019-02-16 22:14:30 -05:00
Takeshi KOMIYA
963d8bc4fc conf.py: Remove html_options from template 2019-02-17 01:16:01 +09:00
Takeshi KOMIYA
68f9339d7f conf.py: Remove html_sidebars from template 2019-02-17 01:15:44 +09:00
Takeshi KOMIYA
8f0b49a4cf
Merge pull request #6051 from tk0miya/6026_xref_for_deflist
Fix #6026: LaTeX: A cross reference to definition list does not work
2019-02-17 00:39:47 +09:00
Takeshi KOMIYA
c67443f4a2
Merge branch '1.8' into 6026_xref_for_deflist 2019-02-17 00:24:25 +09:00
Takeshi KOMIYA
74ec98bb1d
Merge pull request #6071 from tk0miya/6019_imgconverter_multipaged_PDF
Fix #6019: imgconverter: Including multipage PDF fails
2019-02-17 00:13:07 +09:00
Takeshi KOMIYA
63ccc34475
Merge pull request #6082 from tk0miya/refactor_XRefRole
refactor XRefRole using ReferenceRole class
2019-02-16 23:42:10 +09:00
Takeshi KOMIYA
a26e9f3d48
Merge pull request #6066 from tk0miya/4148_renew_quickstart_question
Closes #4148: quickstart: some questions are removed
2019-02-16 22:50:16 +09:00
Takeshi KOMIYA
c23835ef06 refactor XRefRole using ReferenceRole class 2019-02-16 21:47:15 +09:00
Takeshi KOMIYA
5437ab61e9
Merge pull request #6074 from tk0miya/1148_autodecorator
Closes #1148: autodoc: Add autodecorator directive for decorators
2019-02-16 21:45:36 +09:00
Takeshi KOMIYA
c0610cee64
Merge pull request #6041 from tk0miya/simplify_conf.py
Simplify conf.py
2019-02-16 21:44:28 +09:00
Takeshi KOMIYA
1ece29597e
Merge branch 'master' into simplify_conf.py 2019-02-16 21:25:21 +09:00
Takeshi KOMIYA
61f1477942 Add testcase for XRefRole class 2019-02-16 21:23:01 +09:00
Takeshi KOMIYA
6748a6de2f Add testcase for download role 2019-02-16 21:23:01 +09:00
Takeshi KOMIYA
392f775cd1
Merge pull request #6081 from tk0miya/refactor_roles2
Replace :file: and :samp: roles by class based implementation
2019-02-16 20:56:10 +09:00
Takeshi KOMIYA
3ec032fa39 Replace :file: and :samp: roles by class based implementation 2019-02-16 12:37:46 +09:00
Takeshi KOMIYA
cd360471c9
Merge pull request #6080 from tk0miya/refactor_roles3
Replace :guilabel: and :menuselection: roles by class based implementation
2019-02-16 11:46:08 +09:00
Takeshi KOMIYA
ea4d8ca08d Replace :guilabel: and :menuselection: roles by class based implementation 2019-02-16 02:30:28 +09:00
Takeshi KOMIYA
cd13a90511
Merge pull request #6079 from tk0miya/refactor_role
docs: Add SphinxRole and ReferenceRole
2019-02-16 02:23:59 +09:00
Takeshi KOMIYA
5fe2e94921
Merge pull request #6078 from tk0miya/fix_test
Fix a test
2019-02-16 02:16:04 +09:00
Takeshi KOMIYA
1660269d01 Fix a test 2019-02-16 01:55:58 +09:00
Takeshi KOMIYA
065ece6f4c docs: Add SphinxRole and ReferenceRole 2019-02-16 01:55:46 +09:00
Takeshi KOMIYA
c892a5abeb refactor: Rename the first argument of roles to name
In docutils' document, it is called as name.  So our base class
should call it as "name" also.
2019-02-16 01:55:46 +09:00
Takeshi KOMIYA
66afbec979
Merge pull request #6077 from tk0miya/refactor_role4
Fix :pep: and :rfc: roles are broken
2019-02-16 01:55:19 +09:00
Takeshi KOMIYA
cb49a6b091 Fix :pep: and :rfc: roles are broken 2019-02-16 01:47:52 +09:00
Takeshi KOMIYA
aeed3d89bf
Merge pull request #6076 from tk0miya/refactor_roles3
Replace :pep: and :rfc: roles by class based implementation
2019-02-16 00:54:06 +09:00
Takeshi KOMIYA
9cb40436ed Replace :pep: and :rfc: roles by class based implementation 2019-02-16 00:34:24 +09:00
Takeshi KOMIYA
1cf8ece5cc
Merge pull request #6075 from tk0miya/refactor_roles
Replace :index: role by class based implementation
2019-02-16 00:26:35 +09:00
Takeshi KOMIYA
a6d345f95d Replace :index: role by class based implementation 2019-02-16 00:05:13 +09:00
Takeshi KOMIYA
424c438c52
Merge pull request #6073 from tk0miya/separate_htmlhelp
Separate htmlhelp to sphinxcontrib package
2019-02-15 21:28:58 +09:00
Takeshi KOMIYA
686486498c Closes #1148: autodoc: Add autodecorator directive for decorators 2019-02-15 02:14:38 +09:00
Takeshi KOMIYA
3b49f9fe3d Separate htmlhelp to sphinxcontrib package 2019-02-15 01:44:32 +09:00
Takeshi KOMIYA
cd542fb2af
Merge pull request #6061 from tk0miya/reduce_warnings_of_rootcase
test: Reduce warnings on building test-root
2019-02-14 22:24:27 +09:00
Takeshi KOMIYA
c50b130357
Merge pull request #6059 from tk0miya/omit_other_settings
refactor: test: Remove unused settings from conf.py
2019-02-14 22:23:56 +09:00
Takeshi KOMIYA
9afe93d8f6 refactor: test: Remove unused settings from conf.py 2019-02-14 02:21:07 +09:00
Takeshi KOMIYA
891178e8ed test: Reduce warnings on building test-root
Note: all warnings are tested on test-warnings.
2019-02-14 02:20:55 +09:00
Takeshi KOMIYA
973fbb81e4
Merge pull request #6072 from tk0miya/fix_master
Fix test_ext_autosectionlabel conflicts with HTML5 writer
2019-02-14 02:20:29 +09:00
Takeshi KOMIYA
3e7113c4c6 Fix test_ext_autosectionlabel conflicts with HTML5 writer 2019-02-14 02:13:14 +09:00
Takeshi KOMIYA
550c88f98c
Merge pull request #6064 from tk0miya/5636_add_autosummary_mock_imports
Closes #5635: autosummary: Add autosummary_mock_imports to mock external libraries
2019-02-14 01:13:04 +09:00