diff --git a/src/jyut-dict/components/entryheaderwidget.cpp b/src/jyut-dict/components/entryheaderwidget.cpp index 614941ba..f7951260 100644 --- a/src/jyut-dict/components/entryheaderwidget.cpp +++ b/src/jyut-dict/components/entryheaderwidget.cpp @@ -9,7 +9,7 @@ EntryHeaderWidget::EntryHeaderWidget(QWidget *parent) : QWidget(parent) _wordLabel->setTextInteractionFlags(Qt::TextSelectableByMouse); _wordLabel->setWordWrap(true); _wordLabel->setStyleSheet("QLabel { font-size: 24px}"); -#if __WIN32 +#ifdef __WIN32 _wordLabel->setFont(QFont("MingLiU")); #endif diff --git a/src/jyut-dict/components/mainsplitter.cpp b/src/jyut-dict/components/mainsplitter.cpp index 933a9aa9..984ef33a 100644 --- a/src/jyut-dict/components/mainsplitter.cpp +++ b/src/jyut-dict/components/mainsplitter.cpp @@ -26,7 +26,7 @@ MainSplitter::MainSplitter(QWidget *parent) : QSplitter(parent) { \ background-color: rgb(0, 0, 0); \ }"); -#elif __WIN32__ +#elif __WIN32 setStyleSheet("QSplitter::handle \ { \ background-color: #b9b9b9; \ diff --git a/src/jyut-dict/components/maintoolbar.cpp b/src/jyut-dict/components/maintoolbar.cpp index e974ff0f..a7751287 100644 --- a/src/jyut-dict/components/maintoolbar.cpp +++ b/src/jyut-dict/components/maintoolbar.cpp @@ -23,7 +23,7 @@ MainToolBar::MainToolBar(QWidget *parent) : QToolBar(parent) setMovable(false); setFloatable(false); -#if __WIN32 +#ifdef __WIN32 setStyleSheet("QToolBar { background-color: white; }"); #endif } diff --git a/src/jyut-dict/components/searchlistview.cpp b/src/jyut-dict/components/searchlistview.cpp index ba1ae9e7..33042885 100644 --- a/src/jyut-dict/components/searchlistview.cpp +++ b/src/jyut-dict/components/searchlistview.cpp @@ -21,7 +21,7 @@ SearchListView::SearchListView(QWidget *parent) setVerticalScrollMode(QAbstractItemView::ScrollPerPixel); } -#if __WIN32 +#ifdef __WIN32 void SearchListView::wheelEvent(QWheelEvent *event) { int singleStep = verticalScrollBar()->singleStep(); diff --git a/src/jyut-dict/components/searchlistview.h b/src/jyut-dict/components/searchlistview.h index e32594e1..70b45ab1 100644 --- a/src/jyut-dict/components/searchlistview.h +++ b/src/jyut-dict/components/searchlistview.h @@ -18,7 +18,7 @@ class SearchListView : public QListView public: explicit SearchListView(QWidget *parent = nullptr); -#if __WIN32 +#ifdef __WIN32 void wheelEvent(QWheelEvent *event) override; #endif