[Mono-dev] Cairo.ImageSurface

John Luke john.luke at gmail.com
Fri Apr 14 19:37:02 EDT 2006


Hello,
On Fri, 14 Apr 2006 14:31:03 -0400, Philipp Baer <phbaer at npw.net> wrote:

> Hi,
>
> this time I have a simple question regarding the Cairo.ImageSurface
> class. The ImageSurface constructor for pre-initialized data buffers
> wraps the cairo_image_surface_create_for_data function call using a
> string as the data parameter. Why?
It was wrapped incorrectly.
(maybe 'unsigned char *data' originally went to char[], and then someone  
made it string)

>
> I must admit that I don't exactly know how the content of a string
> is passed to the non-managed context. Because of the fact that a
> string is composed of chars (which represent 2-byte unicode characters),
> the raw string buffer presumably is a char array. IMO a byte array
> would be much better suited (it simply is more generic).
>
Yes. If you can resend it as a patch, something like that could probably  
be committed.



More information about the Mono-devel-list mailing list