Commit 8ca29cdd authored by Jean-Baptiste Mardelle's avatar Jean-Baptiste Mardelle
Browse files

Improve timeline AppImage font

parent 9c3e1531
Pipeline #17353 passed with stage
in 17 minutes and 47 seconds
......@@ -222,14 +222,8 @@ Rectangle {
background: Rectangle {
color: trackLed.bgColor
}
FontMetrics {
id: textMetricsLed
font: miniFont
}
width: (Math.ceil(textMetricsLed.averageCharacterWidth * trackLed.text.length * 1.2))
width: fontMetrics.boundingRect("M").width * trackLed.text.length
y: 1
leftPadding:0
rightPadding:0
verticalAlignment: Text.AlignVCenter
horizontalAlignment: Text.AlignHCenter
MouseArea {
......
......@@ -164,7 +164,10 @@ void TimelineWidget::setModel(const std::shared_ptr<TimelineItemModel> &model, M
rootContext()->setContextProperty("audiorec", pCore->getAudioDevice());
rootContext()->setContextProperty("guidesModel", pCore->projectManager()->current()->getGuideModel().get());
rootContext()->setContextProperty("clipboard", new ClipboardProxy(this));
rootContext()->setContextProperty("miniFont", QFontDatabase::systemFont(QFontDatabase::SmallestReadableFont));
QFont ft = QFontDatabase::systemFont(QFontDatabase::GeneralFont);
ft.setPixelSize(QFontDatabase::systemFont(QFontDatabase::SmallestReadableFont).pixelSize());
setFont(ft);
rootContext()->setContextProperty("miniFont", font());
const QStringList effs = sortedItems(KdenliveSettings::favorite_effects(), false).values();
const QStringList trans = sortedItems(KdenliveSettings::favorite_transitions(), true).values();
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment