Hi Dimitris,

Silica SearchField is just a specially-styled TextField, the actual search 
string filtering should be implemented in the application model 
(QAbstractListModel or QML ListModel). For an example of how to use SearchField 
see Search page in Component Gallery. When displaying the search results on the 
view, please use Theme.highlightText(model.text, searchString, 
Theme.highlightColor) to highlight the matched sub-text on the search results.

Qt Quick unfortunately lacks generic proxy models for doing filtering, so 
implementing filtering to models can be a bit of pain. Be careful when adding, 
removing and updating model items during an active search, badly written model 
logic often leads to lousy performance when the view unnecessarily 
re-constructs view delegates.

Cheers,

Joona

________________________________________
From: devel-boun...@lists.sailfishos.org [devel-boun...@lists.sailfishos.org] 
on behalf of Dimitris [sarlis....@gmail.com]
Sent: 14 August 2013 14:42
To: devel@lists.sailfishos.org
Subject: [SailfishDevel] Search Field Component

Hello,

I want to use this component and there is not much info about it in the
documentation. Is it just a TextField with two additional icons or does
it actually filters the result according to the text given? Because if
it doesn't I have to implement it on my own.

Thanks.
_______________________________________________
SailfishOS.org Devel mailing list
_______________________________________________
SailfishOS.org Devel mailing list

Reply via email to