Пример #1
0
        public override Control Render(Rectangle rect)
        {
            TextBox stringBox = new TextBox();

            stringBox.Text   = Value.ToString();
            stringBox.Width  = rect.Width;
            stringBox.Height = CFMeasureString.MeasureString(stringBox, stringBox.Text, stringBox.ClientRectangle).Height;
            return(stringBox);
        }
Пример #2
0
        public override Control Render(Rectangle rect)
        {
            /* PARAMS:
             * XmlAnnotatedElement n --> <Nome>[StringBox1]<Value>value or nothing</Value></Nome>
             */

            TextBox stringBox = new TextBox();

            stringBox.Text   = Value;
            stringBox.Width  = rect.Width;
            stringBox.Height = CFMeasureString.MeasureString(stringBox, stringBox.Text, stringBox.ClientRectangle).Height;
            return(stringBox);
        }