TextField::GetFont Method (ShapeElement^)
Visual Studio 2015
Gets the font to draw with for the specified ShapeElement instance.
Assembly: Microsoft.VisualStudio.Modeling.Sdk.Diagrams.12.0 (in Microsoft.VisualStudio.Modeling.Sdk.Diagrams.12.0.dll)
Parameters
- parentShape
-
Type:
Microsoft.VisualStudio.Modeling.Diagrams::ShapeElement^
The ShapeElement on which to draw.
Return Value
Type: System.Drawing::Font^The default method looks up the font ID in the style set of the parent shape:
public virtual Font GetFont(ShapeElement parentShape)
{
StyleSet parentStyleSet = (parentShape != null) ? parentShape.StyleSet : ApplicationStyleSet.StyleSet;
return parentStyleSet.GetFont(GetFontId(parentShape));
}
For more information and examples, see TextField
Show: