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

QgsLayerStylingWidget::apply() always calls the apply() method of QgsLabelingWidget twice #58782

Open
2 tasks
gacarrillor opened this issue Sep 18, 2024 · 0 comments · May be fixed by #58568
Open
2 tasks

QgsLayerStylingWidget::apply() always calls the apply() method of QgsLabelingWidget twice #58782

gacarrillor opened this issue Sep 18, 2024 · 0 comments · May be fixed by #58568
Labels
Bug Either a bug report, or a bug fix. Let's hope for the latter! GUI/UX Related to QGIS application GUI or User Experience Labeling Related to QGIS map labeling Optimization I feel the need... the need for speed!

Comments

@gacarrillor
Copy link
Member

gacarrillor commented Sep 18, 2024

What is the bug or the crash?

Any widget inheriting from QgsMapLayerConfigWidget is getting its apply() method called twice.
This is specially noticeable when the Live Update mode is active.

Steps to reproduce the issue

To make this evident, go to qgslabelingwidget.cpp, apply() method and add something like:

QgsLogger::warning( QStringLiteral( "Call to labeling's apply" ) );

Use the labeling rendering properties in the panel widget and click on the Apply button, or use the Live Update mode activated. You'll see the duplicate call.

Versions

At least, QGIS master.

Supported QGIS version

  • I'm running a supported QGIS version according to the roadmap.

New profile

Additional context

I'm creating this issue for reference. It'll be fixed in an upcoming PR.

@gacarrillor gacarrillor added Optimization I feel the need... the need for speed! Labeling Related to QGIS map labeling GUI/UX Related to QGIS application GUI or User Experience Bug Either a bug report, or a bug fix. Let's hope for the latter! labels Sep 18, 2024
gacarrillor added a commit to gacarrillor/QGIS that referenced this issue Sep 18, 2024
…d of a list when docked; harmonize stacked diagram configuration with rule-based labeling; allow QgsDiagramProperties to sync to renderers and diagram layer settings, in addition to syncing to layers; when editing a subdiagram of a stacked diagram, only show widgets for diagram layer settings if the subdiagram is the first one, for the rest, hide those widgets and show a note informing users; make sure stacked diagrams handle enabled and disabled subdiagrams (i.e., don't take into account disabled subdiagrams) and add a test for it; switching from single to stacked diagram: take the single diagram definition as the first stacked diagram; fix qgis#58782 (calling twice the apply method for label rendering)
gacarrillor added a commit to gacarrillor/QGIS that referenced this issue Sep 18, 2024
…d of a list when docked; harmonize stacked diagram configuration with rule-based labeling; allow QgsDiagramProperties to sync to renderers and diagram layer settings, in addition to syncing to layers; when editing a subdiagram of a stacked diagram, only show widgets for diagram layer settings if the subdiagram is the first one, for the rest, hide those widgets and show a note informing users; make sure stacked diagrams handle enabled and disabled subdiagrams (i.e., don't take into account disabled subdiagrams) and add a test for it; switching from single to stacked diagram: take the single diagram definition as the first stacked diagram; fix qgis#58782 (calling twice the apply method for label rendering)
@gacarrillor gacarrillor linked a pull request Sep 18, 2024 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Either a bug report, or a bug fix. Let's hope for the latter! GUI/UX Related to QGIS application GUI or User Experience Labeling Related to QGIS map labeling Optimization I feel the need... the need for speed!
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant