-
-
Notifications
You must be signed in to change notification settings - Fork 5
Configuration options
- aliases
- author
- autolinks
- badges
- changelog
- code_blocks
- cpp
- description
- examples
- extra_files
- favicon
- generate_tagfile
- github
- gitlab
- html_header
- images
- implementation_headers
- inline_namespaces
- internal_docs
- jquery
- license
- logo
- macros
- meta_tags
- name
- navbar
- private_repo
- robots
- scripts
- show_includes
- sources
- stylesheets
- tagfiles
- theme
- warnings
Doxygen @command
aliases.
A table containing alias
⇒ substitution
mappings.
[aliases]
'make_link{1}' = '<a href="\1">\1</a>'
'make_link{2}' = '<a href="\1">\2</a>'
The author of the project.
A string
.
author = 'Mark Gillard'
Adds additional automatic hotlinking beyond what Doxygen and tagfiles can provide alone.
A table containing regex
⇒ uri
mappings. uri
can be local or a fully-qualified external link.
[autolinks]
'(?:toml::)?parse[_ ]results?' = 'classtoml_1_1parse__result.html'
'(?:toml::)?parse[_ ]errors?' = 'classtoml_1_1parse__error.html'
'(?:toml::)?node[_ ]views?' = 'classtoml_1_1node__view.html'
Adds shields.io-style badges under your main page's banner image.
A table containing description
⇒ [ image, uri ]
mappings. image
can be local or a fully-qualified external link.
[badges]
'C++20' = [ 'badge-C++20.svg', 'https://en.cppreference.com/w/cpp/compiler_support' ]
'TOML v1.0.0' = [ 'badge-TOML.svg', 'https://toml.io/en/v1.0.0' ]
Adds a changelog page and a link to it in the site footer.
A boolean
or explicit string
path to the changelog markdown file.
false
changelog = false # no changelog will be generated
changelog = true # find the changelog file in the poxy.toml directory or a parent
changelog = 'path/to/the/changelog.md'
When setting this value to true
, the library will search for the following filenames, in order:
CHANGELOG.md
CHANGELOG.txt
CHANGELOG
HISTORY.md
HISTORY.txt
HISTORY
Searching starts in the same directory as poxy.toml
, and continues up through parent directories until a match is found.
Note that the file is assumed to be plain-text and will be parsed as markdown. No other formats are supported.
A table of nested options for improving how <code>
blocks are rendered as HTML. See the specific entries below.
Injects additional enum values into the syntax highligher.
A single regex
or an array of regexes
.
namespace magic
{
enum class values
{
a,
b,
c,
COUNT
};
}
[code_blocks]
enums = [ 'magic::values::[a-zA-Z]+' ]
You do not need to add enum values from your own code or from the C++ standard library; Poxy does this for you.
Injects additional preprocessor macro #defines
into the syntax highlighter.
A single regex
or an array of regexes
.
[code_blocks]
macros = [ 'TOML_[A-Z0-9_]+?', 'print_value' ]
You generally do not need to add macros from your own code or C++ feature test macros since Poxy does this for you. That being said, given library-specific macros tend to be 'namespaced' using a common prefix, a catch-all regex can be a useful future-proofing mechanism.
Injects additional namespaces into the syntax highlighter.
A single regex
or an array of regexes
.
namespace magic
{
namespace more_magic { /* ... */ }
}
[code_blocks]
namespaces = [ 'magic(::more_magic)?' ]
You do not need to add namespaces from your own code or from the C++ standard library; Poxy does this for you.
Injects additional numeric literal operators into the syntax highlighter.
A single regex
or an array of regexes
.
constexpr uint64_t operator"" _u64 (unsigned long long n) noexcept
{
return static_cast<uint64_t>(n);
}
[code_blocks]
numeric_literals = [ '_u64' ]
Injects additional string literal operators into the syntax highlighter.
A single regex
or an array of regexes
.
void operator"" _print(const char* str)
{
std::cout << str << '\n';
}
[code_blocks]
string_literals = [ '_print' ]
Injects additional typenames into the syntax highlighter.
A single regex
or an array of regexes
.
[code_blocks]
types = [ 'my::namespace::(foo|bar)' ]
You do not need to add typenames from your own code or from the C++ standard library; Poxy does this for you.
Specifies the minimum C++ version your project targets. Effects:
- Adds a badge under your main page's banner image
- Dictates which C++ feature test macros are fed to Doxygen's preprocessor
A string
or integer
containing the C++ standard year as YYYY or YY, e.g. 2003
, 17
, '20'
, etc.
The current three-yearly C++ standard as if by (current year - 2)
.
cpp = 17
A brief description of the project.
A string
.
description = 'TOML for modern C++'
A table of nested options relating to Doxygen's discovery of example code for @include
, @snippet
, et cetera. See the specific entries below.
Specifies the input paths and file path filter patterns used by Doxygen to discover example code specified using
@include
, @snippet
, etc. Directories specified using recursive_paths
are searched recursively, while those
specified using paths
are only subject to shallow searches.
A single string
or an array of strings
.
-
paths
andrecursive_paths
: No paths are specified by default. -
patterns
:*
(all files are matched)
[examples]
paths = '../examples'
recursive_paths = [ '../../include', '../../src' ]
patterns = [ '*.h' , '*.cpp' ]
EXAMPLE_PATH
EXAMPLE_RECURSIVE
EXAMPLE_PATTERNS
A list of local files to copy verbatim to the output html
directory.
A single string
or an array of strings
.
extra_files = [
'images/banner_small.png',
'images/badge-awesome.svg',
'images/badge-TOML.svg',
'images/badge-C++20.svg'
]
Path to the icon file to use as the HTML site's favicon.
A string
.
favicon = 'images/favicon.ico'
Specifies whether a doxygen tagfile should be generated and linked to in HTML page footers.
A boolean
.
true
generate_tagfile = true
Specifies the GitHub or GitLab repository the project relates to. Effects:
- Adds a repository link to the navbar
- Adds repository and "Report an issue" links to the page footer
- Adds a "Releases" badge under the main page's banner (if
private_repo
isfalse
) - Linkifies issues (
#999
), users (@person
) and pull requests (!person
) in the changelog page whenchangelog
is used
A user/repository
string.
github = 'marzer/tomlplusplus'
Specify one or the other; do not specify both. If your project has a repository on both, specify only the one that is the main developer tree (i.e. not merely a mirror).
Adds an additional snippet of HTML to each page's <head>
section.
A single string
.
html_header = '''
<script> console.log("this is going to be ugly!"); </script>
<style> div { background-color: red; } </style>
''''
This option is exposed for more advanced scenarios since most things you'd typically put in a page's <head>
already have their own configuration options:
- Setting page title:
name
- Adding CSS stylesheets:
stylesheets
- Adding JS scripts:
scripts
- Adding page metadata (
<meta>
tags):meta_tags
- Controlling robots/scrapers:
robots
A table of nested options relating to Doxygen's discovery of image files for the @image
command.
See the specific entries below.
Specifies the input paths used by Doxygen to discover images specified using the @image
command.
Directories specified using recursive_paths
are searched recursively, while those specified using paths
are only subject to shallow searches.
A single string
or an array of strings
.
[images]
paths = '../images'
# recursive_paths = [ ]
Folds documentation from internal implementation headers up into the public header they support.
A table containing header
⇒ impl header
mappings.
Given a project with the following structure:
/include
/impl
strings_utf8.h
strings_utf16.h
strings_utf32.h
strings.h
To have all documentation parsed from the /impl/strings_XXXX.h
headers appear as though it were
actually from strings.h
:
[implementation_headers]
'include/strings.h' = [
'include/impl/strings_utf8.h',
'include/impl/strings_utf16.h',
'include/impl/strings_utf32.h'
]
Tells Doxygen which namespaces are inline namespaces
, since older versions of Doxygen would lose this information.
A single string
or an array of strings
.
inline_namespaces = [ 'toml::literals' ]
This property is unnecessary if you're using Doxygen 1.8.19 or later.
Specifies that the documentation generated from this config file is 'internal'. Effects:
-
true
:- Sets Doxygen's INTERNAL_DOCS to
YES
- Adds
private
andinternal
to Doxygen's ENABLED_SECTIONS
- Sets Doxygen's INTERNAL_DOCS to
-
false
:- Sets Doxygen's INTERNAL_DOCS to
NO
- Adds
public
andexternal
to Doxygen's ENABLED_SECTIONS
- Sets Doxygen's INTERNAL_DOCS to
A boolean
.
false
internal_docs = false
ENABLED_SECTIONS
INTERNAL_DOCS
Specifies whether jQuery should be included as part of the generated HTML.
A boolean
false
jquery = true
Poxy itself does not (currently) make use of jQuery; this is provided as a convenience if you wish to make use of it
in additional script files added via scripts
. Setting this to true
if you do not intend to add any of your own
custom javascript serves no purpose.
Specifies the license used by the project. Effects:
- Adds a license link to the HTML page footer
- Adds a badge under your main page's banner image
An [ SDPX, uri ]
pair.
uri
can be local or a fully-qualified external link.
license = [ 'MIT', 'https://github.com/marzer/tomlplusplus/blob/master/LICENSE' ]
Specifies the project logo image to feature in the HTML navbar.
A string
.
logo = 'images/logo.png'
Specifies additional macros to pass to Doxygen's preprocessor. Also makes these definitions known to the syntax highlighter.
A table containing macro
⇒ expansion
mappings.
[macros]
'TOML_ASYMMETRICAL_EQUALITY_OPS(...)' = 'static_assert(true)'
'TOML_ABI_NAMESPACE_START(...)' = 'static_assert(true)'
'TOML_ABI_NAMESPACE_BOOL(...)' = 'static_assert(true)'
In addition to the C++ feature test macros, Poxy automatically defines many 'built-in' macros for you:
macro | expansion |
---|---|
NDEBUG |
1 |
DOXYGEN |
1 |
__DOXYGEN__ |
1 |
__doxygen__ |
1 |
__POXY__ |
1 |
__poxy__ |
1 |
__has_builtin(...) |
0 |
__has_feature(...) |
0 |
__has_include(...) |
0 |
__has_attribute(...) |
0 |
__has_cpp_attribute(...) |
999999 |
__cplusplus |
the standard value per cpp
|
Specifies addititional <meta>
tags to add to the generated HTML <head>
.
A table of name
⇒ content
mappings, where content
may be a string
or an integer
.
[meta_tags]
'google-site-verification' = 'kjnwnkj234njk324wefknsdf'
The name of the project.
A string
.
name = 'toml++'
Specifies what appears on the navbar of each HTML page.
A single string
or list of strings
:
Value | Links to |
---|---|
annotated |
Same as classes
|
classes |
Project class and struct index page |
files |
Project file hierarchy index page (per Doxygen's @file command ) |
github |
Project github repository (per config option github ). |
groups |
Index of function and type groups created using @addgroup , @ingroup , etc. |
modules |
Same as groups
|
namespaces |
Project namespace index page |
pages |
Index of articles created using @mainpage , @page , etc. |
<a href=""></a> |
Custom anchor tags can be added directly. |
files
, groups
, namespaces
, classes
and github
(if a repository is specified).
navbar = [ 'namespaces', 'classes' ]
The github
link is always added if a repository is specified, though you can explicitly specify it yourself
if you wish to change its position on the navbar.
M_LINKS_NAVBAR1
M_LINKS_NAVBAR2
Specifies whether the Github repository for this project is private.
A boolean
.
false
private_repo = false
Specifies whether search 'bots' and webcrawlers should interact with the generated HTML.
A boolean
.
true
robots = true
A list of javascript files to include as <script>
tags in the <head>
of each generated HTML page.
A single string
or an array of strings
.
scripts = [
'some_local_script.js',
'https://code.jquery.com/jquery-3.6.0.min.js'
]
Any local files will be copied to the output directory as if by adding them to extra_files
.
Specifies whether #include
directives should be shown in HTML pages.
A boolean
.
true
show_includes = true
A table of nested options relating to Doxygen's discovery and handling of source files. See the specific entries below.
Default behaviour is to only emit documentation for explicitly documented symbols to encourage careful, selective
documentation practices. Override this by setting sources.extract_all
to true
.
A boolean
false
[sources]
extract_all = true
Specifies the input paths and file path filter patterns used by Doxygen to discover documentation source files.
Directories specified using recursive_paths
are searched recursively, while those specified using paths
are only subject to shallow searches.
A single string
or an array of strings
.
-
paths
andrecursive_paths
: No paths are specified by default. -
patterns
:*.h
,*.hh
,*.hxx
,*.hpp
,*.h++
,*.inc
,*.markdown
,*.md
,*.dox
[sources]
paths = 'pages'
recursive_paths = [ '../include' ]
patterns = [ '*.h' , '*.dox' ]
Specifies path prefixes to strip from file paths emitted in documentation.
A single string
or an array of strings
.
[sources]
strip_paths = [ '../include' ]
Specifies path prefixes to strip from #include <path/to/header.h>
directives emitted in documentation.
A single string
or an array of strings
.
[sources]
strip_includes = 'include/'
This property is applied after sources.strip_paths
; the final rendered version of #include
directives is a
combination of both options.
A list of CSS files to include as <link>
tags in the <head>
of each generated HTML page.
A single string
or an array of strings
.
stylesheets = [
'my_fancy_styles.css',
'https://fonts.googleapis.com/css?family=Source+Sans+Pro:400,400i,600,600i%7CSource+Code+Pro:400,400i,600'
]
Any local files will be copied to the output directory as if by adding them to extra_files
.
Specifies additional tagfiles for Doxygen to use during documentation generation.
A table of tagfile
⇒ base_uri
mappings. tagfile
can be local or a fully-qualified external link
to a web resource (in which case it is downloaded and cached locally).
[tagfiles]
'https://marzer.github.io/tomlplusplus/tomlplusplus.tagfile.xml' = 'https://marzer.github.io/tomlplusplus/'
You don't need to apply the C++ standard library tagfile from cppreference.com; Poxy automatically does this for you.
Specifies the default visual theme to use in the generated HTML pages.
A string
. May be one of the following values:
light
dark
dark
theme = 'light'
As of v0.7.0 this option only controls the default theme to use, with there being a navbar button for users to switch between light and dark as they please.
A table of nested options relating to the handling of warnings. See the specific entries below.
Controls the emission of all warnings.
A boolean
.
true
[warnings]
enabled = true
Specifies whether warnings should be treated as errors and cause Poxy to exit with an error code.
A boolean
.
false
[warnings]
treat_as_errors = true
You can also enable this on the command-line using --werror
.
The command-line option always takes precedence over config files.
Specifies if undocumented classes, types, defines etc. should cause Doxygen to emit warnings.
A boolean
.
true
[warnings]
undocumented = false