MCPcopy Create free account
hub / github.com/Schildkroet/Candle2 / parseCoord

Method parseCoord

src/parser/gcodepreprocessorutils.cpp:310–323  ·  view source on GitHub ↗

TODO: Replace everything that uses this with a loop that loops through the string and creates a hash with all the values.

Source from the content-addressed store, hash-verified

308// TODO: Replace everything that uses this with a loop that loops through
309// the string and creates a hash with all the values.
310double GcodePreprocessorUtils::parseCoord(QStringList argList, char c)
311{
312// int n = argList.length();
313
314// for (int i = 0; i < n; i++) {
315// if (argList[i].length() > 0 && argList[i][0].toUpper() == c) return argList[i].mid(1).toDouble();
316// }
317
318 foreach (QString t, argList)
319 {
320 if (t.length() > 0 && t[0].toUpper() == c) return t.mid(1).toDouble();
321 }
322 return qQNaN();
323}
324
325//static public List<String> convertArcsToLines(Point3d start, Point3d end) {
326// List<String> l = new ArrayList<String>();

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected