Bug report #4283

Composer forgets on/off status of layers ("Lock layers for map item" feature)

Added by Thaddeus - about 13 years ago. Updated about 13 years ago.

Status:Closed
Priority:Normal
Assignee:Marco Hugentobler
Category:-
Affected QGIS version: Regression?:No
Operating System: Easy fix?:No
Pull Request or Patch supplied:Yes Resolution:
Crashes QGIS or corrupts data: Copied to github as #:14222

Description

Composer is one nifty features of QGIS: on my last project I had 238 layers and 21 composer pages, I had to redo the locked layer selection many, many, ... many times.

After playing with this (QGIS 1.6 and 1.7) I discovered that adding and removing layers is what triggers the Composer lock-layer amnesia, but it actually resets all Composers lock-layer values to what the main canvas has at the time of doing the add/remove layer operation.

To reproduce:

1) Open test data "ComposerLockLayerForgetfulness.qgs" and I get what I see on 0001.png.

2) Turn off all layers but one (see 0002.png).

3) Open "Composer 1" and refresh view if desired.

4) Add raster layer -- say included "google-roadmap-z0-2-13092011_172245.png" -- and I get what is shown on 0004.png.

ComposerLockLayerForgetfulness.zip (53.7 KB) Thaddeus -, 2011-09-14 09:23 AM

0001.png (88 KB) Thaddeus -, 2011-09-14 09:24 AM

0002.png (63.3 KB) Thaddeus -, 2011-09-14 09:24 AM

0003.png (70.7 KB) Thaddeus -, 2011-09-14 09:25 AM

0004.png (56.6 KB) Thaddeus -, 2011-09-14 09:25 AM

fix_4283.patch Magnifier (929 Bytes) Nathan Woodrow, 2011-09-14 03:44 PM

History

#1 Updated by Thaddeus - about 13 years ago

#2 Updated by Thaddeus - about 13 years ago

#3 Updated by Thaddeus - about 13 years ago

#4 Updated by Thaddeus - about 13 years ago

#5 Updated by Nathan Woodrow about 13 years ago

  • Category set to 33
  • Pull Request or Patch supplied changed from No to Yes
  • Target version set to Version 1.7.1
  • File fix_4283.patchMagnifier added

Attached is a patch that fixes the problem.

#6 Updated by Nathan Woodrow about 13 years ago

  • Assignee set to Marco Hugentobler
  • % Done changed from 0 to 50

#7 Updated by Marco Hugentobler about 13 years ago

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

The composermap regularly checks for removed layers. The problem was that it didn't consider the non-visible layers if the layer-lock option was enabled and assumed those layers where deleted.
Fixed now in commit 820469f4b1f179348e9a46b27b0c55bcfd466576.

Also available in: Atom PDF