Re: [Qt-qml] on device performance

2010-12-14 Thread Juha Turunen
On Tue, Dec 14, 2010 at 1:51 PM, Cornelius Hald wrote: > As far as I know Symbian automatically uses OpenGL or OpenVG if > available. You have to #ifdef this part of the code :( You might also > want to have a look at this blog: > http://thpmaemo.blogspot.com/2010/10/qt-write-once-ifdef-everywhere

Re: [Qt-qml] Loading font from resource file not working on Symbian

2010-12-08 Thread Juha Turunen
>> You need to tell the Symbian FBS (font and bitmap server) that it >> should add your font to the typeface store. You can do that with this >> bit of code: >> >>     TInt id; >>     CEikonEnv::Static()->ScreenDevice()->AddFile(_L("> font file>"), id); > > Looks a bit scary to a Symbian noob like

Re: [Qt-qml] Loading font from resource file not working on Symbian

2010-12-08 Thread Juha Turunen
Hi, I think the Symbian Qt port is just lacking functionality in this department (don't know about Maemo). You can work around this though with some Symbian specific code. Non-damaged souls and uninterested parties, please close your eyes for the rest of this e-mail. You need to tell the Symbian

Re: [Qt-qml] Returning a QImage to QML from C++ for a ListView delegate...

2010-11-12 Thread Juha Turunen
Hi Ray, You can implement this by inheriting your own image provider from QDeclarativeImageProvider (http://doc.qt.nokia.com/4.7-snapshot/qdeclarativeimageprovider.html). Using it you have a choice of returning QPixmaps and QImages. There's a catch though. You can't modify (well you can, but you'r

Re: [Qt-qml] How get informations from a qml-object ?

2010-11-08 Thread Juha Turunen
Hi Thomas, If the item you want to refer to has an id (not dynamically created) you can give the "rootitem" in your main.qml and id and then simply refer to it or bind other properties to it by it's id. For example: First.qml: import Qt 4.7 Item { id: screen width: 500 height: 300

Re: [Qt-qml] rgb colors does not work?

2010-09-30 Thread Juha Turunen
The range of all components (not just alpha) goes from 0 to 1. So essentially you're maxing out all components -> the color is white. Juha On Thu, Sep 30, 2010 at 6:24 PM, Bartosh Wroblevksy wrote: > *Hi,* > * > * > *With Qt 4.7.0 > * > * > > import Qt 4.7 > > Rectangle { > > width:100 > >

Re: [Qt-qml] Performance issue with Repeater

2010-09-19 Thread Juha Turunen
unds like the > Flickable type? > > On 10-09-19 5:37 PM, Juha Turunen wrote: >> How about using a ListView instead of Flickable? This way everything >> doesn't have to be instantiated at once, but instead ListView smartly >> creates (and disposes) instances of the dele

Re: [Qt-qml] Performance issue with Repeater

2010-09-19 Thread Juha Turunen
How about using a ListView instead of Flickable? This way everything doesn't have to be instantiated at once, but instead ListView smartly creates (and disposes) instances of the delegate component as the user scrolls the view. Juha On Mon, Sep 20, 2010 at 12:19 AM, Sohail Somani wrote: > Hi, >

Re: [Qt-qml] QML and graphics item caching

2010-09-03 Thread Juha Turunen
On Fri, Sep 3, 2010 at 6:05 PM, Adriano Rezende wrote: > AFAIK cacheMode is not exposed in QML side. But for what you want > there is not official support even in QGraphicsView side. > There was an idea to implement a DeepItemCacheMode that would do > exactly this, but it was forgotten and never

Re: [Qt-qml] Transparent background

2010-08-26 Thread Juha Turunen
You could try: http://doc.qt.nokia.com/4.6/qgraphicsview.html#backgroundBrush-prop Juha On Thu, Aug 26, 2010 at 8:43 PM, Anton Alferov wrote: > I suppose that desktop (or other windows) still will not be visible under my > window prepared with that code. > I think I need to write something like

[Qt-qml] QML and graphics item caching

2010-07-28 Thread Juha Turunen
Hi all, I'm developing an app with a QML UI and targeting a mobile device which I know to have pretty modest graphics performance. Let's assume I have two views that fill the whole screen and I want to animate between them by simply scrolling the new one in while the old one scrolls out. The view

Re: [Qt-qml] Working with larger projects.

2010-07-16 Thread Juha Turunen
On Fri, Jul 16, 2010 at 4:32 PM, Jason H wrote: > > My immediate task is: > I have 2 QML files and qmproject file. I added a 3rd "main.qml". I want to > have > the main load the two other QML files and switch between them. (Each file > defines a "page") However, I would actually like the main to

Re: [Qt-qml] Why can't I anchor to parent

2010-07-12 Thread Juha Turunen
You anchor to a parent like this: anchors.top: parent.top Check out the documentation here: http://doc.qt.nokia.com/4.7-snapshot/anchor-layout.html On Tue, Jul 13, 2010 at 2:46 AM, Jason H wrote: > Hi again. I am trying to anchor to parent > |A| > |B| > |C| > > With the rect being