The std::string mammoth path.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@7862 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
Lars Gullik Bjønnes 2003-10-06 15:43:21 +00:00
parent 05f3c80f92
commit 44cd0fc9a1
721 changed files with 2825 additions and 2435 deletions

View File

@ -1,7 +1,14 @@
2003-10-06 Lars Gullik Bjønnes <larsbj@gullik.net>
* INSTALL: remove a comment about --with-included-string
* configure.ac: remove the configure are
--with-included-string
2003-09-21 Lars Gullik Bjønnes <larsbj@gullik.net>
* configure.ac (FORNTENDS): use tabs to align message, make gtk
not delete info about other frontends
not delete info about other frontends
2003-09-16 Lars Gullik Bjønnes <larsbj@gullik.net>

View File

@ -366,9 +366,6 @@ notify us.
then you need to upgrade the version of the xforms library you have
installed.
o On solaris 2.6, you may have to compile with --with-included-string
if compiling with gcc 2.95.2.
o On SUN Sparc Solaris 8, you need gnumake. The LyX makefiles do not
work with Solaris make.

View File

@ -369,7 +369,7 @@ public:
r.release();
}
#endif
#endif
~shared_count() // nothrow
{

View File

@ -7,11 +7,11 @@
// Aleksey Gurtovoy
//
// Permission to use, copy, modify, distribute and sell this software
// and its documentation for any purpose is hereby granted without fee,
// provided that the above copyright notice appears in all copies and
// that both the copyright notice and this permission notice appear in
// supporting documentation. No representations are made about the
// suitability of this software for any purpose. It is provided "as is"
// and its documentation for any purpose is hereby granted without fee,
// provided that the above copyright notice appears in all copies and
// that both the copyright notice and this permission notice appear in
// supporting documentation. No representations are made about the
// suitability of this software for any purpose. It is provided "as is"
// without express or implied warranty.
#ifndef BOOST_MPL_AUX_TEMPLATE_ARITY_FWD_HPP_INCLUDED

View File

@ -1,4 +1,3 @@
#ifndef BOOST_MPL_BOOL_FWD_HPP_INCLUDED
#define BOOST_MPL_BOOL_FWD_HPP_INCLUDED
@ -9,11 +8,11 @@
// Aleksey Gurtovoy
//
// Permission to use, copy, modify, distribute and sell this software
// and its documentation for any purpose is hereby granted without fee,
// provided that the above copyright notice appears in all copies and
// that both the copyright notice and this permission notice appear in
// supporting documentation. No representations are made about the
// suitability of this software for any purpose. It is provided "as is"
// and its documentation for any purpose is hereby granted without fee,
// provided that the above copyright notice appears in all copies and
// that both the copyright notice and this permission notice appear in
// supporting documentation. No representations are made about the
// suitability of this software for any purpose. It is provided "as is"
// without express or implied warranty.
//
// See http://www.boost.org/libs/mpl for documentation.

View File

@ -238,7 +238,7 @@ public:
BOOST_ASSERT(px != 0);
return px;
}
T * get() const // never throws
{
return px;
@ -404,7 +404,7 @@ using std::basic_ostream;
template<class E, class T, class Y> basic_ostream<E, T> & operator<< (basic_ostream<E, T> & os, shared_ptr<Y> const & p)
# else
template<class E, class T, class Y> std::basic_ostream<E, T> & operator<< (std::basic_ostream<E, T> & os, shared_ptr<Y> const & p)
# endif
# endif
{
os << p.get();
return os;
@ -437,7 +437,7 @@ template<class D, class T> D * get_deleter(shared_ptr<T> const & p)
#ifdef BOOST_MSVC
# pragma warning(pop)
#endif
#endif
#endif // #if defined(BOOST_NO_MEMBER_TEMPLATES) && !defined(BOOST_MSVC6_MEMBER_TEMPLATES)

View File

@ -1,5 +1,5 @@
// (C) Copyright Gennadiy Rozental 2002.
// (C) Copyright Daryle Walker 2000-2001.
// (C) Copyright Daryle Walker 2000-2001.
// Permission to copy, use, modify, sell and distribute this software
// is granted provided this copyright notice appears in all copies.
// This software is provided "as is" without express or implied warranty,
@ -9,7 +9,7 @@
//
// File : $RCSfile: nullstream.hpp,v $
//
// Version : $Id: nullstream.hpp,v 1.3 2003/02/15 21:57:25 rogeeff Exp $
// Version : $Id: nullstream.hpp,v 1.1 2003/09/26 14:27:18 larsbj Exp $
//
// Description : simulate /dev/null stream
// ***************************************************************************

View File

@ -3,36 +3,36 @@
// Copyright (C) 1999, 2000 Jaakko Järvi (jaakko.jarvi@cs.utu.fi)
//
// Permission to copy, use, sell and distribute this software is granted
// provided this copyright notice appears in all copies.
// provided this copyright notice appears in all copies.
// Permission to modify the code and to distribute modified code is granted
// provided this copyright notice appears in all copies, and a notice
// provided this copyright notice appears in all copies, and a notice
// that the code was modified is included with the copyright notice.
//
// This software is provided "as is" without express or implied warranty,
// This software is provided "as is" without express or implied warranty,
// and with no claim as to its suitability for any purpose.
// For more information, see http://www.boost.org
// Outside help:
// This and that, Gary Powell.
// Fixed return types for get_head/get_tail
// Fixed return types for get_head/get_tail
// ( and other bugs ) per suggestion of Jens Maurer
// simplified element type accessors + bug fix (Jeremy Siek)
// Several changes/additions according to suggestions by Doug Gregor,
// Several changes/additions according to suggestions by Doug Gregor,
// William Kempf, Vesa Karvonen, John Max Skaller, Ed Brey, Beman Dawes,
// David Abrahams.
// Revision history:
// 2002 05 01 Hugo Duncan: Fix for Borland after Jaakko's previous changes
// 2002 04 18 Jaakko: tuple element types can be void or plain function
// 2002 04 18 Jaakko: tuple element types can be void or plain function
// types, as long as no object is created.
// Tuple objects can no hold even noncopyable types
// such as arrays.
// such as arrays.
// 2001 10 22 John Maddock
// Fixes for Borland C++
// 2001 08 30 David Abrahams
// Added default constructor for cons<>.
// -----------------------------------------------------------------
// -----------------------------------------------------------------
#ifndef BOOST_TUPLE_BASIC_HPP
#define BOOST_TUPLE_BASIC_HPP
@ -42,7 +42,7 @@
#include "boost/type_traits/cv_traits.hpp"
#include "boost/type_traits/function_traits.hpp"
namespace boost {
namespace tuples {
@ -66,16 +66,16 @@ template <class Then, class Else> struct IF<false, Then, Else> {
} // end detail
// - cons forward declaration -----------------------------------------------
template <class HT, class TT> struct cons;
template <class HT, class TT> struct cons;
// - tuple forward declaration -----------------------------------------------
template <
class T0 = null_type, class T1 = null_type, class T2 = null_type,
class T3 = null_type, class T4 = null_type, class T5 = null_type,
class T6 = null_type, class T7 = null_type, class T8 = null_type,
class T0 = null_type, class T1 = null_type, class T2 = null_type,
class T3 = null_type, class T4 = null_type, class T5 = null_type,
class T6 = null_type, class T7 = null_type, class T8 = null_type,
class T9 = null_type>
class tuple;
class tuple;
// tuple_length forward declaration
template<class T> struct length;
@ -95,7 +95,7 @@ namespace detail {
# define BOOST_TUPLE_SINGLE_DUMMY_PARM
#endif
// -- generate error template, referencing to non-existing members of this
// -- generate error template, referencing to non-existing members of this
// template is used to produce compilation errors intentionally
template<class T>
class generate_error;
@ -119,12 +119,12 @@ struct get_class {
template<>
struct get_class<0> {
template<class RET, class HT, class TT>
template<class RET, class HT, class TT>
inline static RET get(const cons<HT, TT>& t)
{
return t.head;
}
template<class RET, class HT, class TT>
template<class RET, class HT, class TT>
inline static RET get(cons<HT, TT>& t)
{
return t.head;
@ -135,7 +135,7 @@ struct get_class<0> {
// -cons type accessors ----------------------------------------
// typename tuples::element<N,T>::type gets the type of the
// typename tuples::element<N,T>::type gets the type of the
// Nth element ot T, first element is at index 0
// -------------------------------------------------------
@ -194,8 +194,8 @@ template <class T> struct access_traits<T&> {
typedef T& const_type;
typedef T& non_const_type;
typedef T& parameter_type;
typedef T& parameter_type;
};
// get function for non-const cons-lists, returns a reference to the element
@ -204,13 +204,13 @@ template<int N, class HT, class TT>
inline typename access_traits<
typename element<N, cons<HT, TT> >::type
>::non_const_type
get(cons<HT, TT>& c BOOST_TUPLE_DUMMY_PARM) {
return detail::get_class<N>::BOOST_NESTED_TEMPLATE
get(cons<HT, TT>& c BOOST_TUPLE_DUMMY_PARM) {
return detail::get_class<N>::BOOST_NESTED_TEMPLATE
get<
typename access_traits<
typename element<N, cons<HT, TT> >::type
>::non_const_type>(c);
}
>::non_const_type>(c);
}
// get function for const cons-lists, returns a const reference to
// the element. If the element is a reference, returns the reference
@ -219,13 +219,13 @@ template<int N, class HT, class TT>
inline typename access_traits<
typename element<N, cons<HT, TT> >::type
>::const_type
get(const cons<HT, TT>& c BOOST_TUPLE_DUMMY_PARM) {
return detail::get_class<N>::BOOST_NESTED_TEMPLATE
get(const cons<HT, TT>& c BOOST_TUPLE_DUMMY_PARM) {
return detail::get_class<N>::BOOST_NESTED_TEMPLATE
get<
typename access_traits<
typename element<N, cons<HT, TT> >::type
>::const_type>(c);
}
}
// -- the cons template --------------------------------------------------
namespace detail {
@ -246,7 +246,7 @@ template <class T> struct wrap_non_storeable_type {
>::RET type;
};
template <> struct wrap_non_storeable_type<void> {
typedef non_storeable_type<void> type;
typedef non_storeable_type<void> type;
};
} // detail
@ -257,49 +257,49 @@ struct cons {
typedef HT head_type;
typedef TT tail_type;
typedef typename
typedef typename
detail::wrap_non_storeable_type<head_type>::type stored_head_type;
stored_head_type head;
tail_type tail;
typename access_traits<stored_head_type>::non_const_type
typename access_traits<stored_head_type>::non_const_type
get_head() { return head; }
typename access_traits<tail_type>::non_const_type
get_tail() { return tail; }
typename access_traits<tail_type>::non_const_type
get_tail() { return tail; }
typename access_traits<stored_head_type>::const_type
typename access_traits<stored_head_type>::const_type
get_head() const { return head; }
typename access_traits<tail_type>::const_type
get_tail() const { return tail; }
typename access_traits<tail_type>::const_type
get_tail() const { return tail; }
cons() : head(), tail() {}
// cons() : head(detail::default_arg<HT>::f()), tail() {}
// the argument for head is not strictly needed, but it prevents
// array type elements. This is good, since array type elements
// cannot be supported properly in any case (no assignment,
// the argument for head is not strictly needed, but it prevents
// array type elements. This is good, since array type elements
// cannot be supported properly in any case (no assignment,
// copy works only if the tails are exactly the same type, ...)
cons(typename access_traits<stored_head_type>::parameter_type h,
const tail_type& t)
: head (h), tail(t) {}
: head (h), tail(t) {}
template <class T1, class T2, class T3, class T4, class T5,
template <class T1, class T2, class T3, class T4, class T5,
class T6, class T7, class T8, class T9, class T10>
cons( T1& t1, T2& t2, T3& t3, T4& t4, T5& t5,
T6& t6, T7& t7, T8& t8, T9& t9, T10& t10 )
: head (t1),
cons( T1& t1, T2& t2, T3& t3, T4& t4, T5& t5,
T6& t6, T7& t7, T8& t8, T9& t9, T10& t10 )
: head (t1),
tail (t2, t3, t4, t5, t6, t7, t8, t9, t10, detail::cnull())
{}
template <class T2, class T3, class T4, class T5,
template <class T2, class T3, class T4, class T5,
class T6, class T7, class T8, class T9, class T10>
cons( const null_type& t1, T2& t2, T3& t3, T4& t4, T5& t5,
T6& t6, T7& t7, T8& t8, T9& t9, T10& t10 )
: head (),
cons( const null_type& t1, T2& t2, T3& t3, T4& t4, T5& t5,
T6& t6, T7& t7, T8& t8, T9& t9, T10& t10 )
: head (),
tail (t2, t3, t4, t5, t6, t7, t8, t9, t10, detail::cnull())
{}
@ -308,18 +308,18 @@ struct cons {
cons( const cons<HT2, TT2>& u ) : head(u.head), tail(u.tail) {}
template <class HT2, class TT2>
cons& operator=( const cons<HT2, TT2>& u ) {
head=u.head; tail=u.tail; return *this;
cons& operator=( const cons<HT2, TT2>& u ) {
head=u.head; tail=u.tail; return *this;
}
// must define assignment operator explicitly, implicit version is
// must define assignment operator explicitly, implicit version is
// illformed if HT is a reference (12.8. (12))
cons& operator=(const cons& u) {
head = u.head; tail = u.tail; return *this;
cons& operator=(const cons& u) {
head = u.head; tail = u.tail; return *this;
}
template <class T1, class T2>
cons& operator=( const std::pair<T1, T2>& u ) {
cons& operator=( const std::pair<T1, T2>& u ) {
BOOST_STATIC_ASSERT(length<cons>::value == 2); // check length = 2
head = u.first; tail.head = u.second; return *this;
}
@ -349,47 +349,47 @@ struct cons<HT, null_type> {
typedef null_type tail_type;
typedef cons<HT, null_type> self_type;
typedef typename
typedef typename
detail::wrap_non_storeable_type<head_type>::type stored_head_type;
stored_head_type head;
typename access_traits<stored_head_type>::non_const_type
get_head() { return head; }
null_type get_tail() { return null_type(); }
typename access_traits<stored_head_type>::const_type
typename access_traits<stored_head_type>::non_const_type
get_head() { return head; }
null_type get_tail() { return null_type(); }
typename access_traits<stored_head_type>::const_type
get_head() const { return head; }
const null_type get_tail() const { return null_type(); }
const null_type get_tail() const { return null_type(); }
// cons() : head(detail::default_arg<HT>::f()) {}
cons() : head() {}
cons(typename access_traits<stored_head_type>::parameter_type h,
const null_type& = null_type())
: head (h) {}
: head (h) {}
template<class T1>
cons(T1& t1, const null_type&, const null_type&, const null_type&,
const null_type&, const null_type&, const null_type&,
cons(T1& t1, const null_type&, const null_type&, const null_type&,
const null_type&, const null_type&, const null_type&,
const null_type&, const null_type&, const null_type&)
: head (t1) {}
cons(const null_type&,
const null_type&, const null_type&, const null_type&,
const null_type&, const null_type&, const null_type&,
cons(const null_type&,
const null_type&, const null_type&, const null_type&,
const null_type&, const null_type&, const null_type&,
const null_type&, const null_type&, const null_type&)
: head () {}
template <class HT2>
cons( const cons<HT2, null_type>& u ) : head(u.head) {}
template <class HT2>
cons& operator=(const cons<HT2, null_type>& u )
cons& operator=(const cons<HT2, null_type>& u )
{ head = u.head; return *this; }
// must define assignment operator explicitely, implicit version
// must define assignment operator explicitely, implicit version
// is illformed if HT is a reference
cons& operator=(const cons& u) { head = u.head; return *this; }
@ -432,12 +432,12 @@ struct length<null_type> {
namespace detail {
// Tuple to cons mapper --------------------------------------------------
template <class T0, class T1, class T2, class T3, class T4,
template <class T0, class T1, class T2, class T3, class T4,
class T5, class T6, class T7, class T8, class T9>
struct map_tuple_to_cons
{
typedef cons<T0,
typename map_tuple_to_cons<T1, T2, T3, T4, T5,
typedef cons<T0,
typename map_tuple_to_cons<T1, T2, T3, T4, T5,
T6, T7, T8, T9, null_type>::type
> type;
};
@ -453,46 +453,46 @@ struct map_tuple_to_cons<null_type, null_type, null_type, null_type, null_type,
// -------------------------------------------------------------------
// -- tuple ------------------------------------------------------
template <class T0, class T1, class T2, class T3, class T4,
template <class T0, class T1, class T2, class T3, class T4,
class T5, class T6, class T7, class T8, class T9>
class tuple :
public detail::map_tuple_to_cons<T0, T1, T2, T3, T4, T5, T6, T7, T8, T9>::type
class tuple :
public detail::map_tuple_to_cons<T0, T1, T2, T3, T4, T5, T6, T7, T8, T9>::type
{
public:
typedef typename
typedef typename
detail::map_tuple_to_cons<T0, T1, T2, T3, T4, T5, T6, T7, T8, T9>::type inherited;
typedef typename inherited::head_type head_type;
typedef typename inherited::tail_type tail_type;
typedef typename inherited::tail_type tail_type;
// access_traits<T>::parameter_type takes non-reference types as const T&
// access_traits<T>::parameter_type takes non-reference types as const T&
tuple() {}
tuple(typename access_traits<T0>::parameter_type t0)
: inherited(t0, detail::cnull(), detail::cnull(), detail::cnull(),
detail::cnull(), detail::cnull(), detail::cnull(),
: inherited(t0, detail::cnull(), detail::cnull(), detail::cnull(),
detail::cnull(), detail::cnull(), detail::cnull(),
detail::cnull(), detail::cnull(), detail::cnull()) {}
tuple(typename access_traits<T0>::parameter_type t0,
typename access_traits<T1>::parameter_type t1)
: inherited(t0, t1, detail::cnull(), detail::cnull(),
detail::cnull(), detail::cnull(), detail::cnull(),
: inherited(t0, t1, detail::cnull(), detail::cnull(),
detail::cnull(), detail::cnull(), detail::cnull(),
detail::cnull(), detail::cnull(), detail::cnull()) {}
tuple(typename access_traits<T0>::parameter_type t0,
typename access_traits<T1>::parameter_type t1,
typename access_traits<T2>::parameter_type t2)
: inherited(t0, t1, t2, detail::cnull(), detail::cnull(),
detail::cnull(), detail::cnull(), detail::cnull(),
: inherited(t0, t1, t2, detail::cnull(), detail::cnull(),
detail::cnull(), detail::cnull(), detail::cnull(),
detail::cnull(), detail::cnull()) {}
tuple(typename access_traits<T0>::parameter_type t0,
typename access_traits<T1>::parameter_type t1,
typename access_traits<T2>::parameter_type t2,
typename access_traits<T3>::parameter_type t3)
: inherited(t0, t1, t2, t3, detail::cnull(), detail::cnull(),
detail::cnull(), detail::cnull(), detail::cnull(),
: inherited(t0, t1, t2, t3, detail::cnull(), detail::cnull(),
detail::cnull(), detail::cnull(), detail::cnull(),
detail::cnull()) {}
tuple(typename access_traits<T0>::parameter_type t0,
@ -500,7 +500,7 @@ public:
typename access_traits<T2>::parameter_type t2,
typename access_traits<T3>::parameter_type t3,
typename access_traits<T4>::parameter_type t4)
: inherited(t0, t1, t2, t3, t4, detail::cnull(), detail::cnull(),
: inherited(t0, t1, t2, t3, t4, detail::cnull(), detail::cnull(),
detail::cnull(), detail::cnull(), detail::cnull()) {}
tuple(typename access_traits<T0>::parameter_type t0,
@ -509,7 +509,7 @@ public:
typename access_traits<T3>::parameter_type t3,
typename access_traits<T4>::parameter_type t4,
typename access_traits<T5>::parameter_type t5)
: inherited(t0, t1, t2, t3, t4, t5, detail::cnull(), detail::cnull(),
: inherited(t0, t1, t2, t3, t4, t5, detail::cnull(), detail::cnull(),
detail::cnull(), detail::cnull()) {}
tuple(typename access_traits<T0>::parameter_type t0,
@ -519,7 +519,7 @@ public:
typename access_traits<T4>::parameter_type t4,
typename access_traits<T5>::parameter_type t5,
typename access_traits<T6>::parameter_type t6)
: inherited(t0, t1, t2, t3, t4, t5, t6, detail::cnull(),
: inherited(t0, t1, t2, t3, t4, t5, t6, detail::cnull(),
detail::cnull(), detail::cnull()) {}
tuple(typename access_traits<T0>::parameter_type t0,
@ -530,7 +530,7 @@ public:
typename access_traits<T5>::parameter_type t5,
typename access_traits<T6>::parameter_type t6,
typename access_traits<T7>::parameter_type t7)
: inherited(t0, t1, t2, t3, t4, t5, t6, t7, detail::cnull(),
: inherited(t0, t1, t2, t3, t4, t5, t6, t7, detail::cnull(),
detail::cnull()) {}
tuple(typename access_traits<T0>::parameter_type t0,
@ -561,16 +561,16 @@ public:
tuple(const cons<U1, U2>& p) : inherited(p) {}
template <class U1, class U2>
tuple& operator=(const cons<U1, U2>& k) {
inherited::operator=(k);
tuple& operator=(const cons<U1, U2>& k) {
inherited::operator=(k);
return *this;
}
template <class U1, class U2>
tuple& operator=(const std::pair<U1, U2>& k) {
tuple& operator=(const std::pair<U1, U2>& k) {
BOOST_STATIC_ASSERT(length<tuple>::value == 2);// check_length = 2
this->head = k.first;
this->tail.head = k.second;
this->tail.head = k.second;
return *this;
}
@ -578,8 +578,8 @@ public:
// The empty tuple
template <>
class tuple<null_type, null_type, null_type, null_type, null_type, null_type, null_type, null_type, null_type, null_type> :
public null_type
class tuple<null_type, null_type, null_type, null_type, null_type, null_type, null_type, null_type, null_type, null_type> :
public null_type
{
public:
typedef null_type inherited;
@ -590,7 +590,7 @@ public:
namespace detail {
struct swallow_assign {
template<typename T>
swallow_assign& operator=(const T&) {
return *this;
@ -599,7 +599,7 @@ struct swallow_assign {
} // namespace detail
// "ignore" allows tuple positions to be ignored when using "tie".
// "ignore" allows tuple positions to be ignored when using "tie".
namespace {
detail::swallow_assign ignore;
}
@ -614,7 +614,7 @@ namespace {
// from template<class T> foo(T& t) : make_tuple_traits<T>::type
// Conversions:
// T -> T,
// T -> T,
// references -> compile_time_error
// reference_wrapper<T> -> T&
// const reference_wrapper<T> -> T&
@ -623,19 +623,19 @@ namespace {
template<class T>
struct make_tuple_traits {
typedef T type;
typedef T type;
// commented away, see below (JJ)
// typedef typename IF<
// typedef typename IF<
// boost::is_function<T>::value,
// T&,
// T>::RET type;
};
// The is_function test was there originally for plain function types,
// The is_function test was there originally for plain function types,
// which can't be stored as such (we must either store them as references or
// pointers). Such a type could be formed if make_tuple was called with a
// pointers). Such a type could be formed if make_tuple was called with a
// reference to a function.
// But this would mean that a const qualified function type was formed in
// the make_tuple function and hence make_tuple can't take a function
@ -650,17 +650,17 @@ struct make_tuple_traits<T&> {
typedef typename
detail::generate_error<T&>::
do_not_use_with_reference_type error;
};
};
// Arrays can't be stored as plain types; convert them to references.
// All arrays are converted to const. This is because make_tuple takes its
// parameters as const T& and thus the knowledge of the potential
// parameters as const T& and thus the knowledge of the potential
// non-constness of actual argument is lost.
template<class T, int n> struct make_tuple_traits <T[n]> {
typedef const T (&type)[n];
};
template<class T, int n>
template<class T, int n>
struct make_tuple_traits<const T[n]> {
typedef const T (&type)[n];
};
@ -669,17 +669,17 @@ template<class T, int n> struct make_tuple_traits<volatile T[n]> {
typedef const volatile T (&type)[n];
};
template<class T, int n>
template<class T, int n>
struct make_tuple_traits<const volatile T[n]> {
typedef const volatile T (&type)[n];
};
template<class T>
template<class T>
struct make_tuple_traits<reference_wrapper<T> >{
typedef T& type;
};
template<class T>
template<class T>
struct make_tuple_traits<const reference_wrapper<T> >{
typedef T& type;
};
@ -692,20 +692,20 @@ namespace detail {
// a helper traits to make the make_tuple functions shorter (Vesa Karvonen's
// suggestion)
template <
class T0 = null_type, class T1 = null_type, class T2 = null_type,
class T3 = null_type, class T4 = null_type, class T5 = null_type,
class T6 = null_type, class T7 = null_type, class T8 = null_type,
class T0 = null_type, class T1 = null_type, class T2 = null_type,
class T3 = null_type, class T4 = null_type, class T5 = null_type,
class T6 = null_type, class T7 = null_type, class T8 = null_type,
class T9 = null_type
>
struct make_tuple_mapper {
typedef
tuple<typename make_tuple_traits<T0>::type,
typename make_tuple_traits<T1>::type,
typename make_tuple_traits<T2>::type,
typename make_tuple_traits<T3>::type,
typename make_tuple_traits<T4>::type,
typename make_tuple_traits<T5>::type,
typename make_tuple_traits<T6>::type,
tuple<typename make_tuple_traits<T0>::type,
typename make_tuple_traits<T1>::type,
typename make_tuple_traits<T2>::type,
typename make_tuple_traits<T3>::type,
typename make_tuple_traits<T4>::type,
typename make_tuple_traits<T5>::type,
typename make_tuple_traits<T6>::type,
typename make_tuple_traits<T7>::type,
typename make_tuple_traits<T8>::type,
typename make_tuple_traits<T9>::type> type;
@ -715,7 +715,7 @@ struct make_tuple_mapper {
// -make_tuple function templates -----------------------------------
inline tuple<> make_tuple() {
return tuple<>();
return tuple<>();
}
template<class T0>
@ -751,7 +751,7 @@ inline typename detail::make_tuple_mapper<T0, T1, T2, T3, T4>::type
make_tuple(const T0& t0, const T1& t1, const T2& t2, const T3& t3,
const T4& t4) {
typedef typename detail::make_tuple_mapper<T0, T1, T2, T3, T4>::type t;
return t(t0, t1, t2, t3, t4);
return t(t0, t1, t2, t3, t4);
}
template<class T0, class T1, class T2, class T3, class T4, class T5>
@ -759,7 +759,7 @@ inline typename detail::make_tuple_mapper<T0, T1, T2, T3, T4, T5>::type
make_tuple(const T0& t0, const T1& t1, const T2& t2, const T3& t3,
const T4& t4, const T5& t5) {
typedef typename detail::make_tuple_mapper<T0, T1, T2, T3, T4, T5>::type t;
return t(t0, t1, t2, t3, t4, t5);
return t(t0, t1, t2, t3, t4, t5);
}
template<class T0, class T1, class T2, class T3, class T4, class T5, class T6>
@ -778,7 +778,7 @@ make_tuple(const T0& t0, const T1& t1, const T2& t2, const T3& t3,
const T4& t4, const T5& t5, const T6& t6, const T7& t7) {
typedef typename detail::make_tuple_mapper
<T0, T1, T2, T3, T4, T5, T6, T7>::type t;
return t(t0, t1, t2, t3, t4, t5, t6, t7);
return t(t0, t1, t2, t3, t4, t5, t6, t7);
}
template<class T0, class T1, class T2, class T3, class T4, class T5, class T6,
@ -790,7 +790,7 @@ make_tuple(const T0& t0, const T1& t1, const T2& t2, const T3& t3,
const T8& t8) {
typedef typename detail::make_tuple_mapper
<T0, T1, T2, T3, T4, T5, T6, T7, T8>::type t;
return t(t0, t1, t2, t3, t4, t5, t6, t7, t8);
return t(t0, t1, t2, t3, t4, t5, t6, t7, t8);
}
template<class T0, class T1, class T2, class T3, class T4, class T5, class T6,
@ -802,7 +802,7 @@ make_tuple(const T0& t0, const T1& t1, const T2& t2, const T3& t3,
const T8& t8, const T9& t9) {
typedef typename detail::make_tuple_mapper
<T0, T1, T2, T3, T4, T5, T6, T7, T8, T9>::type t;
return t(t0, t1, t2, t3, t4, t5, t6, t7, t8, t9);
return t(t0, t1, t2, t3, t4, t5, t6, t7, t8, t9);
}
@ -829,46 +829,46 @@ inline tuple<T1&, T2&, T3&, T4&> tie(T1& t1, T2& t2, T3& t3, T4& t4) {
}
template<class T1, class T2, class T3, class T4, class T5>
inline tuple<T1&, T2&, T3&, T4&, T5&>
inline tuple<T1&, T2&, T3&, T4&, T5&>
tie(T1& t1, T2& t2, T3& t3, T4& t4, T5& t5) {
return tuple<T1&, T2&, T3&, T4&, T5&> (t1, t2, t3, t4, t5);
}
template<class T1, class T2, class T3, class T4, class T5, class T6>
inline tuple<T1&, T2&, T3&, T4&, T5&, T6&>
inline tuple<T1&, T2&, T3&, T4&, T5&, T6&>
tie(T1& t1, T2& t2, T3& t3, T4& t4, T5& t5, T6& t6) {
return tuple<T1&, T2&, T3&, T4&, T5&, T6&> (t1, t2, t3, t4, t5, t6);
}
template<class T1, class T2, class T3, class T4, class T5, class T6, class T7>
inline tuple<T1&, T2&, T3&, T4&, T5&, T6&, T7&>
inline tuple<T1&, T2&, T3&, T4&, T5&, T6&, T7&>
tie(T1& t1, T2& t2, T3& t3, T4& t4, T5& t5, T6& t6, T7& t7) {
return tuple<T1&, T2&, T3&, T4&, T5&, T6&, T7&> (t1, t2, t3, t4, t5, t6, t7);
}
template<class T1, class T2, class T3, class T4, class T5, class T6, class T7,
template<class T1, class T2, class T3, class T4, class T5, class T6, class T7,
class T8>
inline tuple<T1&, T2&, T3&, T4&, T5&, T6&, T7&, T8&>
inline tuple<T1&, T2&, T3&, T4&, T5&, T6&, T7&, T8&>
tie(T1& t1, T2& t2, T3& t3, T4& t4, T5& t5, T6& t6, T7& t7, T8& t8) {
return tuple<T1&, T2&, T3&, T4&, T5&, T6&, T7&, T8&>
return tuple<T1&, T2&, T3&, T4&, T5&, T6&, T7&, T8&>
(t1, t2, t3, t4, t5, t6, t7, t8);
}
template<class T1, class T2, class T3, class T4, class T5, class T6, class T7,
template<class T1, class T2, class T3, class T4, class T5, class T6, class T7,
class T8, class T9>
inline tuple<T1&, T2&, T3&, T4&, T5&, T6&, T7&, T8&, T9&>
tie(T1& t1, T2& t2, T3& t3, T4& t4, T5& t5, T6& t6, T7& t7, T8& t8,
inline tuple<T1&, T2&, T3&, T4&, T5&, T6&, T7&, T8&, T9&>
tie(T1& t1, T2& t2, T3& t3, T4& t4, T5& t5, T6& t6, T7& t7, T8& t8,
T9& t9) {
return tuple<T1&, T2&, T3&, T4&, T5&, T6&, T7&, T8&, T9&>
return tuple<T1&, T2&, T3&, T4&, T5&, T6&, T7&, T8&, T9&>
(t1, t2, t3, t4, t5, t6, t7, t8, t9);
}
template<class T1, class T2, class T3, class T4, class T5, class T6, class T7,
template<class T1, class T2, class T3, class T4, class T5, class T6, class T7,
class T8, class T9, class T10>
inline tuple<T1&, T2&, T3&, T4&, T5&, T6&, T7&, T8&, T9&, T10&>
tie(T1& t1, T2& t2, T3& t3, T4& t4, T5& t5, T6& t6, T7& t7, T8& t8,
inline tuple<T1&, T2&, T3&, T4&, T5&, T6&, T7&, T8&, T9&, T10&>
tie(T1& t1, T2& t2, T3& t3, T4& t4, T5& t5, T6& t6, T7& t7, T8& t8,
T9& t9, T10& t10) {
return tuple<T1&, T2&, T3&, T4&, T5&, T6&, T7&, T8&, T9&, T10&>
return tuple<T1&, T2&, T3&, T4&, T5&, T6&, T7&, T8&, T9&, T10&>
(t1, t2, t3, t4, t5, t6, t7, t8, t9, t10);
}
@ -879,5 +879,3 @@ tie(T1& t1, T2& t2, T3& t3, T4& t4, T5& t5, T6& t6, T7& t7, T8& t8,
#undef BOOST_TUPLE_SINGLE_DUMMY_PARM
#endif // BOOST_TUPLE_BASIC_HPP

View File

@ -1,8 +1,7 @@
// (C) Copyright Steve Cleary, Beman Dawes, Howard Hinnant & John Maddock 2000.
// Permission to copy, use, modify, sell and distribute this software is
// granted provided this copyright notice appears in all copies. This software
// is provided "as is" without express or implied warranty, and with no claim
// Permission to copy, use, modify, sell and distribute this software is
// granted provided this copyright notice appears in all copies. This software
// is provided "as is" without express or implied warranty, and with no claim
// as to its suitability for any purpose.
//
// See http://www.boost.org for most recent version including documentation.
@ -77,7 +76,7 @@ BOOST_TT_AUX_TYPE_TRAIT_IMPL_SPEC1(add_reference,void const volatile,void const
BOOST_TT_AUX_TYPE_TRAIT_DEF1(add_reference,T,typename detail::add_reference_impl<T>::type)
// agurt, 07/mar/03: workaround Borland's ill-formed sensitivity to an additional
// agurt, 07/mar/03: workaround Borland's ill-formed sensitivity to an additional
// level of indirection, here
#if BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x561))
BOOST_TT_AUX_TYPE_TRAIT_PARTIAL_SPEC1_1(typename T,add_reference,T&,T&)

View File

@ -1,4 +1,3 @@
// (C) Copyright Dave Abrahams, Steve Cleary, Beman Dawes, Howard
// Hinnant & John Maddock 2000. Permission to copy, use, modify,
// sell and distribute this software is granted provided this
@ -49,8 +48,8 @@ yes_type BOOST_TT_DECL is_array_tester2(...);
template< typename T >
struct is_array_impl
{
BOOST_STATIC_CONSTANT(bool, value =
{
BOOST_STATIC_CONSTANT(bool, value =
sizeof(::boost::detail::is_array_tester2(
::boost::detail::is_array_tester1(
::boost::type_traits::wrap<T>()

View File

@ -1,4 +1,3 @@
// (C) Copyright David Abrahams Steve Cleary, Beman Dawes, Howard
// Hinnant & John Maddock 2000-2002. Permission to copy, use,
// modify, sell and distribute this software is granted provided this
@ -26,7 +25,7 @@
// should be the last #include
#include "boost/type_traits/detail/bool_trait_def.hpp"
namespace boost {
namespace boost {
#ifndef BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION
@ -108,4 +107,3 @@ BOOST_TT_AUX_BOOL_TRAIT_DEF1(is_reference,T,::boost::detail::is_reference_impl<T
#include "boost/type_traits/detail/bool_trait_undef.hpp"
#endif // BOOST_TT_IS_REFERENCE_HPP_INCLUDED

View File

@ -74,19 +74,6 @@ dnl LYX_CXX_RTTI
AC_CHECK_HEADERS(ostream istream sstream locale limits ios)
LYX_CXX_STL_MODERN_STREAMS
###
AC_ARG_WITH(included-string,
AC_HELP_STRING([--with-included-string],[use std::string through namespace lyx]),
[lyx_cv_with_included_string=$withval
AC_MSG_RESULT([$with_included_string])],
[AC_CACHE_CHECK([],lyx_cv_with_included_string,[lyx_cv_with_included_string=no])])
if test x$lyx_cv_with_included_string = xyes ; then
AC_DEFINE(USE_INCLUDED_STRING, 1,
[Define to use std::string through namespace lyx.])
lyx_flags="$lyx_flags included-string"
fi
### and now some special lyx flags.
AC_ARG_ENABLE(assertions,
AC_HELP_STRING([--enable-assertions],[add runtime sanity checks in the program]),,

View File

@ -185,7 +185,6 @@ src/mathed/ref_inset.C
src/paragraph.C
src/paragraph_funcs.C
src/rowpainter.C
src/support/path_defines.C
src/text.C
src/text2.C
src/text3.C

View File

@ -16,6 +16,8 @@
#include <functional>
using std::string;
using std::bind2nd;
using std::binary_function;

View File

@ -30,32 +30,33 @@
#ifndef BRANCHES_H
#define BRANCHES_H
#include "support/std_string.h"
#include <string>
#include <list>
class Branch {
public:
///
string const getBranch() const;
std::string const getBranch() const;
///
void setBranch(string const &);
void setBranch(std::string const &);
///
bool getSelected() const;
///
void setSelected(bool);
///
string const getColor() const;
std::string const getColor() const;
///
void setColor(string const &);
void setColor(std::string const &);
private:
///
string branch_;
std::string branch_;
///
bool selected_;
///
string color_;
std::string color_;
};
@ -78,29 +79,29 @@ public:
///
List::const_iterator end() const { return list.end(); }
///
string getColor(string const &) const;
std::string getColor(std::string const &) const;
///
void setColor(string const &, string const &);
void setColor(std::string const &, std::string const &);
/// Select/deselect multiple branches given in '|'-separated string
void setSelected(string const &, bool);
void setSelected(std::string const &, bool);
/// Add multiple branches to list
void add(string const &);
void add(std::string const &);
/// remove a branch from list by name
void remove(string const &);
void remove(std::string const &);
/// return whether this branch is selected
bool selected(string const &) const;
bool selected(std::string const &) const;
/// return, as a '|'-separated string, all branch names
string allBranches() const;
std::string allBranches() const;
///
string allSelected() const;
std::string allSelected() const;
///
string const separator() const;
std::string const separator() const;
private:
///
List list;
///
string separator_;
std::string separator_;
};
#endif

View File

@ -47,7 +47,7 @@ using lyx::support::bformat;
using lyx::support::MakeAbsPath;
using std::find;
using std::string;
using std::vector;

View File

@ -17,7 +17,8 @@
#include <boost/utility.hpp>
#include "support/std_string.h"
#include <string>
class Buffer;
class Change;
@ -76,10 +77,10 @@ public:
/// reload the contained buffer
void reload();
/// create a new buffer based on template
bool newFile(string const & fname, string const & tname,
bool newFile(std::string const & fname, std::string const & tname,
bool named = true);
/// load a buffer into the view
bool loadLyXFile(string const & name, bool tolastfiles = true);
bool loadLyXFile(std::string const & name, bool tolastfiles = true);
/// fit the user cursor within the visible view
bool fitCursor();
@ -137,14 +138,14 @@ public:
/// Select the "current" word
void selectLastWord();
/// replace the currently selected word
void replaceWord(string const & replacestring);
void replaceWord(std::string const & replacestring);
/// Update after spellcheck finishes
void endOfSpellCheck();
/// return the next word
WordLangTuple const nextWord(float & value);
/// move cursor to the named label
void gotoLabel(string const & label);
void gotoLabel(std::string const & label);
/// undo last action
void undo();
@ -154,7 +155,7 @@ public:
/// get the stored error list
ErrorList const & getErrorList() const;
/// show the error list to the user
void showErrorList(string const &) const;
void showErrorList(std::string const &) const;
/// set the cursor based on the given TeX source row
void setCursorFromRow(int row);
@ -162,10 +163,10 @@ public:
* Insert an inset into the buffer.
* Place it in a layout of lout,
*/
bool insertInset(InsetOld * inset, string const & lout = string());
bool insertInset(InsetOld * inset, std::string const & lout = std::string());
/// Inserts a lyx file at cursor position. return false if it fails
bool insertLyXFile(string const & file);
bool insertLyXFile(std::string const & file);
/// FIXME
bool fitLockedInsetCursor(int x, int y, int asc, int desc);
@ -189,12 +190,12 @@ public:
void switchKeyMap();
/// FIXME
bool ChangeRefsIfUnique(string const & from, string const & to);
bool ChangeRefsIfUnique(std::string const & from, std::string const & to);
/// get the contents of the window system clipboard
string const getClipboard() const;
std::string const getClipboard() const;
/// fill the window system clipboard
void stuffClipboard(string const &) const;
void stuffClipboard(std::string const &) const;
/// tell the window system we have a selection
void haveSelection(bool sel);

View File

@ -92,6 +92,7 @@ using lyx::support::system_lyxdir;
using std::endl;
using std::make_pair;
using std::min;
using std::string;
extern BufferList bufferlist;

View File

@ -64,9 +64,9 @@ struct BufferView::Pimpl : public boost::signals::trackable {
* change but don't need the full update() logic
*/
///
bool newFile(string const &, string const &, bool);
bool newFile(std::string const &, std::string const &, bool);
///
bool loadLyXFile(string const &, bool);
bool loadLyXFile(std::string const &, bool);
///
void workAreaResize();
///
@ -106,7 +106,7 @@ struct BufferView::Pimpl : public boost::signals::trackable {
///
void center();
///
bool insertInset(InsetOld * inset, string const & lout = string());
bool insertInset(InsetOld * inset, std::string const & lout = std::string());
///
void updateInset(InsetOld const * inset);
/// a function should be executed from the workarea
@ -152,8 +152,8 @@ private:
* string. May only be used with InsetCommand-derived insets
* Returns true if a screen update is needed.
*/
bool ChangeInsets(InsetOld::Code code, string const & from,
string const & to);
bool ChangeInsets(InsetOld::Code code, std::string const & from,
std::string const & to);
///
friend class BufferView;
@ -171,13 +171,13 @@ private:
///
Timeout cursor_timeout;
///
void stuffClipboard(string const &) const;
void stuffClipboard(std::string const &) const;
///
bool using_xterm_cursor;
///
struct Position {
/// Filename
string filename;
std::string filename;
/// Cursor paragraph Id
int par_id;
/// Cursor position
@ -185,7 +185,7 @@ private:
///
Position() : par_id(0), par_pos(0) {}
///
Position(string const & f, int id, lyx::pos_type pos)
Position(std::string const & f, int id, lyx::pos_type pos)
: filename(f), par_id(id), par_pos(pos) {}
};
///
@ -193,7 +193,7 @@ private:
/// Get next inset of this class from current cursor position
InsetOld * getInsetByCode(InsetOld::Code code);
///
void MenuInsertLyXFile(string const & filen);
void MenuInsertLyXFile(std::string const & filen);
/// our workarea
WorkArea & workarea() const;
};

View File

@ -20,6 +20,8 @@
#include <boost/assert.hpp>
using std::string;
/** The four LaTeX itemize environment default bullets
*/

View File

@ -13,7 +13,7 @@
#ifndef BULLET_H
#define BULLET_H
#include "support/std_string.h"
#include <string>
///
class Bullet {
@ -22,7 +22,7 @@ public:
Bullet(int f = -1, int c = -1, int s = -1);
///
explicit Bullet(string const &);
explicit Bullet(std::string const &);
///
void setCharacter(int);
@ -31,7 +31,7 @@ public:
///
void setSize(int);
///
void setText(string const &);
void setText(std::string const &);
///
int getCharacter() const;
///
@ -39,7 +39,7 @@ public:
///
int getSize() const;
///
string const & getText() const;
std::string const & getText() const;
///
Bullet & operator=(Bullet const &);
///
@ -70,9 +70,9 @@ private:
///
void generateText() const;
///
static string const bulletSize(int);
static std::string const bulletSize(int);
///
static string const bulletEntry(int, int);
static std::string const bulletEntry(int, int);
///
int font;
@ -97,7 +97,7 @@ private:
or one generated internally from the font, character
and size settings.
*/
mutable string text;
mutable std::string text;
};

View File

@ -1,3 +1,7 @@
2003-10-06 Lars Gullik Bjønnes <larsbj@gullik.net>
* All most all file in all subdirs: Make <string> be the prefered
way of getting to std::string, add using declarations.
2003-10-06 André Pönitz <poenitz@gmx.net>
@ -24,7 +28,7 @@
2003-09-26 Lars Gullik Bjønnes <larsbj@gullik.net>
* lyx_main.C: remove the global debug object
* lyx_main.C: remove the global debug object
* debug.h: adjust for new debugstream

View File

@ -30,7 +30,7 @@ using lyx::support::split;
using lyx::support::Systemcall;
using std::getline;
using std::string;
using std::ifstream;

View File

@ -12,11 +12,12 @@
#ifndef CHKTEX_H
#define CHKTEX_H
#include "support/std_string.h"
class LyXLex;
class TeXErrors;
#include <string>
///
class Chktex {
public:
@ -25,8 +26,8 @@ public:
@param file name of the (temporary) latex file.
@param path name of the files original path.
*/
Chktex(string const & cmd, string const & file,
string const & path);
Chktex(std::string const & cmd, std::string const & file,
std::string const & path);
/** Runs chktex.
@return -1 if fail, number of messages otherwise.
@ -37,13 +38,13 @@ private:
int scanLogFile(TeXErrors &);
///
string cmd;
std::string cmd;
///
string file;
std::string file;
///
string path;
std::string path;
};
#endif

View File

@ -37,6 +37,7 @@ using std::for_each;
using std::make_pair;
using std::pair;
using std::vector;
using std::string;
typedef limited_stack<pair<ParagraphList, textclass_type> > CutStack;

View File

@ -17,7 +17,6 @@
#include "ParagraphList_fwd.h"
#include "support/types.h"
#include "support/std_string.h"
#include <vector>
class Buffer;
@ -30,7 +29,7 @@ class Paragraph;
namespace CutAndPaste {
///
std::vector<string>
std::vector<std::string>
CutAndPaste::availableSelections(Buffer const & buffer);
///

View File

@ -38,7 +38,7 @@ using lyx::support::sum;
using std::endl;
using std::flush;
using std::getline;
using std::string;
using std::ofstream;
using std::ifstream;

View File

@ -13,7 +13,6 @@
#ifndef DEP_TABLE_H
#define DEP_TABLE_H
#include "support/std_string.h"
#include <map>
///
@ -22,28 +21,28 @@ public:
/** This one is a little bit harder since we need the absolute
filename. Should we insert files with .sty .cls etc as
extension? */
void insert(string const & f, bool upd = false);
void insert(std::string const & f, bool upd = false);
///
void update();
///
void write(string const & f) const;
void write(std::string const & f) const;
/// returns true if dep file was read successfully
bool read(string const & f);
bool read(std::string const & f);
/// returns true if any of the files has changed
bool sumchange() const;
/// return true if fil has changed.
bool haschanged(string const & fil) const;
bool haschanged(std::string const & fil) const;
/// return true if a file with extension ext has changed.
bool extchanged(string const & ext) const;
bool extchanged(std::string const & ext) const;
///
bool exist(string const & fil) const;
bool exist(std::string const & fil) const;
/// returns true if any files with ext exist
bool ext_exist(string const & ext) const;
bool ext_exist(std::string const & ext) const;
///
void remove_files_with_extension(string const &);
void remove_files_with_extension(std::string const &);
///
void remove_file(string const &);
void remove_file(std::string const &);
private:
///
struct dep_info {
@ -57,7 +56,7 @@ private:
bool changed() const;
};
///
typedef std::map<string, dep_info> DepList;
typedef std::map<std::string, dep_info> DepList;
///
DepList deplist;
};

View File

@ -13,6 +13,8 @@
#include "FloatList.h"
#include "Floating.h"
using std::string;
// This class is now mostly finished, except one thing, it is a global
// object. This will not do. The user (and layout files) are free to
// create floats and modify them to fit into a certain document. So it is

View File

@ -14,7 +14,6 @@
#include <map>
#include "support/std_string.h"
class Floating;
@ -22,7 +21,7 @@ class Floating;
class FloatList {
public:
///
typedef std::map<string, Floating> List;
typedef std::map<std::string, Floating> List;
///
typedef List::const_iterator const_iterator;
///
@ -34,15 +33,15 @@ public:
///
void newFloat(Floating const & fl);
///
string const defaultPlacement(string const & t) const;
std::string const defaultPlacement(std::string const & t) const;
///
bool typeExist(string const & t) const;
bool typeExist(std::string const & t) const;
///
Floating const & getType(string const & t) const;
Floating const & getType(std::string const & t) const;
///
void erase(string const & t);
void erase(std::string const & t);
///
const_iterator operator[](string const & t) const;
const_iterator operator[](std::string const & t) const;
private:
///
List list;

View File

@ -14,6 +14,8 @@
#include "Floating.h"
using std::string;
Floating::Floating()
{}

View File

@ -12,7 +12,7 @@
#ifndef FLOATING_H
#define FLOATING_H
#include "support/std_string.h"
#include <string>
/** This is a "float layout" object. It contains the parameters for how to
handle the different kinds of floats, default ones and user created ones.
@ -25,41 +25,41 @@ public:
///
Floating();
///
Floating(string const & type, string const & placement,
string const & ext, string const & within,
string const & style, string const & name,
string const & listName, bool builtin = false);
Floating(std::string const & type, std::string const & placement,
std::string const & ext, std::string const & within,
std::string const & style, std::string const & name,
std::string const & listName, bool builtin = false);
///
string const & type() const;
std::string const & type() const;
///
string const & placement() const;
std::string const & placement() const;
///
string const & ext() const;
std::string const & ext() const;
///
string const & within() const;
std::string const & within() const;
///
string const & style() const;
std::string const & style() const;
///
string const & name() const;
std::string const & name() const;
///
string const & listName() const;
std::string const & listName() const;
///
bool builtin() const;
private:
///
string type_;
std::string type_;
///
string placement_;
std::string placement_;
///
string ext_;
std::string ext_;
///
string within_;
std::string within_;
///
string style_;
std::string style_;
///
string name_;
std::string name_;
///
string listName_;
std::string listName_;
///
bool builtin_;
};

View File

@ -26,6 +26,7 @@
using lyx::support::compare_ascii_no_case;
using std::endl;
using std::string;
namespace {

View File

@ -19,7 +19,6 @@
#ifndef LCOLOR_H
#define LCOLOR_H
#include "support/std_string.h"
#include <boost/scoped_ptr.hpp>
/**
@ -195,42 +194,42 @@ public:
///
void LColor::fill(LColor::color c,
string const & lyxname,
string const & x11name = string(),
string const & latexname = string(),
string const & guiname = string());
std::string const & lyxname,
std::string const & x11name = std::string(),
std::string const & latexname = std::string(),
std::string const & guiname = std::string());
/// set the given LyX color to the color defined by the X11 name given
void setColor(LColor::color col, string const & x11name);
void setColor(LColor::color col, std::string const & x11name);
/// set the given LyX color to the color defined by the X11 name given
bool setColor(string const & lyxname, string const & x11name);
bool setColor(std::string const & lyxname, std::string const & x11name);
/// Get GUI name of color
string const getGUIName(LColor::color c) const;
std::string const getGUIName(LColor::color c) const;
///
string const getGUIName(string const & s) const;
std::string const getGUIName(std::string const & s) const;
/// Get X11 name of color
string const getX11Name(LColor::color c) const;
std::string const getX11Name(LColor::color c) const;
///
string const getX11Name(string const & s) const;
std::string const getX11Name(std::string const & s) const;
/// Get LaTeX name of color
string const getLaTeXName(LColor::color c) const;
std::string const getLaTeXName(LColor::color c) const;
///
string const getLaTeXName(string const & s) const;
std::string const getLaTeXName(std::string const & s) const;
/// Get LyX name of color
string const getLyXName(LColor::color c) const;
std::string const getLyXName(LColor::color c) const;
/// (string-to-string version not needed as it is identity)
///
size_t size() const;
/// get the color from the GUI name
LColor::color getFromGUIName(string const & guiname) const;
LColor::color getFromGUIName(std::string const & guiname) const;
/// get the color from the LyX name
LColor::color getFromLyXName(string const & lyxname) const;
LColor::color getFromLyXName(std::string const & lyxname) const;
private:
///
struct Pimpl;

View File

@ -59,7 +59,7 @@ using std::sscanf;
using std::endl;
using std::getline;
using std::string;
using std::ifstream;
using std::set;
using std::vector;

View File

@ -15,13 +15,13 @@
#define LATEX_H
#include "latexrunparams.h"
#include "support/std_string.h"
#include <vector>
#include <set>
#include <boost/utility.hpp>
#include <boost/signals/signal1.hpp>
#include <vector>
#include <set>
class DepTable;
///
@ -32,16 +32,16 @@ private:
///
Error () : error_in_line(0) {}
///
Error(int line, string const & desc, string const & text)
Error(int line, std::string const & desc, std::string const & text)
: error_in_line(line),
error_desc(desc),
error_text(text) {}
/// what line in the TeX file the error occured in
int error_in_line;
/// The kind of error
string error_desc;
std::string error_desc;
/// The line/cmd that caused the error.
string error_text;
std::string error_text;
};
public:
///
@ -51,8 +51,8 @@ public:
///
Errors::const_iterator end() const { return errors.end(); }
///
void insertError(int line, string const & error_desc,
string const & error_text);
void insertError(int line, std::string const & error_desc,
std::string const & error_text);
private:
///
Errors errors;
@ -64,13 +64,13 @@ public:
///
Aux_Info() {}
///
string aux_file;
std::string aux_file;
///
std::set<string> citations;
std::set<std::string> citations;
///
std::set<string> databases;
std::set<std::string> databases;
///
std::set<string> styles;
std::set<std::string> styles;
};
@ -125,15 +125,15 @@ public:
};
/// This signal emits an informative message
boost::signal1<void, string> message;
boost::signal1<void, std::string> message;
/**
cmd = the latex command, file = name of the (temporary) latex file,
path = name of the files original path.
*/
LaTeX(string const & cmd, LatexRunParams const &,
string const & file, string const & path);
LaTeX(std::string const & cmd, LatexRunParams const &,
std::string const & file, std::string const & path);
/// runs LaTeX several times
int run(TeXErrors &);
@ -149,22 +149,22 @@ private:
int startscript();
/// The dependency file.
string depfile;
std::string depfile;
///
void deplog(DepTable & head);
///
bool runMakeIndex(string const &);
bool runMakeIndex(std::string const &);
///
std::vector<Aux_Info> const scanAuxFiles(string const &);
std::vector<Aux_Info> const scanAuxFiles(std::string const &);
///
Aux_Info const scanAuxFile(string const &);
Aux_Info const scanAuxFile(std::string const &);
///
void scanAuxFile(string const &, Aux_Info &);
void scanAuxFile(std::string const &, Aux_Info &);
///
void updateBibtexDependencies(DepTable &,
@ -177,19 +177,19 @@ private:
void deleteFilesOnError() const;
///
string cmd;
std::string cmd;
///
string file;
std::string file;
///
string path;
std::string path;
/// used by scanLogFile
int num_errors;
/// The name of the final output file.
string output_file;
std::string output_file;
///
LatexRunParams runparams;

View File

@ -35,7 +35,7 @@ using lyx::support::OnlyPath;
using std::endl;
using std::find;
using std::string;
using std::list;
using std::ostream;
using std::ostringstream;

View File

@ -14,8 +14,6 @@
#define LATEXFEATURES_H
#include "support/std_string.h"
#include <set>
#include <list>
#include <map>
@ -42,41 +40,41 @@ public:
///
LaTeXFeatures(Buffer const &, BufferParams const &);
/// The packages needed by the document
string const getPackages() const;
std::string const getPackages() const;
/// The macros definitions needed by the document
string const getMacros() const;
std::string const getMacros() const;
///
string const getBabelOptions() const;
std::string const getBabelOptions() const;
/// The definitions needed by the document's textclass
string const getTClassPreamble() const;
std::string const getTClassPreamble() const;
/// The sgml definitions needed by the document (dobook/linuxdoc)
string const getLyXSGMLEntities() const;
std::string const getLyXSGMLEntities() const;
/// The SGML Required to include the files added with includeFile();
string const getIncludedFiles(string const & fname) const;
std::string const getIncludedFiles(std::string const & fname) const;
/// Include a file for use with the SGML entities
void includeFile(string const & key, string const & name);
void includeFile(std::string const & key, std::string const & name);
/// The float definitions.
void getFloatDefinitions(std::ostream & os) const;
/// Print requirements to lyxerr
void showStruct() const;
///
void addExternalPreamble(string const &);
void addExternalPreamble(std::string const &);
/// Provide a string name-space to the requirements
void require(string const & name);
void require(std::string const & name);
/// Is the package required?
bool isRequired(string const & name) const;
bool isRequired(std::string const & name) const;
///
void useFloat(string const & name);
void useFloat(std::string const & name);
///
void useLanguage(Language const *);
///
bool hasLanguages() const;
///
string getLanguages() const;
std::string getLanguages() const;
///
std::set<string> getEncodingSet(string const & doc_encoding) const;
std::set<std::string> getEncodingSet(std::string const & doc_encoding) const;
///
void useLayout(string const & lyt);
void useLayout(std::string const & lyt);
///
Buffer const & buffer() const;
///
@ -85,10 +83,10 @@ public:
bool useBabel() const;
private:
std::list<string> usedLayouts_;
std::list<std::string> usedLayouts_;
/// Static preamble bits from the external material insets
typedef std::list<string> FeaturesList;
typedef std::list<std::string> FeaturesList;
///
FeaturesList features_;
///
@ -98,11 +96,11 @@ private:
///
LanguageList UsedLanguages_;
///
typedef std::set<string> UsedFloats;
typedef std::set<std::string> UsedFloats;
///
UsedFloats usedFloats_;
///
typedef std::map<string , string> FileMap;
typedef std::map<std::string , std::string> FileMap;
///
FileMap IncludedFiles_;
///

View File

@ -26,7 +26,7 @@ using lyx::support::split;
using lyx::support::trim;
using std::endl;
using std::string;
using std::ostream;

View File

@ -15,10 +15,10 @@
#include "lfuns.h"
#include "support/std_string.h"
#include <boost/utility.hpp>
#include <map>
#include <map>
#include <string>
class FuncRequest;
@ -34,14 +34,14 @@ private:
/// information for an action
struct func_info {
/// the action name
string name;
std::string name;
/// the func_attrib values set
unsigned int attrib;
};
public:
/// type for map between a function name and its action
typedef std::map<string, kb_action> func_map;
typedef std::map<std::string, kb_action> func_map;
/// type for map between an action and its info
typedef std::map<kb_action, func_info> info_map;
@ -60,10 +60,10 @@ public:
* If you include arguments in func_name, a new pseudoaction
* will be created if needed.
*/
FuncRequest lookupFunc(string const & func_name) const;
FuncRequest lookupFunc(std::string const & func_name) const;
/// Return the name (and argument) associated with the given (pseudo) action
string const getActionName(kb_action action) const;
std::string const getActionName(kb_action action) const;
/// True if the command has `flag' set
bool funcHasFlag(kb_action action, func_attrib flag) const;
@ -81,7 +81,7 @@ private:
/// populate the action container with our actions
void init();
/// add the given action
void newFunc(kb_action, string const & name, unsigned int attrib);
void newFunc(kb_action, std::string const & name, unsigned int attrib);
/**
* This is a list of all the LyXFunc names with the

View File

@ -55,7 +55,7 @@ using std::endl;
using std::find_if;
using std::max;
using std::sort;
using std::string;
using std::vector;

View File

@ -16,8 +16,6 @@
#include "FuncStatus.h"
#include "funcrequest.h"
#include "support/std_string.h"
#include <boost/shared_ptr.hpp>
#include <vector>
@ -73,23 +71,23 @@ public:
explicit MenuItem(Kind kind);
MenuItem(Kind kind,
string const & label,
string const & command = string(),
std::string const & label,
std::string const & command = std::string(),
bool optional = false);
MenuItem(Kind kind,
string const & label,
std::string const & label,
FuncRequest const & func,
bool optional = false);
/// This one is just to please boost::shared_ptr<>
~MenuItem();
/// The label of a given menuitem
string const label() const;
std::string const label() const;
/// The keyboard shortcut (usually underlined in the entry)
string const shortcut() const;
std::string const shortcut() const;
/// The complete label, with label and shortcut separated by a '|'
string const fulllabel() const { return label_;}
std::string const fulllabel() const { return label_;}
/// The kind of entry
Kind kind() const { return kind_; }
/// the action (if relevant)
@ -103,11 +101,11 @@ public:
/// returns the status of the lfun associated with this entry
void status(FuncStatus const & status) { status_ = status; }
/// returns the binding associated to this action
string const binding() const;
std::string const binding() const;
/// the description of the submenu (if relevant)
string const & submenuname() const { return submenuname_; }
std::string const & submenuname() const { return submenuname_; }
/// set the description of the submenu
void submenuname(string const & name) { submenuname_ = name; }
void submenuname(std::string const & name) { submenuname_ = name; }
///
Menu * submenu() const { return submenu_.get(); }
///
@ -118,11 +116,11 @@ private:
///
Kind kind_;
///
string label_;
std::string label_;
///
FuncRequest func_;
///
string submenuname_;
std::string submenuname_;
///
bool optional_;
///
@ -142,20 +140,20 @@ public:
///
typedef ItemList::size_type size_type;
///
explicit Menu(string const & name = string())
explicit Menu(std::string const & name = std::string())
: name_(name) {}
///
Menu & add(MenuItem const &, LyXView const * view = 0);
///
Menu & read(LyXLex &);
///
string const & name() const { return name_; }
std::string const & name() const { return name_; }
///
bool empty() const { return items_.empty(); }
///
ItemList::size_type size() const { return items_.size(); }
///
bool hasSubmenu(string const &) const;
bool hasSubmenu(std::string const &) const;
///
const_iterator begin() const {
return items_.begin();
@ -173,7 +171,7 @@ private:
///
ItemList items_;
///
string name_;
std::string name_;
};
@ -189,11 +187,11 @@ public:
///
void add(Menu const &);
///
bool hasMenu(string const &) const;
bool hasMenu(std::string const &) const;
///
Menu & getMenu(string const &);
Menu & getMenu(std::string const &);
///
Menu const & getMenu(string const &) const;
Menu const & getMenu(std::string const &) const;
///
Menu const & getMenubar() const;
///

View File

@ -37,6 +37,7 @@ using lyx::support::rtrim;
using std::istringstream;
using std::ostream;
using std::ostringstream;
using std::string;
// Initialize static member var.

View File

@ -19,7 +19,6 @@
#include "support/types.h"
#include "support/std_string.h"
#include <iosfwd>
class BufferView;
@ -90,13 +89,13 @@ public:
///
void appendix(bool);
///
string const & labelString() const;
std::string const & labelString() const;
///
void labelString(string const &);
void labelString(std::string const &);
///
string const & labelWidthString() const;
std::string const & labelWidthString() const;
///
void labelWidthString(string const &);
void labelWidthString(std::string const &);
///
LyXLength const & leftIndent() const;
///
@ -122,12 +121,12 @@ private:
The function also generates some additional info needed by the
Paragraph dialog.
*/
void params2string(Paragraph const & par, string & data);
void params2string(Paragraph const & par, std::string & data);
/** Given \param data, an encoding of the ParagraphParameters generated
in the Paragraph dialog, this function sets the current paragraph
appropriately.
*/
void setParagraphParams(BufferView & bv, string const & data);
void setParagraphParams(BufferView & bv, std::string const & data);
#endif

View File

@ -51,9 +51,9 @@ struct ParameterStruct {
///
bool appendix;
///
string labelstring;
std::string labelstring;
///
string labelwidthstring;
std::string labelwidthstring;
///
LyXLength leftindent;
};

View File

@ -16,6 +16,8 @@
#include <boost/assert.hpp>
using std::string;
PrinterParams::PrinterParams(Target t,
string const & pname,

View File

@ -33,9 +33,9 @@ struct PrinterParams {
///
Target target;
///
string printer_name;
std::string printer_name;
///
string file_name;
std::string file_name;
///
bool all_pages;
/** Print a page range. Both from_page and to_page used to be strings
@ -76,8 +76,8 @@ struct PrinterParams {
void testInvariant() const;
///
PrinterParams(Target t = PRINTER,
string const & pname = lyxrc.printer,
string const & fname = string(),
std::string const & pname = lyxrc.printer,
std::string const & fname = std::string(),
bool all = true,
unsigned int from = 1,
unsigned int to = 0,

View File

@ -12,39 +12,39 @@
#ifndef SECTIONING_H
#define SECTIONING_H
#include "lyxfont.h"
#include <map>
#include "support/std_string.h"
#include "lyxfont.h"
///
class Section {
public:
///
string const & name() const;
std::string const & name() const;
///
int level() const;
///
string const & indent() const;
std::string const & indent() const;
///
string const & beforeskip() const;
std::string const & beforeskip() const;
///
string const & afterskip() const;
std::string const & afterskip() const;
///
LyXFont const & style() const;
///
bool display() const;
private:
///
string name_;
std::string name_;
///
int level_;
///
string indent_;
std::string indent_;
///
string beforeskip_;
std::string beforeskip_;
///
string afterskip_;
std::string afterskip_;
///
LyXFont style_;
};
@ -54,7 +54,7 @@ private:
class SectioningList {
private:
///
typedef std::map<string, Section> List_;
typedef std::map<std::string, Section> List_;
///
List_ list_;
};

View File

@ -18,6 +18,7 @@ using std::ios;
using std::istringstream;
using std::ostream;
using std::ostringstream;
using std::string;
string const Spacing::spacing_string[]

View File

@ -14,7 +14,6 @@
#include <iosfwd>
#include "support/std_string.h"
///
class Spacing {
@ -38,7 +37,7 @@ public:
Spacing(Spacing::Space sp, float val = 1.0) {
set(sp, val);
}
Spacing(Spacing::Space sp, string const & val) {
Spacing(Spacing::Space sp, std::string const & val) {
set(sp, val);
}
///
@ -52,13 +51,13 @@ public:
///
void set(Spacing::Space sp, float val = 1.0);
///
void set(Spacing::Space sp, string const & val) ;
void set(Spacing::Space sp, std::string const & val) ;
///
void writeFile(std::ostream &, bool para = false) const;
///
string const writeEnvirBegin() const;
std::string const writeEnvirBegin() const;
///
string const writeEnvirEnd() const;
std::string const writeEnvirEnd() const;
private:
///
@ -66,7 +65,7 @@ private:
///
float value;
/// names of line spacing
static string const spacing_string[];
static std::string const spacing_string[];
};

View File

@ -13,7 +13,7 @@
#ifndef SPELL_BASE_H
#define SPELL_BASE_H
#include "support/std_string.h" // can't forward declare...
#include <string>
class BufferParams;
class WordLangTuple;
@ -49,10 +49,10 @@ public:
virtual void accept(WordLangTuple const &) = 0;
/// return the next near miss after a MISSED result
virtual string const nextMiss() = 0;
virtual std::string const nextMiss() = 0;
/// give an error message on messy exit
virtual string const error() = 0;
virtual std::string const error() = 0;
};

View File

@ -21,7 +21,7 @@ using std::endl;
using std::find_if;
using std::for_each;
using std::make_pair;
using std::string;
using std::ostream;
extern BufferList bufferlist;

View File

@ -12,8 +12,6 @@
#ifndef TEXT_CACHE_H
#define TEXT_CACHE_H
#include "support/std_string.h"
#include <iosfwd>
#include <map>
@ -117,7 +115,7 @@ public:
LyXText * findFit(Buffer * b, int p);
/** Lists all the LyXText's currently in the cache.
Uses msg as header for the list. */
void show(std::ostream & o, string const & msg);
void show(std::ostream & o, std::string const & msg);
/// Gives info on a single LyXText (buffer and width)
static void show(std::ostream & o, value_type const &);
/** Adds a LyXText to the cache iff its buffer is

View File

@ -12,9 +12,12 @@
#include "Thesaurus.h"
#ifdef HAVE_LIBAIKSAURUS
#include <algorithm>
#include <string>
using std::string;
#ifdef HAVE_LIBAIKSAURUS
using std::sort;

View File

@ -15,7 +15,6 @@
#include <vector>
#include <map>
#include "support/std_string.h"
#ifdef HAVE_LIBAIKSAURUS
#include AIKSAURUS_H_LOCATION
#endif
@ -31,12 +30,12 @@ public:
///
~Thesaurus();
typedef std::map<string, std::vector<string> > Meanings;
typedef std::map<std::string, std::vector<std::string> > Meanings;
/**
* look up some text in the thesaurus
*/
Meanings lookup(string const & text);
Meanings lookup(std::string const & text);
private:
#ifdef HAVE_LIBAIKSAURUS

View File

@ -30,7 +30,7 @@ using lyx::support::subst;
using std::endl;
using std::make_pair;
using std::string;
using std::vector;

View File

@ -17,7 +17,6 @@
#include <vector>
#include "support/std_string.h"
class LyXLex;
@ -36,7 +35,7 @@ public:
};
/// action, tooltip
typedef std::pair<FuncRequest, string> Item;
typedef std::pair<FuncRequest, std::string> Item;
/// the toolbar items
typedef std::vector<Item> Items;
@ -56,7 +55,7 @@ public:
/// a toolbar
struct Toolbar {
/// toolbar UI name
string name;
std::string name;
/// toolbar contents
Items items;
/// flags
@ -85,12 +84,12 @@ public:
void readToolbars(LyXLex &);
/// return a full path of an XPM for the given action
static string const getIcon(FuncRequest const &);
static std::string const getIcon(FuncRequest const &);
private:
/// add the given lfun with tooltip if relevant
void add(Toolbar & tb, FuncRequest const &,
string const & tooltip = string());
std::string const & tooltip = std::string());
/// all the toolbars
Toolbars toolbars;

View File

@ -13,7 +13,6 @@
#ifndef VARIABLES_H
#define VARIABLES_H
#include "support/std_string.h"
#include <map>
@ -21,16 +20,16 @@
class Variables {
public:
///
void set(string const &, string const &);
void set(std::string const &, std::string const &);
///
string const get(string const &) const;
std::string const get(std::string const &) const;
///
bool isSet(string const & var) const;
bool isSet(std::string const & var) const;
///
string const expand(string const &) const;
std::string const expand(std::string const &) const;
private:
///
typedef std::map<string, string> Vars;
typedef std::map<std::string, std::string> Vars;
///
Vars vars_;
};

View File

@ -12,8 +12,6 @@
#ifndef WORD_LANG_TUPLE_H
#define WORD_LANG_TUPLE_H
#include "support/std_string.h"
/**
* A word and its given language code ("en_US").
* This is used for spellchecking.
@ -22,25 +20,25 @@ class WordLangTuple {
public:
WordLangTuple() {}
WordLangTuple(string const & w, string const & c)
WordLangTuple(std::string const & w, std::string const & c)
: word_(w), code_(c)
{}
/// return the word
string const & word() const {
std::string const & word() const {
return word_;
}
/// return its language code
string const & lang_code() const {
std::string const & lang_code() const {
return code_;
}
private:
/// the word
string word_;
std::string word_;
/// language code of word
string code_;
std::string code_;
};
#endif // WORD_LANG_TUPLE_H

View File

@ -21,6 +21,8 @@
using lyx::support::token;
using lyx::support::trim;
using std::string;
bool operator==(Author const & l, Author const & r)
{

View File

@ -14,30 +14,30 @@
#include <map>
#include <iosfwd>
#include <string>
#include "support/std_string.h"
class Author {
public:
Author() {}
Author(string const & name, string const & email)
Author(std::string const & name, std::string const & email)
: name_(name), email_(email) {}
string const name() const {
std::string const name() const {
return name_;
}
string const email() const {
std::string const email() const {
return email_;
}
friend std::istream & operator>>(std::istream & os, Author & a);
private:
string name_;
std::string name_;
string email_;
std::string email_;
};

View File

@ -123,6 +123,7 @@ using std::ofstream;
using std::pair;
using std::stack;
using std::vector;
using std::string;
// all these externs should eventually be removed.

View File

@ -22,7 +22,6 @@
#include <boost/signals/signal0.hpp>
#include <boost/signals/signal1.hpp>
#include "support/std_string.h"
#include <iosfwd>
#include <map>
#include <utility>
@ -65,7 +64,7 @@ public:
\param file
\param b optional \c false by default
*/
explicit Buffer(string const & file, bool b = false);
explicit Buffer(std::string const & file, bool b = false);
/// Destructor
~Buffer();
@ -73,7 +72,7 @@ public:
/** High-level interface to buffer functionality.
This function parses a command string and executes it
*/
bool dispatch(string const & command, bool * result = 0);
bool dispatch(std::string const & command, bool * result = 0);
/// Maybe we know the function already by number...
bool dispatch(FuncRequest const & func, bool * result = 0);
@ -82,9 +81,9 @@ public:
void loadAutoSaveFile();
/// load a new file
bool readFile(string const & filename);
bool readFile(std::string const & filename);
bool readFile(string const & filename, ParagraphList::iterator pit);
bool readFile(std::string const & filename, ParagraphList::iterator pit);
/// read the header, returns number of unknown tokens
int readHeader(LyXLex & lex);
@ -96,14 +95,14 @@ public:
bool readBody(LyXLex &, ParagraphList::iterator pit);
/// This parses a single token
int readParagraph(LyXLex &, string const & token,
int readParagraph(LyXLex &, std::string const & token,
ParagraphList & pars,
ParagraphList::iterator & pit,
lyx::depth_type & depth);
///
void insertStringAsLines(ParagraphList::iterator &, lyx::pos_type &,
LyXFont const &, string const &);
LyXFont const &, std::string const &);
///
ParIterator getParFromID(int id) const;
/// do we have a paragraph with this id?
@ -112,7 +111,7 @@ public:
/// This signal is emitted when a parsing error shows up.
boost::signal1<void, ErrorItem> error;
/// This signal is emitted when some message shows up.
boost::signal1<void, string> message;
boost::signal1<void, std::string> message;
/// This signal is emitted when the buffer busy status change.
boost::signal1<void, bool> busy;
/// This signal is emitted when the buffer readonly status change.
@ -132,24 +131,24 @@ public:
bool save() const;
/// Write file. Returns \c false if unsuccesful.
bool writeFile(string const &) const;
bool writeFile(std::string const &) const;
///
void writeFileAscii(string const &, int);
void writeFileAscii(std::string const &, int);
///
void writeFileAscii(std::ostream &, int);
///
string const asciiParagraph(Paragraph const &, unsigned int linelen,
std::string const asciiParagraph(Paragraph const &, unsigned int linelen,
bool noparbreak = false) const;
/// Just a wrapper for the method below, first creating the ofstream.
void makeLaTeXFile(string const & filename,
string const & original_path,
void makeLaTeXFile(std::string const & filename,
std::string const & original_path,
LatexRunParams const &,
bool output_preamble = true,
bool output_body = true);
///
void makeLaTeXFile(std::ostream & os,
string const & original_path,
std::string const & original_path,
LatexRunParams const &,
bool output_preamble = true,
bool output_body = true);
@ -163,15 +162,15 @@ public:
ParagraphList::iterator par,
lyx::depth_type depth) const;
///
void makeLinuxDocFile(string const & filename,
void makeLinuxDocFile(std::string const & filename,
bool nice, bool only_body = false);
///
void makeDocBookFile(string const & filename,
void makeDocBookFile(std::string const & filename,
bool nice, bool only_body = false);
/// returns the main language for the buffer (document)
Language const * getLanguage() const;
/// get l10n translated to the buffers language
string const B_(string const & l10n) const;
std::string const B_(std::string const & l10n) const;
///
int runChktex();
@ -180,7 +179,7 @@ public:
///
bool isBakClean() const;
///
bool isDepClean(string const & name) const;
bool isDepClean(std::string const & name) const;
/// mark the main lyx file as not needing saving
void markClean() const;
@ -189,7 +188,7 @@ public:
void markBakClean();
///
void markDepClean(string const & name);
void markDepClean(std::string const & name);
///
void setUnnamed(bool flag = true);
@ -201,25 +200,25 @@ public:
void markDirty();
/// Returns the buffer's filename. It is always an absolute path.
string const & fileName() const;
std::string const & fileName() const;
/// Returns the the path where the buffer lives.
/// It is always an absolute path.
string const & filePath() const;
std::string const & filePath() const;
/** A transformed version of the file name, adequate for LaTeX.
\param no_path optional if \c true then the path is stripped.
*/
string const getLatexName(bool no_path = true) const;
std::string const getLatexName(bool no_path = true) const;
/// Get the name and type of the log.
std::pair<LogType, string> const getLogName() const;
std::pair<LogType, std::string> const getLogName() const;
/// Change name of buffer. Updates "read-only" flag.
void setFileName(string const & newfile);
void setFileName(std::string const & newfile);
/// Name of the document's parent
void setParentName(string const &);
void setParentName(std::string const &);
/// Is buffer read-only?
bool isReadonly() const;
@ -251,9 +250,9 @@ public:
void validate(LaTeXFeatures &) const;
/// return all bibkeys from buffer and its childs
void fillWithBibKeys(std::vector<std::pair<string, string> > & keys) const;
void fillWithBibKeys(std::vector<std::pair<std::string, std::string> > & keys) const;
///
void getLabelList(std::vector<string> &) const;
void getLabelList(std::vector<std::string> &) const;
///
void changeLanguage(Language const * from, Language const * to);
@ -288,7 +287,7 @@ public:
LyXVC const & lyxvc() const;
/// Where to put temporary files.
string const & temppath() const;
std::string const & temppath() const;
/** If we are writing a nice LaTeX file or not.
While writing as LaTeX, tells whether we are
@ -373,7 +372,7 @@ private:
\param par if != 0 insert the file.
\return \c false if method fails.
*/
bool readFile(LyXLex &, string const & filename,
bool readFile(LyXLex &, std::string const & filename,
ParagraphList::iterator pit);
bool do_writeFile(std::ostream & ofs) const;

View File

@ -40,6 +40,8 @@ using lyx::support::OnlyFilename;
using lyx::support::OnlyPath;
using lyx::support::unlink;
using std::string;
extern BufferList bufferlist;

View File

@ -12,7 +12,8 @@
#ifndef BUFFER_FUNCS_H
#define BUFFER_FUNCS_H
#include "support/std_string.h"
#include <string>
class Buffer;
class TeXErrors;
@ -22,16 +23,16 @@ class ErrorList;
* Loads a LyX file \c filename into \c Buffer
* and \return success status.
*/
bool loadLyXFile(Buffer *, string const & filename);
bool loadLyXFile(Buffer *, std::string const & filename);
/* Make a new file (buffer) with name \c filename based on a template
* named \c templatename
*/
Buffer * newFile(string const & filename, string const & templatename,
Buffer * newFile(std::string const & filename, std::string const & templatename,
bool isNamed = false);
///return the format of the buffer on a string
string const BufferFormat(Buffer const & buffer);
std::string const BufferFormat(Buffer const & buffer);
///
void bufferErrors(Buffer const &, TeXErrors const &);
///

View File

@ -42,7 +42,7 @@ using std::endl;
using std::find;
using std::find_if;
using std::for_each;
using std::string;
using std::vector;

View File

@ -12,8 +12,6 @@
#ifndef BUFFER_LIST_H
#define BUFFER_LIST_H
#include "support/std_string.h"
#include <boost/utility.hpp>
#include <vector>
@ -33,7 +31,7 @@ public:
bool quitWriteAll();
/// create a new buffer
Buffer * newBuffer(string const & s, bool ronly = false);
Buffer * newBuffer(std::string const & s, bool ronly = false);
/// delete a buffer
void release(Buffer * b);
@ -42,10 +40,10 @@ public:
void closeAll();
/// returns a vector with all the buffers filenames
std::vector<string> const getFileNames() const;
std::vector<std::string> const getFileNames() const;
/// FIXME
void updateIncludedTeXfiles(string const &, LatexRunParams const &);
void updateIncludedTeXfiles(std::string const &, LatexRunParams const &);
/// emergency save for all buffers
void emergencyWriteAll();
@ -60,18 +58,18 @@ public:
Buffer * first();
/// returns true if the buffer exists already
bool exists(string const &) const;
bool exists(std::string const &) const;
/// returns true if the buffer is loaded
bool isLoaded(Buffer const * b) const;
/// returns a pointer to the buffer with the given name.
Buffer * getBuffer(string const &);
Buffer * getBuffer(std::string const &);
/// returns a pointer to the buffer with the given number.
Buffer * getBuffer(unsigned int);
/// reset current author for all buffers
void setCurrentAuthor(string const & name, string const & email);
void setCurrentAuthor(std::string const & name, std::string const & email);
private:
/// ask to save a buffer on quit, returns false if should cancel

View File

@ -49,7 +49,7 @@ using lyx::support::rtrim;
using lyx::support::tokenPos;
using std::endl;
using std::string;
using std::istringstream;
using std::ostream;
using std::ostringstream;

View File

@ -23,7 +23,6 @@
#include "support/copied_ptr.h"
#include "support/types.h"
#include "support/std_string.h"
#include <vector>
@ -57,7 +56,7 @@ public:
~BufferParams();
/// read a header token, if unrecognised, return it or an unknown class name
string const readToken(LyXLex & lex, string const & token);
std::string const readToken(LyXLex & lex, std::string const & token);
///
void writeFile(std::ostream &) const;
@ -92,7 +91,7 @@ public:
///
InsetQuotes::quote_times quotes_times;
///
string fontsize;
std::string fontsize;
///
lyx::textclass_type textclass;
///
@ -110,29 +109,29 @@ public:
///
bool use_geometry;
///
string paperwidth;
std::string paperwidth;
///
string paperheight;
std::string paperheight;
///
string leftmargin;
std::string leftmargin;
///
string topmargin;
std::string topmargin;
///
string rightmargin;
std::string rightmargin;
///
string bottommargin;
std::string bottommargin;
///
string headheight;
std::string headheight;
///
string headsep;
std::string headsep;
///
string footskip;
std::string footskip;
/* some LaTeX options */
/// The graphics driver
string graphicsDriver;
std::string graphicsDriver;
///
string fonts;
std::string fonts;
///
Spacing & spacing();
Spacing const & spacing() const;
@ -146,19 +145,19 @@ public:
BranchList & branchlist();
BranchList const & branchlist() const;
///
string inputenc;
std::string inputenc;
///
string preamble;
std::string preamble;
///
string options;
std::string options;
///
string float_placement;
std::string float_placement;
///
unsigned int columns;
///
LyXTextClass::PageSides sides;
///
string pagestyle;
std::string pagestyle;
/// \param index should lie in the range 0 <= \c index <= 3.
Bullet & temp_bullet(lyx::size_type index);
Bullet const & temp_bullet(lyx::size_type index) const;
@ -186,7 +185,7 @@ public:
/// revision tracking for this buffer ?
bool tracking_changes;
/// Time ago we agreed that this was a buffer property [ale990407]
string parentname;
std::string parentname;
///
bool compressed;
@ -197,9 +196,9 @@ public:
/// map of the file's author IDs to buffer author IDs
std::vector<int> author_map;
///
string const dvips_options() const;
std::string const dvips_options() const;
///
string const paperSizeName() const;
std::string const paperSizeName() const;
private:
/** Use the Pimpl idiom to hide those member variables that would otherwise

View File

@ -42,6 +42,7 @@ using lyx::support::bformat;
using std::istringstream;
using std::ostringstream;
using std::string;
namespace {
@ -374,7 +375,7 @@ string const currentState(BufferView * bv)
state << inset << " id: " << inset->id()
<< " text: " << inset->getLyXText(bv, true)
<< " owner: " << inset->owner();
else
else
state << -1;
#endif
return state.str();

View File

@ -14,30 +14,32 @@
#ifndef BUFFERVIEW_FUNCS_H
#define BUFFERVIEW_FUNCS_H
#include "support/std_string.h"
#include <string>
class BufferView;
class LyXFont;
class LyXText;
namespace bv_funcs {
/** Set \param data using \param font and \param toggle.
* If successful, returns true.
*/
bool font2string(LyXFont const & font, bool toggle, string & data);
bool font2string(LyXFont const & font, bool toggle, std::string & data);
/** Set \param font and \param toggle using \param data.
* If successful, returns true.
*/
bool string2font(string const & data, LyXFont & font, bool & toggle);
/** Returns the current freefont, encoded as a string to be passed to the
bool string2font(std::string const & data, LyXFont & font, bool & toggle);
/** Returns the current freefont, encoded as a std::string to be passed to the
* frontends.
*/
string const freefont2string();
std::string const freefont2string();
/** Set the freefont using the contents of \param data dispatched from
* the frontends and apply it at the current cursor location.
*/
void update_and_apply_freefont(BufferView * bv, string const & data);
void update_and_apply_freefont(BufferView * bv, std::string const & data);
/** Apply the contents of freefont at the current cursor location.
*/
void apply_freefont(BufferView * bv);
@ -62,7 +64,7 @@ extern void bold(BufferView *);
///
extern void noun(BufferView *);
///
extern void lang(BufferView *, string const &);
extern void lang(BufferView *, std::string const &);
///
extern void number(BufferView *);
///
@ -78,9 +80,9 @@ extern void styleReset(BufferView *);
///
extern void underline(BufferView *);
///
extern void fontSize(BufferView *, string const &);
extern void fontSize(BufferView *, std::string const &);
/// Returns the current font and depth as a message.
extern string const currentState(BufferView *);
extern std::string const currentState(BufferView *);
///
extern void toggleAndShow(BufferView *, LyXFont const &,
bool toggleall = true);

View File

@ -17,9 +17,10 @@
#include <boost/assert.hpp>
using lyx::pos_type;
using std::endl;
using lyx::pos_type;
using std::string;
bool operator==(Change const & l, Change const & r)

View File

@ -34,7 +34,7 @@ using std::make_pair;
using std::ifstream;
using std::pair;
using std::string;
bool CharacterSet::loadFile(string const & fname)

View File

@ -15,8 +15,8 @@
#include <map>
#include <utility>
#include <string>
#include "support/std_string.h"
/// a class for mapping char strings such as "\^{A}" to the integer value
class CharacterSet {
@ -29,21 +29,21 @@ public:
* and parses it. This function is only intended to be
* called once.
*/
bool loadFile(string const & charset);
bool loadFile(std::string const & charset);
/// return the name of the current charset
string const & getName() const;
std::string const & getName() const;
/**
* Return the encoded charset value of the given string.
*
* The bool value is false if an encoding could not be found
* in this charset, and true otherwise.
*/
std::pair<bool, int> const encodeString(string const &) const;
std::pair<bool, int> const encodeString(std::string const &) const;
private:
/// charset name
string name_;
std::string name_;
///
typedef std::map<string, unsigned char> Cdef;
typedef std::map<std::string, unsigned char> Cdef;
/// mapping from string representation to encoded value
Cdef map_;
};

View File

@ -48,7 +48,7 @@ using lyx::support::Systemcall;
using std::endl;
using std::find_if;
using std::string;
using std::vector;

View File

@ -14,8 +14,9 @@
#include "graph.h"
#include "support/std_string.h"
#include <vector>
#include <string>
class Buffer;
class Format;
@ -27,18 +28,18 @@ class LatexRunParams;
class Converter {
public:
///
Converter(string const & f, string const & t, string const & c,
string const & l);
Converter(std::string const & f, std::string const & t, std::string const & c,
std::string const & l);
///
void readFlags();
///
string from;
std::string from;
///
string to;
std::string to;
///
string command;
std::string command;
///
string flags;
std::string flags;
///
Format const * From;
///
@ -52,12 +53,12 @@ public:
bool need_aux;
/// If the converter put the result in a directory, then result_dir
/// is the name of the directory
string result_dir;
std::string result_dir;
/// If the converter put the result in a directory, then result_file
/// is the name of the main file in that directory
string result_file;
std::string result_file;
/// Command to convert the program output to a LaTeX log file format
string parselog;
std::string parselog;
};
@ -75,44 +76,44 @@ public:
return converterlist_[i];
}
///
Converter const * getConverter(string const & from, string const & to);
Converter const * getConverter(std::string const & from, std::string const & to);
///
int getNumber(string const & from, string const & to);
int getNumber(std::string const & from, std::string const & to);
///
void add(string const & from, string const & to,
string const & command, string const & flags);
void add(std::string const & from, std::string const & to,
std::string const & command, std::string const & flags);
//
void erase(string const & from, string const & to);
void erase(std::string const & from, std::string const & to);
///
void sort();
///
std::vector<Format const *> const
getReachableTo(string const & target, bool clear_visited);
getReachableTo(std::string const & target, bool clear_visited);
///
std::vector<Format const *> const
getReachable(string const & from, bool only_viewable,
getReachable(std::string const & from, bool only_viewable,
bool clear_visited);
///
bool isReachable(string const & from, string const & to);
bool isReachable(std::string const & from, std::string const & to);
///
Graph::EdgePath const getPath(string const & from, string const & to);
Graph::EdgePath const getPath(std::string const & from, std::string const & to);
///
bool usePdflatex(Graph::EdgePath const & path);
///
bool convert(Buffer const * buffer,
string const & from_file, string const & to_file_base,
string const & from_format, string const & to_format,
string & to_file);
std::string const & from_file, std::string const & to_file_base,
std::string const & from_format, std::string const & to_format,
std::string & to_file);
///
bool convert(Buffer const * buffer,
string const & from_file, string const & to_file_base,
string const & from_format, string const & to_format);
std::string const & from_file, std::string const & to_file_base,
std::string const & from_format, std::string const & to_format);
///
void update(Formats const & formats);
///
void updateLast(Formats const & formats);
///
bool formatIsUsed(string const & format);
bool formatIsUsed(std::string const & format);
///
const_iterator begin() const {
return converterlist_.begin();
@ -127,17 +128,17 @@ private:
std::vector<Format const *> const
Converters::intToFormat(std::vector<int> const & input);
///
bool scanLog(Buffer const & buffer, string const & command,
string const & filename);
bool scanLog(Buffer const & buffer, std::string const & command,
std::string const & filename);
///
bool runLaTeX(Buffer const & buffer, string const & command,
bool runLaTeX(Buffer const & buffer, std::string const & command,
LatexRunParams const &);
///
ConverterList converterlist_;
///
string latex_command_;
std::string latex_command_;
///
bool move(string const & from, string const & to, bool copy);
bool move(std::string const & from, std::string const & to, bool copy);
///
Graph G_;
};

View File

@ -23,6 +23,7 @@
using std::endl;
using std::ostringstream;
using std::string;
Counter::Counter()

View File

@ -15,8 +15,8 @@
#ifndef COUNTERS_H
#define COUNTERS_H
#include "support/std_string.h"
#include <map>
#include <string>
/// This represents a single counter.
@ -35,16 +35,16 @@ public:
///
void reset();
/// Returns the master counter of this counter
string master() const;
std::string master() const;
/// sets the master counter for this counter
void setMaster(string const & m);
void setMaster(std::string const & m);
private:
///
int value_;
/// contains master counter name; master counter is the counter
/// that, if stepped (incremented) zeroes this counter. E.g.
/// "subparagraph"'s master is "paragraph".
string master_;
std::string master_;
};
@ -53,38 +53,38 @@ private:
class Counters {
public:
/// Add a new counter to array.
void newCounter(string const & newc);
void newCounter(std::string const & newc);
/// Add new counter having oldc as its master.
void newCounter(string const & newc, string const & oldc);
void newCounter(std::string const & newc, std::string const & oldc);
///
void set(string const & ctr, int val);
void set(std::string const & ctr, int val);
///
void addto(string const & ctr, int val);
void addto(std::string const & ctr, int val);
///
int value(string const & ctr) const;
int value(std::string const & ctr) const;
/// Step (increment by one) counter named by arg, and
/// zeroes slave counter(s) for which it is the master.
/// NOTE sub-slaves not zeroed! That happens at slave's
/// first step 0->1. Seems to be sufficient.
void step(string const & ctr);
void step(std::string const & ctr);
/// Reset all counters.
void reset();
/// Reset counters matched by match string.
void reset(string const & match);
void reset(std::string const & match);
/// Copy counters whose name matches match from the &from to
/// the &to array of counters. Empty string matches all.
void copy(Counters & from, Counters & to, string const & match = string());
void copy(Counters & from, Counters & to, std::string const & match = std::string());
/// A complete expanded label, like 2.1.4 for a subsubsection
/// according to the given format
string counterLabel(string const & format);
std::string counterLabel(std::string const & format);
/// A complete label, like 1.a for enumerations
string enumLabel(string const & ctr, string const & langtype = "latin");
std::string enumLabel(std::string const & ctr, std::string const & langtype = "latin");
private:
/// A counter label's single item, 1 for subsection number in
/// the 2.1.4 subsubsection number label.
string labelItem(string const & ctr, string const & numbertype);
std::string labelItem(std::string const & ctr, std::string const & numbertype);
/// Maps counter (layout) names to actual counters.
typedef std::map<string, Counter> CounterList;
typedef std::map<std::string, Counter> CounterList;
/// Instantiate.
CounterList counterList;

View File

@ -25,7 +25,7 @@ using lyx::support::isStrInt;
using lyx::support::strToInt;
using std::setw;
using std::string;
using std::ostream;
namespace {

View File

@ -14,7 +14,6 @@
#define LYXDEBUG_H
#include "support/std_string.h"
#include "support/debugstream.h"
/** Ideally this should have been a namespace, but since we try to be
@ -85,7 +84,7 @@ struct lyx_debug_trait {
/** A function to convert symbolic string names on debug levels
to their numerical value.
*/
static type value(string const & val);
static type value(std::string const & val);
/** Display the tags and descriptions of the current debug level
of ds

View File

@ -23,6 +23,8 @@ using std::strtol;
#endif
using std::endl;
using std::string;
Encodings encodings;

View File

@ -13,8 +13,9 @@
#ifndef ENCODING_H
#define ENCODING_H
#include "support/std_string.h"
#include <map>
#include <string>
///
typedef unsigned short int Uchar;
@ -25,17 +26,17 @@ public:
///
Encoding() {}
///
Encoding(string const & n, string const & l, Uchar const * e)
Encoding(std::string const & n, std::string const & l, Uchar const * e)
: Name_(n), LatexName_(l) {
for (int i = 0; i < 256; ++i)
encoding_table[i] = e[i];
}
///
string const & Name() const {
std::string const & Name() const {
return Name_;
}
///
string const & LatexName() const {
std::string const & LatexName() const {
return LatexName_;
}
///
@ -44,9 +45,9 @@ public:
}
private:
///
string Name_;
std::string Name_;
///
string LatexName_;
std::string LatexName_;
///
Uchar encoding_table[256];
};
@ -56,13 +57,13 @@ extern Encoding symbol_encoding;
class Encodings {
public:
///
typedef std::map<string, Encoding> EncodingList;
typedef std::map<std::string, Encoding> EncodingList;
///
Encodings();
///
void read(string const & filename);
void read(std::string const & filename);
///
Encoding const * getEncoding(string const & encoding) const;
Encoding const * getEncoding(std::string const & encoding) const;
///
Encoding const * symbol_encoding() {
return &symbol_encoding_;

View File

@ -12,6 +12,8 @@
#include "errorlist.h"
using std::string;
ErrorItem::ErrorItem(string const & error, string const & description,
int par_id, int pos_start, int pos_end)
@ -23,5 +25,3 @@ ErrorItem::ErrorItem(string const & error, string const & description,
ErrorItem::ErrorItem()
: par_id(-1), pos_start(0), pos_end(0)
{}

View File

@ -12,20 +12,19 @@
#ifndef ERRORLIST_H
#define ERRORLIST_H
#include "support/std_string.h"
#include <vector>
#include <string>
class Buffer;
/// A class to hold an error item
struct ErrorItem {
string error;
string description;
std::string error;
std::string description;
int par_id;
int pos_start;
int pos_end;
ErrorItem(string const & error, string const & description,
ErrorItem(std::string const & error, std::string const & description,
int parid, int posstart, int posend);
ErrorItem();
};

View File

@ -38,7 +38,7 @@ using lyx::support::contains;
using lyx::support::MakeDisplayPath;
using std::find;
using std::string;
using std::vector;

View File

@ -14,7 +14,7 @@
#define EXPORTER_H
#include <vector>
#include "support/std_string.h"
class Buffer;
class Format;
@ -23,18 +23,18 @@ class Exporter {
public:
///
static
bool Export(Buffer * buffer, string const & format,
bool put_in_tempdir, string & result_file);
bool Export(Buffer * buffer, std::string const & format,
bool put_in_tempdir, std::string & result_file);
///
static
bool Export(Buffer * buffer, string const & format,
bool Export(Buffer * buffer, std::string const & format,
bool put_in_tempdir);
///
static
bool Preview(Buffer * buffer, string const & format);
bool Preview(Buffer * buffer, std::string const & format);
///
static
bool IsExportable(Buffer const & buffer, string const & format);
bool IsExportable(Buffer const & buffer, std::string const & format);
///
static
std::vector<Format const *> const

View File

@ -60,6 +60,7 @@
using lyx::support::compare_ascii_no_case;
using std::endl;
using std::string;
InsetOld * createInset(FuncRequest const & cmd)

View File

@ -34,6 +34,8 @@ using lyx::support::QuoteName;
using lyx::support::subst;
using lyx::support::Systemcall;
using std::string;
namespace {

View File

@ -12,58 +12,56 @@
#ifndef FORMAT_H
#define FORMAT_H
#include "support/std_string.h"
#include <vector>
#include <string>
class Buffer;
class Format {
public:
///
Format(string const & n, string const & e, string const & p,
string const & s, string const & v);
Format(std::string const & n, std::string const & e, std::string const & p,
std::string const & s, std::string const & v);
///
bool dummy() const;
///
bool isChildFormat() const;
///
string const parentFormat() const;
std::string const parentFormat() const;
///
string const & name() const {
std::string const & name() const {
return name_;
}
///
string const & extension() const {
std::string const & extension() const {
return extension_;
}
///
string const & prettyname() const {
std::string const & prettyname() const {
return prettyname_;
}
///
string const & shortcut() const {
std::string const & shortcut() const {
return shortcut_;
}
///
string const & viewer() const {
std::string const & viewer() const {
return viewer_;
}
///
void setViewer(string const & v) {
void setViewer(std::string const & v) {
viewer_ = v;
}
private:
string name_;
std::string name_;
///
string extension_;
std::string extension_;
///
string prettyname_;
std::string prettyname_;
///
string shortcut_;
std::string shortcut_;
///
string viewer_;
std::string viewer_;
};
@ -81,27 +79,27 @@ public:
return formatlist[i];
}
///
Format const * getFormat(string const & name) const;
Format const * getFormat(std::string const & name) const;
///
int getNumber(string const & name) const;
int getNumber(std::string const & name) const;
///
void add(string const & name);
void add(std::string const & name);
///
void add(string const & name, string const & extension,
string const & prettyname, string const & shortcut);
void add(std::string const & name, std::string const & extension,
std::string const & prettyname, std::string const & shortcut);
///
void erase(string const & name);
void erase(std::string const & name);
///
void sort();
///
void setViewer(string const & name, string const & command);
void setViewer(std::string const & name, std::string const & command);
///
bool view(Buffer const & buffer, string const & filename,
string const & format_name) const;
bool view(Buffer const & buffer, std::string const & filename,
std::string const & format_name) const;
///
string const prettyName(string const & name) const;
std::string const prettyName(std::string const & name) const;
///
string const extension(string const & name) const;
std::string const extension(std::string const & name) const;
///
const_iterator begin() const {
return formatlist.begin();

View File

@ -19,6 +19,7 @@
using std::endl;
using std::make_pair;
using std::pair;
using std::string;
int Alert::prompt(string const & title, string const & question,

View File

@ -28,21 +28,21 @@ namespace Alert {
* "Yes" or "No", I will personally come around to your house and
* slap you with fish, and not in an enjoyable way either.
*/
int prompt(string const & title, string const & question,
int prompt(std::string const & title, std::string const & question,
int default_button, int cancel_button,
string const & b1, string const & b2, string const & b3 = string());
std::string const & b1, std::string const & b2, std::string const & b3 = std::string());
/**
* Display a warning to the user. Title should be a short (general) summary.
* Only use this if the user cannot perform some remedial action.
*/
void warning(string const & title, string const & message);
void warning(std::string const & title, std::string const & message);
/**
* Display a warning to the user. Title should be a short (general) summary.
* Only use this if the user cannot perform some remedial action.
*/
void error(string const & title, string const & message);
void error(std::string const & title, std::string const & message);
/**
* Informational message. Use very very sparingly. That is, you must
@ -50,12 +50,12 @@ void error(string const & title, string const & message);
* and reciting the Nicene Creed, whilst running uphill and also
* eating.
*/
void information(string const & title, string const & message);
void information(std::string const & title, std::string const & message);
/// Asks for a text. DO NOT USE !!
std::pair<bool, string> const
askForText(string const & msg,
string const & dflt = string());
std::pair<bool, std::string> const
askForText(std::string const & msg,
std::string const & dflt = std::string());
}

View File

@ -11,15 +11,16 @@
// GUI-specific implementations
#include "support/std_string.h"
#include <utility>
#include <string>
int prompt_pimpl(string const & title, string const & question,
int prompt_pimpl(std::string const & title, std::string const & question,
int default_button, int escape_button,
string const & b1, string const & b2, string const & b3);
std::string const & b1, std::string const & b2, std::string const & b3);
void warning_pimpl(string const & title, string const & warning);
void error_pimpl(string const & title, string const & warning);
void information_pimpl(string const & title, string const & warning);
void warning_pimpl(std::string const & title, std::string const & warning);
void error_pimpl(std::string const & title, std::string const & warning);
void information_pimpl(std::string const & title, std::string const & warning);
std::pair<bool, string> const askForText_pimpl(string const & msg, string const & dflt);
std::pair<bool, std::string> const askForText_pimpl(std::string const & msg, std::string const & dflt);

View File

@ -20,6 +20,9 @@
#include <boost/bind.hpp>
using std::string;
// Note that static boost signals break some compilers, so this wrapper
// initialises the signal dynamically when it is first invoked.
template<typename Signal>

View File

@ -15,9 +15,6 @@
#include <boost/signals/signal0.hpp>
#include <boost/signals/signal1.hpp>
#include "support/std_string.h"
class Dialog;
class InsetBase;
class LyXView;
@ -92,7 +89,7 @@ public:
the dialog. Several of these dialogs do not need any data,
so it defaults to string().
*/
void show(string const & name, string const & data = string());
void show(std::string const & name, std::string const & data = std::string());
/** \param name == "bibtex", "citation" etc; an identifier used to
launch a particular dialog.
@ -105,46 +102,46 @@ public:
dialog on 'Apply'; should it be used to create a new inset at
the current cursor position or modify an existing, 'open' inset?
*/
void show(string const & name, string const & data, InsetBase * inset);
void show(std::string const & name, std::string const & data, InsetBase * inset);
/** \param name == "citation", "bibtex" etc; an identifier used
to update the contents of a particular dialog with \param data .
See the comments to 'show', above.
*/
void update(string const & name, string const & data);
void update(std::string const & name, std::string const & data);
/// is the dialog currently visible?
bool visible(string const & name) const;
bool visible(std::string const & name) const;
/** All Dialogs of the given \param name will be closed if they are
connected to the given \param inset.
*/
static void hide(string const & name, InsetBase * inset);
static void hide(std::string const & name, InsetBase * inset);
///
void disconnect(string const & name);
void disconnect(std::string const & name);
///
InsetBase * getOpenInset(string const & name) const;
InsetBase * getOpenInset(std::string const & name) const;
private:
///
void hideSlot(string const & name, InsetBase * inset);
void hideSlot(std::string const & name, InsetBase * inset);
///
void redraw() const;
///
bool isValidName(string const & name) const;
bool isValidName(std::string const & name) const;
///
Dialog * find_or_build(string const & name);
Dialog * find_or_build(std::string const & name);
///
Dialog * build(string const & name);
Dialog * build(std::string const & name);
///
LyXView & lyxview_;
///
std::map<string, InsetBase *> open_insets_;
std::map<std::string, InsetBase *> open_insets_;
///
typedef boost::shared_ptr<Dialog> DialogPtr;
///
std::map<string, DialogPtr> dialogs_;
std::map<std::string, DialogPtr> dialogs_;
/// the stuff below is slated to go...
void init_pimpl();

View File

@ -13,12 +13,11 @@
#ifndef FILEDIALOG_H
#define FILEDIALOG_H
#include <utility>
#include "lfuns.h"
#include "support/std_string.h"
#include <utility>
#include <string>
/**
* \class FileDialog
@ -28,7 +27,7 @@ class FileDialog
{
public:
/// label, directory path button
typedef std::pair<string, string> Button;
typedef std::pair<std::string, std::string> Button;
/// result type
enum ResultType {
@ -37,7 +36,7 @@ public:
};
/// result return
typedef std::pair<FileDialog::ResultType, string> Result;
typedef std::pair<FileDialog::ResultType, std::string> Result;
/**
* Constructs a file dialog with title \param title.
@ -50,10 +49,10 @@ public:
* additional directories in the navigation (an empty
* directory is interpreted as getcwd())
*/
FileDialog(string const & title,
FileDialog(std::string const & title,
kb_action a = LFUN_SELECT_FILE_SYNC,
Button b1 = Button(string(), string()),
Button b2 = Button(string(), string()));
Button b1 = Button(std::string(), std::string()),
Button b2 = Button(std::string(), std::string()));
~FileDialog();
@ -69,16 +68,16 @@ public:
*
* FIXME: should support multiple lines of these for different file types.
*/
Result const open(string const & path = string(),
string const & mask = string(),
string const & suggested = string());
Result const open(std::string const & path = std::string(),
std::string const & mask = std::string(),
std::string const & suggested = std::string());
/**
* Choose a directory, starting in directory \param
* path.
*/
Result const opendir(string const & path = string(),
string const & suggested = string());
Result const opendir(std::string const & path = std::string(),
std::string const & suggested = std::string());
/**
* Choose a file for saving, starting in directory \param
@ -89,9 +88,9 @@ public:
*
* for example, "*.ps | PostScript files (*.ps)".
*/
Result const save(string const & path = string(),
string const & mask = string(),
string const & suggested = string());
Result const save(std::string const & path = std::string(),
std::string const & mask = std::string(),
std::string const & suggested = std::string());
/* This *has* to be public because there is no way to specify extern "C" functions
@ -103,7 +102,7 @@ public:
private:
/// the dialog title
string title_;
std::string title_;
/// success action to perform if not synchronous
kb_action success_;

View File

@ -12,7 +12,7 @@
#ifndef LYXKEYSYM_H
#define LYXKEYSYM_H
#include "support/std_string.h"
#include <string>
/**
* This is a base class for representing a keypress.
@ -27,7 +27,7 @@ public:
virtual ~LyXKeySym() {}
/// Initialize with the name of a key. F. ex. "space" or "a"
virtual void init(string const & symbolname) = 0;
virtual void init(std::string const & symbolname) = 0;
/// Is this a valid key?
virtual bool isOK() const = 0;
@ -39,14 +39,14 @@ public:
virtual bool isText() const { return false; }
/// What is the symbolic name of this key? F.ex. "Return" or "c"
virtual string getSymbolName() const = 0;
virtual std::string getSymbolName() const = 0;
/**
* Return the value of the keysym into the local ISO encoding.
* This converts the LyXKeySym to a 8-bit encoded character.
* This relies on user to use the right encoding.
*/
virtual char getISOEncoded(string const & encoding) const = 0;
virtual char getISOEncoded(std::string const & encoding) const = 0;
};

View File

@ -47,6 +47,7 @@ using lyx::support::MakeDisplayPath;
using lyx::support::OnlyFilename;
using std::endl;
using std::string;
string current_layout;

View File

@ -19,8 +19,6 @@
#include <boost/signals/trackable.hpp>
#include <boost/signals/signal0.hpp>
#include "support/std_string.h"
class Buffer;
class Toolbar;
class Intl;
@ -103,7 +101,7 @@ public:
//@}
/// sets the layout in the toolbar layout selection
void setLayout(string const & layout);
void setLayout(std::string const & layout);
/// updates the possible layouts selectable
void updateLayoutChoice();
@ -119,7 +117,7 @@ public:
boost::signal0<void> view_state_changed;
/// display a message in the view
virtual void message(string const &) = 0;
virtual void message(std::string const &) = 0;
/// clear any temporary message and replace with current status
virtual void clearMessage() = 0;
@ -148,7 +146,7 @@ private:
* @param t main window title
* @param it iconified (short) title
*/
virtual void setWindowTitle(string const & t, string const & it) = 0;
virtual void setWindowTitle(std::string const & t, std::string const & it) = 0;
/// called on timeout
void autoSave();

View File

@ -13,9 +13,6 @@
#ifndef MENUBAR_H
#define MENUBAR_H
#include "support/std_string.h"
/**
* The LyX GUI independent menubar class
* The GUI interface is implemented in the frontends
@ -25,7 +22,7 @@ public:
///
virtual ~Menubar() {}
/// Opens a top-level submenu given its name
virtual void openByName(string const &) = 0;
virtual void openByName(std::string const &) = 0;
/// update the state of the menuitems
virtual void update() = 0;
};

View File

@ -19,6 +19,7 @@
#include "lyxfont.h"
using std::max;
using std::string;
Painter & Painter::button(int x, int y, int w, int h)

Some files were not shown because too many files have changed in this diff Show More