Esempio n. 1
0
        public void ControlStyle()
        {
            Form f = new Form();

            f.ShowInTaskbar = false;

            ExposeProtectedProperties epp = new ExposeProtectedProperties();

            f.Controls.Add(epp);

            ControlStyles cs = ControlStyles.ContainerControl;

            cs |= ControlStyles.UserPaint;
            cs |= ControlStyles.StandardClick;
            cs |= ControlStyles.SupportsTransparentBackColor;
            cs |= ControlStyles.StandardDoubleClick;
            cs |= ControlStyles.AllPaintingInWmPaint;
            cs |= ControlStyles.OptimizedDoubleBuffer;
            cs |= ControlStyles.UseTextForAccessibility;

            Assert.AreEqual(cs, epp.GetControlStyles(), "Styles");

            epp.TabStop = true;

            cs |= ControlStyles.Selectable;

            Assert.AreEqual(cs, epp.GetControlStyles(), "Styles-2");

            epp.TabStop = false;

            cs &= ~ControlStyles.Selectable;

            Assert.AreEqual(cs, epp.GetControlStyles(), "Styles-3");

            f.Close();
            f.Dispose();
        }
Esempio n. 2
0
		public void ControlStyle ()
		{
			ExposeProtectedProperties epp = new ExposeProtectedProperties ();

			ControlStyles cs = ControlStyles.ContainerControl;
			cs |= ControlStyles.UserPaint;
			cs |= ControlStyles.StandardClick;
			cs |= ControlStyles.SupportsTransparentBackColor;
			cs |= ControlStyles.StandardDoubleClick;
			cs |= ControlStyles.AllPaintingInWmPaint;
			cs |= ControlStyles.OptimizedDoubleBuffer;
			cs |= ControlStyles.UseTextForAccessibility;

			Assert.AreEqual (cs, epp.GetControlStyles (), "Styles");
		}
        public void ControlStyle()
        {
            ExposeProtectedProperties epp = new ExposeProtectedProperties();

            ControlStyles cs = ControlStyles.ContainerControl;

            cs |= ControlStyles.UserPaint;
            cs |= ControlStyles.StandardClick;
            cs |= ControlStyles.SupportsTransparentBackColor;
            cs |= ControlStyles.StandardDoubleClick;
            cs |= ControlStyles.Selectable;
            cs |= ControlStyles.ResizeRedraw;
            cs |= ControlStyles.UseTextForAccessibility;

            Assert.AreEqual(cs, epp.GetControlStyles(), "Styles");
        }
Esempio n. 4
0
        public void ControlStyle()
        {
            ExposeProtectedProperties epp = new ExposeProtectedProperties();

            ControlStyles cs = ControlStyles.ContainerControl;

            cs |= ControlStyles.UserPaint;
            cs |= ControlStyles.StandardClick;
            cs |= ControlStyles.SupportsTransparentBackColor;
            cs |= ControlStyles.StandardDoubleClick;
            cs |= ControlStyles.AllPaintingInWmPaint;
            cs |= ControlStyles.OptimizedDoubleBuffer;
            cs |= ControlStyles.UseTextForAccessibility;

            Assert.AreEqual(cs, epp.GetControlStyles(), "Styles");
        }
		public void ControlStyle ()
		{
			ExposeProtectedProperties epp = new ExposeProtectedProperties ();

			ControlStyles cs = ControlStyles.ContainerControl;
			cs |= ControlStyles.UserPaint;
			cs |= ControlStyles.StandardClick;
			cs |= ControlStyles.SupportsTransparentBackColor;
			cs |= ControlStyles.StandardDoubleClick;
			cs |= ControlStyles.Selectable;
			cs |= ControlStyles.ResizeRedraw;
			cs |= ControlStyles.UseTextForAccessibility;

			Assert.AreEqual (cs, epp.GetControlStyles (), "Styles");
		}
Esempio n. 6
0
		public void ControlStyle ()
		{
			Form f = new Form ();
			f.ShowInTaskbar = false;
			
			ExposeProtectedProperties epp = new ExposeProtectedProperties ();
			f.Controls.Add (epp);
			
			ControlStyles cs = ControlStyles.ContainerControl;
			cs |= ControlStyles.UserPaint;
			cs |= ControlStyles.StandardClick;
			cs |= ControlStyles.SupportsTransparentBackColor;
			cs |= ControlStyles.StandardDoubleClick;
			cs |= ControlStyles.AllPaintingInWmPaint;
			cs |= ControlStyles.OptimizedDoubleBuffer;
			cs |= ControlStyles.UseTextForAccessibility;

			Assert.AreEqual (cs, epp.GetControlStyles (), "Styles");
			
			epp.TabStop = true;
			
			cs |= ControlStyles.Selectable;

			Assert.AreEqual (cs, epp.GetControlStyles (), "Styles-2");
			
			epp.TabStop = false;
			
			cs &= ~ControlStyles.Selectable;

			Assert.AreEqual (cs, epp.GetControlStyles (), "Styles-3");
			
			f.Close ();
			f.Dispose ();
		}