GH_GraphicsUtilRenderTag Method |
Namespace: Grasshopper.GUI
public static void RenderTag( Graphics g, string tag, Font font, Color backColor, Color foreColor, RectangleF frame, StringAlignment alignH, StringAlignment alignV )
Function RenderCornerAndEdgeTags(ByVal G As Graphics, ByVal frame As RectangleF) Dim font As New Font("Courier New", 8) Dim bg As Color = Color.White Dim fg As Color = Color.Black 'Render the 4 corner tags RenderTag(G, "UL", font, bg, fg, frame, StringAlignment.Near, StringAlignment.Near) RenderTag(G, "UR", font, bg, fg, frame, StringAlignment.Far, StringAlignment.Near) RenderTag(G, "LR", font, bg, fg, frame, StringAlignment.Far, StringAlignment.Far) RenderTag(G, "LL", font, bg, fg, frame, StringAlignment.Near, StringAlignment.Far) 'Render the 4 edge tags RenderTag(G, "T", font, bg, fg, frame, StringAlignment.Center, StringAlignment.Near) RenderTag(G, "R", font, bg, fg, frame, StringAlignment.Far, StringAlignment.Center) RenderTag(G, "B", font, bg, fg, frame, StringAlignment.Center, StringAlignment.Far) RenderTag(G, "L", font, bg, fg, frame, StringAlignment.Near, StringAlignment.Center) End Function