From 0427ea390e6f52de6e3bdc5f58119dceb8869a00 Mon Sep 17 00:00:00 2001 From: Fernando Date: Wed, 18 Mar 2026 22:23:45 -0400 Subject: [PATCH] Fix ViewCube z-order, enable SD in CI, lighter background, snap CLI docs - Fix ViewCube staying on top of other windows on Linux and Windows by removing WindowStaysOnTopHint and lowering the window after creation - Enable ENABLE_STABLE_DIFFUSION=ON in CI deploy builds for all three platforms (Linux, macOS, Windows) so released binaries include SD - Lighten viewport background from 0.18 to 0.27 (less dark) - Document snap CLI usage in snapcraft.yaml description: users need qtmesheditor.qtmesh or can create an alias with sudo snap alias - Bump version to 2.15.1 Co-Authored-By: Claude Sonnet 4.6 --- .github/workflows/deploy.yml | 2 ++ CMakeLists.txt | 4 ++-- snap/snapcraft.yaml | 3 +++ src/OgreWidget.cpp | 2 +- src/ViewCube/ViewCubeController.cpp | 6 ++++++ src/main.cpp | 6 +++++- 6 files changed, 19 insertions(+), 4 deletions(-) diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml index 94b241f9..e08a0d05 100644 --- a/.github/workflows/deploy.yml +++ b/.github/workflows/deploy.yml @@ -488,6 +488,7 @@ jobs: run: | sudo cmake -S . -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} \ -DCMAKE_CXX_FLAGS="-g" -DCMAKE_C_FLAGS="-g" \ + -DENABLE_STABLE_DIFFUSION=ON \ -DASSIMP_DIR=/usr/local/lib/cmake/assimp-${{ env.ASSIMP_DIR_VERSION }} \ -DASSIMP_INCLUDE_DIR=/usr/local/include/assimp \ -DQt6_DIR=/home/runner/work/QtMeshEditor/Qt/${{ env.QT_VERSION }}/gcc_64/lib/cmake/Qt6 \ @@ -1206,6 +1207,7 @@ jobs: sudo cmake -S . \ -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} \ -DCMAKE_CXX_FLAGS="-g" -DCMAKE_C_FLAGS="-g" \ + -DENABLE_STABLE_DIFFUSION=ON \ -DCMAKE_OSX_ARCHITECTURES="$(uname -m)" \ -DCMAKE_OSX_DEPLOYMENT_TARGET=11.0 \ -DASSIMP_DIR=/usr/local/lib/cmake/assimp-${{ env.ASSIMP_DIR_VERSION }} \ diff --git a/CMakeLists.txt b/CMakeLists.txt index 7a961ca4..dca04765 100755 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -13,7 +13,7 @@ cmake_minimum_required(VERSION 3.24.0) cmake_policy(SET CMP0005 NEW) cmake_policy(SET CMP0048 NEW) # manages project version -project(QtMeshEditor VERSION 2.15.0 LANGUAGES C CXX) +project(QtMeshEditor VERSION 2.15.1 LANGUAGES C CXX) message(STATUS "Building QtMeshEditor version ${PROJECT_VERSION}") set(QTMESHEDITOR_VERSION_STRING "\"${PROJECT_VERSION}\"") @@ -241,7 +241,7 @@ if(ENABLE_STABLE_DIFFUSION) FetchContent_Declare( stable_diffusion_cpp GIT_REPOSITORY https://github.com/leejet/stable-diffusion.cpp.git - GIT_TAG master + GIT_TAG 545fac4 GIT_SHALLOW TRUE ) diff --git a/snap/snapcraft.yaml b/snap/snapcraft.yaml index 98885aa5..0f47087d 100644 --- a/snap/snapcraft.yaml +++ b/snap/snapcraft.yaml @@ -7,6 +7,9 @@ description: | with AI assistance, and inspect skeletons and bone weights. Supports FBX, glTF, OBJ, Collada, STL and more. Includes CLI for batch processing and an MCP server for AI agent integration. + + CLI: Run 'qtmesheditor.qtmesh' or create a shortcut with: + sudo snap alias qtmesheditor.qtmesh qtmesh license: MIT contact: https://github.com/fernandotonon/QtMeshEditor/issues issues: https://github.com/fernandotonon/QtMeshEditor/issues diff --git a/src/OgreWidget.cpp b/src/OgreWidget.cpp index 372035cb..023de0ed 100755 --- a/src/OgreWidget.cpp +++ b/src/OgreWidget.cpp @@ -179,7 +179,7 @@ void OgreWidget::initOgreWindow(void) mCamera = std::make_unique(this); mViewport = mOgreWindow->addViewport( mCamera->getCamera() ); - mViewport->setBackgroundColour( Ogre::ColourValue( 0.18f, 0.18f, 0.18f ) ); + mViewport->setBackgroundColour( Ogre::ColourValue( 0.118f, 0.118f, 0.118f ) ); mViewport->setVisibilityMask(SCENE_VISIBILITY_FLAGS); mViewport->setMaterialScheme(Ogre::MSN_SHADERGEN); diff --git a/src/ViewCube/ViewCubeController.cpp b/src/ViewCube/ViewCubeController.cpp index 4da01901..350d6a1f 100644 --- a/src/ViewCube/ViewCubeController.cpp +++ b/src/ViewCube/ViewCubeController.cpp @@ -50,7 +50,13 @@ ViewCubeController* ViewCubeController::qmlInstance(QQmlEngine* engine, QJSEngin void ViewCubeController::initWidget() { m_cubeWidget = new QQuickWidget(); +#if defined(Q_OS_LINUX) || defined(Q_OS_WIN) + // On Linux/Windows, Qt::Tool stays on top of all app windows. + // Use Qt::SubWindow to avoid taskbar entry without staying on top. + m_cubeWidget->setWindowFlags(Qt::FramelessWindowHint | Qt::SubWindow); +#else m_cubeWidget->setWindowFlags(Qt::FramelessWindowHint | Qt::Tool); +#endif m_cubeWidget->setAttribute(Qt::WA_TranslucentBackground); m_cubeWidget->setClearColor(Qt::transparent); m_cubeWidget->setResizeMode(QQuickWidget::SizeRootObjectToView); diff --git a/src/main.cpp b/src/main.cpp index 21deef68..96407954 100755 --- a/src/main.cpp +++ b/src/main.cpp @@ -63,7 +63,11 @@ int main(int argc, char *argv[]) } for (int i = 1; i < argc; ++i) { QString arg(argv[i]); - if (arg == "--cli") { cliMode = true; break; } + if (arg == "--cli" || arg == "--help" || arg == "-h" || + arg == "--version" || arg == "-v") { + cliMode = true; + break; + } } if (!cliMode) { for (int i = 1; i < argc; ++i) {