Logiweb(TM)

6.4.3 A page with a rendering

Prev Up Next Page 70 of 800 Search internet


Now define a file named hw.lgs:

   ""P hw
   ""R base
   page      ( ""N , ""C )
   title     "Hello World"
   bib       " "
   main text "Hello world."
   appendix  "This is an appendix."
   end page

Then translate it:

   > lgc hw
   ...
   Error running bibtex ...
   ...
   Goodbye
   > firefox hw/index.html &

Ignore the bibtex error. Bibtex just whines because you cite nothing. Then view your page:

   > firefox hw/index.html &

Then click 'Index' to get to a page entitled 'Hello World'. The 'Hello World' title is taken from Line 4 of the lgs source above. The 'Hello World' web page points to the following pdf documents:

Main text
The main text says 'Hello world' from Line 6 in the lgs source.
Appendix
The appendix says 'This is an appendix' from Line 7 in the lgs source.
Chores
The 'chores' says that 'hw' has name 'hw' and charge zero. The name and charge definitions come from the N and C escape sequences in Line 3 of the lgs source above.

The 'Hello World' page is signed by 'The Logiweb compiler' as if the compiler is the author. That is not completely true. The rendering is done by the

   page ( ... , ... ) title ... bib ... main text ... appendix ... end page

construct from the base page. But it is the Logiweb compiler lgc which makes the rendering happen and a 'sincerely yours from the page...end page' construct looks silly.

Prev Up Next Page 70 of 800 Search logiweb.eu

Copyright © 2010 Klaus Grue, GRD-2010-01-05