mirror of
https://github.com/zeek/zeek.git
synced 2025-10-16 05:28:20 +00:00
Teach Desc class how to (optionally) use spaces for indentation.
And (to be consistent with current conventions for reST documentation) update places in the auto-documentation-generation framework where tabs were used in the generated reST.
This commit is contained in:
parent
e491caeeb7
commit
5fbcde7344
5 changed files with 19 additions and 7 deletions
|
@ -22,17 +22,18 @@ BroDocObj::~BroDocObj()
|
|||
void BroDocObj::WriteReST(FILE* file) const
|
||||
{
|
||||
ODesc desc;
|
||||
desc.SetIndentSpaces(4);
|
||||
desc.SetQuotes(1);
|
||||
broID->DescribeReST(&desc);
|
||||
fprintf(file, "%s\n", desc.Description());
|
||||
|
||||
if ( HasDocumentation() )
|
||||
{
|
||||
fprintf(file, "\t.. bro:comment::\n");
|
||||
fprintf(file, "\n");
|
||||
std::list<std::string>::const_iterator it;
|
||||
for ( it = reST_doc_strings->begin();
|
||||
it != reST_doc_strings->end(); ++it)
|
||||
fprintf(file, "\t\t%s\n", it->c_str());
|
||||
fprintf(file, " %s\n", it->c_str());
|
||||
}
|
||||
|
||||
fprintf(file, "\n");
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue