1
/** @mainpage The libkiten Library API Reference
9
This is the online reference for developing using the libkiten library.
11
libkiten is a library for managing a variety of japanese cross-language
12
dictionaries through a common interface. It provides a light abstraction layer
13
over various types of japanese dictionaries, with a simple facility for adding
17
(c)2001 Jason Katz-Brown <jason@katzbrown.com> : Original Author of most of kiten and libkiten
18
(c)1998 Jim W. Breen <jwb@csse.monash.edu.au> : Creator of an index file format used in libkiten
19
(c)2006-2007 Eric Kjeldergaard : Rewriting effort for KDE 4
20
(c)2006-2008 Joseph Kerian <jkerian@gmail.com> : Rewriting effort for KDE 4
23
Daniel E. Moctezuma <democtezuma@gmail.com> is the current maintainer.
26
This library is distributed under the lgpl: @lgpl<br>
30
/** @page components Components
33
@ref index "Overview" |
39
Below is a brief summary of the various components of libkiten
42
<dd>Class to load with a query to the dictionary system.</dd>
44
<dt>DictionaryManager</dt>
45
<dd>Main management class. These objects are the main interface to the library.</dd>
47
<dt>DictionaryPreferenceDialog</dt>
48
<dd>Abstract Base Class, providing an interface between the individual dictionary preferences and the host application.</dd>
51
<dd>Results from a dictionary search are returned to the user application in a list of type Entry, aggregated in an EntryList.</dd>
54
<dd>Results from a dictionary search are returned to the user application in a list of type Entry, aggregated in an EntryList.</dd>
56
<dt>HistoryPtrList</dt>
57
<dd>A useful utility class if you want to keep a history of results. Contains a list of EntryLists. Automatically handles maximum history size, and truncation/tracking current item</dd>
60
<dd>An abstract base class, used internally for managing dictionary types</dd>
63
<dd>An input box, can allow the user to enter kana without a japanese input manager installed</dd>
67
/** @page using Using libkiten
69
@ref index "Overview" |
75
General Approach to using the classes in the library:
77
Create a DictionaryManager object, load dictionaries to it using member functions. (persistant)
78
Create a DictQuery object, load it with your query
79
EntryList *results = DictionaryManagerObject->doSearch(DictQueryObject);
80
//Do something with each Entry in the EntryList, or do something with the whole list
82
For your preferences dialog:
83
Get a list of DictionaryPreferenceDialog objects from DictionaryManager to put into your preferences dialog.
85
If you maintain a history:
86
You can use HistoryPtrList to store and manage lists of EntryList's.
89
/** @page adding Adding New Dictionary Types
91
@ref index "Overview" |
94
Adding New Dictionary Types
97
Adding a new dictionary type is relatively simple.
98
Look over the documentation of the DictFile abstract class. You may also need to subclass from Entry, if your dictionary requires special logic or strangely formatted fields. If you have no particular preferences to set (or want to put off that work until later), your DictFile descendent can return NULL, when asked for a preference dialog.