LaTeX forum ⇒ Fonts & Character SetsAccented letters such as 'ą' and 'ę' are converted

Information and discussion about fonts and character sets (e.g. how to use language specific characters)
Vedyimyn
Posts: 4
Joined: Thu May 15, 2014 9:18 pm

Accented letters such as 'ą' and 'ę' are converted

Postby Vedyimyn » Mon Oct 17, 2016 10:59 pm

Hello!

I have a problem with 'ą' and 'ę' letters. I have to write a document that can be easily copied to Notepad without losing any character. Unfortunately, 'ą' and 'ę' are converted to something like 'a˛' and '˛e'.

MWE:
  1. \documentclass[12pt,a4paper]{article}
  2. \usepackage[T1]{fontenc}
  3. \usepackage[utf8x]{inputenc}
  4. \usepackage{polski}
  5. \usepackage{mathptmx}
  6.  
  7. \begin{document}
  8. Zażółć gęślą jaźń.
  9. \end{document}


As you can see I use mathptmx package. I do so since I have to use a Times-like font.

Is there any way to include the proper 'ą' and 'ę' characters here (not the ones combined of two characters, ogonek+letter)? Or maybe there is a Times-like font that contains them?

I use Tex Live on Linux. I prefer not to use XeTex, because I'm unfamiliar with it (and I use a lot of mathematical symbols - I'm unsure if XeTex copes with them sufficiently well).

I'll appreciate any help.

kaiserkarl13
Posts: 582
Joined: Tue Mar 25, 2008 5:02 pm
Location: Columbia, Missouri, USA

Postby kaiserkarl13 » Tue Oct 18, 2016 7:37 am

Is there any reason you don't want to use the standard commands that produce accents? For example,

  1. \documentclass[12pt,a4paper]{article}
  2. \usepackage{txfonts} % or any font you wish
  3. \begin{document}
  4. Za\.z\'o\l \'c g\c e\'sl\c a ja\'z\'n.
  5. \end{document}

Those use 100% ASCII text, pretty much guaranteed to be compatible with even the meekest text editor.

Vedyimyn
Posts: 4
Joined: Thu May 15, 2014 9:18 pm

Postby Vedyimyn » Tue Oct 18, 2016 4:03 pm

I think that the source would be a bit cluttered if I included commands in place of some letters (a lot of letters in fact), so I'll do it only if nothing else works. At least I would if it actually worked. Unfortunately your MWE doesn't produce the correct output. Cedille differs from Polish ogonek. Just compare: ą - a̧, ę - ȩ.

kaiserkarl13
Posts: 582
Joined: Tue Mar 25, 2008 5:02 pm
Location: Columbia, Missouri, USA

Postby kaiserkarl13 » Tue Jan 24, 2017 7:13 am

Sorry to reply to a very old post, but I failed to catch this post when it was new, and if someone else finds it....

The command for the diacritical mark you wanted above is \k{e} and similar; you'll need T1 encoding using the fontenc package.


Return to “Fonts & Character Sets”

Who is online

Users browsing this forum: No registered users and 4 guests