From: handa Date: Thu, 2 Jul 2009 04:16:56 +0000 (+0000) Subject: *** empty log message *** X-Git-Url: http://git.chise.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=81107fe224e464dc6e0b62e6a95a7ed79faab8da;p=m17n%2Fm17n-lib-cs.git *** empty log message *** --- diff --git a/MDatabase.cs b/MDatabase.cs index 6c601de..b558789 100644 --- a/MDatabase.cs +++ b/MDatabase.cs @@ -881,7 +881,8 @@ namespace M17N.Core return null; } - // Return a list of currently available database directories. + /// Return a list of currently available database + /// directory names. public static string[] DirectoryList () { List dirs = new List (); @@ -900,4 +901,4 @@ namespace M17N.Core : ListIndex - other.ListIndex); } } -} \ No newline at end of file +} diff --git a/MText.cs b/MText.cs index 39f9359..7f6de04 100644 --- a/MText.cs +++ b/MText.cs @@ -969,21 +969,25 @@ namespace M17N.Core MInterval head = find_head (start); MInterval tail = find_tail (end); + M17n.DebugPrint ("Copying: {0}", copy); + if (! head.Stack.IsEmpty && (isSensitive && head.From < start - || isFrontSensitive && ! first)) + || (isFrontSensitive && ! first))) { + M17n.DebugPrint (" clear head"); head = copy.find_head (0); head.Stack.Clear (); } if (! tail.Stack.IsEmpty - && (isSensitive && end < head.To - || isRearSensitive && ! last)) + && (isSensitive && end < tail.To + || (isRearSensitive && ! last))) { + M17n.DebugPrint (" clear tail"); tail = copy.find_tail (copy.Length); tail.Stack.Clear (); } - M17n.DebugPrint ("Copied: {0}\n", copy); + M17n.DebugPrint ("\n"); return copy; } @@ -1315,7 +1319,7 @@ namespace M17N.Core interval = interval.Copy (mtext, start, end, front_grafted, (rear_grafted - || (next == null && end < interval.mtext.Length))); + || (next == null && end == interval.mtext.Length))); else interval = new MInterval (Key, mtext, end - start, null);