本文整理汇总了C#中SizeChangedEventHandler类的典型用法代码示例。如果您正苦于以下问题:C# SizeChangedEventHandler类的具体用法?C# SizeChangedEventHandler怎么用?C# SizeChangedEventHandler使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
SizeChangedEventHandler类属于命名空间,在下文中一共展示了SizeChangedEventHandler类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: ImageSequence
public ImageSequence()
{
DefaultStyleKey = typeof(ImageSequence);
imageHeight = 1600;
Loaded += new System.Windows.RoutedEventHandler(ImageSequence_Loaded);
SizeChanged += new SizeChangedEventHandler(ImageSequence_SizeChanged);
}
示例2: CircleVisual
public CircleVisual(GMapMarker m, Brush background)
{
Marker = m;
Marker.ZIndex = 100;
Popup.AllowsTransparency = true;
Popup.PlacementTarget = this;
Popup.Placement = PlacementMode.Mouse;
Popup.Child.Opacity = 0.777;
SizeChanged += new SizeChangedEventHandler(CircleVisual_SizeChanged);
MouseEnter += new System.Windows.Input.MouseEventHandler(CircleVisual_MouseEnter);
MouseLeave += new System.Windows.Input.MouseEventHandler(CircleVisual_MouseLeave);
Loaded += new RoutedEventHandler(OnLoaded);
Text = "?";
StrokeArrow.EndLineCap = PenLineCap.Triangle;
StrokeArrow.LineJoin = PenLineJoin.Round;
RenderTransform = scale;
Width = Height = 22;
FontSize = (Width/1.55);
Background = background;
Angle = null;
}
示例3: SceneView
/// <summary>
/// Initializes a new instance of the <see cref="SceneView"/> class.
/// </summary>
public SceneView()
{
InitializeComponent();
// Handle the size changed event.
SizeChanged += new SizeChangedEventHandler(SceneView_SizeChanged);
}
示例4: ColorButton
public ColorButton()
{
this.DefaultStyleKey = typeof(ColorButton);
//if (System.ComponentModel.DesignerProperties.IsInDesignTool)
// return;
SizeChanged += new SizeChangedEventHandler(ColorButton_SizeChanged);
}
示例5: TPill
public TPill()
{
InitializeComponent();
tb.DataContext = this;
foreColor = Colors.White;
SizeChanged += new SizeChangedEventHandler(TPill_SizeChanged);
}
示例6: GlassWindow_Loaded
private void GlassWindow_Loaded( object sender, RoutedEventArgs e )
{
// update GlassRegion on window size change
SizeChanged += new SizeChangedEventHandler( Window1_SizeChanged );
// update background color on change of desktop composition mode
AeroGlassCompositionChanged += new AeroGlassCompositionChangedEvent( Window1_AeroGlassCompositionChanged );
// Set the window background color
if( AeroGlassCompositionEnabled )
{
// exclude the GDI rendered controls from the initial GlassRegion
ExcludeElementFromAeroGlass( eb1 );
SetAeroGlassTransparency( );
}
else
{
this.Background = System.Windows.Media.Brushes.Teal;
}
// initialize the explorer browser control
eb1.NavigationTarget = (ShellObject)KnownFolders.Computer;
// set the state of the Desktop Composition check box.
EnableCompositionCheck.IsChecked = AeroGlassCompositionEnabled;
}
示例7: MainWindow
public MainWindow() {
InitializeComponent();
devlistCaption.CreateBinding(TextBlock.TextProperty, LocalTitles.instance, s => s.devicesList);
this.CommandBindings.Add(
new CommandBinding(
DeviceListView.HideCommand,
(s, a) => {
devlist.Visibility = Visibility.Collapsed;
deviceListButton.Visibility = Visibility.Visible;
}
)
);
deviceListButton.Command = new DelegateCommand(
() => {
devlist.Visibility = Visibility.Visible;
deviceListButton.Visibility = Visibility.Collapsed;
}
);
//AppDefaults.InitConfigs();
InitPosition();
SizeChanged += new SizeChangedEventHandler((obj, evargs) => {
var mvs = AppDefaults.visualSettings;
mvs.WndState = this.WindowState;
if (this.WindowState == System.Windows.WindowState.Maximized) {
AppDefaults.UpdateVisualSettings(mvs);
return;
}
if (this.WindowState == System.Windows.WindowState.Minimized) {
AppDefaults.UpdateVisualSettings(mvs);
return;
}
mvs.WndSize = new Rect(mvs.WndSize.X, mvs.WndSize.Y, evargs.NewSize.Width, evargs.NewSize.Height);
AppDefaults.UpdateVisualSettings(mvs);
});
LocationChanged += new EventHandler((obj, evargs) => {
var vs = AppDefaults.visualSettings;
vs.WndState = this.WindowState;
if (this.WindowState == System.Windows.WindowState.Maximized) {
AppDefaults.UpdateVisualSettings(vs);
return;
}
if (this.WindowState == System.Windows.WindowState.Minimized) {
AppDefaults.UpdateVisualSettings(vs);
return;
}
vs.WndSize = new Rect(this.Left, this.Top, vs.WndSize.Width, vs.WndSize.Height);
AppDefaults.UpdateVisualSettings(vs);
});
}
示例8: RibbonWindow
public RibbonWindow()
: base()
{
SizeChanged += new SizeChangedEventHandler(OnSizeChanged);
HookWndProc();
RegisterCommands();
SkinManager.SkinChanged += new EventHandler(OnSkinChanged);
}
示例9: MainPage
public MainPage()
{
InitializeComponent();
SupportedOrientations = SupportedPageOrientation.PortraitOrLandscape;
SizeChanged += new SizeChangedEventHandler(BinaryClock_SizeChanged);
Loaded += new RoutedEventHandler(BinaryClock_Loaded);
}
示例10: TiledBackground
public TiledBackground()
{
// create an image as the content of the control
tiledImage.Stretch = Stretch.None;
Content = tiledImage;
// no sizechanged to override
SizeChanged += new SizeChangedEventHandler(TiledBackground_SizeChanged);
}
示例11: GraphicsControlBase
public GraphicsControlBase()
{
Loaded += new RoutedEventHandler(XnaWindowHost_Loaded);
SizeChanged += new SizeChangedEventHandler(XnaWindowHost_SizeChanged);
Application.Current.Activated += new EventHandler(Current_Activated);
Application.Current.Deactivated += new EventHandler(Current_Deactivated);
CompositionTarget.Rendering += CompositionTarget_Rendering;
}
示例12: Viewport2D
public Viewport2D()
{
// ClipToBounds = true;
Grid.SetColumn(this, 1);
Grid.SetRow(this, 1);
visible = new Rect(new Point(0, 0), new Point(1, 1));
SizeChanged += new SizeChangedEventHandler(Viewport2D_SizeChanged);
UpdateTransform();
}
示例13: Outline
public Outline()
{
moves = new ObservableCollection<TXY>(outLineMoves);
DataContext = this;
fOutLineSize = 0.05;
InitializeComponent();
SizeChanged += new SizeChangedEventHandler(TPill_SizeChanged);
text = "0";
fKW = 1;
fKH = 1;
}
示例14: LayoutDocumentPaneControl
internal LayoutDocumentPaneControl(LayoutDocumentPane model)
{
if (model == null)
throw new ArgumentNullException("model");
_model = model;
SetBinding(ItemsSourceProperty, new Binding("Model.Children") { Source = this });
SetBinding(FlowDirectionProperty, new Binding("Model.Root.Manager.FlowDirection") { Source = this });
this.LayoutUpdated += new EventHandler(OnLayoutUpdated);
SizeChanged += new SizeChangedEventHandler(LayoutDocumentPaneControl_SizeChanged);
}
示例15: UIContainer
public UIContainer()
{
m_elements = new VisualCollection(this);
CreateElements();
SnapsToDevicePixels = true;
RenderOptions.SetEdgeMode(this, EdgeMode.Aliased);
SizeChanged += new SizeChangedEventHandler((sender, e) => {
VisualClip = new RectangleGeometry(new Rect(0, 0, ActualWidth, ActualHeight));
});
}