takeScreenshot method
Takes a screenshot of the current editor state.
This method captures a screenshot of the current editor state, storing it in the screenshot history for potential future use.
Implementation
@protected
void takeScreenshot() async {
if (!initConfigs.convertToUint8List) return;
await setImageInfos();
screenshotHistory.removeRange(
screenshotHistoryPosition, screenshotHistory.length);
screenshotHistoryPosition++;
screenshotCtrl.captureImage(
imageInfos: imageInfos!,
screenshots: screenshotHistory,
);
}