3

I am generating Russian table and row height issue. Below is part of my code (MWE).

\documentclass[11pt,table,a5paper]{article}
\usepackage{graphicx}
\usepackage[framemethod=TikZ]{mdframed}
\usepackage[top=2cm, bottom=2cm, outer=2.1cm, inner=1cm,twoside, headsep=26pt]{geometry}
\usepackage[utf8]{inputenc}
\usepackage{longtable}
\usepackage[english,russian]{babel}
\usepackage{multirow}
\definecolor{textcol}{rgb}{0,.412,.651}
\definecolor{rowcol}{rgb}{.04, .55, .87}
\begin{document}
\newcolumntype{M}[1]{>{\centering\arraybackslash}p{#1}} 
 {\renewcommand{\arraystretch}{1.8}\begin{longtable} {|p{3.35cm}|M{1.3cm}|M{1.87cm}|} 
\hline 
\rowcolor{textcol} \textbf{\textcolor{white} {данные}}&\textbf{\textcolor{white}{данные}}&\textbf{ \textcolor{white} {Страница}} \\ 
\endfirsthead 
\rowcolor{textcol} \textbf{\textcolor{white} {данные}}&\textbf{\textcolor{white}{данные}}&\textbf{ \textcolor{white} {Страница}} \\ 
\endhead 
\hline 
\rowcolor{rowcol} 
\parbox[t][1.058cm]{3.4cm}{\raggedright развитие постоянных зубов} & N/A&19\\ 
\hline 
\rowcolor{rowcol} 
\parbox[t][1.058cm]{3.4cm}{\raggedright ожирение (в раннем детстве)} & N/A&24\\ 
\hline 
\end{longtable}} 
\end{document}linecolor=goldenpoppy

enter image description here

In the outout, row1 of table has more height than row2 while both are using same parameter 1.058cm. How can i fix this issue.

  • 1
    Is this really a minimum working example (MWE)? It seems to me that a lot of packages are not necessary. What are you trying to achieve? Why not just have one table instead of two side by side? What you can do is use the {minipage}[<vertical alignment>][<height>]{<width>} environment inside the table cells to control the height. – yori Dec 10 '13 at 8:28
  • Why don't you simply use one table? – egreg Dec 10 '13 at 8:50
  • It is part of big chunk. Actually for my need i have to use 2 side by tables. For my need, i use \parbox[t][1.058cm]{3.4cm}. How is this different from {minipage}[<vertical alignment>][<height>]{<width>}. Any working example will surely help me. – manish Dec 11 '13 at 0:58
  • I have just updated my question. Pls refer to latest question. – manish Dec 11 '13 at 2:26
  • The code is still far from minimal. – Svend Tveskæg Dec 11 '13 at 3:35
4
\documentclass[11pt,table,a5paper]{article}
\usepackage[utf8]{inputenc}
\usepackage[english,russian]{babel}

\usepackage{array}
\usepackage{longtable}
\usepackage{ragged2e}
\newcolumntype{M}[1]{>{\Centering}m{#1}} 

\begin{document}

\begingroup%  to keep \arraystretch local
\renewcommand{\arraystretch}{1.8}
\begin{longtable} {|>{\RaggedRight}m{3.35cm}|M{1.3cm}|M{1.87cm}|}\hline 
 развитие\vphantom{()} постоянных зубов & N/A&19\\\hline  
 ожирение (в раннем детстве) & N/A&24\\\hline 
\end{longtable}
\endgroup

\end{document}

enter image description here

|improve this answer|||||

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.