From: Angus Leeming Date: Fri, 25 Feb 2005 22:13:13 +0000 (+0000) Subject: Declare stuff with a constructor as "class Foo" rather than "struct Foo". X-Git-Tag: 1.6.10~14495 X-Git-Url: https://git.lyx.org/gitweb/?a=commitdiff_plain;h=1f735c7380c03f3759375b7855b53e62ca90719e;p=features.git Declare stuff with a constructor as "class Foo" rather than "struct Foo". Nonsense to keep MSVC happy. git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@9684 a592a061-630c-0410-9148-cb99ea01b6c8 --- diff --git a/src/tex2lyx/ChangeLog b/src/tex2lyx/ChangeLog index c113b3de3d..e8d9de17cf 100644 --- a/src/tex2lyx/ChangeLog +++ b/src/tex2lyx/ChangeLog @@ -1,3 +1,13 @@ +2005-02-25 Angus Leeming + + * context.h: declare as "class Font" rather than "struct Font". + Ditto "class Context". + + * table.C: declare as "class ColInfo" rather than "struct ColInfo". + Ditto "class RowInfo" and "class CellInfo". + + Changes to make MSVC agree to link the code. + 2005-02-05 Georg Baum * context.C (begin_deeper, end_deeper): adjust output to LyX diff --git a/src/tex2lyx/context.h b/src/tex2lyx/context.h index a4fd4a916a..29be22ffb2 100644 --- a/src/tex2lyx/context.h +++ b/src/tex2lyx/context.h @@ -23,7 +23,8 @@ * If more font related stuff is needed, it might be good to change to * LyXFont. */ -struct Font { +class Font { +public: Font() { init(); @@ -43,7 +44,8 @@ struct Font { // A helper struct -struct Context { +class Context { +public: Context(bool need_layout_, LyXTextClass const & textclass_, LyXLayout_ptr layout_ = LyXLayout_ptr(), @@ -106,5 +108,4 @@ struct Context { Font font; }; - #endif diff --git a/src/tex2lyx/table.C b/src/tex2lyx/table.C index 4cc1d08021..a7e5b606a1 100644 --- a/src/tex2lyx/table.C +++ b/src/tex2lyx/table.C @@ -38,8 +38,8 @@ std::map special_columns; namespace { -struct ColInfo -{ +class ColInfo { +public: ColInfo() : align('c'), rightline(false), leftline(false) {} /// column alignment char align; @@ -70,8 +70,8 @@ enum LTRowType }; -struct RowInfo -{ +class RowInfo { +public: RowInfo() : topline(false), bottomline(false), type(LT_NORMAL), newpage(false) {} /// horizontal line above @@ -86,8 +86,8 @@ struct RowInfo }; -struct CellInfo -{ +class CellInfo { +public: CellInfo() : multi(0), align('n'), leftline(false), rightline(false), topline(false), bottomline(false) {} /// cell content