Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Qt6 Support #7339

Open
wants to merge 24 commits into
base: master
Choose a base branch
from
Open

Add Qt6 Support #7339

wants to merge 24 commits into from

Conversation

tresf
Copy link
Member

@tresf tresf commented Jun 22, 2024

Resolves #6614.

@JohannesLorenz JohannesLorenz added this to the 1.3 milestone Aug 4, 2024
@messmerd
Copy link
Member

I successfully built LMMS with Qt 6.8.0 on Linux without the Core5Compat module.

When compiling, there were a number of deprecation warnings unrelated to that change that we should probably address in this PR.

@tresf tresf mentioned this pull request Dec 5, 2024
1 task
@tresf
Copy link
Member Author

tresf commented Feb 9, 2025

When compiling, there were a number of deprecation warnings unrelated to that change that we should probably address in this PR.

I'm wondering if we should put our efforts into fixing merge conflicts with the qt6 branch and getting it merged before the codebase diverts further? I also believe that we should have at least one automated build to ensure new features added don't cause compilation errors for future qt6 efforts.

@messmerd
Copy link
Member

messmerd commented Feb 9, 2025

@tresf I'd be fine with that.

Maybe Windows MSVC could be our Qt 6 build in the CI since it wouldn't be hard to update the dependency to Qt 6, and the MinGW build is still available in case any issues arise with it. We could do it in this PR after fixing the merge conflicts.

tresf and others added 14 commits February 18, 2025 16:13
- Fix linking issues with Qt Framework files
- Fix qmake detection
Fix implicit conversion from int when using QString.arg(...)
* Adds win32EventFilter a wrapper for nativeEventFilter on Windows
* win32EventFilter is currently used to intercept top-level Window events (currently, to avoid VSTs setting transparency of the parent application)
QComboBox activated() replaced with textActivated() since Qt 5.14
* enabled VST support for Qt 6 builds
* Note : Embedding on QT6 will be buggy on linux as a result of using qt embedding, which unfortunately is a qt bug which hasn't been resolved.
* Added lines in between bars
* Changed bar lines to follow snap size
* Changed default zoom and quantization value
* Added constants for line widths
* Added QSS configuration for new grid line colors
* Tied line widths to QSS properties
* Changed default quantization to 1/4
* Removed clear() from destructor model
* Removed destructor in ComboBoxModel.h
* Changed member set/get functions to pass by value
* Updated signal connection with newer syntax
* ensured mouse event != nullptr before deref

* separation of concerns: AFP WaveView updateCursor

extract check to pointerCloseToStartEndOrLoop()

* marked some function parameters as const
@@ -212,7 +212,7 @@ TimePos AutomationClip::timeMapLength() const
if (m_timeMap.isEmpty()) { return one_bar; }

timeMap::const_iterator it = m_timeMap.end();
auto last_tick = static_cast<tick_t>(POS(it - 1));
auto last_tick = static_cast<tick_t>(POS(std::prev(it)));
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hmm... are any of these changes Qt related?

if( it+1 == m_clip->getTimeMap().end() )
const auto nit = std::next(it);

if( nit == m_clip->getTimeMap().end() )
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same goes for these, are these Qt related?

@tresf
Copy link
Member Author

tresf commented Feb 18, 2025

@tresf I'd be fine with that.

Maybe Windows MSVC could be our Qt 6 build in the CI since it wouldn't be hard to update the dependency to Qt 6, and the MinGW build is still available in case any issues arise with it. We could do it in this PR after fixing the merge conflicts.

Merge conflicts fixed. Some touched lines don't appear to be related to this PR I've started a conversation thread on these files, please mark as resolved if they're warranted.

The history is a bit weird (as most rebases are) and I made plenty of mistakes merging, but the branch should be in pretty good shape right now. I think it's ready for a CI job to run against Qt6 as well as a few set of eyes particularly from those that have helped with the code leading up to this point.

Please push patches directly to this branch.

@tresf tresf mentioned this pull request Feb 18, 2025
26 tasks
I chose Qt 6.5 because it's the last Qt LTS release with declared
support for Visual Studio 2019. Once we upgrade to Visual Studio 2022,
we could upgrade Qt as well.
Also fixes two memory leaks in MidiWinMM
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add Qt 6 support
7 participants