Development/Tutorials/Qt4 Ruby Tutorial: Difference between revisions
m (→Table of Contents: fixing a broken link to the examples) |
Aspotashev (talk | contribs) (add translate tags) |
||
Line 1: | Line 1: | ||
<languages /> | |||
{{Template:I18n/Language Navigation Bar|Development/Tutorials/Qt4 Ruby Tutorial}} | {{Template:I18n/Language Navigation Bar|Development/Tutorials/Qt4 Ruby Tutorial}} | ||
'' | <translate>''Author:'' [mailto:qt-tutorial@darshancomputing.com Darshan Ishaya, qt-tutorial@darshancomputing.com]</translate> | ||
<translate>''Original link:''http://www.darshancomputing.com/qt4-qtruby-tutorial/</translate> | |||
<translate> | |||
== Qt®4 Tutorial for Ruby == | == Qt®4 Tutorial for Ruby == | ||
</translate> | |||
<translate> | |||
This tutorial gives an introduction to GUI programming using the | This tutorial gives an introduction to GUI programming using the | ||
[http://qt.nokia.com Qt toolkit], | [http://qt.nokia.com Qt toolkit], | ||
[http://www.ruby-lang.org Ruby], and | [http://www.ruby-lang.org Ruby], and | ||
[http://rubyforge.org/projects/korundum/ qt4-qtruby]. | [http://rubyforge.org/projects/korundum/ qt4-qtruby]. | ||
</translate> | |||
<translate> | |||
It is simply a port of Nokia's fine | It is simply a port of Nokia's fine | ||
[http://doc.qt.nokia.com//4.2/tutorial.html Qt Tutorial]. | [http://doc.qt.nokia.com//4.2/tutorial.html Qt Tutorial]. | ||
Therefore, most of the text after this paragraph comes straight from their tutorial. | </translate> | ||
<translate> | |||
Therefore, most of the text after this paragraph comes straight from their tutorial. I have modified it as necessary to make it make sense with the Ruby bindings, and have rearranged or rewritten a few parts to make them (I hope) a bit clearer. | |||
This tutorial doesn't cover everything; the emphasis is on teaching the programming philosophy of GUI programming, and Qt's features are introduced as needed. Some commonly used features are never used in this tutorial. | This tutorial doesn't cover everything; the emphasis is on teaching the programming philosophy of GUI programming, and Qt's features are introduced as needed. Some commonly used features are never used in this tutorial. | ||
Line 19: | Line 27: | ||
If you're completely new to Qt, you might want to read [http://doc.qt.nokia.com/latest/how-to-learn-qt.html How to Learn Qt] if you haven't already done so. Keep in mind that like most documents about Qt, it is very C++ oriented. | If you're completely new to Qt, you might want to read [http://doc.qt.nokia.com/latest/how-to-learn-qt.html How to Learn Qt] if you haven't already done so. Keep in mind that like most documents about Qt, it is very C++ oriented. | ||
</translate> | |||
<translate> | |||
==Table of Contents== | ==Table of Contents== | ||
</translate> | |||
#[[Development/Tutorials/Qt4 Ruby Tutorial/Chapter 01|Hello World!]] | #[[Special:myLanguage/Development/Tutorials/Qt4 Ruby Tutorial/Chapter 01|<translate>Hello World!</translate>]] | ||
#[[Development/Tutorials/Qt4 Ruby Tutorial/Chapter 2|Calling it Quits]] | #[[Special:myLanguage/Development/Tutorials/Qt4 Ruby Tutorial/Chapter 2|<translate>Calling it Quits</translate>]] | ||
#[[Development/Tutorials/Qt4 Ruby Tutorial/Chapter 3|Family Values]] | #[[Special:myLanguage/Development/Tutorials/Qt4 Ruby Tutorial/Chapter 3|<translate>Family Values</translate>]] | ||
#[[Development/Tutorials/Qt4 Ruby Tutorial/Chapter 04|Let There Be Widgets]] | #[[Special:myLanguage/Development/Tutorials/Qt4 Ruby Tutorial/Chapter 04|<translate>Let There Be Widgets</translate>]] | ||
#[[Development/Tutorials/Qt4 Ruby Tutorial/Chapter 05|Building Blocks]] | #[[Special:myLanguage/Development/Tutorials/Qt4 Ruby Tutorial/Chapter 05|<translate>Building Blocks</translate>]] | ||
#[[Development/Tutorials/Qt4 Ruby Tutorial/Chapter 06|Building Blocks Galore!]] | #[[Special:myLanguage/Development/Tutorials/Qt4 Ruby Tutorial/Chapter 06|<translate>Building Blocks Galore!</translate>]] | ||
#[[Development/Tutorials/Qt4 Ruby Tutorial/Chapter 07|One Thing Leads to Another]] | #[[Special:myLanguage/Development/Tutorials/Qt4 Ruby Tutorial/Chapter 07|<translate>One Thing Leads to Another</translate>]] | ||
#[[Development/Tutorials/Qt4 Ruby Tutorial/Chapter 08|Preparing for Battle]] | #[[Special:myLanguage/Development/Tutorials/Qt4 Ruby Tutorial/Chapter 08|<translate>Preparing for Battle</translate>]] | ||
#[[Development/Tutorials/Qt4 Ruby Tutorial/Chapter 09|With Cannon You Can]] | #[[Special:myLanguage/Development/Tutorials/Qt4 Ruby Tutorial/Chapter 09|<translate>With Cannon You Can</translate>]] | ||
#[[Development/Tutorials/Qt4 Ruby Tutorial/Chapter 10|Smooth as Silk]] | #[[Special:myLanguage/Development/Tutorials/Qt4 Ruby Tutorial/Chapter 10|<translate>Smooth as Silk</translate>]] | ||
#[[Development/Tutorials/Qt4 Ruby Tutorial/Chapter 11|Giving It a Shot]] | #[[Special:myLanguage/Development/Tutorials/Qt4 Ruby Tutorial/Chapter 11|<translate>Giving It a Shot</translate>]] | ||
#[[Development/Tutorials/Qt4 Ruby Tutorial/Chapter 12|Hanging in the Air the Way Bricks Don't]] | #[[Special:myLanguage/Development/Tutorials/Qt4 Ruby Tutorial/Chapter 12|<translate>Hanging in the Air the Way Bricks Don't</translate>]] | ||
#[[Development/Tutorials/Qt4 Ruby Tutorial/Chapter 13|Game Over]] | #[[Special:myLanguage/Development/Tutorials/Qt4 Ruby Tutorial/Chapter 13|<translate>Game Over</translate>]] | ||
#[[Development/Tutorials/Qt4 Ruby Tutorial/Chapter 14|Facing the Wall]] | #[[Special:myLanguage/Development/Tutorials/Qt4 Ruby Tutorial/Chapter 14|<translate>Facing the Wall</translate>]] | ||
<translate> | |||
This little game doesn't look much like a modern GUI application. It uses some GUI techniques, but after you've worked through it, I recommend checking out the [http://doc.qt.nokia.com/latest/mainwindows-application.html Application] example, which presents a small GUI application with menus, tool bars, a status bar, and so on. There are quite a few very educational [http://doc.qt.nokia.com/latest/all-examples.html Examples]. They are all written in C++, but are easy enough to follow since the point of them is to demonstrate usage of the Qt library, not C++ features. | This little game doesn't look much like a modern GUI application. It uses some GUI techniques, but after you've worked through it, I recommend checking out the [http://doc.qt.nokia.com/latest/mainwindows-application.html Application] example, which presents a small GUI application with menus, tool bars, a status bar, and so on. There are quite a few very educational [http://doc.qt.nokia.com/latest/all-examples.html Examples]. They are all written in C++, but are easy enough to follow since the point of them is to demonstrate usage of the Qt library, not C++ features. | ||
</translate> | |||
<translate> | |||
[[Category:Ruby]] | [[Category:Ruby]] | ||
</translate> |
Revision as of 19:32, 1 July 2011
Development/Tutorials/Qt4 Ruby Tutorial
Languages: عربي | Asturianu | Català | Česky | Kaszëbsczi | Dansk | Deutsch | English | Esperanto | Español | Eesti | فارسی | Suomi | Français | Galego | Italiano | 日本語 | 한국어 | Norwegian | Polski | Português Brasileiro | Română | Русский | Svenska | Slovenčina | Slovenščina | српски | Türkçe | Tiếng Việt | Українська | 简体中文 | 繁體中文
Author: Darshan Ishaya, [email protected]
Original link:http://www.darshancomputing.com/qt4-qtruby-tutorial/
Qt®4 Tutorial for Ruby
This tutorial gives an introduction to GUI programming using the Qt toolkit, Ruby, and qt4-qtruby. It is simply a port of Nokia's fine Qt Tutorial. Therefore, most of the text after this paragraph comes straight from their tutorial. I have modified it as necessary to make it make sense with the Ruby bindings, and have rearranged or rewritten a few parts to make them (I hope) a bit clearer.
This tutorial doesn't cover everything; the emphasis is on teaching the programming philosophy of GUI programming, and Qt's features are introduced as needed. Some commonly used features are never used in this tutorial.
Chapter one starts with a minimal "Hello world" program and the following chapters introduce new concepts. By Chapter 14, the "Hello world" program from Chapter 1 will have turned into a 448-line game.
If you're completely new to Qt, you might want to read How to Learn Qt if you haven't already done so. Keep in mind that like most documents about Qt, it is very C++ oriented.
Table of Contents
- Hello World!
- Calling it Quits
- Family Values
- Let There Be Widgets
- Building Blocks
- Building Blocks Galore!
- One Thing Leads to Another
- Preparing for Battle
- With Cannon You Can
- Smooth as Silk
- Giving It a Shot
- Hanging in the Air the Way Bricks Don't
- Game Over
- Facing the Wall
This little game doesn't look much like a modern GUI application. It uses some GUI techniques, but after you've worked through it, I recommend checking out the Application example, which presents a small GUI application with menus, tool bars, a status bar, and so on. There are quite a few very educational Examples. They are all written in C++, but are easy enough to follow since the point of them is to demonstrate usage of the Qt library, not C++ features.