EditorExtension class abstract
The single add-on mechanism of the editor: every feature beyond plain text editing — including the built-in formats — is packaged as an extension.
A QuillKitController is constructed with a list of extensions; at
construction it registers each extension's attributes into the
document's AttributeRegistry, its rules into the document's RuleSet
(consulted before the baseline rules), and its typingShortcuts into the
controller's TypingShortcutEngine, then calls attach with the
per-instance EditorScope. embedRenderers, toolbarItems and
shortcuts are consumed by the widget layers.
Everything is per-instance: two editors on one screen can run different
extension sets without interfering. The full set of built-in extensions
(bold, lists, links, ... and the basic/standard/full presets) lands
as extensions.
Constructors
- EditorExtension()
-
Enables const constructors in subclasses.
const
Properties
-
attributes
→ List<
AttributeSpec> -
The attribute kinds this extension adds to the document's registry.
no setter
-
embedRenderers
→ List<
EmbedRenderer> -
The embed renderers this extension contributes.
no setter
- hashCode → int
-
The hash code for this object.
no setterinherited
- id → String
-
Unique identifier of this extension, e.g.
'quill_kit.bold'.no setter -
rules
→ List<
EditRule> -
The edit rules this extension contributes; they run before the
document's existing rules so they can override baseline behavior.
no setter
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
-
shortcuts
→ Map<
ShortcutActivator, Intent> -
Keyboard shortcuts this extension contributes; merged with the default
activator map by the editor widget.
no setter
-
toolbarItems
→ List<
ToolbarItem> -
The toolbar items this extension contributes.
no setter
-
typingShortcuts
→ List<
TypingShortcut> -
Markdown-style typing shortcuts this extension contributes; consulted
before the built-in ones.
no setter
Methods
-
attach(
EditorScope scope) → void -
Called once when the owning controller is constructed. Use it to
register or replace services on
scopeand to capture per-instance state. -
detach(
) → void - Called when the owning controller is disposed; release any resources captured in attach.
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited