/// <summary> /// Returns a value indicating whether this instance and a specified Object represent the same type and value. /// </summary> /// <param name="obj">An object to compare to this instance.</param> /// <returns>true if obj is the same type and value; otherwise, false. </returns> public override bool Equals(object obj) { if (obj != null) { PictureRectangle o = (PictureRectangle)obj; if (this.X != o.X) { return(false); } if (this.Y != o.Y) { return(false); } if (this.Width != o.Width) { return(false); } if (this.Height != o.Height) { return(false); } return(true); } return(false); }
public void DisplayMessageBoxWindow(PictureRectangle rect, byte backgroundColor, byte lineColor) { // Draws the familiar white/red boxes in the picture buffer this.Interpreter.GraphicsRenderer.RenderSolidRectangle(new PictureRectangle(rect.X, rect.Y, rect.Width, rect.Height), backgroundColor); this.Interpreter.GraphicsRenderer.RenderSolidRectangle(new PictureRectangle(rect.X + 1, rect.Y - 1, rect.Width - 2, 1), lineColor); this.Interpreter.GraphicsRenderer.RenderSolidRectangle(new PictureRectangle(rect.X + rect.Width - 2, rect.Y - 2, 1, rect.Height - 4), lineColor); this.Interpreter.GraphicsRenderer.RenderSolidRectangle(new PictureRectangle(rect.X + 1, rect.Y - rect.Height + 2, rect.Width - 2, 1), lineColor); this.Interpreter.GraphicsRenderer.RenderSolidRectangle(new PictureRectangle(rect.X + 1, rect.Y - 2, 1, rect.Height - 4), lineColor); }
public abstract void RenderSolidRectangle(PictureRectangle rect, byte color);
public abstract void RenderPictureBuffer(PictureRectangle rect, bool picBuffRotate);