Code:
/ DotNET / DotNET / 8.0 / untmp / WIN_WINDOWS / lh_tools_devdiv_wpf / Windows / wcp / Core / MS / Internal / Ink / StrokeNodeData.cs / 1 / StrokeNodeData.cs
//------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------- using System; using System.Collections.Generic; using System.Windows; using System.Windows.Media; using System.Windows.Input; using System.Diagnostics; namespace MS.Internal.Ink { #region StrokeNodeData ////// This structure represents a node on a stroke spine. /// internal struct StrokeNodeData { #region Statics private static StrokeNodeData s_empty = new StrokeNodeData(); #endregion #region API (internal) ///Returns static object representing an unitialized node internal static StrokeNodeData Empty { get { return s_empty; } } ////// Constructor for nodes of a pressure insensitive stroke /// /// position of the node internal StrokeNodeData(Point position) { _position = position; _pressure = 1; } ////// Constructor for nodes with pressure data /// /// position of the node /// pressure scaling factor at the node internal StrokeNodeData(Point position, float pressure) { System.Diagnostics.Debug.Assert(DoubleUtil.GreaterThan((double)pressure, 0d)); _position = position; _pressure = pressure; } ///Tells whether the structre was properly initialized internal bool IsEmpty { get { Debug.Assert(DoubleUtil.AreClose(0, s_empty._pressure)); return DoubleUtil.AreClose(_pressure, s_empty._pressure); } } ///Position of the node internal Point Position { get { return _position; } } ///Pressure scaling factor at the node internal float PressureFactor { get { return _pressure; } } #endregion #region Privates private Point _position; private float _pressure; #endregion } #endregion } // File provided for Reference Use Only by Microsoft Corporation (c) 2007.
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- Parameter.cs
- SelectionHighlightInfo.cs
- InvalidEnumArgumentException.cs
- BulletDecorator.cs
- Attribute.cs
- MethodAccessException.cs
- PersonalizationStateInfo.cs
- Interfaces.cs
- ComplusTypeValidator.cs
- Variant.cs
- DataServices.cs
- IERequestCache.cs
- UserPreferenceChangedEventArgs.cs
- PTUtility.cs
- MediaPlayerState.cs
- BinaryObjectInfo.cs
- ListViewInsertionMark.cs
- IPAddressCollection.cs
- GlobalProxySelection.cs
- PropertyGridView.cs
- DataGridViewImageColumn.cs
- DeferredSelectedIndexReference.cs
- XmlSchemaExporter.cs
- ExplicitDiscriminatorMap.cs
- SingleAnimation.cs
- RuntimeUtils.cs
- DocComment.cs
- NotFiniteNumberException.cs
- UInt32Storage.cs
- WindowsAuthenticationModule.cs
- XPathScanner.cs
- ActivityCodeDomSerializer.cs
- ExtenderControl.cs
- TabletDevice.cs
- DataGridTablesFactory.cs
- UTF7Encoding.cs
- ClientCredentialsSecurityTokenManager.cs
- SpellerStatusTable.cs
- SpeechSeg.cs
- ReadWriteSpinLock.cs
- SerTrace.cs
- SamlAuthorizationDecisionStatement.cs
- ProxyHwnd.cs
- Encoder.cs
- Setter.cs
- HttpListenerElement.cs
- SmiTypedGetterSetter.cs
- QuaternionAnimation.cs
- SchemaLookupTable.cs
- TableStyle.cs
- SingleAnimationUsingKeyFrames.cs
- FlowLayoutSettings.cs
- ActiveXHost.cs
- HMACSHA512.cs
- DbConnectionPoolCounters.cs
- DnsElement.cs
- WebControlAdapter.cs
- XmlSchemaSet.cs
- TcpConnectionPoolSettings.cs
- StorageModelBuildProvider.cs
- TCEAdapterGenerator.cs
- ExpressionBindingCollection.cs
- LoginView.cs
- CodeCatchClauseCollection.cs
- ObjectDesignerDataSourceView.cs
- EditorPartCollection.cs
- DateTimeValueSerializer.cs
- TextDecoration.cs
- RawUIStateInputReport.cs
- DataListGeneralPage.cs
- XmlSortKeyAccumulator.cs
- AssemblyAttributesGoHere.cs
- NegotiateStream.cs
- HttpListenerException.cs
- MediaElement.cs
- ProvidePropertyAttribute.cs
- SqlColumnizer.cs
- XmlSignatureManifest.cs
- DeclarationUpdate.cs
- HasCopySemanticsAttribute.cs
- ErrorReporting.cs
- ApplicationHost.cs
- EdmPropertyAttribute.cs
- sqlmetadatafactory.cs
- XmlDataProvider.cs
- XmlDictionaryString.cs
- NavigationService.cs
- PerfProviderCollection.cs
- BamlLocalizationDictionary.cs
- TypeDescriptionProvider.cs
- AlphabeticalEnumConverter.cs
- SQLString.cs
- PointCollection.cs
- NotificationContext.cs
- _Connection.cs
- Dispatcher.cs
- CodeAttachEventStatement.cs
- FilePrompt.cs
- Camera.cs
- IfJoinedCondition.cs