X Tutup
Skip to content

imshow bug on GTKCairo and GTK3Cairo #4154

@OceanWolf

Description

@OceanWolf

On master, the following code fails (works fine on master with GTK3Agg and with GTK3Cairo on 1.3.1 (debian))

import matplotlib
matplotlib.use('GTK3Cairo')
import matplotlib.pyplot as plt
import numpy as np

data = np.linspace(0, 10, 80).reshape(10, 8)

plt.imshow(data)
plt.show()
File "matplotlib/lib/matplotlib/backends/backend_cairo.py", line 169, in in draw_image
    buf, cairo.FORMAT_ARGB32, cols, rows, cols*4)
TypeError: Cannot use string as modifiable buffer

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions

    X Tutup