|
Packit |
1c1d7e |
/******************************************************************************
|
|
Packit |
1c1d7e |
*
|
|
Packit |
1c1d7e |
*
|
|
Packit |
1c1d7e |
*
|
|
Packit |
1c1d7e |
* Copyright (C) 1997-2015 by Dimitri van Heesch.
|
|
Packit |
1c1d7e |
*
|
|
Packit |
1c1d7e |
* Permission to use, copy, modify, and distribute this software and its
|
|
Packit |
1c1d7e |
* documentation under the terms of the GNU General Public License is hereby
|
|
Packit |
1c1d7e |
* granted. No representations are made about the suitability of this software
|
|
Packit |
1c1d7e |
* for any purpose. It is provided "as is" without express or implied warranty.
|
|
Packit |
1c1d7e |
* See the GNU General Public License for more details.
|
|
Packit |
1c1d7e |
*
|
|
Packit |
1c1d7e |
* Documents produced by Doxygen are derivative works derived from the
|
|
Packit |
1c1d7e |
* input used in their production; they are not affected by this license.
|
|
Packit |
1c1d7e |
*
|
|
Packit |
1c1d7e |
*/
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
#ifndef OUTPUTGEN_H
|
|
Packit |
1c1d7e |
#define OUTPUTGEN_H
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
#include <qstack.h>
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
#include "index.h"
|
|
Packit |
1c1d7e |
#include "section.h"
|
|
Packit |
1c1d7e |
#include "ftextstream.h"
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
class ClassDiagram;
|
|
Packit |
1c1d7e |
class DotClassGraph;
|
|
Packit |
1c1d7e |
class DotInclDepGraph;
|
|
Packit |
1c1d7e |
class DotCallGraph;
|
|
Packit |
1c1d7e |
class DotDirDeps;
|
|
Packit |
1c1d7e |
class DotGfxHierarchyTable;
|
|
Packit |
1c1d7e |
class DotGroupCollaboration;
|
|
Packit |
1c1d7e |
class DocNode;
|
|
Packit |
1c1d7e |
class MemberDef;
|
|
Packit |
1c1d7e |
class GroupDef;
|
|
Packit |
1c1d7e |
class Definition;
|
|
Packit |
1c1d7e |
class QFile;
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
struct DocLinkInfo
|
|
Packit |
1c1d7e |
{
|
|
Packit |
1c1d7e |
QCString name;
|
|
Packit |
1c1d7e |
QCString ref;
|
|
Packit |
1c1d7e |
QCString url;
|
|
Packit |
1c1d7e |
QCString anchor;
|
|
Packit |
1c1d7e |
};
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
struct SourceLinkInfo
|
|
Packit |
1c1d7e |
{
|
|
Packit |
1c1d7e |
QCString file;
|
|
Packit |
1c1d7e |
int line;
|
|
Packit |
1c1d7e |
QCString ref;
|
|
Packit |
1c1d7e |
QCString url;
|
|
Packit |
1c1d7e |
QCString anchor;
|
|
Packit |
1c1d7e |
};
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
/** Output interface for code parser.
|
|
Packit |
1c1d7e |
*/
|
|
Packit |
1c1d7e |
class CodeOutputInterface
|
|
Packit |
1c1d7e |
{
|
|
Packit |
1c1d7e |
public:
|
|
Packit |
1c1d7e |
virtual ~CodeOutputInterface() {}
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
/*! Writes an code fragment to the output. This function should keep
|
|
Packit |
1c1d7e |
* spaces visible, should break lines at a newline and should convert
|
|
Packit |
1c1d7e |
* tabs to the right number of spaces.
|
|
Packit |
1c1d7e |
*/
|
|
Packit |
1c1d7e |
virtual void codify(const char *s) = 0;
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
/*! Writes a link to an object in a code fragment.
|
|
Packit |
1c1d7e |
* \param ref If this is non-zero, the object is to be found in
|
|
Packit |
1c1d7e |
* an external documentation file.
|
|
Packit |
1c1d7e |
* \param file The file in which the object is located.
|
|
Packit |
1c1d7e |
* \param anchor The anchor uniquely identifying the object within
|
|
Packit |
1c1d7e |
* the file.
|
|
Packit |
1c1d7e |
* \param name The text to display as a placeholder for the link.
|
|
Packit |
1c1d7e |
* \param tooltip The tooltip to display when the mouse is on the link.
|
|
Packit |
1c1d7e |
*/
|
|
Packit |
1c1d7e |
virtual void writeCodeLink(const char *ref,const char *file,
|
|
Packit |
1c1d7e |
const char *anchor,const char *name,
|
|
Packit |
1c1d7e |
const char *tooltip) = 0;
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
/*! Writes the line number of a source listing
|
|
Packit |
1c1d7e |
* \param ref External reference (when imported from a tag file)
|
|
Packit |
1c1d7e |
* \param file The file part of the URL pointing to the docs.
|
|
Packit |
1c1d7e |
* \param anchor The anchor part of the URL pointing to the docs.
|
|
Packit |
1c1d7e |
* \param lineNumber The line number to write
|
|
Packit |
1c1d7e |
*/
|
|
Packit |
1c1d7e |
virtual void writeLineNumber(const char *ref,const char *file,
|
|
Packit |
1c1d7e |
const char *anchor,int lineNumber) = 0;
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
/*! Writes a tool tip definition
|
|
Packit |
1c1d7e |
* \param id unique identifier for the tooltip
|
|
Packit |
1c1d7e |
* \param docInfo Info about the symbol's documentation.
|
|
Packit |
1c1d7e |
* \param decl full declaration of the symbol (for functions)
|
|
Packit |
1c1d7e |
* \param desc brief description for the symbol
|
|
Packit |
1c1d7e |
* \param defInfo Info about the symbol's definition in the source code
|
|
Packit |
1c1d7e |
* \param declInfo Info about the symbol's declaration in the source code
|
|
Packit |
1c1d7e |
*/
|
|
Packit |
1c1d7e |
virtual void writeTooltip(const char *id,
|
|
Packit |
1c1d7e |
const DocLinkInfo &docInfo,
|
|
Packit |
1c1d7e |
const char *decl,
|
|
Packit |
1c1d7e |
const char *desc,
|
|
Packit |
1c1d7e |
const SourceLinkInfo &defInfo,
|
|
Packit |
1c1d7e |
const SourceLinkInfo &declInfo
|
|
Packit |
1c1d7e |
) = 0;
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
virtual void startCodeLine(bool hasLineNumbers) = 0;
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
/*! Ends a line of code started with startCodeLine() */
|
|
Packit |
1c1d7e |
virtual void endCodeLine() = 0;
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
/*! Starts a block with a certain meaning. Used for syntax highlighting,
|
|
Packit |
1c1d7e |
* which elements of the same type are rendered using the same 'font class'.
|
|
Packit |
1c1d7e |
* \param clsName The category name.
|
|
Packit |
1c1d7e |
*/
|
|
Packit |
1c1d7e |
virtual void startFontClass(const char *clsName) = 0;
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
/*! Ends a block started with startFontClass() */
|
|
Packit |
1c1d7e |
virtual void endFontClass() = 0;
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
/*! Write an anchor to a source listing.
|
|
Packit |
1c1d7e |
* \param name The name of the anchor.
|
|
Packit |
1c1d7e |
*/
|
|
Packit |
1c1d7e |
virtual void writeCodeAnchor(const char *name) = 0;
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
virtual void setCurrentDoc(Definition *context,const char *anchor,bool isSourceFile) = 0;
|
|
Packit |
1c1d7e |
virtual void addWord(const char *word,bool hiPriority) = 0;
|
|
Packit |
1c1d7e |
};
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
/** Base Interface used for generating output outside of the
|
|
Packit |
1c1d7e |
* comment blocks.
|
|
Packit |
1c1d7e |
*
|
|
Packit |
1c1d7e |
* This abstract class is used by output generation functions
|
|
Packit |
1c1d7e |
* to generate the output for a specific format,
|
|
Packit |
1c1d7e |
* or a list of formats (see OutputList). This interface
|
|
Packit |
1c1d7e |
* contains functions that generate fragments of the output.
|
|
Packit |
1c1d7e |
*/
|
|
Packit |
1c1d7e |
class BaseOutputDocInterface : public CodeOutputInterface
|
|
Packit |
1c1d7e |
{
|
|
Packit |
1c1d7e |
public:
|
|
Packit |
1c1d7e |
virtual ~BaseOutputDocInterface() {}
|
|
Packit |
1c1d7e |
enum ParamListTypes { Param, RetVal, Exception };
|
|
Packit |
1c1d7e |
enum SectionTypes { /*See, Return, Author, Version,
|
|
Packit |
1c1d7e |
Since, Date, Bug, Note,
|
|
Packit |
1c1d7e |
Warning, Par, Deprecated, Pre,
|
|
Packit |
1c1d7e |
Post, Invar, Remark, Attention,
|
|
Packit |
1c1d7e |
Todo, Test, RCS, */ EnumValues,
|
|
Packit |
1c1d7e |
Examples
|
|
Packit |
1c1d7e |
};
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
virtual bool parseText(const QCString &s) { return s.isEmpty(); }
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
/*! Start of a bullet list: e.g. \c \<ul\> in html. startItemListItem() is
|
|
Packit |
1c1d7e |
* Used for the bullet items.
|
|
Packit |
1c1d7e |
*/
|
|
Packit |
1c1d7e |
virtual void startItemList() = 0;
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
/*! Writes a list item for a bullet or enumerated
|
|
Packit |
1c1d7e |
* list: e.g. \c \<li\> in html
|
|
Packit |
1c1d7e |
*/
|
|
Packit |
1c1d7e |
virtual void startItemListItem() = 0;
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
/*! Writes a list item for a bullet or enumerated
|
|
Packit |
1c1d7e |
* list: e.g. \c \</li\> in html
|
|
Packit |
1c1d7e |
*/
|
|
Packit |
1c1d7e |
virtual void endItemListItem() = 0;
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
/*! Ends a bullet list: e.g. \c \</ul\> in html */
|
|
Packit |
1c1d7e |
virtual void endItemList() = 0;
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
/*! Writes an ASCII string to the output. Converts characters that have
|
|
Packit |
1c1d7e |
* A special meaning, like \c & in html.
|
|
Packit |
1c1d7e |
*/
|
|
Packit |
1c1d7e |
virtual void docify(const char *s) = 0;
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
/*! Writes a single ASCII character to the output. Converts characters
|
|
Packit |
1c1d7e |
* that have a special meaning.
|
|
Packit |
1c1d7e |
*/
|
|
Packit |
1c1d7e |
virtual void writeChar(char c) = 0;
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
/*! Writes an ASCII string to the output, \e without converting
|
|
Packit |
1c1d7e |
* special characters.
|
|
Packit |
1c1d7e |
*/
|
|
Packit |
1c1d7e |
virtual void writeString(const char *text) = 0;
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
/*! Starts a new paragraph */
|
|
Packit |
1c1d7e |
//virtual void newParagraph() = 0;
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
/*! Starts a new paragraph */
|
|
Packit |
1c1d7e |
virtual void startParagraph(const char *classDef) = 0;
|
|
Packit |
1c1d7e |
/*! Ends a paragraph */
|
|
Packit |
1c1d7e |
virtual void endParagraph() = 0;
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
/*! Writes a link to an object in the documentation.
|
|
Packit |
1c1d7e |
* \param ref If this is non-zero, the object is to be found in
|
|
Packit |
1c1d7e |
* an external documentation file.
|
|
Packit |
1c1d7e |
* \param file The file in which the object is located.
|
|
Packit |
1c1d7e |
* \param anchor The anchor uniquely identifying the object within
|
|
Packit |
1c1d7e |
* the file.
|
|
Packit |
1c1d7e |
* \param name The text to display as a placeholder for the link.
|
|
Packit |
1c1d7e |
*/
|
|
Packit |
1c1d7e |
virtual void writeObjectLink(const char *ref,const char *file,
|
|
Packit |
1c1d7e |
const char *anchor, const char *name) = 0;
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
/*! Starts a (link to an) URL found in the documentation.
|
|
Packit |
1c1d7e |
* \param url The URL to link to.
|
|
Packit |
1c1d7e |
*/
|
|
Packit |
1c1d7e |
virtual void startHtmlLink(const char *url) = 0;
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
/*! Ends a link started by startHtmlLink().
|
|
Packit |
1c1d7e |
*/
|
|
Packit |
1c1d7e |
virtual void endHtmlLink() = 0;
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
/*! Changes the text font to bold face. The bold section ends with
|
|
Packit |
1c1d7e |
* endBold()
|
|
Packit |
1c1d7e |
*/
|
|
Packit |
1c1d7e |
virtual void startBold() = 0;
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
/*! End a section of text displayed in bold face. */
|
|
Packit |
1c1d7e |
virtual void endBold() = 0;
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
/*! Changes the text font to fixed size. The section ends with
|
|
Packit |
1c1d7e |
* endTypewriter()
|
|
Packit |
1c1d7e |
*/
|
|
Packit |
1c1d7e |
virtual void startTypewriter() = 0;
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
/*! End a section of text displayed in typewriter style. */
|
|
Packit |
1c1d7e |
virtual void endTypewriter() = 0;
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
/*! Changes the text font to italic. The italic section ends with
|
|
Packit |
1c1d7e |
* endEmphasis()
|
|
Packit |
1c1d7e |
*/
|
|
Packit |
1c1d7e |
virtual void startEmphasis() = 0;
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
/*! Ends a section of text displayed in italic. */
|
|
Packit |
1c1d7e |
virtual void endEmphasis() = 0;
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
/*! Starts a source code fragment. The fragment will be
|
|
Packit |
1c1d7e |
* fed to the code parser (see code.h) for syntax highlighting
|
|
Packit |
1c1d7e |
* and cross-referencing. The fragment ends by a call to
|
|
Packit |
1c1d7e |
* endCodeFragment()
|
|
Packit |
1c1d7e |
*/
|
|
Packit |
1c1d7e |
virtual void startCodeFragment() = 0;
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
/*! Ends a source code fragment
|
|
Packit |
1c1d7e |
*/
|
|
Packit |
1c1d7e |
virtual void endCodeFragment() = 0;
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
/*! Writes a horizontal ruler to the output */
|
|
Packit |
1c1d7e |
virtual void writeRuler() = 0;
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
/*! Starts a description list: e.g. \c \<dl\> in HTML
|
|
Packit |
1c1d7e |
* Items are surrounded by startDescItem() and endDescItem()
|
|
Packit |
1c1d7e |
*/
|
|
Packit |
1c1d7e |
virtual void startDescription() = 0;
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
/*! Ends a description list: e.g. \c \</dl\> in HTML */
|
|
Packit |
1c1d7e |
virtual void endDescription() = 0;
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
/*! Starts an item of a description list: e.g. \c \<dt\> in HTML. */
|
|
Packit |
1c1d7e |
virtual void startDescItem() = 0;
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
virtual void startDescForItem() = 0;
|
|
Packit |
1c1d7e |
virtual void endDescForItem() = 0;
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
/*! Ends an item of a description list and starts the
|
|
Packit |
1c1d7e |
* description itself: e.g. \c \</dt\> in HTML.
|
|
Packit |
1c1d7e |
*/
|
|
Packit |
1c1d7e |
virtual void endDescItem() = 0;
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
virtual void startCenter() = 0;
|
|
Packit |
1c1d7e |
virtual void endCenter() = 0;
|
|
Packit |
1c1d7e |
virtual void startSmall() = 0;
|
|
Packit |
1c1d7e |
virtual void endSmall() = 0;
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
virtual void startSimpleSect(SectionTypes t,const char *file,
|
|
Packit |
1c1d7e |
const char *anchor,const char *title) = 0;
|
|
Packit |
1c1d7e |
virtual void endSimpleSect() = 0;
|
|
Packit |
1c1d7e |
virtual void startParamList(ParamListTypes t,const char *title) = 0;
|
|
Packit |
1c1d7e |
virtual void endParamList() = 0;
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
//virtual void writeDescItem() = 0;
|
|
Packit |
1c1d7e |
virtual void startTitle() = 0;
|
|
Packit |
1c1d7e |
virtual void endTitle() = 0;
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
virtual void writeAnchor(const char *fileName,const char *name) = 0;
|
|
Packit |
1c1d7e |
virtual void startSection(const char *,const char *,SectionInfo::SectionType) = 0;
|
|
Packit |
1c1d7e |
virtual void endSection(const char *,SectionInfo::SectionType) = 0;
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
virtual void lineBreak(const char *style) = 0;
|
|
Packit |
1c1d7e |
virtual void addIndexItem(const char *s1,const char *s2) = 0;
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
virtual void writeNonBreakableSpace(int) = 0;
|
|
Packit |
1c1d7e |
virtual void startDescTable(const char *title) = 0;
|
|
Packit |
1c1d7e |
virtual void endDescTable() = 0;
|
|
Packit |
1c1d7e |
virtual void startDescTableRow() = 0;
|
|
Packit |
1c1d7e |
virtual void endDescTableRow() = 0;
|
|
Packit |
1c1d7e |
virtual void startDescTableTitle() = 0;
|
|
Packit |
1c1d7e |
virtual void endDescTableTitle() = 0;
|
|
Packit |
1c1d7e |
virtual void startDescTableData() = 0;
|
|
Packit |
1c1d7e |
virtual void endDescTableData() = 0;
|
|
Packit |
1c1d7e |
virtual void startTextLink(const char *file,const char *anchor) = 0;
|
|
Packit |
1c1d7e |
virtual void endTextLink() = 0;
|
|
Packit |
1c1d7e |
virtual void startPageRef() = 0;
|
|
Packit |
1c1d7e |
virtual void endPageRef(const char *,const char *) = 0;
|
|
Packit |
1c1d7e |
virtual void startSubsection() = 0;
|
|
Packit |
1c1d7e |
virtual void endSubsection() = 0;
|
|
Packit |
1c1d7e |
virtual void startSubsubsection() = 0;
|
|
Packit |
1c1d7e |
virtual void endSubsubsection() = 0;
|
|
Packit |
1c1d7e |
};
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
/** Abstract output generator.
|
|
Packit |
1c1d7e |
*
|
|
Packit |
1c1d7e |
* Subclass this class to add support for a new output format
|
|
Packit |
1c1d7e |
*/
|
|
Packit |
1c1d7e |
class OutputGenerator : public BaseOutputDocInterface
|
|
Packit |
1c1d7e |
{
|
|
Packit |
1c1d7e |
public:
|
|
Packit |
1c1d7e |
enum OutputType { Html, Latex, Man, RTF, XML, DEF, Perl };
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
OutputGenerator();
|
|
Packit |
1c1d7e |
virtual ~OutputGenerator();
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
///////////////////////////////////////////////////////////////
|
|
Packit |
1c1d7e |
// generic generator methods
|
|
Packit |
1c1d7e |
///////////////////////////////////////////////////////////////
|
|
Packit |
1c1d7e |
virtual void enable() = 0;
|
|
Packit |
1c1d7e |
virtual void disable() = 0;
|
|
Packit |
1c1d7e |
virtual void enableIf(OutputType o) = 0;
|
|
Packit |
1c1d7e |
virtual void disableIf(OutputType o) = 0;
|
|
Packit |
1c1d7e |
virtual void disableIfNot(OutputType o) = 0;
|
|
Packit |
1c1d7e |
virtual bool isEnabled(OutputType o) = 0;
|
|
Packit |
1c1d7e |
virtual OutputGenerator *get(OutputType o) = 0;
|
|
Packit |
1c1d7e |
void startPlainFile(const char *name);
|
|
Packit |
1c1d7e |
void endPlainFile();
|
|
Packit |
1c1d7e |
//QCString getContents() const;
|
|
Packit |
1c1d7e |
bool isEnabled() const { return active; }
|
|
Packit |
1c1d7e |
void pushGeneratorState();
|
|
Packit |
1c1d7e |
void popGeneratorState();
|
|
Packit |
1c1d7e |
//void setEncoding(const QCString &enc) { encoding = enc; }
|
|
Packit |
1c1d7e |
//virtual void postProcess(QByteArray &) { }
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
virtual void writeDoc(DocNode *,Definition *ctx,MemberDef *md) = 0;
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
///////////////////////////////////////////////////////////////
|
|
Packit |
1c1d7e |
// structural output interface
|
|
Packit |
1c1d7e |
///////////////////////////////////////////////////////////////
|
|
Packit |
1c1d7e |
virtual void startFile(const char *name,const char *manName,
|
|
Packit |
1c1d7e |
const char *title) = 0;
|
|
Packit |
1c1d7e |
virtual void writeSearchInfo() = 0;
|
|
Packit |
1c1d7e |
virtual void writeFooter(const char *navPath) = 0;
|
|
Packit |
1c1d7e |
virtual void endFile() = 0;
|
|
Packit |
1c1d7e |
virtual void startIndexSection(IndexSections) = 0;
|
|
Packit |
1c1d7e |
virtual void endIndexSection(IndexSections) = 0;
|
|
Packit |
1c1d7e |
virtual void writePageLink(const char *,bool) = 0;
|
|
Packit |
1c1d7e |
virtual void startProjectNumber() = 0;
|
|
Packit |
1c1d7e |
virtual void endProjectNumber() = 0;
|
|
Packit |
1c1d7e |
virtual void writeStyleInfo(int part) = 0;
|
|
Packit |
1c1d7e |
virtual void startTitleHead(const char *) = 0;
|
|
Packit |
1c1d7e |
virtual void endTitleHead(const char *fileName,const char *name) = 0;
|
|
Packit |
1c1d7e |
virtual void startIndexListItem() = 0;
|
|
Packit |
1c1d7e |
virtual void endIndexListItem() = 0;
|
|
Packit |
1c1d7e |
virtual void startIndexList() = 0;
|
|
Packit |
1c1d7e |
virtual void endIndexList() = 0;
|
|
Packit |
1c1d7e |
virtual void startIndexKey() = 0;
|
|
Packit |
1c1d7e |
virtual void endIndexKey() = 0;
|
|
Packit |
1c1d7e |
virtual void startIndexValue(bool) = 0;
|
|
Packit |
1c1d7e |
virtual void endIndexValue(const char *,bool) = 0;
|
|
Packit |
1c1d7e |
virtual void startIndexItem(const char *ref,const char *file) = 0;
|
|
Packit |
1c1d7e |
virtual void endIndexItem(const char *ref,const char *file) = 0;
|
|
Packit |
1c1d7e |
virtual void startGroupHeader(int) = 0;
|
|
Packit |
1c1d7e |
virtual void endGroupHeader(int) = 0;
|
|
Packit |
1c1d7e |
virtual void startMemberSections() = 0;
|
|
Packit |
1c1d7e |
virtual void endMemberSections() = 0;
|
|
Packit |
1c1d7e |
virtual void startHeaderSection() = 0;
|
|
Packit |
1c1d7e |
virtual void endHeaderSection() = 0;
|
|
Packit |
1c1d7e |
virtual void startMemberHeader(const char *anchor) = 0;
|
|
Packit |
1c1d7e |
virtual void endMemberHeader() = 0;
|
|
Packit |
1c1d7e |
virtual void startMemberSubtitle() = 0;
|
|
Packit |
1c1d7e |
virtual void endMemberSubtitle() = 0;
|
|
Packit |
1c1d7e |
virtual void startMemberDocList() = 0;
|
|
Packit |
1c1d7e |
virtual void endMemberDocList() = 0;
|
|
Packit |
1c1d7e |
virtual void startMemberList() = 0;
|
|
Packit |
1c1d7e |
virtual void endMemberList() = 0;
|
|
Packit |
1c1d7e |
virtual void startInlineHeader() = 0;
|
|
Packit |
1c1d7e |
virtual void endInlineHeader() = 0;
|
|
Packit |
1c1d7e |
virtual void startAnonTypeScope(int) = 0;
|
|
Packit |
1c1d7e |
virtual void endAnonTypeScope(int) = 0;
|
|
Packit |
1c1d7e |
virtual void startMemberItem(const char *,int,const char *) = 0;
|
|
Packit |
1c1d7e |
virtual void endMemberItem() = 0;
|
|
Packit |
1c1d7e |
virtual void startMemberTemplateParams() = 0;
|
|
Packit |
1c1d7e |
virtual void endMemberTemplateParams(const char *,const char *) = 0;
|
|
Packit |
1c1d7e |
virtual void startMemberGroupHeader(bool) = 0;
|
|
Packit |
1c1d7e |
virtual void endMemberGroupHeader() = 0;
|
|
Packit |
1c1d7e |
virtual void startMemberGroupDocs() = 0;
|
|
Packit |
1c1d7e |
virtual void endMemberGroupDocs() = 0;
|
|
Packit |
1c1d7e |
virtual void startMemberGroup() = 0;
|
|
Packit |
1c1d7e |
virtual void endMemberGroup(bool) = 0;
|
|
Packit |
1c1d7e |
virtual void insertMemberAlign(bool) = 0;
|
|
Packit |
1c1d7e |
virtual void startMemberDoc(const char *,const char *,
|
|
Packit |
1c1d7e |
const char *,const char *,int,int,bool) = 0;
|
|
Packit |
1c1d7e |
virtual void endMemberDoc(bool) = 0;
|
|
Packit |
1c1d7e |
virtual void startDoxyAnchor(const char *fName,const char *manName,
|
|
Packit |
1c1d7e |
const char *anchor,const char *name,
|
|
Packit |
1c1d7e |
const char *args) = 0;
|
|
Packit |
1c1d7e |
virtual void endDoxyAnchor(const char *fileName,const char *anchor) = 0;
|
|
Packit |
1c1d7e |
virtual void writeLatexSpacing() = 0;
|
|
Packit |
1c1d7e |
virtual void writeStartAnnoItem(const char *type,const char *file,
|
|
Packit |
1c1d7e |
const char *path,const char *name) = 0;
|
|
Packit |
1c1d7e |
virtual void writeEndAnnoItem(const char *name) = 0;
|
|
Packit |
1c1d7e |
virtual void startMemberDescription(const char *anchor,const char *inheritId) = 0;
|
|
Packit |
1c1d7e |
virtual void endMemberDescription() = 0;
|
|
Packit |
1c1d7e |
virtual void startMemberDeclaration() = 0;
|
|
Packit |
1c1d7e |
virtual void endMemberDeclaration(const char *anchor,const char *inheritId) = 0;
|
|
Packit |
1c1d7e |
virtual void writeInheritedSectionTitle(const char *id,const char *ref,
|
|
Packit |
1c1d7e |
const char *file,const char *anchor,
|
|
Packit |
1c1d7e |
const char *title,const char *name) = 0;
|
|
Packit |
1c1d7e |
virtual void startIndent() = 0;
|
|
Packit |
1c1d7e |
virtual void endIndent() = 0;
|
|
Packit |
1c1d7e |
virtual void writeSynopsis() = 0;
|
|
Packit |
1c1d7e |
virtual void startClassDiagram() = 0;
|
|
Packit |
1c1d7e |
virtual void endClassDiagram(const ClassDiagram &,const char *,const char *) = 0;
|
|
Packit |
1c1d7e |
virtual void startDotGraph() = 0;
|
|
Packit |
1c1d7e |
virtual void endDotGraph(const DotClassGraph &g) = 0;
|
|
Packit |
1c1d7e |
virtual void startInclDepGraph() = 0;
|
|
Packit |
1c1d7e |
virtual void endInclDepGraph(const DotInclDepGraph &g) = 0;
|
|
Packit |
1c1d7e |
virtual void startGroupCollaboration() = 0;
|
|
Packit |
1c1d7e |
virtual void endGroupCollaboration(const DotGroupCollaboration &g) = 0;
|
|
Packit |
1c1d7e |
virtual void startCallGraph() = 0;
|
|
Packit |
1c1d7e |
virtual void endCallGraph(const DotCallGraph &g) = 0;
|
|
Packit |
1c1d7e |
virtual void startDirDepGraph() = 0;
|
|
Packit |
1c1d7e |
virtual void endDirDepGraph(const DotDirDeps &g) = 0;
|
|
Packit |
1c1d7e |
virtual void writeGraphicalHierarchy(const DotGfxHierarchyTable &g) = 0;
|
|
Packit |
1c1d7e |
virtual void startQuickIndices() = 0;
|
|
Packit |
1c1d7e |
virtual void endQuickIndices() = 0;
|
|
Packit |
1c1d7e |
virtual void writeSplitBar(const char *) = 0;
|
|
Packit |
1c1d7e |
virtual void writeNavigationPath(const char *) = 0;
|
|
Packit |
1c1d7e |
virtual void writeLogo() = 0;
|
|
Packit |
1c1d7e |
virtual void writeQuickLinks(bool compact,HighlightedItem hli,const char *file) = 0;
|
|
Packit |
1c1d7e |
virtual void writeSummaryLink(const char *file,const char *anchor,const char *title,bool first) = 0;
|
|
Packit |
1c1d7e |
virtual void startContents() = 0;
|
|
Packit |
1c1d7e |
virtual void endContents() = 0;
|
|
Packit |
1c1d7e |
virtual void startTextBlock(bool) = 0;
|
|
Packit |
1c1d7e |
virtual void endTextBlock(bool) = 0;
|
|
Packit |
1c1d7e |
virtual void lastIndexPage() = 0;
|
|
Packit |
1c1d7e |
virtual void startMemberDocPrefixItem() = 0;
|
|
Packit |
1c1d7e |
virtual void endMemberDocPrefixItem() = 0;
|
|
Packit |
1c1d7e |
virtual void startMemberDocName(bool) = 0;
|
|
Packit |
1c1d7e |
virtual void endMemberDocName() = 0;
|
|
Packit |
1c1d7e |
virtual void startParameterType(bool,const char *key) = 0;
|
|
Packit |
1c1d7e |
virtual void endParameterType() = 0;
|
|
Packit |
1c1d7e |
virtual void startParameterName(bool) = 0;
|
|
Packit |
1c1d7e |
virtual void endParameterName(bool,bool,bool) = 0;
|
|
Packit |
1c1d7e |
virtual void startParameterList(bool) = 0;
|
|
Packit |
1c1d7e |
virtual void endParameterList() = 0;
|
|
Packit |
1c1d7e |
virtual void exceptionEntry(const char*,bool) = 0;
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
virtual void startConstraintList(const char *) = 0;
|
|
Packit |
1c1d7e |
virtual void startConstraintParam() = 0;
|
|
Packit |
1c1d7e |
virtual void endConstraintParam() = 0;
|
|
Packit |
1c1d7e |
virtual void startConstraintType() = 0;
|
|
Packit |
1c1d7e |
virtual void endConstraintType() = 0;
|
|
Packit |
1c1d7e |
virtual void startConstraintDocs() = 0;
|
|
Packit |
1c1d7e |
virtual void endConstraintDocs() = 0;
|
|
Packit |
1c1d7e |
virtual void endConstraintList() = 0;
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
virtual void startMemberDocSimple(bool) = 0;
|
|
Packit |
1c1d7e |
virtual void endMemberDocSimple(bool) = 0;
|
|
Packit |
1c1d7e |
virtual void startInlineMemberType() = 0;
|
|
Packit |
1c1d7e |
virtual void endInlineMemberType() = 0;
|
|
Packit |
1c1d7e |
virtual void startInlineMemberName() = 0;
|
|
Packit |
1c1d7e |
virtual void endInlineMemberName() = 0;
|
|
Packit |
1c1d7e |
virtual void startInlineMemberDoc() = 0;
|
|
Packit |
1c1d7e |
virtual void endInlineMemberDoc() = 0;
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
virtual void startLabels() = 0;
|
|
Packit |
1c1d7e |
virtual void writeLabel(const char *,bool) = 0;
|
|
Packit |
1c1d7e |
virtual void endLabels() = 0;
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
protected:
|
|
Packit |
1c1d7e |
FTextStream t;
|
|
Packit |
1c1d7e |
QFile *file;
|
|
Packit |
1c1d7e |
QCString fileName;
|
|
Packit |
1c1d7e |
QCString dir;
|
|
Packit |
1c1d7e |
bool active;
|
|
Packit |
1c1d7e |
QStack<bool> *genStack;
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
private:
|
|
Packit |
1c1d7e |
OutputGenerator(const OutputGenerator &o);
|
|
Packit |
1c1d7e |
OutputGenerator &operator=(const OutputGenerator &o);
|
|
Packit |
1c1d7e |
};
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
/** Interface used for generating documentation.
|
|
Packit |
1c1d7e |
*
|
|
Packit |
1c1d7e |
* This abstract class is used by several functions
|
|
Packit |
1c1d7e |
* to generate the output for a specific format.
|
|
Packit |
1c1d7e |
* This interface contains some state saving and changing
|
|
Packit |
1c1d7e |
* functions for dealing with format specific output.
|
|
Packit |
1c1d7e |
*/
|
|
Packit |
1c1d7e |
class OutputDocInterface : public BaseOutputDocInterface
|
|
Packit |
1c1d7e |
{
|
|
Packit |
1c1d7e |
public:
|
|
Packit |
1c1d7e |
virtual ~OutputDocInterface() {}
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
/*! Create a new output generator. This can later by appended
|
|
Packit |
1c1d7e |
* to the current one using append().
|
|
Packit |
1c1d7e |
*/
|
|
Packit |
1c1d7e |
//virtual OutputDocInterface *clone() = 0;
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
/*! Disables all output formats except format \a o
|
|
Packit |
1c1d7e |
* (useful for OutputList only)
|
|
Packit |
1c1d7e |
*/
|
|
Packit |
1c1d7e |
virtual void disableAllBut(OutputGenerator::OutputType o) = 0;
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
/*! Enables all output formats as far as they have been enabled in
|
|
Packit |
1c1d7e |
* the config file. (useful for OutputList only)
|
|
Packit |
1c1d7e |
*/
|
|
Packit |
1c1d7e |
virtual void enableAll() = 0;
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
/*! Disables all output formats (useful for OutputList only) */
|
|
Packit |
1c1d7e |
virtual void disableAll()= 0;
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
/*! Disables a specific output format (useful for OutputList only) */
|
|
Packit |
1c1d7e |
virtual void disable(OutputGenerator::OutputType o) = 0;
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
/*! Enables a specific output format (useful for OutputList only) */
|
|
Packit |
1c1d7e |
virtual void enable(OutputGenerator::OutputType o) = 0;
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
/*! Check whether a specific output format is currently enabled
|
|
Packit |
1c1d7e |
* (useful for OutputList only)
|
|
Packit |
1c1d7e |
*/
|
|
Packit |
1c1d7e |
virtual bool isEnabled(OutputGenerator::OutputType o) = 0;
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
/*! Appends the output generated by generator \a g to this
|
|
Packit |
1c1d7e |
* generator.
|
|
Packit |
1c1d7e |
*/
|
|
Packit |
1c1d7e |
//virtual void append(const OutputDocInterface *g) = 0;
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
/*! Pushes the state of the current generator (or list of
|
|
Packit |
1c1d7e |
* generators) on a stack.
|
|
Packit |
1c1d7e |
*/
|
|
Packit |
1c1d7e |
virtual void pushGeneratorState() = 0;
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
/*! Pops the state of the current generator (or list of
|
|
Packit |
1c1d7e |
* generators) on a stack. Should be preceded by a call
|
|
Packit |
1c1d7e |
* the pushGeneratorState().
|
|
Packit |
1c1d7e |
*/
|
|
Packit |
1c1d7e |
virtual void popGeneratorState() = 0;
|
|
Packit |
1c1d7e |
};
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
|
|
Packit |
1c1d7e |
#endif
|