Commit e5cc92b8 authored by Gabriel Felipe Huwe's avatar Gabriel Felipe Huwe Committed by Nate Graham

Make text from Dolphin's information panel copyable

Summary:
Fixed text from Dolphin's information panel not being copyable by adding the correct text interaction flags to the label.

BUG: 408359
FIXED-IN: 19.08.0

Reviewers: #baloo, #dolphin, ngraham

Reviewed By: #baloo, #dolphin, ngraham

Subscribers: ngraham, #dolphin, #baloo

Tags: #dolphin, #baloo

Differential Revision: https://phabricator.kde.org/D21740
parent 956f2b38
......@@ -121,6 +121,7 @@ void FileMetaDataWidget::Private::deleteRows()
QLabel* FileMetaDataWidget::Private::createLabel(const QString &key, const QString& itemLabel, FileMetaDataWidget* parent)
{
QLabel* label = new QLabel(itemLabel + QLatin1Char(':'), parent);
label->setTextInteractionFlags(Qt::TextSelectableByMouse | Qt::TextSelectableByKeyboard);
label->setSizePolicy(QSizePolicy::MinimumExpanding, QSizePolicy::Preferred);
label->setForegroundRole(parent->foregroundRole());
label->setFont(parent->font());
......
......@@ -238,6 +238,7 @@ QSize ValueWidget::sizeHint() const
QWidget* WidgetFactory::createValueWidget(const QString& value, QWidget* parent)
{
ValueWidget* valueWidget = new ValueWidget(parent);
valueWidget->setTextInteractionFlags(Qt::TextSelectableByMouse | Qt::TextSelectableByKeyboard);
valueWidget->setWordWrap(true);
valueWidget->setAlignment(Qt::AlignTop | Qt::AlignLeft);
valueWidget->setText(m_readOnly ? plainText(value) : value);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment