Beispiel #1
0
        public int GetModuleNum()
        {
            BarCharEnumerator enumerator = this.EnumerateBars();
            Bars    bars          = new Bars();
            CharDef charDefBuffer = new CharDef();

            if (!enumerator.NextBars(bars, charDefBuffer))
            {
                return(0);
            }
            while (enumerator.NextBars(bars, charDefBuffer))
            {
            }
            return((bars.GetOffset() + bars.GetWidth()) + (this._spec.bdRightMargin * this._spec.bdBarExt[0]));
        }
Beispiel #2
0
 internal BarEnumerator(Barcode barcode, int iModuleWidth)
 {
     this._symbol        = barcode._symbol;
     this._iModuleWidth  = iModuleWidth;
     this._more          = false;
     this._bEnumStart    = true;
     this._bars          = new Bars();
     this._charDefBuffer = new CharDef();
     this._bcenum        = this._symbol.EnumerateBars();
     this._anmBarWidth   = new int[5];
     this._anmSpaceWidth = new int[5];
     this._symbol.GetBarExts(this._anmBarWidth, 5);
     this._symbol.GetSpaceExts(this._anmSpaceWidth, 5);
     this._currentValid = false;
 }