Thomas Hallgren
33aeb53f7a
PGFService: userLanguage now defaults to English, if present in the grammar
...
The userLangauge is the name of the concrete syntax that has a languageCode
that matches the user's preferred language, as reported by the web browser.
If no matching language code is found, the PGF service now sets userLanguage
to the concrete syntax for English (e.g. FoodsEng) if present, and defaults
to the first concrete syntax (e.g. FoodsAfr) only if English is not present
in the grammar.
2019-11-26 15:27:02 +01:00
Thomas Hallgren
e6b33ac8b8
Minibar: make it possible to configure a list of preferred grammars
...
A preferred grammar is selected when a user visits the Minibar for the
first time. (Like before, Minibar remembers the selected grammar for future
visits.)
A preferred list of grammars can be specified in config.js in the .../minibar
directory on the server, e.g. like this:
preferred_grammars=["/grammars/Foods.pgf","/grammars/ResourceDemo.pgf"]
The first available grammar from the list is used.
2019-11-21 14:25:07 +01:00
Thomas Hallgren
28f53e801a
PGFService: revert unlexing change in PGFService to restore &+ behaviour
2019-11-18 13:20:41 +01:00
aarneranta
6f2b1a83b7
fixed a vd bug that sometimes erased the root label
2019-11-13 11:40:37 +01:00
aarneranta
d3b501d35f
fixed the problem with generating several roots in ud2gf. Now only the leftmost word becomes ROOT, the others become dep - which can be eliminated by cnclabels. This works fine for e.g. English prepositional and particle verbs. But it does not work if the 'main' word is not the leftmost one
2019-11-12 17:46:55 +01:00
krangelov
95b3fb306f
forgot that debugging is on
2019-10-09 14:34:04 +02:00
krangelov
5b790b82c5
fix chunk extraction when there are literals
2019-10-09 14:32:20 +02:00
krangelov
26361b3692
fix the parsing for literals after the latest changes in the parser
2019-10-09 14:18:05 +02:00
krangelov
30eef61f0a
more dead code
2019-09-20 16:15:28 +02:00
krangelov
29662350dc
removed more dead code
2019-09-20 10:49:29 +02:00
krangelov
4d79aa8b19
remove obsolete code
2019-09-20 10:37:50 +02:00
Thomas Hallgren
9d3badd8b2
GrammarToCanonical: bug fix: add missing case for Empty
2019-09-10 12:41:16 +02:00
krangelov
e2ddea6c7d
first version of a parser which returns chunks in case of failure
2019-08-30 13:31:57 +02:00
krangelov
59a6e3cfdd
fix gu_map_next
2019-08-30 13:31:19 +02:00
krangelov
1e8d684f9a
Merge branch 'master' of https://github.com/GrammaticalFramework/gf-core
2019-08-30 08:12:52 +02:00
krangelov
72cfc1f48a
a more reasonable API to iterate over a map
2019-08-30 08:12:15 +02:00
Thomas Hallgren
a7a592d93e
Merge branch 'master' of https://github.com/GrammaticalFramework/gf-core
2019-08-21 14:33:30 +02:00
Thomas Hallgren
d1bb1de87f
Minibar: support for links to open a given grammar in the minibar
...
When you press the "i" or "More info" button for a grammar, the info now
includes a link that can be used by anyone to open this specific grammar in
the minibar.
2019-08-21 14:27:56 +02:00
krangelov
394d033d19
added gu_map_delete
2019-08-20 18:55:36 +02:00
krangelov
cb678dfdc8
fix packages
2019-08-18 09:37:55 +02:00
krangelov
4161bbf0ec
fix reference to FastCGIUtils
2019-08-18 09:12:30 +02:00
krangelov
148590927c
remove obsolete code
2019-08-18 09:09:40 +02:00
krangelov
85a81ef741
Merge branch 'master' of https://github.com/GrammaticalFramework/gf-core
2019-08-09 15:18:27 +02:00
krangelov
3e662475ee
bugfix in the parser's scanner
2019-08-09 15:15:30 +02:00
John J. Camilleri
85f12a5544
Remove wrong Haddock comment in PGF2
...
Clearly just a copy-paste error
2019-08-07 12:52:17 +02:00
Thomas Hallgren
81362ed7b7
Minibar can now display grammar documentation.
...
The documentation is taken from a file called Grammar.pgf_info, located
next to the Grammar.pgf file on the server.
The first line of the documentation is displayed below the menu bar in
the minibar. The rest of the documentation is displayed when you press
the "More info" button (or the "i" button).
The documentation can contain HTML markup. Blank lines are treated as
paragraph breaks.
2019-08-05 15:25:29 +02:00
John J. Camilleri
12079550f8
Remove TypeScript runtime and point to new repository
...
https://github.com/GrammaticalFramework/gf-typescript
2019-07-11 09:29:49 +02:00
John J. Camilleri
eab9fb88aa
Minor renamings in JSON format
2019-07-10 08:49:00 +02:00
John J. Camilleri
acd4a5e8cd
Address @heatherleaf's suggestions
2019-07-10 08:45:23 +02:00
John J. Camilleri
a4b1fb03aa
Whitespace fixes
2019-07-07 17:38:07 +02:00
John J. Camilleri
cb88b56016
Finish compile to PGF JSON, including JSON schema for resulting format.
2019-07-07 17:35:31 +02:00
John J. Camilleri
ecf9b41db0
Finish JSON conversion for abstract
2019-07-03 16:34:07 +02:00
John J. Camilleri
c5a75c482c
Start work on PGFtoJSON module. Add compiler flag -f json.
2019-07-03 15:07:31 +02:00
krangelov
32379a8d11
fully supported case-insensitive parsing/lookup
2019-06-30 08:48:23 +02:00
krangelov
b56591c6b6
the parser now ensures that all word senses are in the chart
2019-06-25 12:58:28 +02:00
krangelov
b94bb50ec9
fix in gu_buf_heap_pop
2019-06-24 12:27:36 +02:00
krangelov
e2395335cb
Merge branch 'master' of https://github.com/GrammaticalFramework/gf-core
2019-06-24 12:14:15 +02:00
krangelov
2d9478b973
share some code for printing
2019-06-24 12:13:14 +02:00
John J. Camilleri
17e3f753fb
gflib.ts: put warning on console when function undefined
2019-06-13 14:43:21 +02:00
John J. Camilleri
498ad572ac
gflib.ts: fix in annotation when type is unknown
2019-06-13 14:12:53 +02:00
John J. Camilleri
bc61f8c191
gflib.ts: generate source map, which is helpful for debugging
2019-06-13 13:53:58 +02:00
John J. Camilleri
d252cfd610
gflib.ts: handled unimplemented functions during linearisation
2019-06-13 10:31:49 +02:00
John J. Camilleri
46a1bdc7ea
gflib.ts: also accept U+00C0-U+00FF (\192-\255) in idents in parseTree
...
Matches definition in src/compiler/GF/Grammar/Lexer.x
2019-06-12 15:28:25 +02:00
John J. Camilleri
18d0e1fad0
gflb.ts: add comments about startsWith polyfill, making into module
2019-06-12 09:51:27 +02:00
John J. Camilleri
ab94e93b94
Avoid modifying String prototype in TypeScript runtime
...
Adds new class TaggedString
2019-06-10 11:39:31 +02:00
John J. Camilleri
a229507392
Use strict mode in TypeScript, catch some more corner cases
2019-06-10 11:14:14 +02:00
John J. Camilleri
6a9c917b29
TypeScript readme
2019-06-10 10:19:43 +02:00
John J. Camilleri
9ba4a42426
Add generated gflib.js under typescript/js. Add deprecation notice in javascript.
2019-06-10 10:15:03 +02:00
John J. Camilleri
bbd1c9147a
Catch for when rules are undefined
2019-06-10 09:48:44 +02:00
John J. Camilleri
4793d376d9
Create copies when tagging
...
Not sure if this behaviour is identical to previous version,
or in truth how important it really is anyway
2019-06-10 09:45:04 +02:00