diff options
| author | hallgren <hallgren@chalmers.se> | 2011-10-12 17:03:54 +0000 |
|---|---|---|
| committer | hallgren <hallgren@chalmers.se> | 2011-10-12 17:03:54 +0000 |
| commit | 44d1a5a9f71b03d9aceeccd760a63fcdc45f8bad (patch) | |
| tree | d51076a708997d6f1af6ac0deefd535bbc25f804 /src/www/minibar/minibar_online.js | |
| parent | 0aba45560d2033c37c3d2e876e6f3ef89e1554d6 (diff) | |
Improvements of "gf -server" mode and related setup
"gf -server" mode now contains everything needed to run the minibar and
the grammar editor (including example-based grammar writing).
The Setup.hs script installs the required files where gf -server can find them.
These files have been moved to a new directory: src/www.
The separate server program pgf-http is now obsolete.
Diffstat (limited to 'src/www/minibar/minibar_online.js')
| -rw-r--r-- | src/www/minibar/minibar_online.js | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/src/www/minibar/minibar_online.js b/src/www/minibar/minibar_online.js new file mode 100644 index 000000000..1c15e87bf --- /dev/null +++ b/src/www/minibar/minibar_online.js @@ -0,0 +1,25 @@ +// minibar_demo.js, assumes that minibar.js and pgf_online.js have been loaded. + +var online_options={ + //grammars_url: "http://www.grammaticalframework.org/grammars/", + //grammars_url: "http://tournesol.cs.chalmers.se:41296/grammars/", + //grammars_url: "http://localhost:41296/grammars/", + //grammar_list: ["Foods.pgf"], // leave undefined to get list from server +} + + +if(/^\?\/tmp\//.test(location.search)) { + online_options.grammars_url=location.search.substr(1); +} + +var server=pgf_online(online_options); + +var minibar_options= { + show_abstract: true, + show_trees: true, + show_grouped_translations: false, + default_source_language: "Eng", +//feedback_url: "feedback.html", + try_google: true +} +var minibar=new Minibar(server,minibar_options); |
