eupolicy.social is one of the many independent Mastodon servers you can use to participate in the fediverse.
This Mastodon server is a friendly and respectful discussion space for people working in areas related to EU policy. When you request to create an account, please tell us something about you.

Server stats:

216
active users

#pyqt

0 posts0 participants0 posts today

I have been making progress with my color converter/creation application built with PyQt. I just added a 4 point gradient tool this morning. This application will allow you to create, convert and manage all your colors in one place.

#Linux#Python#PyQt

One way to make money online as a programmer.

Step 1: Learn Python and/or PyQt

Step 2: Develop an open source application that solves a specific problem.

Step 3: Develop plugins or extensions that extend the application functionality.

* Companies might sponsor addition features. If this happens, disregard Step 4 below.

Step 4: Sell the additional functionality as a product or service.

#python#pyqt#pyqt5

With a huge diff of +3,972 / −3,667 lines, rewriting the project tree of @novelwriter to use a model/view set from the previous approach that synced changes between the data class and the view widget's internal model didn't result in less code.

But I think it resulted in an easier to maintain code, and hopefully more stable over time. Syncing the project state between two locations is just a little error-prone, and Qt's default implementation is also a bit buggy.

#Code#Python#Qt

My latest coding project is moving the project data structure of @novelwriter from a Qt standard tree view into a custom model/view set.

The old implementation based on a QTreeWidget is a shadow copy of the project data, which needs to be kept in sync and is the most error prone part of the code.

The new model/view set holds the proper tree structure in memory and handles consistency directly in the hierarchy. But there is *so* much functionality to port over!

#Code#Python#Qt

If you use Qt from #Python (from any of its bindings like #PyQt or PySide or QtPy), read this excellent guide from @czaki on writing robust tests.

@czaki has repeatedly cleaned up the test suite for @napari, which often failed randomly in CI, and this post distills many of his learnings. I’ve found it super useful for my understanding of wtf was going on in our CI! 😂
fosstodon.org/@czaki/113146457

FosstodonGrzegorz Bokota (@czaki@fosstodon.org)I have summarized my experience in debugging of segfaults in Python test for Qt widgets here https://czaki.github.io/blog/2024/09/16/preventing-segfaults-in-test-suite-that-has-qt-tests/