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

Method getSelectionToSymbolCompatibility

src/core/map.cpp:909–928  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

907
908
909void Map::getSelectionToSymbolCompatibility(const Symbol* symbol, bool& out_compatible, bool& out_different) const
910{
911 out_compatible = symbol && !object_selection.empty();
912 out_different = false;
913
914 if (symbol)
915 {
916 for (const Object* object : object_selection)
917 {
918 if (!symbol->isTypeCompatibleTo(object))
919 {
920 out_compatible = false;
921 out_different = true;
922 return;
923 }
924 else if (symbol != object->getSymbol())
925 out_different = true;
926 }
927 }
928}
929
930void Map::deleteSelectedObjects()
931{

Calls 3

isTypeCompatibleToMethod · 0.80
emptyMethod · 0.45
getSymbolMethod · 0.45

Tested by

no test coverage detected