Albert
Loading...
Searching...
No Matches
albert::InputHistory Class Referencefinal

#include <inputhistory.h>

Inheritance diagram for albert::InputHistory:

Detailed Description

Input history class.

Stores input stings and provides a search iterator. Input line history for frontends.

Public Member Functions

 InputHistory ()
 
 ~InputHistory () override
 
Q_INVOKABLE void add (const QString &str)
 Add text to history search. More...
 
Q_INVOKABLE QString next (const QString &substring=QString{})
 Next distinct history item. More...
 
Q_INVOKABLE QString prev (const QString &substring=QString{})
 Previous distinct history item. More...
 
Q_INVOKABLE void resetIterator ()
 Reset history search. More...
 

Constructor & Destructor Documentation

◆ InputHistory()

albert::InputHistory::InputHistory ( )
explicit

◆ ~InputHistory()

albert::InputHistory::~InputHistory ( )
override

Member Function Documentation

◆ add()

Q_INVOKABLE void albert::InputHistory::add ( const QString &  str)

Add text to history search.

Note
Skips empty strings and drops duplicates.

◆ next()

Q_INVOKABLE QString albert::InputHistory::next ( const QString &  substring = QString{})

Next distinct history item.

Note
Skips perfect matches.

◆ prev()

Q_INVOKABLE QString albert::InputHistory::prev ( const QString &  substring = QString{})

Previous distinct history item.

Note
Skips perfect matches.

◆ resetIterator()

Q_INVOKABLE void albert::InputHistory::resetIterator ( )

Reset history search.


The documentation for this class was generated from the following file: