CadDrawingDiff
from OpenCAD2D import CadDrawingDiff
class CadDrawingDiff(System.Object) ยท CadDrawingDiff in the .NET reference
Compares two drawings object by object, by handle: what was added, what was removed and what changed, with the names of the properties that differ and how far an object moved. It reads each drawing as CadDrawingJson writes it (every entity walked down to its shapes, in millimetres), so a block's pieces are told apart by their index path and a drawing in inches is compared with one in millimetres as the same thing. It is meant for two states of one drawing: a file and the file after an edit, a dump of the app and the app now. Two drawings that were drawn separately share no handles and every object of one is added or removed.
Methods
Compare
@staticmethod
def Compare(before: CadDocument, after: CadDocument, tolerance: Tolerance) -> CadDrawingDiffResult
Compares two drawings: all their layouts, model space included. Two lines of one handle whose end moved 3 mm come out as one changed object with end and box among its properties.