コード例 #1
0
        public override bool TryAddFormatAtDestination(IDataModel owner, ModelDelta token, int source, int destination, string name, IReadOnlyList <ArrayRunElementSegment> sourceSegments, int parentIndex)
        {
            var run = new BSERun(destination, new SortedSpan <int>(source));

            if (run.Length < 1)
            {
                return(false);
            }
            owner.ClearFormat(token, run.Start, run.Length);
            owner.ObserveRunWritten(token, run);
            return(true);
        }
コード例 #2
0
 public override void UpdateNewRunFromPointerFormat(IDataModel model, ModelDelta token, string name, IReadOnlyList <ArrayRunElementSegment> sourceSegments, int parentIndex, ref IFormattedRun run)
 {
     run = new BSERun(run.Start, run.PointerSources);
 }
コード例 #3
0
 // TODO
 public override ErrorInfo TryParseData(IDataModel model, string name, int dataIndex, ref IFormattedRun run)
 {
     run = new BSERun(dataIndex, run.PointerSources);
     return(ErrorInfo.NoError);
 }
コード例 #4
0
 public override void UpdateNewRunFromPointerFormat(IDataModel model, ModelDelta token, string name, ref IFormattedRun run)
 {
     run = new BSERun(run.Start, run.PointerSources);
 }