Commit Graph

697 Commits

Author SHA1 Message Date
Maximilian Krög
0d5d346bcd Update links to external resources 2021-02-08 19:40:05 +01:00
Simon Seyock
8facb252f1 Replace google closure syntax = with brackets around name 2021-02-03 14:06:02 +01:00
Hannes
25a374d698 Mention unit of radius for Polygon.circular()
Radius was using an unknown unit. This makes it clear that it will be interpreted as meters.
2021-01-19 17:25:47 +01:00
mike-000
1c529a9e2f document rotation direction 2020-11-23 14:41:30 +00:00
mike-000
540e5faa74 document rotation direction 2020-11-23 14:41:19 +00:00
mike-000
35266c47a3 document fromCircle angle direction and 0 2020-11-23 14:35:40 +00:00
Andreas Hocevar
946d11269f Merge pull request #11587 from MoonE/fix-text-along-path-orientation
Determine orientation by actual text start and end x
2020-11-06 13:35:55 +01:00
Andreas Hocevar
c1a547a9af Return to simpler and less efficient winding order algorithm 2020-11-06 00:02:01 +01:00
Maximilian Krög
03f6cbb5a8 Draw substrings on straight line in one operation 2020-11-05 22:35:54 +01:00
Maximilian Krög
528833b05b Don't iterate each chracter if entire string fits in single segment 2020-11-05 22:35:54 +01:00
Maximilian Krög
7660f3c522 Determine orientation by actual text start and end x 2020-10-20 22:46:04 +02:00
Andreas Hocevar
a9e51d85ec Fix Index adjustment at the beginning of the ring 2020-09-05 16:21:01 +02:00
Andreas Hocevar
f2b790adf1 Make clockwise check work when coordinates are duplicated 2020-09-04 20:47:15 +02:00
Michał Zielański
0001292a62 Method that copies properties from another object moved to the BaseObject class. Not using getProperties() to avoid creating an intermediate object that is not used later 2020-08-27 09:18:08 +02:00
Michał Zielański
8e0a61ac5f Adding original properties to cloned geometry 2020-08-26 15:11:11 +02:00
Andreas Hocevar
6ec49d5ee0 Fix upright labels on vector tiles 2020-07-11 17:55:34 +02:00
Andreas Hocevar
e4303c7b26 Merge pull request #11215 from ahocevar/flat-multipolygon
Fix MVT multipolygons with featureClass: Feature
2020-06-24 19:36:38 +02:00
Andreas Hocevar
4ce1cb89c6 Merge pull request #11195 from mike-000/patch-16
getExtent() to return getEmpty() if geometry is unprojectable
2020-06-24 15:01:00 +02:00
mike-000
4c7a1817fa optimise check for NaN in extent 2020-06-24 12:46:02 +01:00
Andreas Hocevar
c490745ff0 Faster clockwise check and better documentation 2020-06-23 19:56:12 +02:00
mike-000
74b74e2478 fix pettier 2020-06-17 16:59:56 +01:00
mike-000
1685913a55 getExtent() return getEmpty() for invalid extents 2020-06-17 16:46:24 +01:00
mike-000
19f3c6b94a getCoordinateAt return Z and M values if available 2020-06-17 15:46:28 +01:00
mike-000
f5d85ab4f9 interpolatePoint optionally returns Z and M values 2020-06-17 15:24:41 +01:00
Andreas Hocevar
b0f20d6bd6 Use imports for enum types 2020-04-15 10:53:23 +02:00
Tim Schaub
054af09032 Make code prettier
This updates ESLint and our shared eslint-config-openlayers to use Prettier.  Most formatting changes were automatically applied with this:

    npm run lint -- --fix

A few manual changes were required:

 * In `examples/offscreen-canvas.js`, the `//eslint-disable-line` comment needed to be moved to the appropriate line to disable the error about the `'worker-loader!./offscreen-canvas.worker.js'` import.
 * In `examples/webpack/exapmle-builder.js`, spaces could not be added after a couple `function`s for some reason.  While editing this, I reworked `ExampleBuilder` to be a class.
 * In `src/ol/format/WMSGetFeatureInfo.js`, the `// @ts-ignore` comment needed to be moved down one line so it applied to the `parsersNS` argument.
2020-04-06 12:54:09 -06:00
Frederic Junod
f392f6b6bb Remove all inheritDoc tags from src/ol/geom 2020-04-03 07:52:51 +02:00
mike-000
7a77793d69 Write fill and outline in PolyStyle
Write styles based on style objects appropriate for geometry.
Write fill and outline in PolyStyle if false (i.e. non-default)
Handle MultiLineString, MultiPoint and MultiPolygon within heterogenous MultiGeometry when writing features

Add getGeometriesArrayRecursive method to ol/geom/GeometryCollection to allow for nested MultiGeometry

Enhanced write GeometryCollection geometries test

A more rigorous write GeometryCollection geometries test including nested collections (the output is simplified to a single MultiGeomtry)

Add writeFeatures to outline and fill tests, setting geometry for geometry specific tests

Add <fill>0</fill> and <outline>0</outline> to some existing tests
2020-02-12 21:18:57 +00:00
Andreas Hocevar
bf7af07657 Ensure inherited docs are shown 2019-10-23 14:40:27 +02:00
mike-000
2b1417df3f Revise the description of applyTransform
Revise the description of applyTransform and transformFn (loosely based on that used in ol/extent) to avoid any misunderstanding that the function is called inside a forEach method.
2019-10-16 13:59:38 +01:00
Tim Schaub
d3b47c794e Make the immediate API work with a user projection 2019-09-30 08:28:50 -06:00
Tim Schaub
965d0541f2 Merge pull request #10004 from tschaub/revisions
Return a new simplified geometry after modification
2019-09-26 09:22:12 +02:00
Tim Schaub
680372ac3f Return a new simplified geometry after modification 2019-09-25 17:26:22 +02:00
Simon Seyock
bb0b94fedf fixed typescript issues 2019-09-25 14:10:05 +02:00
Tim Schaub
c071c749eb Merge pull request #9981 from KlausBenndorf/replace-geometry-cache
Remove simplified geometry cache
2019-09-24 18:11:33 +02:00
Tim Schaub
30cbbfea9d Get simplified transformed geometry and load features in user projection 2019-09-24 17:45:04 +02:00
Simon Seyock
6866f06375 Remove simplified geometry cache 2019-09-24 16:55:33 +02:00
mike-000
a4a0414eeb LineString.forEachSegment callback description
Include API description of the LineString.forEachSegment callback arguments.
2019-09-05 22:53:54 +01:00
ahocevar
ebfb20440a Simplify events and store listeners only in one place 2019-09-04 16:48:43 +02:00
Frederic Junod
2db953ceb1 Use markdown link syntax in jsdoc 2019-05-27 11:06:12 +02:00
ahocevar
41e958ea1f Split text into single chars or don't split at all 2019-05-15 11:55:29 +02:00
Frederic Junod
2989c84248 Implement translate function for circle geometry 2019-04-11 16:12:41 +02:00
Frederic Junod
319a905ec0 Implement rotate function for circle geometry 2019-04-09 16:58:44 +02:00
Frederic Junod
187f58c1c3 Remove opt_this param in ol/extent 2019-04-08 13:46:54 +02:00
Frederic Junod
438736068e Remove opt_this param in forEach function 2019-02-07 13:07:36 +01:00
Roman Zoller
ee57b197e5 Fix offset passed from linearRingssAreOriented to linearRingsAreOriented
The offset needs to be set to the end of the previous Polygon,
see `offset = orientLinearRings(...)` in function orientLinearRingsArray

Fixes #9189
2019-02-05 17:56:52 +01:00
Roman Zoller
2c859b1196 Rename misnamed functions in geom/flat/orient
- Rename linearRingIsOriented => linearRingsAreOriented
  The function checks all linear rings of a Polygon, so
  the plural "rings" is more appropriate
- Rename linearRingsAreOriented => linearRingssAreOriented
  The double s is appropriate because the check is done for
  all Polygons of a MultiPolygon

This commit restores the function names from OpenLayers v4,
they were changed (wrongly IMHO) in #7820.
2019-02-05 17:49:21 +01:00
Niklas Alt
d00bfe8fe7 Use generic * for Coordinate array returns 2018-12-06 14:36:33 +01:00
Niklas Alt
8f7d0c8a4b Specify the return array as coordinates 2018-12-03 20:22:46 +01:00
Tim Schaub
8b50c3c6cb Pass along the ability to measure and cache text width 2018-11-19 15:34:48 -07:00