#ifndef SPELLFILTERVIEWER_H
#define SPELLFILTERVIEWER_H

#include <QWidget>
#include <QLineEdit>
#include <QComboBox>
#include <QCheckBox>
#include <QLabel>
#include "SpellFilter.h"
#include "Spells.h"

class SpellFilterViewer : public QWidget
{
    Q_OBJECT

public:
    explicit SpellFilterViewer(QWidget *parent = 0);
    SpellFilter* toFilter();
    void populate(Spells &spells);
    void setResults(int results);

signals:
    void filterChanged();

private:
    void setupUi();

private slots:
    void materialsClicked();
    void materialsExpensiveClicked();
    void clearClicked();

private:
    QLineEdit *_name;
    QComboBox *_level;
    QComboBox *_school;
    QComboBox *_class;
    QCheckBox *_ritual;
    QCheckBox *_concentration;
    QCheckBox *_vocal;
    QCheckBox *_somatic;
    QCheckBox *_material;
    QCheckBox *_expensiveMaterial;
    QCheckBox *_consumedMaterial;

    QLabel *_results;
};

#endif // SPELLFILTERVIEWER_H
