本文整理汇总了C++中QScrollArea::setFrameShape方法的典型用法代码示例。如果您正苦于以下问题:C++ QScrollArea::setFrameShape方法的具体用法?C++ QScrollArea::setFrameShape怎么用?C++ QScrollArea::setFrameShape使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类QScrollArea
的用法示例。
在下文中一共展示了QScrollArea::setFrameShape方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: createLabels
void MusicRecommendFoundWidget::createLabels()
{
delete m_statusLabel;
m_statusLabel = nullptr;
initFirstWidget();
m_container->show();
layout()->removeWidget(m_mainWindow);
QScrollArea *scrollArea = new QScrollArea(this);
scrollArea->setStyleSheet(MusicUIObject::MScrollBarStyle01);
scrollArea->setWidgetResizable(true);
scrollArea->setFrameShape(QFrame::NoFrame);
scrollArea->setAlignment(Qt::AlignLeft);
scrollArea->setWidget(m_mainWindow);
layout()->addWidget(scrollArea);
QWidget *function = new QWidget(m_mainWindow);
function->setStyleSheet(MusicUIObject::MCheckBoxStyle01 + MusicUIObject::MPushButtonStyle03);
QVBoxLayout *grid = new QVBoxLayout(function);
QLabel *firstLabel = new QLabel(function);
firstLabel->setText(tr("<font color=#158FE1> Recommend Music</font>"));
grid->addWidget(firstLabel);
QLabel *iconLabel = new QLabel(function);
iconLabel->setPixmap(QPixmap(":/image/lb_recmd_daily"));
grid->addWidget(iconLabel);
////////////////////////////////////////////////////////////////////////////
grid->addWidget(m_container);
m_mainWindow->layout()->addWidget(function);
}
示例2: QDialog
DownloadRegionDialog::DownloadRegionDialog( MarbleWidget *const widget, QWidget * const parent,
Qt::WindowFlags const f )
: QDialog( parent, f ),
d( new Private( widget, this ))
{
setWindowTitle( tr( "Download Region" ));
QVBoxLayout * const layout = new QVBoxLayout;
layout->addWidget( d->createSelectionMethodBox() );
layout->addWidget( d->m_tileLevelRangeWidget );
layout->addLayout( d->createTilesCounter() );
if ( MarbleGlobal::getInstance()->profiles() & MarbleGlobal::SmallScreen ) {
QWidget* widget = new QWidget( this );
widget->setLayout( layout );
QScrollArea* scrollArea = new QScrollArea( this );
scrollArea->setFrameShape( QFrame::NoFrame );
scrollArea->setWidget( widget );
QVBoxLayout * const mainLayout = new QVBoxLayout;
mainLayout->addWidget( scrollArea );
mainLayout->addWidget( d->createOkCancelButtonBox() );
setLayout( mainLayout );
} else {
layout->addWidget( d->createOkCancelButtonBox() );
setLayout( layout );
}
connect( d->m_latLonBoxWidget, SIGNAL(valueChanged()), SLOT(updateTilesCount()) );
connect( d->m_tileLevelRangeWidget, SIGNAL(topLevelChanged(int)),
SLOT(updateTilesCount()) );
connect( d->m_tileLevelRangeWidget, SIGNAL(bottomLevelChanged(int)),
SLOT(updateTilesCount()) );
connect( d->m_routeOffsetSpinBox, SIGNAL(valueChanged(double)), SLOT(updateTilesCount()) );
connect( d->m_routeOffsetSpinBox, SIGNAL(valueChanged(double)), SLOT(setOffsetUnit()) );
connect( d->m_model, SIGNAL(themeChanged(QString)), SLOT(updateTilesCount()) );
}
示例3: setupUi
void TwitterApiShowThread::setupUi()
{
kDebug();
QVBoxLayout *gridLayout;
QScrollArea *scrollArea;
QWidget *scrollAreaWidgetContents;
QVBoxLayout *verticalLayout_2;
QSpacerItem *verticalSpacer;
gridLayout = new QVBoxLayout(this);
gridLayout->setMargin(0);
gridLayout->setObjectName("gridLayout");
scrollArea = new QScrollArea(this);
scrollArea->setObjectName("scrollArea");
scrollArea->setFrameShape(QFrame::NoFrame);
scrollArea->setWidgetResizable(true);
scrollAreaWidgetContents = new QWidget();
scrollAreaWidgetContents->setObjectName("scrollAreaWidgetContents");
scrollAreaWidgetContents->setGeometry(QRect(0, 0, 254, 300));
verticalLayout_2 = new QVBoxLayout(scrollAreaWidgetContents);
verticalLayout_2->setMargin(1);
d->mainLayout = new QVBoxLayout();
verticalSpacer = new QSpacerItem(20, 40, QSizePolicy::Minimum, QSizePolicy::Expanding);
d->mainLayout->addItem(verticalSpacer);
d->mainLayout->setSpacing(3);
d->mainLayout->setMargin(1);
verticalLayout_2->addLayout(d->mainLayout);
scrollArea->setWidget(scrollAreaWidgetContents);
gridLayout->addWidget(scrollArea);
}
示例4: resizeEvent
void DlgPreferencesImp::resizeEvent(QResizeEvent* ev)
{
if (canEmbedScrollArea) {
// embed the widget stack into a scroll area if the size is
// bigger than the available desktop
QRect rect = QApplication::desktop()->availableGeometry();
int maxHeight = rect.height();
int maxWidth = rect.width();
if (height() > maxHeight || width() > maxWidth) {
canEmbedScrollArea = false;
ui->hboxLayout->removeWidget(ui->tabWidgetStack);
QScrollArea* scrollArea = new QScrollArea(this);
scrollArea->setFrameShape(QFrame::NoFrame);
scrollArea->setWidgetResizable(true);
scrollArea->setWidget(ui->tabWidgetStack);
ui->hboxLayout->addWidget(scrollArea);
// if possible the minimum width should so that it doesn't show
// a horizontal scroll bar.
QScrollBar* bar = scrollArea->verticalScrollBar();
if (bar) {
int newWidth = width() + bar->width();
newWidth = std::min<int>(newWidth, maxWidth);
int newHeight = std::min<int>(height(), maxHeight-30);
QMetaObject::invokeMethod(this, "resizeWindow",
Qt::QueuedConnection,
QGenericReturnArgument(),
Q_ARG(int, newWidth),
Q_ARG(int, newHeight));
}
}
}
示例5: CreatePartControl
void QmitkFunctionality::CreatePartControl(void* parent)
{
// scrollArea
QScrollArea* scrollArea = new QScrollArea;
//QVBoxLayout* scrollAreaLayout = new QVBoxLayout(scrollArea);
scrollArea->setFrameShadow(QFrame::Plain);
scrollArea->setFrameShape(QFrame::NoFrame);
scrollArea->setHorizontalScrollBarPolicy(Qt::ScrollBarAsNeeded);
scrollArea->setVerticalScrollBarPolicy(Qt::ScrollBarAsNeeded);
// m_Parent
m_Parent = new QWidget;
//m_Parent->setSizePolicy(QSizePolicy(QSizePolicy::MinimumExpanding, QSizePolicy::MinimumExpanding));
this->CreateQtPartControl(m_Parent);
//scrollAreaLayout->addWidget(m_Parent);
//scrollArea->setLayout(scrollAreaLayout);
// set the widget now
scrollArea->setWidgetResizable(true);
scrollArea->setWidget(m_Parent);
// add the scroll area to the real parent (the view tabbar)
QWidget* parentQWidget = static_cast<QWidget*>(parent);
QVBoxLayout* parentLayout = new QVBoxLayout(parentQWidget);
parentLayout->setMargin(0);
parentLayout->setSpacing(0);
parentLayout->addWidget(scrollArea);
// finally set the layout containing the scroll area to the parent widget (= show it)
parentQWidget->setLayout(parentLayout);
this->AfterCreateQtPartControl();
}
示例6: AddPage
void SettingsDialog::AddPage(Page id, SettingsPage* page) {
// Connect page's signals to the settings dialog's signals
connect(page, SIGNAL(NotificationPreview(OSD::Behaviour,QString,QString)),
SIGNAL(NotificationPreview(OSD::Behaviour,QString,QString)));
connect(page, SIGNAL(SetWiimotedevInterfaceActived(bool)),
SIGNAL(SetWiimotedevInterfaceActived(bool)));
// Create the list item
QListWidgetItem* item = new QListWidgetItem(page->windowIcon(),
page->windowTitle());
ui_->list->addItem(item);
if (!page->IsEnabled()) {
item->setFlags(Qt::NoItemFlags);
}
// Create a scroll area containing the page
QScrollArea* area = new QScrollArea;
area->setHorizontalScrollBarPolicy(Qt::ScrollBarAlwaysOff);
area->setWidget(page);
area->setWidgetResizable(true);
area->setFrameShape(QFrame::NoFrame);
area->setMinimumWidth(page->layout()->minimumSize().width());
// Add the page to the stack
ui_->stacked_widget->addWidget(area);
// Remember where the page is
PageData data;
data.index_ = ui_->list->row(item);
data.scroll_area_ = area;
data.page_ = page;
pages_[id] = data;
}
示例7: QWizardPage
DocumentTypeSelectionPage::DocumentTypeSelectionPage(QWidget* parent) : QWizardPage(parent)
{
QVBoxLayout *vb = new QVBoxLayout;
QScrollArea *scroll = new QScrollArea;
scroll->setWidgetResizable(true);
scroll->setFocusPolicy(Qt::NoFocus);
scroll->setFrameShape(QFrame::NoFrame);
scroll->setHorizontalScrollBarPolicy(Qt::ScrollBarAlwaysOff);
m_ui = new Ui::DocumentTypeSelector;
m_ui->setupUi(scroll);
vb->addWidget(scroll);
setLayout(vb);
registerField("documentsTypeSelectionPage_minimumSize", m_ui->minimumSize);
registerField("documentsTypeSelectionPage_allLocations", m_ui->allLocations, "checked");
registerField("documentsTypeSelectionPage_location", m_ui->location, "installationPath");
registerField("documentsTypeSelectionPage_allDocuments", m_ui->allDocuments);
registerField("documentsTypeSelectionPage_audioDocuments", m_ui->audioDocuments);
registerField("documentsTypeSelectionPage_imageDocuments", m_ui->imageDocuments);
registerField("documentsTypeSelectionPage_textDocuments", m_ui->textDocuments);
registerField("documentsTypeSelectionPage_videoDocuments", m_ui->videoDocuments);
connect(m_ui->allDocuments, SIGNAL(clicked(bool)), this, SLOT(alltypes(bool)));
connect(m_ui->allDocuments, SIGNAL(clicked()), this, SIGNAL(completeChanged()));
connect(m_ui->audioDocuments, SIGNAL(clicked()), this, SIGNAL(completeChanged()));
connect(m_ui->imageDocuments, SIGNAL(clicked()), this, SIGNAL(completeChanged()));
connect(m_ui->textDocuments, SIGNAL(clicked()), this, SIGNAL(completeChanged()));
connect(m_ui->videoDocuments, SIGNAL(clicked()), this, SIGNAL(completeChanged()));
}
示例8: QWidget
MusicWebDJRadioCategoryWidget::MusicWebDJRadioCategoryWidget(QWidget *parent)
: QWidget(parent)
{
QHBoxLayout *layout = new QHBoxLayout(this);
layout->setSpacing(0);
layout->setContentsMargins(0, 0, 0, 0);
setLayout(layout);
QWidget *mainWindow = new QWidget(this);
QScrollArea *scrollArea = new QScrollArea(this);
scrollArea->verticalScrollBar()->setStyleSheet(MusicUIObject::MScrollBarStyle01);
scrollArea->setWidgetResizable(true);
scrollArea->setFrameShape(QFrame::NoFrame);
scrollArea->setAlignment(Qt::AlignLeft);
scrollArea->setWidget(mainWindow);
layout->addWidget(scrollArea);
m_gridLayout = new QGridLayout(mainWindow);
m_gridLayout->setVerticalSpacing(35);
mainWindow->setLayout(m_gridLayout);
m_categoryThread = new MusicDJRadioCategoryThread(this);
connect(m_categoryThread, SIGNAL(downLoadDataChanged(QString)), SLOT(createCategoryItems()));
}
示例9: AddPage
void SettingsDialog::AddPage(Page id, SettingsPage* page) {
// Create the list item
QListWidgetItem* item = new QListWidgetItem(page->windowIcon(),
page->windowTitle());
ui_->list->addItem(item);
if (!page->IsEnabled()) {
item->setFlags(Qt::NoItemFlags);
}
// Create a scroll area containing the page
QScrollArea* area = new QScrollArea;
area->setHorizontalScrollBarPolicy(Qt::ScrollBarAlwaysOff);
area->setWidget(page);
area->setWidgetResizable(true);
area->setFrameShape(QFrame::NoFrame);
area->setMinimumWidth(page->layout()->minimumSize().width());
// Add the page to the stack
ui_->stacked_widget->addWidget(area);
// Remember where the page is
PageData data;
data.index_ = ui_->list->row(item);
data.scroll_area_ = area;
data.page_ = page;
pages_[id] = data;
}
示例10: createPlaylistItem
void MusicPlaylistFoundWidget::createPlaylistItem(const MusicResultsItem &item)
{
if(!m_firstInit)
{
delete m_statusLabel;
m_statusLabel = nullptr;
m_container->removeWidget(m_mainWindow);
QScrollArea *scrollArea = new QScrollArea(this);
scrollArea->setStyleSheet(MusicUIObject::MScrollBarStyle01);
scrollArea->setWidgetResizable(true);
scrollArea->setFrameShape(QFrame::NoFrame);
scrollArea->setAlignment(Qt::AlignLeft);
scrollArea->setWidget(m_mainWindow);
m_container->addWidget(scrollArea);
m_firstInit = true;
QHBoxLayout *mainlayout = MStatic_cast(QHBoxLayout*, m_mainWindow->layout());
QWidget *containTopWidget = new QWidget(m_mainWindow);
QHBoxLayout *containTopLayout = new QHBoxLayout(containTopWidget);
containTopLayout->setContentsMargins(30, 0, 30, 0);
m_categoryButton = new MusicPlaylistFoundCategoryPopWidget(m_mainWindow);
m_categoryButton->setCategory(m_downloadThread->getQueryServer(), this);
containTopLayout->addWidget(m_categoryButton);
containTopLayout->addStretch(1);
foreach(const QString &data, QStringList() << tr("Recommend") << tr("Top") << tr("Hot") << tr("New"))
{
QLabel *l = new QLabel(data, containTopWidget);
l->setStyleSheet(QString("QLabel::hover{%1}").arg(MusicUIObject::MColorStyle08));
QFrame *hline = new QFrame(containTopWidget);
hline->setFrameShape(QFrame::VLine);
hline->setStyleSheet(MusicUIObject::MColorStyle06);
containTopLayout->addWidget(l);
containTopLayout->addWidget(hline);
}
containTopWidget->setLayout(containTopLayout);
QFrame *line = new QFrame(m_mainWindow);
line->setFrameShape(QFrame::HLine);
line->setStyleSheet(MusicUIObject::MColorStyle06);
QWidget *containWidget = new QWidget(m_mainWindow);
m_gridLayout = new QGridLayout(containWidget);
m_gridLayout->setVerticalSpacing(35);
containWidget->setLayout(m_gridLayout);
mainlayout->addWidget(containTopWidget);
mainlayout->addWidget(line);
mainlayout->addWidget(containWidget);
m_pagingWidgetObject = new MusicPagingWidgetObject(m_mainWindow);
connect(m_pagingWidgetObject, SIGNAL(mapped(int)), SLOT(buttonClicked(int)));
int total = ceil(m_downloadThread->getPageTotal()*1.0/m_downloadThread->getPageSize());
mainlayout->addWidget(m_pagingWidgetObject->createPagingWidget(m_mainWindow, total));
mainlayout->addStretch(1);
}
示例11: setupLayout
//-----------------------------------------------------------------------------
// Function: AddressSpaceEditor::setupLayout()
//-----------------------------------------------------------------------------
void AddressSpaceEditor::setupLayout()
{
QScrollArea* scrollArea = new QScrollArea(this);
scrollArea->setWidgetResizable(true);
scrollArea->setFrameShape(QFrame::NoFrame);
QVBoxLayout* scrollLayout = new QVBoxLayout(this);
scrollLayout->addWidget(scrollArea);
scrollLayout->setContentsMargins(0, 0, 0, 0);
QWidget* topWidget = new QWidget(scrollArea);
topWidget->setSizePolicy(QSizePolicy::Expanding, QSizePolicy::Expanding);
QVBoxLayout* topLayout = new QVBoxLayout(topWidget);
QHBoxLayout* nameAndGeneralLayout = new QHBoxLayout();
nameAndGeneralLayout->addWidget(&nameEditor_, 0, Qt::AlignTop);
nameAndGeneralLayout->addWidget(&generalEditor_);
topLayout->addLayout(nameAndGeneralLayout);
topLayout->addWidget(&segmentsEditor_, 1);
topLayout->setContentsMargins(0, 0, 0, 0);
QWidget* bottomWidget = new QWidget(scrollArea);
bottomWidget->setSizePolicy(QSizePolicy::Expanding, QSizePolicy::Expanding);
QVBoxLayout* bottomLayout = new QVBoxLayout(bottomWidget);
bottomLayout->addWidget(&localMemMapEditor_);
bottomLayout->setContentsMargins(0, 0, 0, 0);
QSplitter* verticalSplitter = new QSplitter(Qt::Vertical, scrollArea);
verticalSplitter->setSizePolicy(QSizePolicy::Expanding, QSizePolicy::Expanding);
verticalSplitter->addWidget(topWidget);
verticalSplitter->addWidget(bottomWidget);
verticalSplitter->setStretchFactor(1, 1);
QSplitterHandle* handle = verticalSplitter->handle(1);
QVBoxLayout* handleLayout = new QVBoxLayout(handle);
handleLayout->setSpacing(0);
handleLayout->setMargin(0);
QFrame* line = new QFrame(handle);
line->setLineWidth(2);
line->setMidLineWidth(2);
line->setFrameShape(QFrame::HLine);
line->setFrameShadow(QFrame::Sunken);
handleLayout->addWidget(line);
verticalSplitter->setHandleWidth(10);
scrollArea->setWidget(verticalSplitter);
}
示例12: on_pbPrepare_clicked
void DenoisingWidget::on_pbPrepare_clicked()
{
// prepare widget
cleanWidget();
QLayout *layout;
if (Constants::showThresholdsWidgetSeparately) {
QScrollArea* scrollArea = new QScrollArea();
scrollArea->setBackgroundRole(QPalette::Window);
scrollArea->setFrameShadow(QFrame::Plain);
scrollArea->setFrameShape(QFrame::NoFrame);
scrollArea->setWidgetResizable(true);
QWidget* wdg = new QWidget();
wdg->setSizePolicy(QSizePolicy::MinimumExpanding, QSizePolicy::MinimumExpanding);
wdg->setLayout(new QVBoxLayout(wdg));
scrollArea->setWidget(wdg);
scrollArea->show();
layout = wdg->layout();
} else {
if (!ui->scrollAreaWidgetContents->layout()) {
ui->scrollAreaWidgetContents->setLayout(new QVBoxLayout());
}
layout = ui->scrollAreaWidgetContents->layout();
}
// prepare signal (wavelet transform)
m_denoisingManager->setSignal(*m_noisedAudioSignal.data());
m_denoisingManager->prepareToDenoising(ui->cbWaveletType->currentText(), ui->sbLevel->value());
PlotManager::plot(ui->inputTransformedSignalWidget, m_denoisingManager->transformedSignal());
auto decomposition = m_denoisingManager->transformedDecomposition();
m_itemsCount = decomposition.size();
// initialize thresholds widgets
for (auto item : decomposition) {
auto wdg = new ThresholdsWidget(this);
m_widgets.push_back(wdg);
wdg->setSignalSource(item);
layout->addWidget(wdg);
}
Q_ASSERT(m_itemsCount == m_widgets.size());
}
示例13: QWidget
QWidget *TilesetItemBox::makeCategory(const QString &categoryItem)
{
QTabWidget *TileSetsCategories = ui->TileSetsCategories;
QWidget *catWid;
QWidget *scrollWid;
QGridLayout *catLayout;
QLabel *grpLabel;
QComboBox *tilesetGroup;
QSpacerItem *spItem;
QScrollArea *TileSets;
FlowLayout *theLayOut;
catWid = new QWidget();
scrollWid = new QWidget();
catLayout = new QGridLayout(catWid);
catLayout->setSpacing(0);
catLayout->setContentsMargins(0, 0, 0, 0);
grpLabel = new QLabel(catWid);
grpLabel->setText(tr("Group:"));
catLayout->addWidget(grpLabel, 0, 0, 1, 1);
tilesetGroup = new QComboBox(catWid);
catLayout->addWidget(tilesetGroup, 0, 1, 1, 1);
tilesetGroup->setInsertPolicy(QComboBox::InsertAlphabetically);
spItem = new QSpacerItem(1283, 20, QSizePolicy::Expanding, QSizePolicy::Minimum);
catLayout->addItem(spItem, 0, 2, 1, 1);
TileSets = new QScrollArea(catWid);
TileSets->setWidget(scrollWid);
TileSets->setWidgetResizable(true);
TileSets->setFrameShape(QFrame::StyledPanel);
TileSets->setFrameShadow(QFrame::Raised);
TileSets->setHorizontalScrollBarPolicy(Qt::ScrollBarAsNeeded);
TileSets->setVerticalScrollBarPolicy(Qt::ScrollBarAsNeeded);
theLayOut = new FlowLayout(scrollWid);
theLayOut->setSizeConstraint(QLayout::SetNoConstraint);
catLayout->addWidget(TileSets, 1, 0, 1, 3);
TileSetsCategories->addTab(catWid, QString());
TileSetsCategories->setTabText(TileSetsCategories->indexOf(catWid), categoryItem);
return catWid;
}
示例14: QTransferFunctionEditor
QTransferFunctionEditorByValues::QTransferFunctionEditorByValues(QWidget *parent)
: QTransferFunctionEditor(parent)
{
setupUi(this);
// Creem una scroll area per si hi ha molts intervals (no es pot crear des del Qt Designer)
QScrollArea *scrollArea = new QScrollArea(this);
qobject_cast<QBoxLayout*>(this->layout())->insertWidget(1, scrollArea);
m_intervalEditorsWidget = new QWidget(scrollArea);
QBoxLayout *layout = new QVBoxLayout(m_intervalEditorsWidget);
m_intervalEditorsLayout = new QVBoxLayout();
layout->addLayout(m_intervalEditorsLayout);
layout->addStretch();
layout->setMargin(0);
scrollArea->setWidget(m_intervalEditorsWidget);
scrollArea->setWidgetResizable(true);
scrollArea->setFrameShape(QFrame::NoFrame);
// Creem el primer interval
QTransferFunctionIntervalEditor *first = new QTransferFunctionIntervalEditor(m_intervalEditorsWidget);
first->setIsFirst(true);
first->setIsLast(true);
first->setObjectName("interval0");
m_intervalEditorsLayout->addWidget(first);
connect(first, SIGNAL(startChanged(int)), SLOT(markAsChanged()));
connect(first, SIGNAL(endChanged(int)), SLOT(markAsChanged()));
connect(first, SIGNAL(colorChanged(const QColor&)), SLOT(markAsChanged()));
// Mida mínima de la scroll area
QStyle *style = scrollArea->style();
int scrollBarWidth = style->pixelMetric(QStyle::PM_ScrollBarExtent);
scrollArea->setMinimumWidth(first->minimumSizeHint().width() + scrollBarWidth);
m_numberOfIntervals = 1;
m_changed = true;
connect(m_addPushButton, SIGNAL(clicked()), SLOT(addInterval()));
connect(m_removePushButton, SIGNAL(clicked()), SLOT(removeInterval()));
connect(m_nameLineEdit, SIGNAL(textChanged(const QString&)), SLOT(markAsChanged()));
}
示例15: QLabel
KSaneDeviceDialog::KSaneDeviceDialog(QWidget *parent)
: KDialog(parent)
{
setButtons(KDialog::User1 | KDialog::Ok | KDialog::Cancel);
setButtonText(User1, i18n("Reload devices list"));
m_btnGroup = new QButtonGroup(this);
m_btnBox = new QGroupBox;
QVBoxLayout *layout = new QVBoxLayout;
m_btnContainer = new QWidget;
m_btnLayout = new QVBoxLayout(m_btnContainer);
QScrollArea *area = new QScrollArea;
m_btnBox->setLayout(layout);
QLabel *explanation =
new QLabel(i18n("<html>The SANE (Scanner Access Now Easy) system could not find any device.<br>"
"Check that the scanner is plugged in and turned on<br>"
"or check your systems scanner setup.<br>"
"For details about SANE see the "
"<a href='http://www.sane-project.org/'>SANE homepage</a>.</html>"));
explanation->setOpenExternalLinks(true);
int l,t,r,b;
layout->getContentsMargins(&l, &t, &r, &b);
explanation->setContentsMargins(l, t, r, b);
layout->addWidget(explanation);
m_btnBox->adjustSize(); // make sure to see the complete explanation text
layout->addWidget(area);
layout->setContentsMargins(0,0,0,0);
area->setWidgetResizable(true);
area->setFrameShape(QFrame::NoFrame);
area->setWidget(m_btnContainer);
setMainWidget(m_btnBox);
setMinimumHeight(200);
m_findDevThread = FindSaneDevicesThread::getInstance();
connect(m_findDevThread, SIGNAL(finished()), this, SLOT(updateDevicesList()));
connect(this, SIGNAL(user1Clicked()), this, SLOT(reloadDevicesList()));
reloadDevicesList();
}