Implementing Multi-Functional Cursors in QCustomPlot Charts
This article extends previous implementations by enhancing cursor functionality in QCustomPlot visualizations. It introduces advanced cursor features for improved data analysis capabilities.
Cursor Functionality Overview
The enhanced cursor system supports:
Single-line cursors with drag capabilities
Independent dual-cursor pairs with constrain ...
Posted on Thu, 27 Aug 2026 16:54:17 +0000 by optikalefx
Exposing C++ Classes to QML in Qt
Thread-Safe Global Singletons with Q_GLOBAL_STATIC
Q_GLOBAL_STATIC provides a thread-safe and lazily initialized global singleton managed by Qt:
Q_GLOBAL_STATIC(Type, instanceName);
Q_GLOBAL_STATIC_WITH_ARGS(Type, instanceName, Args...);
Type: The class type of the singleton.
instanceName: The name of the static instance varible.
Args...: Op ...
Posted on Thu, 27 Aug 2026 16:43:51 +0000 by Shadeless
Essential Qt Widget Properties
EnabledControls the interactive state of a widget. A disabled widget does not process user inputs.isEnabled(): Retrieves the current active state of the widget.setEnabled(bool): Toggles the widget's availability. Pass true to activate, false to deactivate.CustomWidget::CustomWidget(QWidget *parent)
: QWidget(parent), ui(new Ui::CustomWidget ...
Posted on Thu, 27 Aug 2026 16:38:10 +0000 by trauch
Comparative Analysis of QMap and QHash in Qt
QMap Deep Dive
QMap is a sorted associative container storing key-value pairs in ascending key order.
The template class is defined as QMap<K, T>.
Elements are sorted based on keys.
Key type must overload operator<.
QMap Usage Example
#include <QtCore>
int main(int argc, char *argv[]) {
QCoreApplication app(argc, argv);
...
Posted on Wed, 26 Aug 2026 16:52:43 +0000 by wrapper
Building a Searchable Autocomplete Box in Qt with Preview Dropdown
A search widget featuring real-time filtering and a preview dropdown can be implemented by combining a model/view architecture with custom proxy filtering. Below is a breakdown of the approach to create a control that accepts a data set, filters rows on the fly as the user types, and displays matching results in a popup list with hover highligh ...
Posted on Tue, 25 Aug 2026 16:29:15 +0000 by GravityFX
Detecting Physical Monitor Count in Qt Applications
The standard Qt method counts logical desktops, which differs from physical monitor count in two primary scenarios:
Remote Desktop Sessions (Windows): When a user connects via Remote Desktop Protocol (RDP), the session may report zero active screens depending on the connection state, or the screen count might reflect the client's configuration ...
Posted on Sun, 23 Aug 2026 16:41:43 +0000 by billabong0202
Real-Time CPU Temperature Monitoring with QCustomPlot in Qt
When developing system monitoring applications, visualizing hardware metrics like CPU temperature is crucial. While specialized tools like CPU-Z or HWMonitor use low-level drivers for hardware access, Qt provides a more accessible approach through system APIs and libraries like QCustomPlot for data visualization. This article demonstrates how t ...
Posted on Sun, 23 Aug 2026 16:05:06 +0000 by Gregg
Dynamic Button Styling in Qt with QSS
In many application development scenarios, there's a common requirement to change a button's appearance based on different application states or logic.
Approach 1: Directly Setting Stylesheets in Code
The most straightforward method is to call setStyleSheet() whenever the button's state changes. This approach is simple but can lead to code dupl ...
Posted on Wed, 19 Aug 2026 16:06:51 +0000 by BluePhoenixNC
Building an Intelligent Facial Recognition Temperature Screening System with Orange Pi AIpro
In response to increasing public health demands, especially following global pandemics, healthcare facilities require advanced screening solutions. Traditional manual temperature checks are inefficient and pose cross-contamination risks. This project presents a comprehensive automated system using Orange Pi AIpro for facial recognition and infr ...
Posted on Fri, 14 Aug 2026 16:39:38 +0000 by wolfan
Creating Qt Threads Through Composition Rather Than Inheritance
Legacy Approaches Versus Modern Techniques
Understanding Historical Context
In early object-oriented programming practices, software engineers commonly extended system functionality through inheritance. This approach was prevalent in Qt applications where developers would subclass QThread and override the run() function to implement thread beha ...
Posted on Tue, 11 Aug 2026 16:53:14 +0000 by fotofx