本文整理汇总了C#中System.Windows.Controls.TextBox.Hide方法的典型用法代码示例。如果您正苦于以下问题:C# TextBox.Hide方法的具体用法?C# TextBox.Hide怎么用?C# TextBox.Hide使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类System.Windows.Controls.TextBox
的用法示例。
在下文中一共展示了TextBox.Hide方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: ApplicationCanvas
public ApplicationCanvas()
{
//var logo = new JSCSolutionsNETImage();
//logo.AttachTo(this);
var text = new TextBox
{
AcceptsReturn = true,
BorderThickness = new Thickness(0),
Background = Brushes.Transparent,
Foreground = Brushes.Blue,
};
text.AttachTo(this);
r.Fill = Brushes.Yellow;
r.Opacity = 0.3;
r.AttachTo(this);
r.MoveTo(8, 8);
this.SizeChanged += (s, e) =>
{
r.SizeTo(this.Width - 16, this.Height - 16);
//logo.MoveTo(
// this.Width - logo.Width,
// this.Height - logo.Height
//);
};
r.MouseEnter +=
(s, e) =>
{
text.Show();
};
r.MouseLeave +=
(s, e) =>
{
text.Hide();
};
r.MouseMove +=
(s, e) =>
{
var p = e.GetPosition(this);
text.Text = "jsc-solutions.net\n" + new { p.X, p.Y };
text.MoveTo(p.X + 32, p.Y);
};
}
示例2: OrcasAvalonApplicationCanvas
//.........这里部分代码省略.........
(Action)
delegate
{
var i = 0;
foreach (var k_ in a)
{
var k = k_;
var Container = new Canvas
{
Width = GameReferenceExtensions.Width,
Height = GameReferenceExtensions.Height,
}.AttachTo(Content).MoveTo(0, i * GameReferenceExtensions.Height);
var Image = new Image
{
Width = GameReferenceExtensions.Width,
Height = GameReferenceExtensions.Height,
Stretch = Stretch.Fill
}.AttachTo(Container);
var Shadow = new Rectangle
{
Fill = Brushes.Black,
Opacity = 0.5,
Width = GameReferenceExtensions.Width - 2 * 2,
Height = GameReferenceExtensions.Height / 3,
}.AttachTo(Container).MoveTo(2, GameReferenceExtensions.Height / 3);
var ShadowBottom = new Rectangle
{
Fill = Brushes.Black,
Width = GameReferenceExtensions.Width - 2 * 2,
Height = GameReferenceExtensions.Height / 3 / 2,
}.AttachTo(Container).MoveTo(2, GameReferenceExtensions.Height / 3 + GameReferenceExtensions.Height / 3 / 2);
var AnimatedShadow = Shadow.ToAnimatedOpacity();
AnimatedShadow.Opacity = 0;
var AnimatedShadowBottom = ShadowBottom.ToAnimatedOpacity();
AnimatedShadowBottom.Opacity = 0;
var Text = new TextBox
{
BorderThickness = new Thickness(0),
Width = GameReferenceExtensions.Width * 2,
Background = Brushes.Transparent,
Foreground = Brushes.White,
IsReadOnly = true,
Text = k.Title,
TextAlignment = TextAlignment.Center,
FontSize = 10,
FontFamily = new FontFamily("Verdana")
}.AttachTo(Container).MoveTo(-GameReferenceExtensions.Width / 2, 8 + GameReferenceExtensions.Height / 3);
Text.Hide();
var AnimatedImage = Container.ToAnimatedOpacity();
AnimatedImage.Opacity = 0;
ShowImageWhenReady(k, Image, Text, AnimatedImage);
var TouchOverlay = new Rectangle
{
Fill = Brushes.White,
Width = GameReferenceExtensions.Width,
Height = GameReferenceExtensions.Height,
Cursor = Cursors.Hand,
Opacity = 0
}.AttachTo(TouchOverlayContainer).MoveTo(0, i * GameReferenceExtensions.Height);
TouchOverlay.MouseLeftButtonUp +=
delegate
{
new Uri(k.Link).NavigateTo();
};
List.Add(new Entry
{
Shadow = AnimatedShadow,
ShadowBottom = AnimatedShadowBottom,
Text = Text,
Canvas = Container,
Image = Image,
TouchOverlay = TouchOverlay
});
i++;
}
StartAnimation(List);
}
);
};
#endregion
wc.DownloadStringAsync(new Uri(GameReferenceExtensions.Host + GameReferenceExtensions.Path));
}
示例3: Main
static void Main(string[] args)
{
var c = new JSCSolutionsNETCarouselCanvas
{
CloseOnClick = false
};
c.HideSattelites();
//c.Container.Effect = new DropShadowEffect();
//c.Container.BitmapEffect = new DropShadowBitmapEffect();
//.MoveTo(0, ImageCarouselCanvas.DefaultHeight - 96).SizeTo(ImageCarouselCanvas.DefaultWidth, 96);
var cc = new Canvas();
// http://cloudstore.blogspot.com/2008/05/creating-custom-window-style.html
var wcam = new Window();
wcam.Background = Brushes.Transparent;
wcam.WindowStyle = WindowStyle.None;
wcam.ResizeMode = ResizeMode.NoResize;
wcam.SizeTo(200, 200);
wcam.AllowsTransparency = true;
//wcam.Opacity = 0.5;
wcam.ShowInTaskbar = false;
wcam.Cursor = Cursors.Hand;
wcam.Focusable = false;
wcam.Topmost = true;
var w = cc.ToWindow();
w.SizeToContent = SizeToContent.Manual;
//w.SizeTo(400, 400);
//w.ToTransparentWindow();
// http://blog.joachim.at/?p=39
// http://blogs.msdn.com/changov/archive/2009/01/19/webbrowser-control-on-transparent-wpf-window.aspx
// http://blogs.interknowlogy.com/johnbowen/archive/2007/06/20/20458.aspx
w.AllowsTransparency = true;
w.WindowStyle = System.Windows.WindowStyle.None;
w.Focusable = false;
//w.Background = new SolidColorBrush(Color.FromArgb(0x20, 0, 0, 0));
w.Background = Brushes.Transparent;
w.WindowStartupLocation = System.Windows.WindowStartupLocation.CenterScreen;
w.Topmost = true;
//w.ShowInTaskbar = false;
var winfoc = new Canvas();
var winfo = winfoc.ToWindow();
winfo.AllowsTransparency = true;
winfo.ShowInTaskbar = false;
winfo.WindowStyle = WindowStyle.None;
//winfo.Background = Brushes.Transparent;
winfo.Background = Brushes.Red;
winfo.Opacity = 0.3;
winfo.ResizeMode = ResizeMode.NoResize;
winfo.SizeToContent = SizeToContent.Manual;
winfo.Topmost = true;
// http://www.squidoo.com/youtubehd
var NextInputModeEnabled = false;
var NextInputModeKeyDownEnabled = false;
Action<Key> NextInputModeKeyDown = delegate { };
var CommandKeysEnabled = false;
#region TopicText
var TopicText = new System.Windows.Controls.TextBox
{
//IsReadOnly = true,
Background = Brushes.Transparent,
BorderThickness = new System.Windows.Thickness(0),
Foreground = Brushes.White,
Effect = new DropShadowEffect(),
Text = "JSC C# Foo Bar",
//TextDecorations = TextDecorations.Underline,
FontFamily = new FontFamily("Verdana"),
FontSize = 24,
TextAlignment = System.Windows.TextAlignment.Right
};
//.........这里部分代码省略.........