Commit Graph

65 Commits

Author SHA1 Message Date
ahocevar
80ebb8142c Avoid unexpected behavior when passing string coordinates 2018-12-13 19:07:12 +01:00
Tim Schaub
ccfacc5ee6 Transformed types
Using the [ts.js codemod](https://gist.github.com/tschaub/1ea498c9d1e5268cf36d212b3949be4e):

    jscodeshift --transform ts.js src
2018-09-05 08:05:29 -06:00
Tim Schaub
d12ef20b12 Use Array<Foo> instead of Array.<Foo> 2018-07-25 18:32:43 -07:00
ahocevar
6c218a903e Fix a typedef 2018-04-27 10:10:49 +02:00
ahocevar
440d1ad3e1 Shorter module paths for default exports 2018-04-25 17:25:39 +02:00
Andreas Hocevar
95d6251dbb Get rid of olx.js and typedef.js typedefs for ol 2018-03-08 18:57:24 +01:00
Tim Schaub
b97554f2f3 Named exports from ol/coordinate 2018-02-09 14:31:20 -07:00
Frederic Junod
a114f64429 Named exports from ol/string 2018-01-19 15:38:21 +01:00
Tim Schaub
ad62739a6e Use blocked scoped variables
In addition to using const and let, this also upgrades our linter config and removes lint (mostly whitespace).
2018-01-12 00:50:30 -07:00
Ron Young
a11208d126 rename _ol_math_ imports 2017-12-20 19:31:00 -06:00
Tim Schaub
7f47883c48 Transformed 2017-12-12 06:53:18 -07:00
Marc Jansen
7d6929c710 Manual adjustment of indentation 2017-06-20 10:41:03 +02:00
Marc Jansen
d0ef05977b Autofix indentation issues (eslint --fix) 2017-06-19 11:58:00 +02:00
Thomas Chandelle
074fdeb212 Add snapping abilities on circles 2017-05-23 14:45:03 +02:00
Andreas Hocevar
3e9cbade45 Improve internal usability of ol.coordinate.degreesToStringHDMS 2017-04-23 22:46:33 +02:00
Andreas Hocevar
c1af0de860 Merge pull request #6410 from rjackson64840/fix-toStringHDMS
fixed the degreesToStringHDMS_() function to promote a seconds value …
2017-02-08 11:36:25 +01:00
Andreas Hocevar
bff6a14a16 Merge pull request #6457 from tst-ppenev/add-circle-support
Add Circle Modification
2017-02-06 21:14:49 +01:00
Pavel Penev
8c6d15b877 Add an ol.coordinate.distance() helper method.
The method is a companion to {@link ol.coordinate.squaredDistance}.
The new method returns the Cartesian distance, instead of its square.

Conflicts:
	src/ol/coordinate.js
2017-02-06 14:43:20 -05:00
Tim Schaub
f5aea97d3b All @api annotations imply stability 2017-02-06 09:22:05 -07:00
alfred.jackson
eebcccab66 fixed the degreesToStringHDMS_() function to promote a seconds value of 60 up to the next minute; fixed calculation of components 2017-01-27 17:32:21 -06:00
alfred.jackson
2001244b88 fixed the degreesToStringHDMS_() function to promote a seconds value of 60 up to the next minute 2017-01-27 14:43:41 -06:00
Frederic Junod
97ececb470 Remove unused ol.coordinate.fromProjectedArray function 2016-09-15 10:39:46 +02:00
Peter Robins
535e8f5e35 Move top-level typedefs to typedefs.js
With one exception, those directly in the `ol` namespace can be moved without problem.
Some left-over goog.requires are also removed.
2016-05-11 17:18:05 +00:00
nicholas
c92223d792 Remove Goog.string 2016-04-08 18:09:57 +12:00
Nicholas Latham
2ee1969de7 Remove goog.math.modulo and goog.math.lerp 2016-04-04 09:43:24 +02:00
pfanguin
b584a9aeb5 Add precision parameter for HDMS coordinate 2016-02-11 09:15:41 +01:00
Marc Jansen
390153adc8 Remove goog.isDef from coordinate.js 2015-09-25 11:28:54 -06:00
Pierre GIRAUD
1cdfc709ae Pad min. and sec. with leading zeros in DMS notation
FIxes 3776
2015-06-25 08:40:43 +02:00
Tim Schaub
d09c4afefb Coordinate docs 2015-04-04 17:36:47 +02:00
Stefan Weil
e812f2435e Fix typos found by codespell
Most of them are in comments, some in strings.

Signed-off-by: Stefan Weil <sw@weilnetz.de>
2015-02-12 16:39:55 +01:00
Éric Lemoine
546b42df07 Remove @api annotation from ol.coordinate.fromProjectedArray 2014-08-22 18:01:31 +02:00
Éric Lemoine
43bd2b740b Add @api stable annotations for ol.coordinate 2014-08-21 13:24:57 +02:00
Frederic Junod
53be13a658 Remove unused ol.CoordinateArray typedef 2014-07-29 14:44:51 +02:00
Marc Jansen
64c03d0f9c Add examples to ol.coordinate functions. 2014-07-23 09:15:50 +02:00
Tim Schaub
4cf5ab4620 Use @api annotation instead of @todo api 2014-07-05 15:41:14 -04:00
Peter Robins
2683f08bd2 Clarify that ol.Coordinate is for xy coordinates
Docs only; no logic change
2014-05-28 17:40:23 +01:00
Frederic Junod
8239a5c92a Document ol.coordinate functions 2014-05-20 14:15:28 +02:00
Andreas Hocevar
e6dbb61d68 Document raw geometry types 2014-05-06 12:45:53 -05:00
Andreas Hocevar
fbdbbfb7a7 Get rid of stability annotations and document stability with api
This change adds a stability value to the api annotation, with
'experimental' as default value.

enum, typedef and event annotations are never exportable, but
api annotations are needed there to make them appear in the
docs.

Nested typedefs are no longer inlined recursively, because the
resulting tables get too wide with the current template.
2014-04-29 09:53:07 -06:00
Andreas Hocevar
c17ac0cae3 Greatly simplify and document the usage of JSDoc
This commit simplifies the exports.js plugin so it only relies
on the stability notes to generate the documentation, which
completely decouples it from the exportable API.

As a rule of thumb, whenever something has an 'api' annotation,
it should also have a 'stability' annotation. A more verbose
documentation of ol3 specific annotation usage is available in
the new 'apidoc/readme.md' file.

This commit also modifies all source files to implement these
usage suggestions.
2014-04-29 09:53:06 -06:00
Tim Schaub
fb497f5288 Annotations for exports 2014-04-29 09:53:05 -06:00
Éric Lemoine
00bc424098 Add ol.coordinate.sub 2014-04-10 12:40:47 +02:00
Tom Payne
35dea5e3a6 Always use === to compare with 0 2014-03-23 18:29:47 +01:00
Bart van den Eijnden
87d651af04 Add documentation for API typedef functions 2014-02-14 15:32:12 +01:00
ahocevar
06406d968f Adding equals method for comparing coordinates 2013-11-13 00:44:38 +01:00
ahocevar
e9b934d041 Let closestOnSegment return nothing more than a coordinate
Since we do not use the 'along' property anywhere, and the
resulting array returned by closestOnSegment could cause trouble
when working with 3d coodinates, now only the closest point is
returned, and the squared distance to the segment is calculated
by squaredDistanceToSegment instead.
2013-11-04 20:54:07 +01:00
ahocevar
1670b31142 Moving squaredDistanceToSegment to the coordinate package 2013-11-04 19:19:54 +01:00
Frederic Junod
1217243f84 Better ol.coordinate.* documentation 2013-10-28 17:34:54 +01:00
Frederic Junod
9ca74200ed Remove opt_precision check in ol.coordinate.format
Default is already 0, see http://www.ecma-international.org/ecma-262/5.1/#sec-15.7.4.5
2013-10-28 16:26:21 +01:00
Frederic Junod
cdf34b558a Add ol.coordinate.format function
Return a formatted coordinate. Example usage:
  > ol.coordinate.format([0.01 ,12.14], "{x}, {y}", 2)
  "0.01, 12.14"
  > ol.coordinate.format([0.01 ,12.14], "lat: {y} / lon: {x}", 1)
  "lat: 12.1 / lon: 0.0"
2013-10-28 15:32:43 +01:00