示例#1
0
        public Tab(Tabstrip parent, string label, TabPosition tabPosition)
        {
            this.parent = parent;
            this.Label  = label;

            layout = PangoUtil.CreateLayout(parent);
            layout.FontDescription = FontService.SansFont.CopyModified(Styles.FontScale11);
            layout.SetText(label);
            layout.Alignment = Pango.Alignment.Center;
            layout.GetPixelSize(out w, out h);

            if (IsSeparator)
            {
                w = SpacerWidth * 2;
            }

            this.TabPosition = tabPosition;

            if (AccessibilityElementProxy.Enabled)
            {
                Accessible = AccessibilityElementProxy.ButtonElementProxy();
                Accessible.SetRole(AtkCocoa.Roles.AXRadioButton, "tab");
                Accessible.Title         = label;
                Accessible.GtkParent     = parent;
                Accessible.Identifier    = "Tabstrip.Tab";
                Accessible.PerformPress += OnTabPressed;
            }
        }
示例#2
0
        public Tab(Tabstrip parent, string label, TabPosition tabPosition)
        {
            this.parent = parent;
            this.Label  = label;
            layout      = PangoUtil.CreateLayout(parent);
            layout.SetText(label);
            layout.GetPixelSize(out w, out h);

            if (IsSeparator)
            {
                w = SpacerWidth * 2;
            }

            this.TabPosition = tabPosition;
        }
示例#3
0
        public Tab(Tabstrip parent, string label, TabPosition tabPosition)
        {
            //this.parent = parent;
            this.Label = label;

            layout = PangoUtil.CreateLayout(parent);
            layout.FontDescription = FontService.SansFont.CopyModified(Styles.FontScale11);
            layout.SetText(label);
            layout.Alignment = Pango.Alignment.Center;
            layout.GetPixelSize(out w, out h);

            if (IsSeparator)
            {
                w = SpacerWidth * 2;
            }

            this.TabPosition = tabPosition;
        }
示例#4
0
 public Tab(Tabstrip parent, string label) : this(parent, label, TabPosition.Left)
 {
 }
示例#5
0
		public Tab (Tabstrip parent, string label, TabPosition tabPosition)
		{
			this.parent = parent;
			this.Label = label;
			layout = PangoUtil.CreateLayout (parent);
			layout.SetText (label);
			layout.GetPixelSize (out w, out h);

			if (IsSeparator)
				w = SpacerWidth * 2;
			
			this.TabPosition = tabPosition;
		}
示例#6
0
		public Tab (Tabstrip parent, string label) : this (parent, label, TabPosition.Left)
		{
		}
		void CheckCreateSubViewToolbar ()
		{
			if (subViewToolbar != null)
				return;
			
			subViewToolbar = new Tabstrip ();
			subViewToolbar.Show ();
			
			CheckCreateToolbarBox ();
			toolbarBox.PackStart (subViewToolbar, true, true, 0);
		}
示例#8
0
		public Tab (Tabstrip parent, string label, TabPosition tabPosition)
		{
			//this.parent = parent;
			this.Label = label;

			layout = PangoUtil.CreateLayout (parent);
			layout.FontDescription = FontService.SansFont.CopyModified (Styles.FontScale11);
			layout.SetText (label);
			layout.Alignment = Pango.Alignment.Center;
			layout.GetPixelSize (out w, out h);

			if (IsSeparator)
				w = SpacerWidth * 2;
			
			this.TabPosition = tabPosition;
		}