コード例 #1
0
ファイル: SvgLength.cs プロジェクト: w8w8w8/SharpVectors
        public SvgLength(string propertyName, SvgStyleableElement ownerElement, SvgLengthDirection direction, string defaultValue)
        {
            _ownerElement = ownerElement;
            _direction    = direction;

            string baseVal = ownerElement.GetPropertyValue(propertyName);

            if (baseVal == null || baseVal == "")
            {
                baseVal = defaultValue;
            }

            baseVal = SvgNumber.ScientificToDec(baseVal);

            _cssLength = new CssAbsPrimitiveLengthValue(new CssPrimitiveLengthValue(baseVal, false), propertyName, ownerElement);
        }