Rich text editor for Flutter
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 

31 lines
767 B

import 'package:flutter/cupertino.dart';
import 'editor.dart';
abstract class EditorTextSelectionGestureDetectorBuilderDelegate {
GlobalKey<EditorState> getEditableTextKey();
bool getForcePressEnabled();
bool getSelectionEnabled();
}
class EditorTextSelectionGestureDetectorBuilder {
final EditorTextSelectionGestureDetectorBuilderDelegate delegate;
bool shouldShowSelectionToolbar = true;
EditorTextSelectionGestureDetectorBuilder(this.delegate)
: assert(delegate != null);
EditorState getEditor() {
return delegate.getEditableTextKey().currentState;
}
RenderEditor getRenderEditor() {
return this.getEditor().getRenderEditor();
}
onTapDown(TapDownDetails details) {
// getRenderEditor().handleTapDown(details);
}
}