1

I want to divide my page into 9 cells(3x3) and each cell contains one minipage. So, I set the minpage width as 0.33\textwidth. Problem is minipage of cell (2,3) moved to (3,1).

enter image description here

\documentclass{article}
\usepackage{booktabs}
\usepackage[a4paper,left=0cm,top=0.2cm,bottom=0cm,right=0cm]{geometry}
\usepackage{polyglossia}
\setmainlanguage[numerals=Devanagari]{bengali}
\setmainlanguage{bengali}
\setotherlanguage{english}
%\newfontfamily\englishfont[Scale=MatchLowercase]{Linux Biolinum O}
\newfontfamily\bengalifont[Script=Bengali]{Akaash}
\usepackage{pgffor}
\newcommand{\ListItem}[1]{\underline{\makebox[5cm][l]{#1}}}
\begin{document}
\begin{minipage}{0.33\textwidth}
\foreach \x in {চাল,ডাল,লবণ,তেল,মরিচ,পেঁয়াজ,রসুন,আদা,মুরগী,মশলা}
{
\ListItem{\x}\par\bigskip}
\end{minipage}
\begin{minipage}{0.33\textwidth}
\foreach \x in {চাল,ডাল,লবণ,তেল,মরিচ,পেঁয়াজ,রসুন,আদা,মুরগী,মশলা}
{
\ListItem{\x}\par\bigskip}
\end{minipage}
\begin{minipage}{0.33\textwidth}
\foreach \x in {চাল,ডাল,লবণ,তেল,মরিচ,পেঁয়াজ,রসুন,আদা,মুরগী,মশলা}
{
\ListItem{\x}\par\bigskip}
\end{minipage}
\\

\vspace{2cm}
\begin{minipage}{0.33\textwidth}
\foreach \x in {চাল,ডাল,লবণ,তেল,মরিচ,পেঁয়াজ,রসুন,আদা,মুরগী,মশলা}
{
\ListItem{\x}\par\bigskip}
\end{minipage}
\begin{minipage}{0.33\textwidth}
\foreach \x in {চাল,ডাল,লবণ,তেল,মরিচ,পেঁয়াজ,রসুন,আদা,মুরগী,মশলা}
{
\ListItem{\x}\par\bigskip}
\end{minipage}

\begin{minipage}{0.33\textwidth}
\foreach \x in {চাল,ডাল,লবণ,তেল,মরিচ,পেঁয়াজ,রসুন,আদা,মুরগী,মশলা}
{
\ListItem{\x}\par\bigskip}
\end{minipage}

\vspace{2cm}
\begin{minipage}{0.33\textwidth}
\foreach \x in {চাল,ডাল,লবণ,তেল,মরিচ,পেঁয়াজ,রসুন,আদা,মুরগী,মশলা}
{
\ListItem{\x}\par\bigskip}
\end{minipage}
\begin{minipage}{0.33\textwidth}
\foreach \x in {চাল,ডাল,লবণ,তেল,মরিচ,পেঁয়াজ,রসুন,আদা,মুরগী,মশলা}
{
\ListItem{\x}\par\bigskip}
\end{minipage}
\begin{minipage}{0.33\textwidth}
\foreach \x in {চাল,ডাল,লবণ,তেল,মরিচ,পেঁয়াজ,রসুন,আদা,মুরগী,মশলা}
{
\ListItem{\x}\par\bigskip}
\end{minipage}
\end{document}
  • 1
    Try this:` ...\end{minipage}\begin{minipage}...` without a new line or space between and and next beginning. – user139954 Mar 23 '18 at 2:42
2

There is an empty line between minipages (2,2) and (2,3), which makes a new paragraph. Just delete this empty line. It is the line 40 in your example.

Here is my MWE. Note I have changed font in the line 9, because I don't have Linux Biolinum font installed.

\documentclass{article}
\usepackage{booktabs}
\usepackage[a4paper,left=0cm,top=0.2cm,bottom=0cm,right=0cm]{geometry}
\usepackage{polyglossia}
\setmainlanguage[numerals=Devanagari]{bengali}
\setmainlanguage{bengali}
\setotherlanguage{english}
\newfontfamily\bengalifont[Script=Bengali]{Ani}
\usepackage{pgffor}
\newcommand{\ListItem}[1]{\underline{\makebox[5cm][l]{#1}}}
\begin{document}
\begin{minipage}{0.33\linewidth}
\foreach \x in {চাল,ডাল,লবণ,তেল,মরিচ,পেঁয়াজ,রসুন,আদা,মুরগী,মশলা}
{
\ListItem{\x}\par\bigskip}
\end{minipage}
\begin{minipage}{0.33\linewidth}
\foreach \x in {চাল,ডাল,লবণ,তেল,মরিচ,পেঁয়াজ,রসুন,আদা,মুরগী,মশলা}
{
\ListItem{\x}\par\bigskip}
\end{minipage}
\begin{minipage}{0.33\linewidth}
\foreach \x in {চাল,ডাল,লবণ,তেল,মরিচ,পেঁয়াজ,রসুন,আদা,মুরগী,মশলা}
{
\ListItem{\x}\par\bigskip}
\end{minipage}
\\

\vspace{2cm}
\begin{minipage}{0.33\linewidth}
\foreach \x in {চাল,ডাল,লবণ,তেল,মরিচ,পেঁয়াজ,রসুন,আদা,মুরগী,মশলা}
{
\ListItem{\x}\par\bigskip}
\end{minipage}
\begin{minipage}{0.33\linewidth}
\foreach \x in {চাল,ডাল,লবণ,তেল,মরিচ,পেঁয়াজ,রসুন,আদা,মুরগী,মশলা}
{
\ListItem{\x}\par\bigskip}
\end{minipage}
\begin{minipage}{0.33\linewidth}
\foreach \x in {চাল,ডাল,লবণ,তেল,মরিচ,পেঁয়াজ,রসুন,আদা,মুরগী,মশলা}
{
\ListItem{\x}\par\bigskip}
\end{minipage}

\vspace{2cm}
\begin{minipage}{0.33\linewidth}
\foreach \x in {চাল,ডাল,লবণ,তেল,মরিচ,পেঁয়াজ,রসুন,আদা,মুরগী,মশলা}
{
\ListItem{\x}\par\bigskip}
\end{minipage}
\begin{minipage}{0.33\linewidth}
\foreach \x in {চাল,ডাল,লবণ,তেল,মরিচ,পেঁয়াজ,রসুন,আদা,মুরগী,মশলা}
{
\ListItem{\x}\par\bigskip}
\end{minipage}
\begin{minipage}{0.33\linewidth}
\foreach \x in {চাল,ডাল,লবণ,তেল,মরিচ,পেঁয়াজ,রসুন,আদা,মুরগী,মশলা}
{
\ListItem{\x}\par\bigskip}
\end{minipage}
\end{document}

enter image description here

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.