Sphinx theme with breathe support #824
Replies: 3 comments 5 replies
-
@dantownsend Thanks for sharing! @2bndy5 FYI Considering recent work in #820 you might find something useful here. The Piccolo ref is piccolo-orm/piccolo_theme#17. |
Beta Was this translation helpful? Give feedback.
-
I also help maintain the sphinx theme called sphinx-immaterial. And the only reason I didn't recommend that theme is because how the C/C++ API ends up looking for multi-line/long signatures. In sphinx-immaterial, we also try to put long signatures (identified as anything over 72 characters) into multiple lines. But so far our approach has been purely CSS. We would prefer a more programmatic approach, but that would have to be very language (also known in sphinx as "domain") dependent. @dantownsend your theme does use a programmatic approach in long signatures (exclusively for py and cpp domains only), but it does that using JS to alter the live I don't mean to sound completely negative, rather I found the approach a bit inspiring. I foresee the JS approach working with template parameters as well. And it doesn't care about the length of the signature - all signatures get multiple lines if there are at least 2 parenthesises (identified as CSS class After looking through the code and the demo, I'm not going to change my proposal to use the furo theme because that theme is just more "seasoned". The piccolo theme has some material design aesthetics that haven't been implemented |
Beta Was this translation helpful? Give feedback.
-
Ironically, I recently had to use a similar JS-based approach when developing a theme for Doxygen HTML output. There's a feature slated for Doxygen v2.0 that should allow using template engines like Django or Jinja. Such a feature may deem this breathe extension as a less ideal solution to prettify Doxygen's horrid default HTML output 🤞 |
Beta Was this translation helpful? Give feedback.
-
Hi! I maintain a Sphinx theme called Piccolo theme.
In the latest version, a contributor added some custom JS and CSS to make C++ snippets from breathe look nice. Here's a demo.
Just sharing in case it's useful for others, thanks!
Beta Was this translation helpful? Give feedback.
All reactions