TechDraw: apply std::ranges
This commit is contained in:
@@ -331,7 +331,7 @@ std::string DrawViewSpreadsheet::getSheetImage()
|
||||
cell->getAlignment(alignment);
|
||||
}
|
||||
// skip cell if found in skiplist
|
||||
if (std::find(skiplist.begin(), skiplist.end(), address.toString()) == skiplist.end()) {
|
||||
if (std::ranges::find(skiplist, address.toString()) == skiplist.end()) {
|
||||
result << " <rect x=\"" << coloffset << "\" y=\"" << rowoffset << "\" width=\""
|
||||
<< cellwidth << "\" height=\"" << cellheight << "\" style=\"fill:" << bcolor
|
||||
<< ";stroke-width:" << LineWidth.getValue() / getScale()
|
||||
@@ -388,7 +388,7 @@ std::string DrawViewSpreadsheet::getSheetImage()
|
||||
int DrawViewSpreadsheet::colInList(const std::vector<std::string>& list,
|
||||
const std::string& toFind)
|
||||
{
|
||||
auto match = std::find(std::begin(list), std::end(list), toFind);
|
||||
const auto match = std::ranges::find(list, toFind);
|
||||
if (match == std::end(list)) {
|
||||
return -1; // Error value
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user