I just started playing with creating a library plug in, based on the Gears one that I found.
What is a good way to log to the QCAD console in or other simple ways to output debugging information. I have hacked things up enough from the sample InvoluteSpur.js (Gears) file but have some simple bugs that I can't see to find.
I tried qDebug("xxx") as well as console.log() but I'm not sure those are right for a library script.
Any other tips for a newcomer with debugging help very much appreciated.
Sandy
New library developer - Debugging
Moderator: andrew
Forum rules
Always indicate your operating system and QCAD version.
Attach drawing files, scripts and screenshots.
Post one question per topic.
Always indicate your operating system and QCAD version.
Attach drawing files, scripts and screenshots.
Post one question per topic.
Re: New library developer - Debugging
Hi,
Win or ....
Win = problematic.
I have a post on that, but can't find it.
look at:
https://qcad.org/rsforum/viewtopic.php?t=5687
https://qcad.org/rsforum/viewtopic.php?t=6215
Or search further with keywords from there.
Regards,
CVH
Win or ....
Win = problematic.
I have a post on that, but can't find it.
look at:
https://qcad.org/rsforum/viewtopic.php?t=5687
https://qcad.org/rsforum/viewtopic.php?t=6215
Or search further with keywords from there.
Regards,
CVH
Re: New library developer - Debugging
qDebug("message") writes to the system console from where QCAD was started (i.e. the terminal, stderr).
To output to the QCAD command line history widget, you can use EAction.handleUserMessage("message");
To output to the QCAD command line history widget, you can use EAction.handleUserMessage("message");
Re: New library developer - Debugging
Thanks all for the suggestions!
I am running on windows, so I'll take a look at the threads and see if that will help out.
I'm sure I'll be back for more questions and help
Sandy
I am running on windows, so I'll take a look at the threads and see if that will help out.
I'm sure I'll be back for more questions and help
Sandy