Class: Google::Apis::SheetsV4::OverlayPosition

Inherits:
Object
  • Object
show all
Includes:
Core::Hashable, Core::JsonObjectSupport
Defined in:
generated/google/apis/sheets_v4/classes.rb,
generated/google/apis/sheets_v4/representations.rb,
generated/google/apis/sheets_v4/representations.rb

Overview

The location an object is overlaid on top of a grid.

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from Core::JsonObjectSupport

#to_json

Methods included from Core::Hashable

process_value, #to_h

Constructor Details

#initialize(**args) ⇒ OverlayPosition

Returns a new instance of OverlayPosition



2827
2828
2829
# File 'generated/google/apis/sheets_v4/classes.rb', line 2827

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#anchor_cellGoogle::Apis::SheetsV4::GridCoordinate

A coordinate in a sheet. All indexes are zero-based. Corresponds to the JSON property anchorCell



2814
2815
2816
# File 'generated/google/apis/sheets_v4/classes.rb', line 2814

def anchor_cell
  @anchor_cell
end

#height_pixelsFixnum

The height of the object, in pixels. Defaults to 371. Corresponds to the JSON property heightPixels

Returns:

  • (Fixnum)


2825
2826
2827
# File 'generated/google/apis/sheets_v4/classes.rb', line 2825

def height_pixels
  @height_pixels
end

#offset_x_pixelsFixnum

The horizontal offset, in pixels, that the object is offset from the anchor cell. Corresponds to the JSON property offsetXPixels

Returns:

  • (Fixnum)


2808
2809
2810
# File 'generated/google/apis/sheets_v4/classes.rb', line 2808

def offset_x_pixels
  @offset_x_pixels
end

#offset_y_pixelsFixnum

The vertical offset, in pixels, that the object is offset from the anchor cell. Corresponds to the JSON property offsetYPixels

Returns:

  • (Fixnum)


2820
2821
2822
# File 'generated/google/apis/sheets_v4/classes.rb', line 2820

def offset_y_pixels
  @offset_y_pixels
end

#width_pixelsFixnum

The width of the object, in pixels. Defaults to 600. Corresponds to the JSON property widthPixels

Returns:

  • (Fixnum)


2802
2803
2804
# File 'generated/google/apis/sheets_v4/classes.rb', line 2802

def width_pixels
  @width_pixels
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



2832
2833
2834
2835
2836
2837
2838
# File 'generated/google/apis/sheets_v4/classes.rb', line 2832

def update!(**args)
  @width_pixels = args[:width_pixels] if args.key?(:width_pixels)
  @offset_x_pixels = args[:offset_x_pixels] if args.key?(:offset_x_pixels)
  @anchor_cell = args[:anchor_cell] if args.key?(:anchor_cell)
  @offset_y_pixels = args[:offset_y_pixels] if args.key?(:offset_y_pixels)
  @height_pixels = args[:height_pixels] if args.key?(:height_pixels)
end