Skip to content

QgsPanelWidget: deprecate widgetChanged signal and use changed instead - #67355

Open
ptitjano wants to merge 2 commits into
qgis:masterfrom
ptitjano:materialwidget-signal
Open

ptitjano wants to merge 2 commits into
qgis:masterfrom
ptitjano:materialwidget-signal

Conversation

@ptitjano

@ptitjano ptitjano commented Sep 9, 2026

Copy link
Copy Markdown
Collaborator

Description

See discussion

I've always dislike the naming of the "widgetChanged" signal -- to me this sounds more like a "emitted when the widget shown in the panel has been changed to another widget" signal, as opposed to a "the settings described by the current widget have been changed" signal. We also use just changed() for many other widget subclasses, so the added consistency would be nice...

AI tool usage

No AI Tool used

@ptitjano ptitjano self-assigned this Sep 9, 2026
@github-actions github-actions Bot added this to the 4.4.0 milestone Sep 9, 2026
@github-actions github-actions Bot added the 3D Relates to QGIS' 3D engine or rendering label Sep 9, 2026
@github-actions

github-actions Bot commented Sep 9, 2026

Copy link
Copy Markdown
Contributor

🪟 Windows Qt6 builds

Download Windows Qt6 builds of this PR for testing.
To execute locally, unzip the downloaded zip file and run bin\qgis-bin.exe in the extracted directory.
You might be prompted by Windows Defender click "Run anyway"
(Built from commit 220f50d)

🍎 MacOS Qt6 builds

Download MacOS Qt6 builds of this PR for testing.
This app is not notarized, run sudo xattr -d com.apple.quarantine /Applications/QGIS*.app to avoid the warning
(Built from commit 220f50d)

🪟 x64-windows⚠️ vcpkg failed before producing per-port logs

vcpkg returned a non-zero exit code but no port left a parseable buildtree. This usually means a portfile-execute abort (e.g. find_library REQUIRED, vcpkg_extract_source_archive download failure), or a vcpkg-internal error such as a missing tool or registry/baseline mismatch.

Look at the artifacts and the workflow log:

📑 Download full build-logs-x64-windows artifact · 🔧 Workflow run · 📌 Commit e2b3348

@nyalldawson

Copy link
Copy Markdown
Collaborator

@ptitjano would you consider adding a "changed" signal to QgsPanelWidget, and deprecating the widgetChanged signal (adding a connection from changed->widgetChanged to maintain api)?

I've always dislike the naming of the "widgetChanged" signal -- to me this sounds more like a "emitted when the widget shown in the panel has been changed to another widget" signal, as opposed to a "the settings described by the current widget have been changed" signal. We also use just changed() for many other widget subclasses, so the added consistency would be nice...

@ptitjano
ptitjano force-pushed the materialwidget-signal branch from 70efe43 to dc138cf Compare September 14, 2026 14:00
@github-actions github-actions Bot added Rasters Related to general raster layer handling (not specific data formats) Labeling Related to QGIS map labeling Print Layouts Related to QGIS Print Layouts, Atlas or Reporting frameworks Mesh Related to general mesh layer handling (not specific data formats) Vector tiles Point Clouds Annotations labels Sep 14, 2026
@ptitjano

Copy link
Copy Markdown
Collaborator Author

@ptitjano would you consider adding a "changed" signal to QgsPanelWidget, and deprecating the widgetChanged signal (adding a connection from changed->widgetChanged to maintain api)?

I've always dislike the naming of the "widgetChanged" signal -- to me this sounds more like a "emitted when the widget shown in the panel has been changed to another widget" signal, as opposed to a "the settings described by the current widget have been changed" signal. We also use just changed() for many other widget subclasses, so the added consistency would be nice...

No strong opinion regarding the naming. My only concern is that a widget which inherits from QgsPanelWidget should not introduce a new signal instead of using the base signal from QgsPanelWidget`.

I have updated the PR. QgsPanelWidget now has a changed signal and widgetChanged is deprecated.

@ptitjano ptitjano changed the title Materialwidget signal QgsPanelWidget: deprecate widgetChanged signal and use changed instead Sep 14, 2026
@ptitjano
ptitjano force-pushed the materialwidget-signal branch 9 times, most recently from e2b3348 to 65d78d5 Compare September 14, 2026 16:28
This is already defined in base class QgsPanelWidget
This is a better description of its usage. Indeed, this signal is
emitted when the settings described by the current widget have been
changed.
@ptitjano
ptitjano force-pushed the materialwidget-signal branch from 65d78d5 to 220f50d Compare September 17, 2026 10:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

3D Relates to QGIS' 3D engine or rendering Annotations Labeling Related to QGIS map labeling Mesh Related to general mesh layer handling (not specific data formats) Point Clouds Print Layouts Related to QGIS Print Layouts, Atlas or Reporting frameworks Rasters Related to general raster layer handling (not specific data formats) Vector tiles

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants