• Skip to content
  • Skip to link menu
Trinity API Reference
  • Trinity API Reference
  • kded
 

kded

  • kded
kmimelist.cpp
1 #include <ktrader.h>
2 #include <kservice.h>
3 #include <kmimetype.h>
4 #include <assert.h>
5 #include <kstandarddirs.h>
6 #include <kservicegroup.h>
7 #include <kimageio.h>
8 #include <kuserprofile.h>
9 #include <kprotocolinfo.h>
10 
11 #include <kapplication.h>
12 
13 #include <stdio.h>
14 
15 int main(int argc, char *argv[])
16 {
17  KApplication k(argc,argv,"blurb",false);
18 
19  KMimeType::List mtl = KMimeType::allMimeTypes( );
20  assert( mtl.count() );
21  qDebug( "Found %d mime types.", mtl.count() );
22  TQValueListIterator<KMimeType::Ptr> it(mtl.begin());
23  KServiceTypeProfile::OfferList ol;
24 
25  for (; it != mtl.end(); ++it)
26  {
27  {
28  // Application
29  printf( "APP:%s:", (*it)->name().latin1() );
30  ol = KServiceTypeProfile::offers((*it)->name(), "Application");
31  TQValueListIterator<KServiceOffer> it2(ol.begin());
32  for (; it2 != ol.end(); ++it2) {
33  if ((*it2).allowAsDefault())
34  printf( " %s", (*it2).service()->desktopEntryPath().ascii() );
35 
36  }
37  printf( "\n" );
38  }
39 
40  {
41  // Embedded
42  printf( "PART:%s:", (*it)->name().latin1() );
43  ol = KServiceTypeProfile::offers((*it)->name(), "KParts/ReadOnlyPart");
44  TQValueListIterator<KServiceOffer> it2(ol.begin());
45  for (; it2 != ol.end(); ++it2) {
46  if ((*it2).allowAsDefault())
47  printf( " %s", (*it2).service()->desktopEntryPath().ascii() );
48 
49  }
50  printf( "\n" );
51  }
52  }
53 }
54 

kded

Skip menu "kded"
  • Main Page
  • Alphabetical List
  • Class List
  • File List
  • Class Members
  • Related Pages

kded

Skip menu "kded"
  • arts
  • dcop
  • dnssd
  • interfaces
  •     interface
  •     library
  •   kspeech
  •   ktexteditor
  • kabc
  • kate
  • kcmshell
  • kdecore
  • kded
  • kdefx
  • kdeprint
  • kdesu
  • kdeui
  • kdoctools
  • khtml
  • kimgio
  • kinit
  • kio
  •   bookmarks
  •   httpfilter
  •   kfile
  •   kio
  •   kioexec
  •   kpasswdserver
  •   kssl
  • kioslave
  •   http
  • kjs
  • kmdi
  •   kmdi
  • knewstuff
  • kparts
  • krandr
  • kresources
  • kspell2
  • kunittest
  • kutils
  • kwallet
  • libkmid
  • libkscreensaver
Generated for kded by doxygen 1.8.6
This website is maintained by Timothy Pearson.
KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. |