mirror of
https://github.com/xiaoyifang/goldendict-ng.git
synced 2024-11-24 08:34:08 +00:00
Full-text search: Adjust limits for allowed distance between words
This commit is contained in:
parent
362acce554
commit
75a459d40b
|
@ -283,7 +283,7 @@ void FTSResultsRequest::checkArticles( QVector< uint32_t > const & offsets,
|
||||||
if( matchWordNom > 0 )
|
if( matchWordNom > 0 )
|
||||||
{
|
{
|
||||||
unmatchWordNom += 1;
|
unmatchWordNom += 1;
|
||||||
if( distanceBetweenWords > 0 && unmatchWordNom > distanceBetweenWords )
|
if( distanceBetweenWords >= 0 && unmatchWordNom > distanceBetweenWords )
|
||||||
{
|
{
|
||||||
matchWordNom = 0;
|
matchWordNom = 0;
|
||||||
unmatchWordNom = 0;
|
unmatchWordNom = 0;
|
||||||
|
|
|
@ -15,8 +15,8 @@ namespace FTS
|
||||||
|
|
||||||
enum
|
enum
|
||||||
{
|
{
|
||||||
MinDistanceBetweenWords = 1,
|
MinDistanceBetweenWords = 0,
|
||||||
MaxDistanceBetweenWords = 10,
|
MaxDistanceBetweenWords = 15,
|
||||||
MinArticlesPerDictionary = 1,
|
MinArticlesPerDictionary = 1,
|
||||||
MaxArticlesPerDictionary = 10000
|
MaxArticlesPerDictionary = 10000
|
||||||
};
|
};
|
||||||
|
|
Loading…
Reference in a new issue