1 #include <lib/base/eerror.h>
7 #include <lib/gui/emessage.h>
11 Signal2<void, int, const eString&> logOutput;
12 int logOutputConsole=1;
14 void eFatal(const char* fmt, ...)
19 vsnprintf(buf, 1024, fmt, ap);
21 logOutput(lvlFatal, buf);
22 fprintf(stderr, "%s\n",buf );
27 eMessageBox msg(buf, "FATAL ERROR", eMessageBox::iconError|eMessageBox::btOK);
37 void eDebug(const char* fmt, ...)
42 vsnprintf(buf, 1024, fmt, ap);
44 logOutput(lvlDebug, eString(buf) + "\n");
46 fprintf(stderr, "%s\n", buf);
49 void eDebugNoNewLine(const char* fmt, ...)
54 vsnprintf(buf, 1024, fmt, ap);
56 logOutput(lvlDebug, buf);
58 fprintf(stderr, "%s", buf);
61 void eWarning(const char* fmt, ...)
66 vsnprintf(buf, 1024, fmt, ap);
68 logOutput(lvlWarning, eString(buf) + "\n");
70 fprintf(stderr, "%s\n", buf);