Fix bug in input of characters >127 ; update fr.po ; portability fix to lyxstring.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@364 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
Jean-Marc Lasgouttes 1999-12-10 14:45:32 +00:00
parent 15161a62ff
commit 1cebcbea99
7 changed files with 648 additions and 709 deletions

View File

@ -1,3 +1,18 @@
1999-12-10 Jean-Marc Lasgouttes <Jean-Marc.Lasgouttes@inria.fr>
* src/support/lyxstring.C: remove the inline added earlier since
they cause a bunch of unsatisfied symbols when linking with dec
cxx. Cxx likes to have the body of inlines at the place where they
are declared.
* src/trans.C (AddDeadkey): add an 'unsigned char' cast to avoid
accessing negative bounds in array. This fixes the crash when
inserting accented characters.
* src/trans.h (Match): ditto
* src/buffer.C (Dispatch): since this is a void, it should not try
to return anything...
1999-12-10 Lars Gullik Bjønnes <larsbj@lyx.org>
* src/buffer.h: removed the two friends from Buffer. Some changes

View File

@ -1,3 +1,7 @@
1999-12-09 Jean-Marc Lasgouttes <Jean-Marc.Lasgouttes@inria.fr>
* fr.po: updated.
1999-11-30 Lars Gullik Bjønnes <larsbj@lyx.org>
* *.po: obsolete entries removed after merge with

1216
po/fr.po

File diff suppressed because it is too large Load Diff

View File

@ -4198,7 +4198,7 @@ void Buffer::Dispatch(const string & command)
string cmd, line = frontStrip(command);
string arg = strip(frontStrip(split(line, cmd, ' ')));
return Dispatch(lyxaction.LookupFunc(cmd.c_str()), arg.c_str());
Dispatch(lyxaction.LookupFunc(cmd.c_str()), arg.c_str());
}
void Buffer::Dispatch(int action, const string & argument)

View File

@ -111,7 +111,6 @@ private:
};
inline
lyxstring::Srep::Srep(lyxstring::size_type nsz, const value_type * p)
{
// can be called with p == 0 by lyxstring::assign(const value_type *, size_type)
@ -131,7 +130,6 @@ lyxstring::Srep::Srep(lyxstring::size_type nsz, const value_type * p)
}
inline
lyxstring::Srep::Srep(lyxstring::size_type nsz, value_type ch)
{
sz = nsz;
@ -147,7 +145,6 @@ lyxstring::Srep::Srep(lyxstring::size_type nsz, value_type ch)
}
inline
void lyxstring::Srep::assign(lyxstring::size_type nsz, const value_type * p)
{
// can be called with p == 0 by lyxstring::assign(const value_type *, size_type)
@ -171,7 +168,6 @@ void lyxstring::Srep::assign(lyxstring::size_type nsz, const value_type * p)
}
inline
void lyxstring::Srep::assign(lyxstring::size_type nsz, value_type ch)
{
sz = nsz;
@ -189,7 +185,6 @@ void lyxstring::Srep::assign(lyxstring::size_type nsz, value_type ch)
}
inline
void lyxstring::Srep::append(lyxstring::size_type asz, const value_type * p)
{
register unsigned int const len = sz + asz;
@ -210,7 +205,6 @@ void lyxstring::Srep::append(lyxstring::size_type asz, const value_type * p)
}
inline
void lyxstring::Srep::push_back(value_type c)
{
s[sz] = c; // it is always room to put a value_type at the end
@ -227,7 +221,6 @@ void lyxstring::Srep::push_back(value_type c)
}
inline
void lyxstring::Srep::insert(lyxstring::size_type pos, const value_type * p,
lyxstring::size_type n)
{
@ -250,7 +243,6 @@ void lyxstring::Srep::insert(lyxstring::size_type pos, const value_type * p,
}
inline
void lyxstring::Srep::resize(size_type n, value_type c)
{
// This resets sz to res_arg
@ -265,7 +257,6 @@ void lyxstring::Srep::resize(size_type n, value_type c)
}
inline
void lyxstring::Srep::reserve(lyxstring::size_type res_arg)
{
// This keeps the old sz, but
@ -278,7 +269,6 @@ void lyxstring::Srep::reserve(lyxstring::size_type res_arg)
}
inline
void lyxstring::Srep::replace(lyxstring::size_type i, lyxstring::size_type n,
value_type const * p, size_type n2)
{
@ -351,7 +341,6 @@ private:
// NOTE: The easiest way to catch this snippet of the output is to wait for
// the splash screen to disappear and then open and close Help->Credits
//
inline
lyxstringInvariant::lyxstringInvariant(lyxstring const * ls) : object(ls)
{
// printf("lyxstringInvariant constructor\n");
@ -359,7 +348,6 @@ lyxstringInvariant::lyxstringInvariant(lyxstring const * ls) : object(ls)
}
inline
lyxstringInvariant::~lyxstringInvariant()
{
helper();
@ -367,7 +355,6 @@ lyxstringInvariant::~lyxstringInvariant()
}
inline
void lyxstringInvariant::helper() const
{
// Some of these tests might look pointless but they are
@ -400,7 +387,6 @@ lyxstring::size_type const lyxstring::npos =
static_cast<lyxstring::size_type>(-1);
inline
lyxstring::lyxstring()
{
static Srep empty_rep(0, "");
@ -409,7 +395,6 @@ lyxstring::lyxstring()
}
inline
lyxstring::lyxstring(lyxstring const & x, size_type pos, size_type n)
{
Assert(pos <= x.rep->sz); // STD!
@ -422,7 +407,6 @@ lyxstring::lyxstring(lyxstring const & x, size_type pos, size_type n)
}
inline
lyxstring::lyxstring(value_type const * s, size_type n)
{
Assert(s && n < npos); // STD!
@ -436,7 +420,6 @@ lyxstring::lyxstring(value_type const * s, size_type n)
}
inline
lyxstring::lyxstring(value_type const * s)
{
Assert(s); // STD!
@ -450,7 +433,6 @@ lyxstring::lyxstring(value_type const * s)
}
inline
lyxstring::lyxstring(size_type n, value_type c)
{
Assert(n < npos); // STD!
@ -458,14 +440,12 @@ lyxstring::lyxstring(size_type n, value_type c)
}
inline
lyxstring::lyxstring(const_iterator first, const_iterator last)
{
rep = new Srep(last - first, first);
}
inline
lyxstring::~lyxstring()
{
if (--rep->ref == 0) delete rep;
@ -475,56 +455,48 @@ lyxstring::~lyxstring()
// Iterators
///////////////////////
inline
lyxstring::iterator lyxstring::begin()
{
return rep->s;
}
inline
lyxstring::const_iterator lyxstring::begin() const
{
return rep->s;
}
inline
lyxstring::iterator lyxstring::end()
{
return rep->s + rep->sz;
}
inline
lyxstring::const_iterator lyxstring::end() const
{
return rep->s + rep->sz;
}
#if 0
inline
reverse_iterator lyxstring::rbegin()
{
return reverse_iterator( end() );
}
inline
const_reverse_iterator lyxstring::rbegin() const
{
return const_reverse_iterator( end() );
}
inline
reverse_iterator lyxstring::rend()
{
return reverse_iterator( begin() );
}
inline
const_reverse_iterator lyxstring::rend() const
{
return const_reverse_iterator( begin() );
@ -536,14 +508,12 @@ const_reverse_iterator lyxstring::rend() const
// Size and Capacity
///////////////////////
inline
lyxstring::size_type lyxstring::size() const
{
return rep->sz;
}
inline
void lyxstring::resize(size_type n, value_type c)
{
Assert(n <= npos); // STD!
@ -555,14 +525,12 @@ void lyxstring::resize(size_type n, value_type c)
}
inline
lyxstring::size_type lyxstring::capacity() const
{
return rep->res;
}
inline
void lyxstring::reserve(size_type res_arg)
{
TestlyxstringInvariant(this);
@ -576,7 +544,6 @@ void lyxstring::reserve(size_type res_arg)
// Assignment
////////////////
inline
lyxstring & lyxstring::operator= (lyxstring const & x)
{
TestlyxstringInvariant(this);
@ -585,7 +552,6 @@ lyxstring & lyxstring::operator= (lyxstring const & x)
}
inline
lyxstring & lyxstring::operator= (value_type const * s)
{
Assert(s); // OURS!
@ -596,7 +562,6 @@ lyxstring & lyxstring::operator= (value_type const * s)
}
inline
lyxstring & lyxstring::operator=(value_type c)
{
TestlyxstringInvariant(this);
@ -613,7 +578,6 @@ lyxstring & lyxstring::operator=(value_type c)
}
inline
lyxstring & lyxstring::assign(lyxstring const & x)
{
TestlyxstringInvariant(this);
@ -625,7 +589,6 @@ lyxstring & lyxstring::assign(lyxstring const & x)
}
inline
lyxstring & lyxstring::assign(lyxstring const & x, size_type pos, size_type n)
{
Assert(pos <= x.rep->sz); // STD!
@ -635,7 +598,6 @@ lyxstring & lyxstring::assign(lyxstring const & x, size_type pos, size_type n)
}
inline
lyxstring & lyxstring::assign(value_type const * s, size_type n)
{
Assert(s); // OURS!
@ -652,7 +614,6 @@ lyxstring & lyxstring::assign(value_type const * s, size_type n)
}
inline
lyxstring & lyxstring::assign(value_type const * s)
{
Assert(s); // OURS!
@ -662,7 +623,6 @@ lyxstring & lyxstring::assign(value_type const * s)
}
inline
lyxstring & lyxstring::assign(size_type n, value_type ch)
{
TestlyxstringInvariant(this);
@ -673,7 +633,6 @@ lyxstring & lyxstring::assign(size_type n, value_type ch)
}
inline
lyxstring & lyxstring::assign(const_iterator first, const_iterator last)
{
TestlyxstringInvariant(this);
@ -688,7 +647,6 @@ lyxstring & lyxstring::assign(const_iterator first, const_iterator last)
// Element Access
////////////////////
inline
lyxstring::const_reference lyxstring::operator[](size_type pos) const
{
Assert(pos <= rep->sz); // OURS!
@ -697,7 +655,6 @@ lyxstring::const_reference lyxstring::operator[](size_type pos) const
}
inline
lyxstring::reference lyxstring::operator[](size_type pos)
{
Assert(pos < rep->sz); // OURS!
@ -708,7 +665,6 @@ lyxstring::reference lyxstring::operator[](size_type pos)
}
inline
lyxstring::const_reference lyxstring::at(size_type n) const
{
Assert(n < rep->sz); // STD!
@ -716,7 +672,6 @@ lyxstring::const_reference lyxstring::at(size_type n) const
}
inline
lyxstring::reference lyxstring::at(size_type n)
{
Assert(n < rep->sz); // STD!
@ -731,7 +686,6 @@ lyxstring::reference lyxstring::at(size_type n)
// Insert
/////////////
inline
lyxstring & lyxstring::operator+=(lyxstring const & x)
{
TestlyxstringInvariant(this);
@ -740,7 +694,6 @@ lyxstring & lyxstring::operator+=(lyxstring const & x)
}
inline
lyxstring & lyxstring::operator+=(value_type const * x)
{
Assert(x); // OURS!
@ -750,7 +703,6 @@ lyxstring & lyxstring::operator+=(value_type const * x)
}
inline
lyxstring & lyxstring::operator+=(value_type c)
{
TestlyxstringInvariant(this);
@ -760,7 +712,6 @@ lyxstring & lyxstring::operator+=(value_type c)
}
inline
void lyxstring::push_back(value_type c)
{
TestlyxstringInvariant(this);
@ -770,7 +721,6 @@ void lyxstring::push_back(value_type c)
}
inline
lyxstring & lyxstring::append(lyxstring const & x)
{
TestlyxstringInvariant(this);
@ -782,7 +732,6 @@ lyxstring & lyxstring::append(lyxstring const & x)
}
inline
lyxstring & lyxstring::append(lyxstring const & x, size_type pos, size_type n)
{
Assert(pos <= x.rep->sz); // STD!
@ -792,7 +741,6 @@ lyxstring & lyxstring::append(lyxstring const & x, size_type pos, size_type n)
}
inline
lyxstring & lyxstring::append(value_type const * p, size_type n)
{
Assert(p); // OURS!
@ -805,7 +753,6 @@ lyxstring & lyxstring::append(value_type const * p, size_type n)
}
inline
lyxstring & lyxstring::append(value_type const * p)
{
Assert(p); // OURS!
@ -818,7 +765,6 @@ lyxstring & lyxstring::append(value_type const * p)
}
inline
lyxstring & lyxstring::append(size_type n, value_type c)
{
TestlyxstringInvariant(this);
@ -832,7 +778,6 @@ lyxstring & lyxstring::append(size_type n, value_type c)
}
inline
lyxstring & lyxstring::append(iterator first, iterator last)
{
TestlyxstringInvariant(this);
@ -844,7 +789,6 @@ lyxstring & lyxstring::append(iterator first, iterator last)
// insert value_typeacters before (*this)[pos]
inline
lyxstring & lyxstring::insert(size_type pos, lyxstring const & x)
{
TestlyxstringInvariant(this);
@ -853,7 +797,6 @@ lyxstring & lyxstring::insert(size_type pos, lyxstring const & x)
}
inline
lyxstring & lyxstring::insert(size_type pos, lyxstring const & x,
size_type pos2, size_type n)
{
@ -866,7 +809,6 @@ lyxstring & lyxstring::insert(size_type pos, lyxstring const & x,
}
inline
lyxstring & lyxstring::insert(size_type pos, value_type const * p, size_type n)
{
Assert(p); // OURS!
@ -881,7 +823,6 @@ lyxstring & lyxstring::insert(size_type pos, value_type const * p, size_type n)
}
inline
lyxstring & lyxstring::insert(size_type pos, value_type const * p)
{
Assert(p); // OURS!
@ -896,7 +837,6 @@ lyxstring & lyxstring::insert(size_type pos, value_type const * p)
}
inline
lyxstring & lyxstring::insert(size_type pos, size_type n, value_type c)
{
TestlyxstringInvariant(this);
@ -910,7 +850,6 @@ lyxstring & lyxstring::insert(size_type pos, size_type n, value_type c)
}
inline
lyxstring::iterator lyxstring::insert(iterator p, value_type c)
{
TestlyxstringInvariant(this);
@ -922,7 +861,6 @@ lyxstring::iterator lyxstring::insert(iterator p, value_type c)
}
inline
void lyxstring::insert(iterator p, size_type n , value_type c)
{
TestlyxstringInvariant(this);
@ -931,7 +869,6 @@ void lyxstring::insert(iterator p, size_type n , value_type c)
}
inline
void lyxstring::insert(iterator p, iterator first, iterator last)
{
TestlyxstringInvariant(this);
@ -949,7 +886,6 @@ void lyxstring::insert(iterator p, iterator first, iterator last)
// some of the parameters wrong, also some of the funcs can surely
// be written more effectively.
inline
lyxstring::size_type lyxstring::find(lyxstring const & a, size_type i) const
{
if (!rep->sz || i >= rep->sz) return npos;
@ -974,7 +910,6 @@ lyxstring::size_type lyxstring::find(lyxstring const & a, size_type i) const
}
inline
lyxstring::size_type lyxstring::find(value_type const * ptr, size_type i,
size_type n) const
{
@ -1006,7 +941,6 @@ lyxstring::size_type lyxstring::find(value_type const * ptr, size_type i,
}
inline
lyxstring::size_type lyxstring::find(value_type const * s, size_type i) const
{
Assert(s); // OURS!
@ -1019,7 +953,6 @@ lyxstring::size_type lyxstring::find(value_type const * s, size_type i) const
}
inline
lyxstring::size_type lyxstring::find(value_type c, size_type i) const
{
if (!rep->sz || i >= rep->sz) return npos;
@ -1033,7 +966,6 @@ lyxstring::size_type lyxstring::find(value_type c, size_type i) const
}
inline
lyxstring::size_type lyxstring::rfind(lyxstring const & a, size_type i) const
{
TestlyxstringInvariant(this);
@ -1053,7 +985,6 @@ lyxstring::size_type lyxstring::rfind(lyxstring const & a, size_type i) const
}
inline
lyxstring::size_type lyxstring::rfind(value_type const * ptr, size_type i,
size_type n) const
{
@ -1076,7 +1007,6 @@ lyxstring::size_type lyxstring::rfind(value_type const * ptr, size_type i,
}
inline
lyxstring::size_type lyxstring::rfind(value_type const * ptr,
size_type i) const
{
@ -1099,7 +1029,6 @@ lyxstring::size_type lyxstring::rfind(value_type const * ptr,
}
inline
lyxstring::size_type lyxstring::rfind(value_type c, size_type i) const
{
TestlyxstringInvariant(this);
@ -1112,7 +1041,6 @@ lyxstring::size_type lyxstring::rfind(value_type c, size_type i) const
}
inline
lyxstring::size_type lyxstring::find_first_of(lyxstring const & a,
size_type i) const
{
@ -1126,7 +1054,6 @@ lyxstring::size_type lyxstring::find_first_of(lyxstring const & a,
}
inline
lyxstring::size_type lyxstring::find_first_of(value_type const * ptr,
size_type i,
size_type n) const
@ -1142,7 +1069,6 @@ lyxstring::size_type lyxstring::find_first_of(value_type const * ptr,
}
inline
lyxstring::size_type lyxstring::find_first_of(value_type const * ptr,
size_type i) const
{
@ -1156,7 +1082,6 @@ lyxstring::size_type lyxstring::find_first_of(value_type const * ptr,
}
inline
lyxstring::size_type lyxstring::find_first_of(value_type c, size_type i) const
{
Assert(i < rep->sz); // OURS!
@ -1169,7 +1094,6 @@ lyxstring::size_type lyxstring::find_first_of(value_type c, size_type i) const
}
inline
lyxstring::size_type lyxstring::find_last_of(lyxstring const & a,
size_type i) const
{
@ -1183,7 +1107,6 @@ lyxstring::size_type lyxstring::find_last_of(lyxstring const & a,
}
inline
lyxstring::size_type lyxstring::find_last_of(value_type const * ptr,
size_type i,
size_type n) const
@ -1200,7 +1123,6 @@ lyxstring::size_type lyxstring::find_last_of(value_type const * ptr,
}
inline
lyxstring::size_type lyxstring::find_last_of(value_type const * ptr,
size_type i) const
{
@ -1215,7 +1137,6 @@ lyxstring::size_type lyxstring::find_last_of(value_type const * ptr,
}
inline
lyxstring::size_type lyxstring::find_last_of(value_type c, size_type i) const
{
TestlyxstringInvariant(this);
@ -1229,7 +1150,6 @@ lyxstring::size_type lyxstring::find_last_of(value_type c, size_type i) const
}
inline
lyxstring::size_type lyxstring::find_first_not_of(lyxstring const & a,
size_type i) const
{
@ -1244,7 +1164,6 @@ lyxstring::size_type lyxstring::find_first_not_of(lyxstring const & a,
}
inline
lyxstring::size_type lyxstring::find_first_not_of(value_type const * ptr,
size_type i,
size_type n) const
@ -1260,7 +1179,6 @@ lyxstring::size_type lyxstring::find_first_not_of(value_type const * ptr,
}
inline
lyxstring::size_type lyxstring::find_first_not_of(value_type const * ptr,
size_type i) const
{
@ -1274,7 +1192,6 @@ lyxstring::size_type lyxstring::find_first_not_of(value_type const * ptr,
}
inline
lyxstring::size_type lyxstring::find_first_not_of(value_type c,
size_type i) const
{
@ -1289,7 +1206,6 @@ lyxstring::size_type lyxstring::find_first_not_of(value_type c,
}
inline
lyxstring::size_type lyxstring::find_last_not_of(lyxstring const & a,
size_type i) const
{
@ -1303,7 +1219,6 @@ lyxstring::size_type lyxstring::find_last_not_of(lyxstring const & a,
}
inline
lyxstring::size_type lyxstring::find_last_not_of(value_type const * ptr,
size_type i,
size_type n) const
@ -1321,7 +1236,6 @@ lyxstring::size_type lyxstring::find_last_not_of(value_type const * ptr,
}
inline
lyxstring::size_type lyxstring::find_last_not_of(value_type const * ptr,
size_type i) const
{
@ -1336,7 +1250,6 @@ lyxstring::size_type lyxstring::find_last_not_of(value_type const * ptr,
}
inline
lyxstring::size_type lyxstring::find_last_not_of(value_type c,
size_type i) const
{
@ -1354,7 +1267,6 @@ lyxstring::size_type lyxstring::find_last_not_of(value_type c,
// Replace
/////////////////
inline
lyxstring & lyxstring::replace(size_type i, size_type n, lyxstring const & x)
{
Assert(i <= rep->sz); // OURS!
@ -1364,7 +1276,6 @@ lyxstring & lyxstring::replace(size_type i, size_type n, lyxstring const & x)
}
inline
lyxstring & lyxstring::replace(size_type i, size_type n, lyxstring const & x,
size_type i2, size_type n2)
{
@ -1377,7 +1288,6 @@ lyxstring & lyxstring::replace(size_type i, size_type n, lyxstring const & x,
}
inline
lyxstring & lyxstring::replace(size_type i, size_type n,
value_type const * p, size_type n2)
{
@ -1390,7 +1300,6 @@ lyxstring & lyxstring::replace(size_type i, size_type n,
}
inline
lyxstring & lyxstring::replace(size_type i, size_type n, value_type const * p)
{
Assert(p && i < rep->sz); // OURS!
@ -1400,7 +1309,6 @@ lyxstring & lyxstring::replace(size_type i, size_type n, value_type const * p)
}
inline
lyxstring & lyxstring::replace(size_type i, size_type n,
size_type n2, value_type c)
{
@ -1416,7 +1324,6 @@ lyxstring & lyxstring::replace(size_type i, size_type n,
}
inline
lyxstring & lyxstring::replace(iterator i, iterator i2, const lyxstring & str)
{
TestlyxstringInvariant(this);
@ -1425,7 +1332,6 @@ lyxstring & lyxstring::replace(iterator i, iterator i2, const lyxstring & str)
}
inline
lyxstring & lyxstring::replace(iterator i, iterator i2,
value_type const * p, size_type n)
{
@ -1436,7 +1342,6 @@ lyxstring & lyxstring::replace(iterator i, iterator i2,
}
inline
lyxstring & lyxstring::replace(iterator i, iterator i2, value_type const * p)
{
Assert(p); // OURS!
@ -1446,7 +1351,6 @@ lyxstring & lyxstring::replace(iterator i, iterator i2, value_type const * p)
}
inline
lyxstring & lyxstring::replace(iterator i, iterator i2,
size_type n , value_type c)
{
@ -1456,7 +1360,6 @@ lyxstring & lyxstring::replace(iterator i, iterator i2,
}
inline
lyxstring & lyxstring::replace(iterator i, iterator i2,
iterator j, iterator j2)
{
@ -1466,7 +1369,6 @@ lyxstring & lyxstring::replace(iterator i, iterator i2,
}
inline
void lyxstring::swap(lyxstring & str)
{
if (rep == str.rep) return;
@ -1476,7 +1378,6 @@ void lyxstring::swap(lyxstring & str)
}
inline
lyxstring & lyxstring::erase(size_type i, size_type n)
{
Assert(i <= rep->sz); // STD!
@ -1494,7 +1395,6 @@ lyxstring & lyxstring::erase(size_type i, size_type n)
}
inline
lyxstring::iterator lyxstring::erase(iterator i)
{
TestlyxstringInvariant(this);
@ -1506,7 +1406,6 @@ lyxstring::iterator lyxstring::erase(iterator i)
}
inline
lyxstring::iterator lyxstring::erase(iterator first, iterator last)
{
TestlyxstringInvariant(this);
@ -1520,7 +1419,6 @@ lyxstring::iterator lyxstring::erase(iterator first, iterator last)
// Conversion to C-style Strings
/////////////////////////////////////
inline
lyxstring::value_type const * lyxstring::c_str() const
{
rep->s[length()] = '\0';
@ -1528,14 +1426,12 @@ lyxstring::value_type const * lyxstring::c_str() const
}
inline
lyxstring::value_type const * lyxstring::data() const
{
return rep->s;
}
inline
lyxstring::size_type lyxstring::copy(value_type * buf, size_type len,
size_type pos) const
{
@ -1555,7 +1451,6 @@ lyxstring::size_type lyxstring::copy(value_type * buf, size_type len,
// Compare funcs should be verified.
inline
int lyxstring::internal_compare(size_type pos, size_type n,
value_type const * s,
size_type slen, size_type n2) const
@ -1579,7 +1474,6 @@ int lyxstring::internal_compare(size_type pos, size_type n,
}
inline
int lyxstring::compare(lyxstring const & str) const
{
TestlyxstringInvariant(this);
@ -1588,7 +1482,6 @@ int lyxstring::compare(lyxstring const & str) const
}
inline
int lyxstring::compare(value_type const * s) const
{
Assert(s); //OURS!
@ -1598,7 +1491,6 @@ int lyxstring::compare(value_type const * s) const
}
inline
int lyxstring::compare(size_type pos, size_type n,
lyxstring const & str) const
{
@ -1608,7 +1500,6 @@ int lyxstring::compare(size_type pos, size_type n,
}
inline
int lyxstring::compare(size_type pos, size_type n, lyxstring const & str,
size_type pos2, size_type n2) const
{
@ -1621,7 +1512,6 @@ int lyxstring::compare(size_type pos, size_type n, lyxstring const & str,
}
inline
int lyxstring::compare(size_type pos, size_type n, value_type const * s,
size_type n2) const
{
@ -1636,7 +1526,6 @@ int lyxstring::compare(size_type pos, size_type n, value_type const * s,
/////////////////
// i = index, n = length
inline
lyxstring lyxstring::substr(size_type i, size_type n) const
{
Assert(i <= rep->sz); // STD!

View File

@ -162,9 +162,7 @@ void Trans::AddDeadkey(tex_accent accent, string const & keys,
for(string::size_type i = 0; i < keys.length(); ++i) {
char * temp;
if (keys[i] == char(254))
lyxerr << "check one triggered" << endl;
temp = keymap_[keys[i]] = new char[2];
temp = keymap_[static_cast<unsigned char>(keys[i])] = new char[2];
temp[0] = 0; temp[1] = accent;
}
kmod_list_[accent]->exception_list = 0;
@ -276,9 +274,6 @@ int Trans::Load(LyXLex & lex)
if (lex.next(true)) {
char const * t = lex.text();
string_to = strcpy(new char[strlen(t)+1], t);
if (key_from == 254)
lyxerr << "check two triggered"
<< endl;
keymap_[key_from] = string_to;
if (lyxerr.debugging(Debug::KBMAP))
lyxerr << "\t`" << string_to << "'"

View File

@ -97,7 +97,7 @@ private:
char * Trans::Match(char c)
{
return keymap_[c];
return keymap_[static_cast<unsigned char>(c)];
}
#endif