-
Notifications
You must be signed in to change notification settings - Fork 46
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
single classdef documentation for MATLAB doc and Sphinx #140
Comments
I think I adapted my documenting style, to what this package has been offering. It's based on the Sphinx auto-document feature for Python. This implied for me not listing methods and properties in Regarding properties, yes currently we list all properties with A better summary would be definitely improve the usability of the package. I think we should strive for something that looks like the MATLAB version. My problem is that I have very little free time to add features to this package, other than fixing errors. I will happily accept pull requests :) Lastly, if you add a minimal example in zip-file I can take a look at it. |
Thanks @joeced, I understand the "little free time" constraint, so I appreciate your work on this project and any attention you can spare. I've attached a minimal example (classdef-min-ex.zip) of my current best attempt at getting something that works with Here are a list of some remaining issues (I'm sure there are more), in rough priority order:
Thanks again for any suggestions (or tweaks to |
Sorry for the late reply. I have been on vacation. Thanks for the example. It's much easier to understand what you would like. I will try to look into to this, as it could make it way easier to transition to Sphinx. Unfortunately, I still have some dark spots around how Sphinx exactly works, and when we can modify certain elements. |
Currently, my highest priority blocker is item 1 in my previous comment, i.e. getting I'm totally unfamiliar with the code at this point, but could you point me where to look in the code to see whether I might be able to figure something out? |
Having had some time to think about this feature request, I like it more and more. The extension is built upon the Python auto-doc extension, hence the naming of "auto"-directives. To built a feature like this, I would suggest to go in the direction of https://www.sphinx-doc.org/en/master/usage/extensions/autosummary.html, this uses a Jinja templating pattern. We could mimick this a make a template for a classdef summary. I would really appreciate a contribution here :)
|
I'm not really familiar with the process Sphinx goes through when it produces HTML output, including the relationships between Currently, using If that's the rough idea, here are a few questions:
|
Hey - sorry not answering before. |
Small update. It's way more difficult to add this feature than I thought. So no progress yet. However, I did address this
in version |
First, thanks for #159, #171, #173, and #176 which together provide significant progress toward the goal of being able to write the help in my Matlab files in a way that works well for both Sphinx and MATLAB's Given this progress, I wanted to summarize the primary remaining issues I am facing and create separate issues (where needed) to track each. They are in rough priority order.
|
I'm happy to make this extension better. The long-term goal for me has also been to make the differences between MATLAB and Sphinx doc requirements as small as possible. I need some time to sketch out the order of action items. First of is #171, which will make it easier to do the other steps. I hope you have a bit of patience as my effective time to work on the project is limited. |
I totally understand the limited time, so no pressure. And I very much appreciate your work on all of this. The only thing that is time-critical for me is that I really need to get started on writing the documentation for my Matlab code. I need to make some assumption about the issues that affect how I write my source documentation. So that would include #171, which I am going to assume will eventually be completed, and the auto-linking (item 1 above). For my current thoughts on the latter, see my follow up in #178. |
My goal is to have reference documentation for my classdef files that work fine with MATLAB's
doc
command and that I can use with this package andautodoc
(and probablynapoleon
or something else) to generate basic HTML documentation for each class.At the very least I need to be able to describe the class and each property and method, with the method signature and descriptions of each input and output argument. Ideally, classes could also be auto-linked to superclasses.
Could anyone who has successfully done this provide an example classdef file and corresponding
conf.py
and .rst file showing how you accomplish this?... and it just creates a single list of properties and methods together. How do I get it to list them separately?
= None
after them, which I don't want.Any help or pointers are greatly appreciated.
The text was updated successfully, but these errors were encountered: