3

I am using Texmaker with PDFLaTeX build option in both Windows 7 and Ubuntu 14.04. The .tex uses my institute's template which is said "using scrreprt class of KOMA-Script".

The problem is: I can copy and paste the content of the PDF file which is created in Windows normally, while the copied content of the PDF file which is created in Ubuntu is just a combination of special characters, for example ❲✐♥❞♦✇s P❧❛tt❢♦r♠ instead of Windows Plattform

\documentclass{scrreprt}
\usepackage{t1enc}
\usepackage[T1]{fontenc}    
\usepackage[utf8]{inputenc}
\usepackage[english,ngerman]{babel}

\begin{document}

Windows Plattform

\end{document}

UPDATE:

pdffonts test.pdf results:

name                                 type              encoding         emb sub uni object ID
------------------------------------ ----------------- ---------------- --- --- --- ---------
[none]                               Type 3            Custom           yes no  no       4  0

About \usepackage{t1enc}: I don't know, since it comes from my institute's template and my supervisor just told me to modify the template as less as possible. There is just a comment % dc-Fonts following that package.

scmg
  • 246
  • 2
    On Ubuntu, what do you get when you use the command (in a terminal) pdffonts myfile.pdf (where 'myfile' is the name of the PDF where you see this problem)? Also please remove \usepackage{t1enc} before compiling. Why do you have that there? – jon Feb 20 '16 at 03:40
  • 2
    Ah, Type 3. Avoid 'em! Either install cm-super or use a different font. \usepackage{lmodern} is a 'modern' but nearly identical font to the default you are using. Also skip the \usepackage{t1enc}: you are doing enough with \usepackage[T1]{fontenc}. – jon Feb 20 '16 at 03:51
  • On Ubuntu, you should be able to do sudo apt-get install cm-super if you installed your 'TeX system' from the Debian repositories on which Ubuntu depends. – jon Feb 20 '16 at 03:53
  • I am working on the .tex file parallel between Ubuntu and Windows (on lab and at home, commit changes via SVN). Does using cm-super on Ubuntu (or \usepackage{lmodern} as you said) make any difference between the PDFs exported by each machine? – scmg Feb 20 '16 at 03:57
  • 2
    You'd have to investigate the PDF produced on the Windows machine. I don't have Windows, so I can't check what is happening. The problem on the Ubuntu side looks like it is that you are using Type 3 fonts (by accident). If so, the solution is to stop using Type 3 fonts. However, if both files use the same font package and are produced with the same way (say, by using pdflatex), then there shouldn't be a problem. Anyway, regardless of the Windows world, on Ubuntu, you should install cm-super (and I doubt the PDFs b/w the two computers will be appreciably different afterwards). – jon Feb 20 '16 at 04:00
  • seems \usepackage{lmodern} has solved my problem ... I will try with cm-super later, thank you – scmg Feb 20 '16 at 04:03
  • OK, seems like this may be a duplicate, then: http://tex.stackexchange.com/q/72900/8528 – jon Feb 20 '16 at 04:04
  • It's quite strange since I tried with Macbook today, Macbook can copy and paste the content of PDF created in Ubuntu totally normal (haven't used lmodern or cm-super in Ubuntu yet). – scmg Feb 20 '16 at 13:17
  • 1
    Apparently, your supervisor doesn't have a good LaTeX knowledge. Please make him aware that the template needs some updates. This kind of thing (outdated templates) happens often and is the cause of about 10 percent of the questions here. – Johannes_B Feb 22 '16 at 10:21
  • Feel free to lok at golatex.de or texwelt.de if you want. – Johannes_B Feb 22 '16 at 10:22
  • 1
    I would suggest that you install cm-super regardless of whether it does or seems to help with this problem (it will then be used whenever you use \usepackage[T1]{fontenc} but don't also load a specific font package). As to whether you should use cm-super or lmodern, the answers here are worth reading. – jon Feb 22 '16 at 14:35
  • 1
    Is there any news here? – Johannes_B May 13 '16 at 08:08

0 Answers0