Bug report #422

Polygon holes connected by lines in Postscript/PDF

Added by Redmine Admin about 18 years ago. Updated over 15 years ago.

Status:Closed
Priority:Low
Assignee:Redmine Admin
Category:-
Affected QGIS version: Regression?:No
Operating System:All Easy fix?:No
Pull Request or Patch supplied: Resolution:fixed
Crashes QGIS or corrupts data: Copied to github as #:10481

Description

This was originaly reported by in ticket
https://svn.qgis.org/trac/ticket/345#comment:21

No crashes anymore. But the eps output happens to be corrupted if it conatins polygons. Take the attached shapefile and compose a map out of it (A4, portrait). In the left-top corner you'll see bogus line rendered (see the attached png dump; you can grab the whole eps from here: http://kufaya.googlepages.com/qgis.eps.bz2). This is only an example, I can reproduce this bug with other polygon layers. It is reproducable, though I can't find a pattern for it.

History

#1 Updated by Redmine Admin about 18 years ago

  • Resolution set to fixed
  • Status changed from Open to Closed

I see the reason but no easy solution. The problem is that Qt (AFAIK) does not support rendering of polygons with holes. We use the trick when each hole is connected 2 lines from the first vertex of the polygon. This works on screen but it seems it does not work in PS. PS has its own correct method how to render polygons with holes but we cannot use it through Qt.

We could probably find for each hole a better outer polygon vertex so that the connection does not run outside the polygon but it can be CPU time consuming in case of large polygons with many holes.

Radim

#2 Updated by Redmine Admin about 18 years ago

  • Resolution deleted (fixed)
  • Status changed from Closed to Feedback

#3 Updated by Martin Dobias about 18 years ago

  • Resolution set to fixed
  • Status changed from Feedback to Closed

Fixed in d520791c (SVN r6194) by using QPainterPath to draw polygons.

#4 Updated by Anonymous over 15 years ago

Milestone Version 0.8 deleted

Also available in: Atom PDF