mirror of
https://gitee.com/spark-store-project/spark-store
synced 2025-10-04 09:32:21 +08:00
fix:搜索框没有提示字的问题
This commit is contained in:
parent
266be7146d
commit
03b053bcc0
@ -66,6 +66,9 @@ MainWindow::MainWindow(QWidget *parent)
|
|||||||
filterAppsByKeyword(keyword);
|
filterAppsByKeyword(keyword);
|
||||||
});
|
});
|
||||||
initStyle();
|
initStyle();
|
||||||
|
|
||||||
|
// 确保搜索框内容为空,placeholder 能显示
|
||||||
|
ui->searchPlainTextEdit->clear();
|
||||||
});
|
});
|
||||||
|
|
||||||
// 启动异步任务
|
// 启动异步任务
|
||||||
@ -91,6 +94,9 @@ void MainWindow::initStyle()
|
|||||||
line-height: 1.4;
|
line-height: 1.4;
|
||||||
color: #9CA3AF;
|
color: #9CA3AF;
|
||||||
}
|
}
|
||||||
|
QPlainTextEdit[placeholderText]:empty {
|
||||||
|
color: #9CA3AF;
|
||||||
|
}
|
||||||
)");
|
)");
|
||||||
|
|
||||||
ui->searchPlainTextEdit->setVerticalScrollBarPolicy(Qt::ScrollBarAlwaysOff);
|
ui->searchPlainTextEdit->setVerticalScrollBarPolicy(Qt::ScrollBarAlwaysOff);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user