/// <summary> /// Draws the caption. /// </summary> public void Draw(Graphics graphics, ICharacterStyle characterStyle, IParagraphStyle paragraphStyle) { if (graphics == null) throw new ArgumentNullException("graphics"); if (characterStyle == null) throw new ArgumentNullException("charStyle"); if (paragraphStyle == null) throw new ArgumentNullException("paragraphStyle"); if (textPath != null && textPath.PointCount > 0) { Brush brush = ToolCache.GetBrush(characterStyle.ColorStyle); graphics.FillPath(brush, textPath); } }
/// <ToBeCompleted></ToBeCompleted> protected virtual void DrawHint(Graphics graphics) { // Draw connection point hints if (IsConnected(GlueControlPoint, null) == ControlPointId.None) { if (DisplayService != null) { Pen foregroundPen = ToolCache.GetPen(DisplayService.HintForegroundStyle, null, null); Brush backgroundBrush = ToolCache.GetBrush(DisplayService.HintBackgroundStyle); DrawOutline(graphics, foregroundPen); graphics.FillPath(backgroundBrush, pinPath); graphics.DrawPath(foregroundPen, pinPath); } } }