aboutsummaryrefslogtreecommitdiffstats
path: root/src/quick
Commit message (Collapse)AuthorAgeFilesLines
...
* Refactor Canvas rendering paths.Justin McPherson2012-02-1012-378/+960
| | | | | | | Refactor Canvas rendering paths to enable different drawing contexts. Change-Id: If0e00a14baa673fca6b999a787b4e89885bb1e51 Reviewed-by: Yunqiao Yin <charles.yin@nokia.com>
* Fix for QTBUG-23862 - Blank screen in ViewportChristopher Ham2012-02-101-5/+4
| | | | | | | | | | This patch fixes an issue that causes Qt3D's Viewport to be blank when its renderMode property is set to BufferedRender. (QSGPainterNode's RenderTarget is set to FramebufferObject) Task-number: QTBUG-23862 Change-Id: Ic7a333f79ecf1aa153ef42e213644a17243a3580 Reviewed-by: Sarah Jane Smith <sarah.j.smith@nokia.com> Reviewed-by: Yoann Lopes <yoann.lopes@nokia.com>
* Remove clang warnings in particlesYann Bodson2012-02-102-7/+8
| | | | | Change-Id: I4fb92a76143e5b9b607bbf9461b27ade3776edf0 Reviewed-by: Alan Alpert <alan.alpert@nokia.com>
* Update SmoothedAnimation and SpringAnimation to accept default target.Michael Brasser2012-02-104-6/+10
| | | | | | | Followup to f5a43c09dbbf0caece4976303250a7582f6037ec. Change-Id: I591836996b815f3128b5f67f11efcc644011d6b4 Reviewed-by: Bea Lam <bea.lam@nokia.com>
* Use use touch events to generate mouse events in Quick canvas.Martin Jones2012-02-104-19/+184
| | | | | | | | | | | | Allowing the canvas to deal with mouse event emulation provides a couple of advantages: 1. touches outside a reactive area can be ignored, allowing a touch within a reactive area to become the "mouse touch". 2. we can extend the mouse events with data available in touch events for use within the quick elements; specifically velocity in this case. Change-Id: Id9df397f1a3a03dbda2ef5dcf6189e7eb3377356 Reviewed-by: Michael Brasser <michael.brasser@nokia.com>
* Added new convenience readonly visibleChildren property to ItemMathias Malmqvist2012-02-103-6/+74
| | | | | | Change-Id: I5ec541226fabd72c05ce8ccb8bb7e56f6ec7717a Task-number: 22724 Reviewed-by: Aaron Kennedy <aaron.kennedy@nokia.com>
* Doc fixAlan Alpert2012-02-091-3/+3
| | | | | Change-Id: I94712d5e7ca81618c4c506f5984ff94c46b730dd Reviewed-by: Michael Brasser <michael.brasser@nokia.com>
* Pass the QQuickCanvas to texture factories.Gunnar Sletta2012-02-096-9/+9
| | | | | | | | | This makes it a lot more convenient as we then have direct access to the GL context, createTexture(), invalidation signal and more. Change-Id: I114514d1379c4d0efcc35c512fa2b485da3438b0 Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com> Reviewed-by: Kim M. Kalland <kim.kalland@nokia.com>
* Add linkColor property to Text.Andrew den Exter2012-02-097-15/+68
| | | | | | | | | | | | | | | Allows the color of links in text to be changed from the default blue. This currently only works with StyledText and the distance field rendererer. It could be made to work with RichText overwriting the specified foreground color in all instances or by not setting a default color in the html parser. The former would prevent the color being set with CSS or some future means for altering text formats. The latter would break rendering with QPainter. Task-number: QTBUG-23048 Change-Id: I98df215cabe8a089f648fd4a6206622b4318fb8f Reviewed-by: Martin Jones <martin.jones@nokia.com>
* Use QDeclarativePixmap in the Particle SystemAlan Alpert2012-02-099-97/+326
| | | | | | | This allows for source URLs to come from network sources. Change-Id: I416edca010e77e507598eaf4eead4291f044f379 Reviewed-by: Martin Jones <martin.jones@nokia.com>
* Fix warnings reported by clang.Michael Brasser2012-02-093-8/+8
| | | | | Change-Id: Ifa850c2848c61319cb2465d7fcfffc7fef630923 Reviewed-by: Yann Bodson <yann.bodson@nokia.com>
* Rewrite multiline strings properlyAlan Alpert2012-02-091-1/+1
| | | | | | | | | | | | | | | | Because the bindings rewriter works on code strings, it would leave multiline strings across multiple lines (which is illegal in ECMAScript. It now manually breaks them up when it sees them, by replacing a \n character with a literal \n. Since RewriteSignalHandler now likes to have the AST passed in too, the related method in QDeclarativeCompiler (and its customers) have been altered to use the QDeclarativeScript::Value instead of just a string. Task-number: QTBUG-23387 Change-Id: Id060de37e70590c9da2a902038ed02d948fdd70f Reviewed-by: Alan Alpert <alan.alpert@nokia.com>
* Add missing interface declarationCharles Yin2012-02-081-0/+2
| | | | | Change-Id: I18774f01b78f160b53c3ee96f1fe3a4cc8ce4950 Reviewed-by: Michael Brasser <michael.brasser@nokia.com>
* Use a singleton for the plugin.Gunnar Sletta2012-02-081-8/+8
| | | | | | | | | | The factory is created from the QQuickCanvas constructor before any alternative threads are started and doesn't need this kind of protected. In addition this caused problems on shutdown if multiple custom contexts where created. Change-Id: Ifdd9bde0c65aa7c399722aea33af78087a2465b4 Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
* Switch to QMetaType::TypeAlan Alpert2012-02-081-12/+15
| | | | | | | | Looks like this change was made to QVariant for Qt5, slight behavioural difference because floats are now a separate case. Change-Id: Ia9d420b03454c13c97515ab9c89b743a668b37e2 Reviewed-by: Gunnar Sletta <gunnar.sletta@nokia.com>
* Provide determinant accessor in render state structure.Glenn Watson2012-02-086-1/+28
| | | | | | | | | | | This allows custom renderers to set the determinant to a value different than the actual model view transform matrix. This is useful when parts of the scene node transformation are done on the CPU rather than in the vertex shader. Change-Id: Icf26a5922b0933275a61af4656cf842bf61e70d5 Reviewed-by: Michael Brasser <michael.brasser@nokia.com> Reviewed-by: Gunnar Sletta <gunnar.sletta@nokia.com>
* Added QQuickCanvas::setRenderTarget(uint fbo, const QSize &size)Gunnar Sletta2012-02-087-7/+85
| | | | | | | This allows to hook in non-QOpenGLFrameBufferObject FBO's also Change-Id: I8a2f8f7f15d5a92262bdbb0507b232d7c11fdf25 Reviewed-by: Jani Hautakangas <jani.hautakangas@nokia.com>
* Accept default targets for transitionsBea Lam2012-02-088-39/+76
| | | | | | | | | | | | QDeclarativeAbstractAnimation::transition(), QDeclarativeTransition::prepare() and QDeclarativeTransitionManager now accept a QObject* to specify a default target for a transition. For view transitions, this will allow the view to pass a view item as the default target for a view transition so that the Transition does not have to explicitly set the target for every animation. Change-Id: I2c8d5535283335e139d98ef56f399f338627fb3e Reviewed-by: Michael Brasser <michael.brasser@nokia.com>
* Don't hide virtual method.Michael Brasser2012-02-082-6/+6
| | | | | | Task-number: QTBUG-20994 Change-Id: Iaeeb23ed758ef52e0a3a61c4310aafec383e8a28 Reviewed-by: Yann Bodson <yann.bodson@nokia.com>
* Let Item.layer.samplerName be a QByteArray instead of QString.Kim Motoyoshi Kalland2012-02-072-10/+10
| | | | | | | | Both Qt's property system and OpenGL shaders use 8-bit characters, so there is no need to use a QString for samplerName. Change-Id: I8cc29c74adb5d71a34cc99d9ecebbbba8b554cdf Reviewed-by: Gunnar Sletta <gunnar.sletta@nokia.com>
* Allow Item components to be assigned to Item.layer.effect.Kim Motoyoshi Kalland2012-02-072-4/+5
| | | | | | | | | Some complex effects are easier to implement as Items using ShaderEffects internally rather than with a top-level ShaderEffect. Auto-tests added. Change-Id: I4b99811b87e7ca5054bf119b99207b7f5a7c666e Reviewed-by: Gunnar Sletta <gunnar.sletta@nokia.com>
* Initialize value.Michael Brasser2012-02-071-1/+1
| | | | | Change-Id: Ibfb045827a38021fcfa43e735823ad346c5c066c Reviewed-by: Jan-Arve Sæther <jan-arve.saether@nokia.com>
* Resolve StyledText img tags relative to baseUrl.Andrew den Exter2012-02-073-8/+22
| | | | | Change-Id: I954195d52330c65e851b7c0fcdb6c8dabf29335d Reviewed-by: Yann Bodson <yann.bodson@nokia.com>
* Fixed some Item.layer bugs and added auto-tests.Kim Motoyoshi Kalland2012-02-072-41/+103
| | | | | Change-Id: I3f66f911d1c499c37a66904f8ddab6951ba85e60 Reviewed-by: Gunnar Sletta <gunnar.sletta@nokia.com>
* Avoid recursive parent chains in QQuickItemGunnar Sletta2012-02-071-0/+11
| | | | | Change-Id: I47b666cfacd804c4302236f0a4b371ca7b382c3d Reviewed-by: Michael Brasser <michael.brasser@nokia.com>
* Add contentWidth and contentHeight properties to Text elements.Andrew den Exter2012-02-078-34/+76
| | | | | | | | | | | For Text and TextEdit this is a rename of paintedWidth and paintedHeight both of which remain as synonyms of the content properties for compatability. For TextInput this is a new property. Task-number: QTBUG-23691 Task-number: QTBUG-15160 Change-Id: Idbdc72fad34922be21b649ca45fc39b5e533ed1a Reviewed-by: Yann Bodson <yann.bodson@nokia.com>
* Add and use new animation backend.Michael Brasser2012-02-0729-759/+1363
| | | | | | | | | The new backend improves performance, and allows us to create multiple running animation jobs from a single Transition. It is based off of the existing Qt animation framework. Change-Id: Id1d0162f6e5c65bf31267f3f9f2042c354375d57 Reviewed-by: Yunqiao Yin <charles.yin@nokia.com>
* Remove warnings with clangYann Bodson2012-02-0710-13/+21
| | | | | Change-Id: I924f0adc036b47e2342bf383d308c6a5269c2de6 Reviewed-by: Michael Brasser <michael.brasser@nokia.com>
* Fix symbol clashAlan Alpert2012-02-072-16/+15
| | | | | | | | SpriteImage and ImageParticle are now in the same library, need different internal class names. Change-Id: Ic32fafb729818a6114fe454e7288fbf00fd6a1e7 Reviewed-by: Martin Jones <martin.jones@nokia.com>
* Ensure Flickable moving and flicking properties are correct.Martin Jones2012-02-071-6/+15
| | | | | | | | | Flicking, then touching to stop the flick should set flicking property to false. Moving or flicking vertically should not set flickingHorizontally, and vise-versa. Change-Id: Iee42a92ffff2707f0691ffa285dec514b47c9986 Reviewed-by: Michael Brasser <michael.brasser@nokia.com>
* Section header is not made visible when changing currentIndex.Martin Jones2012-02-071-3/+5
| | | | | | | | | Make section header visible when setting currentIndex to an item on a section boundary. Could also affect initial position if view size started at 0. Change-Id: Ie65f91826311d34a290d369d8956f1c88f7efb70 Reviewed-by: Bea Lam <bea.lam@nokia.com>
* Remove pixmap text caching in QML text elementYann Bodson2012-02-073-333/+35
| | | | | | Task-number: QTBUG-24033 Change-Id: Ifa24482b98536300c2f4c643a86517a019de8a84 Reviewed-by: Martin Jones <martin.jones@nokia.com>
* Fix truncation and incorrect formatting of RichText.Andrew den Exter2012-02-071-1/+1
| | | | | | | | | Update the text position when adding text. Task-number: QTBUG-23981 Change-Id: I4a10916559745e8df805b1f8563522341bc6f69b Reviewed-by: Yann Bodson <yann.bodson@nokia.com> Reviewed-by: Jiang Jiang <jiang.jiang@nokia.com>
* Fix acceptance of unhandled mouse events.Simon Hausmann2012-02-061-1/+5
| | | | | | | | | | | | Mouse events not handled by the canvas need to be ignored, in order for features like touch synthetization to work. In case of the initially delivered mouse press event, the canvas did not ignore the event if it was not handled. This patch corrects that and adds an auto-test to verify the new behaviour. Change-Id: I8499701f5a161ce1e90a70303aa7ca4ccf2f0b6f Reviewed-by: Andras Becsi <andras.becsi@nokia.com> Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
* Warnings in the before/afterRender docsGunnar Sletta2012-02-061-4/+11
| | | | | Change-Id: I2311e574b45d518893ef868fdcf51053dc43bb13 Reviewed-by: Kim M. Kalland <kim.kalland@nokia.com>
* Don't start timers in the QDeclarativePixmapStore destructorTor Arne Vestbø2012-02-061-0/+5
| | | | | | | | | | Timers use global static data, which might have been torn down at the point where we start the timer. Change-Id: Id11de05ae92b9a3652f9b1d7c3d5ca4947ffe065 Reviewed-by: João Abecasis <joao.abecasis@nokia.com> Reviewed-by: Simon Hausmann <simon.hausmann@nokia.com> Reviewed-by: Gunnar Sletta <gunnar.sletta@nokia.com>
* Fix updating text color in Text elementEskil Abrahamsen Blomfeldt2012-02-061-1/+3
| | | | | | | | | | The setColor() function in QQuickText calls markDirty() which did not specify that the whole paint node should be updated, so color updates would have no effect until something else changed. Change-Id: I93741b6c697f2dd6ad5a315250502a7a6e3ce1d7 Reviewed-by: Jiang Jiang <jiang.jiang@nokia.com> Reviewed-by: Andrew den Exter <andrew.den-exter@nokia.com>
* Fix vertical offset of TextInput.positionToRectangle.Andrew den Exter2012-02-061-3/+5
| | | | | | | | | Offset the y value of the rectangle by the vertical scroll and line offset. Task-number: QTBUG-23934 Change-Id: I43815b480f43a089a9a03b0aec32dfc0598b6154 Reviewed-by: Martin Jones <martin.jones@nokia.com>
* Fix TextEdit vertical alignment.Andrew den Exter2012-02-062-3/+3
| | | | | | | | | | Don't ignore the position of a QTextDocument when contructing a text node, and translate the rectangle returned by positionToRectangle by the y offset. Task-number: QTBUG-23935 Change-Id: I55a2b69a32a8b623be7e36de54ad083c2f8591e5 Reviewed-by: Martin Jones <martin.jones@nokia.com>
* Add support for resizing fonts to fit Text dimensions.Andrew den Exter2012-02-063-156/+393
| | | | | | | | | | | This adds a mode where if the content of a Text item doesn't fit within its bounds the font size is reduced during layout until it does or a minimum font size is reached. Task-number: QTBUG-22832 Change-Id: I6198ef03899e2f21b32e313548966ef4b0e3bff1 Reviewed-by: Andrew den Exter <andrew.den-exter@nokia.com> Reviewed-by: Yann Bodson <yann.bodson@nokia.com>
* Cleanup: remove some debugging and use QQuickTextNode::addImageYann Bodson2012-02-061-17/+2
| | | | | Change-Id: I20f38f590b158d5d615923c30e85e2a7cfd99763 Reviewed-by: Martin Jones <martin.jones@nokia.com>
* Remove QtQuick1 elements from qtdeclarativeMatthew Vogt2012-02-038-26/+12
| | | | | | | | QtQuick1 is now contained in a separate repository. Task-number: QTBUG-23737 Change-Id: I09eae67af5693a22b896b916f816f73ccc3a89b1 Reviewed-by: Martin Jones <martin.jones@nokia.com>
* Started implementation of offscreen canvas FBO rendering APIGunnar Sletta2012-02-023-9/+76
| | | | | Change-Id: I15b1799982d20d16c9c5e08eee7095cf087b49e1 Reviewed-by: Kim M. Kalland <kim.kalland@nokia.com>
* Do not start timers in QDeclarativePixmapStore teardownLaszlo Agocs2012-02-021-2/+5
| | | | | | | | | | The store instance is a global static and so starting timers during its destruction is unnecessary, and may cause crashes if the QAbstractEventDispatcher's statics are already destroyed. This happens on OS X at least. Change-Id: I785515c8973b291a7bfc6c5dabe2c19e8393c7ad Reviewed-by: Martin Jones <martin.jones@nokia.com>
* Adapt to QGuiApplication::focusObject() for notifying input methodPekka Vuorela2012-02-023-21/+8
| | | | | | | | | Emitting focusObjectChanged() signal now instead of explicitly setting inputItem to QInputPanel. Also adapted from deprecated QInputPanel::inputItem() to QGuiApplication::focusObject(). Change-Id: I97460625cc8bb2820ec7716a06330aecd1b585ea Reviewed-by: Joona Petrell <joona.t.petrell@nokia.com>
* Support inline images with <img> tag in StyledTextYann Bodson2012-02-025-29/+276
| | | | | | Task-number: QTBUG-21793 Change-Id: Ie7b9f293c6c9a949c1899152c38b61251b0069d3 Reviewed-by: Yann Bodson <yann.bodson@nokia.com>
* Incorrect initial pos after resizing view with margins.Martin Jones2012-02-022-20/+27
| | | | | | | | | | The currentItem tracking didn't position the view to show the margins. This affects resizing the view and also changing currentIndex. Task-number: QTBUG-24028 Change-Id: I47d4c771c0d712c93abadfb6b2deb5194241fb6b Reviewed-by: Bea Lam <bea.lam@nokia.com>
* Fix unhandled touch events not being ignored.Simon Hausmann2012-02-021-1/+6
| | | | | | | | | Unhandled touch events need to be ignored in order for things like mouse event synthetization in QtGui to work. Change-Id: I6fe9dad205c8bb8547d2424c2e2a3b3518598006 Reviewed-by: Andras Becsi <andras.becsi@nokia.com> Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
* Must update columns when GridView geometry changesBea Lam2012-02-025-15/+23
| | | | | | | | | | Regression from changes in 80d85e0017cb5cc4b0a0df6c19d4126bf5062731 Also remove shared duplicate code in visibleItemsChanged() in ListView and GridView. Change-Id: Ic3ab3ba070ddf9901a232ed5b3250c725797cf69 Reviewed-by: Martin Jones <martin.jones@nokia.com>
* Multiple fast flicks with large content moves fasterMartin Jones2012-02-022-16/+75
| | | | | | | | | Repeatedly flicking quickly in a large view moves faster than the velocity of the touch. Task-number: QTBUG-18600 Change-Id: Ie6747e0d945022e0c0c5f6c5f95bc35403a14d56 Reviewed-by: Martin Jones <martin.jones@nokia.com>