text_zipper 0.1.0 copy "text_zipper: ^0.1.0" to clipboard
text_zipper: ^0.1.0 copied to clipboard

Dart 1 only

A two dimensional text zipper data structure.

example/text_zipper_example.dart

// Copyright (c) 2015, Kwang Yul Seo. All rights reserved. Use of this source code
// is governed by a BSD-style license that can be found in the LICENSE file.

library text_zipper.example;

import 'package:text_zipper/text_zipper.dart';

main() {
  const String text = '''
abc
df
efg''';

  var tz = stringZipper(text);
  tz = tz.moveCursorTo(new Position(1, 1)).insertCharCode('e'.codeUnitAt(0));
  print(tz.text);
  /// abc
  /// def
  /// efg
}
0
likes
30
points
1
downloads

Publisher

unverified uploader

Weekly Downloads

A two dimensional text zipper data structure.

Repository (GitHub)
View/report issues

License

BSD-3-Clause (license)

Dependencies

quiver_check

More

Packages that depend on text_zipper