2 // System.Windows.Forms.PaintEventArgs.cs
\r
5 // stubbed out by Paul Osman (paul.osman@sympatico.ca)
\r
6 // Dennis Hayes (dennish@raytek.com)
\r
7 // Gianandrea Terzi (gianandrea.terzi@lario.com)
\r
9 // (C) 2002 Ximian, Inc
\r
11 using System.Drawing;
\r
13 namespace System.Windows.Forms {
\r
16 // This is only a template. Nothing is implemented yet.
\r
20 public class PaintEventArgs : EventArgs, IDisposable {
\r
24 private Graphics mgraphics;
\r
25 private Rectangle mclipRect;
\r
30 public PaintEventArgs(Graphics graphics, Rectangle clipRect )
\r
32 this.mgraphics = graphics;
\r
33 this.mclipRect = clipRect;
\r
37 #region Public Properties
\r
38 public Rectangle ClipRectangle
\r
45 public Graphics Graphics {
\r
52 #region Public Methods
\r
55 public void Dispose()
\r
57 throw new NotImplementedException ();
\r
61 /// Equality Operator
\r
65 /// Compares two PaintEventArgs objects.
\r
66 /// The return value is based on the equivalence of
\r
67 /// Graphics and ClipRectangle Property
\r
68 /// of the two PaintEventArgs.
\r
70 public static bool operator == (PaintEventArgs PaintEventArgsA, PaintEventArgs PaintEventArgsB)
\r
72 return (PaintEventArgsA.Graphics == PaintEventArgsB.Graphics) && (PaintEventArgsA.ClipRectangle == PaintEventArgsB.ClipRectangle);
\r
76 /// Inequality Operator
\r
80 /// Compares two PaintEventArgs objects.
\r
81 /// The return value is based on the equivalence of
\r
82 /// Graphics and ClipRectangle Property
\r
83 /// of the two PaintEventArgs.
\r
85 public static bool operator != (PaintEventArgs PaintEventArgsA, PaintEventArgs PaintEventArgsB)
\r
87 return (PaintEventArgsA.Graphics != PaintEventArgsB.Graphics) || (PaintEventArgsA.ClipRectangle != PaintEventArgsB.ClipRectangle);
\r
95 /// Checks equivalence of this
\r
96 /// PaintEventArgs and another
\r
99 public override bool Equals (object obj)
\r
101 if (!(obj is PaintEventArgs))return false;
\r
102 return (this == (PaintEventArgs) obj);
\r
106 /// GetHashCode Method
\r
110 /// Calculates a hashing value.
\r
113 public override int GetHashCode ()
\r
115 //FIXME: add class specific stuff;
\r
116 return base.GetHashCode();
\r
120 /// ToString Method
\r
124 /// Formats the object as a string.
\r
127 public override string ToString ()
\r
129 //FIXME: add class specific stuff;
\r
130 return base.ToString();
\r
135 #region Protected Methods
\r
138 protected virtual void Dispose(bool disposing)
\r
140 throw new NotImplementedException ();
\r