summaryrefslogtreecommitdiffstats
path: root/pymodule.c
diff options
context:
space:
mode:
authorChristopher Davis <loafier@gmail.com>2006-07-14 10:02:13 +0000
committerChristopher Davis <loafier@gmail.com>2006-07-14 10:02:13 +0000
commit5eaed0dbf78fca2bcf185da0abf1dbf41722deb2 (patch)
tree2ff9c8bc5c8d206f2b7a852609d1eac6bd377d27 /pymodule.c
parent34cdeaae9369af5dce3ce3a4a7756c033bc44cc5 (diff)
downloadirssi-python-5eaed0dbf78fca2bcf185da0abf1dbf41722deb2.tar.gz
irssi-python-5eaed0dbf78fca2bcf185da0abf1dbf41722deb2.tar.xz
irssi-python-5eaed0dbf78fca2bcf185da0abf1dbf41722deb2.zip
finished up themes. time for textui stuff
git-svn-id: http://svn.irssi.org/repos/irssi-python@4297 dbcabf3a-b0e7-0310-adc4-f8d773084564
Diffstat (limited to 'pymodule.c')
-rw-r--r--pymodule.c24
1 files changed, 24 insertions, 0 deletions
diff --git a/pymodule.c b/pymodule.c
index d0d17f7..34413a5 100644
--- a/pymodule.c
+++ b/pymodule.c
@@ -1353,6 +1353,26 @@ error:
}
#endif
+PyDoc_STRVAR(py_themes_reload_doc,
+ "themes_reload() -> None\n"
+);
+static PyObject *py_themes_reload(PyObject *self, PyObject *args)
+{
+ themes_reload();
+ Py_RETURN_NONE;
+}
+
+PyDoc_STRVAR(py_current_theme_doc,
+ "current_theme() -> Theme object\n"
+);
+static PyObject *py_current_theme(PyObject *self, PyObject *args)
+{
+ if (current_theme)
+ return pytheme_new(current_theme);
+
+ Py_RETURN_NONE;
+}
+
static PyMethodDef ModuleMethods[] = {
{"prnt", (PyCFunction)py_prnt, METH_VARARGS | METH_KEYWORDS,
py_prnt_doc},
@@ -1506,6 +1526,10 @@ static PyMethodDef ModuleMethods[] = {
py_strip_codes_doc},
/*{"format_get_text", (PyCFunction)py_format_get_text, METH_VARARGS,
py_format_get_text_doc},*/
+ {"themes_reload", (PyCFunction)py_themes_reload, METH_NOARGS,
+ py_themes_reload_doc},
+ {"current_theme", (PyCFunction)py_current_theme, METH_NOARGS,
+ py_current_theme_doc},
{NULL, NULL, 0, NULL} /* Sentinel */
};