Grammalecte  Check-in [159086011c]

Overview
Comment:[lo] Graphspell: remove trailing dot before looking for suggestions
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk | lo
Files: files | file ages | folders
SHA3-256: 159086011c45879d684030f04e3961892e766f672d5b5dc83dbd59c86271f84d
User & Date: olr on 2023-03-23 11:00:31
Other Links: manifest | tags
Context
2023-03-23
11:14
[graphspell] new ad hoc suggestions check-in: 4a92ae342e user: olr tags: trunk, graphspell
11:00
[lo] Graphspell: remove trailing dot before looking for suggestions check-in: 159086011c user: olr tags: trunk, lo
09:31
[fr] update dictionnary builder: tag checker, maj dictionnaire 7.6 check-in: cc24153f41 user: olr tags: trunk, fr
Changes

Modified gc_lang/fr/oxt/Graphspell.py from [76770ac233] to [4511f8b4ed].

128
129
130
131
132
133
134
135
136
137
138
139
140
141
142

    def spell (self, aWord, aLocale, aProperties):
        "returns an object SpellAlternatives"
        try:
            if not self.bHunspell:
                # Graphspell
                lSugg = []
                for l in self.oGraphspell.suggest(aWord):
                    lSugg.extend(l)
                return SpellAlternatives(aWord, tuple(lSugg))
            # fallback dictionary suggestions (Hunspell)
            return self.xHunspell.spell(aWord, self.xHunspellLocale, aProperties)
        except:
            traceback.print_exc()
        return None







|







128
129
130
131
132
133
134
135
136
137
138
139
140
141
142

    def spell (self, aWord, aLocale, aProperties):
        "returns an object SpellAlternatives"
        try:
            if not self.bHunspell:
                # Graphspell
                lSugg = []
                for l in self.oGraphspell.suggest(aWord.rstrip(".")):
                    lSugg.extend(l)
                return SpellAlternatives(aWord, tuple(lSugg))
            # fallback dictionary suggestions (Hunspell)
            return self.xHunspell.spell(aWord, self.xHunspellLocale, aProperties)
        except:
            traceback.print_exc()
        return None