ShapeElement::UpdateGeometryLuminosity Method (DiagramClientView^, Brush^)

 

Updates the luminosity for the brush.

Namespace:   Microsoft.VisualStudio.Modeling.Diagrams
Assembly:  Microsoft.VisualStudio.Modeling.Sdk.Diagrams.12.0 (in Microsoft.VisualStudio.Modeling.Sdk.Diagrams.12.0.dll)

public:
virtual Color UpdateGeometryLuminosity(
	DiagramClientView^ view,
	Brush^ brush
) sealed

Parameters

view
Type: Microsoft.VisualStudio.Modeling.Diagrams::DiagramClientView^

The client view for the diagram.

brush
Type: System.Drawing::Brush^

The brush.

Return Value

Type: System.Drawing::Color

The color of the brush before the luminosity was updated.

if (this.HasFilledBackground(geometryHost))
{                    
    Color oldColor = geometryHost.UpdateGeometryLuminosity(e.View, interiorBrush);                                       
    graphics.FillPath(interiorBrush, interiorPath);

    graphics.DrawPath(solidLinePen, interiorPath);
    SolidBrush brush = interiorBrush as SolidBrush;
    if (brush != null) { brush.Color = oldColor; }                  

}
Return to top
Show: