Ejemplo n.º 1
0
		/// <summary>
		/// Default constructor.
		/// </summary>
		public GdiRenderer()
			: base()
		{
			_pen = new Pen(Color.White);
			_brush = new SolidBrush(Color.Black);
            _fontFactory = new FontFactory();
		}
Ejemplo n.º 2
0
		/// <summary>
		/// Dispose method.  Inheritors should override this method to do any additional cleanup.
		/// </summary>
		protected override void Dispose(bool disposing)
		{
			base.Dispose(disposing);

			if (disposing)
			{
				if (_pen != null)
				{
					_pen.Dispose();
					_pen = null;
				}
				if (_brush != null)
				{
					_brush.Dispose();
					_brush = null;
				}
                if (_fontFactory != null)
                {
                    _fontFactory.Dispose();
                    _fontFactory = null;
                }
			}
		}