public MemberFigure(Gdk.Pixbuf icon, IMember memberInfo, bool hidden) : base() { this.icon = new ImageFigure (icon); if (memberInfo.ReturnType != null) retval = new TextFigure (memberInfo.ReturnType.Name); else retval = new TextFigure (String.Empty); name = new TextFigure (memberInfo.Name); MemberInfo = memberInfo; Visible = !hidden; name.Padding = 1.0; name.FontSize = 10; retval.Padding = 0; retval.FontSize = 10; retval.FontColor = new Cairo.Color(0, 0, 1.0); AllowFormatting = true; Alignment = HStackAlignment.Bottom; SetAttribute (FigureAttribute.Selectable, true); Add (this.icon); Add (retval); Add (name); }
// For testing purposes public MemberFigure(Gdk.Pixbuf icon, string name, string retval, bool hidden) { this.icon = new ImageFigure (icon); this.name = new TextFigure (name); this.retval = new TextFigure (retval); this.name.Padding = 2.0; this.name.FontSize = 10; this.retval.Padding = 0.0; this.retval.FontSize = 10; this.retval.FontColor = new Cairo.Color(0, 0, 1.0); Visible = !hidden; AllowFormatting = true; Alignment = HStackAlignment.Bottom; Add (this.icon); Add (this.retval); Add (this.name); }