-
Notifications
You must be signed in to change notification settings - Fork 1.7k
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
Missing spaces inside dt's #694
Comments
I have just started using Sphinx & Breathe (version as of Jun 1, 2020) to convert my Doxygen docs to the RTD theme. I'm also having this problem, where my C++ types and other identifiers have no spaces between them. |
Is there any progress on this one? |
Hi, can you paste the RST code to generate the issue. It makes testing for us easier. |
I'm using breathe's directives: .. doxygenfunction:: vtInitializeArray From the C function prototype documented with Doxygen: void vtInitializeArray(VTObj *obj, VTChar const *v); Note that
|
I'm experiencing the same issue, using Breathe to bridge Doxygen's XML to Sphinx. For those in need of a quick hack until this is fixed upstream: you can override the def setup(app):
app.add_css_file('path/to/style.css') Then in dt {
display: inline-block !important;
} |
I looked into this add found that fix however there are still some spacing issues because some elements manually add padding but its hard to make a CSS selector add padding to all the correct places, a bit more investigation is needed. |
For C and C++ declarations I believe the issue should be fixed from Sphinx v4, as the declarations are rendered using a new set of nodes. This includes all spaces being in spans instead of in the top-level dt (e.g., see breathe-doc/breathe#655 (comment)). |
Yes, this should now be fixed in newer sphinx versions. There are currently no intentions in fixing this for older versions so this issue can be closed. |
Problem
dt
s that contain formatting lose the spaces between their formatting.Reproducible Project
The pybind11 project uses Breathe to include Doxygen-generated C++ information in its docs. This should have spaces between the keywords and identifiers (e.g.,
iterator begin() const
). However, because thedt
is set asdisplay: table
, any internal spaces are lost, and the text shows asiteratorbegin()const
.See https://pybind11.readthedocs.io/en/master/reference.html#_CPPv3NK10object_api5beginEv for an example.
This problem was apparently introduced with #384's change from
display: inline-block
todisplay: table
(that was made to fix #90). If I undo the change from #384 (either by building the pybind11 docs with an older version of the theme or by using Chrome Dev Tools to change the style on the fly), the pybind11 docs look correct.I tinkered with styles some and couldn't find a way to fix both this problem and the problem from #384 without changing the HTML. For what it's worth, I noticed that the sample document that demonstrated #90 had updated its documentation style to no longer be affected by #90. I'm fairly new to RST, though, so I don't know which
.. data::
style is preferred.)Error Logs/Results
Current (bad) pybind11:
Expected Results
Building pybind11 with a
display: inline-block
:Environment Info
Here's the information for locally building the pybind11 docs (which does NOT demonstrate thisbug).
The text was updated successfully, but these errors were encountered: