you might ask this question on the user list to get better response.
can you provide also the text & query you want to highlight?

simon

On Fri, Jun 8, 2012 at 1:17 PM, gerryjun <gerry...@yahoo.com> wrote:
> Hi,
>
>    How can i highlight 3 letter words? everything is working except for
> this, what setting do i need to change?
>
>    Im using  lucene-highlighter-3.6.0.jar & lucene-core-3.6.0.jar.
>
>
>        Analyzer analyzer = new StandardAnalyzer(Version.LUCENE_30);
>        QueryParser parser = new QueryParser(Version.LUCENE_30, "",
> analyzer);
>        parser.setAllowLeadingWildcard(true);
>        SimpleHTMLFormatter htmlFormatter = new SimpleHTMLFormatter("","");
>        Highlighter highlighter = new Highlighter(htmlFormatter,new
> QueryScorer(parser.parse(pQuery)));
>        highlighter.setTextFragmenter(new NullFragmenter());
>        highlighter.setMaxDocCharsToAnalyze(Integer.MAX_VALUE);
>        String text = highlighter.getBestFragment(analyzer, "", pText);
>
> Thanks
>
> --
> View this message in context: 
> http://lucene.472066.n3.nabble.com/lucene-highlighter-3-6-No-highlight-for-3-letter-words-tp3988464.html
> Sent from the Lucene - Java Developer mailing list archive at Nabble.com.
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org
> For additional commands, e-mail: dev-h...@lucene.apache.org
>

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org
For additional commands, e-mail: dev-h...@lucene.apache.org

Reply via email to