BALL
1.5.0
include
BALL
VIEW
WIDGETS
logView.h
Go to the documentation of this file.
1
// -*- Mode: C++; tab-width: 2; -*-
2
// vi: set ts=2:
3
//
4
5
#ifndef BALL_VIEW_WIDGETS_LOGVIEW_H
6
#define BALL_VIEW_WIDGETS_LOGVIEW_H
7
8
#include <
BALL/common.h
>
9
#include <
BALL/VIEW/WIDGETS/dockWidget.h
>
10
11
#include <QtWidgets/QTextBrowser>
12
#include <QtGui/QDragEnterEvent>
13
#include <QtGui/QDragLeaveEvent>
14
#include <QtGui/QDropEvent>
15
16
namespace
BALL
17
{
18
namespace
VIEW
19
{
20
class
DragLogView
21
:
public
QTextBrowser
22
{
23
Q_OBJECT
24
25
public
:
26
27
DragLogView
(
QWidget
* parent);
28
29
public
Q_SLOTS:
30
virtual
void
contentsDragEnterEvent
(QDragEnterEvent* e);
31
virtual
void
contentsDragLeaveEvent
(QDragLeaveEvent* e);
32
virtual
void
contentsDropEvent
(QDropEvent* e);
33
virtual
void
setSource
(
const
QUrl&
/* name */
);
34
};
35
47
class
BALL_VIEW_EXPORT
LogView
48
:
public
DockWidget
,
49
public
LogStreamNotifier
50
{
51
Q_OBJECT
52
53
public
:
54
55
BALL_EMBEDDABLE
(
LogView
,
DockWidget
)
56
57
64
LogView
(
QWidget
*parent = 0,
const
char
*name = 0);
65
70
LogView
(
const
LogView
& view);
71
75
virtual
~
LogView
();
76
79
virtual
void
initializeWidget(
MainControl
& main_control);
80
83
virtual
void
finalizeWidget(
MainControl
& main_control);
84
85
// output a string
86
void
logString
(
const
String
& text);
87
88
public
Q_SLOTS:
89
90
virtual
void
showGuestContextMenu(
const
QPoint&);
91
93
bool
eventFilter(
QObject
*,
QEvent
*);
94
95
protected
:
96
103
void
logNotify();
104
105
private
:
106
107
QTextEdit* text_edit_;
108
};
109
110
} }
// namespaces
111
112
#endif // BALL_VIEW_WIDGETS_LOGVIEW_H
BALL::LogStreamNotifier
Definition:
logStream.h:210
BALL::VIEW::LogView
Definition:
logView.h:47
BALL::VIEW::DragLogView::contentsDragLeaveEvent
virtual void contentsDragLeaveEvent(QDragLeaveEvent *e)
QObject
dockWidget.h
BALL::VIEW::DragLogView
Definition:
logView.h:20
QEvent
BALL::String
Definition:
string.h:56
BALL_EMBEDDABLE
#define BALL_EMBEDDABLE(TYPE, BASE)
Definition:
embeddable.h:31
BALL::VIEW::MainControl
Definition:
mainControl.h:114
BALL
Definition:
constants.h:12
BALL::VIEW::DragLogView::contentsDropEvent
virtual void contentsDropEvent(QDropEvent *e)
QWidget
BALL::VIEW::DockWidget
Definition:
dockWidget.h:25
common.h
BALL::VIEW::DragLogView::contentsDragEnterEvent
virtual void contentsDragEnterEvent(QDragEnterEvent *e)
BALL_VIEW_EXPORT
#define BALL_VIEW_EXPORT
Definition:
COMMON/global.h:52
BALL::VIEW::DragLogView::setSource
virtual void setSource(const QUrl &)
BALL::VIEW::logString
BALL_VIEW_EXPORT void logString(const String &data)
thread safe output to logview
BALL::VIEW::DragLogView::DragLogView
DragLogView(QWidget *parent)
QTextBrowser
Generated by
1.8.17