From db1d3d37e9c1c6ca2137b2affe662903b0ab69c9 Mon Sep 17 00:00:00 2001 From: Sebastian Gottfried Date: Wed, 19 Dec 2012 15:41:40 +0100 Subject: [PATCH 01/32] Plasma QML components: fix internal anchoring in Button and ToolButton There is a bug in the tool button and button components resulting in layout breakage if one clears and sets the text property of the component when not visible, see the attached screenshot. I have tried to solve the issue without changing the existing anchoring system, but without success. The only working solution was to put the icon and the label item into Row item. That way I was able to fix the bug and even get rid of the ugly explicit non-declarative anchor assignments. I have also removed the preferredWidth property of the label item, that one always evaluated to paintedWidth, anyway. REVIEW: 107813 --- .../plasmacomponents/qml/Button.qml | 33 +++++-------------- .../plasmacomponents/qml/ToolButton.qml | 33 +++++-------------- 2 files changed, 17 insertions(+), 49 deletions(-) diff --git a/declarativeimports/plasmacomponents/qml/Button.qml b/declarativeimports/plasmacomponents/qml/Button.qml index 5bfb8d74e..1168e6a7f 100644 --- a/declarativeimports/plasmacomponents/qml/Button.qml +++ b/declarativeimports/plasmacomponents/qml/Button.qml @@ -94,7 +94,7 @@ Item { /** * Smallest width this button can be to show all the contents */ - property real minimumWidth: icon.width + label.preferredWidth + surfaceNormal.margins.left + surfaceNormal.margins.right + ((icon.valid) ? surfaceNormal.margins.left : 0) + property real minimumWidth: icon.width + label.paintedWidth + surfaceNormal.margins.left + surfaceNormal.margins.right + ((icon.valid) ? surfaceNormal.margins.left : 0) /** * Smallest height this button can be to show all the contents @@ -191,9 +191,10 @@ Item { opacity: 0 } - Item { + Row { id: buttonContent state: (internal.userPressed || checked) ? "pressed" : "normal" + spacing: icon.valid ? surfaceNormal.margins.left : 0 states: [ State { name: "normal" }, @@ -229,35 +230,17 @@ Item { PlasmaCore.IconItem { id: icon - - anchors { - verticalCenter: parent.verticalCenter - left: label.text.length > 0 ? parent.left : undefined - horizontalCenter: label.text.length > 0 ? undefined : parent.horizontalCenter - } + anchors.verticalCenter: parent.verticalCenter + width: valid? parent.height: 0 + height: width active: shadow.hasOverState && mouse.containsMouse - height: parent.height - width: parent.height } Text { id: label - //FIXME: why this is needed? - onTextChanged: { - icon.anchors.horizontalCenter = label.text.length > 0 ? undefined : icon.parent.horizontalCenter - icon.anchors.left = label.text.length > 0 ? icon.parent.left : undefined - } - - property int preferredWidth: button.width < button.implicitWidth ? paintedWidth: paintedWidth - - anchors { - top: parent.top - bottom: parent.bottom - right: parent.right - left: icon.valid ? icon.right : parent.left - leftMargin: icon.valid ? parent.anchors.leftMargin : 0 - } + width: parent.width - icon.width - parent.spacing + height: parent.height font.capitalization: theme.defaultFont.capitalization font.family: theme.defaultFont.family diff --git a/declarativeimports/plasmacomponents/qml/ToolButton.qml b/declarativeimports/plasmacomponents/qml/ToolButton.qml index 594067d88..f517780b0 100644 --- a/declarativeimports/plasmacomponents/qml/ToolButton.qml +++ b/declarativeimports/plasmacomponents/qml/ToolButton.qml @@ -94,7 +94,7 @@ Item { //icon + label + left margin + right margin + spacing between icon and text //here it assumesleft margin = right top = bottom, why? // because the right and bottom margins can be disabled, so they would return 0, but their actual size is still needed for size hints - property real minimumWidth: theme.smallIconSize + label.preferredWidth + delegate.margins.left + delegate.margins.left + ((icon.valid) ? delegate.margins.left : 0) + property real minimumWidth: theme.smallIconSize + label.paintedWidth + delegate.margins.left + delegate.margins.left + ((icon.valid) ? delegate.margins.left : 0) property real minimumHeight: Math.max(theme.smallIconSize, label.paintedHeight) + delegate.margins.top + delegate.margins.top implicitWidth: { @@ -342,7 +342,7 @@ Item { } } - Item { + Row { anchors { fill: parent leftMargin: delegate.margins.left @@ -351,37 +351,22 @@ Item { bottomMargin: delegate.margins.bottom } + spacing: icon.valid ? delegate.margins.left : 0 + PlasmaCore.IconItem { id: icon - - anchors { - verticalCenter: parent.verticalCenter - left: label.text ? parent.left : undefined - horizontalCenter: label.text ? undefined : parent.horizontalCenter - } - height: parent.height - width: parent.height + anchors.verticalCenter: parent.verticalCenter + width: valid ? parent.height: 0 + height: width active: delegate.item.hasOverState && mouse.containsMouse } Text { id: label - //FIXME: why this is needed? - onPaintedWidthChanged: { - icon.anchors.horizontalCenter = label.paintedWidth > 0 ? undefined : icon.parent.horizontalCenter - icon.anchors.left = label.paintedWidth > 0 ? icon.parent.left : undefined - } + width: parent.width - icon.width - parent.spacing + height: parent.height - property int preferredWidth: button.width < button.implicitWidth ? paintedWidth: paintedWidth - - anchors { - top: parent.top - bottom: parent.bottom - left: icon.valid ? icon.right : parent.left - leftMargin: icon.valid ? delegate.margins.left : 0 - right: parent.right - } font.capitalization: theme.defaultFont.capitalization font.family: theme.defaultFont.family font.italic: theme.defaultFont.italic From ffabd9493817656f98262abfddd7a79448fc6515 Mon Sep 17 00:00:00 2001 From: Weng Xuetian Date: Sat, 22 Dec 2012 21:43:01 -0500 Subject: [PATCH 02/32] fix QMimeData copy, setData is hidden and the real setData will not be used. --- declarativeimports/draganddrop/DeclarativeMimeData.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/declarativeimports/draganddrop/DeclarativeMimeData.cpp b/declarativeimports/draganddrop/DeclarativeMimeData.cpp index f6b4613d4..28532a2de 100644 --- a/declarativeimports/draganddrop/DeclarativeMimeData.cpp +++ b/declarativeimports/draganddrop/DeclarativeMimeData.cpp @@ -48,7 +48,7 @@ DeclarativeMimeData::DeclarativeMimeData(const QMimeData* copy) { // Copy the standard MIME data foreach(QString format, copy->formats()) { - this->setData(format, copy->data(format)); + QMimeData::setData(format, copy->data(format)); } // If the object we are copying actually is a DeclarativeMimeData, copy our extended properties as well From f31291bf5e47b1a0118214ef37e64afe239b8cb2 Mon Sep 17 00:00:00 2001 From: Script Kiddy Date: Sun, 23 Dec 2012 07:59:29 +0100 Subject: [PATCH 03/32] SVN_SILENT made messages (.desktop file) --- kpart/plasma-kpart.desktop | 1 - remotewidgetshelper/kcm_remotewidgets.actions | 2 -- scriptengines/javascript/data/plasma-javascriptaddon.desktop | 1 - .../data/plasma-packagestructure-javascript-addon.desktop | 2 -- .../data/plasma-scriptengine-applet-declarative.desktop | 2 -- .../data/plasma-scriptengine-applet-simple-javascript.desktop | 2 -- .../data/plasma-scriptengine-dataengine-javascript.desktop | 1 - .../data/plasma-scriptengine-runner-javascript.desktop | 2 -- 8 files changed, 13 deletions(-) diff --git a/kpart/plasma-kpart.desktop b/kpart/plasma-kpart.desktop index c4f2fe6ad..4431124f9 100644 --- a/kpart/plasma-kpart.desktop +++ b/kpart/plasma-kpart.desktop @@ -3,7 +3,6 @@ Name=plasma-kpart Name[ast]=plasma-kpart Name[bg]=plasma-kpart Name[bn]=প্লাসমা কে-পার্ট -Name[bs]=plasma-kpart Name[ca]=plasma-kpart Name[ca@valencia]=plasma-kpart Name[cs]=plasma-kpart diff --git a/remotewidgetshelper/kcm_remotewidgets.actions b/remotewidgetshelper/kcm_remotewidgets.actions index 3e1d8c4d7..e3f3f54f4 100644 --- a/remotewidgetshelper/kcm_remotewidgets.actions +++ b/remotewidgetshelper/kcm_remotewidgets.actions @@ -3,7 +3,6 @@ Name=Save remote widgets' policies Name[ar]=احفظ سياسات الودجات البعيدة Name[ast]=Guardáu de polítiques d'elementos gráficos remotos Name[bg]=Запазване на правилата на отдалечените джаджи -Name[bs]=Sačuvaj smjernice za udaljene grafičke kontrole Name[ca]=Desa les polítiques d'estris remots Name[ca@valencia]=Alça les polítiques d'estris remots Name[cs]=Uložit zásady vzdálených widgetů @@ -66,7 +65,6 @@ Description=Prevents the system from saving remote plasma widgets' policies Description[ar]=يمنع النظام من حفظ سياسات ودجات بلازما البعيدة Description[ast]=Impide que'l sistema guarde polítiques d'elementos gráficos Plasma remotos Description[bg]=Забраняване запазването на правилата на отдалечените джаджи -Description[bs]=Sprečava sistem da sačuva smjernice udaljenih plazma grafičkih kontrola Description[ca]=Evita al sistema de desar polítiques d'estris remots del plasma Description[ca@valencia]=Evita al sistema d'alçar polítiques d'estris remots del plasma Description[cs]=Zabrání systému ukládat zásady vzdálených widgetů plasmy diff --git a/scriptengines/javascript/data/plasma-javascriptaddon.desktop b/scriptengines/javascript/data/plasma-javascriptaddon.desktop index fc6d0ceef..528214ae9 100644 --- a/scriptengines/javascript/data/plasma-javascriptaddon.desktop +++ b/scriptengines/javascript/data/plasma-javascriptaddon.desktop @@ -2,7 +2,6 @@ Name=Plasma JavaScript Addon Name[ast]=Complementu de JavaScript pa Plasma Name[bg]=Добавка за JavaScript на Plasma -Name[bs]=Plazma javaskriptni dodatak Name[ca]=Complement del JavaScript pel Plasma Name[ca@valencia]=Complement del JavaScript pel Plasma Name[cs]=Doplněk Plasmy JavaScript diff --git a/scriptengines/javascript/data/plasma-packagestructure-javascript-addon.desktop b/scriptengines/javascript/data/plasma-packagestructure-javascript-addon.desktop index 4afcbd7de..98af588b8 100644 --- a/scriptengines/javascript/data/plasma-packagestructure-javascript-addon.desktop +++ b/scriptengines/javascript/data/plasma-packagestructure-javascript-addon.desktop @@ -3,7 +3,6 @@ Name=Javascript Addon Name[ast]=Complementu de JavaScript Name[bg]=Добавка за Javascript Name[bn]=জাভাস্ক্রিপ্ট অ্যাড-অন -Name[bs]=Javaskriptni dodatak Name[ca]=Complement del Javascript Name[ca@valencia]=Complement del Javascript Name[cs]=Doplněk JavaScript @@ -65,7 +64,6 @@ Name[zh_TW]=Javascript Addon Comment=Addons for Javascript Plasma plugins Comment[ast]=Amestaos pa complementos de JavaScript pa Plasma Comment[bg]=Добавки за приставките за Javascript на Plasma -Comment[bs]=Dodaci za javaskriptne plazma priključke Comment[ca]=Complements pels connectors Javascript del Plasma Comment[ca@valencia]=Complements pels connectors Javascript del Plasma Comment[cs]=Doplňky pro javascriptové zásuvné moduly plasmy diff --git a/scriptengines/javascript/data/plasma-scriptengine-applet-declarative.desktop b/scriptengines/javascript/data/plasma-scriptengine-applet-declarative.desktop index 450db37ae..2f649cf2c 100644 --- a/scriptengines/javascript/data/plasma-scriptengine-applet-declarative.desktop +++ b/scriptengines/javascript/data/plasma-scriptengine-applet-declarative.desktop @@ -2,7 +2,6 @@ Name=Declarative widget Name[ast]=Elementu gráficu declarativu Name[bg]=Декларативна джаджа -Name[bs]=Deklarativna grafička kontrola Name[ca]=Estri declaratiu Name[ca@valencia]=Estri declaratiu Name[cs]=Deklarativní widget @@ -60,7 +59,6 @@ Name[zh_TW]=宣告元件 Comment=Native Plasma widget written in QML and JavaScript Comment[ast]=Elementu gráficu nativu de Plasma escritu en QML y JavaScript Comment[bg]=Оригинална джаджа за Plasma, написана наQML и JavaScript -Comment[bs]=Samosvojni plazma grafičkih kontrola napisana u QML‑u i javaskriptu Comment[ca]=Estri nadiu del Plasma escrit en QML i JavaScript Comment[ca@valencia]=Estri nadiu del Plasma escrit en QML i JavaScript Comment[cs]=Nativní Plasma widget napsaný v QML a JavaScriptu diff --git a/scriptengines/javascript/data/plasma-scriptengine-applet-simple-javascript.desktop b/scriptengines/javascript/data/plasma-scriptengine-applet-simple-javascript.desktop index f9e281620..f12474581 100644 --- a/scriptengines/javascript/data/plasma-scriptengine-applet-simple-javascript.desktop +++ b/scriptengines/javascript/data/plasma-scriptengine-applet-simple-javascript.desktop @@ -6,7 +6,6 @@ Name[be@latin]=Widžet „JavaScript” Name[bg]=Джаджа JavaScript Name[bn]=জাভাস্ক্রিপ্ট উইজেট Name[bn_IN]=JavaScript Widget -Name[bs]=Javascript grafička kontrola Name[ca]=Estri del JavaScript Name[ca@valencia]=Estri del JavaScript Name[cs]=JavaScript Widget @@ -81,7 +80,6 @@ Comment[ar]=ودجة بلازما أصلية كتبت بجافا سكربت Comment[ast]=Elementu gráficu nativu de Plasma escritu en JavaScript Comment[be@latin]=Widžet systemy „Plasma”, napisany ŭ movie „JavaScript” Comment[bg]=Оригинална джаджа за Plasma, написана с JavaScript -Comment[bs]=Samosvojni plazma grafička kontrola napisana u javaskriptu Comment[ca]=Estri nadiu del Plasma escrit en JavaScript Comment[ca@valencia]=Estri nadiu del Plasma escrit en JavaScript Comment[cs]=Nativní Plasma widget napsaný v JavaScriptu diff --git a/scriptengines/javascript/data/plasma-scriptengine-dataengine-javascript.desktop b/scriptengines/javascript/data/plasma-scriptengine-dataengine-javascript.desktop index 163b1166e..c3012a97f 100644 --- a/scriptengines/javascript/data/plasma-scriptengine-dataengine-javascript.desktop +++ b/scriptengines/javascript/data/plasma-scriptengine-dataengine-javascript.desktop @@ -4,7 +4,6 @@ Name[ar]=مشغل جافا سكربت Name[ast]=Motor de datos JavaScript Name[bg]=Ядро за данни на JavaScript Name[bn]=জাভাস্ক্রিপ্ট ডেটা-ইঞ্জিন -Name[bs]=Javascript pogon podataka Name[ca]=Motor de dades de JavaScript Name[ca@valencia]=Motor de dades de JavaScript Name[cs]=Datový nástroj JavaScript diff --git a/scriptengines/javascript/data/plasma-scriptengine-runner-javascript.desktop b/scriptengines/javascript/data/plasma-scriptengine-runner-javascript.desktop index e56741d41..038186cb0 100644 --- a/scriptengines/javascript/data/plasma-scriptengine-runner-javascript.desktop +++ b/scriptengines/javascript/data/plasma-scriptengine-runner-javascript.desktop @@ -6,7 +6,6 @@ Name[be@latin]=Uklučeńnie „JavaScript” Name[bg]=Изпълнение на JavaScript Name[bn]=জাভাস্ক্রিপ্ট রানার Name[bn_IN]=JavaScript Runner -Name[bs]=Javascript izvođač Name[ca]=Executor de JavaScript Name[ca@valencia]=Executor de JavaScript Name[cs]=Spouštěč JavaScriptu @@ -84,7 +83,6 @@ Comment[be@latin]=Uklučeńnie „JavaScript”. Comment[bg]=Изпълнение на JavaScript Comment[bn]=জাভাস্ক্রিপ্ট চালক Comment[bn_IN]=JavaScript Runner -Comment[bs]=Javascript izvođač Comment[ca]=Executor de JavaScript Comment[ca@valencia]=Executor de JavaScript Comment[cs]=Spouštěč JavaScriptu From 107f3734dee4f33366ac097184bc84af33ef9d50 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Aur=C3=A9lien=20G=C3=A2teau?= Date: Mon, 17 Dec 2012 15:48:36 +0100 Subject: [PATCH 04/32] Do not include touch components --- declarativeimports/plasmacomponents/Mainpage.dox | 2 ++ 1 file changed, 2 insertions(+) diff --git a/declarativeimports/plasmacomponents/Mainpage.dox b/declarativeimports/plasmacomponents/Mainpage.dox index b911aaf8f..76c63209e 100644 --- a/declarativeimports/plasmacomponents/Mainpage.dox +++ b/declarativeimports/plasmacomponents/Mainpage.dox @@ -40,4 +40,6 @@ */ // DOXYGEN_SET_PROJECT_NAME = PlasmaComponents +// Maybe there should be a touch-specific api doc? +// DOXYGEN_SET_EXCLUDE += @topdir@/plasma/declarativeimports/plasmacomponents/platformcomponents // vim:ts=4:sw=4:expandtab:filetype=doxygen From bb9917084439f0b63d922a49b7fdef88f7bc7f6d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Aur=C3=A9lien=20G=C3=A2teau?= Date: Mon, 17 Dec 2012 15:48:59 +0100 Subject: [PATCH 05/32] dox: properties => elements --- declarativeimports/plasmacomponents/qml/CheckBox.qml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/declarativeimports/plasmacomponents/qml/CheckBox.qml b/declarativeimports/plasmacomponents/qml/CheckBox.qml index 13659440e..93f82b03e 100644 --- a/declarativeimports/plasmacomponents/qml/CheckBox.qml +++ b/declarativeimports/plasmacomponents/qml/CheckBox.qml @@ -32,7 +32,7 @@ import "private" as Private * Qt.Key_Select, Qt.Key_Return, and Qt.Key_Enter hardware keys that send the * clicked signal. * - * All properties of this component are defined in DualStateButton, its base component. + * All elements of this component are defined in DualStateButton, its base component. */ Private.DualStateButton { id: checkBox From 0bf70da2fef07f4c1ea90188235f5778540a4226 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Aur=C3=A9lien=20G=C3=A2teau?= Date: Mon, 17 Dec 2012 15:49:18 +0100 Subject: [PATCH 06/32] Doxygenize CommonDialog --- .../plasmacomponents/qml/CommonDialog.qml | 46 +++++++------------ 1 file changed, 17 insertions(+), 29 deletions(-) diff --git a/declarativeimports/plasmacomponents/qml/CommonDialog.qml b/declarativeimports/plasmacomponents/qml/CommonDialog.qml index aad37b1be..b7064752e 100644 --- a/declarativeimports/plasmacomponents/qml/CommonDialog.qml +++ b/declarativeimports/plasmacomponents/qml/CommonDialog.qml @@ -44,42 +44,30 @@ import QtQuick 1.1 import org.kde.plasma.core 0.1 as PlasmaCore import "." 0.1 - -/**Documented API -Inherits: - Dialog - -Imports: - QtQuick 1.0 - org.kde.plasma.core - -Description: - CommonDialog is a convenience component that provides a dialog with the platform-style title area. You only have to define titleText. CommonDialog handles its layout automatically. - Note: This component is experimental, so it may be changed or removed in future releases. - -Properties: - string titleText: - the title of the dialog. - - string titleIcon: - the name or path of the dialog title icon - - Array variant buttonTexts: - the texts of all the buttons - -Signals: - buttonClicked(int index): - Emitted when the user clicks on a button - @arg int index: the index of the clicked button: buttonTexts[index] will hold the text of the clicked button. - -**/ +/** + * CommonDialog is a convenience component that provides a dialog with the + * platform-style title area. You only have to define titleText. CommonDialog + * handles its layout automatically. + * + * Note: This component is experimental, so it may be changed or removed in + * future releases. + */ Dialog { id: root + /** type:string the title of the dialog */ property alias titleText: titleAreaText.text + + /** the name or path of the dialog title icon */ property string titleIcon + + /** the texts of all the buttons */ property variant buttonTexts: [] + /** + * Emitted when the use clicks on a button + * @param index the index of the clicked button: buttonTexts[index] will hold the text of the clicked button. + */ signal buttonClicked(int index) onButtonTextsChanged: { From 00c289c6108f07b085b699816e5259e5efe95c7f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Aur=C3=A9lien=20G=C3=A2teau?= Date: Mon, 17 Dec 2012 15:49:34 +0100 Subject: [PATCH 07/32] Doxygenize ContextMenu --- .../plasmacomponents/qml/ContextMenu.qml | 27 ++++--------------- 1 file changed, 5 insertions(+), 22 deletions(-) diff --git a/declarativeimports/plasmacomponents/qml/ContextMenu.qml b/declarativeimports/plasmacomponents/qml/ContextMenu.qml index 3568b3081..bbb6dd33a 100644 --- a/declarativeimports/plasmacomponents/qml/ContextMenu.qml +++ b/declarativeimports/plasmacomponents/qml/ContextMenu.qml @@ -40,31 +40,14 @@ ** ****************************************************************************/ -/**Documented API -Inherits: - Item - -Imports: - QtQuick 1.1 - org.kde.plasma.components - -Description: - Provides a component with list of options that the user can choose from. - -Properties: - * QtObject model: - This property holds the model providing data for the menu. - The model provides the set of data that is used to create the items in the view. - Each model item must have a property called "text" or "display". - -Methods: - * void rebuildMenu(): - Rebuild the menu if property model is defined. -**/ - import QtQuick 1.1 import org.kde.plasma.components 0.1 +/** + * Provides a component with list of options that the user can choose from. + * + * All elements of this component are defined in Menu, its base component. + */ Menu { id: root } From 4399eed01778804118c3dff1fbbc985a7ac0183f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Aur=C3=A9lien=20G=C3=A2teau?= Date: Mon, 17 Dec 2012 18:28:08 +0100 Subject: [PATCH 08/32] Doxygenize Dialog --- .../plasmacomponents/qml/Dialog.qml | 144 ++++++++++-------- 1 file changed, 83 insertions(+), 61 deletions(-) diff --git a/declarativeimports/plasmacomponents/qml/Dialog.qml b/declarativeimports/plasmacomponents/qml/Dialog.qml index 6e1a561b9..f01309940 100644 --- a/declarativeimports/plasmacomponents/qml/Dialog.qml +++ b/declarativeimports/plasmacomponents/qml/Dialog.qml @@ -40,90 +40,97 @@ ** ****************************************************************************/ -/**Documented API -Inherits: - Item - -Imports: - QtQuick 1.0 - org.kde.plasma.core - -Description: - Provides a top-level window for short-term tasks and brief interaction with the user. - A dialog floats on the top layer of the application view, usually overlapping the area reserved for the application content. Normally, a dialog provides information and gives warnings to the user, or asks the user to answer a question or select an option. - -Properties: - list buttons: - A list of items in the dialog's button area. For example, you can use Row or Button components but you can also use any number of components that are based on Item component. - - list content: - A list of items in the dialog's content area. You can use any component that is based on Item. For example, you can use ListView, so that the user can select from a list of names. - - int status: - Indicates the dialog's phase in its life cycle. The values are as follows: - - DialogStatus.Opening - the dialog is opening - - DialogStatus.Open - the dialog is open and visible to the user - - DialogStatus.Closing - the dialog is closing - - DialogStatus.Closed - the dialog is closed and not visible to the user - The dialog's initial status is DialogStatus.Closed. - - list title: - A list of items in the dialog's title area. You can use a Text component but also any number of components that are based on Item. For example, you can use Text and Image components. - - Item visualParent: - The item that the dialog refers to. The dialog will usually be positioned relative to VisualParent - -Signals: - accepted(): - This signal is emitted when the user accepts the dialog's request or the accept() method is called. - See also rejected(). - - clickedOutside(): This signal is emitted when the user taps in the area that is inside the dialog's visual parent area but outside the dialog's area. Normally the visual parent is the root object. In that case this signal is emitted if the user taps anywhere outside the dialog's area. - See also visualParent. - - rejected(): - This signal is emitted when the user rejects the dialog's request or the reject() method is called. - See also accepted(). - -Methods: - void accept(): - Accepts the dialog's request without any user interaction. The method emits the accepted() signal and closes the internalLoader.dialog. - See also reject(). - - void close(): - Closes the dialog without any user interaction. - - void open(): - Shows the dialog to the user. - - void reject(): - Rejects the dialog's request without any user interaction. The method emits the rejected() signal and closes the internalLoader.dialog. - See also accept(). -**/ - import QtQuick 1.0 import org.kde.plasma.core 0.1 as PlasmaCore import "private/AppManager.js" as Utils import "." 0.1 import "private" as Private +/** + * Top-level window for short-term tasks and brief interaction with the user + * + * A dialog floats on the top layer of the application view, usually + * overlapping the area reserved for the application content. Normally, a + * dialog provides information and gives warnings to the user, or asks the user + * to answer a question or select an option. + */ Item { id: root + /** + * type:list A list of items in the dialog's title area. You can use + * a Text component but also any number of components that are based on + * Item. For example, you can use Text and Image components. + */ property alias title: titleBar.children + + /** + * type:list A list of items in the dialog's content area. You can + * use any component that is based on Item. For example, you can use + * ListView, so that the user can select from a list of names. + */ property alias content: contentItem.children + + /** + * type:list A list of items in the dialog's button area. For + * example, you can use Row or Button components but you can also use any + * number of components that are based on Item component. + */ property alias buttons: buttonItem.children + + /** + * The item that the dialog refers to. The dialog will usually be + * positioned relative to VisualParent + */ property Item visualParent + + /** + * Indicates the dialog's phase in its life cycle. The values are as follows: + * + * - DialogStatus.Opening - the dialog is opening + * - DialogStatus.Open - the dialog is open and visible to the user + * - DialogStatus.Closing - the dialog is closing + * - DialogStatus.Closed - the dialog is closed and not visible to the user + * + * The dialog's initial status is DialogStatus.Closed. + */ property int status: DialogStatus.Closed property alias privateTitleHeight: titleBar.height property alias privateButtonsHeight: buttonItem.height + /** + * This signal is emitted when the user accepts the dialog's request or the + * accept() method is called. + * + * @see rejected() + */ signal accepted + + /** + * + * This signal is emitted when the user rejects the dialog's request or the + * reject() method is called. + * + * @see accepted() + */ + signal rejected + + /** + * This signal is emitted when the user taps in the area that is inside the + * dialog's visual parent area but outside the dialog's area. Normally the + * visual parent is the root object. In that case this signal is emitted if + * the user taps anywhere outside the dialog's area. + * + * @see visualParent + */ signal clickedOutside + /** + * Shows the dialog to the user. + */ function open() { dialogLayout.parent = internalLoader.item.mainItem @@ -139,6 +146,12 @@ Item { } } + /** + * Accepts the dialog's request without any user interaction. The method + * emits the accepted() signal and closes the internalLoader.dialog. + * + * @see reject() + */ function accept() { if (status == DialogStatus.Open) { if (internalLoader.dialog) { @@ -150,6 +163,12 @@ Item { } } + /** + * Rejects the dialog's request without any user interaction. The method + * emits the rejected() signal and closes the internalLoader.dialog. + * + * @see accept() + */ function reject() { if (status == DialogStatus.Open) { if (internalLoader.dialog) { @@ -161,6 +180,9 @@ Item { } } + /** + * Closes the dialog without any user interaction. + */ function close() { if (internalLoader.dialog) { internalLoader.dialog.visible = false From 982e5979b41fe0e04bf1bdaa615ce1902ed814c3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Aur=C3=A9lien=20G=C3=A2teau?= Date: Mon, 17 Dec 2012 18:31:37 +0100 Subject: [PATCH 09/32] Doxygenize Highlight --- .../plasmacomponents/qml/Highlight.qml | 33 ++++++++----------- 1 file changed, 13 insertions(+), 20 deletions(-) diff --git a/declarativeimports/plasmacomponents/qml/Highlight.qml b/declarativeimports/plasmacomponents/qml/Highlight.qml index 2b5735cb7..785a5444f 100644 --- a/declarativeimports/plasmacomponents/qml/Highlight.qml +++ b/declarativeimports/plasmacomponents/qml/Highlight.qml @@ -17,34 +17,27 @@ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ -/**Documented API -Inherits: - Item - -Imports: - QtQuick 1.1 - org.kde.plasma.core - -Description: - Used to highlight an item of a list. to be used only as the "highlight" property of the ListView and GridView primitive QML components (or their derivates) - Provides built-in animation of Behavior on opacity Easing.OutQuad for a duration of 250. (TODO, make optional? e.g. animate: false) - -Properties: - bool hover: - true if the user is hovering over the component - - bool pressed: - true if the mouse button is pressed over the component. -**/ - import QtQuick 1.0 import org.kde.plasma.core 0.1 as PlasmaCore +/** + * Used to highlight an item of a list. to be used only as the "highlight" + * property of the ListView and GridView primitive QML components (or their + * derivates) + * + * Provides built-in animation of Behavior on opacity Easing.OutQuad for a + * duration of 250. + * + * (TODO, make optional? e.g. animate: false) + */ Item { id: highlight + /** true if the user is hovering over the component */ //in the case we are the highlight of a listview, it follows the mouse, so hover = true property bool hover: ListView ? true : false + + /** true if the mouse button is pressed over the component. */ property bool pressed: false width: ListView.view ? ListView.view.width : undefined From ce2459b4ba207a9306d60a7a79b144da664cf6d3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Aur=C3=A9lien=20G=C3=A2teau?= Date: Mon, 17 Dec 2012 18:36:59 +0100 Subject: [PATCH 10/32] Doxygenize Label --- .../plasmacomponents/qml/Label.qml | 36 ++++++------------- 1 file changed, 10 insertions(+), 26 deletions(-) diff --git a/declarativeimports/plasmacomponents/qml/Label.qml b/declarativeimports/plasmacomponents/qml/Label.qml index d034394c1..e22fd5015 100644 --- a/declarativeimports/plasmacomponents/qml/Label.qml +++ b/declarativeimports/plasmacomponents/qml/Label.qml @@ -17,35 +17,19 @@ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ -/**Documented API -Inherits: - Text - -Imports: - QtQuick 1.1 - org.kde.plasma.core - -Description: - This is a label which uses the plasma theme. - The characteristics of the text will be automatically set - according to the plasma theme. If you need a more customized - text item use the Text component from QtQuick. - -Properties: - string text: - The most important property is "text". - For the other ones see the primitive QML Text element - -Methods: - See the primitive QML Text element - -Signals: - See the primitive QML Text element -**/ - import QtQuick 1.1 import org.kde.plasma.core 0.1 as PlasmaCore +/** + * This is a label which uses the plasma theme. + * + * The characteristics of the text will be automatically set according to the + * plasma theme. If you need a more customized text item use the Text component + * from QtQuick. + * + * You can use all elements of the QML Text component, in particular the "text" + * property to define the label text. + */ Text { id: root From cd453af5a8507047decfce8b3dd54b74860e6ef5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Aur=C3=A9lien=20G=C3=A2teau?= Date: Mon, 17 Dec 2012 18:41:57 +0100 Subject: [PATCH 11/32] Doxygenize ListItem --- .../plasmacomponents/qml/ListItem.qml | 68 ++++++++++--------- 1 file changed, 35 insertions(+), 33 deletions(-) diff --git a/declarativeimports/plasmacomponents/qml/ListItem.qml b/declarativeimports/plasmacomponents/qml/ListItem.qml index 0ea5ffdc5..425b62301 100644 --- a/declarativeimports/plasmacomponents/qml/ListItem.qml +++ b/declarativeimports/plasmacomponents/qml/ListItem.qml @@ -17,55 +17,57 @@ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ -/**Documented API -Inherits: - Item - -Imports: - org.kde.plasma.core - QtQuick 1.0 - -Description: - An item delegate for the primitive ListView component. It's intended to make all listview look coherent - -Properties: - * bool checked: - If true makes the list item look as checked or pressed. It has to be set from the code, it won't change by itself. - - * bool sectionDelegate: - If true the item will be a delegate for a section, so will look like a "title" for the otems under it. - - * bool enabled: - Holds if the item emits signals related to mouse interaction. - The default value is false. - -Signals: - * clicked(): - This handler is called when there is a click. - This is disabled by default, use enable property to activate it. - - * pressAndHold(): - The user pressed the item with the mouse and didn't release it for a certain amount of time. - This is disabled by default, use enable property to activate it. -**/ - import QtQuick 1.0 import org.kde.plasma.core 0.1 as PlasmaCore import "private/Config.js" as Config +/** + * An item delegate for the primitive ListView component. + * + * It's intended to make all listviews look coherent. + */ Item { id: listItem default property alias content: paddingItem.data - //this defines if the item will emit clicked and look pressed on mouse down + /** + * type:bool Holds if the item emits signals related to mouse interaction. + * + * The default value is false. + */ property alias enabled: itemMouse.enabled //item has been clicked or pressed+hold + + /** + * This signal is emitted when there is a click. + * + * This is disabled by default, set enabled to true to use it. + * @see enabled + */ signal clicked + + + /** + * The user pressed the item with the mouse and didn't release it for a + * certain amount of time. + * + * This is disabled by default, set enabled to true to use it. + * @see enabled + */ signal pressAndHold + /** + * If true makes the list item look as checked or pressed. It has to be set + * from the code, it won't change by itself. + */ //plasma extension //always look pressed? property bool checked: false + + /** + * If true the item will be a delegate for a section, so will look like a + * "title" for the otems under it. + */ //is this to be used as section delegate? property bool sectionDelegate: false From 4cf125f4a4816ad22ae59531424f7e4aefe83fdc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Aur=C3=A9lien=20G=C3=A2teau?= Date: Mon, 17 Dec 2012 18:47:45 +0100 Subject: [PATCH 12/32] Doxygenize Page --- .../plasmacomponents/qml/Page.qml | 69 +++++++++---------- 1 file changed, 32 insertions(+), 37 deletions(-) diff --git a/declarativeimports/plasmacomponents/qml/Page.qml b/declarativeimports/plasmacomponents/qml/Page.qml index 1bed9461b..3266b43bc 100644 --- a/declarativeimports/plasmacomponents/qml/Page.qml +++ b/declarativeimports/plasmacomponents/qml/Page.qml @@ -38,56 +38,51 @@ ** ****************************************************************************/ -/**Documented API -Inherits: - Item - -Imports: - QtQuick 1.1 - everything in the same dir which are version 0.1 - -Description: - Defines the content of a piece of the user interface, it's meant to be loaded by a PageStack or TabGroup element. - The typical use can be in small plasmoids or mobile devices where the whole screen is a series of interchangeable and flickable pages, of which the user navigates across. - - -Properties: - * int status: - The current status of the page. It can be one of the following values: - PageStatus.Inactive (default) - the page is not visible. - PageStatus.Activating - the page is becoming to the active page. - PageStatus.Active - the page is the currently active page. - PageStatus.Deactivating - the page is becoming to inactive page. - - * PageStack pageStack: - The page stack that this page is owned by. - - * int orientationLock: - Sets the orientation for the Page - - * Item tools: - Defines the toolbar contents for the page. If the page stack is set up using a toolbar instance, it automatically shows the currently active page's toolbar contents in the toolbar. The default value is null resulting in the page's toolbar to be invisible when the page is active. -**/ - import QtQuick 1.1 import "." 0.1 +/** + * Defines the content of a piece of the user interface, it's meant to be + * loaded by a PageStack or TabGroup element. The typical use can be in small + * plasmoids or mobile devices where the whole screen is a series of + * interchangeable and flickable pages, of which the user navigates across. + */ Item { id: root - // The status of the page. One of the following: - // PageStatus.Inactive - the page is not visible - // PageStatus.Activating - the page is transitioning into becoming the active page - // PageStatus.Active - the page is the current active page - // PageStatus.Deactivating - the page is transitioning into becoming inactive + /** + * type:PageStatus::Status + * The status of the page + * + * One of the following: + * + * - PageStatus.Inactive: the page is not visible + * - PageStatus.Activating: the page is transitioning into becoming the active page + * - PageStatus.Active: the page is the current active page + * - PageStatus.Deactivating: the page is transitioning into becoming inactive + */ property int status: PageStatus.Inactive + /** + * type:PageStack + * The page stack that this page is owned by. + */ property Item pageStack - // Defines orientation lock for a page + /** + * Sets the orientation for the Page + */ property int orientationLock: PageOrientation.Automatic + /** + * Defines the toolbar contents for the page. If the page stack is set up + * using a toolbar instance, it automatically shows the currently active + * page's toolbar contents in the toolbar. + * + * The default value is null resulting in the page's toolbar to be + * invisible when the page is active. + */ property Item tools: null visible: false From 2f9faa8f4ae3a9943bcbbcd122828dd30ba4e498 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Aur=C3=A9lien=20G=C3=A2teau?= Date: Mon, 17 Dec 2012 19:05:25 +0100 Subject: [PATCH 13/32] Doxygenize PageStack --- .../plasmacomponents/qml/PageStack.qml | 176 +++++++++--------- 1 file changed, 88 insertions(+), 88 deletions(-) diff --git a/declarativeimports/plasmacomponents/qml/PageStack.qml b/declarativeimports/plasmacomponents/qml/PageStack.qml index 6be6e31be..3d5b04150 100644 --- a/declarativeimports/plasmacomponents/qml/PageStack.qml +++ b/declarativeimports/plasmacomponents/qml/PageStack.qml @@ -43,131 +43,131 @@ // The PageStack item defines a container for pages and a stack-based // navigation model. Pages can be defined as QML items or components. -/**Documented API -Inherits: - Item - -Imports: - QtQuick 1.1 - . - PageStack.js - -Description: - The PageStack component provides a stack-based navigation model that you can use in your application. A stack-based navigation model means that a page of content for your application is pushed onto a stack when the user navigates deeper into the application page hierarchy. The user can then go back to the previous page (or several pages back) by popping a page (or several pages) off the top of the stack. - -Properties: - * int depth: - The number of pages on the page stack. - - * Item currentPage: - The page in the stack that is currently visible. - - * ToolBar toolBar: - The toolbar container for the tools associated with each page. If a toolbar is specified, the tools set for the current page is shown to the user. - If toolbar is null, then no tools are shown even if a page does have tools. - - * variant initialPage: - The page to be automatically loaded when this PageStack component gets instantiated. - - * bool busy: - Indicates whether there is an ongoing page transition. - -Methods: - * clear(): - Clears the page stack of all pages. - - * find(function): - This iterates, top to bottom, through all the pages in the page stack and passes each page to the given function. If the specified function returns true, the iterating stops and this function returns the page that produced the true result. If no matching page is found in the page stack, null is returned. - - * pop(page, immediate): - When you use pop() with no arguments, it pops the top page off the stack and returns that page to the caller. The normal pop transition animation is performed. If the page popped off the stack is based on the Item element, the page is re-parented back to its original parent. - If the page didn't have an original parent (ie, was created with push(Qt.createComponent("foo.qml")) the page instance will be deleted. - If you give a page argument, the stack is unwound to the given page. Any Item-based pages popped off the stack are re-parented to their original parent. - If the given page is not found in the stack, the stack is unwound to the first page in the stack. However, if you specifically want to unwind the page stack to the first page in the stack, it is best to be explicit about what you are doing and use pop(null) rather than guessing a page that is not on the stack. - The immediate argument defaults to false which means the normal transition animation is performed when a page is popped. If you do not want the transition animation to be performed pass a value of true for immediate. - Note: A pop() on a stack with that contains 0 or 1 pages is a no-operation. - Returns: The page that was top-most on the stack before the pop operation. - - * push(page, properties, immediate): - Pushes the given page onto the page stack. You can use a component, item or string for the page. If the page is based on the Item element, the page is re-parented. If a string is used then it is interpreted as a URL that is used to load a page component. The push operation results in the appropriate transition animation being run. If you are pushing an array of pages, the transition animation is only shown for the last page. - Returns: The new top page on the stack. - The page argument can also be an array of pages. In this case, all the pages in the array are pushed onto the stack. The items in the array can be components, items or strings just like for pushing a single page. - The page argument can also be an object that specifies a page with properties or even an array of pages with properties. - The properties argument is optional and allows you to specify values for properties in the page being pushed. - The immediate argument defaults to false which means the normal transition animation is performed when a page is pushed. If you do not want the transition animation to be performed pass a value of true for immediate. - Note: When the stack is empty, a push() or replace() does not perform a transition animation because there is no page to transition from. The only time this normally happens is when an application is starting up so it is not appropriate to have a transition animation anyway. - See also Page. - - * replace(page, properties, immediate): - Replaces the top-most page on the stack with page. As in the push() operation, you can use a component, item or string for the page, or even an array of pages. If the page is based on the Item element, the page is re- parented. As in the pop() operation, the replaced page on the stack is re- parented back to its original parent. - Returns: The new top page on the stack. - See also push(). - -**/ - import QtQuick 1.1 import "." 0.1 import "private/PageStack.js" as Engine +/** + * The PageStack component provides a stack-based navigation model that you can + * use in your application. A stack-based navigation model means that a page of + * content for your application is pushed onto a stack when the user navigates + * deeper into the application page hierarchy. The user can then go back to the + * previous page (or several pages back) by popping a page (or several pages) + * off the top of the stack. + */ Item { id: root width: parent ? parent.width : 0 height: parent ? parent.height : 0 + /** The number of pages on the page stack. */ property int depth: Engine.getDepth() + + /** The page in the stack that is currently visible. */ property Item currentPage: null + + /** + * The toolbar container for the tools associated with each page. + * + * If a toolbar is specified, the tools set for the current page is shown + * to the user. + * + * If toolbar is null, then no tools are shown even if a page does have + * tools. + */ property ToolBar toolBar + + /** + * The page to be automatically loaded when this PageStack component gets + * instantiated. + */ property variant initialPage - // Indicates whether there is an ongoing page transition. + /** Indicates whether there is an ongoing page transition. */ property bool busy: internal.ongoingTransitionCount > 0 - // Pushes a page on the stack. - // The page can be defined as a component, item or string. - // If an item is used then the page will get re-parented. - // If a string is used then it is interpreted as a url that is used to load a page component. - // - // The page can also be given as an array of pages. In this case all those pages will be pushed - // onto the stack. The items in the stack can be components, items or strings just like for single - // pages. Additionally an object can be used, which specifies a page and an optional properties - // property. This can be used to push multiple pages while still giving each of them properties. - // When an array is used the transition animation will only be to the last page. - // - // The properties argument is optional and allows defining a map of properties to set on the page. - // If the immediate argument is true then no transition animation is performed. - // Returns the page instance. + /** + * Pushes a page on the stack. + * + * The page can be defined as a component, item or string. If an item is + * used then the page will get re-parented. If a string is used then it is + * interpreted as a url that is used to load a page component. + * + * The page can also be given as an array of pages. In this case all those + * pages will be pushed onto the stack. The items in the stack can be + * components, items or strings just like for single pages. Additionally an + * object can be used, which specifies a page and an optional properties + * property. This can be used to push multiple pages while still giving + * each of them properties. When an array is used the transition animation + * will only be to the last page. + * + * Note: When the stack is empty, a push() or replace() does not perform a + * transition animation because there is no page to transition from. The + * only time this normally happens is when an application is starting up so + * it is not appropriate to have a transition animation anyway. + * + * @param type:variant page the page to push + * @param type:dict properties optional argument to define a map of + * properties to set on the page. + * @param type:bool immediate set to true to disable transition animations + * + * @return type:Page the page instance. + */ function push(page, properties, immediate) { return Engine.push(page, properties, false, immediate); } - // Pops a page off the stack. - // If page is specified then the stack is unwound to that page, to unwind to the first page specify - // page as null. If the immediate argument is true then no transition animation is performed. - // Returns the page instance that was popped off the stack. + /** + * Pops a page off the stack. + * + * @param type:Page page if page is specified then the stack is unwound to that + * page, to unwind to the first page specify page as null. + * @param type:bool immediate set to true to disable transition animations + * + * @return type:Page the page instance that was popped off the stack. + */ function pop(page, immediate) { return Engine.pop(page, immediate); } - // Replaces a page on the stack. - // See push() for details. + /** + * Replaces the top-most page on the stack with page. + * + * As in the push() operation, you can use a component, item or string for + * the page, or even an array of pages. If the page is based on the Item + * element, the page is re-parented. As in the pop() operation, the + * replaced page on the stack is re-parented back to its original parent. + * + * @param type:variant page the page to push + * @param type:dict properties optional argument to define a map of + * properties to set on the page. + * @param type:bool immediate set to true to disable transition animations + * + * @return type:Page The new top page on the stack. + */ function replace(page, properties, immediate) { return Engine.push(page, properties, true, immediate); } - // Clears the page stack. + /** Clears the page stack of all pages. */ function clear() { return Engine.clear(); } - // Iterates through all pages (top to bottom) and invokes the specified function. - // If the specified function returns true the search stops and the find function - // returns the page that the iteration stopped at. If the search doesn't result - // in any page being found then null is returned. + /** + * Iterates through all pages (top to bottom) and invokes the specified function. + * If the specified function returns true the search stops and the find function + * returns the page that the iteration stopped at. If the search doesn't result + * in any page being found then null is returned. + * + * @param type:function func the function to call + * @return type:Page the found page or null + */ function find(func) { return Engine.find(func); From 3ede948f58eb762db3cf8af7bdec921a4ef9a09f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Aur=C3=A9lien=20G=C3=A2teau?= Date: Mon, 17 Dec 2012 21:39:55 +0100 Subject: [PATCH 14/32] Doxygenize ProgressBar --- .../plasmacomponents/qml/ProgressBar.qml | 63 +++++++++---------- 1 file changed, 28 insertions(+), 35 deletions(-) diff --git a/declarativeimports/plasmacomponents/qml/ProgressBar.qml b/declarativeimports/plasmacomponents/qml/ProgressBar.qml index 9f65b1605..c3877cd4d 100644 --- a/declarativeimports/plasmacomponents/qml/ProgressBar.qml +++ b/declarativeimports/plasmacomponents/qml/ProgressBar.qml @@ -17,54 +17,47 @@ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ -/**Documented API - Inherits: - Item - -Imports: - QtQuick 1.0 - org.kde.plasma.core - -Description: - It is a simple progressBar which is using the plasma theme. - Some operations take a period of time to be performed and the user needs a confirmation that the operation is still ongoing. If the user does not get any confirmation, they might suspect that they did something wrong or that the device has broken. A progress bar is one of available mechanisms for providing this reassurance to the user. - -Properties: - * real minimumValue: - Minimum Value for the progressBar - - * real maximumValue: - Maximum value for the progressBar - - real value: - Current value of the progressBar - - * bool indeterminate: - Indicates whether the operation's duration is known or not. The property can have the following values: - true - the operation's duration is unknown, so the progress bar is animated. The value, minimum, and maximum properties are ignored. - false - the operation's duration is known, so the progress bar is drawn to indicate progress between the minimum and maximum values. - The default value is false. - - * int orientation: - Orientation of the progressBar: - Qt.Horizontal or - Qt.Vertical -**/ - import QtQuick 1.0 import org.kde.plasma.core 0.1 as PlasmaCore import org.kde.qtextracomponents 0.1 +/** + * Simple progressBar using the plasma theme. + * + * Some operations take a period of time to be performed and the user needs a + * confirmation that the operation is still ongoing. If the user does not get + * any confirmation, they might suspect that they did something wrong or that + * the device has broken. A progress bar is one of the available mechanisms for + * providing this reassurance to the user. + */ Item { id: progressBar // Common API + /** type:real Minimum value for the progressBar */ property alias minimumValue: range.minimumValue + /** type:real Maximum value for the progressBar */ property alias maximumValue: range.maximumValue + /** type:real Current value of the progressBar */ property alias value: range.value + /** + * type:bool + * Indicates whether the operation's duration is known or not. The property + * can have the following values: + * + * - true: the operation's duration is unknown, so the progress bar is + * animated. The value, minimum, and maximum properties are ignored. + * - false: the operation's duration is known, so the progress bar is drawn + * to indicate progress between the minimum and maximum values. + * + * The default value is false. + */ property alias indeterminate: indeterminateAnimation.running // Plasma API + /** + * Orientation of the progressBar: Qt.Horizontal or Qt.Vertical + */ property int orientation: Qt.Horizontal width: 100 @@ -179,4 +172,4 @@ Item { } } } -} \ No newline at end of file +} From 8091f5591b87ceaf4133f2f7633ddc10159156d5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Aur=C3=A9lien=20G=C3=A2teau?= Date: Mon, 17 Dec 2012 22:02:29 +0100 Subject: [PATCH 15/32] Doxygenize RadioButton --- .../plasmacomponents/qml/RadioButton.qml | 38 +++++-------------- 1 file changed, 10 insertions(+), 28 deletions(-) diff --git a/declarativeimports/plasmacomponents/qml/RadioButton.qml b/declarativeimports/plasmacomponents/qml/RadioButton.qml index d9e77ae74..dd1247372 100644 --- a/declarativeimports/plasmacomponents/qml/RadioButton.qml +++ b/declarativeimports/plasmacomponents/qml/RadioButton.qml @@ -17,37 +17,19 @@ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ -/**Documented API -Inherits: - The private DualStateButton - -Imports: - QtQuick 1.0 - org.kde.plasma.core - -Description: - A radio button component consists of a radio button and a line of text. Only one item in a list may be selected at a time. Once an item is selected, it can be deselected only by selecting another item. Initial item selection may be set at the list creation. If not set, the list is shown without a selection. - -Properties: - bool checked: - If the button is checked, its checked property is true; otherwise false. The property is false by default. - - bool pressed: - If the button is pressed, its pressed property is true. - See also clicked. - - string text: - The text is shown beside the check box. By default text is an empty string. - -Signals: - clicked(): - Emitted when the user clicked a mouse button over the checkbox (or tapped on the touch screen) -**/ - import QtQuick 1.0 import org.kde.plasma.core 0.1 as PlasmaCore import "private" as Private +/** + * A radio button component consists of a radio button and a line of text. Only + * one item in a list may be selected at a time. Once an item is selected, it + * can be deselected only by selecting another item. Initial item selection may + * be set at the list creation. If not set, the list is shown without a + * selection. + * + * All elements of this component are defined in DualStateButton, its base component. + */ //FIXME: this should be round, DualStateButton shouldn't draw the shadow Private.DualStateButton { id: radioButton @@ -80,4 +62,4 @@ Private.DualStateButton { } shadow: Private.RoundShadow {} -} \ No newline at end of file +} From d20924b1dae04592d839381b8a89ae65a3569e38 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Aur=C3=A9lien=20G=C3=A2teau?= Date: Mon, 17 Dec 2012 22:02:40 +0100 Subject: [PATCH 16/32] Doxygenize ScrollBar --- .../plasmacomponents/qml/ScrollBar.qml | 112 ++++++++---------- 1 file changed, 47 insertions(+), 65 deletions(-) diff --git a/declarativeimports/plasmacomponents/qml/ScrollBar.qml b/declarativeimports/plasmacomponents/qml/ScrollBar.qml index ed0616fc1..11ebc6879 100644 --- a/declarativeimports/plasmacomponents/qml/ScrollBar.qml +++ b/declarativeimports/plasmacomponents/qml/ScrollBar.qml @@ -18,90 +18,72 @@ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ -/**Documented API -Inherits: - Item - -Imports: - org.kde.plasma.core - QtQuick 1.1 - -Description: - Just a simple Scroll Bar which is using the plasma theme. - This component does not belong to the QtComponents API specification - but it was base on ScrollDecorator component. - You should not use it for touch interfaces, use a flickable and a - ScrollDecorator instead. - By default, this component will look and behave like a scroll decorator - on touchscreens - -Properties: - - enumeration orientation: - This property holds the orientation where the ScrollBar will scroll. - The orientation can be either Qt.Horizontal or Qt.Vertical - The default value is Qt.Vertical. - - bool inverted: - This property holds if the ScrollBar will increase the Flickable - content in the normal direction (Left to Right or Top to Bottom) or - if this will be inverted. - The default value is false. - - bool updateValueWhileDragging: - This property holds if the Scrollbar will update the Flickeble - position while dragging or only when released. - The default value is true. - - real stepSize: - This property holds how many steps exists while moving the handler. - If you want the ScrollBar buttons to appear you must set this property - with a value bigger than 0. - The default value is 0. - - bool pressed: - This property holds if the ScrollBar is pressed. - - real scrollButtonInterval: - This property holds the interval time used by the ScrollBar button - to increase or decrease steps. - - Flickable flickableItem: - This property holds the Flickable component which the ScrollBar will - interact with. - - bool interactive: - This property holds if the ScrollBar is interactive. - The default value is true. - - bool enabeld: - This property holds if the button will be enabled for user - interaction. - The default value is true. -**/ - import QtQuick 1.1 import org.kde.plasma.core 0.1 as PlasmaCore import "private" as Private /** - * A generic ScrollBar/ScrollDecorator component: - * Always prefer this to ScrollDecorator that is not available on desktop. - * By default, this component will look and behave like a scroll decorator on touchscreens + * A simple Scroll Bar using the plasma theme. + * + * This component does not belong to the QtComponents API specification but it + * was based on the ScrollDecorator component. You should not use it for touch + * interfaces, use a flickable and a ScrollDecorator instead. + * + * By default, this component looks and behaves like a scroll decorator + * on touchscreens. */ // TODO: add support mouse wheel events Item { id: scrollbar // Common API + /** + * The Flickable component which the ScrollBar will interact with. + */ property Flickable flickableItem: null + /** + * The orientation where the ScrollBar will scroll. + * The orientation * can be either Qt.Horizontal or Qt.Vertical. + * + * The default value is Qt.Vertical. + */ property int orientation: Qt.Vertical + + /** + * Whether the ScrollBar is interactive. + * + * The default value is true. + */ property bool interactive: true // Plasma API + /** + * Whether the ScrollBar will increase the Flickable content in the normal + * direction (Left to Right or Top to Bottom) or if this will be inverted. + * + * The default value is false. + */ property bool inverted: false + + /** + * type:bool + * How many steps exist while moving the handler. If you want the + * ScrollBar buttons to appear you must set this property to a value + * bigger than 0. + * + * The default value is 0. + */ property alias stepSize: range.stepSize + + /** + * Indicates if the ScrollBar is pressed. + */ property bool pressed: internalLoader.item.mouseArea?internalLoader.item.mouseArea.pressed:false + + /** + * The interval time used by the ScrollBar button to increase or decrease + * steps. + */ property real scrollButtonInterval: 50 implicitWidth: internalLoader.isVertical ? (internalLoader.item ? internalLoader.item.implicitWidth : 12) : 200 From 5fb8c46cd55f7e88a916b02dbaf872cc1e25dc03 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Aur=C3=A9lien=20G=C3=A2teau?= Date: Mon, 17 Dec 2012 22:02:53 +0100 Subject: [PATCH 17/32] Doxygenize SectionScroller --- .../plasmacomponents/qml/SectionScroller.qml | 37 +++++++------------ 1 file changed, 14 insertions(+), 23 deletions(-) diff --git a/declarativeimports/plasmacomponents/qml/SectionScroller.qml b/declarativeimports/plasmacomponents/qml/SectionScroller.qml index be459d8c8..507216d50 100644 --- a/declarativeimports/plasmacomponents/qml/SectionScroller.qml +++ b/declarativeimports/plasmacomponents/qml/SectionScroller.qml @@ -37,37 +37,28 @@ ** $QT_END_LICENSE$ ** ****************************************************************************/ -/**Documented API -Inherits: - Item - -Imports: - QtQuick 1.1 - org.kde.plasma.core - -Description: - It's similar to a ScrollBar or a ScrollDecorator. - It's interactive and works on ListViews that have section.property set, - so its contents are categorized. - An indicator will say to what category the user scrolled to. - Useful for things like address books or things sorted by date. - Don't use with models too big (thousands of items) because implies - loading all the items to memory, as well loses precision. - -Properties: - ListView listView: - As The ScrollBar, this is the listview the sectionScroller will operate on. This component doesn't work with simple Flickable or GridView. -**/ import QtQuick 1.1 import "private/SectionScroller.js" as Sections import org.kde.plasma.core 0.1 as PlasmaCore +/** + * Similar to a ScrollBar or a ScrollDecorator. + * + * It's interactive and works on ListViews that have section.property set, so + * its contents are categorized. + * + * An indicator will say to what category the user scrolled to. Useful for + * things like address books or things sorted by date. Don't use with models + * too big (thousands of items) because it implies loading all the items to + * memory, as well loses precision. + */ Item { id: root - /* - * The listview this scroll indicator will work on + /** + * The listview the sectionScroller will operate on. This component doesn't + * work with Flickable or GridView. */ property ListView listView From bd9ec5fa67645f55b4b451203744884c4162eac9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Aur=C3=A9lien=20G=C3=A2teau?= Date: Mon, 17 Dec 2012 22:03:08 +0100 Subject: [PATCH 18/32] Doxygenize SelectionDialog --- .../plasmacomponents/qml/SelectionDialog.qml | 51 ++++++++----------- 1 file changed, 22 insertions(+), 29 deletions(-) diff --git a/declarativeimports/plasmacomponents/qml/SelectionDialog.qml b/declarativeimports/plasmacomponents/qml/SelectionDialog.qml index 34c1e8d86..0fc21c4e9 100644 --- a/declarativeimports/plasmacomponents/qml/SelectionDialog.qml +++ b/declarativeimports/plasmacomponents/qml/SelectionDialog.qml @@ -40,46 +40,39 @@ ** ****************************************************************************/ -/**Documentanted API -Inherits: - CommonDialog - -Imports: - org.kde.plasma.core - QtQuick 1.1 - "." 0.1 - -Description: - This is plasma themed SelectionDialog, with which you can customize the visual representation - of the selectable items' list by overriding the ListView delegate. - By default SelectionDialog provides a scrollable list of textual menu items. - The user can choose one item from the list at a time. - -Properties: - QtObject: listView.model: - The model of selectionDialog. - Can be a simple model or a custom QAbstractItemModel - - int selectedIndex: -1 - It returns the index that the user has selected. - The default value is -1. - - Component delegate: - This is a common delegate with which,you will choose - how your items will be displayed. -**/ - import QtQuick 1.1 import org.kde.plasma.core 0.1 as PlasmaCore import "." 0.1 +/** + * A plasma themed SelectionDialog, which can be customized by overriding the + * ListView delegate. + * + * By default SelectionDialog provides a scrollable list of textual menu items. + * The user can choose one item from the list at a time. + */ CommonDialog { id: root // Common API + /** + * type:QtObject + * The model of selectionDialog. Can be a simple model or a custom + * QAbstractItemModel + */ property alias model: listView.model + + /** + * Selected index. + * + * The default value is -1. + */ property int selectedIndex: -1 + + /** + * The delegate used to render the items. + */ property Component delegate: defaultDelegate Component { From ade2f1cfc0b06791a202ec458508a76ddc63c5f4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Aur=C3=A9lien=20G=C3=A2teau?= Date: Mon, 17 Dec 2012 22:03:29 +0100 Subject: [PATCH 19/32] Doxygenize Sheet --- .../plasmacomponents/qml/Sheet.qml | 148 +++++++++--------- 1 file changed, 77 insertions(+), 71 deletions(-) diff --git a/declarativeimports/plasmacomponents/qml/Sheet.qml b/declarativeimports/plasmacomponents/qml/Sheet.qml index b29027bb7..f13705aac 100644 --- a/declarativeimports/plasmacomponents/qml/Sheet.qml +++ b/declarativeimports/plasmacomponents/qml/Sheet.qml @@ -40,101 +40,92 @@ ** ****************************************************************************/ -/**Documented API -Inherits: - Item - -Imports: - QtQuick 1.0 - org.kde.plasma.core - -Description: - Provides a top-level window for short-term tasks and brief interaction with the user. - Is intended to be for interaction more complex and bigger in size then Dialog. On the desktop its looks is almost identical to Dialog, on touch interfaces is an almost fullscreen sliding Sheet. It is provided mostly for compatibility with mobile implementations - -Properties: - list content: - A list of items in the dialog's content area. You can use any component that is based on Item. For example, you can use ListView, so that the user can select from a list of names. - - int status: - Indicates the dialog's phase in its life cycle. The values are as follows: - - DialogStatus.Opening - the dialog is opening - - DialogStatus.Open - the dialog is open and visible to the user - - DialogStatus.Closing - the dialog is closing - - DialogStatus.Closed - the dialog is closed and not visible to the user - The dialog's initial status is DialogStatus.Closed. - - string title: - The title text of this Sheet. - - Item acceptButton: - button that when pressed will close the dialog, representing the user accepting it, accepted() will be called - - Item rejectButton: - button that when pressed will close the dialog, representing the user rejecting it, rejected() will be called - - string acceptButtonText: - Text of the accept button - - string rejectButtonText: - Text of the reject button - - Item visualParent: - The item that is dimmed when the dialog opens. By default the root parent object is visualParent. - -Signals: - accepted(): - This signal is emitted when the user accepts the dialog's request or the accept() method is called. - See also rejected(). - - clickedOutside(): This signal is emitted when the user taps in the area that is inside the dialog's visual parent area but outside the dialog's area. Normally the visual parent is the root object. In that case this signal is emitted if the user taps anywhere outside the dialog's area. - See also visualParent. - - rejected(): - This signal is emitted when the user rejects the dialog's request or the reject() method is called. - See also accepted(). - -Methods: - void accept(): - Accepts the dialog's request without any user interaction. The method emits the accepted() signal and closes the dialog. - See also reject(). - - void close(): - Closes the dialog without any user interaction. - - void open(): - Shows the dialog to the user. - - void reject(): - Rejects the dialog's request without any user interaction. The method emits the rejected() signal and closes the dialog. - See also accept(). -**/ - import QtQuick 1.0 import org.kde.plasma.core 0.1 as PlasmaCore import "private/AppManager.js" as Utils import "." 0.1 +/** + * Provides a top-level window for short-term tasks and brief interaction with + * the user. + * + * It is intended to be used for interaction more complex and bigger in size + * than Dialog. On the desktop its looks is almost identical to Dialog, on + * touch interfaces it is an almost fullscreen sliding Sheet. It is provided + * mostly for compatibility with mobile implementations. + */ Item { id: root + /** + * type:string + * The title text of this Sheet. + */ property alias title: titleLabel.text + + /** + * type:list + * A list of items in the dialog's content area. You can use any component + * that is based on Item. For example, you can use ListView, so that the + * user can select from a list of names. + */ property alias content: contentItem.children // property alias visualParent: dialog.visualParent + + /** + * Indicates the dialog's phase in its life cycle. The values are as follows: + * + * - DialogStatus.Opening - the dialog is opening + * - DialogStatus.Open - the dialog is open and visible to the user + * - DialogStatus.Closing - the dialog is closing + * - DialogStatus.Closed - the dialog is closed and not visible to the user + * + * The dialog's initial status is DialogStatus.Closed. + */ property int status: DialogStatus.Closed property alias acceptButtonText: acceptButton.text property alias rejectButtonText: rejectButton.text + /** + * type:Button + * button that when pressed will close the dialog, representing the user + * accepting it, accepted() will be called + */ property alias acceptButton: acceptButton - property alias rejectButton: rejectButton + /** + * type:Button + * button that when pressed will close the dialog, representing the user rejecting it, rejected() will be called + */ + property alias rejectButton: rejectButton property alias privateTitleHeight: titleBar.height property alias privateButtonsHeight: buttonsRow.height + /** + * Emitted when the user accepts the dialog's request or the accept() + * method is called. + */ signal accepted + + /** + * Emitted when the user rejects the dialog's request or the reject() + * method is called. + * + * @see accepted() + */ signal rejected + + /** + * Emitted when the user taps in the area that is inside the dialog's + * visual parent area but outside the dialog's area. Normally the visual + * parent is the root object. In that case this signal is emitted if the + * user taps anywhere outside the dialog's area. + */ signal clickedOutside + /** + * Shows the dialog to the user. + */ function open() { var pos = dialog.popupPosition(null, Qt.AlignCenter) @@ -145,6 +136,12 @@ Item { dialog.activateWindow() } + /** + * Accepts the dialog's request without any user interaction. The method + * emits the accepted() signal and closes the dialog. + * + * @see reject() + */ function accept() { if (status == DialogStatus.Open) { @@ -153,6 +150,12 @@ Item { } } + /** + * Rejects the dialog's request without any user interaction. The method + * emits the rejected() signal and closes the dialog. + * + * @see accept() + */ function reject() { if (status == DialogStatus.Open) { dialog.visible = false @@ -160,6 +163,9 @@ Item { } } + /** + * Closes the dialog without any user interaction. + */ function close() { dialog.visible = false } From d37d8096ea80529d606d2806a06381a4861b8bf4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Aur=C3=A9lien=20G=C3=A2teau?= Date: Mon, 17 Dec 2012 22:16:05 +0100 Subject: [PATCH 20/32] Doxygenize Slider --- .../plasmacomponents/qml/Slider.qml | 119 ++++++++++-------- 1 file changed, 65 insertions(+), 54 deletions(-) diff --git a/declarativeimports/plasmacomponents/qml/Slider.qml b/declarativeimports/plasmacomponents/qml/Slider.qml index 730096ebf..3190d212b 100644 --- a/declarativeimports/plasmacomponents/qml/Slider.qml +++ b/declarativeimports/plasmacomponents/qml/Slider.qml @@ -17,79 +17,90 @@ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ -/**Documented API -Inherits: - Item - -Imports: - QtQuick 1.0 - org.kde.plasma.core - -Description: - An interactive slider component with Plasma look and feel. - -Properties: - int stepSize: range.stepSize - This property holds in how many steps the slider value can be selected within it's - range value. - - real minimumValue: - This property holds the minimum value that the slider's value can assume. - The default value is 0. - - real maximumValue: - This property holds the maximum value that the slider's value can assume. - The default value is 1. - - real value: - This property holds the value selected inside the minimum to maximum range of value. - The default value is 0. - - enumeration orientation: - This property holds the orientation for this component. - The orientation can assume Qt.Horizontal and Qt.Vertical values. - The default is Qt.Horizontal. - - bool pressed: - This property holds if the Slider is being pressed or not. - Read-only. - - bool valueIndicatorVisible: - This property holds if a value indicator element will be shown while is dragged or not. - ! The value indicator is not implemented in the Plasma Slider. - The default value is false. - - string valueIndicatorText: - This property holds the text being displayed in the value indicator. - ! The value indicator is not implemented in the Plasma Slider. - Read-only. - -Plasma Properties: - - alias inverted: - This property holds if the slider visualizations has an inverted direction. - The default value is false. -**/ - import QtQuick 1.0 import org.kde.plasma.core 0.1 as PlasmaCore import "private" as Private // TODO: create a value indicator for plasma? +/** + * An interactive slider component with Plasma look and feel. + */ Item { id: slider // Common API + /** + * type:real + * How many steps the slider value can be selected within its range value. + */ property alias stepSize: range.stepSize + + /** + * type:real + * Minimum value that the slider's value can assume. + * + * The default value is 0. + */ property alias minimumValue: range.minimumValue + + /** + * type:real + * Maximum value that the slider's value can assume. + * + * The default value is 1. + */ property alias maximumValue: range.maximumValue + + /** + * type:real + * This property holds the value selected inside the minimum to maximum + * range of value. + * + * The default value is 0. + */ property alias value: range.value + + /** + * Orientation for this component. + * + * The orientation can be either Qt.Horizontal or Qt.Vertical. + * + * The default is Qt.Horizontal. + */ property int orientation: Qt.Horizontal + + /** + * type:bool + * + * True if the Slider is being pressed. + */ property alias pressed: mouseArea.pressed + + /** + * This property holds if a value indicator element will be shown while is + * dragged or not. + * + * @warning The value indicator is not implemented in the Plasma Slider. + * + * The default value is false. + */ property bool valueIndicatorVisible: false + + /** + * This property holds the text being displayed in the value indicator. + * + * @warning The value indicator is not implemented in the Plasma Slider. + */ property string valueIndicatorText: value // Plasma API + /** + * type:bool + * This property holds if the slider visualizations has an inverted + * direction. + * + * The default value is false. + */ property alias inverted: range.inverted width: contents.isVertical ? theme.defaultFont.mSize.height*1.6 : 200 From b05fd20f0a4d952963aece8fce154c8ddd7e1015 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Aur=C3=A9lien=20G=C3=A2teau?= Date: Mon, 17 Dec 2012 22:16:19 +0100 Subject: [PATCH 21/32] Doxygenize Switch --- .../plasmacomponents/qml/Switch.qml | 44 +++++-------------- 1 file changed, 11 insertions(+), 33 deletions(-) diff --git a/declarativeimports/plasmacomponents/qml/Switch.qml b/declarativeimports/plasmacomponents/qml/Switch.qml index 27a512369..999359730 100644 --- a/declarativeimports/plasmacomponents/qml/Switch.qml +++ b/declarativeimports/plasmacomponents/qml/Switch.qml @@ -17,43 +17,21 @@ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ -/**Documented API -Inherits: - DualStateButton - -Imports: - QtQuick 1.0 - org.kde.plasma.core - -Description: - A boolean toggle button with the visual representation of a "realistic" switch - with a movable toggle showing the state of the Switch. Generally easier to use - on touch devices than a CheckBox due to the larger surface space and more evident - state visualization. - - You can bind the Switch component, for example, to a feature that the application - has to enable or disable depending on the user's input. - -Properties: - bool checked: - Returns true if the Button is checked, otherwise - it returns false. - - bool pressed: - Returns true if the Button is pressed, otherwise - it returns false. - - string text: - Sets the text for the switch. The default value is empty. - -Signals: - onClicked: - The signal is emited when the button is clicked! -**/ import QtQuick 1.0 import org.kde.plasma.core 0.1 as PlasmaCore import "private" as Private +/** + * A boolean toggle button with the visual representation of a "realistic" + * switch with a movable toggle showing the state of the Switch. Generally + * easier to use on touch devices than a CheckBox due to the larger surface + * space and more evident state visualization. + * + * You can bind the Switch component, for example, to a feature that the + * application has to enable or disable depending on the user's input. + * + * All elements of this component are defined in DualStateButton, its base component. + */ Private.DualStateButton { id: switchItem From 342ca686d315b9f168e513b0bb58e704539e8629 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Aur=C3=A9lien=20G=C3=A2teau?= Date: Mon, 17 Dec 2012 22:50:33 +0100 Subject: [PATCH 22/32] Doxygenize Tab* components --- .../plasmacomponents/qml/TabBar.qml | 40 +++++------- .../plasmacomponents/qml/TabButton.qml | 63 +++++++++---------- .../plasmacomponents/qml/TabGroup.qml | 43 +++++++------ 3 files changed, 69 insertions(+), 77 deletions(-) diff --git a/declarativeimports/plasmacomponents/qml/TabBar.qml b/declarativeimports/plasmacomponents/qml/TabBar.qml index 3ff54f40e..f7287bf60 100644 --- a/declarativeimports/plasmacomponents/qml/TabBar.qml +++ b/declarativeimports/plasmacomponents/qml/TabBar.qml @@ -40,40 +40,32 @@ ** ****************************************************************************/ -/**Documented API -Inherits: - DualStateButton - -Imports: - QtQuick 1.1 - org.kde.plasma.core - -Description: - TabBar is a plasma themed component that you can - use as a container for the tab buttons. - -Properties: - Item currentTab: - Returns the current tabbar button. - - default alias content: - This property represends the the content of - the TabBarLayout. - - Item tabBarLayout: - This is an alias for the layout of the tabbar. -**/ - import QtQuick 1.1 import org.kde.plasma.core 0.1 as PlasmaCore import "private" as Private +/** + * TabBar is a plasma-themed component that you can use as a container for + * tab buttons. + */ FocusScope { id: root + /** + * type:list + * The content of the TabBarLayout. + */ default property alias content: tabBarLayout.data + + /** + * type:TabBarLayout + * The layout of the TabBar. + */ property alias layout: tabBarLayout //Plasma extension + /** + * The current tabbar button. + */ property Item currentTab implicitWidth: layout.implicitWidth + backgroundFrame.margins.left + backgroundFrame.margins.right diff --git a/declarativeimports/plasmacomponents/qml/TabButton.qml b/declarativeimports/plasmacomponents/qml/TabButton.qml index 696165d8c..a17a1de3e 100644 --- a/declarativeimports/plasmacomponents/qml/TabButton.qml +++ b/declarativeimports/plasmacomponents/qml/TabButton.qml @@ -40,55 +40,50 @@ ** ****************************************************************************/ -/**Documented API -Inherits: - Item - -Imports: - QtQuick 1.1 - AppManager.js - -Description: - A simple tab button which is using the plasma theme. - -Properties: - Item tab: - The reference to the tab content (one of the children of a TabGroup, - usually a Page) that is activated when this TabButton is clicked. - - bool checked: - True if the button is checked,otherwise false. - - bool pressed: - True if the button is being pressed,otherwise false. - - string text: - Sets the text for the button. - - string iconSource: - Icon for the button. It can be a Freedesktop icon name, a full path to a png/svg file, - or any name for which the application has an image handler registered. - -Signals: - onClicked: - The signal is emmited when the button is clicked. -**/ - import QtQuick 1.1 import "private/AppManager.js" as Utils import org.kde.plasma.core 0.1 as PlasmaCore +/** + * A simple tab button which is using the plasma theme. + */ Item { id: root // Common Public API + /** + * The reference to the tab content (one of the children of a TabGroup, + * usually a Page) that is activated when this TabButton is clicked. + */ property Item tab + + /** + * True if the button is checked, false otherwise. + */ property bool checked: (internal.tabGroup == null) ? (internal.tabBar.currentTab == root) : (internal.tabGroup.currentTab == tab) + /** + * True if the button is being pressed, false otherwise. + */ property bool pressed: mouseArea.pressed == true && mouseArea.containsMouse + + /** + * type:string + * The text for the button. + */ property alias text: label.text + + /** + * type:string + * Icon for the button. It can be a Freedesktop icon name, a full path to a + * png/svg file, or any name for which the application has an image handler + * registered. + */ property alias iconSource: imageLoader.source + /** + * Emitted when the button is clicked. + */ signal clicked implicitWidth: label.implicitWidth + (internal.portrait ? 0 : (iconSource != null ? 16 : 0)) diff --git a/declarativeimports/plasmacomponents/qml/TabGroup.qml b/declarativeimports/plasmacomponents/qml/TabGroup.qml index aebe7a15d..93c502b97 100644 --- a/declarativeimports/plasmacomponents/qml/TabGroup.qml +++ b/declarativeimports/plasmacomponents/qml/TabGroup.qml @@ -38,32 +38,37 @@ ** ****************************************************************************/ -/**Documented API -Inherits: - Item - -Imports: - QtQuick 1.1 - -Description: - Provides a set of pages for a tab-based interface. - A tabbed interface is made up of tab buttons plus content for each button. A TabGroup component has, as its children, each page of content in the interface. These pages can be any QML items but are typically Page components for a single page of content or PageStack components when a hierarchical navigation system is required for the tab content. - If you use Page components for your tab content, the status property of each page is updated appropriately when the current tab is changed: the current page has status PageStatus.Active and other pages have the status PageStatus.Inactive. During page transitions, PageStatus.Activating (for the page that is becoming the current page) and PageStatus.Deactivating (for the page that was the current page) statuses are also set. - -Properties: - Item currentTab: - The tab that is currently active and visible to the user. - The currentTab property is initialized to null and is automatically set to point to the first tab when content is added. You can set the currentTab at any time to activate a particular tab. - -**/ - import QtQuick 1.1 import "private/TabGroup.js" as Engine import "." 0.1 +/** + * Provides a set of pages for a tab-based interface. + * + * A tabbed interface is made up of tab buttons plus content for each button. A + * TabGroup component has, as its children, each page of content in the + * interface. These pages can be any QML items but are typically Page + * components for a single page of content or PageStack components when a + * hierarchical navigation system is required for the tab content. + * + * If you use Page components for your tab content, the status property of each + * page is updated appropriately when the current tab is changed: the current + * page has status PageStatus.Active and other pages have the status + * PageStatus.Inactive. During page transitions, PageStatus.Activating (for the + * page that is becoming the current page) and PageStatus.Deactivating (for the + * page that was the current page) statuses are also set. + */ Item { id: root + + /** + * The tab that is currently active and visible to the user. + * + * The currentTab property is initialized to null and is automatically set + * to point to the first tab when content is added. You can set the + * currentTab at any time to activate a particular tab. + */ property Item currentTab property list privateContents From 156b5e1669757ce83dd1129498babc353e581264 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Aur=C3=A9lien=20G=C3=A2teau?= Date: Mon, 17 Dec 2012 22:50:53 +0100 Subject: [PATCH 23/32] Doxygenize TextArea --- .../plasmacomponents/qml/TextArea.qml | 368 ++++++++++-------- 1 file changed, 211 insertions(+), 157 deletions(-) diff --git a/declarativeimports/plasmacomponents/qml/TextArea.qml b/declarativeimports/plasmacomponents/qml/TextArea.qml index a85f2e62e..a4864d003 100644 --- a/declarativeimports/plasmacomponents/qml/TextArea.qml +++ b/declarativeimports/plasmacomponents/qml/TextArea.qml @@ -17,215 +17,269 @@ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ -/**Documented API -Inherits: - Item - -Imports: - QtQuick 1.1 - org.kde.plasma.core 0.1 - -Description: - Creates a simple plasma theme based text area. - Like kates.. - -Properties: - * font font: - This property holds the font used in the text field. - The default font value is the font from plasma desktop theme. - - * Qt::InputMethodHints inputMethodHints: - This property holds the the currently supported input method hints - for the text field. - The default values is Qt.ImhNone. - - * bool errorHighlight: - This property holds if the text field is highlighted or not - If it is true then the problematic lines will be highlighted. - This feature is defined in the Common API but is unimplemented in plasma components. - - * int cursorPosition: - This property holds the current cursor position. - - * enumeration horizontalAlignment: - Sets the horizontal alignment of the text within the TextArea item's width and height. - By default, the text alignment follows the natural alignment of the text, - for example text that is read from left to right will be aligned to the left. - Valid values: - * TextEdit.AlignLeft (default) - * TextEdit.AlignRight - * TextEdit.AlignHCenter - * TextEdit.AlignJustify - - * enumeration verticalAlignment: - Sets the vertical alignment of the text within the TextArea item's width and height. - By default, the text alignment follows the natural alignment of the text, - for example text that is read from left to right will be aligned to the left. - Valid values: - * TextEdit.AlignTop (default) - * TextEdit.AlignBottom - * TextEdit.AlignVCenter - - * bool readOnly: - This property holds if the TextArea can be modified by the user interaction. - The default value is false. - - * string selectedText: - This property holds the text selected by the user. - If no text is selected it holds an empty string. - This property is read-only. - - * int selectionEnd: - This property holds the cursor position after the last character in the current selection. - This property is read-only. - - * int selectionStart: - This property holds the cursor position before the first character in the current selection. - This property is read-only. - - * string text: - This property holds the entire text in the TextArea. - - * enumeration textFormat: - The way the text property should be displayed. - - * TextEdit.AutoText - * TextEdit.PlainText - * TextEdit.RichText - * TextEdit.StyledText - - The default is TextEdit.AutoText. If the text format is TextEdit.AutoText the text edit will automatically determine whether the text should be treated as rich text. This determination is made using Qt::mightBeRichText(). - - * enumeration wrapMode: - Set this property to wrap the text to the TextArea item's width. The text will only wrap if an explicit width has been set. - * TextEdit.NoWrap - no wrapping will be performed. - If the text contains insufficient newlines, then implicitWidth will exceed a set width. - * TextEdit.WordWrap - wrapping is done on word boundaries only. - If a word is too long, implicitWidth will exceed a set width. - * TextEdit.WrapAnywhere - wrapping is done at any point on a line, even if it occurs in the middle of a word. - * TextEdit.Wrap - if possible, wrapping occurs at a word boundary; otherwise it will occur at the appropriate point on the line, even in the middle of a word. - - The default is TextEdit.NoWrap. If you set a width, consider using TextEdit.Wrap. - - * string placeholderText: - This property holds the text displayed in when the text is empty. - The default value is empty string, meaning no placeholderText shown. - - -Plasma properties: - - * bool interactive: - This property describes whether the user can interact with the TextArea flicking content. - A user cannot drag or flick a TextArea that is not interactive. - This property is useful for temporarily disabling flicking. - - * int contentMaxWidth: - This property holds the maximum width that the text content can have. - - * int contentMaxHeight: - This property holds the maximum height that the text content can have. - - * property real scrollWidth: - This property holds the stepSize of the ScrollBar present at the TextArea - when it's content are bigger than it's size. - -Methods: - * void copy(): - Copies the currently selected text to the system clipboard. - - * void cut(): - Moves the currently selected text to the system clipboard. - - * void deselect(): - Removes active text selection. - - * void paste(): - Replaces the currently selected text by the contents of the system clipboard. - - * void select(int start, int end): - Causes the text from start to end to be selected. - If either start or end is out of range, the selection is not changed. - After calling this, selectionStart will become the lesser and selectionEnd will become the greater - (regardless of the order passed to this method). - - * void selectAll(): - Causes all text to be selected. - - * void selectWord(): - Causes the word closest to the current cursor position to be selected. - - * void positionAt(int position): - This function returns the character position at x pixels from the left of the TextArea. - Position 0 is before the first character, position 1 is after the first character but before the second, - and so on until position text.length, which is after all characters. - This means that for all x values before the first character this function returns 0, - and for all x values after the last character this function returns text.length. - - * rectangle positionToRectangle(position): - Returns the rectangle at the given position in the text. - The x, y, and height properties correspond to the cursor that would describe that position. - -**/ - import QtQuick 1.1 import org.kde.plasma.core 0.1 as PlasmaCore import "private" as Private +/** + * A plasma theme based text area. + */ Item { id: textArea // Common API - property alias font: textEdit.font // alias to textEdit.font + /** + * type:font + * Font used in the text field. + * + * The default font value is the font from plasma desktop theme. + */ + property alias font: textEdit.font + + /** + * The currently supported input method hints for the text field. + * + * The default values is Qt.ImhNone. + */ property int inputMethodHints + + /** + * Whether the text field is highlighted or not. + * + * If it is true then the problematic lines will be highlighted. + * + * @warning unimplemented in plasma components. + */ property bool errorHighlight + + /** + * type:int + * Current cursor position. + */ property alias cursorPosition: textEdit.cursorPosition + + /** + * type:enum + * Sets the horizontal alignment of the text within the TextArea item's + * width and height. + * + * By default, the text alignment follows the natural alignment of the + * text, for example text that is read from left to right will be aligned + * to the left. + * + * Valid values: + * + * - TextEdit.AlignLeft (default) + * - TextEdit.AlignRight + * - TextEdit.AlignHCenter + * - TextEdit.AlignJustify + */ property alias horizontalAlignment: textEdit.horizontalAlignment + + /** + * type:enum + * Sets the vertical alignment of the text within the TextArea item's width + * and height. + * + * Valid values: + * + * - TextEdit.AlignTop (default) + * - TextEdit.AlignBottom + * - TextEdit.AlignVCenter + */ property alias verticalAlignment: textEdit.verticalAlignment + + /** + * type:bool + * Whether the TextArea is in read-only mode, and cannot be modified by the + * user. + * + * The default value is false. + */ property alias readOnly: textEdit.readOnly - property alias selectedText: textEdit.selectedText // read-only - property alias selectionEnd: textEdit.selectionEnd // read-only - property alias selectionStart: textEdit.selectionStart // read-only + + /** + * type:string + * The text selected by the user. If no text is selected it holds an empty + * string. + * + * This property is read-only. + */ + property alias selectedText: textEdit.selectedText + + /** + * type:int + * The cursor position after the last character in the current selection. + * + * This property is read-only. + */ + property alias selectionEnd: textEdit.selectionEnd + + /** + * type:int + * The cursor position before the first character in the current selection. + * + * This property is read-only. + */ + property alias selectionStart: textEdit.selectionStart + + + /** + * type:string + * The text in the TextArea. + */ property alias text: textEdit.text - property alias textFormat: textEdit.textFormat // enumeration - property alias wrapMode: textEdit.wrapMode // enumeration + + /** + * type:enum + * The way the text property should be displayed. + * + * Valid values: + * + * - TextEdit.AutoText + * - TextEdit.PlainText + * - TextEdit.RichText + * - TextEdit.StyledText + * + * The default is TextEdit.AutoText. If the text format is + * TextEdit.AutoText the text edit will automatically determine whether the + * text should be treated as rich text. This determination is made using + * Qt::mightBeRichText(). + */ + property alias textFormat: textEdit.textFormat + + /** + * type:enum + * Set this property to wrap the text to the TextArea item's width. The + * text will only wrap if an explicit width has been set. + * + * Valid values: + * + * - TextEdit.NoWrap: no wrapping will be performed. If the text contains + * insufficient newlines, then implicitWidth will exceed a set width. + * - TextEdit.WordWrap: wrapping is done on word boundaries only. If a + * word is too long, implicitWidth will exceed a set width. + * - TextEdit.WrapAnywhere: wrapping is done at any point on a line, even + * if it occurs in the middle of a word. + * - TextEdit.Wrap: if possible, wrapping occurs at a word boundary; + * otherwise it will occur at the appropriate point on the line, even in + * the middle of a word. + * + * The default is TextEdit.NoWrap. If you set a width, consider using + * TextEdit.Wrap. + */ + property alias wrapMode: textEdit.wrapMode + + /** + * The text displayed when the text property is empty. + * + * The default value is an empty string, meaning no placeholderText shown. + */ property string placeholderText // functions + /** + * Copies the currently selected text to the system clipboard. + */ function copy() { textEdit.copy(); } - + /** + * Replaces the currently selected text by the contents of the system + * clipboard. + */ function paste() { textEdit.paste(); } + /** + * Moves the currently selected text to the system clipboard. + */ function cut() { textEdit.cut(); } + /** + * Causes the text from start to end to be selected. + * + * If either start or end is out of range, the selection is not changed. + * After calling this, selectionStart will become the lesser and + * selectionEnd will become the greater (regardless of the order passed to + * this method). + * + * @param int start Start of selection + * @param int end End of selection + */ function select(start, end) { textEdit.select(start, end); } + /** + * Causes all text to be selected. + */ function selectAll() { textEdit.selectAll(); } + /** + * Causes the word closest to the current cursor position to be selected. + */ function selectWord() { textEdit.selectWord(); } + /** + * This function returns the character position at x pixels from the left + * of the TextArea. + * + * Position 0 is before the first character, position 1 is after the first + * character but before the second, and so on until position text.length, + * which is after all characters. This means that for all x values before + * the first character this function returns 0, and for all x values after + * the last character this function returns text.length. + * + * @param int pos x-coordinate we are interested in. + * @return int the character position + */ + // Does this work at all? doc for TextEdit says positionAt() accepts two + // ints: x and y function positionAt(pos) { return textEdit.positionAt(pos); } + /** + * Returns the rectangle at the given position in the text. + * + * The x, y, and height properties correspond to the cursor that would + * describe that position. + * + * @param int pos the text position + * @param type:rectangle the cursor rectangle + */ function positionToRectangle(pos) { return textEdit.positionToRectangle(pos); } // Plasma API + /** + * type:bool + * This property describes whether the user can interact with the TextArea + * flicking content. A user cannot drag or flick a TextArea that is not + * interactive. This property is useful for temporarily disabling + * flicking. + */ property alias interactive: flickArea.interactive + + /** + * type:int + * Maximum width that the text content can have. + */ property alias contentMaxWidth: textEdit.width + + /** + * type:int + * Maximum height that the text content can have. + */ property alias contentMaxHeight: textEdit.height // Set active focus to it's internal textInput. From f4c06531742ccefa78e733ba078d097409b7f59c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Aur=C3=A9lien=20G=C3=A2teau?= Date: Mon, 17 Dec 2012 23:34:31 +0100 Subject: [PATCH 24/32] Doxygenize TextField --- .../plasmacomponents/qml/TextField.qml | 329 ++++++++++-------- 1 file changed, 187 insertions(+), 142 deletions(-) diff --git a/declarativeimports/plasmacomponents/qml/TextField.qml b/declarativeimports/plasmacomponents/qml/TextField.qml index d19e7d886..2f0133f52 100644 --- a/declarativeimports/plasmacomponents/qml/TextField.qml +++ b/declarativeimports/plasmacomponents/qml/TextField.qml @@ -17,207 +17,252 @@ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ -/**Documented API -Inherits: - Item - -Imports: - QtQuick 1.1 - -Description: - Creates a simple plasma theme based text field widget. - -Properties: - * font font: - This property holds the font used in the text field. - The default font value is the font from plasma desktop theme. - - * Qt::InputMethodHints inputMethodHints: - This property holds the the currently supported input method hints - for the text field. - The default values is Qt.ImhNone. - - * bool errorHighlight: - This property holds if the text field is highlighted or not - If it is true then the problematic lines will be highlighted. - This feature is defined in the Common API but is unimplemented in plasma components. - - * int cursorPosition: - This property holds the current cursor position. - - * bool readOnly: - This property holds if the text field can be modified by the user interaction. - The default value is false. - - * string selectedText: - This property holds the text selected by the user. - If no text is selected it holds an empty string. - This property is read-only. - - * int selectionEnd: - This property holds the cursor position after the last character in the current selection. - This property is read-only. - - * int selectionStart: - This property holds the cursor position before the first character in the current selection. - This property is read-only. - - * string text: - This property holds the entire text in the text field. - - * string placeholderText: - This property holds the text displayed in when the text is empty. - The default value is empty string, meaning no placeholderText shown. - - * enumeration echoMode: - This property specifies how the text should be displayed in the TextField. - The acceptable values are: - - TextInput.Normal - Displays the text as it is. (Default) - - TextInput.Password - Displays asterixes instead of characters. - - TextInput.NoEcho - Displays nothing. - - TextInput.PasswordEchoOnEdit - Displays all but the current character as asterixes. - The default value is TextInput.Normal - - * string inputMask: - Allows you to set an input mask on the TextField, restricting the allowable text inputs. - See QLineEdit::inputMask for further details, as the exact same mask strings are used by TextInput. - - * Validator validator: - Allows you to set a validator on the TextField. When a validator is set the TextField - will only accept input which leaves the text property in an acceptable or intermediate state. - The accepted signal will only be sent if the text is in an acceptable state when enter is pressed. - Currently supported validators are IntValidator, DoubleValidator and RegExpValidator. - An example of using validators is shown below, which allows input of integers - between 11 and 31 into the text input: - - import QtQuick 1.0 - TextInput { - validator: IntValidator { bottom: 11; top: 31 } - focus: true - } - - - * int maximumLength: - The maximum permitted length of the text in the TextField. - If the text is too long, it is truncated at the limit. - By default, this property contains a value of 32767. - - * bool acceptableInput: - This property is always true unless a validator or input mask has been set. - If a validator or input mask has been set, this property will only be true if the current - text is acceptable to the validator or input mask as a final string (not as an intermediate string). - This property is always true unless a validator has been set. - If a validator has been set, this property will only be true if the current text is acceptable to the - validator as a final string (not as an intermediate string). - This property is read-only. - - * bool clearButtonShown: - Holds if the button to clear the text from TextField is visible. -Signals: - * accepted(): - This signal is emitted when the text input is accepted. - -Methods: - * void copy(): - Copies the currently selected text to the system clipboard. - - * void cut(): - Moves the currently selected text to the system clipboard. - - * void deselect(): - Removes active text selection. - - * void paste(): - Replaces the currently selected text by the contents of the system clipboard. - - * void select(int start, int end): - Causes the text from start to end to be selected. - If either start or end is out of range, the selection is not changed. - After calling this, selectionStart will become the lesser and selectionEnd will become the greater - (regardless of the order passed to this method). - - * void selectAll(): - Causes all text to be selected. - - * void selectWord(): - Causes the word closest to the current cursor position to be selected. - - * void positionAt(int position): - This function returns the character position at x pixels from the left of the TextField. - Position 0 is before the first character, position 1 is after the first character but before the second, - and so on until position text.length, which is after all characters. - This means that for all x values before the first character this function returns 0, - and for all x values after the last character this function returns text.length. - - * rectangle positionToRectangle(position): - Returns the rectangle at the given position in the text. - The x, y, and height properties correspond to the cursor that would describe that position. -**/ - import QtQuick 1.1 import org.kde.plasma.core 0.1 as PlasmaCore import "private" as Private +/** + * A plasma theme based text field widget. + */ FocusScope { id: textField // Common API + /** + * Whether the text field is highlighted or not + * + * If it is true then the problematic lines will be highlighted. + * + * @warning Not implemented in Plasma components. + */ property bool errorHighlight: false // TODO + + /** + * type:string + * + * The text displayed in when the text is empty. + * + * The default value is an empty string, meaning no placeholderText shown. + */ property string placeholderText + + /** + * type:int + * The currently supported input method hints for the text field. + * + * The default values is Qt.ImhNone. + */ property alias inputMethodHints: textInput.inputMethodHints + + /** + * type:font + * The font used in the text field. + * + * The default font value is the font from plasma desktop theme. + */ property alias font: textInput.font + /** + * type:int + * This property holds the current cursor position. + */ property alias cursorPosition: textInput.cursorPosition + + /** + * type:bool + * This property holds if the text field can be modified by the user interaction. + * + * The default value is false. + */ property alias readOnly: textInput.readOnly - property alias echoMode: textInput.echoMode // Supports TextInput.Normal,TextInput.Password, TextInput.NoEcho, TextInput.PasswordEchoOnEdit + + /** + * type:enum + * + * Specifies how the text should be displayed in the TextField. + * + * The acceptable values are: + * - TextInput.Normal: Displays the text as it is. (Default) + * - TextInput.Password: Displays asterixes instead of characters. + * - TextInput.NoEcho: Displays nothing. + * - TextInput.PasswordEchoOnEdit: Displays all but the current character + * as asterixes. + * + * The default value is TextInput.Normal + */ + property alias echoMode: textInput.echoMode + + property alias passwordCharacter: textInput.passwordCharacter property alias acceptableInput: textInput.acceptableInput // read-only + + /** + * type:string + * + * Allows you to set an input mask on the TextField, restricting the + * allowable text inputs. + * + * See QLineEdit::inputMask for further details, as the exact same mask + * strings are used by TextInput. + */ property alias inputMask: textInput.inputMask + + /** + * type:QtObject + * + * Allows you to set a validator on the TextField. When a validator is set + * the TextField will only accept input which leaves the text property in + * an acceptable or intermediate state. The accepted signal will only be + * sent if the text is in an acceptable state when enter is pressed. + * + * Currently supported validators are IntValidator, DoubleValidator and + * RegExpValidator. + * + * An example of using validators is shown below, which allows input of + * integers between 11 and 31 into the text input: + * + * @code + * import QtQuick 1.0 + * TextInput { + * validator: IntValidator { bottom: 11; top: 31 } + * focus: true + * } + * @endcode + */ property alias validator: textInput.validator - property alias selectedText: textInput.selectedText // read-only - property alias selectionEnd: textInput.selectionEnd // read-only - property alias selectionStart: textInput.selectionStart // read-only + + /** + * type:string + * The text selected by the user. If no text is selected it holds an empty string. + * + * This property is read-only. + */ + property alias selectedText: textInput.selectedText + + /** + * type:int + * The cursor position after the last character in the current selection. + * + * This property is read-only. + */ + property alias selectionEnd: textInput.selectionEnd + + /** + * type:int + * The cursor position before the first character in the current selection. + * + * This property is read-only. + */ + property alias selectionStart: textInput.selectionStart + + /** + * type:string + * The text in the text field. + */ property alias text: textInput.text + + /** + * type:int + * + * The maximum permitted length of the text in the TextField. If the text + * is too long, it is truncated at the limit. + * + * Default value is 32767. + */ property alias maximumLength: textInput.maximumLength + /** + * Emitted when the text input is accepted. + */ signal accepted() //Plasma api + /** + * Whether the button to clear the text from TextField is visible. + */ property bool clearButtonShown: false + /** + * Copies the currently selected text to the system clipboard. + */ function copy() { textInput.copy(); } + /** + * Replaces the currently selected text by the contents of the system + * clipboard. + */ function paste() { textInput.paste(); } + /** + * Moves the currently selected text to the system clipboard. + */ function cut() { textInput.cut(); } + /** + * Causes the text from start to end to be selected. + * + * If either start or end is out of range, the selection is not changed. + * After calling this, selectionStart will become the lesser and + * selectionEnd will become the greater (regardless of the order passed to + * this method). + * + * @param int start Start of selection + * @param int end End of selection + */ function select(start, end) { textInput.select(start, end); } + /** + * Causes all text to be selected. + */ function selectAll() { textInput.selectAll(); } + /** + * Causes the word closest to the current cursor position to be selected. + */ function selectWord() { textInput.selectWord(); } + /** + * This function returns the character position at x pixels from the left + * of the TextField. + * + * Position 0 is before the first character, position 1 is after the first + * character but before the second, and so on until position text.length, + * which is after all characters. This means that for all x values before + * the first character this function returns 0, and for all x values after + * the last character this function returns text.length. + * + * @param int pos x-coordinate we are interested in. + * @return int the character position + */ function positionAt(pos) { return textInput.positionAt(pos); } + /** + * Returns the rectangle at the given position in the text. + * + * The x, y, and height properties correspond to the cursor that would + * describe that position. + * + * @param int pos the text position + * @param type:rectangle the cursor rectangle + */ function positionToRectangle(pos) { return textInput.positionToRectangle(pos); } - // Set active focus to it's internal textInput. // Overriding QtQuick.Item forceActiveFocus function. function forceActiveFocus() { From bc21de1b4c258e3cc1a537579a0b2c740f90ddc6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Aur=C3=A9lien=20G=C3=A2teau?= Date: Mon, 17 Dec 2012 23:35:55 +0100 Subject: [PATCH 25/32] Doxygenize ToolBar, ToolBarLayout and ToolButton --- .../plasmacomponents/qml/ToolBar.qml | 80 +++++++--------- .../plasmacomponents/qml/ToolBarLayout.qml | 20 +--- .../plasmacomponents/qml/ToolButton.qml | 95 +++++++++---------- 3 files changed, 84 insertions(+), 111 deletions(-) diff --git a/declarativeimports/plasmacomponents/qml/ToolBar.qml b/declarativeimports/plasmacomponents/qml/ToolBar.qml index dfe3c72a7..930c7c13b 100644 --- a/declarativeimports/plasmacomponents/qml/ToolBar.qml +++ b/declarativeimports/plasmacomponents/qml/ToolBar.qml @@ -17,53 +17,23 @@ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ -/**Documented API -Inherits: - PlasmaCore.FrameSvgItem - -Imports: - QtQuick 1.1 - org.kde.plasma.core - -Description: - A plasma theme based toolbar. - -Properties: - - Item tools: - The ToolBarLayout that contains the ToolButton components that - are contained in the ToolBar. ToolBarLayout is not mandatory. - The default value is NULL. - - - string transition: - The type of transition to be used for the ToolBar when - the page changes on the relevant PageStack. - The possible values can be one of the following: - set an instantaneous change (default) - push follows page stack push animation - pop follows page stack pop animation - replace follows page stack replace animation - - Object margins: - margins from the toolbar to the contents. it had 4 properties: left, top, right, bottom - -Methods: - void setTools( tools, transition ): - This sets the tools for the ToolBar and the transition type that - will be used when the page changes on the relevant PageStack. - @arg Item tools see tool property - @arg string transition see transition property -**/ - import QtQuick 1.1 import org.kde.plasma.core 0.1 as PlasmaCore +/** + * A plasma theme based toolbar. + */ Item{ id: toolBar width: parent.width height: (tools && enabled) ? tools.height + frameSvg.margins.top + frameSvg.margins.bottom : 0 visible: height > 0 + + /** + * type:Object margins + * margins from the toolbar to the contents. It has 4 properties: left, + * top, right, bottom + */ property alias margins: frameSvg.margins Behavior on height { @@ -74,14 +44,25 @@ Item{ } z: 1000 - // The current set of tools; null if none. + /** + * The ToolBarLayout that contains the ToolButton components that are + * contained in the ToolBar. ToolBarLayout is not mandatory. + * + * The default value is null. + */ property Item tools - // The transition type. One of the following: - // set an instantaneous change (default) - // push follows page stack push animation - // pop follows page stack pop animation - // replace follows page stack replace animation + /** + * The type of transition to be used for the ToolBar when the page changes + * on the relevant PageStack. + * + * The possible values can be one of the following: + * + * - set: an instantaneous change (default) + * - push: follows page stack push animation + * - pop: follows page stack pop animation + * - replace: follows page stack replace animation + */ property string transition: "set" //This invisible item keeps all the old dismissed tools: @@ -90,7 +71,14 @@ Item{ id: oldToolsItem visible: false } - // Sets the tools with a transition. + + /** + * This sets the tools for the ToolBar and the transition type that will be + * used when the page changes on the relevant PageStack. + * + * @param type:Item tools see tool property + * @param type:string transition see transition property + */ function setTools(tools, transition) { if (toolBar.tools == tools) { diff --git a/declarativeimports/plasmacomponents/qml/ToolBarLayout.qml b/declarativeimports/plasmacomponents/qml/ToolBarLayout.qml index a6145d6ec..dfee250fa 100644 --- a/declarativeimports/plasmacomponents/qml/ToolBarLayout.qml +++ b/declarativeimports/plasmacomponents/qml/ToolBarLayout.qml @@ -17,25 +17,13 @@ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ - -// ToolBarLayout is a container for items on a toolbar that automatically -// implements an appropriate layout for its children. - -/**Documented API -Inherits: - Row - -Imports: - QtQuick 1.1 - -Description: - ToolBarLayout is a container for items on a toolbar that automatically implements an appropriate layout for its children. -**/ - import QtQuick 1.1 import "." 0.1 - +/** + * ToolBarLayout is a container for items on a toolbar that automatically + * implements an appropriate layout for its children. + */ Row { id: root diff --git a/declarativeimports/plasmacomponents/qml/ToolButton.qml b/declarativeimports/plasmacomponents/qml/ToolButton.qml index f517780b0..bd6af7df2 100644 --- a/declarativeimports/plasmacomponents/qml/ToolButton.qml +++ b/declarativeimports/plasmacomponents/qml/ToolButton.qml @@ -18,71 +18,61 @@ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ -/**Documented API -Inherits: - Item - -Imports: - QtQuick 1.1 - org.kde.plasma.core - -Description: - A plasma theme based toolbutton. - -Properties: - bool flat: - Returns true if the button is flat. - - bool checked: false - Returns true if the button is checked. - - bool checkable: - Returns true if the button is checkable. - - bool pressed: - Returns true if the button is pressed. - alias text: - Sets the text for the button. - - variant iconSource: - Sets the icon for the button. - It can be any image from any protocol supported by the Image element, or a freedesktop-compatible icon name - - string font: - Sets the font for the button. - - bool enabled: - Returns whether the button is currently enabled and receives user input. - -Signals: - onClicked: - The signal is being emmited when the button is being clicked. - -Plasma properties: - - * real minimumWidth: - This property holds the smallest width this button can be to show all the contents - - * real minimumHeight: - This property holds the smallest height this button can be to show all the contents -**/ - import QtQuick 1.1 import org.kde.plasma.core 0.1 as PlasmaCore import "private" as Private +/** + * A plasma theme based toolbutton. + */ Item { id: button // Commmon API + /** + * true if the button is flat. + */ property bool flat: true + + /** + * true if the button is checked. + */ property bool checked: defaultAction ? defaultAction.checked : false + + /** + * true if the button is checkable. + */ property bool checkable: defaultAction ? defaultAction.checkable : false + + /** + * type:string + * true if the button is currently pressed. + */ property alias pressed: mouse.pressed + + /** + * type:string + * The text of the button + */ property alias text: label.text + + /** + * type:variant + * + * Sets the icon for the button. It can be any image from any protocol + * supported by the Image element, or a freedesktop-compatible icon name + */ property alias iconSource: icon.source + + /** + * type:font + * The font for the button + */ property alias font: label.font + /** + * Emited when the button is clicked. + */ signal clicked() // Plasma extensiuons @@ -91,10 +81,17 @@ Item { enabled: defaultAction == undefined || defaultAction.enabled + /** + * The smallest width this button can be to show all the contents + */ //icon + label + left margin + right margin + spacing between icon and text //here it assumesleft margin = right top = bottom, why? // because the right and bottom margins can be disabled, so they would return 0, but their actual size is still needed for size hints property real minimumWidth: theme.smallIconSize + label.paintedWidth + delegate.margins.left + delegate.margins.left + ((icon.valid) ? delegate.margins.left : 0) + + /** + * The smallest height this button can be to show all the contents + */ property real minimumHeight: Math.max(theme.smallIconSize, label.paintedHeight) + delegate.margins.top + delegate.margins.top implicitWidth: { From 9f209bac3f914c50ac3d6e5b3d388ff47fcba845 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Aur=C3=A9lien=20G=C3=A2teau?= Date: Mon, 17 Dec 2012 23:39:31 +0100 Subject: [PATCH 26/32] Doxygenize App --- .../plasmaextracomponents/qml/App.qml | 103 +++++++++--------- 1 file changed, 50 insertions(+), 53 deletions(-) diff --git a/declarativeimports/plasmaextracomponents/qml/App.qml b/declarativeimports/plasmaextracomponents/qml/App.qml index 25e14546a..5ac2a655d 100644 --- a/declarativeimports/plasmaextracomponents/qml/App.qml +++ b/declarativeimports/plasmaextracomponents/qml/App.qml @@ -17,67 +17,64 @@ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ -/**Documented API -Inherits: - Item - -Imports: - QtQuick 1.1 - org.kde.plasma.extras - -Description: - This is a container for Apps. Navigation and Content area layout can vary depending on the - available size. This class can be used as top level Item or inside your top-level item. It - will manage context or navigation area, content area and toolbars in a way consistent with - other apps, and adaptive to the device. - - Note that App is experimental, its API might change. - - Example usage: -
import QtQuick 1.1
-import org.kde.plasma.core 0.1 as PlasmaCore
-import org.kde.plasma.extras 0.1 as PlasmaExtras
-
-PlasmaExtras.App {
-    id: app
-    width: 800
-    height: 600
-
-    navigation: navigationItem
-    content: contentItem
-
-    Item {
-        id: navigationItem
-        // [...] this is the navigation area
-    }
-
-    Loader {
-        id: contentItem
-        source: "gallery/Extras.qml"
-        parent: contentArea
-    }
-}
- -Properties: - Item navigation: - Navigation or Context Area. - - Item content: - The "main view" - - ToolBarLayout tools: - alias to the topBar's ToolBar.tools - -**/ - import QtQuick 1.1 import org.kde.plasma.core 0.1 as PlasmaCore import org.kde.plasma.components 0.1 as PlasmaComponents +/** + * This is a container for Apps. Navigation and Content area layout can vary + * depending on the available size. This class can be used as top level Item or + * inside your top-level item. It will manage context or navigation area, + * content area and toolbars in a way consistent with other apps, and adaptive + * to the device. + * + * @remark App is experimental, its API might change. + * + * Example usage: + * @code + * import QtQuick 1.1 + * import org.kde.plasma.core 0.1 as PlasmaCore + * import org.kde.plasma.extras 0.1 as PlasmaExtras + * + * PlasmaExtras.App { + * id: app + * width: 800 + * height: 600 + * + * navigation: navigationItem + * content: contentItem + * + * Item { + * id: navigationItem + * // [...] this is the navigation area + * } + * + * Loader { + * id: contentItem + * source: "gallery/Extras.qml" + * parent: contentArea + * } + * } + * @endcode + */ Item { id: app + /** + * type:Item + * Navigation or Context Area. + */ property alias navigation: navigationItem.children + + /** + * type:Item + * The "main view" + */ property alias content: contentItem.children + + /** + * type:Item + * the topBar's ToolBar.tools + */ property alias tools: topBar.tools property alias contentArea: contentBackground From bc924f1ebf0078f16c3fe713dbdda9f92e043c64 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Aur=C3=A9lien=20G=C3=A2teau?= Date: Mon, 17 Dec 2012 23:42:34 +0100 Subject: [PATCH 27/32] Doxygenize ConditionalLoader --- .../qml/ConditionalLoader.qml | 48 +++++++++++-------- 1 file changed, 27 insertions(+), 21 deletions(-) diff --git a/declarativeimports/plasmaextracomponents/qml/ConditionalLoader.qml b/declarativeimports/plasmaextracomponents/qml/ConditionalLoader.qml index 14e86764b..da42b7123 100644 --- a/declarativeimports/plasmaextracomponents/qml/ConditionalLoader.qml +++ b/declarativeimports/plasmaextracomponents/qml/ConditionalLoader.qml @@ -17,30 +17,36 @@ */ import QtQuick 1.1 -/**Documented API -Inherits: - Item - -Imports: - QtQuick 1.1 - -Description: - This item can load any qml component, just like a Loader. Important difference, the component will be only loaded when the "when" property is satisfied (ie evaluates to true) in this way it's easy to have big (and memory expensive) parts of the user interface load only when a certain condition is satisfied. - For instance the contents of the tabs of a TabBar can be loaded only when they become the current page - -Properties: - bool when: - Boolean condition that tells when to load the declarative component - - variant source: - It can be a string with a path name of a qml file or a Component. It's the component that will be loaded when "when" is true. If the component changes the old instantiated component will be deleted and the new will be loaded instead. - - Item item: the item instantiated from component, if any. -**/ +/** + * This item can load any qml component, just like a Loader. Important + * difference, the component will only be loaded when the "when" property is + * satisfied (ie evaluates to true) in this way it's easy to have big (and + * memory expensive) parts of the user interface load only when a certain + * condition is satisfied. For instance the contents of the tabs of a TabBar + * can be loaded only when they become the current page. + */ Item { id: root + + /** + * type:bool + * Condition that tells when to load the declarative component + */ property alias when: loader.when + + /** + * type:variant + * It can be a string with a path name of a qml file or a Component. It's + * the component that will be loaded when "when" is true. If the component + * changes the old instantiated component will be deleted and the new one + * will be loaded instead. + */ property alias source: loader.conditionalSource + + /** + * type:Item + * The item instantiated from component, if any. + */ property alias item: loader.item Loader { @@ -76,4 +82,4 @@ Item { } } } -} \ No newline at end of file +} From 068a46b9d4cd00cbdd18c8752a34106e140f0788 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Aur=C3=A9lien=20G=C3=A2teau?= Date: Tue, 18 Dec 2012 00:02:53 +0100 Subject: [PATCH 28/32] Doxygenize Heading, Paragraph and Title --- .../plasmaextracomponents/qml/Heading.qml | 70 ++++++++----------- .../plasmaextracomponents/qml/Paragraph.qml | 65 ++++++----------- .../plasmaextracomponents/qml/Title.qml | 55 ++++++--------- 3 files changed, 72 insertions(+), 118 deletions(-) diff --git a/declarativeimports/plasmaextracomponents/qml/Heading.qml b/declarativeimports/plasmaextracomponents/qml/Heading.qml index 1966bc83f..7aa8d27e2 100644 --- a/declarativeimports/plasmaextracomponents/qml/Heading.qml +++ b/declarativeimports/plasmaextracomponents/qml/Heading.qml @@ -17,52 +17,42 @@ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ -/**Documented API -Inherits: - Label - -Imports: - QtQuick 1.1 - org.kde.plasma.extras - -Description: - This is a heading label used for subsections of texts. - The characteristics of the text will be automatically set according to the plasma theme. Use - this components for section titles or headings in your UI, for example page or section titles. - - Example usage: - -import org.kde.plasma.extras 0.1 as PlasmaExtras -[...] -Column{ - PlasmaExtras.Title { text: "Fruit sweetness on the rise" } - PlasmaExtras.Heading { text: "Apples in the sunlight"; level: 2 } - PlasmaExtras.Paragraph { text: "Long text about fruit and apples [...]" } - [...] -} - - - See Plasma Component's Label and primitive QML Text element API for additional properties, - methods and signals. - - -Properties: - string text: - The most important property is "text", which applies to the text property of Label - For the other ones see Plasma Component's Label or QML primitive Text element - - int level: - The level determines how big the section header is display, values between 1 (big) - and 5 (small) are accepted - -**/ - import QtQuick 1.1 import org.kde.plasma.components 0.1 +/** + * A heading label used for subsections of texts. + * + * The characteristics of the text will be automatically set according to the + * plasma theme. Use this components for section titles or headings in your UI, + * for example page or section titles. + * + * Example usage: + * + * @code + * import org.kde.plasma.extras 0.1 as PlasmaExtras + * [...] + * Column { + * PlasmaExtras.Title { text: "Fruit sweetness on the rise" } + * PlasmaExtras.Heading { text: "Apples in the sunlight"; level: 2 } + * PlasmaExtras.Paragraph { text: "Long text about fruit and apples [...]" } + * [...] + * } + * @endcode + * + * The most important property is "text", which applies to the text property of + * Label. See PlasmaComponents Label and primitive QML Text element API for + * additional properties, methods and signals. + */ Label { id: heading + + /** + * The level determines how big the section header is display, values + * between 1 (big) and 5 (small) are accepted + */ property int level: 1 + property int step: 2 font.pointSize: headerPointSize(level) diff --git a/declarativeimports/plasmaextracomponents/qml/Paragraph.qml b/declarativeimports/plasmaextracomponents/qml/Paragraph.qml index a7d459683..ec509f9d8 100644 --- a/declarativeimports/plasmaextracomponents/qml/Paragraph.qml +++ b/declarativeimports/plasmaextracomponents/qml/Paragraph.qml @@ -17,52 +17,31 @@ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ -/**Documented API -Inherits: - Label - -Imports: - QtQuick 1.1 - org.kde.plasma.extras - -Description: - This is a paragraph Label which uses the plasma theme. The characteristics of the text will - be automatically set according to the plasma theme. Use this components for paragraphs - of text in your application. Use this component for blocks of text in your app. - - Example usage: - -import org.kde.plasma.extras 0.1 as PlasmaExtras -[...] -Column{ - PlasmaExtras.Title { text: "Fruit sweetness on the rise" } - PlasmaExtras.Heading { text: "Apples in the sunlight"; level: 2 } - PlasmaExtras.Paragraph { text: "Long text about fruit and apples [...]" } - [...] -} - - - See Plasma Component's Label and primitive QML Text element API for additional properties, - methods and signals. - -Properties: - string text: - The most important property is "text", which applies to the text property of Label - For the other ones see Plasma Component's Label or QML primitive Text element - - int level: - The level determines how big the section header is display, values between 1 (big) - and 5 (small) are accepted - -Methods: - -Signals: - See Plasma Component's Label and primitive QML Text element -**/ - import QtQuick 1.1 import org.kde.plasma.components 0.1 +/** + * This is a paragraph Label which uses the plasma theme. + * + * The characteristics of the text will be automatically set according to the + * plasma theme. Use this components for paragraphs of text in your + * application. Use this component for blocks of text in your app. + * + * Example usage: + * @code + * import org.kde.plasma.extras 0.1 as PlasmaExtras + * [...] + * Column { + * PlasmaExtras.Title { text: "Fruit sweetness on the rise" } + * PlasmaExtras.Heading { text: "Apples in the sunlight"; level: 2 } + * PlasmaExtras.Paragraph { text: "Long text about fruit and apples [...]" } + * [...] + * } + * @endcode + * + * See PlasmaComponents Label and primitive QML Text element API for additional + * properties, methods and signals. + */ Label { id: paragraph width: parent.width diff --git a/declarativeimports/plasmaextracomponents/qml/Title.qml b/declarativeimports/plasmaextracomponents/qml/Title.qml index 87addb42a..f817b1780 100644 --- a/declarativeimports/plasmaextracomponents/qml/Title.qml +++ b/declarativeimports/plasmaextracomponents/qml/Title.qml @@ -17,44 +17,29 @@ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ -/**Documented API -Inherits: - Label - -Imports: - QtQuick 1.1 - org.kde.plasma.components 0.1 - -Description: - This is a title label which uses the plasma theme. - The characteristics of the text will be automatically set - according to the plasma theme. Use this components for titles - in your UI, for example page or section titles. - - Example usage: - -import org.kde.plasma.extras 0.1 as PlasmaExtras -[...] -Column{ - PlasmaExtras.Title { text: "Fruit sweetness on the rise" } - PlasmaExtras.Heading { text: "Apples in the sunlight"; level: 2 } - PlasmaExtras.Paragraph { text: "Long text about fruit and apples [...]" } - [...] -} - - - See Plasma Component's Label and primitive QML Text element API for additional properties, - methods and signals. - -Properties: - string text: - The most important property is "text", which applies to the text property of Label - For the other ones see Plasma Component's Label or QML primitive Text element -**/ - import QtQuick 1.1 import org.kde.plasma.components 0.1 +/** + * This is a title label which uses the plasma theme. The characteristics of + * the text will be automatically set according to the plasma theme. Use this + * components for titles in your UI, for example page or section titles. + * + * Example usage: + * @code + * import org.kde.plasma.extras 0.1 as PlasmaExtras + * [...] + * Column { + * PlasmaExtras.Title { text: "Fruit sweetness on the rise" } + * PlasmaExtras.Heading { text: "Apples in the sunlight"; level: 2 } + * PlasmaExtras.Paragraph { text: "Long text about fruit and apples [...]" } + * [...] + * } + * @endcode + * + * See PlasmaComponents Label and primitive QML Text element API for additional + * properties, methods and signals. + */ Label { id: root From 5586cc4f9a60ae67702ea05f9e4ffcd93315de3c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Aur=C3=A9lien=20G=C3=A2teau?= Date: Tue, 18 Dec 2012 00:03:01 +0100 Subject: [PATCH 29/32] Doxygenize ScrollArea --- .../plasmaextracomponents/qml/ScrollArea.qml | 27 +++++++------------ 1 file changed, 10 insertions(+), 17 deletions(-) diff --git a/declarativeimports/plasmaextracomponents/qml/ScrollArea.qml b/declarativeimports/plasmaextracomponents/qml/ScrollArea.qml index 501fa330e..c73b1a9a1 100644 --- a/declarativeimports/plasmaextracomponents/qml/ScrollArea.qml +++ b/declarativeimports/plasmaextracomponents/qml/ScrollArea.qml @@ -17,30 +17,23 @@ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ -/**Documented API -Inherits: - Item - -Imports: - QtQuick 1.1 - org.kde.plasma.components 0.1 - -Description: - This item takes a Flickable and automatically puts scrollbars in adjusting the layout if needed. The scrollbars will be interactive or not, depending on the platform. - If flickableItem is a categorized ListView the vertical scrollbar will be a SectionScroller. - -Properties: - Item flickableItem: - The Flickable of this area: it can be either a Flickable or a subclass, ListView or GridView -**/ - import QtQuick 1.1 import org.kde.plasma.components 0.1 as PlasmaComponents import org.kde.plasma.core 0.1 as PlasmaCore +/** + * This item takes a Flickable and automatically puts scrollbars in adjusting + * the layout if needed. The scrollbars will be interactive or not, depending + * on the platform. If flickableItem is a categorized ListView the vertical + * scrollbar will be a SectionScroller. + */ Item { id: root + /** + * The Flickable of this area: it can be either a Flickable or a subclass, + * ListView or GridView + */ property Flickable flickableItem //FIXME: this alias seems necessary for it to correctly parse default property alias flickableItemDefault: root.flickableItem From a1bbbfcdd4858c0d516cb910aab0396085fa02fd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Aur=C3=A9lien=20G=C3=A2teau?= Date: Tue, 18 Dec 2012 00:12:55 +0100 Subject: [PATCH 30/32] Categorize components on PlasmaExtraComponents landing page --- .../plasmaextracomponents/Mainpage.dox | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/declarativeimports/plasmaextracomponents/Mainpage.dox b/declarativeimports/plasmaextracomponents/Mainpage.dox index e9f1ed7fe..ed96489ac 100644 --- a/declarativeimports/plasmaextracomponents/Mainpage.dox +++ b/declarativeimports/plasmaextracomponents/Mainpage.dox @@ -3,17 +3,21 @@

import org.kde.plasma.extras

- App -- Heading -- Paragraph - PageRow - ScrollArea +- FallbackComponent +- ResourceInstance + +Text formatting +- Heading +- Paragraph - Title + +Animations - ActivateAnimation - AppearAnimation - PressedAnimation - ReleasedAnimation -- FallbackComponent -- ResourceInstance */ From 871b414f4fc1b7731dc8218bfcc1d32096b43a42 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Aur=C3=A9lien=20G=C3=A2teau?= Date: Wed, 19 Dec 2012 14:35:18 +0100 Subject: [PATCH 31/32] Group components by category --- .../plasmacomponents/Mainpage.dox | 61 +++++++++++++------ 1 file changed, 41 insertions(+), 20 deletions(-) diff --git a/declarativeimports/plasmacomponents/Mainpage.dox b/declarativeimports/plasmacomponents/Mainpage.dox index 76c63209e..12d031bcc 100644 --- a/declarativeimports/plasmacomponents/Mainpage.dox +++ b/declarativeimports/plasmacomponents/Mainpage.dox @@ -2,41 +2,62 @@

import org.kde.plasma.components

-- BusyIndicator +## Widgets +Input: +- TextArea +- TextField +- CheckBox +- RadioButton +- Switch +- Slider + +Buttons: - Button - ButtonColumn - ButtonRow -- CheckBox -- CommonDialog -- ContextMenu -- Dialog -- DialogStatus -- Highlight +- ToolButton + +Misc: +- BusyIndicator +- ProgressBar - Label -- ListItem -- Menu -- MenuItem + +## Containers +Pages: - Page - PageOrientation - PageStatus - PageStack -- ProgressBar + +Dialogs: +- Dialog +- DialogStatus +- CommonDialog - QueryDialog -- RadioButton -- ScrollBar -- SectionScroller - SelectionDialog -- Sheet -- Slider -- Switch + +Tab bars: - TabBar - TabButton - TabGroup -- TextArea -- TextField + +Misc: +- Sheet +- ScrollBar + +## Menus +- Menu +- MenuItem +- ContextMenu + +## Lists +- ListItem +- Highlight +- SectionScroller + +## Toolbar - ToolBar - ToolBarLayout -- ToolButton */ // DOXYGEN_SET_PROJECT_NAME = PlasmaComponents From fd00bbdafa245054cfb7c6117d14e33b22375ebc Mon Sep 17 00:00:00 2001 From: Script Kiddy Date: Mon, 24 Dec 2012 09:03:26 +0100 Subject: [PATCH 32/32] SVN_SILENT made messages (.desktop file) --- kpart/plasma-kpart.desktop | 1 + remotewidgetshelper/kcm_remotewidgets.actions | 2 ++ scriptengines/javascript/data/plasma-javascriptaddon.desktop | 1 + .../data/plasma-packagestructure-javascript-addon.desktop | 2 ++ .../data/plasma-scriptengine-applet-declarative.desktop | 2 ++ .../data/plasma-scriptengine-applet-simple-javascript.desktop | 2 ++ .../data/plasma-scriptengine-dataengine-javascript.desktop | 1 + .../data/plasma-scriptengine-runner-javascript.desktop | 2 ++ 8 files changed, 13 insertions(+) diff --git a/kpart/plasma-kpart.desktop b/kpart/plasma-kpart.desktop index 4431124f9..c4f2fe6ad 100644 --- a/kpart/plasma-kpart.desktop +++ b/kpart/plasma-kpart.desktop @@ -3,6 +3,7 @@ Name=plasma-kpart Name[ast]=plasma-kpart Name[bg]=plasma-kpart Name[bn]=প্লাসমা কে-পার্ট +Name[bs]=plasma-kpart Name[ca]=plasma-kpart Name[ca@valencia]=plasma-kpart Name[cs]=plasma-kpart diff --git a/remotewidgetshelper/kcm_remotewidgets.actions b/remotewidgetshelper/kcm_remotewidgets.actions index e3f3f54f4..3e1d8c4d7 100644 --- a/remotewidgetshelper/kcm_remotewidgets.actions +++ b/remotewidgetshelper/kcm_remotewidgets.actions @@ -3,6 +3,7 @@ Name=Save remote widgets' policies Name[ar]=احفظ سياسات الودجات البعيدة Name[ast]=Guardáu de polítiques d'elementos gráficos remotos Name[bg]=Запазване на правилата на отдалечените джаджи +Name[bs]=Sačuvaj smjernice za udaljene grafičke kontrole Name[ca]=Desa les polítiques d'estris remots Name[ca@valencia]=Alça les polítiques d'estris remots Name[cs]=Uložit zásady vzdálených widgetů @@ -65,6 +66,7 @@ Description=Prevents the system from saving remote plasma widgets' policies Description[ar]=يمنع النظام من حفظ سياسات ودجات بلازما البعيدة Description[ast]=Impide que'l sistema guarde polítiques d'elementos gráficos Plasma remotos Description[bg]=Забраняване запазването на правилата на отдалечените джаджи +Description[bs]=Sprečava sistem da sačuva smjernice udaljenih plazma grafičkih kontrola Description[ca]=Evita al sistema de desar polítiques d'estris remots del plasma Description[ca@valencia]=Evita al sistema d'alçar polítiques d'estris remots del plasma Description[cs]=Zabrání systému ukládat zásady vzdálených widgetů plasmy diff --git a/scriptengines/javascript/data/plasma-javascriptaddon.desktop b/scriptengines/javascript/data/plasma-javascriptaddon.desktop index 528214ae9..fc6d0ceef 100644 --- a/scriptengines/javascript/data/plasma-javascriptaddon.desktop +++ b/scriptengines/javascript/data/plasma-javascriptaddon.desktop @@ -2,6 +2,7 @@ Name=Plasma JavaScript Addon Name[ast]=Complementu de JavaScript pa Plasma Name[bg]=Добавка за JavaScript на Plasma +Name[bs]=Plazma javaskriptni dodatak Name[ca]=Complement del JavaScript pel Plasma Name[ca@valencia]=Complement del JavaScript pel Plasma Name[cs]=Doplněk Plasmy JavaScript diff --git a/scriptengines/javascript/data/plasma-packagestructure-javascript-addon.desktop b/scriptengines/javascript/data/plasma-packagestructure-javascript-addon.desktop index 98af588b8..4afcbd7de 100644 --- a/scriptengines/javascript/data/plasma-packagestructure-javascript-addon.desktop +++ b/scriptengines/javascript/data/plasma-packagestructure-javascript-addon.desktop @@ -3,6 +3,7 @@ Name=Javascript Addon Name[ast]=Complementu de JavaScript Name[bg]=Добавка за Javascript Name[bn]=জাভাস্ক্রিপ্ট অ্যাড-অন +Name[bs]=Javaskriptni dodatak Name[ca]=Complement del Javascript Name[ca@valencia]=Complement del Javascript Name[cs]=Doplněk JavaScript @@ -64,6 +65,7 @@ Name[zh_TW]=Javascript Addon Comment=Addons for Javascript Plasma plugins Comment[ast]=Amestaos pa complementos de JavaScript pa Plasma Comment[bg]=Добавки за приставките за Javascript на Plasma +Comment[bs]=Dodaci za javaskriptne plazma priključke Comment[ca]=Complements pels connectors Javascript del Plasma Comment[ca@valencia]=Complements pels connectors Javascript del Plasma Comment[cs]=Doplňky pro javascriptové zásuvné moduly plasmy diff --git a/scriptengines/javascript/data/plasma-scriptengine-applet-declarative.desktop b/scriptengines/javascript/data/plasma-scriptengine-applet-declarative.desktop index 2f649cf2c..450db37ae 100644 --- a/scriptengines/javascript/data/plasma-scriptengine-applet-declarative.desktop +++ b/scriptengines/javascript/data/plasma-scriptengine-applet-declarative.desktop @@ -2,6 +2,7 @@ Name=Declarative widget Name[ast]=Elementu gráficu declarativu Name[bg]=Декларативна джаджа +Name[bs]=Deklarativna grafička kontrola Name[ca]=Estri declaratiu Name[ca@valencia]=Estri declaratiu Name[cs]=Deklarativní widget @@ -59,6 +60,7 @@ Name[zh_TW]=宣告元件 Comment=Native Plasma widget written in QML and JavaScript Comment[ast]=Elementu gráficu nativu de Plasma escritu en QML y JavaScript Comment[bg]=Оригинална джаджа за Plasma, написана наQML и JavaScript +Comment[bs]=Samosvojni plazma grafičkih kontrola napisana u QML‑u i javaskriptu Comment[ca]=Estri nadiu del Plasma escrit en QML i JavaScript Comment[ca@valencia]=Estri nadiu del Plasma escrit en QML i JavaScript Comment[cs]=Nativní Plasma widget napsaný v QML a JavaScriptu diff --git a/scriptengines/javascript/data/plasma-scriptengine-applet-simple-javascript.desktop b/scriptengines/javascript/data/plasma-scriptengine-applet-simple-javascript.desktop index f12474581..f9e281620 100644 --- a/scriptengines/javascript/data/plasma-scriptengine-applet-simple-javascript.desktop +++ b/scriptengines/javascript/data/plasma-scriptengine-applet-simple-javascript.desktop @@ -6,6 +6,7 @@ Name[be@latin]=Widžet „JavaScript” Name[bg]=Джаджа JavaScript Name[bn]=জাভাস্ক্রিপ্ট উইজেট Name[bn_IN]=JavaScript Widget +Name[bs]=Javascript grafička kontrola Name[ca]=Estri del JavaScript Name[ca@valencia]=Estri del JavaScript Name[cs]=JavaScript Widget @@ -80,6 +81,7 @@ Comment[ar]=ودجة بلازما أصلية كتبت بجافا سكربت Comment[ast]=Elementu gráficu nativu de Plasma escritu en JavaScript Comment[be@latin]=Widžet systemy „Plasma”, napisany ŭ movie „JavaScript” Comment[bg]=Оригинална джаджа за Plasma, написана с JavaScript +Comment[bs]=Samosvojni plazma grafička kontrola napisana u javaskriptu Comment[ca]=Estri nadiu del Plasma escrit en JavaScript Comment[ca@valencia]=Estri nadiu del Plasma escrit en JavaScript Comment[cs]=Nativní Plasma widget napsaný v JavaScriptu diff --git a/scriptengines/javascript/data/plasma-scriptengine-dataengine-javascript.desktop b/scriptengines/javascript/data/plasma-scriptengine-dataengine-javascript.desktop index c3012a97f..163b1166e 100644 --- a/scriptengines/javascript/data/plasma-scriptengine-dataengine-javascript.desktop +++ b/scriptengines/javascript/data/plasma-scriptengine-dataengine-javascript.desktop @@ -4,6 +4,7 @@ Name[ar]=مشغل جافا سكربت Name[ast]=Motor de datos JavaScript Name[bg]=Ядро за данни на JavaScript Name[bn]=জাভাস্ক্রিপ্ট ডেটা-ইঞ্জিন +Name[bs]=Javascript pogon podataka Name[ca]=Motor de dades de JavaScript Name[ca@valencia]=Motor de dades de JavaScript Name[cs]=Datový nástroj JavaScript diff --git a/scriptengines/javascript/data/plasma-scriptengine-runner-javascript.desktop b/scriptengines/javascript/data/plasma-scriptengine-runner-javascript.desktop index 038186cb0..e56741d41 100644 --- a/scriptengines/javascript/data/plasma-scriptengine-runner-javascript.desktop +++ b/scriptengines/javascript/data/plasma-scriptengine-runner-javascript.desktop @@ -6,6 +6,7 @@ Name[be@latin]=Uklučeńnie „JavaScript” Name[bg]=Изпълнение на JavaScript Name[bn]=জাভাস্ক্রিপ্ট রানার Name[bn_IN]=JavaScript Runner +Name[bs]=Javascript izvođač Name[ca]=Executor de JavaScript Name[ca@valencia]=Executor de JavaScript Name[cs]=Spouštěč JavaScriptu @@ -83,6 +84,7 @@ Comment[be@latin]=Uklučeńnie „JavaScript”. Comment[bg]=Изпълнение на JavaScript Comment[bn]=জাভাস্ক্রিপ্ট চালক Comment[bn_IN]=JavaScript Runner +Comment[bs]=Javascript izvođač Comment[ca]=Executor de JavaScript Comment[ca@valencia]=Executor de JavaScript Comment[cs]=Spouštěč JavaScriptu