| 118 | } |
| 119 | |
| 120 | QList<int> GcodePreprocessorUtils::parseMCodes(QString command) |
| 121 | { |
| 122 | static QRegExp re("[Mm]0*(\\d+)"); |
| 123 | |
| 124 | QList<int> codes; |
| 125 | int pos = 0; |
| 126 | |
| 127 | while ((pos = re.indexIn(command, pos)) != -1) { |
| 128 | codes.append(re.cap(1).toInt()); |
| 129 | pos += re.matchedLength(); |
| 130 | } |
| 131 | |
| 132 | return codes; |
| 133 | } |
| 134 | |
| 135 | /** |
| 136 | * Update a point given the arguments of a command. |
nothing calls this directly
no outgoing calls
no test coverage detected