Bugfixes, de.po and sl.po updates, lyxlookup cleanup

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@1304 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
Jean-Marc Lasgouttes 2001-01-08 14:19:29 +00:00
parent 67ef45b7c8
commit 7fa7d43740
11 changed files with 2291 additions and 3174 deletions

View File

@ -1,3 +1,23 @@
2001-01-08 Jean-Marc Lasgouttes <Jean-Marc.Lasgouttes@inria.fr>
* src/frontends/xforms/Toolbar_pimpl.C (BubbleTimerCB): translate
the tooltip.
(set): ditto.
* src/spellchecker.C (sigchldhandler): add an #ifndef USE_PSPELL
around some ispell code.
* src/lyxcursor.[Ch]: add proper constructor, to avoid tons of
Unitialized Memory Read in purify.
* lib/examples/nl_splash.lyx: update from Tino Meinen.
2001-01-04 Dekel Tsur <dekelts@tau.ac.il>
* src/frontends/xforms/FormDocument.C (FormDocument::build):
Disable class_->choice_doc_class and language_->choice_language to
allow using the class/language combox with keyboard.
2001-01-08 Lars Gullik Bjønnes <larsbj@lyx.org> 2001-01-08 Lars Gullik Bjønnes <larsbj@lyx.org>
* src/support/snprintf.c (va_copy): only define va_copy if undefined * src/support/snprintf.c (va_copy): only define va_copy if undefined

View File

@ -1,6 +1,5 @@
#This file was created by <maarten> Fri Jul 23 14:44:46 1999 #LyX 1.1 created this file. For more info see http://www.lyx.org/
#LyX 1.0 (C) 1995-1999 Matthias Ettrich and the LyX Team \lyxformat 2.17
\lyxformat 2.15
\textclass article \textclass article
\language dutch \language dutch
\inputencoding default \inputencoding default
@ -28,29 +27,32 @@
Welkom bij LyX! Welkom bij LyX!
\layout Section* \layout Section*
De Belangrijkste N Dingen die je moet weten om LyX te gebruiken De Belangrijkste Dingen die je moet weten als je LyX gebruikt
\layout Enumerate \layout Enumerate
LyX komt met zeer goede documentatie---gebruik die! De documentatie is momenteel LyX komt met zeer goede documentatie---gebruik die! De documentatie is momenteel
nog niet in het Nederlands vertaald maar wordt in het Engels meegeleverd. nog niet volledig in het Nederlands vertaald maar wordt tevens in het Engels
meegeleverd.
Begin met Begin met
\family sans \family sans
\bar under \bar under
H H
\bar default \bar default
elp-> elp\SpecialChar \menuseparator
\bar under \bar under
I I
\bar default \bar default
ntroduction ntroduction
\family default \family default
, dat je een korte introductie tot de documentatie geeft. , wat je een korte inleiding tot de documentatie zal geven.
Leer daarna LyX te gebruiken met Leer daarna LyX te gebruiken met
\family sans \family sans
\bar under \bar under
H H
\bar default \bar default
elp-> elp\SpecialChar \menuseparator
\bar under \bar under
T T
\bar default \bar default
@ -68,8 +70,8 @@ document verwerker.
\end_inset \end_inset
LyX is bewust anders ontworpen dan normale tekstverwerkers---met LyX wordt LyX is bewust anders ontworpen dan normale tekstverwerkers---met LyX wordt
het schrijven van documenten makkelijker. het schrijven van teksten makkelijker.
Maar alleen een beetje anders, dus geen reden om bang te zijn. Een beetje anders maar geen reden om bang te zijn.
De documentatie zal het allemaal duidelijk maken De documentatie zal het allemaal duidelijk maken
\begin_float footnote \begin_float footnote
\layout Standard \layout Standard
@ -79,23 +81,23 @@ Hebben we al verteld dat je de documentatie moet lezen?
. .
\layout Enumerate \layout Enumerate
Het resultaat van LyX ziet er goed uit! Selecteer Het resultaat van LyX ziet er prachtig uit! Doe
\family sans \family sans
nu
\bar under \bar under
F V
\bar default \bar default
ile->View iew\SpecialChar \menuseparator
\protected_separator
\bar under \bar under
d D
\bar default \bar default
vi VI
\family default \family default
nu om het zelf te zien. om het zelf te zien.
\layout Enumerate \layout Enumerate
Ja, LyX kan (bijna) alle LaTeX functionaliteit nabootsen. Jazeker, LyX kan (bijna) alle LaTeX functionaliteit nabootsen.
En ja, LyX kan LaTeX bestanden importeren. En ja, LyX kan LaTeX bestanden importeren.
Ervaren LaTeX gebruikers kunnen de rest van de Ervaren LaTeX gebruikers kunnen de rest van de
\emph on \emph on
@ -114,10 +116,10 @@ LyX for LaTeX Users
te gebruiken.) te gebruiken.)
\layout Enumerate \layout Enumerate
LyX heeft veel mogelijkheden voor mensen die lezen en schrijven in een andere LyX heeft veel extras voor mensen die in een andere taal lezen of schrijven
taal dan Engels. dan het Engels.
Daarnaast zijn de bindingen voor het toetsenbord, de knoppenbalk en veel Daarnaast zijn de sneltoetsen, de knoppenbalk en veel andere zaken uiterst
andere zaken uiterst configureerbaar. configureerbaar.
(Meestal door je (Meestal door je
\family typewriter \family typewriter
lyxrc lyxrc
@ -128,7 +130,8 @@ lyxrc
\bar under \bar under
H H
\bar default \bar default
elp-> elp\SpecialChar \menuseparator
\bar under \bar under
C C
\bar default \bar default
@ -137,11 +140,16 @@ ustomization
voor de details. voor de details.
\layout Enumerate \layout Enumerate
De LyX homepage is De LyX home page is
\family typewriter \family typewriter
www.lyx.org
\begin_inset LatexCommand \url{http://www.lyx.org/}
\end_inset
\family default \family default
. .
Leer over LyX, abonneer op LyX email lijst(en), doe de LyX Graphical Tour, Haal informatie over LyX, abonneer je op LyX email lijst(en), doe de LyX
en meer. Graphical Tour, en meer.
\the_end \the_end

View File

@ -1,3 +1,9 @@
2001-01-08 Jean-Marc Lasgouttes <Jean-Marc.Lasgouttes@inria.fr>
* sl.po: update from Roman Maurer
* de.po: update from Pit
2001-01-08 Lars Gullik Bjønnes <larsbj@lyx.org> 2001-01-08 Lars Gullik Bjønnes <larsbj@lyx.org>
* no.po: update * no.po: update

3569
po/de.po

File diff suppressed because it is too large Load Diff

1721
po/sl.po

File diff suppressed because it is too large Load Diff

View File

@ -154,6 +154,7 @@ void FormDocument::build()
#ifdef USE_CLASS_COMBO #ifdef USE_CLASS_COMBO
// The language is a combo-box and has to be inserted manually // The language is a combo-box and has to be inserted manually
obj = class_->choice_doc_class; obj = class_->choice_doc_class;
fl_deactivate_object(obj);
fl_addto_form(class_->form); fl_addto_form(class_->form);
combo_doc_class = new Combox(FL_COMBOX_DROPLIST); combo_doc_class = new Combox(FL_COMBOX_DROPLIST);
combo_doc_class->add(obj->x, obj->y, obj->w, obj->h, 400, combo_doc_class->add(obj->x, obj->y, obj->w, obj->h, 400,
@ -214,6 +215,7 @@ void FormDocument::build()
// The language is a combo-box and has to be inserted manually // The language is a combo-box and has to be inserted manually
obj = language_->choice_language; obj = language_->choice_language;
fl_deactivate_object(obj);
fl_addto_form(language_->form); fl_addto_form(language_->form);
combo_language = new Combox(FL_COMBOX_DROPLIST); combo_language = new Combox(FL_COMBOX_DROPLIST);
combo_language->add(obj->x, obj->y, obj->w, obj->h, 400, combo_language->add(obj->x, obj->y, obj->w, obj->h, 400,
@ -234,7 +236,6 @@ void FormDocument::build()
_(" ``text'' | ''text'' | ,,text`` | ,,text'' |" _(" ``text'' | ''text'' | ,,text`` | ,,text'' |"
" «text» | »text« ")); " «text» | »text« "));
bc_.addReadOnly (language_->choice_language);
bc_.addReadOnly (language_->choice_inputenc); bc_.addReadOnly (language_->choice_inputenc);
// the document options form // the document options form

View File

@ -99,7 +99,7 @@ void BubbleTimerCB(FL_OBJECT *, long data)
// The trick we use to get the help text is to read the // The trick we use to get the help text is to read the
// argument of the callback that has been registered for // argument of the callback that has been registered for
// ToolBarCB. (JMarc) // ToolBarCB. (JMarc)
string help = lyxaction.helpText(ob->argument); string help = _(lyxaction.helpText(ob->argument));
fl_show_oneliner(help.c_str(), ob->form->x + ob->x, fl_show_oneliner(help.c_str(), ob->form->x + ob->x,
ob->form->y + ob->y + ob->h); ob->form->y + ob->y + ob->h);
} }
@ -384,7 +384,7 @@ void Toolbar::Pimpl::set(bool doingmain)
// Set the tooltip // Set the tooltip
#if FL_REVISION >= 89 #if FL_REVISION >= 89
string help = lyxaction.helpText(item->action); string help = _(lyxaction.helpText(item->action));
fl_set_object_helper(obj, help.c_str()); fl_set_object_helper(obj, help.c_str());
#else #else
fl_set_object_posthandler(obj, C_Toolbar_BubblePost); fl_set_object_posthandler(obj, C_Toolbar_BubblePost);

View File

@ -17,6 +17,12 @@
#include "lyxcursor.h" #include "lyxcursor.h"
LyXCursor::LyXCursor() : par_(0), pos_(0), boundary_(false),
x_(0), x_fix_(0), y_(0), row_(0)
{
}
void LyXCursor::par(LyXParagraph * p) void LyXCursor::par(LyXParagraph * p)
{ {
par_ = p; par_ = p;

View File

@ -24,6 +24,7 @@ struct Row;
*/ */
class LyXCursor { class LyXCursor {
public: public:
LyXCursor();
/// ///
void par(LyXParagraph * p); void par(LyXParagraph * p);
/// ///

View File

@ -45,6 +45,7 @@ void InitLyXLookup(Display * display, Window window)
<< endl; << endl;
// This part could be done before opening display // This part could be done before opening display
string oldlocale = setlocale(LC_CTYPE, 0);
setlocale(LC_CTYPE, ""); setlocale(LC_CTYPE, "");
if (!XSupportsLocale()) { if (!XSupportsLocale()) {
lyxerr[Debug::KEY] lyxerr[Debug::KEY]
@ -52,24 +53,32 @@ void InitLyXLookup(Display * display, Window window)
<< endl; << endl;
return; return;
} }
if (!XSetLocaleModifiers("")) { // reset the LC_CTYPE locale to previous value.
setlocale(LC_CTYPE, oldlocale.c_str());
char const * locmod;
if (!(locmod = XSetLocaleModifiers(""))) {
lyxerr[Debug::KEY] << "InitLyXLookup: Could not set modifiers " lyxerr[Debug::KEY] << "InitLyXLookup: Could not set modifiers "
"for this locale." << endl; "for this locale." << endl;
return; return;
} }
else
lyxerr[Debug::KEY] << "InitLyXLookup: X locale modifiers are `"
<< locmod << '\'' << endl;
// This part will have to be done for each frame // This part will have to be done for each frame
xim = XOpenIM (display, 0, 0, 0); xim = XOpenIM (display, 0, 0, 0);
if (xim) { if (xim) {
xic = XCreateIC(xim, XNInputStyle, xic = XCreateIC(xim,
XIMPreeditNothing | XIMStatusNothing, XNInputStyle,
XIMPreeditNothing|XIMStatusNothing,
XNClientWindow, window, XNClientWindow, window,
XNFocusWindow, window, XNFocusWindow, window,
0); 0);
if (!xic) { if (!xic) {
lyxerr[Debug::KEY] << "InitLyXLookup: could not create " lyxerr[Debug::KEY] << "InitLyXLookup: "
"an input context" << endl; "could not create an input context" << endl;
XCloseIM (xim); XCloseIM (xim);
xim = 0; xim = 0;
} }
@ -81,21 +90,11 @@ void InitLyXLookup(Display * display, Window window)
static static
bool isDeadEvent(XEvent * event, bool isDeadEvent(KeySym keysym)
char * buffer_return, int bytes_buffer,
KeySym * keysym_return)
{ {
XLookupString(&event->xkey, buffer_return,
bytes_buffer, keysym_return,
0);
// somehow it is necessary to do the lookup. Why? (JMarc)
if (!lyxrc.override_x_deadkeys)
return false;
// Can this be done safely in any other way? // Can this be done safely in any other way?
// This is all the dead keys I know of in X11R6.1 // This is all the dead keys I know of in X11R6.1
switch (*keysym_return) { switch (keysym) {
#ifdef XK_dead_grave #ifdef XK_dead_grave
case XK_dead_grave: case XK_dead_grave:
#endif #endif
@ -159,14 +158,27 @@ int LyXLookupString(XEvent * event,
char * buffer_return, int bytes_buffer, char * buffer_return, int bytes_buffer,
KeySym * keysym_return) KeySym * keysym_return)
{ {
if (event->type != KeyPress) {
lyxerr << "LyXLookupString: wrong event type: "
<< event->type << endl;
return 0;
}
int result = 0; int result = 0;
if (xic) { if (xic) {
if (isDeadEvent(event, buffer_return, bytes_buffer, #if 1
keysym_return)) { // somehow it is necessary to do the lookup. Why? (JMarc)
XLookupString(&event->xkey, buffer_return,
bytes_buffer, keysym_return,
0);
if (lyxrc.override_x_deadkeys &&
isDeadEvent(*keysym_return)) {
lyxerr[Debug::KEY] lyxerr[Debug::KEY]
<< "LyXLookupString: found DeadEvent" << endl; << "LyXLookupString: found DeadEvent" << endl;
return 0; return 0;
} }
#endif
#if 1 #if 1
if (XFilterEvent (event, None)) { if (XFilterEvent (event, None)) {
lyxerr[Debug::KEY] <<"XFilterEvent" << endl; lyxerr[Debug::KEY] <<"XFilterEvent" << endl;
@ -174,9 +186,6 @@ int LyXLookupString(XEvent * event,
return 0; return 0;
} }
#endif #endif
if (event->type != KeyPress)
lyxerr << "LyXLookupString: wrong event type"
<< event->type << endl;
Status status_return = 0; Status status_return = 0;
result = XmbLookupString(xic, &event->xkey, buffer_return, result = XmbLookupString(xic, &event->xkey, buffer_return,

View File

@ -969,6 +969,7 @@ bool RunSpellChecker(BufferView * bv)
#warning should go somewhere more sensible #warning should go somewhere more sensible
void sigchldhandler(pid_t pid, int * status) void sigchldhandler(pid_t pid, int * status)
{ {
#ifndef USE_PSPELL
if (isp_pid > 0) if (isp_pid > 0)
if (pid == isp_pid) { if (pid == isp_pid) {
isp_pid= -1; isp_pid= -1;
@ -976,5 +977,6 @@ void sigchldhandler(pid_t pid, int * status)
to nonblocking so we can to nonblocking so we can
continue */ continue */
} }
#endif
sigchldchecker(pid, status); sigchldchecker(pid, status);
} }