]> git.lyx.org Git - lyx.git/blobdiff - src/Compare.h
Account for old versions of Pygments
[lyx.git] / src / Compare.h
index 5458c5a3f2a5f8c6a6d9339c7cd440c6bb95f6ed..c1956c13ccbb0207f187a8a0aa2283a9d735fcf2 100644 (file)
 
 #include "Buffer.h"
 
-#include "support/FileName.h"
-
-#include <string>
-
 #include <QObject>
 #include <QThread>
+#include <QTimer>
 #include <QWaitCondition>
 
 
@@ -60,8 +57,11 @@ public:
        }
 
 Q_SIGNALS:
+       /// The thread has finished due to an error.
+       void error() const;
+
        /// The thread has finished. If the thread is cancelled
-       /// by the user or due to an error \c aborted is true.
+       /// by the user \c aborted is true.
        void finished(bool aborted) const;
 
        /// Adds \c progress to the value of the progress bar in the dialog
@@ -70,8 +70,15 @@ Q_SIGNALS:
        /// Sets the maximum value of the progress bar in the dialog.
        void progressMax(int max) const;
 
+       /// A message describing the process
+       void statusMessage(QString msg) const;
+
+public Q_SLOTS:
+       /// Emits the status message signal
+       void doStatusMessage();
+
 public:
-       /// QThread inherited methods
+       /// \name QThread inherited methods
        //@{
        void run();
        //@}
@@ -83,12 +90,12 @@ private:
        /// Starts the comparison algorithm
        int doCompare();
        
-       /// The buffer with the differences marked with track changes
-       Buffer * const dest_buffer;
-       /// The old document's buffer
-       Buffer const * const old_buffer;
        /// The new document's buffer
        Buffer const * const new_buffer;
+       /// The old document's buffer
+       Buffer const * const old_buffer;
+       /// The buffer with the differences marked with track changes
+       Buffer * const dest_buffer;
        
        /// The options that are set in the GuiCompare dialog
        CompareOptions options_;
@@ -96,6 +103,9 @@ private:
        ///
        QWaitCondition condition_;
 
+       /// Emit a statusMessage signal from time to time
+       QTimer status_timer_;
+
        /// Use the Pimpl idiom to hide the internals.
        class Impl;
        ///