public override string ToString()
 {
     if (_position == null) throw new ApplicationException("Field position must be set for barcode generator");
     if (_data == null) throw new ApplicationException("Field data must be set for barcode generator");
     var barcodePosition = getBarcodePosition();
     var textPosition = new LabelPosition(_position.X, _position.Y + getHeights());
     return barcodePosition +   _barcodeType.Value + paramList() + _width +  _data + textPosition + getBlock() + getFont() + _data;
 }
Example #2
0
        private string getUnderline()
        {
            if (!_underline)
            {
                return("");
            }
            var ulPosition = new LabelPosition(_position.X, _position.Y + 3);

            return(ulPosition + "^FD".PadRight(_data.Length, '_') + "^FS");
        }
        public override string ToString()
        {
            if (_position == null)
            {
                throw new ApplicationException("Field position must be set for barcode generator");
            }
            if (_data == null)
            {
                throw new ApplicationException("Field data must be set for barcode generator");
            }
            var barcodePosition = getBarcodePosition();
            var textPosition    = new LabelPosition(_position.X, _position.Y + getHeights());

            return(barcodePosition + _barcodeType.Value + paramList() + _width + _data + textPosition + getBlock() + getFont() + _data);
        }
Example #4
0
 public LabelTextGenerator At(int fromLeft, int fromTop)
 {
     _position = new LabelPosition(fromLeft, fromTop);
     return(this);
 }
Example #5
0
 private string getUnderline()
 {
     if (!_underline) return "";
     var ulPosition = new LabelPosition(_position.X, _position.Y + 3);
     return ulPosition + "^FD".PadRight(_data.Length, '_') + "^FS";
 }
Example #6
0
 public LabelTextGenerator At(int fromLeft, int fromTop)
 {
     _position = new LabelPosition(fromLeft, fromTop);
     return this;
 }
 public LabelBarcodeGenerator At(int x, int y)
 {
     _position = new LabelPosition(x, y);
     return this;
 }
Example #8
0
 /// <summary>
 /// Set Textposition in milimeter
 /// </summary>
 /// <param name="dpiHelper"></param>
 /// <param name="fromLeft"></param>
 /// <param name="fromTop"></param>
 /// <returns></returns>
 public LabelTextGenerator At(ZplLabels.Utilities.DPIHelper dpiHelper, double fromLeft, double fromTop,
                              LabelPosition.LabelAlignemnet alignment)
 {
     _position = new LabelPosition(dpiHelper.mmToPx(fromLeft), dpiHelper.mmToPx(fromTop), alignment);
     return(this);
 }
 public LabelBarcodeGenerator At(int x, int y)
 {
     _position = new LabelPosition(x, y);
     return(this);
 }
Example #10
0
 /// <summary>
 /// Set Textposition in Pixel
 /// </summary>
 /// <param name="fromLeft"></param>
 /// <param name="fromTop"></param>
 /// <returns></returns>
 public LabelTextGenerator At(int fromLeft, int fromTop, LabelPosition.LabelAlignemnet alignment)
 {
     _position = new LabelPosition(fromLeft, fromTop, alignment);
     return(this);
 }
Example #11
0
 /// <summary>
 /// Set Textposition in milimeter
 /// </summary>
 /// <param name="dpiHelper"></param>
 /// <param name="fromLeft"></param>
 /// <param name="fromTop"></param>
 /// <returns></returns>
 public LabelTextGenerator At(ZplLabels.Utilities.DPIHelper dpiHelper, double fromLeft, double fromTop)
 {
     _position = new LabelPosition(dpiHelper.mmToPx(fromLeft), dpiHelper.mmToPx(fromTop));
     return(this);
 }
 /// <summary>
 /// Set Barcode Position in milimeter
 /// </summary>
 /// <param name="dpiHelper"></param>
 /// <param name="x"></param>
 /// <param name="y"></param>
 /// <returns></returns>
 public LabelBarcodeGenerator At(ZplLabels.Utilities.DPIHelper dpiHelper, double x, double y,
                                 LabelPosition.LabelAlignemnet alignment)
 {
     _position = new LabelPosition(dpiHelper.mmToPx(x), dpiHelper.mmToPx(y), alignment);
     return(this);
 }
 /// <summary>
 /// Set Barcode position in pixel
 /// </summary>
 /// <param name="x"></param>
 /// <param name="y"></param>
 /// <returns></returns>
 public LabelBarcodeGenerator At(int x, int y, LabelPosition.LabelAlignemnet alignment)
 {
     _position = new LabelPosition(x, y, alignment);
     return(this);
 }
 /// <summary>
 /// Set Barcode Position in milimeter
 /// </summary>
 /// <param name="dpiHelper"></param>
 /// <param name="x"></param>
 /// <param name="y"></param>
 /// <returns></returns>
 public LabelBarcodeGenerator At(ZplLabels.Utilities.DPIHelper dpiHelper, double x, double y)
 {
     _position = new LabelPosition(dpiHelper.mmToPx(x), dpiHelper.mmToPx(y));
     return(this);
 }