[bt-devel] Why HTML?

Torsten Uhlmann bt-devel@crosswire.org
Tue, 29 Feb 2000 08:31:40 +0100


On Die, 29 Feb 2000 darwin@ichristian.com wrote:
> As I was digging around and discovering how BibleTime works, and how I
> should store/retrieve various values I came up with a question...
> 
> Why HTML?
> 
> My comments are based on assumptions, and someone with actual knowledge or
> research could disprove anything...
> 
> My suspicion is that the underlying processes in the HTML widget being used
> for display takes HTML and after parsing converts the information to KDE or
> Qt standard objects like QColor and QFont.  This would lead to a
> significant amount of processing to get back to where we couldbe to begin
> with...
> 
> In effect this means that we go through the work of converting text to HTML
> just to parse it in the next step.  Am I missing something?  Is there a
> reason that we dynamically build HTML just to have it immediately parsed
> instead of using a different, simpler widget?
> 
> I haven't looked at BT 0.2x, is this the way it was done before?  If not,
> couldn't this be one reason that someone recently noted that BT 0.3 is
> slower than BT 0.2x?

BibleTime shows it's texts always in HTML widgets. This is because it is the
most advanced widget. In qt-1.4 there was no widget that understood RTF
formatting (there should be one now).

The data flow is the following: The frontend (a presenter for instance)
requests a specific passage from a module. This request is routed to the
connected CModuleInfo object. The object retrieves the text and while
retrieving the HTML filter is invoked by sword. So we need to filter the text
anyway, either into RTF, HTML, THML or whatever.

The HTML text is given to the presenter HTML widget which displays it.


> 
> I also am having some problem understanding the differentiation between the
> front-end and back-end.  I would have assumed that font and color selection
> would have been in the front end, and this is where I looked first.  Aren't
> color and font logically display related processes?

I understand a frontend as the part that comunicates with the user, dialogs,
presenters, groupmanager, Fontdialog, etc.

The backand prepares the data for the others or in line with directions given
by the others (Fontdialog) to be presented by the frontend. So the data looks
into the config file to find out how to format the data. But the Fontdialog
(Frontend) is the part that communicates with the user to retrieve the values
and write them into the config file.

> 
> I don't mean to rock the boat, I was just wondering, and hoping to gain
> understanding.
> 
> Thanks for any clarification.

Hope this helps a bit.

> 
> --
>    Darwin Gregory
> 
>    Help California define marriage the way God does...
>    Support Proposition 22!   Vote YES on Prop 22!
-- 

best regards,
Torsten Uhlmann

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
TUhlmann@gmx.de
TUhlmann@debis.com

http://www.tuhlmann.purespace.de
http://www.bibletime.de
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Wise men still seek him.