public ExceptionCaughtWidget(ExceptionInfo exception)
        {
            this.Build();

            vboxExceptionInfo.Remove(labelMessage);
            var frame = new InfoFrame(labelMessage);

            frame.Show();
            vboxExceptionInfo.PackStart(frame, false, true, 0);

            stackStore      = new TreeStore(typeof(string), typeof(string), typeof(int), typeof(int));
            treeStack.Model = stackStore;
            var crt = new CellRendererText();

            crt.Ellipsize = Pango.EllipsizeMode.End;
            crt.WrapWidth = -1;
            treeStack.AppendColumn("", crt, "markup", 0);
            treeStack.ShowExpanders = false;
            treeStack.RulesHint     = true;

            valueView.AllowExpanding = true;
            valueView.Frame          = DebuggingService.CurrentFrame;
            this.exception           = exception;

            exception.Changed       += HandleExceptionChanged;
            treeStack.SizeAllocated += (object o, SizeAllocatedArgs args) => crt.WrapWidth = args.Allocation.Width;

            Fill();
            treeStack.RowActivated += HandleRowActivated;
        }
		public ExceptionCaughtWidget (ExceptionInfo exception)
		{
			this.Build ();

			vboxExceptionInfo.Remove (labelMessage);
			var frame = new InfoFrame (labelMessage);
			frame.Show ();
			vboxExceptionInfo.PackStart (frame, false, true, 0);

			stackStore = new TreeStore (typeof(string), typeof(string), typeof(int), typeof(int));
			treeStack.Model = stackStore;
			var crt = new CellRendererText ();
			crt.Ellipsize = Pango.EllipsizeMode.End;
			crt.WrapWidth = -1;
			treeStack.AppendColumn ("", crt, "markup", 0);
			treeStack.ShowExpanders = false;
			treeStack.RulesHint = true;
			
			valueView.AllowExpanding = true;
			valueView.Frame = DebuggingService.CurrentFrame;
			this.exception = exception;
			
			exception.Changed += HandleExceptionChanged;
			treeStack.SizeAllocated += (object o, SizeAllocatedArgs args) => crt.WrapWidth = args.Allocation.Width;
			
			Fill ();
			treeStack.RowActivated += HandleRowActivated;
		}
示例#3
0
        Widget CreateExceptionInfoHeader()
        {
            ExceptionMessageLabel = new Label {
                UseMarkup = true, Selectable = true, Wrap = true, WidthRequest = 500, Xalign = 0.0f, Yalign = 0.0f
            };
            ExceptionTypeLabel = new Label {
                UseMarkup = true, Xalign = 0.0f
            };

            ExceptionMessageLabel.Show();
            ExceptionTypeLabel.Show();

            var alignment = new Alignment(0.0f, 0.0f, 0.0f, 0.0f);

            alignment.Child       = ExceptionMessageLabel;
            alignment.BorderWidth = 6;
            alignment.Show();

            var frame = new InfoFrame(alignment);

            frame.Show();

            var vbox = new VBox(false, 12);

            vbox.PackStart(ExceptionTypeLabel, false, true, 0);
            vbox.PackStart(frame, true, true, 0);
            vbox.Show();

            return(vbox);
        }
		Widget CreateExceptionInfoHeader ()
		{
			ExceptionMessageLabel = new Label () { Selectable = true, Wrap = true, WidthRequest = 500, Xalign = 0.0f };
			ExceptionTypeLabel = new Label () { UseMarkup = true, Xalign = 0.0f };

			ExceptionMessageLabel.Show ();
			ExceptionTypeLabel.Show ();

			var frame = new InfoFrame (ExceptionMessageLabel);
			frame.Show ();

			var vbox = new VBox (false, 6);
			vbox.PackStart (ExceptionTypeLabel, false, true, 0);
			vbox.PackStart (frame, true, true, 0);
			vbox.Show ();

			return vbox;
		}
		Widget CreateExceptionInfoHeader ()
		{
			ExceptionMessageLabel = new Label () { UseMarkup = true, Selectable = true, Wrap = true, WidthRequest = 500, Xalign = 0.0f, Yalign = 0.0f };
			ExceptionTypeLabel = new Label () { UseMarkup = true, Xalign = 0.0f };

			ExceptionMessageLabel.Show ();
			ExceptionTypeLabel.Show ();

			var alignment = new Alignment (0.0f, 0.0f, 0.0f, 0.0f);
			alignment.Child = ExceptionMessageLabel;
			alignment.BorderWidth = 6;
			alignment.Show ();

			var frame = new InfoFrame (alignment);
			frame.Show ();

			var vbox = new VBox (false, 12);
			vbox.PackStart (ExceptionTypeLabel, false, true, 0);
			vbox.PackStart (frame, true, true, 0);
			vbox.Show ();

			return vbox;
		}