Code:
/ Net / Net / 3.5.50727.3053 / DEVDIV / depot / DevDiv / releases / Orcas / SP / wpf / src / Core / CSharp / System / Windows / Media / RotateTransform.cs / 1 / RotateTransform.cs
//------------------------------------------------------------------------------
// Microsoft Avalon
// Copyright (c) Microsoft Corporation, 2001
//
// File: RotateTransform.cs
//-----------------------------------------------------------------------------
using MS.Internal;
using MS.Internal.PresentationCore;
using System;
using System.Collections;
using System.ComponentModel;
using System.ComponentModel.Design.Serialization;
using System.Diagnostics;
using System.Globalization;
using System.Reflection;
using System.Runtime.InteropServices;
using System.Text;
using System.Windows;
using System.Windows.Media;
using System.Windows.Media.Animation;
using System.Windows.Media.Composition;
using SR=MS.Internal.PresentationCore.SR;
using SRID=MS.Internal.PresentationCore.SRID;
namespace System.Windows.Media
{
///
/// Create a rotation transformation in degrees.
///
public sealed partial class RotateTransform : Transform
{
///
///
///
public RotateTransform()
{
}
///
/// Create a rotation transformation in degrees.
///
///The angle of rotation in degrees.
public RotateTransform(double angle)
{
Angle = angle;
}
///
/// Create a rotation transformation in degrees.
///
public RotateTransform(
double angle,
double centerX,
double centerY
) : this(angle)
{
CenterX = centerX;
CenterY = centerY;
}
///
/// Return the current transformation value.
///
public override Matrix Value
{
get
{
ReadPreamble();
Matrix m = new Matrix();
m.RotateAt(Angle, CenterX, CenterY);
return m;
}
}
///
/// Returns true if transformation matches the identity transform.
///
internal override bool IsIdentity
{
get
{
return Angle == 0 && CanFreeze;
}
}
}
}
// File provided for Reference Use Only by Microsoft Corporation (c) 2007.
// Copyright (c) Microsoft Corporation. All rights reserved.
//------------------------------------------------------------------------------
// Microsoft Avalon
// Copyright (c) Microsoft Corporation, 2001
//
// File: RotateTransform.cs
//-----------------------------------------------------------------------------
using MS.Internal;
using MS.Internal.PresentationCore;
using System;
using System.Collections;
using System.ComponentModel;
using System.ComponentModel.Design.Serialization;
using System.Diagnostics;
using System.Globalization;
using System.Reflection;
using System.Runtime.InteropServices;
using System.Text;
using System.Windows;
using System.Windows.Media;
using System.Windows.Media.Animation;
using System.Windows.Media.Composition;
using SR=MS.Internal.PresentationCore.SR;
using SRID=MS.Internal.PresentationCore.SRID;
namespace System.Windows.Media
{
///
/// Create a rotation transformation in degrees.
///
public sealed partial class RotateTransform : Transform
{
///
///
///
public RotateTransform()
{
}
///
/// Create a rotation transformation in degrees.
///
///The angle of rotation in degrees.
public RotateTransform(double angle)
{
Angle = angle;
}
///
/// Create a rotation transformation in degrees.
///
public RotateTransform(
double angle,
double centerX,
double centerY
) : this(angle)
{
CenterX = centerX;
CenterY = centerY;
}
///
/// Return the current transformation value.
///
public override Matrix Value
{
get
{
ReadPreamble();
Matrix m = new Matrix();
m.RotateAt(Angle, CenterX, CenterY);
return m;
}
}
///
/// Returns true if transformation matches the identity transform.
///
internal override bool IsIdentity
{
get
{
return Angle == 0 && CanFreeze;
}
}
}
}
// File provided for Reference Use Only by Microsoft Corporation (c) 2007.
// Copyright (c) Microsoft Corporation. All rights reserved.
Link Menu

This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- IsolatedStorageFile.cs
- TypeSystemHelpers.cs
- NGCSerializerAsync.cs
- MarkupCompilePass1.cs
- VisualBasicSettingsHandler.cs
- SupportsEventValidationAttribute.cs
- ChannelServices.cs
- ChtmlTextBoxAdapter.cs
- ThreadNeutralSemaphore.cs
- CssTextWriter.cs
- ActivitiesCollection.cs
- SmtpNetworkElement.cs
- HierarchicalDataSourceControl.cs
- CodeTypeReference.cs
- CryptoStream.cs
- StreamUpdate.cs
- NodeLabelEditEvent.cs
- DesignTable.cs
- ErrorWebPart.cs
- HttpWriter.cs
- TokenCreationException.cs
- HostingEnvironmentSection.cs
- TypeUtils.cs
- ExpressionBindingCollection.cs
- UrlMappingsModule.cs
- TdsValueSetter.cs
- MetadataPropertyCollection.cs
- IPCCacheManager.cs
- SchemeSettingElement.cs
- RectangleConverter.cs
- Executor.cs
- VsPropertyGrid.cs
- Group.cs
- UIServiceHelper.cs
- HttpDebugHandler.cs
- TemplateBindingExtensionConverter.cs
- MemberMaps.cs
- XmlSchemaObject.cs
- UIElementAutomationPeer.cs
- AdditionalEntityFunctions.cs
- NTAccount.cs
- XmlLoader.cs
- BufferedGraphicsContext.cs
- LocalizedNameDescriptionPair.cs
- TextServicesLoader.cs
- DataTable.cs
- AppModelKnownContentFactory.cs
- ConfigXmlCDataSection.cs
- DBConnectionString.cs
- M3DUtil.cs
- Control.cs
- DesignerAdapterUtil.cs
- BitmapEffectGeneralTransform.cs
- SystemColors.cs
- HelloMessage11.cs
- Paragraph.cs
- DependencyPropertyValueSerializer.cs
- IncrementalCompileAnalyzer.cs
- CompressStream.cs
- DateTimeConverter.cs
- BitmapEffect.cs
- StreamResourceInfo.cs
- TraceHandlerErrorFormatter.cs
- ProcessRequestArgs.cs
- StringDictionaryEditor.cs
- SrgsDocumentParser.cs
- QilReference.cs
- ImageAutomationPeer.cs
- ServiceControllerDesigner.cs
- LineUtil.cs
- FeatureSupport.cs
- ReadOnlyNameValueCollection.cs
- infer.cs
- TrustManagerMoreInformation.cs
- ProcessThread.cs
- StrongName.cs
- SafeRegistryKey.cs
- CannotUnloadAppDomainException.cs
- ConfigXmlReader.cs
- CodeAccessSecurityEngine.cs
- NodeLabelEditEvent.cs
- ToolStripContentPanel.cs
- CryptoConfig.cs
- ObjectManager.cs
- UInt16Converter.cs
- DrawingContextWalker.cs
- HMAC.cs
- IntranetCredentialPolicy.cs
- WindowPattern.cs
- ReachIDocumentPaginatorSerializerAsync.cs
- categoryentry.cs
- RequestCacheValidator.cs
- HttpHandlerActionCollection.cs
- Timer.cs
- Adorner.cs
- SweepDirectionValidation.cs
- TextDecorationUnitValidation.cs
- ReflectionTypeLoadException.cs
- ThreadAbortException.cs
- PcmConverter.cs