diff options
author | Karl Berry <karl@freefriends.org> | 2015-03-06 22:27:41 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2015-03-06 22:27:41 +0000 |
commit | 3d79f409be380b65bef407bae10629114ea5755a (patch) | |
tree | 6d1494490e7ee59aaeaf2b2bd8c5644d557c0342 /Master/texmf-dist/tex | |
parent | 59459b17c1b5c64a74bb926836393d379e64493e (diff) |
moderntimeline (6mar15)
git-svn-id: svn://tug.org/texlive/trunk@36450 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex')
-rw-r--r-- | Master/texmf-dist/tex/latex/moderntimeline/moderntimeline.sty | 27 |
1 files changed, 21 insertions, 6 deletions
diff --git a/Master/texmf-dist/tex/latex/moderntimeline/moderntimeline.sty b/Master/texmf-dist/tex/latex/moderntimeline/moderntimeline.sty index 5a80f34bcc1..f4fe260d0fc 100644 --- a/Master/texmf-dist/tex/latex/moderntimeline/moderntimeline.sty +++ b/Master/texmf-dist/tex/latex/moderntimeline/moderntimeline.sty @@ -8,7 +8,7 @@ %% %% This is a generated file. %% -%% Copyright (C) 2011 by Raphaël Pinson <raphink@gmail.com> +%% Copyright (C) 2011-2012 by Raphaël Pinson <raphink@gmail.com> %% -------------------------------------------------------------------------- %% This work may be distributed and/or modified under the %% conditions of the LaTeX Project Public License, either version 1.3 @@ -20,7 +20,7 @@ %% \NeedsTeXFormat{LaTeX2e}[1999/12/01] \ProvidesPackage{moderntimeline} - [2012/04/27 0.7 Add timelines to moderncv entries] + [2015/02/25 0.8 Add timelines to moderncv entries] \ProvidesPackage{moderntimeline} \RequirePackage{tikz} \RequirePackage{kvoptions} @@ -44,6 +44,10 @@ \newcommand{\tlsince}[1]{% \def\tl@since{#1} } +\newcommand{\tlsetnotshadedfraction}[1]{% + \def\tl@nsfrac{#1} +} +\tlsetnotshadedfraction{0} \newcommand{\tltextstart}[2][base west]{% \tikzset{ tl@startyear/.style={ @@ -126,7 +130,8 @@ \pgfmathsetmacro\tl@endyear{ifthenelse(#3==0,\tl@lastyear,#3)}% \pgfmathsetmacro\tl@startfraction{(#2-\tl@firstyear)/(\tl@lastyear-\tl@firstyear)}% \pgfmathsetmacro\tl@endfraction{(\tl@endyear-\tl@firstyear)/(\tl@lastyear-\tl@firstyear)}% -\pgfmathsetlength{\pgf@xa}{#3} \ifdim\pgf@xa=0pt \def\tl@startlabel{\tl@since #2} \else \def\tl@startlabel{#2} \fi +\pgfmathsetlength{\pgf@xa}{#3} \ifdim\pgf@xa=0pt +\def\tl@startlabel{\tl@since #2} \else \def\tl@startlabel{#2} \fi \cventry{\tikz[baseline=0pt]{ \useasboundingbox (0,-1.5ex) rectangle (\hintscolumnwidth,1ex); \fill [\tl@runningcolor] (0,0) @@ -138,7 +143,12 @@ node [tl@endyear] {\pgfmathparse{ifthenelse(#3==0,,#3)}\pgfmathresult} (\hintscolumnwidth,0pt) ; \pgfmathsetlength{\pgf@xa}{#3} \ifdim\pgf@xa=0pt - \shade [left color=#1] (\tl@startfraction*\hintscolumnwidth,0) + \newdimen\fullcolorwidth + \pgfmathsetlength\fullcolorwidth{\tl@startfraction*(1+(1-\tl@startfraction)*\tl@nsfrac)*\hintscolumnwidth} + \shade [left color=#1,right color=#1] +(\tl@startfraction*\hintscolumnwidth,0) + rectangle (\fullcolorwidth,\tl@width); + \shade [left color=#1] (\fullcolorwidth,0) rectangle (\tl@endfraction*\hintscolumnwidth,\tl@width); \else \fill [#1] (\tl@startfraction*\hintscolumnwidth,0) @@ -162,8 +172,13 @@ node [tl@startyear] {#4} rectangle (\tl@endfraction*\hintscolumnwidth,\tl@width-1pt); \pgfmathsetlength{\pgf@xa}{#3} \ifdim\pgf@xa=0pt - \shade [left color=#1] (\tl@startfraction*\hintscolumnwidth,0) - rectangle (\tl@endfraction*\hintscolumnwidth,\tl@width); + \newdimen\fullcolorwidth + \pgfmathsetlength\fullcolorwidth{\tl@startfraction*(1+(1-\tl@startfraction)*\tl@nsfrac)*\hintscolumnwidth} + \shade [left color=#1,right color=#1] +(\tl@startfraction*\hintscolumnwidth,0) + rectangle (\fullcolorwidth,\tl@width); + \shade [left color=#1] (\fullcolorwidth,0) + rectangle (\tl@endfraction*\hintscolumnwidth,\tl@width); \else \fill [#1] (\tl@startfraction*\hintscolumnwidth,0) rectangle (\tl@endfraction*\hintscolumnwidth,\tl@width); |