From: Sikon <ine...@gm...> - 2007-12-20 18:27:11
|
Help support resides in help.c and help.h. The About dialog has also been=20 moved there. The one and currently only documentation file is doc/gtkpod.xml. It's in th= e=20 DocBook format. To use context-sensitive help, call gtkpod_open_help_context (in help.h) using the ID of the chapter or sect1 in the DocBook/XML file as the context. It will first try to open the XML file in yelp (the GNOME help viewer), and if that fails, will open the corresponding HTML file in the browser. =46or example, the call gtkpod_open_help_context("layout-of-gtkpod"); will either open the "Layout of gtkpod" section in the XML file in yelp, or= ,=20 failing that (e.g., if yelp is not installed), will open the file=20 layout-of-gtkpod.html in the web browser. Notes on editing the documentation file: Even if you don't know DocBook, the format of gtkpod.xml should be=20 self-evident. When starting a new chapter or sect1, ALWAYS assign an id to it. It will be= =20 used as the name of the HTML file generated from it, without extension=20 (e.g. "layout-of-gtkpod"). If you don't assign an id, the HTML file will be= =20 created as ".html" and overwritten by any subsequent idless chapters/sect1'= s. After making changes, you may want to run xmlindent to make the XML source= =20 more human-readable. To generate HTML from XML, run make update-docs You will need to have the GNOME DocBook XSL tools installed. There are othe= r=20 DocBook-to-HTML converters, but this one produces the prettiest HTML pages = =2D=20 which are also almost identical to what a GNOME user will see in yelp. Remember to add any new HTML or PNG files to SVN. Notes on importing from the wiki: To quickly convert a wiki page to DocBook, save its contents to a text file= =20 and then run wt2db ( http://tldp.org/downloads/ ). Open the resulting XML file in yelp. It will probably not be well-formed an= d=20 require manual tweaking. Things to check for: * <, & and > in the wiki markup are not automatically converted to <, &a= mp;=20 and >. * Internal links are incorrectly converted to <filename>. Just do a search = for=20 <filename> and convert it to <link linkend=3D"target-chapter-or-section-id"= >. * Nesting of tags - wt2db tends to be confused with correct nestings of=20 </para> and </listitem></itemizedlist>. * Bold and italic are left unaccounted for, you should manually convert it = to=20 <emphasis role=3D"bold"> and <emphasis role=3D"italic">. * Images should be uploaded to the doc/figures directory manually and inclu= ded=20 using the <figure> tag. * Listings ([[code]]) - should be wrapped in <programlisting>, and in a <! [CDATA[ section if there is more than one line. I've imported a current snapshot of the wiki. The documentation will need L= OTS=20 OF POLISH, though. |