The DejaVU Framework -- hush 3.1
[.] Papers Tutorials Examples Manuals Interfaces Sources Packages Resources ?

Manual: BROWSER 7 1996


[.] [man] man1 man2 man3 man4 man5 man6 man7 man8 man9 manl mann ?

NAME

browser - World Wide Web browser

SYNOPSIS


The browser component is a browser for World Wide Web documents. It extends the web(7) widget with a complete user-interface, including scrollbar, navigation buttons (back, forward, reload, home) and an entrybox with the URL. The browser can be used in application programs as a separate browser, for example to read the online documentation.

Because the browser is based on the web(7) widget it contains a validating SGML parser, that complains about errors in SGML documents. The browser is able to display various document types (e.g. HTML, SGML, VRML, video).


slide: SYNOPSIS

INTERFACE


    interface browser : public toplevel
    {
        public:
          browser( const char* p, const char* options="" );
          browser( const widget* w, const char* p, const char* options="" );
          ~browser();
  
          void home(const char* url);
          void load(const char* url);
    };
  

slide: INTERFACE

DESCRIPTION


Because the browser is a widget(4), it contains the standard widget(4) constructors and destructor.

The home function can be used to set the URL that will be loaded whenever the user presses the home button of the browser. To load a document the load function can be called with the URL.


slide: DESCRIPTION

EXAMPLE


    #include <widgets/browser.h>
    #include <unistd.h>
    #include <hush/session.h>
  
    const char* HUSH_URL = "http://www.cs.vu.nl/~hush/";
    const char* HOME_URL = "file:/home/bastiaan/www/ScheuScape/index.html";
  
    class application: public session
    {
        public:
          application(int argc, char* argv[], char* name) : 
                  session(argc, argv, name), 
                  Browser(0) {};
          ~application() {
                  if (Browser) delete Browser;
          };
   
          int main() {
                  Browser = new browser(".browser");
                  Browser->pack();
                  Browser->home(HOME_URL);
                  Browser->load(HUSH_URL);
                  return 0;
          }
   
        private:
          browser* Browser;
    };
   
    int main (int argc, char* argv[])
    {
          application App(argc, argv, "ScheuScape");
          return App.run();
    }
  

slide: EXAMPLE

LIBRARY


web -- file <widgets/browser.h>


slide: LIBRARY

SEE ALSO

web(7), viewer(7), client(7), browser(l)

BUGS


See webbugs(7)

Send questions/bugs to bastiaan@cs.vu.nl


[.] Papers Tutorials Examples Manuals Interfaces Sources Packages Resources ?
Hush Online Technology
hush@cs.vu.nl
09/24/99