
Entonces descargué una plantilla para un CV. Utiliza XeLaTeX. Me gustaría cambiar la fuente, pero perdí la esperanza de saber cómo se supone que debo hacerlo. Mi sistema operativo es Windows 7. Aquí hay un código funcional que usa la fuente original Fontin. Lo descargué para que funcione y me gustaría usar algo más (¡y algo que use acentos (hablo francés)!)
\documentclass[a4paper,10pt]{article} % Default font size and paper size
\usepackage{graphicx}
\usepackage{caption}
\usepackage{subcaption}
\usepackage{textpos}
\usepackage{fontspec} % For loading fonts
\defaultfontfeatures{Mapping=tex-text}
\setmainfont[SmallCapsFont = Fontin SmallCaps]{Fontin}
\usepackage{xunicode,xltxtra,url,parskip} % Formatting packages
\usepackage[usenames,dvipsnames]{xcolor} % Required for specifying custom colors
\usepackage[big]{layaureo}
\usepackage{hyperref} % Required for adding links and customizing them
\definecolor{linkcolour}{rgb}{0,0.2,0.6} % Link color
\hypersetup{colorlinks,breaklinks,urlcolor=linkcolour,linkcolor=linkcolour} % Set link colors throughout the document
\usepackage{titlesec} % Used to customize the \section command
\titleformat{\section}{\Large\raggedright}{}{0em}{} % Text formatting of sections
\titlespacing{\section}{0pt}{2pt}{2pt} % Spacing around sections
\usepackage{vmargin}
\usepackage{fullpage}
\begin{document}
\setmarginsrb{25mm}{0mm}{30mm}{0mm}{1cm}{5mm}{1mm}{10mm}
\pagestyle{empty} % Removes page numbering
\font\fb=''[cmr10]'' % Change the font of the \LaTeX command under the skills section
\par{\Huge TacTac \textsc{TicToc} - OncheOnche \bigskip\par}
\par{\Huge \hspace{8mm} huehuehue \bigskip\par}
\section{Données personnelles}
\begin{textblock}{.9}(0,0)
\rule{97mm}{0.09mm}
\end{textblock}
\begin{tabular}{rl}
\textsc{Date de naissance:} & 01 brumeneige 3030 \\
\textsc{Adresse:} & Somewhere, sometimes \\
\textsc{Téléphone:} & +123456789\\
\textsc{Email:} & what about
\end{tabular}
\section{Objectifs}\titlerule
I met a traveler from an antic land who said : Two vast and trunkless legs of stone stand in the desert... \\
%----------------------------------------------------------------------------------------
% EDUCATION
%------------------------------------------------------------------------------- ---------
\end{document}
Creo que el problema viene de las líneas.
\defaultfontfeatures{Mapping=tex-text}
\setmainfont[SmallCapsFont = Fontin SmallCaps]{Fontin}
Pero no sé qué debo cambiar, dónde busca el compilador las fuentes... Vi otras preguntas que se parecen a las mías, pero todas usaban Linux. También vi que podría haber algunos problemas con las fuentes que usan espacios en su nombre (¿en serio...?)... De todos modos. ¿Alguien tiene una idea?
Respuesta1
Reducir su documento al mínimo requerido para esta pregunta (consulteejemplo de trabajo mínimo (MWE)para más detalles), a continuación se muestra cómo cambiar la fuente principal de su documento con \setmainfont
:
\documentclass{article}
\usepackage{lipsum} % add nonsense text
\usepackage{fontspec}
\setmainfont{Arial}
\begin{document}
\lipsum[1]
\end{document}
Respuesta2
Esto funciona para mí:
\documentclass[a4paper,10pt]{article} % Default font size and paper size
\usepackage{fontspec} % For loading fonts
\setmainfont[SmallCapsFont=Fontin SmallCaps]{Fontin-Regular}
\usepackage{url,parskip} % Formatting packages
\usepackage{graphicx}
\usepackage{caption}
\usepackage{subcaption}
\usepackage{textpos}
\usepackage[usenames,dvipsnames]{xcolor} % Required for specifying custom colors
\usepackage[big]{layaureo}
\usepackage{titlesec} % Used to customize the \section command
\titleformat{\section}{\Large\raggedright}{}{0em}{} % Text formatting of sections
\titlespacing{\section}{0pt}{2pt}{2pt} % Spacing around sections
\usepackage{hyperref} % Required for adding links and customizing them
\hypersetup{colorlinks,breaklinks,urlcolor=linkcolour,linkcolor=linkcolour} % Set link colors throughout the document
\definecolor{linkcolour}{rgb}{0,0.2,0.6} % Link color
\usepackage{vmargin}
\usepackage{fullpage}
\begin{document}
\setmarginsrb{25mm}{0mm}{30mm}{0mm}{1cm}{5mm}{1mm}{10mm}
\pagestyle{empty} % Removes page numbering
\par{\Huge TacTac \textsc{TicToc} - OncheOnche \bigskip\par}
\par{\Huge \hspace{8mm} huehuehue \bigskip\par}
\section{Données personnelles}
\begin{textblock}{.9}(0,0)
\rule{97mm}{0.09mm}
\end{textblock}
\begin{tabular}{rl}
\textsc{Date de naissance:} & 01 brumeneige 3030 \\
\textsc{Adresse:} & Somewhere, sometimes \\
\textsc{Téléphone:} & +123456789\\
\textsc{Email:} & what about
\end{tabular}
\section{Objectifs}\titlerule
I met a traveler from an antic land who said : Two vast and trunkless legs of stone stand in the desert... \\
%----------------------------------------------------------------------------------------
% EDUCATION
%------------------------------------------------------------------------------- ---------
\end{document}