c# - Convert System.Windows.Media.Brush to System.Drawing.Brush -


How can I convert a system. Windows Media. System system Drawing Brush?

I am trying to get the color of a system. Windows.media.brush was formatted in a system. Drawing.Color Object.

The following solution does not work because it requires a solid color object, while the object I need to change is a system.windows. Media. Brush object:

  public system. Drawing Caller GateColor (System. Windows Media, Solid Coulobrish Obrish) {Return System. Drawing Color .FromArgb (oBrush.Color.A, oBrush.Color.R, oBrush.Color.G, oBrush.Color.B); }  

I believe that you get it to be a solid coiler Can put in the form of a brush. / P>

Try doing something like this:

  MyColor = ((SolidColorBrush) MyMediaBrush). Colour;  

Comments

Popular posts from this blog

c++ - Linux and clipboard -

What is expire header and how to achive them in ASP.NET and PHP? -

sql server - How can I determine which of my SQL 2005 statistics are unused? -