mirror of
https://github.com/kovidgoyal/kitty
synced 2026-06-11 11:09:16 +02:00
Forgot to change a couple of usages of line_as_unicode
This commit is contained in:
@@ -278,7 +278,7 @@ __str__(HistoryBuf *self) {
|
||||
if (lines == NULL) return PyErr_NoMemory();
|
||||
for (index_type i = 0; i < self->count; i++) {
|
||||
init_line(self, index_of(self, i), self->line);
|
||||
PyObject *t = line_as_unicode(self->line);
|
||||
PyObject *t = line_as_unicode(self->line, false);
|
||||
if (t == NULL) { Py_CLEAR(lines); return NULL; }
|
||||
PyTuple_SET_ITEM(lines, i, t);
|
||||
}
|
||||
|
||||
@@ -388,6 +388,12 @@ __repr__(Line* self) {
|
||||
return ans;
|
||||
}
|
||||
|
||||
static PyObject*
|
||||
__str__(Line* self) {
|
||||
return line_as_unicode(self, false);
|
||||
}
|
||||
|
||||
|
||||
static PyObject*
|
||||
width(Line *self, PyObject *val) {
|
||||
#define width_doc "width(x) -> the width of the character at x"
|
||||
@@ -907,7 +913,7 @@ PyTypeObject Line_Type = {
|
||||
.tp_basicsize = sizeof(Line),
|
||||
.tp_dealloc = (destructor)dealloc,
|
||||
.tp_repr = (reprfunc)__repr__,
|
||||
.tp_str = (reprfunc)line_as_unicode,
|
||||
.tp_str = (reprfunc)__str__,
|
||||
.tp_as_sequence = &sequence_methods,
|
||||
.tp_flags = Py_TPFLAGS_DEFAULT,
|
||||
.tp_richcompare = richcmp,
|
||||
|
||||
Reference in New Issue
Block a user