libyui-qt-pkg  2.45.6
YQPkgSearchFilterView Class Reference

Filter view for searching within packages. More...

#include <YQPkgSearchFilterView.h>

Inheritance diagram for YQPkgSearchFilterView:
Collaboration diagram for YQPkgSearchFilterView:

Public Slots

void filter ()
 Filter according to the view's rules and current selection. More...
 
void filterIfVisible ()
 Same as filter(), but only if this widget is currently visible.
 
void setFocus ()
 Set the keyboard focus into this view's input field.
 

Signals

void filterStart ()
 Emitted when the filtering starts. More...
 
void filterMatch (ZyppSel selectable, ZyppPkg pkg)
 Emitted during filtering for each pkg that matches the filter.
 
void filterFinished ()
 Emitted when filtering is finished.
 
void message (const QString &text)
 Send a short message about unsuccessful searches.
 

Public Member Functions

 YQPkgSearchFilterView (QWidget *parent)
 Constructor.
 
virtual ~YQPkgSearchFilterView ()
 Destructor.
 
virtual QSize minimumSizeHint () const
 Returns the minimum size required for this widget. More...
 
bool check (ZyppSel selectable, ZyppObj zyppObj)
 Check one ResObject against the currently selected values. More...
 

Protected Types

enum  SearchMode {
  Contains = 0, BeginsWith, ExactMatch, UseWildcards,
  UseRegExp
}
 

Protected Member Functions

virtual void keyPressEvent (QKeyEvent *event)
 Key press event: Execute search upon 'Return' Reimplemented from QVBox / QWidget.
 
bool check (ZyppSel selectable, ZyppObj zyppObj, const QRegExp &regexp)
 Check if pkg matches the search criteria.
 
bool check (const string &attribute, const QRegExp &regexp)
 Check if a single pkg attribute matches the search criteria.
 
bool check (const zypp::Capabilities &capSet, const QRegExp &regexp)
 Check capability like zypp::Resolvable::dep( zypp::Dep::PROVIDES ), zypp::Resolvable::dep( zypp::Dep::REQUIRES )
 

Protected Attributes

QComboBox * _searchText
 
QPushButton * _searchButton
 
QCheckBox * _searchInName
 
QCheckBox * _searchInKeywords
 
QCheckBox * _searchInSummary
 
QCheckBox * _searchInDescription
 
QCheckBox * _searchInRequires
 
QCheckBox * _searchInProvides
 
QCheckBox * _searchInFileList
 
QComboBox * _searchMode
 
QCheckBox * _caseSensitive
 
int _matchCount
 

Detailed Description

Filter view for searching within packages.

Definition at line 63 of file YQPkgSearchFilterView.h.

Member Function Documentation

bool YQPkgSearchFilterView::check ( ZyppSel  selectable,
ZyppObj  zyppObj 
)

Check one ResObject against the currently selected values.

Returns true if the package matches, false if not.

Definition at line 373 of file YQPkgSearchFilterView.cc.

void YQPkgSearchFilterView::filter ( )
slot

Filter according to the view's rules and current selection.

Emits those signals: filterStart() filterMatch() for each pkg that matches the filter filterFinished()

Definition at line 230 of file YQPkgSearchFilterView.cc.

void YQPkgSearchFilterView::filterStart ( )
signal

Emitted when the filtering starts.

Use this to clear package lists etc. prior to adding new entries.

QSize YQPkgSearchFilterView::minimumSizeHint ( ) const
virtual

Returns the minimum size required for this widget.

Inherited from QWidget.

Definition at line 215 of file YQPkgSearchFilterView.cc.


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