KProperty
22#ifndef KPROPERTY_STRINGEDIT_H
23#define KPROPERTY_STRINGEDIT_H
25#include "KPropertyWidgetsFactory.h"
29class KPROPERTYWIDGETS_EXPORT KPropertyStringEditor :
public QLineEdit
32 Q_PROPERTY(QString value READ value WRITE setValue USER
true)
34 explicit KPropertyStringEditor(QWidget *parent =
nullptr);
36 ~KPropertyStringEditor()
override;
38 QString value()
const;
41 void commitData( QWidget * editor );
44 void setValue(
const QString& value);
47 void slotTextChanged(
const QString & text );
50 Q_DISABLE_COPY(KPropertyStringEditor)
56 public KPropertyValuePainterInterface,
60 KPropertyStringDelegate();
62 QWidget *createEditor(
int type, QWidget *parent,
const QStyleOptionViewItem &option,
63 const QModelIndex &index)
const override;
65 void paint(QPainter *painter,
66 const QStyleOptionViewItem &option,
const QModelIndex &index)
const override;
68 QString valueToString(
const QVariant& value,
const QLocale &locale)
const override;
An interface for editor widget creators.
Provides a specialized conversion of value to string depending on type.
This file is part of the KDE documentation.
Documentation copyright © 1996-2025 The KDE developers.
Generated on Fri Jan 24 2025 11:57:41 by
doxygen 1.13.2 written
by
Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.