3
% !TEX TS-program = XeLaTeX

\documentclass[10pt]{article}
\usepackage{polyglossia}
\setmainlanguage[numerals=Devanagari]{bengali}
\setotherlanguage{english}
\newfontfamily\englishfont[Scale=MatchLowercase]{Linux Biolinum O}
\newfontfamily\bengalifont[Script=Bengali]{Akaash}
\begin{document}
\tableofcontents

\section{ভূমিকা}
এটি একটি ইংরেজি লেখা ছোট অধ্যায় যে বাঙ্গালী এ \textenglish{Google Translate} দ্বারা অনুবাদ করা হয়েছে. এটা খুব স্পষ্ট নয় যদি সঠিক অনুবাদ বা না কিন্তু ক্রিয়াটি ফন্ট দেখাতে যথেষ্ট হওয়া উচিত.
\end{document}

I have copied the code from How to write Bengali in LaTeX? .

When I paste it in my KILE editor its not working. Even I have inserted it on https://www.writelatex.com/656918hxmjxx#/1381658/
but it is showing compile error. How to solve this?

sudo apt-get install ttf-bengali-fonts

From above I have installed the code.

When I run the problem is showing:

enter image description here

This is the .log file,:

This is pdfTeX, Version 3.1415926-1.40.10 (TeX Live 2009/Debian) (format=pdflatex 2013.11.5)  17 JAN 2014 00:44
entering extended mode
 %&-line parsing enabled.
**ppp.tex
(./ppp.tex
LaTeX2e <2009/09/24>
Babel <v3.8l> and hyphenation patterns for english, usenglishmax, dumylang, noh
yphenation, sanskrit, loaded.
(/usr/share/texmf-texlive/tex/latex/base/article.cls
Document Class: article 2007/10/19 v1.4h Standard LaTeX document class
(/usr/share/texmf-texlive/tex/latex/base/size10.clo
File: size10.clo 2007/10/19 v1.4h Standard LaTeX file (size option)
)
\c@part=\count79
\c@section=\count80
\c@subsection=\count81
\c@subsubsection=\count82
\c@paragraph=\count83
\c@subparagraph=\count84
\c@figure=\count85
\c@table=\count86
\abovecaptionskip=\skip41
\belowcaptionskip=\skip42
\bibindent=\dimen102
)
(/usr/share/texmf-texlive/tex/xelatex/polyglossia/polyglossia.sty
Package: polyglossia 2009/01/25 v1.0.2 Babel replacement for XeLaTeX


! LaTeX Error: File `etoolbox.sty' not found.

Type X to quit or <RETURN> to proceed,
or enter new name. (Default extension: sty)

Enter file name: 
! Emergency stop.
<read *> 

l.5 \RequirePackage
                   {fontspec} %which itself depends on xkeyval^^M
*** (cannot \read from terminal in nonstop modes)


Here is how much of TeX's memory you used:
 208 strings out of 495052
 2371 string characters out of 1182271
 47242 words of memory out of 3000000
 3474 multiletter control sequences out of 15000+50000
 3640 words of font info for 14 fonts, out of 3000000 for 9000
 28 hyphenation exceptions out of 8191
 23i,0n,19p,158b,36s stack positions out of 5000i,500n,10000p,200000b,50000s
!  ==> Fatal error occurred, no output PDF file produced!
5
  • 1
    Make sure you are compiling with XeLaTeX; pdfTeX has many limitations concerning Unicode. Also ensure you have the Akaash and Linux Biolinum O fonts installed on your computer. Arial Unicode MS is installed on OSX: i.stack.imgur.com/qMJ42.png Jan 16, 2014 at 17:06
  • Please post the error you are getting. You can find errors in the log file (created in the same directory as your TeX file). Errors are indicated with lines that start with !, so find the first error that you get and post it. Jan 16, 2014 at 18:42
  • The sty file is part of the standard distribution; please post the relevant portion of your log file. Jan 16, 2014 at 18:47
  • log file has been attached. Jan 16, 2014 at 18:52
  • @ComplexGuy As Sean Allred pointed out, you need to compile with XeLaTeX - that log shows that you are trying to compile with pdfTeX. Also, it strongly suggests that there is something amiss with your installation of TeX or your configuration since, as has also been said, etoolbox is standard. How did you install TeX exactly?
    – cfr
    Jan 16, 2014 at 22:22

1 Answer 1

2

The log file is telling you that polyglossia needs etoolbox to work. You appear to not have etoolbox installed:

! LaTeX Error: File `etoolbox.sty' not found.

Type X to quit or <RETURN> to proceed,
or enter new name. (Default extension: sty)

Enter file name: 
! Emergency stop.

I would take a look at How to install "vanilla" TeXLive on Debian or Ubuntu? to ensure you have a full TeX Live distribution. If you don't mind being several iterations behind the current state of CTAN, you can run

sudo apt-get install texlive-full

to get (mostly) everything. It should at least come with the tools you need to get this document compiling.


Make sure you are compiling with XeLaTeX; pdfTeX has many limitations concerning Unicode. I don't have Kile installed, but this suggestion from the TUG mailing list will be helpful:

Configure Kile -> tools -> new -> create some name -> behaviour like pdflatex -> change command into "xelatex"


Also ensure you have the Akaash and Linux Biolinum O fonts installed on your computer.

Arial Unicode MS is installed on OSX:

\documentclass[10pt]{article}
\usepackage{polyglossia}
\setmainlanguage[numerals=Devanagari]{bengali}
\setotherlanguage{english}
\newfontfamily\bengalifont[Script=Bengali]{Arial Unicode MS}
\begin{document}
\tableofcontents

\section{ভূমিকা}
এটি একটি ইংরেজি লেখা ছোট অধ্যায় যে বাঙ্গালী এ \textenglish{Google Translate}
দ্বারা অনুবাদ করা হয়েছে. এটা খুব স্পষ্ট নয় যদি সঠিক অনুবাদ বা না কিন্তু ক্রিয়াটি ফন্ট দেখাতে যথেষ্ট হওয়া উচিত.
\end{document}

enter image description here

Find out which fonts Aptitude installed for you and use one of those in Arial's place.

6
  • Not working can you see the image I attached please. Jan 16, 2014 at 18:38
  • Yeah… that means nothing to me. No error is even shown. See my additional comment on your original question. Jan 16, 2014 at 18:41
  • when I run a .sty file file is appeared. I have inserted in the question box. Jan 16, 2014 at 18:46
  • @ComplexGuy See my edit. Jan 16, 2014 at 18:56
  • I have installed the total texlive you mentioned by sudo apt-get install texlive-full and a blank out page is appeared. What to do? What is the error in the log filke ! Cannot use \XeTeXOTfeaturetag with nullfont; not an OpenType Layout font. \iterate ...ifnum \XeTeXOTfeaturetag \zf@basefont \c@zf@script \c@zf@languag... l.7 ...tfamily\bengalifont[Script=Bengali]{Akaash} ! Missing = inserted for \ifnum. <to be read again> Jan 17, 2014 at 16:28

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .