java


How to write bangla language in iText pdf in android


I have used bangali Language in itext pdf in java but it not work properly My expected output is :প্রযুক্তি শিল্পের দ্রুত
But actual generated output is :
here is my code
try {
Document document = new Document();
String encoding = "Identity-H";
Font fontNormal = FontFactory.getFont(("c:/windows/fonts/arialuni.ttf"), encoding, BaseFont.EMBEDDED, 8, Font.NORMAL);
PdfWriter pdfWriter = PdfWriter.getInstance(document, new FileOutputStream("D:/lockman/mas.pdf"));
pdfWriter.setPageEvent(new PDFGenerator());
document.open();
document.add(header);
Chunk chunkBengali = new Chunk("প্রযুক্তি শিল্পের দ্রুত " + "\n", fontNormal);
PdfPTable table = new PdfPTable(2);
table.addCell("Locale");
table.addCell("Translated Text");
PdfPCell cellBengali = new PdfPCell(new Phrase(chunkBengali));
table.addCell(new PdfPCell(new Phrase(new Chunk("Bengali", fontNormal))));
table.addCell(cellBengali);
document.add(table);
document.add(footer);
document.close();
} catch (FileNotFoundException ex) {
Logger.getLogger(PDFGenerator.class.getName()).log(Level.SEVERE, null, ex);
} catch (DocumentException ex) {
Logger.getLogger(PDFGenerator.class.getName()).log(Level.SEVERE, null, ex);
}
`

Related Links

Android aar extracted
Javafx: new UI thread
Add list view to fragment using rettrofit
DropwizardAppRule and maven-failsafe-plugin
Iterate through a String,Vector LinkedHashmap and print the full vector
hprof file not generated by Android application
Formatting preference values onSharedPreferenceChanged
Java dead code in different places
How to programmatically achieve editing of the spool file header of the normal windows print queue 'spool file' before it is sent to the printer?
Caused by: java.lang.NoClassDefFoundError: org/springframework/data/repository/support/PageableExecutionUtils
Why can't Java find a class from a jar file?
Propert file is not loading properly
Invalid format String containing %
Java Game only numbers validation and split in classes
Redeploy spring-boot application in docker container?
Two For loops to increment, compare and find shift cipher keys

Categories

HOME
client
omnet++
zeromq
lodash
relay
grep
jsp-tags
rsync
blueprintjs
node-notifier
android-youtube-api
contact
awesome-wm
vb.net-2010
size
hex-editors
designer
ef-migrations
lucene.net
scichart
predix
errorlevel
cloudhub
tar
google-search-api
blazemeter
sqlcipher
smb
neo4j-spatial
xacml
procdump
uisplitview
catel
noraui
caret
accelerate-framework
gammu
ghost4j
http-referer
amazon-kinesis-kpl
avro4s
dynamic-reports
glew
eclipse-gef
websphere-mq-fte
executenonquery
long-polling
upstart
worksheet
pnotify
datastax-startup
pebble-watch
ifs
epson
hittest
color-profile
orthogonal
blacklist
gnome-shell-extensions
messenger
abcpdf9
color-picker
savon
bonobo
thrust
storekit
holder.js
moveit
master-slave
bgp
ford-fulkerson
qdialog
feedback
iis-arr
kcachegrind
deis
cakephp-3.1
tableau-online
apache-commons-fileupload
clipperlib
notify
umbraco6
rake-task
xc16
file-copying
fmod
floating-point-precision
runtime.exec
apc
easy-install
chronoforms
kyotocabinet
free-variable
e4x
pvrtc
browser-detection
javaspaces
onsubmit
enter
netbeans-6.9
coercion
appender
self-extracting
netbeans-7.1
recent-documents
xfbml
html-input
gallio
gamequery
preference
database-management
meego
yagni
pascal-fc
rtml
caching-application-block

Resources

Mobile Apps Dev
Database Users
javascript
java
csharp
php
android
MS Developer
developer works
python
ios
c
html
jquery
RDBMS discuss
Cloud Virtualization
Database Dev&Adm
javascript
java
csharp
php
python
android
jquery
ruby
ios
html
Mobile App
Mobile App
Mobile App