Sun, 10 Aug 2025 23:53:22 +0800
Various improvement, Support configuration from UI
|
2
efafd19ab2fe
satoriformat.{c,h}: Add message parsing support
Gong Zhile <gongzl@stu.hebust.edu.cn>
parents:
diff
changeset
|
1 | /* |
|
efafd19ab2fe
satoriformat.{c,h}: Add message parsing support
Gong Zhile <gongzl@stu.hebust.edu.cn>
parents:
diff
changeset
|
2 | * Purple Satori Plugin - Satori Protocol Plugin for Purple3 |
|
efafd19ab2fe
satoriformat.{c,h}: Add message parsing support
Gong Zhile <gongzl@stu.hebust.edu.cn>
parents:
diff
changeset
|
3 | * Copyright (C) 2025 Gong Zhile |
|
efafd19ab2fe
satoriformat.{c,h}: Add message parsing support
Gong Zhile <gongzl@stu.hebust.edu.cn>
parents:
diff
changeset
|
4 | * |
|
efafd19ab2fe
satoriformat.{c,h}: Add message parsing support
Gong Zhile <gongzl@stu.hebust.edu.cn>
parents:
diff
changeset
|
5 | * This library is free software; you can redistribute it and/or |
|
efafd19ab2fe
satoriformat.{c,h}: Add message parsing support
Gong Zhile <gongzl@stu.hebust.edu.cn>
parents:
diff
changeset
|
6 | * modify it under the terms of the GNU Lesser General Public |
|
efafd19ab2fe
satoriformat.{c,h}: Add message parsing support
Gong Zhile <gongzl@stu.hebust.edu.cn>
parents:
diff
changeset
|
7 | * License as published by the Free Software Foundation; either |
|
efafd19ab2fe
satoriformat.{c,h}: Add message parsing support
Gong Zhile <gongzl@stu.hebust.edu.cn>
parents:
diff
changeset
|
8 | * version 2 of the License, or (at your option) any later version. |
|
efafd19ab2fe
satoriformat.{c,h}: Add message parsing support
Gong Zhile <gongzl@stu.hebust.edu.cn>
parents:
diff
changeset
|
9 | * |
|
efafd19ab2fe
satoriformat.{c,h}: Add message parsing support
Gong Zhile <gongzl@stu.hebust.edu.cn>
parents:
diff
changeset
|
10 | * This library is distributed in the hope that it will be useful, |
|
efafd19ab2fe
satoriformat.{c,h}: Add message parsing support
Gong Zhile <gongzl@stu.hebust.edu.cn>
parents:
diff
changeset
|
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
|
efafd19ab2fe
satoriformat.{c,h}: Add message parsing support
Gong Zhile <gongzl@stu.hebust.edu.cn>
parents:
diff
changeset
|
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
|
efafd19ab2fe
satoriformat.{c,h}: Add message parsing support
Gong Zhile <gongzl@stu.hebust.edu.cn>
parents:
diff
changeset
|
13 | * Lesser General Public License for more details. |
|
efafd19ab2fe
satoriformat.{c,h}: Add message parsing support
Gong Zhile <gongzl@stu.hebust.edu.cn>
parents:
diff
changeset
|
14 | * |
|
efafd19ab2fe
satoriformat.{c,h}: Add message parsing support
Gong Zhile <gongzl@stu.hebust.edu.cn>
parents:
diff
changeset
|
15 | * You should have received a copy of the GNU Lesser General Public |
|
efafd19ab2fe
satoriformat.{c,h}: Add message parsing support
Gong Zhile <gongzl@stu.hebust.edu.cn>
parents:
diff
changeset
|
16 | * License along with this library; if not, see <https://www.gnu.org/licenses/>. |
|
efafd19ab2fe
satoriformat.{c,h}: Add message parsing support
Gong Zhile <gongzl@stu.hebust.edu.cn>
parents:
diff
changeset
|
17 | */ |
|
efafd19ab2fe
satoriformat.{c,h}: Add message parsing support
Gong Zhile <gongzl@stu.hebust.edu.cn>
parents:
diff
changeset
|
18 | |
|
efafd19ab2fe
satoriformat.{c,h}: Add message parsing support
Gong Zhile <gongzl@stu.hebust.edu.cn>
parents:
diff
changeset
|
19 | #ifndef SATORI_FORMAT_H |
|
efafd19ab2fe
satoriformat.{c,h}: Add message parsing support
Gong Zhile <gongzl@stu.hebust.edu.cn>
parents:
diff
changeset
|
20 | #define SATORI_FORMAT_H |
|
efafd19ab2fe
satoriformat.{c,h}: Add message parsing support
Gong Zhile <gongzl@stu.hebust.edu.cn>
parents:
diff
changeset
|
21 | |
|
efafd19ab2fe
satoriformat.{c,h}: Add message parsing support
Gong Zhile <gongzl@stu.hebust.edu.cn>
parents:
diff
changeset
|
22 | #include <glib.h> |
|
efafd19ab2fe
satoriformat.{c,h}: Add message parsing support
Gong Zhile <gongzl@stu.hebust.edu.cn>
parents:
diff
changeset
|
23 | #include <purple.h> |
|
efafd19ab2fe
satoriformat.{c,h}: Add message parsing support
Gong Zhile <gongzl@stu.hebust.edu.cn>
parents:
diff
changeset
|
24 | #include <pango/pango-attributes.h> |
|
efafd19ab2fe
satoriformat.{c,h}: Add message parsing support
Gong Zhile <gongzl@stu.hebust.edu.cn>
parents:
diff
changeset
|
25 | |
|
efafd19ab2fe
satoriformat.{c,h}: Add message parsing support
Gong Zhile <gongzl@stu.hebust.edu.cn>
parents:
diff
changeset
|
26 | void |
|
efafd19ab2fe
satoriformat.{c,h}: Add message parsing support
Gong Zhile <gongzl@stu.hebust.edu.cn>
parents:
diff
changeset
|
27 | satori_format_html_to_purple(PurpleConversation *conversation, |
|
efafd19ab2fe
satoriformat.{c,h}: Add message parsing support
Gong Zhile <gongzl@stu.hebust.edu.cn>
parents:
diff
changeset
|
28 | const gchar *html, GString **out_content, |
|
efafd19ab2fe
satoriformat.{c,h}: Add message parsing support
Gong Zhile <gongzl@stu.hebust.edu.cn>
parents:
diff
changeset
|
29 | PangoAttrList *attrs); |
|
efafd19ab2fe
satoriformat.{c,h}: Add message parsing support
Gong Zhile <gongzl@stu.hebust.edu.cn>
parents:
diff
changeset
|
30 | |
|
efafd19ab2fe
satoriformat.{c,h}: Add message parsing support
Gong Zhile <gongzl@stu.hebust.edu.cn>
parents:
diff
changeset
|
31 | #endif /* SATORI_FORMAT_H */ |