IDL and JavaScript bindings .. ?
Hello Everyone, I am new to Webkit domain. I am initially trying to use Webkit to render a simple html text file with no graphics. I am confused with the IDL files that come with Webkit source. Why is there any need to generate JavaScript bindings via IDL files using Perl scripts. What I want to say is why these binding files are not part of the source? Everyone will be required to generate them on his system through the Perl script. If I am trying to render a plain text message, will I still need to generate these bindings in order to build successfully? Can I somehow skip these files to simplify the usage. Thanks, J R Shah
WebKit is a full web browser engine (supporting JavaScript and rendering of HTML, XHTML, SVG, images and plug-ins), not just a simple HTML renderer (although it does that, too :). If all you're looking for is a simple HTML renderer, there are probably better choices. See the thread entitled, "WebKit-GTK in embedded system" for more details (you didn't say which platform this was for, though): https://lists.webkit.org/pipermail/webkit-dev/2008-July/004503.html Dave On Thu, 8/7/08, Javed Rabbani <jrabbani@gmail.com> wrote:
Hello Everyone,
I am new to Webkit domain. I am initially trying to use Webkit to render a simple html text file with no graphics. I am confused with the IDL files that come with Webkit source. Why is there any need to generate JavaScript bindings via IDL files using Perl scripts. What I want to say is why these binding files are not part of the source? Everyone will be required to generate them on his system through the Perl script. If I am trying to render a plain text message, will I still need to generate these bindings in order to build successfully? Can I somehow skip these files to simplify the usage.
Thanks, J R Shah
You are indeed right in saying that there are better options to use if only basic text rendering is desired. However, as I mentioned, the text rendering is just to start with. Obviously, the ultimate task will be to use other powerful features of the webkit browser engine. I am currently investigating the Webkit to get some insight into how it works and how it can be used. So my initial concern was related to JavaScript and ObjectiveC bindings that are generated through the generate-bindings.pl Perl script. The script takes IDL files as input and genertes corresponding C++ source and header files as JavaScript bindings. I was wondering why the files need to be generated after getting the source from SVN. Why do the generated files not part of the actual source? What is the concept behind generating these files explicility at my system. I hope you get my point. I want to be clear about relation between IDL, DOM and JavaScript bindings and the Perl script. Regards, J R Shah On Thu, Aug 7, 2008 at 10:45 PM, David Kilzer <ddkilzer@webkit.org> wrote:
WebKit is a full web browser engine (supporting JavaScript and rendering of HTML, XHTML, SVG, images and plug-ins), not just a simple HTML renderer (although it does that, too :).
If all you're looking for is a simple HTML renderer, there are probably better choices. See the thread entitled, "WebKit-GTK in embedded system" for more details (you didn't say which platform this was for, though):
https://lists.webkit.org/pipermail/webkit-dev/2008-July/004503.html
Dave
On Thu, 8/7/08, Javed Rabbani <jrabbani@gmail.com> wrote:
Hello Everyone,
I am new to Webkit domain. I am initially trying to use Webkit to render a simple html text file with no graphics. I am confused with the IDL files that come with Webkit source. Why is there any need to generate JavaScript bindings via IDL files using Perl scripts. What I want to say is why these binding files are not part of the source? Everyone will be required to generate them on his system through the Perl script. If I am trying to render a plain text message, will I still need to generate these bindings in order to build successfully? Can I somehow skip these files to simplify the usage.
Thanks, J R Shah
On Aug 7, 2008, at 8:49 AM, Javed Rabbani wrote:
Why is there any need to generate JavaScript bindings via IDL files using Perl scripts. What I want to say is why these binding files are not part of the source?
There are at least two different answers to your question: 1) Using IDL files instead of hand written bindings allows us to easily change details of the binding mechanism without modifying hundreds of files. It's been a great boon for folks working on the WebKit project. 2) The WebKit source repository doesn't include copies of generated files. That includes the files generated by the IDL scripts, bison-based parsers, flex-based lexers, and many other generated source files. This is the usual practice in most software projects. Checking in copies of those generated files would help some people, but can cause all sorts of problems. -- Darin
Thanks for the response. That clarified number of confusions. Now working from a non-MAC platform, the Objective-C bindings will not be used. These bindings are meant for developers working in Mac through the Cocoa framework. Am I right in making this judgement? Now, if that is the case then is it mandatory to generate JavaScript bindings to successfully build webkit? It is becuase number of files will be depending upon these generated files. Thanks. - J R Shah On Thu, Aug 7, 2008 at 11:48 PM, Darin Adler <darin@apple.com> wrote:
On Aug 7, 2008, at 8:49 AM, Javed Rabbani wrote:
Why is there any need to generate JavaScript bindings via IDL files using
Perl scripts. What I want to say is why these binding files are not part of the source?
There are at least two different answers to your question:
1) Using IDL files instead of hand written bindings allows us to easily change details of the binding mechanism without modifying hundreds of files. It's been a great boon for folks working on the WebKit project.
2) The WebKit source repository doesn't include copies of generated files. That includes the files generated by the IDL scripts, bison-based parsers, flex-based lexers, and many other generated source files. This is the usual practice in most software projects. Checking in copies of those generated files would help some people, but can cause all sorts of problems.
-- Darin
On Aug 7, 2008, at 11:33 AM, Javed Rabbani wrote:
Now working from a non-MAC platform, the Objective-C bindings will not be used. These bindings are meant for developers working in Mac through the Cocoa framework. Am I right in making this judgement?
Yes.
Now, if that is the case then is it mandatory to generate JavaScript bindings to successfully build webkit?
Yes. -- Darin
participants (3)
-
Darin Adler
-
David Kilzer
-
Javed Rabbani