Bug report #4223

printing issue

Added by KOSUKE ASAHI about 3 years ago. Updated about 1 year ago.

Status:Closed Start Date:08/26/2011
Priority:Normal Due date:
Assigned to:Pirmin Kalberer % Done:

0%

Category:-
Target version:-
Patch supplied:No Tag:

Description

I can't get correct output on print function.
Position is different, scale is changed and so on.

How about to make special print plugin for OpenLayers plugin.
This plugin has following actions.
1) Keep original position, scale and dpi, because we must refresh canvas after print
2) define print device, and get drawable area from print device
3) calculate output image size from darawable area using screen resolution, and make image
4) calculate output extent from drawable area
5) adjust QgsMapToPixel to 5)'s extent
6) render the canvas to 3)'s image, but not set extent, size and other information
7) adjust image to print device resolution
8) put image to print device
9) refresh the canvas using original info

I made this plugin, please check it.
http://d.hatena.ne.jp/waigani/files/PrintForOpenLayers.zip?d=download

Sorry for my poor English...

History

Updated by Pirmin Kalberer over 2 years ago

  • Assigned to set to Pirmin Kalberer

Hi Ashai,
Sorry for my very late response.
Your plugin is working for me, but I would very much prefer printing with the print composer.
I tried to adapt your printing method to the print composer. The problem is, that the print composer requests rendering with screen DPI, but with a larger extent.
I will discuss with Marco H., whether a there is a proper way for doing that.
Pirmin

Updated by barryrowlingson - over 2 years ago

Same problem here, just want to add that printing to a PDF from the print composer is also misaligned - probably a symptom of the same problem, but just requesting that when you fix it on-screen you check the PDF (and SVG?) output too!

Updated by MRick - over 2 years ago

When printing and using some levels or scales, the OL map will be completely at a different size of the vectors. Would be nice to get it working with the included print composer avoiding to ad tons of plug-ins that can conflicts between them.

Updated by Pirmin Kalberer over 2 years ago

  • Status changed from Open to Closed

Closing this ticket after the releasing 0.90. Please report remaining print issues in a new ticket.

Updated by MRick - about 2 years ago

This bug is back with QGIS 1.8

It will not happen with all the layers : if I use a Google based layer, no problem, with an OSM based layer, the bug happens.

Updated by MRick - about 2 years ago

I made tests back to version 1.7 and everything works perfectly well.
Printing is even smoother with version 1.7 than version 1.8.

Updated by Peter Kraska almost 2 years ago

I am having a similar problem as Bug#4223 while using QGIS 1.8 and OpenLayers 1.0.0. When I use the print manager the final pdf/svg/image is not aligned with my shapefiles. I'm at a loss for what to do, I have made it so that the project CRS is EPSG:3857 and changed the projections of the individual shapefiles to match. Any help would be appreciated.

Updated by Anita Graser about 1 year ago

I can confirm this problem with QGIS 1.8 on Ubuntu.
Seems to be fixed in master.

Also available in: Atom PDF