diff --git a/doc/acknowledgments.qbk b/doc/acknowledgments.qbk index 929fa8d2a9..623f995ead 100644 --- a/doc/acknowledgments.qbk +++ b/doc/acknowledgments.qbk @@ -15,7 +15,7 @@ We like to thank all the people who helped to develop this library. First of all we are grateful to Hartmut Kaiser for managing the formal review -of this library. Hartmut is an excellent review manager, who intervented when +of this library. Hartmut is an excellent review manager, who intervened when necessary and produced the review report quickly. We thank the 14 reviewers of our library, reviewed from November 5, 2009 to diff --git a/doc/compiling.qbk b/doc/compiling.qbk index 8cf9088476..fac82391cf 100644 --- a/doc/compiling.qbk +++ b/doc/compiling.qbk @@ -20,7 +20,7 @@ library headers in their programs in order to be able to access definitions and algorithms provided by the __boost_geometry__ library. No linking against any binaries is required. -__boost_geometry__ is only dependant on headers-only __boost__ libraries. +__boost_geometry__ is only dependent on headers-only __boost__ libraries. It does not introduce indirect dependencies on any binary libraries. In order to be able to use __boost_geometry__, the only thing users need to do @@ -43,7 +43,7 @@ testing software, to configure, build and execute unit tests and example programs. The build configuration is provided as a collection of `Jamfile` files. -For gcc, flag [^-Wno-long-long] can be used to surpress some warnings +For gcc, flag [^-Wno-long-long] can be used to suppress some warnings originating from Boost. [heading Includes] @@ -58,7 +58,7 @@ recommended to include this file. Alternatively, it is possible to include __boost_geometry__ header files separately. However, this may be inconvenient as header files might be renamed -or moved occasionaly in future. +or moved occasionally in future. Another often used header is `geometries.hpp`: @@ -86,7 +86,7 @@ to include. Users who have their own geometries and want to use algorithms from __boost_geometry__ might include the files containing registration -macro's, like: +macros, like: #include @@ -101,7 +101,7 @@ performance: significantly faster code than use of the C++ standard library provided by __msvc__. * Turn on compiler optimizations, compile in release mode. -[heading Problems with Intellisense] +[heading Problems with IntelliSense] Both versions of __msvc__, 2005 and 2008 (including Express Editions) can hang trying to resolve symbols and give [@http://en.wikipedia.org/wiki/IntelliSense diff --git a/doc/concept/box.qbk b/doc/concept/box.qbk index 2f1ec9ed7a..28864747e7 100644 --- a/doc/concept/box.qbk +++ b/doc/concept/box.qbk @@ -18,7 +18,7 @@ A box is a geometry with (usually) two or three dimensions, having its axis aligned to the coordinate system. The box is not one of the basic types in Boost.Geometry (point, linestring, polygon) but it is a ['helper type]. -The main reasons for the box existance are its usefulness for indexing (a spatial index, or splitting a geometry +The main reasons for the box existence are its usefulness for indexing (a spatial index, or splitting a geometry into monotonic sections) and it is the output of the [link geometry.reference.algorithms.envelope envelope] algorithm. Therefore, a box is axis aligned (the envelope is also called aabb, axis aligned bounding box). diff --git a/doc/concept/point.qbk b/doc/concept/point.qbk index 3a59653e85..09fa167867 100644 --- a/doc/concept/point.qbk +++ b/doc/concept/point.qbk @@ -68,7 +68,7 @@ struct access, Index> { * [link geometry.reference.adapted.boost_fusion Boost.Fusion] * [link geometry.reference.adapted.boost_polygon Boost.Polygon] * [link geometry.reference.adapted.boost_tuple Boost.Tuple] -* other point types, adapted e.g. using one of the [link geometry.reference.adapted.register registration macro's] +* other point types, adapted e.g. using one of the [link geometry.reference.adapted.register registration macros] [endsect] diff --git a/doc/design_rationale.qbk b/doc/design_rationale.qbk index 93db7584dd..0a76ead0c9 100644 --- a/doc/design_rationale.qbk +++ b/doc/design_rationale.qbk @@ -188,7 +188,7 @@ Like the free get function, the library also contains a dimension meta-function. Below is explained why the extra declaration is useful. Now we have agnosticism in the number of dimensions. Our more generic distance function now accepts points of three or more dimensions. -The compile-time assertion will prevent point a having two dimension and point b having +The compile-time assertion will prevent point a having two dimensions and point b having three dimensions. [heading Coordinate Type] @@ -422,7 +422,7 @@ The same applies for the meta-function dimension and for the upcoming meta-funct Until here we assumed a Cartesian system. But we know that the Earth is not flat. Calculating a distance between two GPS-points with the system above would result in nonsense. So we again extend our design. We define for each point type a coordinate system type -using the traits system again. Then we make the calculation dependant on that coordinate system. +using the traits system again. Then we make the calculation dependent on that coordinate system. Coordinate system is similar to coordinate type, a meta-function, calling a dispatch function to have it for any geometry-type, forwarding to its point specialization, and finally calling @@ -575,7 +575,7 @@ that contains the squared value and is convertible to a double value. This, howe be done for `pythagoras`. The spherical distance functions do not take the square root so for them it is not necessary to avoid the expensive square root call; they can just return their distance. -So the distance result struct is dependant on strategy, therefore made a member type of +So the distance result struct is dependent on strategy, therefore made a member type of the strategy. The result struct looks like this: template diff --git a/doc/doxy/Doxyfile b/doc/doxy/Doxyfile index 8a835c443e..fe49c1ea84 100644 --- a/doc/doxy/Doxyfile +++ b/doc/doxy/Doxyfile @@ -88,7 +88,7 @@ ALIASES = qbk{1}="\xmlonly \1 \endxmlonly" \ param_macro_coorsystem="Coordinate system (e.g. cs::cartesian)" \ param_macro_member{1}="Member containing \1 coordinate" \ param_macro_getset{2}="Method to \1 the \2 coordinate" \ - param_range_point="A range containg points fulfilling range and point concepts" \ + param_range_point="A range containing points fulfilling range and point concepts" \ param_x="First coordinate (usually x-coordinate)" \ param_y="Second coordinate (usually y-coordinate)" \ param_z="Third coordinate (usually z-coordinate)" \ @@ -103,7 +103,7 @@ ALIASES = qbk{1}="\xmlonly \1 \endxmlonly" \ details_calc2{1}="The free function \1 calculates the \1 of two geometries" \ details_free_function{3}="The free function [^\1] calculates the \2 \3 two geometries" \ details_check12{2}="The free function \1 checks if the first geometry \2 the second geometry" \ - details_macro{2}="The macro \1 registers a \2 such that it is recognized by Boost.Geometry and that Boost.Geometry functionality can used with the specified type." \ + details_macro{2}="The macro \1 registers a \2 such that it is recognized by Boost.Geometry and that Boost.Geometry functionality can be used with the specified type." \ details_macro_const="The const version registers only read access to the fields, the point type is therefore read-only." \ details_macro_getset="The get/set version registers get and set methods separately and can be used for classes with protected member variables and get/set methods to change coordinates." \ details_macro_templated{2}="The type must have one template parameter, which should be a \2 type, and should not be specified. Boost.Geometry takes care of inserting the template parameter. Hence all types of this templated \1 are registered, regardless of their point type." \ diff --git a/doc/example_adapting_a_legacy_geometry_object_model.qbk b/doc/example_adapting_a_legacy_geometry_object_model.qbk index cf3b4dff3b..e083dbcd97 100644 --- a/doc/example_adapting_a_legacy_geometry_object_model.qbk +++ b/doc/example_adapting_a_legacy_geometry_object_model.qbk @@ -4,7 +4,7 @@ One of the primary benefits of __boost_geometry__, and the reason for its fairly By defining the relationship between the __boost_geometry__ concepts and an existing, legacy object model, the legacy objects can be used in place of __boost_geometry__'s own geometry classes. -__boost_geometry__ will then happliy read and write directly from and to the legacy object, treating it as a native __boost_geometry__ object. +__boost_geometry__ will then happily read and write directly from and to the legacy object, treating it as a native __boost_geometry__ object. This means that one can adapt algorithms and methods from __boost_geometry__ to any existing legacy geometry object model at a very small runtime cost, which is simply not possible with most geometry libraries, where one has to make an intermediate object specific to the geometry library one is using. @@ -12,7 +12,7 @@ The following example will demonstrate the adaption process of a legacy geometry [h2 Adapting a shared geometry legacy object model] -[h3 Example code: object hierarcy] +[h3 Example code: object hierarchy] class QPoint { @@ -42,7 +42,7 @@ The following example will demonstrate the adaption process of a legacy geometry std::vector interiors; }; -The legacy object hierarcy is based on topology (e.g. two QRings might share one QLineString) instead of points directly (i.e. each object does not point directly to it's QPoints), and it also uses pointers for access. +The legacy object hierarchy is based on topology (e.g. two QRings might share one QLineString) instead of points directly (i.e. each object does not point directly to its QPoints), and it also uses pointers for access. This is the other common way to approach geometries, to enable e.g. shared boundaries between surfaces. __boost_geometry__'s approach use simple features, and does not have shared geometries. @@ -77,7 +77,7 @@ The [link adaption_of_qring_source_code adaption of the QRing] is mostly equal t However, the QRing expose pointers-to-QLineStrings, and not QPoints directly, which is [link geometry.reference.concepts.concept_ring required in the Ring concept], so it is not enough to trivially make the std::vector into a __boost_range__. We need to create a Boost.Iterator that expose QPoints, and because we are dealing with a legacy object model, we are not allowed to change the class definition. -The [link adaption_of_qring_iterator_source_code custom iterator that does this] uses Boost.Iterator Facade, and is not very different from the [@http://www.boost.org/doc/libs/1_53_0/libs/iterator/doc/iterator_facade.html example provided in Boost.Iterator's own documentation](link), except that our __boost_range__ need to be random access. +The [link adaption_of_qring_iterator_source_code custom iterator that does this] uses Boost.Iterator Facade, and is not very different from the [@http://www.boost.org/doc/libs/1_53_0/libs/iterator/doc/iterator_facade.html example provided in Boost.Iterator's own documentation] (link), except that our __boost_range__ need to be random access. Now, with the custom iterator made, we can [link adaption_of_qring_range_source_code define the __boost_range__] that traverses through QPoints. diff --git a/doc/geometry.qbk b/doc/geometry.qbk index c224c26e98..980c6b53ce 100644 --- a/doc/geometry.qbk +++ b/doc/geometry.qbk @@ -111,7 +111,7 @@ Boost.Geometry contains contributions by: * Akira Takahashi (adaption of Boost.Fusion) * Alfredo Correa (adaption of Boost.Array) -* Andrew Hundt (varray container, aka. static_vector) +* Andrew Hundt (varray container, aka static_vector) * Federico Fern\u00E1ndez (preliminary version of R-tree spatial index) * Karsten Ahnert (patch for cross-track distance) * Mats Taraldsvik (documentation: adapting a legacy model) diff --git a/doc/index/introduction.qbk b/doc/index/introduction.qbk index e0c5b03e04..2b99cba761 100644 --- a/doc/index/introduction.qbk +++ b/doc/index/introduction.qbk @@ -12,7 +12,7 @@ The __boost_geometry_index__ is intended to gather data structures called spatial indexes which may be used to accelerate searching for objects in space. In general, -spatial indexes stores geometric objects' representations and allows searching for +spatial indexes store geometric objects' representations and allow searching for objects occupying some space or close to some point in space. Currently, only one spatial index is implemented - __rtree__. @@ -26,8 +26,8 @@ perform a spatial query. This query may for example return objects that are insi [footnote Cheung, K.; Fu, A. (1998). /Enhanced Nearest Neighbour Search on the R-tree/]. It's possible to insert new objects or to remove the ones already stored. -The __rtree__ structure is presented on the image below. Each __rtree__'s node store a box describing the space occupied by -its children nodes. At the bottom of the structure, there are leaf-nodes which contains values +The __rtree__ structure is presented on the image below. Each __rtree__'s node stores a box describing the space occupied by +its children nodes. At the bottom of the structure, there are leaf-nodes which contain values (geometric objects representations). [$img/index/rtree/rstar.png] @@ -36,11 +36,11 @@ The __rtree__ is a self-balanced data structure. The key part of balancing algor [footnote Greene, D. (1989). /An implementation and performance analysis of spatial data access methods/] [footnote Beckmann, N.; Kriegel, H. P.; Schneider, R.; Seeger, B. (1990). /The R*-tree: an efficient and robust access method for points and rectangles/]. Each algorithm produces different splits so the internal structure of a tree may be different for each one of them. -In general, more complex algorithms analyses elements better and produces less overlapping nodes. In the searching process less nodes must be traversed +In general, more complex algorithms analyse elements better and produce less overlapping nodes. In the searching process less nodes must be traversed in order to find desired objects. On the other hand more complex analysis takes more time. In general faster inserting will result in slower searching and vice versa. The performance of the R-tree depends on balancing algorithm, parameters and data inserted into the container. -Additionally there are also algorithms creating R-tree containing some, number of objects. This technique is called bulk loading and is +Additionally, there are also algorithms creating R-tree containing some number of objects. This technique is called bulk loading and is done by use of packing algorithm [footnote Leutenegger, Scott T.; Edgington, Jeffrey M.; Lopez, Mario A. (1997). /STR: A Simple and Efficient Algorithm for R-Tree Packing/] [footnote Garcia, Yvan J.; Lopez, Mario A.; Leutenegger, Scott T. (1997). /A Greedy Algorithm for Bulk Loading R-trees/]. diff --git a/doc/index/rtree/creation.qbk b/doc/index/rtree/creation.qbk index 7f5f8290ac..450ad6217e 100644 --- a/doc/index/rtree/creation.qbk +++ b/doc/index/rtree/creation.qbk @@ -139,7 +139,7 @@ The following code creates an __rtree__ using quadratic balancing algorithm. typedef std::pair __value__; index::rtree< __value__, index::quadratic<16> > rt; -To insert or remove a `__value__' by method call one may use the following +To insert or remove a `__value__` by method call one may use the following code. __value__ v = std::make_pair(__box__(...), 0); @@ -148,7 +148,7 @@ code. rt.remove(v); -To insert or remove a `__value__' by function call one may use the following +To insert or remove a `__value__` by function call one may use the following code. __value__ v = std::make_pair(__box__(...), 0); diff --git a/doc/index/rtree/query.qbk b/doc/index/rtree/query.qbk index 3fce9af903..61d18ae14d 100644 --- a/doc/index/rtree/query.qbk +++ b/doc/index/rtree/query.qbk @@ -10,7 +10,7 @@ [section Queries] -Queries returns `__value__`s which meets some predicates. Currently supported are three types of predicates: +Queries return `__value__`s which meet some predicates. Currently supported are three types of predicates: * spatial predicates - spatial conditions that must be met by stored Value and some Geometry, * distance predicates - distance conditions that must be met by stored Value and some Geometry, @@ -25,7 +25,7 @@ For example queries may be used to retrieve Values: [h4 Performing a query] There are various ways to perform a query. They are presented below. -All of them returns `__value__`s intersecting some region defined as a `__box__`. +All of them return `__value__`s intersecting some region defined as a `__box__`. Member function call @@ -59,7 +59,7 @@ Query iterators returned by free functions [h4 Spatial queries] -Queries using spatial predicates returns `__value__`s which are related somehow to some Geometry - box, polygon, etc. +Queries using spatial predicates return `__value__`s which are related somehow to some Geometry - box, polygon, etc. Names of spatial predicates correspond to names of __boost_geometry__ algorithms (boolean operations). Examples of some basic queries may be found in the tables below. The query region and result `Value`s are orange. @@ -101,7 +101,7 @@ All spatial predicates may be negated, e.g.: [h4 Nearest neighbours queries] -Nearest neighbours queries returns `__value__`s which are closest to some Geometry. +Nearest neighbours queries return `__value__`s which are closest to some Geometry. The examples of k-NN queries are presented below. 5 `__value__`s nearest to the Geometry are orange. [table diff --git a/doc/index/rtree/quickstart.qbk b/doc/index/rtree/quickstart.qbk index 37826b6e2e..13111e9cfa 100644 --- a/doc/index/rtree/quickstart.qbk +++ b/doc/index/rtree/quickstart.qbk @@ -10,7 +10,7 @@ [section:rtree_quickstart Quick Start] -This Quick Start section shows simple way to creating a typical R-tree and perform +This Quick Start section shows a simple way to create a typical R-tree and perform spatial query. The code below assumes that following files are included and namespaces used. @@ -32,7 +32,7 @@ passed as template parameters. Maximum number of elements in nodes is set to 16. Typically `Value`s will be generated in a loop from e.g. `Polygon`s stored in some other container. In this case `Box` objects will probably be created with `geometry::envelope()` function. -But to keep it simple lets just generate some boxes manually and insert them into the R-tree by +But to keep it simple let's just generate some boxes manually and insert them into the R-tree by using `insert()` method. [rtree_quickstart_insert] diff --git a/doc/introduction.qbk b/doc/introduction.qbk index b8399201c2..ec2ca47b73 100644 --- a/doc/introduction.qbk +++ b/doc/introduction.qbk @@ -38,7 +38,7 @@ The library follows existing conventions: * conventions from boost * conventions from the std library * conventions and names from one of the __ogc__ standards on geometry and, more - specificly, from the __ogc_sf__ + specifically, from the __ogc_sf__ The library was first released with Boost 1.47.0 and from that point on it is officially part of the Boost C++ Libraries. diff --git a/doc/reference.qbk b/doc/reference.qbk index 705a779838..bdf28e3f7d 100644 --- a/doc/reference.qbk +++ b/doc/reference.qbk @@ -63,7 +63,7 @@ [include reference/geometries/adapted/boost_range/strided.qbk] [/ include reference/geometries/adapted/boost_range/uniqued.qbk] [endsect] -[section:register Macro's for adaption] +[section:register Macros for adaption] [include generated/register.qbk] [endsect] [endsect] diff --git a/doc/reference/algorithms/append.qbk b/doc/reference/algorithms/append.qbk index 22dbb561ae..3bca8a71e4 100644 --- a/doc/reference/algorithms/append.qbk +++ b/doc/reference/algorithms/append.qbk @@ -34,7 +34,7 @@ [[__multi_linestring__][Appends point or range to the end of the linestring with the given multi index. The multi-linestring is not resized automatically, so ensure - that the multi index is smaller than then number of linestring + that the multi index is smaller than the number of linestring in the multi-linestring.]] [[__multi_polygon__][Appends point or range to the end of the polygon (without explicitly closing it) with the given multi-index. @@ -42,7 +42,7 @@ exterior ring (the default) or specify a zero-based ring index for the interior rings. The multi-polygon is not resized automatically, so ensure - that the multi index is smaller than then number of polygon + that the multi index is smaller than the number of polygon in the multi-polygon. The same applies for the interior rings of the polygon: the interior rings are not resized automatically, so ensure that the zero-based ring index is diff --git a/doc/reference/algorithms/buffer_with_strategies.qbk b/doc/reference/algorithms/buffer_with_strategies.qbk index cf348b9ece..f098ae92b2 100644 --- a/doc/reference/algorithms/buffer_with_strategies.qbk +++ b/doc/reference/algorithms/buffer_with_strategies.qbk @@ -15,7 +15,7 @@ The 5 strategies give the user control to the generated buffer * convex corners can be rounded or sharp * line-ends can be rounded or flat -* distance can be symmetric or assymetric, and positive or negative +* distance can be symmetric or asymmetric, and positive or negative * around points the shape can be circular or square * the sides can be controlled (currently there is only one option provided) diff --git a/doc/reference/algorithms/expand.qbk b/doc/reference/algorithms/expand.qbk index 0b1c14bd77..44269cdb93 100644 --- a/doc/reference/algorithms/expand.qbk +++ b/doc/reference/algorithms/expand.qbk @@ -24,7 +24,7 @@ [[__box__ / __other__][__nyiversion__]] ] -[note To use expand with another geometry type then specified, use expand(make_envelope(geometry)] +[note To use expand with another geometry type than specified, use expand(make_envelope(geometry)] [heading Complexity] Linear diff --git a/include/boost/geometry/algorithms/for_each.hpp b/include/boost/geometry/algorithms/for_each.hpp index ee65045d6b..bf7350a348 100644 --- a/include/boost/geometry/algorithms/for_each.hpp +++ b/include/boost/geometry/algorithms/for_each.hpp @@ -123,7 +123,7 @@ struct fe_point_type template -struct fe_point_type_is_referencable +struct fe_point_type_is_referenceable { static const bool value = std::is_const::value @@ -138,7 +138,7 @@ struct fe_point_type_is_referencable template < typename Range, - bool UseReferences = fe_point_type_is_referencable::value + bool UseReferences = fe_point_type_is_referenceable::value > struct fe_point_call_f { @@ -192,7 +192,7 @@ struct fe_point_range template < typename Range, - bool UseReferences = fe_point_type_is_referencable::value + bool UseReferences = fe_point_type_is_referenceable::value > struct fe_segment_call_f { diff --git a/include/boost/geometry/algorithms/union.hpp b/include/boost/geometry/algorithms/union.hpp index 494e700ee0..73882e43ef 100644 --- a/include/boost/geometry/algorithms/union.hpp +++ b/include/boost/geometry/algorithms/union.hpp @@ -811,7 +811,7 @@ struct union_() const { - BOOST_GEOMETRY_INDEX_ASSERT(false, "iterator not dereferencable"); + BOOST_GEOMETRY_INDEX_ASSERT(false, "iterator not dereferenceable"); const value_type * p = 0; return p; } diff --git a/include/boost/geometry/index/detail/rtree/linear/redistribute_elements.hpp b/include/boost/geometry/index/detail/rtree/linear/redistribute_elements.hpp index 87f933f659..4cba83b6be 100644 --- a/include/boost/geometry/index/detail/rtree/linear/redistribute_elements.hpp +++ b/include/boost/geometry/index/detail/rtree/linear/redistribute_elements.hpp @@ -71,12 +71,12 @@ inline R difference(T const& from, T const& to) // IMPORTANT! // Still probably the best way would be providing specialized algorithms for each Indexable-Bounds pair! -// Probably on pick_seeds algorithm level - For Bounds=Sphere seeds would be choosen differently +// Probably on pick_seeds algorithm level - For Bounds=Sphere seeds would be chosen differently // TODO: awulkiew // there are loops inside find_greatest_normalized_separation::apply() // iteration is done for each DimensionIndex. -// Separations and seeds for all DimensionIndex(es) could be calculated at once, stored, then the greatest would be choosen. +// Separations and seeds for all DimensionIndex(es) could be calculated at once, stored, then the greatest would be chosen. // The following struct/method was adapted for the preliminary version of the R-tree. Then it was called: // void find_normalized_separations(std::vector const& boxes, T& separation, unsigned int& first, unsigned int& second) const diff --git a/include/boost/geometry/index/detail/rtree/quadratic/redistribute_elements.hpp b/include/boost/geometry/index/detail/rtree/quadratic/redistribute_elements.hpp index 23de98c161..31ee5cc842 100644 --- a/include/boost/geometry/index/detail/rtree/quadratic/redistribute_elements.hpp +++ b/include/boost/geometry/index/detail/rtree/quadratic/redistribute_elements.hpp @@ -220,7 +220,7 @@ struct redistribute_elements } } - // move element to the choosen group + // move element to the chosen group element_type const& elem = *el_it; indexable_type const& indexable = rtree::element_indexable(elem, translator); diff --git a/include/boost/geometry/index/detail/rtree/query_iterators.hpp b/include/boost/geometry/index/detail/rtree/query_iterators.hpp index 170c3ac9b1..6fc5253f42 100644 --- a/include/boost/geometry/index/detail/rtree/query_iterators.hpp +++ b/include/boost/geometry/index/detail/rtree/query_iterators.hpp @@ -34,14 +34,14 @@ struct end_query_iterator reference operator*() const { - BOOST_GEOMETRY_INDEX_ASSERT(false, "iterator not dereferencable"); + BOOST_GEOMETRY_INDEX_ASSERT(false, "iterator not dereferenceable"); pointer p(0); return *p; } const value_type * operator->() const { - BOOST_GEOMETRY_INDEX_ASSERT(false, "iterator not dereferencable"); + BOOST_GEOMETRY_INDEX_ASSERT(false, "iterator not dereferenceable"); const value_type * p = 0; return p; } diff --git a/include/boost/geometry/index/detail/rtree/rstar/choose_next_node.hpp b/include/boost/geometry/index/detail/rtree/rstar/choose_next_node.hpp index 8032a2626e..3e5584c6b4 100644 --- a/include/boost/geometry/index/detail/rtree/rstar/choose_next_node.hpp +++ b/include/boost/geometry/index/detail/rtree/rstar/choose_next_node.hpp @@ -101,7 +101,7 @@ class choose_next_node content_type min_content_diff = (std::numeric_limits::max)(); content_type min_content = (std::numeric_limits::max)(); - size_t choosen_index = 0; + size_t chosen_index = 0; // create container of children sorted by content enlargement needed to include the new value typename rtree::container_from_elements_type::type @@ -126,7 +126,7 @@ class choose_next_node { min_content_diff = content_diff; min_content = content; - choosen_index = i; + chosen_index = i; } } @@ -144,14 +144,14 @@ class choose_next_node } // calculate minimum or nearly minimum overlap cost - choosen_index = choose_by_minimum_overlap_cost_first_n(children, indexable, + chosen_index = choose_by_minimum_overlap_cost_first_n(children, indexable, first_n_children_count, children_count, children_contents, strategy); } - return choosen_index; + return chosen_index; } static inline bool content_diff_less(child_contents const& p1, child_contents const& p2) @@ -172,7 +172,7 @@ class choose_next_node BOOST_GEOMETRY_INDEX_ASSERT(children_contents.size() == children_count, "unexpected number of elements"); // choose index with smallest overlap change value, or content change or smallest content - size_t choosen_index = 0; + size_t chosen_index = 0; content_type smallest_overlap_diff = (std::numeric_limits::max)(); content_type smallest_content_diff = (std::numeric_limits::max)(); content_type smallest_content = (std::numeric_limits::max)(); @@ -216,11 +216,11 @@ class choose_next_node smallest_overlap_diff = overlap_diff; smallest_content_diff = content_diff; smallest_content = content; - choosen_index = i; + chosen_index = i; } } - return choosen_index; + return chosen_index; } template @@ -231,7 +231,7 @@ class choose_next_node size_t children_count = children.size(); // choose index with smallest content change or smallest content - size_t choosen_index = 0; + size_t chosen_index = 0; content_type smallest_content_diff = (std::numeric_limits::max)(); content_type smallest_content = (std::numeric_limits::max)(); @@ -254,11 +254,11 @@ class choose_next_node { smallest_content_diff = content_diff; smallest_content = content; - choosen_index = i; + chosen_index = i; } } - return choosen_index; + return chosen_index; } }; diff --git a/include/boost/geometry/index/detail/rtree/rstar/redistribute_elements.hpp b/include/boost/geometry/index/detail/rtree/rstar/redistribute_elements.hpp index 8d1a25548e..e9084a3a0a 100644 --- a/include/boost/geometry/index/detail/rtree/rstar/redistribute_elements.hpp +++ b/include/boost/geometry/index/detail/rtree/rstar/redistribute_elements.hpp @@ -114,7 +114,7 @@ struct choose_split_axis_and_index_for_corner template static inline void apply(Elements const& elements, - size_t & choosen_index, + size_t & chosen_index, margin_type & sum_of_margins, content_type & smallest_overlap, content_type & smallest_content, @@ -152,7 +152,7 @@ struct choose_split_axis_and_index_for_corner // } // init outputs - choosen_index = index_first; + chosen_index = index_first; sum_of_margins = 0; smallest_overlap = (std::numeric_limits::max)(); smallest_content = (std::numeric_limits::max)(); @@ -176,7 +176,7 @@ struct choose_split_axis_and_index_for_corner // TODO - shouldn't here be < instead of <= ? if ( ovl < smallest_overlap || (ovl == smallest_overlap && con <= smallest_content) ) { - choosen_index = i; + chosen_index = i; smallest_overlap = ovl; smallest_content = con; } @@ -200,8 +200,8 @@ struct choose_split_axis_and_index_for_axis template static inline void apply(Elements const& elements, - size_t & choosen_corner, - size_t & choosen_index, + size_t & chosen_corner, + size_t & chosen_index, margin_type & sum_of_margins, content_type & smallest_overlap, content_type & smallest_content, @@ -232,15 +232,15 @@ struct choose_split_axis_and_index_for_axis if ( ovl1 < ovl2 || (ovl1 == ovl2 && con1 <= con2) ) { - choosen_corner = min_corner; - choosen_index = index1; + chosen_corner = min_corner; + chosen_index = index1; smallest_overlap = ovl1; smallest_content = con1; } else { - choosen_corner = max_corner; - choosen_index = index2; + chosen_corner = max_corner; + chosen_index = index2; smallest_overlap = ovl2; smallest_content = con2; } @@ -255,8 +255,8 @@ struct choose_split_axis_and_index_for_axis template static inline void apply(Elements const& elements, - size_t & choosen_corner, - size_t & choosen_index, + size_t & chosen_corner, + size_t & chosen_index, margin_type & sum_of_margins, content_type & smallest_overlap, content_type & smallest_content, @@ -264,11 +264,11 @@ struct choose_split_axis_and_index_for_axis Translator const& translator) { choose_split_axis_and_index_for_corner - ::apply(elements, choosen_index, + ::apply(elements, chosen_index, sum_of_margins, smallest_overlap, smallest_content, parameters, translator); // MAY THROW, STRONG - choosen_corner = min_corner; + chosen_corner = min_corner; } }; @@ -282,9 +282,9 @@ struct choose_split_axis_and_index template static inline void apply(Elements const& elements, - size_t & choosen_axis, - size_t & choosen_corner, - size_t & choosen_index, + size_t & chosen_axis, + size_t & chosen_corner, + size_t & chosen_index, margin_type & smallest_sum_of_margins, content_type & smallest_overlap, content_type & smallest_content, @@ -294,7 +294,7 @@ struct choose_split_axis_and_index typedef typename rtree::element_indexable_type::type element_indexable_type; choose_split_axis_and_index - ::apply(elements, choosen_axis, choosen_corner, choosen_index, + ::apply(elements, chosen_axis, chosen_corner, chosen_index, smallest_sum_of_margins, smallest_overlap, smallest_content, parameters, translator); // MAY THROW, STRONG @@ -316,9 +316,9 @@ struct choose_split_axis_and_index if (sum_of_margins < smallest_sum_of_margins) { - choosen_axis = Dimension - 1; - choosen_corner = corner; - choosen_index = index; + chosen_axis = Dimension - 1; + chosen_corner = corner; + chosen_index = index; smallest_sum_of_margins = sum_of_margins; smallest_overlap = overlap_val; smallest_content = content_val; @@ -334,9 +334,9 @@ struct choose_split_axis_and_index template static inline void apply(Elements const& elements, - size_t & choosen_axis, - size_t & choosen_corner, - size_t & choosen_index, + size_t & chosen_axis, + size_t & chosen_corner, + size_t & chosen_index, margin_type & smallest_sum_of_margins, content_type & smallest_overlap, content_type & smallest_content, @@ -345,14 +345,14 @@ struct choose_split_axis_and_index { using element_indexable_type = typename rtree::element_indexable_type::type; - choosen_axis = 0; + chosen_axis = 0; choose_split_axis_and_index_for_axis < Box, 0, tag_t - >::apply(elements, choosen_corner, choosen_index, smallest_sum_of_margins, + >::apply(elements, chosen_corner, chosen_index, smallest_sum_of_margins, smallest_overlap, smallest_content, parameters, translator); // MAY THROW } }; diff --git a/include/boost/geometry/index/detail/rtree/visitors/insert.hpp b/include/boost/geometry/index/detail/rtree/visitors/insert.hpp index 27e62584d4..1c046b1bde 100644 --- a/include/boost/geometry/index/detail/rtree/visitors/insert.hpp +++ b/include/boost/geometry/index/detail/rtree/visitors/insert.hpp @@ -72,7 +72,7 @@ class choose_next_node size_t children_count = children.size(); // choose index with smallest content change or smallest content - size_t choosen_index = 0; + size_t chosen_index = 0; content_type smallest_content_diff = (std::numeric_limits::max)(); content_type smallest_content = (std::numeric_limits::max)(); @@ -97,11 +97,11 @@ class choose_next_node { smallest_content_diff = content_diff; smallest_content = content; - choosen_index = i; + chosen_index = i; } } - return choosen_index; + return chosen_index; } }; @@ -343,19 +343,19 @@ class insert inline void traverse(Visitor & visitor, internal_node & n) { // choose next node - size_t choosen_node_index = rtree::choose_next_node + size_t chosen_node_index = rtree::choose_next_node ::apply(n, rtree::element_indexable(m_element, m_translator), m_parameters, m_leafs_level - m_traverse_data.current_level); // expand the node to contain value index::detail::expand( - rtree::elements(n)[choosen_node_index].first, + rtree::elements(n)[chosen_node_index].first, m_element_bounds, index::detail::get_strategy(m_parameters)); // next traversing step - traverse_apply_visitor(visitor, n, choosen_node_index); // MAY THROW (V, E: alloc, copy, N:alloc) + traverse_apply_visitor(visitor, n, chosen_node_index); // MAY THROW (V, E: alloc, copy, N:alloc) } // TODO: awulkiew - change post_traverse name to handle_overflow or overflow_treatment? @@ -377,17 +377,17 @@ class insert } template - inline void traverse_apply_visitor(Visitor & visitor, internal_node &n, size_t choosen_node_index) + inline void traverse_apply_visitor(Visitor & visitor, internal_node &n, size_t chosen_node_index) { // save previous traverse inputs and set new ones insert_traverse_data backup_traverse_data = m_traverse_data; // calculate new traverse inputs - m_traverse_data.move_to_next_level(&n, choosen_node_index); + m_traverse_data.move_to_next_level(&n, chosen_node_index); // next traversing step - rtree::apply_visitor(visitor, *rtree::elements(n)[choosen_node_index].second); // MAY THROW (V, E: alloc, copy, N:alloc) + rtree::apply_visitor(visitor, *rtree::elements(n)[chosen_node_index].second); // MAY THROW (V, E: alloc, copy, N:alloc) // restore previous traverse inputs m_traverse_data = backup_traverse_data; diff --git a/include/boost/geometry/index/detail/rtree/visitors/iterator.hpp b/include/boost/geometry/index/detail/rtree/visitors/iterator.hpp index 1a08f2b3f0..07f4bcc9b3 100644 --- a/include/boost/geometry/index/detail/rtree/visitors/iterator.hpp +++ b/include/boost/geometry/index/detail/rtree/visitors/iterator.hpp @@ -82,7 +82,7 @@ class iterator { for (;;) { - // if leaf is choosen, move to the next value in leaf + // if leaf is chosen, move to the next value in leaf if ( m_values ) { // there are more values in the current leaf @@ -96,7 +96,7 @@ class iterator m_values = 0; } } - // if leaf isn't choosen, move to the next leaf + // if leaf isn't chosen, move to the next leaf else { // return if there is no more nodes to traverse diff --git a/include/boost/geometry/index/detail/rtree/visitors/remove.hpp b/include/boost/geometry/index/detail/rtree/visitors/remove.hpp index 4e8e9078f2..9cf10f250f 100644 --- a/include/boost/geometry/index/detail/rtree/visitors/remove.hpp +++ b/include/boost/geometry/index/detail/rtree/visitors/remove.hpp @@ -202,7 +202,7 @@ class remove typedef std::vector< std::pair > underflow_nodes; - void traverse_apply_visitor(internal_node &n, internal_size_type choosen_node_index) + void traverse_apply_visitor(internal_node &n, internal_size_type chosen_node_index) { // save previous traverse inputs and set new ones internal_node_pointer parent_bckup = m_parent; @@ -210,11 +210,11 @@ class remove size_type current_level_bckup = m_current_level; m_parent = &n; - m_current_child_index = choosen_node_index; + m_current_child_index = chosen_node_index; ++m_current_level; // next traversing step - rtree::apply_visitor(*this, *rtree::elements(n)[choosen_node_index].second); // MAY THROW (V, E: alloc, copy, N: alloc) + rtree::apply_visitor(*this, *rtree::elements(n)[chosen_node_index].second); // MAY THROW (V, E: alloc, copy, N: alloc) // restore previous traverse inputs m_parent = parent_bckup; diff --git a/include/boost/geometry/index/detail/rtree/visitors/spatial_query.hpp b/include/boost/geometry/index/detail/rtree/visitors/spatial_query.hpp index 678f9ddd74..9cabcf963a 100644 --- a/include/boost/geometry/index/detail/rtree/visitors/spatial_query.hpp +++ b/include/boost/geometry/index/detail/rtree/visitors/spatial_query.hpp @@ -158,7 +158,7 @@ class spatial_query_incremental const_reference dereference() const { - BOOST_GEOMETRY_INDEX_ASSERT(m_values, "not dereferencable"); + BOOST_GEOMETRY_INDEX_ASSERT(m_values, "not dereferenceable"); return *m_current; } @@ -208,7 +208,7 @@ class spatial_query_incremental namespace id = index::detail; for (;;) { - // if leaf is choosen, move to the next value in leaf + // if leaf is chosen, move to the next value in leaf if ( m_values ) { if ( m_current != m_values->end() ) @@ -228,7 +228,7 @@ class spatial_query_incremental m_values = 0; } } - // if leaf isn't choosen, move to the next leaf + // if leaf isn't chosen, move to the next leaf else { // return if there is no more nodes to traverse diff --git a/include/boost/geometry/index/indexable.hpp b/include/boost/geometry/index/indexable.hpp index 84cf05face..337bfdd4d3 100644 --- a/include/boost/geometry/index/indexable.hpp +++ b/include/boost/geometry/index/indexable.hpp @@ -27,7 +27,7 @@ namespace boost { namespace geometry { namespace index { namespace detail { template -struct is_referencable +struct is_referenceable : std::is_same < typename util::remove_cref::type, @@ -126,7 +126,7 @@ struct indexable, false> inline result_type operator()(std::pair const& v) const { BOOST_GEOMETRY_STATIC_ASSERT( - (is_referencable::value), + (is_referenceable::value), "Unexpected type.", std::pair); return v.first; @@ -186,7 +186,7 @@ struct indexable_boost_tuple inline result_type operator()(boost::tuple const& v) const { BOOST_GEOMETRY_STATIC_ASSERT( - (is_referencable::value), + (is_referenceable::value), "Unexpected type.", boost::tuple); return boost::get<0>(v); @@ -202,7 +202,7 @@ struct indexable_boost_tuple inline result_type operator()(boost::tuples::cons const& v) const { BOOST_GEOMETRY_STATIC_ASSERT( - (is_referencable::value), + (is_referenceable::value), "Unexpected type.", boost::tuples::cons); return boost::get<0>(v); @@ -297,7 +297,7 @@ struct indexable, false> inline result_type operator()(std::tuple const& v) const { BOOST_GEOMETRY_STATIC_ASSERT( - (is_referencable::value), + (is_referenceable::value), "Unexpected type.", std::tuple); return std::get<0>(v); @@ -347,7 +347,7 @@ struct indexable /*! \brief Return indexable extracted from the value. Overload for types - compatible with Value but different yet holding referencable + compatible with Value but different yet holding referenceable Indexable, e.g. tuple containing a reference. \param v The value. diff --git a/include/boost/geometry/index/rtree.hpp b/include/boost/geometry/index/rtree.hpp index ec8451f33e..d4454e18f9 100644 --- a/include/boost/geometry/index/rtree.hpp +++ b/include/boost/geometry/index/rtree.hpp @@ -826,7 +826,7 @@ class rtree \warning This operation only guarantees that there will be no memory leaks. After an exception is thrown the R-tree may be left in an inconsistent state, - elements must not be inserted or removed. Other operations are allowed however + elements must not be inserted or removed. Other operations are allowed, however, some of them may return invalid data. */ inline void insert(value_type const& value) @@ -850,7 +850,7 @@ class rtree \warning This operation only guarantees that there will be no memory leaks. After an exception is thrown the R-tree may be left in an inconsistent state, - elements must not be inserted or removed. Other operations are allowed however + elements must not be inserted or removed. Other operations are allowed, however, some of them may return invalid data. */ template diff --git a/include/boost/geometry/srs/projections/proj/imw_p.hpp b/include/boost/geometry/srs/projections/proj/imw_p.hpp index 72ac322f82..2d255ba385 100644 --- a/include/boost/geometry/srs/projections/proj/imw_p.hpp +++ b/include/boost/geometry/srs/projections/proj/imw_p.hpp @@ -183,7 +183,7 @@ namespace projections point_xy t; T yc = 0.0; int i = 0; - const int n_max_iter = 1000; /* Arbitrarily choosen number... */ + const int n_max_iter = 1000; /* Arbitrarily chosen number... */ lp_lat = this->m_proj_parm.phi_2; lp_lon = xy_x / cos(lp_lat); diff --git a/include/boost/geometry/strategies/agnostic/point_in_poly_winding.hpp b/include/boost/geometry/strategies/agnostic/point_in_poly_winding.hpp index b7400d8523..944e34abdb 100644 --- a/include/boost/geometry/strategies/agnostic/point_in_poly_winding.hpp +++ b/include/boost/geometry/strategies/agnostic/point_in_poly_winding.hpp @@ -84,7 +84,7 @@ struct winding_base_type /*! \brief Within detection using winding rule. Side strategy used internally is - choosen based on Point's coordinate system. + chosen based on Point's coordinate system. \ingroup strategies \tparam Point \tparam_point \tparam PointOfSegment \tparam_segment_point diff --git a/include/boost/geometry/strategies/cartesian/point_in_poly_crossings_multiply.hpp b/include/boost/geometry/strategies/cartesian/point_in_poly_crossings_multiply.hpp index dda6dc0ad9..2aa5121cf1 100644 --- a/include/boost/geometry/strategies/cartesian/point_in_poly_crossings_multiply.hpp +++ b/include/boost/geometry/strategies/cartesian/point_in_poly_crossings_multiply.hpp @@ -32,7 +32,7 @@ namespace strategy { namespace within { /*! -\brief Within detection using cross counting, +\brief Within detection using cross counting \ingroup strategies \tparam CalculationType \tparam_calculation \see http://tog.acm.org/resources/GraphicsGems/gemsiv/ptpoly_haines/ptinpoly.c diff --git a/include/boost/geometry/views/closeable_view.hpp b/include/boost/geometry/views/closeable_view.hpp index c3c4b14085..bae992679f 100644 --- a/include/boost/geometry/views/closeable_view.hpp +++ b/include/boost/geometry/views/closeable_view.hpp @@ -93,7 +93,7 @@ struct closed_view The closeable_view might be used by library users, but its main purpose is internally. \tparam Range Original range -\tparam Close Specifies if it the range is closed, if so, nothing will happen. +\tparam Close Specifies if the range is closed, if so, nothing will happen. If it is open, it will iterate the first point after the last point. \ingroup views */