AlohaKit.UI icon indicating copy to clipboard operation
AlohaKit.UI copied to clipboard

Layout system

Open KSemenenko opened this issue 2 years ago • 10 comments

Let's add drawable Layouts like Grid, or Stack or so. And then we can do like this:

<alohakit:CanvasView> 
   <alohakit:StackLayout>
      <alohakit:RoundRectangle
          WidthRequest="50" HeightRequest="50" 
          CornerRadius="12, 0, 0, 24"
          Fill="Orange" />
          <alohakit:Grid>
            <alohakit:RoundRectangle
                WidthRequest="50" HeightRequest="50" 
                CornerRadius="12, 0, 0, 24"
                Fill="Orange" />
          </alohakit:Grid>
   </alohakit:StackLayout> 
</alohakit:CanvasView>

Of course naming is random, but the idea is - to have one canvas with a lot if graphic introls inside.

KSemenenko avatar Oct 30 '22 14:10 KSemenenko

so we no need X and Y now, also we can create complicated laytous. @jsuarezruiz can you guid me plese do you have some like SizeRequest OnMeasure(double widthConstraint, double heightConstraint) functions?

KSemenenko avatar Oct 30 '22 14:10 KSemenenko

We definitely need this, according to me ScrollView is also a layout we must have (besides Stack and Grid).

Martinn2 avatar Oct 30 '22 20:10 Martinn2

I have code for it, it was implemented some times ago with skiasharp. But I need some guidance how we can integrate it in better way

KSemenenko avatar Oct 30 '22 20:10 KSemenenko

so we no need X and Y now, also we can create complicated laytous. @jsuarezruiz can you guid me plese do you have some like SizeRequest OnMeasure(double widthConstraint, double heightConstraint) functions?

Definitely, after having gestures and other important Core APIs, Layouts is the next big step forward. I am going to prepare a PR with a basic prototype and we can iterate continue from it. Sounds good?

jsuarezruiz avatar Nov 03 '22 18:11 jsuarezruiz

so we no need X and Y now, also we can create complicated laytous. @jsuarezruiz can you guid me plese do you have some like SizeRequest OnMeasure(double widthConstraint, double heightConstraint) functions?

Definitely, after having gestures and other important Core APIs, Layouts is the next big step forward. I am going to prepare a PR with a basic prototype and we can iterate continue from it. Sounds good?

Sound good! Waiting for it

KSemenenko avatar Nov 03 '22 21:11 KSemenenko

Maybe Im waiting to have Parent layout like scrollview.. stack,,, gridview, listview... from drawings... I am tired and thinking go to flutter because of lag in .net maui xaml that undergo 50 compilation before it landed on native UI.

nextcodelab avatar Nov 15 '22 12:11 nextcodelab

Any update?

roughiain avatar Jan 19 '23 18:01 roughiain

Very soon. alohakit-layout-grid

jsuarezruiz avatar Mar 01 '23 11:03 jsuarezruiz

Very soon. alohakit-layout-grid

I like this,,, thanks for this,, I hope every UI Control is breaking down for single task to make it more performant like flutter. Column => for only column task, Row => for only row task Expand => to expand available space Fraction => Divide children base on available space. Divider => for divider task, SizeBox => for spacing. Padding => for padding task Center => for centering task

nextcodelab avatar Mar 01 '23 11:03 nextcodelab

Do you have any plans for an update at the moment?

lukewire129 avatar Jan 14 '24 00:01 lukewire129