Chinese characters in IntelliJ IDEA 12 overlapped - intellij-idea

I use IntelliJ IDEA to develop my Android project. I've encountered this issue when editing the string XML resource file today. The Chinese characters do show but just overlapped one by one. So basically all you see is a bunch of Chinese characters filled in and overlapped at single character space. Interestingly, when you try to delete those Chinese characters, you just delete the following XML closing tag but not the Chinese character itself...
Have tried copy/paste, same result. I am using the Windows 32bit version.
Can anybody help to fix this issue?

Please check this issue and linked issues for the problem background.
Right now when IDEA doesn't find the glyph to display in the current editor font that you have set in File | Settings | Editor | Colors & Fonts, Font, it starts to search for the first font that has this glyph and finds some font with incorrect metrics that displays overlapping glyphs.
When this request is implemented, you'll be able to specify the order of fall back fonts so that some properly working font is tried first.
At the moment the solution is to change the editor font to the one that has all the required glyphs and proper font metrics (or to find and uninstall the font that is tried first and is displayed incorrectly, note that when running under JDK 1.7 IDEA will also try .otf fonts, not just .ttf, that is why the behavior is different in IDEA 11 defaulting to JDK 1.6 and IDEA 12 that runs under JDK 1.7).

Related

How to convert unusual unicode characters (UTF-8) to PDF?

I would like to convert a text file containing Unicode characters in UTF-8 to a PDF file. When I cat the file or look at it with vim, everything is great, but when I open the file with LibreOffice, the formatting is off. I have tried various fonts, none of which have worked. Is there a font file somewhere on my Ubuntu 16.04 system which is used for display in a terminal window? It seems that would be the font to tell LibreOffice to use.
I am not attached to LibreOffice. Any app that will convert the text file into a PDF file is fine. I have tried txt2pdf and pandoc without success.
This is what the file looks like
To be more specific about the problem, below is an example of what the above lines look like in LibreOffice using Liberation Mono font (no mono font does better):
I answered to you by mail, but here is the answer. You are using some very specific characters; the most difficult to find being in the Miscellaneous Symbols unicode block. For instance the SESQUIQUADRATE which sould is on your second line as ⚼.
A quick search lead me to the two following candidates (for monospace fonts):
Everson Mono
GNU Unifont
As you can see, the block is partially covered by PragmataPro which is a very good font; however, I tried with an old version and found all your own characters, but an issue occured because the Sun character (rendered as ☉) seems to be printed twice wider than the other characters, but my version of this font is rather old and perhaps buggy.
Once you have chosen the font suiting your needs, you may be able to render your documents as PDF with various tools. I made all my experiments with txt2pdf which I use daily for many documents.

wkhtmltopdf and chinese characters

Trying to generate a PDF with wkhtmltopdf but it gives me a lot of trouble displaying all the characters.
Some of characters work - e.g. when printing
"Invoice No (付款编号)" Chinese character no 1, 2 and 4 are correctly printed but character no 3 just displays an empty space in the PDF.
"Customer no (客户编号)" Chinese character no 1 and 4 are correctly displayed but character no 2 and 3 aren't displayed in the PDF.
"Total (总额)" none of the Chinese characters are displayed in the generated PDF.
I'm on a Ubuntu 14.04 desktop system with wkhtmltopdf version "wkhtmltopdf 0.12.1 (with patched qt)". I have installed the Chinese fonts and all the characters are correctly displayed in both gedit and Firefox on my system, but wkhtmltopdf only displayes about 75% of them.
My HTML document is made in with UTF-8 character set and is correctly displayed in Firefox and gedit. I have also tried to embed the font-face directly in the style section of the header using the src: url(data:font/ttf;base64,AAEA....) tag and wkhtmltopdf changes the font face as expected but the missing characters are still missing.
Any help is really really appreciated as I'm getting out of ideas.
Did you install the Chinese, Japanese, and Korean Fonts that are mentioned in the Ubuntu Community Help Wiki?
Looking at the PDF generated on another System in detail, you can find out which font is used by wkhtmltopdf on that system and then locate the proper substitute.
Dalibror Nasevic did the work for a large subset of asian fonts and described what he had to install on a CentOS (RedHat) based system:
Figuring out missing fonts for wkHTMLtoPDF
On a headless Debian-stretch-based system, according to Dalibror Nasevic I had to add
fonts-droid-fallback,
fonts-wqy-microhei and fonts-wqy-zenhei
In addition, following the recommendations from the Ubuntu Community Help Wiki, fonts-dejima-mincho, fonts-nanum-coding, fonts-takao, fonts-takao-gothic, fonts-takao-mincho might be worth giving a try.

Headless conver-to PDF soft-hyphen replaced with zero-width whitespace

i'm working on an webapp creating LibreOffice Documents that i want to convert to PDFs with unoconv and a headless libreoffice.
There is just one problem i can't solve: The soft-hyphens i include in the .odt are replaced with zero-width whitespaces in the resulting PDF. The Problem is not related to unoconv - i tried it directly with a headless libreoffice (same result). i tried both v 4.1.4.2 as well as 4.2.5.2.
i tried another font (Ubuntu) (i use Arial as the body font) as i expected that the missing Arial font on Linux causing the problem (i have the problem on the production server with debian 7 as well on a virtualbox with ubuntu 12.04).
i even installed the arial font in hope it caused the problem due to libreoffice inability to calculate where to set the "real" hyphens without the font file at hand.
strange thing: using LO 4.1.4.2 on my mac (headless of course) produces flawless PDFs. So the problem must be related to either linux or some missing "graphical" package in my server setup. i installed the hyphen-de package which results in hyphens based on the dictionary, but the specified soft-hyphens are still replaced with zero-width whitespaces.
the problem affects both body text as well as text boxes that are used for annotations.
i'd appreciate any hint very very much!
I had a similar problem.
I had to install the right language hyphenation package that fit with the document's language.

Prestashop 1.5.4.1 Turkish character does not show correctly

My prestashop has a problem with Turkish characters. I tried different things like changing font in classes/pdf PDFGenerato.php from helvetica to freeserif. I tried different character sets But couldn't find a right combinnation of them :(
Someone in a forum suggested that font sets should be changed so I backuped \tools\fpdf\fonts and installed that fonts.zip package but nothing changed :(
What should i do?
I was having the same issue with arabic characters. I even reported the bug, but did not get any reply from there
http://forge.prestashop.com/browse/PSCFV-6253?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
PS is using tcpdf behind the scene for generating PDF invoices. The tcpdf coming with PS has some missing fonts, which you need to place there. Download tcpdf . In the download you will see a fonts folder. Compare that folder with the PS tools/tcpdf/fonts folder and you will see the missing fonts. Copy and paste that folder to tools/tcpdf .
Next change the fonts at your classes accordingly and i hope it will work for you. For me it fixed the issue, but did the currency text ( ر يال ) was not displaying correctly.
Also checkout the example files coming with the tcpdf download.
Thank you

SimSun Regular font problems

I developed RDLC report rendered with pdf by using SimSun font. My web sever uses SimSun font 5.00. The problem is some of my clients cannot see the correct words. The report displays as garbage. But some of them can see the correct words. And I tested and found that the correct words are displayed in window where SimSum font 2.11 or 3.03 exists. And if the window installed SimSum 5.03 font, incorrect words are displayed. But I don't know exactly which SimSun font versions are compatible with version 5.00. Anyone can tell me, please?