|
|
|
@ -5,6 +5,7 @@ export class Command {
|
|
|
|
private static undo: Function
|
|
|
|
private static undo: Function
|
|
|
|
private static redo: Function
|
|
|
|
private static redo: Function
|
|
|
|
private static format: Function
|
|
|
|
private static format: Function
|
|
|
|
|
|
|
|
private static bold: Function
|
|
|
|
private static print: Function
|
|
|
|
private static print: Function
|
|
|
|
|
|
|
|
|
|
|
|
constructor(adapt: CommandAdapt) {
|
|
|
|
constructor(adapt: CommandAdapt) {
|
|
|
|
@ -12,6 +13,7 @@ export class Command {
|
|
|
|
Command.redo = adapt.redo.bind(adapt)
|
|
|
|
Command.redo = adapt.redo.bind(adapt)
|
|
|
|
Command.print = adapt.print.bind(adapt)
|
|
|
|
Command.print = adapt.print.bind(adapt)
|
|
|
|
Command.format = adapt.format.bind(adapt)
|
|
|
|
Command.format = adapt.format.bind(adapt)
|
|
|
|
|
|
|
|
Command.bold = adapt.bold.bind(adapt)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
// 撤销、重做、格式刷、清除格式
|
|
|
|
// 撤销、重做、格式刷、清除格式
|
|
|
|
@ -28,6 +30,9 @@ export class Command {
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
// 字体变大、字体变小、加粗、斜体、下划线、删除线、字体颜色、背景色
|
|
|
|
// 字体变大、字体变小、加粗、斜体、下划线、删除线、字体颜色、背景色
|
|
|
|
|
|
|
|
public executeBold() {
|
|
|
|
|
|
|
|
return Command.bold()
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
// 搜索、打印
|
|
|
|
// 搜索、打印
|
|
|
|
public executePrint() {
|
|
|
|
public executePrint() {
|
|
|
|
|