KdeDevQ&A

App Developer Week -- KDE Development Intro: Q+A -- apachelogger & Riddell -- Mon, Apr 12th, 2011

   1 [20:01] <ClassBot> Logs for this session will be available at http://irclogs.ubuntu.com/2011/04/12/%23ubuntu-classroom.html following the conclusion of the session.
   2 [20:05] <dpm> hey everyone, we're up for a slight change of schedule on the next session
   3 [20:05] <dpm> First of all a big applause to jderose for a great session
   4 [20:06] <dpm> Originally we scheduled a talk on writing KDE applications with KdeAppTemplate
   5 [20:06] <dpm> but the speaker could not make it this time
   6 [20:06] <dpm> however...
   7 [20:07] <dpm> fear not, we've got some cool KDE topics as a replacement for you
   8 [20:07] <dpm> Please welcome apachelogger and Riddell, who are going to do a quick intro and Q+A session on how to get started with KDE development
   9 [20:08] <dpm> All yours apachelogger and Riddell!
  10 [20:08] <apachelogger> thank you dpm
  11 [20:08] <apachelogger> hi everyone
  12 [20:08] <dpm> (And everyone, line up your questions on #ubuntu-classroom-chat!)
  13 [20:08] <apachelogger> so, this session is highly dependent on your questions, the more you ask the better :)
  14 [20:10] <apachelogger> One of the best resources for KDE development related topics is the KDE techbase
  15 [20:10] <apachelogger> http://techbase.kde.org/
  16 [20:10] <apachelogger> you can find just about anything there
  17 [20:10] <ClassBot> dpm asked: which tools do you recommend for getting started developing KDE applications?
  18 [20:11] <apachelogger> It really depends on what you personally prefer. If you like IDEs there are 2 KDE (and Qt) centric ones. Namely KDevelop and QtCreator.
  19 [20:11] <apachelogger> They are both very powerful and easy to use.
  20 [20:12] <apachelogger> Of course you can also use any editor and command line tools :)
  21 [20:12] <ClassBot> bulldog98_konv asked: whom to poke to get help?
  22 [20:12] <apachelogger> No one :P
  23 [20:12] <apachelogger> Usually it is best to just go to #kde-devel and ask your question
  24 [20:13] <Riddell> kate is great for development without being filled with options
  25 [20:13] <apachelogger> Most of the time someone will be around to answer it.
  26 [20:13] <Riddell> the kde-devel mailing list is also good for questions
  27 [20:13] <apachelogger> If that fails there is also a mailing list kde-devel@kde.org :)
  28 [20:13] <Riddell> if you already have some code then reviewboard.kde.org is the place to post it to get feedback
  29 [20:13] <ClassBot> styx_ asked: Which language is recommended? Can i use java?
  30 [20:14] <apachelogger> Good question indeed. As with Qt itself, one can write applications in a number of languages.
  31 [20:14] <apachelogger> C++ being the (most) native language, but also Ruby, Python and C# are options
  32 [20:15] <apachelogger> There used to be Java bindings but I think they disappeared (actually I believe they are just unmaintained, so if someone wants to pick that up... I am sure there are plenty of people who would love to write KDE magic in Java :))
  33 [20:15] <Riddell> I'm a big fan of Python
  34 [20:15] <Riddell> PyQt is well maintained and supported, PyKDE is popular and easy to use
  35 [20:16] <Riddell> and none of the caring about memory stuff you get in C++
  36 [20:16] <Riddell> although it can be easier to trip yourself up since there's no compiler to check all the syntax
  37 [20:16] <apachelogger> Also a number of Kubuntu and KDE tools are written in PyKDE.
  38 [20:16] <apachelogger> Like the Kubuntu installer, or the KDE print applet
  39 [20:17] <ClassBot> bulldog98_konv asked: is kparts recomended for a new application or should I try not to use them?
  40 [20:17] <apachelogger> That is a very good question indeed. For all those that do not know what a kpart is .... simply put it is a GUI plugin
  41 [20:18] <Riddell> Nokia dropped funding for the Java bindings so they're unmaintained indeed
  42 [20:18] <apachelogger> For example the HTML view frame of Konqueror is a KPart and as such could be easily integrated into any application (without build time dependency on it).
  43 [20:19] <apachelogger> So, while KParts are very powerful, as they move a couple of build time decisions to runtime, they are also a bit of a complicated thing.
  44 [20:19] <apachelogger> My advise is to think carefully about the advantages.
  45 [20:19] <apachelogger> If you have none, you should not use a kpart.
  46 [20:20] <Riddell> most applications don't need KParts, I remember when I was developing Umbrello we'd get occational suggestions to turn it into a KPart but nobody could tell us why it was just a buzz word
  47 [20:20] <apachelogger> yeah
  48 [20:20] <Riddell> but they're great for e.g. rekonq where you can embed okular to read PDFs or Calligra where you can embed a spreadsheet in a word processing document
  49 [20:20] <apachelogger> Creating a kpart is pretty easy, so turning things into a kpart as a use case arises is mostly no problem (given appropriate code design ;))
  50 [20:21] <ClassBot> bulldog98_konv asked: is it also possible to develop in JavaScript like Plasmoids?
  51 [20:21] <apachelogger> I do not think you can write actual applications in javascript (not yet).
  52 [20:22] <Riddell> you can consider QML a form of javascript and write in that
  53 [20:22] <apachelogger> However, as Qt recently grew new GUI magic called QML (which is based on JavasScript) it is entirely possible that in the not too far future you can indeed create apps using javascript.
  54 [20:22] <apachelogger> At this point if you were using QML you would not have the desktop integration advantages that KDE has over Qt-only software.
  55 [20:23] <apachelogger> though, generally you can do it already as Riddell suggested
  56 [20:23] <ClassBot> sera10 asked: what is the state of QT/KDE integration into the Gnome desktop? (gstreamer, notifications, unity, ...)
  57 [20:23] <apachelogger> Now, this might sounds silly ... but it is spelled Qt, and pronnouced "cute" :)
  58 [20:24] <apachelogger> Qt (and thus KDE) can visually integrate into GNOME/GTK+ such as that you would not notice they are not actually GTK applications
  59 [20:25] <apachelogger> http://labs.qt.nokia.com/2008/09/05/qgtkstyle-now-part-of-qt/
  60 [20:25] <Riddell> that's a nice feature of Qt, it goes out of its way to integrate with gnome.  I wish the equivalent was true with GTK
  61 [20:26] <apachelogger> KDE and Canonical are working together on the notification API, unfortunately GNOME itself is not contributing to the effort (not yet anyway).
  62 [20:26] <apachelogger> sera10: I hope this answers the question more or less, if not please ask more precisely :)
  63 [20:26] <ClassBot> dpm asked: we've heard a lot about introspection in the GNOME world in this App Developer Week (GObject Introspection, PyGI, etc.). Is there any similar move planned in the KDE world?
  64 [20:27] <Riddell> KDE's Plasma team created the status notifier spec to replace the old systray protocol, that got adopted by Canonical for Unity where it's called app indicators
  65 [20:27] <Riddell> Canonical also worked on the dbus menu spec which it helped bring to KDE, so that's some nice cross desktop work
  66 [20:28] <apachelogger> I am not particularly aware of what GObject Introspection is
  67 [20:28] <apachelogger> Riddell: do you know?
  68 [20:28] <Riddell> gstreamer is a library for audio and video, nothing directly to do with the desktop, it's used by gnome applications and is a backend to Qt's multimedia API Phonon, so that's shared too
  69 [20:29] <apachelogger> Ah, so regarding GObject introspection :D ... https://wiki.ubuntu.com/MeetingLogs/appdevweek1104/GObjectIntrospection
  70 [20:29] <Riddell> notifications have had a shared spec for a while, canonical changed that a bit by removing action from it which has since been picked up by KDE so its notifications work when running on unity
  71 [20:29] <apachelogger> reading the first 3 lines I can say, KDE has sort of such a thing
  72 [20:29] <Riddell> Qt has had introspection for over 15 years, I'm glad that gtk is catching up :)
  73 [20:30] <apachelogger> it is called smoke and basically responsible for generating almost all available KDE language bindings
  74 [20:30] <Riddell> when you compile Qt code the classes get read through a programme called moc which adds introspection, signals/slots and other handy features
  75 [20:32] <apachelogger> http://quickgit.kde.org/?p=smokegen.git&a=summary <-- smoke is actually based on C++, thus faster than runtime introspection which is what QObjects (the Qt object type) have
  76 [20:33] <ClassBot> dpm asked: what are the main technologies I should know about if I want to get started developing in KDE?
  77 === seidos is now known as saytwo
  78 [20:33] <apachelogger> You will of course have to know the language you want to program in :)
  79 [20:34] <apachelogger> Additionally some basic stuff about Qt (such as signals and slots).
  80 [20:34] <apachelogger> http://doc.qt.nokia.com/4.7/signalsandslots.html
  81 [20:35] <apachelogger> Other than that I can't think of much you would need to know really.
  82 [20:35] <apachelogger> Riddell: anything you would like to add?
  83 [20:35] <Riddell> well it depends on what you want to code of course
  84 [20:35] <Riddell> if you want to code plasmoids then you need to know the plasma widgets
  85 [20:36] <Riddell> if you're using traditional widgets you want to know about designer to create the UI and the main classes from QtCore and QtGUI to do stuff with them
  86 [20:36] <Riddell> then you probably want to look at some of the KDE classes which add and improve on the Qt ones
  87 [20:37] <Riddell> Qt has many good tutorials on its docs site and there's plenty of KDE ones on techbase
  88 [20:37] <ClassBot> sera10 asked: How should I make an app that integrates in both the KDE and the Gnome environment, regarding menu integration, notifications, default applications registered with mime-types, etc. ?
  89 [20:38] <apachelogger> Depends on the menu you mean, if you mean the application menus, then that is actually a specification from freedesktop.org and implemented in both KDE and GNOME alike, so as long as you obey the spec you are good.
  90 [20:39] <apachelogger> http://standards.freedesktop.org/desktop-entry-spec/latest/
  91 === EvilPhoenix is now known as TheEvilPhoenix
  92 [20:40] <apachelogger> If you mean the in-application menu (which for example is dragged out of the application in Unity, then you need to be in luck currently. Generally on Ubuntu all GTK apps can do that in KDE and all Qt apps (including KDE ones) can do it in Unity.
  93 [20:40] <apachelogger> On other distributions it might or might not work equally well.
  94 === saytwo is now known as kevin4896
  95 [20:41] <apachelogger> default applications registered with mimetypes is part of the aforementioned desktop entry spec (in addition KDE has an overriding initial priority system, as KDE in general supports a couple more keys outlined by this specification)
  96 [20:43] <apachelogger> Any more questions?
  97 [20:44] <apachelogger> Very useful resources for development using the KDE platform: tutorials: http://techbase.kde.org/Development/Tutorials the API documentat: http://api.kde.org/ Qt documentation and examples: http://doc.qt.nokia.com/4.7/index.html
  98 [20:44] <Riddell> KDE is an exciting community to be in just now, you can read on planet.kde.org about Plasma Active which is the new inititive to take KDE software to all sorts of devices
  99 [20:45] <Riddell> and with innovative technologies like Nepomuk and Akonadi finally coming to fruition there's a lot of nice features becoming available and useable
 100 [20:46] <Riddell> and it's pleasingly stable to use as a developer and user, no rewrites are happening underneith you
 101 [20:47] <ClassBot> sera10 asked: regarding Nepomuk, is there a standard spec for search in the works?
 102 [20:47] <apachelogger> I do not think so.
 103 [20:49] <apachelogger> I would imagine breaking search API down to a common denominator would be rather crippling, usually if you want to do search in an application you do not only want to search some random file on the user's file system
 104 [20:50] <apachelogger> at least I could not imagine a use case for that :)
 105 [20:50] <ClassBot> bulldog98_konv asked: what’s about the exapmels module?
 106 [20:50] <apachelogger> I suppose you mean http://quickgit.kde.org/?p=kdeexamples.git&a=summary
 107 [20:51] <apachelogger> which is indeed a very great resource of examples regarding KDE and KDE related technologies.
 108 [20:51] <ClassBot> There are 10 minutes remaining in the current session.
 109 [20:51] <apachelogger> like attica, which is a library for the open collaboration service
 110 [20:51] <apachelogger> http://freedesktop.org/wiki/Specifications/open-collaboration-services
 111 [20:52] <apachelogger> And as I mentioned earlier, the KDE techbase simply contains everything you would want to know.
 112 [20:52] <apachelogger> For example how to contribute to the KDE community: http://techbase.kde.org/Contribute
 113 [20:53] <apachelogger> Which is a worthwhile effort really :)
 114 [20:54] <apachelogger> With 6 minutes left in this session.... any final questions?
 115 [20:55] <ClassBot> bulldog98_konv asked: is DesktopSummit worth coming to learn about KDE and KDE programming?
 116 [20:55] <apachelogger> maybe
 117 [20:56] <ClassBot> There are 5 minutes remaining in the current session.
 118 [20:56] <apachelogger> There are 2 days of talks, which are worthwhile if you already have an idea about Qt and KDE
 119 [20:57] <Riddell> desktop summit is more about getting involved in the community, knowing who all the faces are, and working on ideas for future development
 120 [20:57] <apachelogger> going there without knowing anything about it is probably a waste of time though .... except you are bound to meet interesting, nice and possibly even famous people (somtimes they are even all 3 of them, such as Riddell :*)
 121 [20:58]  * Riddell bats eyelids at apachelogger 
 122 [20:58] <apachelogger> Well.
 123 [20:59] <apachelogger> Thanks everyone for coming and have fun developing awesome new KDE software :D
 124 [20:59] <Riddell> I belive m_conley is up in a few minutes
 125 [20:59] <Riddell> Thunderbird + Unity = Awesome, and How JCStypes Lets You Get to the Candy
 126 [21:00] <apachelogger> Next up is Mike Conley telling us about Thunderbird and Unity and how the combination of them results in pure awesomeness :)

MeetingLogs/appdevweek1104/KdeDevQ&A (last edited 2011-04-13 07:33:18 by 178)