Creating a basic web browser

Started by
11 comments, last by JY 18 years, 8 months ago
There are really two basic ways of doing this

1. The easy way:

Create an application which embeds Gecko (from Mozilla), MSHTML (Ships with Windows; part of MSIE) or KHTML / Applewebkit (Used in Konqueror / Safari). There are other less well known HTML rendering engines around, but they're generally not as good.

2. The hard way:

Parse the HTML and write your own layout engine, your own CSS engine etc. Embed an existing &#106avascript engine (if desired).

This will be enormously difficult. You can get existing HTML parsers (I'm using the libxml2), but I've drawn a blank with a usable embeddable CSS interpreter (i.e. something which can read CSS and then tell me what styles apply to a given element for rendering)

Mark
Advertisement
Several days before. i embed the IE into our game, but at last ,we give up . :) here are some links i collected, it may give you some help. :)

http://blog.360.yahoo.com/blog-snn8VuQrdLOqLz3TCGLzfNGuJM8-?l=6&u=11&mx=11&lmt=5&p=7
It would certainly be a good project to learn many aspects of programming; networking, graphical interface, optimal data structure etc. etc. Good luck with that!

If you're planning on making it standards compliant there is an awful lot of reading to do first. The CSS and XHTML specs are pretty big.
"Absorb what is useful, reject what is useless, and add what is specifically your own." - Lee Jun Fan

This topic is closed to new replies.

Advertisement