OSDN Git Service

行を生成するメソッドをLineToIndexTableに移動した
[fooeditengine/FooEditEngine.git] / Windows / FooEditEngine / PrintableTextRender.cs
index 72281c1..d4c666d 100644 (file)
@@ -254,43 +254,6 @@ namespace FooEditEngine.Windows
         {
         }
 
-        public List<LineToIndexTableData> BreakLine(Document doc, LineToIndexTable layoutLineCollection, int startIndex, int endIndex, double maxwidth)
-        {
-            List<LineToIndexTableData> output = new List<LineToIndexTableData>();
-
-            foreach (string str in doc.GetLines(startIndex, endIndex))
-            {
-                LineToIndexTableData info;
-
-                if (str.Length == 0)
-                {
-                    info = layoutLineCollection.CreateLineToIndexTableData(startIndex, 0, true, null);
-                    output.Add(info);
-                    return output;
-                }
-
-                int fitlen, index = 0, x = 0, width;
-                do
-                {
-                    int linesFilled;
-                    SizeF metrics = g.MeasureString(str.Substring(index), this.font, new SizeF((float)maxwidth, this.font.Height + 1), this.sf, out fitlen, out linesFilled);
-
-                    x += width = (int)metrics.Width;
-
-                    info = layoutLineCollection.CreateLineToIndexTableData(index + startIndex, fitlen, false, null);
-                    output.Add(info);
-
-                    index += fitlen;
-                } while (index < str.Length);
-
-                output[output.Count - 1].LineEnd = true;
-
-                startIndex += str.Length;
-            }
-
-            return output;
-        }
-
         public void DrawGripper(Point p, double radius)
         {
             //タッチには対応していないので実装する必要はない