summaryrefslogtreecommitdiff
path: root/plugins/pychrysalide/glibext/bufferline.c
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/pychrysalide/glibext/bufferline.c')
-rw-r--r--plugins/pychrysalide/glibext/bufferline.c92
1 files changed, 3 insertions, 89 deletions
diff --git a/plugins/pychrysalide/glibext/bufferline.c b/plugins/pychrysalide/glibext/bufferline.c
index ea84567..c88fe7f 100644
--- a/plugins/pychrysalide/glibext/bufferline.c
+++ b/plugins/pychrysalide/glibext/bufferline.c
@@ -51,12 +51,6 @@ static PyObject *py_buffer_line_append_text(PyObject *, PyObject *);
/* Reconstruit et fournit le texte présent sur une ligne tampon. */
static PyObject *py_buffer_line_get_text(PyObject *, PyObject *);
-/* Ajoute une propriété particulière à une ligne donnée. */
-static PyObject *py_buffer_line_add_flag(PyObject *, PyObject *);
-
-/* Retire une propriété particulière à une ligne donnée. */
-static PyObject *py_buffer_line_remove_flag(PyObject *, PyObject *);
-
/* Renseigne sur les propriétés particulières liées à une ligne. */
static PyObject *py_buffer_line_get_flags(PyObject *, void *);
@@ -93,7 +87,9 @@ static PyObject *py_buffer_line_new(PyTypeObject *type, PyObject *args, PyObject
" BufferLine()" \
"\n" \
"Such objets aim to be created from the Chrysalide core only, and" \
- " then get populated by plugins on demand."
+ " then get populated on demand. Thus, these lines can be viewed as" \
+ " cached lines and their properties have to be set through the" \
+ " pychrysalide.glibext.BufferCache instance which contains them."
/* Validations diverses */
@@ -235,78 +231,6 @@ static PyObject *py_buffer_line_get_text(PyObject *self, PyObject *args)
/******************************************************************************
* *
-* Paramètres : self = classe représentant une ligne de tampon. *
-* args = arguments fournis à l'appel. *
-* *
-* Description : Ajoute une propriété particulière à une ligne donnée. *
-* *
-* Retour : - *
-* *
-* Remarques : - *
-* *
-******************************************************************************/
-
-static PyObject *py_buffer_line_add_flag(PyObject *self, PyObject *args)
-{
- BufferLineFlags flag; /* Drapeau à considérer */
- int ret; /* Bilan de lecture des args. */
- GBufferLine *line; /* Version native */
-
- ret = PyArg_ParseTuple(args, "I", &flag);
- if (!ret) return NULL;
-
- if ((flag & ~BLF_ALL) != 0)
- {
- PyErr_SetString(PyExc_ValueError, _("Invalid flag"));
- return NULL;
- }
-
- line = G_BUFFER_LINE(pygobject_get(self));
- g_buffer_line_add_flag(line, flag);
-
- Py_RETURN_NONE;
-
-}
-
-
-/******************************************************************************
-* *
-* Paramètres : self = classe représentant une ligne de tampon. *
-* args = arguments fournis à l'appel. *
-* *
-* Description : Retire une propriété particulière à une ligne donnée. *
-* *
-* Retour : - *
-* *
-* Remarques : - *
-* *
-******************************************************************************/
-
-static PyObject *py_buffer_line_remove_flag(PyObject *self, PyObject *args)
-{
- BufferLineFlags flag; /* Drapeau à considérer */
- int ret; /* Bilan de lecture des args. */
- GBufferLine *line; /* Version native */
-
- ret = PyArg_ParseTuple(args, "I", &flag);
- if (!ret) return NULL;
-
- if ((flag & ~BLF_ALL) != 0)
- {
- PyErr_SetString(PyExc_ValueError, _("Invalid flag"));
- return NULL;
- }
-
- line = G_BUFFER_LINE(pygobject_get(self));
- g_buffer_line_remove_flag(line, flag);
-
- Py_RETURN_NONE;
-
-}
-
-
-/******************************************************************************
-* *
* Paramètres : self = objet Python concerné par l'appel. *
* closure = non utilisé ici. *
* *
@@ -355,16 +279,6 @@ PyTypeObject *get_python_buffer_line_type(void)
METH_VARARGS,
"get_text($self, first_col, last_col, markup, /)\n--\n\nProvide the text of a buffer line."
},
- {
- "add_flag", py_buffer_line_add_flag,
- METH_VARARGS,
- "add_flag($self, flag, /)\n--\n\nAdd a flag to the buffer line."
- },
- {
- "remove_flag", py_buffer_line_remove_flag,
- METH_VARARGS,
- "remove_flag($self, flag, /)\n--\n\nRemove a flag from the buffer line."
- },
{ NULL }
};