1 | /* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */ |
---|
2 | |
---|
3 | /* |
---|
4 | * e-searching-tokenizer.h |
---|
5 | * |
---|
6 | * Copyright (C) 2001 Ximian, Inc. |
---|
7 | * |
---|
8 | * Developed by Jon Trowbridge <trow@ximian.com> |
---|
9 | */ |
---|
10 | |
---|
11 | /* |
---|
12 | * This program is free software; you can redistribute it and/or |
---|
13 | * modify it under the terms of version 2 of the GNU General Public |
---|
14 | * License as published by the Free Software Foundation. |
---|
15 | * |
---|
16 | * This program is distributed in the hope that it will be useful, |
---|
17 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
---|
18 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
---|
19 | * GNU General Public License for more details. |
---|
20 | * |
---|
21 | * You should have received a copy of the GNU General Public License |
---|
22 | * along with this program; if not, write to the Free Software |
---|
23 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 |
---|
24 | * USA. |
---|
25 | */ |
---|
26 | |
---|
27 | #ifndef __E_SEARCHING_TOKENIZER_H__ |
---|
28 | #define __E_SEARCHING_TOKENIZER_H__ |
---|
29 | |
---|
30 | #include <glib.h> |
---|
31 | #include <gtkhtml/htmltokenizer.h> |
---|
32 | |
---|
33 | #define E_TYPE_SEARCHING_TOKENIZER (e_searching_tokenizer_get_type ()) |
---|
34 | #define E_SEARCHING_TOKENIZER(o) (GTK_CHECK_CAST ((o), E_TYPE_SEARCHING_TOKENIZER, ESearchingTokenizer)) |
---|
35 | #define E_SEARCHING_TOKENIZER_CLASS(k) (GTK_CHECK_CLASS_CAST ((k), E_TYPE_SEARCHING_TOKENIZER, ESearchingTokenizerClass)) |
---|
36 | #define E_IS_SEARCHING_TOKENIZER(o) (GTK_CHECK_TYPE ((o), E_TYPE_SEARCHING_TOKENIZER)) |
---|
37 | #define E_IS_SEARCHING_TOKENIZER_CLASS(k) (GTK_CHECK_CLASS_TYPE ((k), E_TYPE_SEARCHING_TOKENIZER)) |
---|
38 | |
---|
39 | typedef struct _ESearchingTokenizer ESearchingTokenizer; |
---|
40 | typedef struct _ESearchingTokenizerClass ESearchingTokenizerClass; |
---|
41 | |
---|
42 | struct _ESearchingTokenizerPrivate; |
---|
43 | |
---|
44 | struct _ESearchingTokenizer { |
---|
45 | HTMLTokenizer parent; |
---|
46 | |
---|
47 | struct _ESearchingTokenizerPrivate *priv; |
---|
48 | }; |
---|
49 | |
---|
50 | struct _ESearchingTokenizerClass { |
---|
51 | HTMLTokenizerClass parent_class; |
---|
52 | |
---|
53 | void (*match) (ESearchingTokenizer *); |
---|
54 | }; |
---|
55 | |
---|
56 | GtkType e_searching_tokenizer_get_type (void); |
---|
57 | |
---|
58 | HTMLTokenizer *e_searching_tokenizer_new (void); |
---|
59 | |
---|
60 | /* For now, just a simple API */ |
---|
61 | |
---|
62 | void e_searching_tokenizer_set_primary_search_string (ESearchingTokenizer *, const gchar *); |
---|
63 | void e_searching_tokenizer_set_primary_case_sensitivity (ESearchingTokenizer *, gboolean is_case_sensitive); |
---|
64 | |
---|
65 | void e_searching_tokenizer_set_secondary_search_string (ESearchingTokenizer *, const gchar *); |
---|
66 | void e_searching_tokenizer_set_secondary_case_sensitivity (ESearchingTokenizer *, gboolean is_case_sensitive); |
---|
67 | |
---|
68 | |
---|
69 | gint e_searching_tokenizer_match_count (ESearchingTokenizer *); |
---|
70 | |
---|
71 | |
---|
72 | #endif /* __E_SEARCHING_TOKENIZER_H__ */ |
---|
73 | |
---|