child1AlignLeft_child2CenterHorizontal static method

Widget child1AlignLeft_child2CenterHorizontal(
  1. Widget child1,
  2. Widget child2, {
  3. double child1_marginLeft = 0,
  4. double child1_marginTop = 0,
  5. double child2_marginTop = 0,
})

Implementation

static Widget child1AlignLeft_child2CenterHorizontal(Widget child1, Widget child2,{
  double child1_marginLeft = 0,
  double child1_marginTop = 0,
  double child2_marginTop = 0
} ) {
  var stack = Stack(
    children: [

      //back
      Positioned(child: child1 ,
          left: child1_marginLeft,  top: child1_marginTop),

      // title
      Positioned(child: child2 , left: 0, right: 0, top: child2_marginTop,)

    ],
  );

  return stack;
}