On 02/01/2013 12:14 PM, John Cummings wrote:
> On 01/31/2013 01:48 AM, Uwe Rathmann wrote:
>> Well, for labels aligned to the corners it is only about having
>> vertical/horizontal offsets. As the direction of the offset is always to
>> the center of the canvas 2 values >= 0 are all what is necessary.
>> When aligning a label to the other 5 anchor points I'm not sure what
>> special other offsets you have in mind. I can imagine to simply ignore
>> the margins for centered alignments. So f.e. for AlignTop | AlignHCenter
>> the vertical offset would have an effect, while the horizontal offset is
> Good points. Yes, the four corners are the simpler case and my primary use case.
> As for the other 5 anchor points, I see some options:
> 1. The option you proposed, which is to use the corresponding margin unless the
> item is centered in that direction. That is, when using AlignHCenter, the
> horizontal offset is ignored. Likewise, when AlignVCenter is used, the vertical
> offset is ignored. When AlignCenter is used, the offset is ignored altogether.
> This limits the functionality to some degree since I can see value in placing an
> item 10 pixels to the right of the center of the canvas (or say to the right of
> another item, which happens to be at the center too- but that is a more involved
> example). However, it is a clean interface.
> 2. Using positive and negative values for margin. For the four corners, I think
> it would be better for positive and negative to mean the same thing. That is, we
> just use the absolute value and the offset is always toward the center of the
> canvas. For the other 5 anchor points, I would use a positive horizontal offset
> to mean move to the right and a negative value to mean left, which is like an X
> axis that is not inverted. In the vertical direction, there are two classical
> views of direction. The first approach is positive being up and negative being
> down, which is like a Y axis that is not inverted. The second is the GUI
> approach of treating the top left corner of the window as the origin and
> positive values indicated moving down the screen. I tend to prefer the first
> approach of up being positive. Overall, this approach of using positive and
> negative values for margin could be slightly confusing with different treatment
> of positive/negative values depending on the anchor point but it does provide
> more precise control over position.
> 3. Make use of the 4 margins as mentioned earlier. Again, this option just seems
> a little confusing.
> I lean toward the second option with the only point of contention being the
> meaning of positive and negative vertical values.
> What do you think?
Uwe et al,
Have you had a chance to consider the options presented above? Specifically, the
second one, which is the only new proposal.