summaryrefslogtreecommitdiffstats
path: root/languages/cpp/app_templates/kateplugin
diff options
context:
space:
mode:
authortoma <toma@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2009-11-25 17:56:58 +0000
committertoma <toma@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2009-11-25 17:56:58 +0000
commit114a878c64ce6f8223cfd22d76a20eb16d177e5e (patch)
treeacaf47eb0fa12142d3896416a69e74cbf5a72242 /languages/cpp/app_templates/kateplugin
downloadtdevelop-114a878c64ce6f8223cfd22d76a20eb16d177e5e.tar.gz
tdevelop-114a878c64ce6f8223cfd22d76a20eb16d177e5e.zip
Copy the KDE 3.5 branch to branches/trinity for new KDE 3.5 features.
BUG:215923 git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdevelop@1054174 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'languages/cpp/app_templates/kateplugin')
-rw-r--r--languages/cpp/app_templates/kateplugin/.kdev_ignore0
-rw-r--r--languages/cpp/app_templates/kateplugin/Makefile.am19
-rw-r--r--languages/cpp/app_templates/kateplugin/hi16-action-plugin.pngbin0 -> 292 bytes
-rw-r--r--languages/cpp/app_templates/kateplugin/hi22-action-plugin.pngbin0 -> 1151 bytes
-rw-r--r--languages/cpp/app_templates/kateplugin/kateplugin.kdevtemplate213
-rw-r--r--languages/cpp/app_templates/kateplugin/kateplugin.pngbin0 -> 12901 bytes
-rw-r--r--languages/cpp/app_templates/kateplugin/plugin.desktop76
-rw-r--r--languages/cpp/app_templates/kateplugin/plugin.kdevelop113
-rw-r--r--languages/cpp/app_templates/kateplugin/plugin_app.cpp89
-rw-r--r--languages/cpp/app_templates/kateplugin/plugin_app.h49
-rw-r--r--languages/cpp/app_templates/kateplugin/plugin_app.rc11
-rw-r--r--languages/cpp/app_templates/kateplugin/src-Makefile.am20
-rw-r--r--languages/cpp/app_templates/kateplugin/subdirs3
13 files changed, 593 insertions, 0 deletions
diff --git a/languages/cpp/app_templates/kateplugin/.kdev_ignore b/languages/cpp/app_templates/kateplugin/.kdev_ignore
new file mode 100644
index 00000000..e69de29b
--- /dev/null
+++ b/languages/cpp/app_templates/kateplugin/.kdev_ignore
diff --git a/languages/cpp/app_templates/kateplugin/Makefile.am b/languages/cpp/app_templates/kateplugin/Makefile.am
new file mode 100644
index 00000000..62da4d60
--- /dev/null
+++ b/languages/cpp/app_templates/kateplugin/Makefile.am
@@ -0,0 +1,19 @@
+templateName = kateplugin
+dataFiles = src-Makefile.am plugin_app.cpp plugin_app.h\
+ plugin_app.rc hi16-action-plugin.png \
+ hi22-action-plugin.png kateplugin.png \
+ plugin.kdevelop subdirs plugin.desktop
+
+### no need to change below:
+template_DATA = $(templateName).kdevtemplate
+templatedir = ${appwizarddatadir}/templates
+
+appwizarddatadir = ${kde_datadir}/kdevappwizard
+$(templateName).tar.gz: ${dataFiles}
+ $(TAR) -cf $(templateName).tar -C $(srcdir) ${dataFiles}
+ $(GZIP_COMMAND) -f9 $(templateName).tar
+
+archivedir = ${appwizarddatadir}
+archive_DATA = $(templateName).tar.gz ${templateName}.png
+
+CLEANFILES = *.tar.gz \ No newline at end of file
diff --git a/languages/cpp/app_templates/kateplugin/hi16-action-plugin.png b/languages/cpp/app_templates/kateplugin/hi16-action-plugin.png
new file mode 100644
index 00000000..e2d7bab8
--- /dev/null
+++ b/languages/cpp/app_templates/kateplugin/hi16-action-plugin.png
Binary files differ
diff --git a/languages/cpp/app_templates/kateplugin/hi22-action-plugin.png b/languages/cpp/app_templates/kateplugin/hi22-action-plugin.png
new file mode 100644
index 00000000..4082bf10
--- /dev/null
+++ b/languages/cpp/app_templates/kateplugin/hi22-action-plugin.png
Binary files differ
diff --git a/languages/cpp/app_templates/kateplugin/kateplugin.kdevtemplate b/languages/cpp/app_templates/kateplugin/kateplugin.kdevtemplate
new file mode 100644
index 00000000..767a0a57
--- /dev/null
+++ b/languages/cpp/app_templates/kateplugin/kateplugin.kdevtemplate
@@ -0,0 +1,213 @@
+# KDE Config File
+[General]
+Name=Kate plugin
+Name[br]=Lugent Kate
+Name[ca]=Connector per a Kate
+Name[de]=Kate-Modul
+Name[el]=Πρόσθετο Kate
+Name[es]=Complemento para Kate
+Name[eu]=Kate plugina
+Name[fa]=وصلۀ Kate
+Name[fr]=Module externe pour Kate
+Name[ga]=Breiseán Kate
+Name[gl]=Extensión para Kate
+Name[hu]=Kate-bővítőmodul
+Name[it]=Plugin per Kate
+Name[ja]=Kate プラグイン
+Name[nds]=Kate-Moduul
+Name[ne]=केट प्लगइन
+Name[nl]=Kate-plugin
+Name[pl]=Wtyczka do Kate
+Name[pt]='Plugin' do Kate
+Name[pt_BR]='Plugin' do Kate
+Name[ru]=Модуль Kate
+Name[sk]=Kate modul
+Name[sl]=Vstavek za Kate
+Name[sr]=Прикључак за Kate
+Name[sr@Latn]=Priključak za Kate
+Name[sv]=Kate-insticksprogram
+Name[tr]=Kate eklentisi
+Name[zh_CN]=Kate 插件
+Name[zh_TW]=Kate 外掛程式
+Icon=kateplugin.png
+Category=C++/KDE
+Comment=Generates a plugin for Kate the text editor.
+Comment[ca]=Genera un connector per a l'editor de text Kate.
+Comment[da]=Genererer et plugin for teksteditoren kate
+Comment[de]=Erstellt ein Modul für den Texteditor Kate
+Comment[el]=Δημιουργεί ένα πρόσθετο για το Kate τον επεξεργαστή κειμένου.
+Comment[es]=Genera un complemento para el editor de texto Kate.
+Comment[et]=Plugina loomine tekstiredaktorile Kate.
+Comment[eu]=Plugin bat sortzen du Kate testu-editorearentzat.
+Comment[fa]=وصله‌ای برای ویرایشگر متن Kate تولید می‌کند.
+Comment[fr]=Génère un module externe pour l'éditeur de texte Kate.
+Comment[ga]=Cruthaíonn sé seo breiseán le haghaidh eagarthóir téacs Kate.
+Comment[gl]=Xera unha extensión para o editor de textos Kate.
+Comment[hu]=Létrehoz egy bővítőmodult a Kate szövegszerkesztőhöz.
+Comment[it]=Genera un plugin per l'editor di testo Kate.
+Comment[ja]=Kate テキストエディタのためのプラグインを作成します
+Comment[nds]=Stellt en Moduul för den Texteditor "Kate" op.
+Comment[ne]=केट पाठ सम्पादकका लागि प्लगइन उत्पन्न गर्दछ ।
+Comment[nl]=Genereert een plugin voor de Kate-teksteditor
+Comment[pl]=Generuje wtyczkę do edytora tekstu Kate
+Comment[pt]=Gera um 'plugin' para o Kate, o editor de texto.
+Comment[pt_BR]=Gera um 'plugin' para o Kate, o editor de texto.
+Comment[ru]=Создание модуля для текстового редактора Kate.
+Comment[sk]=Vygeneruje modul pre textový editor Kate.
+Comment[sl]=Ustvari vstavek za urejevalnik besedil Kate.
+Comment[sr]=Прави прикључак за уређивач текста Kate.
+Comment[sr@Latn]=Pravi priključak za uređivač teksta Kate.
+Comment[sv]=Skapar ett insticksprogram för texteditorn Kate.
+Comment[tr]=Kate metin düzenleyicisi için bir eklenti yaratır.
+Comment[zh_CN]=生成 Kate 文本编辑器的插件。
+Comment[zh_TW]=產生一個 Kate 文字編輯器的外掛程式
+FileTemplates=h,CStyle,cpp,CStyle
+ShowFilesAfterGeneration=%{dest}/src/plugin_%{APPNAMELC}.cpp
+Archive=kateplugin.tar.gz
+
+[ADMIN]
+Type=include
+File=%{kdevelop}/template-common/admin.kdevtemplate
+
+[GNU]
+Type=include
+File=%{kdevelop}/template-common/gnu.kdevtemplate
+
+[MKDIR_DOCBOOK1]
+Type=mkdir
+Dir=%{dest}/doc
+
+[MKDIR_DOCBOOK2]
+Type=mkdir
+Dir=%{dest}/doc/en
+
+[FILE1]
+Type=install
+Source=%{kdevelop}/template-common/kde-doc-Makefile.am
+Dest=%{dest}/doc/Makefile.am
+
+[FILE2]
+Type=install
+Source=%{kdevelop}/template-common/kde-doc-en-Makefile.am
+Dest=%{dest}/doc/en/Makefile.am
+
+[FILE3]
+Type=install
+EscapeXML=true
+Source=%{kdevelop}/template-common/kde-index.docbook
+Dest=%{dest}/doc/en/index.docbook
+
+[FILE4]
+Type=install
+EscapeXML=true
+Source=%{src}/plugin.kdevelop
+Dest=%{dest}/%{APPNAMELC}.kdevelop
+
+[FILE5]
+Type=install
+Source=%{kdevelop}/template-common/kde-Makefile.cvs
+Dest=%{dest}/Makefile.cvs
+
+[FILE6]
+Type=install
+Source=%{kdevelop}/template-common/kde-Makefile.am
+Dest=%{dest}/Makefile.am
+
+[FILE7]
+Type=install
+Source=%{kdevelop}/template-common/kde-configure.in.in
+Dest=%{dest}/configure.in.in
+
+[MkDir3]
+Type=mkdir
+Dir=%{dest}/src
+
+[FILE8]
+Type=install
+Source=%{kdevelop}/template-common/kde-app.lsm
+Dest=%{dest}/src/%{APPNAMELC}.lsm
+
+[MkDir4]
+Type=mkdir
+Dir=%{dest}/po
+
+[FILE9]
+Type=install
+Source=%{kdevelop}/template-common/kde-po-Makefile.am
+Dest=%{dest}/po/Makefile.am
+
+[FILE10]
+Type=install
+Source=%{src}/subdirs
+Dest=%{dest}/subdirs
+
+[FILE11]
+Type=install
+Source=%{src}/src-Makefile.am
+Dest=%{dest}/src/Makefile.am
+
+[FILE12]
+Type=install
+Source=%{src}/plugin.desktop
+Dest=%{dest}/src/%{APPNAMELC}.desktop
+
+[FILE13]
+Type=install
+Source=%{src}/plugin_app.cpp
+Dest=%{dest}/src/plugin_%{APPNAMELC}.cpp
+
+[FILE14]
+Type=install
+Source=%{src}/plugin_app.h
+Dest=%{dest}/src/plugin_%{APPNAMELC}.h
+
+[FILE15]
+Type=install
+EscapeXML=true
+Source=%{src}/plugin_app.rc
+Dest=%{dest}/src/plugin_%{APPNAMELC}.rc
+
+[FILE16]
+Type=install
+Source=%{src}/hi16-action-plugin.png
+Dest=%{dest}/src/hi16-action-plugin.png
+Process=false
+
+[FILE17]
+Type=install
+Source=%{src}/hi22-action-plugin.png
+Dest=%{dest}/src/hi32-action-plugin.png
+Process=false
+
+[MSG]
+Type=message
+Comment=A plugin for Kate was created at %{dest}
+Comment[ca]=Un connector per a Kate ha estat creat a %{dest}
+Comment[da]=Et plugin for Kate blev oprettet på %{dest}
+Comment[de]=Ein Modul für Kate wurde in %{dest} erstellt.
+Comment[el]=Ένα πρόσθετο για το Kate δημιουργήθηκε στο %{dest}
+Comment[es]=Un complemento para Kate ha sido creado en %{dest}
+Comment[et]=Kate plugin loodi asukohta %{dest}
+Comment[eu]=Kate plugin bat sortu da hemen: %{dest}
+Comment[fa]=وصله‌ای برای Kate در %{dest} ایجاد شد
+Comment[fr]=Un module externe pour Kate a été créé dans %{dest}
+Comment[ga]=Cruthaíodh breiseán Kate ag %{dest}
+Comment[gl]=Creouse unha extensión para Kate en %{dest}
+Comment[hu]=Létrejött egy Kate-bővítőmodul itt: %{dest}
+Comment[it]=È stato creato un plugin per Kate in %{dest}
+Comment[ja]=Kate のプラグインを %{dest} に作成しました
+Comment[nds]=In %{dest} wöör en Moduul för "Kate" opstellt
+Comment[ne]=केटका लागि प्लगइन %{dest} मा सिर्जना गरियो
+Comment[nl]=Een plugin voor Kate is aangemaakt in %{dest}
+Comment[pl]=Wtyczka dla Kate została utworzona w %{dest}
+Comment[pt]=Foi criado um 'plugin' para o Kate em %{dest}
+Comment[pt_BR]=Foi criado um 'plugin' para o Kate em %{dest}
+Comment[ru]=Модуль Kate создан в %{dest}
+Comment[sk]=Modul pre Kate bol vytvorený v %{dest}
+Comment[sl]=Vstavek za Kate je bil ustvarjen v %{dest}
+Comment[sr]=Прикључак за Kate направљен је у %{dest}
+Comment[sr@Latn]=Priključak za Kate napravljen je u %{dest}
+Comment[sv]=Ett insticksprogram för Kate skapades i %{dest}
+Comment[tr]=Kate için bir eklenti %{dest} içinde yaratıldı.
+Comment[zh_CN]=在 %{dest} 中创建了一个 Kate 的插件
+Comment[zh_TW]=一個 Kate 外掛程式已建立於 %{dest}
diff --git a/languages/cpp/app_templates/kateplugin/kateplugin.png b/languages/cpp/app_templates/kateplugin/kateplugin.png
new file mode 100644
index 00000000..b442a706
--- /dev/null
+++ b/languages/cpp/app_templates/kateplugin/kateplugin.png
Binary files differ
diff --git a/languages/cpp/app_templates/kateplugin/plugin.desktop b/languages/cpp/app_templates/kateplugin/plugin.desktop
new file mode 100644
index 00000000..761ac763
--- /dev/null
+++ b/languages/cpp/app_templates/kateplugin/plugin.desktop
@@ -0,0 +1,76 @@
+[Desktop Entry]
+Type=Service
+ServiceTypes=Kate/Plugin
+X-KDE-Library=lib%{APPNAMELC}plugin
+X-Kate-Version=2.2
+Name=My First Kate Plugin
+Name[br]=Ma lugent Kate kentañ
+Name[ca]=El meu primer connector per a Kate
+Name[cy]=F'ategyn cyntaf Kate
+Name[da]=Mit første Kate plugin
+Name[de]=Mein erstes Kate-Modul
+Name[el]=Το πρώτο μου πρόσθετο για το Kate
+Name[es]=Mi primer complemento para Kate
+Name[et]=Minu esimene Kate plugin
+Name[eu]=Nire lehenengo Kate plugina
+Name[fa]=اولین وصلۀ Kate من
+Name[fr]=Mon premier module externe pour Kate
+Name[ga]=Mo Chéad Bhreiseán Kate
+Name[gl]=A miña primeira extensión para Kate
+Name[hu]=Mintapélda Kate-bővítőmodulra
+Name[it]=Il mio primo plugin di Kate
+Name[ja]=はじめての Kate プラグイン
+Name[ms]=Plugin Kate Pertama Saya
+Name[nds]=Mien eerst Kate-Moduul
+Name[ne]=मेरो पहिलो केट प्लगइन
+Name[nl]=Mijn eerste Kate-plugin
+Name[pl]=Moja pierwsza wtyczka do Kate
+Name[pt]=O Meu Primeiro 'Plugin' para o Kate
+Name[pt_BR]=Meu Primeiro Plug-in do Kate
+Name[ru]=Мой первый модуль к Kate
+Name[sk]=Môj prvý Kate modul
+Name[sl]=Moj prvi vstavek za Kate
+Name[sr]=Мој први прикључак за Kate
+Name[sr@Latn]=Moj prvi priključak za Kate
+Name[sv]=Mitt första insticksprogram för Kate
+Name[tr]=İlk Kate Eklentim
+Name[zh_CN]=我的第一个 Kate 插件
+Name[zh_TW]=我的第一個 Kate 外掛程式
+Comment=Your short description about the plugin goes here
+Comment[ca]=Aquí va la descripció curta referent al connector
+Comment[cy]=Mae eich disgrifiad byr am yr ategyn yn mynd yma
+Comment[da]=Din korte beskrivelse af plugin skal være her
+Comment[de]=Hierhin gehört eine kurze Beschreibung des Moduls
+Comment[el]=Η σύντομη περιγραφή σας σχετικά με το πρόσθετο πηγαίνει εδώ
+Comment[es]=Aquí va la descripción corta sobre el complemento
+Comment[et]=Sinu plugina lühikirjeldus
+Comment[eu]=Hemen dihoa plugin-aren buruzko zure deskribapen motza
+Comment[fa]=توصیف کوتاه شما در مورد وصله در اینجا می‌آید
+Comment[fr]=Une courte description de votre module externe s'insère ici
+Comment[ga]=Cuir do chur síos gearr ar an mbreiseán anseo
+Comment[gl]=A súa descrición breve sobre a extensión vai aquí.
+Comment[hi]=प्लगइन के बारे में आपका छोटा सा वर्णन यहाँ जाएगा
+Comment[hu]=Itt lehet egy rövid leírást adni a bővítőmodulról
+Comment[is]=Hér ætti að vera smá lýsing á viðbótinni
+Comment[it]=La tua breve descrizione sui plugin va qui
+Comment[ja]=プラグインに関する短い説明をここに記述します。
+Comment[lt]=Čia turėtų būti trumpas priedo aprašymas
+Comment[ms]=Huraian ringkas anda tentang plugin anda di sini
+Comment[nds]=Hier kannst Du en kort Moduulbeschrieven ingeven
+Comment[ne]=प्लगइनका बारेमा तपाईँको छोटो भनाइ यस्तो छ
+Comment[nl]=Hier kunt u een korte omschrijving opgeven
+Comment[pl]=Tu powinien się pojawić krótki opis wtyczki
+Comment[pt]=Aqui deverá colocar uma descrição do 'plugin'
+Comment[pt_BR]=Sua descrição sumária sobre o plug-in vai aqui
+Comment[ru]=Здесь располагается краткое описание модуля
+Comment[sk]=Sem vložte krátky popis modulu
+Comment[sl]=Tukaj je kratek opis o vstavku
+Comment[sr]=Овде иде ваш кратак опис прикључка
+Comment[sr@Latn]=Ovde ide vaš kratak opis priključka
+Comment[sv]=En kort beskrivningen av vad insticksprogrammet gör
+Comment[ta]=உங்கள் சொருகின் சிறு விவரம் இங்கிருக்கும்
+Comment[tg]=Дар инҷо тасвири кӯтоҳи модул ҷойгир аст
+Comment[tr]=Eklenti hakkında kısa bir tanımı buraya yazın.
+Comment[zh_CN]=关于这个插件的简短描述
+Comment[zh_TW]=您對此外掛程式的描述寫在這裡
+author=%{AUTHOR}, %{EMAIL}
diff --git a/languages/cpp/app_templates/kateplugin/plugin.kdevelop b/languages/cpp/app_templates/kateplugin/plugin.kdevelop
new file mode 100644
index 00000000..9f0b4ede
--- /dev/null
+++ b/languages/cpp/app_templates/kateplugin/plugin.kdevelop
@@ -0,0 +1,113 @@
+<?xml version="1.0"?>
+<kdevelop>
+ <general>
+ <author>%{AUTHOR}</author>
+ <email>%{EMAIL}</email>
+ <version>%{VERSION}</version>
+ <projectmanagement>KDevKDEAutoProject</projectmanagement>
+ <primarylanguage>C++</primarylanguage>
+ <keywords>
+ <keyword>C++</keyword>
+ <keyword>Code</keyword>
+ <keyword>Qt</keyword>
+ <keyword>KDE</keyword>
+ </keywords>
+ </general>
+ <kdevcppsupport>
+ <qt>
+ <version>3</version>
+ <used>true</used>
+ <includestyle>3</includestyle>
+ <designerintegration>EmbeddedKDevDesigner</designerintegration>
+ </qt>
+ </kdevcppsupport>
+<kdevautoproject>
+ <general>
+ <activetarget>src/lib%{APPNAMELC}plugin.la</activetarget>
+ <useconfiguration>debug</useconfiguration>
+ </general>
+ <configurations>
+ <optimized>
+ <builddir>optimized</builddir>
+ <ccompiler>kdevgccoptions</ccompiler>
+ <cxxcompiler>kdevgppoptions</cxxcompiler>
+ <f77compiler>kdevg77options</f77compiler>
+ <cxxflags>-O2 -g0</cxxflags>
+ </optimized>
+ <debug>
+ <configargs>--enable-debug=full</configargs>
+ <builddir>debug</builddir>
+ <ccompiler>kdevgccoptions</ccompiler>
+ <cxxcompiler>kdevgppoptions</cxxcompiler>
+ <f77compiler>kdevg77options</f77compiler>
+ <cxxflags>-O0 -g3</cxxflags>
+ </debug>
+ </configurations>
+ </kdevautoproject>
+ <kdevfileview>
+ <groups>
+ <group pattern="*.cpp;*.cxx;*.h" name="Sources" />
+ <group pattern="*.ui" name="User Interface" />
+ <group pattern="*.png" name="Icons" />
+ <group pattern="*.po;*.ts" name="Translations" />
+ <group pattern="*" name="Others" />
+ </groups>
+ </kdevfileview>
+ <kdevdoctreeview>
+ <ignoretocs>
+ <toc>ada</toc>
+ <toc>ada_bugs_gcc</toc>
+ <toc>bash</toc>
+ <toc>bash_bugs</toc>
+ <toc>clanlib</toc>
+ <toc>fortran_bugs_gcc</toc>
+ <toc>gnome1</toc>
+ <toc>gnustep</toc>
+ <toc>gtk</toc>
+ <toc>gtk_bugs</toc>
+ <toc>haskell</toc>
+ <toc>haskell_bugs_ghc</toc>
+ <toc>java_bugs_gcc</toc>
+ <toc>java_bugs_sun</toc>
+ <toc>opengl</toc>
+ <toc>pascal_bugs_fp</toc>
+ <toc>php</toc>
+ <toc>php_bugs</toc>
+ <toc>perl</toc>
+ <toc>perl_bugs</toc>
+ <toc>python</toc>
+ <toc>python_bugs</toc>
+ <toc>ruby</toc>
+ <toc>ruby_bugs</toc>
+ <toc>sdl</toc>
+ <toc>stl</toc>
+ <toc>sw</toc>
+ <toc>w3c-dom-level2-html</toc>
+ <toc>w3c-svg</toc>
+ <toc>w3c-uaag10</toc>
+ <toc>wxwidgets_bugs</toc>
+ </ignoretocs>
+ <ignoreqt_xml>
+ <toc>qmake User Guide</toc>
+ </ignoreqt_xml>
+ </kdevdoctreeview>
+ <kdevdebugger>
+ <general>
+ <dbgshell>libtool</dbgshell>
+ </general>
+ </kdevdebugger>
+ <kdevfilecreate>
+ <filetypes/>
+ <useglobaltypes>
+ <type ext="ui" />
+ <type ext="cpp" />
+ <type ext="h" />
+ </useglobaltypes>
+ </kdevfilecreate>
+ <kdevdocumentation>
+ <projectdoc>
+ <docsystem>Doxygen Documentation Collection</docsystem>
+ <docurl>%{APPNAMELC}.tag</docurl>
+ </projectdoc>
+ </kdevdocumentation>
+</kdevelop>
diff --git a/languages/cpp/app_templates/kateplugin/plugin_app.cpp b/languages/cpp/app_templates/kateplugin/plugin_app.cpp
new file mode 100644
index 00000000..9fd4a694
--- /dev/null
+++ b/languages/cpp/app_templates/kateplugin/plugin_app.cpp
@@ -0,0 +1,89 @@
+%{CPP_TEMPLATE}
+
+#include "plugin_%{APPNAMELC}.h"
+
+#include <kaction.h>
+#include <klocale.h>
+#include <kstandarddirs.h>
+
+class PluginView : public KXMLGUIClient
+{
+ friend class KatePlugin%{APPNAME};
+
+ public:
+ Kate::MainWindow *win;
+};
+
+extern "C"
+{
+ void* init_lib%{APPNAMELC}plugin()
+ {
+ KGlobal::locale()->insertCatalogue("kate%{APPNAMELC}");
+ return new KatePluginFactory;
+ }
+}
+
+KatePluginFactory::KatePluginFactory()
+{
+ s_instance = new KInstance( "kate" );
+}
+
+KatePluginFactory::~KatePluginFactory()
+{
+ delete s_instance;
+}
+
+QObject* KatePluginFactory::createObject( QObject* parent, const char* name, const char*, const QStringList & )
+{
+ return new KatePlugin%{APPNAME}( parent, name );
+}
+
+KInstance* KatePluginFactory::s_instance = 0L;
+
+KatePlugin%{APPNAME}::KatePlugin%{APPNAME}( QObject* parent, const char* name )
+ : Kate::Plugin ( (Kate::Application*)parent, name )
+{
+}
+
+KatePlugin%{APPNAME}::~KatePlugin%{APPNAME}()
+{
+}
+
+void KatePlugin%{APPNAME}::addView(Kate::MainWindow *win)
+{
+ /// @todo doesn't this have to be deleted?
+ PluginView *view = new PluginView ();
+
+ (void) new KAction ( i18n("Insert Hello World"), 0, this,
+ SLOT( slotInsertHello() ), view->actionCollection(),
+ "edit_insert_%{APPNAMELC}" );
+
+ view->setInstance (new KInstance("kate"));
+ view->setXMLFile("plugins/%{APPNAMELC}/plugin_%{APPNAMELC}.rc");
+ win->guiFactory()->addClient (view);
+ view->win = win;
+
+ m_views.append (view);
+}
+void KatePlugin%{APPNAME}::removeView(Kate::MainWindow *win)
+{
+ for (uint z=0; z < m_views.count(); z++)
+ if (m_views.at(z)->win == win)
+ {
+ PluginView *view = m_views.at(z);
+ m_views.remove (view);
+ win->guiFactory()->removeClient (view);
+ delete view;
+ }
+}
+
+void KatePlugin%{APPNAME}::slotInsertHello()
+{
+ Kate::View *kv = application()->activeMainWindow()->viewManager()->activeView();
+
+ if (kv)
+ kv->insertText ("Hello World");
+}
+
+#include "plugin_%{APPNAMELC}.moc"
+
diff --git a/languages/cpp/app_templates/kateplugin/plugin_app.h b/languages/cpp/app_templates/kateplugin/plugin_app.h
new file mode 100644
index 00000000..8cc5b237
--- /dev/null
+++ b/languages/cpp/app_templates/kateplugin/plugin_app.h
@@ -0,0 +1,49 @@
+%{H_TEMPLATE}
+
+#ifndef _PLUGIN_%{APPNAMEUC}_H_
+#define _PLUGIN_%{APPNAMEUC}_H_
+
+#include <kate/application.h>
+#include <kate/documentmanager.h>
+#include <kate/document.h>
+#include <kate/mainwindow.h>
+#include <kate/plugin.h>
+#include <kate/view.h>
+#include <kate/viewmanager.h>
+
+#include <klibloader.h>
+#include <klocale.h>
+
+class KatePluginFactory : public KLibFactory
+{
+ Q_OBJECT
+
+ public:
+ KatePluginFactory();
+ virtual ~KatePluginFactory();
+
+ virtual QObject* createObject( QObject* parent = 0, const char* pname = 0, const char* name = "QObject", const QStringList &args = QStringList() );
+
+ private:
+ static KInstance* s_instance;
+};
+
+class KatePlugin%{APPNAME} : public Kate::Plugin, Kate::PluginViewInterface
+{
+ Q_OBJECT
+
+ public:
+ KatePlugin%{APPNAME}( QObject* parent = 0, const char* name = 0 );
+ virtual ~KatePlugin%{APPNAME}();
+
+ void addView (Kate::MainWindow *win);
+ void removeView (Kate::MainWindow *win);
+
+ public slots:
+ void slotInsertHello();
+
+ private:
+ QPtrList<class PluginView> m_views;
+};
+
+#endif // _PLUGIN_%{APPNAMEUC}_H_
diff --git a/languages/cpp/app_templates/kateplugin/plugin_app.rc b/languages/cpp/app_templates/kateplugin/plugin_app.rc
new file mode 100644
index 00000000..fe98416f
--- /dev/null
+++ b/languages/cpp/app_templates/kateplugin/plugin_app.rc
@@ -0,0 +1,11 @@
+<!DOCTYPE kpartgui>
+<kpartplugin name="%{APPNAMELC}" library="lib%{APPNAMELC}plugin" version="1">
+<MenuBar>
+ <Menu name="tools"><Text>&amp;Tools</Text>
+ <Action name="edit_insert_%{APPNAMELC}"/>
+ </Menu>
+</MenuBar>
+<ToolBar name="extraToolBar">
+ <Action name="edit_insert_%{APPNAMELC}"/>
+</ToolBar>
+</kpartplugin>
diff --git a/languages/cpp/app_templates/kateplugin/src-Makefile.am b/languages/cpp/app_templates/kateplugin/src-Makefile.am
new file mode 100644
index 00000000..88ba33a8
--- /dev/null
+++ b/languages/cpp/app_templates/kateplugin/src-Makefile.am
@@ -0,0 +1,20 @@
+INCLUDES = $(all_includes)
+METASOURCES = AUTO
+
+KDE_ICON = AUTO
+
+# Install this plugin in the KDE modules directory
+kde_module_LTLIBRARIES = lib%{APPNAMELC}plugin.la
+
+lib%{APPNAMELC}plugin_la_SOURCES = plugin_%{APPNAMELC}.cpp
+lib%{APPNAMELC}plugin_la_LIBADD = -lkateinterfaces
+lib%{APPNAMELC}plugin_la_LDFLAGS = -module $(KDE_PLUGIN) $(all_libraries)
+
+pluginsdir = $(kde_datadir)/kate/plugins/%{APPNAMELC}
+plugins_DATA = plugin_%{APPNAMELC}.rc
+
+kde_services_DATA = %{APPNAMELC}.desktop
+
+messages: rc.cpp
+ $(EXTRACTRC) `find . -name \*.ui -o -name \*.rc` > rc.cpp
+ $(XGETTEXT) *.cpp -o $(podir)/%{APPNAMELC}.pot
diff --git a/languages/cpp/app_templates/kateplugin/subdirs b/languages/cpp/app_templates/kateplugin/subdirs
new file mode 100644
index 00000000..0e678106
--- /dev/null
+++ b/languages/cpp/app_templates/kateplugin/subdirs
@@ -0,0 +1,3 @@
+doc
+po
+src