summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGunnar Sletta <gunnar.sletta@digia.com>2012-12-17 16:18:36 +0100
committerGunnar Sletta <gunnar.sletta@digia.com>2012-12-17 16:18:36 +0100
commit74300c194f93881835c072368650c311818e16b7 (patch)
treed9512714d76418aedb5b7f423894ac4abdc19b2c
parent3fe4438f39ceb825fc867157afa496809b9669db (diff)
Some more tweaks...
-rw-r--r--CanvasSlide.qml79
-rw-r--r--EffectsSlide.qml2
-rw-r--r--FontSlide.qml2
-rw-r--r--ParticleSlide.qml7
-rw-r--r--ShaderSlide.qml2
-rw-r--r--SlideDeck.qml73
-rw-r--r--Swirl.qml2
-rw-r--r--VideoSlide.qml4
-rw-r--r--WebkitSlide.qml4
-rw-r--r--WidgetsSlide.qml2
10 files changed, 124 insertions, 53 deletions
diff --git a/CanvasSlide.qml b/CanvasSlide.qml
index ffdb819..c0b780a 100644
--- a/CanvasSlide.qml
+++ b/CanvasSlide.qml
@@ -39,6 +39,7 @@
****************************************************************************/
import QtQuick 2.0
+import QtQuick.Particles 2.0
import Qt.labs.presentation 1.0
Slide {
@@ -46,11 +47,18 @@ Slide {
title: "Qt Quick - Canvas"
+
+
Rectangle {
height: parent.height
width: parent.width * 0.45
anchors.right: parent.right;
- color: "white"
+ antialiasing: true
+ radius: slide.height * 0.03;
+ gradient: Gradient {
+ GradientStop { position: 0; color: Qt.rgba(0.4, 0.4, 0.4) }
+ GradientStop { position: 1; color: Qt.rgba(0.05, 0.05, 0.05) }
+ }
Canvas {
id:canvas
anchors.fill: parent;
@@ -66,7 +74,13 @@ Slide {
height: parent.height
width: parent.width * 0.45
anchors.left: parent.left
- color: "white"
+ antialiasing: true
+ radius: slide.height * 0.03;
+ gradient: Gradient {
+ GradientStop { position: 0; color: Qt.rgba(0.4, 0.4, 0.4) }
+ GradientStop { position: 1; color: Qt.rgba(0.05, 0.05, 0.05) }
+ }
+
clip: true;
TextEdit {
@@ -75,32 +89,81 @@ Slide {
anchors.margins: 10
font.pixelSize: 16
+ color: "white"
+ font.family: "courier"
+ font.bold: true
text:
"var ctx = canvas.getContext('2d');
ctx.save();
ctx.clearRect(0, 0, canvas.width, canvas.height);
-ctx.strokeStyle = 'steelblue'
-ctx.fillStyle = 'lightsteelblue';
+ctx.strokeStyle = 'palegreen'
+ctx.fillStyle = 'limegreen';
ctx.lineWidth = 5;
ctx.beginPath();
ctx.moveTo(100, 100);
ctx.lineTo(300, 100);
ctx.lineTo(100, 200);
-ctx.lineTo(100, 100);
+ctx.closePath();
ctx.fill();
ctx.stroke();
ctx.restore();
-ctx.fillStyle = 'black'
+ctx.fillStyle = 'aquamarine'
ctx.font = '20px sansserif'
-ctx.fillText('Implements the HTML Canvas API', 50, 300);
-ctx.fillText('Imperative Drawing from JavaScript', 50, 340);
+ctx.fillText('HTML Canvas API!', 100, 300);
+ctx.fillText('Imperative Drawing!', 100, 340);
+
+ctx.restore();
"
onTextChanged: canvas.requestPaint();
+
+ onCursorRectangleChanged: {
+ emitter.burst(10)
+
+ }
+
+ ParticleSystem {
+ id: sys1
+ running: slide.visible
+ }
+
+ ImageParticle {
+ system: sys1
+ source: "images/particle.png"
+ color: "white"
+ colorVariation: 0.2
+ alpha: 0
+ }
+
+ Emitter {
+ id: emitter
+ system: sys1
+
+ x: editor.cursorRectangle.x - editor.cursorRectangle.height / 2;
+ y: editor.cursorRectangle.y
+ width: editor.cursorRectangle.height
+ height: editor.cursorRectangle.height
+ enabled: false
+
+ lifeSpan: 1000
+
+ velocity: PointDirection { xVariation: 30; yVariation: 30; }
+ acceleration: PointDirection {xVariation: 30; yVariation: 30; y: 100 }
+
+ endSize: 0
+
+ size: 4
+ sizeVariation: 2
+ }
+
}
+
+
+
+
}
}
diff --git a/EffectsSlide.qml b/EffectsSlide.qml
index f6436d9..016ad54 100644
--- a/EffectsSlide.qml
+++ b/EffectsSlide.qml
@@ -60,7 +60,7 @@ Slide {
SequentialAnimation {
PropertyAction { target: grid; property: "opacity"; value: 0 }
- PauseAnimation { duration: 4000 }
+ PauseAnimation { duration: 1500 }
NumberAnimation { target: grid; property: "opacity"; to: 1; duration: 2000; easing.type: Easing.InOutCubic }
running: slide.visible;
}
diff --git a/FontSlide.qml b/FontSlide.qml
index 4885fe0..f79e4d1 100644
--- a/FontSlide.qml
+++ b/FontSlide.qml
@@ -64,7 +64,7 @@ Native font rendering is also an option for applications that want to look nativ
Text {
anchors.centerIn: parent
- text: "Pretty neat, eh?"
+ text: "Awesome!"
color: "white"
font.pixelSize: 20;
diff --git a/ParticleSlide.qml b/ParticleSlide.qml
index d5b4d94..b630a34 100644
--- a/ParticleSlide.qml
+++ b/ParticleSlide.qml
@@ -50,6 +50,13 @@ Slide
Row {
anchors.fill: parent
+ SequentialAnimation on opacity {
+ running: slide.visible;
+ PropertyAction { value: 0 }
+ PauseAnimation { duration: 2000; }
+ NumberAnimation { to: 1; duration: 1000 }
+ }
+
spacing: (width - 320 * 3) / 2
Loader {
diff --git a/ShaderSlide.qml b/ShaderSlide.qml
index 57ac9ee..40d8e92 100644
--- a/ShaderSlide.qml
+++ b/ShaderSlide.qml
@@ -69,7 +69,7 @@ Slide {
PropertyAction { target: rotationAnimation; property: "running"; value: false }
PropertyAction { target: timeAnimation; property: "running"; value: false }
// short pause
- PauseAnimation { duration: 3000 }
+ PauseAnimation { duration: 2000 }
// get started...
ParallelAnimation {
NumberAnimation { target: shader; property: "xrot"; to: 2 * Math.PI / 8; duration: 1000; easing.type: Easing.InOutCubic }
diff --git a/SlideDeck.qml b/SlideDeck.qml
index 3b3c543..b86415a 100644
--- a/SlideDeck.qml
+++ b/SlideDeck.qml
@@ -116,6 +116,31 @@ WebKit - Full HTML 5 support from the worlds most popular web engine, including
}
+ Slide {
+ title: "Qt 5 - Features"
+ writeInText: "Modularization of the Qt libraries - sanitizing our codebase and making it possible to deploy only that which is needed
+
+Qt Platform Abstraction - Unifying the Qt codebase across platforms and greatly reducing the effort needed to port to new platforms
+
+Wayland support - Wayland 1.0 compatible Qt backend and compositor framework"
+ }
+
+ Slide {
+ title: "Qt 5 - Features"
+ writeInText: "C++ language features - template based connect(), C++11 support, move constructors and more
+
+Connectivity and Networking - DNS lookup, improved IPv6 support
+
+JSON Support - Fast parser and writer, binary format support
+
+Unicode - Updated to latest Unicode specification, UTF-8 source files"
+ }
+
+ Slide {
+ centeredText: "And much more..."
+ }
+
+
/********************************************************************************
@@ -140,23 +165,23 @@ WebKit - Full HTML 5 support from the worlds most popular web engine, including
EffectsSlide {}
+// /********************************************************************************
+// *
+// * Multimedia
+// *
+// */
- /********************************************************************************
- *
- * Multimedia
- *
- */
+// Slide {
+// title: "Qt Multimedia"
+// writeInText: "The Qt Multmedia module is implemented on all our major platforms, including Windows, Mac OS X and Linux.
- Slide {
- title: "Qt Multimedia"
- writeInText: "The Qt Multmedia module is implemented on all our major platforms, including Windows, Mac OS X and Linux.
+//It contains both a C++ API for use with existing Qt Widgets based applications and a QML API for use with Qt Quick 2.0.
-It contains both a C++ API for use with existing Qt Widgets based applications and a QML API for use with Qt Quick 2.0.
+//The features include recording and playback of video and audio and also use of camera.
-The features include recording and playback of video and audio and also use of camera.
+//It also integrates nicely with the Qt Graphical Effects module."
+// }
-It also integrates nicely with the Qt Graphical Effects module."
- }
VideoSlide { }
CameraSlide { }
@@ -178,30 +203,6 @@ It also integrates nicely with the Qt Graphical Effects module."
*
*/
- Slide {
- centeredText: "And much more..."
- }
-
- Slide {
- title: "Qt 5 - Features"
- writeInText: "Modularization of the Qt libraries - sanitizing our codebase and making it possible to deploy only that which is needed
-
-Qt Platform Abstraction - Unifying the Qt codebase across platforms and greatly reducing the effort needed to port to new platforms
-
-Wayland support - Wayland 1.0 compatible Qt backend and compositor framework"
- }
-
- Slide {
- title: "Qt 5 - Features"
- writeInText: "C++ language features - template based connect(), C++11 support, move constructors and more
-
-Connectivity and Networking - DNS lookup, improved IPv6 support
-
-JSON Support - Fast parser and writer, binary format support
-
-Unicode - Updated to latest Unicode specification, UTF-8 source files"
- }
-
WidgetsSlide { }
Slide {
diff --git a/Swirl.qml b/Swirl.qml
index e870cb7..710f04b 100644
--- a/Swirl.qml
+++ b/Swirl.qml
@@ -103,7 +103,7 @@ ShaderEffect {
+ sin(-ty * 8.0 + d.w * qt_MultiTexCoord0.x * 15. + 7. * d.z);
xx = x;
- pos.xy += vec2(x * sin(qt_MultiTexCoord0.x * 3.14152),
+ pos.xy += vec2(x * sin(qt_MultiTexCoord0.x * 3.14152) * 0.3,
y * (1.0 - qt_MultiTexCoord0.y)) * amplitude;
gl_Position = qt_Matrix * pos;
diff --git a/VideoSlide.qml b/VideoSlide.qml
index adedbb7..b2cae06 100644
--- a/VideoSlide.qml
+++ b/VideoSlide.qml
@@ -77,9 +77,9 @@ Slide {
id: label
color: "white"
text: "Qt 5"
- font.family: "Times New Roman"
+// font.family: "Times New Roman"
font.bold: true;
- font.pixelSize: 60
+ font.pixelSize: 80
anchors.centerIn: parent
}
visible: false;
diff --git a/WebkitSlide.qml b/WebkitSlide.qml
index e560ed7..6806529 100644
--- a/WebkitSlide.qml
+++ b/WebkitSlide.qml
@@ -17,7 +17,7 @@ Slide {
// clips it so it is not visible. Not ideal, but it kinda works
// for now.
layer.enabled: true
- layer.smooth: true
+ layer.smooth: true
}
Rectangle {
@@ -37,7 +37,7 @@ Slide {
anchors.top: browser.bottom;
anchors.horizontalCenter: browser.horizontalCenter
font.pixelSize: slide.baseFontSize;
- text: "http://www.google.com"
+ text: "http://qt.digia.com"
onAccepted: browser.reload();
color: "white"
}
diff --git a/WidgetsSlide.qml b/WidgetsSlide.qml
index e1bf330..ac1be91 100644
--- a/WidgetsSlide.qml
+++ b/WidgetsSlide.qml
@@ -59,7 +59,7 @@ Slide {
stylesWindow.opacity = 0;
}
}
- PauseAnimation { duration: 3000 }
+ PauseAnimation { duration: 2000 }
ParallelAnimation {
NumberAnimation { target: boxesImage; property: "opacity"; from: 0; to: 1; duration: slide.slamTime; easing.type: Easing.OutBack }
NumberAnimation { target: boxesImage; property: "rotation"; from: 20; to: 10; duration: slide.slamTime; easing.type: Easing.OutBack }