示例#1
0
        public TypeMemberGroupFigure(string name)
            : base()
        {
            Spacing = 5;
            Alignment = VStackAlignment.Left;

            groupName = new SimpleTextFigure(name);
            groupName.Padding = 0;
            groupName.FontSize = 10;
            groupName.FontColor = new Cairo.Color(0.3, 0.0, 0.0);

            Add(groupName);

            membersStack = new VStackFigure();
            membersStack.Spacing = 2;

            expandHandle = new ToggleButtonHandle(this, new AbsoluteLocator(-10, 7.5));
            expandHandle.Toggled += delegate(object sender, ToggleEventArgs e) {
                if (e.Active) {
                    Add(membersStack);
                }
                else {
                    Remove(membersStack);
                }
            };
            expandHandle.Active = true;
        }
        public TypeMemberGroupFigure(string name)
            : base()
        {
            Spacing = 10;
            Alignment = VStackAlignment.Left;

            groupName = new SimpleTextFigure(name);
            groupName.Padding = 0;
            groupName.FontSize = 12;
            groupName.FontColor = new Cairo.Color(0.3, 0.0, 0.0);
            groupName.FontFamily = Pango.Weight.Heavy.ToString();
            //groupName.FontColor  = new Cairo.Color(1.0,1.0,1.0);
            //this.FillColor = new Cairo.Color(1.0,1.0,1.0);
            Add(groupName);

            membersStack = new VStackFigure();
            membersStack.Spacing = 8;

            expandHandle = new ToggleButtonHandle(this, new AbsoluteLocator(-10, 7.5));
            expandHandle.Toggled += delegate(object sender, ToggleEventArgs e) {
                if (e.Active) {
                    Add(membersStack);
                }
                else {
                    Remove(membersStack);
                }
            };

            expandHandle.Active = true;
            expandHandle.FillColor = new Cairo.Color(0,0,0.0,0.0);
            expandHandle.Height = 10;
            expandHandle.Width = 10;
        }
示例#3
0
 public TypeFigure(string type)
     : base()
 {
     Spacing = 10.0;
     Header = new TypeHeaderFigure(GetPixBuf(type));
     members = new VStackFigure();
     Add(Header);
 }
        public TypeFigure()
            : base()
        {
            Spacing = 1.5;
            members = new List<MemberFigure> ();
            Header = new HeaderFigure ();
            MemberCompartments = new VStackFigure ();
            expandHandle = new ToggleButtonHandle (this, new AbsoluteLocator (10, 15));
            expandHandle.Toggled += OnToggled;
            SetAttribute (FigureAttribute.Draggable, true);
            SetAttribute (FigureAttribute.Selectable, true);
            grouping = GroupingSetting.Member;
            MembersFormat = MembersFormat.FullSignature;

            Add (Header);
            Add (MemberCompartments);
            Collapsed = true;
        }
示例#5
0
        public TypeFigure()
            : base()
        {
            Spacing = 10.0;
            Header = new TypeHeaderFigure();
            members = new VStackFigure();
            Add(Header);

            expandHandle = new ToggleButtonHandle(this, new AbsoluteLocator(10, 20));
            expandHandle.Toggled += delegate(object sender, ToggleEventArgs e) {
                if (e.Active) {
                    Add(members);
                }
                else {
                    Remove(members);
                }
            };
            expandHandle.Active = false;

            CreateGroups();
        }
        public CompartmentFigure(string name)
            : base()
        {
            Spacing = 1;
            Alignment = VStackAlignment.Left;

            _name = name;
            compartmentName = new TextFigure (name);
            compartmentName.Padding = 0;
            compartmentName.FontSize = 10;
            compartmentName.FontColor = new Cairo.Color(0.3, 0.0, 0.0);
            SetAttribute (FigureAttribute.Selectable, true);

            membersStack = new VStackFigure();
            membersStack.Spacing = 2;

            expandHandle = new ToggleButtonHandle (this, new AbsoluteLocator(-10, 7.5));
            expandHandle.Toggled += OnToggled;

            Add (compartmentName);
            Add (membersStack);
            Collapsed = false;
        }
示例#7
0
 protected virtual void AddMemberGroup(VStackFigure group)
 {
     members.Add(group);
 }