[RQt-devel] a couple of minor things

Deepayan Sarkar deepayan.sarkar at gmail.com
Fri Sep 17 13:39:26 CEST 2010


Hi,

A couple of low-priority things that might be nice to have:

(1) In dealing with images, Qt used unsigned int for colors.

> qimg <- Qt$QImage(100, 100, Qt$QImage$Format_ARGB32_Premultiplied)
> qimg$fill(0L)
> qimg$pixel(40, 50)
[1] 0

Is there an easy way to implement conversion to/from R colors? (Maybe
through R color <-> R integer <-> unsigned int.)

(2) QByteArrays are almost like strings, and used in various places. E.g.,

> Qt$QImageReader$supportedImageFormats()
Error in qinvokeStatic(cl, name, ...) :
  Attempt to create SmokeObject with NULL class
> Qt$QByteArray()
NULL

Is there a risk in allowing the conversion?

-Deepayan


More information about the Qtinterfaces-devel mailing list