Aard Dictionary’s user interface consists of lookup and history pane (initally grouped into tabs), article pane, toolbar and menu.
First open some dictionaries, either by selecting Dictionary ‣ Add Dictionaries or Dictionary ‣ Add Directory. Adding a directory means that Aard Dictionary will scan that directory (without subdirectories) and open any dictionaries it finds every time it is started.
Dictionaries have .aar extension. Dictionaries in newer aar-HTML format have double extension .html.aar, while dictionaries in older aar-JSON format have single .aar extension.
Start typing a word to look up in Lookup Box. List of matching words appears below Lookup Box and is updated when typing is paused, best matches displayed first (at the top of the list) and first match automatically selected. Articles with similar titles found in one or more dictionaries are grouped together and are display in multiple tabs in article pane when selected.
Lookup pane, history pane and toolbar can be rearranged and moved to a new position (click pane’s title bar or toolbar’s drag handle and start dragging), either docked around article pane:
or floating:
Lookup pane, history pane and toolbar can also be hidden (through View menu, close button in lookup and history pane’s title bar, or context menu over menu bar, tool bar or lokup and history title bars).
Article visual style can be customized with Article Appearance dialog (Article ‣ Appearance...).
See also
Article ‣ Find brings up Find bar:
Matching text in current article is selected as user types. Use Find bar’s arrow buttons or Shift+Enter/Enter to select previous/next occurence of the phrase. Hide Find bar with the close button or Esc.
Many Wikipedia articles have equivalent articles in other language Wikipedias and contain corresponding inter-wiki links. Aard Dictionary compiler can optionally put corresponding article titles into dictionary’s index so that articles can be found by their titles in other languages. For example, if English Wikipedia is compiled with Russian language links, searching for Уравнение лап finds Laplace’s Equation by corresponding Russian title Уравнение Лапласа.
Note redirect title at the top.
Dictionary info dialog shows list of language link languages included into dictionarie’s lookup index.
When downloading or copying large data files such as Aard Dicrionary volumes data may get corrupted due to software, hardware or data transmittion error. Dictionary volumes store SHA-1 digest of the content which is used to verify data integrity. To verify volume data integrity open Verify dialog (Dictionary ‣ Verify...), select one of the volumes and click Verify button.
Once verified volume status changes from Unverified to OK or Corrupt.
Volumes can also be verified by running Aard Dictionary from the command line like this:
aarddict --verify enwiki-20090810-1.1_of_4.aar enwiki-20090810-1.2_of_4.aar
Article appearance can be changed via Article Appearance dialog (Article ‣ Appearance...). User can switch between Wikipedia style (based on default Wikipedia skin, Monobook) and Aard style which allows to customize link colors and article text font.
New in version 0.9.1: Power users can further customize article appearance by creating and editing user.css in $HOME/.aarddict directory.
Here’s a naïve example of creating a dark color theme for articles:
body, h1, h2, h3, h4, h5, h6 {
background-color: black;
color: gray;
}
.tex {
background-color: lightgray;
padding: 5px;
}
.infobox {
display: none;
}
a:link {
color: white;
font-weight: bold;
}
a:active {
background-color: rgb(80, 80, 80);
}
Currently Aard Dictionary user interface is available in English, Russian and Greek. User interface language should be selected automatically based on system’s locale. System settings can be overridden by starting Aard Dictionary from command line like this:
$ LANG=ru_RU.UTF-8 aarddict
If specified locale is not available this will result in GTK warning
(process:12326): Gtk-WARNING **: Locale not supported by C library.
Using the fallback 'C' locale.
followed by a stack trace and Aard Dictionary will fail to start. Corresponding locale will need to be installed. For example, in Ubuntu 9.04 the following command will fix the error:
$ sudo locale-gen ru
Many dictionaries use International Phonetic Alphabet (IPA) in their articles to write phonetic transcription of a word (describe it’s pronunciation). To have IPA characters displayed properly you may need to install one of the excellent IPA fonts available at http://scripts.sil.org.
Note
Aard Dictionary 0.7.x supports special tag for marking up phonetic transcription. Font for the article text marked as phonetic transcription can be assigned through View ‣ Phonetic Font... menu.
You also may need to install additional fonts if you use dictionaries that use script not available on your system. WAZU JAPAN’s Gallery of Unicode Fonts is an excellent resource for various unicode fonts.
To install fonts on Maemo simply create /home/user/.fonts directory and copy font files there. New fonts should now appear in font selection dialogs across the system, including Phonetic Font dialog in Aard Dictionary 0.7.x.
If you don’t like to copy font files into /home/user/.fonts or don’t know how to do it you may install Doulos SIL Font package with Maemo Application Manager.
Dictionaries with articles in older aar-JSON format have additional limitations (limited table support, math is not rendered) and is deprecated. Support for aar-JSON has been removed from Aard Dictionary in version 0.9.0. Aard Dictionary for Android also doesn’t support it.
Warning
Users are strongly advised to uninstall Aard Dictionary 0.7.x by running Aard Dictionary uninstaller before upgrading to 0.8.0
If starting the application results in error message like this:
This application has failed to start because the application
configuration is incorrect. Reinstalling the application may fix this
problem.
or
The application has failed to start because its side-by-side
configuration is incorrect. Please see the application event log for
more detail.
most likely Microsoft Visual C++ 2008 SP1 Redistributable Package (x86) needs to be installed.
On Windows earlier than Windows XP SP3 users may also need to install Microsoft Visual C++ 2005 Redistributable Package (x86).
Aard Dictionary starting with 0.8.0 depends on PyQt4 libraries which have not been officially released for Maemo 4 (N800 and N810) and are only available in development repository. Single click install for Maemo 4 enables it (extras-devel). Be advised that extras-devel contains potentially unstable software that is primarily intended for developers and testers.
Another issue users may encounter when installing on N800/N810 is that Aard Dictionary 0.8.0 together with PyQt4 and Qt4 libraries is approximately 23 Mb download and requires some 70 Mb of device memory. Some applications may need to be uninstalled to free enough memory for the installation.
Mac OS X application bundle can be built with py2app for Aard Dictionary 0.8.0 and newer.
Install MacPorts
Install Python 2.6:
sudo port install python26 +no_tkinter +ucs4
Change environment to make this Python version default:
sudo port install python_select
sudo python_select python26
Make sure Python 2.6 you just installed runs indeed when you type python (you mae need to open a new terminal for python_select to take effect).
Install PyQT4:
sudo port install py26-pyqt4
This should bring in py26-sip and qt4-mac as dependencies. Qt4 compilation takes several hours and requires a lot of disc space (around 6-8 Gb).
Install py2app:
sudo port install py26-py2app
Install PyICU. This is a bit tricky because MacPorts 1.8.1 includes ICU 4.3.1 and PyICU doesn’t seem to build with that. It looks like py26-pyicu @0.8.1 port was added when ICU was at 4.2.0 and it probably worked then. In any case, PyICU 0.8.1 only claims to work with ICU 3.6 and 3.8, so it is best to install and activate older ICU port - 3.8.1.
Copy aarddict.py recipe (and __init__.py) for py2app from macosx to installed py2app package directory:
cp macosx/py2app/recipes/*.py /opt/local/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/py2app/recipes/
This recipe is same as for numpy and other libraries that have package data and won’t work if put in zip archive.
Finally, run py2app:
python setup.py py2app
Remove unused debug binaries:
find dist/ -name "*_debug*" -print0 | xargs -0 rm
A number of unused Qt frameworks gets included in final app (QtDesigner, QtSql etc.) but they can’t be removed since they are linked in _qt.so.
Aard Dictionary started from SDict Viewer code base as an attempt to address some of it’s shortcomings. Initially Jeremy Mortis started to hack on SDict Viewer and ptksdict so that he could look up words in French Wikipedia without having to type accented characters. This required changes to dictionary format. Trying to make SDict Viewer work with both the original Sdictionary format and the new format turned out to be cumbersome and limiting, so SDict Viewer was forked into a new project that can focus on building functionality around new format.
SDict Viewer has a number of issues due to limitations of underlying Sdictionary format developed by AXMA Soft. Aard Dictionary tries to resolve them by introducing aard format.
Sdictionary relies on so called short index to perform word lookups. First few letters of all words in a dictionary are mapped to a pointer that points to position in full index (maximum length of a key in short index is index depth). To find a word SDict Viewer uses short index to jump to a particular place in full index and then iterates through the word list until it finds the word or encounters a word that doesn’t begin with the same letters.
This works reasonably well for small and medium sized dictionaries. Short index depth for dictionaries from http://sdict.com is 3, although the format theoretically allows deeper short index. With large dictionaries like Wikipedia short index of depth 3 is not enough: SDict Viewer sometimes ends up iterating through tens or even hundreds of thousands words, which takes significant amount of time even on powerful desktop machines.
SDict Viewer tries to alleviate this problem by building additional short index on the fly as it iterates through corresponding word list fragment, so that subsequent lookups in that fragment of word list are fast. This, however, significantly slows down first lookup.
Reading and parsing short index when opening a dictionary is in itself a time consuming operation. SDict Viewer saves binary dump of short index on application exit, which speeds up subsequent loads of corresponding dictionary. This, however, requires certain amount of storage and memory at runtime. Size of short index may grow noticeably - depending on how “under-indexed” a particular dictionary is and how often it is used.
Sdictionary format uses several HTML-style tags to mark up dictionary article text. Sdictionary compiler doesn’t escape special characters like < and >, doesn’t produce well-formed markup, doesn’t produce clean article text. Parsing such article text on Nokia Internet Tablets is not very fast and doesn’t always produce nice-looking results.
Sdictionary format defines <r> tag to mark regions of text that are links (references) to other entries in the same dictionary. There is, however, no facility to specify link target, so this mechanism breaks when link target is not exactly the same as corresponding text in the article. There is no support for external (http://) links. SDict Viewer treats all strings that start with http:// as external links, this slows down article formatting.
Sdictionary format theoretically has three options for compressing dictionary data: no compression, gzip and bzip2. In practice all dictionaries actually use gzip. Sdictionary compiler doesn’t actually allow to create bzip2 compressed dictionaries.
Please submit issue reports and enhancement requests to Aard Dictionary issue tracker.
Please submit issue reports and enhancement requests to Aard Dictionary for Android issue tracker.
Initial release. Changes compared to SDict Viewer:
Major user visible differences: