Playing with my TGraphicPanel (a parented TGraphicControl) I've think about a feature that could be nice to have, an AlignWeight property to priorise controls alignments.


Playing with my TGraphicPanel (a parented TGraphicControl) I've think about a feature that could be nice to have, an AlignWeight property to priorise controls alignments.

The concept is simple, by default, a value of 0 do not change the behavior.

If the AligWeigth of a component is higher, then it is aligned first.

It can also define the align order of a set of "alLeft" components regardless of it's actual position.

Comments

  1. Paul TOTH I have downloaded your software quit a wile ago but never thought there is a component inside it.
    Will you please put any components in a directory named "components"
    so we will know.
    Great job.

    ReplyDelete
  2. Paul TOTH Is it possible to use TextPath in Android ?
    since DesignIDE is not applicable

    ReplyDelete
  3. shlomo abuisak it's the goal ! TextPath compute TPath.Data at design time under Windows, then it's just a TPath like any other.

    ReplyDelete
  4. Paul TOTH Strange. Using Delphi 10.2.1
    No Align and No align weight .
    Using Demo1.
    Mite be i am using an older version ?

    https://plus.google.com/photos/...

    ReplyDelete
  5. shlomo abuisak it's a work in progress

    it should be included in the VCL ;)
    https://quality.embarcadero.com/browse/RSP-16543

    ReplyDelete
  6. shlomo abuisak the biggest problem with TGraphicPanel is that only GraphicPanel can be put inside until the concept is included at TControl level...or you have to derive a new set of TGraphicPanel descendants for everything. So this component is more a proof of concept then an usable component.

    ReplyDelete
  7. Not a bad idea. Thoughts go to the DOM FlexBox.

    ReplyDelete
  8. Paul TOTH I saw the AlignWeight item is a comment in RSP-16543: can you enter its own QP please?

    Re naming, as I understand AlignIndex might be better (like TabIndex) because it's sorting the order of items with the same alignment.

    Align weight to me implies something variable, a weighting among multiple influencing values - say, something anchored but with elastic so it moves as the window size is changed ("25% tied to left, 75% tied to right"). (Which would give a mobile-like UI, but be rather complicated to implement in the VCL. But don't let that stop you entering a QP for it too ;))

    ReplyDelete
  9. Scratch that - I should have watched your full video, it's not weighting among items with the same alignment but different alignment. Looks really useful. I am not sure what to call it :)

    ReplyDelete
  10. David Millington yes and Index should not have gap between components, while Weight is not related to other items. two items can have the same weight for instance.

    ReplyDelete

Post a Comment