开发者

LaTeX adjusting space in toc items

I am struggling with custom toc items added via:

\addcontentsline{toc}{section}{Some text here}

Actually my problem is that I need to add some items which contain chronological date period开发者_StackOverflows like:

12/1/2005 - 3/3/2006 Some event.........................................1
10/10/2005 - 11/30/2005 Some other event................................2

This looks not so nice. What I would like to do is adjusting event description to some line position to look like:

12/1/2005 - 3/3/2006     Some event.....................................1
10/10/2005 - 11/30/2005  Some other event...............................2

I tried to use \makebox but as it seems it is not allowed to be used within \addcontentsline{toc}{section}{...} command.

Does anyone have other suggestions?


Got it...

\makebox is a fragile command, so I need to protect it :)

\addcontentsline{toc}{section}{\protect\makebox[2cm][l]{date here} Description here}

Sorry for noise!

Ovanes

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜