19 #include "tdesycoca.h"
20 #include "tdesycocadict.h"
21 #include "kresourcelist.h"
23 #include <tdeglobal.h>
24 #include <kstandarddirs.h>
26 #include <tdelocale.h>
29 #include <kimageiofactory.h>
30 #include <kbuildimageiofactory.h>
35 m_resourceList =
new KSycocaResourceList();
36 m_resourceList->add(
"services",
"*.kimgio" );
43 return TQStringList() <<
"services";
46 KBuildImageIOFactory::~KBuildImageIOFactory()
48 delete m_resourceList;
54 TQString fullPath = locate( resource, file);
56 KImageIOFormat *format =
new KImageIOFormat(fullPath);
61 KBuildImageIOFactory::addEntry(KSycocaEntry *newEntry,
const char *resource)
63 KSycocaFactory::addEntry(newEntry, resource);
65 KImageIOFormat *format = (KImageIOFormat *) newEntry;
66 rPath += format->rPaths;
72 for( KImageIOFormatList::ConstIterator it = formatList->begin();
73 it != formatList->end();
76 KImageIOFormat *_format = (*it);
77 if (format->mType == _format->mType)
85 formatList->append( format );
92 KSycocaFactory::saveHeader(str);
94 str << mReadPattern << mWritePattern << rPath;
103 for(TQStringList::Iterator it = rPath.begin();
106 TQStringList::Iterator it2 = it++;
117 mReadPattern = createPattern( KImageIO::Reading );
118 mWritePattern = createPattern( KImageIO::Writing );
120 KSycocaFactory::save(str);
KBuildImageIOFactory()
Create factory.
virtual void save(TQDataStream &str)
Write out service type specific index files.
static TQStringList resourceTypes()
Returns all resource types for this service factory.
virtual KSycocaEntry * createEntry(const TQString &, const char *)
Create new entry.
virtual void saveHeader(TQDataStream &)
Save header info to database.