[]
        
(Showing Draft Content)

GrapeCity.Documents.Drawing.GcGraphics.PushClip

PushClip Method

PushClip(RectangleF, RectangleF)

Specifies a rectangle to which all subsequent drawing operations are clipped. Clipping is applied only if containerRect does not contain clipRect.

The GcGraphics.Clip object returned by this method implements IDisposable, so this method can be used with the 'using' pattern:

using (g.PushClip(...)) ...

in which case the clipping region will be removed when the returned object is disposed.

Declaration
public GcGraphics.Clip PushClip(RectangleF clipRect, RectangleF containerRect)
Public Function PushClip(clipRect As RectangleF, containerRect As RectangleF) As GcGraphics.Clip
Parameters
Type Name Description
RectangleF clipRect

The clipping rectangle.

RectangleF containerRect

The container rectangle.

Returns
Type Description
GcGraphics.Clip

The GcGraphics.Clip object that removes the clipping when disposed.

PushClip(RectangleF?)

Specifies a rectangle to which all subsequent drawing operations are clipped.

The GcGraphics.Clip object returned by this method implements IDisposable, so this method can be used with the 'using' pattern:

using (g.PushClip(...)) ...

in which case the clipping region will be removed when the returned object is disposed.

Declaration
public GcGraphics.Clip PushClip(RectangleF? clipRect)
Public Function PushClip(clipRect As RectangleF?) As GcGraphics.Clip
Parameters
Type Name Description
RectangleF? clipRect

The clipping rectangle. If this parameter is null, this method does nothing and returns null.

Returns
Type Description
GcGraphics.Clip

The GcGraphics.Clip object that removes the clipping when disposed, or null.

PushClip(RectangleF)

Specifies a rectangle to which all subsequent drawing operations are clipped.

The GcGraphics.Clip object returned by this method implements IDisposable, so this method can be used with the 'using' pattern:

using (g.PushClip(...)) ...

in which case the clipping region will be removed when the returned object is disposed.

Declaration
public GcGraphics.Clip PushClip(RectangleF clipRect)
Public Function PushClip(clipRect As RectangleF) As GcGraphics.Clip
Parameters
Type Name Description
RectangleF clipRect

The clipping rectangle.

Returns
Type Description
GcGraphics.Clip

The GcGraphics.Clip object that removes the clipping when disposed.

PushClip(IPath)

Specifies a path to which all subsequent drawing operations are clipped.

The GcGraphics.Clip object returned by this method implements IDisposable, so this method can be used with the 'using' pattern:

using (g.PushClip(...)) ...

in which case the clipping region will be removed when the returned object is disposed.

Declaration
public GcGraphics.Clip PushClip(IPath clipPath)
Public Function PushClip(clipPath As IPath) As GcGraphics.Clip
Parameters
Type Name Description
IPath clipPath

The IPath object defining clipping area.

Returns
Type Description
GcGraphics.Clip

The GcGraphics.Clip object that removes the clipping when disposed.

PushClip(IClipRegion)

Specifies a clipping region to which all subsequent drawing operations are clipped.

Declaration
public void PushClip(IClipRegion clipRegion)
Public Sub PushClip(clipRegion As IClipRegion)
Parameters
Type Name Description
IClipRegion clipRegion

The clipping region.