45 #include <QtCore/qdebug.h> 46 #include <QtGui/qboxlayout.h> 47 #include <QtGui/qplaintextedit.h> 48 #include <QtGui/qscrollbar.h> 57 QScriptDebugOutputWidgetOutputEdit(
QWidget *parent = 0)
71 int charactersPerLine()
const 74 return width() / fm.maxWidth();
103 d->outputEdit =
new QScriptDebugOutputWidgetOutputEdit();
109 #ifndef QT_NO_STYLE_STYLESHEET 121 int lineNumber,
int columnNumber,
const QVariant &)
126 if (!fileName.
isEmpty() || (lineNumber != -1)) {
131 if (lineNumber != -1) {
134 if (columnNumber != -1) {
146 d->outputEdit->setCurrentCharFormat(fmt);
148 d->outputEdit->appendPlainText(msg);
149 d->outputEdit->setCurrentCharFormat(oldFmt);
150 d->outputEdit->scrollToBottom();
156 d->outputEdit->clear();
static QString number(int, int base=10)
This is an overloaded member function, provided for convenience. It differs from the above function o...
The QVariant class acts like a union for the most common Qt data types.
The QTextCharFormat class provides formatting information for characters in a QTextDocument.
The QFontMetrics class provides font metrics information.
#define QT_END_NAMESPACE
This macro expands to.
QLatin1String(DBUS_INTERFACE_DBUS))) Q_GLOBAL_STATIC_WITH_ARGS(QString
The QString class provides a Unicode character string.
QtMsgType
This enum describes the messages that can be sent to a message handler (QtMsgHandler).
void addWidget(QWidget *, int stretch=0, Qt::Alignment alignment=0)
Adds widget to the end of this box layout, with a stretch factor of stretch and alignment alignment...
void setMaximumBlockCount(int maximum)
#define QT_BEGIN_NAMESPACE
This macro expands to.
bool isEmpty() const
Returns true if the string has no characters; otherwise returns false.
The QPlainTextEdit class provides a widget that is used to edit and display plain text...
#define Q_DECLARE_PUBLIC(Class)
QString & append(QChar c)
static QString fromLatin1(const char *, int size=-1)
Returns a QString initialized with the first size characters of the Latin-1 string str...
void setSpacing(int spacing)
Reimplements QLayout::setSpacing().
void setForeground(const QBrush &brush)
Sets the foreground brush to the specified brush.
The QVBoxLayout class lines up widgets vertically.
void setReadOnly(bool ro)
static QString fileName(const QString &fileUrl)
The QLatin1Char class provides an 8-bit ASCII/Latin-1 character.