Commit Graph

214 Commits

Author SHA1 Message Date
John Firebaugh eb55e36c3c Delete relations that become empty (#2270) 2014-06-26 10:21:03 -07:00
John Firebaugh f811c19cdc Fix straight on restricting with splits 2014-05-18 16:02:53 -07:00
John Firebaugh 6089a6aaea Better solution for maintaining selection 2014-05-18 16:02:48 -07:00
John Firebaugh 243e86b277 Update selected segment after splits 2014-05-18 16:02:48 -07:00
John Firebaugh eaaff52d62 Help text 2014-05-18 16:02:48 -07:00
John Firebaugh d4d80b2d6e Use turn restriction icons 2014-05-18 16:02:48 -07:00
John Firebaugh 3d210ac3c1 Implement basic restriction toggling 2014-05-18 16:02:47 -07:00
Bryan Housel 33782a3958 Require 2 uniq points for circularize. Handle 2 point case, where D3 centroid() fails. 2014-04-21 23:29:25 -04:00
Bryan Housel 210e7889a1 Factor makeConvex into new method, fix missing comma and style issues.. 2014-04-14 23:54:03 -04:00
Bryan Housel 52f631f4a0 Coax concave ways to convex before circularizing.. 2014-04-10 15:26:31 -04:00
Bryan Housel 4c0c078045 When circularizing a way, try to add inBetweenNodes to shared ways too.. 2014-04-07 22:42:34 -04:00
Bryan Housel a3a125187d preserve disconnect for lines, improve disconnect for shared nodes in areas.. 2014-04-01 17:22:48 -04:00
Bryan Housel 48dedb15ed Prevent a closed way from disconnecting itself.. 2014-03-30 22:49:19 -04:00
John Firebaugh 327af5176b Fix jshint 2014-02-09 18:48:52 -08:00
John Firebaugh 173108ae46 Style adjustments 2014-02-09 18:45:31 -08:00
tyr 90fd8b6e51 disable merge operation if at least one relation is incomplete
Incomplete multipolygons were harmed in the merge operation (which
relies on completely loaded relations to determine inner/outer
status for example).

This disables the operation and adds an appropriate tooltip.
2014-02-09 18:41:31 +01:00
tyr 422f76be77 merge-polygons: do not merge tags from all possible members
previously when merging polygons, all tags from all involved
members were merged into the resulting multipolygon. This includes
existing inner members with different tags or outer members that
are not directly involved in the merge operations.

Example: A forest (landuse=forest) containing some clearings
(landuse=meadow), whose outline is in part a river (waterway=river)
is merged with a new untagged area. The resulting multipolygon
would have falsely been tagged: landuse=forest;meadow + waterway=river
2014-02-09 17:53:55 +01:00
Paul Mach 4078d353b2 Bump threshold for Orthogonalize to 12 degrees 2014-01-16 12:06:54 -08:00
Aaron Lidman 383023f4c1 Don't upload tags with empty values 2014-01-02 15:03:21 -05:00
Martijn van Exel c43d915625 Reverse cardinal directions for relation member roles 2013-11-21 10:08:16 -08:00
John Firebaugh 3f99e2fd4b Fix Disconnect of way with multiple intersections (fixes #1955) 2013-11-14 15:48:07 -08:00
John Firebaugh 1e78ee5c87 Stricter jshint 2013-10-24 16:08:48 -07:00
John Firebaugh 8323c948a7 jshint fixes 2013-10-24 15:33:52 -07:00
John Firebaugh b69abc2359 iD.geo.edgeEqual 2013-10-10 11:29:10 -07:00
John Firebaugh 16d3346147 Split only the line of a node shared by a line and an area 2013-09-30 16:54:03 -07:00
John Firebaugh dfd0854314 Fix strict mode parse error and other style issues 2013-09-30 16:31:23 -07:00
John Firebaugh 69689a59d5 Reuse iD.actions.AddMember 2013-09-30 16:19:36 -07:00
John Firebaugh 011dc140a3 Handle multipolygon corner case when splitting (fixes #1799) 2013-09-30 16:17:16 -07:00
John Firebaugh 30bf1cd87c Remove unused variables 2013-09-30 10:14:40 -07:00
Paul Mach 0e080b3ed6 Limit squaring to near square or near straight nodes 2013-09-29 13:44:30 -07:00
tyr e8d637f2bb Add iD.geo.sphericalDistance
iD.geo.euclideanDistance should only be used for calculations of 
projected coordinates or display (pixel) coordinates.

iD.geo.sphericalDistance calculates approximate geographical 
distances, accounting for distortions at higher latitudes. This 
can be used for determining the nearest node (operations.Delete,
actions.Circularize) or relative length comparisons (actions.Split).
2013-09-29 07:45:04 -07:00
tyr 6afe3adfbe more clever splitting of closed ways
if a way is closed, iD needs to choose a second node to
split the way at.

This algorithm looks for a node that is both far away from
the initial node in terms of way segment length and nearby
in terms of beeline-distance. This assures that areas get
split on the most "natural" points (independent of the number
of nodes).

For example: bone-shaped areas get split across their waist-
line, circles across the diameter.
2013-09-29 07:43:20 -07:00
Paul Mach be30344cfd Improve Circularize Action 2013-09-28 14:33:39 -07:00
Paul Mach 3ac12a1e70 Orthononalize bug fixes 2013-09-27 22:24:32 -07:00
John Firebaugh 690a04e538 Make straighten/orthogonalize act like a single operation
- Display only one or the other in the radial menu
- Rename "Orthogonalize" to "Square"
- Use "S" as shortcut for both

Refs #1839
2013-09-25 14:26:30 -07:00
Paul Mach 76e0ef7c26 Better orthogonalization of skinny quads. Fixes #1812 2013-09-21 21:21:36 -07:00
Paul Mach b8efb00cfc Add straighten way operation and action 2013-09-20 12:14:16 -07:00
John Firebaugh e11ab9699d Avoid consecutive identical nodes when adding a midpoint
Previously, adding a midpoint to an invalidly doubled-back
segment (aba) resulted in a self-intersection with an invalid
consecutive node (accba). Now a self-intersection is still
produced, but with only one c node (acba).

Refs #1296
2013-09-01 12:57:10 -07:00
John Firebaugh 163c85bacb Delete relations that become empty
Fixes #465
Fixes #1454
2013-08-27 12:27:11 -07:00
John Firebaugh 21fa8c9c5d Prevent merging over restriction relations (#1512) 2013-06-18 14:25:10 -07:00
John Firebaugh ddd9e4e8cc Make iD.actions.Join agnostic to selection order
This is accomplished by reusing iD.geo.joinMemberWays,
which was refactored, generalized, and renamed to joinWays.
2013-06-18 12:19:53 -07:00
ProtD 80b7fd7f40 Allow to join more than two ways (#649) 2013-06-12 17:10:41 -07:00
John Firebaugh 7ec1222402 Try to insert relation members at a sensible index (#1539) 2013-06-05 16:00:53 -07:00
John Firebaugh 33cf029d43 Extract and refactor iD.geo.joinMemberWays 2013-06-05 16:00:12 -07:00
John Firebaugh 467d01d339 First pass at "Add to Relation" (#1539) 2013-06-05 11:22:00 -07:00
John Firebaugh 40526764bf Test / fix ChangePreset action 2013-05-29 08:44:59 -07:00
John Firebaugh f9f72be9c8 Extract iD.actions.ChangePreset 2013-05-28 17:41:26 -07:00
John Firebaugh 56f8b9e4a9 Fixup after merge 2013-05-28 16:56:49 -07:00
John Firebaugh 1e8052182d Merge pull request #1247 from systemed/create-multipolygon
ability to create multipolygons
2013-05-28 16:56:22 -07:00
John Firebaugh cac654e8ab Add iD.actions.ChangeMember 2013-05-22 17:41:06 -07:00