From a841e16182d2e8eabd67a5ef1f158b009efcde6d Mon Sep 17 00:00:00 2001 From: Paolo Cignoni cignoni Date: Sat, 26 Nov 2005 18:24:00 +0000 Subject: [PATCH] Added method [print] that writes the log entries ina QStringList --- src/meshlab/GLLogStream.cpp | 12 ++++++++++++ src/meshlab/GLLogStream.h | 4 ++++ 2 files changed, 16 insertions(+) diff --git a/src/meshlab/GLLogStream.cpp b/src/meshlab/GLLogStream.cpp index cf9c50b14..5f4c392eb 100644 --- a/src/meshlab/GLLogStream.cpp +++ b/src/meshlab/GLLogStream.cpp @@ -23,6 +23,9 @@ /**************************************************************************** History $Log$ +Revision 1.4 2005/11/26 18:24:00 glvertex +Added method [print] that writes the log entries ina QStringList + Revision 1.3 2005/11/21 12:12:54 cignoni Added copyright info @@ -34,6 +37,15 @@ Added copyright info #include "GLLogStream.h" using namespace std; + +void GLLogStream::print(QStringList &l) +{ + list > ::iterator li; + + for(li=S.begin();;li!=S.end();++li) + l << (*li).second.c_str(); +} + void GLLogStream::Log(int Level, const char * f, ... ) { char buf[4096]; diff --git a/src/meshlab/GLLogStream.h b/src/meshlab/GLLogStream.h index a066f95b5..c3edc1398 100644 --- a/src/meshlab/GLLogStream.h +++ b/src/meshlab/GLLogStream.h @@ -24,6 +24,9 @@ /**************************************************************************** History $Log$ +Revision 1.2 2005/11/26 18:24:00 glvertex +Added method [print] that writes the log entries ina QStringList + Revision 1.1 2005/11/16 23:19:22 cignoni Initial Draft release; still to be adapted to our needs. @@ -56,6 +59,7 @@ Initial Commit class GLLogStream : public LogStream { public: + void print(QStringList &list); // Fills a QStringList with the log entries void glDraw(QGLWidget *qgl, int Level, int nlines); void Save(int Level, const char *filename); void Clear() {S.clear();}