Skip to content

Commit b360305

Browse files
authored
Merge pull request #785 from readthedocs/style-cpp-domain
Fix styling of generated cpp documentation
2 parents 7e0d793 + 10d9f51 commit b360305

File tree

2 files changed

+24
-5
lines changed

2 files changed

+24
-5
lines changed

docs/demo/api.rst

Lines changed: 23 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,34 @@
1-
2-
*********************
3-
:mod:`test_py_module`
4-
*********************
1+
***************************************
2+
API documentation and generated content
3+
***************************************
54

65
.. contents:: Table of Contents
76

7+
:mod:`test_py_module`
8+
=====================
9+
810
.. automodule:: test_py_module.test
911
:members:
1012
:private-members:
1113
:special-members:
1214

15+
16+
C++ API
17+
=======
18+
19+
.. cpp:type:: MyType
20+
21+
Some type
22+
23+
.. cpp:function:: const MyType Foo(const MyType bar)
24+
25+
Some function type thing
26+
27+
.. cpp:class:: template<typename T, std::size_t N> std::array
28+
29+
Some cpp class
30+
31+
1332
Generated Index
1433
===============
1534

src/sass/_theme_rst.sass

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -328,7 +328,7 @@
328328
// that output similar, but not quite the same nesting so this is really the best we can do.
329329
dl:not(.docutils)
330330
// In Sphinx 2.0+ most DLs no longer contain .docutils, needs tighter scoping using next line
331-
&.class, &.data
331+
&.class, &.data, &.type, &.function
332332
margin-bottom: $base-line-height
333333
// This would be the equivilant of a .. class::
334334
dt

0 commit comments

Comments
 (0)