Esempio n. 1
0
        public UnderOverAtom(
            SourceSpan source,
            Atom baseAtom,
            Atom under,
            TexUnit underUnit,
            double underSpace,
            bool underScriptSize,
            Atom over,
            TexUnit overUnit,
            double overSpace,
            bool overScriptSize)
            : base(source)
        {
            SpaceAtom.CheckUnit(underUnit);
            SpaceAtom.CheckUnit(overUnit);

            this.BaseAtom           = baseAtom;
            this.UnderAtom          = under;
            this.UnderSpaceUnit     = underUnit;
            this.UnderSpace         = underSpace;
            this.UnderScriptSmaller = underScriptSize;
            this.OverAtom           = over;
            this.OverSpaceUnit      = overUnit;
            this.OverSpace          = overSpace;
            this.OverScriptSmaller  = overScriptSize;
        }
Esempio n. 2
0
        protected FractionAtom(
            SourceSpan source,
            Atom numerator,
            Atom denominator,
            bool useDefaultThickness,
            TexUnit unit,
            double thickness)
            : base(source, TexAtomType.Inner)
        {
            SpaceAtom.CheckUnit(unit);

            this.Numerator            = numerator;
            this.Denominator          = denominator;
            this.numeratorAlignment   = TexAlignment.Center;
            this.denominatorAlignment = TexAlignment.Center;
            this.useDefaultThickness  = useDefaultThickness;
            this.lineThicknessUnit    = unit;
            this.lineThickness        = thickness;
        }
Esempio n. 3
0
        public UnderOverAtom(
            SourceSpan source,
            Atom baseAtom,
            Atom underOver,
            TexUnit underOverUnit,
            double underOverSpace,
            bool underOverScriptSize,
            bool over)
            : base(source)
        {
            SpaceAtom.CheckUnit(underOverUnit);

            this.BaseAtom = baseAtom;

            if (over)
            {
                this.UnderAtom          = null;
                this.UnderSpace         = 0;
                this.UnderSpaceUnit     = 0;
                this.UnderScriptSmaller = false;
                this.OverAtom           = underOver;
                this.OverSpaceUnit      = underOverUnit;
                this.OverSpace          = underOverSpace;
                this.OverScriptSmaller  = underOverScriptSize;
            }
            else
            {
                this.UnderAtom          = underOver;
                this.UnderSpaceUnit     = underOverUnit;
                this.UnderSpace         = underOverSpace;
                this.UnderScriptSmaller = underOverScriptSize;
                this.OverSpace          = 0;
                this.OverAtom           = null;
                this.OverSpaceUnit      = 0;
                this.OverScriptSmaller  = false;
            }
        }