Description

class Axlsx::Pic

a Pic object represents an image in your worksheet Worksheet#add_image is the recommended way to manage images in your sheets

Creates a new Pic(ture) object

Parameters:

  • anchor (Anchor)

    the anchor that holds this image

  • options (Hash) (defaults to: {})

    a customizable set of options

Options Hash (options):

  • name (String)
  • descr (String)
  • image_src (String)
  • start_at (Array)
  • width (Intger)
  • height (Intger)

Yields:

  • (_self)

Yield Parameters:

  • _self (Axlsx::Pic)

    the object that the method was called on

The anchor for this image

A description of the picture

noop if not using a two cell anchor

Parameters:

  • x (Integer)

    The column

  • y (Integer) (defaults to: nil)

    The row

returns the extension of image_src without the preceeding '.'

The file name of image_src without any path information

Note:

this is a noop if you are using a TwoCellAnchor

providing access to update the anchor's height attribute

Parameters:

  • v (Integer)
Note:

This is a noop if you are using a TwoCellAnchor

Returns the value of attribute hyperlink

The path to the image you want to include Only local images are supported at this time.

The index of this image in the workbooks images collections

The name to use for this picture

The picture locking attributes for this picture

The part name for this image used in serialization and relationship building

The relationship object for this pic.

This is a short cut method to set the start anchor position If you need finer granularity in positioning use graphic_frame.anchor.from.colOff / rowOff

Parameters:

  • x (Integer)

    The column

  • y (Integer) (defaults to: nil)

    The row

refactoring of swapping code, law of demeter be damned!

Serializes the object

Parameters:

  • str (String) (defaults to: '')

Changes the anchor to a one cell anchor.

changes the anchor type to a two cell anchor

providing access to the anchor's width attribute

Parameters:

  • v (Integer)

Pic is referenced in 0 repositories