From: Juergen Spitzmueller Date: Fri, 24 Aug 2018 07:39:46 +0000 (+0200) Subject: tex2lyx: also support rotated xltabulars X-Git-Url: https://git.lyx.org/gitweb/?a=commitdiff_plain;h=1ddf94a1565cd9f2b3358513907e3c408b13f107;p=features.git tex2lyx: also support rotated xltabulars --- diff --git a/src/tex2lyx/Context.cpp b/src/tex2lyx/Context.cpp index 5112401b08..f28911a3c5 100644 --- a/src/tex2lyx/Context.cpp +++ b/src/tex2lyx/Context.cpp @@ -85,7 +85,7 @@ Context::Context(bool need_layout_, new_layout_allowed(true), merging_hyphens_allowed(true), textclass(textclass_), layout(layout_), parent_layout(parent_layout_), - font(font_), rotlongtable(false) + font(font_), tablerotation(0) { if (!layout) layout = &textclass.defaultLayout(); diff --git a/src/tex2lyx/Context.h b/src/tex2lyx/Context.h index 4fd1ff28bb..64d69e3561 100644 --- a/src/tex2lyx/Context.h +++ b/src/tex2lyx/Context.h @@ -165,8 +165,8 @@ public: TeXFont font; /// font attributes of normal text static TeXFont normalfont; - /// A rotated longtable - bool rotlongtable; + /// Table rotation angle + int tablerotation; private: void begin_layout(std::ostream & os, Layout const * const & l); diff --git a/src/tex2lyx/table.cpp b/src/tex2lyx/table.cpp index c432a2c35f..8beeb2d28f 100644 --- a/src/tex2lyx/table.cpp +++ b/src/tex2lyx/table.cpp @@ -1416,13 +1416,10 @@ void handle_tabular(Parser & p, ostream & os, string const & name, //cerr << "// output what we have\n"; // output what we have - string rotate = "0"; - if (is_long_tabular && context.rotlongtable) - rotate = "90"; os << "\n\n"; os << "