2018-04-06 15:30:24 +00:00
|
|
|
/******************************************************************************
|
|
|
|
* QSkinny - Copyright (C) 2016 Uwe Rathmann
|
2023-04-06 07:23:37 +00:00
|
|
|
* SPDX-License-Identifier: BSD-3-Clause
|
2018-04-06 15:30:24 +00:00
|
|
|
*****************************************************************************/
|
|
|
|
|
2018-04-26 12:42:33 +00:00
|
|
|
#ifndef QSK_INPUT_PREDICTION_BAR_H
|
|
|
|
#define QSK_INPUT_PREDICTION_BAR_H
|
2018-04-06 15:30:24 +00:00
|
|
|
|
|
|
|
#include "QskBox.h"
|
|
|
|
|
2018-04-26 12:42:33 +00:00
|
|
|
class QSK_EXPORT QskInputPredictionBar : public QskBox
|
2018-04-06 15:30:24 +00:00
|
|
|
{
|
|
|
|
Q_OBJECT
|
|
|
|
|
|
|
|
using Inherited = QskBox;
|
|
|
|
|
2018-08-03 06:15:28 +00:00
|
|
|
public:
|
2018-04-06 15:30:24 +00:00
|
|
|
QSK_SUBCONTROLS( Panel, ButtonPanel, ButtonText )
|
|
|
|
|
2018-04-26 12:42:33 +00:00
|
|
|
QskInputPredictionBar( QQuickItem* parent = nullptr );
|
2018-07-31 15:32:25 +00:00
|
|
|
~QskInputPredictionBar() override;
|
2018-04-06 15:30:24 +00:00
|
|
|
|
2018-05-01 09:52:29 +00:00
|
|
|
QStringList candidates() const;
|
2018-04-10 14:51:35 +00:00
|
|
|
|
2018-08-03 06:15:28 +00:00
|
|
|
Q_SIGNALS:
|
2018-04-26 12:42:33 +00:00
|
|
|
void predictiveTextSelected( int );
|
2018-04-06 15:30:24 +00:00
|
|
|
|
2018-08-03 06:15:28 +00:00
|
|
|
public Q_SLOTS:
|
2018-05-01 09:52:29 +00:00
|
|
|
void setPrediction( const QStringList& );
|
2018-04-06 15:30:24 +00:00
|
|
|
|
2021-08-05 13:30:27 +00:00
|
|
|
protected:
|
2021-08-04 13:06:04 +00:00
|
|
|
QskAspect::Subcontrol substitutedSubcontrol(
|
|
|
|
QskAspect::Subcontrol ) const override;
|
|
|
|
|
2018-04-26 12:42:33 +00:00
|
|
|
void buttonClicked();
|
|
|
|
void setScrollOffset( int );
|
2018-04-06 15:30:24 +00:00
|
|
|
|
|
|
|
class PrivateData;
|
|
|
|
std::unique_ptr< PrivateData > m_data;
|
|
|
|
};
|
|
|
|
|
|
|
|
#endif
|