issue104:c_c
Différences
Ci-dessous, les différences entre deux révisions de la page.
Prochaine révision | Révision précédente | ||
issue104:c_c [2015/12/28 18:39] – créée auntiee | issue104:c_c [2016/01/16 14:44] (Version actuelle) – andre_domenech | ||
---|---|---|---|
Ligne 1: | Ligne 1: | ||
- | As promised last month, I’ll be covering some more ubuntu phone programming. While preparing for this article, I have looked at most of the tutorials from Ubuntu itself. They are well written, and definitely a good spot to start. I will focus on more general approaches - what app type to use for what purpose, as well as a small example of a web app. | + | **As promised last month, I’ll be covering some more ubuntu phone programming. While preparing for this article, I have looked at most of the tutorials from Ubuntu itself. They are well written, and definitely a good spot to start. I will focus on more general approaches - what app type to use for what purpose, as well as a small example of a web app.** |
- | App Types | + | Comme promis le mois dernier, je vais approfondir le sujet de la programmation des téléphones sous Ubuntu. Pour préparer cet article, j'ai consulté la plupart des tutoriels d' |
+ | |||
+ | **App Types | ||
• HTML5 app - this is a full-fledged HTML app. If you’re a web developer and want to create a specific HTML5 app for Ubuntu, you’ll want this. | • HTML5 app - this is a full-fledged HTML app. If you’re a web developer and want to create a specific HTML5 app for Ubuntu, you’ll want this. | ||
• Webapp - this is the app type you use to open an existing page, in order to run it like an app. | • Webapp - this is the app type you use to open an existing page, in order to run it like an app. | ||
• QML - A native app for Ubuntu (written in QML, which is the Qt Meta Language). | • QML - A native app for Ubuntu (written in QML, which is the Qt Meta Language). | ||
- | • Scopes - These can be written in various languages, and combined with APIs. | + | • Scopes - These can be written in various languages, and combined with APIs.** |
- | Webapp | + | Les types d' |
+ | |||
+ | • Application HTML5 : c'est une application HTML à part entière. Si vous êtes développeur Web et si vous voulez créer une application spécifique à Ubuntu en HTML5, c'est ce que vous utiliserez. | ||
+ | • Webapp : c'est le type d' | ||
+ | • QML : pour une application native sur Ubuntu (écrite en QML, qui est le méta-langage de Qt). | ||
+ | • Scopes : ils peuvent être écrits en différents langages et combinés avec des API. | ||
+ | |||
+ | |||
+ | **Webapp | ||
As an example, I’ll briefly cover how to create a webapp for opening the Full Circle Magazine site. | As an example, I’ll briefly cover how to create a webapp for opening the Full Circle Magazine site. | ||
• Create a new Webapp project | • Create a new Webapp project | ||
+ | |||
• Open < | • Open < | ||
- | • Edit the exec line to read: | ||
- | Exec=webapp-container --enable-back-forward --store-session-cookies --webappUrlPatterns=https?:// | ||
- | • Replace < | ||
- | The important step is the third one. Here you indicate the allowed URL patterns | + | • Edit the exec line to read: |
+ | • Replace < | ||
- | As you can see - creating a basic webapp is extremely simple. If you want to connect an account, you can either log in via the web interface (as normal) by setting the login page to the default URL (last URL in the Exec line). If you want to use the OnlineAccounts API, you’ll apparently need to use a fully-fledged HTML5 app. If the site you’re connecting to also offers an API, using an HTML5 app (and asking for credentials in settings), you should be able to connect via API as well. See the examples on the Ubuntu page for more details. | ||
- | QML App | + | Webapp |
- | I was planning on also including a QML app example here, but have faced various issues with translations and the make files required for compiling a QML app. Instead, I’m trying to fix the issues, so that I can hopefully cover QML apps in my next article. | + | En guise d' |
+ | • créez un nouveau projet Webapp ; | ||
+ | • ouvrez < | ||
+ | • éditez la ligne exec ainsi : exec=webapp-container --enable-back-forward --store-session-cookies --webappUrlPatterns=https?:< | ||
+ | • remplacez < | ||
- | Questions for readers | + | |
+ | **The important step is the third one. Here you indicate the allowed URL patterns - in this case we allow any https or http (< | ||
+ | |||
+ | As you can see - creating a basic webapp is extremely simple. If you want to connect an account, you can either log in via the web interface (as normal) by setting the login page to the default URL (last URL in the Exec line). If you want to use the OnlineAccounts API, you’ll apparently need to use a fully-fledged HTML5 app. If the site you’re connecting to also offers an API, using an HTML5 app (and asking for credentials in settings), you should be able to connect via API as well. See the examples on the Ubuntu page for more details.** | ||
+ | |||
+ | |||
+ | L' | ||
+ | |||
+ | Comme vous pouvez le voir, créer une webapp basique est extrêmement simple. Si vous voulez vous connecter à un compte, vous pouvez le faire via l' | ||
+ | |||
+ | **QML App | ||
+ | |||
+ | I was planning on also including a QML app example here, but have faced various issues with translations and the make files required for compiling a QML app. Instead, I’m trying to fix the issues, so that I can hopefully cover QML apps in my next article.** | ||
+ | |||
+ | Applications QML | ||
+ | |||
+ | J' | ||
+ | |||
+ | **Questions for readers | ||
Are there any Ubuntu phone apps you can’t live without? Or maybe there’s a particular style of app you’re curious about. Send me an email, and I will see if I can’t include an answer in my next article. | Are there any Ubuntu phone apps you can’t live without? Or maybe there’s a particular style of app you’re curious about. Send me an email, and I will see if I can’t include an answer in my next article. | ||
Ligne 32: | Ligne 62: | ||
In general - is there something you’d like to see more of from me in 2016? All answers can be emailed to: lswest34+fcm@gmail.com. | In general - is there something you’d like to see more of from me in 2016? All answers can be emailed to: lswest34+fcm@gmail.com. | ||
- | I hope everyone’s had a good year, and thank you for reading C&C! | + | I hope everyone’s had a good year, and thank you for reading C&C!** |
- | Further Reading | + | Questions aux lecteurs |
+ | |||
+ | Y a-t-il des applications pour téléphones Ubuntu sans lesquelles vous ne pourriez pas vivre ? Ou y a-t-il une catégorie d' | ||
+ | |||
+ | De manière générale, y a-t-il un sujet que vous souhaiteriez voir développé en 2016 ? Toutes vos réponses peuvent être envoyées à lswest34+fcm@gmail.com. | ||
+ | |||
+ | Je vous souhaite à tous une bonne année et je vous remercie d' | ||
+ | |||
+ | **Further Reading | ||
HTML5 apps: https:// | HTML5 apps: https:// | ||
Get started: https:// | Get started: https:// | ||
Webapp: https:// | Webapp: https:// | ||
QML Apps: https:// | QML Apps: https:// | ||
- | Scopes: https:// | + | Scopes: https:// |
+ | |||
+ | Lectures complémentaires | ||
+ | |||
+ | Applications HTML5 : https:// | ||
+ | Premiers pas : https:// | ||
+ | Webapp : https:// | ||
+ | Applications QML : https:// | ||
+ | Scopes : https:// |
issue104/c_c.1451324375.txt.gz · Dernière modification : 2015/12/28 18:39 de auntiee