new style for sidebar titles in OSX

This commit is contained in:
Luis Ángel San Martín 2015-08-20 22:46:14 +02:00
parent 1d59ba206a
commit 97fb8fd85b
2 changed files with 12 additions and 5 deletions

View File

@ -23,9 +23,15 @@ YACReaderSideBar::YACReaderSideBar(QWidget *parent) :
readingListsView = new YACReaderReadingListsView;
selectedLibrary = new YACReaderLibraryListWidget;
librariesTitle = new YACReaderTitledToolBar(tr("LIBRARIES"));
foldersTitle = new YACReaderTitledToolBar(tr("FOLDERS"));
#ifdef Q_OS_MAC
librariesTitle = new YACReaderTitledToolBar(tr("Libraries"));
foldersTitle = new YACReaderTitledToolBar(tr("Folders"));
readingListsTitle = new YACReaderTitledToolBar(tr("Reading Lists"));
#else
librariesTitle = new YACReaderTitledToolBar(tr("LIBRARIES"));
foldersTitle = new YACReaderTitledToolBar(tr("FOLDERS"));
readingListsTitle = new YACReaderTitledToolBar(tr("READING LISTS"));
#endif
splitter = new QSplitter(this);
splitter->setOrientation(Qt::Vertical);

View File

@ -40,8 +40,9 @@ void DropShadowLabel::paintEvent(QPaintEvent *event)
QPainter painter(this);
painter.setFont(font());
//TODO find where is the '3' comming from?
#ifndef Q_OS_MAC
drawTextEffect(&painter, QPoint(contentsMargins().left(), 1));
#endif
drawText(&painter, QPoint(contentsMargins().left(), 0));
}
@ -71,8 +72,8 @@ YACReaderTitledToolBar::YACReaderTitledToolBar(const QString & title, QWidget *p
nameLabel->setText(title);
#ifdef Q_OS_MAC
QString nameLabelStyleSheet = "QLabel {padding:0 0 0 10px; margin:0px; font-size:11px; font-weight:bold;}";
nameLabel->setColor(QColor("#707E8C"));
nameLabel->setDropShadowColor(QColor("#F9FAFB"));
nameLabel->setColor(QColor("#808080"));
//nameLabel->setDropShadowColor(QColor("#F9FAFB"));
#else
QString nameLabelStyleSheet = "QLabel {padding:0 0 0 10px; margin:0px; font-size:11px; font-weight:bold;}";
nameLabel->setColor(QColor("#BDBFBF"));