Bug report #15026

regression: pasting (or loading via .qml) a raster style changes layer extent

Added by Mathieu Pellerin - nIRV over 8 years ago. Updated over 8 years ago.

Status:Closed
Priority:Severe/Regression
Assignee:-
Category:Symbology
Affected QGIS version:master Regression?:No
Operating System: Easy fix?:No
Pull Request or Patch supplied:No Resolution:
Crashes QGIS or corrupts data:No Copied to github as #:22973

Description

When pasting a raster style (from layer A) onto another raster (layer B), QGIS now wrongly apply layer A's extent onto layer B. That pretty much renders that feature unusable for rasters.

Steps to reproduce
  1. Insert two rasters (A & B) with a different extent into a new project (for e.g. two LANDSAT scenes, two SRTM DEMs, etc.)
  2. Right click on one raster (A), and copy its style (through Style -> Copy style)
  3. Right click on the other raster (B), and paste the copied style (through Style -> Paste style)
  4. Notice the raster B goes missing
  5. Use the "Zoom to layer" action, notice how the canvas will zoom to the extent of raster A

Associated revisions

Revision 6d1e5542
Added by Jürgen Fischer over 8 years ago

don't save extents to style (fixes #15026, followup 92aed6e and d690d72)

Revision e1d54029
Added by Jürgen Fischer over 8 years ago

don't save extents to style (fixes #15026, followup 92aed6e and d690d72)

History

#1 Updated by Mathieu Pellerin - nIRV over 8 years ago

  • Subject changed from regression: pasting a raster style changes layer extent to regression: pasting (or loading via .qml) a raster style changes layer extent

The commit which led to this regression is d690d72

It also has broken loading of raster style via saved .qml files.

#2 Updated by Jürgen Fischer over 8 years ago

  • Status changed from Open to Closed

Also available in: Atom PDF