コード例 #1
0
 public CenteredTextField(CoreGraphics.CGRect frame, string message = "") : base(frame)
 {
     Cell            = new CenteredTextFieldCell();
     Alignment       = NSTextAlignment.Center;
     BackgroundColor = NSColor.Clear;
     Bezeled         = false;
     Bordered        = false;
     Editable        = false;
     Selectable      = false;
     StringValue     = message;
 }
コード例 #2
0
 private void Initialize()
 {
     Cell            = new CenteredTextFieldCell();
     Alignment       = NSTextAlignment.Center;
     BackgroundColor = NSColor.Clear;
     Bezeled         = true;
     Bordered        = true;
     Editable        = true;
     Font            = NSFont.FromFontName("HelveticaNeue-Bold", 24);
     Formatter       = new SingleDigitFormatter();
     StringValue     = string.Empty;
 }