Example #1
0
        /// <summary>
        /// Initialize the label content on the device.
        /// </summary>
        /// <param name="device"></param>
        public void Initialize(IDrawing.IDevice device, Font font)
        {
            try
            {
                #region Update#2
                if (line != null)
                {
                    line.Dispose();
                    line = null;
                }

                if (textWriter != null)
                {
                    textWriter.Dispose();
                    textWriter = null;
                }
                #endregion

                line           = GraphicEngine.GraphicEngine.CreateLine(device, font);
                line.Width     = lineWidth;
                line.Antialias = true;
                textWriter     = GraphicEngine.GraphicEngine.CreateTextWriter(device, Font);// 12, "Mitra");
            }
            catch (System.Exception ex)
            {
                xPFT.Exceptions.ExceptionHandler.LogError(ex);
            }
        }
Example #2
0
 /// <summary>
 /// Dispose line
 /// </summary>
 public void Dispose()
 {
     if (line != null)
     {
         line.Dispose();
         line = null;
     }
 }
Example #3
0
 /// <summary>
 /// Dispose the axis.
 /// </summary>
 public override void Dispose()
 {
     if (line != null)
     {
         line.Dispose();
         line = null;
     }
     axisTitle.Dispose();
 }
Example #4
0
 /// <summary>
 /// Dispose the series
 /// </summary>
 public override void Dispose()
 {
     if (mainPolyLine != null)
     {
         mainPolyLine.Dispose();
         mainPolyLine = null;
     }
     if (labelTextWriter != null)
     {
         labelTextWriter.Dispose();
         labelTextWriter = null;
     }
 }
Example #5
0
 /// <summary>
 /// Initialize the series component on the device.
 /// </summary>
 /// <param name="device"></param>
 internal override void Initialize(IDrawing.IDevice device)
 {
     try
     {
         this.device            = device;
         mainPolyLine           = GraphicEngine.GraphicEngine.CreateLine(device, Font);
         mainPolyLine.Width     = LineThickness;
         mainPolyLine.Antialias = true;
         mainPolyLine.Pattern   = linePattern;
         labelTextWriter        = GraphicEngine.GraphicEngine.CreateTextWriter(device, Font);
         points.Width           = XAxis.Maximum - XAxis.Minimum;
         points.HeightBottom    = YAxis.Minimum;
         points.HeightTop       = YAxis.Maximum;
     }
     catch (System.Exception ex)
     {
         xPFT.Exceptions.ExceptionHandler.LogError(ex);
     }
 }
Example #6
0
        /// <summary>
        /// Initialize the line on the device.
        /// </summary>
        /// <param name="device"></param>
        internal override void Initialize(IDrawing.IDevice device)
        {
            base.Initialize(device);
            try
            {
                this.device = device;

                #region Update#2
                if (line != null)
                {
                    line.Dispose();
                    line = null;
                }
                #endregion

                line       = GraphicEngine.GraphicEngine.CreateLine(device, Font);
                line.Width = LineWidth;
            }
            catch (System.Exception ex)
            {
                xPFT.Exceptions.ExceptionHandler.LogError(ex);
            }
        }
Example #7
0
        /// <summary>
        /// Initilize the axis on the device.
        /// </summary>
        /// <param name="device"></param>
        internal override void Initialize(IDrawing.IDevice device)
        {
            try
            {
                if (line != null && !line.IsDisposed)
                {
                    line.Dispose();
                }

                line           = GraphicEngine.GraphicEngine.CreateLine(device, Font);
                line.Width     = lineWidth;
                line.Antialias = true;
                foreach (AxisLabel al in labelsCollection)
                {
                    al.Initialize(device, Font);
                }
                axisTitle.AxisSide = type;
                axisTitle.Initialize(device, Font);
            }
            catch (System.Exception ex)
            {
                xPFT.Exceptions.ExceptionHandler.LogError(ex);
            }
        }