Hold your mouse click button down to draw.
Click on the eraser in the upper left hand corner and move it around to erase. Click again to park the eraser.
Press Print Screen key to save the screen image to the clipboard.
Press F5 key to erase the entire screen.
Press ESC to quit
This isn't going to replace any CAD software but demonstrates another amazing capability of Macro Scheduler
Code: Select all
OnEvent>KEY_DOWN,VK27,0,Quit
OnEvent>KEY_DOWN,VK1,0,Draw
OnEvent>KEY_DOWN,VK44,0,Save
Let>StartFlag=0
Let>NoDrawFlag=0
GetScreenRes>ScreenX,ScreenY
Let>scrX={-1*%ScreenX%}
Let>scrY={-1*%ScreenY%}
ScreenCapture>%ScrX%,%ScrY%,0,0,%TEMP_DIR%Whitespace.bmp
Dialog>Doodle1
Caption=Doodle Pad
Width=%ScreenX%
Height=%ScreenY%
Top=0
Left=0
Close=0
Button=Erase X Erase,10,10,20,20,10
Image=%TEMP_DIR%Whitespace.bmp,0,0,%ScreenX%,%ScreenY%,newimage
EndDialog>Doodle1
Show>Doodle1
Label>start
GetDialogAction>Doodle1,res1
if>Res1=2,EOF
if>Res1=10,Erase
If>StartFlag>0
Add>startFlag,1
If>StartFlag>5
Let>StartFlag=0
EndIf
EndIf
Wait>0.01
Goto>start
SRT>Quit
Goto>EOF
END>Quit
Label>EOF
SRT>Erase
RDA>Doodle1
Label>KeepErasing
Let>NoDrawFlag=1
Wait>0.01
GetCursorPos>CurX,CurY
Sub>CurX,15
Sub>CurY,35
MoveWindow>Erase X Erase*,curX,CurY
GetDialogAction>Doodle1,res1
if>Res1=10,FinishedErasing
Goto>KeepErasing
Label>FinishedErasing
RDA>Doodle1
Wait>0.5
Let>NoDrawFlag=0
END>Erase
SRT>Draw
If>NoDrawFlag=1,NoDraw
If>StartFlag=0
GetCursorPos>CurX,CurY
LibFunc>user32,GetDC,HDC,0
Libfunc>gdi32,MoveToEx,mtres,HDC,CurX,CurY,0
Libfunc>gdi32,LineTo,ltres,HDC,CurX,CurY
EndIf
Let>StartFlag=1
Wait>0.01
GetCursorPos>CurX,CurY
Libfunc>gdi32,LineTo,ltres,HDC,CurX,CurY
Label>NoDraw
END>Draw
SRT>Save
MoveWindow>Erase X Erase*,-1000,-1000
Press Print Screen
MoveWindow>Erase X Erase*,10,10
END>Save