Make sidebar topic expand on click and fix html formatting of elided text. (#96)
Fixes #95
This commit is contained in:
parent
8299a74775
commit
3205e5fdd3
5 changed files with 102 additions and 6 deletions
26
include/ui/Label.h
Normal file
26
include/ui/Label.h
Normal file
|
|
@ -0,0 +1,26 @@
|
|||
#pragma once
|
||||
|
||||
#include <QLabel>
|
||||
|
||||
class Label : public QLabel
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
explicit Label(QWidget *parent = Q_NULLPTR, Qt::WindowFlags f = Qt::WindowFlags());
|
||||
explicit Label(const QString &text,
|
||||
QWidget *parent = Q_NULLPTR,
|
||||
Qt::WindowFlags f = Qt::WindowFlags());
|
||||
~Label() override {}
|
||||
|
||||
signals:
|
||||
void clicked(QMouseEvent *e);
|
||||
void pressed(QMouseEvent *e);
|
||||
void released(QMouseEvent *e);
|
||||
|
||||
protected:
|
||||
void mousePressEvent(QMouseEvent *e) override;
|
||||
void mouseReleaseEvent(QMouseEvent *e) override;
|
||||
|
||||
QPoint pressPosition_;
|
||||
};
|
||||
Loading…
Add table
Add a link
Reference in a new issue