FAUST compiler  0.9.9.6b8
Functions | Variables
doc_notice.hh File Reference
#include <iostream>
#include <fstream>
#include <sstream>
#include <map>
#include <string>
Include dependency graph for doc_notice.hh:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Functions

void initDocNotice ()
 Dispatch initialization of notice containers, after default notice file loading. More...
 
void printDocNotice (const string &faustversion, ostream &docout)
 Print the content of the notice (a string map), as LaTeX items inside an itemize environment. More...
 

Variables

map< string, bool > gDocNoticeFlagMap
 gDocNoticeFlagMap is public to let others turn to "true" flags that one want to print. More...
 

Function Documentation

void initDocNotice ( )

Dispatch initialization of notice containers, after default notice file loading.

Remarks
The default (english) notice is already loaded at this stage to ensure that all keywords will receive a definition.

Definition at line 134 of file doc_notice.cpp.

References initDocNoticeFlagMap(), and initDocNoticeKeySet().

Referenced by loadTranslationFile().

135 {
138 }
static void initDocNoticeFlagMap()
Initialize gDocNoticeFlagMap, a map containing all the flags.
Definition: doc_notice.cpp:178
static void initDocNoticeKeySet()
Initialize gDocNoticeKeySet, a set containing all the keywords.
Definition: doc_notice.cpp:151

Here is the call graph for this function:

Here is the caller graph for this function:

void printDocNotice ( const string &  faustversion,
ostream &  docout 
)

Print the content of the notice (a string map), as LaTeX items inside an itemize environment.

Remarks
This function is meant to make it easier to reorder the notice printing by gathering all the items.
Parameters
[in]noticeThe set containing the strings to print as items.
[in]faustversionThe current version of this Faust compiler.
[out]docoutThe LaTeX output file to print into.

Definition at line 66 of file doc_notice.cpp.

References gDocAutodocStringMap, gDocNoticeFlagMap, and gDocNoticeStringMap.

Referenced by printdoccontent().

66  {
67 
68  if (! gDocNoticeStringMap.empty() ) {
69 
70  //cerr << "Documentator : printDocNotice : printing..." << endl;
71 
72  docout << endl << "\\begin{itemize}" << endl;
73 
74  /* Presentations. */
75  docout << "\t\\item " << gDocAutodocStringMap["autontctext"] << endl;
76  if(gDocNoticeFlagMap["faustapply"]) docout << "\t\\item " << gDocNoticeStringMap["faustapply"] << endl;
77  if(gDocNoticeFlagMap["faustpresentation"]) docout << "\t\\item " << gDocNoticeStringMap["faustpresentation"] << endl;
78  if(gDocNoticeFlagMap["causality"]) docout << "\t\\item " << gDocNoticeStringMap["causality"] << endl;
79  if(gDocNoticeFlagMap["blockdiagrams"]) docout << "\t\\item " << gDocNoticeStringMap["blockdiagrams"] << endl;
80 
81  /* Naming conventions of variables and functions. */
82  if(gDocNoticeFlagMap["foreignfun"]) docout << "\t\\item " << gDocNoticeStringMap["foreignfun"] << endl;
83  if(gDocNoticeFlagMap["intcast"]) docout << "\t\\item " << gDocNoticeStringMap["intcast"] << endl;
84 
85  /* Integer arithmetic into a tabular environment. */
86  if(gDocNoticeFlagMap["intplus"] ||
87  gDocNoticeFlagMap["intminus"] ||
88  gDocNoticeFlagMap["intmult"] ||
89  gDocNoticeFlagMap["intdiv"] ||
90  gDocNoticeFlagMap["intand"] ||
91  gDocNoticeFlagMap["intor"] ||
92  gDocNoticeFlagMap["intxor"])
93  {
94  gDocNoticeFlagMap["operators"] = true;
95  gDocNoticeFlagMap["optabtitle"] = true;
96  gDocNoticeFlagMap["integerops"] = true;
97 
98  docout << "\t\\item " << endl;
99  docout << "\t\t" << gDocNoticeStringMap["operators"] << endl;
100  docout << "\t\\begin{center}" << endl;
101  docout << "\t\\begin{tabular}{|c|l|l|} " << endl;
102  docout << "\t\t\\hline " << endl;
103  docout << "\t\t" << gDocNoticeStringMap["optabtitle"] << endl;
104  docout << "\t\t\\hline " << endl;
105  if(gDocNoticeFlagMap["intplus"]) docout << "\t\t" << gDocNoticeStringMap["intplus"] << endl;
106  if(gDocNoticeFlagMap["intminus"]) docout << "\t\t" << gDocNoticeStringMap["intminus"] << endl;
107  if(gDocNoticeFlagMap["intmult"]) docout << "\t\t" << gDocNoticeStringMap["intmult"] << endl;
108  if(gDocNoticeFlagMap["intdiv"]) docout << "\t\t" << gDocNoticeStringMap["intdiv"] << endl;
109  if(gDocNoticeFlagMap["intand"]) docout << "\t\t" << gDocNoticeStringMap["intand"] << endl;
110  if(gDocNoticeFlagMap["intor"]) docout << "\t\t" << gDocNoticeStringMap["intor"] << endl;
111  if(gDocNoticeFlagMap["intxor"]) docout << "\t\t" << gDocNoticeStringMap["intxor"] << endl;
112  docout << "\t\t\\hline " << endl;
113  docout << "\t\\end{tabular} " << endl;
114  docout << "\t\\end{center}" << endl;
115  docout << "\t\t" << gDocNoticeStringMap["integerops"] << endl;
116  }
117 
118  if(gDocNoticeFlagMap["faustdocdir"]) docout << "\t\\item " << gDocNoticeStringMap["faustdocdir"] << endl;
119 
120  docout << "\\end{itemize}" << endl << endl;
121  }
122  //cerr << " ... Documentator : printDocNotice : end of printing." << endl;
123 }
map< string, string > gDocNoticeStringMap
Definition: doc_notice.cpp:38
map< string, bool > gDocNoticeFlagMap
gDocNoticeFlagMap is public to let others turn to "true" flags that one want to print.
Definition: doc_notice.cpp:36
map< string, string > gDocAutodocStringMap
Definition: doc_autodoc.cpp:40

Here is the caller graph for this function:

Variable Documentation

map<string, bool> gDocNoticeFlagMap