Plan for the Yelp Spoon branch



Hi,

A long while ago (okay, a couple of weeks ago) shaunm asked that I post
an outline of my plan for the yelp-spoon branch here.  This info
(together with the similar plan shuanm's promised to write for the
yelp-document branch) should help us formulate a plan for how to merge
all this stuff.  So, without further ado, here we go.

The plan is to roughly follow the current structure in yelp-toc.c, but
rip out the scrollkeeper stuff, man page and info page stuff and replace
it with calls into spoon.  Right now, the scrollkeeper is done, the info
stuff is started and the man page stuff, not so much (see later).

In addition, the YelpDocInfo stuff from yelp-utils will go the way of
the dodo, as it'll be superseded by spoon structures.  This should
simplify yelp-toc-pager (at a minimum - no more hash tables and
many-nested loops or filling in YelpDocInfo structs).  In addition, the
yelp-window file will be cleared out somewhat as the various YelpDocInfo
stuff will need to be altered to calls into Spoon.  I haven't yet
figured out exactly what changes are required in yelp-window, but I will
do soon.  I am planning on keeping (roughly) the same structure in all
the files (at least, nothing that should strongly contradict with
shaunm's own yelp-document branch).

Unfortunately, fd.o hasn't yet responded to my request for SVN storage
for Spoon, so testing out the new yelp is difficult (unless you pester
me for a dump from Spoon SVN from my machine).

Finally, the plan for man pages in Spoon...
I had planned on ripping the yelp version of the man page TOC stuff, but
then I thought "There is already a man index available: mandb".  So the
new plan is (roughly):
init():
search for /var/cache/man/index.{bt,db,dir,pag}
if found:
  setup_handle_to_use()
else search for /usr/man/index.{bt,db,dir,pag}
if found:
  setup_handle_to_use()
else
  for all_files_in_man_heirarchy:
    add_to_internal_list()
  setup_handle_as_internal
end init()

function_for_getting_value():
decide_on_handle()
from_handle_get_struct()
parse_struct_into_own_format() /* That'll be more consistant with other
				* spoon structs and across handle types
				*/
return struct
end function_for_getting_value()

This will (hopefully) give the advantage that mandb has a description
for each man page (parsed out of the man page itself).  It should also
be faster and use less memory.

Does this sound reasonable?  Am I doing something stupid?  Are there
other places for man index / other man index options?  Is mandb run on
all systems that modern GNOME's are intended to run on?

Any insight into the last part would be welcome ;)
Thanks
Don




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]