API Reference
BarcodeBuilder
Fluent barcode builder returned by BarcodeOptions).
Inheritance
- Object
- BarcodeBuilder
Usage
This type appears in these public API surfaces even when no hand-authored example is attached directly to the page.
Returned or exposed by
- Method Barcode.Create
- Method BarcodeBuilder.WithBackground
- Method BarcodeBuilder.WithColors
- Method BarcodeBuilder.WithForeground
- Method BarcodeBuilder.WithHeight
- Method BarcodeBuilder.WithIcoPreserveAspectRatio
- Method BarcodeBuilder.WithIcoSizes
- Method BarcodeBuilder.WithJpegOptions
- Method BarcodeBuilder.WithJpegQuality
- Method BarcodeBuilder.WithLabel
- Method BarcodeBuilder.WithLabelColor
- Method BarcodeBuilder.WithLabelFontFamily
- Method BarcodeBuilder.WithLabelFontSize
- Method BarcodeBuilder.WithLabelMargin
- Method BarcodeBuilder.WithModuleSize
- Method BarcodeBuilder.WithOptions
- Method BarcodeBuilder.WithQuietZone
- Method BarcodeBuilder.WithTransparentBackground
Methods
public RenderedOutput Render(OutputFormat format, RenderExtras extras = null) #RenderedOutputRenders the configured barcode to the requested output format.
Parameters
- format CodeGlyphX.Rendering.OutputFormat
- extras CodeGlyphX.Rendering.RenderExtras = null
public String Save(String path, RenderExtras extras = null) #StringSaves the configured barcode, selecting the output format from the file extension.
Parameters
- path System.String
- extras CodeGlyphX.Rendering.RenderExtras = null
public Void Save(Stream stream, OutputFormat format, RenderExtras extras = null) #VoidWrites the configured barcode to a stream in the requested output format.
Parameters
- stream System.IO.Stream
- format CodeGlyphX.Rendering.OutputFormat
- extras CodeGlyphX.Rendering.RenderExtras = null
public BarcodeBuilder WithBackground(Rgba32 color) #BarcodeBuilderSets background color.
Parameters
- color CodeGlyphX.Rendering.Png.Rgba32
public BarcodeBuilder WithColors(Rgba32 foreground, Rgba32 background) #BarcodeBuilderSets foreground and background colors.
Parameters
- foreground CodeGlyphX.Rendering.Png.Rgba32
- background CodeGlyphX.Rendering.Png.Rgba32
public BarcodeBuilder WithForeground(Rgba32 color) #BarcodeBuilderSets foreground color.
Parameters
- color CodeGlyphX.Rendering.Png.Rgba32
public BarcodeBuilder WithHeight(Int32 heightModules) #BarcodeBuilderSets barcode height in modules.
Parameters
- heightModules System.Int32
public BarcodeBuilder WithIcoPreserveAspectRatio(Boolean enabled = true) #BarcodeBuilderSets ICO aspect ratio preservation behavior.
Parameters
- enabled System.Boolean = true
public BarcodeBuilder WithIcoSizes(params Int32[] sizes) #BarcodeBuilderSets ICO output sizes (in pixels).
Parameters
- sizes System.Int32[]
public BarcodeBuilder WithJpegOptions(JpegEncodeOptions options) #BarcodeBuilderSets JPEG encoding options.
Parameters
- options CodeGlyphX.Rendering.Jpeg.JpegEncodeOptions
public BarcodeBuilder WithJpegQuality(Int32 quality) #BarcodeBuilderSets JPEG quality.
Parameters
- quality System.Int32
public BarcodeBuilder WithLabel(String text) #BarcodeBuilderSets label text rendered under bars.
Parameters
- text System.String
public BarcodeBuilder WithLabelColor(Rgba32 color) #BarcodeBuilderSets label color.
Parameters
- color CodeGlyphX.Rendering.Png.Rgba32
public BarcodeBuilder WithLabelFontFamily(String fontFamily) #BarcodeBuilderSets label font family (SVG/HTML).
Parameters
- fontFamily System.String
public BarcodeBuilder WithLabelFontSize(Int32 fontSizePx) #BarcodeBuilderSets label font size in pixels.
Parameters
- fontSizePx System.Int32
public BarcodeBuilder WithLabelMargin(Int32 marginPx) #BarcodeBuilderSets label margin in pixels.
Parameters
- marginPx System.Int32
public BarcodeBuilder WithModuleSize(Int32 moduleSize) #BarcodeBuilderSets module size.
Parameters
- moduleSize System.Int32
public BarcodeBuilder WithOptions(Action<BarcodeOptions> configure) #BarcodeBuilderUpdates rendering options.
Parameters
- configure System.Action{CodeGlyphX.BarcodeOptions}
public BarcodeBuilder WithQuietZone(Int32 quietZone) #BarcodeBuilderSets quiet zone size.
Parameters
- quietZone System.Int32
public BarcodeBuilder WithTransparentBackground() #BarcodeBuilderUses a transparent background (alpha = 0).
Inherited Methods
public override Boolean Equals(Object obj) #BooleanParameters
- obj Object
Properties
public BarcodeOptions Options { get; } #Rendering options used by this builder.