aboutsummaryrefslogtreecommitdiffstats
path: root/resume.cls
diff options
context:
space:
mode:
authorAaron LI <aly@aaronly.me>2024-12-06 09:31:06 +0800
committerAaron LI <aly@aaronly.me>2024-12-06 09:34:43 +0800
commit664ed4b92c5e792dcf275ba062a00d6c2e699c3b (patch)
tree21089596bd36b8b1198c01f79bcd5396c6c490a5 /resume.cls
parent4c316f5e66dc380bf194a150e43d34395dd1aecb (diff)
downloadresume-664ed4b92c5e792dcf275ba062a00d6c2e699c3b.tar.bz2
class: Fix the case of no photo
Diffstat (limited to 'resume.cls')
-rw-r--r--resume.cls18
1 files changed, 10 insertions, 8 deletions
diff --git a/resume.cls b/resume.cls
index 2d08b2c..1bea11d 100644
--- a/resume.cls
+++ b/resume.cls
@@ -324,14 +324,14 @@
% Render resume header
\newcommand*{\makeheader}{
- \ifdef{\@photo@width}{
- \def\@profile@width{\dimexpr \linewidth - \@photo@width - 1em}%
- }{
+ \ifdef{\@photo}{%
+ \def\@profile@width{\dimexpr \linewidth - \@photo@width - 1em}
+ \ifdefstring{\@photo@position}{left}{%
+ \@photo\hspace{1em}%
+ }{}%
+ }{%
\def\@profile@width{\linewidth}
}%
- \ifdefstring{\@photo@position}{left}{%
- \@photo\hspace{1em}%
- }{}%
\begin{minipage}{\@profile@width}
{\LARGE\bfseries\color{accentcolor} \@name}
\ifdef{\@tagline}{%
@@ -341,8 +341,10 @@
\medskip \\
\@profile
\end{minipage}
- % photo on the right side
- \ifdefstring{\@photo@position}{left}{}{\hfill\@photo}
+ \ifdef{\@photo}{%
+ % photo on the right side
+ \ifdefstring{\@photo@position}{left}{}{\hfill\@photo}
+ }{}
}
%%