Using moderncv
as follows;
\documentclass{moderncv}
\moderncvtheme[black]{casual}
I'd like to remove the coloured struts/rectangles/boxes, adjacent to section headings, from the output.
Can someone please tell me how to do this? I have previously used latex only for article writing.
Best Answer
Write after your given two lines to change the color of the leading box to white:
This workaround runs with the styles
casual
andclassic
but not withbanking
. I changed only the used color from\color{color1}
to\color{mycolor}
and setmycolor
towhite
. The original definition of macro section you can find in the filemoderncvstyleclassic.sty
.Have you checked the style
banking
? This style does not use colored boxes.Update to class
moderncv
, version 2.0.0 (current version):with the current class
moderncv
, version 2.0.0 the definition in stylecasual
has changed to:Therefore we need to use command
\RenewDocumentCommand
to redefine\color{color1}
to\color{white}
. Please note that a patch with command\patchcmd
is not working, commands defined with\RenewDocumentCommand
are not patchable!We need to add the following code into the preamble (
\makeatletter
and\makeatother
are needed because the code uses@
):With the complete code
you get your wished result: