|
a/src/qtgui/plaintorich.h |
|
b/src/qtgui/plaintorich.h |
1 |
#ifndef _PLAINTORICH_H_INCLUDED_
|
1 |
#ifndef _PLAINTORICH_H_INCLUDED_
|
2 |
#define _PLAINTORICH_H_INCLUDED_
|
2 |
#define _PLAINTORICH_H_INCLUDED_
|
3 |
/* @(#$Id: plaintorich.h,v 1.2 2005-10-10 13:24:53 dockes Exp $ (C) 2004 J.F.Dockes */
|
3 |
/* @(#$Id: plaintorich.h,v 1.3 2006-01-19 12:01:43 dockes Exp $ (C) 2004 J.F.Dockes */
|
4 |
|
4 |
|
5 |
#include <string>
|
5 |
#include <string>
|
6 |
|
6 |
|
7 |
/**
|
7 |
/**
|
8 |
* Fix result text for display inside the gui text window.
|
8 |
* Transform plain text into qt rich text for the preview window.
|
|
|
9 |
*
|
|
|
10 |
* We mainly escape characters like < or &, and add qt rich text tags to
|
|
|
11 |
* colorize the query terms.
|
9 |
*
|
12 |
*
|
10 |
* @param in raw text out of internfile.
|
13 |
* @param in raw text out of internfile.
|
11 |
* @param terms list of query terms
|
14 |
* @param terms list of query terms
|
12 |
* @param termoffsets character offsets where we find terms
|
15 |
* @param termoffsets output: character offsets where we find terms.
|
13 |
*/
|
16 |
*/
|
14 |
extern string plaintorich(const string &in,
|
17 |
extern string plaintorich(const string &in,
|
15 |
const list<string>& terms,
|
18 |
const list<string>& terms,
|
16 |
list<pair<int, int> >&termoffsets);
|
19 |
list<pair<int, int> >&termoffsets);
|
17 |
|
20 |
|
18 |
extern string stripMarkup(const string &in);
|
|
|
19 |
|
|
|
20 |
#endif /* _PLAINTORICH_H_INCLUDED_ */
|
21 |
#endif /* _PLAINTORICH_H_INCLUDED_ */
|