#include "wx/wx.h"
#endif
-#include <wx/hash.h>
+#include "wx/hash.h"
+
+#ifdef new
+#undef new
+#endif
#if wxUSE_IOSTREAMH
#include <iostream.h>
static char *forceTopicName = NULL;
-void ForceTopicName(char *name)
+void ForceTopicName(const char *name)
{
if (forceTopicName)
delete[] forceTopicName;
void WriteTexReferences(char *filename)
{
- ofstream ostr(filename);
+ wxSTD ofstream ostr(filename);
if (ostr.bad()) return;
char buf[200];
if (!wxFileExists(filename))
return;
- ifstream istr(filename, ios::in);
+ wxSTD ifstream istr(filename, ios::in);
if (istr.bad()) return;
*
*/
-void BibEatWhiteSpace(istream& str)
+void BibEatWhiteSpace(wxSTD istream& str)
{
char ch = str.peek();
}
// Read word up to { or , or space
-void BibReadWord(istream& istr, char *buffer)
+void BibReadWord(wxSTD istream& istr, char *buffer)
{
int i = 0;
buffer[i] = 0;
}
// Read string (double-quoted or not) to end quote or EOL
-void BibReadToEOL(istream& istr, char *buffer)
+void BibReadToEOL(wxSTD istream& istr, char *buffer)
{
int i = 0;
buffer[i] = 0;
}
// Read }-terminated value, taking nested braces into account.
-void BibReadValue(istream& istr, char *buffer, bool ignoreBraces = TRUE,
+void BibReadValue(wxSTD istream& istr, char *buffer, bool ignoreBraces = TRUE,
bool quotesMayTerminate = TRUE)
{
int braceCount = 1;
if (i >= 4000)
{
char buf[100];
- sprintf(buf, "Sorry, value > 4000 chars in bib file at line %ld, terminating.", BibLine);
- wxFatalError(buf, "Tex2RTF Fatal Error");
+ sprintf(buf, "Sorry, value > 4000 chars in bib file at line %ld.", BibLine);
+ wxLogError(buf, "Tex2RTF Fatal Error");
+ return;
}
istr.get(ch);
return FALSE;
char buf[300];
- ifstream istr(filename, ios::in);
+ wxSTD ifstream istr(filename, ios::in);
if (istr.bad()) return FALSE;
BibLine = 1;
htmlFrameContents = StringTobool(settingValue);
else if (StringMatch(settingName, "upperCaseNames", FALSE, TRUE))
upperCaseNames = StringTobool(settingValue);
+ else if (StringMatch(settingName, "ignoreBadRefs", FALSE, TRUE))
+ ignoreBadRefs = StringTobool(settingValue);
+ else if (StringMatch(settingName, "htmlFaceName", FALSE, TRUE))
+ {
+ delete[] htmlFaceName;
+ htmlFaceName = copystring(settingValue);
+ }
else if (StringMatch(settingName, "winHelpTitle", FALSE, TRUE))
{
if (winHelpTitle)
if (!wxFileExists(filename))
return FALSE;
- ifstream istr(filename, ios::in);
+ wxSTD ifstream istr(filename, ios::in);
if (istr.bad()) return FALSE;
*
*/
-ColourTableEntry::ColourTableEntry(char *theName, unsigned int r, unsigned int g, unsigned int b)
+ColourTableEntry::ColourTableEntry(const char *theName, unsigned int r, unsigned int g, unsigned int b)
{
name = copystring(theName);
red = r;
delete[] name;
}
-void AddColour(char *theName, unsigned int r, unsigned int g, unsigned int b)
+void AddColour(const char *theName, unsigned int r, unsigned int g, unsigned int b)
{
wxNode *node = ColourTable.Find(theName);
if (node)