Bug report #21471

Regression with expressions in Composer

Added by Pedro Venâncio almost 6 years ago. Updated almost 6 years ago.

Status:Closed
Priority:High
Assignee:-
Category:Map Composer/Printing
Affected QGIS version:3.4.5 Regression?:Yes
Operating System:Windows 10 Easy fix?:No
Pull Request or Patch supplied:No Resolution:
Crashes QGIS or corrupts data:No Copied to github as #:29288

Description

I updated QGIS 3.4.5, 3.6.0 and 3.7.0 today to 3.4.5-3 (code revision 8ba90fc441), 3.6.0-4 (code revision ec30c48de9) and 3.7.0-4 (code revision 34a0650177) with OSGeo4W, and the labels with expressions are not rendered as expected, when are used more than one line.

For instance,

[% CASE WHEN month($now) = 3 THEN 'March' END || ' ' || year($now) %]

renders ok

March 2019

but

[% 
    CASE WHEN month($now) = 3 THEN 'March' END || ' ' || year($now) 
%]

renders

[% 
    CASE WHEN month($now) = 3 THEN 'March' END || ' ' || year($now) 
%]

I'm sure this is a regression, because it was working fine before today's update. Last week this was working fine.

Associated revisions

Revision daeb3d84
Added by Nyall Dawson almost 6 years ago

Fix newline characters break embedded expressions

Fixes #21471

Revision e470b6c9
Added by Nyall Dawson almost 6 years ago

Fix newline characters break embedded expressions

Fixes #21471

(cherry picked from commit daeb3d84f7d3b4a0b4e3daab4140951c637ef88a)

Revision d036a5f5
Added by Nyall Dawson almost 6 years ago

Fix newline characters break embedded expressions

Fixes #21471

(cherry picked from commit daeb3d84f7d3b4a0b4e3daab4140951c637ef88a)

History

#1 Updated by Giovanni Manghi almost 6 years ago

  • Subject changed from Problem with expressions in Composer to Regression with expressions in Composer

#2 Updated by Nyall Dawson almost 6 years ago

  • % Done changed from 0 to 100
  • Status changed from Open to Closed

#3 Updated by Pedro Venâncio almost 6 years ago

  • Status changed from Closed to Reopened

Hi Nyall,

Thank you very much for the fix!

But this also needs to be backported to release-3_4 (LTR).

Thanks!

#4 Updated by Giovanni Manghi almost 6 years ago

Hi Pedro, I think we can keep this closed as the bug is fixed, for heads up about backporting I think is better to leave messages in the PR on GitHub.

#5 Updated by Nyall Dawson almost 6 years ago

  • Status changed from Reopened to Closed

There's already a 3.4 backported pr, it just hasn't been merged yet

Also available in: Atom PDF