-
-
Notifications
You must be signed in to change notification settings - Fork 201
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
C# Support #550
C# Support #550
Conversation
is this going to be merged? |
I've been using it successfully for a while now, for me its in a stable state. The complexity is really inside the c# domain, for breathe its reasonably trivial. |
This also corrects the source file pointed to in the sphinxrenderer comment.
@rogerbarton Thanks a lot for the patches and the patience! |
Just released v4.20.0 containing this among other things, fyi. |
…gration. This project depends on a few external dependencies: - Sphinx, to drive the whole documentation process. - Breathe, to parse doxygen's XML output. - Exhale, to build autogenerated documentation using breathe's directives. - A C# domain extension, which tells Sphinx how to render C# elements. To support our admittedly odd use case, I patch breathe (at [1]) and exhale (at [2]). I've also been developing [3] on top of djungelorm's `sphinx_csharp` repo [4], since it only supports a subset of C#, and doesn't cover some of our uses. However, in the meanwhile, rogerbarton forked and developed off of the old C# extension [5], and merged a change into breathe [6] using djungelorm's interface rather than a sphinxcontrib namespace package. In [6] it's linked against the package from his repository, since djungelorm still holds the PyPI package. Furthermore, even rogerbarton's quality extension of sphinx_csharp doesn't support the subset of C# we are using (including some properties), so we have to comment out a piece of the `Size2D` example struct. This is all to say that the dependencies are currently wonky, although we'll eventually be able to depend just on my forks, and one day on just the normal breathe/exhale if they can incorporate any useful new changes. This project also depends on `doxygen`, which isn't a Python package, but rather an external binary. Here's hoping it exists on the build servers. The `requirements.txt` file includes a few custom HTML themes, just for variety. [1]: https://github.com/sredmond/breathe [2]: https://github.com/sredmond/exhale [3]: https://github.com/sredmond/sphinxcontrib-csharpdomain [4]: https://github.com/djungelorm/sphinx-csharp [5]: https://github.com/rogerbarton/sphinx-csharp [6]: breathe-doc/breathe#550
Hi guys, looks like awesome work here! I'm trying to use Breathe for a c# project that has xml output. I have included extensions['breathe'] in conf.py Exception occurred: Any suggestions? |
Using You should use this for now:
Hope this fixes it |
Awesome, thanks @rogerbarton! Something I am missing? |
Hmm, did you use Maybe have a look at how its done here: https://github.com/rogerbarton/vr-modeling/blob/master/conf.py |
you are right I had added sphinx_csharp.csharp instead. It works now! Thanks for your work, much appreciated! |
Hi @rogerbarton rogerbarton, I am trying your solution and have some warning and exception, do you have any thought about this? WARNING: Method signature invalid: static inline void Error (string s) Exception: |
Hi thanks for this amazing tool! I'm working on a C#/C++ Unity project and wanted some good docs so decided to use this.
I've added basic C# support via the sphinx-csharp package, which is a simple C# domain. I have also made several modifications there, see djungelorm/sphinx-csharp#8
I have got it to work quite well already, have a look here.
It was initially based it on the php domain PR #351, so it's also done as a optional part.
You can use these pip requirements.txt
Note: I'm still working on this, and there are some things that need to be fixed. Some parts related to the version/dependencies will be removed hopefully. Also fyi I haven't done much py/sphinx stuff yet.