[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-devel
Subject:    Re: Question on using KHTML as HTML and CSS parser without rendering
From:       David Faure <faure () kde ! org>
Date:       2006-04-11 8:59:51
Message-ID: 200604111059.51349.faure () kde ! org
[Download RAW message or body]

On Tuesday 11 April 2006 01:01, Igor Yu. Zhbanov wrote:
> > > Thanks for your response!
> > > I don't like the word "widget" because "w" stands for window. ;-)
> > > I need to write a tool, so I can analyse pages. I will not display them.
> > > I just need to extract for every word whether it will be visible on page,
> > > with what font and with which size. So, I need something that can build
> > > DOM or render tree based on HTML and CSS of a particular page. So I can
> > > walk on DOM tree and inspect interesting for me style properties of
> > > particular tags.
> > >
> > > And I look for something that can parse HTML+CSS and can be easily
> > > separated from rendering a page on a window. I don't need to render, I need
> > > to inspect memory structures representing a page.
> > 
> > It should be possible to use KHTML and a pseudo/fake X server
> 
> First of all I will try to separate parsers code from code that renders
> page. As I understand, window drawing is done on very ast stage of page
> processing. So why not to have separated parsing parts and rendering parts?
> 
> I need KHTML's in-memory representation of a particular page how it will
> look e.g. on 1280x1024 window (the more interesting case is 1280 infinity,
> so I don't need any vertical scroll bars and all elements fits on virtual
> screen). And I will try to cut the code responsible for rendering texts
> and bitblitting of images. Parsers should be able to process pages
> without having connection to X-server. All they need to know is window
> size.

If a parser cares about window size, then it's doing rendering, so it also cares about
fonts and images, both of which need an X server  [well, technically fonts don't, but 
even in the latest Qt4 they still do, I reported a bug about that recently].

-- 
David Faure, faure@kde.org, sponsored by Trolltech to work on KDE,
Konqueror (http://www.konqueror.org), and KOffice (http://www.koffice.org).

 
>> Visit http://mail.kde.org/mailman/listinfo/kde-devel#unsub to unsubscribe <<
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic