コード例 #1
0
        //--------------------------------------------------------------------------
        //
        // Utility Methods
        //
        //--------------------------------------------------------------------------

        /// <summary> Tests whether this DefineFont tag is equivalent to another DefineFont tag
        /// instance.
        ///
        /// </summary>
        /// <param name="obj">Another DefineFont (version 1) instance to test for
        /// equality.
        /// </param>
        /// <returns> true if the given instance is considered equal to this instance
        /// </returns>
        public override bool Equals(System.Object obj)
        {
            bool isEqual = false;

            if (obj is DefineFont1 && base.Equals(obj))
            {
                DefineFont1 defineFont = (DefineFont1)obj;

                if (equals(defineFont.fontInfo, this.fontInfo) && SupportClass.ArraySupport.Equals(defineFont.glyphShapeTable, this.glyphShapeTable))
                {
                    isEqual = true;
                }
            }

            return(isEqual);
        }
コード例 #2
0
		public virtual void  defineFont(DefineFont1 tag)
		{
		}
コード例 #3
0
		private Tag decodeDefineFont()
		{
			DefineFont1 t;
			t = new DefineFont1();
			int id = r.readUI16();
			int offset = r.readUI16();
			int numGlyphs = offset / 2;
			
			t.glyphShapeTable = new Shape[numGlyphs];
			
			// skip the offset table
			for (int i = 1; i < numGlyphs; i++)
			{
				r.readUI16();
			}
			
			for (int i = 0; i < numGlyphs; i++)
			{
				t.glyphShapeTable[i] = decodeShape(Flash.Swf.TagValues.stagDefineShape3);
			}
			
			dict.add(id, t);
			dict.addFontFace(t);
			return t;
		}