DISEÑO DE VENTANA (XAML Y WPF VS2010)



VISTA DE LA VENTANA



CÓDIGO EN XAML


Código por defecto, Sólo cambié las propiedades principales, el ancho y alto de formulario, la locación de inicio de la ventana que la imagen al momento de inicio aparezca maximizada.
<Window x:Class="XAML_IniciodeSesion_Ventana.Window1"
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
        Title="Window1" Height="1024" Width="1280" WindowStartupLocation="CenterScreen" Background="#FFEFDCDC" WindowState="Maximized" BorderBrush="#FFFC2727" >




    <Grid Background="#FFFFF8F8">
        <Grid Grid.Row="1" Grid.Column="1" Margin="9,10,10,10">
            <BorderCornerRadius="30"Margin="25,136,0,24" HorizontalAlignment="Left" Width="321"Background="#9BFFFFFF" BorderBrush="#FFCDE4E5">
                <StackPanelGrid.Column="0"Grid.Row="0">
                    <Grid Height="804">
               
                         
                       
                       
                    <Border BorderBrush="Gray" BorderThickness="1" Name="Border1" CornerRadius="10" Height="40" Margin=" 15,15,15,5"VerticalAlignment="Top" >
                        <Border.Background>
                            <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                <GradientStopColor="#FFD6D6EB" Offset="0" />
                                <GradientStopColor="#FFEF720D" Offset="1" />
                            </LinearGradientBrush>
                        </Border.Background>
                        <LabelContent="Datos Ingresados" Height="27"Name="label1"FontWeight="Bold"Foreground="#FFF2F5EF" Width="108"VerticalAlignment="Center" HorizontalAlignment="Center" Background="{x:Null}"></Label>
                    </Border>
                        <LabelContent="Apellidos:" Name="label3"FontFamily="Arial"FontSize="11"Margin="34,89,220,692" FontWeight="Bold" />
                        <TextBoxHeight="23"Name="textBox1" Width="199"Margin="0,88,15,693" HorizontalAlignment="Right" FontSize="12" />
                        <LabelContent="Nombre(s):" FontFamily="Arial" FontSize="11" Margin="32,118,220,663" Name="label4"FontWeight="Bold" />
                        <TextBoxHeight="23"Margin="105,117,15,664" Name="textBox2" FontSize="12" />
                        <LabelContent="Especialidad:" FontFamily="Arial" FontSize="11" Margin="15,149,220,632" Name="label6"FontWeight="Bold" />
                        <TextBoxFontSize="12"Height="23"Margin="0,148,15,633" Name="textBox4" HorizontalAlignment="Right" Width="199" />
                    </Grid>
                </StackPanel>
            </Border>
       
       
       
            <BorderCornerRadius="30"Margin="368,488,0,34" HorizontalAlignment="Left" Width="839"BorderBrush="#FFCDE4E5" Background="#9BFFFFFF">
                <BorderBorderBrush="Gray"BorderThickness="1"CornerRadius="30,30,0,0" Height="40"Name="border2" VerticalAlignment="Top" Margin="0,0,0,15">
                    <Border.Background>
                        <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                            <GradientStopColor="#FFD6D6EB" Offset="0" />
                            <GradientStopColor="#FFEF720D" Offset="1" />
                        </LinearGradientBrush>
                    </Border.Background>
                    <LabelBackground="{x:Null}" Content="Datos Ingresados" FontWeight="Bold" Foreground="#FFF2F5EF" Height="28"Name="label2"Width="108" />
                </Border>
            </Border>
           
           
           
            <Border Background="#9BFFFFFF" BorderBrush="#FFCDE4E5" CornerRadius="30" HorizontalAlignment="Left" Margin="368,136,0,504" Width="839">
                <StackPanelGrid.Column="0"Grid.Row="0">
                                  
                <BorderBorderBrush="Gray"BorderThickness="1"CornerRadius="30,30,0,0" Height="40"Margin="10,10,10,10" Name="border3" VerticalAlignment="Top" >
                   

                    <Border.Background>
                        <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                            <GradientStopColor="#FFD6D6EB" Offset="0" />
                            <GradientStopColor="#FFEF720D" Offset="1" />
                        </LinearGradientBrush>
                    </Border.Background>
                    <LabelBackground="{x:Null}" Content="Datos Ingresados" FontWeight="Bold" Foreground="#FFF2F5EF" Height="27"HorizontalAlignment="Center" Name="label7"VerticalAlignment="Center" Width="108" />
                </Border>


                    <BorderBorderThickness="1"CornerRadius="0,0,30,30" Height="239"Margin="10,10,10,10" Name="border4" VerticalAlignment="Top" >
                        <Border.Background>
                            <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                <GradientStopColor="#FFEBEBF8" Offset="0" />
                                <GradientStopColor="White"Offset="1" />
                            </LinearGradientBrush>
                        </Border.Background>
                        <Border.BorderBrush>
                            <SolidColorBrush/>
                        </Border.BorderBrush>
                    </Border>

                </StackPanel>
            </Border>
           
           
           
            <ComboBoxHeight="23"HorizontalAlignment="Left" Margin="977,677,0,0" Name="comboBox1" VerticalAlignment="Top" Width="187"BorderBrush="#FF190000">
                <ComboBox.Background>
                    <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                        <GradientStopColor="#FF9FC5E5" Offset="1" />
                        <GradientStop Color="#E6FFFFFF" Offset="0.033" />
                    </LinearGradientBrush>
                </ComboBox.Background>
            </ComboBox>
          
        
            <Grid.Background>
                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                    <GradientStopColor="#FFEDF1F6" Offset="1" />
                    <GradientStopColor="#FF4C87C6" Offset="0.049" />
                </LinearGradientBrush>
            </Grid.Background>
        </Grid>
    </Grid >
   
   


</Window>

ORDEN (GRID > STACKPANEL > BORDER > GRID > CONTROLES)

0 comentarios: