I'm trying to make something similar to http://ww1.microchip.com/downloads/en/appnotes/00734b.pdf I'm using the twocolumn option, and have defined my own \showtitle command:
\newcommand{\showtitle}{
\parbox[t]{\textwidth}{
\flushright\textbf{\fontsize{50}{1}\selectfont\gettitle{}}
\vbox {\vskip3mm\hrule width \hsize height 1.5pt\vskip1mm\hrule width \hsize height 4pt\vskip1mm}
\flushleft\textbf{\Huge{\getsubtitle}}
\vbox {\vskip2mm\hrule width \hsize height 4pt\vskip1mm\hrule width \hsize height 1.5pt\vskip1mm}
\normalsize\normalfont}
}
The formatting is OK, however, the second column starts at the top of the column, behind the title... I tried it with minipage as well, not working.
Full code:
\documentclass[a4paper,twocolumn]{scrartcl}
\usepackage{lipsum}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% General information
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\newcommand{\gettitle}{CBus}
\newcommand{\getsubtitle}{Protocol Specification}
\newcommand{\getauthor}{Keelan}
\newcommand{\getdate}{\today}
\title{\gettitle}
\subtitle{\getsubtitle}
\author{\getauthor}
\date{\getdate}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% General layout
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\setlength{\columnsep}{6mm}
\setlength{\parindent}{0mm}
\renewcommand{\familydefault}{\sfdefault}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% Special functions
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\newcommand{\showtitle}{
\parbox[t]{\textwidth}{
\flushright\textbf{\fontsize{50}{1}\selectfont\gettitle{}}
\vbox {\vskip3mm\hrule width \hsize height 1.5pt\vskip1mm\hrule width \hsize height 4pt\vskip1mm}
\flushleft\textbf{\Huge{\getsubtitle}}
\vbox {\vskip2mm\hrule width \hsize height 4pt\vskip1mm\hrule width \hsize height 1.5pt\vskip1mm}
\normalsize\normalfont}
}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% The document
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\begin{document}
\showtitle{}
\section{Lipsum}
\lipsum[1-5]
\end{document}
How can I solve this?
%after every{which ends a line to avoid a spurious space there. See What is the use of percent signs (%) at the end of lines? for the details. – Martin Scharrer Jan 05 '13 at 10:47\flushright\textbf{\fontsize{50}{1}\selectfont\gettitle{}}. Now using\flushright\textbf{\fontsize{50}{1}\selectfont\gettitle{}} %. – Keelan Jan 05 '13 at 10:52