Example #1
0
        private void FGColorButton_Click(object sender, EventArgs e)
        {
            FGColor.ShowDialog();

            DrawingAreaState drawingArea = client.clientMachine.drawingArea;

            drawingArea.Access();
            drawingArea.ForegroundColor = Color.FromArgb(drawingArea.ForegroundColor.A, FGColor.Color);
            drawingArea.Exit();

            FGColorButton.BackColor = FGColor.Color;
        }
 public override int GetHashCode()
 {
     return(FontSize.GetHashCode() ^ FontName.GetHashCode() ^ FontBold.GetHashCode() ^ FontColor.GetHashCode() ^ FGColor.GetHashCode() ^ Borders[0].GetHashCode() ^ Borders[1].GetHashCode() ^ Borders[2].GetHashCode() ^ Borders[3].GetHashCode() ^ CellWidth.GetHashCode() ^ CellHeight.GetHashCode() ^ HorizontalAlignment.GetHashCode() ^ VerticalAlignment.GetHashCode() ^ WrapText.GetHashCode());
 }
        public bool Equals(SheetCellFormats other)
        {
            if (ReferenceEquals(other, null))
            {
                return(false);
            }

            if (ReferenceEquals(this, other))
            {
                return(true);
            }

            return(FontSize.Equals(other.FontSize) && FontName.Equals(other.FontName) && FontBold.Equals(other.FontBold) && FontColor.Equals(other.FontColor) && FGColor.Equals(other.FGColor) && Borders[0].Equals(other.Borders[0]) && Borders[1].Equals(other.Borders[1]) && Borders[2].Equals(other.Borders[2]) && Borders[3].Equals(other.Borders[3]) && CellWidth.Equals(other.CellWidth) && CellHeight.Equals(other.CellHeight) && HorizontalAlignment == other.HorizontalAlignment && VerticalAlignment == other.VerticalAlignment && WrapText == other.WrapText);
        }