How to Debug JavaScript code in the QtCreator?

Discussion forum for contributors and developers who are using the QCAD ECMAScript development platform or the C++ plugin interface or who are otherwise looking to contribute to QCAD (translations, documentation, etc).

Moderator: andrew

Post Reply
fang_h_y
Newbie Member
Posts: 8
Joined: Sat Jul 14, 2018 4:15 am

How to Debug JavaScript code in the QtCreator?

Post by fang_h_y » Sat Jul 14, 2018 10:04 am

Hello, Andrew.
We know the code is realized by JavaScript. When I debug the code I cannot debug the js file. Can you teach me how to debug JavaScript code with QtCreator?

Look forward to your reply.
fang_h_y

User avatar
andrew
Site Admin
Posts: 5702
Joined: Fri Mar 30, 2007 6:07 am

Re: How to Debug JavaScript code in the QtCreator?

Post by andrew » Mon Jul 16, 2018 1:18 pm

You can output states and variable values to stderr using qDebug("some string" + someVariable);

Use -enable-script-debugger to show the script debugger when an exception occurs of when the debugger; statement is used in your code.

fang_h_y
Newbie Member
Posts: 8
Joined: Sat Jul 14, 2018 4:15 am

Re: How to Debug JavaScript code in the QtCreator?

Post by fang_h_y » Thu Jul 19, 2018 1:00 am

Hello, andrew

Thank you very much!

fang_h_y

Post Reply

Return to “QCAD Developers and Contributors”