16 buffer = buffer.
replace(
"<",
"<");
17 buffer = buffer.
replace(
">",
">");
18 buffer = buffer.
replace(
"\\\"\\\\\\\"",
"\"\\\"");
19 buffer = buffer.
replace(
"\\\\\\\"\\\"",
"\\\"\"");
20 buffer = buffer.
replace(
"\"",
""");
21 buffer = buffer.
replace(
"\\dots{}",
"...");
22 buffer = buffer.
replace(
"\\'e",
"é");
23 buffer = buffer.
replace(
"\\'",
"");
24 buffer = buffer.
replace(
"~",
"~");
25 buffer = buffer.
replace(
"\\and",
"&");
27 buffer = buffer.
replace(
"\\,",
"");
28 buffer = buffer.
replace(
"\\",
"\");
62 const std::vector<PParserEnv> & vecPars = vecParser.
getVecEnv();
63 for(std::vector<PParserEnv>::const_iterator it(vecPars.begin()); it != vecPars.end(); ++it){
64 if(it->getName() == nameParser){
108 bool parseUntilEnd(
false), isFind(
false);
111 if(strNotBeforeBegin ==
"" || (strNotBeforeBegin !=
"" && !fileParser.
isMatch(strNotBeforeBegin))){
112 if(fileParser.
isMatch(strBegin)){
113 if(strNotAfterBegin !=
""){
114 parseUntilEnd = !fileParser.
isMatch(strNotAfterBegin);
116 parseUntilEnd =
true;
124 if(strNotBeforeEnd !=
""){
141 if(vecKeyword.size() != 0lu){
143 if(matchString !=
""){
150 if(vecStep.size() != 0lu){
172 PVecContext::const_iterator it(vecContext.begin());
174 while(it != vecContext.end() && isSearch){
200 tmpText += plainText;
215 if(vecObj.size() != 0lu){
218 PVecLatexObj::reverse_iterator it(vecObj.rbegin());
219 while(outPtr == NULL && it != vecObj.rend()){
std::vector< PParseStep > PVecParseStep
std::vector< PString > PVecString
Context for parser environement.
const PString & getNotBeforeBegin() const
Gets the notBeforeBegin of the PContext.
const PString & getBegin() const
Gets the begin of the PContext.
const PParseSeq & getSeq() const
Gets the seq of the PContext.
const PString & getEnd() const
Gets the end of the PContext.
const PString & getNotBeforeEnd() const
Gets the notBeforeEnd of the PContext.
const std::vector< PString > & getVecKeyword() const
Gets the vecKeyword of the PContext.
const PString & getName() const
Gets the name of the PContext.
const PString & getNotAfterBegin() const
Gets the notAfterBegin of the PContext.
classe qui permet de parser des fichiers texte en renvoyant les tokens les uns après les autres
PString getUntilKeyWithoutPaternExclude(const PString &patern, const PString &strNotBeforeEndPatern)
Parse a string until the patern is found, only if it has not strNotBeforeEndPatern before it.
PString getUntilKeyWithoutPatern(const PString &patern)
Renvoie la chaine de caractère du caractère courant jusqu'à patern exclu.
void setEscapeChar(char escapeChar)
Sets the escape character of the PFileParser.
PString getStrComposedOf(const PString &charset)
Get string composed of the characters in the string charset.
void setWhiteSpace(const PString &whiteSpace)
Initialise la liste des caractères blancs.
bool isMatchToken(const PString &patern)
Says if the patern match with the current caracters of the PFileParser but treats the string as a tok...
bool isMatch(const PString &patern)
Says if the patern match with the current caracters of the PFileParser.
char getCurrentCh() const
Renvoie le caractère courant.
void popPosition()
Get to the last saved position of the PFileParser in the current file.
void setFileContent(const PString &fileContent)
Set the file content.
void pushPosition()
Remember the current position of the PFileParser in the current file.
bool isEndOfFile() const
Dit si on est à la fin du fichier.
char getNextChar()
Fonction qui renvoie le prochain caractère du fichier courant.
const std::vector< PLatexObj > & getVecContent() const
Gets the vecContent of the PLatexObj.
const PLatexType::PLatexType & getType() const
Gets the type of the PLatexObj.
const std ::vector< PParseStep > & getVecStep() const
Get the variable p_vecStep.
const PString & getPlainText() const
Gets the plainText of the PParserEnv.
const std::vector< PContext > & getVecContext() const
Gets the vecContext of the PParserEnv.
PString replace(const PString &pattern, const PString &replaceStr) const
Replace a PString into an other PString.
Vector of the environements.
const std::vector< PParserEnv > & getVecEnv() const
Gets the vecEnv of the PVecParserEnv.
PLatexType
Type of the PLatexObj.
PString parser_makeHighlighting(const PString &strContent, const PParserEnv &parser)
Do the highlighting of the input text.
PLatexObj * getLastPLatexObj(PLatexObj &obj)
Get the last PLatexObj of the given one.
void playTextLatexObj(PString &parent, PString &textObj)
Play the text latex obj.
bool parser_parseKeyword(PString &out, PString &textObj, PFileParser &fileParser, const PContext &context)
Parse the keyword of the given parser.
PString convertCharToHtml(char ch)
fonction qui converti une chaîne de caractères en html (elle remplace les caractères spéciaux)
PParserEnv getParserEnv(const PVecParserEnv &vecParser, const PString &nameParser)
Get the parser env.
PString convertStrToHtml(const PString &str)
fonction qui converti une chaîne de caractères en html (elle remplace les caractères spéciaux)
void incrementCurrentChar(PFileParser &fileParser, PString &textObj)
Increment current char position.
std::vector< PContext > PVecContext
Vector of context.
std::vector< PLatexObj > PVecLatexObj
Vector of obj.