From e55f2671c62dfac414b477aa96010558240e4203 Mon Sep 17 00:00:00 2001 From: Eugeniy Mikhailov Date: Mon, 29 Dec 2014 15:54:39 -0500 Subject: properly implemented nologo option --- wmletterhead.cls | 25 +++++++++++++++++++------ 1 file changed, 19 insertions(+), 6 deletions(-) (limited to 'wmletterhead.cls') diff --git a/wmletterhead.cls b/wmletterhead.cls index 0323dc4..d15c47b 100644 --- a/wmletterhead.cls +++ b/wmletterhead.cls @@ -7,10 +7,11 @@ % 'wmletterhead' class accepts all options of the 'letter' class and the following % additional options which specify the header logo % prior2014dec - old logo prior 2014 -% fullcolor - full color logo with yellowish WM cypher -% black - all black logo -% green - all green logo -% white - all white logo (quite use less on white background) +% fullcolor - (default) full color logo with yellowish WM cypher +% black - all black logo +% green - all green logo +% white - all white logo (quite use less on white background) +% nologo - do not show logo image % DEFAULT options: [fullcolor] % Recomended use: % \documentclass[12pt,fullcolor]{wmletterhead} @@ -18,6 +19,13 @@ \RequirePackage{xcolor} \RequirePackage{ifthen} +% -------------------------------------------------- +% Global flag +\newif\iflogo + +% by default we want logo +\logotrue + % -------------------------------------------------- % Tagline color since December 2014 \definecolor{WMgold}{rgb}{0.73,0.59,0.36} @@ -93,11 +101,12 @@ \setonelinelayout{default} % set page layout defaults %-------------- define WM header logo file --------------------------------- -\providecommand{\wmheaderlogo}{}% nologo +\providecommand{\wmheaderlogo}{}% no logo % this is prior December 2014 logo with Wren building \DeclareOption{nologo}{% - \renewcommand{\wmheaderlogo}{}% nologo + \renewcommand{\wmheaderlogo}{}% no logo + \logofalse \setonelinelayout{default}% } @@ -191,10 +200,14 @@ \newcommand{\wmfromwithlogo}{ \setwmaddresssizes + \iflogo \raisebox{\wmaddressheight-\wmlogoheight+\wmlogoWvpos}[\wmaddressheight]{ \hskip -\wmlogoWhpos% \includegraphics[height=\wmlogoheight{},keepaspectratio=true]{\wmheaderlogo}% } + \else% + % do nothing + \fi% \hfill\wmaddress{}% } -- cgit v1.2.3