> For the complete documentation index, see [llms.txt](https://overleaf-pro.ayaka.space/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://overleaf-pro.ayaka.space/latex/it/domande-su-latex/01-how-can-i-typeset-text-in-cyrillic-e.g.-in-russian.md).

# Come posso comporre testo in cirillico (ad es. in russo)?

## Introduzione

Per comporre testo in cirillico su Overleaf dovrai caricare alcuni pacchetti aggiuntivi: i pacchetti esatti dipenderanno dal compilatore che stai usando: pdfLaTeX, XeLaTeX, LuaLaTeX o LaTeX (cioè, da DVI a PDF).

## Composizione del cirillico con pdfLaTeX o LaTeX

Se usi pdfLaTeX o LaTeX come compilatore, allora funzionerebbe quanto segue:

```latex
\documentclass{article}
\usepackage[T2A,T1]{fontenc}
\usepackage[main=english,russian]{babel}
\begin{document}
Questo è inglese e questo è russo: \textcyrillic{Здравствуй, мир!}
\end{document}
```

[Apri questo `compilatore pdfLaTeX` esempio in Overleaf.](https://www.overleaf.com/docs?engine=pdflatex\&snip_name=Typesetting+Cyrillic+text\&snip=%5Cdocumentclass%7Barticle%7D%0A%5Cusepackage%5BT2A%2CT1%5D%7Bfontenc%7D%0A%5Cusepackage%5Bmain%3Denglish%2Crussian%5D%7Bbabel%7D%0A%5Cbegin%7Bdocument%7D%0AThis+is+English+and+this+is+Russian%3A+%5Ctextcyrillic%7B%D0%97%D0%B4%D1%80%D0%B0%D0%B2%D1%81%D1%82%D0%B2%D1%83%D0%B9%2C+%D0%BC%D0%B8%D1%80%21%7D%0A%5Cend%7Bdocument%7D)

Questo esempio produce il seguente output:

![Cirillico russo composto in LaTeX](/files/9092ac303955651c993a58728e7148c6278f0ed1)

## Composizione del cirillico con XeLaTeX o LuaLaTeX

I compilatori XeLaTeX e LuaLaTeX hanno il supporto integrato per il testo codificato in UTF-8, quindi non c'è bisogno di usare `\inputenc` (`\usepackage[utf8]{inputenc}`). Dal 2018 non c'è più bisogno di usare `\usepackage[utf8]{inputenc}` anche con pdfLaTeX—vedi il [numero di aprile 2018 di LaTeX News](https://www.latex-project.org/news/2018/04/10/issue28-of-latex2e-news-released/) e il post del blog di Overleaf [*Aggiornamento di TeX Live—settembre 2019*](https://www.overleaf.com/blog/tex-live-upgrade-september-2019).

Per XeLaTeX o LuaLaTeX, il [`polyglossia` che fornisce i comandi e le funzionalità necessarie per includere file grafici esterni. L'esempio sopra carica il](https://ctan.org/pkg/polyglossia?lang=en) può essere utile, soprattutto se vuoi scegliere un font personalizzato.

```latex
\documentclass{article}
\usepackage{polyglossia}
\setmainlanguage{english}
\setotherlanguage{russian}
\newfontfamily{\russianfont}[Script=Cyrillic]{CMU Serif}
\begin{document}
Questo è inglese e questo è russo: \textrussian{Здравствуй, мир!}
\end{document}
```

[Apri questo esempio LuaLaTeX su Overleaf.](https://www.overleaf.com/docs?engine=lualatex\&snip_name=Cyrillc+text+typeset+with+LuaTeX\&snip=%5Cdocumentclass%7Barticle%7D%0A%5Cusepackage%7Bpolyglossia%7D%0A%5Csetmainlanguage%7Benglish%7D%0A%5Csetotherlanguage%7Brussian%7D%0A%5Cnewfontfamily%7B%5Crussianfont%7D%5BScript%3DCyrillic%5D%7BCMU+Serif%7D%0A%5Cbegin%7Bdocument%7D%0AThis+is+English+and+this+is+Russian%3A+%5Ctextrussian%7B%D0%97%D0%B4%D1%80%D0%B0%D0%B2%D1%81%D1%82%D0%B2%D1%83%D0%B9%2C+%D0%BC%D0%B8%D1%80%21%7D%0A%5Cend%7Bdocument%7D)

Questo esempio LuaLaTeX produce il seguente output:

![Testo in cirillico composto con LuaLaTeX](/files/1626fd93d367d0a1e4061e6502c70c50d89a8da8)

## SUGGERIMENTO: come cambiare i compilatori LaTeX

Nota che puoi passare il compilatore a XeLaTeX o LuaLaTeX facendo clic sul **Menu** pulsante in alto a sinistra e cambiando l'impostazione: il seguente breve video ti mostra come farlo. **Compilatore** pulsante in alto a sinistra e cambiando l'impostazione: il seguente breve video ti mostra come farlo.

{% embed url="<https://www.filepicker.io/api/file/ikMVZIu9S6SurOfUPO34>" %}

## Alcuni articoli correlati di Overleaf

* [Russo](/latex/it/lingue/14-russian.md)
* [Supporto per le lingue internazionali](/latex/it/lingue/03-international-language-support.md)
* [Composizione multilingue su Overleaf usando polyglossia e fontspec](/latex/it/lingue/01-multilingual-typesetting-on-overleaf-using-polyglossia-and-fontspec.md)
* [Uso dei font con XeLaTeX](/latex/it/caratteri/03-xelatex.md)


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://overleaf-pro.ayaka.space/latex/it/domande-su-latex/01-how-can-i-typeset-text-in-cyrillic-e.g.-in-russian.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
