/// <summary> /// Move to next line and reset currentX /// </summary> /// <param name="startPos">a start position</param> /// <returns>current line number</returns> public Int32 NewLine(float startPos) { if (currentLine == -1) { lineInfo.Add(new aLine(this, WidthLimit(), 0, 0, 0)); } else if (currentX == startPos) { return(lineInfo.Count - 1); } else { aLine line = lineInfo[lineInfo.Count - 1]; lineInfo.Add(new aLine(this, WidthLimit(), line.lineTop + line.lineHeight, 0, line.lineNumber + 1)); } currentLine++; currentX = startPos; currentY = lineInfo[lineInfo.Count - 1].lineTop; return(lineInfo.Count - 1); }
public bool Contains(aLine value) { return(List.Contains(value)); }
public void Remove(aLine value) { List.Remove(value); }
public void Insert(Int32 index, aLine value) { List.Insert(index, value); }
public Int32 Add(aLine value) { List.Add(value); return(List.Count - 1); }
public void setLine(Int32 aIndex, aLine value) { List[aIndex] = value; }