code: function ListView_convertCoordinatesByCanvasMargins(coordinates, conversionCallback) {
                      function fix(field, offset) {
                          if (coordinates[field] !== undefined) {
                              coordinates[field] = conversionCallback(coordinates[field], offset);
                          }
                      }
  
                      var offset;
                      if (this._horizontal()) {
                          offset = this._getCanvasMargins()[this._rtl() ? "right" : "left"];
                          fix("left", offset);
                      } else {
                          offset = this._getCanvasMargins().top;
                          fix("top", offset);
                      }
                      fix("begin", offset);
                      fix("end", offset);
  
                      return coordinates;
                  }
docs: Convert between canvas coordinates and viewport coordinates