|
Cet article a fait l'objet d'une traduction automatique. Déplacez votre pointeur sur les phrases de l'article pour voir la version originale de ce texte. Informations supplémentaires.
|
Traduction
Source
|
TransformGroup, classe
Espace de noms : System.Windows.Media
Assembly : PresentationCore (dans PresentationCore.dll)
XMLNS pour XAML : http://schemas.microsoft.com/winfx/2006/xaml/presentation, http://schemas.microsoft.com/netfx/2007/xaml/presentation
Le type TransformGroup expose les membres suivants.
| Nom | Description | |
|---|---|---|
![]() | CanFreeze | |
![]() | Children | |
![]() | DependencyObjectType | |
![]() | Dispatcher | |
![]() | HasAnimatedProperties | |
![]() | Inverse | |
![]() | IsFrozen | |
![]() | IsSealed | |
![]() | Value |
| Nom | Description | |
|---|---|---|
![]() | ApplyAnimationClock(DependencyProperty, AnimationClock) | |
![]() | ApplyAnimationClock(DependencyProperty, AnimationClock, HandoffBehavior) | |
![]() | BeginAnimation(DependencyProperty, AnimationTimeline) | |
![]() | BeginAnimation(DependencyProperty, AnimationTimeline, HandoffBehavior) | |
![]() | CheckAccess | |
![]() | ClearValue(DependencyProperty) | |
![]() | ClearValue(DependencyPropertyKey) | |
![]() | Clone | |
![]() | CloneCurrentValue | |
![]() | CoerceValue | |
![]() | Equals | |
![]() | Freeze() | |
![]() | GetAnimationBaseValue | |
![]() | GetAsFrozen | |
![]() | GetCurrentValueAsFrozen | |
![]() | GetHashCode | |
![]() | GetLocalValueEnumerator | |
![]() | GetType | |
![]() | GetValue | |
![]() | InvalidateProperty | |
![]() | ReadLocalValue | |
![]() | SetCurrentValue | |
![]() | SetValue(DependencyProperty, Object) | |
![]() | SetValue(DependencyPropertyKey, Object) | |
![]() | ShouldSerializeProperty | |
![]() | ToString() | |
![]() | ToString(IFormatProvider) | |
![]() | Transform | |
![]() | TransformBounds | |
![]() | TryTransform | |
![]() | VerifyAccess |
| Nom | Description | |
|---|---|---|
![]() ![]() | IFormattable.ToString |
<Page xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" > <StackPanel Margin="50"> <Button RenderTransformOrigin="0.5,0.5" HorizontalAlignment="Center">Click <Button.RenderTransform> <!-- TransformGroup enables you to apply multiple transforms. In this example, the button is scaled and rotated. --> <TransformGroup> <!-- Triple the size (scale) of the button in the Y direction. --> <ScaleTransform ScaleY="3" /> <!-- Rotate the button by 45 degrees. --> <RotateTransform Angle="45" /> </TransformGroup> </Button.RenderTransform> </Button> </StackPanel> </Page>
Imports System Imports System.Windows Imports System.Windows.Controls Imports System.Windows.Media Namespace SDKSample Partial Public Class MultipleTransformsExample Inherits Page Public Sub New() ' Create a Button that will have two transforms applied to it. Dim myButton As New Button() myButton.Content = "Click" ' Set the center point of the transforms. myButton.RenderTransformOrigin = New Point(0.5,0.5) ' Create a transform to scale the size of the button. Dim myScaleTransform As New ScaleTransform() ' Set the transform to triple the scale in the Y direction. myScaleTransform.ScaleY = 3 ' Create a transform to rotate the button Dim myRotateTransform As New RotateTransform() ' Set the rotation of the transform to 45 degrees. myRotateTransform.Angle = 45 ' Create a TransformGroup to contain the transforms ' and add the transforms to it. Dim myTransformGroup As New TransformGroup() myTransformGroup.Children.Add(myScaleTransform) myTransformGroup.Children.Add(myRotateTransform) ' Associate the transforms to the button. myButton.RenderTransform = myTransformGroup ' Create a StackPanel which will contain the Button. Dim myStackPanel As New StackPanel() myStackPanel.Margin = New Thickness(50) myStackPanel.Children.Add(myButton) Me.Content = myStackPanel End Sub End Class End Namespace
using System; using System.Windows; using System.Windows.Controls; using System.Windows.Media; namespace SDKSample { public partial class MultipleTransformsExample : Page { public MultipleTransformsExample() { // Create a Button that will have two transforms applied to it. Button myButton = new Button(); myButton.Content = "Click"; // Set the center point of the transforms. myButton.RenderTransformOrigin = new Point(0.5,0.5); // Create a transform to scale the size of the button. ScaleTransform myScaleTransform = new ScaleTransform(); // Set the transform to triple the scale in the Y direction. myScaleTransform.ScaleY = 3; // Create a transform to rotate the button RotateTransform myRotateTransform = new RotateTransform(); // Set the rotation of the transform to 45 degrees. myRotateTransform.Angle = 45; // Create a TransformGroup to contain the transforms // and add the transforms to it. TransformGroup myTransformGroup = new TransformGroup(); myTransformGroup.Children.Add(myScaleTransform); myTransformGroup.Children.Add(myRotateTransform); // Associate the transforms to the button. myButton.RenderTransform = myTransformGroup; // Create a StackPanel which will contain the Button. StackPanel myStackPanel = new StackPanel(); myStackPanel.Margin = new Thickness(50); myStackPanel.Children.Add(myButton); this.Content = myStackPanel; } } }
Windows 8, Windows Server 2012, Windows 7, Windows Vista SP2, Windows Server 2008 (rôle principal du serveur non pris en charge), Windows Server 2008 R2 (rôle principal du serveur pris en charge avec SP1 ou version ultérieure ; Itanium non pris en charge)
Le .NET Framework ne prend pas en charge toutes les versions de chaque plateforme. Pour obtenir la liste des versions prises en charge, consultez Configuration requise du .NET Framework.
