2017-11-15 1 views
0

어떻게하면 컨트롤의 50 %를 메뉴 막대 위로 50 % 이미지보기처럼 놓을 수 있으며 스크린 샷과 마찬가지로 페이지를 50 % 이상 제어 할 수 있습니까? please find attached screenshot...as showing in image there is circular image ,half section of image placed over the toolbar and rest placed over the pagexamarin 양식의 도구 모음보다 50 % 제어 할 수있는 방법은 무엇입니까?

나는 상대 레이아웃을 사용하여이를 구현하려고했지만 그럴 수 없었다. 그런 UI를 디자인하는 데 도움이되는 사람을 기쁘게하십시오.

 <Button HeightRequest="50" WidthRequest="50" BorderRadius="35" BackgroundColor="Aqua" 
      RelativeLayout.XConstraint= "{ConstraintExpression Type=RelativeToParent, Property=Width, Factor = .5}" 
      RelativeLayout.YConstraint="{ConstraintExpression Type=RelativeToParent, Property=Height, Factor = -.05}" /> 
+0

가 음의 값으로'TranslationY' 속성을 설정하는 것이 사용 절대 레이아웃을 할 수 있습니다. –

+0

ok..Gerald 난 .. I이 시도 – nitu

+0

이것을 시도하지만 메뉴 바 버튼 <버튼 HeightRequest = "50"WidthRequest = "50"BorderRadius = "35"의 backgroundColor가 = "아쿠아" \t \t \t \t RelativeLayout의 중첩 .XConstraint = "{ConstraintExpression Type = RelativeToParent, Property = 너비, Factor = .5}" \t RelativeLayout.YConstraint = "{ConstraintExpressionType = RelativeToParent, 속성 = 높이, 요소 = -05}"/> – nitu

답변

0

당신은 가장 기본적인 방법

  <AbsoluteLayout BackgroundColor="white"> 
       <BoxView BackgroundColor="Aqua" AbsoluteLayout.LayoutBounds="0 
        0,1,100" AbsoluteLayout.LayoutFlags="XProportional,YProportional,WidthProportional" /> 
       <Button BackgroundColor="White" 
        AbsoluteLayout.LayoutBounds=".5,75,70,70" AbsoluteLayout.LayoutFlags="XProportional" BorderRadius="35" /> 
       <Button BackgroundColor="Red" AbsoluteLayout.LayoutBounds=".5 
        80,60,60" AbsoluteLayout.LayoutFlags="XProportional" BorderRadius="30" /> 
      </AbsoluteLayout> 

Reference

+0

절대 레이아웃을 사용하면 툴바가 버튼과 겹칩니다. – nitu

+0

@nitu ContentView에 단추 넣기 –

관련 문제