Пример #1
0
        public void DanhDau(AxMap pMap, Graphics g, Pen Pen)
        {
            float num = (float)(this.m_Zoom / pMap.Zoom);

            num = Conversions.ToSingle(Operators.MultiplyObject(num, Interaction.IIf(this.m_MWidth > 0f, pMap.MapScreenWidth / this.m_MWidth, 1)));
            float dx;
            float dy;

            pMap.ConvertCoord(ref dx, ref dy, ref this.m_GocX, ref this.m_GocY, ConversionConstants.miMapToScreen);
            GraphicsContainer container = g.BeginContainer();

            g.TranslateTransform(dx, dy);
            g.ScaleTransform(num, num);
            try
            {
                IEnumerator enumerator = this.m_GObjs.GetEnumerator();
                while (enumerator.MoveNext())
                {
                    GraphicObject graphicObject = (GraphicObject)enumerator.Current;
                    graphicObject.DanhDau(g, Pen);
                }
            }
            finally
            {
                IEnumerator enumerator;
                if (enumerator is IDisposable)
                {
                    (enumerator as IDisposable).Dispose();
                }
            }
            g.EndContainer(container);
        }
Пример #2
0
        public void DanhDau(AxMap pMap, Graphics g, GraphicObject pObj, Color Color)
        {
            float num = (float)(this.m_Zoom / pMap.Zoom);

            num = Conversions.ToSingle(Operators.MultiplyObject(num, Interaction.IIf(this.m_MWidth > 0f, pMap.MapScreenWidth / this.m_MWidth, 1)));
            float dx;
            float dy;

            pMap.ConvertCoord(ref dx, ref dy, ref this.m_GocX, ref this.m_GocY, ConversionConstants.miMapToScreen);
            GraphicsContainer container = g.BeginContainer();

            g.TranslateTransform(dx, dy);
            g.ScaleTransform(num, num);
            pObj.DanhDau(g, Color);
            g.EndContainer(container);
        }