KDevelop API Documentation

parts/outputviews/makewidget.h

Go to the documentation of this file.
00001 /*************************************************************************** 00002 * Copyright (C) 1999-2001 by Bernd Gehrmann * 00003 * bernd@kdevelop.org * 00004 * * 00005 * This program is free software; you can redistribute it and/or modify * 00006 * it under the terms of the GNU General Public License as published by * 00007 * the Free Software Foundation; either version 2 of the License, or * 00008 * (at your option) any later version. * 00009 * * 00010 ***************************************************************************/ 00011 00012 #ifndef _MAKEWIDGET_H_ 00013 #define _MAKEWIDGET_H_ 00014 00015 #include <qptrstack.h> 00016 #include <qregexp.h> 00017 #include <qtextedit.h> 00018 #include <qvaluevector.h> 00019 #include <qintdict.h> 00020 00021 #include "outputfilter.h" 00022 #include "directorystatusmessagefilter.h" 00023 #include "compileerrorfilter.h" 00024 #include "commandcontinuationfilter.h" 00025 #include "makeactionfilter.h" 00026 #include "otherfilter.h" 00027 #include "makeitem.h" 00028 00029 class MakeViewPart; 00030 class MakeItem; 00031 class KProcess; 00032 class ProcessLineMaker; 00033 namespace KTextEditor { class Document; } 00034 00035 class MakeWidget : public QTextEdit 00036 { 00037 Q_OBJECT 00038 00039 public: 00040 MakeWidget(MakeViewPart *part); 00041 ~MakeWidget(); 00042 00043 void queueJob(const QString &dir, const QString &command); 00044 bool isRunning(); 00045 void updateSettingsFromConfig(); 00046 void processLine( const QString& line ); 00047 00048 public slots: 00049 void startNextJob(); 00050 void killJob(); 00051 void nextError(); 00052 void prevError(); 00053 void copy(); 00054 00055 protected: 00056 virtual QPopupMenu *createPopupMenu( const QPoint& pos ); 00057 virtual void contentsMouseReleaseEvent( QMouseEvent* e ); 00058 00059 private slots: 00060 void insertStdoutLine(const QString& line); 00061 void insertStderrLine(const QString& line); 00062 void slotProcessExited(KProcess *); 00063 void verticScrollingOn() { m_vertScrolling = true; } 00064 void verticScrollingOff() { m_vertScrolling = false; } 00065 void horizScrollingOn() { m_horizScrolling = true; } 00066 void horizScrollingOff() { m_horizScrolling = false; } 00067 void toggleLineWrapping(); 00068 void slotVeryShortCompilerOutput(); 00069 void slotShortCompilerOutput(); 00070 void slotFullCompilerOutput(); 00071 void toggleShowDirNavigMessages(); 00072 void slotEnteredDirectory( EnteringDirectoryItem* ); 00073 void slotExitedDirectory( ExitingDirectoryItem* ); 00074 void insertItem( MakeItem* ); 00075 void slotDocumentOpened(const QString& filename); 00076 void slotDocumentClosed(QObject* doc); 00077 00078 private: 00079 virtual void keyPressEvent(QKeyEvent *e); 00080 void searchItem(int parag); 00081 QString guessFileName( const QString& fName, int parag ) const; 00082 QString directory(int parag) const; 00083 bool brightBg(); 00084 void refill(); 00085 void createCursor(ErrorItem* e, KTextEditor::Document* doc); 00086 00087 bool scanErrorForward(int parag); 00088 bool scanErrorBackward(int parag); 00089 00090 DirectoryStatusMessageFilter m_directoryStatusFilter; 00091 CompileErrorFilter m_errorFilter; 00092 CommandContinuationFilter m_continuationFilter; 00093 MakeActionFilter m_actionFilter; 00094 OtherFilter m_otherFilter; 00095 00096 bool appendToLastLine( const QString& text ); 00097 void setCompilerOutputLevel(EOutputLevel level); 00098 00099 QStringList commandList; 00100 QStringList dirList; 00101 QString currentCommand; 00102 KProcess *childproc; 00103 ProcessLineMaker* procLineMaker; 00104 QPtrStack<QString> dirstack; 00105 QValueVector<MakeItem*> m_items; 00106 QIntDict<MakeItem> m_paragraphToItem; 00107 long m_paragraphs; 00108 int m_lastErrorSelected; 00109 00110 MakeViewPart *m_part; 00111 00112 bool m_vertScrolling, m_horizScrolling; 00113 bool m_bCompiling; 00114 00115 bool m_bLineWrapping; 00116 EOutputLevel m_compilerOutputLevel; 00117 }; 00118 00119 #endif
KDE Logo
This file is part of the documentation for KDevelop Version 3.0.4.
Documentation copyright © 1996-2004 the KDE developers.
Generated on Tue Oct 19 08:01:52 2004 by doxygen 1.3.7 written by Dimitri van Heesch, © 1997-2003