Commit Graph

66 Commits

Author SHA1 Message Date
Bryan Housel 23bd2a101d Fix issues with <use>'d elements and fill under Firefox (closes #2860) 2015-12-06 22:28:09 -08:00
Bryan Housel 093b2a5a60 Workaround for broken maki hairdresser-18 icon 2015-11-25 02:00:28 -05:00
Bryan Housel d729795049 Use svg for maki also 2015-11-03 16:43:22 -05:00
Martin Raifer 6707063a53 don't try to label if centroid is undefined
updates fix from 09642b1e to updated d3 path.centroid return value structure (see https://github.com/mbostock/d3/commit/492215ad42e4b23bb713c012c449fa262007ec88#diff-fa5fbee10216651a004363cf56fb3602L43)

fixes #2757
refs #1180
2015-08-26 09:47:07 +02:00
Bryan Housel 1db51501a5 switch jshint to eslint (closes #2733) 2015-08-23 03:14:20 -04:00
John Firebaugh 1e78ee5c87 Stricter jshint 2013-10-24 16:08:48 -07:00
John Firebaugh 9557d8f130 Cache path 2013-10-17 10:19:56 -04:00
Tom MacWright 7ff9bf4a8f Cleanup style and null check 2013-09-17 10:46:49 -04:00
hhclaw.eb@gmail.com ab6c6411bd Unicode fix for label 2013-09-06 20:15:01 +08:00
hhclaw.eb@gmail.com 2c163ae2c2 Amend width calculation for wide characters 2013-09-06 20:00:08 +08:00
John Firebaugh 20cf935c46 Optimize iD.svg.Labels 2013-08-26 16:33:03 -07:00
Vladimir Agafonkin 454eecae8f replace RTree with RBush 2013-07-21 17:20:14 +03:00
John Firebaugh 6befa984db Fall back to ref tag for displayed feature name 2013-06-03 18:32:27 -07:00
John Firebaugh 0d7f38f6c1 Extract iD.util.localeName 2013-05-22 11:30:28 -07:00
John Firebaugh 6c849baad6 Revert "Cache centroid"
Causes misplaced labels, suspect due to rounding artifacts.

This reverts commit 5344bdea26.
2013-05-18 09:20:58 -07:00
John Firebaugh 5344bdea26 Cache centroid 2013-05-17 15:31:27 -07:00
John Firebaugh a53d5cbb44 Optimize label hover
Add entity IDs to the element class list, so that specific
elements can be selected by ID rather than needing `filter`.
2013-05-12 11:47:48 -07:00
John Firebaugh 2c631c6a0f Remove unused 2013-05-12 09:40:34 -07:00
John Firebaugh c829cbb463 Cleanup 2013-05-11 13:13:06 -07:00
John Firebaugh 1641f38632 Use context.mouse() 2013-05-09 21:55:05 -07:00
Ansis Brammanis 6096f9b230 fix #1362 2013-04-22 13:17:06 -04:00
John Firebaugh 20150cb9d4 Avoid retaining a graph reference
The supersurface event bindings retained a reference to the initial
graph, preventing it being GC'd after a save operation.
2013-04-20 15:18:14 -07:00
Ansis Brammanis 09642b1ea7 don't try to label if centroid is undefined
fixes #1180
2013-03-28 15:26:38 -04:00
Ansis Brammanis 0a7b19efdc nicer label halos
renders a second text with wider stroke
instead of drawing a block halo with a rect or path
2013-03-15 15:39:10 -04:00
Ansis Brammanis 747b7eda47 fix changing area icons 2013-03-15 14:14:34 -04:00
Ansis Brammanis 6e0925003c add Maki icons to areas 2013-03-15 13:57:08 -04:00
John Firebaugh 364d93693b Use traditional marker shape for points (fixes #172) 2013-03-14 11:22:10 -07:00
Tom MacWright 0fafa340fe Start using d3 3.1.0
Update d3, use streams, d3.set, clip
Use clipping, fix side effects
2013-03-07 17:45:16 -05:00
Ansis Brammanis 2af11c71db disable hideOnMouseover while dragging 2013-03-07 15:19:32 -05:00
Ansis Brammanis 116e03c6d6 tweak point label halo 2013-03-06 14:22:52 -05:00
Tom MacWright 71a4c5a383 Fix jshint errors - plz do not use unnecessary magic 2013-03-04 12:08:54 -05:00
Ansis Brammanis baa9dc6e5e Render unclosed areas correctly 2013-02-28 14:08:03 -05:00
Tom MacWright 5829438391 Enable advanced uglify compression, remove unused variables 2013-02-27 12:13:59 -05:00
Ansis Brammanis f4a6edb224 Localize labels 2013-02-08 18:25:39 -05:00
Tom MacWright 0b89df063f Optimize resetting opacity 2013-02-08 11:02:23 -05:00
Tom MacWright bd615fb19f Cache mousePosition 2013-02-08 10:48:00 -05:00
Tom MacWright 20e1181b7a Use a trueObj for filtering labels, add fastMouse 2013-02-08 10:08:30 -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 d0d1a16c0a Fix label halo sizing 2013-02-04 17:04:33 -05:00
Tom MacWright 4ee620cb09 Namespace selectors to iD-owned elements 2013-02-04 12:23:46 -05:00
Ansis Brammanis 8dcb215fe3 Hide labels on mouseover 2013-01-31 15:40:17 -05:00
Ansis Brammanis 26dfaf8161 Revise label stack 2013-01-31 14:43:41 -05:00
Ansis Brammanis c69345e039 Fix comparisons in subpath 2013-01-31 10:50:14 -05:00
Ansis Brammanis 5c1d3cc18e Preserve label tree between partial redraws 2013-01-31 10:34:57 -05:00
Ansis Brammanis 1d4c04c334 Slightly smarter line label placement 2013-01-28 12:10:25 -05:00
Tom MacWright adc302863f jshint please 2013-01-25 17:52:09 -05:00
John Firebaugh 5ea855e18d Replace Graph#fetch with Graph#childNodes
Having two kinds of Ways (fetched and non-fetched)
introduced some accidental complexity. This brings things
more in line with how parentWays/parentRelations work.

Fixes #73.
2013-01-25 15:10:44 -05:00
Tom MacWright 29577f7645 Fix loading inflight requests and clearing history when you switch
sources
2013-01-24 10:28:05 -05:00
Ansis Brammanis 9008779a18 Fix point label hiding 2013-01-23 19:10:10 -05:00
Ansis Brammanis 99748dba4e Fix several small label related bugs 2013-01-23 18:54:31 -05:00