extern wxHashTable TexReferences;
// Are we in verbatim mode? If so, format differently.
extern wxHashTable TexReferences;
// Are we in verbatim mode? If so, format differently.
// Remember that at this level, we had a book and *must* for the
// remainder of sections at this level.
// Remember that at this level, we had a book and *must* for the
// remainder of sections at this level.
// Always have a book at level 1
wxFprintf(WinHelpContentsFile, _T("%d %s\n"), level, title);
wxFprintf(WinHelpContentsFile, _T("%d %s=%s\n"), level+1, title, topicName);
// Always have a book at level 1
wxFprintf(WinHelpContentsFile, _T("%d %s\n"), level, title);
wxFprintf(WinHelpContentsFile, _T("%d %s=%s\n"), level+1, title, topicName);
wxFprintf(fd, _T("BrowseButtons()\n\n"));
wxFprintf(fd, _T("[MAP]\n\n[BITMAPS]\n\n"));
fclose(fd);
wxFprintf(fd, _T("BrowseButtons()\n\n"));
wxFprintf(fd, _T("[MAP]\n\n[BITMAPS]\n\n"));
fclose(fd);
BigBuffer[ptr] = 0; wxStrcat(BigBuffer, _T("\\par\n")); ptr += 5;
// BigBuffer[ptr] = 0; wxStrcat(BigBuffer, _T("\\par{\\v this was verbatim}\n")); ptr += 5;
i ++;
BigBuffer[ptr] = 0; wxStrcat(BigBuffer, _T("\\par\n")); ptr += 5;
// BigBuffer[ptr] = 0; wxStrcat(BigBuffer, _T("\\par{\\v this was verbatim}\n")); ptr += 5;
i ++;
((len > i+1 && chunk->value[i+1] == 13) &&
(len > i+2 && isascii(chunk->value[i+2]) &&
!isspace(chunk->value[i+2]))))
((len > i+1 && chunk->value[i+1] == 13) &&
(len > i+2 && isascii(chunk->value[i+2]) &&
!isspace(chunk->value[i+2]))))
}
else if (inVerbatim && ch == '\\') // Change backslash to two backslashes
{
BigBuffer[ptr] = '\\'; ptr ++;
BigBuffer[ptr] = '\\'; ptr ++;
i += 1;
}
else if (inVerbatim && ch == '\\') // Change backslash to two backslashes
{
BigBuffer[ptr] = '\\'; ptr ++;
BigBuffer[ptr] = '\\'; ptr ++;
i += 1;
}
else if (inVerbatim && (ch == '{' || ch == '}')) // Escape the curley bracket
{
BigBuffer[ptr] = '\\'; ptr ++;
BigBuffer[ptr] = ch; ptr ++;
i += 1;
}
else if (inVerbatim && (ch == '{' || ch == '}')) // Escape the curley bracket
{
BigBuffer[ptr] = '\\'; ptr ++;
BigBuffer[ptr] = ch; ptr ++;
i += 1;
int noZeroes = 5-wxStrlen(buf);
wxStrcpy(browseBuf, _T("browse"));
for (int i = 0; i < noZeroes; i++)
int noZeroes = 5-wxStrlen(buf);
wxStrcpy(browseBuf, _T("browse"));
for (int i = 0; i < noZeroes; i++)
- wxSprintf(buf, _T("\\fi%d"), ParIndent*20); // Convert points to TWIPS
+ wxSnprintf(buf, sizeof(buf), _T("\\fi%d"), ParIndent*20); // Convert points to TWIPS
- wxSprintf(buf, _T("SECTION %d"), sectionNo);
+ wxSnprintf(buf, sizeof(buf), _T("SECTION %d"), sectionNo);
- wxSprintf(buf, _T("CHAPTER %d: "), chapterNo);
+ wxSnprintf(buf, sizeof(buf), _T("CHAPTER %d: "), chapterNo);
- wxSprintf(buf, _T("SECTION %d"), sectionNo);
+ wxSnprintf(buf, sizeof(buf), _T("SECTION %d"), sectionNo);
- wxSprintf(buf, _T("CHAPTER %d"), chapterNo);
+ wxSnprintf(buf, sizeof(buf), _T("CHAPTER %d"), chapterNo);
- wxSprintf(tmpBuf, _T("%d (%d)"), macroId, (int)start);
+ wxSnprintf(tmpBuf, sizeof(tmpBuf), _T("%d (%d)"), macroId, (int)start);
OutputDebugString("RTFOnMacro Start "); OutputDebugString(tmpBuf);
OutputDebugString("\n"); wxYield();
*/
OutputDebugString("RTFOnMacro Start "); OutputDebugString(tmpBuf);
OutputDebugString("\n"); wxYield();
*/
- wxFprintf(Contents, _T("}{\\v %s}\\par\\pard\n"), topicName);
+ {
+ wxFprintf(Contents, _T("}{\\v %s}\\pard\\par\n"), topicName);
+ //WriteEnvironmentStyles();
+ }
else if ((macroId == ltCHAPTER) || (macroId == ltCHAPTERHEADING))
wxFprintf(Contents, _T("}\\par\\par\\pard\n"));
else if ((macroId == ltCHAPTER) || (macroId == ltCHAPTERHEADING))
wxFprintf(Contents, _T("}\\par\\par\\pard\n"));
- wxFprintf(jumpFrom, _T("}{\\v %s}\\par\\pard\n"), topicName);
+ {
+ wxFprintf(jumpFrom, _T("}{\\v %s}\\pard\\par\n"), topicName);
+ //WriteEnvironmentStyles();
+ }
- wxFprintf(Sections, _T("}{\\v %s}\\par\\pard\n"), topicName);
+ {
+ wxFprintf(Sections, _T("}{\\v %s}\\pard\\par\n"), topicName);
+ //WriteEnvironmentStyles();
+ }
}
else if ((macroId != ltSUBSECTIONSTAR) && (macroId != ltMEMBERSECTION) &&
(macroId != ltFUNCTIONSECTION))
}
else if ((macroId != ltSUBSECTIONSTAR) && (macroId != ltMEMBERSECTION) &&
(macroId != ltFUNCTIONSECTION))
- wxFprintf(Subsections, _T("}{\\v %s}\\par\\pard\n"), topicName);
+ {
+ wxFprintf(Subsections, _T("}{\\v %s}\\pard\\par\n"), topicName);
+ //WriteEnvironmentStyles();
+ }
else if ((DocumentStyle == LATEX_ARTICLE) && (macroId != ltSUBSUBSECTIONSTAR))
wxFprintf(Contents, _T("\\par\\pard\n"));
else if ((DocumentStyle == LATEX_ARTICLE) && (macroId != ltSUBSUBSECTIONSTAR))
wxFprintf(Contents, _T("\\par\\pard\n"));
- wxSprintf(figBuf, _T("%s %d.%d: "), FigureNameString, chapterNo, figureNo);
+ wxSnprintf(figBuf, sizeof(figBuf), _T("%s %d.%d: "), FigureNameString, chapterNo, figureNo);
- wxSprintf(figBuf, _T("%s %d: "), FigureNameString, figureNo);
+ wxSnprintf(figBuf, sizeof(figBuf), _T("%s %d: "), FigureNameString, figureNo);
- wxSprintf(figBuf, _T("%s {\\field\\flddirty{\\*\\fldinst SEQ Figure \\\\* ARABIC }{\\fldrslt {\\bkmkstart %s}??{\\bkmkend %s}}}: "),
+ wxSnprintf(figBuf, sizeof(figBuf), _T("%s {\\field\\flddirty{\\*\\fldinst SEQ Figure \\\\* ARABIC }{\\fldrslt {\\bkmkstart %s}??{\\bkmkend %s}}}: "),
- wxSprintf(figBuf, _T("%s %d.%d: "), TableNameString, chapterNo, tableNo);
+ wxSnprintf(figBuf, sizeof(figBuf), _T("%s %d.%d: "), TableNameString, chapterNo, tableNo);
- wxSprintf(figBuf, _T("%s %d: "), TableNameString, tableNo);
+ wxSnprintf(figBuf, sizeof(figBuf), _T("%s %d: "), TableNameString, tableNo);
- wxSprintf(figBuf, _T("%s {\\field\\flddirty{\\*\\fldinst SEQ Table \\\\* ARABIC }{\\fldrslt {\\bkmkstart %s}??{\\bkmkend %s}}}: "),
+ wxSnprintf(figBuf, sizeof(figBuf), _T("%s {\\field\\flddirty{\\*\\fldinst SEQ Table \\\\* ARABIC }{\\fldrslt {\\bkmkstart %s}??{\\bkmkend %s}}}: "),
TexOutput(_T("\\par\\pard\\pgnrestart\\sect\\titlepg"));
// In linear RTF, same as chapter headings.
TexOutput(_T("\\par\\pard\\pgnrestart\\sect\\titlepg"));
// In linear RTF, same as chapter headings.
- wxSprintf(buf, _T("{\\b\\fs%d %s}\\par\\par\\pard\n\n"), chapterFont*2, ContentsNameString);
+ wxSnprintf(buf, sizeof(buf), _T("{\\b\\fs%d %s}\\par\\par\\pard\n\n"), chapterFont*2, ContentsNameString);
- wxSprintf(buf, _T("{\\field{\\*\\fldinst TOC \\\\o \"1-%d\" }{\\fldrslt PRESS F9 TO REFORMAT CONTENTS}}\n"), contentsDepth);
+ wxSnprintf(buf, sizeof(buf), _T("{\\field{\\*\\fldinst TOC \\\\o \"1-%d\" }{\\fldrslt PRESS F9 TO REFORMAT CONTENTS}}\n"), contentsDepth);
- wxSprintf(buf, _T("\\cellx%d"), currentWidth);
+ wxSnprintf(buf, sizeof(buf), _T("\\cellx%d"), currentWidth);
ItemizeStruc *struc = new ItemizeStruc(listType, indentSize2, indentSize1);
itemizeStack.Insert(struc);
ItemizeStruc *struc = new ItemizeStruc(listType, indentSize2, indentSize1);
itemizeStack.Insert(struc);
- wxSprintf(buf, _T("\\tx%d\\tx%d\\li%d\\sa200"), indentSize1, indentSize2, indentSize2);
+ wxSnprintf(buf, sizeof(buf), _T("\\tx%d\\tx%d\\li%d\\sa200"), indentSize1, indentSize2, indentSize2);
- OnMacro(ltPAR, 0, TRUE);
- OnMacro(ltPAR, 0, FALSE);
+ OnMacro(ltPAR, 0, true);
+ OnMacro(ltPAR, 0, false);
ItemizeStruc *struc = new ItemizeStruc(LATEX_TWOCOL, indentSize);
itemizeStack.Insert(struc);
ItemizeStruc *struc = new ItemizeStruc(LATEX_TWOCOL, indentSize);
itemizeStack.Insert(struc);
-// wxSprintf(buf, _T("\\tx%d\\li%d\\ri%d"), indentSize, indentSize, TwoColWidthA+TwoColWidthB+oldIndent);
- wxSprintf(buf, _T("\\tx%d\\li%d\\sa200"), indentSize, indentSize);
+// wxSnprintf(buf, sizeof(buf), _T("\\tx%d\\li%d\\ri%d"), indentSize, indentSize, TwoColWidthA+TwoColWidthB+oldIndent);
+ wxSnprintf(buf, sizeof(buf), _T("\\tx%d\\li%d\\sa200"), indentSize, indentSize);
- OnMacro(ltPAR, 0, TRUE);
- OnMacro(ltPAR, 0, FALSE);
+ OnMacro(ltPAR, 0, true);
+ OnMacro(ltPAR, 0, false);
- wxSprintf(buf, _T("\\tx%d\\tx%d\\li%d\\fi-%d\n"), indentSize1, indentSize2,
+ wxSnprintf(buf, sizeof(buf), _T("\\tx%d\\tx%d\\li%d\\fi-%d\n"), indentSize1, indentSize2,
- wxSprintf(indentBuf, _T("\\tab{\\b %d.}\\tab"), struc->currentItem);
+ wxSnprintf(indentBuf, sizeof(indentBuf), _T("\\tab{\\b %d.}\\tab"), struc->currentItem);
- wxSprintf(indentBuf, _T("\\tab\\{bmct %s\\}\\tab"), bulletFile);
+ wxSnprintf(indentBuf, sizeof(indentBuf), _T("\\tab\\{bmct %s\\}\\tab"), bulletFile);
- wxSprintf(indentBuf, _T("\\tab\\{bmc %s\\}\\tab"), bulletFile);
+ wxSnprintf(indentBuf, sizeof(indentBuf), _T("\\tab\\{bmc %s\\}\\tab"), bulletFile);
-// wxSprintf(buf, _T("\\tx%d\\li%d\\fi-%d\\ri%d\n"), TwoColWidthA,
+// wxSnprintf(buf, sizeof(buf), _T("\\tx%d\\li%d\\fi-%d\\ri%d\n"), TwoColWidthA,
- wxSprintf(buf, _T("\\tx%d\\li%d\\fi-%d\n"), TwoColWidthA,
+ wxSnprintf(buf, sizeof(buf), _T("\\tx%d\\li%d\\fi-%d\n"), TwoColWidthA,
- wxSprintf(buf, _T("\\tx%d\\li%d\\fi-%d\n"), TwoColWidthA + oldIndent,
+ wxSnprintf(buf, sizeof(buf), _T("\\tx%d\\li%d\\fi-%d\n"), TwoColWidthA + oldIndent,
- wxSprintf(buf, _T("{\\fs%d\n"), smallFont*2);
+ wxSnprintf(buf, sizeof(buf), _T("{\\fs%d\n"), smallFont*2);
- wxSprintf(buf, _T("{\\fs%d\n"), tinyFont*2);
+ wxSnprintf(buf, sizeof(buf), _T("{\\fs%d\n"), tinyFont*2);
- wxSprintf(buf, _T("{\\fs%d\n"), normalFont*2);
+ wxSnprintf(buf, sizeof(buf), _T("{\\fs%d\n"), normalFont*2);
- wxSprintf(buf, _T("{\\fs%d\n"), largeFont1*2);
+ wxSnprintf(buf, sizeof(buf), _T("{\\fs%d\n"), largeFont1*2);
- wxSprintf(buf, _T("{\\fs%d\n"), LargeFont2*2);
+ wxSnprintf(buf, sizeof(buf), _T("{\\fs%d\n"), LargeFont2*2);
- wxSprintf(buf, _T("{\\fs%d\n"), LARGEFont3*2);
+ wxSnprintf(buf, sizeof(buf), _T("{\\fs%d\n"), LARGEFont3*2);
- wxSprintf(buf, _T("{\\fs%d\n"), hugeFont1*2);
+ wxSnprintf(buf, sizeof(buf), _T("{\\fs%d\n"), hugeFont1*2);
- wxSprintf(buf, _T("{\\fs%d\n"), HugeFont2*2);
+ wxSnprintf(buf, sizeof(buf), _T("{\\fs%d\n"), HugeFont2*2);
- wxSprintf(buf, _T("{\\fs%d\n"), HUGEFont3*2);
+ wxSnprintf(buf, sizeof(buf), _T("{\\fs%d\n"), HUGEFont3*2);
// Extra par if parskip is more than zero (usually looks best.)
// N.B. JACS 2004-02-21: shouldn't need this for linear RTF if
// we have a suitable set of styles.
// Extra par if parskip is more than zero (usually looks best.)
// N.B. JACS 2004-02-21: shouldn't need this for linear RTF if
// we have a suitable set of styles.
WriteEnvironmentStyles();
}
// 1 is a whole paragraph if ParSkip == 0,
WriteEnvironmentStyles();
}
// 1 is a whole paragraph if ParSkip == 0,
// Extra par if parskip is more than zero (usually looks best.)
if (winHelp && !inTabular && (ParSkip > 0))
{
TexOutput(_T("\\par"));
issuedNewParagraph ++;
}
// Extra par if parskip is more than zero (usually looks best.)
if (winHelp && !inTabular && (ParSkip > 0))
{
TexOutput(_T("\\par"));
issuedNewParagraph ++;
}
- wxSprintf(buf, _T("\\qc{\\fs%d\\b "), titleFont*2);
+ wxSnprintf(buf, sizeof(buf), _T("\\qc{\\fs%d\\b "), titleFont*2);
- wxSprintf(buf, _T("\\par\\qc{\\fs%d "), authorFont*2);
+ wxSnprintf(buf, sizeof(buf), _T("\\par\\qc{\\fs%d "), authorFont*2);
- wxSprintf(buf, _T("\\qc{\\fs%d "), authorFont*2);
+ wxSnprintf(buf, sizeof(buf), _T("\\qc{\\fs%d "), authorFont*2);
- OnMacro(ltPAR, 0, TRUE);
- OnMacro(ltPAR, 0, FALSE);
+ OnMacro(ltPAR, 0, true);
+ OnMacro(ltPAR, 0, false);
- FakeCurrentSection(FiguresNameString, FALSE);
- OnMacro(ltPAR, 0, TRUE);
- OnMacro(ltPAR, 0, FALSE);
- OnMacro(ltPAR, 0, TRUE);
- OnMacro(ltPAR, 0, FALSE);
+ FakeCurrentSection(FiguresNameString, false);
+ OnMacro(ltPAR, 0, true);
+ OnMacro(ltPAR, 0, false);
+ OnMacro(ltPAR, 0, true);
+ OnMacro(ltPAR, 0, false);
- wxSprintf(buf, _T("{\\field\\fldedit{\\*\\fldinst TOC \\\\c \"%s\" }{\\fldrslt PRESS F9 TO REFORMAT LIST OF FIGURES}}\n"),
+ wxSnprintf(buf, sizeof(buf), _T("{\\field\\fldedit{\\*\\fldinst TOC \\\\c \"%s\" }{\\fldrslt PRESS F9 TO REFORMAT LIST OF FIGURES}}\n"),
- FakeCurrentSection(TablesNameString, FALSE);
- OnMacro(ltPAR, 0, TRUE);
- OnMacro(ltPAR, 0, FALSE);
- OnMacro(ltPAR, 0, TRUE);
- OnMacro(ltPAR, 0, FALSE);
+ FakeCurrentSection(TablesNameString, false);
+ OnMacro(ltPAR, 0, true);
+ OnMacro(ltPAR, 0, false);
+ OnMacro(ltPAR, 0, true);
+ OnMacro(ltPAR, 0, false);
- wxSprintf(buf, _T("{\\field\\fldedit{\\*\\fldinst TOC \\\\c \"%s\" }{\\fldrslt PRESS F9 TO REFORMAT LIST OF TABLES}}\n"),
+ wxSnprintf(buf, sizeof(buf), _T("{\\field\\fldedit{\\*\\fldinst TOC \\\\c \"%s\" }{\\fldrslt PRESS F9 TO REFORMAT LIST OF TABLES}}\n"),
- wxSprintf(buf, _T("Warning: unresolved reference '%s'"), refName);
+ wxSnprintf(buf, sizeof(buf), _T("Warning: unresolved reference '%s'"), refName);
- wxSprintf(buf, _T("Warning: could not find a BMP or WMF equivalent for %s."), filename);
+ wxSnprintf(buf, sizeof(buf), _T("Warning: could not find a BMP or WMF equivalent for %s."), filename);
- wxSprintf(buf, _T("Could not read bitmap %s.\nMay be in wrong format (needs RGB-encoded Windows BMP)."), f.c_str());
+ wxSnprintf(buf, sizeof(buf), _T("Could not read bitmap %s.\nMay be in wrong format (needs RGB-encoded Windows BMP)."), f.c_str());
- wxSprintf(buf, _T("Could not read metafile %s. Perhaps it's not a placeable metafile?"), f.c_str());
+ wxSnprintf(buf, sizeof(buf), _T("Could not read metafile %s. Perhaps it's not a placeable metafile?"), f.c_str());
- wxSprintf(buf, _T("Warning: could not find a BMP or WMF equivalent for %s."), filename);
+ wxSnprintf(buf, sizeof(buf), _T("Warning: could not find a BMP or WMF equivalent for %s."), filename);
- wxSprintf(buf, _T("\\cellx%d"), currentWidth);
+ wxSnprintf(buf, sizeof(buf), _T("\\cellx%d"), currentWidth);
}
}
else if (arg_no == 2 && !start)
{
TexOutput(_T("\\pard\n"));
WriteEnvironmentStyles();
}
}
else if (arg_no == 2 && !start)
{
TexOutput(_T("\\pard\n"));
WriteEnvironmentStyles();
- OnMacro(ltPAR, 0, TRUE);
- OnMacro(ltPAR, 0, FALSE);
+ OnMacro(ltPAR, 0, true);
+ OnMacro(ltPAR, 0, false);
- OnMacro(ltPAR, 0, TRUE);
- OnMacro(ltPAR, 0, FALSE);
+ OnMacro(ltPAR, 0, true);
+ OnMacro(ltPAR, 0, false);
- wxSprintf(buf, _T("\\sa200\\box\\trgaph108%s\n"), ((macroId == ltNORMALBOXD) ? _T("\\brdrdb") : _T("\\brdrs")));
+ wxSnprintf(buf, sizeof(buf), _T("\\sa200\\box\\trgaph108%s\n"), ((macroId == ltNORMALBOXD) ? _T("\\brdrdb") : _T("\\brdrs")));
- OnMacro(ltPAR, 0, TRUE);
- OnMacro(ltPAR, 0, FALSE);
+ OnMacro(ltPAR, 0, true);
+ OnMacro(ltPAR, 0, false);
- wxSprintf(buf, _T("\\fs%d\n"), normalFont*2);
+ wxSnprintf(buf, sizeof(buf), _T("\\fs%d\n"), normalFont*2);
- wxSprintf(buf, _T("\\fi%d\n"), ParIndent*20);
+ wxSnprintf(buf, sizeof(buf), _T("\\fi%d\n"), ParIndent*20);
- wxSprintf(footBuf, _T("(%d)"), footnoteCount);
+ wxSnprintf(footBuf, sizeof(footBuf), _T("(%d)"), footnoteCount);
RTFOnArgument(ltSETHEADER, 4, start);
if (!start)
OutputRTFHeaderCommands();
RTFOnArgument(ltSETHEADER, 4, start);
if (!start)
OutputRTFHeaderCommands();
RTFOnArgument(ltSETHEADER, 4, start);
if (!start)
OutputRTFHeaderCommands();
RTFOnArgument(ltSETHEADER, 4, start);
if (!start)
OutputRTFHeaderCommands();
- wxSprintf(buf, _T("\\margl%d\n"), twips);
+ wxSnprintf(buf, sizeof(buf), _T("\\margl%d\n"), twips);
CurrentMarginParSep = twips;
CurrentMarginParX = CurrentLeftMarginOdd + CurrentTextWidth + CurrentMarginParSep;
}
CurrentMarginParSep = twips;
CurrentMarginParX = CurrentLeftMarginOdd + CurrentTextWidth + CurrentMarginParSep;
}
CurrentRightMarginOdd = PageWidth - CurrentTextWidth - CurrentLeftMarginOdd;
CurrentRightMarginEven = PageWidth - CurrentTextWidth - CurrentLeftMarginEven;
CurrentMarginParX = CurrentLeftMarginOdd + CurrentTextWidth + CurrentMarginParSep;
CurrentRightMarginOdd = PageWidth - CurrentTextWidth - CurrentLeftMarginOdd;
CurrentRightMarginEven = PageWidth - CurrentTextWidth - CurrentLeftMarginEven;
CurrentMarginParX = CurrentLeftMarginOdd + CurrentTextWidth + CurrentMarginParSep;
- wxSprintf(buf, _T("\\margr%d\n"), CurrentRightMarginOdd);
+ wxSnprintf(buf, sizeof(buf), _T("\\margr%d\n"), CurrentRightMarginOdd);
- wxSprintf(buf, _T("\\phpg\\posx%d\\absw%d\n"), CurrentMarginParX, CurrentMarginParWidth);
+ wxSnprintf(buf, sizeof(buf), _T("\\phpg\\posx%d\\absw%d\n"), CurrentMarginParX, CurrentMarginParWidth);
// mirror mode, on an even (left-hand) page.
int x = PageWidth - CurrentRightMarginOdd - CurrentMarginParWidth - CurrentMarginParSep
- CurrentTextWidth + GutterWidth;
// mirror mode, on an even (left-hand) page.
int x = PageWidth - CurrentRightMarginOdd - CurrentMarginParWidth - CurrentMarginParSep
- CurrentTextWidth + GutterWidth;
- wxSprintf(buf, _T("\\phpg\\posx%d\\absw%d\n"), x, CurrentMarginParWidth);
+ wxSnprintf(buf, sizeof(buf), _T("\\phpg\\posx%d\\absw%d\n"), x, CurrentMarginParWidth);
- wxSprintf(buf, _T("\\phpg\\posx%d\\absw%d\n"), CurrentMarginParX, CurrentMarginParWidth);
+ wxSnprintf(buf, sizeof(buf), _T("\\phpg\\posx%d\\absw%d\n"), CurrentMarginParX, CurrentMarginParWidth);
- wxSprintf(buf, _T("\\cellx%d"), currentWidth);
+ wxSnprintf(buf, sizeof(buf), _T("\\cellx%d"), currentWidth);
ItemizeStruc *struc = new ItemizeStruc(LATEX_INDENT, indentSize);
itemizeStack.Insert(struc);
ItemizeStruc *struc = new ItemizeStruc(LATEX_INDENT, indentSize);
itemizeStack.Insert(struc);
- wxSprintf(buf, _T("\\tx%d\\li%d\\sa200 "), indentSize, indentSize);
+ wxSnprintf(buf, sizeof(buf), _T("\\tx%d\\li%d\\sa200 "), indentSize, indentSize);
ItemizeStruc *struc = new ItemizeStruc(LATEX_INDENT, indentSize);
itemizeStack.Insert(struc);
ItemizeStruc *struc = new ItemizeStruc(LATEX_INDENT, indentSize);
itemizeStack.Insert(struc);
- wxSprintf(buf, _T("\\tx%d\\li%d\\lr%d\\sa200\\box%s "), indentSize, indentSize, indentSizeRight,
+ wxSnprintf(buf, sizeof(buf), _T("\\tx%d\\li%d\\lr%d\\sa200\\box%s "), indentSize, indentSize, indentSizeRight,
{
wxChar *text = GetArgData();
if (wxStrcmp(text, _T("yes")) == 0 || wxStrcmp(text, _T("on")) == 0 || wxStrcmp(text, _T("ok")) == 0)
{
wxChar *text = GetArgData();
if (wxStrcmp(text, _T("yes")) == 0 || wxStrcmp(text, _T("on")) == 0 || wxStrcmp(text, _T("ok")) == 0)
{
wxChar *text = GetArgData();
if (wxStrcmp(text, _T("yes")) == 0 || wxStrcmp(text, _T("on")) == 0 || wxStrcmp(text, _T("ok")) == 0)
{
wxChar *text = GetArgData();
if (wxStrcmp(text, _T("yes")) == 0 || wxStrcmp(text, _T("on")) == 0 || wxStrcmp(text, _T("ok")) == 0)
{
wxChar *text = GetArgData();
if (wxStrcmp(text, _T("yes")) == 0 || wxStrcmp(text, _T("on")) == 0 || wxStrcmp(text, _T("ok")) == 0)
{
wxChar *text = GetArgData();
if (wxStrcmp(text, _T("yes")) == 0 || wxStrcmp(text, _T("on")) == 0 || wxStrcmp(text, _T("ok")) == 0)
- wxSprintf(buf, _T("{\\b [%d]} "), citeCount);
+ wxSnprintf(buf, sizeof(buf), _T("{\\b [%d]} "), citeCount);
wxFprintf(Chapters, _T("\\pard{%s"), (winHelp ? _T("\\keepn\\sa140\\sb140") : styleCommand));
WriteHeadingStyle(Chapters, 1); wxFprintf(Chapters, _T(" References\\par\\pard}\n"));
wxFprintf(Chapters, _T("\\pard{%s"), (winHelp ? _T("\\keepn\\sa140\\sb140") : styleCommand));
WriteHeadingStyle(Chapters, 1); wxFprintf(Chapters, _T(" References\\par\\pard}\n"));
- wxSprintf(buf, _T("{%s%d "), ((macroId == ltFCOL) ? _T("\\cf") : _T("\\cb")), pos);
+ wxSnprintf(buf, sizeof(buf), _T("{%s%d "), ((macroId == ltFCOL) ? _T("\\cf") : _T("\\cb")), pos);
- wxSprintf(buf, _T("Could not find colour name %s"), name);
+ wxSnprintf(buf, sizeof(buf), _T("Could not find colour name %s"), name);
wxFprintf(Chapters, _T("{\\bkmkstart %s}{\\bkmkend %s}"), s,s);
}
}
wxFprintf(Chapters, _T("{\\bkmkstart %s}{\\bkmkend %s}"), s,s);
}
}
// This macro allows you to insert text at a different level
// from the current level, e.g. into the Sections from within a subsubsection.
if (!winHelp & useWord)
// This macro allows you to insert text at a different level
// from the current level, e.g. into the Sections from within a subsubsection.
if (!winHelp & useWord)
contentsLineSection = NULL;
contentsLineValue = NULL;
descriptionItemArg = NULL;
contentsLineSection = NULL;
contentsLineValue = NULL;
descriptionItemArg = NULL;
if (!Sections || !Subsections || !Subsubsections || !Popups || (winHelpContents && !WinHelpContentsFile))
{
OnError(_T("Ouch! Could not open temporary file(s) for writing."));
if (!Sections || !Subsections || !Subsubsections || !Popups || (winHelpContents && !WinHelpContentsFile))
{
OnError(_T("Ouch! Could not open temporary file(s) for writing."));