CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 6 of 6

Threaded View

  1. #1
    Join Date
    Feb 2001
    Posts
    2,455

    Label postions on item.

    I am designing a mile stone task scheduler class. For each item (See Attached Bitmap), you have a start point and end point which is represented by a symbol (triangle, square, circle) and between a rectangle representing the connector line.

    Now, each item has 5 possible labels, one displaying the start date (drawn around the start point symbol), one displaying the end date (drawn around the end point symbol), and 3 description labels drawn anywhere around the item. My problem is that I need to come up with a solution to determine where to draw each label so that no label conflicts with another. Each label can have a vertical and horizontal justification which is based on the symbol or connector line. TOP | MIDDLE| BOTTOM and LEFT|CENTER|MIDDLE.

    E.G. Of problem: If the start date and end date are the same, then the right symbol and connector line are not drawn, but all five labels are drawn around the left symbol. If all the items are to be drawn with the justification TOP | CENTER, then they would be drawn over each other at the top of the left symbol.

    Any hints on how I can solve this problem?

    Note: The order of drawing the labels is from 0-4 top to bottom.

    Mike B
    Attached Images Attached Images

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured