if ( combineSubSections && !subsectionStarted )
{
+ fflush(Sections);
+
// Read old .con file in at this point
wxChar buf[256];
wxStrcpy(buf, CurrentSectionFile);
int ch = getc(fd);
while (ch != EOF)
{
- putc(ch, Sections);
+ wxPutc(ch, Sections);
ch = getc(fd);
}
fclose(fd);
{
if (start)
{
+ // NB: if this is uncommented, the table of contents
+ // completely disappears. If left commented, it's in the wrong
+ // place.
+ //fflush(Titlepage);
+
FILE *fd = wxFopen(ContentsName, _T("r"));
if (fd)
{
int ch = getc(fd);
while (ch != EOF)
{
- putc(ch, Titlepage);
+ wxPutc(ch, Titlepage);
ch = getc(fd);
}
fclose(fd);
+ fflush(Titlepage);
}
else
{
{
SetCurrentOutput(tmpTitle);
HTMLHead();
- TexOutput(_T("\n<HEAD><TITLE>"));
+ TexOutput(_T("\n<TITLE>"));
TraverseChildrenFromChunk(DocumentTitle);
TexOutput(_T("</TITLE></HEAD>\n"));
}
// Output <BODY...> to temporary title page
OutputBodyStart();
+ fflush(tmpTitle);
// Concat titlepage
FILE *fd = wxFopen(TitlepageName, _T("r"));
int ch = getc(fd);
while (ch != EOF)
{
- putc(ch, tmpTitle);
+ wxPutc(ch, tmpTitle);
ch = getc(fd);
}
fclose(fd);