EditorController class
エディタ全体の状態を保持するコントローラー。
以前は Riverpod のプロバイダ群で管理していた状態を、外部依存を持たない ChangeNotifier / ValueNotifier に集約したもの。各状態は個別の ValueNotifier として公開し、ウィジェット側は必要な状態だけを購読する。
Constructors
- EditorController({required ThemeDataDto themeDataDto})
Properties
- decoratingTheme → ThemeData
-
no setter
-
decorationPalette
→ ValueNotifier<
DecorationPalette> -
装飾アイテムの履歴。
final
-
editingTextItem
→ ValueNotifier<
RenderItem< DecorationText> > -
編集中のテキストアイテム。
final
- editorTheme → ThemeData
-
no setter
-
no setter
- hashCode → int
-
The hash code for this object.
no setterinherited
- paintingTheme → ThemeData
-
no setter
-
paintLines
→ ValueNotifier<
List< PaintLine> > -
確定済みのペイント線。
final
-
paintPalette
→ ValueNotifier<
PaintPalette> -
ペイントのパレット設定。
final
-
palette
→ ValueNotifier<
Palette> -
編集中フラグ(描画中・テキスト編集中・移動中)。
final
-
paletteKey
→ GlobalKey<
State< StatefulWidget> > -
エクスポート時に描画領域を取得するための GlobalKey。
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- themeDataDto → ThemeDataDto
-
テーマ定義(呼び出し側から注入される)。
final
-
themeMode
→ ValueListenable<
ThemeMode> -
背景画像から導出されるテーマモード。背景画像が変わったときのみ更新される。
no setter
Methods
-
addLine(
PaintLine line) → void -
addRenderItem(
RenderItem< DecorationItem> renderItem) → void -
backHistory(
) → void -
changeBrushType(
BrushType brushType) → void -
changeColor(
Color color) → void -
changeDeletePosition(
String uuid, bool isDeletePosition) → void -
changeEditingText(
bool isEditingText) → void -
changeFillColor(
) → void -
changeFontFamily(
String fontFamily) → void -
changeFontSize(
double fontSize) → void -
changeMovingItem(
bool isMovingItem) → void -
changePainting(
bool isPainting) → void -
changeStrokeOptions(
StrokeOptions strokeOptions) → void -
changeText(
String text) → void -
changeTextAlign(
) → void -
changeTextColor(
Color color) → void -
clearLines(
) → void -
deleteLine(
) → void -
dispose(
) → void -
exportImage(
) → Future< Uint8List?> - 現在の描画領域を PNG バイト列としてエクスポートする。
-
initHistoryRenderItem(
List< List< initHistoryRenderItem) → voidRenderItem< >DecorationItem> > -
moveBackgroundImage(
{required Matrix4 transform, required String? uuid}) → void - 背景画像の移動
-
moveRenderItem(
RenderItem< DecorationItem> renderItem) → void - RenderItemの移動
-
nextHistory(
) → void -
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
removeRenderItem(
String renderItemId) → void -
resetEditingText(
) → void -
setEditingTextItem(
RenderItem< DecorationText> renderItem) → void -
toString(
) → String -
A string representation of this object.
inherited
-
updateRenderItem(
RenderItem< DecorationItem> renderItem) → void - DecorationItemの更新
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited