fixed QML font settings

This commit is contained in:
Luis Ángel San Martín 2014-11-14 09:30:53 +01:00
parent eafeeff720
commit 77028f4be1
2 changed files with 17 additions and 6 deletions

View File

@ -72,6 +72,10 @@ void GridComicsView::setModel(ComicModel *model)
ctxt->setContextProperty("borderColor", "#DBDBDB"); ctxt->setContextProperty("borderColor", "#DBDBDB");
ctxt->setContextProperty("titleColor", "#121212"); ctxt->setContextProperty("titleColor", "#121212");
ctxt->setContextProperty("textColor", "#636363"); ctxt->setContextProperty("textColor", "#636363");
//fonts settings
ctxt->setContextProperty("fontSize", "11");
ctxt->setContextProperty("fontFamily", "none");
ctxt->setContextProperty("fontSpacing", "0.5");
#else #else
ctxt->setContextProperty("backgroundColor", "#2A2A2A"); ctxt->setContextProperty("backgroundColor", "#2A2A2A");
@ -82,6 +86,10 @@ void GridComicsView::setModel(ComicModel *model)
ctxt->setContextProperty("titleColor", "#E6E6E6"); ctxt->setContextProperty("titleColor", "#E6E6E6");
ctxt->setContextProperty("textColor", "#E6E6E6"); ctxt->setContextProperty("textColor", "#E6E6E6");
ctxt->setContextProperty("dropShadow",false); ctxt->setContextProperty("dropShadow",false);
//fonts settings
ctxt->setContextProperty("fontSize", "none");
ctxt->setContextProperty("fontFamily", "none");
ctxt->setContextProperty("fontSpacing", "0.5");
#endif #endif

View File

@ -166,16 +166,18 @@ Rectangle {
elide: Text.ElideRight elide: Text.ElideRight
color: titleColor color: titleColor
clip: true clip: true
font.letterSpacing: 0.5 font.letterSpacing: fontSpacing
font.pointSize: 11 font.pointSize: fontSize
font.family: fontFamily
} }
//number //number
Text { Text {
anchors {bottom: realCell.bottom; left: realCell.left; margins: 4} anchors {bottom: realCell.bottom; left: realCell.left; margins: 4}
text: number?"<b>#</b>"+number:"" text: number?"<b>#</b>"+number:""
color: textColor color: textColor
font.letterSpacing: 0.5 font.letterSpacing: fontSpacing
font.pointSize: 11 font.pointSize: fontSize
font.family: fontFamily
} }
//page icon //page icon
Image { Image {
@ -189,8 +191,9 @@ Rectangle {
anchors {bottom: realCell.bottom; right: pageImage.left; margins: 4} anchors {bottom: realCell.bottom; right: pageImage.left; margins: 4}
text: has_been_opened?current_page+"/"+num_pages:num_pages text: has_been_opened?current_page+"/"+num_pages:num_pages
color: textColor color: textColor
font.letterSpacing: 0.5 font.letterSpacing: fontSpacing
font.pointSize: 11 font.pointSize: fontSize
font.family: fontFamily
} }
//rating icon //rating icon
Image { Image {