Switch to unified view

a/src/qtgui/plaintorich.h b/src/qtgui/plaintorich.h
...
...
14
 *   Free Software Foundation, Inc.,
14
 *   Free Software Foundation, Inc.,
15
 *   59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
15
 *   59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
16
 */
16
 */
17
#ifndef _PLAINTORICH_H_INCLUDED_
17
#ifndef _PLAINTORICH_H_INCLUDED_
18
#define _PLAINTORICH_H_INCLUDED_
18
#define _PLAINTORICH_H_INCLUDED_
19
/* @(#$Id: plaintorich.h,v 1.17 2008-07-01 08:27:58 dockes Exp $  (C) 2004 J.F.Dockes */
19
/* @(#$Id: plaintorich.h,v 1.18 2008-10-03 08:09:35 dockes Exp $  (C) 2004 J.F.Dockes */
20
20
21
#include <string>
21
#include <string>
22
#include <list>
22
#include <list>
23
using std::list;
23
using std::list;
24
using std::string;
24
using std::string;
...
...
35
    vector<int> gslks; 
35
    vector<int> gslks; 
36
};
36
};
37
37
38
/** 
38
/** 
39
 * A class for highlighting search results. Overridable methods allow
39
 * A class for highlighting search results. Overridable methods allow
40
 * for different styles
40
 * for different styles. We can handle plain text or html input. In the latter
41
 * case, we may fail to highligt term groups if they are mixed with html tags.
41
 */
42
 */
42
class PlainToRich {
43
class PlainToRich {
43
public:
44
public:
44
    static const string snull;
45
    PlainToRich(bool inputhtml = false) : m_inputhtml(inputhtml) {}
45
    virtual ~PlainToRich() {}
46
    virtual ~PlainToRich() {}
47
    void set_inputhtml(bool v) {m_inputhtml = v;}
48
46
    /**
49
    /**
47
     * Transform plain text for highlighting search terms, ie in the
50
     * Transform plain text for highlighting search terms, ie in the
48
     * preview window or result list entries.
51
     * preview window or result list entries.
49
     *
52
     *
50
     * The actual tags used for highlighting and anchoring are
53
     * The actual tags used for highlighting and anchoring are
...
...
73
    virtual string header() {return snull;}
76
    virtual string header() {return snull;}
74
    virtual string startMatch() {return snull;}
77
    virtual string startMatch() {return snull;}
75
    virtual string endMatch() {return snull;}
78
    virtual string endMatch() {return snull;}
76
    virtual string startAnchor(int) {return snull;}
79
    virtual string startAnchor(int) {return snull;}
77
    virtual string endAnchor() {return snull;}
80
    virtual string endAnchor() {return snull;}
81
82
protected:
83
    static const string snull;
84
    bool m_inputhtml;
78
};
85
};
79
86
80
#endif /* _PLAINTORICH_H_INCLUDED_ */
87
#endif /* _PLAINTORICH_H_INCLUDED_ */