I'm dealing with memoir
class trying to create an own fancy chapter style for a project. I'm currently using TikZ and got some good advance. The issue, however, is a black box/line which does not vanish at all.
Here's the MWE:
\documentclass[a4paper,12pt,extrafontsizes,twoside,onecolumn,openany,draft]{memoir}
\setlrmarginsandblock{2.5cm}{2.5cm}{*}
\setulmarginsandblock{2.5cm}{2.5cm}{*}
\checkandfixthelayout
\usepackage{tikz}
\usepackage{color,calc}
\usepackage{lipsum}
\makeatletter
\renewcommand{\@chapapp}{Lição}
\newcommand*\BuildChpNumb[1]{%
\begin{tikzpicture}
\draw [-, rounded corners, thick, purple] (0,2) -- (0,0) -- (\textwidth,0) -- (\textwidth,2);
\node at (\textwidth - 200,1) {\chaptitlefont #1};
\end{tikzpicture}
}
\makechapterstyle{Filipe}{%
\renewcommand{\chapnamefont}{\large\scshape}
\renewcommand{\chapnumfont}{\Huge\bfseries}
\renewcommand{\chaptitlefont}{\Huge\bfseries}
\setlength{\beforechapskip}{0pt}
\setlength{\midchapskip}{0pt}
\setlength{\afterchapskip}{0pt}
\renewcommand{\printchaptername}{}
\renewcommand{\chapternamenum}{}
\renewcommand{\printchapternum}{}
\renewcommand{\afterchapternum}{}
\renewcommand{\afterchaptertitle}{}
\renewcommand{\printchaptertitle}[1]{%
\BuildChpNumb{##1}\par
}%
}
\chapterstyle{Filipe}
\makeatother
\begin{document}
\chapter{A MWE}
\section{Introduction}
\lipsum[1-5]
\section{History of the MWE}
\lipsum[6-10]
\end{document}
And the result comes out with this damn line just in the rightside of the header box.
How to get rid of it?