C# Class ImageResizer.FluentExtensions.StyleExpression

As expression for configuring image style options
Inheritance: ImageUrlBuilderExpression
Show file Open project: benfoster/ImageResizer.FluentExtensions

Public Methods

Method Description
BackgroundColor ( string backgroundColor ) : StyleExpression

Sets the background/whitespace color.

BorderColor ( string borderColor ) : StyleExpression

Sets the border color

BorderWidth ( int borderWidth ) : StyleExpression

Sets the width of the image border

DropShadow ( int shadowWidth, string shadowColor ) : DropShadowExpression

Adds a drop shadow to the image. Requires the drop shadow plugin. For more information see http://imageresizing.net/plugins/dropshadow.

Margin ( int width ) : StyleExpression

Sets a universal margin for the image

Margin ( int left, int top, int right, int bottom ) : StyleExpression

Sets the left, top, right and bottom margin widths

PaddingColor ( string paddingColor ) : StyleExpression

Sets the padding color (defaults to background color)

PaddingWidth ( int paddingWidth ) : StyleExpression

Sets the padding width

Private Methods

Method Description
StyleExpression ( ImageUrlBuilder builder ) : System

Method Details

BackgroundColor() public method

Sets the background/whitespace color.
public BackgroundColor ( string backgroundColor ) : StyleExpression
backgroundColor string Either a color name or 6 character hex code e.g. FFFFFF
return StyleExpression

BorderColor() public method

Sets the border color
public BorderColor ( string borderColor ) : StyleExpression
borderColor string Either a color name or 6 character hex code e.g. FFFFFF
return StyleExpression

BorderWidth() public method

Sets the width of the image border
public BorderWidth ( int borderWidth ) : StyleExpression
borderWidth int The desired width in pixels
return StyleExpression

DropShadow() public method

Adds a drop shadow to the image. Requires the drop shadow plugin. For more information see http://imageresizing.net/plugins/dropshadow.
public DropShadow ( int shadowWidth, string shadowColor ) : DropShadowExpression
shadowWidth int The desired shadow width in pixels. 1
shadowColor string Configure the shade and opacity of the drop-shadow black|rrggbbaa
return DropShadowExpression

Margin() public method

Sets a universal margin for the image
public Margin ( int width ) : StyleExpression
width int The desired margin size in pixels
return StyleExpression

Margin() public method

Sets the left, top, right and bottom margin widths
public Margin ( int left, int top, int right, int bottom ) : StyleExpression
left int
top int
right int
bottom int
return StyleExpression

PaddingColor() public method

Sets the padding color (defaults to background color)
public PaddingColor ( string paddingColor ) : StyleExpression
paddingColor string Either a color name or 6 character hex code e.g. FFFFFF
return StyleExpression

PaddingWidth() public method

Sets the padding width
public PaddingWidth ( int paddingWidth ) : StyleExpression
paddingWidth int The desired width in pixels
return StyleExpression