chiark / gitweb /
Vladimír Vondruš [Thu, 11 Jul 2019 23:03:42 +0000 (01:03 +0200)]
documentation/python: properly handle recursively imported modules.
Basically converting the crawl to be breadth-first instead of
depth-first and maintaining a set of crawled modules to ensure they're
never visited again.
This could happen with classes as well, but it's rarer -- one would need
to add it to __all__ twice (or once and then it gets discovered
implicitly) etc. For now I'm simply asserting, will revisit in case it
proves to be an actual problem.
Vladimír Vondruš [Wed, 10 Jul 2019 21:39:40 +0000 (23:39 +0200)]
documentation/python: minor code reorganization.
Vladimír Vondruš [Wed, 10 Jul 2019 21:31:27 +0000 (23:31 +0200)]
documentation/python: inline functions that are used in a single place.
Those are the ugliest, ha. Keep them together.
Vladimír Vondruš [Wed, 10 Jul 2019 14:08:32 +0000 (16:08 +0200)]
documentation/python: format also anchors for class/module members.
First step towards symbol crosslinking.
Vladimír Vondruš [Wed, 10 Jul 2019 20:45:15 +0000 (22:45 +0200)]
documentation/python: make it possible to configure how URLs look.
Well, this is a bit overdone preparation for links to actual class /
module members, but can't hurt, no?? :D
Vladimír Vondruš [Wed, 10 Jul 2019 20:29:54 +0000 (22:29 +0200)]
documentation/python: crawl the names first to build a name map.
And then render eeach page non-recursively. That helps with
deduplicating the code (although the result is more code now), memory
usage (we're freeing everything before continuing to render another
page) and prepares the codebase for crosslinking and search.
Vladimír Vondruš [Sun, 14 Jul 2019 17:10:48 +0000 (19:10 +0200)]
pelican-theme: nope, this PR is still not merged yet.
Vladimír Vondruš [Tue, 9 Jul 2019 11:16:40 +0000 (13:16 +0200)]
documentation/python: adapt to a minor change in pybind 2.3 signatures.
Cris Luengo [Tue, 9 Jul 2019 11:14:52 +0000 (13:14 +0200)]
documentation/doxygen: fixed link to defines section.
Vanilla HTML Doxygen output uses #define-members and that's what was
used to define the section ID, however the link to it was by mistake
just #defines.
Vladimír Vondruš [Sun, 7 Jul 2019 20:29:42 +0000 (22:29 +0200)]
package/ci: use matplotlib 3.0 on the CI.
Vladimír Vondruš [Sun, 7 Jul 2019 20:28:19 +0000 (22:28 +0200)]
m.plots: adapt for matplotlib 3.0.
3.0 uses a HTTPS URL in the SVG preamble, so the regex needed updating.
That's it. And I was putting this off for over a year, heh.
Well, actually now I have THREE DIFFERENT OUTPUTS to test for --
Python 3.5 and older has slightly different number rounding, while
matplotlib 3.1 adds a CSS property that 3.0 didn't have. Yay this is
annoying as hell.
Vladimír Vondruš [Sun, 7 Jul 2019 20:13:33 +0000 (22:13 +0200)]
package/ci: use latest Jinja on the CI.
Should work again.
Vladimír Vondruš [Sun, 7 Jul 2019 20:12:13 +0000 (22:12 +0200)]
Doc++
Vladimír Vondruš [Sun, 7 Jul 2019 19:34:50 +0000 (21:34 +0200)]
Trim extra trailing newlines before passing it to Jinja's indent().
In Jinja 2.9 indent() unconditionally stripped the trailing newline, in
2.10 it preserves it. That ... actually makes sense, so we have to
adapt.
Vladimír Vondruš [Sun, 7 Jul 2019 19:23:35 +0000 (21:23 +0200)]
m.htmlsanity: add a rtrim Jinja2 filter.
Argh, I wanted to update to Jina 2.10 without workarounds, but it's not
possible.
Cris Luengo [Wed, 1 May 2019 22:13:52 +0000 (16:13 -0600)]
css: allow customizing text line height.
Cris Luengo [Wed, 1 May 2019 22:16:11 +0000 (16:16 -0600)]
css: allow variables to be defined in terms of other variables.
Vladimír Vondruš [Sun, 7 Jul 2019 16:44:05 +0000 (18:44 +0200)]
Revert "documentation: fix for duplicate detailed description issue."
Wait no, this was a total brainfart. Things continue to work even
without those (and the new branches are OTOH never actually executed).
This partially reverts commit
d1961231589a1cdf7a742d1f55a8daaf4533dfd6.
Cris Luengo [Wed, 8 May 2019 04:09:00 +0000 (22:09 -0600)]
documentation: allow tests to run under MacOS and Windows.
Cris Luengo [Wed, 8 May 2019 04:18:00 +0000 (22:18 -0600)]
documentation: these two also had duplicate detailed description issues.
Cris Luengo [Tue, 7 May 2019 05:43:38 +0000 (23:43 -0600)]
documentation: fix for duplicate detailed description issue.
Also fixes issue with group (module) defined across two files.
Vladimír Vondruš [Sun, 7 Jul 2019 16:27:25 +0000 (18:27 +0200)]
documentation/doxygen: defines *can* appear twice, too.
In a group and in file docs. So accomodate for that.
Cris Luengo [Tue, 7 May 2019 05:54:19 +0000 (23:54 -0600)]
documentation: test issues with duplicate detailed descriptions.
Also shows issues that come up when groups (modules) are spread over
multiple files.
Vladimír Vondruš [Sun, 7 Jul 2019 12:22:04 +0000 (14:22 +0200)]
Updated CREDITS.rst.
Vladimír Vondruš [Sun, 7 Jul 2019 12:20:11 +0000 (14:20 +0200)]
documentation/python: test for external docs that get unused.
Those should print a warning and not affect the output in any way.
Vladimír Vondruš [Sun, 7 Jul 2019 13:05:33 +0000 (15:05 +0200)]
documentation/doxygen: "improve" empty page filtering.
By throwing more mud at the wall. Ugh. Wow doxygen, why is everything
so damn hard.
Cris Luengo [Tue, 7 May 2019 04:20:40 +0000 (22:20 -0600)]
documentation: fix for empty pages issue.
Cris Luengo [Tue, 7 May 2019 05:13:58 +0000 (23:13 -0600)]
documentation: test that shows empty page issue.
Vladimír Vondruš [Sun, 7 Jul 2019 11:21:16 +0000 (13:21 +0200)]
documentation: reword the footer.
Neither Doxygen nor m.css is a human capable of writing the docs.
Vladimír Vondruš [Sun, 7 Jul 2019 11:18:17 +0000 (13:18 +0200)]
m.plots: support stacked values.
Vladimír Vondruš [Sun, 7 Jul 2019 10:53:54 +0000 (12:53 +0200)]
documentation/python: Häagen-Dazs?!
Vladimír Vondruš [Sun, 7 Jul 2019 10:49:59 +0000 (12:49 +0200)]
documentation/python: properly extract images with complex paths.
The paths are patched to contains just a filename so things like
../../image.png work and don't lead to unreferenceable images. This is
similar to what Doxygen does even though I don't really like that -- it
could lead to conflicting files if there are files with the same
basename.
Vladimír Vondruš [Sun, 7 Jul 2019 09:39:15 +0000 (11:39 +0200)]
plugins: make latex2svg work at least partially with dvisvgm 1.9.2.
Vladimír Vondruš [Tue, 21 May 2019 22:08:19 +0000 (00:08 +0200)]
documentation/python: don't ignore pybind submodules inside packages.
This is extra brittle. Hahah why this has to be so damn complex.
Vladimír Vondruš [Tue, 21 May 2019 18:04:10 +0000 (20:04 +0200)]
documentation/python: use external summary only if it's actually there.
Vladimír Vondruš [Tue, 21 May 2019 14:35:24 +0000 (16:35 +0200)]
m.dot: fix skip message in the test.
Vladimír Vondruš [Sun, 12 May 2019 21:01:10 +0000 (23:01 +0200)]
documentation/python: add support for pre-page and post-run hooks.
Vladimír Vondruš [Sun, 12 May 2019 20:30:56 +0000 (22:30 +0200)]
documentation/python: different order of rendering nested pages.
This should be better for memory usage.
Vladimír Vondruš [Sun, 12 May 2019 20:08:44 +0000 (22:08 +0200)]
m.qr: new plugin for QR code rendering.
Vladimír Vondruš [Sun, 12 May 2019 17:33:19 +0000 (19:33 +0200)]
Doc++
Vladimír Vondruš [Sun, 12 May 2019 17:33:00 +0000 (19:33 +0200)]
doc: link to the Magnum Python docs.
Vladimír Vondruš [Sun, 12 May 2019 17:32:24 +0000 (19:32 +0200)]
documentation/python: copy all referenced images as well.
Vladimír Vondruš [Sun, 5 May 2019 16:10:49 +0000 (18:10 +0200)]
m.sphinx: new plugin for Python docs via external files.
Provides a way to document modules, classes and data in the Python doc
theme.
Vladimír Vondruš [Sun, 12 May 2019 13:58:11 +0000 (15:58 +0200)]
plugins: make it clear the testing is done through Pelican.
Vladimír Vondruš [Tue, 7 May 2019 22:28:24 +0000 (00:28 +0200)]
documentation/python: module tree showed expanders where not needed.
What the heck was I doing there.
Vladimír Vondruš [Tue, 7 May 2019 22:26:21 +0000 (00:26 +0200)]
documentation/python: support more than 9 function overloads.
I thought this time would never come. But here we are, math.dot() needs
this.
Vladimír Vondruš [Tue, 7 May 2019 22:03:47 +0000 (00:03 +0200)]
documentation/python: implement name mapping for _all__.
Basically, if there's this in the code:
from ._native import Foo as PublicName
from ._native import sub as submodule
__all__ = ['PublicName', 'submodule']
then it's clear that the docs should refere library.PublicName and
library.submodule instead of library._native.Foo / library._native.sub.
This mapping is done for both pybind11 signatures and pure Python code.
Vladimír Vondruš [Tue, 7 May 2019 16:27:17 +0000 (18:27 +0200)]
documentation/python: support string annotations.
Vladimír Vondruš [Tue, 7 May 2019 10:35:48 +0000 (12:35 +0200)]
documentation/python: don't cut off the last character in a warning.
I mistakenly thought a[:-1] is the same as a[:]. It isn't.
Vladimír Vondruš [Sun, 5 May 2019 14:05:10 +0000 (16:05 +0200)]
documentation/python: support plugins.
It looks like we're 90% there, hah.
Vladimír Vondruš [Sun, 12 May 2019 14:42:33 +0000 (16:42 +0200)]
documentation/python: introduce the INPUT option for specifying input dir.
Vladimír Vondruš [Sun, 5 May 2019 12:14:23 +0000 (14:14 +0200)]
documentation/python: initial support for documentation pages.
Vladimír Vondruš [Sun, 5 May 2019 12:41:39 +0000 (14:41 +0200)]
documentation/python: don't add implicit INPUT_MODULES in all tests.
Only in the inspect tests, elsewhere it's counterproductive.
Vladimír Vondruš [Sun, 5 May 2019 12:10:19 +0000 (14:10 +0200)]
documentation/python: properly set up everything from m.htmlsanity.
Vladimír Vondruš [Sun, 5 May 2019 14:26:35 +0000 (16:26 +0200)]
m.filesize: minor cleanup.
Vladimír Vondruš [Sun, 5 May 2019 12:13:57 +0000 (14:13 +0200)]
m.htmlsanity: doc++
Vladimír Vondruš [Sun, 5 May 2019 12:12:45 +0000 (14:12 +0200)]
m.htmlsanity: make it possible to compact field lists again.
Do the patching in _SaneFieldBodyTranslator instead, but since both
Pelican theme (which wants field lists uncompacted) and Python docs
(which doesn't) use it, it has to allow another override again.
Vladimír Vondruš [Sun, 5 May 2019 12:06:29 +0000 (14:06 +0200)]
m.htmlsanity: make the docutils settings public.
Vladimír Vondruš [Sat, 4 May 2019 19:47:34 +0000 (21:47 +0200)]
documentation/python: rename brief to summary.
Another doxygen-ism. It made some sense for API docs, but having "brief"
and "description" for pages doesn't make any sense at all. Summary and
content makes much more sense for pages and since it doesn't make sense
to have two types of naming, let's rename it for everything else as
well. This is now also in-line with Pelican article metadata and XMLDoc
for C# docs, yay.
Vladimír Vondruš [Sat, 4 May 2019 19:27:12 +0000 (21:27 +0200)]
documentation/python: properly escape default values.
Vladimír Vondruš [Sat, 4 May 2019 19:22:59 +0000 (21:22 +0200)]
documentation/python: functions actually *can* take args/kwargs directly.
Vladimír Vondruš [Tue, 30 Apr 2019 21:43:50 +0000 (23:43 +0200)]
doc: fix broken anchor.
Vladimír Vondruš [Tue, 30 Apr 2019 21:31:13 +0000 (23:31 +0200)]
doc: another missing reST role.
Vladimír Vondruš [Tue, 30 Apr 2019 21:30:25 +0000 (23:30 +0200)]
m.code: add ZWNJ before ANSI colored squares.
Otherwise it wasn't wrapping even with .m-console-wrap. Not sure why,
<wbr/> didn't work either.
Vladimír Vondruš [Tue, 30 Apr 2019 21:23:51 +0000 (23:23 +0200)]
css: add .m-tiny.
Vladimír Vondruš [Tue, 30 Apr 2019 21:23:24 +0000 (23:23 +0200)]
css: add .m-console-wrap for console output.
Vladimír Vondruš [Mon, 29 Apr 2019 17:28:16 +0000 (19:28 +0200)]
documentation: minor cleanup.
Vladimír Vondruš [Mon, 29 Apr 2019 17:27:02 +0000 (19:27 +0200)]
m.code: rudimentary support for 24bit console colors.
MVP I need for an upcoming article (and docs).
Vladimír Vondruš [Mon, 29 Apr 2019 17:20:51 +0000 (19:20 +0200)]
css: nicely packed code + console figure.
Vladimír Vondruš [Mon, 29 Apr 2019 17:14:45 +0000 (19:14 +0200)]
css: make console output slightly less than pitch black.
I like black coffee and all, but since KDE moved away from #000000 as
well recently, it kinda hurts my eyes now.
Vladimír Vondruš [Mon, 29 Apr 2019 17:12:50 +0000 (19:12 +0200)]
css: consistently use just .m-{code,console}-figure w/o the figure prefix.
This was done in order to make it possible to use code figures with
less-than-ideal authoring tools (Doxygen) and some cases were left out
by accident.
Vladimír Vondruš [Mon, 29 Apr 2019 17:37:40 +0000 (19:37 +0200)]
documentation: whoops, this slipped through when pushing.
Vladimír Vondruš [Mon, 29 Apr 2019 17:37:25 +0000 (19:37 +0200)]
Updated credits.
Cris Luengo [Fri, 26 Apr 2019 04:02:46 +0000 (22:02 -0600)]
Correctly handling <sub>, <sup>, and all HTML entities accepted by Doxygen.
Vladimír Vondruš [Mon, 22 Apr 2019 15:12:46 +0000 (17:12 +0200)]
doc: mention more pybind11 specifics.
Vladimír Vondruš [Sun, 21 Apr 2019 22:05:17 +0000 (00:05 +0200)]
package/ci: set up pybind11 compilation on Travis.
Vladimír Vondruš [Sun, 21 Apr 2019 20:55:40 +0000 (22:55 +0200)]
documentation/python: gracefully handle also crazy return types.
Vladimír Vondruš [Sun, 21 Apr 2019 17:21:40 +0000 (19:21 +0200)]
documentation/python: parsing types of pybind11 properties.
Vladimír Vondruš [Sat, 20 Apr 2019 21:41:31 +0000 (23:41 +0200)]
documentation/python: parse pybind11 function signatures.
Vladimír Vondruš [Sat, 20 Apr 2019 22:07:07 +0000 (00:07 +0200)]
documentation/python: support pybind11-style submodules.
The usual detection fails there. Oh well.
Vladimír Vondruš [Sat, 20 Apr 2019 22:05:14 +0000 (00:05 +0200)]
documentation/python: support pybind11 enums.
Vladimír Vondruš [Sat, 20 Apr 2019 22:03:35 +0000 (00:03 +0200)]
documentation/python: make pybind11 compatibility opt-in.
This is becoming rather shitty.
Vladimír Vondruš [Sat, 20 Apr 2019 18:29:53 +0000 (20:29 +0200)]
documentation/python: module and class index.
Vladimír Vondruš [Sat, 20 Apr 2019 14:47:55 +0000 (16:47 +0200)]
documentation/python: adapt to slightly different internals in 3.6.
Vladimír Vondruš [Sat, 20 Apr 2019 14:10:19 +0000 (16:10 +0200)]
documentation/python: support enums.
Vladimír Vondruš [Fri, 19 Apr 2019 15:47:39 +0000 (17:47 +0200)]
documentation: initial version of the Python doc generator.
Inspecting modules, functions, classes, methods and properties, taking
the first line of the docstring for a brief docs. Nothing more at the
moment, no index or search is hooked up yet.
Vladimír Vondruš [Sat, 20 Apr 2019 18:19:54 +0000 (20:19 +0200)]
documentation/doxygen: reflow a comment.
Vladimír Vondruš [Mon, 22 Apr 2019 14:59:40 +0000 (16:59 +0200)]
Doc++
Vladimír Vondruš [Sat, 20 Apr 2019 15:27:40 +0000 (17:27 +0200)]
documentation: ignore more npm cruft.
Vladimír Vondruš [Sat, 20 Apr 2019 15:11:12 +0000 (17:11 +0200)]
documentation: ignore test files for code coverage.
Stupid fucking istanbul, now it's deprecated and renamed to nyc and
there's some magic that puts istanbul into PATH but only in the root
directory and I hate that.
Vladimír Vondruš [Fri, 19 Apr 2019 17:51:09 +0000 (19:51 +0200)]
m.alias: remove useless dependency on m.htmlsanity.
Vladimír Vondruš [Fri, 19 Apr 2019 15:22:11 +0000 (17:22 +0200)]
m.htmlsanity: make the plugin usable outside of Pelican.
Vladimír Vondruš [Fri, 19 Apr 2019 17:52:39 +0000 (19:52 +0200)]
documentation/doxygen: use proper CSS color in the test.
Vladimír Vondruš [Fri, 19 Apr 2019 15:52:29 +0000 (17:52 +0200)]
Doc++
Vladimír Vondruš [Wed, 17 Apr 2019 17:23:52 +0000 (19:23 +0200)]
Various updates to the contribution guide.
I spotted a bunch of Engrish and in the end went over everything.
Vladimír Vondruš [Sun, 14 Apr 2019 11:26:24 +0000 (13:26 +0200)]
doxygen: whoops, forgot to update the JS.
Vladimír Vondruš [Wed, 3 Apr 2019 20:13:51 +0000 (22:13 +0200)]
doc: whoops, forgot to commit this.
Vladimír Vondruš [Wed, 3 Apr 2019 15:11:50 +0000 (17:11 +0200)]
doc: fix another order-dependent rst processing error.
Vladimír Vondruš [Wed, 3 Apr 2019 09:16:45 +0000 (11:16 +0200)]
doc: moved sample Doxygen tagfile.
Vladimír Vondruš [Wed, 3 Apr 2019 08:38:52 +0000 (10:38 +0200)]
css: renamed m-doxygen.css to m-documentation.css.
And all .m-dox* classes to .m-doc*. It's not Doxygen-specific anymore.
Note this is a breaking change if you are using the Doxygen theme. In
particular:
* all stylesheet references in HTML_EXTRA_STYLESHEETS have to be
updated to reference m-dark+documentation.compiled.css instead of
m-dark+doxygen.compiled.css
* all processing scripts and theme derivations that were depending on
the m-doxygen.css file need to reference m-documentation.css
* all theme modifications need to use the m-doc prefix instead of
m-dox for CSS classes