qgis / QGIS

QGIS is a free, open source, cross platform (lin/win/mac) geographical information system (GIS)
https://qgis.org
GNU General Public License v2.0
10.65k stars 3.01k forks source link

Balloon annotations fails to adopt text formatting #57423

Open pggsn opened 6 months ago

pggsn commented 6 months ago

What is the bug or the crash?

When changing the formattin of a text annotation, the format is not adopted and set back to the default (MS Shell Dlg 2, size 8, black color).

Steps to reproduce the issue

  1. Go to the Annotations Toolbar.
  2. Select Text Annotation.
  3. Open the Annotation properties by double clicking on the ballon.
  4. Change the text formatting.
  5. Confirm with OK or Apply.
  6. See that the changed formatting is set back to the default formatting.

Versions

QGIS-Version | 3.34.6-Prizren | QGIS-Codeversion | 623828f5 -- | -- | -- | -- Qt-Version | 5.15.13 Python-Version | 3.12.3 GDAL-Version | 3.8.5 PROJ-Version | 9.4.0 EPSG-Registraturdatenbankversion | v11.004 (2024-02-24) GEOS-Version | 3.12.1-CAPI-1.18.1 SQLite-Version | 3.45.1 PDAL-Version | 2.6.3 PostgreSQL-Client-Version | 16.2 SpatiaLite-Version | 5.1.0 QWT-Version | 6.2.0 QScintilla2-Version | 2.14.1 BS-Version | Windows 10 Version 2009   |   |   |   Aktive Python-Erweiterungen alkisplugin | 2.0.55 AnotherDXF2Shape | 1.3.1 DataPlotly | 4.1.0 GroupStats | 2.2.7 loadthemall | 3.4 mapswipetool_plugin | 1.2 pluginbuilder3 | 3.2.1 pointsamplingtool | 0.5.4 ProcessX | 1.7 qfieldsync | v4.9.1 quick_map_services | 0.19.34 SemiAutomaticClassificationPlugin | 8.2.2 slyr | 7.2.1 db_manager | 0.1.20 grassprovider | 2.12.99 MetaSearch | 0.3.6 otbprovider | 2.12.99 processing | 2.12.99 QGIS-Version 3.34.6-Prizren QGIS-Codeversion [623828f5](https://github.com/qgis/QGIS/commit/623828f5) Qt-Version 5.15.13 Python-Version 3.12.3 GDAL-Version 3.8.5 PROJ-Version 9.4.0 EPSG-Registraturdatenbankversion v11.004 (2024-02-24) GEOS-Version 3.12.1-CAPI-1.18.1 SQLite-Version 3.45.1 PDAL-Version 2.6.3 PostgreSQL-Client-Version 16.2 SpatiaLite-Version 5.1.0 QWT-Version 6.2.0 QScintilla2-Version 2.14.1 BS-Version Windows 10 Version 2009 ### Supported QGIS version - [X] I'm running a supported QGIS version according to [the roadmap](https://www.qgis.org/en/site/getinvolved/development/roadmap.html#release-schedule). ### New profile - [X] I tried with a new [QGIS profile](https://docs.qgis.org/latest/en/docs/user_manual/introduction/qgis_configuration.html#working-with-user-profiles) ### Additional context _No response_
elpaso commented 6 months ago

I cannot reproduce on Linux/master.

ntrip6 commented 3 months ago

I too have run into this issue repeatedly in the past year (Windows 11 current 3.38). Perhaps related to how windows handles fonts? It seems to happen especially with Annotations that are longer than 1 line.

ntrip6 commented 1 month ago

The problem persists in 3.38.1. In recent testing the problem appears when I open a new document and paste in some text from an email (in a browser window). No ability to change the font or the font size in the resulting text. If I start typing a new text in the bubble, however, it is modifiable. So maybe the inherited font styling from the web browser is causing problems. I just tested this theory by pasting into a plain text first and then pasting into QGIS the formating is OK. So the issue seems to be inherited styles from cutting and pasting from a browser causes the Bubble annotation formatting to be unchangable on WIndows 10 and 11. Can any text formatting in the clipboard be stripped out automatically on the way into QGIS ?