| 1 | /**************************************************************************** |
| 2 | ** |
| 3 | ** Copyright (C) 2018 The Qt Company Ltd. |
| 4 | ** Contact: https://www.qt.io/licensing/ |
| 5 | ** |
| 6 | ** This file is part of the QtSCriptTools module of the Qt Toolkit. |
| 7 | ** |
| 8 | ** $QT_BEGIN_LICENSE:LGPL$ |
| 9 | ** Commercial License Usage |
| 10 | ** Licensees holding valid commercial Qt licenses may use this file in |
| 11 | ** accordance with the commercial license agreement provided with the |
| 12 | ** Software or, alternatively, in accordance with the terms contained in |
| 13 | ** a written agreement between you and The Qt Company. For licensing terms |
| 14 | ** and conditions see https://www.qt.io/terms-conditions. For further |
| 15 | ** information use the contact form at https://www.qt.io/contact-us. |
| 16 | ** |
| 17 | ** GNU Lesser General Public License Usage |
| 18 | ** Alternatively, this file may be used under the terms of the GNU Lesser |
| 19 | ** General Public License version 3 as published by the Free Software |
| 20 | ** Foundation and appearing in the file LICENSE.LGPL3 included in the |
| 21 | ** packaging of this file. Please review the following information to |
| 22 | ** ensure the GNU Lesser General Public License version 3 requirements |
| 23 | ** will be met: https://www.gnu.org/licenses/lgpl-3.0.html. |
| 24 | ** |
| 25 | ** GNU General Public License Usage |
| 26 | ** Alternatively, this file may be used under the terms of the GNU |
| 27 | ** General Public License version 2.0 or (at your option) the GNU General |
| 28 | ** Public license version 3 or any later version approved by the KDE Free |
| 29 | ** Qt Foundation. The licenses are as published by the Free Software |
| 30 | ** Foundation and appearing in the file LICENSE.GPL2 and LICENSE.GPL3 |
| 31 | ** included in the packaging of this file. Please review the following |
| 32 | ** information to ensure the GNU General Public License requirements will |
| 33 | ** be met: https://www.gnu.org/licenses/gpl-2.0.html and |
| 34 | ** https://www.gnu.org/licenses/gpl-3.0.html. |
| 35 | ** |
| 36 | ** $QT_END_LICENSE$ |
| 37 | ** |
| 38 | ****************************************************************************/ |
| 39 | |
| 40 | #include "qscripterrorlogwidget_p.h"cxx . . $ `<file>/src/scripttools/debugging/qscripterrorlogwidget_p.h`/ |
| 41 | #include "qscripterrorlogwidgetinterface_p_p.h"cxx . . $ `<file>/src/scripttools/debugging/qscripterrorlogwidgetinterface_p_p.h`/ |
| 42 | |
| 43 | #include <QtCore/qdatetime.h> |
| 44 | #include <QtWidgets/qboxlayout.h> |
| 45 | #include <QtWidgets/qtextedit.h> |
| 46 | #include <QtWidgets/qscrollbar.h> |
| 47 | #include <QtCore/qdebug.h> |
| 48 | |
| 49 | QT_BEGIN_NAMESPACEcxx . . $ `<external>/15045578679651060896/qglobal.h:148:10`! |
| 50 | |
| 51 | namespacecxx . . $ `$anonymous_namespace_src/scripttools/debugging/qscripterrorlogwidget.cpp`/ { |
| 52 | |
| 53 | class QScriptErrorLogWidgetOutputEditcxx . . $ `$anonymous_namespace_src/scripttools/debugging/qscripterrorlogwidget.cpp`/QScriptErrorLogWidgetOutputEdit# : public QTextEditcxx . . $ QTextEdit# |
| 54 | { |
| 55 | public: |
| 56 | QScriptErrorLogWidgetOutputEditcxx . . $ `$anonymous_namespace_src/scripttools/debugging/qscripterrorlogwidget.cpp`/QScriptErrorLogWidgetOutputEdit#QScriptErrorLogWidgetOutputEdit(108f35f7aa7f3cf9).(QWidgetcxx . . $ QWidget# *parent = 0) |
| 57 | : QTextEditcxx . . $ QTextEdit#(parent) |
| 58 | { |
| 59 | setReadOnlycxx . . $ QTextEdit#setReadOnly(b45ddcbc8423892c).(true); |
| 60 | // setFocusPolicy(Qt::NoFocus); |
| 61 | documentcxx . . $ QTextEdit#document(f21741221844491e).()->setMaximumBlockCount(255); |
| 62 | } |
| 63 | |
| 64 | void scrollToBottomcxx . . $ `$anonymous_namespace_src/scripttools/debugging/qscripterrorlogwidget.cpp`/QScriptErrorLogWidgetOutputEdit#scrollToBottom(49f6e7a06ebc5aa8).() |
| 65 | { |
| 66 | QScrollBarcxx . . $ QScrollBar# *bar = verticalScrollBarcxx . . $ QAbstractScrollArea#verticalScrollBar(49d9510c6adf8c19).(); |
| 67 | bar->setValuecxx . . $ QAbstractSlider#setValue(d4f767463ce0a6b3).(bar->maximumcxx . . $ QAbstractSlider#maximum(455f465bc33b4cdf).()); |
| 68 | } |
| 69 | }; |
| 70 | |
| 71 | } // namespace |
| 72 | |
| 73 | class QScriptErrorLogWidgetPrivatecxx . . $ QScriptErrorLogWidgetPrivate# |
| 74 | : public QScriptErrorLogWidgetInterfacePrivatecxx . . $ QScriptErrorLogWidgetInterfacePrivate# |
| 75 | { |
| 76 | Q_DECLARE_PUBLICcxx . . $ `<external>/15045578679651060896/qglobal.h:1172:9`!(QScriptErrorLogWidget) |
| 77 | public: |
| 78 | QScriptErrorLogWidgetPrivatecxx . . $ QScriptErrorLogWidgetPrivate#QScriptErrorLogWidgetPrivate(49f6e7a06ebc5aa8).(); |
| 79 | ~cxx . . $ QScriptErrorLogWidgetPrivate#`~QScriptErrorLogWidgetPrivate`(ced63f7c635d850d).QScriptErrorLogWidgetPrivatecxx . . $ QScriptErrorLogWidgetPrivate#(); |
| 80 | |
| 81 | QScriptErrorLogWidgetOutputEditcxx . . $ `$anonymous_namespace_src/scripttools/debugging/qscripterrorlogwidget.cpp`/QScriptErrorLogWidgetOutputEdit# *outputEditcxx . . $ QScriptErrorLogWidgetPrivate#outputEdit.; |
| 82 | }; |
| 83 | |
| 84 | QScriptErrorLogWidgetPrivatecxx . . $ QScriptErrorLogWidgetPrivate#::QScriptErrorLogWidgetPrivatecxx . . $ QScriptErrorLogWidgetPrivate#QScriptErrorLogWidgetPrivate(49f6e7a06ebc5aa8).() |
| 85 | { |
| 86 | } |
| 87 | |
| 88 | QScriptErrorLogWidgetPrivatecxx . . $ QScriptErrorLogWidgetPrivate#::~cxx . . $ QScriptErrorLogWidgetPrivate#`~QScriptErrorLogWidgetPrivate`(ced63f7c635d850d).QScriptErrorLogWidgetPrivatecxx . . $ QScriptErrorLogWidgetPrivate#() |
| 89 | { |
| 90 | } |
| 91 | |
| 92 | QScriptErrorLogWidgetcxx . . $ QScriptErrorLogWidget#::QScriptErrorLogWidgetcxx . . $ QScriptErrorLogWidget#QScriptErrorLogWidget(108f35f7aa7f3cf9).(QWidgetcxx . . $ QWidget# *parent) |
| 93 | : QScriptErrorLogWidgetInterfacecxx . . $ QScriptErrorLogWidgetInterface#(*new QScriptErrorLogWidgetPrivatecxx . . $ QScriptErrorLogWidgetPrivate#QScriptErrorLogWidgetPrivate(49f6e7a06ebc5aa8)., parent, {}) |
| 94 | { |
| 95 | Q_Dcxx . . $ `<external>/15045578679651060896/qglobal.h:1177:9`!(QScriptErrorLogWidget); |
| 96 | d->outputEditcxx . . $ QScriptErrorLogWidgetPrivate#outputEdit. = new QScriptErrorLogWidgetOutputEditcxx . . $ `$anonymous_namespace_src/scripttools/debugging/qscripterrorlogwidget.cpp`/QScriptErrorLogWidgetOutputEdit#(); |
| 97 | QVBoxLayoutcxx . . $ QVBoxLayout# *vbox = new QVBoxLayout(this); |
| 98 | vbox->setContentsMarginscxx . . $ QLayout#setContentsMargins(79c4c8645766fc71).(0, 0, 0, 0); |
| 99 | vbox->setSpacingcxx . . $ QBoxLayout#setSpacing(d4f767463ce0a6b3).(0); |
| 100 | vbox->addWidgetcxx . . $ QBoxLayout#addWidget(d39963fa34d6acb).(d->outputEditcxx . . $ QScriptErrorLogWidgetPrivate#outputEdit.); |
| 101 | |
| 102 | // QString sheet = QString::fromLatin1("font-size: 14px; font-family: \"Monospace\";"); |
| 103 | // setStyleSheet(sheet); |
| 104 | } |
| 105 | |
| 106 | QScriptErrorLogWidgetcxx . . $ QScriptErrorLogWidget#::~cxx . . $ QScriptErrorLogWidget#`~QScriptErrorLogWidget`(ced63f7c635d850d).QScriptErrorLogWidgetcxx . . $ QScriptErrorLogWidget#() |
| 107 | { |
| 108 | } |
| 109 | |
| 110 | void QScriptErrorLogWidgetcxx . . $ QScriptErrorLogWidget#::messagecxx . . $ QScriptErrorLogWidget#message(2525eba6d4edee60).( |
| 111 | QtMsgTypecxx . . $ QtMsgType# type, const QStringcxx . . $ QString# &text, const QStringcxx . . $ QString# &fileName, |
| 112 | int lineNumber, int columnNumber, const QVariantcxx . . $ QVariant# &/*data*/) |
| 113 | { |
| 114 | // ### we need the error message rather than Error.toString() |
| 115 | Q_UNUSEDcxx . . $ `<external>/15045578679651060896/qglobal.h:117:9`!(type); |
| 116 | Q_UNUSEDcxx . . $ `<external>/15045578679651060896/qglobal.h:117:9`!(fileName); |
| 117 | Q_UNUSEDcxx . . $ `<external>/15045578679651060896/qglobal.h:117:9`!(lineNumber); |
| 118 | Q_UNUSEDcxx . . $ `<external>/15045578679651060896/qglobal.h:117:9`!(columnNumber); |
| 119 | Q_Dcxx . . $ `<external>/15045578679651060896/qglobal.h:1177:9`!(QScriptErrorLogWidget); |
| 120 | QStringcxx . . $ QString# htmlcxx . . $ QString#QString(ced63f7c635d850d).; |
| 121 | html.appendcxx . . $ QString#append(6a89d0b7f4d2681c).(QStringcxx . . $ QString#::fromLatin1cxx . . $ QString#fromLatin1(5ac70cc0fa2a874e).("<b>%0</b> %1<br>") |
| 122 | .argcxx . . $ QString#arg(bc823072288cbbb5).(QDateTimecxx . . $ QDateTime#::currentDateTimecxx . . $ QDateTime#currentDateTime(bf5129c8228c71c0).().toStringcxx . . $ QDateTime#toString(7b7e68bded046f2f).()).argcxx . . $ QString#arg(bc823072288cbbb5).(text.toHtmlEscapedcxx . . $ QString#toHtmlEscaped(6ef7b6c27b00b43d).())); |
| 123 | d->outputEditcxx . . $ QScriptErrorLogWidgetPrivate#outputEdit.->insertHtmlcxx . . $ QTextEdit#insertHtml(3520e46b33348bf6).(html); |
| 124 | d->outputEditcxx . . $ QScriptErrorLogWidgetPrivate#outputEdit.->scrollToBottomcxx . . $ `$anonymous_namespace_src/scripttools/debugging/qscripterrorlogwidget.cpp`/QScriptErrorLogWidgetOutputEdit#scrollToBottom(49f6e7a06ebc5aa8).(); |
| 125 | } |
| 126 | |
| 127 | void QScriptErrorLogWidgetcxx . . $ QScriptErrorLogWidget#::clearcxx . . $ QScriptErrorLogWidget#clear(49f6e7a06ebc5aa8).() |
| 128 | { |
| 129 | Q_Dcxx . . $ `<external>/15045578679651060896/qglobal.h:1177:9`!(QScriptErrorLogWidget); |
| 130 | d->outputEditcxx . . $ QScriptErrorLogWidgetPrivate#outputEdit.->clearcxx . . $ QTextEdit#clear(49f6e7a06ebc5aa8).(); |
| 131 | } |
| 132 | |
| 133 | QT_END_NAMESPACEcxx . . $ `<external>/15045578679651060896/qglobal.h:149:10`! |