예제 #1
0
 public bool SameStyle(WordStyle o)
 {
     return Equals(Font, o.Font) && (Color == o.Color) && (Point.Y == o.Point.Y);
 }
예제 #2
0
 private static void DrawText(Graphics g, string text, Font font, Point point, Color color, List<WordStyle> words)
 {
     if (words == null) {
         TextRenderer.DrawText(g, text, font, point, color, tf);
     } else {
         WordStyle s = new WordStyle(text, font, point, color);
         if (words.Count > 0) {
             if (words[words.Count - 1].SameStyle(s)) {
                 words[words.Count - 1].Text += text;
                 return;
             }
         }
         words.Add(s);
     }
 }