MCPcopy Create free account
hub / github.com/OpenOrienteering/mapper / findObjectsAt

Method findObjectsAt

src/core/map_part.cpp:251–272  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

249}
250
251void MapPart::findObjectsAt(
252 const MapCoordF& coord,
253 qreal tolerance,
254 bool treat_areas_as_paths,
255 bool extended_selection,
256 bool include_hidden_objects,
257 bool include_protected_objects,
258 SelectionInfoVector& out ) const
259{
260 for (Object* object : objects)
261 {
262 if (!include_hidden_objects && object->getSymbol()->isHidden())
263 continue;
264 if (!include_protected_objects && object->getSymbol()->isProtected())
265 continue;
266
267 object->update();
268 int selected_type = object->isPointOnObject(coord, tolerance, treat_areas_as_paths, extended_selection);
269 if (selected_type != (int)Symbol::NoSymbol)
270 out.emplace_back(selected_type, object);
271 }
272}
273
274void MapPart::findObjectsAtBox(
275 const MapCoordF& corner1,

Callers

nothing calls this directly

Calls 5

isHiddenMethod · 0.80
isProtectedMethod · 0.80
isPointOnObjectMethod · 0.80
getSymbolMethod · 0.45
updateMethod · 0.45

Tested by

no test coverage detected