diff --git a/CMakeLists.txt.user b/CMakeLists.txt.user index 4497f57..d745ba9 100644 --- a/CMakeLists.txt.user +++ b/CMakeLists.txt.user @@ -1,14 +1,14 @@ - + EnvironmentId - {d6595ca1-5c4f-4487-b405-470a7201d856} + {96b0233c-0ac3-4a64-9b08-eb9c58898997} ProjectExplorer.Project.ActiveTarget - 0 + 0 ProjectExplorer.Project.EditorSettings @@ -28,7 +28,7 @@ QmlJSGlobal - 2 + 2 UTF-8 false 4 @@ -37,7 +37,6 @@ true true 1 - false true false 0 @@ -46,139 +45,707 @@ 0 8 true - false 1 true true true - *.md, *.MD, Makefile false - true ProjectExplorer.Project.PluginSettings - - true - false - true - true - true - true - - - 0 - true true - Builtin.BuildSystem - - true - true - Builtin.DefaultTidyAndClazy - 4 - - - - true - ProjectExplorer.Project.Target.0 - Desktop - Qt 5.15.2 in PATH (System) - Qt 5.15.2 in PATH (System) - {055b3c2c-94ff-418e-b088-9847da1e7c71} - 0 - 0 - 0 + Desktop + Desktop + {96187c35-1a90-4f71-ac12-1cde906cba06} + 0 + 0 + 0 - Debug - -GUnix Makefiles --DCMAKE_BUILD_TYPE:STRING=Debug --DCMAKE_PROJECT_INCLUDE_BEFORE:PATH=%{IDE:ResourcePath}/package-manager/auto-setup.cmake --DQT_QMAKE_EXECUTABLE:STRING=%{Qt:qmakeExecutable} --DCMAKE_PREFIX_PATH:STRING=%{Qt:QT_INSTALL_PREFIX} --DCMAKE_C_COMPILER:STRING=%{Compiler:Executable:C} --DCMAKE_CXX_COMPILER:STRING=%{Compiler:Executable:Cxx} - /home/chris/dev/church-presenter - /home/chris/dev/church-presenter/build + + CMAKE_BUILD_TYPE:STRING=Debug + CMAKE_CXX_COMPILER:STRING=%{Compiler:Executable:Cxx} + CMAKE_C_COMPILER:STRING=%{Compiler:Executable:C} + CMAKE_PREFIX_PATH:STRING=%{Qt:QT_INSTALL_PREFIX} + QT_QMAKE_EXECUTABLE:STRING=%{Qt:qmakeExecutable} + + /home/chris/dev/build-church-presenter-Desktop-Debug + all true - Build CMakeProjectManager.MakeStep - 1 + 1 Build Build ProjectExplorer.BuildSteps.Build + clean true - Build CMakeProjectManager.MakeStep - 1 + 1 Clean Clean ProjectExplorer.BuildSteps.Clean 2 false - - false Debug CMakeProjectManager.CMakeBuildConfiguration - 1 + + + CMAKE_BUILD_TYPE:STRING=Release + CMAKE_CXX_COMPILER:STRING=%{Compiler:Executable:Cxx} + CMAKE_C_COMPILER:STRING=%{Compiler:Executable:C} + CMAKE_PREFIX_PATH:STRING=%{Qt:QT_INSTALL_PREFIX} + QT_QMAKE_EXECUTABLE:STRING=%{Qt:qmakeExecutable} + + /home/chris/dev/build-church-presenter-Desktop-Release + + + + + all + + true + CMakeProjectManager.MakeStep + + 1 + Build + Build + ProjectExplorer.BuildSteps.Build + + + + + + clean + + true + CMakeProjectManager.MakeStep + + 1 + Clean + Clean + ProjectExplorer.BuildSteps.Clean + + 2 + false + + Release + CMakeProjectManager.CMakeBuildConfiguration + + + + CMAKE_BUILD_TYPE:STRING=RelWithDebInfo + CMAKE_CXX_COMPILER:STRING=%{Compiler:Executable:Cxx} + CMAKE_C_COMPILER:STRING=%{Compiler:Executable:C} + CMAKE_PREFIX_PATH:STRING=%{Qt:QT_INSTALL_PREFIX} + QT_QMAKE_EXECUTABLE:STRING=%{Qt:qmakeExecutable} + + /home/chris/dev/build-church-presenter-Desktop-RelWithDebInfo + + + + + all + + true + CMakeProjectManager.MakeStep + + 1 + Build + Build + ProjectExplorer.BuildSteps.Build + + + + + + clean + + true + CMakeProjectManager.MakeStep + + 1 + Clean + Clean + ProjectExplorer.BuildSteps.Clean + + 2 + false + + Release with Debug Information + CMakeProjectManager.CMakeBuildConfiguration + + + + CMAKE_BUILD_TYPE:STRING=MinSizeRel + CMAKE_CXX_COMPILER:STRING=%{Compiler:Executable:Cxx} + CMAKE_C_COMPILER:STRING=%{Compiler:Executable:C} + CMAKE_PREFIX_PATH:STRING=%{Qt:QT_INSTALL_PREFIX} + QT_QMAKE_EXECUTABLE:STRING=%{Qt:qmakeExecutable} + + /home/chris/dev/build-church-presenter-Desktop-MinSizeRel + + + + + all + + true + CMakeProjectManager.MakeStep + + 1 + Build + Build + ProjectExplorer.BuildSteps.Build + + + + + + clean + + true + CMakeProjectManager.MakeStep + + 1 + Clean + Clean + ProjectExplorer.BuildSteps.Clean + + 2 + false + + Minimum Size Release + CMakeProjectManager.CMakeBuildConfiguration + + 4 - 0 + 0 Deploy Deploy ProjectExplorer.BuildSteps.Deploy 1 - - false ProjectExplorer.DefaultDeployConfiguration - 1 + 1 + + dwarf + + cpu-cycles + + + 250 + + -e + cpu-cycles + --call-graph + dwarf,4096 + -F + 250 + + -F true + 4096 + false + false + 1000 + true + + false + false + false + false + true + 0.01 + 10 + true + kcachegrind + 1 + 25 + + 1 true - + false + true + valgrind + + 0 + 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 10 + 11 + 12 + 13 + 14 + 2 - presenter - CMakeProjectManager.CMakeRunConfiguration.presenter - presenter + + ProjectExplorer.CustomExecutableRunConfiguration + + + false + false true - true + false false true - /home/chris/dev/church-presenter/build/bin + + - 1 + 1 + + + + ProjectExplorer.Project.Target.1 + + Felgo Desktop (Qt 5.15.2 GCC) + Felgo Desktop (Qt 5.15.2 GCC) + vplayengine.2.qt.gcc_64_kit + 0 + 0 + 0 + + + CMAKE_BUILD_TYPE:STRING=Debug + CMAKE_CXX_COMPILER:STRING=%{Compiler:Executable:Cxx} + CMAKE_C_COMPILER:STRING=%{Compiler:Executable:C} + CMAKE_PREFIX_PATH:STRING=%{Qt:QT_INSTALL_PREFIX} + QT_QMAKE_EXECUTABLE:STRING=%{Qt:qmakeExecutable} + + /home/chris/dev/build-church-presenter-Felgo_Desktop_Qt_5_15_2_GCC-Debug + + + + + all + + true + CMakeProjectManager.MakeStep + + 1 + Build + Build + ProjectExplorer.BuildSteps.Build + + + + + + clean + + true + CMakeProjectManager.MakeStep + + 1 + Clean + Clean + ProjectExplorer.BuildSteps.Clean + + 2 + false + + Debug + CMakeProjectManager.CMakeBuildConfiguration + + + + CMAKE_BUILD_TYPE:STRING=Release + CMAKE_CXX_COMPILER:STRING=%{Compiler:Executable:Cxx} + CMAKE_C_COMPILER:STRING=%{Compiler:Executable:C} + CMAKE_PREFIX_PATH:STRING=%{Qt:QT_INSTALL_PREFIX} + QT_QMAKE_EXECUTABLE:STRING=%{Qt:qmakeExecutable} + + /home/chris/dev/build-church-presenter-Felgo_Desktop_Qt_5_15_2_GCC-Release + + + + + all + + true + CMakeProjectManager.MakeStep + + 1 + Build + Build + ProjectExplorer.BuildSteps.Build + + + + + + clean + + true + CMakeProjectManager.MakeStep + + 1 + Clean + Clean + ProjectExplorer.BuildSteps.Clean + + 2 + false + + Release + CMakeProjectManager.CMakeBuildConfiguration + + + + CMAKE_BUILD_TYPE:STRING=RelWithDebInfo + CMAKE_CXX_COMPILER:STRING=%{Compiler:Executable:Cxx} + CMAKE_C_COMPILER:STRING=%{Compiler:Executable:C} + CMAKE_PREFIX_PATH:STRING=%{Qt:QT_INSTALL_PREFIX} + QT_QMAKE_EXECUTABLE:STRING=%{Qt:qmakeExecutable} + + /home/chris/dev/build-church-presenter-Felgo_Desktop_Qt_5_15_2_GCC-RelWithDebInfo + + + + + all + + true + CMakeProjectManager.MakeStep + + 1 + Build + Build + ProjectExplorer.BuildSteps.Build + + + + + + clean + + true + CMakeProjectManager.MakeStep + + 1 + Clean + Clean + ProjectExplorer.BuildSteps.Clean + + 2 + false + + Release with Debug Information + CMakeProjectManager.CMakeBuildConfiguration + + + + CMAKE_BUILD_TYPE:STRING=MinSizeRel + CMAKE_CXX_COMPILER:STRING=%{Compiler:Executable:Cxx} + CMAKE_C_COMPILER:STRING=%{Compiler:Executable:C} + CMAKE_PREFIX_PATH:STRING=%{Qt:QT_INSTALL_PREFIX} + QT_QMAKE_EXECUTABLE:STRING=%{Qt:qmakeExecutable} + + /home/chris/dev/build-church-presenter-Felgo_Desktop_Qt_5_15_2_GCC-MinSizeRel + + + + + all + + true + CMakeProjectManager.MakeStep + + 1 + Build + Build + ProjectExplorer.BuildSteps.Build + + + + + + clean + + true + CMakeProjectManager.MakeStep + + 1 + Clean + Clean + ProjectExplorer.BuildSteps.Clean + + 2 + false + + Minimum Size Release + CMakeProjectManager.CMakeBuildConfiguration + + 4 + + + 0 + Deploy + Deploy + ProjectExplorer.BuildSteps.Deploy + + 1 + ProjectExplorer.DefaultDeployConfiguration + + 1 + + + dwarf + + cpu-cycles + + + 250 + + -e + cpu-cycles + --call-graph + dwarf,4096 + -F + 250 + + -F + true + 4096 + false + false + 1000 + + true + + false + false + false + false + true + 0.01 + 10 + true + kcachegrind + 1 + 25 + + 1 + true + false + true + valgrind + + 0 + 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 10 + 11 + 12 + 13 + 14 + + 2 + + + ProjectExplorer.CustomExecutableRunConfiguration + + + false + + false + true + false + false + true + + + + 1 + + + + ProjectExplorer.Project.Target.2 + + Unnamed + Unnamed + {ead1f619-db1e-418c-b0eb-2111d1bf7fd0} + 0 + 0 + 0 + + + CMAKE_BUILD_TYPE:STRING=Debug + CMAKE_CXX_COMPILER:STRING=%{Compiler:Executable:Cxx} + CMAKE_C_COMPILER:STRING=%{Compiler:Executable:C} + CMAKE_PREFIX_PATH:STRING=%{Qt:QT_INSTALL_PREFIX} + QT_QMAKE_EXECUTABLE:STRING=%{Qt:qmakeExecutable} + + /home/chris/dev/church-presenter/build + + + + + all + + true + CMakeProjectManager.MakeStep + + 1 + Build + Build + ProjectExplorer.BuildSteps.Build + + + + + + clean + + true + CMakeProjectManager.MakeStep + + 1 + Clean + Clean + ProjectExplorer.BuildSteps.Clean + + 2 + false + + Debug + CMakeProjectManager.CMakeBuildConfiguration + + 1 + + + 0 + Deploy + Deploy + ProjectExplorer.BuildSteps.Deploy + + 1 + ProjectExplorer.DefaultDeployConfiguration + + 1 + + + dwarf + + cpu-cycles + + + 250 + + -e + cpu-cycles + --call-graph + dwarf,4096 + -F + 250 + + -F + true + 4096 + false + false + 1000 + + true + + false + false + false + false + true + 0.01 + 10 + true + kcachegrind + 1 + 25 + + 1 + true + false + true + valgrind + + 0 + 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + 10 + 11 + 12 + 13 + 14 + + 2 + + + ProjectExplorer.CustomExecutableRunConfiguration + + + false + + false + true + false + false + true + + + + 1 ProjectExplorer.Project.TargetCount - 1 + 3 ProjectExplorer.Project.Updater.FileVersion diff --git a/build/CMakeCache.txt b/build/CMakeCache.txt index 9cc341d..98c6816 100644 --- a/build/CMakeCache.txt +++ b/build/CMakeCache.txt @@ -615,11 +615,11 @@ CMAKE_VERBOSE_MAKEFILE-ADVANCED:INTERNAL=1 //Details about finding Gettext FIND_PACKAGE_MESSAGE_DETAILS_Gettext:INTERNAL=[/usr/bin/msgmerge][/usr/bin/msgfmt][v0.21()] //Details about finding KF5 -FIND_PACKAGE_MESSAGE_DETAILS_KF5:INTERNAL=[success][cfound components: Kirigami2 I18n CoreAddons ][v5.87.0(5.68.0)] +FIND_PACKAGE_MESSAGE_DETAILS_KF5:INTERNAL=[success][cfound components: Kirigami2 I18n CoreAddons ][v5.90.0(5.68.0)] //Details about finding KF5CoreAddons FIND_PACKAGE_MESSAGE_DETAILS_KF5CoreAddons:INTERNAL=[/usr/lib64/cmake/KF5CoreAddons/KF5CoreAddonsConfig.cmake][v5.90.0()] //Details about finding KF5I18n -FIND_PACKAGE_MESSAGE_DETAILS_KF5I18n:INTERNAL=[/usr/lib64/cmake/KF5I18n/KF5I18nConfig.cmake][v5.87.0()] +FIND_PACKAGE_MESSAGE_DETAILS_KF5I18n:INTERNAL=[/usr/lib64/cmake/KF5I18n/KF5I18nConfig.cmake][v5.90.0()] //Details about finding KF5Kirigami2 FIND_PACKAGE_MESSAGE_DETAILS_KF5Kirigami2:INTERNAL=[/usr/lib64/cmake/KF5Kirigami2/KF5Kirigami2Config.cmake][v5.90.0()] //Test HAVE_DATE_TIME diff --git a/build/CMakeFiles/Makefile.cmake b/build/CMakeFiles/Makefile.cmake index cac60cb..2ff999d 100644 --- a/build/CMakeFiles/Makefile.cmake +++ b/build/CMakeFiles/Makefile.cmake @@ -25,7 +25,7 @@ set(CMAKE_MAKEFILE_DEPENDS "/usr/lib64/cmake/KF5I18n/KF5I18nConfigVersion.cmake" "/usr/lib64/cmake/KF5I18n/KF5I18nMacros.cmake" "/usr/lib64/cmake/KF5I18n/KF5I18nQchTargets.cmake" - "/usr/lib64/cmake/KF5I18n/KF5I18nTargets-debug.cmake" + "/usr/lib64/cmake/KF5I18n/KF5I18nTargets-noconfig.cmake" "/usr/lib64/cmake/KF5I18n/KF5I18nTargets.cmake" "/usr/lib64/cmake/KF5Kirigami2/KF5Kirigami2Config.cmake" "/usr/lib64/cmake/KF5Kirigami2/KF5Kirigami2ConfigVersion.cmake" @@ -54,25 +54,35 @@ set(CMAKE_MAKEFILE_DEPENDS "/usr/lib64/cmake/Qt5Gui/Qt5Gui_QEvdevTabletPlugin.cmake" "/usr/lib64/cmake/Qt5Gui/Qt5Gui_QEvdevTouchScreenPlugin.cmake" "/usr/lib64/cmake/Qt5Gui/Qt5Gui_QGifPlugin.cmake" + "/usr/lib64/cmake/Qt5Gui/Qt5Gui_QGtk2ThemePlugin.cmake" "/usr/lib64/cmake/Qt5Gui/Qt5Gui_QGtk3ThemePlugin.cmake" + "/usr/lib64/cmake/Qt5Gui/Qt5Gui_QICNSPlugin.cmake" "/usr/lib64/cmake/Qt5Gui/Qt5Gui_QICOPlugin.cmake" "/usr/lib64/cmake/Qt5Gui/Qt5Gui_QIbusPlatformInputContextPlugin.cmake" + "/usr/lib64/cmake/Qt5Gui/Qt5Gui_QJp2Plugin.cmake" "/usr/lib64/cmake/Qt5Gui/Qt5Gui_QJpegPlugin.cmake" "/usr/lib64/cmake/Qt5Gui/Qt5Gui_QLibInputPlugin.cmake" "/usr/lib64/cmake/Qt5Gui/Qt5Gui_QLinuxFbIntegrationPlugin.cmake" "/usr/lib64/cmake/Qt5Gui/Qt5Gui_QMinimalEglIntegrationPlugin.cmake" "/usr/lib64/cmake/Qt5Gui/Qt5Gui_QMinimalIntegrationPlugin.cmake" + "/usr/lib64/cmake/Qt5Gui/Qt5Gui_QMngPlugin.cmake" "/usr/lib64/cmake/Qt5Gui/Qt5Gui_QOffscreenIntegrationPlugin.cmake" "/usr/lib64/cmake/Qt5Gui/Qt5Gui_QPdfPlugin.cmake" "/usr/lib64/cmake/Qt5Gui/Qt5Gui_QSvgIconPlugin.cmake" "/usr/lib64/cmake/Qt5Gui/Qt5Gui_QSvgPlugin.cmake" + "/usr/lib64/cmake/Qt5Gui/Qt5Gui_QTgaPlugin.cmake" + "/usr/lib64/cmake/Qt5Gui/Qt5Gui_QTiffPlugin.cmake" "/usr/lib64/cmake/Qt5Gui/Qt5Gui_QTsLibPlugin.cmake" "/usr/lib64/cmake/Qt5Gui/Qt5Gui_QTuioTouchPlugin.cmake" + "/usr/lib64/cmake/Qt5Gui/Qt5Gui_QVirtualKeyboardPlugin.cmake" "/usr/lib64/cmake/Qt5Gui/Qt5Gui_QVncIntegrationPlugin.cmake" "/usr/lib64/cmake/Qt5Gui/Qt5Gui_QWaylandEglPlatformIntegrationPlugin.cmake" "/usr/lib64/cmake/Qt5Gui/Qt5Gui_QWaylandIntegrationPlugin.cmake" "/usr/lib64/cmake/Qt5Gui/Qt5Gui_QWaylandXCompositeEglPlatformIntegrationPlugin.cmake" "/usr/lib64/cmake/Qt5Gui/Qt5Gui_QWaylandXCompositeGlxPlatformIntegrationPlugin.cmake" + "/usr/lib64/cmake/Qt5Gui/Qt5Gui_QWbmpPlugin.cmake" + "/usr/lib64/cmake/Qt5Gui/Qt5Gui_QWebGLIntegrationPlugin.cmake" + "/usr/lib64/cmake/Qt5Gui/Qt5Gui_QWebpPlugin.cmake" "/usr/lib64/cmake/Qt5Gui/Qt5Gui_QXcbEglIntegrationPlugin.cmake" "/usr/lib64/cmake/Qt5Gui/Qt5Gui_QXcbGlxIntegrationPlugin.cmake" "/usr/lib64/cmake/Qt5Gui/Qt5Gui_QXcbIntegrationPlugin.cmake" @@ -109,6 +119,11 @@ set(CMAKE_MAKEFILE_DEPENDS "/usr/lib64/cmake/Qt5Widgets/Qt5WidgetsConfigExtras.cmake" "/usr/lib64/cmake/Qt5Widgets/Qt5WidgetsConfigVersion.cmake" "/usr/lib64/cmake/Qt5Widgets/Qt5WidgetsMacros.cmake" + "/usr/lib64/cmake/Qt5Widgets/Qt5Widgets_QBB10StylePlugin.cmake" + "/usr/lib64/cmake/Qt5Widgets/Qt5Widgets_QCleanlooksStylePlugin.cmake" + "/usr/lib64/cmake/Qt5Widgets/Qt5Widgets_QGtk2StylePlugin.cmake" + "/usr/lib64/cmake/Qt5Widgets/Qt5Widgets_QMotifStylePlugin.cmake" + "/usr/lib64/cmake/Qt5Widgets/Qt5Widgets_QPlastiqueStylePlugin.cmake" "/usr/share/ECM/cmake/ECMConfig.cmake" "/usr/share/ECM/cmake/ECMConfigVersion.cmake" "/usr/share/ECM/find-modules/ECMFindModuleHelpersStub.cmake" diff --git a/src/assets/parallel.jpg b/src/assets/parallel.jpg new file mode 100644 index 0000000..c2316fb Binary files /dev/null and b/src/assets/parallel.jpg differ diff --git a/src/qml/main.qml b/src/qml/main.qml index 3747066..6537ca0 100644 --- a/src/qml/main.qml +++ b/src/qml/main.qml @@ -12,6 +12,7 @@ Kirigami.ApplicationWindow { id: root property bool libraryOpen: true + property bool presenting: false pageStack.initialPage: mainPage header: Presenter.Header {} diff --git a/src/qml/presenter/Header.qml b/src/qml/presenter/Header.qml index deb31fb..d4b9883 100644 --- a/src/qml/presenter/Header.qml +++ b/src/qml/presenter/Header.qml @@ -40,13 +40,13 @@ Kirigami.ActionToolBar { text: "Go Live" onTriggered: { print("Window is loading") - presentLoader.active = true + presenting = true } }, Kirigami.Action { - icon.name: "sidebar-collapse-right" - text: "Close Library" + icon.name: libraryOpen ? "sidebar-collapse-right" : "sidebar-expand-right" + text: libraryOpen ? "Close Library" : "Open Library" onTriggered: toggleLibrary() } diff --git a/src/qml/presenter/MainWindow.qml b/src/qml/presenter/MainWindow.qml index 6cb9225..d2c2b77 100644 --- a/src/qml/presenter/MainWindow.qml +++ b/src/qml/presenter/MainWindow.qml @@ -76,68 +76,20 @@ Controls.Page { Loader { id: presentLoader - active: false + active: presenting sourceComponent: Window { - id: presentWindow + id: presentationWindow title: "presentation-window" height: maximumHeight width: maximumWidth - visible: true - onClosing: presentLoader.active = false + screen: Qt.application.screens[1] + onClosing: presenting = false Component.onCompleted: { - presentWindow.showFullScreen(); + presentationWindow.showFullScreen(); } - Item { - id: basePresentationLayer - anchors.fill: parent - Rectangle { - id: basePrColor - anchors.fill: parent - color: "black" - - MediaPlayer { - id: videoPlayer - source: video - loops: MediaPlayer.Infinite - autoPlay: true - notifyInterval: 100 - } - - VideoOutput { - id: videoOutput - anchors.fill: parent - source: videoPlayer - } - MouseArea { - id: playArea - anchors.fill: parent - onPressed: videoPlayer.play(); - } - - Controls.ProgressBar { - id: progressBar - - anchors.left: parent.left - anchors.right: parent.right - anchors.bottom: parent.bottom - anchors.margins: 100 - from: 0 - to: videoPlayer.duraion - value: videoPlayer.position/videoPlayer.duration - - height: 30 - - MouseArea { - anchors.fill: parent - - onClicked: { - if (videoPlayer.seekable) { - videoPlayer.seek(videoPlayer.duration * mouse.x/width); - } - } - } - } - } + Presenter.Slide { + id: presentationSlide + imageSource: "../../assets/parallel.jpg" } } } diff --git a/src/qml/presenter/Slide.qml b/src/qml/presenter/Slide.qml index 2fd0eee..791b491 100644 --- a/src/qml/presenter/Slide.qml +++ b/src/qml/presenter/Slide.qml @@ -3,162 +3,71 @@ import QtQuick.Controls 2.15 as Controls import QtQuick.Layouts 1.2 import QtMultimedia 5.15 import QtAudioEngine 1.15 +import QtGraphicalEffects 1.15 import org.kde.kirigami 2.13 as Kirigami import "./" as Presenter Item { - /* - Slides can only be instantiated as a direct child of a Presentation {} as they rely on - several properties there. - */ + id: root + anchors.fill: parent - id: slide + property real textSize: 50 + property bool dropShadow: false + property url imageSource: "" + property url videoSource: "" + property string chosenFont: "Quicksand" - property bool isSlide: true; + Rectangle { + id: basePrColor + anchors.fill: parent + color: "black" - property bool delayPoints: false; - property int _pointCounter: 0; - function _advance() { - if (!parent.allowDelay) - return false; - - _pointCounter = _pointCounter + 1; - if (_pointCounter < content.length) - return true; - _pointCounter = 0; - return false; - } - - property string title; - property variant content: [] - property string centeredText - property string writeInText; - property string notes; - - property real fontSize: parent.height * 0.05 - property real fontScale: 1 - - property real baseFontSize: fontSize * fontScale - property real titleFontSize: fontSize * 1.2 * fontScale - property real bulletSpacing: 1 - - property real contentWidth: width - - // Define the slide to be the "content area" - x: parent.width * 0.05 - y: parent.height * 0.2 - width: parent.width * 0.9 - height: parent.height * 0.7 - - property real masterWidth: parent.width - property real masterHeight: parent.height - - property color titleColor: parent.titleColor; - property color textColor: parent.textColor; - property string fontFamily: parent.fontFamily; - property int textFormat: Text.PlainText - - visible: false - - Controls.Label { - id: titleText - font.pixelSize: titleFontSize - text: title; - anchors.horizontalCenter: parent.horizontalCenter - anchors.bottom: parent.top - anchors.bottomMargin: parent.fontSize * 1.5 - font.bold: true; - font.family: slide.fontFamily - color: slide.titleColor - horizontalAlignment: Text.Center - z: 1 - } - - Controls.Label { - id: centeredId - width: parent.width - anchors.centerIn: parent - anchors.verticalCenterOffset: - parent.y / 3 - text: centeredText - horizontalAlignment: Text.Center - font.pixelSize: baseFontSize - font.family: slide.fontFamily - color: slide.textColor - wrapMode: Text.Wrap - } - - Controls.Label { - id: writeInTextId - property int length; - font.family: slide.fontFamily - font.pixelSize: baseFontSize - color: slide.textColor - - anchors.fill: parent; - wrapMode: Text.Wrap - - text: slide.writeInText.substring(0, length); - - NumberAnimation on length { - from: 0; - to: slide.writeInText.length; - duration: slide.writeInText.length * 30; - running: slide.visible && parent.visible && slide.writeInText.length > 0 + MediaPlayer { + id: videoPlayer + source: videoSource + loops: MediaPlayer.Infinite + autoPlay: true + notifyInterval: 100 } - visible: slide.writeInText != undefined; - } + VideoOutput { + id: videoOutput + anchors.fill: parent + source: videoPlayer + } + MouseArea { + id: playArea + anchors.fill: parent + onPressed: videoPlayer.play(); + } + Image { + id: backgroundImage + anchors.fill: parent + source: imageSource + fillMode: Image.PreserveAspectCrop + clip: true - Column { - id: contentId - anchors.fill: parent + Controls.Label { + id: lyrics + text: "This is some test lyrics" // change to song lyrics of current verse + font.pointSize: textSize + font.family: chosenFont + style: Text.Raised + anchors.centerIn: parent + } - Repeater { - model: content.length - - Row { - id: row - - function decideIndentLevel(s) { return s.charAt(0) == " " ? 1 + decideIndentLevel(s.substring(1)) : 0 } - property int indentLevel: decideIndentLevel(content[index]) - property int nextIndentLevel: index < content.length - 1 ? decideIndentLevel(content[index+1]) : 0 - property real indentFactor: (10 - row.indentLevel * 2) / 10; - - height: text.height + (nextIndentLevel == 0 ? 1 : 0.3) * slide.baseFontSize * slide.bulletSpacing - x: slide.baseFontSize * indentLevel - visible: (!slide.parent.allowDelay || !delayPoints) || index <= _pointCounter - - Rectangle { - id: dot - anchors.baseline: text.baseline - anchors.baselineOffset: -text.font.pixelSize / 2 - width: text.font.pixelSize / 3 - height: text.font.pixelSize / 3 - color: slide.textColor - radius: width / 2 - opacity: text.text.length == 0 ? 0 : 1 - } - - Item { - id: space - width: dot.width * 1.5 - height: 1 - } - - Controls.Label { - id: text - width: slide.contentWidth - parent.x - dot.width - space.width - font.pixelSize: baseFontSize * row.indentFactor - text: content[index] - textFormat: slide.textFormat - wrapMode: Text.WordWrap - color: slide.textColor - horizontalAlignment: Text.AlignLeft - font.family: slide.fontFamily - } + DropShadow { + id: textDropShadow + source: lyrics + anchors.fill: lyrics + horizontalOffset: 3 + verticalOffset: 3 + radius: 8.0 + samples: 17 + color: "#80000000" + visible: true } } } - } diff --git a/src/qml/presenter/SongEditor.qml b/src/qml/presenter/SongEditor.qml index abea756..b2d698d 100644 --- a/src/qml/presenter/SongEditor.qml +++ b/src/qml/presenter/SongEditor.qml @@ -48,6 +48,9 @@ Item { Controls.ToolButton { text: "Effects" } + Controls.ToolButton { + text: "Background" + } } } diff --git a/src/resources.qrc b/src/resources.qrc index 965d502..ebdf96c 100644 --- a/src/resources.qrc +++ b/src/resources.qrc @@ -11,5 +11,7 @@ qml/presenter/Actions.qml qml/presenter/PanelItem.qml qml/presenter/SongEditor.qml + qml/presenter/Slide.qml + assets/parallel.jpg