Question marks instead of text when writing Persian with XePersian

I am trying to write in Persian in TexShop(Mac) and keep getting question marks instead of my text. Here is my code:

\documentclass{article}
\usepackage{xepersian}
\usepackage{bidi}
\settextfont{HM_XBNiloofar}
\title{چکیده}
\begin{document}
\maketitle
ساقیا
\end{document}


I am compiling it using XeLaTeX btw.

I remember being able to write in persian with my TexShop but now I cannot and I cannot find my old document to check it up.

• Is it really this hard?? – Naji Sep 28 '13 at 18:00

I found the problem. The encoding option should be set to UTF-8.

• where did you set the encoding? – Reza Saberi Jun 28 '17 at 11:21