Ejemplo n.º 1
0
        /// <summary>
        /// Writes the content of this instance to a persistent storage area.
        /// </summary>
        /// <param name="editSerializer">The mechanism for storing content.</param>
        public virtual void WriteData(EditSerializer editSerializer)
        {
            if (m_Font != null)
            {
                editSerializer.WriteInt32(DataField.Font, m_Font.Id);
            }

            editSerializer.WritePointGeometry(DataField.X, DataField.Y, m_Position);
            editSerializer.WriteDouble(DataField.Width, Math.Round((double)m_Width, 2));
            editSerializer.WriteDouble(DataField.Height, Math.Round((double)m_Height, 2));

            // TODO: May want to cover indirect rotations
            editSerializer.WriteRadians(DataField.Rotation, new RadianValue(m_Rotation.Radians));
        }
Ejemplo n.º 2
0
        /*
         * //	@mfunc	Create transient primitives (CeMiscText objects, and
         * //			optionally CeSegment objects) that correspond
         * //			to any angles associated with this point.
         * //
         * //			The caller is responsible for deleting the primitives
         * //			once done with them.
         * //
         * //	@parm	List of pointers to created primitives.
         * //	@parm	Should lines be produced too? NOT IMPLEMENTED.
         * //
         * //	@rdesc	The number of primitives that were created (if any).
         * //
         * //////////////////////////////////////////////////////////////////////
         *
         #include "CeMiscText.h"
         *
         * UINT4 CePoint::CreateAngleText ( CPtrList& prims
         *                                                 , const LOGICAL wantLinesToo ) const {
         *
         * // Get the creating op to create any angle text for
         * // this point.
         * CeOperation* pop = GetpCreator();
         * if ( pop ) pop->CreateAngleText(prims,wantLinesToo,this);
         *
         * // Get the location to do the same for any operations that
         * // utilize this point as part of an angular observation.
         * m_pLocation->CreateAngleText(prims,wantLinesToo,this);
         *
         * // Return the number of primitives in the list.
         * return prims.GetCount();
         *
         * } // end of CreateAngleText
         */

        /// <summary>
        /// Writes the content of this instance to a persistent storage area.
        /// </summary>
        /// <param name="editSerializer">The mechanism for storing content.</param>
        public override void WriteData(EditSerializer editSerializer)
        {
            base.WriteData(editSerializer);
            editSerializer.WritePointGeometry(DataField.X, DataField.Y, m_Geom);
        }