Commit Graph
100 Commits
Author SHA1 Message Date
bjorn 7a5e2a15bd Fixe copy-paste error: srgs_abnf_nonrec produced xml, fixed now. 2008-09-25 11:36:04 +00:00
bjorn cc7173a034 Somewhat nicer FCFG output format. 2008-09-25 08:44:23 +00:00
bjorn cdc647e788 Added an FCFG output format (--output-format=fcfg). This now lives in GF.Speech.PGFToCFG, but should probably move somewhere else. 2008-09-25 08:41:49 +00:00
bjorn 34c5617ef6 Got SRGS ABNF generation to compile. 2008-09-23 12:56:25 +00:00
bjorn 75df5cf443 Added srgs_abnf_nonrec grammar printer to GF.Infra.Options. 2008-09-23 12:44:17 +00:00
bjorn e5779fc594 Re-added old PrSRGS_ABNF (does not compile yet). 2008-09-23 12:41:44 +00:00
bjorn 4862018f14 GWT: somewhat nicer iterable() hack. 2008-09-22 10:11:15 +00:00
bjorn 0031276944 Added iterable() method for nicer iteration through GF method results. (GWT) 2008-09-21 20:37:27 +00:00
bjorn e9f915ba9c Fixed gf-morpho-server.cabal name typo. Added basic README for morpho server. 2008-09-18 20:12:01 +00:00
bjorn 0fdf2ceea2 GWT: disable translation until the language info has been loaded from the server, 2008-09-17 13:25:08 +00:00
bjorn 6fab2a64f4 GWT: update to use new /grammar resource. Select from language based on Accept-Language header. 2008-09-17 13:04:10 +00:00
bjorn c99ce1fd0d fastcgi: rename /info to /grammar 2008-09-17 12:42:05 +00:00
bjorn db6ff30694 fastcgi: replace /categories, /languages and /mylanguage with /info. 2008-09-17 12:37:34 +00:00
bjorn 417ada31f5 fastcgi server: add /mylanguage resource, which selects the language that best matches the Accept-language header. 2008-09-17 12:22:17 +00:00
bjorn 50e600763f GWT: comment out flag icon stuff in CSS. 2008-09-17 11:40:35 +00:00
bjorn b06039634e Towards looking at the locale for default language. Added flag icons. 2008-09-17 10:12:36 +00:00
bjorn 5c2eae8abd Better error handling in GWT UI. 2008-09-16 13:53:07 +00:00
bjorn 117b38e47f GWT client: set Accept header to get plain text error messages, 2008-09-15 15:43:37 +00:00
bjorn c72df9914e Added loading popup to gwt ui 2008-09-15 15:27:33 +00:00
bjorn 6fce3054e3 fastcgi server: decode UTF-8 inputs produced by the gwt client 2008-09-15 15:20:15 +00:00
bjorn b6635b200f gwt installball should not contain gf.fcgi 2008-09-15 14:40:05 +00:00
bjorn ce50458877 GWT: only allow a single compeltion request at a time. 2008-09-15 14:39:25 +00:00
bjorn 6edca9983a Use abs path for gf.fcgi in gwt client. 2008-09-15 14:16:56 +00:00
bjorn eb15d88404 Fixes to the GWT UI to be able to run it on other machines (still some hardcoded paths in the compilation). 2008-09-15 13:49:55 +00:00
bjorn aecf9597eb Added partial word completion to fastcgi server and update GWT UI accordingly. 2008-09-15 13:33:40 +00:00
bjorn 3a7888e660 A somewhat better solution to the words/UTF-8 problem: do encoding last, but only on what appears to be string literals. 2008-09-15 13:16:04 +00:00
bjorn dbb0f3f3e4 Temporary fix for the grave accent a encoding problem: change compatPrint to id.
The problem is that lower case a with a grave accent is coded in UTF-8 as \195\160. 
Unicode character \160 is non-breaking space, so Haskell's words function
will break a UTF-8 encoded string at this character.
String literals in the .gfo file are UTF-8 encoded in generateModuleCode,
just before the call to prGrammar (which uses compactPrint, which used words).
The real solution would be to pretty-print the grammar to Unicode, and then
encode as UTF-8. The problem with that is Latin-1 identifers. They are now
kept in Latin-1 in the .gfo file, since Alex can't handle Unicode.
The real solution to that would be to fix Alex to handle Unicode, but 
that is non-trivial. GHC interally uses a very hacky .x file to be
able to lex UTF-8 source files. 

An alternative solution that doesn't address the weirdness of using two different
encodings in the same .gfo as we do now, is to incorporate compactPrint
into the grammar printer, to avoid having to do any postprocessing.
2008-09-15 12:38:37 +00:00
bjorn becdc147d2 Somewhat nicer gwt client ui style. 2008-09-12 21:07:14 +00:00
bjorn 426b4e8a5b GWT client now has the same func 2008-09-12 11:47:41 +00:00
bjorn e290d744e4 server: changes lang field to name 2008-09-12 11:32:30 +00:00
bjorn 24d82d5a48 Update gf-client.html with new gf.fcgi output types. 2008-09-12 11:14:02 +00:00
bjorn a7bf88fb32 Change JSON structures returned by the translation server to always be arrays of objects. 2008-09-12 11:05:38 +00:00
bjorn 1a320db136 translation server: added limit argument to /complete. 2008-09-12 10:13:16 +00:00
bjorn 45331ffa9c Started working on Google Web Toolkit version of translation server ui. 2008-09-12 10:03:12 +00:00
bjorn 92ffc5072a Fix binary-dist to include gfc and exclude compiled grammars, since the latter didn't work anyway. NOTE: you must re-run autoconf (actually the previous patch is the one that requires this). 2008-09-11 08:35:17 +00:00
bjorn 8a0e9077ce Remove old editor shell script and configure stuff. 2008-09-11 08:30:29 +00:00
bjorn a66913b00a Change version number in configure.ac to 3.0-beta2 too. 2008-09-10 12:48:34 +00:00
bjorn 72b11abe72 Added temporary completions button to AJAX translation UI. 2008-09-10 11:57:00 +00:00
bjorn d6e20ca0bc Note about deleting /tmp/fcgi_ipc 2008-09-10 11:55:10 +00:00
bjorn 7208ead223 missing sudo in erver README 2008-09-10 11:52:45 +00:00
bjorn 5210d1745c mod_fastcgi installation instructions in src/server/README 2008-09-10 08:44:18 +00:00
bjorn 6e6efb14f7 Note that Apache must be restarted after config changes. 2008-09-10 08:19:50 +00:00
bjorn b9066feacc Fix type error in fastcgi server.
I forgot to fix this after I copied the modified FastCGIUtils from morpho-server.
2008-09-10 07:09:44 +00:00
bjorn e566530c4a More info in src/server/README. 2008-09-09 12:38:45 +00:00
bjorn 6eae3fcf68 Disable translation on every keystroke, and completion, in the gf FastCGI AJAX client, since it can be too slow. 2008-09-09 12:19:28 +00:00
bjorn 207ddc4cb6 Added --haskell-prefix option for changing the constructor prefix in generated Haskell modules. 2008-09-03 15:42:11 +00:00
bjorn d1ebdf8154 gf-server: the readData function given to getData should be m a, not IO a. 2008-08-24 20:44:30 +00:00
bjorn b3ab690ddd First (hacky) working version of FastCGI JSON morphology server. 2008-08-24 19:31:12 +00:00
bjorn a8f0546574 Move CGIError stuff to FastCGIUtils. 2008-08-24 19:12:44 +00:00
bjorn 5c0487200f URL decode text input in fastcgi server, including %uXXXX sequences. 2008-08-24 17:39:24 +00:00
bjorn 23a6375ced Completed SISR 1.0 support (untested). 2008-08-24 14:53:21 +00:00
bjorn a415c83319 Export modifyFlags and modifyModuleFlags from GF.Infra.Options. 2008-08-24 14:52:49 +00:00
bjorn cc2442bec4 Re-enable Catalan in the server demo grammar. 2008-08-24 10:19:44 +00:00
bjorn 90d41b4f4e Added target for building translation server grammar for LangX. 2008-08-23 10:33:16 +00:00
bjorn 8cf0d654ba Added README with build instructions for the fastcgi server. 2008-08-22 13:16:31 +00:00
bjorn c345a087bb Don't include DemoCat in server example grammar, since some parts are missing. 2008-08-22 13:15:51 +00:00
bjorn 52af19bd64 UTF8 encode all generated XML. 2008-08-22 09:47:42 +00:00
bjorn b6785df0d2 In GF.Compile.Export, output file name extensions should not have double dots. 2008-08-22 09:27:44 +00:00
bjorn a76a118ec9 Renamed the gf3 executable to gf in GF.cabal 2008-08-22 08:45:40 +00:00
bjorn cb98536de1 Added srgs_xml_nonrec output format. 2008-08-22 08:43:58 +00:00
bjorn 3e5414ba4a Removed Overload modules from GF.cabal. 2008-08-22 07:18:34 +00:00
bjorn 7d83d90e51 Use overloaded API in peace keeping grammar. Still not compiling, "no instance of mkS for Cl among ... Cl ... ?" 2008-08-19 14:35:45 +00:00
bjorn 9242bdfcc8 tweak ajax client html 2008-08-19 12:40:17 +00:00
bjorn e1584715cc First version of ajax / fastcgi interface with completion. 2008-08-19 12:29:31 +00:00
bjorn bd977e7587 Remove src/server/grammar.pgf from the repo, use 'make food' if you want it. 2008-08-19 08:14:22 +00:00
bjorn d33fe739a7 Added parse and linearize functions to the fastcgi server. Some refactoring. 2008-08-19 08:13:51 +00:00
bjorn bc3281d5e7 Fix order in the cncnames list in unionPGF. It was made in reverse. 2008-08-19 07:40:45 +00:00
bjorn 55603b78f6 Ajax: use onsubmit instead of onclick, to catch Firefox auto-submit-on-enter. 2008-08-18 20:56:30 +00:00
bjorn c102ab157a Ajax translator: copied iPhone viewport stuff from Aarne's JS translator, untested. 2008-08-18 20:28:22 +00:00
bjorn 972d7e4058 AJAX translator: update translation when the from or to language is changed. 2008-08-18 20:26:52 +00:00
bjorn 401d1cd7d1 Some peacekeeping clean-up, still far from compiling. 2008-08-18 20:22:25 +00:00
bjorn 256ab54807 Include all languages in the demo pgf for the fastcgi server. 2008-08-18 20:21:02 +00:00
bjorn c6c9028022 Sort languages in fastcgi /languages output. 2008-08-18 20:20:32 +00:00
bjorn dc1db399f6 When producing PGF, do UTF-8 encoding of the whole file after pretty printing instead of walking through the PGF structure before pretty-printing.
The old code was brittle, and only converted strings in the lins and opers, not in printnames and parsers. The old code also double encoded some grammars when using gfc to combine PGF files.
2008-08-18 12:34:56 +00:00
bjorn 255b5488f4 Updated AJAX translator to make use of canParse and the fixed parseAllLangs. 2008-08-18 09:38:21 +00:00
bjorn 7007a875e3 Added canParse function to the PGF API. Make parseAllLang and parseAll skip languages which don't have parsers, instead of always throwing exceptions when some language is missing a parser. 2008-08-18 09:26:24 +00:00
bjorn 3a21fcd4ba Added languageCode function to the PGF API. 2008-08-18 09:25:43 +00:00
bjorn d22474ea8d Updated resource grammar fle list in GF.cabal 2008-08-18 08:47:39 +00:00
bjorn f28dc5ac16 gfc can now combine PGF files. 2008-08-15 21:10:54 +00:00
bjorn 137133b742 Added peacekeeping example back in. Doesn't compile yet. 2008-08-15 20:21:12 +00:00
bjorn 22c434a39b Added Makefile for fastcgi server. 2008-08-15 20:33:04 +00:00
bjorn 5bdfedcedf Qualify PGF import in fastcgi server, to avoid hiding Language, which breaks with older cgi versions. 2008-08-15 20:31:23 +00:00
bjorn 0475ef3414 Added a basic stylesheet for the js and ajax translators. 2008-08-15 11:46:36 +00:00
bjorn 7a2268d9d5 JS translator: fixed typo, before a ul was produced instead of an li 2008-08-15 11:28:41 +00:00
bjorn 08fae303df First working version of the AJAX translation client. 2008-08-15 11:14:13 +00:00
bjorn bf7ec18141 Started working on an AJAX client for the fastcgi server. 2008-08-14 15:56:52 +00:00
bjorn 094150fde1 Added /cats and /langs to fastcgi server. 2008-08-14 15:56:38 +00:00
bjorn b2e7b6f89d Better error handlig in the GF FastCGi server. 2008-08-14 12:08:38 +00:00
bjorn a7aa8fb981 Added first version of the GF FastCGI server. 2008-08-14 09:06:26 +00:00
bjorn 77270a010a Remove the grammars directory. It was full of old grammars that don't compile these days. See the old source distributions if you want them. 2008-08-14 07:58:04 +00:00
bjorn 0bbb906141 Remove src/module-structure.txt, it's about the restructuring in GF 2.2. 2008-08-14 07:14:22 +00:00
bjorn 6619326df0 Include concrete syntax flags in generated JS. 2008-08-13 12:08:11 +00:00
bjorn d6f2d6d170 Don't build lib twice in make binary-dist. 2008-06-27 18:16:46 +00:00
bjorn c10ce9ccf0 Build gfdoc in binary-dist, since the tarball includes it. 2008-06-27 18:15:27 +00:00
bjorn 5f6691dac3 Set charset to utf-8 when printing html code. This is needed to get Safari to display resdemo.html correctly. 2008-06-27 18:14:19 +00:00
bjorn a6e7b8d2a3 Drop java-related stuff from Makefile.binary. 2008-06-27 18:02:54 +00:00
bjorn 0dde13ed6f Changed version number in configure.ac. 2008-06-27 18:02:05 +00:00
bjorn 313ef2908d Changed src-3.0 to src in GF.cabal 2008-06-25 18:29:21 +00:00
bjorn e459cc7771 Include coding flag in .gfo files.
Because the PGF file gets all the flags from the GFO file automatically, we get the coding flag in the PGF file too. This is undesirable, since PGF is supposed to always by in UTF-8.
2008-06-25 18:14:45 +00:00
bjorn 53a8693f3a quote stirng in getDataDir as generated by make today 2008-06-25 17:20:16 +00:00