Sophie

Sophie

distrib > Mandriva > 8.2 > i586 > media > contrib > by-pkgid > fb1e86d4abb8b97a55c9455475ceff59 > files > 54

wordtrans-1.1-pre7.2mdk.i586.rpm

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">
<HTML>
<HEAD>
 <META NAME="GENERATOR" CONTENT="SGML-Tools 1.0.9">
 <TITLE>Multi Language Word Translator 1.0.1: qwordtrans / kwordtrans</TITLE>
 <LINK HREF="wordtrans_en-7.html" REL=next>
 <LINK HREF="wordtrans_en-5.html" REL=previous>
 <LINK HREF="wordtrans_en.html#toc6" REL=contents>
</HEAD>
<BODY>
<A HREF="wordtrans_en-7.html"><IMG SRC="next.gif" ALT="Next"></A>
<A HREF="wordtrans_en-5.html"><IMG SRC="prev.gif" ALT="Previous"></A>
<A HREF="wordtrans_en.html#toc6"><IMG SRC="toc.gif" ALT="Contents"></A>
<HR>
<H2><A NAME="s6">6. qwordtrans / kwordtrans</A></H2>

<P>There are two version for X-Window: qwordtrans and kwordtrans. 
Both are almost equal so I talk about them in the same section.
<P><B>qwordtrans</B> is the Qt version. The sources can be compiled 
with Qt 2.x.x (tested with Qt 2.0.2, 2.2.2 and 2.2.3).
<P><B>kwordtrans</B> is the KDE version. There are not much differences
with qwordtrans, the most important is that it will have the same look
as the other KDE applications. The most important difference is that
it could be docked in the KDE panel.
<P>
<H2><A NAME="ss6.1">6.1 Parameters</A>
</H2>

<P><B>qwordtrans</B> and <B>kwordtrans</B> are the versions for X-Window.
<P>
<H3>Usage</H3>

<P>
<BLOCKQUOTE><CODE>
<PRE>
qwordtrans [--help] [--conf dir] [Qt-options]

kwordtrans [--help] [--conf dir] [Qt-options] [KDE-options]
</PRE>
</CODE></BLOCKQUOTE>
<P>
<P>Wordtrans options:
<P>
<DL>
<P>
<DT><B>--help</B><DD><P>Shows a helping message.
<P>
<DT><B>--conf dir</B><DD><P>Directory with the configuration files. This is
used in the web interface to read the configuration files from the
directory /etc/wordtrans, so wordtrans can be executed as the
user nobody.
<P>
</DL>
<P>
<P>Qt-options. 
All Qt programs support the following parameters (from qt-doc):
<P>
<DL>
<P>
<DT><B>-style= style</B><DD><P>sets the application GUI style. Possible
values are motif, windows, and platinum.
<P>
<DT><B>-session= session</B><DD><P>restores the application from an
earlier session.
<P>
<DT><B>-display display</B><DD><P>sets the X display (default is
$DISPLAY).
<P>
<DT><B>-geometry geometry</B><DD><P>sets the client geometry of the main
widget.
<P>
<DT><B>-fn or -font font</B><DD><P>defines the application font.
<P>
<DT><B>-bg or -background color</B><DD><P>sets the default background
color and an application palette (light and dark shades
are calculated).
<P>
<DT><B>-fg or -foreground color</B><DD><P>sets the default foreground
color.
<P>
<DT><B>-btn or -button color</B><DD><P>sets the default button color.
<P>
<DT><B>-name name</B><DD><P>sets the application name.
<P>
<DT><B>-title title</B><DD><P>sets the application title (caption).
<P>
<DT><B>-visual TrueColor</B><DD><P>forces the application to use a
TrueColor visual on an 8-bit display.
<P>
<DT><B>-ncols count</B><DD><P>limits the number of colors allocated in the
color cube on a 8-bit display, if the application is using
the QApplication::ManyColor color specification. If count
is 216 then a 6x6x6 color cube is used (ie. 6 levels of
red, 6 of green, and 6 of blue); for other values, a cube
approximately proportional to a 2x3x1 cube is used.
<P>
<DT><B>-cmap</B><DD><P>causes the application to install a private color
map on an 8-bit display.
<P>
</DL>
<P>
<P>KDE-options:
<P>
<DL>
<DT><B>--help-qt</B><DD><P>Show Qt specific options.
<P>
<DT><B>--help-kde</B><DD><P>Show KDE specific options.
<P>
<DT><B>--help-all</B><DD><P>Show all options.
<P>
<DT><B>--author</B><DD><P>Show author information.
<P>
<DT><B>-v, --version</B><DD><P>Show version information.
<P>
<DT><B>--license</B><DD><P>Show license information.
<P>
</DL>
<P>
<P>
<H2><A NAME="ss6.2">6.2 How to use it</A>
</H2>

<P>Using this application is very simple. Basically you type the word
to look for and qwordtrans will search it and display the matches
found in the selected dictionary.
<P>
<H3>Application window</H3>

<P>The application has the following items (up to down):
<P>
<H3>Menus</H3>

<P>
<UL>
<LI> <B>File</B>
<UL>
<LI>New window. Opens a new main window. 
<B>Important:</B> This feature is experimental, it has
known problems. Nevertheless it will be always better
using this option than running two different processes
of qwordtrans (for instance, only one of the windows will
try to save the preferences).</LI>
<LI>Save. If the option <B>Options->Rich Text</B>
is on then the text will be saved in HTML format, in other
case it will be saved as plain text.</LI>
<LI>Print. Obvious, isn't it?</LI>
<LI>Exit. Closes the application.</LI>
</UL>

</LI>
<LI> <B>Translate</B>
<UL>
<LI>Language1 -> Language2. Words in language1 will be
shown first in the output window.</LI>
<LI>Language2 -> Language1. Words in language2 will be
shown first in the output window.</LI>
<LI>Learn. If there is not translation for a word selecting
this option you can append it to the dictionary. 
A dialog will show where you should type the word in
both languages. Then, if there's no error, the new
translation will be saved in your personal dictionary.</LI>
</UL>

</LI>
<LI> <B>Dictionaries</B>
<UL>
<LI>New... Lets you configure the application to use
a new dictionary.</LI>
<LI>Edit... Lets you edit the options of the current dictionary. 
You can change the alias, icons, main &amp; personal dictionary 
files, etc.</LI>
<LI>&lt;dictionary list&gt; Here will be the list of
available dictionaries. You can select the one you're 
interested in. I must say that here appear the dictionaries
qwordtrans knows about, but there's no check to see if
the dictionaries are really installed. When the application
is closed it will saved the selected dictionary as the
default dictionary.</LI>
</UL>
</LI>
<LI> <B>Bookmarks</B>
<UL>
<LI>Add bookmark. Stores in the list of bookmarks the 
latest searched word.</LI>
</UL>

</LI>
<LI> <B>View</B>
<UL>
<LI>Introduction. Shows the wordtrans introduction.</LI>
<LI>Description of the dictionary. Shows the description of 
the selected dictionary.</LI>
<LI>Server info (only for dict dictionaries).
It will connect to the dict server and ask for some information,
that usually shows the available databases of that server.</LI>
<LI>Dictionary info (only for dict dictionaries).
It will ask the dict server information about the
databases which the dictionary is using. That won't work
if the selected database is "*", which means "all".</LI>
</UL>

</LI>
<LI> <B>Options</B>
<UL>
<LI>Full words. Only search for full words.</LI>
<LI>Case sensitive. Obvious, isn't it?</LI>
<LI>Rich text. If you disable it the text won't be process
to add bolds or links, it simply will display the text
in the same way it is received.</LI>
</UL>

</LI>
<LI> <B>Preferences</B>
<UL>
<LI> <B>Clipboard</B>
<UL>
<LI>Watch. When you select this option the application will
watch the clipboard and translate the word which is there.
That means that by selecting a word in any application it
will be automatically translated. Hint: in most applications
double clicking a word would be to be selected.</LI>
<LI>Adjust sensitivity. Lets you set how many milliseconds the
the clipboard will be checked.</LI>
</UL>
</LI>
<LI>Fonts. Allows you to change the main font and
output window font.</LI>
<LI>Toolbar. You can change the size of the toolbar.</LI>
<LI>Hide. Allows you to hide the toolbar, the status bar and the 
menu bar.</LI>
<LI>Change background colour. Here you can select a new background
colour for the output window.</LI>
<LI>Animation effects. Enables or disabled the animation effects
of some widgets.</LI>
<LI>Dock. <B>(kwordtrans)</B> The main window will be hidden
and a small icon will appear in the KDE panel. When clicking 
with the mouse left button over that icon will make the main
window to be shown again. Clicking with the right button
will show a menu where you can activate the option to
watch the clipboard and select a dictionary. If the watch
clipboard option is on, then whenever you select a word
in any application, the <B>mini-window</B> will show
with the translation of the word (if found). Clicking in any
place of the mini-window will make it to hide. 
<B>I think this is a very useful feature</B>.</LI>
<LI>Hide and use miniwindow. <B>(qwordtrans)</B> This option
is quite similar to <B>"Dock"</B> from kwordtrans, the only
difference is that the main window will be minimised instead
of going to the KDE panel. Everything else will be the same.</LI>
</UL>

</LI>
<LI> <B>Help (qwordtrans)</B>
<UL>
<LI>Select browser... The application help is written in HTML 
so you have to select a web browser. A dialog window will
show where you can choose among several popular web
browsers.</LI>
<LI>Contents. The previously selected browser will be run
with the contents page of this help 
(<CODE>/usr/share/doc/wordtrans/html/wordtrans_en.html</CODE>).</LI>
<LI>What's this. The cursor will be transformed in a question
mark. Clicking with it on some widgets will display some
info about that widget.</LI>
<LI>Questionnaire. A window will be shown with a questionnaire.
I would appreciate if you could take some minutes to fill it. 
Your answers could help me improve this application.</LI>
<LI>About Qt. Show info about the library Qt.</LI>
<LI>About... That shows the "About" dialog of this application.</LI>
</UL>

</LI>
<LI> <B>Help (kwordtrans)</B>
<UL>
<LI>Contents. It will run konqueror to show you the HTML
pages of this application.</LI>
<LI>What's this. The cursor will be transformed in a question
mark. Clicking with it on some widgets will display some
info about that widget.</LI>
<LI>Bug report. It will open a dialog where you can report
a bug.</LI>
<LI>Questionnaire. A window will be shown with a questionnaire.
I would appreciate if you could take some minutes to fill it. 
Your answers could help me improve this application.</LI>
<LI>About kwordtrans. That shows the "About" dialog of this application.</LI>
<LI>About KDE. Info about the version of KDE.</LI>
</UL>
</LI>
</UL>
<P>
<H3>Tool bar</H3>

<P>qwordtrans has some icons in the tool bar, if you stop the mouse over
them for a while a tooltip will show telling you what's that button for:
<P>
<UL>
<LI> Language1->Language2. See description in previous section. 
You must know that "language1" and "language2" are replace with
the actual names of the languages in the selected dictionary.</LI>
<LI> Language2->Language1.
</LI>
<LI> Learn.
</LI>
<LI> Watch clipboard.

</LI>
</UL>
<P>
<H3>Input text box</H3>

<P>In this box you can type the word to look for. Pressing <B>enter</B> (or 
clicking in the button on the right) the search will be performed.
<P>
<H3>Output window</H3>

<P>Here is where the words matched will be displayed. If the application
is compiled with Qt 2 the search term will be in bold, improving the
legibility.
<P>
<H3>The right way of adding new translations</H3>

<P>(From the i2e man page)
<P>When adding words to the dictionary (button "Learn") it should be taken into
account that when a word allows several different translations, they should be
learned separately.
<P>For example, 'hola' can be translated as 'hi' or as 'hello', so, in order to
add 'hola' to the dictionary with both translations, 'hola' and 'hi' should be
learnt first and then 'hola' and 'hello'.
<P>
<H2><A NAME="ss6.3">6.3 Creating or adding a dictionary</A>
</H2>

<P>The most of the times I talk about "dictionary" I'm referring to the group
of data (files, icons, language's names, etc.) that wordtrans needs to
be able to use a determined dictionary, but not to the dictionary itself
(the list of words with the equivalences for one and another language).
<P>
<P>
<H3>New dictionary</H3>

<P>With this option you can configure qwordtrans to support a new dictionary. 
When selecting this option qwordtrans will create the necessary 
structure to manage a new dictionary (with some data by default).
Once this is done it will show you the dictionary editing dialog.
<P>
<P>
<H3>Dictionary editing dialog</H3>

<P>When you edit or create a dictionary you'll see this dialog with
some fields you should fill:
<P>
<H3>Main</H3>

<P>
<P>
<DL>
<DT><B>alias</B><DD><P>The alias is used by the console version 
(binary <B>wordtrans</B>), to choose the dictionary to use. 
It's also used as the configuration file name in new dictionaries.
The name will be <CODE>~/.wordtrans/typed_alias.conf</CODE>. 
Once this file has been created the file name won't be changed although
you change the alias.
<P>
<DT><B>dictionary</B><DD><P>Here you have to type the path where the main
dictionary is. You can click on the right button to select it from
the file dialog.
<P>
<DT><B>personal</B><DD><P>Here goes the file used as your personal dictionary, 
in other words, where the new translations will be added. 
This file will be stored in your HOME directory. 
Don't put an absolute file name!
<P>
<DT><B>language 1</B><DD><P>Name of the first language of the dictionary. 
<P>
<DT><B>language 2</B><DD><P>Name of the second language of the dictionary.  
<P>
<DT><B>separator</B><DD><P>Separator used by the dictionary to separate
the words in a language of the another one. i2e dictionary uses " : " 
(without quotations marks), in other words, space, colon, space; 
while trans-de-en dictionary uses " :: ".
<P>
<DT><B>icon 1</B><DD><P>Here goes the icon that represents "translation of 
language 1 into language 2". In directory
<CODE>/usr/share/icons/wordtrans/</CODE> you have some icons.
You can make new ones with <CODE>the gimp</CODE>, for example.
I recommend that icons aren't bigger than 26x26 pixels.
<P>
<DT><B>icon 2</B><DD><P>Here goes the icon that represents "translation of 
language 1 into language 2".
<P>
</DL>
<P><B>NOTE:</B> If you're editing a dict server dictionary this dialog
will be quite different.
In section 
<A HREF="wordtrans_en-8.html#dict">dict</A>
 there's an explanation of that dialog.
<P>
<H3>Description</H3>

<P>You can type here a description for the dictionary. You can indicate
copyright info, where you download it from, or whatever you want.
<P>You may also use some HTML-like tags, but lookout it is not HTML. 
If you want to know exactly what tags you can use type 
<CODE>man qstylesheet</CODE> (you'll need the Qt 2 development library installed
to work).
<P>
<P>
<HR>
<A HREF="wordtrans_en-7.html"><IMG SRC="next.gif" ALT="Next"></A>
<A HREF="wordtrans_en-5.html"><IMG SRC="prev.gif" ALT="Previous"></A>
<A HREF="wordtrans_en.html#toc6"><IMG SRC="toc.gif" ALT="Contents"></A>
</BODY>
</HTML>