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

I think the title is obvious but I will explain my idea with the following picture:
(I am using moderncv classic style toghether with moderntimeline)


The first panel on the left shows the current output. The one in the center is something that I put together in photoshop to explain my objective (see below). The right panel is what I expect to obtain.

This is not a new problem and other have given good solutions to the problem (moderntimeline: alignment of text on start and end of bars or Moderncv with moderntimeline - how do I center the label above the timeline?).

However, none of them fulfill all my requirements and most of all they are not completely automatic, i.e. if the time scale changes I will have to change some code by hand).

We know the length of hintscolumnwidth because we have to set it and here in my example is represented by green lines. All I want is the labels of\tllabelcventry and \tldatelabelcventry to stay inside that space. However, if the label using the default settings does not cross the green lines (orange box) than it should be left as is.

Now let's consider that the label is inside a box (here represented by blue and orange). If that box cross the green lines (blue box) than it should be moved either left or right. But how much? well it should be the minimum value so its border align with the green line it has crossed.
This way, the label keeps some "information" to its mark but is also aligned within hintscolumn.

I think if one could work with label boxes and hintscolumnwidth than the process should be automatic and whenever the timeline increases the label box that was once blue could become orange and would not require the hack.

share|improve this question

closed as unclear what you're asking by Keks Dose, Svend Tveskæg, Christian Hupfer, Mico, Johannes_B Jul 25 '15 at 14:47

Please clarify your specific problem or add additional details to highlight exactly what you need. As it's currently written, it’s hard to tell exactly what you're asking. See the How to Ask page for help clarifying this question.If this question can be reworded to fit the rules in the help center, please edit the question.

Could you provide an MWE to start working with/for testing purposes? – Paul Gessler Feb 8 '15 at 21:57