view include/gui/pages/statistics.h @ 274:f6a756c19bfb

anime_list.cc: use mutexes so we don't sex the stack strings.cc: use Qt to convert from HTML to plain text.
author Paper <paper@paper.us.eu.org>
date Thu, 18 Apr 2024 17:24:42 -0400
parents 3ec7804abf17
children 6b0768158dcd
line wrap: on
line source

#ifndef MINORI_GUI_PAGES_STATISTICS_H_
#define MINORI_GUI_PAGES_STATISTICS_H_

#include <QFrame>
#include <QWidget>

template<typename T>
class Graph;

namespace TextWidgets {
class LabelledSection;
}

class StatisticsPage final : public QFrame {
	Q_OBJECT

public:
	StatisticsPage(QWidget* parent = nullptr);
	void UpdateStatistics();

protected:
	void showEvent(QShowEvent*) override;

private:
	std::shared_ptr<TextWidgets::LabelledSection> _anime_list;
	std::shared_ptr<Graph<int>> _score_distribution_graph;
	std::shared_ptr<TextWidgets::LabelledSection> _application;
};

#endif // MINORI_GUI_PAGES_STATISTICS_H_