Status changed to 'Confirmed' because the bug affects multiple users.

** Changed in: py3cairo (Ubuntu)
       Status: New => Confirmed

-- 
You received this bug notification because you are a member of Desktop
Packages, which is subscribed to py3cairo in Ubuntu.
https://bugs.launchpad.net/bugs/1330228

Title:
  Surface.create_for_data: Not Implemented yet.

Status in py3cairo package in Ubuntu:
  Confirmed

Bug description:
  Kazam Screen caster, written in Python3, is using Cairo for doing
  graphics. Now, I've run into this:

  File "../kazam/frontend/window_countdown.py", line 181, in createDropShadow
      surface = cairo.ImageSurface.create_for_data(data, format, width, height)
  NotImplementedError: Surface.create_for_data: Not Implemented yet.

  It appears that Surface.create_for_data isn't implemented. After
  inspecting the weird code in the original tar.gz I confirmed this:

  static PyObject *
  image_surface_create_for_data (PyTypeObject *type, PyObject *args) {
    cairo_surface_t *surface;
    cairo_format_t format;
    unsigned char *buffer;
    int width, height, stride = -1, res;
    Py_ssize_t buffer_len;
    PyObject *obj;

    // buffer function disabled
    PyErr_SetString(PyExc_NotImplementedError, "Surface.create_for_data: Not 
Implemented yet.");
    return NULL;    /* By BigW: Everything past here is dead code */

    if (!PyArg_ParseTuple(args, "Oiii|i:Surface.create_for_data",
                          &obj, &format, &width, &height, &stride))
      return NULL;

  
  However, after checking couple of other repositories with pycairo, 
create_for_data() function is different, without the weird return call.

  I've checked:

  http://cgit.freedesktop.org/pycairo/
  git://git.cairographics.org/git/pycairo

  Can this patch from 2011 be included in Ubuntu?
  http://lists.cairographics.org/archives/cairo/2011-December/022563.html

  And why am I the first one running into this? :)

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/py3cairo/+bug/1330228/+subscriptions

-- 
Mailing list: https://launchpad.net/~desktop-packages
Post to     : desktop-packages@lists.launchpad.net
Unsubscribe : https://launchpad.net/~desktop-packages
More help   : https://help.launchpad.net/ListHelp

Reply via email to