Update UI.

This commit is contained in:
iaom 2021-08-16 19:34:40 +08:00
parent f1fe0f3a78
commit a6b573205e
3 changed files with 7 additions and 2 deletions

View File

@ -167,7 +167,9 @@ void DetailArea::initUi()
this->setHorizontalScrollBarPolicy(Qt::ScrollBarAlwaysOff);
this->setVerticalScrollBarPolicy(Qt::ScrollBarAsNeeded);
this->setWidgetResizable(true);
this->setFixedSize(368, 516);
this->setFixedSize(376, 516);
// this->setStyleSheet("QScrollArea{border:2px solid red;}");
this->setContentsMargins(0,0,0,0);
m_detailWidget = new DetailWidget(this);
this->setWidget(m_detailWidget);
this->hide();
@ -330,7 +332,7 @@ void DetailWidget::paintEvent(QPaintEvent *event)
QPainter p(this);
style()->drawPrimitive(QStyle::PE_Widget, &opt, &p, this);
QRect rect = this->rect().adjusted(0, 0, -8, 0);
QRect rect = this->rect().adjusted(0, 0, 0, 0);
p.setRenderHint(QPainter::Antialiasing); // 反锯齿;
p.setBrush(opt.palette.color(QPalette::Text));
p.setOpacity(DETAIL_WIDGET_TRANSPARENT);

View File

@ -115,6 +115,7 @@ void SearchResultPage::initUi()
m_hlayout->addWidget(m_resultArea);
m_hlayout->addWidget(m_detailArea);
m_hlayout->setSpacing(0);
this->setLayout(m_hlayout);
// m_splitter->addWidget(m_resultArea);
// m_splitter->addWidget(m_detailArea);

View File

@ -39,6 +39,7 @@
#include "libsearch.h"
#include "global-settings.h"
#include "ukui-search-dbus-service.h"
#include "plugin-manager.h"
using namespace Zeeker;
@ -262,6 +263,7 @@ int main(int argc, char *argv[]) {
qDebug() << "Load translations file" << QLocale() << "failed!";
}
PluginManager::getInstance();
//set main window to the center of screen
MainWindow *w = new MainWindow;
UkuiSearchDbusServices dbusService(w);