What JS functions are available in Qt Creator Wizards? Where's the documentation?
-
wrote on 9 May 2016, 16:57 last edited by
If you're adding a new template / wizard to Qt Creator, you'll see that existing ones have several calls to JS: <something>. Sometimes those are pretty trivial statements to evaluate, but other times, they're things like: Util.preferredSuffix('text/x-c++src') or Cpp.classToFileName. are these any sort of standard JS libraries? or are their sources somewhere available? The 'wizard' documentation just shows that they're used but doesn't give any information as to how to use them.
-
wrote on 17 May 2016, 01:35 last edited by
I would love to know, too.
-
Hi,
I'd take a look at Qt Creator's sources to see what's in there. You can clone it from git here
-
wrote on 17 May 2016, 20:25 last edited by
Yes, that's an option but hopefully they will get the documentation written. Digging through the source is one way to get the info but it's not very productive but until the docs are done it may be the only way.
-
wrote on 3 May 2017, 15:01 last edited by
This StackOverflow question addresses this: http://stackoverflow.com/q/43763488/1329652
There's no documentation, but if you grep for
registerQObjectForJs
you'll find them all. The answer to the SO question contains a current list of all the global objects and their methods.