Namespace: PdfSharp.Drawing.BarCodes
Implementation of the Code 2 of 5 bar code.
public class Code2of5Interleaved : ThickThinBarCode
Inheritance Object → CodeBase → BarCode → ThickThinBarCode → Code2of5Interleaved
Gets or sets the ratio between thick and thin lines. Must be between 2 and 3. Optimal and also default value is 2.6.
public double WideNarrowRatio { get; set; }
Gets or sets the location of the text next to the bar code.
public TextLocation TextLocation { get; set; }
Gets or sets the length of the data that defines the bar code.
public int DataLength { get; set; }
Gets or sets the optional start character.
public char StartChar { get; set; }
Gets or sets the optional end character.
public char EndChar { get; set; }
Gets or sets a value indicating whether the turbo bit is to be drawn. (A turbo bit is something special to Kern (computer output processing) company (as far as I know))
public bool TurboBit { get; set; }
Gets or sets the size.
public XSize Size { get; set; }
Gets or sets the text the bar code shall represent.
public string Text { get; set; }
Always MiddleCenter.
public AnchorType Anchor { get; set; }
Gets or sets the drawing direction.
public CodeDirection Direction { get; set; }
Initializes a new instance of Interleaved2of5.
public Code2of5Interleaved()
Initializes a new instance of Interleaved2of5.
public Code2of5Interleaved(string code)
code String
Initializes a new instance of Interleaved2of5.
public Code2of5Interleaved(string code, XSize size)
code String
size XSize
Initializes a new instance of Interleaved2of5.
public Code2of5Interleaved(string code, XSize size, CodeDirection direction)
code String
size XSize
direction CodeDirection
Renders the bar code.
protected internal void Render(XGraphics gfx, XBrush brush, XFont font, XPoint position)
gfx XGraphics
brush XBrush
font XFont
position XPoint
Calculates the thick and thin line widths, taking into account the required rendering size.
internal void CalcThinBarWidth(BarCodeRenderInfo info)
info BarCodeRenderInfo
Checks the code to be convertible into an interleaved 2 of 5 bar code.
protected void CheckCode(string text)
text String
The code to be checked.