Inherits from GSElement : NSObject

Overview

GSBackgroundImage: The class defining the image

It is a subclass of GSElement

Properties

crop

The Crop

@property (assign, nonatomic) NSRect crop

image

the NSImage

@property (strong, nonatomic) NSImage *image

imagePath

the image path

@property (strong, nonatomic) NSString *imagePath

locked

if the image is locked

@property (assign, nonatomic) BOOL locked

transformStruct

The transformation of the component.

@property (assign, nonatomic) NSAffineTransformStruct transformStruct

Discussion

The values of the struct are: {m11, m12, m21, m22, tX, tY} this is equivalent to the glif attributes {xScale, xyScale, yxScale, yScale, xOffset, yOffset} in the same order. The initial value is {1,0,0,1,0,0}.

Instance Methods

initWithPath:

Inits with a path

- (instancetype)initWithPath:(NSString *)Path

Parameters

Path

the Path

initWithURL:

Inits with a NSURL

- (instancetype)initWithURL:(NSURL *)URL

Parameters

URL

the URL

setScaleX:scaleY:rotation:

Sets the transfomration from scale and angel values

- (void)setScaleX:(CGFloat)sX scaleY:(CGFloat)sY rotation:(CGFloat)R

Parameters

sX

the horizontal scale value

sY

the vertical scale value

R

the angle in degree

showInFinder:

Shows the image in the Finder

- (void)showInFinder:(id)sender

toggleLocked

toggle locked

- (void)toggleLocked