첨부 실행 코드는 나눔고딕코딩 폰트를 사용합니다.
유용한 소스 코드가 있으면 icodebroker@naver.com으로 보내주시면 감사합니다.
블로그 자료는 자유롭게 사용하세요.

728x90
반응형

■ CombinedGeometry 엘리먼트 : GeometryCombineMode 속성 사용하기

------------------------------------------------------------------------------------------------------------------------


TestProject.zip


MainWindow.xaml

 

 

<Window x:Class="TestProject.MainWindow"

    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"

    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"

    Width="800"

    Height="600"

    Title="CombinedGeometry 엘리먼트 : GeometryCombineMode 속성 사용하기"

    FontFamily="나눔고딕코딩"

    FontSize="16">

    <Grid>

        <Path

            HorizontalAlignment="Center"

            VerticalAlignment="Center"

            Stroke="Black"

            StrokeThickness="5"

            Fill="DarkGray">

            <Path.Data>

                <CombinedGeometry GeometryCombineMode="Union">

                    <CombinedGeometry.Geometry1>

                        <CombinedGeometry GeometryCombineMode="Union">

                            <CombinedGeometry.Geometry1>

                                <EllipseGeometry

                                    Center="50 50"

                                    RadiusX="50"

                                    RadiusY="50" />

                            </CombinedGeometry.Geometry1>

                            <CombinedGeometry.Geometry2>

                                <RectangleGeometry Rect="50 25 200 50" />

                            </CombinedGeometry.Geometry2>

                        </CombinedGeometry>

                    </CombinedGeometry.Geometry1>

                    <CombinedGeometry.Geometry2>

                        <EllipseGeometry

                            Center="250 50"

                            RadiusX="50"

                            RadiusY="50" />

                    </CombinedGeometry.Geometry2>

                </CombinedGeometry>

            </Path.Data>

        </Path>

    </Grid>

</Window>

 

------------------------------------------------------------------------------------------------------------------------

728x90
반응형
Posted by 사용자 icodebroker

댓글을 달아 주세요