Plan 9: Dynamic HTML

 

Render Dynamic HTML using plot and qjs.

Render a simple website
 
Font zoom

 

E-Book Reader


eBook is a collection of HTML files in a ZIP archive. Follow same steps for Comic Book reader which are collection of JPG/PNG images in a ZIP/RAR archive.

For columns, pure HTML solution involves column-count CSS property. However, this works only for designed screen sizes. For non-standard sizes, the first column might span multiple pages before continuing in the second column. Hence, the page mode manages the split without relying on the column-count.

 

Keymap

t                    Table of Content

-/=                Font zoom

1,2,3             Column

s                   Toggle scroll/page mode 

Up/down      Scroll

Prev/Next    Chapter navigation 

q                  Quit 

  

Linkedom Fixes

  • Use lowerCaseAttributeNames: isHTML to ignore case for attribute names.
 

Lessons Learnt

  1. Mouse click generates two events like a keypress. If you are doing a zero byte read, you're likely to miss an event as each read pops the event queue.
  2. Screen, keyboard and mouse are separate devices - obviously. However, only Plan 9 allows these to be interacted with via separate programs.
  3. Plan 9 draws a symmetrical line i.e. 2*thickness+1 pixels. Important to note for table calculations. 

 

References

  1. HTML rendering in Emacs 
  2. HTML rendering via SVG 
  3. Browser in Javascript 
  4. Plan 9: Tiled Map 
  5. Comic Book Reader 

 

Miscellaneous

  1. Andrey's port of Links 

 

Comments

Popular posts from this blog

Plan 9 : The Infinity Notebook

Plan 9: Quick Boot with UEFI

Comics Builder in GNU Emacs