Kehitys/oppikurssit/Qt4 Ruby-oppikurssi

From KDE TechBase
Revision as of 18:09, 22 August 2011 by Centerlink (talk | contribs) (Created page with "Siksi enin osa tekstistä tämän kappaleen jälkeen tulee suoraan heidän oppikurssistaan. Olen muokannut sitä silloin kun on välttämätöntä selventää Ruby-sidoksia, ja o...")
Other languages:


Tekijä: Darshan Ishaya, [email protected]

Alkuperäinen linkki:http://www.darshancomputing.com/qt4-qtruby-tutorial/

Qt®4 Ruby-oppikurssi

Tämä oppikurssi perehdyttää graafiseen käyttöliittymäohjelmointiin käyttäen Qt-työkalusarjaa, Ruby-kieltä, ja qt4-qtruby:a. Se on yksinkertainen siirros Nokian hienosta Qt-oppikurssista. Siksi enin osa tekstistä tämän kappaleen jälkeen tulee suoraan heidän oppikurssistaan. Olen muokannut sitä silloin kun on välttämätöntä selventää Ruby-sidoksia, ja olen järjestänyt uudelleen ja kirjoittanut uudelleen joitakin harvoja kappaleita tehdäkseni ne (toivon mukaan) hiukan selvemmäksi.

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

  1. Hello World!
  2. Calling it Quits
  3. Family Values
  4. Let There Be Widgets
  5. Building Blocks
  6. Building Blocks Galore!
  7. One Thing Leads to Another
  8. Preparing for Battle
  9. With Cannon You Can
  10. Smooth as Silk
  11. Giving It a Shot
  12. Hanging in the Air the Way Bricks Don't
  13. Game Over
  14. 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.