square/Paralayout

Improve support for handling layout directions

NickEntin opened this issue · 0 comments

Currently most of the layout utilities assume an LTR layout direction. We should extend the APIs to better handle RTL layout. Specifically, I think we need the following changes:

  • Add cases to the Position enum with leading/trailing variants for each left/right case
  • Support these new positions in the alignment methods
  • Support these new positions in AspectRatio utilities for finding a rect to fit/fill
  • Change the distribution options for orthogonal alignment to actually select the leading/trailing edge rather than always using left/right (and potentially add options for explicitly specifying left/right alignment)