Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 13 additions & 7 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -120,14 +120,14 @@ jobs:
fail-fast: false
matrix:
qt:
- version: 6.6.0
- version: 6.7.3

env:
- name: linux
os: ubuntu-latest
ninja_platform: linux
qt_platform: linux
qt_arch: gcc_64
qt_arch: linux_gcc_64
openssl_arch: linux-x86_64
ld_library_arch: linux-x86-64
cmake_flags: "-DGENERATE_APPDATA=ON -DCMAKE_INSTALL_PREFIX=/usr -DENABLE_UPDATE_OVER_GUI=OFF -DUSE_SSH=ON"
Expand Down Expand Up @@ -186,6 +186,7 @@ jobs:
sudo apt-get update
sudo apt-get -y install libssh2-1
sudo apt-get -y install libssh2-1-dev
sudo apt-get -y install libcups2-dev

- name: Install Qt
uses: jurplel/install-qt-action@v4.3.0
Expand Down Expand Up @@ -312,7 +313,10 @@ jobs:
mkdir -p AppDir
DESTDIR=AppDir ninja install

export QTDIR=$RUNNER_WORKSPACE/Qt/${{ matrix.qt.version }}/${{ matrix.env.qt_arch }}
# install-qt-action exports QT_ROOT_DIR to the actual install dir.
# aqt downloads the "linux_gcc_64" package but extracts it to "gcc_64",
# so the arch id and the on-disk dir name differ; prefer QT_ROOT_DIR.
export QTDIR=${QT_ROOT_DIR:-$RUNNER_WORKSPACE/Qt/${{ matrix.qt.version }}/${{ matrix.env.qt_arch }}}
export QT_ROOT_DIR=$QTDIR

rm -rf ./AppDir/usr/include/
Expand Down Expand Up @@ -382,14 +386,15 @@ jobs:
echo "No Flatpak or AppImage assets to upload."
exit 1
fi
if ! gh release view development >/dev/null 2>&1; then
if ! gh release view development --repo "${{ github.repository }}" >/dev/null 2>&1; then
gh release create development \
--repo "${{ github.repository }}" \
--prerelease \
--title "Latest Build (Development)" \
--target "${{ github.sha }}" \
"${files[@]}"
else
gh release upload development "${files[@]}" --clobber
gh release upload development "${files[@]}" --repo "${{ github.repository }}" --clobber
fi

- name: Update GitHub release (version tag)
Expand All @@ -407,13 +412,14 @@ jobs:
echo "No Flatpak or AppImage assets to upload."
exit 1
fi
if ! gh release view "$TAG" >/dev/null 2>&1; then
if ! gh release view "$TAG" --repo "${{ github.repository }}" >/dev/null 2>&1; then
gh release create "$TAG" \
--repo "${{ github.repository }}" \
--title "Gittyup Release ${{ steps.version.outputs.VERSION }}" \
--target "${{ github.sha }}" \
"${files[@]}"
else
gh release upload "$TAG" "${files[@]}" --clobber
gh release upload "$TAG" "${files[@]}" --repo "${{ github.repository }}" --clobber
fi

# needed otherwise the docs folder is not available
Expand Down
6 changes: 2 additions & 4 deletions pack/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ if(APPLE)
set(QT_PLUGINS ${QT_PLUGINS} QCocoaIntegrationPlugin QMacStylePlugin)
elseif(GITTYUP_PACK_WIN64)
set(QT_PLUGINS ${QT_PLUGINS} QWindowsIntegrationPlugin
QWindowsVistaStylePlugin)
QModernWindowsStylePlugin)
else()
set(QT_PLUGINS ${QT_PLUGINS} QXcbIntegrationPlugin
QComposePlatformInputContextPlugin)
Expand All @@ -39,9 +39,7 @@ if(FLATPAK)
elseif(NOT USE_SYSTEM_QT)
foreach(QT_PLUGIN ${QT_PLUGINS})
if(NOT TARGET Qt6::${QT_PLUGIN})
if(UNIX OR APPLE)
continue()
endif()
continue()
endif()

get_target_property(PLUGIN Qt6::${QT_PLUGIN} LOCATION_${CMAKE_BUILD_TYPE})
Expand Down
13 changes: 13 additions & 0 deletions src/app/Application.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@
#include <QNetworkProxyFactory>
#include <QNetworkReply>
#include <QOperatingSystemVersion>
#include <QPalette>
#include <QSettings>
#include <QStyle>
#include <QTimer>
Expand Down Expand Up @@ -162,6 +163,18 @@ Application::Application(int &argc, char **argv, bool haltOnParseError)
setStyle(mTheme->style());
setStyleSheet(mTheme->styleSheet());

#if defined(Q_OS_WIN)
// Qt normally re-polishes the application palette through the style on
// setStyle(), but the explicit base palette set above is treated as
// user-defined and is not re-polished, dropping the theme's color remaps
// (e.g. BrightText, which leaves white-on-white text on the start page).
// Polish the palette through the style ourselves so all themes render
// correctly.
QPalette palette = QApplication::palette();
style()->polish(palette);
QApplication::setPalette(palette);
#endif

#if defined(Q_OS_WIN)
// Set default font style and hinting.
QFont font = QApplication::font();
Expand Down