Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 7 additions & 7 deletions libraries/radpdfprocessing/concepts/clipping.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,9 +28,9 @@ __Example 1__ demonstrates how you can create a Clipping element and assign a __

#### __[C#] Example 1: Create clipping__

{{region radpdfprocessing-concepts-clipping_0}}
Clipping clipping = new Clipping();
clipping.Clip = new RectangleGeometry(new Rect(5, 5, 50, 50));
{{region cs-radpdfprocessing-concepts-clipping_0}}
Clipping clipping = new Clipping();
clipping.Clip = new RectangleGeometry(new Rect(5, 5, 50, 50));
{{endregion}}


Expand All @@ -45,13 +45,13 @@ __Example 2__ demonstrates how to clip an image using the Clipping created in __

#### __[C#] Example 2: Use clipping__

{{region radpdfprocessing-concepts-clipping_1}}
Image image = container.Content.AddImage(imageSource);
image.Clipping = clipping;
{{region cs-radpdfprocessing-concepts-clipping_1}}
Image image = container.Content.AddImage(imageSource);
image.Clipping = clipping;
{{endregion}}



# See Also
## See Also

* [Geometry]({%slug radpdfprocessing-concepts-geometry%})
53 changes: 26 additions & 27 deletions libraries/radpdfprocessing/concepts/colors-and-color-spaces.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,10 +41,10 @@ __Example 1__ demonstrates how you can create an RgbColor and assign it as Fill

#### __[C#] Example 1: Create RgbColor__

{{region radpdfprocessing-concepts-colors-and-color-spaces_0}}
RgbColor magenta = new RgbColor(255, 0, 255);
Path path = new Path();
path.Fill = magenta;
{{region cs-radpdfprocessing-concepts-colors-and-color-spaces_0}}
RgbColor magenta = new RgbColor(255, 0, 255);
Path path = new Path();
path.Fill = magenta;
{{endregion}}


Expand Down Expand Up @@ -83,15 +83,15 @@ The __Gradient__ class is inherited by the following classes:

#### __[C#] Example 2: Create LinearGradient__

{{region radpdfprocessing-concepts-colors-and-color-spaces_1}}
FixedContentEditor containerEditor = new FixedContentEditor(container);

LinearGradient linearGradient = new LinearGradient(new Point(0, 0), new Point(30, 30));
linearGradient.GradientStops.Add(new GradientStop(new RgbColor(0, 207, 0), 0));
linearGradient.GradientStops.Add(new GradientStop(new RgbColor(0, 102, 204), 1));

containerEditor.GraphicProperties.FillColor = linearGradient;
containerEditor.DrawRectangle(new Rect(10, 10, 48, 29));
{{region cs-radpdfprocessing-concepts-colors-and-color-spaces_1}}
FixedContentEditor containerEditor = new FixedContentEditor(container);
LinearGradient linearGradient = new LinearGradient(new Point(0, 0), new Point(30, 30));
linearGradient.GradientStops.Add(new GradientStop(new RgbColor(0, 207, 0), 0));
linearGradient.GradientStops.Add(new GradientStop(new RgbColor(0, 102, 204), 1));
containerEditor.GraphicProperties.FillColor = linearGradient;
containerEditor.DrawRectangle(new Rect(10, 10, 48, 29));
{{endregion}}


Expand All @@ -114,8 +114,7 @@ The __Gradient__ class is inherited by the following classes:

#### __[C#] Example 3: Create RadialGradient__

{{region radpdfprocessing-concepts-colors-and-color-spaces_3}}

{{region cs-radpdfprocessing-concepts-colors-and-color-spaces_3}}
FixedContentEditor containerEditor = new FixedContentEditor(container);

RadialGradient radialGradient = new RadialGradient(new Point(40, 40), new Point(40, 40), 0, 30);
Expand Down Expand Up @@ -169,17 +168,17 @@ Since the __TilingBase__ class implements the __IContentRootElement__ interface

#### __[C#] Example 4: Create tiling__

{{region radpdfprocessing-concepts-colors-and-color-spaces_2}}
FixedContentEditor containerEditor = new FixedContentEditor(container);

Tiling tiling = new Tiling(new Rect(0, 0, 10, 10));
FixedContentEditor tilingEditor = new FixedContentEditor(tiling);
tilingEditor.GraphicProperties.IsStroked = false;
tilingEditor.GraphicProperties.FillColor = new RgbColor(128, 28, 43);
tilingEditor.DrawRectangle(new Rect(2, 2, 5, 7));

containerEditor.GraphicProperties.FillColor = tiling;
containerEditor.DrawCircle(new Point(30, 30), 20);
{{region cs-radpdfprocessing-concepts-colors-and-color-spaces_2}}
FixedContentEditor containerEditor = new FixedContentEditor(container);
Tiling tiling = new Tiling(new Rect(0, 0, 10, 10));
FixedContentEditor tilingEditor = new FixedContentEditor(tiling);
tilingEditor.GraphicProperties.IsStroked = false;
tilingEditor.GraphicProperties.FillColor = new RgbColor(128, 28, 43);
tilingEditor.DrawRectangle(new Rect(2, 2, 5, 7));
containerEditor.GraphicProperties.FillColor = tiling;
containerEditor.DrawCircle(new Point(30, 30), 20);
{{endregion}}


Expand All @@ -190,7 +189,7 @@ The tiling created in __Example 4__ is shown in __Figure 3__.
#### Figure 3: Tiling
![Rad Pdf Processing Concepts Colors And Color Spaces 02](images/RadPdfProcessing_Concepts_Colors_And_Color_Spaces_02.png)

# See Also
## See Also

* [Path]({%slug radpdfprocessing-model-path%})
* [FixedContentEditor]({%slug radpdfprocessing-editing-fixedcontenteditor%})
12 changes: 6 additions & 6 deletions libraries/radpdfprocessing/concepts/fonts.md
Original file line number Diff line number Diff line change
Expand Up @@ -50,8 +50,8 @@ __Example 1__ demonstrates how you can use the RegisterFont() method.

#### __[C#] Example 1: Register font__

{{region radpdfprocessing-concepts-fonts_0}}
FontsRepository.RegisterFont(fontFamily, fontStyle, fontWeight, data);
{{region cs-radpdfprocessing-concepts-fonts_0}}
FontsRepository.RegisterFont(fontFamily, fontStyle, fontWeight, data);
{{endregion}}


Expand All @@ -66,9 +66,9 @@ __Example 2__ shows how to create a font using the FontsRepository.

#### __[C#] Example 2: Create FontBase__

{{region radpdfprocessing-concepts-fonts_1}}
FontBase font;
bool success = FontsRepository.TryCreateFont(fontFamily, fontStyle, fontWeight, out font);
{{region cs-radpdfprocessing-concepts-fonts_1}}
FontBase font;
bool success = FontsRepository.TryCreateFont(fontFamily, fontStyle, fontWeight, out font);
{{endregion}}


Expand All @@ -78,7 +78,7 @@ __Example 2__ shows how to create a font using the FontsRepository.



# See Also
## See Also
* [FontsRepository](http://docs.telerik.com/devtools/document-processing/api/html/T_Telerik_Windows_Documents_Fixed_Model_Fonts_FontsRepository.htm)
* [TextFragment]({%slug radpdfprocessing-model-textfragment%})

30 changes: 15 additions & 15 deletions libraries/radpdfprocessing/concepts/geometry.md
Original file line number Diff line number Diff line change
Expand Up @@ -48,9 +48,9 @@ __Example 1__ shows hot to create a RectangleGeometry.

#### __[C#] Example 1: Create RectangleGeometry__

{{region radpdfprocessing-concepts-geometry_0}}
RectangleGeometry rectangleGeometry = new RectangleGeometry();
rectangleGeometry.Rect = new Rect(10, 5, 400, 300);
{{region cs-radpdfprocessing-concepts-geometry_0}}
RectangleGeometry rectangleGeometry = new RectangleGeometry();
rectangleGeometry.Rect = new Rect(10, 5, 400, 300);
{{endregion}}


Expand All @@ -73,17 +73,17 @@ __Example 2__ shows how to create a PathGeometry, which consists of line segment

#### __[C#] Example 2: Create PathGeometry__

{{region radpdfprocessing-concepts-geometry_1}}
PathGeometry pathGeometry = new PathGeometry();
PathFigure pathFigure = pathGeometry.Figures.AddPathFigure();
pathFigure.StartPoint = new Point(5, 5);
LineSegment lineSegment = pathFigure.Segments.AddLineSegment();
lineSegment.Point = new Point(205, 5);
BezierSegment bezierSegment = pathFigure.Segments.AddBezierSegment();
bezierSegment.Point1 = new Point(105, 50);
bezierSegment.Point2 = new Point(130, 105);
bezierSegment.Point3 = new Point(100, 200);
pathFigure.IsClosed = true;
{{region cs-radpdfprocessing-concepts-geometry_1}}
PathGeometry pathGeometry = new PathGeometry();
PathFigure pathFigure = pathGeometry.Figures.AddPathFigure();
pathFigure.StartPoint = new Point(5, 5);
LineSegment lineSegment = pathFigure.Segments.AddLineSegment();
lineSegment.Point = new Point(205, 5);
BezierSegment bezierSegment = pathFigure.Segments.AddBezierSegment();
bezierSegment.Point1 = new Point(105, 50);
bezierSegment.Point2 = new Point(130, 105);
bezierSegment.Point3 = new Point(100, 200);
pathFigure.IsClosed = true;
{{endregion}}


Expand Down Expand Up @@ -158,7 +158,7 @@ Represents an elliptical arc between two points. The __ArcSegment__ exposes the

* __RotationAngle__: Specifies the amount (in degrees) by which the ellipse is rotated about the x-axis.

# See Also
## See Also

* [Path]({%slug radpdfprocessing-model-path%})
* [FixedContentEditor]({%slug radpdfprocessing-editing-fixedcontenteditor%})
8 changes: 4 additions & 4 deletions libraries/radpdfprocessing/concepts/imagequality.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,9 +34,9 @@ In order to specify the default **ImageQuality** value when exporting to PDF, yo

#### __[C#] Example 1: Set a default value for all images in a document__

{{region radpdfprocessing-concepts-imagequality_0}}
{{region cs-radpdfprocessing-concepts-imagequality_0}}
PdfExportSettings settings = new PdfExportSettings();
settings.ImageQuality = ImageQuality.Medium;
settings.ImageQuality = ImageQuality.Medium;
{{endregion}}


Expand All @@ -46,7 +46,7 @@ If you need some particular image to be exported with a different **ImageQuality

#### __[C#] Example 2: Set the image quality of an image__

{{region radpdfprocessing-concepts-imagequality_1}}
{{region cs-radpdfprocessing-concepts-imagequality_1}}
ImageSource imageSource = new ImageSource(bitmap, ImageQuality.Medium);
{{endregion}}

Expand All @@ -62,7 +62,7 @@ When **ImageQuality** of an image is set to **High**, **RadPdfProcessing** inter

> JPEG2000 images in **RadPdfProcessing** can be inserted only with **ImageQuality.High**. Exporting them with lower ImageQuality value requires decoding JPEG2000 files, which is currently unsupported by the library.

# See also
## See also

* [ImageQuality API Reference](http://docs.telerik.com/devtools/document-processing/api/html/T_Telerik_Windows_Documents_Fixed_FormatProviders_Pdf_Export_ImageQuality.htm)
* [ImageSource]({%slug radpdfprocessing-model-imagesource%})
Expand Down
18 changes: 9 additions & 9 deletions libraries/radpdfprocessing/concepts/position.md
Original file line number Diff line number Diff line change
Expand Up @@ -63,10 +63,10 @@ __Example 1__ shows how transformations can be appended.

#### __[C#] Example 1: Trasform MatrixPosition__

{{region radpdfprocessing-concepts-position_0}}
MatrixPosition matrixPosition = new MatrixPosition();
matrixPosition.Translate(20, 20); // Translates the position by (20, 20)
matrixPosition.Translate(30, 30); // Translates the position by (30, 30).
{{region cs-radpdfprocessing-concepts-position_0}}
MatrixPosition matrixPosition = new MatrixPosition();
matrixPosition.Translate(20, 20); // Translates the position by (20, 20)
matrixPosition.Translate(30, 30); // Translates the position by (30, 30).
{{endregion}}


Expand All @@ -92,18 +92,18 @@ __Example 2__ shows how transformations overwrite the previous transformations o

#### __[C#] Example 2: Transform SimplePosition__

{{region radpdfprocessing-concepts-position_1}}
SimplePosition simplePosition = new SimplePosition();
simplePosition.Translate(20, 20); // Translates the position by (30, 30).
simplePosition.Translate(30, 30); // Translates the position by (20, 20) overwriting the previous translations.
{{region cs-radpdfprocessing-concepts-position_1}}
SimplePosition simplePosition = new SimplePosition();
simplePosition.Translate(20, 20); // Translates the position by (30, 30).
simplePosition.Translate(30, 30); // Translates the position by (20, 20) overwriting the previous translations.
{{endregion}}



The resulting simple position was translated both horizontally and vertically by 30, because of the transformation overwriting.


# See Also
## See Also

* [Model]({%slug radpdfprocessing-model-general-information%})
* [FixedContentEditor]({%slug radpdfprocessing-editing-fixedcontenteditor%})
34 changes: 18 additions & 16 deletions libraries/radpdfprocessing/editing/block.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,9 +27,9 @@ Inserting [TextFragments]({%slug radpdfprocessing-model-textfragment%}) is achie

#### __[C#] Example 1: Insert text__

{{region radpdfprocessing-editing-block_0}}
Block block = new Block();
block.InsertText("Text");
{{region cs-radpdfprocessing-editing-block_0}}
Block block = new Block();
block.InsertText("Text");
{{endregion}}


Expand All @@ -39,8 +39,8 @@ __Example 2__ demonstrates how to insert text with a specific font family.

#### __[C#] Example 2: Insert text with Arial font family__

{{region radpdfprocessing-editing-block_1}}
block.InsertText(new FontFamily("Arial"), "Text");
{{region cs-radpdfprocessing-editing-block_1}}
block.InsertText(new FontFamily("Arial"), "Text");
{{endregion}}


Expand All @@ -54,8 +54,8 @@ Inserting a line break results in the next element starting on a new line. The a

#### __[C#] Example 3: Break the line__

{{region radpdfprocessing-editing-block_3}}
block.InsertLineBreak();
{{region cs-radpdfprocessing-editing-block_3}}
block.InsertLineBreak();
{{endregion}}


Expand Down Expand Up @@ -165,9 +165,9 @@ __Example 4__ demonstrates how to draw a block.

#### __[C#] Example 4: Draw block__

{{region radpdfprocessing-editing-block_4}}
Rect boundingRect = new Rect(new Point(0, 0), new Size(200, 300));
block.Draw(fixedContentEditor, boundingRect);
{{region cs-radpdfprocessing-editing-block_4}}
Rect boundingRect = new Rect(new Point(0, 0), new Size(200, 300));
block.Draw(fixedContentEditor, boundingRect);
{{endregion}}


Expand All @@ -188,10 +188,10 @@ __Example 5__ creates a Block with the text "Hello RadPdfProcessing!" and measur

#### __[C#] Example 5: Measure block__

{{region radpdfprocessing-editing-block_5}}
Block block = new Block();
block.InsertText("Hello RadPdfProcessing!");
Size size = block.Measure();
{{region cs-radpdfprocessing-editing-block_5}}
Block block = new Block();
block.InsertText("Hello RadPdfProcessing!");
Size size = block.Measure();
{{endregion}}


Expand All @@ -205,7 +205,7 @@ The code in __Example 6__ splits a block in two. The first will contains text "H

#### __[C#] Example 6: Split block__

{{region radpdfprocessing-editing-block_6}}
{{region cs-radpdfprocessing-editing-block_6}}
Block helloBlock = new Block();
helloBlock.InsertText("Hello");
Size helloSize = helloBlock.Measure();
Expand All @@ -215,7 +215,9 @@ The code in __Example 6__ splits a block in two. The first will contains text "H
Size size = block.Measure(helloSize);
Block secondBlock = block.Split();
{{endregion}}
# See Also


## See Also

* [FixedContentEditor]({%slug radpdfprocessing-editing-fixedcontenteditor%})
* [TextFragment]({%slug radpdfprocessing-model-textfragment%})
Expand Down
Loading