Overview
Comment: | [fr][bug] conj_generator: correction: flexion vide si nCut = 0 |
---|---|
Downloads: | Tarball | ZIP archive | SQL archive |
Timelines: | family | ancestors | descendants | both | fr | multid |
Files: | files | file ages | folders |
SHA3-256: |
479b4f4cfb0db85537c88820cc767574 |
User & Date: | olr on 2018-03-21 08:20:44 |
Other Links: | branch diff | manifest | tags |
Context
2018-03-21
| ||
17:06 | [tb] lexicon editor: ui update > search tab + info tab check-in: 93888e7c05 user: olr tags: tb, multid | |
08:20 | [fr][bug] conj_generator: correction: flexion vide si nCut = 0 check-in: 479b4f4cfb user: olr tags: fr, multid | |
08:07 | [lo] lexicon editor: deal with empty dictionary check-in: cac2434abd user: olr tags: lo, multid | |
Changes
Modified gc_lang/fr/modules-js/conj_generator.js from [354852a8f0] to [058e3de2f7].
︙ | ︙ | |||
11 12 13 14 15 16 17 | var conj_generator = { conjugate: function (sVerb, sVerbTag="i_____a", bVarPpas=true) { let lEntry = []; let cGroup = this.getVerbGroupChar(sVerb); for (let [nCut, sAdd, sFlexTags, sPattern] of this.getConjRules(sVerb, bVarPpas)) { if (!sPattern || RegExp(sPattern).test(sVerb)) { | > | | 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 | var conj_generator = { conjugate: function (sVerb, sVerbTag="i_____a", bVarPpas=true) { let lEntry = []; let cGroup = this.getVerbGroupChar(sVerb); for (let [nCut, sAdd, sFlexTags, sPattern] of this.getConjRules(sVerb, bVarPpas)) { if (!sPattern || RegExp(sPattern).test(sVerb)) { let sFlexion = (nCut > 0) ? sVerb.slice(0, -nCut) + sAdd : sVerb + sAdd; lEntry.push( [sFlexion, ":V" + cGroup + "_" + sVerbTag + sFlexTags] ); } } return lEntry; }, getVerbGroupChar: function (sVerb) { sVerb = sVerb.toLowerCase(); |
︙ | ︙ |
Modified gc_lang/fr/modules/conj_generator.py from [4f543d9f23] to [2e696a65e3].
1 2 3 4 5 6 7 8 9 10 11 | # Conjugation generator # beta stage, unfinished, the root for a new way to generate flexions… import re def conjugate (sVerb, sVerbTag="i_____a", bVarPpas=True): lConj = [] cGroup = getVerbGroupChar(sVerb) for nCut, sAdd, sFlexTags, sPattern in getConjRules(sVerb, bVarPpas): if not sPattern or re.search(sPattern, sVerb): | > | | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 | # Conjugation generator # beta stage, unfinished, the root for a new way to generate flexions… import re def conjugate (sVerb, sVerbTag="i_____a", bVarPpas=True): lConj = [] cGroup = getVerbGroupChar(sVerb) for nCut, sAdd, sFlexTags, sPattern in getConjRules(sVerb, bVarPpas): if not sPattern or re.search(sPattern, sVerb): sFlexion = sVerb[0:-nCut] + sAdd if nCut else sVerb + sAdd lConj.append((sFlexion, ":V" + cGroup + "_" + sVerbTag + sFlexTags)) return lConj def getVerbGroupChar (sVerb, ): sVerb = sVerb.lower() if sVerb.endswith("er"): return "1" |
︙ | ︙ |