Bug report #3837

new symbology line decoration has wrong orientation when final vertices are duplicated

Added by Sandro Santilli over 9 years ago. Updated about 9 years ago.

Status:Closed
Priority:Low
Assignee:Jürgen Fischer
Category:Symbology
Affected QGIS version: Regression?:No
Operating System:All Easy fix?:No
Pull Request or Patch supplied:No Resolution:fixed
Crashes QGIS or corrupts data: Copied to github as #:13895

Description

After a long time happyness due to closing ticket #3434 the wrong arrow orientation bug is back.

This time the problem is due to lines having duplicated vertices toward the end, so that the "last segment" is empty.

I hit this bug while testing handling of such cases by postgis topology so it was intentional to have lines with endings collapsed.
Example:

LINESTRING(10 0, 0 0, 0 0)

I haven't checked this specific case but what I'm looking at right now is an arrow pointing o the right, so I guess you'd see the same right-pointing arrow for the case above (which is instead going to the left).
Note that the same right-arrow should appear for any line orientation: vertical or diagonal...

Label orientation might be affected too, but didn't try to produce that bug (I guess it'd take making it so that centroid of the line falls on a collapsed segment)

History

#1 Updated by Sandro Santilli over 9 years ago

The following changes since commit f88f72172450df32a41588b5b14915c69ae79c90:
  Marco Hugentobler (1):
        Discard empty http parameters in mapserver

are available in the git repository at:

  git://github.com/strk/Quantum-GIS.git bug3837

Sandro Santilli (1):
      Fix wrong arrow orientation when lines end with duplicated points (#3837)

 src/core/symbology-ng/qgslinesymbollayerv2.cpp |   11 +++++++++--
 1 files changed, 9 insertions(+), 2 deletions(-)

#2 Updated by Sandro Santilli over 9 years ago

One way to pull those changes is:

$ git remote add strk git://github.com/strk/Quantum-GIS.git
$ git pull strk bug3837

Oh, my bug3837 is branched from master, not 1_7_0 branch

#3 Updated by Sandro Santilli over 9 years ago

Note that the change was tested with vertical, horizontal and diagonal lines. Was also tested with lines collapsed to a point, in which case no arrow is printed.

#5 Updated by Paolo Cavallini about 9 years ago

  • Assignee deleted (nobody -)
  • Pull Request or Patch supplied set to No

Is this fixed?

#6 Updated by Sandro Santilli about 9 years ago

  • Assignee set to Jürgen Fischer
  • % Done changed from 0 to 100
  • Resolution set to fixed

Looks so, yes. Jef: was it pushed to both 1.7 and master ?

#7 Updated by Jürgen Fischer about 9 years ago

  • Status changed from Open to Closed

Sandro Santilli wrote:

Looks so, yes. Jef: was it pushed to both 1.7 and master ?

yes, in 3f60dc09edd2b73979dcc553aa94ee2353e69c01

Also available in: Atom PDF