Open shihbas opened 2 years ago
I 'm not sure, whether the issue relating my code format. My code is fail json format.
I am also experiencing this error. I've tried it on several pieces of code and think I found a cause: the content of the window.
It is specifically (at least) %XX
that seems to break it, where XX is two hex digits, %f
does work.
screenshotting the below with c/cpp tools in the c language
void set_ratio_text(double ratio) {
char message[] = "Compression ratio: %0f";
float rounded_ratio = ((int)(ratio * 100)) / 100;
snprintf(char_overlay_dest, strlen(message), message, rounded_ratio);
}
causes the flash to fail and code snap to copy the selected code to the buffer, but changing it to below changes it.
void set_ratio_text(double ratio) {
char message[] = "Compression ratio: %0d";
float rounded_ratio = ((int)(ratio * 100)) / 100;
snprintf(char_overlay_dest, strlen(message), message, rounded_ratio);
}
%0d
adds a newline to the rendered dom but successfully completes.
When the screenshot fails the flash action fails and leaves the container background dark.
codesnap: v1.3.4
Version: 1.66.2 Commit: dfd34e8260c270da74b5c2d86d61aee4b6d56977 Date: 2022-04-11T07:49:20.994Z (2 wks ago) Electron: 17.2.0 Chromium: 98.0.4758.109 Node.js: 16.13.0 V8: 9.8.177.11-electron.0 OS: Darwin x64 21.4.0
Hi guys,
Now, I want share the beautiful code image to other peer. but the plugin not work in my vscode.
Can you help me to fix the issue?
My vscode:
version: 1.66.2 commit : dfd34e8260c270da74b5c2d86d61aee4b6d56977 date: 2022-04-11T07:49:20.994Z Electron: 17.2.0 Chromium: 98.0.4758.109 Node.js: 16.13.0 V8: 9.8.177.11-electron.0 OS: Darwin x64 21.3.0
CodeSnap version : 1.3.4
Looking forward to your reply.
thank you