X-Git-Url: https://gerrit.automotivelinux.org/gerrit/gitweb?a=blobdiff_plain;f=doc%2Fwidgets.html;fp=doc%2Fwidgets.html;h=8c2757713f76ab447a518f4db81f9af8417aeb82;hb=5b74cd6f2b5cdd82273759aa7d72150dfff58a2c;hp=5a22e4be3eceea55d76ce709034eaa5e9bd92cd6;hpb=628dc10767d95436538391534dc3c95f45fe9a3a;p=src%2Fapp-framework-main.git diff --git a/doc/widgets.html b/doc/widgets.html index 5a22e4b..8c27577 100644 --- a/doc/widgets.html +++ b/doc/widgets.html @@ -8,29 +8,47 @@
This is one of the important file of the widget. It fully describes the widget.
Here is the example of the config file for the QML application SmartHome.
-<?xml version="1.0" encoding="UTF-8"?>
+<?xml version="1.0" encoding="UTF-8"?>
<widget xmlns="http://www.w3.org/ns/widgets" id="smarthome" version="0.1">
<name>SmartHome</name>
<icon src="smarthome.png"/>
@@ -77,7 +95,7 @@ code > span.er { color: #ff0000; font-weight: bold; }
automated house. The user interface is completely done with QML.</description>
<author>Qt team</author>
<license>GPL</license>
-</widget>
+</widget>
The most important items are:
<widget id="......">: gives the id of the widget. It must be unique.
@@ -97,22 +115,22 @@ automated house. The user interface is completely done with QML.For all these commands, a tiny help is available with options -h or --help.
There is no tool for unpacking a widget. For doing such operation, you can use the command unzip.
To list the files of a widget:
-$ unzip -l WIDGET
+$ unzip -l WIDGET
To extract a widget in some directory:
-$ unzip WIDGET -d DIRECTORY
+$ unzip WIDGET -d DIRECTORY
Note that DIRECTORY will be created if needed.
Signing a widget
To sign a widget, you need a private key and its certificate.
The tool wgtpkg-sign creates or replace a signature file in the directory of the widget BEFORE its packaging.
There are two types of signature files: author and distributor.
Example 1: add an author signature
-$ wgtpkg-sign -a -k me.key.pem -c me.cert.pem DIRECTORY
+$ wgtpkg-sign -a -k me.key.pem -c me.cert.pem DIRECTORY
Example 2: add a distributor signature
-$ wgtpkg-sign -k authority.key.pem -c authority.cert.pem DIRECTORY
+$ wgtpkg-sign -k authority.key.pem -c authority.cert.pem DIRECTORY
Packing a widget
This operation can be done using the command zip but we provide the tool wgtpkg-pack that may add checking.
Example:
-$ wgtpkg-pack DIRECTORY -o file.wgt
+$ wgtpkg-pack DIRECTORY -o file.wgt
Getting data about a widget file
The command wgtpkg-info opens a widget file, reads its config.xml file and displays its content in a human readable way.
Writing a widget