From: Tony G. <Ton...@Su...> - 2005-09-09 11:15:19
|
Tony Graham <Ton...@Su...> writes: > Aron Stansvik <elv...@gm...> writes: ... >> I was getting: >> >> fo-image.c: In function `fo_image_get_width': >> fo-image.c:247: error: assignment of read-only member `width' >> fo-image.c: In function `fo_image_get_height': >> fo-image.c:270: error: assignment of read-only member `height' >> >> In this newly added file. I fixed by removing the const constrain on >> the passed in FoImage (patches attached), don't know if that is the >> right thing to do (I'm not such a proficient programmer), but it fixed >> the compilation error. Maybe the real solution to this is to not >> declare the width and height members the way they are declared? The >> funky GObject macros confused my little head. Heh. ... > It is unlikely that an FoImage will be created for which fo_image_get_width() > and fo_image_get_height() will never be called, so it's probably best to > create the FoDatatypes when the image is created. Done. Regards, Tony. |