toJson method

Map<String, Object?> toJson()

Implementation

Map<String, Object?> toJson() => {
      'glintId': glintId,
      'logicalCenter': {'x': logicalCenter.x, 'y': logicalCenter.y},
      'logicalBounds': {
        'x': logicalBounds.x,
        'y': logicalBounds.y,
        'w': logicalBounds.w,
        'h': logicalBounds.h,
      },
      'devicePixelRatio': devicePixelRatio,
      'logicalViewSize': {
        'w': logicalViewSize.w,
        'h': logicalViewSize.h,
      },
      'physicalCenter': {'x': physicalCenter.x, 'y': physicalCenter.y},
      'nearestAncestorOpacity': nearestAncestorOpacity,
      'nearestAncestorVisible': nearestAncestorVisible,
      'painted': painted,
      'hittable': hittable,
      'hitTest': hitTestReal ? 'real' : 'approximate',
      if (hitBy != null) 'hitBy': hitBy,
      if (clip != null) 'clip': {'x': clip!.x, 'y': clip!.y, 'w': clip!.w, 'h': clip!.h},
      if (keyboardInset > 0) 'keyboardInset': keyboardInset,
    };