public inbox for insight@sourceware.org
 help / color / mirror / Atom feed
From: Roland Schwingel <roland@onevision.com>
To: insight@sourceware.org
Subject: [PATCH] libgui: remove bgerror.tcl script
Date: Thu, 22 Mar 2012 14:37:00 -0000	[thread overview]
Message-ID: <4F6B3917.9080906@onevision.com> (raw)

[-- Attachment #1: Type: text/plain, Size: 569 bytes --]

Hi...

At least since the insight intree supplied tk 8.4 version there is 
bgerror handling script coming with tk. libgui has its own version, 
which is also not so nice than the tk version. The attached patch 
removes it in favor ot the tk version.
As tk 8.4 is anyway (still) the prerequisite for insight this change 
does not harm.

2012-03-22  Roland Schwingel <roland.schwingel@onevision.com>

     * library/Makefile.in: Remove reference to bgerror.tcl.
     * library/tclIndex: Ditto.
     * library/bgerror.tcl: Removed file.

Any comments? Is this ok?

Roland

[-- Attachment #2: libgui_delete_bgerror.patch --]
[-- Type: text/plain, Size: 3535 bytes --]

diff -ruN libgui_orig/library/Makefile.in libgui/library/Makefile.in
--- libgui_orig/library/Makefile.in	2010-02-22 16:26:07.000000000 +0100
+++ libgui/library/Makefile.in	2012-03-22 14:36:51.752537700 +0100
@@ -203,7 +203,7 @@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
 AUTOMAKE_OPTIONS = cygnus
-TCL = advice.tcl balloon.tcl bbox.tcl bgerror.tcl bindings.tcl \
+TCL = advice.tcl balloon.tcl bbox.tcl bindings.tcl \
 canvas.tcl cframe.tcl center.tcl debug.tcl def.tcl internet.tcl	\
 font.tcl gensym.tcl gettext.tcl hooks.tcl lframe.tcl list.tcl \
 looknfeel.tcl menu.tcl mono.tcl multibox.tcl parse_args.tcl path.tcl \
diff -ruN libgui_orig/library/bgerror.tcl libgui/library/bgerror.tcl
--- libgui_orig/library/bgerror.tcl	2001-09-09 00:34:46.000000000 +0200
+++ libgui/library/bgerror.tcl	1970-01-01 01:00:00.000000000 +0100
@@ -1,64 +0,0 @@
-# bgerror.tcl - Send bug report in response to uncaught Tcl error.
-# Copyright (C) 1997, 1998, 1999 Cygnus Solutions.
-# Written by Tom Tromey <tromey@cygnus.com>.
-
-proc bgerror err {
-  global errorInfo errorCode
-
-  set info $errorInfo
-  set code $errorCode
-
-  # log the error to the debug window or file
-  dbug E $info
-  dbug E $code
-
-  set command [list tk_dialog .bgerrorDialog [gettext "GDB Error"] \
-		 [format [gettext "Error: %s"] $err] \
-		 error 0 [gettext "OK"]]
-  lappend command [gettext "Stack Trace"]
-  
-  
-  set value [eval $command]
-  if {$value == 0} {
-    return
-  }
-
-  set w .bgerrorTrace
-  catch {destroy $w}
-  toplevel $w -class ErrorTrace
-  wm minsize $w 1 1
-  wm title $w "Stack Trace for Error"
-  wm iconname $w "Stack Trace"
-  button $w.ok -text OK -command "destroy $w" -default active
-  text $w.text -relief sunken -bd 2 -yscrollcommand "$w.scroll set" \
-    -setgrid true -width 60 -height 20
-  scrollbar $w.scroll -relief sunken -command "$w.text yview"
-  pack $w.ok -side bottom -padx 3m -pady 2m
-  pack $w.scroll -side right -fill y
-  pack $w.text -side left -expand yes -fill both
-  $w.text insert 0.0 "errorCode is $errorCode"
-  $w.text insert 0.0 $info
-  $w.text mark set insert 0.0
-
-  bind $w <Return> "destroy $w"
-  bind $w.text <Return> "destroy $w; break"
-
-  # Center the window on the screen.
-
-  wm withdraw $w
-  update idletasks
-  set x [expr [winfo screenwidth $w]/2 - [winfo reqwidth $w]/2 \
-	   - [winfo vrootx [winfo parent $w]]]
-  set y [expr [winfo screenheight $w]/2 - [winfo reqheight $w]/2 \
-	   - [winfo vrooty [winfo parent $w]]]
-  wm geom $w +$x+$y
-  wm deiconify $w
-
-  # Be sure to release any grabs that might be present on the
-  # screen, since they could make it impossible for the user
-  # to interact with the stack trace.
-
-  if {[grab current .] != ""} {
-    grab release [grab current .]
-  }
-}
diff -ruN libgui_orig/library/tclIndex libgui/library/tclIndex
--- libgui_orig/library/tclIndex	2002-12-04 00:03:16.000000000 +0100
+++ libgui/library/tclIndex	2012-03-22 13:15:53.438502700 +0100
@@ -18,7 +18,6 @@
 set auto_index(BALLOON_command_variable) [list source [file join $dir balloon.tcl]]
 set auto_index(balloon) [list source [file join $dir balloon.tcl]]
 set auto_index(standard_button_box) [list source [file join $dir bbox.tcl]]
-set auto_index(bgerror) [list source [file join $dir bgerror.tcl]]
 set auto_index(bind_widget_after_tag) [list source [file join $dir bindings.tcl]]
 set auto_index(bind_widget_after_class) [list source [file join $dir bindings.tcl]]
 set auto_index(bind_plain_key) [list source [file join $dir bindings.tcl]]

             reply	other threads:[~2012-03-22 14:37 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-03-22 14:37 Roland Schwingel [this message]
2012-03-29 23:16 ` Keith Seitz
2012-03-30 10:01 Roland Schwingel

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4F6B3917.9080906@onevision.com \
    --to=roland@onevision.com \
    --cc=insight@sourceware.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).