Esempio n. 1
0
 /// <summary>
 /// Set the current colour (in HSV form) and generate the Results in the
 /// Results property.
 /// </summary>
 /// <param name="c">The new colour.</param>
 /// <param name="keepHistory">
 /// If you want to update the undo stack. Note that it will only update it if
 /// the current colour and new colour are different.
 /// </param>
 /// <param name="fireEvent">
 /// If you want to fire the event.
 /// </param>
 public void SetColor(HsvColor c, bool keepHistory = true, bool fireEvent = true)
 {
     if (keepHistory && c.ToString() != HsvColor.ToString())
     {
         PushUndo();
     }
     HsvColor = c;
     GetSchemeResults();
     if (fireEvent)
     {
         OnResultChanged(new EventArgs());
     }
 }