TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

In the following code, the use of the package titlesec modifies dramatically the formatting based on the package marginnote. The package titlesec is needed so as to use this.

Is there one possibility to repair that ?

    %\usepackage{titlesec} % << Uncomment to see the changes... >>

    \reversemarginpar % To put the margin pars on the left



            show background rectangle,
            inner frame sep=0pt,
            text width=1cm,
            \node [fill=colorDateGene]  at (0,0)                                (dayofweek)  {\footnotesize{#1}};
            \node [fill=colorDateToday] at ($(dayofweek)  +(0,-\baselineskip)$) (dayofmonth) {#2};
            \node [fill=colorDateToday] at ($(dayofmonth) +(0,-\baselineskip)$) (month)      {#3};
            \node [fill=colorDateGene]  at ($(month)      +(0,-\baselineskip)$) (dayofmonth) {\footnotesize{#4}};



\addcontentsline{toc}{section}{Mon. 28 Nov.}
\section*{One day \marginnote{\Date{Mon}{28}{NOV}{2011}}}


\addcontentsline{toc}{section}{Wed. 30 Nov.}
\section*{One day \marginnote{\Date{Wed}{30}{NOV}{2011}}}


\addcontentsline{toc}{section}{Fri. 2nd Dec.}
\section*{One day \marginnote{\Date{Fri}{2nd}{DEC}{2011}}}


\addcontentsline{toc}{section}{Mon. 5 Dec.}
\section*{One day \marginnote{\Date{Fri}{5}{DEC}{2011}}}


share|improve this question
up vote 2 down vote accepted

As I said in my revised answer to your former question: Instead of putting \marginnote inside \section*, change the vertical positioning of the \marginnote using its second optimal argument.

\section*{One day} \marginnote{\Date{Mon}{28}{NOV}{2011}}[-32pt]
share|improve this answer
To obtain the same formatting as the \section header, use \marginnote{\bfseries...}. Why 32pt? – Werner Dec 1 '11 at 0:22
@Werner: The OP seems to want a marginnote in \normalfont that is nevertheless vertically aligned witth the sectioning title -- 32pt is a crude aligning attempt, considering the marginnote's box. – lockstep Dec 1 '11 at 0:26
Okay - \normalfont in the text has a \baselineskip of 14.5pt, while that of the section heading is 22pt, so I had thought 36.5pt. But your visual attempt is definitely sufficient. – Werner Dec 1 '11 at 0:33

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.