The KHTML Future FAQ

The KHTML Future FAQ

As people on #khtml and elsewhere keep asking the same type of questions I will summarize some of the answers that I can give and which – to my best knowledge – should match the view of other maintainers. This is to inform contributors, bug reporters, other helpers and users about the current state, avoid unfounded irritation and provide the basis for further discussion.

Feedback is greatly appreciated and will be incorporated into an updated version to be placed on konqueror.kde.org or so.


Will KHTML be the HTML rendering engine in KDE 4.0?

Yes. We are currently working on polishing it to get it into shape after so much of the frameworks around it have changed.

Are there any plans to drop KTHML?

No. Despite rampant rumors floating around there are no such concrete plans. We have had several discussions about alternatives but none of the them has yet crystallized as being accepted by the majority as a real option for KDE.

Why don’t you pull all the good patches from Apple’s WebCore and JavaScript libraries?

We do that to a certain degree since the beginning. More for KJS than for KHTML which is much bigger and platform dependent. Apple’s code repository is publicly accessible now which has eased patch extraction. Prior to its opening the code had already forked a lot, unfortunately. Misaligned release schedules, design conceptions and platform needs have also sometimes resulted in incompatible solutions.

Are KDE patches ending up in Apple’s code base?

To a small degree only. There were several attempts to establish a tradition of feeding our patches. Apple engineers also sometimes cherry-pick performance improvements on their own – possibly way later than we published it. As the patches at the same time often get reformatted to fit their coding style this does not make the “diff”between the code bases any smaller. As changes never get pushed back to us this is not an overly satisfying experience.

Does KDE profit from Apple’s work?

We do in many ways. There are not only improvements and bug fixes that we can adopt but also an increased public awareness of our work and a group of skilled engineers to exchange ideas with. On the downside we are competing for independent contributors and have to live with the fact that some prefer to team up with a shiny and mighty company as opposed to joining our multi-faceted desktop project.

How about joining forces?

This is the obvious solution, of course, and since the beginning there have been various initiatives to establish a common project. So far all such attempts have failed. One has to realize that the Safari team is constantly under immense pressure to produce new features and benchmarks for the next Mac OS X release or whatever Steve Jobs will present at next year’s WWDC keynote and does not want to risk giving up full control. As with the Windows version of Safari, work is sometimes done behind the scenes. We have not given up hope of course and hope to find some solution that accommodates the need of all
parties.

Why is all of this important?

The attention paid to KHTML and interest in its future is amazing. The number of well-meaning advisors by far outweighs the number of developers actually writing the code. But the interest is fully warranted. The use of Internet technologies will inevitably continue to rise in our applications. And the degree to which we are involved in the development of these technologies will govern our freedom in advancing their use. The Web development environment Quanta built on top of KHTML is such an example. Further opportunities for our mail mail, IRC, blog, news, media, calendaring, messaging and you name it clients are sheer endless. Merely adding a GUI around ready-made 3rd party components will not add much extra value to our framework.

What are maintainers asking for?

To be able to satisfy our user’s expectations we need to be able to provide a patched version in case they find a bug. This is
particularly important in case of security problems. This requires access to the development repository as well as KDE producing packages out of that repository. Waiting for other vendors to ship bug fix releases is not an option. When it comes to development of new features KDE developers need to have some say into it even if it needs to be coordinated with other parties. In case of KDE-specific needs there needs to be some way to add them.

Isn’t this all a rather trivial job?

A Web browser component is about more than plain HTML rendering. Apart from dynamic scripting there is Java, Flash, cookies, URI shortcuts, password managers, security and networking support. And KDE has invested a lot into providing this infrastructure that is being shared with other applications.

How about using QtWebKit ones it comes out?

QtWebKit is a port of the forked KHTML sources that aims at providing a ready-made HTML component to Trolltech customers without relying on KDE (other than incorporating the WebKit sources with KDE origin). It just is yet another platform port without any influence on the feature set and therefore useless for KDE’s purposes. See the “Why is all of this important?” and “What are maintainers asking for?” questions for more details.

So what are the plans?

As the current alternatives would mean dropping our code and losing all influence on development these are not real options. So we’ll simply stick to our code base for now and keep on merging in improvements ourselves. The code is pretty good, surpassing other browsers in speed and features in some areas.

Of course, we would be very much interested in joining forces with others having the same development goals. And we’ll keep the
discussion about cooperation going. One approach I could imagine is to merge our work (thousands of commits done over the recent years) into a WebKit branch and switch over to that one day. This wouldn’t be a branch like Nokia’s that diverges from the main line more and more. Instead we could branch it off trunk regularly and simply re-apply our KDE-specific patches.