Commit Graph

54 Commits

Author SHA1 Message Date
John Firebaugh dd0e08b244 Write presets and imagery to standalone files 2014-10-23 15:52:29 -07:00
Bryan Housel 26f8849c3a render triangular midpoints to show direction of way #1085 2014-07-16 00:30:21 -04:00
Bryan Housel 1a2b9c82f6 add tests, jshint cleanup 2014-06-16 11:49:07 -04:00
John Firebaugh a3c7b5956d Remove obsolete tests 2014-06-13 12:03:08 -07:00
Bryan Housel 38cb42e0bc Add tests for line z-indexing. 2014-06-11 22:30:36 -04:00
Bryan Housel 7f35ab6125 separate svg group for areas and their related strokes/fills
(for consistency)
2014-06-11 13:01:27 -04:00
John Firebaugh 26422d9c9a Show ways in restriction editor as if they were split 2014-05-18 16:02:47 -07:00
John Firebaugh f39ae89177 Render turns of selected way 2014-05-18 16:02:47 -07:00
John Firebaugh cdd9f8ba5f Fix SVG parse errors in specs (fixes #2012) 2013-11-22 11:16:08 -08:00
John Firebaugh 14bfc52e33 Remove repetition of entity IDs in tests
There were several places where the key and entity id
didn't match up.
2013-10-31 15:57:47 -07:00
John Firebaugh d6c7c1d81d Fix tests 2013-10-21 16:24:06 -07:00
John Firebaugh f1deed2712 Fix area sorting corner case (fixes #1903) 2013-10-18 10:28:01 -04:00
John Firebaugh 411db160fe Prefer to render highway=* styles over railway=*
Fixes #1880
2013-10-09 14:02:55 -07:00
John Firebaugh 405a49506b Building logic for turn restrictions 2013-08-30 14:23:05 -07:00
John Firebaugh 30f68c4ef9 Insert areas in sorted order
Fixes #1693
2013-08-26 15:27:57 -07:00
John Firebaugh a84a3364cc selection -> selectedIDs
Overloading "selection" is a bad idea.
2013-06-03 15:48:03 -07:00
John Firebaugh ee4ec4e252 Fix tests 2013-05-22 17:36:41 -07:00
John Firebaugh bd2c7ba756 Render bridge casing for bridge=viaduct, etc.
Fixes #1500.
2013-05-20 16:49:55 -07:00
John Firebaugh 67d95595ba Points always need full re-render (#569) 2013-05-20 12:05:31 -07:00
John Firebaugh 6431fca8a3 Fix area caching (fixes #1485) 2013-05-14 16:52:02 -07:00
John Firebaugh 878a4c0074 Don't need member tags for area strokes
Member tags are for multipolygon members, and multipolygon
member strokes are rendered by iD.svg.Lines.
2013-05-13 21:45:26 -07:00
John Firebaugh 9495f8f1c0 Optimize area rendering
Use iD.svg.Path for caching, and teach iD.svg.Path to
round coordinates.
2013-05-13 17:48:18 -07:00
John Firebaugh fd1573fa08 Abandon iD.svg.MemberClasses
Substantial performance hit for something that's barely used.
2013-05-13 12:46:01 -07:00
John Firebaugh 70e5411114 Optimize vertex rendering
* Cache icon
* Append rather than insert
* Do fewer things on update
* Don't create a fill unless needed
* Don't apply tag and member classes (never used)
* Drop down to raw setAttribute (d3 is slow :trollface:)
2013-05-13 09:37:48 -07:00
John Firebaugh 6941d1914b Perfect oneway markers 2013-04-26 17:33:01 -07:00
John Firebaugh 78aee5b6aa Fix tests 2013-04-23 20:09:36 -07:00
John Firebaugh 77ce20c8c1 Add configurable image path 2013-04-16 17:20:21 -07:00
John Firebaugh 944f44defd Really fix spec 2013-03-13 17:45:16 -07:00
John Firebaugh 71897a53cd Fix spec 2013-03-13 17:42:16 -07:00
John Firebaugh 3787185182 Rendering tagged points
At z16 and below, tagged points are rendered with a small
dot in the center. At z17 and above, they are rendered with
a maki icon.

See the test rendering page for examples.

Fixes #381.
2013-03-13 17:31:25 -07:00
John Firebaugh da902061d6 Fix tests 2013-03-08 20:37:19 -08:00
Tom MacWright 3e69ef6f9e Fix tests and global leak 2013-03-07 17:53:36 -05:00
Tom MacWright 1228155551 Fix tests
Way lines are no longer the only paths on the map, so we need to be more
specific.
2013-03-07 15:31:26 -05:00
John Firebaugh 98d1ee4f10 Fix rendering of multipolygons with the tags on the outer way
From the wiki:

> If you have one closed way making up the outer ring and it does not
> describe something in its own right, you may also put these tags on
> the outer ring and leave the relation untagged.

During line and area rendering, fix up such ways so that they are
rendered as if the tags were on the relation instead.

Fixes #613.
2013-03-06 13:22:43 -08:00
John Firebaugh 8aaa91d96f Fix tests 2013-03-04 08:00:12 -08:00
John Firebaugh 56a3edcf7f Fix tests
Disabling translation test, it's just too painful
2013-02-27 20:47:49 -08:00
Ansis Brammanis dfeff7e00d Fix svg midpoint tests 2013-02-18 18:38:01 -05:00
John Firebaugh 5eb0644242 Improve multipolygon rendering
Multipolygon relations report their geometry as 'area' and are rendered
as such. However, they do not render a stroke. The stroke rendering
will come from the individual lines, which are given the tag
classes of their parent relations, allowing them to have a stroke
style matching the style of simple areas with the same tags.

Untagged circular ways are no longer considered areas. This prevents
an untagged inner way of a multipolygon from rendering as an area and
is consistent with how P2 and JOSM treat them.

In the CSS, it's no longer necessary to deal with multipolygons
explicitly in selectors. But keep in mind that area boundaries can
now be rendered either as lines or as area strokes. In most cases
the selector should be `path.stroke.tag-_____`, i.e. an explicit
`.area` or `.line` classes should not be included.

Finally, the parent ways of selected multipolygons are given the 'selected'
class.
2013-02-05 15:20:11 -08:00
Ansis Brammanis d3d0851596 Fix svg/midpoint tests
Proper solution waiting on 369
2013-02-05 00:51:54 -05:00
John Firebaugh 459dc00ce5 Change the midpoint data a bit
Store the ways which share the segment and the index of
the segment. This will be used in both DragWay and Draw
behaviors.
2013-01-30 15:47:33 -05:00
John Firebaugh 66ac8349ac Stack areas by area (#324)
This doesn't address stacking multipolygons, or interleaving
areas and multipolygons. More and more, I'm thinking we should
just merge the two into a unified "area" geometry.
2013-01-25 17:13:34 -05:00
John Firebaugh 1be596c21b Fix tests 2013-01-24 11:26:57 -05:00
John Firebaugh 2c6e244fb0 Add tests for iD.svg.Lines 2013-01-17 15:17:40 -08:00
John Firebaugh 3eaf4a46e0 Add CSS classes for relation memberships
An entity that is a member of a relation will have the classes
`member`, `member-role-<member role>`, and `member-type-<relation type>`.

The first use of these classes is to avoid filling multipolygon
member areas.
2013-01-17 15:17:40 -08:00
John Firebaugh 9a76b81125 First cut on multipolygon rendering 2013-01-17 11:57:30 -08:00
John Firebaugh 545789efcc More area tests 2013-01-17 11:57:30 -08:00
John Firebaugh 8564279926 Use identity projection in tests 2013-01-17 11:57:29 -08:00
John Firebaugh 9f1506af5e Always use rounded projection 2013-01-17 11:57:29 -08:00
Tom MacWright ea3b7baf14 Tag classes no longer changes classes if there is no change. This makes the default, no-class scenario null instead of an empty string 2013-01-12 09:30:11 -05:00
John Firebaugh acaaab5dc9 Extract iD.svg.Surface 2013-01-11 16:01:39 -08:00