25 #include <QTableWidget> 26 #include <QToolButton> 29 #include <QPlainTextEdit> 42 connect( tabWidget, SIGNAL( tabCloseRequested(
int ) ),
this, SLOT( closeTab(
int ) ) );
61 tag =
tr(
"General" );
64 for ( i = 0; i < tabWidget->count() && tabWidget->tabText( i ) != tag; i++ )
68 if ( i < tabWidget->count() )
71 tabWidget->setCurrentIndex( i );
77 tabWidget->addTab( w, tag );
78 tabWidget->setCurrentIndex( tabWidget->count() - 1 );
79 tabWidget->setTabsClosable(
true );
89 void QgsMessageLogViewer::closeTab(
int index )
91 tabWidget->removeTab( index );
92 tabWidget->setTabsClosable( tabWidget->count() > 1 );
QString & prepend(QChar ch)
void closeEvent(QCloseEvent *e) override
QString tr(const char *sourceText, const char *disambiguation, int n)
void appendPlainText(const QString &text)
void logMessage(QString message, QString tag, QgsMessageLog::MessageLevel level)
QgsMessageLogViewer(QStatusBar *statusBar=nullptr, QWidget *parent=nullptr, const Qt::WindowFlags &fl=QgisGui::ModalDialogFlags)
QString & replace(int position, int n, QChar after)
void setReadOnly(bool ro)
QDateTime currentDateTime()
static QgsMessageLog * instance()
bool connect(const QObject *sender, const char *signal, const QObject *receiver, const char *method, Qt::ConnectionType type)
QString arg(qlonglong a, int fieldWidth, int base, const QChar &fillChar) const