#include <QFileDialog>
#include <QLayout>
#include <QMouseEvent>
+#include <QScrollArea>
#include <QtConcurrent/QtConcurrent>
#include "bigintwidget.h"
BigintWidget::BigintWidget(QWidget *parent)
: QWidget(parent),
fw(new QFutureWatcher<MandelResultCell>(this)),
- meta(8192, QSize(1800, 900)),
+ meta(128, QSize(1800, 900)),
img_label(new QLabel(this)),
img_dirty(true),
status_bar(new QStatusBar(this))
{
+ QScrollArea *scroll_area = new QScrollArea(this);
+ scroll_area->setWidget(img_label);
connect(
fw,
&QFutureWatcher<MandelResultCell>::resultReadyAt,
fw->setFuture(QtConcurrent::mapped(meta.get_cells(), MandelMeta::iterate));
setLayout(new QVBoxLayout());
layout()->addWidget(setup_menu_bar());
- layout()->addWidget(img_label);
+ layout()->addWidget(scroll_area);
status_bar->setSizeGripEnabled(false);
layout()->addWidget(status_bar);
img_label->setMinimumSize(meta.get_size());
&BigintWidget::close
);
menu_bar->addMenu(menu);
-/*
- menu = new QMenu("&Calcluation", this);
- connect(
- menu->addAction("&Double Max Iterations"),
- &QAction::triggered,
- this,
- &meta.double_max_iter
- );
- connect(
- menu->addAction("&Halve Max Iterations"),
- &QAction::triggered,
- this,
- &meta.halve_max_iter
- );
-*/
return menu_bar;
}