summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJason Molenda <jmolenda@apple.com>2000-02-07 00:19:29 +0000
committerJason Molenda <jmolenda@apple.com>2000-02-07 00:19:29 +0000
commita44117a86b0b18d788522dac573da385a11b2f3b (patch)
tree66735f66a5f2396abb4502fa50ebd4db52f7be5d
parent1ee8fbc74feb22b051cd538cac11ac6a7c5121ab (diff)
downloadgdb-a44117a86b0b18d788522dac573da385a11b2f3b.tar.gz
import insight-2000-02-04 snapshot (2nd try)
-rw-r--r--gdb/ChangeLog5
-rw-r--r--gdb/ChangeLog-997
-rw-r--r--gdb/MAINTAINERS2
-rw-r--r--gdb/Makefile.in111
-rwxr-xr-xgdb/configure997
-rw-r--r--gdb/configure.in162
-rw-r--r--gdb/doc/ChangeLog4
-rw-r--r--gdb/doc/Makefile.in13
-rw-r--r--gdb/doc/gdbgui.texinfo411
-rw-r--r--gdb/gdbtk/ChangeLog-gdbtk7
-rw-r--r--gdb/gdbtk/README.GDBTK403
-rw-r--r--gdb/gdbtk/generic/ChangeLog-gdbtk2655
-rw-r--r--gdb/gdbtk/generic/gdbtk-cmds.c3898
-rw-r--r--gdb/gdbtk/generic/gdbtk-hooks.c592
-rw-r--r--gdb/gdbtk/generic/gdbtk-variable.c2417
-rw-r--r--gdb/gdbtk/generic/gdbtk-varobj.c298
-rw-r--r--gdb/gdbtk/generic/gdbtk-wrapper.c629
-rw-r--r--gdb/gdbtk/generic/gdbtk-wrapper.h85
-rw-r--r--gdb/gdbtk/generic/gdbtk.c449
-rw-r--r--gdb/gdbtk/generic/gdbtk.h65
-rw-r--r--gdb/gdbtk/library/ChangeLog6074
-rw-r--r--gdb/gdbtk/library/Makefile6
-rw-r--r--gdb/gdbtk/library/about.tcl11
-rw-r--r--gdb/gdbtk/library/actiondlg.tcl112
-rw-r--r--gdb/gdbtk/library/attachdlg.itb130
-rw-r--r--gdb/gdbtk/library/attachdlg.ith4
-rw-r--r--gdb/gdbtk/library/blockframe.itb40
-rw-r--r--gdb/gdbtk/library/blockframe.ith6
-rw-r--r--gdb/gdbtk/library/bpwin.itb259
-rw-r--r--gdb/gdbtk/library/bpwin.ith17
-rw-r--r--gdb/gdbtk/library/browserwin.itb900
-rw-r--r--gdb/gdbtk/library/browserwin.ith29
-rw-r--r--gdb/gdbtk/library/console.itb299
-rw-r--r--gdb/gdbtk/library/console.ith30
-rw-r--r--gdb/gdbtk/library/data.itb48
-rw-r--r--gdb/gdbtk/library/data.ith42
-rw-r--r--gdb/gdbtk/library/debugwin.itb160
-rw-r--r--gdb/gdbtk/library/debugwin.ith18
-rw-r--r--gdb/gdbtk/library/download.itb102
-rw-r--r--gdb/gdbtk/library/download.ith12
-rw-r--r--gdb/gdbtk/library/embeddedwin.ith8
-rw-r--r--gdb/gdbtk/library/gdbwin.ith13
-rw-r--r--gdb/gdbtk/library/globalpref.itb380
-rw-r--r--gdb/gdbtk/library/globalpref.ith38
-rw-r--r--gdb/gdbtk/library/help/browser.html127
-rw-r--r--gdb/gdbtk/library/help/debug.html58
-rw-r--r--gdb/gdbtk/library/help/help.html18
-rw-r--r--gdb/gdbtk/library/help/images/index.gifbin0 -> 11645 bytes
-rw-r--r--gdb/gdbtk/library/help/index.html78
-rw-r--r--gdb/gdbtk/library/help/locals.html95
-rw-r--r--gdb/gdbtk/library/help/memory.html6
-rw-r--r--gdb/gdbtk/library/help/reg_pref.html20
-rw-r--r--gdb/gdbtk/library/help/register.html126
-rw-r--r--gdb/gdbtk/library/help/source.html10
-rw-r--r--gdb/gdbtk/library/help/target.html57
-rw-r--r--gdb/gdbtk/library/help/trace/locals.html4
-rw-r--r--gdb/gdbtk/library/help/trace/watch.html2
-rw-r--r--gdb/gdbtk/library/help/watch.html115
-rw-r--r--gdb/gdbtk/library/helpviewer.itb286
-rw-r--r--gdb/gdbtk/library/helpviewer.ith97
-rw-r--r--gdb/gdbtk/library/images/back.gifbin0 -> 136 bytes
-rw-r--r--gdb/gdbtk/library/images/build.gifbin0 -> 177 bytes
-rw-r--r--gdb/gdbtk/library/images/cygnus.gifbin0 -> 11996 bytes
-rw-r--r--gdb/gdbtk/library/images/file.gifbin0 -> 707 bytes
-rw-r--r--gdb/gdbtk/library/images/fore.gifbin0 -> 149 bytes
-rw-r--r--gdb/gdbtk/library/images/gdbtk.gifbin0 -> 22247 bytes
-rw-r--r--gdb/gdbtk/library/images/insight.gifbin7573 -> 17189 bytes
-rw-r--r--gdb/gdbtk/library/images/opt.gifbin0 -> 1198 bytes
-rw-r--r--gdb/gdbtk/library/images/tools.gifbin0 -> 2526 bytes
-rw-r--r--gdb/gdbtk/library/images/tools2_3d.gifbin0 -> 687 bytes
-rw-r--r--gdb/gdbtk/library/images/vmake.gifbin0 -> 152 bytes
-rw-r--r--gdb/gdbtk/library/images2/back.gifbin0 -> 138 bytes
-rw-r--r--gdb/gdbtk/library/images2/build.gifbin0 -> 181 bytes
-rw-r--r--gdb/gdbtk/library/images2/cygnus.gifbin0 -> 11996 bytes
-rw-r--r--gdb/gdbtk/library/images2/file.gifbin0 -> 1536 bytes
-rw-r--r--gdb/gdbtk/library/images2/fore.gifbin0 -> 147 bytes
-rw-r--r--gdb/gdbtk/library/images2/gdbtk.gifbin0 -> 22247 bytes
-rw-r--r--gdb/gdbtk/library/images2/insight.gifbin7573 -> 17189 bytes
-rw-r--r--gdb/gdbtk/library/images2/load.gifbin0 -> 125 bytes
-rw-r--r--gdb/gdbtk/library/images2/opt.gifbin0 -> 541 bytes
-rw-r--r--gdb/gdbtk/library/images2/tools.gifbin0 -> 2526 bytes
-rw-r--r--gdb/gdbtk/library/images2/tools2_3d.gifbin0 -> 687 bytes
-rw-r--r--gdb/gdbtk/library/images2/vmake.gifbin0 -> 152 bytes
-rw-r--r--gdb/gdbtk/library/interface.tcl590
-rw-r--r--gdb/gdbtk/library/kod.itb75
-rw-r--r--gdb/gdbtk/library/kod.ith18
-rw-r--r--gdb/gdbtk/library/locals.tcl265
-rw-r--r--gdb/gdbtk/library/main.tcl117
-rw-r--r--gdb/gdbtk/library/managedwin.itb286
-rw-r--r--gdb/gdbtk/library/managedwin.ith96
-rw-r--r--gdb/gdbtk/library/mempref.itb91
-rw-r--r--gdb/gdbtk/library/mempref.ith5
-rw-r--r--gdb/gdbtk/library/memwin.itb455
-rw-r--r--gdb/gdbtk/library/memwin.ith21
-rw-r--r--gdb/gdbtk/library/modal.tcl6
-rw-r--r--gdb/gdbtk/library/prefs.tcl573
-rw-r--r--gdb/gdbtk/library/process.itb91
-rw-r--r--gdb/gdbtk/library/process.ith23
-rw-r--r--gdb/gdbtk/library/regwin.itb1386
-rw-r--r--gdb/gdbtk/library/regwin.ith127
-rw-r--r--gdb/gdbtk/library/srcbar.tcl643
-rw-r--r--gdb/gdbtk/library/srcpref.itb140
-rw-r--r--gdb/gdbtk/library/srcpref.ith18
-rw-r--r--gdb/gdbtk/library/srctextwin.itb736
-rw-r--r--gdb/gdbtk/library/srctextwin.ith25
-rw-r--r--gdb/gdbtk/library/srcwin.itb490
-rw-r--r--gdb/gdbtk/library/srcwin.ith34
-rw-r--r--gdb/gdbtk/library/stackwin.itb96
-rw-r--r--gdb/gdbtk/library/stackwin.ith16
-rw-r--r--gdb/gdbtk/library/targetselection.itb233
-rw-r--r--gdb/gdbtk/library/targetselection.ith8
-rw-r--r--gdb/gdbtk/library/tclIndex269
-rw-r--r--gdb/gdbtk/library/tdump.tcl78
-rw-r--r--gdb/gdbtk/library/tfind_args.tcl2
-rw-r--r--gdb/gdbtk/library/toolbar.tcl845
-rw-r--r--gdb/gdbtk/library/toplevelwin.ith4
-rw-r--r--gdb/gdbtk/library/tracedlg.tcl209
-rw-r--r--gdb/gdbtk/library/util.tcl179
-rw-r--r--gdb/gdbtk/library/variables.tcl959
-rw-r--r--gdb/gdbtk/library/warning.tcl6
-rw-r--r--gdb/gdbtk/library/watch.tcl236
-rw-r--r--gdb/main.c39
-rw-r--r--gdb/testsuite/ChangeLog91
-rwxr-xr-xgdb/testsuite/configure36
-rw-r--r--gdb/testsuite/configure.in32
-rw-r--r--gdb/testsuite/gdb.gdbtk/ChangeLog-gdbtk83
-rw-r--r--gdb/testsuite/gdb.gdbtk/Makefile.in7
-rw-r--r--gdb/testsuite/gdb.gdbtk/browser.exp20
-rw-r--r--gdb/testsuite/gdb.gdbtk/browser.test77
-rw-r--r--gdb/testsuite/gdb.gdbtk/c_variable.c2
-rw-r--r--gdb/testsuite/gdb.gdbtk/c_variable.exp18
-rw-r--r--gdb/testsuite/gdb.gdbtk/c_variable.test165
-rw-r--r--gdb/testsuite/gdb.gdbtk/configure2378
-rw-r--r--gdb/testsuite/gdb.gdbtk/configure.in14
-rw-r--r--gdb/testsuite/gdb.gdbtk/console.exp18
-rw-r--r--gdb/testsuite/gdb.gdbtk/console.test77
-rw-r--r--gdb/testsuite/gdb.gdbtk/cpp_variable.exp58
-rw-r--r--gdb/testsuite/gdb.gdbtk/cpp_variable.test116
-rw-r--r--gdb/testsuite/gdb.gdbtk/defs96
-rw-r--r--gdb/testsuite/gdb.gdbtk/simple.c5
-rw-r--r--gdb/testsuite/gdb.gdbtk/srcwin.exp52
-rw-r--r--gdb/testsuite/gdb.gdbtk/srcwin.test247
-rw-r--r--gdb/testsuite/gdb.gdbtk/srcwin2.test135
-rw-r--r--gdb/testsuite/gdb.gdbtk/srcwin3.test81
-rw-r--r--gdb/testsuite/gdb.gdbtk/stack1.c2
-rw-r--r--gdb/testsuite/lib/gdb.exp101
-rw-r--r--gdb/v850ice.c29
-rw-r--r--itcl/itcl/unix/confdefs.h1
-rw-r--r--itcl/itcl/unix/config.log12
-rw-r--r--tk/doc/tk4.0.ps4602
-rw-r--r--tk/library/prolog.ps284
-rw-r--r--tk/library/tkfboxTest.tcl1666
-rw-r--r--tk/mac/tkMacProjects.sit.hqx2534
-rw-r--r--tk/mac/tkMacProlog.c61
-rw-r--r--tk/tests/all73
-rw-r--r--tk/tests/defs371
-rw-r--r--tk/tests/script14
-rw-r--r--tk/tests/visual81
-rw-r--r--tk/unix/porting.notes86
-rw-r--r--tk/win/Defines.h5175
160 files changed, 40408 insertions, 11029 deletions
diff --git a/gdb/ChangeLog b/gdb/ChangeLog
index c2c53f21290..4d68fd71b92 100644
--- a/gdb/ChangeLog
+++ b/gdb/ChangeLog
@@ -22,6 +22,11 @@ Fri Feb 4 22:42:36 2000 Andrew Cagney <cagney@b1.cygnus.com>
* Makefile.in (INIT_FILES): Append CONFIG_INITS
* configure.in (CONFIG_INIT): Initialize.
+ (links): Link srcdir/gdbtk/library to gdbtcl2.
+ * gdbtcl2: Moved to gdbtk/library.
+ ChangeLog-gdbtk, gdbtk-cmds.c, gdbtk-hooks.c, gdbtk-variable.c,
+ gdbtk-varobj.c, gdbtk-wrapper.c, gdbtk-wrapper.h, gdbtk.c,
+ gdbtk.h: Moved to gdbtk/generic.
2000-02-03 Elena Zannoni <ezannoni@kwikemart.cygnus.com>
diff --git a/gdb/ChangeLog-99 b/gdb/ChangeLog-99
index 2fc778b652a..b82a88d5521 100644
--- a/gdb/ChangeLog-99
+++ b/gdb/ChangeLog-99
@@ -3209,6 +3209,9 @@ Sat Sep 18 07:13:03 1999 Jeffrey A Law (law@cygnus.com)
1999-09-17 Fernando Nasser <fnasser@totem.to.cygnus.com>
* Makefile.in: Add entries for varobj.[cho] and wrapper.[cho].
+ gdbtk-varobj.[co]. gdbtk-varobj.o is not yet on the COMMON_OBS
+ list because it conflicts with the older gdbtk-variable.o which
+ is still the default.
1999-09-17 Fernando Nasser <fnasser@totem.to.cygnus.com>
@@ -3368,6 +3371,8 @@ Tue Sep 14 14:34:28 1999 Andrew Cagney <cagney@b1.cygnus.com>
* defs.h (continuation): Make this a typedef.
+ * Makefile.in (gdbtk.o, gdbtk-cmds.o): Depend on $(top_h).
+
* Makefile.in (i386-linux-nat.o): Depend on symfile.h, not
$(symfile_h); the latter has no definition.
@@ -3411,6 +3416,8 @@ Tue Sep 14 14:34:28 1999 Andrew Cagney <cagney@b1.cygnus.com>
__dld_break, which contains the permanent breakpoint, when interesting
things happen. Tell GDB that the breakpoint in __dld_break is
permanent.
+ * gdbtk-cmds.c (gdb_get_breakpoint_info): Report a permanent
+ breakpoint as enabled.
* infrun.c (SKIP_PERMANENT_BREAKPOINT): Provide default definition.
(default_skip_permanent_breakpoint): New function.
(resume): If we're trying to resume at a permanent breakpoint, use
diff --git a/gdb/MAINTAINERS b/gdb/MAINTAINERS
index ef02b907400..7da82dd9124 100644
--- a/gdb/MAINTAINERS
+++ b/gdb/MAINTAINERS
@@ -20,6 +20,8 @@ x86 linux native Jim Blandy jimb@cygnus.com
Scheme support Jim Blandy jimb@cygnus.com
svr4 shlibs (solib.c) Jim Blandy jimb@cygnus.com
arm target Jim Ingham jingham@cygnus.com
+gdbtk (c & tcl) Jim Ingham jingham@cygnus.com
+libgui (w/foundry, sn) Jim Ingham jingham@cygnus.com
hurd native Mark Kettenis kettenis@wins.va.nl
hpux, hp pa native Jeff Law law@cygnus.com
m32r target Michael Snyder msnyder@cygnus.com
diff --git a/gdb/Makefile.in b/gdb/Makefile.in
index 775067c760e..034cafa69d8 100644
--- a/gdb/Makefile.in
+++ b/gdb/Makefile.in
@@ -158,6 +158,47 @@ SIM =
WIN32LIBS = @WIN32LIBS@
+# Where is the TCL library? Typically in ../tcl.
+LIB_INSTALL_DIR = $(libdir)
+# This variable is needed when doing dynamic linking.
+LIB_RUNTIME_DIR = $(libdir)
+TCL = @TCL_LD_SEARCH_FLAGS@ @TCL_BUILD_LIB_SPEC@
+TCL_CFLAGS = @TCLHDIR@
+TCL_DEPS =
+GDBTKLIBS = @GDBTKLIBS@
+# Extra flags that the GDBTK files need:
+GDBTK_CFLAGS = @GDBTK_CFLAGS@
+
+# Where is the TK library? Typically in ../tk.
+TK = @TK_BUILD_LIB_SPEC@
+TK_CFLAGS = @TKHDIR@ @TK_BUILD_INCLUDES@
+TK_DEPS =
+
+# Where is Itcl? Typically in ../itcl/itcl.
+ITCL_CFLAGS = @ITCLHDIR@
+ITCL = @ITCLLIB@
+ITCL_DEPS = @ITCL_DEPS@
+
+# Where is Itk? Typically in ../itcl/itk.
+ITK_CFLAGS = @ITKHDIR@
+ITK = @ITKLIB@
+ITK_DEPS = @ITK_DEPS@
+
+# Where is Tix? Typically in ../tix.
+TIX_CFLAGS = @TIXHDIR@
+TIX = @TIXLIB@
+TIX_DEPS = @TIX_DEPS@
+
+X11_CFLAGS = @TK_XINCLUDES@
+X11_LDFLAGS =
+X11_LIBS =
+
+WIN32LDAPP = @WIN32LDAPP@
+
+ENABLE_GDBTK= @ENABLE_GDBTK@
+LIBGUI = @LIBGUI@
+GUI_CFLAGS_X = @GUI_CFLAGS_X@
+IDE_CFLAGS=$(GUI_CFLAGS_X) $(IDE_CFLAGS_X)
ENABLE_CFLAGS= @ENABLE_CFLAGS@
@@ -390,6 +431,7 @@ SFILES = ax-general.c ax-gdb.c bcache.c blockframe.c breakpoint.c \
kod.c kod-cisco.c \
ui-out.c cli-out.c \
varobj.c wrapper.c \
+ gdbtk-varobj.c \
jv-exp.y jv-lang.c jv-valprint.c jv-typeprint.c \
m2-exp.y m2-lang.c m2-typeprint.c m2-valprint.c main.c maint.c \
mem-break.c minsyms.c mipsread.c nlmread.c objfiles.c parse.c \
@@ -609,6 +651,18 @@ install-only:
fi ; \
$(INSTALL_PROGRAM) gdb$(EXEEXT) $(bindir)/$$transformed_name$(EXEEXT) ; \
$(INSTALL_DATA) $(srcdir)/gdb.1 $(man1dir)/$$transformed_name.1
+ $(SHELL) $(srcdir)/../mkinstalldirs $(datadir)/gdbtcl ; \
+ $(SHELL) $(srcdir)/../mkinstalldirs \
+ $(datadir)/gdbtcl/images \
+ $(datadir)/gdbtcl/images2 ; \
+ $(SHELL) $(srcdir)/../mkinstalldirs $(datadir)/gdbtcl/help \
+ $(datadir)/gdbtcl/help/images \
+ $(datadir)/gdbtcl/help/trace ; \
+ cd $(srcdir)/gdbtk/library ; \
+ for i in *.tcl *.ith *.itb images/*.gif images2/*.gif images/icons.txt images2/icons.txt tclIndex help/*.html help/trace/*.html help/trace/index.toc help/images/*.gif; \
+ do \
+ $(INSTALL_DATA) $$i $(datadir)/gdbtcl/$$i ; \
+ done ;
@$(MAKE) DO=install "DODIRS=$(SUBDIRS)" $(FLAGS_TO_PASS) subdir_do
uninstall: force
@@ -620,6 +674,7 @@ uninstall: force
true ; \
fi ; \
rm -f $(bindir)/$$transformed_name$(EXEEXT) $(man1dir)/$$transformed_name.1
+ rm -rf $(datadir)/gdbtcl
@$(MAKE) DO=uninstall "DODIRS=$(SUBDIRS)" $(FLAGS_TO_PASS) subdir_do
# We do this by grepping through sources. If that turns out to be too slow,
@@ -1170,6 +1225,62 @@ findvar.o: findvar.c $(defs_h) $(gdbcore_h) $(inferior_h) target.h \
fork-child.o: fork-child.c $(wait_h) $(defs_h) $(gdbcore_h) \
$(inferior_h) target.h terminal.h gdbthread.h gdb_string.h
+gdbres.o: $(srcdir)/gdbtk/gdb.rc $(srcdir)/gdbtk/gdbtool.ico
+ $(WINDRES) --include $(srcdir)/gdbtk $(srcdir)/gdbtk/gdb.rc gdbres.o
+
+gdbtk.o: $(srcdir)/gdbtk/generic/gdbtk.c \
+ $(srcdir)/gdbtk/generic/gdbtk.h $(defs_h) \
+ $(symtab_h) $(inferior_h) $(command_h) \
+ $(bfd_h) symfile.h objfiles.h target.h gdb_string.h $(tracepoint_h) \
+ $(top_h)
+ $(CC) -c $(INTERNAL_CFLAGS) $(IDE_CFLAGS) $(ITCL_CFLAGS) \
+ $(ITK_CFLAGS) $(TIX_CFLAGS) \
+ $(TCL_CFLAGS) $(TK_CFLAGS) $(X11_CFLAGS) $(GDBTK_CFLAGS)\
+ $(srcdir)/gdbtk/generic/gdbtk.c -DGDBTK_LIBRARY=\"$(datadir)/gdbtcl\"
+
+gdbtk-cmds.o: $(srcdir)/gdbtk/generic/gdbtk-cmds.c \
+ $(srcdir)/gdbtk/generic/gdbtk.h \
+ $(defs_h) $(symtab_h) $(inferior_h) \
+ $(command_h) $(bfd_h) $(top_h) symfile.h objfiles.h target.h \
+ gdb_string.h $(tracepoint_h) $(frame_h) source.h
+ $(CC) -c $(INTERNAL_CFLAGS) $(IDE_CFLAGS) $(ITCL_CFLAGS) \
+ $(TIX_CFLAGS) $(TCL_CFLAGS) $(TK_CFLAGS) $(X11_CFLAGS) \
+ $(GDBTK_CFLAGS) $(srcdir)/gdbtk/generic/gdbtk-cmds.c \
+ -DGDBTK_LIBRARY=\"$(datadir)/gdbtcl\"
+
+gdbtk-hooks.o: $(srcdir)/gdbtk/generic/gdbtk-hooks.c \
+ $(srcdir)/gdbtk/generic/gdbtk.h $(defs_h) \
+ $(symtab_h) $(inferior_h) $(command_h) \
+ $(bfd_h) symfile.h objfiles.h target.h gdb_string.h $(tracepoint_h)
+ $(CC) -c $(INTERNAL_CFLAGS) $(IDE_CFLAGS) $(ITCL_CFLAGS) $(TIX_CFLAGS) \
+ $(TCL_CFLAGS) $(TK_CFLAGS) $(X11_CFLAGS) $(GDBTK_CFLAGS)\
+ $(srcdir)/gdbtk/generic/gdbtk-hooks.c -DGDBTK_LIBRARY=\"$(datadir)/gdbtcl\"
+
+gdbtk-variable.o: $(srcdir)/gdbtk/generic/gdbtk-variable.c \
+ $(srcdir)/gdbtk/generic/gdbtk.h $(srcdir)/gdbtk/generic/gdbtk-wrapper.h
+ $(CC) -c $(INTERNAL_CFLAGS) $(IDE_CFLAGS) $(ITCL_CFLAGS) $(TIX_CFLAGS) \
+ $(TCL_CFLAGS) $(TK_CFLAGS) $(X11_CFLAGS) $(GDBTK_CFLAGS)\
+ $(srcdir)/gdbtk/generic/gdbtk-variable.c
+
+gdbtk-varobj.o: $(srcdir)/gdbtk/generic/gdbtk-varobj.c \
+ $(srcdir)/gdbtk/generic/gdbtk.h \
+ $(defs_h) $(value_h) varobj.h
+ $(CC) -c $(INTERNAL_CFLAGS) $(IDE_CFLAGS) $(ITCL_CFLAGS) $(TIX_CFLAGS) \
+ $(TCL_CFLAGS) $(TK_CFLAGS) $(X11_CFLAGS) $(GDBTK_CFLAGS)\
+ $(srcdir)/gdbtk/generic/gdbtk-varobj.c
+
+gdbtk-wrapper.o: $(srcdir)/gdbtk/generic/gdbtk-wrapper.c \
+ $(srcdir)/gdbtk/generic/gdbtk-wrapper.h
+ $(CC) -c $(INTERNAL_CFLAGS) $(IDE_CFLAGS) $(GDBTK_CFLAGS)\
+ $(srcdir)/gdbtk/generic/gdbtk-wrapper.c
+
+v850ice.o: v850ice.c $(defs_h) $(symtab_h) $(inferior_h) $(command_h) \
+ $(frame_h) $(breakpoint_h) $(gdbcore_h) $(value_h) symfile.h \
+ gdb_string.h target.h objfiles.h
+ $(CC) -c $(INTERNAL_CFLAGS) $(IDE_CFLAGS) $(ITCL_CFLAGS) $(TIX_CFLAGS) \
+ $(TCL_CFLAGS) $(TK_CFLAGS) $(X11_CFLAGS) $(GDBTK_CFLAGS)\
+ $(srcdir)/v850ice.c
+
tracepoint.o: tracepoint.c $(defs_h) $(symtab_h) $(frame_h) $(tracepoint_h) \
$(gdbtypes_h) $(expression_h) $(gdbcmd_h) $(value_h) target.h \
language.h gdb_string.h $(readline_headers) $(remote_h)
diff --git a/gdb/configure b/gdb/configure
index 441911a096e..a53879c6529 100755
--- a/gdb/configure
+++ b/gdb/configure
@@ -5554,6 +5554,10 @@ if test x$gdb_cv_os_cygwin = xyes; then
fi
+LIBGUI="../libgui/src/libgui.a"
+GUI_CFLAGS_X="-I${srcdir}/../libgui/src"
+
+
# Check whether --with-cpu or --without-cpu was given.
if test "${with_cpu+set}" = set; then
@@ -5596,6 +5600,968 @@ fi
+ENABLE_GDBTK=
+
+# Check whether --enable-gdbtk or --disable-gdbtk was given.
+if test "${enable_gdbtk+set}" = set; then
+ enableval="$enable_gdbtk"
+ case "${enableval}" in
+ yes)
+ case "$host" in
+ *go32*)
+ echo "configure: warning: GDB does not support GDBtk on host ${host}. GDBtk will be disabled." 1>&2
+ enable_gdbtk=no ;;
+ *windows*)
+ echo "configure: warning: GDB does not support GDBtk on host ${host}. GDBtk will be disabled." 1>&2
+ enable_gdbtk=no ;;
+ *)
+ enable_gdbtk=yes ;;
+ esac ;;
+ no)
+ enable_gdbtk=no ;;
+ *)
+ { echo "configure: error: bad value ${enableval} given for gdbtk option" 1>&2; exit 1; } ;;
+esac
+else
+
+# Default is on for everything but go32 and Cygwin
+case "$host" in
+ *go32* | *windows*)
+ ;;
+ *)
+ enable_gdbtk=yes ;;
+ esac
+
+fi
+
+
+WIN32LDAPP=
+
+
+
+configdir="unix"
+
+GDBTKLIBS=
+if test "${enable_gdbtk}" = "yes"; then
+
+
+#
+# Ok, lets find the tcl configuration
+# First, look for one uninstalled.
+# the alternative search directory is invoked by --with-tclconfig
+#
+
+if test x"${no_tcl}" = x ; then
+ # we reset no_tcl in case something fails here
+ no_tcl=true
+ # Check whether --with-tclconfig or --without-tclconfig was given.
+if test "${with_tclconfig+set}" = set; then
+ withval="$with_tclconfig"
+ with_tclconfig=${withval}
+fi
+
+ echo $ac_n "checking for Tcl configuration""... $ac_c" 1>&6
+echo "configure:5791: checking for Tcl configuration" >&5
+ if eval "test \"`echo '$''{'ac_cv_c_tclconfig'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+
+
+ # First check to see if --with-tclconfig was specified.
+ if test x"${with_tclconfig}" != x ; then
+ if test -f "${with_tclconfig}/tclConfig.sh" ; then
+ ac_cv_c_tclconfig=`(cd ${with_tclconfig}; pwd)`
+ else
+ { echo "configure: error: ${with_tclconfig} directory doesn't contain tclConfig.sh" 1>&2; exit 1; }
+ fi
+ fi
+
+ # then check for a private Tcl installation
+ if test x"${ac_cv_c_tclconfig}" = x ; then
+ for i in \
+ ../tcl \
+ `ls -dr ../tcl[7-9]* 2>/dev/null` \
+ ../../tcl \
+ `ls -dr ../../tcl[7-9]* 2>/dev/null` \
+ ../../../tcl \
+ `ls -dr ../../../tcl[7-9]* 2>/dev/null` ; do
+ if test -f "$i/${configdir}/tclConfig.sh" ; then
+ ac_cv_c_tclconfig=`(cd $i/${configdir}; pwd)`
+ break
+ fi
+ done
+ fi
+ # check in a few common install locations
+ if test x"${ac_cv_c_tclconfig}" = x ; then
+ for i in `ls -d ${prefix}/lib /usr/local/lib 2>/dev/null` ; do
+ if test -f "$i/tclConfig.sh" ; then
+ ac_cv_c_tclconfig=`(cd $i; pwd)`
+ break
+ fi
+ done
+ fi
+ # check in a few other private locations
+ if test x"${ac_cv_c_tclconfig}" = x ; then
+ for i in \
+ ${srcdir}/../tcl \
+ `ls -dr ${srcdir}/../tcl[7-9]* 2>/dev/null` ; do
+ if test -f "$i/${configdir}/tclConfig.sh" ; then
+ ac_cv_c_tclconfig=`(cd $i/${configdir}; pwd)`
+ break
+ fi
+ done
+ fi
+
+fi
+
+ if test x"${ac_cv_c_tclconfig}" = x ; then
+ TCLCONFIG="# no Tcl configs found"
+ echo "configure: warning: Can't find Tcl configuration definitions" 1>&2
+ else
+ no_tcl=
+ TCLCONFIG=${ac_cv_c_tclconfig}/tclConfig.sh
+ echo "$ac_t""found $TCLCONFIG" 1>&6
+ fi
+fi
+
+ if test -z "${no_tcl}"; then
+
+ . $TCLCONFIG
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+#
+# Ok, lets find the tk configuration
+# First, look for one uninstalled.
+# the alternative search directory is invoked by --with-tkconfig
+#
+
+if test x"${no_tk}" = x ; then
+ # we reset no_tk in case something fails here
+ no_tk=true
+ # Check whether --with-tkconfig or --without-tkconfig was given.
+if test "${with_tkconfig+set}" = set; then
+ withval="$with_tkconfig"
+ with_tkconfig=${withval}
+fi
+
+ echo $ac_n "checking for Tk configuration""... $ac_c" 1>&6
+echo "configure:5899: checking for Tk configuration" >&5
+ if eval "test \"`echo '$''{'ac_cv_c_tkconfig'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+
+
+ # First check to see if --with-tkconfig was specified.
+ if test x"${with_tkconfig}" != x ; then
+ if test -f "${with_tkconfig}/tkConfig.sh" ; then
+ ac_cv_c_tkconfig=`(cd ${with_tkconfig}; pwd)`
+ else
+ { echo "configure: error: ${with_tkconfig} directory doesn't contain tkConfig.sh" 1>&2; exit 1; }
+ fi
+ fi
+
+ # then check for a private Tk library
+ if test x"${ac_cv_c_tkconfig}" = x ; then
+ for i in \
+ ../tk \
+ `ls -dr ../tk[4-9]* 2>/dev/null` \
+ ../../tk \
+ `ls -dr ../../tk[4-9]* 2>/dev/null` \
+ ../../../tk \
+ `ls -dr ../../../tk[4-9]* 2>/dev/null` ; do
+ if test -f "$i/${configdir}/tkConfig.sh" ; then
+ ac_cv_c_tkconfig=`(cd $i/${configdir}; pwd)`
+ break
+ fi
+ done
+ fi
+ # check in a few common install locations
+ if test x"${ac_cv_c_tkconfig}" = x ; then
+ for i in `ls -d ${prefix}/lib /usr/local/lib 2>/dev/null` ; do
+ if test -f "$i/tkConfig.sh" ; then
+ ac_cv_c_tkconfig=`(cd $i; pwd)`
+ break
+ fi
+ done
+ fi
+ # check in a few other private locations
+ if test x"${ac_cv_c_tkconfig}" = x ; then
+ for i in \
+ ${srcdir}/../tk \
+ `ls -dr ${srcdir}/../tk[4-9]* 2>/dev/null` ; do
+ if test -f "$i/${configdir}/tkConfig.sh" ; then
+ ac_cv_c_tkconfig=`(cd $i/${configdir}; pwd)`
+ break
+ fi
+ done
+ fi
+
+fi
+
+ if test x"${ac_cv_c_tkconfig}" = x ; then
+ TKCONFIG="# no Tk configs found"
+ echo "configure: warning: Can't find Tk configuration definitions" 1>&2
+ else
+ no_tk=
+ TKCONFIG=${ac_cv_c_tkconfig}/tkConfig.sh
+ echo "$ac_t""found $TKCONFIG" 1>&6
+ fi
+fi
+
+
+
+ # If $no_tk is nonempty, then we can't do Tk, and there is no
+ # point to doing Tcl.
+ if test -z "${no_tk}"; then
+
+ if test -f "$TKCONFIG" ; then
+ . $TKCONFIG
+ fi
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+#
+# Ok, lets find the tcl source trees so we can use the headers
+# Warning: transition of version 9 to 10 will break this algorithm
+# because 10 sorts before 9. We also look for just tcl. We have to
+# be careful that we don't match stuff like tclX by accident.
+# the alternative search directory is involked by --with-tclinclude
+#
+
+no_tcl=true
+echo $ac_n "checking for Tcl private headers. dir=${configdir}""... $ac_c" 1>&6
+echo "configure:5995: checking for Tcl private headers. dir=${configdir}" >&5
+# Check whether --with-tclinclude or --without-tclinclude was given.
+if test "${with_tclinclude+set}" = set; then
+ withval="$with_tclinclude"
+ with_tclinclude=${withval}
+fi
+
+if eval "test \"`echo '$''{'ac_cv_c_tclh'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+
+# first check to see if --with-tclinclude was specified
+if test x"${with_tclinclude}" != x ; then
+ if test -f ${with_tclinclude}/tclInt.h ; then
+ ac_cv_c_tclh=`(cd ${with_tclinclude}; pwd)`
+ elif test -f ${with_tclinclude}/generic/tclInt.h ; then
+ ac_cv_c_tclh=`(cd ${with_tclinclude}/generic; pwd)`
+ else
+ { echo "configure: error: ${with_tclinclude} directory doesn't contain private headers" 1>&2; exit 1; }
+ fi
+fi
+
+# next check if it came with Tcl configuration file
+if test x"${ac_cv_c_tclconfig}" = x ; then
+ if test -f $ac_cv_c_tclconfig/../generic/tclInt.h ; then
+ ac_cv_c_tclh=`(cd $ac_cv_c_tclconfig/..; pwd)`
+ fi
+fi
+
+# next check in private source directory
+#
+# since ls returns lowest version numbers first, reverse its output
+if test x"${ac_cv_c_tclh}" = x ; then
+ for i in \
+ ${srcdir}/../tcl \
+ `ls -dr ${srcdir}/../tcl[7-9]* 2>/dev/null` \
+ ${srcdir}/../../tcl \
+ `ls -dr ${srcdir}/../../tcl[7-9]* 2>/dev/null` \
+ ${srcdir}/../../../tcl \
+ `ls -dr ${srcdir}/../../../tcl[7-9]* 2>/dev/null ` ; do
+ if test -f $i/generic/tclInt.h ; then
+ ac_cv_c_tclh=`(cd $i/generic; pwd)`
+ break
+ fi
+ done
+fi
+# finally check in a few common install locations
+#
+# since ls returns lowest version numbers first, reverse its output
+if test x"${ac_cv_c_tclh}" = x ; then
+ for i in \
+ `ls -dr /usr/local/src/tcl[7-9]* 2>/dev/null` \
+ `ls -dr /usr/local/lib/tcl[7-9]* 2>/dev/null` \
+ /usr/local/src/tcl \
+ /usr/local/lib/tcl \
+ ${prefix}/include ; do
+ if test -f $i/generic/tclInt.h ; then
+ ac_cv_c_tclh=`(cd $i/generic; pwd)`
+ break
+ fi
+ done
+fi
+# see if one is installed
+if test x"${ac_cv_c_tclh}" = x ; then
+ ac_safe=`echo "tclInt.h" | sed 'y%./+-%__p_%'`
+echo $ac_n "checking for tclInt.h""... $ac_c" 1>&6
+echo "configure:6061: checking for tclInt.h" >&5
+if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ cat > conftest.$ac_ext <<EOF
+#line 6066 "configure"
+#include "confdefs.h"
+#include <tclInt.h>
+EOF
+ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
+{ (eval echo configure:6071: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
+if test -z "$ac_err"; then
+ rm -rf conftest*
+ eval "ac_cv_header_$ac_safe=yes"
+else
+ echo "$ac_err" >&5
+ echo "configure: failed program was:" >&5
+ cat conftest.$ac_ext >&5
+ rm -rf conftest*
+ eval "ac_cv_header_$ac_safe=no"
+fi
+rm -f conftest*
+fi
+if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
+ echo "$ac_t""yes" 1>&6
+ ac_cv_c_tclh=installed
+else
+ echo "$ac_t""no" 1>&6
+ac_cv_c_tclh=""
+fi
+
+fi
+
+fi
+
+if test x"${ac_cv_c_tclh}" = x ; then
+ TCLHDIR="# no Tcl private headers found"
+ { echo "configure: error: Can't find Tcl private headers" 1>&2; exit 1; }
+fi
+if test x"${ac_cv_c_tclh}" != x ; then
+ no_tcl=""
+ if test x"${ac_cv_c_tclh}" = x"installed" ; then
+ echo "$ac_t""is installed" 1>&6
+ TCLHDIR=""
+ else
+ echo "$ac_t""found in ${ac_cv_c_tclh}" 1>&6
+ # this hack is cause the TCLHDIR won't print if there is a "-I" in it.
+ TCLHDIR="-I${ac_cv_c_tclh}"
+ fi
+fi
+
+
+
+
+#
+# Ok, lets find the tk source trees so we can use the headers
+# If the directory (presumably symlink) named "tk" exists, use that one
+# in preference to any others. Same logic is used when choosing library
+# and again with Tcl. The search order is the best place to look first, then in
+# decreasing significance. The loop breaks if the trigger file is found.
+# Note the gross little conversion here of srcdir by cd'ing to the found
+# directory. This converts the path from a relative to an absolute, so
+# recursive cache variables for the path will work right. We check all
+# the possible paths in one loop rather than many seperate loops to speed
+# things up.
+# the alternative search directory is involked by --with-tkinclude
+#
+no_tk=true
+echo $ac_n "checking for Tk private headers""... $ac_c" 1>&6
+echo "configure:6131: checking for Tk private headers" >&5
+# Check whether --with-tkinclude or --without-tkinclude was given.
+if test "${with_tkinclude+set}" = set; then
+ withval="$with_tkinclude"
+ with_tkinclude=${withval}
+fi
+
+if eval "test \"`echo '$''{'ac_cv_c_tkh'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+
+# first check to see if --with-tkinclude was specified
+if test x"${with_tkinclude}" != x ; then
+ if test -f ${with_tkinclude}/tk.h ; then
+ ac_cv_c_tkh=`(cd ${with_tkinclude}; pwd)`
+ elif test -f ${with_tkinclude}/generic/tk.h ; then
+ ac_cv_c_tkh=`(cd ${with_tkinclude}/generic; pwd)`
+ else
+ { echo "configure: error: ${with_tkinclude} directory doesn't contain private headers" 1>&2; exit 1; }
+ fi
+fi
+
+# next check if it came with Tk configuration file
+if test x"${ac_cv_c_tkconfig}" = x ; then
+ if test -f $ac_cv_c_tkconfig/../generic/tk.h ; then
+ ac_cv_c_tkh=`(cd $ac_cv_c_tkconfig/..; pwd)`
+ fi
+fi
+
+# next check in private source directory
+#
+# since ls returns lowest version numbers first, reverse its output
+if test x"${ac_cv_c_tkh}" = x ; then
+ for i in \
+ ${srcdir}/../tk \
+ `ls -dr ${srcdir}/../tk[4-9]* 2>/dev/null` \
+ ${srcdir}/../../tk \
+ `ls -dr ${srcdir}/../../tk[4-9]* 2>/dev/null` \
+ ${srcdir}/../../../tk \
+ `ls -dr ${srcdir}/../../../tk[4-9]* 2>/dev/null ` ; do
+ if test -f $i/generic/tk.h ; then
+ ac_cv_c_tkh=`(cd $i/generic; pwd)`
+ break
+ fi
+ done
+fi
+# finally check in a few common install locations
+#
+# since ls returns lowest version numbers first, reverse its output
+if test x"${ac_cv_c_tkh}" = x ; then
+ for i in \
+ `ls -dr /usr/local/src/tk[4-9]* 2>/dev/null` \
+ `ls -dr /usr/local/lib/tk[4-9]* 2>/dev/null` \
+ /usr/local/src/tk \
+ /usr/local/lib/tk \
+ ${prefix}/include ; do
+ if test -f $i/generic/tk.h ; then
+ ac_cv_c_tkh=`(cd $i/generic; pwd)`
+ break
+ fi
+ done
+fi
+# see if one is installed
+if test x"${ac_cv_c_tkh}" = x ; then
+ ac_safe=`echo "tk.h" | sed 'y%./+-%__p_%'`
+echo $ac_n "checking for tk.h""... $ac_c" 1>&6
+echo "configure:6197: checking for tk.h" >&5
+if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ cat > conftest.$ac_ext <<EOF
+#line 6202 "configure"
+#include "confdefs.h"
+#include <tk.h>
+EOF
+ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
+{ (eval echo configure:6207: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
+if test -z "$ac_err"; then
+ rm -rf conftest*
+ eval "ac_cv_header_$ac_safe=yes"
+else
+ echo "$ac_err" >&5
+ echo "configure: failed program was:" >&5
+ cat conftest.$ac_ext >&5
+ rm -rf conftest*
+ eval "ac_cv_header_$ac_safe=no"
+fi
+rm -f conftest*
+fi
+if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
+ echo "$ac_t""yes" 1>&6
+ ac_cv_c_tkh=installed
+else
+ echo "$ac_t""no" 1>&6
+ac_cv_c_tkh=""
+fi
+
+fi
+
+fi
+
+if test x"${ac_cv_c_tkh}" != x ; then
+ no_tk=""
+ if test x"${ac_cv_c_tkh}" = x"installed" ; then
+ echo "$ac_t""is installed" 1>&6
+ TKHDIR=""
+ else
+ echo "$ac_t""found in ${ac_cv_c_tkh}" 1>&6
+ # this hack is cause the TKHDIR won't print if there is a "-I" in it.
+ TKHDIR="-I${ac_cv_c_tkh}"
+ fi
+else
+ TKHDIR="# no Tk directory found"
+ echo "configure: warning: Can't find Tk private headers" 1>&2
+ no_tk=true
+fi
+
+
+
+
+echo $ac_n "checking for Itcl private headers. srcdir=${srcdir}""... $ac_c" 1>&6
+echo "configure:6253: checking for Itcl private headers. srcdir=${srcdir}" >&5
+if test x"${ac_cv_c_itclh}" = x ; then
+ for i in ${srcdir}/../itcl ${srcdir}/../../itcl ${srcdir}/../../../itcl ${srcdir}/../itcl/itcl; do
+ if test -f $i/generic/itcl.h ; then
+ ac_cv_c_itclh=`(cd $i/generic; pwd)`
+ break
+ fi
+ done
+fi
+if test x"${ac_cv_c_itclh}" = x ; then
+ ITCLHDIR="# no Itcl private headers found"
+ { echo "configure: error: Can't find Itcl private headers" 1>&2; exit 1; }
+fi
+if test x"${ac_cv_c_itclh}" != x ; then
+ ITCLHDIR="-I${ac_cv_c_itclh}"
+fi
+# should always be here
+# ITCLLIB="../itcl/itcl/unix/libitcl.a"
+
+#AC_SUBST(ITCLLIB)
+
+
+echo $ac_n "checking for Itk private headers. srcdir=${srcdir}""... $ac_c" 1>&6
+echo "configure:6276: checking for Itk private headers. srcdir=${srcdir}" >&5
+if test x"${ac_cv_c_itkh}" = x ; then
+ for i in ${srcdir}/../itcl ${srcdir}/../../itcl ${srcdir}/../../../itcl ${srcdir}/../itcl/itk; do
+ if test -f $i/generic/itk.h ; then
+ ac_cv_c_itkh=`(cd $i/generic; pwd)`
+ break
+ fi
+ done
+fi
+if test x"${ac_cv_c_itkh}" = x ; then
+ ITKHDIR="# no Itk private headers found"
+ { echo "configure: error: Can't find Itk private headers" 1>&2; exit 1; }
+fi
+if test x"${ac_cv_c_itkh}" != x ; then
+ ITKHDIR="-I${ac_cv_c_itkh}"
+fi
+# should always be here
+# ITKLIB="../itcl/itk/unix/libitk.a"
+
+#AC_SUBST(ITKLIB)
+
+
+echo $ac_n "checking for Tix private headers. srcdir=${srcdir}""... $ac_c" 1>&6
+echo "configure:6299: checking for Tix private headers. srcdir=${srcdir}" >&5
+if test x"${ac_cv_c_tixh}" = x ; then
+ for i in ${srcdir}/../tix ${srcdir}/../../tix ${srcdir}/../../../tix ; do
+ if test -f $i/generic/tix.h ; then
+ ac_cv_c_tixh=`(cd $i/generic; pwd)`
+ break
+ fi
+ done
+fi
+if test x"${ac_cv_c_tixh}" = x ; then
+ TIXHDIR="# no Tix private headers found"
+ { echo "configure: error: Can't find Tix private headers" 1>&2; exit 1; }
+fi
+if test x"${ac_cv_c_tixh}" != x ; then
+ TIXHDIR="-I${ac_cv_c_tixh}"
+fi
+
+
+
+ # now look for Itcl library stuff
+
+
+#
+# Ok, lets find the itcl configuration
+# First, look for one uninstalled.
+# the alternative search directory is invoked by --with-itclconfig
+#
+
+if test x"${no_itcl}" = x ; then
+ # we reset no_itcl in case something fails here
+ no_itcl=true
+ # Check whether --with-itclconfig or --without-itclconfig was given.
+if test "${with_itclconfig+set}" = set; then
+ withval="$with_itclconfig"
+ with_itclconfig=${withval}
+fi
+
+ echo $ac_n "checking for Itcl configuration""... $ac_c" 1>&6
+echo "configure:6337: checking for Itcl configuration" >&5
+ if eval "test \"`echo '$''{'ac_cv_c_itclconfig'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+
+
+ # First check to see if --with-itclconfig was specified.
+ if test x"${with_itclconfig}" != x ; then
+ if test -f "${with_itclconfig}/itclConfig.sh" ; then
+ ac_cv_c_itclconfig=`(cd ${with_itclconfig}; pwd)`
+ else
+ { echo "configure: error: ${with_itclconfig} directory doesn't contain itclConfig.sh" 1>&2; exit 1; }
+ fi
+ fi
+
+ # then check for a private Itcl library
+ if test x"${ac_cv_c_itclconfig}" = x ; then
+ for i in \
+ ../itcl/itcl \
+ `ls -dr ../itcl[4-9]*/itcl 2>/dev/null` \
+ ../../itcl \
+ `ls -dr ../../itcl[4-9]*/itcl 2>/dev/null` \
+ ../../../itcl \
+ `ls -dr ../../../itcl[4-9]*/itcl 2>/dev/null` ; do
+ if test -f "$i/itclConfig.sh" ; then
+ ac_cv_c_itclconfig=`(cd $i; pwd)`
+ break
+ fi
+ done
+ fi
+ # check in a few common install locations
+ if test x"${ac_cv_c_itclconfig}" = x ; then
+ for i in `ls -d ${prefix}/lib /usr/local/lib 2>/dev/null` ; do
+ if test -f "$i/itclConfig.sh" ; then
+ ac_cv_c_itclconfig=`(cd $i; pwd)`
+ break
+ fi
+ done
+ fi
+ # check in a few other private locations
+ if test x"${ac_cv_c_itclconfig}" = x ; then
+ for i in \
+ ${srcdir}/../itcl/itcl \
+ `ls -dr ${srcdir}/../itcl[4-9]*/itcl 2>/dev/null` ; do
+ if test -f "$i/itclConfig.sh" ; then
+ ac_cv_c_itclconfig=`(cd $i; pwd)`
+ break
+ fi
+ done
+ fi
+
+fi
+
+ if test x"${ac_cv_c_itclconfig}" = x ; then
+ ITCLCONFIG="# no Itcl configs found"
+ echo "configure: warning: Can't find Itcl configuration definitions" 1>&2
+ else
+ no_itcl=
+ ITCLCONFIG=${ac_cv_c_itclconfig}/itclConfig.sh
+ echo "$ac_t""found $ITCLCONFIG" 1>&6
+ fi
+fi
+
+ if test -z "${no_itcl}"; then
+
+ if test -f "$ITCLCONFIG" ; then
+ . $ITCLCONFIG
+ fi
+
+
+
+
+
+
+
+
+
+
+
+ case "${host}" in
+ *-*-cygwin*)
+ itcldir=../itcl/itcl/win/
+ ;;
+ *)
+ itcldir=../itcl/itcl/unix/
+ ;;
+ esac
+
+
+ ITCLLIB="${ITCL_BUILD_LIB_SPEC}"
+ ITCL_DEPS="${itcldir}${ITCL_LIB_FILE}"
+ fi
+
+
+ # now look for Itk library stuff
+
+#
+# Ok, lets find the itk configuration
+# First, look for one uninstalled.
+# the alternative search directory is invoked by --with-itkconfig
+#
+
+if test x"${no_itk}" = x ; then
+ # we reset no_itk in case something fails here
+ no_itk=true
+ # Check whether --with-itkconfig or --without-itkconfig was given.
+if test "${with_itkconfig+set}" = set; then
+ withval="$with_itkconfig"
+ with_itkconfig=${withval}
+fi
+
+ echo $ac_n "checking for Itk configuration""... $ac_c" 1>&6
+echo "configure:6449: checking for Itk configuration" >&5
+ if eval "test \"`echo '$''{'ac_cv_c_itkconfig'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+
+
+ # First check to see if --with-itkconfig was specified.
+ if test x"${with_itkconfig}" != x ; then
+ if test -f "${with_itkconfig}/itkConfig.sh" ; then
+ ac_cv_c_itkconfig=`(cd ${with_itkconfig}; pwd)`
+ else
+ { echo "configure: error: ${with_itkconfig} directory doesn't contain itkConfig.sh" 1>&2; exit 1; }
+ fi
+ fi
+
+ # then check for a private Itk library
+ if test x"${ac_cv_c_itkconfig}" = x ; then
+ for i in \
+ ../itcl/itk \
+ `ls -dr ../itcl[4-9]*/itk 2>/dev/null` \
+ ../../itk \
+ `ls -dr ../../itcl[4-9]*/itk 2>/dev/null` \
+ ../../../itk \
+ `ls -dr ../../../itcl[4-9]*/itk 2>/dev/null` ; do
+ if test -f "$i/itkConfig.sh" ; then
+ ac_cv_c_itkconfig=`(cd $i; pwd)`
+ break
+ fi
+ done
+ fi
+ # check in a few common install locations
+ if test x"${ac_cv_c_itkconfig}" = x ; then
+ for i in `ls -d ${prefix}/lib /usr/local/lib 2>/dev/null` ; do
+ if test -f "$i/itkConfig.sh" ; then
+ ac_cv_c_itkconfig=`(cd $i; pwd)`
+ break
+ fi
+ done
+ fi
+ # check in a few other private locations
+ if test x"${ac_cv_c_itkconfig}" = x ; then
+ for i in \
+ ${srcdir}/../itcl/itk \
+ `ls -dr ${srcdir}/../itcl[4-9]*/itk 2>/dev/null` ; do
+ if test -f "$i/itkConfig.sh" ; then
+ ac_cv_c_itkconfig=`(cd $i; pwd)`
+ break
+ fi
+ done
+ fi
+
+fi
+
+ if test x"${ac_cv_c_itkconfig}" = x ; then
+ ITKCONFIG="# no Itk configs found"
+ echo "configure: warning: Can't find Itk configuration definitions" 1>&2
+ else
+ no_itk=
+ ITKCONFIG=${ac_cv_c_itkconfig}/itkConfig.sh
+ echo "$ac_t""found $ITKCONFIG" 1>&6
+ fi
+fi
+
+
+ if test -z "${no_itcl}"; then
+
+ if test -f "$ITKCONFIG" ; then
+ . $ITKCONFIG
+ fi
+
+
+
+
+
+
+
+
+
+
+
+
+ case "${host}" in
+ *-*-cygwin*)
+ itkdir=../itcl/itk/win/
+ ;;
+ *)
+ itkdir=../itcl/itk/unix/
+ ;;
+ esac
+
+ ITKLIB="${ITK_BUILD_LIB_SPEC}"
+ ITK_DEPS="${itkdir}${ITK_LIB_FILE}"
+ fi
+
+ # now look for Tix library stuff
+
+#
+# Ok, lets find the tix configuration
+# First, look for one uninstalled.
+# the alternative search directory is invoked by --with-itkconfig
+#
+
+if test x"${no_tix}" = x ; then
+ # we reset no_tix in case something fails here
+ no_tix=true
+ # Check whether --with-tixconfig or --without-tixconfig was given.
+if test "${with_tixconfig+set}" = set; then
+ withval="$with_tixconfig"
+ with_tixconfig=${withval}
+fi
+
+ echo $ac_n "checking for Tix configuration""... $ac_c" 1>&6
+echo "configure:6561: checking for Tix configuration" >&5
+ if eval "test \"`echo '$''{'ac_cv_c_tixconfig'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+
+
+ # First check to see if --with-tixconfig was specified.
+ if test x"${with_tixconfig}" != x ; then
+ if test -f "${with_tixconfig}/tixConfig.sh" ; then
+ ac_cv_c_tixconfig=`(cd ${with_tixconfig}; pwd)`
+ else
+ { echo "configure: error: ${with_tixconfig} directory doesn't contain tixConfig.sh" 1>&2; exit 1; }
+ fi
+ fi
+
+ # then check for a private Tix library
+ if test x"${ac_cv_c_tixconfig}" = x ; then
+ for i in \
+ ../tix \
+ `ls -dr ../tix 2>/dev/null` \
+ ../../tix \
+ `ls -dr ../../tix 2>/dev/null` \
+ ../../../tix \
+ `ls -dr ../../../tix 2>/dev/null` ; do
+ echo "**** Looking at $i - with ${configdir}"
+ if test -f "$i/tixConfig.sh" ; then
+ ac_cv_c_tixconfig=`(cd $i; pwd)`
+ break
+ fi
+ done
+ fi
+ # check in a few common install locations
+ if test x"${ac_cv_c_tixconfig}" = x ; then
+ for i in `ls -d ${prefix}/lib /usr/local/lib 2>/dev/null` ; do
+ echo "**** Looking at $i"
+ if test -f "$i/tixConfig.sh" ; then
+ ac_cv_c_tixconfig=`(cd $i; pwd)`
+ break
+ fi
+ done
+ fi
+ # check in a few other private locations
+ echo "**** Other private locations"
+ if test x"${ac_cv_c_tixconfig}" = x ; then
+ for i in \
+ ${srcdir}/../tix \
+ `ls -dr ${srcdir}/../tix 2>/dev/null` ; do
+ echo "**** Looking at $i - with ${configdir}"
+ if test -f "$i/${configdir}/tixConfig.sh" ; then
+ ac_cv_c_tixconfig=`(cd $i/${configdir}; pwd)`
+ break
+ fi
+ done
+ fi
+
+fi
+
+ if test x"${ac_cv_c_tixconfig}" = x ; then
+ TIXCONFIG="# no Tix configs found"
+ echo "configure: warning: Can't find Tix configuration definitions" 1>&2
+ else
+ no_tix=
+ TIXCONFIG=${ac_cv_c_tixconfig}/tixConfig.sh
+ echo "$ac_t""found $TIXCONFIG" 1>&6
+ fi
+fi
+
+
+ if test -z "${no_tix}"; then
+
+ if test -f "$TIXCONFIG" ; then
+ . $TIXCONFIG
+ fi
+
+
+
+
+
+
+
+
+ TIXLIB="${TIX_BUILD_LIB_SPEC}"
+ TIX_DEPS="${TIX_BUILD_LOCATION}/${TIX_LIB_FILE}"
+ fi
+
+ ENABLE_GDBTK=1
+ ENABLE_CFLAGS="$ENABLE_CFLAGS -DGDBTK"
+ # Tcl/Tk 8.1 require -fwritable strings. I don't
+ # know whether 8.2 will or not, but I bet it will.
+ # I don't have to worry about 7.x since we don't support it.
+ GDBTK_CFLAGS=""
+ if test "$GCC" = "yes"; then
+ if test "$TCL_VERSION" != "8.0" ; then
+ GDBTK_CFLAGS="-fwritable-strings"
+ fi
+ fi
+
+ # Include some libraries that Tcl and Tk want.
+ TCL_LIBS='$(LIBGUI) $(ITCL) $(ITK) $(TIX) $(TK) $(TCL) $(X11_LDFLAGS) $(X11_LIBS)'
+ CONFIG_DEPS='$(LIBGUI) $(ITCL_DEPS) $(ITK_DEPS) $(TIX_DEPS) $(TK_DEPS) $(TCL_DEPS)'
+ # Yes, the ordering seems wrong here. But it isn't.
+ # TK_LIBS is the list of libraries that need to be linked
+ # after Tcl/Tk. Note that this isn't put into LIBS. If it
+ # were in LIBS then any link tests after this point would
+ # try to include things like `$(LIBGUI)', which wouldn't work.
+ GDBTKLIBS="${TCL_LIBS} ${TK_LIBS}"
+ CONFIG_SRCS="${CONFIG_SRCS} gdbtk/generic/gdbtk.c gdbtk/generic/gdbtk-cmds.c gdbtk/generic/gdbtk-hooks.c gdbtk/generic/gdbtk-variable.c gdbtk/generic/gdbtk-wrapper.c"
+ CONFIG_OBS="${CONFIG_OBS} gdbtk.o gdbtk-cmds.o gdbtk-hooks.o gdbtk-variable.o gdbtk-wrapper.o"
+ CONFIG_INITS="${CONFIG_INITS} gdbtk/generic/gdbtk.c gdbtk/generic/gdbtk-cmds.c gdbtk/generic/gdbtk-hooks.c gdbtk/generic/gdbtk-variable.c gdbtk/generic/gdbtk-wrapper.c"
+
+ if test x$gdb_cv_os_cygwin = xyes; then
+ WIN32LIBS="${WIN32LIBS} -lshell32 -lgdi32 -lcomdlg32 -ladvapi32"
+ WIN32LDAPP="-Wl,--subsystem,console"
+ CONFIG_OBS="${CONFIG_OBS} gdbres.o"
+ fi
+ fi
+ fi
+fi
+
+
+
+
+
+
+
+
+
+
+
+
+
# If we find X, set shell vars x_includes and x_libraries to the
# paths, otherwise set no_x=yes.
@@ -6022,6 +6988,37 @@ else
files="${files} config/nm-empty.h"
links="${links} nm.h"
fi
+echo $ac_n "checking whether ln -s works""... $ac_c" 1>&6
+echo "configure:7159: checking whether ln -s works" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_LN_S'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ rm -f conftestdata
+if ln -s X conftestdata 2>/dev/null
+then
+ rm -f conftestdata
+ ac_cv_prog_LN_S="ln -s"
+else
+ ac_cv_prog_LN_S=ln
+fi
+fi
+LN_S="$ac_cv_prog_LN_S"
+if test "$ac_cv_prog_LN_S" = "ln -s"; then
+ echo "$ac_t""yes" 1>&6
+else
+ echo "$ac_t""no" 1>&6
+fi
+
+# Make it possible to use the GUI without doing a full install
+if test "${enable_gdbtk}" = "yes" ; then
+ if test "$LN_S" = "ln -s" -a ! -f gdbtcl ; then
+ echo linking $srcdir/gdbtk/library to gdbtcl
+ $LN_S $srcdir/gdbtk/library gdbtcl
+ else
+ echo Warning: Unable to link $srcdir/gdbtk/library to gdbtcl. You will need to do a
+ echo " " make install before you are able to run the GUI.
+ fi
+fi
diff --git a/gdb/configure.in b/gdb/configure.in
index e85f6367a84..8c5ba2fbe95 100644
--- a/gdb/configure.in
+++ b/gdb/configure.in
@@ -500,6 +500,10 @@ if test x$gdb_cv_os_cygwin = xyes; then
fi
AC_SUBST(WIN32LIBS)
+LIBGUI="../libgui/src/libgui.a"
+GUI_CFLAGS_X="-I${srcdir}/../libgui/src"
+AC_SUBST(LIBGUI)
+AC_SUBST(GUI_CFLAGS_X)
AC_ARG_WITH(cpu,
[ --with-cpu=CPU Set the default CPU variant to debug],
@@ -536,6 +540,153 @@ AC_DEFINE_UNQUOTED(TARGET_CPU_DEFAULT, "${with_cpu}")
],)
+ENABLE_GDBTK=
+
+AC_ARG_ENABLE(gdbtk,
+[ --enable-gdbtk Enable GDBTK GUI front end],
+[case "${enableval}" in
+ yes)
+ case "$host" in
+ *go32*)
+ AC_MSG_WARN([GDB does not support GDBtk on host ${host}. GDBtk will be disabled.])
+ enable_gdbtk=no ;;
+ *windows*)
+ AC_MSG_WARN([GDB does not support GDBtk on host ${host}. GDBtk will be disabled.])
+ enable_gdbtk=no ;;
+ *)
+ enable_gdbtk=yes ;;
+ esac ;;
+ no)
+ enable_gdbtk=no ;;
+ *)
+ AC_MSG_ERROR(bad value ${enableval} given for gdbtk option) ;;
+esac],
+[
+# Default is on for everything but go32 and Cygwin
+case "$host" in
+ *go32* | *windows*)
+ ;;
+ *)
+ enable_gdbtk=yes ;;
+ esac
+])
+
+WIN32LDAPP=
+AC_SUBST(WIN32LIBS)
+AC_SUBST(WIN32LDAPP)
+
+configdir="unix"
+
+GDBTKLIBS=
+if test "${enable_gdbtk}" = "yes"; then
+
+ CY_AC_PATH_TCLCONFIG
+ if test -z "${no_tcl}"; then
+ CY_AC_LOAD_TCLCONFIG
+ CY_AC_PATH_TKCONFIG
+
+ # If $no_tk is nonempty, then we can't do Tk, and there is no
+ # point to doing Tcl.
+ if test -z "${no_tk}"; then
+ CY_AC_LOAD_TKCONFIG
+ CY_AC_PATH_TCLH
+ CY_AC_PATH_TKH
+ CY_AC_PATH_ITCLH
+ CY_AC_PATH_ITKH
+ CY_AC_PATH_TIXH
+
+ # now look for Itcl library stuff
+
+ CY_AC_PATH_ITCLCONFIG
+ if test -z "${no_itcl}"; then
+ CY_AC_LOAD_ITCLCONFIG
+ case "${host}" in
+ *-*-cygwin*)
+ itcldir=../itcl/itcl/win/
+ ;;
+ *)
+ itcldir=../itcl/itcl/unix/
+ ;;
+ esac
+
+
+ ITCLLIB="${ITCL_BUILD_LIB_SPEC}"
+ ITCL_DEPS="${itcldir}${ITCL_LIB_FILE}"
+ fi
+
+
+ # now look for Itk library stuff
+ CY_AC_PATH_ITKCONFIG
+ if test -z "${no_itcl}"; then
+ CY_AC_LOAD_ITKCONFIG
+
+ case "${host}" in
+ *-*-cygwin*)
+ itkdir=../itcl/itk/win/
+ ;;
+ *)
+ itkdir=../itcl/itk/unix/
+ ;;
+ esac
+
+ ITKLIB="${ITK_BUILD_LIB_SPEC}"
+ ITK_DEPS="${itkdir}${ITK_LIB_FILE}"
+ fi
+
+ # now look for Tix library stuff
+ CY_AC_PATH_TIXCONFIG
+ if test -z "${no_tix}"; then
+ CY_AC_LOAD_TIXCONFIG
+ TIXLIB="${TIX_BUILD_LIB_SPEC}"
+ TIX_DEPS="${TIX_BUILD_LOCATION}/${TIX_LIB_FILE}"
+ fi
+
+ ENABLE_GDBTK=1
+ ENABLE_CFLAGS="$ENABLE_CFLAGS -DGDBTK"
+ # Tcl/Tk 8.1 require -fwritable strings. I don't
+ # know whether 8.2 will or not, but I bet it will.
+ # I don't have to worry about 7.x since we don't support it.
+ GDBTK_CFLAGS=""
+ if test "$GCC" = "yes"; then
+ if test "$TCL_VERSION" != "8.0" ; then
+ GDBTK_CFLAGS="-fwritable-strings"
+ fi
+ fi
+
+ # Include some libraries that Tcl and Tk want.
+ TCL_LIBS='$(LIBGUI) $(ITCL) $(ITK) $(TIX) $(TK) $(TCL) $(X11_LDFLAGS) $(X11_LIBS)'
+ CONFIG_DEPS='$(LIBGUI) $(ITCL_DEPS) $(ITK_DEPS) $(TIX_DEPS) $(TK_DEPS) $(TCL_DEPS)'
+ # Yes, the ordering seems wrong here. But it isn't.
+ # TK_LIBS is the list of libraries that need to be linked
+ # after Tcl/Tk. Note that this isn't put into LIBS. If it
+ # were in LIBS then any link tests after this point would
+ # try to include things like `$(LIBGUI)', which wouldn't work.
+ GDBTKLIBS="${TCL_LIBS} ${TK_LIBS}"
+ CONFIG_SRCS="${CONFIG_SRCS} gdbtk/generic/gdbtk.c gdbtk/generic/gdbtk-cmds.c gdbtk/generic/gdbtk-hooks.c gdbtk/generic/gdbtk-variable.c gdbtk/generic/gdbtk-wrapper.c"
+ CONFIG_OBS="${CONFIG_OBS} gdbtk.o gdbtk-cmds.o gdbtk-hooks.o gdbtk-variable.o gdbtk-wrapper.o"
+ CONFIG_INITS="${CONFIG_INITS} gdbtk/generic/gdbtk.c gdbtk/generic/gdbtk-cmds.c gdbtk/generic/gdbtk-hooks.c gdbtk/generic/gdbtk-variable.c gdbtk/generic/gdbtk-wrapper.c"
+
+ if test x$gdb_cv_os_cygwin = xyes; then
+ WIN32LIBS="${WIN32LIBS} -lshell32 -lgdi32 -lcomdlg32 -ladvapi32"
+ WIN32LDAPP="-Wl,--subsystem,console"
+ CONFIG_OBS="${CONFIG_OBS} gdbres.o"
+ fi
+ fi
+ fi
+fi
+
+AC_SUBST(ENABLE_GDBTK)
+AC_SUBST(X_CFLAGS)
+AC_SUBST(X_LDFLAGS)
+AC_SUBST(X_LIBS)
+AC_SUBST(ITCLLIB)
+AC_SUBST(ITCL_DEPS)
+AC_SUBST(ITKLIB)
+AC_SUBST(ITK_DEPS)
+AC_SUBST(TIXLIB)
+AC_SUBST(TIX_DEPS)
+AC_SUBST(GDBTKLIBS)
+AC_SUBST(GDBTK_CFLAGS)
AC_PATH_X
@@ -721,6 +872,17 @@ else
files="${files} config/nm-empty.h"
links="${links} nm.h"
fi
+AC_PROG_LN_S
+# Make it possible to use the GUI without doing a full install
+if test "${enable_gdbtk}" = "yes" ; then
+ if test "$LN_S" = "ln -s" -a ! -f gdbtcl ; then
+ echo linking $srcdir/gdbtk/library to gdbtcl
+ $LN_S $srcdir/gdbtk/library gdbtcl
+ else
+ echo Warning: Unable to link $srcdir/gdbtk/library to gdbtcl. You will need to do a
+ echo " " make install before you are able to run the GUI.
+ fi
+fi
AC_LINK_FILES($files, $links)
diff --git a/gdb/doc/ChangeLog b/gdb/doc/ChangeLog
index d6aedaa57f1..e2422d58255 100644
--- a/gdb/doc/ChangeLog
+++ b/gdb/doc/ChangeLog
@@ -646,6 +646,10 @@ Tue Jan 17 14:09:03 1995 Ian Lance Taylor <ian@sanguine.cygnus.com>
* remote.texi: Update documentation of set/show mipsfpu.
+Fri Jan 6 17:17:28 1995 Stan Shebs <shebs@andros.cygnus.com>
+
+ * gdbgui.texinfo: New file, manual for GUI (gdbtk) users.
+ * Makefile.in (gdbgui.dvi, gdbgui.info): New actions.
Sun Sep 4 16:47:21 1994 Stan Shebs (shebs@andros.cygnus.com)
diff --git a/gdb/doc/Makefile.in b/gdb/doc/Makefile.in
index 9cbacbb29bb..1280ed7be0f 100644
--- a/gdb/doc/Makefile.in
+++ b/gdb/doc/Makefile.in
@@ -318,6 +318,19 @@ gdb.mm: $(SFILES_LOCAL) links2roff rluser.texinfo inc-hist.texinfo
gdb_toc.html: ${SFILES_DOC}
$(MAKEHTML) $(MAKEHTMLFLAGS) -I ${READLINE_DIR} -I $(srcdir) $(srcdir)/gdb.texinfo
+# GDB GUI MANUAL: TeX dvi file
+gdbgui.dvi : gdbgui.texinfo ${SFILES_DOC}
+ $(SET_TEXINPUTS) $(TEX) gdbgui.texinfo
+ $(TEXINDEX) gdbgui.??
+ $(SET_TEXINPUTS) $(TEX) gdbgui.texinfo
+ rm -f gdbgui.aux gdbgui.cp* gdbgui.fn* gdbgui.ky* \
+ gdbgui.log gdbgui.pg* gdbgui.toc gdbgui.tp* gdbgui.vr*
+
+# GDB GUI MANUAL: info file
+gdb-gui: gdbgui.info
+
+gdbgui.info: gdbgui.texinfo ${SFILES_DOC}
+ $(MAKEINFO) -o gdbgui.info $(srcdir)/gdbgui.texinfo
# GDB INTERNALS MANUAL: TeX dvi file
gdbint.dvi : gdbint.texinfo
diff --git a/gdb/doc/gdbgui.texinfo b/gdb/doc/gdbgui.texinfo
new file mode 100644
index 00000000000..6618f73a30a
--- /dev/null
+++ b/gdb/doc/gdbgui.texinfo
@@ -0,0 +1,411 @@
+\input texinfo @c -*-texinfo-*-
+@c Copyright 1988 1989 1990 1991 1992 1993 1994 Free Software Foundation, Inc.
+@c
+@c %**start of header
+@c makeinfo ignores cmds prev to setfilename, so its arg cannot make use
+@c of @set vars. However, you can override filename with makeinfo -o.
+@setfilename gdb.info
+@c
+@include gdb-cfg.texi
+@c
+@ifset GENERIC
+@settitle Using the Graphical Interface to @value{GDBN}
+@end ifset
+@ifclear GENERIC
+@settitle Using the Graphical Interface to @value{GDBN} (@value{TARGET})
+@end ifclear
+@setchapternewpage odd
+@c %**end of header
+
+@c Since this interface is so new, there is much missing still.
+@c Desired but unimplemented features are commented out.
+
+@iftex
+@c @smallbook
+@c @cropmarks
+@end iftex
+
+@finalout
+@syncodeindex ky cp
+
+@c readline appendices use @vindex
+@syncodeindex vr cp
+
+@c !!set GDB manual's edition---not the same as GDB version!
+@set EDITION 4.13
+
+@c !!set GDB manual's revision date
+@set DATE January 1995
+
+@c THIS MANUAL REQUIRES TEXINFO-2 macros and info-makers to format properly.
+
+@ifinfo
+@c This is a dir.info fragment to support semi-automated addition of
+@c manuals to an info tree. zoo@cygnus.com is developing this facility.
+@format
+START-INFO-DIR-ENTRY
+* Gdb: (gdb). The GNU debugger.
+END-INFO-DIR-ENTRY
+@end format
+@end ifinfo
+@c
+@c
+@ifinfo
+This file documents the graphical interface to the GNU debugger @value{GDBN}.
+
+
+This is Edition @value{EDITION}, @value{DATE},
+of @cite{Using the Graphical Interface to @value{GDBN}}
+for GDB Version @value{GDBVN}.
+
+Copyright (C) 1994, 1995 Free Software Foundation, Inc.
+
+Permission is granted to make and distribute verbatim copies of
+this manual provided the copyright notice and this permission notice
+are preserved on all copies.
+
+@ignore
+Permission is granted to process this file through TeX and print the
+results, provided the printed document carries copying permission
+notice identical to this one except for the removal of this paragraph
+(this paragraph not being relevant to the printed manual).
+
+@end ignore
+Permission is granted to copy and distribute modified versions of this
+manual under the conditions for verbatim copying, provided also that the
+entire resulting derived work is distributed under the terms of a
+permission notice identical to this one.
+
+Permission is granted to copy and distribute translations of this manual
+into another language, under the above conditions for modified versions.
+@end ifinfo
+
+@titlepage
+@title Using the Graphical Interface to @value{GDBN}
+@subtitle The GNU Source-Level Debugger
+@ifclear GENERIC
+@subtitle (@value{TARGET})
+@end ifclear
+@sp 1
+@subtitle Edition @value{EDITION}, for @value{GDBN} version @value{GDBVN}
+@subtitle @value{DATE}
+@author Stanley T. Shebs
+@page
+@tex
+{\parskip=0pt
+\hfill (Send bugs and comments on @value{GDBN} to bug-gdb\@prep.ai.mit.edu.)\par
+\hfill {\it Debugging with @value{GDBN}}\par
+\hfill \TeX{}info \texinfoversion\par
+\hfill doc\@cygnus.com\par
+}
+@end tex
+
+@vskip 0pt plus 1filll
+Copyright @copyright{} 1994, 1995 Free Software Foundation, Inc.
+@sp 2
+
+Permission is granted to make and distribute verbatim copies of
+this manual provided the copyright notice and this permission notice
+are preserved on all copies.
+
+Permission is granted to copy and distribute modified versions of this
+manual under the conditions for verbatim copying, provided also that the
+entire resulting derived work is distributed under the terms of a
+permission notice identical to this one.
+
+Permission is granted to copy and distribute translations of this manual
+into another language, under the above conditions for modified versions.
+@end titlepage
+@page
+
+@ifinfo
+@node Top
+@top Using the Graphical Interface to @value{GDBN}
+@end ifinfo
+
+This file describes a graphical interface to @value{GDBN},
+the GNU symbolic debugger.
+
+@node Invocation
+@chapter Starting up GUI @value{GDBN}
+
+If @value{GDBN} has been configured to use the graphical interface,
+then you will get the interface automatically upon startup.
+
+When running as a Unix program and using the X11-based interface,
+you must of course be using an X server and/or workstation,
+and your @code{DISPLAY} environment variable must be set correctly.
+If either of these is not true, then @value{GDBN} will still start up,
+but will use only the traditional command interface.
+
+The exact layout and appearance of the windows will depend on the host
+system type. For instance, GDB under Windows will display its windows
+inside a larger window, while under Unix/X, each window is a separate
+toplevel window. However, general behavior and layout is consistent
+across all platforms; omissions or restrictions on particular platforms,
+if not documented as unavoidable, should be considered bugs and
+reported.
+
+All GDB windows have a common structure. Each window has an associated
+menu bar, which may be at the top of the window or perhaps elsewhere.
+Some of the menus and menu items in the menu bar are common to all GDB
+windows, while others are specific to particular types of windows.
+Below the menu bar is the working data area of the window. If the data
+is too large to display all at once, the data area will have scroll bars
+on its right and bottom sides. Below the data area are two optional
+features; a status/data line, and a button box.
+
+@section Menus
+
+@subsection File Menu
+
+The standard file menu provides operations that affect the overall state
+of GDB, mainly file operations, but other things as well.
+
+About GDB...
+
+Displays the startup window for GDB.
+
+File...
+
+Lets you set the combined executable and symbol file that GDB will use.
+(Like "file".)
+
+Target...
+
+Brings up a dialog that you can use to connect GDB to a target program.
+The dialog is described in more depth later.
+(Like "target".)
+
+Edit...
+
+Starts up an editor to modify the source file being displayed.
+
+Exec File...
+
+Lets you set the executable file that GDB will use.
+(Like "exec-file".)
+
+Symbol File...
+
+Lets you set the symbol file that GDB will use.
+(Like "symbol-file".)
+
+Add Symbol File...
+
+Lets you add additional symbol files.
+(Like "add-symbol-file".)
+
+Core File...
+
+Lets you set the core file that GDB will use.
+(Like "core-file".)
+
+Shared Libraries...
+
+(Like "sharedlibrary".)
+
+Quit
+
+quits GDB.
+(Like @samp{quit}.)
+
+
+@c @subsection Commands Menu
+
+@c The commands menu consists of items that let you run and control the program being
+@c debugged.
+@c
+@c Run
+@c
+@c Step
+@c
+@c Next
+@c
+@c Finish
+@c
+@c Stepi
+@c
+@c Nexti
+
+@subsection Windows Menu
+
+The windows menu allows access to all the windows available in GDB.
+The first part of the menu lists all of the predefined individual windows.
+If the window exists already, its item will be marked as such;
+selecting the item will cause the window to be put in front if it is
+obscured. If it does not exist, then it will be created.
+
+The second part of the menu lists additional windows that you may have
+created, such as source windows or variable displays.
+
+Command
+---
+Source
+Assembly
+---
+Registers
+Variables
+---
+Files
+@c ---
+@c <extra windows>
+
+@subsection View Menu
+
+All windows have a view menu, but its contents are highly specific to
+window type. For instance, a source window will have a view menu item
+to control the display of line numbers, but a register window will instead
+have an option to choose the radix in which to display register contents.
+You can find the full description of view options with each window type.
+
+@subsection Help Menu
+
+The help menu includes access to GDB's online help.
+
+@section Windows
+
+@subsection Command Window
+
+The command window provides access to the standard GDB command
+interpreter. In nearly all cases, commands typed into this window
+will behave exactly as for a non-windowing GDB.
+
+Note that not all changes to GDB will be reflected in this window. For instance,
+if you were to type a "step" command, then click on the "step" menu item in
+the source window, then go back, and type another "step" command, the command
+buffer will only show two steps, when you have actually done three. GDB will
+put a "..." into the command buffer when operations in other windows are done,
+as a reminder that the command buffer is incomplete.
+
+@c Also note that as a side effect of having the interface and possibly an
+@c associated scripting language built in, additional commands may be
+@c available. For instance, if tcl is in GDB, the command ``tcl <tcl code>''
+@c will be available.
+
+The command window has no status line or button box.
+
+@subsection Files Window
+
+The files window lists all of the files that were used to build the
+executable.
+
+Clicking on the xxx in the left margin expands/contracts the display of
+included files and symbols defined by the file.
+
+The View menu for this window includes the following items:
+Name/Full Pathname
+@c Sort by Name
+@c Sort by Section&Offset
+@c Show All Included Files
+@c Included File Indentation...
+
+@subsection Source Window
+
+A source window displays a single file of source code.
+
+The left margin includes an indicator for the current PC, breakpoints and potential breakpoints,
+and (optionally) line numbers.
+
+The View menu for this window includes the following items:
+Show Line Numbers
+Show Breakdots
+@c Jump to PC (if pc changes, scroll back so PC is centered)
+@c Tab... (set tabbing)
+
+@section Extensions
+
+[description of gdbtk details]
+
+@c
+@c GDBTK Interface Design
+@c
+@c This is the working document describing the design of the GDBTK
+@c interface. Note that overall layout applies only to the default setup;
+@c it is expected that debugger users will be able to customize extensively.
+@c
+@c Default Startup
+@c
+@c One source window, shows source as in "list main", does *not* set a
+@c break at main or run or anything. No current PC indicator, only put
+@c in when something runs.
+@c
+@c Source Window
+@c
+@c For native, "run" button is always the same, for cross, it's actually
+@c a "target" button that pops up appropriate dialog to get connected.
+@c Once remote target is active, change button to "run".
+@c
+@c Be able to toggle assembly interleaved between source.
+@c
+@c Command Window
+@c
+@c Is an *optional* window.
+@c
+@c Behavior mimics command-line GDB running in an Emacs buffer as much
+@c as possible.
+@c
+@c Assembly Window
+@c
+@c Be able to toggle source interleaved between assembly.
+@c
+@c Target Info Window
+@c
+@c Contents similar to "info target".
+@c
+@c Should expand into process and thread info also.
+@c
+@c File Info Window
+@c
+@c Contents similar to "info files".
+@c
+@c Include data shown in "info sources" as well as "info files".
+@c
+@c Register Info Window
+@c
+@c Contents similar to "info registers".
+@c
+@c Add view option(s) for classes of registers.
+@c
+@c Stack Info Window
+@c
+@c Combines backtrace, frame, and local var displays.
+@c
+@c Signals Dialog
+@c
+@c Includes all signals whose handling may be controlled, plus
+@c checkboxes for what to do with each.
+@c
+@c Settings Dialog(s)
+@c
+@c Include all variables that can be "set" and "show"n.
+@c
+@c General Principles
+@c
+@c All windows should have a menu that allows access to other windows.
+@c Selection of item either brings up for first time or brings to front.
+@c
+@c All windows should have a "view" menu that controls formatting
+@c options for that window.
+@c
+@c Windows should usually be scrollable. Windows that display largish
+@c horizontal things should be horizontal and vertical scrollbars.
+@c
+@c To do standard modification, add commands or tcl code to .gdbtkinit.
+@c
+@c Be able to record window positions so they come up in the same way
+@c the next time. Could scribble on .gdbtkinit perhaps, or else an
+@c aux file that can be sourced by .gdbtkinit.
+
+@section How to Build
+
+If GDB is configured with --enable-gdbtk, then upon startup, it will
+open windows.
+
+@node Index
+@unnumbered Index
+
+@printindex cp
+
+@contents
+@bye
diff --git a/gdb/gdbtk/ChangeLog-gdbtk b/gdb/gdbtk/ChangeLog-gdbtk
new file mode 100644
index 00000000000..a635d673266
--- /dev/null
+++ b/gdb/gdbtk/ChangeLog-gdbtk
@@ -0,0 +1,7 @@
+Sat Feb 5 00:14:30 2000 Andrew Cagney <cagney@b1.cygnus.com>
+
+ * gdb.rc, gdbtool.ico, README.GDBTK: To here from top level GDB
+ directory.
+ * gdb/gdbtcl2: Directory moved to gdbtk/library.
+ * gdb/gdbtk/generic: New directory.
+
diff --git a/gdb/gdbtk/README.GDBTK b/gdb/gdbtk/README.GDBTK
new file mode 100644
index 00000000000..9f5c0c0b90c
--- /dev/null
+++ b/gdb/gdbtk/README.GDBTK
@@ -0,0 +1,403 @@
+ README.GDBTK
+ Written by Stu Grossman
+ Updated 9/26/95 by Fred Fish for gdb 4.15 release
+ Updated 4/18/97 by Martin Hunt
+
+This file describes how to build, install, use and hack on GDBtk, a TK based
+GUI for GDB, the GNU debugger.
+
+Introduction
+============
+
+GDBtk is a version of GDB that uses Tcl/Tk to implement a graphical
+user inter-face. It is a fully integrated GUI, not a separate
+front-end program. The interface consists of several seperate
+windows, which use standard elements like buttons, scrollbars, entry
+boxes and such to create a fairly easy to use interface. Each window
+has a distinct content and purpose, and can be enabled or disabled
+individually. The windows contain things like the current source
+file, a disassembly of the current function, text commands (for things
+that aren't accessible via a button), and so forth.
+
+Building and installing
+=======================
+
+Building GDBtk is very straightforward. The main difference is that you will
+need to use the `--enable-gdbtk' option when you run configure in the top level
+directory. You will also need to install Tcl version 7.6 and Tk version 4.2.
+
+On Unix machines, you will also need to have X11 (R4/R5/R6) installed
+(this is a prerequisite to installing Tk).
+
+For Windows, you can obtain Tcl/Tk from ftp://ftp.smli.com:/pub/tcl/win76p2.exe.
+There is a bug in this version of Tcl/tk that requires you to set the
+environmental variable TK_LIBRARY to where the tk library directory is installed.
+There is also a problem with the colors in images on 16-bit displays under
+Windows, so some icons may look strange.
+
+[See the GDB README file for more details on configure options and such.]
+
+For example:
+
+ host> cd gdbtk
+ host> ./configure --enable-gdbtk
+ host> make
+ host> make install
+
+Using GDBtk
+===========
+
+Just run it like you would a normal GDB (in fact, it's actually called `gdb').
+If everything goes well, you should have several windows pop up. To get going,
+hit the start button, and go exploring.
+
+If you want to use GDB in command line mode, just use the -nw option. Or, you
+can undefine the DISPLAY environment variable.
+
+In the current version, you can have up to 6 windows active at once. They are:
+
+ 1) Command
+ 2) Source
+ 3) Assembly
+ 4) Register
+ 5) Auto Command
+ 6) Expression
+
+Most windows have a similar layout consisting of a menubar, display area,
+scrollbar, status box and window-specific buttons.
+
+The menubar contains the following items:
+
+ File - General file control. Also has window close and quit buttons.
+ Options - Window specific options.
+ Window - A menu of other windows that can be popped up or created.
+ Help - Mostly unimplemented.
+
+The status box indicates things like the current file and function, or the
+current PC and function depending upon the window.
+
+Command window:
+
+ This can be used to type commands at GDB (useful for when there isn't a
+ button for what you want to do).
+
+Source window:
+
+ This contains the current source file. The margin displays line
+ numbers, and has an indicator for lines that actually contain code (and
+ therefore can have breakpoints as well). When a breakpoint is set at
+ that line, the indicator is replaced with a stop sign icon.
+
+ The buttons are:
+
+ Start - Put a breakpoint at main, and then run.
+ Stop - Stop the program (only active when program is running).
+ Step, Next, Cont[inue], Finish, Up, Down - Same as the corresponding
+ GDB command. (Finish runs the current subroutine until it's done.)
+ Bottom - Does a `frame 0' to put you at the innermost call frame.
+
+ There are also accelerators for various buttons (just type the letter
+ without any control/meta/alt/shift in the text frame):
+
+ s - Step
+ n - Next
+ c - Continue
+ f - Finish
+ u - Up
+ d - Down
+
+ The mouse can also be used to set and clear breakpoints when clicked
+ in the margin (on a breakpoint indicator).
+
+Assembly window:
+
+ This displays a disassembly of the current function. It's buttons are
+ similar to those of the source window, except that it uses Stepi and
+ Nexti to run one instruction at a time instead of one statement at a
+ time. The accelerators and mouse actions are also similar.
+
+ Additionally, there is an option to enable mixed source and assembly.
+
+Register window:
+
+ This displays the registers. It may have to be resized to properly
+ display all the registers. The displayed registers can be selected
+ via the Options|Config menu item.
+
+Auto Command window:
+
+ Using this window, you can specify a command to be executed frequently.
+ The output will be automatically updated. Options|Accumulate-output
+ can be used to avoid clearing the window each time so that you can
+ accumulate a history.
+
+Expressions:
+
+ The expression window can be used to just calculate an expression, or
+ to watch the value of an expression (ala the `display' command), using
+ the Update button. The expression window will also pop up
+ automatically when an expression is double-clicked in the source window.
+
+Customizing GDBtk
+=================
+
+There are three primary ways to customize GDBtk. One is to modifiy the
+appropriate X resources. The other is to hack a ~/.gdbtkinit file. The last
+is to change the files in gdbtcl, which defines the most basic interface
+elements.
+
+X resources give you control over things like the choice of fonts, color
+schemes and some geometry info.
+
+For more serious customizations, you will probably need to hack your
+~/.gdbtkinit or gdbtcl files.
+
+X Resources
+===========
+
+ The class name for GDBtk is `Gdb', and it's appname is `gdb'. The top-
+level windows have instance names of `src', 'asm', 'reg', and 'cmd'. The main
+display area in each has the class `Text'. So, to change the font in all the
+main display areas, something like the following will do:
+
+ Gdb*Text*font: fixed
+
+To change the font in only the source window:
+
+ Gdb*src*Text*font: fixed
+
+To find out the names of the widgets do the following (in the command window):
+
+ tk info comm .*
+
+To get the list of resources (and their classes) for a given widget, do some-
+thing like:
+
+ tk .asm.text config
+
+This will return a list of lists, where each sublist looks something like this:
+
+ {-height height Height 24 25}
+
+The first item is the name of the config option used when creating the widget.
+The second item is the instance name of this resource, the third is the class
+name. The fourth item is the default value, and the last item is the current
+value.
+
+To get info about a single resource, add the config option name to the end of
+the previous command. Ie:
+
+ tk .asm.text config -font
+
+will return just the info about the font.
+
+To find out the class of a window, just do:
+
+ tk winfo class .asm.text
+
+Note that some things may be explicitly overridden by gdbtk.tcl. In
+particular, the `tk colormodel . monochrome' command should probably be
+disabled if you want to use color.
+
+Hacking ~/.gdbtkinit and gdbtcl
+==================================
+~/.gdbtkinit is sourced at the end of gdbtk.tcl. Currently there is no good
+doc on this. See gdbtcl/main.tcl for see what you can change.
+
+The GUI is primarily implemented by Tcl/Tk code which lives in gdbtcl and a
+C file called gdbtk.c. The Tcl/Tk code determines the look and feel, the
+layout, and the functions associated with all of the interface elements. The C
+code is mostly just glue between GDB internals and Tclland. In essence, all of
+the policy is implemented in Tcl/Tk, and is easily changed without recompiling.
+
+To make more serious changes to the interface, such as adding a new window or
+changing the framework, you will have to hack the tcl code. This directory is
+installed in $(libdir) (probably /usr/local/lib/). But, you will probably want
+to hack on your own private copy before putting it up for the rest of the
+users. To find the GDB tcl code, GDB first checks for the environment variable
+GDBTK_LIBRARY. This can be a directory name or a list of directories seperated
+by colons (semicolons on Windows). GDB will check each directory in order until
+it finds "main.tcl". If GDBTK_LIBRARY is not set, GDB will look for
+"gdbtcl/main.tcl" in the current directory, and finally, it will try to find
+the tcl directory in the sources.
+
+Note that the old GDBTK_FILENAME environment variable is no longer used.
+
+Internally, GDBtk is basically GDB, linked with Tcl/Tk, and some glue code that
+interfaces GDB internals to Tclland. This means that GDBtk operates as a
+single program, not a front-end to GDB. All GDB commands, and a great deal of
+the target program state are accessible to the Tcl programmer. In addition,
+there are many callbacks from GDB to notify Tclland of important events.
+
+Here is a brief rundown of the GDB<=>Tcl interfaces:
+
+Tcl->GDB calls:
+ gdb_cmd - sends a text command to gdb. Returns the result
+ gdb_loc - takes PC, and returns a list consisting of a short file name,
+ the function name, a long file name, the line number and the
+ PC (in case you didn't supply it).
+ gdb_sourcelines - Takes a filename, and returns a list of lines that
+ contain code.
+ gdb_listfiles - Returns a list of all of the source files.
+ gdb_stop - Stops the target process.
+ gdb_regnames - Returns a list of all of the register names.
+ gdb_fetch_registers - Returns the contents of the specified registers.
+ gdb_changed_register_list - Returns a list of registers that have
+ changed since the last call.
+ gdb_disassemble - Takes a function or PC. Returns the text of a dis-
+ assembly of the entire function.
+ gdb_eval - Takes an expression. Returns it's value.
+ gdb_get_breakpoint_list - Does the obvious.
+ gdb_get_breakpoint_info - Takes a breakpoint number. Returns a list of
+ info about that breakpoint.
+
+GDB->Tcl callbacks:
+ gdb_tcl_fputs - Sends output into Tcl for the command window.
+ gdb_tcl_query - Pops up a query window.
+ gdbtk_tcl_breakpoint - Notifies Tcl of changes to a breakpoint.
+ gdbtk_tcl_idle - Notifies Tcl that debugged process is now idle.
+ gdbtk_tcl_busy - Notifies Tcl that debugged process is now running.
+
+For details, see the usage in gdbtk.tcl, or the definitions in gdbtk.c.
+
+Additionally, there is a new GDB command `tk', which can be used to poke at
+Tk/Tcl from the command window.
+
+Problems
+========
+
+During building, you may run into problems with finding Tcl, Tk or X11. Look
+in gdb/Makefile, and fix TCL_CFLAGS, TCL, TK_CFLAGS, TK, and ENABLE_CLIBS as
+appropriate.
+
+If you one of the following messages when you run gdb:
+
+ Tcl_Init failed: can't find init.tcl; perhaps you need to
+ install Tcl or set your TCL_LIBRARY environment variable?
+or
+ Tk_Init failed: can't find tk.tcl; perhaps you need to
+ install Tk or set your TK_LIBRARY environment variable?
+
+then you haven't installed Tcl or TK properly. Fix the appropriate environment
+variable to point at the {tcl tk}/library directory, and restart gdb.
+
+If you get the following:
+
+ /usr/local/lib/gdbtk.tcl:1: couldn't read file "/usr/local/lib/gdbtk.tcl": No such file or directory
+ Stack trace:
+ can't unset "auto_index": no such variable
+ while executing
+ "unset auto_index"
+
+then GDBtk wasn't installed properly. You can set the GDBTK_FILENAME
+environment variable to point at the gdbtk.tcl in your source directory. Note
+that the stack trace displayed here is not valid. If you actually get an error
+in gdbtk.tcl, the stack trace is useful to pinpoint the location.
+
+Known Bugs
+==========
+
+generic problems
+
+ o If you open an Assembly window before you have run the program, gdbtk
+ pops up a dialog box titled "Error in Tcl Script" with the contents
+ "Error: No function contains the specified address". Trying to then
+ do other things brings up a dialog box with the contents "Error:
+ can't read 'current_asm_label': no such variable.
+
+ Solution: Close Assembly window when there is no program running.
+
+ o If you open Registers window before you have run the program, gdbtk
+ pops up a dialog box titled "Error in Tcl Script" with the contents
+ "Error: No registers". Trying to then do other things, like use the
+ Start button to run the program, repeatedly produce the same dialog
+ box and the action is not performed.
+
+ Solution: Close Registers window when there is no program running.
+
+ o Expressions are sometimes not displayed correctly in the Expression
+ window. I.E. "argc" works, as does "*(argv+argc)" but not "argv[argc]".
+
+ Solution: None
+ [ I believe this problem is fixed, but I have not tested it ]
+
+ o The Breakpoint window does not get automatically updated and changes
+ made in the window are not reflected back in the results from "info br".
+ I.E. the breakpoint count in the window is not updated at each hit and
+ enabling/disabling the breakpoint from the Breakpoint window has no effect.
+
+ Solution: Use the command interface to control breakpoints and don't
+ open a Breakpoint window.
+
+ o Sometimes while an expression window is active you get a dialog box
+ that complains "Error: invalide command name ".expr.e5.expr" for
+ example. The Tcl stack trace looks something like:
+
+ invalid command name ".expr.e5.expr"
+ while executing
+ "$e.expr get 0.0 end"
+ invoked from within
+ "set expr [$e.expr get 0.0 end]..."
+ (procedure "update_expr" line 17)
+ invoked from within
+ "update_expr $expr_num"
+ invoked from within
+ "if $expr_update_list($expr_num) {
+ update_expr $expr_num
+ .
+ .
+ .
+
+ Solution: None except close expression window and reopen it.
+
+ o If you select the "Down" button in either the Source or Assembly
+ window while in the bottom (innermost) frame, the error message that
+ results goes just to the command window and may be missed if the
+ command window is not open. This may also apply to other messages
+ as well. It should probably put up a notification box instead.
+
+ Solution: Keep Command window open to see error messages.
+
+ o Not really a problem, but it would be nice to have a backtrace
+ window.
+
+ Solution: Do bt in command window?
+
+ o Also not really a problem, but it might be nice to have a frame/stack
+ window that displays the last N words on the stack, along with
+ indications about which function owns a particular frame, how the
+ frame pointers are chained, and possibly the names of variables
+ alongside their frame slots.
+
+m68k-hp-hpux9.00:
+
+ o Attempting to use a Register window results in a Tcl Script Error
+ "Error: Erroneous arithmetic operation". The Tcl stack trace is:
+
+ while executing
+ "gdb_fetch_registers $reg_format $regnum"
+ invoked from within
+ "set regval [gdb_fetch_registers $reg_format $regnum]..."
+ ("foreach" body line 2)
+ invoked from within
+ "foreach regnum $reg_display_list {
+ set regval [gdb_fetch_registers $reg_format $regnum]
+ set regval [format "%-*s" $valwidth $regval]
+ $win del ..."
+ invoked from within
+ "if {$which == "all"} {
+ set lineindex 1
+ foreach regnum $reg_display_list {
+ set regval [gdb_fetch_registers $reg_format $regnum]
+ set regval [f ..."
+ (procedure "update_registers" line 16)
+ invoked from within
+ "update_registers all"
+ .
+ .
+ .
+
+
+/* Local variables: */
+/* change-log-default-name: "ChangeLog-gdbtk" */
+/* End: */
diff --git a/gdb/gdbtk/generic/ChangeLog-gdbtk b/gdb/gdbtk/generic/ChangeLog-gdbtk
new file mode 100644
index 00000000000..47cc9887edf
--- /dev/null
+++ b/gdb/gdbtk/generic/ChangeLog-gdbtk
@@ -0,0 +1,2655 @@
+Fri Feb 4 23:19:03 2000 Andrew Cagney <cagney@b1.cygnus.com>
+
+ * gdbtk.c (gdbtk_init): Update default path to tcl code - now
+ gdbtk/library.
+
+Fri Feb 4 23:19:03 2000 Andrew Cagney <cagney@b1.cygnus.com>
+
+ * ChangeLog-gdbtk, gdbtk-cmds.c, gdbtk-hooks.c, gdbtk-variable.c,
+ gdbtk-varobj.c, gdbtk-wrapper.c, gdbtk-wrapper.h, gdbtk.c,
+ gdbtk.h: Moved here from the top level GDB directory.
+
+Tue Feb 1 00:17:12 2000 Andrew Cagney <cagney@b1.cygnus.com>
+
+ * gdbtk-hooks.c, gdbtk-variable.c, gdbtk-wrapper.c,
+ gdbtk-wrapper.h, gdbtk.h: Update to reflect rename of gdb-file /
+ GDB_FILE to ui-file / ``struct ui_file''.
+
+2000-01-31 Keith Seitz <kseitz@nwlink.com>
+
+ * gdbtk-cmds.c (gdb_disassemble_driver) If using multi-arch, set the
+ architecture in the disassembly info.
+
+Mon Jan 31 18:32:06 2000 Andrew Cagney <cagney@b1.cygnus.com>
+
+ * gdbtk-variable.c, gdbtk-cmds.c, gdbtk.c: Include "tui/tui-file.h"
+
+1999-09-23 Fernando Nasser <fnasser@totem.to.cygnus.com>
+
+ * gdbtk-varobj.c (variable_value): Fix small memory leak.
+
+Mon Jan 3 01:09:24 2000 Andrew Cagney <cagney@b1.cygnus.com>
+
+ * gdbtk-cmds.c (gdb_get_mem): Use builtin_type_int32 et.al. to
+ force the word size to 32 bits.
+
+Thu Nov 18 18:19:59 1999 Andrew Cagney <cagney@b1.cygnus.com>
+
+ * gdbtk.c (tk_command), gdbtk-hooks.c (gdbtk_readline),
+ gdbtk-variable.c (variable_type): Replace strdup with xstrdup.
+
+Thu Nov 18 19:03:28 1999 Andrew Cagney <cagney@b1.cygnus.com>
+
+ * gdbtk-cmds.c (gdb_get_mem): Document nbr parameter. Fix check
+ on nbr and nbytes parameters.
+
+1999-11-18 Tom Tromey <tromey@cygnus.com>
+
+ * gdbtk-cmds.c (gdb_actions_command): Updated for new
+ get_tracepoint_by_number.
+
+Tue Nov 9 15:40:51 1999 Andrew Cagney <cagney@b1.cygnus.com>
+
+ * gdbtk-cmds.c (gdb_get_mem): Keep calling
+ target_read_memory_partial until all the data is read.
+
+1999-11-01 Tom Tromey <tromey@cygnus.com>
+
+ * gdbtk-cmds.c (gdb_actions_command): Updated for new
+ get_tracepoint_by_number.
+
+Fri Oct 15 18:34:41 1999 Andrew Cagney <cagney@b1.cygnus.com>
+
+ * gdbtk-hooks.c (ui_load_progress_hook): Move extern declaration
+ to defs.h.
+ (gdbtk_load_hash): Update SECTION argument to match prototype.
+ Make static.
+
+Wed Oct 13 17:57:17 1999 Andrew Cagney <cagney@b1.cygnus.com>
+
+ * gdbtk-hooks.c (gdbtk_flush): Delete.
+ (gdbtk_add_hooks): Don't initialize flush_hook.
+
+Mon Oct 11 10:19:04 1999 Andrew Cagney <cagney@b1.cygnus.com>
+
+ * gdbtk-cmds.c (gdb_get_tracepoint_info): Use paddr_nz to convert
+ the address into a string.
+
+1999-10-05 James Ingham <jingham@leda.cygnus.com>
+
+ * gdbtk-cmds.c (map_arg_registers): Don't stop at the first
+ undefined register, but skip it and go on. There may be other
+ defined registers higher up in the list.
+
+1999-09-29 Fred Fish <fnf@cygnus.com>
+
+ * gdbtk-varobj.c (variable_create): Replace cast "(CORE_ADDR) - 1"
+ with the more obviously intended expression "(CORE_ADDR) -1".
+
+1999-09-23 Fernando Nasser <fnasser@totem.to.cygnus.com>
+
+ * gdbtk-variable.c (variable_value): Fix handling of baseclasses and
+ correct the behavior when it is not a baseclass (both cases could
+ potentially dumping core).
+
+1999-09-23 James Ingham <jingham@leda.cygnus.com>
+
+ * gdbtk.c (gdbtk_init): Add the initialization of the shell
+ execute command under cygwin.
+
+ * gdbtk-hooks.c (gdbtk_attach): New function, run from the attach
+ hook.
+ (gdbtk_detach): New function, run from the detach hook.
+ (gdbtk_add_hooks): Add the attach & detach hooks.
+
+1999-09-23 Fernando Nasser <fnasser@totem.to.cygnus.com>
+
+ * gdbtk-varobj.c (variable_create): Dynamically allocate variable
+ object name string.
+
+1999-09-22 Fernando Nasser <fnasser@totem.to.cygnus.com>
+
+ * gdbtk-variable.c (_gdb_variable): Remove unused entry.
+ (variable_update): Fix error in list initialization (apparently
+ innocuous).
+ (type_changeable): Fix handling of typedef'ed structs and
+ unions (removing c_variable.exp test case 2.12 FAIL).
+
+Mon Sep 20 18:03:28 1999 Andrew Cagney <cagney@b1.cygnus.com>
+
+ * gdbtk-variable.c (new_root_variable): Fix prototype declaration.
+ * gdbtk.c (_initialize_gdbtk): Add declaration.
+ * gdbtk-cmds.c (tracepoint_exists): Make static. Add declaration.
+ * gdbtk.c (gdbtk_add_hooks): Move declaration from here.
+ * gdbtk.h (gdbtk_add_hooks): To here.
+
+Fri Sep 17 19:00:39 1999 Andrew Cagney <cagney@b1.cygnus.com>
+
+ * gdbtk-cmds.c: Include "source.h".
+ (gdb_load_disassembly): Fix printf calls.
+ Makefile.in (gdbtk-cmds.o): Add dependency on source.h.
+
+ * gdbtk.c: Include <itk.h> for Itk_Init.
+
+1999-09-17 Fernando Nasser <fnasser@totem.to.cygnus.com>
+
+ * gdbtk-varobj.c: New file. It supersedes gdbtk-variable.c and
+ uses standard gdb varobj code.
+
+Fri Sep 3 20:16:54 1999 Andrew Cagney <cagney@b1.cygnus.com>
+
+ * gdbtk.c (gdbtk_init): Cast ``host_name'' and ``target_name'' to
+ void. While Tcl_SetVar2 treats the value argument as read-only
+ its prototype does not specify const for the parameter.
+
+Mon Aug 30 17:56:28 1999 Andrew Cagney <cagney@b1.cygnus.com>
+
+ * gdbtk.c, gdbtk-hooks.c, gdbtk-cmds.c: #include <unistd.h> moved
+ to defs.h.
+
+Mon Aug 30 15:34:42 1999 Andrew Cagney <cagney@b1.cygnus.com>
+
+ * gdbtk-hooks.c (x_event): Missing result to return - return 0.
+ Make in_x_event volatile.
+ (in_fputs): Make volatile.
+
+1999-09-02 Stan Shebs <shebs@andros.cygnus.com>
+
+ * gdbtk.c: Include version.h, remove inconsistent decls of
+ host_name and target_name.
+
+1999-08-27 James Ingham <jingham@leda.cygnus.com>
+
+ * gdbtk.h: Add def'n for gdbtk_fputs, since it is needed outside
+ of gdbtk-hooks.c
+
+ * gdbtk-cmds.c (gdb_load_disassembly): Really implement this
+ function. Load the source widget from C.
+ (gdbtk_load_source): Helper for the above, which loads source lines.
+ (gdbtk_load_asm): Helper for the above, which loads assembly
+ lines.
+ (gdb_restore_fputs): New function, restore the gdbtk_fputs hook,
+ in case somebody supressed it, and then errored out before they
+ got a chance to put it back.
+
+1999-08-10 James Ingham <jingham@leda.cygnus.com>
+
+ * gdbtk-hooks.c: Remove the gdb_disassembly_flavor_hook. Use the
+ set_hook instead.
+
+Mon Aug 9 10:28:22 1999 Andrew Cagney <cagney@b1.cygnus.com>
+
+ * gdbtk.c, gdbtk-cmds.c: Delete #if ANSI_PROTOTYPES code, GDB
+ assumes ISO-C.
+
+1999-08-06 Tom Tromey <tromey@cygnus.com>
+
+ * gdbtk-hooks.c (gdbtk_add_hooks): Set `set_hook'.
+ (gdbtk_set_hook): New function.
+
+1999-08-05 Keith Seitz <keiths@cygnus.com>
+
+ * gdbtk-variable.c (new_variable): Add missing return value.
+
+1999-08-02 James Ingham <jingham@leda.cygnus.com>
+
+ * gdbtk-cmds.c: Misc. Cleanups... Mostly wrapping at 80
+ characters.
+ (gdb_loadfile): Go straight to the widget command to insert the
+ text, rather than through the interpreter. Gives about 2x-3x
+ speedup in rendering the source text.
+ (gdb_disassemble): Rewrite to separate out the generic disassembly
+ work from the printing part. The former goes in
+ gdb_disassembly_driver. This way I can share the code with the
+ version that loads the text widget directly.
+ (gdb_load_disassembly): New function. This will load the text
+ widget directly (not done yet).
+ (gdbtk_load_source): Load the text widget with a source line.
+ (gdbtk_load_asm): Load the text widget with an assembly line.
+ (gdbtk_print_source): Print a source line to stdout.
+ (gdbtk_print_asm): Print an assembly line to stdout.
+ (gdb_disassemble_driver): New function.
+
+ * gdbtk.h: Fix a compiler warning from Keith's 07-27 checkin.
+
+1999-08-02 Keith Seitz <keiths@cygnus.com>
+
+ * gdbtk-variable.c (CPLUS_FAKE_CHILD): NULL variables are not
+ "fakes", either.
+
+1999-07-27 Keith Seitz <keiths@cygnus.com>
+
+ * gdbtk-variable.c: Rewrite. :-)
+ * gdbtk-wrapper.c (GDB_value_ind): New function.
+ (GDB_value_slice): New function.
+ (GDB_value_coerce_array): New function.
+ (GDB_value_struct_elt): New function.
+ (GDB_value_cast): New function.
+ (GDB_get_frame_block): New function.
+ (wrap_value_slice): New function.
+ (wrap_value_coerce_array): New function.
+ (wrap_value_struct_elt): New function.
+ (wrap_value_cast): New function.
+ (wrap_get_frame_block): New function.
+ * gdbtk-wrapper.h: Add declarations for above new functions.
+ * gdbtk-cmds.c (gdb_selected_block): New function.
+ (gdb_get_blocks): New function.
+ (gdb_block_vars): New function.
+
+1999-07-16 Keith Seitz <keiths@cygnus.com>
+
+ * gdbtk-cmds.c (gdb_loc): Change all references of "stop_pc" to
+ "read_pc ()".
+
+ * gdbtk.c (target_is_native): New function.
+ (target_should_use_timer): Use target_is_native to determine whether
+ the timer should run.
+ * gdbtk.h (target_is_native): Add prototype.
+ * gdbtk-cmds.c (gdb_disassemble): Use target_is_native to determine if
+ we should disassemble from inferior memory.
+
+1999-07-09 Fernando Nasser <fnasser@totem.to.cygnus.com>
+
+ * gdbtk-variable.c (variable_obj_command): Add missing comments
+ for object variable commands.
+
+Fri Jul 9 12:06:36 1999 Andrew Cagney <cagney@b1.cygnus.com>
+
+ * gdbtk-cmds.c (Gdbtk_Init): Explicitly route log/debug and target
+ output to stderr instead of stdout.
+
+1999-06-21 James Ingham <jingham@leda.cygnus.com>
+
+ * gdbtk.c (target_should_use_timer): Add check for "linuxthreads"
+ to enable the timer for Linux as well as other natives.
+
+1999-06-15 Keith Seitz <keiths@cygnus.com>
+
+ * gdbtk-hooks.c (gdbtk_annotate_signal): Run
+ gdbtk_stop_idle_callback so that signals don't interfere
+ with the stop button.
+
+1999-06-10 Keith Seitz <keiths@cygnus.com>
+
+ * gdbtk.c (gdbtk_init): Add host_name and target_name to
+ GDBStartup.
+
+ * gdbtk-cmds.c (gdb_clear_file): Delete breakpoints and
+ clear the exec file, too.
+ (gdb_loadfile): Don't close a file that's not opened until
+ later.
+
+Wed Jun 9 14:21:40 1999 Andrew Cagney <cagney@b1.cygnus.com>
+
+ * gdbtk-cmds.c (old_regs): Change array to a pointer.
+ (setup_architecture_data): New function.
+ (Gdbtk_Init): Call setup_architecture_data. Register ``old_regs''
+ as an architecture dependant variable.
+
+1999-05-25 Keith Seitz <keiths@cygnus.com>
+
+ * gdbtk-wrapper.c (GDB_val_print): Fix compiler warnings.
+ (wrap_val_print): Ditto.
+ (GDB_block_for_pc): Ditto.
+ (wrap_block_for_pc): Ditto.
+ (GDB_find_frame_addr_in_frame_chain): Ditto.
+ (wrap_find_frame_addr_in_frame_chain): Ditto.
+
+ * gdbtk-variable.c (variable_create): Rename "-pc" option
+ to the more explicit name "-frame". Update usage.
+ (create_variable): Swallow errors before parse_exp_1, too.
+ If no frame is given as an argument, use the current frame;
+ otherwise, use the current block in the specified frame.
+ (variable_children): Check for errors creating children.
+ (create_child): Ditto.
+
+ * gdbtk-cmds.c (get_selected_frame): New function.
+ (Gdbtk_Init): Add get_selected_frame to interpreter.
+ (gdb_get_vars_command): Use current block in selected frame
+ if no args specified.
+
+ * Makefile.in (gdbtk-cmds.o): Depend on frame.h, too
+
+Tue May 25 16:12:57 1999 Andrew Cagney <cagney@b1.cygnus.com>
+
+ * gdbtk-cmds.c (REGISTER_CONVERTIBLE,
+ REGISTER_CONVERT_TO_VIRTUAL): Delete default definitions.
+ gdbarch.h ensures that there is always a definition available.
+
+1999-05-20 Andrew Cagney <cagney@b1.cygnus.com>
+
+ Mon Apr 26 09:15:27 1999 Andrew Cagney <cagney@b1.cygnus.com>:
+ * gdbtk.c (x_event_wrapper): Wrapper for x_event that matches
+ signal function signature.
+ (gdbtk_start_timer): set .sa_handler to x_event_wrapper instead of
+ x_event.
+
+1999-05-14 Keith Seitz <keiths@cygnus.com>
+
+ * configure.in (ENABLE_GDBTK): Don't clobber WIN32LIBS.
+ * configure: Regenerated.
+
+1999-04-12 Keith Seitz <keiths@cygnus.com>
+
+ * gdbtk-variable.c (variable_value_changed): Swallow errors from
+ evaluate_expression.
+
+1999-04-09 James Ingham <jingham@cygnus.com>
+
+ * gdbtk-cmds.c (gdb_get_mem): Use the Tcl list API to add the
+ ASCII entry to the return list. We were trying to do the quoting
+ by hand which is bound to lose in some cases.
+
+1999-04-06 Martin Hunt <hunt@cygnus.com>
+
+ * gdbtk-hooks.c (gdbtk_annotate_signal): New function.
+ Notifies GDBtk when a signal occurs.
+
+1999-04-02 Keith Seitz <keiths@cygnus.com>
+
+ * gdbtk-hooks.c (gdbtk_force_detach): New global.
+ (x_event): Change to return gdbtk_force_detach so that
+ callers will know if we want to detach. See comments.
+ (gdbtk_wait): Insert calls to gdbtk_start/stop_timer. This
+ is a nop for most hosts/targets. Remove ice-specific code.
+
+ * gdbtk-cmds.c (gdb_stop): Add "detach" option, which forces
+ gdb to detach from the target. See comments.
+
+ * gdbtk.c (target_should_use_timer): New function.
+ (gdbtk_start_timer): Only use on unix native targets.
+ (gdbtk_stop_timer): Ditto.
+
+ * gdbtk.h (x_event): Update declaration: now returns an int.
+
+1999-03-29 Stan Shebs <shebs@andros.cygnus.com>
+
+ * gdbtk.c, gdbtk-cmds.c, gdbtk-hooks.c: Don't include setjmp.h.
+
+1999-03-29 Keith Seitz <keiths@cygnus.com>
+
+ * gdbtk-cmds.c (pc_function_name): New function which returns the
+ source name (regardless of mangling) of the function at a given PC.
+ (gdb_get_function_command): Use it.
+ (gdb_get_tracepoint_info): Ditto.
+ (gdb_loc): Ditto.
+ (gdb_get_breakpoint_info): Ditto.
+
+ * Makefile.in (install-only): Don't install help/index.toc: it doesn't
+ exist anymore.
+
+Wed Mar 10 19:37:23 1999 Geoffrey Noer <noer@cygnus.com>
+
+ * gdbtk-cmds.c: Don't need to include any Win32 API headers.
+ * gdbtk-hooks.c: Include Windows.h, not just winuser.h.
+ * gdbtk.c: Ditto.
+
+1999-03-04 Martin Hunt <hunt@cygnus.com>
+
+ * gdbtk-hooks.c (gdbtk_load_hash): Change download_hash()
+ to Download::download_hash().
+
+1999-03-01 Martin Hunt <hunt@cygnus.com>
+
+ * gdbtk.c (TclDebug): Increase buffer size to 10000, in case
+ backtraces are very long.
+
+1999-02-26 James Ingham <jingham@cygnus.com>
+
+ * gdbtk-cmds.c (gdb_search): Add a -filename switch, which returns
+ the file in which the function or type was defined, along with the
+ function...
+
+ * gdbtk.c (gdbtk_find_main): The external editor stuff was getting
+ set twice...
+
+1999-02-18 Martin Hunt <hunt@cygnus.com>
+
+ * gdbtk-cmds.c (gdb_disassemble): When debugging native threads,
+ set disassemble_from_exec to 0. This fixes bugs where disassembly
+ of threaded programs failed.
+
+1999-02-16 James Ingham <jingham@cygnus.com>
+
+ * gdbtk.c (gdbtk_init): Remove redundant setting of the external
+ editor variables.
+
+1999-02-11 Martin Hunt <hunt@cygnus.com>
+
+ * gdbtk-variable.c (variable_format): Enable binary format.
+
+1999-02-11 Martin Hunt <hunt@cygnus.com>
+
+ * gdbtk-hooks.c: Change ALL Tcl_Eval calls in hooks to
+ call report_error() if there are errors.
+
+1999-02-11 Martin Hunt <hunt@cygnus.com>
+
+ * gdbtk.c, gdbtk-cmds.c, gdbtk-hooks.c: Removed old IDE stuff.
+
+1999-02-09 Martin Hunt <hunt@cygnus.com>
+
+ * gdbtk-hooks.c: Remove gdbtk_ignorable_warning prototype.
+ It is in gdbtk.h.
+ (report_error): New function. Displays debugging information
+ if a hook function fails. All hook functions should probably
+ call this.
+ (gdbtk_warning): Call report_error() if there is a problem.
+ (gdbtk_register_changed): Call report_error() if there is a problem.
+ (gdbtk_memory_changed): Call report_error() if there is a problem.
+ (gdbtk_ignorable_warning): Pass along class argument. If there
+ is a problem, call report_error().
+
+ * gdbtk-cmds.c: Remove TclDebug prototype. It is in gdbtk.h.
+ (gdb_loadfile): Add class name to gdbtk_ignorable_warning call.
+
+ * gdbtk.c (TclDebug): Add "priority" argument. Calls "dbug"
+ instead of "debug". Removed non-ANSI ifdefs.
+
+ * gdbtk.h: Fixed protos for gdbtk_ignorable_warning and TclDebug.
+
+1999-02-05 James Ingham <jingham@cygnus.com>
+
+ * Makefile.in: Add GDBTK_CFLAGS - this is now used to hold
+ -fwritable-strings when compiling with Tk8.1.
+ * configure.in: Add GDBTK_CFLAGS, set it to -fwritable-strings for
+ Tcl/Tk8.1 & greater.
+ * acinclude.m4: Move the rest of the defines to find Itcl, Itk &
+ Tix from aclocal.m4 to here.
+ * aclocal.m4: regenerate.
+ * configure: regenerate.
+
+ * gdbtk-hooks.c (x_event): Tcl_ObjGetVar2 was removed from
+ Tcl8.1. Use Tcl_GetVar2 instead.
+ * gdbtk-hooks.c (gdbtk_trace_find): Fix up call to
+ Tcl_GlobalEvalObj for Tcl/Tk 8.1.
+ * gdbtk-hooks.c (gdbtk_trace_start_stop): Call to Tcl_EvalObj was
+ inefficient, replace with call to Tcl_GlobalEval.
+ * gdbtk.c: Don't swap out the Tcl_Alloc calls in gdbtk.c. We took
+ care of that in Tcl itself for 8.1.
+ * gdbtk.c: Remove const from the script string since Tcl8.1 has
+ taken to scribbling sentinals into strings passed to it again...
+
+ * gdbtk-cmds.c (wrapped_call): Change declaration of 1st arg from
+ char * to PTR to eliminate warning.
+ * gdbtk-cmds.c (perror_with_name_wrapper): Ditto
+
+Thu Feb 4 10:35:28 1999 Keith Seitz <keiths@cygnus.com>
+
+ * gdbtk-variable.c (variable_create): Allocate enough
+ space to hold the NULL, too!
+
+Wed Feb 3 13:37:07 1999 Keith Seitz <keiths@cygnus.com>
+
+ * gdbtk-variable.c (variable_create): Add parentheses to the name
+ so that casts do not confuse the expression parser.
+
+1999-02-03 Keith Seitz <keiths@cygnus.com>
+
+ * gdbtool.ico: Add missing desktop image.
+
+1999-02-02 Martin Hunt <hunt@cygnus.com>
+
+ * gdbtk-cmds.c (get_register): For RAW display, concat all the
+ pieces together before calling fputs.
+
+1999-02-01 Martin Hunt <hunt@cygnus.com>
+
+ * gdbtk-cmds.c: (gdb_set_bp): Change the "type" argument
+ to be ASCII instead of an integer. Currently accepts "temp"
+ or "normal". Fixed error messages.
+ (gdb_set_bp_addr): Ditto.
+
+1999-01-29 James Ingham <jingham@cygnus.com>
+
+ * gdbtk.c (gdbtk_init): Set the fputs_unfiltered_hook to
+ gdbtk_fputs BEFORE you eval script. The old code was setting it
+ to null until after you did this, but that is wrong, because it
+ will cause the output of CAUGHT errors to go to gdb_stderr, which
+ is wrong. You only want to write errors to the console if the
+ eval generates an error.
+
+1999-01-29 Martin Hunt <hunt@cygnus.com>
+
+ * gdbtk-cmds.c (gdb_get_breakpoint_info): When printing addresses,
+ do not rely on the format string "%lx" -- it does not exist for all
+ hosts. Use paddr instead.
+ (gdb_loadfile): Increase maximum line size to pass testsuite cases.
+
+ * gdbtk-hooks.c (gdbtk_add_hooks): Remove pc_changed_hook and
+ add register_changed_hook and memory_changed_hook.
+ (gdbtk_register_changed): New function.
+ (gdbtk_memory_changed): New function.
+
+ * gdbtk.c (gdbtk_init): Create tcl warp_pointer command
+ for use with testing.
+
+ * gdbtk-cmds.c (gdb_loc): Fix for case where there are only
+ minimal symbols. Also make gdb_loc return the shared library
+ the location is in, if it is in one.
+
+1999-01-27 James Ingham <jingham@cygnus.com>
+
+ * gdbtk-wrapper.c: Missed a couple of places where FILE->GDB_FILE
+ in the fputs_unfiltered_hook needed to propagate.
+
+1999-01-27 James Ingham <jingham@cygnus.com>
+
+ Merging in changes from gdbtk-980810 - the Itcl3
+ gdb branch.
+
+ 1999-01-12 Martin Hunt <hunt@cygnus.com>
+
+ * gdbtk-cmds.c (gdb_loadfile): Increase maximum line size so
+ files with very long lines get numbered correctly.
+
+ Thu Jan 7 06:50:32 1999 Keith Seitz <keiths@cygnus.com>
+
+ * gdbtk-hooks.c (gdbtk_add_hooks): Add the error_begin_hook;
+ (gdbtk_error_begin): New function.
+ (gdbtk_fputs): If GDBTK_ERROR_ONLY is set, treat output to
+ any stream as if it had come from gdb_stderr.
+
+ * gdbtk.h: Define GDBTK_SYMBOL_SOURCE_NAME: does the same thing
+ as SYMBOL_SOURCE_NAME, except that it NEVER returns a mangled name.
+ Define GDBTK_ERROR_ONLY flag for result_ptr.
+
+ * gdbtk-cmds.c (gdb_listfuncs): Use SYMBOL_DEMANGLED_NAME to
+ get the symbol's fully demangled name (including class and
+ args for overloaded funcs), not cplus_demangle.
+ (get_frame_name): Use GDBTK_SYMBOL_SOURCE_NAME to get the name
+ of the frame level.
+
+ * gdbtk-wrapper.c, gdbtk-wrapper.h:
+ (GDB_val_print): Allow caller to specify all function args to val_print.
+ (wrap_val_print): Ditto.
+
+ * gdbtk-variable.c (variable_value): Clear addressprint when getting
+ value of C++ reference-type variables
+ If we errored because a parent (struct pointer) was junk, output
+ an error message indicating so.
+ (call_gdb_val_print): Tell val_print to dereference C++ reference
+ types.
+ (number_of_children): void * also has no children.
+ (get_call_output): Clear any error flags that may have been set
+ as a result of error_begin.
+
+ * utils.c (error_begin_hook): New hook.
+ (error_begin): Call error_begin_hook so that the GUI
+ gets notified.
+
+ * defs.h (error_begin_hook): Declare.
+
+ Wed Jan 6 08:43:31 1999 Keith Seitz <keiths@cygnus.com>
+
+ * gdbtk-wrapper.c, gdbtk-wrapper.h: Add wrappers for parse_exp_1,
+ evaluate_type, block_for_pc, block_innermost_frame, reinit_frame_cache,
+ and find_frame_addr_in_frame_chain.
+
+ * gdbtk-variable.c (variable_create): Check for failure when
+ creating variables.
+ (create_variable): Use wrapped calls for block_for_pc, parse_exp_1,
+ and block_innermost_frame.
+ Return NULL if parse_exp_1 fails.
+ Attempt to prohibit creating a gdb_variable for type names.
+ (variable_value_changed): Use wrapped calls for reinit_frame_cache and
+ find_frame_addr_in_frame_chain.
+ (variable_type): Use wrapped call for evaluate_type.
+ (variable_value): Use wrapped call for parse_exp_1.
+ (variable_editable): Use wrapped call for evaluate_type.
+
+ Tue Jan 5 11:37:17 1999 Keith Seitz <keiths@cygnus.com>
+
+ * gdbtk-variable.c: New variable object interface.
+ * gdbtk-wrapper.c, gdbtk-wrapper.h: New wrappers for safely calling
+ gdb functions without the fear of longjmp'ing.
+ * configure.in (CONFIG_OBS): Add gdbtk-wrapper.o and gdbtk-variable.o
+ when gdbtk is enabled.
+ * configure: Regenerate.
+ * Makefile.in: Add gdbtk-wrapper.o and gdbtk-variable.o
+ * gdbtk-cmds.c (call_wrapper): Export so that other files can use.
+ (Gdbtk_Init): Initialize new variable interface.
+ * gdbtk.h: Add declaration for call_wrapper.
+
+ Tue Jan 5 11:19:14 1999 Keith Seitz <keiths@cygnus.com>
+
+ * gdbtk-cmds.c (gdb_loc): Call resolve_sal_pc to before using
+ the sal's pc.
+
+ * gdbtk.c (gdbtk_init): Add global array GDBStartup to interpreter
+ which contains any startup info. Add "inhibit_prefs" (follows -nx)
+ so that "-nx" turns preference reading/writing off.
+
+ Mon Dec 21 11:11:02 1998 Keith Seitz <keiths@cygnus.com>
+
+ * gdbtk-cmds.c (get_register): Call get_saved_register instead of
+ read_relative_register_raw_bytes to fetch registers.
+
+ Thu Dec 17 09:00:56 1998 Keith Seitz <keiths@cygnus.com>
+
+ * gdbtk-cmds.c (gdb_search): Don't mention C++ RTTI and
+ global constructor/destructor symbols.
+
+ Thu Nov 12 15:20:15 1998 Jim Ingham <jingham@cygnus.com>
+ * More bug fixes merged in from devo.
+
+ * gdbtk-cmds.c (gdb_cmd): Added an optional second argument to the
+ gdb_cmd, which is from_tty. This is passed to the gdb command
+ parser. It is 0 by default, and the console window passes 1.
+
+ * gdbtk-cmds.c: moved disassemble_from_exec from gdbtk.c to gdbtk-cmds.c
+ with all the other link-var'ed variables
+
+ * gdbtk-hooks.c (gdbtk_trace_find): Only run the hook functions if
+ we are called from_tty.
+
+ * gdbtk-hooks.c (gdbtk_trace_start_stop): Set the trace buttons
+ from a trace_start_command callback rather than doing it as a
+ special case in gdb_cmd.
+
+ * tracepoint.c (tstart_command, tstop_command): Add call to
+ trace_start_stop_hook here.
+
+ 1998-11-04 Martin M. Hunt <hunt@cygnus.com>
+
+ * gdbtk-cmds.c (gdb_set_bp_addr): For callback, send full
+ pathname instead of just basename.
+
+ 1998-11-03 Keith Seitz <keiths@cygnus.com>
+ * v850ice.c (do_gdb): New function.
+ (ice_stepi): Use do_gdb to step properly.
+ (ice_nexti): Use do_gdb to step properly.
+ (view_source): Correct call to src window's location for new version.
+
+ Tue Aug 25 18:13:30 1998 Jim Ingham <jingham@cygnus.com>
+
+ * gdbtk.c (gdbtk_init): I hadn't excised ALL the old startup code,
+ so it was not working correctly. Now it does.
+
+ Fri Aug 21 14:37:40 1998 Jim Ingham <jingham@cygnus.com>
+
+ * gdbtk.c (gdbtk_init): Changed the startup code to use
+ tcl_findLibrary
+
+
+
+
+on Dec 28 17:44:36 1998 David Taylor <taylor@texas.cygnus.com>
+
+
+ The following changes were made by Jim Blandy <jimb@cygnus.com>,
+ Edith Epstein <eepstein@cygnus.com>, Elena Zannoni
+ <ezannoni@cygnus.com> Stan Shebs <shebs@cygnus.com>, and David
+ Taylor <taylor@cygnus.com>, as part of the project to merge in
+ changes originally made by HP; HP did not create ChangeLog
+ entries.
+
+ * gdbtk.c (gdbtk_init): change stderr to gdb_stderr.
+
+ * gdbtk-cmds.c
+ (get_pc_register): Use paddr_nz, not sprintf's %llx and
+ a cast to `long long'. Those aren't portable.
+ (gdb_eval): add embedded_offset param to val_print call
+ (get_register): add embedded_offset param to val_print call
+
+ * gdbtk-hooks.c
+ (tk_command_loop): change instream to a FILE.
+ (gdbtk_flush): change both the declaration and definition to
+ use GDB_FILE rather than FILE.
+
+Mon Dec 21 11:11:02 1998 Keith Seitz <keiths@cygnus.com>
+
+ * gdbtk-cmds.c (get_register): Call get_saved_register instead of
+ read_relative_register_raw_bytes to fetch registers.
+
+Thu Dec 17 09:00:56 1998 Keith Seitz <keiths@cygnus.com>
+
+ * gdbtk-cmds.c (gdb_search): Don't mention C++ RTTI and
+ global constructor/destructor symbols.
+
+Tue Dec 15 10:09:31 1998 Andrew Cagney <cagney@b1.cygnus.com>
+
+ * gdbtk-cmds.c (gdb_disassemble): Fix typo.
+
+Sun Dec 13 09:52:51 1998 Andrew Cagney <cagney@b1.cygnus.com>
+
+ * gdbtk-cmds.c: Update TARGET_PRINT_INSN_INFO, TARGET_PRINT_INSN.
+
+Fri Dec 11 09:52:04 1998 Andrew Cagney <cagney@chook>
+
+ * gdbtk-cmds.c: Replace reg_name with REGISTER_NAME.
+
+Mon Dec 14 13:20:50 1998 Jim Ingham <jingham@cygnus.com>
+
+ * Makefile.in, configure.in configure - add support for LIBGUI
+ outside the IDE context.
+
+Thu Nov 19 13:14:57 1998 Geoffrey Noer <noer@cygnus.com>
+
+ * gdbtk-cmds.c: Can't start using new API names yet. Switch back
+ to calling cygwin32_ funcs until some time has passed...
+ * gdbtk.c: Ditto. Also, include sys/cygwin.h for Cygwin, instead
+ of providing own proto.
+
+Fri Nov 13 00:15:08 1998 Geoffrey Noer <noer@cygnus.com>
+
+ Changes to account for name change from cygwin32 to cygwin and
+ clean up Win32-related ifdefs.
+
+ * gdbtk.c: lose "32" from cygwin_ func calls. ifndef for
+ checking DISPLAY should be for _WIN32, not WINNT.
+ * gdbtk.h: pick GDBTK_PATH_SEP based on _WIN32, not WINNT.
+ * gdbtk-cmds.c (gdb_path_conv): lose "32" from cygwin_ func call,
+ change ifdef to __CYGWIN32__ instead of WINNT.
+ * {gdbtk.c, gdbtk-hooks.c}: __CYGWIN32__ refs drop the "32".
+
+Thu Nov 12 15:20:15 1998 Jim Ingham <jingham@cygnus.com>
+
+ * gdbtk-cmds.c (gdb_cmd): Added an optional second argument to the
+ gdb_cmd, which is from_tty. This is passed to the gdb command
+ parser. It is 0 by default, and the console window passes 1.
+
+ * gdbtk-cmds.c: moved disassemble_from_exec from gdbtk.c to gdbtk-cmds.c
+ with all the other link-var'ed variables
+
+ * gdbtk-hooks.c (gdbtk_trace_find): Only run the hook functions if
+ we are called from_tty.
+
+ * gdbtk-hooks.c (gdbtk_trace_start_stop): Set the trace buttons
+ from a trace_start_command callback rather than doing it as a
+ special case in gdb_cmd.
+
+ * tracepoint.c (tstart_command, tstop_command): Add call to
+ trace_start_stop_hook here.
+
+Wed Nov 4 12:41:42 1998 Jim Ingham <jingham@cygnus.com>
+
+ * gdbtk-cmds.c (gdb_set_bp_addr): Pass the type, enable & thread
+ to gdbtk_tcl_breakpoint.
+ * gdbtk-hooks.c (gdbtk_trace_find): Added this function. It is
+ the hook function for tfind commands.
+ * tracepoint.c (trace_find_command): Added the trace_find_hook,
+ run when you do trace_find_command.
+ * tracepoint.h: Define the trace_find_hook.
+
+1998-11-03 Keith Seitz <keiths@cygnus.com>
+
+ * v850ice.c (do_gdb): New function.
+ (ice_stepi): Use do_gdb to step properly.
+ (ice_nexti): Use do_gdb to step properly.
+ (view_source): Correct call to src window's location for new version.
+
+Mon Nov 2 11:16:10 1998 Jim Ingham <jingham@cygnus.com>
+
+ * gdbtk-cmds (gdb_get_tracepoint_info): Demangle C++ function names.
+
+Fri Oct 30 11:22:23 1998 Jim Ingham <jingham@cygnus.com>
+
+ * gdbtk-cmds (gdb_get_tracepoint_info): Fixed typo.
+
+Wed Oct 28 16:19:02 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * gdbtk-cmds.c (gdb_set_bp_addr): For callback, send full
+ pathname instead of just basename.
+
+Wed Oct 28 10:14:33 1998 Jim Ingham <jingham@cygnus.com>
+
+ * gdbtk-cmds.c: Made the bdtypes & bpdisp arrays shared so they
+ could be used in gdbtk-hooks.c (breakpoint_notify).
+ Also fixed a few error messages to actually print the bp number
+ rather that #%d...
+ * gdbtk-hooks.c (breakpoint_notify): pass more of the information
+ about the breakpoint into the Tcl command, so it does not have to
+ try and guess about information we have on the C side.
+ * gdbtk.h: Export the bptypes & pbdisp arrays.
+
+1998-10-13 Jason Molenda (jsm@bugshack.cygnus.com)
+
+ * gdbtk.c, gdbtk-cmds.c: Cast parameters passed to make_cleanup to
+ use the new make_cleanup_func typedef.
+
+1998-10-08 Keith Seitz <keiths@cygnus.com>
+
+ * gdbtk-hooks.c (gdbtk_add_hooks): Install a hook for
+ (new) file_changed_hook.
+ (gdbtk_exec_file_changed): Rename to gdbtk_exec_file_display
+ to mimic hook's name.
+ (gdbtk_file_changed): New hook function.
+
+Tue Oct 6 22:57:13 1998 Andrew Cagney <cagney@b1.cygnus.com>
+
+ * configure.in (links): Link gdbtcl2 directory instead of gdbtcl.
+
+Mon Oct 5 00:34:00 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * gdbtk-cmds.c (gdb_set_bp_addr): New command. Sets a
+ breakpoint at an address. Use this instead of gdb_cmd "break"
+ because the syntax of the break command is broken and doesn't
+ allow you to create a thread-specific BP at an address. Also
+ this is faster.
+
+Sun Oct 4 22:35:47 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * gdbtk-cmds.c (gdb_set_bp): Add an optional thread number.
+ (gdb_find_bp_at_line): New function. Returns a list of bpnums
+ at the specified line number.
+ (gdb_find_bp_at_addr): New function. Returns a list of bpnums
+ at an address..
+
+1998-10-02 Keith Seitz <keiths@cygnus.com>
+
+ * gdbtk-hooks.c (gdbtk_exec_file_changed): New function which handles
+ exec_file changes.
+ (gdbtk_add_hooks): Define exec_file_display_hook (to gdbtk_exec_file_changed)
+
+ * gdbtk-cmds.c (gdb_stop): target_stop is ALWAYS defined, so
+ compare against something a little more meaningful (target_ignore).
+
+1998-09-24 Keith Seitz <keiths@cygnus.com>
+
+ * gdbtk.c (gdbtk_wait): Don't run the timer for ice targets.
+
+ * v850ice.c (WM_ADDR_TO_SYM): New message.
+ (v850ice_wndproc): Add handler for WM_SOURCE.
+ (v850ice_wait): Call the ui_loop_hook occasionally.
+ (ice_cont): Acknowledge message before doing anything.
+ (ice_stepi): Ack message and let gdbtk do stepping.
+ (ice_nexti): Ack message and let gdbtk do stepping.
+ (view_source): New function ICE calls to display source code.
+
+1998-09-18 Keith Seitz <keiths@cygnus.com>
+
+ * gdbtk-cmds.c (get_frame_name): Demangle function names, too.
+
+Thu Sep 10 22:10:29 1998 Jim Ingham <jingham@cygnus.com>
+
+ *gdbtk-cmds.c (gdb_disassemble): Make sure the symtab's linetable is not
+ null before trying to use it...
+
+1998-09-02 Keith Seitz <keiths@cygnus.com>
+
+ * gdbtk-cmds.c (gdb_cmd): Do not run the timer when downloading --
+ the ui_progress_hook that has been installed will actually
+ update the gui for us.
+
+Mon Aug 31 15:42:10 1998 Tom Tromey <tromey@cygnus.com>
+
+ * gdbtk-hooks.c (context_hook): Don't define.
+
+1998-08-31 Keith Seitz <keiths@cygnus.com>
+
+ * gdbtk-cmds.c (gdb_listfuncs): When stripping out "global destructors"
+ and "global constructors", do not append any elements to the result.
+
+Sun Aug 30 00:49:18 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * gdbtk-cmds.c (Gdbtk_Init): Link C variable gdb_context
+ with tcl variable gdb_context_id.
+
+ * gdbtk-hooks.c (gdbtk_context_change): Implement new hook called
+ context_hook. Called when threads change.
+
+ * gdbtk.c: Initialize gdb_context.
+
+ * gdbtk.h: Declare gdb_context.
+
+ * infrun (wait_for_inferior): Call context_hook.
+
+ * thread.c (thread_command): Call context_hook.
+
+ * defs.h: Declare context_hook.
+
+Fri Aug 28 12:14:49 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * gdbtk-cmds.c (gdb_loadfile): Open the file after doing
+ the symtab lookup and calling symtab_to_filename(). This
+ makes GDBtk work with the GDB "dir" command.
+
+1998-08-18 Keith Seitz <keiths@cygnus.com>
+
+ * gdbtk-hooks.c (gdbtk_add_hooks): Set selected_frame_level_changed_hook.
+ (gdbtk_selected_frame_changed): New function.
+
+ * gdbtk-cmds.c (Gdbtk_Init): Add command gdb_stack into interpreter.
+ Link gdb's global selected_frame_level with interpreter global
+ gdb_selected_frame_level.
+ (gdb_stack): New function to faciltate speedier backtraces from
+ gdbtk.
+ (get_frame_name): New helper function for gdb_stack.
+
+Tue Aug 18 15:42:40 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * gdbtk-cmds.c (gdb_listfuncs): Strip out global constructors
+ and destructors from the function list.
+
+Thu Aug 13 15:09:59 1998 Drew Moseley <dmoseley@cygnus.com>
+
+ * gdbtk.c (gdbtk_cleanup): added a scope-level around the contents
+ of the #ifdef so that the variable declarations in there would not
+ be illegal in a C compilation.
+
+Mon Jul 27 13:07:16 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * gdbtk.c (gdbtk_call_command): Removed because it is now
+ in gdbtk-hooks.c
+ (null_routine): Removed.
+
+ * gdbtk-hooks.c (tracepoint_notify): Fix sprintf to
+ match number of arguments.
+
+ * gdbtk-cmds.c (gdb_loc): When calling gdb_loc with an
+ argument, call find_pc_line() to get a complete
+ symtab_and_line struct.
+
+Fri Jul 24 14:25:43 1998 Keith Seitz <keiths@cygnus.com>
+
+ * gdbtk-cmds.c (gdb_search): Add missing NULL to switches.
+ Add missing flags to result_ptr.
+ Pass along any errors caused by getting the list of files from
+ tcl.
+ Allocate correct amount of memory for the file list.
+ Don't do any unecessary cleanups.
+
+Fri Jul 24 01:08:37 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * gdbtk-cmds.c (gdb_loadfile): When there are no
+ linenumbers, use only one tab.
+
+Sat Jul 18 12:28:39 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * gdbtk.c (gdbtk_cleanup): Add call to tcl function
+ gdbtk_cleanup. We need this so the GUI gets to clean
+ up no matter how GDB exits.
+
+Wed Jul 1 13:10:58 1998 Jim Ingham <jingham@cygnus.com>
+
+ * Moved gdbtk_hooks.c & gdbtk_cmds.c to gdbtk-hooks.c &
+ gdbtk-cmds.c to comply with the gdb conventions. Changed the
+ configure & makefile to reflect the change...
+
+Wed Jul 1 11:07:21 1998 Jim Ingham <jingham@cygnus.com>
+
+ * gdbtk.c: removed all the commands and hooks from this file so
+ now it contains only the startup code.
+ * gdbtk.c (gdbtk_init): Fixed a bug in the startup code on Windows
+ that caused gdbtk not to find the share directory unless
+ GDBTK_LIBRARY was set.
+ * gdbtk_cmds.c: New file - this contains all the Tcl commands that
+ gdb defines. All the old commands were moved here, the
+ string-based commands were converted to object commands, and the
+ object-based commands were all converted to uniformly use the
+ call_wrapper. A new function, Gdbtk_Init was added to centralize
+ initializing the gdb package.
+ * gdbtk_hooks.c: New file - All the hooks were moved here, and a new
+ function, gdbtk_add_hooks was added to centralize adding all these
+ hook functions. gdbtk_fputs was also modified to handle the new
+ result_ptr structure. See the comments in gdbtk.h for more
+ details.
+ * gdbtk.h: New file - this contains all the defines and globals
+ shared by gdbtk.c, gdbtk_cmds.c & gdbtk_hooks.c
+ * Makefile.in, configure.in & configure: mutatis mutandi for the
+ new files.
+
+
+Mon Jun 29 11:49:17 1998 Keith Seitz <keiths@cygnus.com>
+
+ * main.c (main): Don't include gdbtk test code if GDBTK is
+ not defined by configure.
+
+ * configure.in: When enabling gdbtk, add "-DGDBTK" to ENABLE_CFLAGS.
+
+ * configure: Regenerate.
+
+Fri Jun 26 13:56:07 1998 Keith Seitz <keiths@cygnus.com>
+
+ * gdbtk.c: Change all references to static global "interp" to
+ "gdbtk_interp" and export this global.
+ (gdbtk_init): If gdbtk_source_filename is not NULL, source this file
+ into the interpreter when it goes idle.
+ Add new command "gdb_search".
+ (gdb_search): New function which searches the symbol table.
+ (gdbtk_test): New function called by main when the --tclcommand
+ option is used.
+
+ * main.c (main): Add a new option "--tclcommand" which is used
+ by the testsuite to source a file into the interpreter when it
+ goes idle.
+
+Sun Jun 21 09:31:12 1998 Ron Unrau (runrau@cygnus.com)
+
+ * gdbtk.c (gdb_set_bp): Use new interface.
+
+Wed Jun 17 19:12:23 1998 Jeff Holcomb <jeffh@cygnus.com>
+
+ * Makefile.in (install-only): Install tracing help files.
+
+Mon Jun 15 13:18:21 1998 Jim Ingham <jingham@cygnus.com>
+
+ * gdbtk.c (gdbtk_init): Add elements to the auto_path AS LIST
+ ELEMENTS. This allows gdbtk to work when installed in a directory
+ which has a space in the path. D. Moseley pointed out the bug.
+
+
+Tue Jun 9 14:10:46 1998 Keith Seitz <keiths@cygnus.com>
+
+ * gdbtk.c (gdb_get_vars_command): Return static variables and
+ variables stored in registers.
+
+ * main.c (main): Call pre/post_add_symbol_hook's when loading
+ executables and symbol files.
+
+Fri Jun 5 00:16:22 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * gdbtk.c (gdbtk_init): Change all references to
+ GDBTK_IDE to IDE_ENABLED.
+
+Thu Jun 4 18:31:53 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * gdbtk.c (gdbtk_init): Initialize tkTable.
+
+Thu Jun 4 10:15:03 1998 Elena Zannoni <ezannoni@kwikemart.cygnus.com>
+
+ * gdbtk.c: merged:
+
+ - Elena Zannoni <ezannoni@kwikemart.cygnus.com>
+ (call_obj_wrapper): in case of error, copy the
+ error message from the result to the error_string.
+ (gdbtk_fputs): add comments.
+ (gdb_actions_command): call validate_actionline when installing the
+ tracepoint, to do the syntax checking of the actions for us.
+ - Elena Zannoni <ezannoni@kwikemart.cygnus.com>
+ (gdb_get_trace_frame_num): new function to get the
+ trace frame number from gdb.
+ (gdbtk_init): added new command gdb_get_trace_frame_num.
+ - Jim Blandy <jimb@zwingli.cygnus.com>
+ (struct wrapped_call_objs): Change the `func' member to
+ be a Tcl_ObjCmdProc, not an Tcl_CmdProc, since it accepts a vector
+ of objects as arguments. Change the object vector to be const,
+ since that's what all the users of this structure seem to expect.
+ (call_obj_wrapper): Cast clientData properly before storing it in
+ the wrapped_args structure.
+
+Thu May 28 17:19:14 1998 Keith Seitz <keiths@cygnus.com>
+
+ * gdbtk.c (_initialize_gdbtk): Get rid of the console. Patch from
+ Chris Faylor (cgf@cygnus.com).
+
+ * configure.in: Link cygwin32 with subsystem console.
+
+ * configure: Regenerated
+
+Sun May 24 14:00:24 1998 Keith Seitz <keiths@cygnus.com>
+
+ * ser-unix.c (wait_for): Do not reset timeout_remaining for cygwin32 so that
+ we can use this member to track real timeouts.
+ (hardwire_readchar): Modify for cygwin32 so that we only ever use a real
+ system timeout of one second. Track the "real" timeout as a series of these
+ one second timeouts.
+ Call ui_loop_hook to keep the gui alive.
+
+ * top.c: Define new hook for cygwin32, "ui_loop_hook".
+
+ * gdbtk.c (gdbtk_init): Add ui_loop_hook for CygWin32 to work around
+ update problems.
+
+Thu May 21 13:56:24 1998 Elena Zannoni <ezannoni@kwikemart.cygnus.com>
+
+ * gdbtk.c: reinserted the changes that were accidentally deleted:
+ (_initialize_gdbtk): Use correct device names in
+ cygwin-specific call (cosmetic change).
+ (gdbtk_ignorable_warning): removed va_list parameter,
+ which was unused.
+ (_initialize_gdbtk): add cygwin32 specific code to
+ allow `gdb -nw' to work when specified specified from a windows
+ console-mode command line.
+
+1998-05-19 Jim Blandy <jimb@zwingli.cygnus.com>
+
+ * gdbtk.c (struct wrapped_call_objs): Change the `func' member to
+ be a Tcl_ObjCmdProc, not an Tcl_CmdProc, since it accepts a vector
+ of objects as arguments. Change the object vector to be const,
+ since that's what all the users of this structure seem to expect.
+ (call_obj_wrapper): Cast clientData properly before storing it in
+ the wrapped_args structure.
+
+Wed May 13 11:12:58 1998 James Ingham <jingham@leda.cygnus.com>
+
+ * gdbtk.c: Fixed a goof in the definition of the gdb_get_args &
+ gdb_get_locals Tcl commands. Moved the previous ChangeLog entry
+ from ChangeLog to ChangeLog-gdbtk (here)...
+
+Tue May 12 13:29:20 1998 Jeff Holcomb <jeffh@cygnus.com>
+
+ * Makefile.in (install-only): Add images/icons.txt and
+ images2/icons.txt to files that need to be installed.
+
+Tue May 12 12:03:16 1998 James Ingham <jingham@leda.cygnus.com>
+
+ * gdbtk.c: Add an object call wrapper for the new Tcl_Obj based
+ commands. This way the obj commands will also go through
+ catch_errors. This is just a bandaid while I rewrite the
+ string-based commands to use the object format.
+
+Tue May 5 09:30:25 1998 Christopher Faylor <cgf@cygnus.com>
+
+ * gdbtk.c (_initialize_gdbtk): Use correct device names in
+ cygwin-specific call (cosmetic change).
+
+Wed Apr 29 15:53:16 1998 Elena Zannoni <ezannoni@kwikemart.cygnus.com>
+
+ * gdbtk.c (gdbtk_ignorable_warning): removed va_list parameter,
+ which was unused.
+
+Tue Apr 28 19:41:33 1998 Tom Tromey <tromey@cygnus.com>
+
+ * Makefile.in (GDBTKLIBS): New macro.
+ (INSTALLED_LIBS): Include GDBTKLIBS.
+ (CLIBS): Likewise.
+ * configure: Rebuilt.
+ * configure.in: Put Tcl/Tk libs into GDBTKLIBS, not LIBS.
+ (GDBTKLIBS): AC_SUBST.
+
+Thu Apr 23 19:01:05 1998 Keith Seitz <keiths@onions.cygnus.com>
+
+ * Makefile.in (install-only): Install help files.
+
+Wed Apr 22 21:17:35 1998 Christopher Faylor <cgf@cygnus.com>
+
+ * gdbtk.c (_initialize_gdbtk): add cygwin32 specific code to
+ allow `gdb -nw' to work when specified specified from a windows
+ console-mode command line.
+
+Wed Apr 15 11:23:53 1998 Stan Shebs <shebs@andros.cygnus.com>
+
+ * gdbtcl: Remove directory and contents, this version of
+ the interface is obsolete.
+
+Mon Apr 13 16:17:52 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * gdbtk.c (gdb_loadfile): Change fstat() call to stat().
+ Needed because you can't convert a FILE* to an fd.
+
+Mon Apr 13 16:28:07 1998 Elena Zannoni <ezannoni@kwikemart.cygnus.com>
+
+ * gdbtk.c: (perror_with_name_wrapper) new function to call
+ perror_with_name safely.
+ (gdb_loadfile) added source vs. executable time stamp check.
+ (gdbtk_warning) new function to pass a warning message to the gui.
+ (gdbtk_ignorable_warning) new function to pass a warning
+ to the gui. Used only for the src. vs. exec check.
+ (gdbtk_init) added warning_hook
+ added include <sys/stat.h>
+
+Mon Apr 13 12:58:26 1998 Keith Seitz <keiths@onions.cygnus.com>
+
+ * gdbtk.c (gdbtk_start_timer): Include on all platforms. Decrease
+ timer interval a little.
+ (gdbtk_stop_timer): Include on all platforms.
+ (gdbtk_wait): No more signals! Use a timer on all platforms to keep the
+ GUI alive.
+ (gdbtk_init): Remove FIOASYNC and all x_fd references. Now using timers
+ on all platforms.
+
+Fri Apr 10 15:48:10 1998 Jason Molenda (crash@bugshack.cygnus.com)
+
+ * gdbtk.c (gdb_listfiles): Allocate space for 'files' dynamically.
+
+Thu Apr 9 14:20:59 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * gdbtk.c (gdbtk_init): Remove redundant variable "IDE".
+
+Tue Apr 7 15:13:58 1998 Stan Shebs <shebs@andros.cygnus.com>
+
+ * gdbtk.tcl: Remove, no longer used.
+
+Tue Apr 7 12:49:45 1998 Keith Seitz <keiths@onions.cygnus.com>
+
+ * gdbtk.c (gdb_cmd): NEVER call the busy, update, and idle hooks.
+
+Tue Mar 31 15:42:06 1998 Keith Seitz <keiths@onions.cygnus.com>
+
+ * gdbtk.c (gdb_loadfile): Don't use the return result from
+ sprintf, which returns a char * under SunOS4.
+
+Tue Mar 31 17:18:43 1998 Ian Lance Taylor <ian@cygnus.com>
+
+ * configure.in: Add $(LIBIDETCL) as well as $(LIBIDE) if
+ --enable-ide.
+ * Makefile.in (IDE_CFLAGS_X): Add -I for libidetcl/src.
+ (LIBIDETCL): Define.
+ * configure: Rebuild.
+
+Sun Mar 29 21:19:46 1998 Keith Seitz <keiths@onions.cygnus.com>
+
+ * gdbtk.c (gdb_get_tracepoint_info): Change formatting of address.
+ (tracepoint_exists): Remove code which confuses assembly traces.
+
+Sat Mar 28 12:13:23 1998 Keith Seitz <keiths@onions.cygnus.com>
+
+ * gdbtk.c (gdb_cmd): If argc > 2, assume that the busy and idle hooks
+ should not be called.
+
+Thu Mar 26 22:29:28 1998 Elena Zannoni <ezannoni@kwikemart.cygnus.com>
+
+ * gdbtk.c: (gdb_trace_status) new function.
+ (gdbtk_init) added command "gdb_is_tracing".
+ (tracepoint_notify) added passcount information.
+
+Thu Mar 26 12:00:35 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * gdbtk.c (gdbtk_fputs): Insert fencepost.
+ (gdb_loc): Correct pc calculation.
+ (gdb_immediate_command): Return if a load is in progress.
+ (gdb_cmd): Return if a load is in progress.
+ (target_stop_wrapper): New function.
+ (gdb_stop): Call target_stop_wrapper.
+ (x_event): Add fencepost and optimize load cancel check.
+ (gdbtk_start_timer): Set up structs only once.
+ (gdbtk_stop_timer): Just use preset structs to set timer parameters.
+ (gdb_loadfile): If file cannot be loaded, return error message.
+ (gdb_loadfile): Add space before tab so that lines without
+ a '-' can later be changed to have one.
+
+Wed Mar 25 14:08:51 1998 Elena Zannoni <ezannoni@kwikemart.cygnus.com>
+
+ * gdbtk.c (gdbtk_pre_add_symbol): Use Tcl_merge to form Tcl commands.
+
+Mon Mar 23 13:41:39 1998 Elena Zannoni <ezannoni@kwikemart.cygnus.com>
+
+ * gdbtk.c (gdb_get_mem): Rewrite to fetch entire contents
+ of the memory window at once.
+
+Sat Mar 21 19:34:49 1998 Elena Zannoni <ezannoni@kwikemart.cygnus.com>
+
+ Merged changes from Foundry: list follows by author:
+
+ - Tom Tromey <tromey@cygnus.com>
+
+ * Makefile.in (gdbres.o): New target.
+ (WINDRES): New define.
+ * configure: Rebuilt.
+ * configure.in (WINDRES): Define.
+ (CONFIG_OBS): Include gdbres.o on Windows.
+ * gdbtool.ico: New file.
+ * gdb.rc: New file.
+ * gdbtk.c (gdbtk_init): Call ide_create_messagebox_command.
+ (gdbtk_cleanup): Call ide_interface_deregister_all.
+ (gdbtk_init): Pass event handle to cleanup.
+ (TclDebug): Use Tcl_Merge to construct command.
+ (gdbtk_init): Call ide_create_cygwin_path_command.
+
+ - Martin M. Hunt <hunt@cygnus.com>
+
+ * gdbtk.c (gdb_set_bp): Set addr_string for bp.
+ (gdb_get_breakpoint_info): Demangle function
+ names in breakpoint info.
+ Include "demangle.h".
+ (gdb_loc, gdb_listfuncs): Demangle C++
+ function names.
+ (gdb_set_bp): Properly quote filename to fix
+ problems with spaces. Send pc back as a hex string.
+ (gdb_listfuncs): Remove debugging line.
+ Turn off some debugging lines.
+ (breakpoint_notify): Return correct line number.
+ (gdb_get_breakpoint_info): Return correct line number.
+ (gdb_set_bp): New function to provide a better way to
+ set breakpoints.
+ (gdbtk_readline, gdbtk_readline_begin): Memory
+ allocated by tcl needs to be freed by Tcl_Free().
+ (find_file_in_dir): Deleted.
+ (gdb_find_file_command): Call full_lookup_symtab().
+ (gdb_listfuncs): Call full_lookup_symtab().
+ (full_lookup_symtab): New function. Like lookup_symtab
+ except handles multiple files with the same basename,
+ full pathnames, and always sets symtab->fullname.
+ (gdb_loadfile): Call full_lookup_symtab(). Clear
+ realloc'd memory.
+ (gdb_loadfile): Don't tag lines without source.
+ Tag source lines with source_tag.
+ (gdb_find_file_command, find_file_in_dir):
+ Rewrite. Now searches symtabs and psymtabs for a match
+ on the partial or full filename. Returns the full pathname.
+ (gdb_loadfile): Realloc additional memory
+ if someone loads in a file with more than 160,000
+ lines. I don't know if this really works because
+ I don't have enough memory to test it.
+ (gdb_sourcelines): Deleted.
+ (gdb_loadfile): New function. Takes a text widget
+ and loads it with the contents of a file. Marks
+ and tags source lines.
+ (pc_changed): New function.
+ (get_pc_register): Returns the value of
+ the PC to GDB.
+ (gdb_loc): If looking on the stack, return
+ real pc along with calling source line.
+ (gdb_loc): Return "" instead of "N/A" if
+ filename is not found.
+ (gdb_get_breakpoint_info): Same.
+ (get_register): For Natural mode, set format to 0.
+ Minor bugfixes from keiths.
+ (TclDebug): New function for debugging use.
+ (gdb_loc): Return correct PC for frames
+ that are not the innermost frame.
+ (gdb_listfiles): Rewritten to use object
+ API. Now takes an optional dirname which will cause
+ only files in that directory or its subdirectories
+ to be returned. Now returns basenames instead of
+ full pathnames.
+ (gdb_cmd): Set/reset load_in_progress flag.
+ (call_wrapper): Don't pop up dialog for errors in
+ downloads; just abort download.
+ (gdbtk_load_hash): Set return value correctly.
+
+ - Keith Seitz <keiths@onions.cygnus.com>
+
+ * gdbtk.c (gdbtk_init): Define the ui_loop_hook so that it can be
+ called by routines which might block, allowing us to update the GUI.
+ (gdbtk_wait): Move timer calls to annotation hooks.
+ (gdbtk_init): Define the annotation hooks.
+ (gdbtk_annotate_starting): New function for cygwin32 hosts.
+ (gdbtk_annotate_stopped): New function for cygwin32 hosts.
+ (gdbtk_annotate_exited): New function for cygwin32 hosts.
+ (gdbtk_annotate_signalled): New function. for cygwin32 hosts.
+ (gdbtk_init): Use gdbtk_print_frame_info hook.
+ (gdbtk_print_frame_info): New function which sets current_source_symtab
+ based on the given symtab and line info.
+ (gdb_immediate_command): New function which does
+ not buffer any
+ output. (Contrast to gdb_cmd.)
+ (gdb_prompt_command): New function to return gdb's prompt.
+ (find_file_in_dir): New functon which searches source paths
+ for a given filename.
+ (gdb_find_file): New function which returns path to given file -- uses
+ find_file_in_dir.
+ (gdbtk_init): Install "gdb_immediate", "gdb_find_file", and
+ "gdb_prompt"
+ commands into interpreter.
+
+ - Ian Lance Taylor <ian@cygnus.com>
+
+ * gdbtk.c (gdbtk_timer_going): If __CYGWIN32__, new static
+ variable.
+ (gdb_cmd): If __CYGWIN32__, if executing the load command, call
+ gdbtk_start_timer and gdbtk_stop_timer.
+ (call_wrapper): If __CYGWIN32__, if the timer is going, turn it
+ off. Clear load_in_progress.
+ (x_event): If load_in_progress, quit if download_cancel_ok.
+ (gdbtk_start_timer): Set gdbtk_timer_going.
+ (gdbtk_stop_timer): Clear gdbtk_timer_going.
+ (gdbtk_wait): Call x_event.
+ (gdbtk_init): Call ide_create_win_grab_command if
+ __CYGIN32__.
+ (gdb_clear_file): Clear stop_pc.
+
+Wed Mar 4 16:50:18 1998 Jason Molenda (crash@bugshack.cygnus.com)
+
+ * gdbtk.c (gdb_listfiles): Fix thinko in last change.
+
+Wed Mar 4 15:34:49 1998 Jason Molenda (crash@bugshack.cygnus.com)
+
+ * gdbtk.c (gdb_listfiles): Allocate space for 'files' dynamically.
+
+Tue Feb 10 17:50:37 1998 Keith Seitz <keiths@onions.cygnus.com>
+
+ * gdbtk.c (gdbtk_modify_tracepoint): Define new tracepoint modification hook.
+ (gdbtk_print_frame_info): Define this hook so that current_source_symtab
+ is set properly.
+ (gdb_actions_command): Use free_actions () from tracepoint.c/h.
+
+Mon Jan 26 11:37:55 1998 Keith Seitz <keiths@onions.cygnus.com>
+
+ * gdbtk.c (gdb_actions_command): Make note of next action
+ before freeing all references to it.
+
+Sat Jan 24 23:52:08 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * gdbtk.c: Merge from Foundry branch.
+ (TclDebug): New debugging function.
+ (gdb_loc): For frames, find address of calling function
+ instead of whatever is on the stack (usually the next
+ instruction).
+ (gdb_listfiles): Takes an optional pathname argument and
+ returns an alphabetized list of basenames of files in the
+ path.
+
+Wed Jan 22 10:37:02 1998 Keith Seitz <keiths@onions.cygnus.com>
+
+ * symfile.c: Define two new hooks for symbol reading:
+ "pre_add_symbol_hook" and "post_add_symbol_hook". These hooks
+ are called before we begin reading symbols, and after we finish.
+ (generic_load): Use new symbol reading hooks and get rid of
+ compiler warning.
+
+ * gdbtk.c (gdbtk_init): Add hooks for pre- and post-symbol reading.
+ (gdbtk_pre_add_symbol): New function: the pre-add-symbol hook.
+ (gdbtk_post_add_symbol): New function: the post-add-symbol hook.
+ (find_file_in_dir): New function. Moved the guts of gdb_find_file_command
+ into here to allow its use by others.
+ (gdb_loc): Use find_file_in_dir to return the real path to the file
+ (or "N/A" if we can't find it).
+
+ * configure.in (TIX_LIB_EXT): Define new variable for those special cases
+ when TCL_SHLIB_SUFFIX is not enough to specify the dependency.
+
+ * configure: Regenerate.
+
+Fri Jan 23 07:47:06 1998 Fred Fish <fnf@cygnus.com>
+
+ * Makefile.in (uninstall): Remove installed gdbtcl dir, if one
+ was installed.
+
+Thu Jan 15 12:42:28 1998 Keith Seitz <keiths@onions.cygnus.com>
+
+ * gdbtk.c (gdb_immediate_command): New function which does not buffer any
+ output. (Contrast to gdb_cmd.)
+ (gdbtk_init): Install "gdb_immediate" command into interpreter.
+
+Wed Jan 14 16:38:44 1998 Keith Seitz <keiths@pizza.cygnus.com>
+
+ * configure.in (--enable-gdbtk): If tcl was built with --enable-shared,
+ use TCL_SHLIB_SUFFIX to specify the suffix of the library file so that
+ we don't expect to see "libfoo.a" instead of "libfoo.{so,sl, etc}".
+
+ * configure: Regenerate.
+
+Wed Dec 31 16:50:26 1998 Keith Seitz (keiths@onions.cygnus.com)
+
+ * gdbtk.c (gdb_actions_command): extract and save step count
+ from "while-stepping" command
+
+Tue Dec 16 21:16:42 1997 Ian Lance Taylor <ian@cygnus.com>
+
+ * Makefile.in (LIBGUI): New variable.
+ (GUI_CFLAGS_X): New variable.
+ (IDE_CFLAGS): Add $(GUI_CFLAGS_X).
+ * configure.in: Add $(LIBGUI) to TCL_LIBS and CONFIG_DEPS.
+ * configure: Rebuild.
+
+Wed Dec 10 13:16:45 1997 Keith Seitz <keiths@onions.cygnus.com>
+
+ * gdbtk.c (gdb_get_tracepoint_info): Use info in struct
+ symtab_and_line (not struct tracepoint) so that we get the
+ real line info for an address. Arrange data more like
+ gdb_get_breakpoint_info.
+ (tracepoint_notify): Use info in struct symtab_and_line again.
+ (gdbtk_init): Add command "gdb_get_tracepoint_list" into
+ interpreter.
+ (gdb_get_tracepoint_list): New function that aids the source
+ window in displaying tracepoints when the file changes.
+
+Fri Dec 5 10:31:23 1997 Keith Seitz <keiths@pizza.cygnus.com>
+
+ * gdbtk.c (gdbtk_init): Add gdb_find_file into interpreter.
+ (gdb_find_file_command): New function which searches source path
+ to find the real full filename of a file.
+
+Mon Dec 1 10:19:44 1997 Keith Seitz <keiths@onions.cygnus.com>
+
+ * gdbtk.c: Move include of "guitcl.h" back out of IDE ifdef.
+ (gdbtk_init): Move ide_initialize_paths out of IDE ifdef.
+
+ * configure.in (TCL_LIBS, CONFIG_DEPS): Add IDE libraries for all
+ builds.
+ (CONFIG_OBS): Remove tracepoint.o, which should always be included.
+
+ * configure: regenerate
+
+ * Makefile.in (install-only): ALWAYS install the new gdbtk
+ (REMOTE_OBS): add tracepoint.o
+
+Thu Nov 27 09:07:18 1997 Michael Meissner <meissner@cygnus.com>
+
+ * configure.in ({TCL_LIBS,CONFIG_DEPS}): Don't add IDE libraries
+ if not --enable-ide.
+ (CONFIG_OBS): Add tracepoint.o to list if --enable-gdbtk.
+ * configure: Regenerate.
+
+ * gdbtk.c (gdb_get_breakpoint_info): Add missing filename
+ argument.
+ (toplevel): Move include of guitcl.h into #ifdef IDE region.
+ (gdbtk_init): Move ide_initialize_paths call into #ifdef IDE
+ section.
+
+ * Makefile.in (gdbtk.o): Update dependencies.
+
+Wed Nov 26 15:02:43 1997 Keith Seitz <keiths@onions.cygnus.com>
+
+ * gdbtk.c (gdb_loc): symtab_to_filename can return NULL.
+ (breakpoint_notify): Ditto.
+ (gdb_get_breakpoint_info): Ditto.
+
+Wed Nov 26 11:33:09 1997 Keith Seitz <keiths@onions.cygnus.com>
+
+ Merge in code from Foundry branch:
+
+ * Makefile.in (install-only): install the new gdbtk, not the old
+
+ * gdbtk.c (gdbtk_call_command): also run idle hooks for class_trace
+ commands
+ (gdbtk_init): Add new commands "gdb_get_locals", "gdb_get_args",
+ "gdb_get_function", "gdb_get_line", "gdb_get_file",
+ "gdb_tracepoint_exists", "gdb_get_tracepoint_info", "gdb_actions",
+ and "gdb_prompt".
+ (gdb_get_vars_command): New function.
+ (gdb_get_line_command): New.
+ (gdb_get_file_command): New.
+ (gdb_get_function_command): New.
+ (gdb_get_tracepoint_info): New.
+ (gdbtk_create_tracepoint): New.
+ (gdbtk_delete_tracepoint): New.
+ (tracepoint_notify): New.
+ (tracepoint_exists): New.
+ (gdb_actions_command): New.
+ (gdb_tracepoint_exists_command): New.
+ (gdb_prompt_command): New.
+
+Thu Nov 13 18:15:54 1997 Ian Lance Taylor <ian@cygnus.com>
+
+ * gdbtk.c: Move include of gdbcore.h to top of file.
+ (close_bfds): New static function if _WIN32.
+ (gdbtk_readline): Call close_bfds.
+ (call_wrapper, tk_command_loop): Likewise.
+ (gdb_clear_file): New static function.
+ (gdbtk_init): Create gdb_clear_file Tcl command.
+
+Wed Nov 12 14:58:39 1997 Jeff Holcomb <jeffh@cygnus.com>
+
+ * gdbtk.c: gdbtk_load_hash and ui_load_progress_hook return an
+ int result.
+ (gdbtk_load_hash): download hash routine returns an int result.
+
+Mon Nov 10 15:11:51 1997 Ian Lance Taylor <ian@cygnus.com>
+
+ * gdbtk.c (gdbtk_init): Call ide_create_shell_execute_command if
+ __CYGWIN32__.
+ * configure.in: Add -lshell32 to WIN32LIBS on cygwin32.
+ * configure: Rebuild.
+
+Sun Nov 9 16:25:34 1997 Tom Tromey <tromey@cygnus.com>
+
+ * gdbtk.c (gdbtk_init): Run ide_create_help_command.
+
+Tue Oct 28 17:31:47 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * gdbtk.c (gdbtk_init): Call ide_create_winprint_command.
+
+Thu Oct 23 15:53:37 1997 Ian Lance Taylor <ian@cygnus.com>
+
+ * configure.in: Add -lgdi32 to WIN32LIBS when linking gdbtk on
+ cygwin32.
+ * configure: Rebuild.
+
+Wed Oct 22 21:32:54 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * gdbtk.c (gdbtk_init): Create sizebox command on Windows.
+
+Thu Oct 9 14:33:21 1997 Ian Lance Taylor <ian@cygnus.com>
+
+ * gdbtk.c (gdbtk_init): Remove assertion argument from call to
+ ide_create_window_register_command.
+
+Wed Oct 1 11:09:52 1997 Tom Tromey <tromey@cygnus.com>
+
+ * gdbtk.c (gdbtk_init): Pass name of restore interface to
+ ide_create_window_register_command.
+
+Fri Sep 26 21:08:22 1997 Keith Seitz <keiths@pizza.cygnus.com>
+
+ * gdbtk.c (gdbtk_init): Initialize ui_load_progress_hook.
+
+Thu Sep 25 03:05:00 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * gdbtk.c (gdb_load_info): New function. Returns a list
+ of section names and sizes for an executable.
+ (gdbtk_load_hash): Stub function to call tcl function
+ download_hash.
+
+Tue Sep 23 01:29:00 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * gdbtk.c (gdb_get_mem): Fix compiler warning.
+
+Sun Sep 21 00:15:00 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * gdbtk.c (gdb_get_mem): Fix problem with ASCII dump.
+
+Tue Sep 16 18:07:17 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * gdbtk.c (gdb_get_mem): New function. Returns
+ a formatted memory dump with optional ASCII dump.
+
+Mon Sep 8 12:48:50 1997 Ian Lance Taylor <ian@cygnus.com>
+
+ * gdbtk.c: Include ilutk.h if IDE.
+ (gdb_confirm_quit, gdb_force_quit): New static functions.
+ (gdbtk_init): Add Tcl commands gdb_confirm_quit and
+ gdb_force_quit.
+
+Mon Sep 8 03:05:33 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * gdbtk.c (gdb_get_breakpoint_info): Now returns the
+ function a breakpoint is in.
+
+Fri Sep 5 20:23:58 1997 Ian Lance Taylor <ian@cygnus.com>
+
+ * gdbtk.c (gdbtk_init): Call ide_create_exit_command.
+
+Wed Sep 3 19:39:15 1997 Ian Lance Taylor <ian@cygnus.com>
+
+ * gdbtk.c: Include guitcl.h.
+ (gdbtk_init): Always call ide_initialize_paths. Set the Tcl
+ variable IDE to 1 when using the IDE. Always try using auto path
+ to find main.tcl.
+ * Makefile.in (IDE_CFLAGS_X): Always include libide.
+ (LIBIDE): New variable.
+ (IDE_X): Omit -lide.
+ (IDE_DEPS): Omit libide.
+ * configure.in: Add LIBIDE to TCL_LIBS and CONFIG_DEPS.
+ * configure: Rebuild.
+
+Mon Aug 25 02:28:55 1997 Keith Seitz <keiths@pizza.cygnus.com>
+
+ * gdbtk.c: (gdb_target_has_inferior) check if inferior_pid is non-zero
+ before assuming that the inferior is running.
+
+Mon Aug 25 01:06:48 1997 Ian Lance Taylor <ian@cygnus.com>
+
+ * gdbtk.c (gdbtk_start_timer): Pass third argument to setitimer.
+ (gdbtk_stop_timer): Likewise.
+
+Mon Aug 25 00:23:08 1997 Keith Seitz <keiths@pizza.cygnus.com>
+
+ * gdbtk.c: (gdbtk_init) create new command "gdb_target_has_execution"
+ (gdb_target_has_execution_command) new function
+
+Sun Aug 24 20:27:22 1997 Ian Lance Taylor <ian@cygnus.com>
+
+ * gdbtk.c (gdb_loc): If there are no symbols, just bail
+ immediately.
+ (tk_command_loop): Print errors encountered while running
+ gdbtk_tcl_preloop.
+
+Sun Aug 24 13:44:03 1997 Tom Tromey <tromey@cygnus.com>
+
+ * gdbtk.c (gdbtk_init): Run ide_create_build_command.
+
+Sat Aug 23 21:53:39 1997 Ian Lance Taylor <ian@cygnus.com>
+
+ * gdbtk.c: If CYGWIN32, include <sys/time.h>.
+ (x_fd): Don't define if WINNT.
+ (gdbtk_start_timer, gdbtk_stop_timer): New static functions if
+ CYGWIN32.
+ (gdbtk_wait): Don't set up signal handling if WINNT. If CYGWIN32,
+ call gdbtk_start_timer and gdbtk_stop_timer.
+ (gdbtk_init): Don't set up signal handling or make x_fd
+ asynchronous if CYGWIN32.
+
+Fri Aug 22 15:23:15 1997 Ian Lance Taylor <ian@cygnus.com>
+
+ * gdbtk.c (error_string_ptr): New static variable.
+ (gdbtk_fputs): If result_ptr is NULL, and error_string_ptr is not
+ NULL, and we're outputting to stderr, append string to
+ error_string_ptr rather than calling gdbtk_tcl_fputs.
+ (call_wrapper): Set up error_string_ptr. Put both error string
+ and normal string in Tcl result.
+
+ * gdbtk.c (gdbtk_init): Don't call ide_run_server_init until after
+ gdb has initialized.
+
+Thu Aug 21 19:14:38 1997 Ian Lance Taylor <ian@cygnus.com>
+
+ * gdbtk.c: If _WIN32, include winuser.h.
+ (gdbtk_init): If _WIN32, use MessageBox to display an error
+ evaluating main.tcl.
+
+Thu Aug 21 00:48:00 1997 Martin M. Hunt <hunt@pern.cygnus.com>
+
+ * gdbtk.c (gdbtk_init): Add call to ide_run_server_init().
+ (gdb_cmd): For the load command, don't buffer the I/O.
+
+Wed Aug 20 11:41:22 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * gdbtk.c (gdbtk_query): Chaneg free() call to Tcl_Free().
+
+Tue Aug 19 17:09:19 1997 Ian Lance Taylor <ian@cygnus.com>
+
+ * Makefile.in (TCL_DEPS, TK_DEPS): New variables.
+ (ITCL_DEPS, TIX_DEPS): New variables.
+ (IDE_DEPS): New variable.
+ (CDEPS): Include @CONFIG_DEPS@.
+ * configure.in: Set and substitute CONFIG_DEPS and TIX_DEPS.
+ * configure: Rebuild.
+
+Sun Aug 17 00:42:11 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * gdbtk.c (gdb_listfuncs): New function that returns
+ a list of all the functions in a source file.
+
+Tue Aug 12 16:35:21 1997 Ian Lance Taylor <ian@cygnus.com>
+
+ * Makefile.in (install-only): Install tclIndex if ENABLE_IDE.
+
+Mon Aug 11 10:43:04 1997 Tom Tromey <tromey@cygnus.com>
+
+ * gdbtk.c (gdbtk_init): Use ide_event_init_from_environment.
+
+Fri Aug 8 15:59:24 1997 Ian Lance Taylor <ian@cygnus.com>
+
+ * gdbtk.c (gdbtk_init): Change gdbtk_lib_tmp and gdbtk_file to be
+ dynamically allocated, rather than fixed size. Pass "gdbtcl" to
+ ide_initialize_paths to match installed directory name. If IDE,
+ use auto_path to search for main.tcl.
+ * Makefile.in (install-only): If ENABLE_IDE, install from gdbtcl2
+ rather than gdbtcl.
+
+ * gdbtk.c (gdbtk_cleanup): New static function.
+ (gdbtk_init): Add gdbtk_cleanup as a final cleanup. Uncomment
+ call to ide_initialize_paths. If we can't initialize the event
+ system, set GDBTK_IDE to 0 in the Tcl interpreter. Create the
+ ide_window_register and the ide_window commands. Initialize tk,
+ itcl, and tix after initializing the IDE.
+
+ * configure.in (tixdir): Update for cygwin32 case for Tcl 8.0.
+ * configure: Rebuild.
+
+Fri Aug 8 00:13:32 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * gdbtk.c (breakpoint_notify): Change buffer size from 100
+ to 256 to avoid memory corruption with very long pathnames.
+
+Thu Aug 7 14:08:23 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * configure.in: Change required Tix version to 4.1.8.0 .
+ * configure: Rebuilt.
+
+Fri Aug 1 15:21:44 1997 Ian Lance Taylor <ian@cygnus.com>
+
+ * gdbtk.c (Tcl_Alloc): Don't provide our own version of this if
+ _WIN32.
+ (Tcl_Realloc, Tcl_Free): Likewise.
+ * configure.in: Check for cygwin32 environment. Define and
+ substitute WIN32LIBS and WIN32LDAPP. Always set configdir to
+ unix; setting it to win was for an old Tcl/Tk configuration
+ scheme.
+ * aclocal.m4 (CY_AC_LOAD_TKCONFIG): Substitute TK_BUILD_INCLUDES.
+ * Makefile.in (TK_CFLAGS): Add @TK_BUILD_INCLUDES@.
+ (WIN32LDAPP, WIN32LIBS): Define.
+ (CLIBS): Add $(WIN32LIBS).
+ (gdb): Use $(WIN32LDAPP).
+ * configure: Rebuild.
+
+Tue Jul 22 19:45:37 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * configure.in, aclocal.m4: Another fix to find the
+ correct Tix library name.
+
+ * configure: Rebuilt.
+
+Mon Jul 21 22:24:07 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * aclocal.m4: Search for the correct tix library.
+
+Thu Jul 10 00:02:41 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * Makefile.in, configure.in, aclocal.m4: Add Itcl, Tix, and
+ IDE configuration information.
+
+ * gdbtk.c (breakpoint_notify): Send address, linenumber and
+ filename when a breakpoint is set. Avoids call to bp_info.
+ (gdbtk_init): Call Tcl_FindExecutable(). Add code to handle
+ Itcl, Tix and IDE initialization.
+
+ * configure: Regenerated.
+
+Fri Jun 13 10:28:09 1997 Fred Fish <fnf@cygnus.com>
+
+ * gdbtk.c (gdbtk_init): Make truth value test explicit.
+ Remove unused static variable "Gdbtk_Library".
+
+Sat Jun 7 02:34:19 1997 Peter Schauer (pes@regent.e-technik.tu-muenchen.de)
+
+ * gdbtk.c (gdb_get_breakpoint_info): Add string for new
+ enumeration del_at_next_stop to bpdisp array.
+
+Tue Jun 3 15:46:51 1997 Tom Tromey <tromey@cygnus.com>
+
+ * Makefile.in (LIB_RUNTIME_DIR): New variable.
+
+Wed May 7 19:10:19 1997 Andrew Cagney <cagney@b1.cygnus.com>
+
+ * gdbtk.c (wrapped_call): New function - make actual call to tk
+ worker function.
+ (call_wrapper): Rewrite to use top.c:catch_errors.
+
+ * gdbtk.c (gdb_stop): If No target_stop set quit flag and hope for
+ best.
+
+Mon Apr 21 14:00:08 1997 Doug Evans <dje@canuck.cygnus.com>
+
+ * gdbtk.c (gdb_disassemble): Store endian-ness in `di'.
+
+Wed Apr 16 12:33:06 1997 Andrew Cagney <cagney@b1.cygnus.com>
+
+ * Makefile.in (install-only): Make list of gdbtcl files to install
+ explicit - was picking up files such as ChangeLog etc.
+ (install-only): Don't blindly create the directory.
+
+Tue Apr 1 15:04:21 1997 Jason Molenda (crash@godzilla.cygnus.co.jp)
+
+ * configure.in (gdbtcl): Create soft-link for gdbtcl/ directory
+ instead of gdbtk.tcl.
+
+Fri Mar 28 17:04:02 1997 Jason Molenda (crash@godzilla.cygnus.co.jp)
+
+ * Makefile.in (gdbtk.o): look for GDBTK_LIBRARY in $(datadir) by
+ default, not $(srcdir).
+
+Wed Mar 19 15:16:17 1997 Martin M. Hunt <hunt@onions.cygnus.com>
+
+ * Makefile.in: Install gdbtcl dir instead of gdbtk.tcl.
+
+ * gdbtk.c: Added some ifdefs for Windows. Changed GDBTK_FILENAME
+ to GDBTK_LIBRARY, which is now a path to search.
+ (gdb_path_conv): New function. Convert Cygwin32 pathname to
+ DOS-style pathname.
+
+ * {aclocal.m4,configure.in}: Changes for Windows builds.
+
+ * configure: Rebuilt.
+
+Fri Mar 14 10:01:29 1997 Tom Tromey <tromey@cygnus.com>
+
+ * configure: Regenerated.
+ * configure.in (LIBS): Re-reverse order of TCL_LIBS and TK_LIBS.
+
+Wed Mar 12 14:29:52 1997 Tom Tromey <tromey@cygnus.com>
+
+ * gdbtk.c (x_event): Use Tcl_DoOneEvent, TCL_DONT_WAIT,
+ TCL_ALL_EVENTS.
+
+ * configure: Regenerated.
+ * configure.in (ENABLE_GDBTK): Put TCL_LIBS after TK_LIBS in
+ LIBS.
+
+Mon Feb 10 13:50:53 1997 Stu Grossman (grossman@critters.cygnus.com)
+
+ * gdbtk.c (call_wrapper): Clear running_now if an error occurs.
+
+Wed Dec 11 18:51:35 1996 Mark Alexander <marka@cygnus.com>
+
+ * gdbtk.c (gdb_loc): Correct truncation of PC on 64-bit MIPS.
+
+Tue Nov 19 09:26:14 1996 Tom Tromey <tromey@cygnus.com>
+
+ * gdbtk.c (gdbtk_readline): Fix memory leak.
+
+Mon Nov 18 23:43:05 1996 Tom Tromey <tromey@cygnus.com>
+
+ Fixes for Tcl 7.6 / Tk 4.2:
+ * gdbtk.tcl (apply_filespec): Use tk_getOpenFile.
+ Remove old fileselect code.
+ * gdbtk.c (Tcl_Alloc): Rename from Tcl_Malloc.
+
+Fri Sep 27 10:25:30 1996 Fred Fish <fnf@cygnus.com>
+
+ * gdbtk.tcl (create_copyright_window): Increase timeout from
+ 15 seconds to 30 seconds.
+
+Wed Sep 4 17:28:40 1996 Stu Grossman (grossman@critters.cygnus.com)
+
+ * configure configure.in: Add host *windows* to list of hosts
+ that don't support GDBtk.
+
+Fri Aug 23 00:44:57 1996 Fred Fish <fnf@cygnus.com>
+
+ * gdbtk.c (gdbtk_init): Check for a DISPLAY env variable and
+ gracefully degrade to using command line interface if none is
+ found.
+
+Fri Aug 9 12:32:53 1996 Tom Tromey <tromey@creche.cygnus.com>
+
+ * Makefile.in (LIB_INSTALL_DIR): New macro.
+ (TCL): Include @TCL_LD_SEARCH_FLAGS@.
+
+Thu Aug 1 20:35:01 1996 Tom Tromey <tromey@creche.cygnus.com>
+
+ * gdbtk.c (mainWindow): Deleted.
+ (cleanup_init): Don't destroy main window.
+ (gdbtk_init): Main window now created by Tk_Init.
+
+ * configure.in: Most X checks now handled automatically by Tk.
+ Use new macros to find Tcl/Tk.
+ * aclocal.m4: New version for new Tcl/Tk; from Don Libes.
+ * config.in, configure: Regenerated.
+
+ * Makefile.in (TCL, TCL_CFLAGS, TK, TK_CFLAGS, X11_CFLAGS,
+ X11_LDFLAGS, X11_LIBS): Changed for new Tcl and Tk.
+
+Thu Aug 1 16:12:05 1996 Jason Molenda (crash@godzilla.cygnus.co.jp)
+
+ * Makefile.in (gdbtk.tcl): put in $(datadir), not $(libdir).
+
+Fri Jul 26 14:07:37 1996 Ian Lance Taylor <ian@cygnus.com>
+
+ * gdbtk.c (gdb_disassemble): Initialize di.flavour.
+
+Thu Jul 25 19:41:31 1996 Fred Fish <fnf@cygnus.com>
+
+ * gdbtk.c (null_routine): Ditto.
+ (gdbtk_flush): Ditto.
+ (gdbtk_fputs): Ditto.
+ (gdbtk_query): Ditto.
+ (gdbtk_readline): Ditto.
+ (gdbtk_readline_end): Ditto.
+ (gdb_get_breakpoint_list): Ditto.
+ (gdb_get_breakpoint_info): Ditto.
+ (breakpoint_notify): Ditto.
+ (gdbtk_create_breakpoint): Ditto.
+ (gdbtk_delete_breakpoint): Ditto.
+ (gdbtk_modify_breakpoint): Ditto.
+ (gdb_loc): Ditto.
+ (gdb_eval): Ditto.
+ (gdb_sourcelines): Ditto.
+ (map_arg_registers): Ditto.
+ (get_register_name): Ditto.
+ (gdb_regnames): Ditto.
+ (get_register): Ditto.
+ (gdb_fetch_registers): Ditto.
+ (register_changed_p): Ditto.
+ (gdb_changed_register_list): Ditto.
+ (gdb_cmd): Ditto.
+ (call_wrapper): Ditto.
+ (gdb_listfiles): Ditto.
+ (gdb_stop): Ditto.
+ (gdbtk_dis_asm_read_memory): Ditto.
+ (compare_lines): Ditto.
+ (gdb_disassemble): Ditto.
+ (tk_command): Ditto.
+ (cleanup_init): Ditto.
+ (gdbtk_interactive): Ditto.
+ (x_event): Ditto.
+ (gdbtk_wait): Ditto.
+ (gdbtk_call_command): Ditto.
+ (tk_command_loop): Ditto.
+ (gdbtk_init): Ditto.
+
+ * gdbtk.c (register_changed_p): Remove unused local variable "buf".
+
+Sat Jul 20 17:46:40 1996 Fred Fish <fnf@cygnus.com>
+
+ * gdbtk.tcl (files_command): Reorder the binding tags for
+ the listbox widget to avoid referencing the listbox after
+ the containing widget has been destroyed by the action of
+ a previous binding.
+
+Sat Jul 20 10:09:28 1996 Fred Fish <fnf@cygnus.com>
+
+ * gdbtk.tcl (delete_expr): Unset corresponding element of
+ expr_update_list when destroying an expression.
+ (create_expr_window): Initialize expr_num, delete_expr_num,
+ and expr_update_list here when each new expression window
+ is created, rather than once at startup.
+
+Mon Jul 15 16:44:05 1996 Stu Grossman (grossman@critters.cygnus.com)
+
+ * gdbtk.c (gdb_disassemble): Setup di.mach from
+ tm_print_insn_info.mach, and set endian from TARGET_BYTE_ORDER.
+
+Fri Jun 21 11:04:47 1996 Fred Fish <fnf@cygnus.com>
+
+ * gdbtk.tcl (create_register_windows): Include missing '$'s.
+ Add global declarations for various reg_format_* variables.
+ * gdbtk.tcl (populate_register_window): Make initial window one
+ line taller to account for new column header line.
+
+Fri Jun 21 09:46:47 1996 Fred Fish <fnf@cygnus.com>
+
+ * gdbtk.c (get_register): Support for printing raw formats.
+ * gdbtk.tcl: Add hint for using debug_interface.
+ (center_window, add_breakpoint_frame, delete_breakpoint_frame):
+ Enclose arg in braces for consistency.
+ (create_registers_window, populate_reg_window, update_registers):
+ Major rewrite to support displaying multiple formats in the register
+ window.
+ (init_reg_info): New function.
+ (recompute_reg_display_list): Reset reg_display_list, start
+ register display lines at line 2.
+
+Thu Jun 20 08:18:59 1996 Fred Fish <fnf@cygnus.com>
+
+ * gdbtk.tcl (gdbtk_tcl_readline_begin): Handle backspace to
+ avoid backing up over prompt. At every input, make sure insert
+ point is at least after command start, handle control-u to delete
+ current input line.
+ (tclsh): Handle backspace to avoid backing up over prompt. Handle
+ control-u to delete current input line.
+
+Wed Jun 19 17:23:38 1996 Geoffrey Noer <noer@cygnus.com>
+
+ * configure.in: disable gdbtk for *cygwin32* hosted compiles
+ * configure: regenerated with autoconf 2.8
+
+Sun May 19 16:49:37 1996 Fred Fish <fnf@cygnus.com>
+
+ * gdbtk.c (gdbtk_readline_begin, gdbtk_readline, gdbtk_readline_end):
+ New functions.
+ (tk_command_loop): Set instream to NULL to enable Tk user interaction.
+ (gdbtk_init): Set readline_begin_hook, readline_hook,
+ and readline_end_hook.
+ * gdbtk.tcl (gdbtk_tcl_readline_begin, gdbtk_tcl_readline,
+ gdbtk_tcl_readline_end): New functions.
+ (tclsh): Pack scroll bar on right side of window, not left.
+
+Fri May 17 13:54:34 1996 Fred Fish <fnf@cygnus.com>
+
+ * gdbtk.tcl (create_command_window): Change a misspelled "get"
+ to the intended "cget".
+ (delete_line): Fix so it deletes the current line at the
+ insertion cursor.
+
+Thu May 16 19:20:29 1996 Fred Fish <fnf@cygnus.com>
+
+ * gdbtk.tcl (gdb_prompt): Set this early on.
+ (create_command_window): Use gdb_prompt rather than "(gdb) ".
+ (gdbtk_tcl_preloop): Proc executed just prior to Tk main loop.
+ (tclsh): If an evaluation window already exists, just bring it
+ to the front instead of trying to create another.
+ * gdbtk.c (tk_command_loop): New function.
+ (gdbtk_init): Call tk_command_loop rather than Tk_MainLoop.
+
+Thu May 16 16:16:35 1996 Fred Fish <fnf@cygnus.com>
+
+ * gdbtk.tcl (evaluate_tcl_command, tclsh): New functions that
+ implement a tcl evaluation window for gdbtk maintainers to use.
+
+Thu May 16 11:42:58 1996 Tom Tromey <tromey@creche.cygnus.com>
+
+ * gdbtk.tcl (files_command): Correctly insert list of files into
+ listbox widget.
+
+ * gdbtk.tcl (files_command): listbox command no longer accepts
+ -geometry.
+
+Wed May 15 16:04:09 1996 Stan Shebs <shebs@andros.cygnus.com>
+
+ * gdbtk.tcl (create_command_window): If command window's buffer
+ is disabled, don't execute any of the key bindings.
+
+Mon May 13 13:43:25 1996 Fred Fish <fnf@cygnus.com>
+
+ * gdbtk.c (tk_command): Catch case where no argument is given
+ since this will cause the tcl interpreter to dump core.
+
+Wed May 8 20:33:24 1996 Fred Fish <fnf@cygnus.com>
+
+ * gdbtk.c: Fix a couple of misspellings.
+
+Thu May 2 19:17:49 1996 Stan Shebs <shebs@andros.cygnus.com>
+
+ * gdbtk.tcl (debug_interface): New global, use to aid debugging.
+ (insert_breakpoint_tag, delete_breakpoint_tag): Fix range.
+ (file_popup_menu): Delete, never used.
+ (listing_window_popup): Rename from listing_window_button_1,
+ remove breakpoint toggling code.
+ (toggle_breakpoint): New procedure.
+ (create_file_win): Bind popup menu to button 2, toggle breakpoints
+ with button 1 in breakpoint area, add display of tagged areas if
+ debugging on.
+
+Fri Apr 5 13:44:40 1996 Stan Shebs <shebs@andros.cygnus.com>
+
+ * gdbtk.c (running_now): New global variable.
+ (gdb_cmd): Test it before executing any command.
+ (gdbtk_call_command): Set it when inferior is running.
+ * gdbtk.tcl (gdbtk_tcl_busy, gdbtk_tcl_idle): Enable and
+ disable interaction with command window's text appropriately.
+
+Fri Apr 5 13:25:42 1996 Michael Meissner <meissner@tiktok.cygnus.com>
+
+ * gdbtk.c (SIOCSPGRP, linux): If on Linux, undef SIOCSPGRP, since
+ some versions of the kernel don't support it.
+
+Tue Feb 6 16:31:25 1996 Tom Tromey <tromey@creche.cygnus.com>
+
+ * gdbtk.tcl (create_file_win): Eliminate text widget B1 binding so
+ double-clicking will work again.
+ (create_asm_win): Put "break" at end of all B1 bindings.
+ (create_file_win): Lower "sel" tag, don't raise it.
+ (ensure_line_visible): New proc.
+ (update_listing, update_assembly): Use it.
+ (create_copyright_window): Destroy window on Leave event.
+ (create_command_window): Put "break" at end of all B2 bindings.
+
+Wed Jan 24 15:28:41 1996 Tom Tromey <tromey@creche.cygnus.com>
+
+ * gdbtk.tcl, gdbtk.c: Updated copyrights.
+
+ * configure.in: Look for -ldl or -ldld when using Tcl 7.5 or
+ greater.
+ * configure: Rebuilt.
+
+Tue Jan 23 09:00:48 1996 Doug Evans <dje@charmed.cygnus.com>
+
+ * gdbtk.c (gdb_disassemble): Pass fprintf_unfiltered to
+ INIT_DISASSEMBLE_INFO.
+
+Mon Jan 15 09:58:41 1996 Tom Tromey <tromey@creche.cygnus.com>
+
+ * gdbtk.tcl (create_expr_window): Many changes to update GUI.
+ (add_expr): Changes from create_expr_window.
+ (create_command_window): Set focus.
+ (delete_expr): Rewrote.
+ (expr_update_button): New proc.
+ (add_expr): Put bindings on FocusIn, FocusOut.
+ Don't allow .file_popup to be torn off.
+
+Fri Jan 12 09:36:17 1996 Tom Tromey <tromey@creche.cygnus.com>
+
+ * gdbtk.tcl (gdbtk_tcl_query): Swap Yes and No buttons.
+ (update_listing): Use lassign. Use "see" to scroll. Don't need
+ screen_top, screen_bot, screen_height.
+ (update_assembly): Use "see" to scroll.
+ (textscrollproc): Removed.
+ (create_file_win): Don't use textscrollproc.
+ (asmscrollproc): Removed.
+ (create_asm_window): Don't use asmscrollproc.
+ (create_asm_win): Ditto.
+ (screen_height, screen_top, screen_bot): Removed.
+ (run_editor): New proc.
+ (build_framework): Use it.
+ (create_file_win, create_source_window): Don't use textscrollproc.
+ (create_breakpoints_window): Set -xscrollcommand on canvas.
+ (not_implemented_yet): Default button is 0.
+ (delete_char): Don't use tk_textBackspace.
+ (create_command_window): Allow Tk bindings to fire after deleting
+ character.
+ (create_command_window): Make Delete delete left, not right.
+
+Thu Jan 11 10:08:14 1996 Tom Tromey <tromey@creche.cygnus.com>
+
+ * gdbtk.tcl (FSBox): Don't use tk_listboxSingleSelect.
+
+ Changes in sync with expect:
+ * configure.in (ENABLE_GDBTK): Use CY_AC_PATH_TCL and
+ CY_AC_PATH_TK.
+ * aclocal.m4: Replaced with version from expect.
+ * configure: Regenerated.
+
+Wed Jan 10 09:07:22 1996 Tom Tromey <tromey@creche.cygnus.com>
+
+ * gdbtk.tcl (gdbtk_tcl_fputs, gdbtk_tcl_fputs_error,
+ gdbtk_tcl_flush): Use "see", not "yview".
+ (gdbtk_tcl_query): Use questhead bitmap.
+ various: Always wrap condition of 'if' in {...}.
+ (add_breakpoint_frame): Set -value on radiobuttons.
+ (lassign): New proc.
+ (add_breakpoint_frame): Use lassign, not series of assignments.
+ (decr): Made faster.
+ (interactive_cmd): Use "see", not "yview".
+ (not_implemented_yet): Use warning bitmap.
+ (update_expr): Don't allow $expr to be evalled by Tcl.
+ (create_expr_window): Don't use "focus".
+ (delete_char, delete_line): Define globally.
+ (delete_line, delete_char, create_command_window, update_autocmd,
+ build_framework, create_asm_win, create_file_win): Use "see", not
+ "yview".
+ (create_copyright_window, center_window, bind_widget_after_class):
+ New procs.
+ (FSBox,create_command_window, create_autocmd_window): Binding
+ changes for Tk4.
+ (textscrollproc): Define globally.
+ (build_framework): tk_menuBar no longer needed. Keys Prior, Next,
+ Home, End, Up, and Down are all defined by Tk.
+ (apply_filespec): Use error bitmap in dialog.
+ (files_command): Don't use tk_listboxSingleSelect.
+ (files_command): Don't use "uniq" to remove duplicates from a
+ list.
+ (update_assembly): Use lassign.
+ (create_asm_win): Removed redundant bindings.
+ (listing_window_button_1, file_popup_menu): Use tk_popup.
+ (ButtonRelease-1 binding): Just remove tag from window; rest
+ handled by Tk.
+
+ * gdbtk.c (gdbtk_query): Use Tcl_Merge to provide quoting.
+ (call_wrapper): Use Tcl_Eval, not Tcl_VarEval.
+ (gdbtk_call_command): Ditto.
+
+Thu Jan 4 16:04:54 1996 Stu Grossman (grossman@cygnus.com)
+
+ * configure configure.in: Make --enable-gdbtk be the default.
+
+Thu Dec 28 15:10:49 1995 Stan Shebs <shebs@andros.cygnus.com>
+
+ * README.GDBTK: Polish introductory paragraph.
+
+Mon Oct 16 11:27:06 1995 Stu Grossman (grossman@cygnus.com)
+
+ * gdbtk.c (gdb_disassemble): Use fprintf_unfiltered instead of
+ fprintf_filtered.
+
+Tue Oct 10 15:26:39 1995 Fred Fish <fnf@cygnus.com>
+
+ * README.GDBTK: Updated for version 4.15.
+
+Sat Aug 19 17:20:22 1995 Michael Tiemann <tiemann@axon.cygnus.com>
+
+ * gdbtk.tcl: ENABLE comes back as "1" or "0", not "enable" or
+ "disable".
+ Also, wire up the breakpoint window so that it can be demo'd.
+
+Tue Aug 1 11:44:53 1995 J.T. Conklin <jtc@rtl.cygnus.com>
+
+ * gdbtk.c: Include "gdb_string.h" instead of <string.h>.
+
+Tue Jun 20 10:19:40 1995 Stu Grossman (grossman@cygnus.com)
+
+ * gdbtk.c: Add functions Tcl_Malloc, Tcl_Realloc, and Tcl_Free.
+
+ * gdbtk.tcl (add_breakpoint_frame): Add more fields.
+ * (create_file_win create_asm_win build_framework): Create null
+ bindings for meta keys to keep window from dropping down to
+ insertion point when meta is pressed by itself. New bindings:
+ Up/Down - Scroll up/down one line at a time
+ Next/Prior - Scroll up/down one page at a time
+ Home/End - Warp to current pc/end of file
+ * (build_framework): Turn on breakpoint menu.
+ * (create_command_window): Implement tab completion. Add binding
+ for ^C to stop target.
+
+Fri May 19 06:15:40 1995 Jim Kingdon <kingdon@deneb.cygnus.com>
+
+ * gdbtk.c: Conditionalize use of stdarg rather than varargs on
+ ANSI_PROTOTYPES not __STDC__; it must match the definition of
+ PARAMS.
+
+Thu May 18 15:58:46 1995 J.T. Conklin <jtc@rtl.cygnus.com>
+
+ * gdbtk.c (gdbtk_query): Use stdarg.h macros when compiling with
+ an ANSI compiler.
+
+Sat Apr 15 13:52:24 1995 Stan Shebs <shebs@andros.cygnus.com>
+
+ * gdbtk.c (gdb_disassemble): Read from inferior if connected
+ to a VxWorks target.
+
+Fri Apr 14 10:18:20 1995 Stu Grossman (grossman@cygnus.com)
+
+ * README.GDBTK: New file. Contains the obvious.
+
+Tue Apr 11 11:07:12 1995 Michael Meissner <meissner@tiktok.cygnus.com>
+
+ * gdbtk.c (gdbtk_init): If SIOCSPGRP is not available, but
+ F_SETOWN is, use that.
+
+Thu Apr 6 17:00:46 1995 Michael Meissner <meissner@tiktok.cygnus.com>
+
+ * Makefile.in (X11_INCLUDES): Define as empty.
+ (X11_CFLAGS): Define as including $(X11_INCLUDES).
+ (X11_LIB_SWITCHES): Define as empty.
+ (X11_LIBS): Define as -lX11.
+
+ * configure.in (enable_gdbtk): If gdbtk, support the --x-includes
+ and --x-libraries switches, setting the X11_INCLUDES and
+ X11_LIB_SWITCHES respectively. Instead of using a hardcoded -lX11
+ in ENABLE_CLIBS, use the X11_LIB_SWITCHES and X11_LIBS variables.
+
+ * gdbtk.c (gdbtk_init): If SIOCSPGRP is not available, don't use
+ it. This means that the stop button doesn't work, but is better
+ than nothing.
+
+Wed Mar 29 17:09:29 1995 Stu Grossman (grossman@cygnus.com)
+
+ * Makefile.in (gdbtk.o): Use X11_CFLAGS to provide alternate
+ locations (per-host) for X11 include files.
+ * config/pa/hppahpux.mh (XM_CLIBS): Add -L/usr/lib/X11R5 to force
+ the use of R5 libs.
+ (X11_CFLAGS): Add this to indicate the locs
+ of the R5 include files.
+
+Wed Mar 8 16:12:21 1995 Stu Grossman (grossman@cygnus.com)
+
+ * gdbtk.c (gdb_get_breakpoint_info): Return error if breakpoint
+ type is not bp_breakpoint.
+
+Tue Feb 14 17:16:41 1995 Stu Grossman (grossman@cygnus.com)
+
+ * gdbtk.c: Ditto.
+ * gdbtk.c: General cleanups, get rid of unused variables. Redo
+ handling of stdout/stderr to just return output as the result of
+ the tcl command that caused the output. Cleanup -Wall stuff.
+ * (breakpoint_notify): Now returns just action and breakpoint
+ number.
+ * (gdb_get_breakpoint_list): New routine. Does the obvious.
+ * (gdb_get_breakpoint_info): Mostly derived from the old
+ breakpoint_notify, but returns lots more info.
+ * (dsprintf_append_element): Helper routine, works like printf,
+ but appends a tcl element onto the specified DString. Good for
+ building up lists as return values.
+ * (gdbtk_enable/disable_breakpoint): Go away. Replaced with
+ gdbtk_modify_breakpoint.
+ * (*many routines*): Use new result protocol.
+ * (call_wrapper): Make sure that recursive calls don't trash results.
+ * gdbtk.tcl: New windows, autocmd, and breakpoints.
+ * (gdbtk_tcl_fputs): Don't use $current_output_win redirection
+ anymore. It's not needed (in fact, this routine may not be needed
+ anymore).
+ * (gdbtk_tcl_breakpoint): Change to reflect new breakpoint
+ notification protocol.
+ * (gdbtk_tcl_busy gdbtk_tcl_idle): Straighten out buttons, remove
+ catches.
+ * (interactive_cmd): Use this wrapper around button invocations
+ of many commands. This will catch errors and put the results into
+ the command window. It also updates all the other windows.
+ * Also, change reliefs of most things to sunken. This actually
+ looks better.
+ * (create_file_win): Fix margin binding to allow breakpoints to
+ work again.
+ * (create_asm_win): Use return value of gdb_disassemble instead
+ of implicit I/O to the command window.
+ * (create_command_window): Use new result protocol to get output
+ from commands.
+
+Sun Feb 5 20:32:44 1995 Jim Kingdon (kingdon@lioth.cygnus.com)
+
+ * gdbtk.c (gdb_disassemble): Deference pointer to function before
+ calling it (pre-ANSI compilers generally require this).
+
+Fri Feb 3 11:19:20 1995 Stu Grossman (grossman@cygnus.com)
+
+ * gdbtk.c (gdb_disassemble): Get rid of
+ dis_asm_read_memory_hook. We can now call the disassemblers
+ directly and have no need for this hook anymore.
+
+Mon Jan 30 17:34:24 1995 Stu Grossman (grossman@cygnus.com)
+
+ * gdbtk.tcl (create_file_win): Disable old popup menu for source
+ window.
+
+Wed Jan 25 18:23:46 1995 Stu Grossman (grossman@cygnus.com)
+
+ * gdbtk.c (gdbtk_init): Prevent segfault when gdbtk.tcl can't be
+ found.
+ * gdbtk.tcl: Initialize expr_update_list() to prevent errors when
+ popping up expression window for the first time.
+
+Tue Jan 24 12:10:28 1995 Stu Grossman (grossman@cygnus.com)
+
+ * gdbtk.tcl (create_registers_window): Work around a radiobutton
+ widget bug to make Options|Natural button work.
+
+ * gdbtk.c (gdb_disassemble): Fix problem with source+assembly and
+ g++ caused by out-of-order pc's.
+ * gdbtk.tcl (files_command): Remove duplicate file names. Also,
+ add scrollbar.
+
+Mon Jan 23 17:21:09 1995 Stu Grossman (grossman@cygnus.com)
+
+ * gdbtk.tcl: Take .gdbtkinit if it exists. Makes gdbtk match the
+ doc!
+
+Thu Jan 12 15:02:40 1995 Stu Grossman (grossman@cygnus.com)
+
+ * gdbtk.c, gdbtk.tcl: Update/add copyright.
+ * gdbtk.tcl (build_framework): Several fixes for filespec widget,
+ including dismiss button, and better error handling.
+ * (create_command_win): Bind button 2 to retrieve selection.
+
+Wed Jan 11 17:06:55 1995 Stu Grossman (grossman@cygnus.com)
+
+ * gdbtk.tcl: Add button to control mixed source disassembly.
+ Use text widgets in expr window. The give me more control over
+ layout.
+ Add auto-updating of exprs in expression window.
+ Handle expressions out of scope a bit better.
+ Make selected window pop up to the top when invoked via the
+ menubar.
+ Make copyright message have raised relief.
+
+ * gdbtk.c (gdbtk_init): Improve handling for errors in gdbtk.tcl
+ during startup.
+
+Thu Jan 5 17:38:29 1995 Stu Grossman (grossman@cygnus.com)
+
+ * gdbtk.c (finish_saving_output): Don't do anything if not saving
+ output.
+ * (breakpoint_notify): Don't send null filename to tcl.
+ * (gdb_eval): New tcl command to eval an expression.
+ * (gdb_disassemble): New tcl command to do disassembly. This
+ allows tcl code to choose between exec file and target memeory,
+ and can also do mixed source and assembly.
+ * (gdbtk_init): Move reading of gdbtk.tcl to the end to make sure
+ that more of the environment is set up. Also, create link between
+ gdb and tcl vars disassemble{-_}from{-_}exec.
+
+ * gdbtk.tcl: New expression window support.
+ * Make assembly window be 80 columns wide.
+ * Use new disassembly method. Add menu items to select
+ disassembly from exec file or target.
+ * Change View menubar item to Options.
+
+ * Get rid of Stack, Breakpoints, Signals, and Variables Windows,
+ since they don't exist yet.
+
+ * Pop up a copyright window on startup.
+
+Wed Jan 4 19:49:10 1995 Stan Shebs <shebs@andros.cygnus.com>
+
+ * gdbtk.tcl (build_framework): Add standard commands menu, more
+ windows to standard windows menu.
+ (not_implemented_yet): Clarify message.
+
+Fri Dec 30 15:49:00 1994 Stan Shebs <shebs@andros.cygnus.com>
+
+ * gdbtk.tcl (FSBox): New proc, File Selection Box code from exmh.
+ (not_implemented_yet): New proc.
+ (build_framework): Add various file commands to file menu.
+
+Fri Dec 23 16:18:50 1994 Stu Grossman (grossman@cygnus.com)
+
+ * gdbtk.c (gdbtk_wait gdbtk_init): Portability improvements for
+ SIGIO handling.
+
+Mon Dec 19 09:55:47 1994 Stu Grossman (grossman@cygnus.com)
+
+ * gdbtk.tcl (update_assembly): Force update to make sure that pc
+ is visible when creating new assembly windows.
+
+Sun Dec 18 23:31:20 1994 Stu Grossman (grossman@cygnus.com)
+
+ * gdbtk.c (gdbtk_wait gdbtk_init): Use different method of
+ enabling I/O interrupts for SVR4 (streams).
+ * (start_saving_output save_output get_saved_output
+ finish_saving_output flush_holdbuf gdbtk_flush gdbtk_fputs
+ gdbtk_init):
+ Totally revamp to use TCLs dynamic string functions. Also, quote
+ all data passed back to TCL to prevent errors with unmatched
+ braces, odd characters, etc... This fixes several wierd problems
+ with outputting strings containing unmatched braces.
+ * (breakpoint_notify gdb_loc): Use long hex format to output
+ addresses of breakpoints and PCs. This fixes some Alpha problems.
+ * (breakpoint_notify): Add stream arg to call to gdbtk_fputs.
+ * (gdb_listfiles): Also, go through the symtabs when looking for
+ files. This makes xcoff work (sort of), but probably breaks
+ something else.
+ * (gdb_stop): Return TCL_OK instead of nothing. This fixes odd
+ TCL errors when hitting stop button.
+ * (tk_command): Don't pass interp->result on to Tcl_{Var}Eval, as
+ that will trash the result. strdup the result instead and pass
+ that on. Improve error handling as well.
+
+ * gdbtk.tcl (gdbtk_tcl_flush): Use global def of
+ current_output_win. Makes flushing actually work!
+ * (asm_win_name create_asm_win update_assembly): Bunch of fixes
+ to make assembly windows stop flashing when loading a new file.
+ * (gdbtk_tcl_busy gdbtk_tcl_idle): Use catch to prevent gdb_cmd
+ errors from losing control.
+ * (create_source_window): Add source file selection to View menu.
+ * (create_command_window (<Key-Return> binding): Quote text fed
+ into gdb_cmd to prevent eval errors.
+
+Thu Dec 15 16:40:10 1994 Stu Grossman (grossman@cygnus.com)
+
+ * gdbtk.c: Improve mechanism for capturing output values.
+ (full_filename): Remove.
+ (gdb_cmd call_wrapper gdbtk_init): Protect all calls from tcl land
+ with call_wrapper. This prevents longjmps (usually via error())
+ from jumping out of tcl/tk and leaving things in an indeterminate
+ state.
+ (gdbtk_fputs): Differentiate stdout from stderr when passing text
+ into tcl land.
+ * gdbtk.tcl: New view option to disable line numbers. Put catch
+ around most uses of gdb_cmd. Add update button to reg config
+ window. Stop doing immediate updates when selecting registers.
+ Change register view values into checkbuttons.
+
+Mon Dec 12 16:59:29 1994 Stu Grossman (grossman@cygnus.com)
+
+ * gdbtk.tcl (reg_config_menu create_registers_window
+ recompute_reg_display_list): Use array instead of individual vars
+ for register display list.
+ * (recompute_reg_display_list update_registers): Fix bug with not
+ displaying all registers.
+
+Mon Dec 12 12:22:21 1994 Stu Grossman (grossman@cygnus.com)
+
+ * gdbtk.c: New tcl commands: gdb_fetch_registers,
+ gdb_changed_register_list, and gdb_regnames.
+ * gdbtk.tcl: Use monochrome color model for now.
+ * (delete_breakpoint_tag create_file_win): Add breakdot support.
+ * (create_file_win create_asm_win update_listing build_framework
+ create_source_window create_command_window): Re-org window
+ creation to give all windows consistent look and feel.
+ * (update_listing update_asm): Change pc pointer to '->'.
+ * (registers_command reg_config_menu create_registers_window
+ populate_reg_window update_registers): Revamp register window.
+ Allow selection of registers to be displayed. Highlight changed
+ registers.
+
+Mon Nov 28 09:17:20 1994 Stu Grossman (grossman@cygnus.com)
+
+ * gdbtk.tcl (build_framework): Fix bug with setting window titles.
+
+ * gdbtk.tcl (build_framework): Add "Report bug" to help menu.
+
+ * gdbtk.tcl: Re-arrange windows using new, consistent layout. Clean
+ up lots of code and centralize framework initialization.
+
+Wed Nov 16 15:28:29 1994 Rob Savoye (rob@cygnus.com)
+
+ * Makefile.in: Fix the test for installing gdbtk.
+
+Mon Nov 14 08:51:29 1994 Stu Grossman (grossman@cygnus.com)
+
+ * Makefile.in: Install gdbtk.tcl.
+ * configure.in: Add ENABLE_GDBTK flag.
+ * gdbtk.c (gdb_sourcelines): Returns list of source lines
+ containing code. (gdb_regnames): Returns list of register names.
+
+Thu Nov 3 14:25:24 1994 Stu Grossman (grossman@cygnus.com)
+
+ * gdbtk.c (gdb_stop): Switch to target_stop().
+
+Tue Nov 1 16:41:12 1994 Stu Grossman (grossman@cygnus.com)
+
+ * Makefile.in: Use $(objdir)/tcl and $(objdir)/tk if they are
+ available.
+ * configure.in (ENABLE_CLIBS): Use $(TCL) and $(TK) instead of
+ -ltcl and -ltk.
+ * gdbtk.c: Get rid of lots of unnecessary #includes.
+ * (gdbtk_init): Use ConnectionNumber macro instead of referencing
+ Display structure directly.
+ * gdbtk.tcl: Change exit button to quit button.
+
+Wed Oct 26 15:41:07 1994 Stu Grossman (grossman@cygnus.com)
+
+ * gdbtk.c: Change sense and name of no_windows variable. Now
+ called use_windows, and defaults to off (for compatibility).
+
+Thu Oct 20 17:35:45 1994 Stu Grossman (grossman@cygnus.com)
+
+ * gdbtk.c (gdb_cmd): Force GUI into idle mode when errors occur.
+ * (gdb_stop): New tcl command to stop the target process.
+ * (x_event, gdbtk_wait): Allow GUI to interrupt gdb out of target
+ waits.
+ * (gdbtk_call_command): Wrapper around command processing to
+ alert GUI of target state changes.
+ * (gdbtk_init): Get the fd of X server for doing async
+ notification of X events (via x_event). Setup new hooks.
+ * gdbtk.tcl: Add scrollbars to assembly and command windows.
+ * Change window foreground & background colors.
+ * Create margin tag for breakpoints in source and assembly windows.
+ * Add new routines to be invoked when target state changes to/from
+ idle.
+ * Add start of expression window.
+ * Change bindings of mouse button 1 in assembly and source window
+ to just set or clear breakpoints when in the margin tag.
+ * Change shape of register window to be more vertical to better
+ reflect its contents.
+ * Add stop button.
+ * Cleanup some code around command window bindings.
+
+Sat Sep 17 17:05:14 1994 Stu Grossman (grossman@cygnus.com)
+
+ * gdbtk.tcl: Let ^U delete lines in the command window.
+
+Fri Sep 16 15:40:34 1994 Stu Grossman (grossman@cygnus.com)
+
+ * gdbtk.c: Replace calls to full_filename with symtab_to_filename.
+ * gdbtk.tcl: New routine pc_to_line replaces in line code. New
+ routine decr replaces in line code.
+ * (create_file_win): Use catch to handle open failures more
+ elegantly. Also, create special window to display file open
+ failure message. Move opening of file prior to creation of text
+ widget.
+ * (create_asm_win): Add PC as argument. We now base disassembly
+ on PC instead of function name, since function names can be
+ ambiguous (usually seen with shared libs). Also, use catch to
+ simplify code where we don't care about failures.
+
+Wed Sep 14 00:55:26 1994 Stu Grossman (grossman@cygnus.com)
+
+ * gdbtk.tcl: Add ref counts to breakpoint tags.
+ * Put quotes around function name in disassemble command to better
+ handle assembler names containing `.'.
+ * Make pclist element 0 be filler to avoid off-by-one problem with
+ line numbers.
+ * Set names of top-level windows.
+ * Add register display window.
+ * Add PC to label of assembly window.
+
+Tue Sep 13 08:59:04 1994 Stu Grossman (grossman@cygnus.com)
+
+ * gdbtk.c (gdbtk_flush gdbtk_fputs): Buffer up output to make
+ disassembly more efficient.
+ * (breakpoint_notify): Include pc in gdbtk_tcl_breakpoint
+ callback.
+ * (gdb_loc): Include pc in return value. Also, return function
+ name if arg was specified.
+ * (gdb_cmd_stub): Call gdb_flush to drain internal GDB buffers
+ after command completes.
+ * (gdbtk_init): Improve error handling.
+
+ * gdbtk.tcl: Add lots of comments. Clean up code.
+ * (gdbtk_tcl_fputs): Make output window redirectable.
+ * Add assembly window, and breapoint support.
+ * Make button 1 in margin toggle breakpoints.
+ * Use stippling to indicate breakpoint disabling.
+
+Fri Sep 2 19:11:40 1994 Stu Grossman (grossman@cygnus.com)
+
+ * configure.in: Don't symlink to gdbtk.tcl if it's already there.
+
+Thu Jul 28 14:37:36 1994 Stu Grossman (grossman@cygnus.com)
+
+ Support for TK GUI.
+ * Makefile.in: Add rule for gdbtk.o.
+ * configure.in: Add support for --enable-gdbtk.
+ * gdbtk.c: New file. Contains support routines for TK interface.
+ * gdbtk.tcl: New file. Implements GUI policy.
+
+
+Local Variables:
+mode: change-log
+left-margin: 8
+fill-column: 74
+version-control: never
+End:
diff --git a/gdb/gdbtk/generic/gdbtk-cmds.c b/gdb/gdbtk/generic/gdbtk-cmds.c
index 1d6effeba8d..656374bb386 100644
--- a/gdb/gdbtk/generic/gdbtk-cmds.c
+++ b/gdb/gdbtk/generic/gdbtk-cmds.c
@@ -1,5 +1,5 @@
-/* Tcl/Tk command definitions for Insight.
- Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2001, 2002, 2003, 2004, 2007, 2008
+/* Tcl/Tk command definitions for gdbtk.
+ Copyright 1994, 1995, 1996, 1997, 1998, 1999
Free Software Foundation, Inc.
Written by Stu Grossman <grossman@cygnus.com> of Cygnus Support.
@@ -20,65 +20,61 @@
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
- Foundation, Inc., 51 Franklin Street, Fifth Floor,
- Boston, MA 02110-1301, USA. */
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
#include "defs.h"
+#include "symtab.h"
#include "inferior.h"
+#include "command.h"
#include "source.h"
+#include "bfd.h"
#include "symfile.h"
#include "objfiles.h"
+#include "target.h"
#include "gdbcore.h"
+#include "tracepoint.h"
#include "demangle.h"
-#include "linespec.h"
+#include "frame.h"
#include "tui/tui-file.h"
-#include "top.h"
-#include "annotate.h"
-#include "block.h"
-#include "dictionary.h"
-#include "filenames.h"
-#include "disasm.h"
-#include "value.h"
-#include "varobj.h"
-#include "exceptions.h"
-#include "language.h"
-#include "target.h"
-/* tcl header files includes varargs.h unless HAS_STDARG is defined,
- but gdb uses stdarg.h, so make sure HAS_STDARG is defined. */
-#define HAS_STDARG 1
+#include <sys/stat.h>
-#include <itcl.h>
#include <tcl.h>
#include <tk.h>
-
+#include <itcl.h>
+#include <tix.h>
#include "guitcl.h"
#include "gdbtk.h"
-#include "gdbtk-wrapper.h"
-#include "gdbtk-cmds.h"
#include <signal.h>
#include <fcntl.h>
-#ifdef HAVE_SYS_IOCTL_H
+#include "top.h"
#include <sys/ioctl.h>
-#endif
-#include <sys/time.h>
-#include <sys/stat.h>
-
#include "gdb_string.h"
#include "dis-asm.h"
+#include <stdio.h>
#include "gdbcmd.h"
-#ifdef __CYGWIN__
-#include <sys/cygwin.h> /* for cygwin_conv_to_full_win32_path */
-#endif
+#include "annotate.h"
+#include <sys/time.h>
-#ifdef HAVE_CTYPE_H
-#include <ctype.h> /* for isprint() */
-#endif
+static void setup_architecture_data PARAMS ((void));
+static int tracepoint_exists (char *args);
-/* Various globals we reference. */
-extern char *source_path;
+/* This structure filled in call_wrapper and passed to
+ the wrapped call function.
+ It stores the command pointer and arguments
+ run in the wrapper function. */
+
+struct wrapped_call_args
+ {
+ Tcl_Interp *interp;
+ Tcl_ObjCmdProc *func;
+ int objc;
+ Tcl_Obj *CONST * objv;
+ int val;
+ };
/* These two objects hold boolean true and false,
and are shared by all the list objects that gdb_listfuncs
@@ -92,31 +88,40 @@ static Tcl_Obj *mangled, *not_mangled;
int No_Update = 0;
int load_in_progress = 0;
-/* This Structure is used in gdb_disassemble_driver.
+/*
+ * This is used in the register fetching routines
+ */
+
+#ifndef INVALID_FLOAT
+#define INVALID_FLOAT(x, y) (0 != 0)
+#endif
+
+
+
+/* This Structure is used in gdb_disassemble.
We need a different sort of line table from the normal one cuz we can't
depend upon implicit line-end pc's for lines to do the
reordering in this function. */
struct my_line_entry
-{
- int line;
- CORE_ADDR start_pc;
- CORE_ADDR end_pc;
-};
+ {
+ int line;
+ CORE_ADDR start_pc;
+ CORE_ADDR end_pc;
+ };
/* Use this to pass the Tcl Text widget command and the open file
descriptor to the disassembly load command. */
-struct disassembly_client_data
-{
+struct disassembly_client_data {
FILE *fp;
int file_opened_p;
int widget_line_no;
Tcl_Interp *interp;
char *widget;
Tcl_Obj *result_obj[3];
- const char *asm_argv[14];
- const char *source_argv[7];
+ char *asm_argv[14];
+ char *source_argv[7];
char *map_arr;
Tcl_DString src_to_line_prefix;
Tcl_DString pc_to_line_prefix;
@@ -124,93 +129,192 @@ struct disassembly_client_data
Tcl_CmdInfo cmd;
};
-/* This variable determines where memory used for disassembly is read
- from. See note in gdbtk.h for details. */
-/* NOTE: cagney/2003-09-08: This variable is unused. */
+/* This contains the previous values of the registers, since the last call to
+ gdb_changed_register_list. */
+
+static char *old_regs;
+
+/* These two lookup tables are used to translate the type & disposition fields
+ of the breakpoint structure (respectively) into something gdbtk understands.
+ They are also used in gdbtk-hooks.c */
+
+char *bptypes[] =
+{"none", "breakpoint", "hw breakpoint", "until",
+ "finish", "watchpoint", "hw watchpoint",
+ "read watchpoint", "acc watchpoint",
+ "longjmp", "longjmp resume", "step resume",
+ "sigtramp", "watchpoint scope",
+ "call dummy", "shlib events", "catch load",
+ "catch unload", "catch fork", "catch vfork",
+ "catch exec", "catch catch", "catch throw"
+};
+char *bpdisp[] =
+{"delete", "delstop", "disable", "donttouch"};
+
+/*
+ * These are routines we need from breakpoint.c.
+ * at some point make these static in breakpoint.c and move GUI code there
+ */
+
+extern struct breakpoint *set_raw_breakpoint (struct symtab_and_line sal);
+extern void set_breakpoint_count (int);
+extern int breakpoint_count;
+
+/* This variable determines where memory used for disassembly is read from.
+ * See note in gdbtk.h for details.
+ */
int disassemble_from_exec = -1;
-extern int gdb_variable_init (Tcl_Interp * interp);
+extern int gdb_variable_init PARAMS ((Tcl_Interp * interp));
/*
* Declarations for routines exported from this file
*/
int Gdbtk_Init (Tcl_Interp * interp);
+int call_wrapper PARAMS ((ClientData, Tcl_Interp *, int, Tcl_Obj * CONST[]));
/*
* Declarations for routines used only in this file.
*/
-static int compare_lines (const PTR, const PTR);
-static int comp_files (const void *, const void *);
-static int gdb_clear_file (ClientData, Tcl_Interp * interp, int,
- Tcl_Obj * CONST[]);
-static int gdb_cmd (ClientData, Tcl_Interp *, int, Tcl_Obj * CONST[]);
-static int gdb_confirm_quit (ClientData, Tcl_Interp *, int,
- Tcl_Obj * CONST[]);
-static int gdb_entry_point (ClientData, Tcl_Interp *, int, Tcl_Obj * CONST[]);
-static int gdb_eval (ClientData, Tcl_Interp *, int, Tcl_Obj * CONST[]);
-static int gdb_find_file_command (ClientData, Tcl_Interp *, int,
- Tcl_Obj * CONST objv[]);
-static int gdb_force_quit (ClientData, Tcl_Interp *, int, Tcl_Obj * CONST[]);
-static int gdb_get_file_command (ClientData, Tcl_Interp *, int,
- Tcl_Obj * CONST objv[]);
-static int gdb_get_function_command (ClientData, Tcl_Interp *, int,
- Tcl_Obj * CONST objv[]);
-static int gdb_get_line_command (ClientData, Tcl_Interp *, int,
- Tcl_Obj * CONST objv[]);
-static int gdb_update_mem (ClientData, Tcl_Interp *, int, Tcl_Obj * CONST[]);
-static int gdb_set_mem (ClientData, Tcl_Interp *, int, Tcl_Obj * CONST[]);
-static int gdb_immediate_command (ClientData, Tcl_Interp *, int,
- Tcl_Obj * CONST[]);
-static int gdb_incr_addr (ClientData, Tcl_Interp *, int, Tcl_Obj * CONST[]);
-static int gdb_CA_to_TAS (ClientData, Tcl_Interp *, int, Tcl_Obj * CONST[]);
-static int gdb_listfiles (ClientData, Tcl_Interp *, int, Tcl_Obj * CONST[]);
-static int gdb_listfuncs (ClientData, Tcl_Interp *, int, Tcl_Obj * CONST[]);
-static int gdb_loadfile (ClientData, Tcl_Interp *, int,
- Tcl_Obj * CONST objv[]);
-static int gdb_load_disassembly (ClientData clientData, Tcl_Interp
- * interp, int objc, Tcl_Obj * CONST objv[]);
-static int gdb_get_inferior_args (ClientData clientData,
- Tcl_Interp *interp,
- int objc, Tcl_Obj * CONST objv[]);
-static int gdb_set_inferior_args (ClientData clientData,
- Tcl_Interp *interp,
- int objc, Tcl_Obj * CONST objv[]);
-static int gdb_load_info (ClientData, Tcl_Interp *, int,
- Tcl_Obj * CONST objv[]);
-static int gdb_loc (ClientData, Tcl_Interp *, int, Tcl_Obj * CONST[]);
-static int gdb_path_conv (ClientData, Tcl_Interp *, int, Tcl_Obj * CONST[]);
-static int gdb_prompt_command (ClientData, Tcl_Interp *, int,
- Tcl_Obj * CONST objv[]);
-static int gdb_restore_fputs (ClientData, Tcl_Interp *, int,
- Tcl_Obj * CONST[]);
-static int gdb_search (ClientData, Tcl_Interp *, int, Tcl_Obj * CONST objv[]);
-static int gdb_stop (ClientData, Tcl_Interp *, int, Tcl_Obj * CONST[]);
-static int gdb_target_has_execution_command (ClientData,
- Tcl_Interp *, int,
- Tcl_Obj * CONST[]);
-static void gdbtk_load_source (ClientData clientData,
- struct symtab *symtab,
- int start_line, int end_line);
-static CORE_ADDR gdbtk_load_asm (ClientData clientData, CORE_ADDR pc,
- struct disassemble_info *di);
-static int gdb_disassemble_driver (CORE_ADDR low, CORE_ADDR high,
- int mixed_source_and_assembly,
- ClientData clientData,
- void (*print_source_fn) (ClientData, struct
- symtab *, int,
- int),
- CORE_ADDR (*print_asm_fn) (ClientData,
- CORE_ADDR,
- struct
- disassemble_info
- *));
-char *get_prompt (void);
-static int perror_with_name_wrapper (PTR args);
+static int compare_lines PARAMS ((const PTR, const PTR));
+static int comp_files PARAMS ((const void *, const void *));
+static int gdb_actions_command PARAMS ((ClientData, Tcl_Interp *, int,
+ Tcl_Obj * CONST objv[]));
+static int gdb_changed_register_list PARAMS ((ClientData, Tcl_Interp *, int,
+ Tcl_Obj * CONST[]));
+static int gdb_clear_file PARAMS ((ClientData, Tcl_Interp * interp, int,
+ Tcl_Obj * CONST[]));
+static int gdb_cmd PARAMS ((ClientData, Tcl_Interp *, int,
+ Tcl_Obj * CONST[]));
+static int gdb_confirm_quit PARAMS ((ClientData, Tcl_Interp *, int,
+ Tcl_Obj * CONST[]));
+static int gdb_disassemble PARAMS ((ClientData, Tcl_Interp *, int,
+ Tcl_Obj * CONST[]));
+static int gdb_eval PARAMS ((ClientData, Tcl_Interp *, int,
+ Tcl_Obj * CONST[]));
+static int gdb_fetch_registers PARAMS ((ClientData, Tcl_Interp *, int,
+ Tcl_Obj * CONST[]));
+static int gdb_find_file_command PARAMS ((ClientData, Tcl_Interp *, int,
+ Tcl_Obj * CONST objv[]));
+static int gdb_force_quit PARAMS ((ClientData, Tcl_Interp *, int,
+ Tcl_Obj * CONST[]));
+static struct symtab *full_lookup_symtab PARAMS ((char *file));
+static int gdb_get_args_command PARAMS ((ClientData, Tcl_Interp *, int,
+ Tcl_Obj * CONST objv[]));
+static int gdb_get_breakpoint_info PARAMS ((ClientData, Tcl_Interp *, int,
+ Tcl_Obj * CONST[]));
+static int gdb_get_breakpoint_list PARAMS ((ClientData, Tcl_Interp *, int,
+ Tcl_Obj * CONST[]));
+static int gdb_get_file_command PARAMS ((ClientData, Tcl_Interp *, int,
+ Tcl_Obj * CONST objv[]));
+static int gdb_get_function_command PARAMS ((ClientData, Tcl_Interp *, int,
+ Tcl_Obj * CONST objv[]));
+static int gdb_get_line_command PARAMS ((ClientData, Tcl_Interp *, int,
+ Tcl_Obj * CONST objv[]));
+static int gdb_get_locals_command PARAMS ((ClientData, Tcl_Interp *, int,
+ Tcl_Obj * CONST objv[]));
+static int gdb_get_mem PARAMS ((ClientData, Tcl_Interp *, int,
+ Tcl_Obj * CONST[]));
+static int gdb_get_trace_frame_num PARAMS ((ClientData, Tcl_Interp *, int,
+ Tcl_Obj * CONST objv[]));
+static int gdb_get_tracepoint_list PARAMS ((ClientData, Tcl_Interp *, int,
+ Tcl_Obj * CONST objv[]));
+static int gdb_get_vars_command PARAMS ((ClientData, Tcl_Interp *, int,
+ Tcl_Obj * CONST objv[]));
+static int gdb_immediate_command PARAMS ((ClientData, Tcl_Interp *, int,
+ Tcl_Obj * CONST[]));
+static int gdb_listfiles PARAMS ((ClientData, Tcl_Interp *, int,
+ Tcl_Obj * CONST[]));
+static int gdb_listfuncs PARAMS ((ClientData, Tcl_Interp *, int,
+ Tcl_Obj * CONST[]));
+static int gdb_loadfile PARAMS ((ClientData, Tcl_Interp *, int,
+ Tcl_Obj * CONST objv[]));
+static int gdb_load_disassembly PARAMS ((ClientData clientData, Tcl_Interp
+ *interp,
+ int objc, Tcl_Obj *CONST objv[]));
+static int gdb_load_info PARAMS ((ClientData, Tcl_Interp *, int,
+ Tcl_Obj * CONST objv[]));
+static int gdb_loc PARAMS ((ClientData, Tcl_Interp *, int,
+ Tcl_Obj * CONST[]));
+static int gdb_path_conv PARAMS ((ClientData, Tcl_Interp *, int,
+ Tcl_Obj * CONST[]));
+static int gdb_prompt_command PARAMS ((ClientData, Tcl_Interp *, int,
+ Tcl_Obj * CONST objv[]));
+static int gdb_regnames PARAMS ((ClientData, Tcl_Interp *, int,
+ Tcl_Obj * CONST[]));
+static int gdb_restore_fputs PARAMS ((ClientData, Tcl_Interp *, int,
+ Tcl_Obj * CONST[]));
+static int gdb_search PARAMS ((ClientData, Tcl_Interp *, int,
+ Tcl_Obj * CONST objv[]));
+static int gdb_set_bp PARAMS ((ClientData, Tcl_Interp *, int,
+ Tcl_Obj * CONST objv[]));
+static int gdb_set_bp_addr PARAMS ((ClientData, Tcl_Interp *, int,
+ Tcl_Obj * CONST objv[]));
+static int gdb_find_bp_at_line PARAMS ((ClientData, Tcl_Interp *, int,
+ Tcl_Obj * CONST objv[]));
+static int gdb_find_bp_at_addr PARAMS ((ClientData, Tcl_Interp *, int,
+ Tcl_Obj * CONST objv[]));
+static int gdb_stop PARAMS ((ClientData, Tcl_Interp *, int,
+ Tcl_Obj * CONST[]));
+static int gdb_target_has_execution_command PARAMS ((ClientData,
+ Tcl_Interp *, int,
+ Tcl_Obj * CONST[]));
+static int gdb_trace_status PARAMS ((ClientData, Tcl_Interp *, int,
+ Tcl_Obj * CONST[]));
+static int gdb_tracepoint_exists_command PARAMS ((ClientData, Tcl_Interp *,
+ int,
+ Tcl_Obj * CONST objv[]));
+static int gdb_get_tracepoint_info PARAMS ((ClientData, Tcl_Interp *, int,
+ Tcl_Obj * CONST objv[]));
+static int gdbtk_dis_asm_read_memory PARAMS ((bfd_vma, bfd_byte *, int,
+ disassemble_info *));
+static void gdbtk_load_source PARAMS ((ClientData clientData,
+ struct symtab *symtab,
+ int start_line, int end_line));
+static CORE_ADDR gdbtk_load_asm PARAMS ((ClientData clientData, CORE_ADDR pc,
+ struct disassemble_info *di));
+static void gdbtk_print_source PARAMS ((ClientData clientData,
+ struct symtab *symtab,
+ int start_line, int end_line));
+static CORE_ADDR gdbtk_print_asm PARAMS ((ClientData clientData, CORE_ADDR pc,
+ struct disassemble_info *di));
+static int gdb_disassemble_driver PARAMS ((CORE_ADDR low, CORE_ADDR high,
+ int mixed_source_and_assembly,
+ ClientData clientData,
+ void (*print_source_fn) (ClientData, struct
+ symtab *, int, int),
+ CORE_ADDR (*print_asm_fn) (ClientData,
+ CORE_ADDR,
+ struct disassemble_info *)));
+static int get_pc_register PARAMS ((ClientData, Tcl_Interp *, int,
+ Tcl_Obj *CONST []));
+static int gdb_stack PARAMS ((ClientData, Tcl_Interp *, int,
+ Tcl_Obj *CONST []));
+static int gdb_selected_frame PARAMS ((ClientData clientData,
+ Tcl_Interp *interp, int argc,
+ Tcl_Obj *CONST objv[]));
+static int gdb_selected_block PARAMS ((ClientData clientData,
+ Tcl_Interp *interp, int argc,
+ Tcl_Obj *CONST objv[]));
+static int gdb_get_blocks PARAMS ((ClientData clientData,
+ Tcl_Interp *interp, int objc,
+ Tcl_Obj *CONST objv[]));
+static int gdb_block_vars PARAMS ((ClientData clientData,
+ Tcl_Interp *interp, int objc,
+ Tcl_Obj *CONST objv[]));
+char * get_prompt PARAMS ((void));
+static void get_register PARAMS ((int, void *));
+static void get_register_name PARAMS ((int, void *));
+static int map_arg_registers PARAMS ((int, Tcl_Obj * CONST[],
+ void (*)(int, void *), void *));
+static int perror_with_name_wrapper PARAMS ((PTR args));
+static void register_changed_p PARAMS ((int, void *));
static int wrapped_call (PTR opaque_args);
-static int hex2bin (const char *hex, char *bin, int count);
-static int fromhex (int a);
+static void get_frame_name PARAMS ((Tcl_Interp * interp, Tcl_Obj * list,
+ struct frame_info * fi));
+char *pc_function_name PARAMS ((CORE_ADDR pc));
/* Gdbtk_Init
@@ -224,98 +328,123 @@ static int fromhex (int a);
*/
int
-Gdbtk_Init (Tcl_Interp *interp)
+Gdbtk_Init (interp)
+ Tcl_Interp *interp;
{
- Tcl_CreateObjCommand (interp, "gdb_cmd", gdbtk_call_wrapper, gdb_cmd, NULL);
- Tcl_CreateObjCommand (interp, "gdb_immediate", gdbtk_call_wrapper,
+ Tcl_CreateObjCommand (interp, "gdb_cmd", call_wrapper, gdb_cmd, NULL);
+ Tcl_CreateObjCommand (interp, "gdb_immediate", call_wrapper,
gdb_immediate_command, NULL);
- Tcl_CreateObjCommand (interp, "gdb_loc", gdbtk_call_wrapper, gdb_loc, NULL);
- Tcl_CreateObjCommand (interp, "gdb_path_conv", gdbtk_call_wrapper, gdb_path_conv,
+ Tcl_CreateObjCommand (interp, "gdb_loc", call_wrapper, gdb_loc, NULL);
+ Tcl_CreateObjCommand (interp, "gdb_path_conv", call_wrapper, gdb_path_conv,
NULL);
- Tcl_CreateObjCommand (interp, "gdb_listfiles", gdbtk_call_wrapper, gdb_listfiles,
+ Tcl_CreateObjCommand (interp, "gdb_listfiles", call_wrapper, gdb_listfiles,
NULL);
- Tcl_CreateObjCommand (interp, "gdb_listfuncs", gdbtk_call_wrapper, gdb_listfuncs,
+ Tcl_CreateObjCommand (interp, "gdb_listfuncs", call_wrapper, gdb_listfuncs,
NULL);
- Tcl_CreateObjCommand (interp, "gdb_entry_point", gdbtk_call_wrapper,
- gdb_entry_point, NULL);
- Tcl_CreateObjCommand (interp, "gdb_update_mem", gdbtk_call_wrapper, gdb_update_mem,
+ Tcl_CreateObjCommand (interp, "gdb_get_mem", call_wrapper, gdb_get_mem,
NULL);
- Tcl_CreateObjCommand (interp, "gdb_set_mem", gdbtk_call_wrapper, gdb_set_mem,
+ Tcl_CreateObjCommand (interp, "gdb_stop", call_wrapper, gdb_stop, NULL);
+ Tcl_CreateObjCommand (interp, "gdb_regnames", call_wrapper, gdb_regnames,
NULL);
- Tcl_CreateObjCommand (interp, "gdb_stop", gdbtk_call_wrapper, gdb_stop, NULL);
- Tcl_CreateObjCommand (interp, "gdb_restore_fputs", gdbtk_call_wrapper, gdb_restore_fputs,
+ Tcl_CreateObjCommand (interp, "gdb_restore_fputs", call_wrapper, gdb_restore_fputs,
NULL);
- Tcl_CreateObjCommand (interp, "gdb_eval", gdbtk_call_wrapper, gdb_eval, NULL);
- Tcl_CreateObjCommand (interp, "gdb_incr_addr", gdbtk_call_wrapper, gdb_incr_addr, NULL);
- Tcl_CreateObjCommand (interp, "gdb_CA_to_TAS", gdbtk_call_wrapper, gdb_CA_to_TAS, NULL);
- Tcl_CreateObjCommand (interp, "gdb_clear_file", gdbtk_call_wrapper,
+ Tcl_CreateObjCommand (interp, "gdb_fetch_registers", call_wrapper,
+ gdb_fetch_registers, NULL);
+ Tcl_CreateObjCommand (interp, "gdb_changed_register_list", call_wrapper,
+ gdb_changed_register_list, NULL);
+ Tcl_CreateObjCommand (interp, "gdb_disassemble", call_wrapper,
+ gdb_disassemble, NULL);
+ Tcl_CreateObjCommand (interp, "gdb_eval", call_wrapper, gdb_eval, NULL);
+ Tcl_CreateObjCommand (interp, "gdb_get_breakpoint_list", call_wrapper,
+ gdb_get_breakpoint_list, NULL);
+ Tcl_CreateObjCommand (interp, "gdb_get_breakpoint_info", call_wrapper,
+ gdb_get_breakpoint_info, NULL);
+ Tcl_CreateObjCommand (interp, "gdb_clear_file", call_wrapper,
gdb_clear_file, NULL);
- Tcl_CreateObjCommand (interp, "gdb_confirm_quit", gdbtk_call_wrapper,
+ Tcl_CreateObjCommand (interp, "gdb_confirm_quit", call_wrapper,
gdb_confirm_quit, NULL);
- Tcl_CreateObjCommand (interp, "gdb_force_quit", gdbtk_call_wrapper,
+ Tcl_CreateObjCommand (interp, "gdb_force_quit", call_wrapper,
gdb_force_quit, NULL);
Tcl_CreateObjCommand (interp, "gdb_target_has_execution",
- gdbtk_call_wrapper,
+ call_wrapper,
gdb_target_has_execution_command, NULL);
- Tcl_CreateObjCommand (interp, "gdb_load_info", gdbtk_call_wrapper, gdb_load_info,
+ Tcl_CreateObjCommand (interp, "gdb_is_tracing",
+ call_wrapper, gdb_trace_status,
+ NULL);
+ Tcl_CreateObjCommand (interp, "gdb_load_info", call_wrapper, gdb_load_info,
NULL);
- Tcl_CreateObjCommand (interp, "gdb_get_function", gdbtk_call_wrapper,
+ Tcl_CreateObjCommand (interp, "gdb_get_locals", call_wrapper,
+ gdb_get_locals_command, NULL);
+ Tcl_CreateObjCommand (interp, "gdb_get_args", call_wrapper,
+ gdb_get_args_command, NULL);
+ Tcl_CreateObjCommand (interp, "gdb_get_function", call_wrapper,
gdb_get_function_command, NULL);
- Tcl_CreateObjCommand (interp, "gdb_get_line", gdbtk_call_wrapper,
+ Tcl_CreateObjCommand (interp, "gdb_get_line", call_wrapper,
gdb_get_line_command, NULL);
- Tcl_CreateObjCommand (interp, "gdb_get_file", gdbtk_call_wrapper,
+ Tcl_CreateObjCommand (interp, "gdb_get_file", call_wrapper,
gdb_get_file_command, NULL);
+ Tcl_CreateObjCommand (interp, "gdb_tracepoint_exists",
+ call_wrapper, gdb_tracepoint_exists_command, NULL);
+ Tcl_CreateObjCommand (interp, "gdb_get_tracepoint_info",
+ call_wrapper, gdb_get_tracepoint_info, NULL);
+ Tcl_CreateObjCommand (interp, "gdb_actions",
+ call_wrapper, gdb_actions_command, NULL);
Tcl_CreateObjCommand (interp, "gdb_prompt",
- gdbtk_call_wrapper, gdb_prompt_command, NULL);
+ call_wrapper, gdb_prompt_command, NULL);
Tcl_CreateObjCommand (interp, "gdb_find_file",
- gdbtk_call_wrapper, gdb_find_file_command, NULL);
- Tcl_CreateObjCommand (interp, "gdb_loadfile", gdbtk_call_wrapper, gdb_loadfile,
+ call_wrapper, gdb_find_file_command, NULL);
+ Tcl_CreateObjCommand (interp, "gdb_get_tracepoint_list",
+ call_wrapper, gdb_get_tracepoint_list, NULL);
+ Tcl_CreateObjCommand (interp, "gdb_pc_reg", call_wrapper, get_pc_register,
NULL);
- Tcl_CreateObjCommand (interp, "gdb_load_disassembly", gdbtk_call_wrapper,
+ Tcl_CreateObjCommand (interp, "gdb_loadfile", call_wrapper, gdb_loadfile,
+ NULL);
+ Tcl_CreateObjCommand (interp, "gdb_load_disassembly", call_wrapper,
gdb_load_disassembly, NULL);
- Tcl_CreateObjCommand (gdbtk_interp, "gdb_search", gdbtk_call_wrapper,
+ Tcl_CreateObjCommand (gdbtk_interp, "gdb_search", call_wrapper,
gdb_search, NULL);
- Tcl_CreateObjCommand (interp, "gdb_get_inferior_args", gdbtk_call_wrapper,
- gdb_get_inferior_args, NULL);
- Tcl_CreateObjCommand (interp, "gdb_set_inferior_args", gdbtk_call_wrapper,
- gdb_set_inferior_args, NULL);
+ Tcl_CreateObjCommand (interp, "gdb_set_bp", call_wrapper, gdb_set_bp, NULL);
+ Tcl_CreateObjCommand (interp, "gdb_set_bp_addr", call_wrapper,
+ gdb_set_bp_addr, NULL);
+ Tcl_CreateObjCommand (interp, "gdb_find_bp_at_line", call_wrapper,
+ gdb_find_bp_at_line, NULL);
+ Tcl_CreateObjCommand (interp, "gdb_find_bp_at_addr", call_wrapper,
+ gdb_find_bp_at_addr, NULL);
+ Tcl_CreateObjCommand (interp, "gdb_get_trace_frame_num",
+ call_wrapper, gdb_get_trace_frame_num, NULL);
+ Tcl_CreateObjCommand (interp, "gdb_stack", call_wrapper, gdb_stack, NULL);
+ Tcl_CreateObjCommand (interp, "gdb_selected_frame", call_wrapper,
+ gdb_selected_frame, NULL);
+ Tcl_CreateObjCommand (interp, "gdb_selected_block", call_wrapper,
+ gdb_selected_block, NULL);
+ Tcl_CreateObjCommand (interp, "gdb_get_blocks", call_wrapper,
+ gdb_get_blocks, NULL);
+ Tcl_CreateObjCommand (interp, "gdb_block_variables", call_wrapper,
+ gdb_block_vars, NULL);
+
+ Tcl_LinkVar (interp, "gdb_selected_frame_level",
+ (char *) &selected_frame_level,
+ TCL_LINK_INT | TCL_LINK_READ_ONLY);
/* gdb_context is used for debugging multiple threads or tasks */
Tcl_LinkVar (interp, "gdb_context_id",
(char *) &gdb_context,
TCL_LINK_INT | TCL_LINK_READ_ONLY);
- /* Make gdb's notion of the pwd visible. This is read-only because
- (1) it doesn't make sense to change it directly and (2) it is
- allocated using xmalloc and not Tcl_Alloc. You might think we
- could just use the Tcl `pwd' command. However, Tcl (erroneously,
- imho) maintains a cache of the current directory name, and
- doesn't provide a way for gdb to invalidate the cache. */
- Tcl_LinkVar (interp, "gdb_current_directory",
- (char *) &current_directory,
- TCL_LINK_STRING | TCL_LINK_READ_ONLY);
-
- /* Current gdb source file search path. This is read-only for
- reasons similar to those for gdb_current_directory. */
- Tcl_LinkVar (interp, "gdb_source_path",
- (char *) &source_path,
- TCL_LINK_STRING | TCL_LINK_READ_ONLY);
-
/* Init variable interface... */
if (gdb_variable_init (interp) != TCL_OK)
return TCL_ERROR;
+
+ /* Route GDB internal log messages and target output and through
+ stderr instead of stdout. FIXME: Should have a separate streams
+ for handling these two types of output. */
+ gdb_stdtarg = gdb_stderr;
+ gdb_stdlog = gdb_stderr;
- /* Init breakpoint module */
- if (Gdbtk_Breakpoint_Init (interp) != TCL_OK)
- return TCL_ERROR;
-
- /* Init stack module */
- if (Gdbtk_Stack_Init (interp) != TCL_OK)
- return TCL_ERROR;
-
- /* Init register module */
- if (Gdbtk_Register_Init (interp) != TCL_OK)
- return TCL_ERROR;
+ /* Register/initialize any architecture specific data */
+ setup_architecture_data ();
+ register_gdbarch_swap (&old_regs, sizeof (old_regs), NULL);
+ register_gdbarch_swap (NULL, 0, setup_architecture_data);
/* Determine where to disassemble from */
Tcl_LinkVar (gdbtk_interp, "disassemble-from-exec",
@@ -335,12 +464,14 @@ Gdbtk_Init (Tcl_Interp *interp)
necessary. */
int
-gdbtk_call_wrapper (ClientData clientData, Tcl_Interp *interp,
- int objc, Tcl_Obj *CONST objv[])
+call_wrapper (clientData, interp, objc, objv)
+ ClientData clientData;
+ Tcl_Interp *interp;
+ int objc;
+ Tcl_Obj *CONST objv[];
{
struct wrapped_call_args wrapped_args;
gdbtk_result new_result, *old_result_ptr;
- int wrapped_returned_error = 0;
old_result_ptr = result_ptr;
result_ptr = &new_result;
@@ -379,24 +510,16 @@ gdbtk_call_wrapper (ClientData clientData, Tcl_Interp *interp,
Tcl_Eval (interp, "gdbtk_tcl_idle");
}
- else
- {
- /* If the wrapped call returned an error directly, then we don't
- want to reset the result. */
- wrapped_returned_error = wrapped_args.val == TCL_ERROR;
- }
/* do not suppress any errors -- a remote target could have errored */
load_in_progress = 0;
/*
- * Now copy the result over to the true Tcl result. If
- * GDBTK_TO_RESULT flag bit is set, this just copies a null object
- * over to the Tcl result, which is fine because we should reset the
- * result in this case anyway. If the wrapped command returned an
- * error, then we assume that the result is already set correctly.
+ * Now copy the result over to the true Tcl result. If GDBTK_TO_RESULT flag
+ * bit is set , this just copies a null object over to the Tcl result,
+ * which is fine because we should reset the result in this case anyway.
*/
- if ((result_ptr->flags & GDBTK_IN_TCL_RESULT) || wrapped_returned_error)
+ if (result_ptr->flags & GDBTK_IN_TCL_RESULT)
{
Tcl_DecrRefCount (result_ptr->obj_ptr);
}
@@ -419,13 +542,30 @@ gdbtk_call_wrapper (ClientData clientData, Tcl_Interp *interp,
*/
static int
-wrapped_call (PTR opaque_args)
+wrapped_call (opaque_args)
+ PTR opaque_args;
{
struct wrapped_call_args *args = (struct wrapped_call_args *) opaque_args;
args->val = (*args->func) (args->func, args->interp, args->objc, args->objv);
return 1;
}
+/* This is a convenience function to sprintf something(s) into a
+ * new element in a Tcl list object.
+ */
+
+static void
+sprintf_append_element_to_obj (Tcl_Obj * objp, char *format,...)
+{
+ va_list args;
+ char buf[1024];
+
+ va_start (args, format);
+
+ vsprintf (buf, format, args);
+
+ Tcl_ListObjAppendElement (NULL, objp, Tcl_NewStringObj (buf, -1));
+}
/*
* This section contains the commands that control execution.
@@ -433,29 +573,30 @@ wrapped_call (PTR opaque_args)
/* This implements the tcl command gdb_clear_file.
-* Prepare to accept a new executable file. This is called when we
-* want to clear away everything we know about the old file, without
-* asking the user. The Tcl code will have already asked the user if
-* necessary. After this is called, we should be able to run the
-* `file' command without getting any questions.
-*
-* Arguments:
-* None
-* Tcl Result:
-* None
-*/
+ * Prepare to accept a new executable file. This is called when we
+ * want to clear away everything we know about the old file, without
+ * asking the user. The Tcl code will have already asked the user if
+ * necessary. After this is called, we should be able to run the
+ * `file' command without getting any questions.
+ *
+ * Arguments:
+ * None
+ * Tcl Result:
+ * None
+ */
static int
-gdb_clear_file (ClientData clientData, Tcl_Interp *interp,
- int objc, Tcl_Obj *CONST objv[])
+gdb_clear_file (clientData, interp, objc, objv)
+ ClientData clientData;
+ Tcl_Interp *interp;
+ int objc;
+ Tcl_Obj *CONST objv[];
{
if (objc != 1)
- {
- Tcl_WrongNumArgs (interp, 1, objv, NULL);
- return TCL_ERROR;
- }
+ Tcl_SetStringObj (result_ptr->obj_ptr,
+ "Wrong number of args, none are allowed.", -1);
- if (! ptid_equal (inferior_ptid, null_ptid) && target_has_execution)
+ if (inferior_pid != 0 && target_has_execution)
{
if (attach_flag)
target_detach (NULL, 0);
@@ -467,8 +608,8 @@ gdb_clear_file (ClientData clientData, Tcl_Interp *interp,
pop_target ();
delete_command (NULL, 0);
- exec_file_clear (0);
- symbol_file_clear (0);
+ exec_file_command (NULL, 0);
+ symbol_file_command (NULL, 0);
return TCL_OK;
}
@@ -483,14 +624,18 @@ gdb_clear_file (ClientData clientData, Tcl_Interp *interp,
*/
static int
-gdb_confirm_quit (ClientData clientData, Tcl_Interp *interp,
- int objc, Tcl_Obj *CONST objv[])
+gdb_confirm_quit (clientData, interp, objc, objv)
+ ClientData clientData;
+ Tcl_Interp *interp;
+ int objc;
+ Tcl_Obj *CONST objv[];
{
int ret;
if (objc != 1)
{
- Tcl_WrongNumArgs (interp, 1, objv, NULL);
+ Tcl_SetStringObj (result_ptr->obj_ptr,
+ "Wrong number of args, should be none.", -1);
return TCL_ERROR;
}
@@ -509,12 +654,16 @@ gdb_confirm_quit (ClientData clientData, Tcl_Interp *interp,
*/
static int
-gdb_force_quit (ClientData clientData, Tcl_Interp *interp,
- int objc, Tcl_Obj *CONST objv[])
+gdb_force_quit (clientData, interp, objc, objv)
+ ClientData clientData;
+ Tcl_Interp *interp;
+ int objc;
+ Tcl_Obj *CONST objv[];
{
if (objc != 1)
{
- Tcl_WrongNumArgs (interp, 1, objv, NULL);
+ Tcl_SetStringObj (result_ptr->obj_ptr,
+ "Wrong number of args, should be none.", -1);
return TCL_ERROR;
}
@@ -526,9 +675,9 @@ gdb_force_quit (ClientData clientData, Tcl_Interp *interp,
* stop the target. If, after some short time, this fails, a dialog
* should appear allowing the user to detach.
*
- * The global GDBTK_FORCE_DETACH is set when we wish to detach from a
- * target. This value is returned by deprecated_ui_loop_hook
- * (x_event), indicating to callers that they should detach.
+ * The global GDBTK_FORCE_DETACH is set when we wish to detach
+ * from a target. This value is returned by ui_loop_hook (x_event),
+ * indicating to callers that they should detach.
*
* Read the comments before x_event to find out how we (try) to keep
* gdbtk alive while some other event loop has stolen control from us.
@@ -547,8 +696,11 @@ gdb_force_quit (ClientData clientData, Tcl_Interp *interp,
*/
static int
-gdb_stop (ClientData clientData, Tcl_Interp *interp,
- int objc, Tcl_Obj *CONST objv[])
+gdb_stop (clientData, interp, objc, objv)
+ ClientData clientData;
+ Tcl_Interp *interp;
+ int objc;
+ Tcl_Obj *CONST objv[];
{
int force = 0;
char *s;
@@ -556,7 +708,7 @@ gdb_stop (ClientData clientData, Tcl_Interp *interp,
if (objc > 1)
{
s = Tcl_GetStringFromObj (objv[1], NULL);
- if (strcmp (s, "detach") == 0)
+ if (STREQ (s, "detach"))
force = 1;
}
@@ -568,8 +720,8 @@ gdb_stop (ClientData clientData, Tcl_Interp *interp,
}
else
{
- if (target_ignore != (void (*) (void)) current_target.to_stop)
- target_stop (gdbtk_get_ptid ());
+ if (target_stop != target_ignore)
+ target_stop ();
else
quit_flag = 1; /* hope something sees this */
}
@@ -590,83 +742,76 @@ gdb_stop (ClientData clientData, Tcl_Interp *interp,
*
* Tcl Arguments:
* expression - the expression to evaluate.
- * format - optional format character. Valid chars are:
- * o - octal
- * x - hex
- * d - decimal
- * u - unsigned decimal
- * t - binary
- * f - float
- * a - address
- * c - char
* Tcl Result:
* The result of the evaluation.
*/
static int
-gdb_eval (ClientData clientData, Tcl_Interp *interp,
- int objc, Tcl_Obj *CONST objv[])
+gdb_eval (clientData, interp, objc, objv)
+ ClientData clientData;
+ Tcl_Interp *interp;
+ int objc;
+ Tcl_Obj *CONST objv[];
{
struct expression *expr;
struct cleanup *old_chain = NULL;
- int format = 0;
value_ptr val;
- struct ui_file *stb;
- long dummy;
- char *result;
- if (objc != 2 && objc != 3)
+ if (objc != 2)
{
- Tcl_WrongNumArgs (interp, 1, objv, "expression [format]");
+ Tcl_SetStringObj (result_ptr->obj_ptr,
+ "wrong # args, should be \"gdb_eval expression\"", -1);
return TCL_ERROR;
}
- if (objc == 3)
- format = *(Tcl_GetStringFromObj (objv[2], NULL));
-
expr = parse_expression (Tcl_GetStringFromObj (objv[1], NULL));
- old_chain = make_cleanup (free_current_contents, &expr);
+
+ old_chain = make_cleanup ((make_cleanup_func) free_current_contents, &expr);
+
val = evaluate_expression (expr);
- /* "Print" the result of the expression evaluation. */
- stb = mem_fileopen ();
- make_cleanup_ui_file_delete (stb);
- val_print (value_type (val), value_contents (val),
- value_embedded_offset (val), VALUE_ADDRESS (val),
- stb, format, 0, 0, 0, current_language);
- result = ui_file_xstrdup (stb, &dummy);
- Tcl_SetObjResult (interp, Tcl_NewStringObj (result, -1));
- xfree (result);
- result_ptr->flags |= GDBTK_IN_TCL_RESULT;
+ /*
+ * Print the result of the expression evaluation. This will go to
+ * eventually go to gdbtk_fputs, and from there be collected into
+ * the Tcl result.
+ */
+
+ val_print (VALUE_TYPE (val), VALUE_CONTENTS (val),
+ VALUE_EMBEDDED_OFFSET (val), VALUE_ADDRESS (val),
+ gdb_stdout, 0, 0, 0, 0);
do_cleanups (old_chain);
+
return TCL_OK;
}
/* This implements the tcl command "gdb_cmd".
-* It sends its argument to the GDB command scanner for execution.
-* This command will never cause the update, idle and busy hooks to be called
-* within the GUI.
-*
-* Tcl Arguments:
-* command - The GDB command to execute
-* from_tty - 1 indicates this comes to the console.
-* Pass this to the gdb command.
-* Tcl Result:
-* The output from the gdb command (except for the "load" & "while"
-* which dump their output to the console.
-*/
+ * It sends its argument to the GDB command scanner for execution.
+ * This command will never cause the update, idle and busy hooks to be called
+ * within the GUI.
+ *
+ * Tcl Arguments:
+ * command - The GDB command to execute
+ * from_tty - 1 indicates this comes to the console.
+ * Pass this to the gdb command.
+ * Tcl Result:
+ * The output from the gdb command (except for the "load" & "while"
+ * which dump their output to the console.
+ */
static int
-gdb_cmd (ClientData clientData, Tcl_Interp *interp,
- int objc, Tcl_Obj *CONST objv[])
+gdb_cmd (clientData, interp, objc, objv)
+ ClientData clientData;
+ Tcl_Interp *interp;
+ int objc;
+ Tcl_Obj *CONST objv[];
{
int from_tty = 0;
- if (objc < 2 || objc > 3)
+ if (objc < 2)
{
- Tcl_WrongNumArgs (interp, 1, objv, "command ?from_tty?");
+ Tcl_SetStringObj (result_ptr->obj_ptr, "wrong # args", -1);
return TCL_ERROR;
}
@@ -674,7 +819,8 @@ gdb_cmd (ClientData clientData, Tcl_Interp *interp,
{
if (Tcl_GetBooleanFromObj (NULL, objv[2], &from_tty) != TCL_OK)
{
- gdbtk_set_result (interp, "from_tty must be a boolean.");
+ Tcl_SetStringObj (result_ptr->obj_ptr, "from_tty must be a boolean.",
+ -1);
return TCL_ERROR;
}
}
@@ -724,14 +870,18 @@ gdb_cmd (ClientData clientData, Tcl_Interp *interp,
*/
static int
-gdb_immediate_command (ClientData clientData, Tcl_Interp *interp,
- int objc, Tcl_Obj *CONST objv[])
+gdb_immediate_command (clientData, interp, objc, objv)
+ ClientData clientData;
+ Tcl_Interp *interp;
+ int objc;
+ Tcl_Obj *CONST objv[];
{
+
int from_tty = 0;
- if (objc < 2 || objc > 3)
+ if (objc < 2)
{
- Tcl_WrongNumArgs (interp, 1, objv, "command ?from_tty?");
+ Tcl_SetStringObj (result_ptr->obj_ptr, "wrong # args", -1);
return TCL_ERROR;
}
@@ -739,7 +889,8 @@ gdb_immediate_command (ClientData clientData, Tcl_Interp *interp,
{
if (Tcl_GetBooleanFromObj (NULL, objv[2], &from_tty) != TCL_OK)
{
- gdbtk_set_result (interp, "from_tty must be a boolean.");
+ Tcl_SetStringObj (result_ptr->obj_ptr, "from_tty must be a boolean.",
+ -1);
return TCL_ERROR;
}
}
@@ -762,17 +913,20 @@ gdb_immediate_command (ClientData clientData, Tcl_Interp *interp,
/* This implements the tcl command "gdb_prompt"
-* It returns the gdb interpreter's prompt.
-*
-* Tcl Arguments:
-* None.
-* Tcl Result:
-* The prompt.
-*/
+ * It returns the gdb interpreter's prompt.
+ *
+ * Tcl Arguments:
+ * None.
+ * Tcl Result:
+ * The prompt.
+ */
static int
-gdb_prompt_command (ClientData clientData, Tcl_Interp *interp,
- int objc, Tcl_Obj *CONST objv[])
+gdb_prompt_command (clientData, interp, objc, objv)
+ ClientData clientData;
+ Tcl_Interp *interp;
+ int objc;
+ Tcl_Obj *CONST objv[];
{
Tcl_SetStringObj (result_ptr->obj_ptr, get_prompt (), -1);
return TCL_OK;
@@ -785,98 +939,46 @@ gdb_prompt_command (ClientData clientData, Tcl_Interp *interp,
/* This implements the tcl command "gdb_target_has_execution"
-* Tells whether the target is executing.
-*
-* Tcl Arguments:
-* None
-* Tcl Result:
-* A boolean indicating whether the target is executing.
-*/
+ * Tells whether the target is executing.
+ *
+ * Tcl Arguments:
+ * None
+ * Tcl Result:
+ * A boolean indicating whether the target is executing.
+ */
static int
-gdb_target_has_execution_command (ClientData clientData, Tcl_Interp *interp,
- int objc, Tcl_Obj *CONST objv[])
+gdb_target_has_execution_command (clientData, interp, objc, objv)
+ ClientData clientData;
+ Tcl_Interp *interp;
+ int objc;
+ Tcl_Obj *CONST objv[];
{
int result = 0;
- if (target_has_execution && ! ptid_equal (inferior_ptid, null_ptid))
+ if (target_has_execution && inferior_pid != 0)
result = 1;
Tcl_SetBooleanObj (result_ptr->obj_ptr, result);
return TCL_OK;
}
-/* This implements the tcl command "gdb_get_inferior_args"
-
-* Returns inferior command line arguments as a string
-*
-* Tcl Arguments:
-* None
-* Tcl Result:
-* A string containing the inferior command line arguments
-*/
-
-static int
-gdb_get_inferior_args (ClientData clientData, Tcl_Interp *interp,
- int objc, Tcl_Obj *CONST objv[])
-{
- if (objc != 1)
- {
- Tcl_WrongNumArgs (interp, 1, objv, NULL);
- return TCL_ERROR;
- }
-
- Tcl_SetStringObj (result_ptr->obj_ptr, get_inferior_args (), -1);
- return TCL_OK;
-}
-
-/* This implements the tcl command "gdb_set_inferior_args"
-
-* Sets inferior command line arguments
-*
-* Tcl Arguments:
-* A string containing the inferior command line arguments
-* Tcl Result:
-* None
-*/
-
-static int
-gdb_set_inferior_args (ClientData clientData, Tcl_Interp *interp,
- int objc, Tcl_Obj *CONST objv[])
-{
- char *args;
-
- if (objc != 2)
- {
- Tcl_WrongNumArgs (interp, 1, objv, "argument");
- return TCL_ERROR;
- }
-
- args = Tcl_GetStringFromObj (objv[1], NULL);
-
- /* The xstrdup/xfree stuff is so that we maintain a coherent picture
- for gdb. I would expect the accessors to do this, but they
- don't. */
- args = xstrdup (args);
- args = set_inferior_args (args);
- xfree (args);
-
- return TCL_OK;
-}
-
/* This implements the tcl command "gdb_load_info"
-* It returns information about the file about to be downloaded.
-*
-* Tcl Arguments:
-* filename: The file to open & get the info on.
-* Tcl Result:
-* A list consisting of the name and size of each section.
-*/
+ * It returns information about the file about to be downloaded.
+ *
+ * Tcl Arguments:
+ * filename: The file to open & get the info on.
+ * Tcl Result:
+ * A list consisting of the name and size of each section.
+ */
static int
-gdb_load_info (ClientData clientData, Tcl_Interp *interp,
- int objc, Tcl_Obj *CONST objv[])
+gdb_load_info (clientData, interp, objc, objv)
+ ClientData clientData;
+ Tcl_Interp *interp;
+ int objc;
+ Tcl_Obj *CONST objv[];
{
bfd *loadfile_bfd;
struct cleanup *old_cleanups;
@@ -888,14 +990,14 @@ gdb_load_info (ClientData clientData, Tcl_Interp *interp,
loadfile_bfd = bfd_openr (filename, gnutarget);
if (loadfile_bfd == NULL)
{
- gdbtk_set_result (interp, "Open of %s failed", filename);
+ Tcl_SetStringObj (result_ptr->obj_ptr, "Open failed", -1);
return TCL_ERROR;
}
- old_cleanups = make_cleanup_bfd_close (loadfile_bfd);
+ old_cleanups = make_cleanup ((make_cleanup_func) bfd_close, loadfile_bfd);
if (!bfd_check_format (loadfile_bfd, bfd_object))
{
- gdbtk_set_result (interp, "Bad Object File");
+ Tcl_SetStringObj (result_ptr->obj_ptr, "Bad Object File", -1);
return TCL_ERROR;
}
@@ -905,7 +1007,7 @@ gdb_load_info (ClientData clientData, Tcl_Interp *interp,
{
if (s->flags & SEC_LOAD)
{
- bfd_size_type size = bfd_get_section_size (s);
+ bfd_size_type size = bfd_get_section_size_before_reloc (s);
if (size > 0)
{
ob[0] = Tcl_NewStringObj ((char *)
@@ -923,31 +1025,184 @@ gdb_load_info (ClientData clientData, Tcl_Interp *interp,
}
+/* gdb_get_locals -
+ * This and gdb_get_locals just call gdb_get_vars_command with the right
+ * value of clientData. We can't use the client data in the definition
+ * of the command, because the call wrapper uses this instead...
+ */
+
+static int
+gdb_get_locals_command (clientData, interp, objc, objv)
+ ClientData clientData;
+ Tcl_Interp *interp;
+ int objc;
+ Tcl_Obj *CONST objv[];
+{
+
+ return gdb_get_vars_command ((ClientData) 0, interp, objc, objv);
+
+}
+
+static int
+gdb_get_args_command (clientData, interp, objc, objv)
+ ClientData clientData;
+ Tcl_Interp *interp;
+ int objc;
+ Tcl_Obj *CONST objv[];
+{
+
+ return gdb_get_vars_command ((ClientData) 1, interp, objc, objv);
+
+}
+
+/* This implements the tcl commands "gdb_get_locals" and "gdb_get_args"
+
+ * This function sets the Tcl interpreter's result to a list of variable names
+ * depending on clientData. If clientData is one, the result is a list of
+ * arguments; zero returns a list of locals -- all relative to the block
+ * specified as an argument to the command. Valid commands include
+ * anything decode_line_1 can handle (like "main.c:2", "*0x02020202",
+ * and "main").
+ *
+ * Tcl Arguments:
+ * linespec - the linespec defining the scope of the lookup. Empty string
+ * to use the current block in the innermost frame.
+ * Tcl Result:
+ * A list of the locals or args
+ */
+
+static int
+gdb_get_vars_command (clientData, interp, objc, objv)
+ ClientData clientData;
+ Tcl_Interp *interp;
+ int objc;
+ Tcl_Obj *CONST objv[];
+{
+ struct symtabs_and_lines sals;
+ struct symbol *sym;
+ struct block *block;
+ char **canonical, *args;
+ int i, nsyms, arguments;
+
+ if (objc > 2)
+ {
+ Tcl_AppendStringsToObj (result_ptr->obj_ptr,
+ "wrong # of args: should be \"",
+ Tcl_GetStringFromObj (objv[0], NULL),
+ " [function:line|function|line|*addr]\"", NULL);
+ return TCL_ERROR;
+ }
+
+ arguments = (int) clientData;
+
+ /* Initialize the result pointer to an empty list. */
+
+ Tcl_SetListObj (result_ptr->obj_ptr, 0, NULL);
+
+ if (objc == 2)
+ {
+ args = Tcl_GetStringFromObj (objv[1], NULL);
+ sals = decode_line_1 (&args, 1, NULL, 0, &canonical);
+ if (sals.nelts == 0)
+ {
+ Tcl_SetStringObj (result_ptr->obj_ptr,
+ "error decoding line", -1);
+ return TCL_ERROR;
+ }
+
+ /* Resolve all line numbers to PC's */
+ for (i = 0; i < sals.nelts; i++)
+ resolve_sal_pc (&sals.sals[i]);
+
+ block = block_for_pc (sals.sals[0].pc);
+ }
+ else
+ {
+ /* Specified currently selected frame */
+ if (selected_frame == NULL)
+ return TCL_OK;
+
+ block = get_frame_block (selected_frame);
+ }
+
+ while (block != 0)
+ {
+ nsyms = BLOCK_NSYMS (block);
+ for (i = 0; i < nsyms; i++)
+ {
+ sym = BLOCK_SYM (block, i);
+ switch (SYMBOL_CLASS (sym))
+ {
+ default:
+ case LOC_UNDEF: /* catches errors */
+ case LOC_CONST: /* constant */
+ case LOC_TYPEDEF: /* local typedef */
+ case LOC_LABEL: /* local label */
+ case LOC_BLOCK: /* local function */
+ case LOC_CONST_BYTES: /* loc. byte seq. */
+ case LOC_UNRESOLVED: /* unresolved static */
+ case LOC_OPTIMIZED_OUT: /* optimized out */
+ break;
+ case LOC_ARG: /* argument */
+ case LOC_REF_ARG: /* reference arg */
+ case LOC_REGPARM: /* register arg */
+ case LOC_REGPARM_ADDR: /* indirect register arg */
+ case LOC_LOCAL_ARG: /* stack arg */
+ case LOC_BASEREG_ARG: /* basereg arg */
+ if (arguments)
+ Tcl_ListObjAppendElement (interp, result_ptr->obj_ptr,
+ Tcl_NewStringObj (SYMBOL_NAME (sym), -1));
+ break;
+ case LOC_LOCAL: /* stack local */
+ case LOC_BASEREG: /* basereg local */
+ case LOC_STATIC: /* static */
+ case LOC_REGISTER: /* register */
+ if (!arguments)
+ Tcl_ListObjAppendElement (interp, result_ptr->obj_ptr,
+ Tcl_NewStringObj (SYMBOL_NAME (sym), -1));
+ break;
+ }
+ }
+ if (BLOCK_FUNCTION (block))
+ break;
+ else
+ block = BLOCK_SUPERBLOCK (block);
+ }
+
+ return TCL_OK;
+}
+
/* This implements the tcl command "gdb_get_line"
-* It returns the linenumber for a given linespec. It will take any spec
-* that can be passed to decode_line_1
-*
-* Tcl Arguments:
-* linespec - the line specification
-* Tcl Result:
-* The line number for that spec.
-*/
+ * It returns the linenumber for a given linespec. It will take any spec
+ * that can be passed to decode_line_1
+ *
+ * Tcl Arguments:
+ * linespec - the line specification
+ * Tcl Result:
+ * The line number for that spec.
+ */
static int
-gdb_get_line_command (ClientData clientData, Tcl_Interp *interp,
- int objc, Tcl_Obj *CONST objv[])
+gdb_get_line_command (clientData, interp, objc, objv)
+ ClientData clientData;
+ Tcl_Interp *interp;
+ int objc;
+ Tcl_Obj *CONST objv[];
{
struct symtabs_and_lines sals;
char *args, **canonical;
if (objc != 2)
{
- Tcl_WrongNumArgs (interp, 1, objv, "linespec");
+ Tcl_AppendStringsToObj (result_ptr->obj_ptr,
+ "wrong # of args: should be \"",
+ Tcl_GetStringFromObj (objv[0], NULL),
+ " linespec\"", NULL);
return TCL_ERROR;
}
args = Tcl_GetStringFromObj (objv[1], NULL);
- sals = decode_line_1 (&args, 1, NULL, 0, &canonical, NULL);
+ sals = decode_line_1 (&args, 1, NULL, 0, &canonical);
if (sals.nelts == 1)
{
Tcl_SetIntObj (result_ptr->obj_ptr, sals.sals[0].line);
@@ -961,29 +1216,35 @@ gdb_get_line_command (ClientData clientData, Tcl_Interp *interp,
/* This implements the tcl command "gdb_get_file"
-* It returns the file containing a given line spec.
-*
-* Tcl Arguments:
-* linespec - The linespec to look up
-* Tcl Result:
-* The file containing it.
-*/
+ * It returns the file containing a given line spec.
+ *
+ * Tcl Arguments:
+ * linespec - The linespec to look up
+ * Tcl Result:
+ * The file containing it.
+ */
static int
-gdb_get_file_command (ClientData clientData, Tcl_Interp *interp,
- int objc, Tcl_Obj *CONST objv[])
+gdb_get_file_command (clientData, interp, objc, objv)
+ ClientData clientData;
+ Tcl_Interp *interp;
+ int objc;
+ Tcl_Obj *CONST objv[];
{
struct symtabs_and_lines sals;
char *args, **canonical;
if (objc != 2)
{
- Tcl_WrongNumArgs (interp, 1, objv, "linespec");
+ Tcl_AppendStringsToObj (result_ptr->obj_ptr,
+ "wrong # of args: should be \"",
+ Tcl_GetStringFromObj (objv[0], NULL),
+ " linespec\"", NULL);
return TCL_ERROR;
}
args = Tcl_GetStringFromObj (objv[1], NULL);
- sals = decode_line_1 (&args, 1, NULL, 0, &canonical, NULL);
+ sals = decode_line_1 (&args, 1, NULL, 0, &canonical);
if (sals.nelts == 1)
{
Tcl_SetStringObj (result_ptr->obj_ptr,
@@ -997,16 +1258,19 @@ gdb_get_file_command (ClientData clientData, Tcl_Interp *interp,
/* This implements the tcl command "gdb_get_function"
-* It finds the function containing the given line spec.
-*
-* Tcl Arguments:
-* linespec - The line specification
-* Tcl Result:
-* The function that contains it, or "N/A" if it is not in a function.
-*/
+ * It finds the function containing the given line spec.
+ *
+ * Tcl Arguments:
+ * linespec - The line specification
+ * Tcl Result:
+ * The function that contains it, or "N/A" if it is not in a function.
+ */
static int
-gdb_get_function_command (ClientData clientData, Tcl_Interp *interp,
- int objc, Tcl_Obj *CONST objv[])
+gdb_get_function_command (clientData, interp, objc, objv)
+ ClientData clientData;
+ Tcl_Interp *interp;
+ int objc;
+ Tcl_Obj *CONST objv[];
{
char *function;
struct symtabs_and_lines sals;
@@ -1014,12 +1278,15 @@ gdb_get_function_command (ClientData clientData, Tcl_Interp *interp,
if (objc != 2)
{
- Tcl_WrongNumArgs (interp, 1, objv, "linespec");
+ Tcl_AppendStringsToObj (result_ptr->obj_ptr,
+ "wrong # of args: should be \"",
+ Tcl_GetStringFromObj (objv[0], NULL),
+ " linespec\"", NULL);
return TCL_ERROR;
}
args = Tcl_GetStringFromObj (objv[1], NULL);
- sals = decode_line_1 (&args, 1, NULL, 0, &canonical, NULL);
+ sals = decode_line_1 (&args, 1, NULL, 0, &canonical);
if (sals.nelts == 1)
{
resolve_sal_pc (&sals.sals[0]);
@@ -1034,21 +1301,24 @@ gdb_get_function_command (ClientData clientData, Tcl_Interp *interp,
/* This implements the tcl command "gdb_find_file"
-* It searches the symbol tables to get the full pathname to a file.
-*
-* Tcl Arguments:
-* filename: the file name to search for.
-* Tcl Result:
-* The full path to the file, an empty string if the file was not
-* available or an error message if the file is not found in the symtab.
-*/
+ * It searches the symbol tables to get the full pathname to a file.
+ *
+ * Tcl Arguments:
+ * filename: the file name to search for.
+ * Tcl Result:
+ * The full path to the file, or an empty string if the file is not
+ * found.
+ */
static int
-gdb_find_file_command (ClientData clientData, Tcl_Interp *interp,
- int objc, Tcl_Obj *CONST objv[])
+gdb_find_file_command (clientData, interp, objc, objv)
+ ClientData clientData;
+ Tcl_Interp *interp;
+ int objc;
+ Tcl_Obj *CONST objv[];
{
+ char *filename = NULL;
struct symtab *st;
- char *filename, *fullname = NULL;
if (objc != 2)
{
@@ -1056,128 +1326,95 @@ gdb_find_file_command (ClientData clientData, Tcl_Interp *interp,
return TCL_ERROR;
}
- filename = Tcl_GetStringFromObj (objv[1], NULL);
-
- /* Shortcut: There seems to be some mess in gdb dealing with
- files. While we should let gdb sort it out, it doesn't hurt
- to be a little defensive here.
-
- If the filename is already an absolute filename, just try
- to stat it. If it's not found, then ask gdb to find it for us. */
- if (IS_ABSOLUTE_PATH (filename))
- {
- struct stat st;
- const int status = stat (filename, &st);
+ st = full_lookup_symtab (Tcl_GetStringFromObj (objv[1], NULL));
+ if (st)
+ filename = st->fullname;
- if (status == 0)
- {
- if (S_ISREG (st.st_mode))
- fullname = filename;
- }
- }
+ if (filename == NULL)
+ Tcl_SetStringObj (result_ptr->obj_ptr, "", 0);
else
- {
- /* Ask gdb to find the file for us. */
- st = lookup_symtab (filename);
-
- /* We should always get a symtab. */
- if (!st)
- {
- gdbtk_set_result (interp, "File not found in symtab (2)");
- return TCL_ERROR;
- }
-
- fullname =
- (st->fullname == NULL ? symtab_to_filename (st) : st->fullname);
- }
-
- /* We may not be able to open the file (not available). */
- if (fullname == NULL)
- {
- Tcl_SetStringObj (result_ptr->obj_ptr, "", -1);
- return TCL_OK;
- }
-
- Tcl_SetStringObj (result_ptr->obj_ptr, fullname, -1);
+ Tcl_SetStringObj (result_ptr->obj_ptr, filename, -1);
return TCL_OK;
}
/* This implements the tcl command "gdb_listfiles"
-* This lists all the files in the current executible.
-*
-* Note that this currently pulls in all sorts of filenames
-* that aren't really part of the executable. It would be
-* best if we could check each file to see if it actually
-* contains executable lines of code, but we can't do that
-* with psymtabs.
-*
-* Arguments:
-* ?pathname? - If provided, only files which match pathname
-* (up to strlen(pathname)) are included. THIS DOES NOT
-* CURRENTLY WORK BECAUSE PARTIAL_SYMTABS DON'T SUPPLY
-* THE FULL PATHNAME!!!
-*
-* Tcl Result:
-* A list of all matching files.
-*/
+ * This lists all the files in the current executible.
+ *
+ * Note that this currently pulls in all sorts of filenames
+ * that aren't really part of the executable. It would be
+ * best if we could check each file to see if it actually
+ * contains executable lines of code, but we can't do that
+ * with psymtabs.
+ *
+ * Arguments:
+ * ?pathname? - If provided, only files which match pathname
+ * (up to strlen(pathname)) are included. THIS DOES NOT
+ * CURRENTLY WORK BECAUSE PARTIAL_SYMTABS DON'T SUPPLY
+ * THE FULL PATHNAME!!!
+ *
+ * Tcl Result:
+ * A list of all matching files.
+ */
static int
-gdb_listfiles (ClientData clientData, Tcl_Interp *interp,
- int objc, Tcl_Obj *CONST objv[])
+gdb_listfiles (clientData, interp, objc, objv)
+ ClientData clientData;
+ Tcl_Interp *interp;
+ int objc;
+ Tcl_Obj *CONST objv[];
{
struct objfile *objfile;
struct partial_symtab *psymtab;
struct symtab *symtab;
- const char *lastfile, *pathname = NULL;
- const char **files;
+ char *lastfile, *pathname = NULL, **files;
int files_size;
int i, numfiles = 0, len = 0;
files_size = 1000;
- files = (const char **) xmalloc (sizeof (char *) * files_size);
+ files = (char **) xmalloc (sizeof (char *) * files_size);
if (objc > 2)
{
- Tcl_WrongNumArgs (interp, 1, objv, "?pathname?");
+ Tcl_WrongNumArgs (interp, 1, objv, "Usage: gdb_listfiles ?pathname?");
return TCL_ERROR;
}
else if (objc == 2)
pathname = Tcl_GetStringFromObj (objv[1], &len);
ALL_PSYMTABS (objfile, psymtab)
- {
- if (numfiles == files_size)
- {
- files_size = files_size * 2;
- files = (const char **) xrealloc (files, sizeof (char *) * files_size);
- }
- if (psymtab->filename)
- {
- if (!len || !strncmp (pathname, psymtab->filename, len)
- || !strcmp (psymtab->filename, lbasename (psymtab->filename)))
- {
- files[numfiles++] = lbasename (psymtab->filename);
- }
- }
- }
+ {
+ if (numfiles == files_size)
+ {
+ files_size = files_size * 2;
+ files = (char **) xrealloc (files, sizeof (char *) * files_size);
+ }
+ if (psymtab->filename)
+ {
+ if (!len || !strncmp (pathname, psymtab->filename, len)
+ || !strcmp (psymtab->filename, basename (psymtab->filename)))
+ {
+ files[numfiles++] = basename (psymtab->filename);
+ }
+ }
+ }
ALL_SYMTABS (objfile, symtab)
- {
- if (numfiles == files_size)
- {
- files_size = files_size * 2;
- files = (const char **) xrealloc (files, sizeof (char *) * files_size);
- }
- if (symtab->filename && symtab->linetable && symtab->linetable->nitems)
- {
- if (!len || !strncmp (pathname, symtab->filename, len)
- || !strcmp (symtab->filename, lbasename (symtab->filename)))
- {
- files[numfiles++] = lbasename (symtab->filename);
- }
- }
- }
+ {
+ if (numfiles == files_size)
+ {
+ files_size = files_size * 2;
+ files = (char **) xrealloc (files, sizeof (char *) * files_size);
+ }
+ if (symtab->filename && symtab->linetable && symtab->linetable->nitems)
+ {
+ if (!len || !strncmp (pathname, symtab->filename, len)
+ || !strcmp (symtab->filename, basename (symtab->filename)))
+ {
+ files[numfiles++] = basename (symtab->filename);
+ }
+ }
+ }
qsort (files, numfiles, sizeof (char *), comp_files);
@@ -1201,7 +1438,8 @@ gdb_listfiles (ClientData clientData, Tcl_Interp *interp,
}
static int
-comp_files (const void *file1, const void *file2)
+comp_files (file1, file2)
+ const void *file1, *file2;
{
return strcmp (*(char **) file1, *(char **) file2);
}
@@ -1210,37 +1448,40 @@ comp_files (const void *file1, const void *file2)
/* This implements the tcl command "gdb_search"
-* Tcl Arguments:
-* option - One of "functions", "variables" or "types"
-* regexp - The regular expression to look for.
-* Then, optionally:
-* -files fileList
-* -static 1/0
-* -filename 1/0
-* Tcl Result:
-* A list of all the matches found. Optionally, if -filename is set to 1,
-* then the output is a list of two element lists, with the symbol first,
-* and the file in which it is found second.
-*/
+ * Tcl Arguments:
+ * option - One of "functions", "variables" or "types"
+ * regexp - The regular expression to look for.
+ * Then, optionally:
+ * -files fileList
+ * -static 1/0
+ * -filename 1/0
+ * Tcl Result:
+ * A list of all the matches found. Optionally, if -filename is set to 1,
+ * then the output is a list of two element lists, with the symbol first,
+ * and the file in which it is found second.
+ */
static int
-gdb_search (ClientData clientData, Tcl_Interp *interp,
- int objc, Tcl_Obj *CONST objv[])
+gdb_search (clientData, interp, objc, objv)
+ ClientData clientData;
+ Tcl_Interp *interp;
+ int objc;
+ Tcl_Obj *CONST objv[];
{
struct symbol_search *ss = NULL;
struct symbol_search *p;
struct cleanup *old_chain = NULL;
Tcl_Obj *CONST * switch_objv;
int index, switch_objc, i, show_files = 0;
- domain_enum space = 0;
+ namespace_enum space = 0;
char *regexp;
int static_only, nfiles;
Tcl_Obj **file_list;
char **files;
- static const char *search_options[] =
- {"functions", "variables", "types", (char *) NULL};
- static const char *switches[] =
- {"-files", "-filename", "-static", (char *) NULL};
+ static char *search_options[] =
+ {"functions", "variables", "types", (char *) NULL};
+ static char *switches[] =
+ {"-files", "-filename", "-static", (char *) NULL};
enum search_opts
{
SEARCH_FUNCTIONS, SEARCH_VARIABLES, SEARCH_TYPES
@@ -1253,6 +1494,7 @@ gdb_search (ClientData clientData, Tcl_Interp *interp,
if (objc < 3)
{
Tcl_WrongNumArgs (interp, 1, objv, "option regexp ?arg ...?");
+ result_ptr->flags |= GDBTK_IN_TCL_RESULT;
return TCL_ERROR;
}
@@ -1269,13 +1511,13 @@ gdb_search (ClientData clientData, Tcl_Interp *interp,
switch ((enum search_opts) index)
{
case SEARCH_FUNCTIONS:
- space = FUNCTIONS_DOMAIN;
+ space = FUNCTIONS_NAMESPACE;
break;
case SEARCH_VARIABLES:
- space = VARIABLES_DOMAIN;
+ space = VARIABLES_NAMESPACE;
break;
case SEARCH_TYPES:
- space = TYPES_DOMAIN;
+ space = TYPES_NAMESPACE;
break;
}
@@ -1362,7 +1604,7 @@ gdb_search (ClientData clientData, Tcl_Interp *interp,
search_symbols (regexp, space, nfiles, files, &ss);
if (ss != NULL)
- old_chain = make_cleanup_free_search_symbols (ss);
+ old_chain = make_cleanup ((make_cleanup_func) free_search_symbols, ss);
Tcl_SetListObj (result_ptr->obj_ptr, 0, NULL);
@@ -1375,19 +1617,18 @@ gdb_search (ClientData clientData, Tcl_Interp *interp,
/* Strip off some C++ special symbols, like RTTI and global
constructors/destructors. */
- if ((p->symbol != NULL
- && strncmp (SYMBOL_LINKAGE_NAME (p->symbol), "__tf", 4) != 0
- && strncmp (SYMBOL_LINKAGE_NAME (p->symbol), "_GLOBAL_", 8) != 0)
+ if ((p->symbol != NULL && !STREQN (SYMBOL_NAME (p->symbol), "__tf", 4)
+ && !STREQN (SYMBOL_NAME (p->symbol), "_GLOBAL_", 8))
|| p->msymbol != NULL)
{
elem = Tcl_NewListObj (0, NULL);
if (p->msymbol == NULL)
Tcl_ListObjAppendElement (interp, elem,
- Tcl_NewStringObj (SYMBOL_PRINT_NAME (p->symbol), -1));
+ Tcl_NewStringObj (SYMBOL_SOURCE_NAME (p->symbol), -1));
else
Tcl_ListObjAppendElement (interp, elem,
- Tcl_NewStringObj (SYMBOL_PRINT_NAME (p->msymbol), -1));
+ Tcl_NewStringObj (SYMBOL_SOURCE_NAME (p->msymbol), -1));
if (show_files)
{
@@ -1415,15 +1656,15 @@ gdb_search (ClientData clientData, Tcl_Interp *interp,
/* This implements the tcl command gdb_listfuncs
-* It lists all the functions defined in a given file
-*
-* Arguments:
-* file - the file to look in
-* Tcl Result:
-* A list of two element lists, the first element is
-* the symbol name, and the second is a boolean indicating
-* whether the symbol is demangled (1 for yes).
-*/
+ * It lists all the functions defined in a given file
+ *
+ * Arguments:
+ * file - the file to look in
+ * Tcl Result:
+ * A list of two element lists, the first element is
+ * the symbol name, and the second is a boolean indicating
+ * whether the symbol is demangled (1 for yes).
+ */
static int
gdb_listfuncs (clientData, interp, objc, objv)
@@ -1436,24 +1677,21 @@ gdb_listfuncs (clientData, interp, objc, objv)
struct blockvector *bv;
struct block *b;
struct symbol *sym;
- int i;
- struct dict_iterator iter;
+ int i, j;
Tcl_Obj *funcVals[2];
if (objc != 2)
{
- Tcl_WrongNumArgs (interp, 1, objv, "file");
- return TCL_ERROR;
+ Tcl_SetStringObj (result_ptr->obj_ptr, "wrong # args", -1);
}
- symtab = lookup_symtab (Tcl_GetStringFromObj (objv[1], NULL));
+ symtab = full_lookup_symtab (Tcl_GetStringFromObj (objv[1], NULL));
if (!symtab)
{
- gdbtk_set_result (interp, "No such file (%s)",
- Tcl_GetStringFromObj (objv[1], NULL));
+ Tcl_SetStringObj (result_ptr->obj_ptr, "No such file", -1);
return TCL_ERROR;
}
-
+
if (mangled == NULL)
{
mangled = Tcl_NewBooleanObj (1);
@@ -1468,8 +1706,12 @@ gdb_listfuncs (clientData, interp, objc, objv)
for (i = GLOBAL_BLOCK; i <= STATIC_BLOCK; i++)
{
b = BLOCKVECTOR_BLOCK (bv, i);
- ALL_BLOCK_SYMBOLS (b, iter, sym)
+ /* Skip the sort if this block is always sorted. */
+ if (!BLOCK_SHOULD_SORT (b))
+ sort_block_syms (b);
+ for (j = 0; j < BLOCK_NSYMS (b); j++)
{
+ sym = BLOCK_SYM (b, j);
if (SYMBOL_CLASS (sym) == LOC_BLOCK)
{
@@ -1496,7 +1738,7 @@ gdb_listfuncs (clientData, interp, objc, objv)
}
else
{
- funcVals[0] = Tcl_NewStringObj (DEPRECATED_SYMBOL_NAME (sym), -1);
+ funcVals[0] = Tcl_NewStringObj (SYMBOL_NAME (sym), -1);
funcVals[1] = not_mangled;
}
Tcl_ListObjAppendElement (NULL, result_ptr->obj_ptr,
@@ -1507,30 +1749,632 @@ gdb_listfuncs (clientData, interp, objc, objv)
return TCL_OK;
}
+
+/*
+ * This section contains all the commands that act on the registers:
+ */
+
+/* This is a sort of mapcar function for operations on registers */
+
+static int
+map_arg_registers (objc, objv, func, argp)
+ int objc;
+ Tcl_Obj *CONST objv[];
+ void (*func) PARAMS ((int regnum, void *argp));
+ void *argp;
+{
+ int regnum, numregs;
+
+ /* Note that the test for a valid register must include checking the
+ REGISTER_NAME because NUM_REGS may be allocated for the union of
+ the register sets within a family of related processors. In this
+ case, some entries of REGISTER_NAME will change depending upon
+ the particular processor being debugged. */
+
+ numregs = ARCH_NUM_REGS;
+
+ if (objc == 0) /* No args, just do all the regs */
+ {
+ for (regnum = 0;
+ regnum < numregs;
+ regnum++)
+ {
+ if (REGISTER_NAME (regnum) == NULL
+ || *(REGISTER_NAME (regnum)) == '\0')
+ continue;
+
+ func (regnum, argp);
+ }
+
+ return TCL_OK;
+ }
+
+ /* Else, list of register #s, just do listed regs */
+ for (; objc > 0; objc--, objv++)
+ {
+ if (Tcl_GetIntFromObj (NULL, *objv, &regnum) != TCL_OK)
+ {
+ result_ptr->flags |= GDBTK_IN_TCL_RESULT;
+ return TCL_ERROR;
+ }
+
+ if (regnum >= 0
+ && regnum < numregs
+ && REGISTER_NAME (regnum) != NULL
+ && *REGISTER_NAME (regnum) != '\000')
+ func (regnum, argp);
+ else
+ {
+ Tcl_SetStringObj (result_ptr->obj_ptr, "bad register number", -1);
+ return TCL_ERROR;
+ }
+ }
+
+ return TCL_OK;
+}
+
/* This implements the TCL command `gdb_restore_fputs'
It sets the fputs_unfiltered hook back to gdbtk_fputs.
Its sole reason for being is that sometimes we move the
fputs hook out of the way to specially trap output, and if
we get an error which we weren't expecting, it won't get put
back, so we run this at idle time as insurance.
-*/
+ */
+
+static int
+gdb_restore_fputs (clientData, interp, objc, objv)
+ ClientData clientData;
+ Tcl_Interp *interp;
+ int objc;
+ Tcl_Obj *CONST objv[];
+{
+ fputs_unfiltered_hook = gdbtk_fputs;
+ return TCL_OK;
+}
+
+/* This implements the TCL command `gdb_regnames', which returns a list of
+ all of the register names. */
+
+static int
+gdb_regnames (clientData, interp, objc, objv)
+ ClientData clientData;
+ Tcl_Interp *interp;
+ int objc;
+ Tcl_Obj *CONST objv[];
+{
+ objc--;
+ objv++;
+
+ return map_arg_registers (objc, objv, get_register_name, NULL);
+}
+
+static void
+get_register_name (regnum, argp)
+ int regnum;
+ void *argp; /* Ignored */
+{
+ Tcl_ListObjAppendElement (NULL, result_ptr->obj_ptr,
+ Tcl_NewStringObj (REGISTER_NAME (regnum), -1));
+}
+
+/* This implements the tcl command gdb_fetch_registers
+ * Pass it a list of register names, and it will
+ * return their values as a list.
+ *
+ * Tcl Arguments:
+ * format: The format string for printing the values
+ * args: the registers to look for
+ * Tcl Result:
+ * A list of their values.
+ */
+
+static int
+gdb_fetch_registers (clientData, interp, objc, objv)
+ ClientData clientData;
+ Tcl_Interp *interp;
+ int objc;
+ Tcl_Obj *CONST objv[];
+{
+ int format, result;
+
+ if (objc < 2)
+ {
+ Tcl_SetStringObj (result_ptr->obj_ptr,
+ "wrong # args, should be gdb_fetch_registers format ?register1 register2 ...?", -1);
+ }
+ objc -= 2;
+ objv++;
+ format = *(Tcl_GetStringFromObj (objv[0], NULL));
+ objv++;
+
+
+ result_ptr->flags |= GDBTK_MAKES_LIST; /* Output the results as a list */
+ result = map_arg_registers (objc, objv, get_register, (void *) format);
+ result_ptr->flags &= ~GDBTK_MAKES_LIST;
+
+ return result;
+}
+
+static void
+get_register (regnum, fp)
+ int regnum;
+ void *fp;
+{
+ char raw_buffer[MAX_REGISTER_RAW_SIZE];
+ char virtual_buffer[MAX_REGISTER_VIRTUAL_SIZE];
+ int format = (int) fp;
+ int optim;
+
+ if (format == 'N')
+ format = 0;
+
+ /* read_relative_register_raw_bytes returns a virtual frame pointer
+ (FRAME_FP (selected_frame)) if regnum == FP_REGNUM instead
+ of the real contents of the register. To get around this,
+ use get_saved_register instead. */
+ get_saved_register (raw_buffer, &optim, (CORE_ADDR *) NULL, selected_frame,
+ regnum, (enum lval_type *) NULL);
+ if (optim)
+ {
+ Tcl_ListObjAppendElement (NULL, result_ptr->obj_ptr,
+ Tcl_NewStringObj ("Optimized out", -1));
+ return;
+ }
+
+ /* Convert raw data to virtual format if necessary. */
+
+ if (REGISTER_CONVERTIBLE (regnum))
+ {
+ REGISTER_CONVERT_TO_VIRTUAL (regnum, REGISTER_VIRTUAL_TYPE (regnum),
+ raw_buffer, virtual_buffer);
+ }
+ else
+ memcpy (virtual_buffer, raw_buffer, REGISTER_VIRTUAL_SIZE (regnum));
+
+ if (format == 'r')
+ {
+ int j;
+ char *ptr, buf[1024];
+
+ strcpy (buf, "0x");
+ ptr = buf + 2;
+ for (j = 0; j < REGISTER_RAW_SIZE (regnum); j++)
+ {
+ register int idx = TARGET_BYTE_ORDER == BIG_ENDIAN ? j
+ : REGISTER_RAW_SIZE (regnum) - 1 - j;
+ sprintf (ptr, "%02x", (unsigned char) raw_buffer[idx]);
+ ptr += 2;
+ }
+ fputs_filtered (buf, gdb_stdout);
+ }
+ else
+ val_print (REGISTER_VIRTUAL_TYPE (regnum), virtual_buffer, 0, 0,
+ gdb_stdout, format, 1, 0, Val_pretty_default);
+
+}
+
+/* This implements the tcl command get_pc_reg
+ * It returns the value of the PC register
+ *
+ * Tcl Arguments:
+ * None
+ * Tcl Result:
+ * The value of the pc register.
+ */
static int
-gdb_restore_fputs (ClientData clientData, Tcl_Interp *interp,
- int objc, Tcl_Obj *CONST objv[])
+get_pc_register (clientData, interp, objc, objv)
+ ClientData clientData;
+ Tcl_Interp *interp;
+ int objc;
+ Tcl_Obj *CONST objv[];
{
- gdbtk_disable_fputs = 0;
+ char buff[64];
+
+ sprintf (buff, "0x%llx", (long long) read_register (PC_REGNUM));
+ Tcl_SetStringObj (result_ptr->obj_ptr, buff, -1);
return TCL_OK;
}
+
+/* This implements the tcl command "gdb_changed_register_list"
+ * It takes a list of registers, and returns a list of
+ * the registers on that list that have changed since the last
+ * time the proc was called.
+ *
+ * Tcl Arguments:
+ * A list of registers.
+ * Tcl Result:
+ * A list of changed registers.
+ */
+
+static int
+gdb_changed_register_list (clientData, interp, objc, objv)
+ ClientData clientData;
+ Tcl_Interp *interp;
+ int objc;
+ Tcl_Obj *CONST objv[];
+{
+ objc--;
+ objv++;
+
+ return map_arg_registers (objc, objv, register_changed_p, NULL);
+}
+
+static void
+register_changed_p (regnum, argp)
+ int regnum;
+ void *argp; /* Ignored */
+{
+ char raw_buffer[MAX_REGISTER_RAW_SIZE];
+
+ if (read_relative_register_raw_bytes (regnum, raw_buffer))
+ return;
+
+ if (memcmp (&old_regs[REGISTER_BYTE (regnum)], raw_buffer,
+ REGISTER_RAW_SIZE (regnum)) == 0)
+ return;
+
+ /* Found a changed register. Save new value and return its number. */
+
+ memcpy (&old_regs[REGISTER_BYTE (regnum)], raw_buffer,
+ REGISTER_RAW_SIZE (regnum));
+
+ Tcl_ListObjAppendElement (NULL, result_ptr->obj_ptr, Tcl_NewIntObj (regnum));
+}
+/*
+ * This section contains the commands that deal with tracepoints:
+ */
+
+/* return a list of all tracepoint numbers in interpreter */
+static int
+gdb_get_tracepoint_list (clientData, interp, objc, objv)
+ ClientData clientData;
+ Tcl_Interp *interp;
+ int objc;
+ Tcl_Obj *CONST objv[];
+{
+ struct tracepoint *tp;
+
+ Tcl_SetListObj (result_ptr->obj_ptr, 0, NULL);
+
+ ALL_TRACEPOINTS (tp)
+ Tcl_ListObjAppendElement (interp, result_ptr->obj_ptr,
+ Tcl_NewIntObj (tp->number));
+
+ return TCL_OK;
+}
+
+/* returns -1 if not found, tracepoint # if found */
+static int
+tracepoint_exists (char *args)
+{
+ struct tracepoint *tp;
+ char **canonical;
+ struct symtabs_and_lines sals;
+ char *file = NULL;
+ int result = -1;
+
+ sals = decode_line_1 (&args, 1, NULL, 0, &canonical);
+ if (sals.nelts == 1)
+ {
+ resolve_sal_pc (&sals.sals[0]);
+ file = xmalloc (strlen (sals.sals[0].symtab->dirname)
+ + strlen (sals.sals[0].symtab->filename) + 1);
+ if (file != NULL)
+ {
+ strcpy (file, sals.sals[0].symtab->dirname);
+ strcat (file, sals.sals[0].symtab->filename);
+
+ ALL_TRACEPOINTS (tp)
+ {
+ if (tp->address == sals.sals[0].pc)
+ result = tp->number;
+#if 0
+ /* Why is this here? This messes up assembly traces */
+ else if (tp->source_file != NULL
+ && strcmp (tp->source_file, file) == 0
+ && sals.sals[0].line == tp->line_number)
+ result = tp->number;
+#endif
+ }
+ }
+ }
+ if (file != NULL)
+ free (file);
+ return result;
+}
+
+static int
+gdb_tracepoint_exists_command (clientData, interp, objc, objv)
+ ClientData clientData;
+ Tcl_Interp *interp;
+ int objc;
+ Tcl_Obj *CONST objv[];
+{
+ char *args;
+
+ if (objc != 2)
+ {
+ Tcl_AppendStringsToObj (result_ptr->obj_ptr,
+ "wrong # of args: should be \"",
+ Tcl_GetStringFromObj (objv[0], NULL),
+ " function:line|function|line|*addr\"", NULL);
+ return TCL_ERROR;
+ }
+
+ args = Tcl_GetStringFromObj (objv[1], NULL);
+
+ Tcl_SetIntObj (result_ptr->obj_ptr, tracepoint_exists (args));
+ return TCL_OK;
+}
+
+static int
+gdb_get_tracepoint_info (clientData, interp, objc, objv)
+ ClientData clientData;
+ Tcl_Interp *interp;
+ int objc;
+ Tcl_Obj *CONST objv[];
+{
+ struct symtab_and_line sal;
+ int tpnum;
+ struct tracepoint *tp;
+ struct action_line *al;
+ Tcl_Obj *action_list;
+ char *filename, *funcname, *fname;
+
+ if (objc != 2)
+ {
+ Tcl_SetStringObj (result_ptr->obj_ptr, "wrong # args", -1);
+ return TCL_ERROR;
+ }
+
+ if (Tcl_GetIntFromObj (NULL, objv[1], &tpnum) != TCL_OK)
+ {
+ result_ptr->flags |= GDBTK_IN_TCL_RESULT;
+ return TCL_ERROR;
+ }
+
+ ALL_TRACEPOINTS (tp)
+ if (tp->number == tpnum)
+ break;
+
+ if (tp == NULL)
+ {
+ char buff[64];
+ sprintf (buff, "Tracepoint #%d does not exist", tpnum);
+ Tcl_SetStringObj (result_ptr->obj_ptr, buff, -1);
+ return TCL_ERROR;
+ }
+
+ Tcl_SetListObj (result_ptr->obj_ptr, 0, NULL);
+ sal = find_pc_line (tp->address, 0);
+ filename = symtab_to_filename (sal.symtab);
+ if (filename == NULL)
+ filename = "N/A";
+ Tcl_ListObjAppendElement (interp, result_ptr->obj_ptr,
+ Tcl_NewStringObj (filename, -1));
+
+ funcname = pc_function_name (tp->address);
+ Tcl_ListObjAppendElement (interp, result_ptr->obj_ptr, Tcl_NewStringObj
+ (funcname, -1));
+
+ Tcl_ListObjAppendElement (interp, result_ptr->obj_ptr,
+ Tcl_NewIntObj (sal.line));
+ {
+ char *tmp;
+ asprintf (&tmp, "0x%s", paddr_nz (tp->address));
+ Tcl_ListObjAppendElement (interp, result_ptr->obj_ptr,
+ Tcl_NewStringObj (tmp, -1));
+ free (tmp);
+ }
+ Tcl_ListObjAppendElement (interp, result_ptr->obj_ptr,
+ Tcl_NewIntObj (tp->enabled));
+ Tcl_ListObjAppendElement (interp, result_ptr->obj_ptr,
+ Tcl_NewIntObj (tp->pass_count));
+ Tcl_ListObjAppendElement (interp, result_ptr->obj_ptr,
+ Tcl_NewIntObj (tp->step_count));
+ Tcl_ListObjAppendElement (interp, result_ptr->obj_ptr,
+ Tcl_NewIntObj (tp->thread));
+ Tcl_ListObjAppendElement (interp, result_ptr->obj_ptr,
+ Tcl_NewIntObj (tp->hit_count));
+
+ /* Append a list of actions */
+ action_list = Tcl_NewObj ();
+ for (al = tp->actions; al != NULL; al = al->next)
+ {
+ Tcl_ListObjAppendElement (interp, action_list,
+ Tcl_NewStringObj (al->action, -1));
+ }
+ Tcl_ListObjAppendElement (interp, result_ptr->obj_ptr, action_list);
+
+ return TCL_OK;
+}
+
+
+static int
+gdb_trace_status (clientData, interp, objc, objv)
+ ClientData clientData;
+ Tcl_Interp *interp;
+ int objc;
+ Tcl_Obj *CONST objv[];
+{
+ int result = 0;
+
+ if (trace_running_p)
+ result = 1;
+
+ Tcl_SetIntObj (result_ptr->obj_ptr, result);
+ return TCL_OK;
+}
+
+
+
+static int
+gdb_get_trace_frame_num (clientData, interp, objc, objv)
+ ClientData clientData;
+ Tcl_Interp *interp;
+ int objc;
+ Tcl_Obj *CONST objv[];
+{
+ if (objc != 1)
+ {
+ Tcl_AppendStringsToObj (result_ptr->obj_ptr,
+ "wrong # of args: should be \"",
+ Tcl_GetStringFromObj (objv[0], NULL),
+ " linespec\"", NULL);
+ return TCL_ERROR;
+ }
+
+ Tcl_SetIntObj (result_ptr->obj_ptr, get_traceframe_number ());
+ return TCL_OK;
+
+}
+
+/* This implements the tcl command gdb_actions
+ * It sets actions for a given tracepoint.
+ *
+ * Tcl Arguments:
+ * number: the tracepoint in question
+ * actions: the actions to add to this tracepoint
+ * Tcl Result:
+ * None.
+ */
+
+static int
+gdb_actions_command (clientData, interp, objc, objv)
+ ClientData clientData;
+ Tcl_Interp *interp;
+ int objc;
+ Tcl_Obj *CONST objv[];
+{
+ struct tracepoint *tp;
+ Tcl_Obj **actions;
+ int nactions, i, len;
+ char *number, *args, *action;
+ long step_count;
+ struct action_line *next = NULL, *temp;
+ enum actionline_type linetype;
+
+ if (objc != 3)
+ {
+ Tcl_AppendStringsToObj (result_ptr->obj_ptr,
+ "wrong # args: should be: \"",
+ Tcl_GetStringFromObj (objv[0], NULL),
+ " number actions\"", NULL);
+ return TCL_ERROR;
+ }
+
+ args = number = Tcl_GetStringFromObj (objv[1], NULL);
+ tp = get_tracepoint_by_number (&args, 0, 0);
+ if (tp == NULL)
+ {
+ Tcl_AppendStringsToObj (result_ptr->obj_ptr, "Tracepoint \"",
+ number, "\" does not exist", NULL);
+ return TCL_ERROR;
+ }
+
+ /* Free any existing actions */
+ if (tp->actions != NULL)
+ free_actions (tp);
+
+ step_count = 0;
+
+ Tcl_ListObjGetElements (interp, objv[2], &nactions, &actions);
+
+ /* Add the actions to the tracepoint */
+ for (i = 0; i < nactions; i++)
+ {
+ temp = xmalloc (sizeof (struct action_line));
+ temp->next = NULL;
+ action = Tcl_GetStringFromObj (actions[i], &len);
+ temp->action = savestring (action, len);
+
+ linetype = validate_actionline (&(temp->action), tp);
+
+ if (linetype == BADLINE)
+ {
+ free (temp);
+ continue;
+ }
+
+ if (next == NULL)
+ {
+ tp->actions = temp;
+ next = temp;
+ }
+ else
+ {
+ next->next = temp;
+ next = temp;
+ }
+ }
+
+ return TCL_OK;
+}
+
+/*
+ * This section has commands that handle source disassembly.
+ */
+/* This implements the tcl command gdb_disassemble. It is no longer
+ * used in GDBTk, we use gdb_load_disassembly, but I kept it around in
+ * case other folks want it.
+ *
+ * Arguments:
+ * source_with_assm - must be "source" or "nosource"
+ * low_address - the address from which to start disassembly
+ * ?hi_address? - the address to which to disassemble, defaults
+ * to the end of the function containing low_address.
+ * Tcl Result:
+ * The disassembled code is passed to fputs_unfiltered, so it
+ * either goes to the console if result_ptr->obj_ptr is NULL or to
+ * the Tcl result.
+ */
+
+static int
+gdb_disassemble (clientData, interp, objc, objv)
+ ClientData clientData;
+ Tcl_Interp *interp;
+ int objc;
+ Tcl_Obj *CONST objv[];
+{
+ CORE_ADDR low, high;
+ char *arg_ptr;
+ int mixed_source_and_assembly;
+
+ if (objc != 3 && objc != 4)
+ error ("wrong # args");
+
+ arg_ptr = Tcl_GetStringFromObj (objv[1], NULL);
+ if (*arg_ptr == 's' && strcmp (arg_ptr, "source") == 0)
+ mixed_source_and_assembly = 1;
+ else if (*arg_ptr == 'n' && strcmp (arg_ptr, "nosource") == 0)
+ mixed_source_and_assembly = 0;
+ else
+ error ("First arg must be 'source' or 'nosource'");
+
+ low = parse_and_eval_address (Tcl_GetStringFromObj (objv[2], NULL));
+
+ if (objc == 3)
+ {
+ if (find_pc_partial_function (low, NULL, &low, &high) == 0)
+ error ("No function contains specified address");
+ }
+ else
+ high = parse_and_eval_address (Tcl_GetStringFromObj (objv[3], NULL));
+
+ return gdb_disassemble_driver (low, high, mixed_source_and_assembly, NULL,
+ gdbtk_print_source, gdbtk_print_asm);
+
+}
/* This implements the tcl command gdb_load_disassembly
*
* Arguments:
* widget - the name of a text widget into which to load the data
* source_with_assm - must be "source" or "nosource"
- * low_address - the CORE_ADDR from which to start disassembly
- * ?hi_address? - the CORE_ADDR to which to disassemble, defaults
+ * low_address - the address from which to start disassembly
+ * ?hi_address? - the address to which to disassemble, defaults
* to the end of the function containing low_address.
* Tcl Result:
* The text widget is loaded with the data, and a list is returned.
@@ -1542,33 +2386,36 @@ gdb_restore_fputs (ClientData clientData, Tcl_Interp *interp,
*/
static int
-gdb_load_disassembly (ClientData clientData, Tcl_Interp *interp,
- int objc, Tcl_Obj *CONST objv[])
+gdb_load_disassembly (clientData, interp, objc, objv)
+ ClientData clientData;
+ Tcl_Interp *interp;
+ int objc;
+ Tcl_Obj *CONST objv[];
{
- CORE_ADDR low, high, orig;
+ CORE_ADDR low, high;
struct disassembly_client_data client_data;
int mixed_source_and_assembly, ret_val, i;
+ char *widget;
char *arg_ptr;
char *map_name;
- Tcl_WideInt waddr;
- if (objc != 6 && objc != 7)
- {
- Tcl_WrongNumArgs (interp, 1, objv, "[source|nosource] map_arr index_prefix low_address ?hi_address");
- return TCL_ERROR;
- }
+ if (objc != 6 && objc != 7) {
+ Tcl_SetStringObj (result_ptr->obj_ptr, "wrong # args, should be: widget [source|nosource] map_arr index_prefix low_address ?hi_address", -1);
+ return TCL_ERROR;
+ }
client_data.widget = Tcl_GetStringFromObj (objv[1], NULL);
if ( Tk_NameToWindow (interp, client_data.widget,
Tk_MainWindow (interp)) == NULL)
{
- gdbtk_set_result (interp, "Invalid widget name.");
+ Tcl_SetStringObj (result_ptr->obj_ptr, "Invalid widget name.", -1);
return TCL_ERROR;
}
if (!Tcl_GetCommandInfo (interp, client_data.widget, &client_data.cmd))
{
- gdbtk_set_result (interp, "Can't get widget command info");
+ Tcl_SetStringObj (result_ptr->obj_ptr, "Can't get widget command info",
+ -1);
return TCL_ERROR;
}
@@ -1579,18 +2426,19 @@ gdb_load_disassembly (ClientData clientData, Tcl_Interp *interp,
mixed_source_and_assembly = 0;
else
{
- gdbtk_set_result (interp, "Second arg must be 'source' or 'nosource'");
+ Tcl_SetStringObj (result_ptr->obj_ptr,
+ "Second arg must be 'source' or 'nosource'", -1);
return TCL_ERROR;
}
/* As we populate the text widget, we will also create an array in the
caller's scope. The name is given by objv[3].
Each source line gets an entry or the form:
- array($prefix,srcline=$src_line_no) = $widget_line_no
+ array($prefix,srcline=$src_line_no) = $widget_line_no
Each assembly line gets two entries of the form:
- array($prefix,pc=$pc) = $widget_line_no
- array($prefix,line=$widget_line_no) = $src_line_no
+ array($prefix,pc=$pc) = $widget_line_no
+ array($prefix,line=$widget_line_no) = $src_line_no
Where prefix is objv[4].
*/
@@ -1603,11 +2451,10 @@ gdb_load_disassembly (ClientData clientData, Tcl_Interp *interp,
int prefix_len;
client_data.map_arr = "map_array";
- if (Tcl_UpVar (interp, "1", map_name, client_data.map_arr, 0) != TCL_OK)
- {
- gdbtk_set_result (interp, "Can't link map array.");
- return TCL_ERROR;
- }
+ if (Tcl_UpVar (interp, "1", map_name, client_data.map_arr, 0) != TCL_OK) {
+ Tcl_SetStringObj (result_ptr->obj_ptr, "Can't link map array.", -1);
+ return TCL_ERROR;
+ }
prefix = Tcl_GetStringFromObj (objv[4], &prefix_len);
@@ -1615,7 +2462,7 @@ gdb_load_disassembly (ClientData clientData, Tcl_Interp *interp,
Tcl_DStringAppend (&client_data.src_to_line_prefix,
prefix, prefix_len);
Tcl_DStringAppend (&client_data.src_to_line_prefix, ",srcline=",
- sizeof (",srcline=") - 1);
+ sizeof (",srcline=") - 1);
Tcl_DStringInit(&client_data.pc_to_line_prefix);
Tcl_DStringAppend (&client_data.pc_to_line_prefix,
@@ -1636,24 +2483,18 @@ gdb_load_disassembly (ClientData clientData, Tcl_Interp *interp,
}
/* Now parse the addresses */
- if (Tcl_GetWideIntFromObj (interp, objv[5], &waddr) != TCL_OK)
- return TCL_ERROR;
- low = waddr;
-
- orig = low;
+
+ low = parse_and_eval_address (Tcl_GetStringFromObj (objv[5], NULL));
if (objc == 6)
{
if (find_pc_partial_function (low, NULL, &low, &high) == 0)
- error ("No function contains address 0x%s", core_addr_to_string (orig));
+ error ("No function contains specified address");
}
else
- {
- if (Tcl_GetWideIntFromObj (interp, objv[6], &waddr) != TCL_OK)
- return TCL_ERROR;
- high = waddr;
- }
-
+ high = parse_and_eval_address (Tcl_GetStringFromObj (objv[6], NULL));
+
+
/* Setup the client_data structure, and call the driver function. */
client_data.file_opened_p = 0;
@@ -1689,18 +2530,18 @@ gdb_load_disassembly (ClientData clientData, Tcl_Interp *interp,
/* client_data.source_argv[3] = line_number; */
client_data.source_argv[4] = "";
/* client_data.source_argv[5] = line; */
- client_data.source_argv[6] = "source_tag2";
+ client_data.source_argv[6] = "source_tag";
}
ret_val = gdb_disassemble_driver (low, high, mixed_source_and_assembly,
- (ClientData) &client_data,
- gdbtk_load_source, gdbtk_load_asm);
+ (ClientData) &client_data,
+ gdbtk_load_source, gdbtk_load_asm);
/* Now clean up the opened file, and the Tcl data structures */
- if (client_data.file_opened_p == 1)
+ if (client_data.file_opened_p == 1) {
fclose(client_data.fp);
-
+ }
if (*client_data.map_arr != '\0')
{
Tcl_DStringFree(&client_data.src_to_line_prefix);
@@ -1716,30 +2557,38 @@ gdb_load_disassembly (ClientData clientData, Tcl_Interp *interp,
/* Finally, if we were successful, stick the low & high addresses
into the Tcl result. */
- if (ret_val == TCL_OK)
- {
- Tcl_ListObjAppendElement (NULL, result_ptr->obj_ptr,
- Tcl_NewStringObj (core_addr_to_string (low), -1));
- Tcl_ListObjAppendElement (NULL, result_ptr->obj_ptr,
- Tcl_NewStringObj (core_addr_to_string (high), -1));
- }
+ if (ret_val == TCL_OK) {
+ char buffer[256];
+ Tcl_Obj *limits_obj[2];
+
+ sprintf (buffer, "0x%s", paddr_nz (low));
+ limits_obj[0] = Tcl_NewStringObj (buffer, -1);
+
+ sprintf (buffer, "0x%s", paddr_nz (high));
+ limits_obj[1] = Tcl_NewStringObj (buffer, -1);
+
+ Tcl_DecrRefCount (result_ptr->obj_ptr);
+ result_ptr->obj_ptr = Tcl_NewListObj (2, limits_obj);
+
+ }
return ret_val;
+
}
static void
-gdbtk_load_source (ClientData clientData, struct symtab *symtab,
- int start_line, int end_line)
+gdbtk_load_source (ClientData clientData, struct symtab *symtab, int
+ start_line, int end_line)
{
struct disassembly_client_data *client_data =
(struct disassembly_client_data *) clientData;
- char *buffer;
+ char buffer[18];
int index_len;
index_len = Tcl_DStringLength (&client_data->src_to_line_prefix);
if (client_data->file_opened_p == 1)
{
- const char **text_argv;
+ char **text_argv;
char line[10000], line_number[18];
int found_carriage_return = 1;
@@ -1780,18 +2629,18 @@ gdbtk_load_source (ClientData clientData, struct symtab *symtab,
sprintf (line_number + 1, "%d", start_line);
- if (found_carriage_return)
- {
- char *p = strrchr(line, '\0') - 2;
- if (*p == '\r')
- {
- *p = '\n';
- *(p + 1) = '\0';
- }
- else
- found_carriage_return = 0;
+ if (found_carriage_return) {
+ char *p;
+
+ p = strrchr(line, '\0') - 2;
+ if (*p == '\r') {
+ *p = '\n';
+ *(p + 1) = '\0';
+ } else {
+ found_carriage_return = 0;
}
-
+ }
+
/* Run the command, then add an entry to the map array in
the caller's scope, if requested. */
@@ -1807,12 +2656,11 @@ gdbtk_load_source (ClientData clientData, struct symtab *symtab,
/* FIXME: Convert to Tcl_SetVar2Ex when we move to 8.2. This
will allow us avoid converting widget_line_no into a string. */
- xasprintf (&buffer, "%d", client_data->widget_line_no);
+ sprintf (buffer, "%d", client_data->widget_line_no);
Tcl_SetVar2 (client_data->interp, client_data->map_arr,
Tcl_DStringValue (&client_data->src_to_line_prefix),
buffer, 0);
- free(buffer);
Tcl_DStringSetLength (&client_data->src_to_line_prefix, index_len);
}
@@ -1851,26 +2699,25 @@ gdbtk_load_source (ClientData clientData, struct symtab *symtab,
gdbtk_load_source (clientData, symtab, start_line, end_line);
}
}
- else
- {
- /* If we couldn't open the file, or got some prior error, just exit. */
- return;
- }
-}
+ else {
+ /* If we couldn't open the file, or got some prior error, just exit. */
+
+ return;
+ }
+}
-/* FIXME: cagney/2003-09-08: "di" is not used and unneeded. */
static CORE_ADDR
-gdbtk_load_asm (ClientData clientData, CORE_ADDR pc,
- struct disassemble_info *di)
+gdbtk_load_asm (clientData, pc, di)
+ ClientData clientData;
+ CORE_ADDR pc;
+ struct disassemble_info *di;
{
struct disassembly_client_data * client_data
= (struct disassembly_client_data *) clientData;
- const char **text_argv;
+ char **text_argv;
int i, pc_to_line_len, line_to_pc_len;
- gdbtk_result new_result;
- int insn;
- struct cleanup *old_chain = NULL;
+ gdbtk_result new_result, *old_result_ptr;
pc_to_line_len = Tcl_DStringLength (&client_data->pc_to_line_prefix);
line_to_pc_len = Tcl_DStringLength (&client_data->line_to_pc_prefix);
@@ -1880,7 +2727,7 @@ gdbtk_load_asm (ClientData clientData, CORE_ADDR pc,
/* Preserve the current Tcl result object, print out what we need, and then
suck it out of the result, and replace... */
- old_chain = make_cleanup (gdbtk_restore_result_ptr, (void *) result_ptr);
+ old_result_ptr = result_ptr;
result_ptr = &new_result;
result_ptr->obj_ptr = client_data->result_obj[0];
result_ptr->flags = GDBTK_TO_RESULT;
@@ -1889,17 +2736,17 @@ gdbtk_load_asm (ClientData clientData, CORE_ADDR pc,
for (i = 0; i < 3; i++)
Tcl_SetObjLength (client_data->result_obj[i], 0);
-
- fputs_filtered (paddress (pc), gdb_stdout);
+
+ print_address_numeric (pc, 1, gdb_stdout);
gdb_flush (gdb_stdout);
result_ptr->obj_ptr = client_data->result_obj[1];
+
print_address_symbolic (pc, gdb_stdout, 1, "\t");
gdb_flush (gdb_stdout);
result_ptr->obj_ptr = client_data->result_obj[2];
- /* FIXME: cagney/2003-09-08: This should use gdb_disassembly. */
- insn = gdb_print_insn (pc, gdb_stdout, NULL);
+ pc += (*tm_print_insn) (pc, di);
gdb_flush (gdb_stdout);
client_data->widget_line_no++;
@@ -1909,21 +2756,21 @@ gdbtk_load_asm (ClientData clientData, CORE_ADDR pc,
text_argv[11] = Tcl_GetStringFromObj (client_data->result_obj[2], NULL);
client_data->cmd.proc (client_data->cmd.clientData,
- client_data->interp, 14, text_argv);
+ client_data->interp, 14, text_argv);
if (*client_data->map_arr != '\0')
{
- char *buffer;
+ char buffer[16];
/* Run the command, then add an entry to the map array in
the caller's scope. */
- Tcl_DStringAppend (&client_data->pc_to_line_prefix, core_addr_to_string (pc), -1);
+ Tcl_DStringAppend (&client_data->pc_to_line_prefix, text_argv[5], -1);
/* FIXME: Convert to Tcl_SetVar2Ex when we move to 8.2. This
will allow us avoid converting widget_line_no into a string. */
- xasprintf (&buffer, "%d", client_data->widget_line_no);
+ sprintf (buffer, "%d", client_data->widget_line_no);
Tcl_SetVar2 (client_data->interp, client_data->map_arr,
Tcl_DStringValue (&client_data->pc_to_line_prefix),
@@ -1931,32 +2778,113 @@ gdbtk_load_asm (ClientData clientData, CORE_ADDR pc,
Tcl_DStringAppend (&client_data->line_to_pc_prefix, buffer, -1);
-
Tcl_SetVar2 (client_data->interp, client_data->map_arr,
Tcl_DStringValue (&client_data->line_to_pc_prefix),
- core_addr_to_string (pc), 0);
-
+ text_argv[5], 0);
+
/* Restore the prefixes to their initial state. */
Tcl_DStringSetLength (&client_data->pc_to_line_prefix, pc_to_line_len);
Tcl_DStringSetLength (&client_data->line_to_pc_prefix, line_to_pc_len);
- xfree (buffer);
}
- do_cleanups (old_chain);
+ result_ptr = old_result_ptr;
+
+ return pc;
+}
+
+static void
+gdbtk_print_source (clientData, symtab, start_line, end_line)
+ ClientData clientData;
+ struct symtab *symtab;
+ int start_line;
+ int end_line;
+{
+ print_source_lines (symtab, start_line, end_line, 0);
+ gdb_flush (gdb_stdout);
+}
- return pc + insn;
+static CORE_ADDR
+gdbtk_print_asm (clientData, pc, di)
+ ClientData clientData;
+ CORE_ADDR pc;
+ struct disassemble_info *di;
+{
+ fputs_unfiltered (" ", gdb_stdout);
+ print_address (pc, gdb_stdout);
+ fputs_unfiltered (":\t ", gdb_stdout);
+ pc += (*tm_print_insn) (pc, di);
+ fputs_unfiltered ("\n", gdb_stdout);
+ gdb_flush (gdb_stdout);
+ return pc;
}
static int
-gdb_disassemble_driver (CORE_ADDR low, CORE_ADDR high,
- int mixed_source_and_assembly,
- ClientData clientData,
- void (*print_source_fn) (ClientData, struct symtab *, int, int),
- CORE_ADDR (*print_asm_fn) (ClientData, CORE_ADDR, struct disassemble_info *))
+gdb_disassemble_driver (low, high, mixed_source_and_assembly,
+ clientData, print_source_fn, print_asm_fn)
+ CORE_ADDR low;
+ CORE_ADDR high;
+ int mixed_source_and_assembly;
+ ClientData clientData;
+ void (*print_source_fn) (ClientData, struct symtab *, int, int);
+ CORE_ADDR (*print_asm_fn) (ClientData, CORE_ADDR,
+ struct disassemble_info *);
{
CORE_ADDR pc;
+ static disassemble_info di;
+ static int di_initialized;
+
+ if (! di_initialized)
+ {
+ INIT_DISASSEMBLE_INFO_NO_ARCH (di, gdb_stdout,
+ (fprintf_ftype) fprintf_unfiltered);
+ di.flavour = bfd_target_unknown_flavour;
+ di.memory_error_func = dis_asm_memory_error;
+ di.print_address_func = dis_asm_print_address;
+ di_initialized = 1;
+ }
+
+ di.mach = TARGET_PRINT_INSN_INFO->mach;
+ if (TARGET_BYTE_ORDER == BIG_ENDIAN)
+ di.endian = BFD_ENDIAN_BIG;
+ else
+ di.endian = BFD_ENDIAN_LITTLE;
+
+ /* Set the architecture for multi-arch configurations. */
+ if (TARGET_ARCHITECTURE != NULL)
+ di.mach = TARGET_ARCHITECTURE->mach;
+
+ /* If disassemble_from_exec == -1, then we use the following heuristic to
+ determine whether or not to do disassembly from target memory or from the
+ exec file:
+
+ If we're debugging a local process, read target memory, instead of the
+ exec file. This makes disassembly of functions in shared libs work
+ correctly. Also, read target memory if we are debugging native threads.
+
+ Else, we're debugging a remote process, and should disassemble from the
+ exec file for speed. However, this is no good if the target modifies its
+ code (for relocation, or whatever).
+ */
+
+ if (disassemble_from_exec == -1)
+ {
+ if (strcmp (target_shortname, "child") == 0
+ || strcmp (target_shortname, "procfs") == 0
+ || strcmp (target_shortname, "vxprocess") == 0
+ || strstr (target_shortname, "-threads") != NULL)
+ /* It's a child process, read inferior mem */
+ disassemble_from_exec = 0;
+ else
+ /* It's remote, read the exec file */
+ disassemble_from_exec = 1;
+ }
+
+ if (disassemble_from_exec)
+ di.read_memory_func = gdbtk_dis_asm_read_memory;
+ else
+ di.read_memory_func = dis_asm_read_memory;
/* If just doing straight assembly, all we need to do is disassemble
everything between low and high. If doing mixed source/assembly, we've
@@ -2012,11 +2940,24 @@ gdb_disassemble_driver (CORE_ADDR low, CORE_ADDR high,
&& le[i].pc == le[i + 1].pc)
continue; /* Ignore duplicates */
- /* Skip any end-of-function markers. */
- if (le[i].line == 0)
- continue;
-
- mle[newlines].line = le[i].line;
+ /* GCC sometimes emits line directives with a linenumber
+ of 0. It does this to handle live range splitting.
+ This may be a bug, but we need to be able to handle it.
+ For now, use the previous instructions line number.
+ Since this is a bit of a hack anyway, we will just lose
+ if the bogus sline is the first line of the range. For
+ functions, I have never seen this to be the case. */
+
+ if (le[i].line != 0)
+ {
+ mle[newlines].line = le[i].line;
+ }
+ else
+ {
+ if (newlines > 0)
+ mle[newlines].line = mle[newlines - 1].line;
+ }
+
if (le[i].line > le[i + 1].line)
out_of_order = 1;
mle[newlines].start_pc = le[i].pc;
@@ -2065,9 +3006,7 @@ gdb_disassemble_driver (CORE_ADDR low, CORE_ADDR high,
for (pc = mle[i].start_pc; pc < mle[i].end_pc; )
{
QUIT;
- /* FIXME: cagney/2003-09-08: This entire function should
- be replaced by gdb_disassembly. */
- pc = print_asm_fn (clientData, pc, NULL);
+ pc = print_asm_fn (clientData, pc, &di);
}
}
}
@@ -2077,19 +3016,43 @@ gdb_disassemble_driver (CORE_ADDR low, CORE_ADDR high,
for (pc = low; pc < high; )
{
QUIT;
- /* FIXME: cagney/2003-09-08: This entire function should be
- replaced by gdb_disassembly. */
- pc = print_asm_fn (clientData, pc, NULL);
+ pc = print_asm_fn (clientData, pc, &di);
}
}
return TCL_OK;
}
+/* This is the memory_read_func for gdb_disassemble when we are
+ disassembling from the exec file. */
+
+static int
+gdbtk_dis_asm_read_memory (memaddr, myaddr, len, info)
+ bfd_vma memaddr;
+ bfd_byte *myaddr;
+ int len;
+ disassemble_info *info;
+{
+ extern struct target_ops exec_ops;
+ int res;
+
+ errno = 0;
+ res = xfer_memory (memaddr, myaddr, len, 0, &exec_ops);
+
+ if (res == len)
+ return 0;
+ else if (errno == 0)
+ return EIO;
+ else
+ return errno;
+}
+
/* This will be passed to qsort to sort the results of the disassembly */
static int
-compare_lines (const PTR mle1p, const PTR mle2p)
+compare_lines (mle1p, mle2p)
+ const PTR mle1p;
+ const PTR mle2p;
{
struct my_line_entry *mle1, *mle2;
int val;
@@ -2107,56 +3070,47 @@ compare_lines (const PTR mle1p, const PTR mle2p)
/* This implements the TCL command `gdb_loc',
-* Arguments:
-* ?symbol? The symbol or address to locate - defaults to pc
-* Tcl Return:
-* a list consisting of the following:
-* basename, function name, filename, line number, address, current pc
-*/
+ * Arguments:
+ * ?symbol? The symbol or address to locate - defaults to pc
+ * Tcl Return:
+ * a list consisting of the following:
+ * basename, function name, filename, line number, address, current pc
+ */
static int
-gdb_loc (ClientData clientData, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[])
+gdb_loc (clientData, interp, objc, objv)
+ ClientData clientData;
+ Tcl_Interp *interp;
+ int objc;
+ Tcl_Obj *CONST objv[];
{
char *filename;
struct symtab_and_line sal;
+ struct symbol *sym;
char *fname;
CORE_ADDR pc;
if (objc == 1)
{
- /* This function can be called, before the target is properly
- set-up, the following prevents an error, by trying to
- read_pc when there is no pc to read. It defaults pc,
- before the target is connected to the entry point of the
- program */
- if (!target_has_registers)
+ if (selected_frame && (selected_frame->pc != read_pc ()))
{
- pc = entry_point_address ();
- sal = find_pc_line (pc, 0);
- }
- else
- {
- struct frame_info *frame;
-
- frame = get_selected_frame (NULL);
-
- if (get_frame_pc (frame) != read_pc ())
- {
- /* Note - this next line is not correct on all architectures.
- For a graphical debugger we really want to highlight the
- assembly line that called the next function on the stack.
- Many architectures have the next instruction saved as the
- pc on the stack, so what happens is the next instruction
- is highlighted. FIXME */
- pc = get_frame_pc (frame);
- find_frame_sal (frame, &sal);
- }
- else
- {
- pc = read_pc ();
- sal = find_pc_line (pc, 0);
- }
+ /* Note - this next line is not correct on all architectures.
+ For a graphical debugger we really want to highlight the
+ assembly line that called the next function on the stack.
+ Many architectures have the next instruction saved as the
+ pc on the stack, so what happens is the next instruction
+ is highlighted. FIXME */
+ pc = selected_frame->pc;
+ sal = find_pc_line (selected_frame->pc,
+ selected_frame->next != NULL
+ && !selected_frame->next->signal_handler_caller
+ && !frame_in_dummy (selected_frame->next));
}
+ else
+ {
+ pc = read_pc ();
+ sal = find_pc_line (pc, 0);
+ }
}
else if (objc == 2)
{
@@ -2171,7 +3125,7 @@ gdb_loc (ClientData clientData, Tcl_Interp *interp, int objc, Tcl_Obj *CONST obj
if (sals.nelts != 1)
{
- gdbtk_set_result (interp, "Ambiguous line spec", -1);
+ Tcl_SetStringObj (result_ptr->obj_ptr, "Ambiguous line spec", -1);
return TCL_ERROR;
}
resolve_sal_pc (&sal);
@@ -2179,7 +3133,7 @@ gdb_loc (ClientData clientData, Tcl_Interp *interp, int objc, Tcl_Obj *CONST obj
}
else
{
- Tcl_WrongNumArgs (interp, 1, objv, "?symbol?");
+ Tcl_SetStringObj (result_ptr->obj_ptr, "wrong # args", -1);
return TCL_ERROR;
}
@@ -2199,15 +3153,17 @@ gdb_loc (ClientData clientData, Tcl_Interp *interp, int objc, Tcl_Obj *CONST obj
filename = "";
/* file name */
- Tcl_ListObjAppendElement (NULL, result_ptr->obj_ptr, Tcl_NewStringObj (filename, -1));
+ Tcl_ListObjAppendElement (NULL, result_ptr->obj_ptr,
+ Tcl_NewStringObj (filename, -1));
/* line number */
- Tcl_ListObjAppendElement (NULL, result_ptr->obj_ptr, Tcl_NewIntObj (sal.line));
+ Tcl_ListObjAppendElement (NULL, result_ptr->obj_ptr,
+ Tcl_NewIntObj (sal.line));
/* PC in current frame */
- Tcl_ListObjAppendElement (NULL, result_ptr->obj_ptr,
- Tcl_NewStringObj (core_addr_to_string (pc), -1));
+ sprintf_append_element_to_obj (result_ptr->obj_ptr, "0x%s", paddr_nz (pc));
/* Real PC */
- Tcl_ListObjAppendElement (NULL, result_ptr->obj_ptr,
- Tcl_NewStringObj (core_addr_to_string (stop_pc), -1));
+ sprintf_append_element_to_obj (result_ptr->obj_ptr, "0x%s",
+ paddr_nz (stop_pc));
+
/* shared library */
#ifdef PC_SOLIB
Tcl_ListObjAppendElement (NULL, result_ptr->obj_ptr,
@@ -2219,237 +3175,109 @@ gdb_loc (ClientData clientData, Tcl_Interp *interp, int objc, Tcl_Obj *CONST obj
return TCL_OK;
}
-/* This implements the TCL command gdb_entry_point. It returns the current
- entry point address. */
-
-static int
-gdb_entry_point (ClientData clientData, Tcl_Interp *interp,
- int objc, Tcl_Obj *CONST objv[])
-{
- char *addrstr;
-
- /* If we have not yet loaded an exec file, then we have no
- entry point, so return an empty string.*/
- if ((int) current_target.to_stratum > (int) dummy_stratum)
- {
- addrstr = (char *)core_addr_to_string (entry_point_address ());
- Tcl_SetStringObj (result_ptr->obj_ptr, addrstr, -1);
- }
- else
- Tcl_SetStringObj (result_ptr->obj_ptr, "", -1);
-
- return TCL_OK;
-}
-
-/* Covert hex to binary. Stolen from remote.c,
- but added error handling */
-static int
-fromhex (int a)
-{
- if (a >= '0' && a <= '9')
- return a - '0';
- else if (a >= 'a' && a <= 'f')
- return a - 'a' + 10;
- else if (a >= 'A' && a <= 'F')
- return a - 'A' + 10;
-
- return -1;
-}
-
-static int
-hex2bin (const char *hex, char *bin, int count)
-{
- int i, m, n;
- int incr = 2;
-
-
- if (gdbarch_byte_order (current_gdbarch) == BFD_ENDIAN_LITTLE)
- {
- /* need to read string in reverse */
- hex += count - 2;
- incr = -2;
- }
-
- for (i = 0; i < count; i += 2)
- {
- if (hex[0] == 0 || hex[1] == 0)
- {
- /* Hex string is short, or of uneven length.
- Return the count that has been converted so far. */
- return i;
- }
- m = fromhex (hex[0]);
- n = fromhex (hex[1]);
- if (m == -1 || n == -1)
- return -1;
- *bin++ = m * 16 + n;
- hex += incr;
- }
-
- return i;
-}
-
-/* This implements the Tcl command 'gdb_set_mem', which
- * sets some chunk of memory.
- *
+/* This implements the Tcl command 'gdb_get_mem', which
+ * dumps a block of memory
* Arguments:
- * gdb_set_mem addr hexstr len
+ * gdb_get_mem addr form size nbytes bpr aschar
*
- * addr: address of data to set
- * hexstr: ascii string of data to set
- * len: number of bytes of data to set
- */
-static int
-gdb_set_mem (ClientData clientData, Tcl_Interp *interp,
- int objc, Tcl_Obj *CONST objv[])
-{
- CORE_ADDR addr;
- gdb_byte buf[128];
- char *hexstr;
- int len, size;
-
- if (objc != 4)
- {
- Tcl_WrongNumArgs (interp, 1, objv, "addr hex_data len");
- return TCL_ERROR;
- }
-
- /* Address to write */
- addr = string_to_core_addr (Tcl_GetStringFromObj (objv[1], NULL));
-
- /* String value to write: it's in hex */
- hexstr = Tcl_GetStringFromObj (objv[2], NULL);
- if (hexstr == NULL)
- return TCL_ERROR;
-
- /* Length of buf */
- if (Tcl_GetIntFromObj (interp, objv[3], &len) != TCL_OK)
- return TCL_ERROR;
-
- /* Convert hexstr to binary and write */
- if (hexstr[0] == '0' && hexstr[1] == 'x')
- hexstr += 2;
- size = hex2bin (hexstr, (char *) buf, strlen (hexstr));
- if (size < 0)
- {
- /* Error in input */
- gdbtk_set_result (interp, "Invalid hexadecimal input: \"0x%s\"", hexstr);
- return TCL_ERROR;
- }
-
- target_write_memory (addr, buf, len);
- return TCL_OK;
-}
-
-/* This implements the Tcl command 'gdb_update_mem', which
- * updates a block of memory in the memory window
- *
- * Arguments:
- * gdb_update_mem data addr form size nbytes bpr aschar
- *
- * 1 data: variable that holds table's data
- * 2 addr: address of data to dump
- * 3 mform: a char indicating format
- * 4 size: size of each element; 1,2,4, or 8 bytes
- * 5 nbytes: the number of bytes to read
- * 6 bpr: bytes per row
- * 7 aschar: if present, an ASCII dump of the row is included. ASCHAR
- * used for unprintable characters.
+ * addr: address of data to dump
+ * form: a char indicating format
+ * size: size of each element; 1,2,4, or 8 bytes
+ * nbytes: the number of bytes to read
+ * bpr: bytes per row
+ * aschar: if present, an ASCII dump of the row is included. ASCHAR
+ * used for unprintable characters.
*
* Return:
- * a list of three integers: {border_col_width data_col_width ascii_col_width}
- * which can be used to set the table's column widths. */
+ * a list of elements followed by an optional ASCII dump */
static int
-gdb_update_mem (ClientData clientData, Tcl_Interp *interp,
- int objc, Tcl_Obj *CONST objv[])
+gdb_get_mem (clientData, interp, objc, objv)
+ ClientData clientData;
+ Tcl_Interp *interp;
+ int objc;
+ Tcl_Obj *CONST objv[];
{
- long dummy;
- char index[20];
+ int size, asize, i, j, bc;
CORE_ADDR addr;
int nbytes, rnum, bpr;
- int size, asize, i, j, bc;
- int max_ascii_len, max_val_len, max_label_len;
- char format, aschar;
- char *data, *tmp;
- char buff[128], *mbuf, *mptr, *cptr, *bptr;
- struct ui_file *stb;
+ long tmp;
+ char format, buff[128], aschar, *mbuf, *mptr, *cptr, *bptr;
struct type *val_type;
- struct cleanup *old_chain;
- if (objc < 7 || objc > 8)
+ if (objc < 6 || objc > 7)
{
- Tcl_WrongNumArgs (interp, 1, objv, "data addr format size bytes bytes_per_row ?ascii_char?");
+ Tcl_SetStringObj (result_ptr->obj_ptr,
+ "addr format size bytes bytes_per_row ?ascii_char?",
+ -1);
return TCL_ERROR;
}
- /* Get table data and link to a local variable */
- data = Tcl_GetStringFromObj (objv[1], NULL);
- if (data == NULL)
+ if (Tcl_GetIntFromObj (interp, objv[3], &size) != TCL_OK)
{
- gdbtk_set_result (interp, "could not get data variable");
+ result_ptr->flags |= GDBTK_IN_TCL_RESULT;
return TCL_ERROR;
}
-
- if (Tcl_UpVar (interp, "1", data, "data", 0) != TCL_OK)
+ else if (size <= 0)
{
- gdbtk_set_result (interp, "could not link table data");
+ Tcl_SetStringObj (result_ptr->obj_ptr, "Invalid size, must be > 0", -1);
return TCL_ERROR;
}
- if (Tcl_GetIntFromObj (interp, objv[4], &size) != TCL_OK)
- return TCL_ERROR;
- else if (size <= 0)
+ if (Tcl_GetIntFromObj (interp, objv[4], &nbytes) != TCL_OK)
{
- gdbtk_set_result (interp, "Invalid size, must be > 0");
+ result_ptr->flags |= GDBTK_IN_TCL_RESULT;
return TCL_ERROR;
}
-
- if (Tcl_GetIntFromObj (interp, objv[5], &nbytes) != TCL_OK)
- return TCL_ERROR;
else if (nbytes <= 0)
{
- gdbtk_set_result (interp, "Invalid number of bytes, must be > 0");
+ Tcl_SetStringObj (result_ptr->obj_ptr,
+ "Invalid number of bytes, must be > 0",
+ -1);
return TCL_ERROR;
}
- if (Tcl_GetIntFromObj (interp, objv[6], &bpr) != TCL_OK)
- return TCL_ERROR;
- else if (bpr <= 0)
+ if (Tcl_GetIntFromObj (interp, objv[5], &bpr) != TCL_OK)
{
- gdbtk_set_result (interp, "Invalid bytes per row, must be > 0");
+ result_ptr->flags |= GDBTK_IN_TCL_RESULT;
return TCL_ERROR;
}
-
- tmp = Tcl_GetStringFromObj (objv[2], NULL);
- if (tmp == NULL)
+ else if (bpr <= 0)
{
- gdbtk_set_result (interp, "could not get address");
+ Tcl_SetStringObj (result_ptr->obj_ptr,
+ "Invalid bytes per row, must be > 0", -1);
return TCL_ERROR;
}
- addr = string_to_core_addr (tmp);
- format = *(Tcl_GetStringFromObj (objv[3], NULL));
- mbuf = (char *) xmalloc (nbytes + 32);
+ if (Tcl_GetLongFromObj (interp, objv[1], &tmp) != TCL_OK)
+ return TCL_OK;
+
+ addr = (CORE_ADDR) tmp;
+
+ format = *(Tcl_GetStringFromObj (objv[2], NULL));
+ mbuf = (char *) malloc (nbytes + 32);
if (!mbuf)
{
- gdbtk_set_result (interp, "Out of memory.");
+ Tcl_SetStringObj (result_ptr->obj_ptr, "Out of memory.", -1);
return TCL_ERROR;
}
memset (mbuf, 0, nbytes + 32);
mptr = cptr = mbuf;
- rnum = target_read (&current_target, TARGET_OBJECT_MEMORY, NULL,
- mbuf, addr, nbytes);
- if (rnum <= 0)
+ rnum = 0;
+ while (rnum < nbytes)
{
- gdbtk_set_result (interp, "Unable to read memory.");
- return TCL_ERROR;
+ int error;
+ int num = target_read_memory_partial (addr + rnum, mbuf + rnum,
+ nbytes - rnum, &error);
+ if (num <= 0)
+ break;
+ rnum += num;
}
- if (objc == 8)
- aschar = *(Tcl_GetStringFromObj (objv[7], NULL));
+ if (objc == 7)
+ aschar = *(Tcl_GetStringFromObj (objv[6], NULL));
else
aschar = 0;
@@ -2479,80 +3307,35 @@ gdb_update_mem (ClientData clientData, Tcl_Interp *interp,
bc = 0; /* count of bytes in a row */
bptr = &buff[0]; /* pointer for ascii dump */
- /* Open a memory ui_file that we can use to print memory values */
- stb = mem_fileopen ();
- old_chain = make_cleanup_ui_file_delete (stb);
+ /* Build up the result as a list... */
- /* A little macro to do column indices. As a rule, given the current
- byte, i, of a total nbytes and the bytes per row, bpr, and the size of
- each cell, size, the row and column will be given by:
-
- row = i/bpr
- col = (i%bpr)/size
- */
-#define INDEX(row,col) sprintf (index, "%d,%d",(row),(col))
-
- /* Fill in address labels */
- max_label_len = 0;
- for (i = 0; i < nbytes; i += bpr)
- {
- char s[130];
- sprintf (s, "%s", core_addr_to_string (addr + i));
- INDEX ((int) i/bpr, -1);
- Tcl_SetVar2 (interp, "data", index, s, 0);
-
- /* The tcl code in MemWin::update_addr used to track the size
- of each cell. I don't see how these could change for any given
- update, so we don't loop over all cells. We just note the first
- size. */
- if (max_label_len == 0)
- max_label_len = strlen (s);
- }
+ result_ptr->flags |= GDBTK_MAKES_LIST;
- /* Fill in memory */
- max_val_len = 0; /* Ditto the above comments about max_label_len */
- max_ascii_len = 0;
for (i = 0; i < nbytes; i += size)
{
- INDEX ((int) i/bpr, (int) (i%bpr)/size);
-
if (i >= rnum)
{
- /* Read fewer bytes than requested */
- tmp = "N/A";
-
+ Tcl_ListObjAppendElement (NULL, result_ptr->obj_ptr,
+ Tcl_NewStringObj ("N/A", 3));
if (aschar)
- {
- for (j = 0; j < size; j++)
- *bptr++ = 'X';
- }
+ for (j = 0; j < size; j++)
+ *bptr++ = 'X';
}
else
{
- /* print memory to our uiout file and set the table's variable */
- ui_file_rewind (stb);
- print_scalar_formatted (mptr, val_type, format, asize, stb);
- tmp = ui_file_xstrdup (stb, &dummy);
-
- /* See comments above on max_*_len */
- if (max_val_len == 0)
- max_val_len = strlen (tmp);
+ print_scalar_formatted (mptr, val_type, format, asize, gdb_stdout);
if (aschar)
{
for (j = 0; j < size; j++)
{
- if (isprint (*cptr))
- *bptr++ = *cptr++;
- else
- {
- *bptr++ = aschar;
- cptr++;;
- }
+ *bptr = *cptr++;
+ if (*bptr < 32 || *bptr > 126)
+ *bptr = aschar;
+ bptr++;
}
}
}
- Tcl_SetVar2 (interp, "data", index, tmp, 0);
mptr += size;
bc += size;
@@ -2560,27 +3343,17 @@ gdb_update_mem (ClientData clientData, Tcl_Interp *interp,
if (aschar && (bc >= bpr))
{
/* end of row. Add it to the result and reset variables */
- *bptr = '\000';
- INDEX (i/bpr, bpr/size);
- Tcl_SetVar2 (interp, "data", index, buff, 0);
-
- /* See comments above on max_*_len */
- if (max_ascii_len == 0)
- max_ascii_len = strlen (buff);
-
+ Tcl_ListObjAppendElement (NULL, result_ptr->obj_ptr,
+ Tcl_NewStringObj (buff, bc));
bc = 0;
bptr = &buff[0];
}
}
- /* return max_*_len so that column widths can be set */
- Tcl_ListObjAppendElement (interp, result_ptr->obj_ptr, Tcl_NewIntObj (max_label_len + 1));
- Tcl_ListObjAppendElement (interp, result_ptr->obj_ptr, Tcl_NewIntObj (max_val_len + 1));
- Tcl_ListObjAppendElement (interp, result_ptr->obj_ptr, Tcl_NewIntObj (max_ascii_len + 1));
- do_cleanups (old_chain);
- xfree (mbuf);
+ result_ptr->flags &= ~GDBTK_MAKES_LIST;
+
+ free (mbuf);
return TCL_OK;
-#undef INDEX
}
@@ -2605,8 +3378,11 @@ gdb_update_mem (ClientData clientData, Tcl_Interp *interp,
* Additional memory will be allocated if needed. */
#define LTABLE_SIZE 20000
static int
-gdb_loadfile (ClientData clientData, Tcl_Interp *interp, int objc,
- Tcl_Obj *CONST objv[])
+gdb_loadfile (clientData, interp, objc, objv)
+ ClientData clientData;
+ Tcl_Interp *interp;
+ int objc;
+ Tcl_Obj *CONST objv[];
{
char *file, *widget;
int linenumbers, ln, lnum, ltable_size;
@@ -2617,7 +3393,8 @@ gdb_loadfile (ClientData clientData, Tcl_Interp *interp, int objc,
long mtime = 0;
struct stat st;
char line[10000], line_num_buf[18];
- const char *text_argv[9];
+ int prefix_len_1, prefix_len_2, cur_prefix_len, widget_len;
+ char *text_argv[8];
Tcl_CmdInfo text_cmd;
@@ -2635,24 +3412,26 @@ gdb_loadfile (ClientData clientData, Tcl_Interp *interp, int objc,
if (!Tcl_GetCommandInfo (interp, widget, &text_cmd))
{
- gdbtk_set_result (interp, "Can't get widget command info");
+ Tcl_SetStringObj (result_ptr->obj_ptr, "Can't get widget command info",
+ -1);
return TCL_ERROR;
}
file = Tcl_GetStringFromObj (objv[2], NULL);
Tcl_GetBooleanFromObj (interp, objv[3], &linenumbers);
- symtab = lookup_symtab (file);
+ symtab = full_lookup_symtab (file);
if (!symtab)
{
- gdbtk_set_result (interp, "File not found in symtab");
+ Tcl_SetStringObj ( result_ptr->obj_ptr, "File not found in symtab", -1);
return TCL_ERROR;
}
file = symtab_to_filename ( symtab );
if ((fp = fopen ( file, "r" )) == NULL)
{
- gdbtk_set_result (interp, "Can't open file for reading");
+ Tcl_SetStringObj ( result_ptr->obj_ptr, "Can't open file for reading",
+ -1);
return TCL_ERROR;
}
@@ -2664,9 +3443,9 @@ gdb_loadfile (ClientData clientData, Tcl_Interp *interp, int objc,
}
if (symtab && symtab->objfile && symtab->objfile->obfd)
- mtime = bfd_get_mtime(symtab->objfile->obfd);
+ mtime = bfd_get_mtime(symtab->objfile->obfd);
else if (exec_bfd)
- mtime = bfd_get_mtime(exec_bfd);
+ mtime = bfd_get_mtime(exec_bfd);
if (mtime && mtime < st.st_mtime)
{
@@ -2683,8 +3462,8 @@ gdb_loadfile (ClientData clientData, Tcl_Interp *interp, int objc,
ltable = (char *)malloc (LTABLE_SIZE);
if (ltable == NULL)
{
+ Tcl_SetStringObj ( result_ptr->obj_ptr, "Out of memory.", -1);
fclose (fp);
- gdbtk_set_result (interp, "Out of memory.");
return TCL_ERROR;
}
@@ -2704,9 +3483,10 @@ gdb_loadfile (ClientData clientData, Tcl_Interp *interp, int objc,
ltable_size *= 2;
if (new_ltable == NULL)
{
+ Tcl_SetStringObj ( result_ptr->obj_ptr, "Out of memory.",
+ -1);
free (ltable);
fclose (fp);
- gdbtk_set_result (interp, "Out of memory.");
return TCL_ERROR;
}
ltable = new_ltable;
@@ -2735,23 +3515,25 @@ gdb_loadfile (ClientData clientData, Tcl_Interp *interp, int objc,
while (fgets (line + 1, 9980, fp))
{
+ char *p;
+
/* Look for DOS style \r\n endings, and if found,
* strip off the \r. We assume (for the sake of
* speed) that ALL lines in the file have DOS endings,
* or none do.
*/
- if (found_carriage_return)
- {
- char *p = strrchr(line, '\0') - 2;
- if (*p == '\r')
- {
- *p = '\n';
- *(p + 1) = '\0';
- }
- else
- found_carriage_return = 0;
+ if (found_carriage_return) {
+ char *p;
+
+ p = strrchr(line, '\0') - 2;
+ if (*p == '\r') {
+ *p = '\n';
+ *(p + 1) = '\0';
+ } else {
+ found_carriage_return = 0;
}
+ }
sprintf (line_num_buf+2, "%d", ln);
if (ltable[ln >> 3] & (1 << (ln % 8)))
@@ -2775,17 +3557,17 @@ gdb_loadfile (ClientData clientData, Tcl_Interp *interp, int objc,
while (fgets (line + 1, 9980, fp))
{
- if (found_carriage_return)
- {
- char *p = strrchr(line, '\0') - 2;
- if (*p == '\r')
- {
- *p = '\n';
- *(p + 1) = '\0';
- }
- else
- found_carriage_return = 0;
+ if (found_carriage_return) {
+ char *p;
+
+ p = strrchr(line, '\0') - 2;
+ if (*p == '\r') {
+ *p = '\n';
+ *(p + 1) = '\0';
+ } else {
+ found_carriage_return = 0;
}
+ }
if (ltable[ln >> 3] & (1 << (ln % 8)))
{
@@ -2809,218 +3591,1056 @@ gdb_loadfile (ClientData clientData, Tcl_Interp *interp, int objc,
}
/*
- * This section contains a bunch of miscellaneous utility commands
+ * This section contains commands for manipulation of breakpoints.
*/
-/* This implements the tcl command gdb_path_conv
-* On Windows, it canonicalizes the pathname,
-* On Unix, it is a no op.
-*
-* Arguments:
-* path
-* Tcl Result:
-* The canonicalized path.
-*/
+/* set a breakpoint by source file and line number */
+/* flags are as follows: */
+/* least significant 2 bits are disposition, rest is */
+/* type (normally 0).
+
+ enum bptype {
+ bp_breakpoint, Normal breakpoint
+ bp_hardware_breakpoint, Hardware assisted breakpoint
+ }
+
+ Disposition of breakpoint. Ie: what to do after hitting it.
+ enum bpdisp {
+ del, Delete it
+ del_at_next_stop, Delete at next stop, whether hit or not
+ disable, Disable it
+ donttouch Leave it alone
+ };
+ */
+
+/* This implements the tcl command "gdb_set_bp"
+ * It sets breakpoints, and runs the Tcl command
+ * gdbtk_tcl_breakpoint create
+ * to register the new breakpoint with the GUI.
+ *
+ * Tcl Arguments:
+ * filename: the file in which to set the breakpoint
+ * line: the line number for the breakpoint
+ * type: the type of the breakpoint
+ * thread: optional thread number
+ * Tcl Result:
+ * The return value of the call to gdbtk_tcl_breakpoint.
+ */
static int
-gdb_path_conv (ClientData clientData, Tcl_Interp *interp,
- int objc, Tcl_Obj *CONST objv[])
+gdb_set_bp (clientData, interp, objc, objv)
+ ClientData clientData;
+ Tcl_Interp *interp;
+ int objc;
+ Tcl_Obj *CONST objv[];
{
- if (objc != 2)
+ struct symtab_and_line sal;
+ int line, ret, thread = -1;
+ struct breakpoint *b;
+ char buf[64], *typestr;
+ Tcl_DString cmd;
+ enum bpdisp disp;
+
+ if (objc != 4 && objc != 5)
{
- Tcl_WrongNumArgs (interp, 1, objv, NULL);
+ Tcl_SetStringObj (result_ptr->obj_ptr,
+ "wrong number of args, should be \"filename line type [thread]\"", -1);
return TCL_ERROR;
}
-#ifdef __CYGWIN__
- {
- char pathname[256], *ptr;
+ sal.symtab = full_lookup_symtab (Tcl_GetStringFromObj (objv[1], NULL));
+ if (sal.symtab == NULL)
+ return TCL_ERROR;
- cygwin_conv_to_full_win32_path (Tcl_GetStringFromObj (objv[1], NULL),
- pathname);
- for (ptr = pathname; *ptr; ptr++)
- {
- if (*ptr == '\\')
- *ptr = '/';
- }
- Tcl_SetStringObj (result_ptr->obj_ptr, pathname, -1);
- }
-#else
- Tcl_SetStringObj (result_ptr->obj_ptr, Tcl_GetStringFromObj (objv[1], NULL),
- -1);
-#endif
+ if (Tcl_GetIntFromObj (interp, objv[2], &line) == TCL_ERROR)
+ {
+ result_ptr->flags = GDBTK_IN_TCL_RESULT;
+ return TCL_ERROR;
+ }
- return TCL_OK;
+ typestr = Tcl_GetStringFromObj (objv[3], NULL);
+ if (typestr == NULL)
+ {
+ result_ptr->flags = GDBTK_IN_TCL_RESULT;
+ return TCL_ERROR;
+ }
+ if (strncmp (typestr, "temp", 4) == 0)
+ disp = del;
+ else if (strncmp (typestr, "normal", 6) == 0)
+ disp = donttouch;
+ else
+ {
+ Tcl_SetStringObj (result_ptr->obj_ptr,
+ "type must be \"temp\" or \"normal\"", -1);
+ return TCL_ERROR;
+ }
+
+ if (objc == 5)
+ {
+ if (Tcl_GetIntFromObj (interp, objv[4], &thread) == TCL_ERROR)
+ {
+ result_ptr->flags = GDBTK_IN_TCL_RESULT;
+ return TCL_ERROR;
+ }
+ }
+
+ sal.line = line;
+ if (!find_line_pc (sal.symtab, sal.line, &sal.pc))
+ return TCL_ERROR;
+
+ sal.section = find_pc_overlay (sal.pc);
+ b = set_raw_breakpoint (sal);
+ set_breakpoint_count (breakpoint_count + 1);
+ b->number = breakpoint_count;
+ b->type = bp_breakpoint;
+ b->disposition = disp;
+ b->thread = thread;
+
+ /* FIXME: this won't work for duplicate basenames! */
+ sprintf (buf, "%s:%d", basename (Tcl_GetStringFromObj (objv[1], NULL)),
+ line);
+ b->addr_string = strsave (buf);
+
+ /* now send notification command back to GUI */
+
+ Tcl_DStringInit (&cmd);
+
+ Tcl_DStringAppend (&cmd, "gdbtk_tcl_breakpoint create ", -1);
+ sprintf (buf, "%d", b->number);
+ Tcl_DStringAppendElement (&cmd, buf);
+ sprintf (buf, "0x%lx", (long) sal.pc);
+ Tcl_DStringAppendElement (&cmd, buf);
+ Tcl_DStringAppendElement (&cmd, Tcl_GetStringFromObj (objv[2], NULL));
+ Tcl_DStringAppendElement (&cmd, Tcl_GetStringFromObj (objv[1], NULL));
+ Tcl_DStringAppendElement (&cmd, bpdisp[b->disposition]);
+ sprintf (buf, "%d", b->enable);
+ Tcl_DStringAppendElement (&cmd, buf);
+ sprintf (buf, "%d", b->thread);
+ Tcl_DStringAppendElement (&cmd, buf);
+
+
+ ret = Tcl_Eval (interp, Tcl_DStringValue (&cmd));
+ Tcl_DStringFree (&cmd);
+ return ret;
}
-
-/*
- * This section has utility routines that are not Tcl commands.
+
+/* This implements the tcl command "gdb_set_bp_addr"
+ * It sets breakpoints, and runs the Tcl command
+ * gdbtk_tcl_breakpoint create
+ * to register the new breakpoint with the GUI.
+ *
+ * Tcl Arguments:
+ * addr: the address at which to set the breakpoint
+ * type: the type of the breakpoint
+ * thread: optional thread number
+ * Tcl Result:
+ * The return value of the call to gdbtk_tcl_breakpoint.
*/
static int
-perror_with_name_wrapper (PTR args)
+gdb_set_bp_addr (clientData, interp, objc, objv)
+ ClientData clientData;
+ Tcl_Interp *interp;
+ int objc;
+ Tcl_Obj *CONST objv[];
+
{
- perror_with_name (args);
- return 1;
+ struct symtab_and_line sal;
+ int line, ret, thread = -1;
+ long addr;
+ struct breakpoint *b;
+ char *filename, *typestr, buf[64];
+ Tcl_DString cmd;
+ enum bpdisp disp;
+
+ if (objc != 4 && objc != 3)
+ {
+ Tcl_SetStringObj (result_ptr->obj_ptr,
+ "wrong number of args, should be \"address type [thread]\"", -1);
+ return TCL_ERROR;
+ }
+
+ if (Tcl_GetLongFromObj (interp, objv[1], &addr) == TCL_ERROR)
+ {
+ result_ptr->flags = GDBTK_IN_TCL_RESULT;
+ return TCL_ERROR;
+ }
+
+ typestr = Tcl_GetStringFromObj (objv[2], NULL);
+ if (typestr == NULL)
+ {
+ result_ptr->flags = GDBTK_IN_TCL_RESULT;
+ return TCL_ERROR;
+ }
+ if (strncmp (typestr, "temp", 4) == 0)
+ disp = del;
+ else if (strncmp (typestr, "normal", 6) == 0)
+ disp = donttouch;
+ else
+ {
+ Tcl_SetStringObj (result_ptr->obj_ptr,
+ "type must be \"temp\" or \"normal\"", -1);
+ return TCL_ERROR;
+ }
+
+ if (objc == 4)
+ {
+ if (Tcl_GetIntFromObj (interp, objv[3], &thread) == TCL_ERROR)
+ {
+ result_ptr->flags = GDBTK_IN_TCL_RESULT;
+ return TCL_ERROR;
+ }
+ }
+
+ sal = find_pc_line (addr, 0);
+ sal.pc = addr;
+ b = set_raw_breakpoint (sal);
+ set_breakpoint_count (breakpoint_count + 1);
+ b->number = breakpoint_count;
+ b->type = bp_breakpoint;
+ b->disposition = disp;
+ b->thread = thread;
+
+ sprintf (buf, "*(0x%lx)", addr);
+ b->addr_string = strsave (buf);
+
+ /* now send notification command back to GUI */
+
+ Tcl_DStringInit (&cmd);
+
+ Tcl_DStringAppend (&cmd, "gdbtk_tcl_breakpoint create ", -1);
+ sprintf (buf, "%d", b->number);
+ Tcl_DStringAppendElement (&cmd, buf);
+ sprintf (buf, "0x%lx", addr);
+ Tcl_DStringAppendElement (&cmd, buf);
+ sprintf (buf, "%d", b->line_number);
+ Tcl_DStringAppendElement (&cmd, buf);
+
+ filename = symtab_to_filename (sal.symtab);
+ if (filename == NULL)
+ filename = "";
+ Tcl_DStringAppendElement (&cmd, filename);
+ Tcl_DStringAppendElement (&cmd, bpdisp[b->disposition]);
+ sprintf (buf, "%d", b->enable);
+ Tcl_DStringAppendElement (&cmd, buf);
+ sprintf (buf, "%d", b->thread);
+ Tcl_DStringAppendElement (&cmd, buf);
+
+ ret = Tcl_Eval (interp, Tcl_DStringValue (&cmd));
+ Tcl_DStringFree (&cmd);
+ return ret;
}
-/* Look for the function that contains PC and return the source
- (demangled) name for this function.
+/* This implements the tcl command "gdb_find_bp_at_line"
+
+ * Tcl Arguments:
+ * filename: the file in which to find the breakpoint
+ * line: the line number for the breakpoint
+ * Tcl Result:
+ * It returns a list of breakpoint numbers
+ */
+
+static int
+gdb_find_bp_at_line (clientData, interp, objc, objv)
+ ClientData clientData;
+ Tcl_Interp *interp;
+ int objc;
+ Tcl_Obj *CONST objv[];
- If no symbol is found, it returns an empty string. In either
- case, memory is owned by gdb. Do not attempt to free it. */
-char *
-pc_function_name (CORE_ADDR pc)
{
- struct symbol *sym;
- char *funcname = NULL;
+ struct symtab *s;
+ int line;
+ struct breakpoint *b;
+ extern struct breakpoint *breakpoint_chain;
- /* First lookup the address in the symbol table... */
- sym = find_pc_function (pc);
- if (sym != NULL)
- funcname = GDBTK_SYMBOL_SOURCE_NAME (sym);
- else
+ if (objc != 3)
{
- /* ... if that fails, look it up in the minimal symbols. */
- struct minimal_symbol *msym = NULL;
+ Tcl_WrongNumArgs (interp, 1, objv, "filename line");
+ return TCL_ERROR;
+ }
- msym = lookup_minimal_symbol_by_pc (pc);
- if (msym != NULL)
- funcname = GDBTK_SYMBOL_SOURCE_NAME (msym);
+ s = full_lookup_symtab (Tcl_GetStringFromObj (objv[1], NULL));
+ if (s == NULL)
+ return TCL_ERROR;
+
+ if (Tcl_GetIntFromObj (interp, objv[2], &line) == TCL_ERROR)
+ {
+ result_ptr->flags = GDBTK_IN_TCL_RESULT;
+ return TCL_ERROR;
}
- if (funcname == NULL)
- funcname = "";
+ Tcl_SetListObj (result_ptr->obj_ptr, 0, NULL);
+ for (b = breakpoint_chain; b; b = b->next)
+ if (b->line_number == line && !strcmp (b->source_file, s->filename))
+ Tcl_ListObjAppendElement (NULL, result_ptr->obj_ptr,
+ Tcl_NewIntObj (b->number));
- return funcname;
+ return TCL_OK;
}
-void
-gdbtk_set_result (Tcl_Interp *interp, const char *fmt,...)
+
+/* This implements the tcl command "gdb_find_bp_at_addr"
+
+ * Tcl Arguments:
+ * addr: address
+ * Tcl Result:
+ * It returns a list of breakpoint numbers
+ */
+
+static int
+gdb_find_bp_at_addr (clientData, interp, objc, objv)
+ ClientData clientData;
+ Tcl_Interp *interp;
+ int objc;
+ Tcl_Obj *CONST objv[];
+
{
- va_list args;
- char *buf;
+ long addr;
+ struct breakpoint *b;
+ extern struct breakpoint *breakpoint_chain;
+
+ if (objc != 2)
+ {
+ Tcl_WrongNumArgs (interp, 1, objv, "address");
+ return TCL_ERROR;
+ }
+
+ if (Tcl_GetLongFromObj (interp, objv[1], &addr) == TCL_ERROR)
+ {
+ result_ptr->flags = GDBTK_IN_TCL_RESULT;
+ return TCL_ERROR;
+ }
+
+ Tcl_SetListObj (result_ptr->obj_ptr, 0, NULL);
+ for (b = breakpoint_chain; b; b = b->next)
+ if (b->address == (CORE_ADDR) addr)
+ Tcl_ListObjAppendElement (NULL, result_ptr->obj_ptr,
+ Tcl_NewIntObj (b->number));
- va_start (args, fmt);
- xvasprintf (&buf, fmt, args);
- va_end (args);
- Tcl_SetObjResult (interp, Tcl_NewStringObj (buf, -1));
- xfree(buf);
+ return TCL_OK;
}
+/* This implements the tcl command gdb_get_breakpoint_info
+
+
+ * Tcl Arguments:
+ * breakpoint_number
+ * Tcl Result:
+ * A list with {file, function, line_number, address, type, enabled?,
+ * disposition, ignore_count, {list_of_commands},
+ * thread, hit_count}
+ */
+
+static int
+gdb_get_breakpoint_info (clientData, interp, objc, objv)
+ ClientData clientData;
+ Tcl_Interp *interp;
+ int objc;
+ Tcl_Obj *CONST objv[];
+{
+ struct symtab_and_line sal;
+ struct command_line *cmd;
+ int bpnum;
+ struct breakpoint *b;
+ extern struct breakpoint *breakpoint_chain;
+ char *funcname, *filename;
+ struct symbol *sym;
+ Tcl_Obj *new_obj;
+
+ if (objc != 2)
+ {
+ Tcl_SetStringObj (result_ptr->obj_ptr,
+ "wrong number of args, should be \"breakpoint\"", -1);
+ return TCL_ERROR;
+ }
+
+ if (Tcl_GetIntFromObj (NULL, objv[1], &bpnum) != TCL_OK)
+ {
+ result_ptr->flags = GDBTK_IN_TCL_RESULT;
+ return TCL_ERROR;
+ }
+
+ for (b = breakpoint_chain; b; b = b->next)
+ if (b->number == bpnum)
+ break;
+
+ if (!b || b->type != bp_breakpoint)
+ {
+ char err_buf[64];
+ sprintf (err_buf, "Breakpoint #%d does not exist.", bpnum);
+ Tcl_SetStringObj (result_ptr->obj_ptr, err_buf, -1);
+ return TCL_ERROR;
+ }
+
+ sal = find_pc_line (b->address, 0);
+
+ filename = symtab_to_filename (sal.symtab);
+ if (filename == NULL)
+ filename = "";
+
+ Tcl_SetListObj (result_ptr->obj_ptr, 0, NULL);
+ Tcl_ListObjAppendElement (NULL, result_ptr->obj_ptr,
+ Tcl_NewStringObj (filename, -1));
+
+ funcname = pc_function_name (b->address);
+ new_obj = Tcl_NewStringObj (funcname, -1);
+ Tcl_ListObjAppendElement (NULL, result_ptr->obj_ptr, new_obj);
+
+ Tcl_ListObjAppendElement (NULL, result_ptr->obj_ptr,
+ Tcl_NewIntObj (b->line_number));
+ sprintf_append_element_to_obj (result_ptr->obj_ptr, "0x%s",
+ paddr_nz (b->address));
+ Tcl_ListObjAppendElement (NULL, result_ptr->obj_ptr,
+ Tcl_NewStringObj (bptypes[b->type], -1));
+ Tcl_ListObjAppendElement (NULL, result_ptr->obj_ptr,
+ Tcl_NewBooleanObj (b->enable == enabled));
+ Tcl_ListObjAppendElement (NULL, result_ptr->obj_ptr,
+ Tcl_NewStringObj (bpdisp[b->disposition], -1));
+ Tcl_ListObjAppendElement (NULL, result_ptr->obj_ptr,
+ Tcl_NewIntObj (b->ignore_count));
-/* This implements the tcl command 'gdb_incr_addr'.
- * It does address arithmetic and outputs a proper
- * hex string. This was originally implemented
- * when tcl did not support 64-bit values, but we keep
- * it because it saves us from having to call incr
- * followed by format to get the result in hex.
- * Also, it may be true in the future that CORE_ADDRs
- * will have their own ALU to deal properly with
- * architecture-specific address arithmetic.
+ new_obj = Tcl_NewObj ();
+ for (cmd = b->commands; cmd; cmd = cmd->next)
+ Tcl_ListObjAppendElement (NULL, new_obj,
+ Tcl_NewStringObj (cmd->line, -1));
+ Tcl_ListObjAppendElement (NULL, result_ptr->obj_ptr, new_obj);
+
+ Tcl_ListObjAppendElement (NULL, result_ptr->obj_ptr,
+ Tcl_NewStringObj (b->cond_string, -1));
+
+ Tcl_ListObjAppendElement (NULL, result_ptr->obj_ptr,
+ Tcl_NewIntObj (b->thread));
+ Tcl_ListObjAppendElement (NULL, result_ptr->obj_ptr,
+ Tcl_NewIntObj (b->hit_count));
+
+ return TCL_OK;
+}
+
+
+/* This implements the tcl command gdb_get_breakpoint_list
+ * It builds up a list of the current breakpoints.
*
* Tcl Arguments:
- * addr - CORE_ADDR
- * number - optional number to add to the address
- * default is 1.
+ * None.
+ * Tcl Result:
+ * A list of breakpoint numbers.
+ */
+
+static int
+gdb_get_breakpoint_list (clientData, interp, objc, objv)
+ ClientData clientData;
+ Tcl_Interp *interp;
+ int objc;
+ Tcl_Obj *CONST objv[];
+{
+ struct breakpoint *b;
+ extern struct breakpoint *breakpoint_chain;
+ Tcl_Obj *new_obj;
+
+ if (objc != 1)
+ error ("wrong number of args, none are allowed");
+
+ for (b = breakpoint_chain; b; b = b->next)
+ if (b->type == bp_breakpoint)
+ {
+ new_obj = Tcl_NewIntObj (b->number);
+ Tcl_ListObjAppendElement (NULL, result_ptr->obj_ptr, new_obj);
+ }
+
+ return TCL_OK;
+}
+
+/* The functions in this section deal with stacks and backtraces. */
+
+/* This implements the tcl command gdb_stack.
+ * It builds up a list of stack frames.
*
+ * Tcl Arguments:
+ * start - starting stack frame
+ * count - number of frames to inspect
* Tcl Result:
- * hex string containing the result of addr + number
+ * A list of function names
*/
static int
-gdb_incr_addr (ClientData clientData, Tcl_Interp *interp,
- int objc, Tcl_Obj *CONST objv[])
+gdb_stack (clientData, interp, objc, objv)
+ ClientData clientData;
+ Tcl_Interp *interp;
+ int objc;
+ Tcl_Obj *CONST objv[];
{
- CORE_ADDR address;
- int number = 1;
+ int start, count;
- if (objc != 2 && objc != 3)
+ if (objc < 3)
{
- Tcl_WrongNumArgs (interp, 1, objv, "CORE_ADDR [number]");
+ Tcl_WrongNumArgs (interp, 1, objv, "start count");
+ result_ptr->flags |= GDBTK_IN_TCL_RESULT;
return TCL_ERROR;
}
- address = string_to_core_addr (Tcl_GetStringFromObj (objv[1], NULL));
+ if (Tcl_GetIntFromObj (NULL, objv[1], &start))
+ {
+ result_ptr->flags |= GDBTK_IN_TCL_RESULT;
+ return TCL_ERROR;
+ }
+ if (Tcl_GetIntFromObj (NULL, objv[2], &count))
+ {
+ result_ptr->flags |= GDBTK_IN_TCL_RESULT;
+ return TCL_ERROR;
+ }
- if (objc == 3)
+ Tcl_SetListObj (result_ptr->obj_ptr, 0, NULL);
+
+ if (target_has_stack)
{
- if (Tcl_GetIntFromObj (interp, objv[2], &number) != TCL_OK)
- return TCL_ERROR;
+ struct frame_info *top;
+ struct frame_info *fi;
+
+ /* Find the outermost frame */
+ fi = get_current_frame ();
+ while (fi != NULL)
+ {
+ top = fi;
+ fi = get_prev_frame (fi);
+ }
+
+ /* top now points to the top (outermost frame) of the
+ stack, so point it to the requested start */
+ start = -start;
+ top = find_relative_frame (top, &start);
+
+ /* If start != 0, then we have asked to start outputting
+ frames beyond the innermost stack frame */
+ if (start == 0)
+ {
+ fi = top;
+ while (fi && count--)
+ {
+ get_frame_name (interp, result_ptr->obj_ptr, fi);
+ fi = get_next_frame (fi);
+ }
+ }
}
-
- address += number;
- Tcl_SetStringObj (result_ptr->obj_ptr, (char *)core_addr_to_string (address), -1);
-
return TCL_OK;
}
-/* This implements the tcl command 'gdb_CAS_to_TAS'.
- * It takes a CORE_ADDR and outputs a string suitable
- * for displaying as the target address.
+/* A helper function for get_stack which adds information about
+ * the stack frame FI to the caller's LIST.
+ *
+ * This is stolen from print_frame_info in stack.c.
+ */
+static void
+get_frame_name (interp, list, fi)
+ Tcl_Interp *interp;
+ Tcl_Obj *list;
+ struct frame_info *fi;
+{
+ struct symtab_and_line sal;
+ struct symbol *func = NULL;
+ register char *funname = 0;
+ enum language funlang = language_unknown;
+ Tcl_Obj *objv[1];
+
+ if (frame_in_dummy (fi))
+ {
+ objv[0] = Tcl_NewStringObj ("<function called from gdb>\n", -1);
+ Tcl_ListObjAppendElement (interp, list, objv[0]);
+ return;
+ }
+ if (fi->signal_handler_caller)
+ {
+ objv[0] = Tcl_NewStringObj ("<signal handler called>\n", -1);
+ Tcl_ListObjAppendElement (interp, list, objv[0]);
+ return;
+ }
+
+ sal =
+ find_pc_line (fi->pc,
+ fi->next != NULL
+ && !fi->next->signal_handler_caller
+ && !frame_in_dummy (fi->next));
+
+ func = find_pc_function (fi->pc);
+ if (func)
+ {
+ struct minimal_symbol *msymbol = lookup_minimal_symbol_by_pc (fi->pc);
+ if (msymbol != NULL
+ && (SYMBOL_VALUE_ADDRESS (msymbol)
+ > BLOCK_START (SYMBOL_BLOCK_VALUE (func))))
+ {
+ func = 0;
+ funname = GDBTK_SYMBOL_SOURCE_NAME (msymbol);
+ funlang = SYMBOL_LANGUAGE (msymbol);
+ }
+ else
+ {
+ funname = GDBTK_SYMBOL_SOURCE_NAME (func);
+ funlang = SYMBOL_LANGUAGE (func);
+ }
+ }
+ else
+ {
+ struct minimal_symbol *msymbol = lookup_minimal_symbol_by_pc (fi->pc);
+ if (msymbol != NULL)
+ {
+ funname = GDBTK_SYMBOL_SOURCE_NAME (msymbol);
+ funlang = SYMBOL_LANGUAGE (msymbol);
+ }
+ }
+
+ if (sal.symtab)
+ {
+ char *name = NULL;
+
+ objv[0] = Tcl_NewStringObj (funname, -1);
+ Tcl_ListObjAppendElement (interp, list, objv[0]);
+ }
+ else
+ {
+#if 0
+ /* we have no convenient way to deal with this yet... */
+ if (fi->pc != sal.pc || !sal.symtab)
+ {
+ print_address_numeric (fi->pc, 1, gdb_stdout);
+ printf_filtered (" in ");
+ }
+ printf_symbol_filtered (gdb_stdout, funname ? funname : "??", funlang,
+ DMGL_ANSI);
+#endif
+ objv[0] = Tcl_NewStringObj (funname != NULL ? funname : "??", -1);
+#ifdef PC_LOAD_SEGMENT
+ /* If we couldn't print out function name but if can figure out what
+ load segment this pc value is from, at least print out some info
+ about its load segment. */
+ if (!funname)
+ {
+ Tcl_AppendStringsToObj (objv[0], " from ", PC_LOAD_SEGMENT (fi->pc),
+ (char *) NULL);
+ }
+#endif
+#ifdef PC_SOLIB
+ if (!funname)
+ {
+ char *lib = PC_SOLIB (fi->pc);
+ if (lib)
+ {
+ Tcl_AppendStringsToObj (objv[0], " from ", lib, (char *) NULL);
+ }
+ }
+#endif
+ Tcl_ListObjAppendElement (interp, list, objv[0]);
+ }
+}
+
+/* This implements the tcl command gdb_selected_frame
+
+ * Returns the address of the selected frame
+ * frame.
+ *
+ * Arguments:
+ * None
+ * Tcl Result:
+ * The currently selected frame's address
+ */
+
+static int
+gdb_selected_frame (clientData, interp, objc, objv)
+ ClientData clientData;
+ Tcl_Interp *interp;
+ int objc;
+ Tcl_Obj *CONST objv[];
+{
+ char frame[32];
+
+ if (selected_frame == NULL)
+ strcpy (frame, "");
+ else
+ sprintf (frame, "0x%s", paddr_nz (FRAME_FP (selected_frame)));
+
+ Tcl_SetStringObj (result_ptr->obj_ptr, frame, -1);
+
+ return TCL_OK;
+}
+
+/* This implements the tcl command gdb_selected_block
*
- * Note that CORE_ADDRs are internal addresses which map
- * to target addresses in different ways depending on the
- * architecture. The target address string is a user-readable
- * string may be quite different than the CORE_ADDR. For example,
- * a CORE_ADDR of 0x02001234 might indicate a data address of
- * 0x1234 which this function might someday output as something
- * like "D:1234".
+ * Returns the start and end addresses of the innermost
+ * block in the selected frame.
*
- * Tcl Arguments:
- * address - CORE_ADDR
+ * Arguments:
+ * None
+ * Tcl Result:
+ * The currently selected block's start and end addresses
+ */
+
+static int
+gdb_selected_block (clientData, interp, objc, objv)
+ ClientData clientData;
+ Tcl_Interp *interp;
+ int objc;
+ Tcl_Obj *CONST objv[];
+{
+ char start[32];
+ char end[32];
+
+ if (selected_frame == NULL)
+ {
+ strcpy (start, "");
+ strcpy (end, "");
+ }
+ else
+ {
+ struct block *block;
+ block = get_frame_block (selected_frame);
+ sprintf (start, "0x%s", paddr_nz (BLOCK_START (block)));
+ sprintf (end, "0x%s", paddr_nz (BLOCK_END (block)));
+ }
+
+ Tcl_SetListObj (result_ptr->obj_ptr, 0, NULL);
+ Tcl_ListObjAppendElement (interp, result_ptr->obj_ptr,
+ Tcl_NewStringObj (start, -1));
+ Tcl_ListObjAppendElement (interp, result_ptr->obj_ptr,
+ Tcl_NewStringObj (end, -1));
+
+ return TCL_OK;
+}
+
+/* This implements the tcl command gdb_get_blocks
*
+ * Returns the start and end addresses for all blocks in
+ * the selected frame.
+ *
+ * Arguments:
+ * None
* Tcl Result:
- * string
+ * A list of all valid blocks in the selected_frame.
*/
static int
-gdb_CA_to_TAS (ClientData clientData, Tcl_Interp *interp,
- int objc, Tcl_Obj *CONST objv[])
+gdb_get_blocks (clientData, interp, objc, objv)
+ ClientData clientData;
+ Tcl_Interp *interp;
+ int objc;
+ Tcl_Obj *CONST objv[];
{
- CORE_ADDR address;
- Tcl_WideInt wide_addr;
+ struct block *block;
+ int nsyms, i, junk;
+ struct symbol *sym;
+ CORE_ADDR pc;
- if (objc != 2)
+ Tcl_SetListObj (result_ptr->obj_ptr, 0, NULL);
+
+ if (selected_frame != NULL)
{
- Tcl_WrongNumArgs (interp, 1, objv, "CORE_ADDR");
+ block = get_frame_block (selected_frame);
+ pc = get_frame_pc (selected_frame);
+ while (block != 0)
+ {
+ nsyms = BLOCK_NSYMS (block);
+ junk = 0;
+ for (i = 0; i < nsyms; i++)
+ {
+ sym = BLOCK_SYM (block, i);
+ switch (SYMBOL_CLASS (sym))
+ {
+ default:
+ case LOC_UNDEF: /* catches errors */
+ case LOC_CONST: /* constant */
+ case LOC_TYPEDEF: /* local typedef */
+ case LOC_LABEL: /* local label */
+ case LOC_BLOCK: /* local function */
+ case LOC_CONST_BYTES: /* loc. byte seq. */
+ case LOC_UNRESOLVED: /* unresolved static */
+ case LOC_OPTIMIZED_OUT: /* optimized out */
+ junk = 1;
+ break;
+
+ case LOC_ARG: /* argument */
+ case LOC_REF_ARG: /* reference arg */
+ case LOC_REGPARM: /* register arg */
+ case LOC_REGPARM_ADDR: /* indirect register arg */
+ case LOC_LOCAL_ARG: /* stack arg */
+ case LOC_BASEREG_ARG: /* basereg arg */
+
+ case LOC_LOCAL: /* stack local */
+ case LOC_BASEREG: /* basereg local */
+ case LOC_STATIC: /* static */
+ case LOC_REGISTER: /* register */
+ junk = 0;
+ break;
+ }
+ }
+
+ /* If we found a block with locals in it, add it to the list.
+ Note that the ranges of start and end address for blocks
+ are exclusive, so double-check against the PC */
+
+ if (!junk && pc < BLOCK_END (block))
+ {
+ char addr[32];
+
+ Tcl_Obj *elt = Tcl_NewListObj (0, NULL);
+ sprintf (addr, "0x%s", paddr_nz (BLOCK_START (block)));
+ Tcl_ListObjAppendElement (interp, elt,
+ Tcl_NewStringObj (addr, -1));
+ sprintf (addr, "0x%s", paddr_nz (BLOCK_END (block)));
+ Tcl_ListObjAppendElement (interp, elt,
+ Tcl_NewStringObj (addr, -1));
+ Tcl_ListObjAppendElement (interp, result_ptr->obj_ptr, elt);
+ }
+
+ if (BLOCK_FUNCTION (block))
+ break;
+ else
+ block = BLOCK_SUPERBLOCK (block);
+ }
+ }
+
+ return TCL_OK;
+}
+
+/* This implements the tcl command gdb_block_vars.
+ *
+ * Returns all variables valid in the specified block.
+ *
+ * Arguments:
+ * The start and end addresses which identify the block.
+ * Tcl Result:
+ * All variables defined in the given block.
+ */
+
+static int
+gdb_block_vars (clientData, interp, objc, objv)
+ ClientData clientData;
+ Tcl_Interp *interp;
+ int objc;
+ Tcl_Obj *CONST objv[];
+{
+ struct block *block;
+ int nsyms, i;
+ struct symbol *sym;
+ CORE_ADDR start, end;
+
+ if (objc < 3)
+ {
+ Tcl_WrongNumArgs (interp, 1, objv, "startAddr endAddr");
+ result_ptr->flags |= GDBTK_IN_TCL_RESULT;
return TCL_ERROR;
}
- /* Read address into a wideint, which is the largest tcl supports
- then convert to a CORE_ADDR */
- if (Tcl_GetWideIntFromObj (interp, objv[1], &wide_addr) != TCL_OK)
- return TCL_ERROR;
- address = wide_addr;
+ Tcl_SetListObj (result_ptr->obj_ptr, 0, NULL);
+ if (selected_frame == NULL)
+ return TCL_OK;
- /* This is not really correct. Using paddr_nz() will convert to hex and truncate
- to 32-bits when required but will otherwise not do what we really want. */
- Tcl_SetStringObj (result_ptr->obj_ptr, paddr_nz (address), -1);
+ start = parse_and_eval_address (Tcl_GetStringFromObj (objv[1], NULL));
+ end = parse_and_eval_address (Tcl_GetStringFromObj (objv[2], NULL));
+
+ block = get_frame_block (selected_frame);
+
+ while (block != 0)
+ {
+ if (BLOCK_START (block) == start && BLOCK_END (block) == end)
+ {
+ nsyms = BLOCK_NSYMS (block);
+ for (i = 0; i < nsyms; i++)
+ {
+ sym = BLOCK_SYM (block, i);
+ switch (SYMBOL_CLASS (sym))
+ {
+ case LOC_ARG: /* argument */
+ case LOC_REF_ARG: /* reference arg */
+ case LOC_REGPARM: /* register arg */
+ case LOC_REGPARM_ADDR: /* indirect register arg */
+ case LOC_LOCAL_ARG: /* stack arg */
+ case LOC_BASEREG_ARG: /* basereg arg */
+ case LOC_LOCAL: /* stack local */
+ case LOC_BASEREG: /* basereg local */
+ case LOC_STATIC: /* static */
+ case LOC_REGISTER: /* register */
+ Tcl_ListObjAppendElement (interp, result_ptr->obj_ptr,
+ Tcl_NewStringObj (SYMBOL_NAME (sym),
+ -1));
+ break;
+
+ default:
+ break;
+ }
+ }
+
+ return TCL_OK;
+ }
+ else if (BLOCK_FUNCTION (block))
+ break;
+ else
+ block = BLOCK_SUPERBLOCK (block);
+ }
return TCL_OK;
}
+
+/*
+ * This section contains a bunch of miscellaneous utility commands
+ */
-/* Another function that was removed in GDB and replaced
- * with something similar, but different enough to break
- * Insight.
+/* This implements the tcl command gdb_path_conv
+
+ * On Windows, it canonicalizes the pathname,
+ * On Unix, it is a no op.
+ *
+ * Arguments:
+ * path
+ * Tcl Result:
+ * The canonicalized path.
*/
-char *
-symtab_to_filename (struct symtab *s)
+
+static int
+gdb_path_conv (clientData, interp, objc, objv)
+ ClientData clientData;
+ Tcl_Interp *interp;
+ int objc;
+ Tcl_Obj *CONST objv[];
{
- int r;
+ if (objc != 2)
+ error ("wrong # args");
+
+#ifdef __CYGWIN__
+ {
+ char pathname[256], *ptr;
- if (!s)
+ cygwin32_conv_to_full_win32_path (Tcl_GetStringFromObj (objv[1], NULL),
+ pathname);
+ for (ptr = pathname; *ptr; ptr++)
+ {
+ if (*ptr == '\\')
+ *ptr = '/';
+ }
+ Tcl_SetStringObj (result_ptr->obj_ptr, pathname, -1);
+ }
+#else
+ Tcl_SetStringObj (result_ptr->obj_ptr, Tcl_GetStringFromObj (objv[1], NULL),
+ -1);
+#endif
+
+ return TCL_OK;
+}
+
+/*
+ * This section has utility routines that are not Tcl commands.
+ */
+
+static int
+perror_with_name_wrapper (args)
+ PTR args;
+{
+ perror_with_name (args);
+ return 1;
+}
+
+/* The lookup_symtab() in symtab.c doesn't work correctly */
+/* It will not work will full pathnames and if multiple */
+/* source files have the same basename, it will return */
+/* the first one instead of the correct one. This version */
+/* also always makes sure symtab->fullname is set. */
+
+static struct symtab *
+full_lookup_symtab (file)
+ char *file;
+{
+ struct symtab *st;
+ struct objfile *objfile;
+ char *bfile, *fullname;
+ struct partial_symtab *pt;
+
+ if (!file)
return NULL;
- /* Don't check s->fullname here, the file could have been
- deleted/moved/..., look for it again */
- r = open_source_file (s);
- if (r)
- close (r);
+ /* first try a direct lookup */
+ st = lookup_symtab (file);
+ if (st)
+ {
+ if (!st->fullname)
+ symtab_to_filename (st);
+ return st;
+ }
+
+ /* if the direct approach failed, try */
+ /* looking up the basename and checking */
+ /* all matches with the fullname */
+ bfile = basename (file);
+ ALL_SYMTABS (objfile, st)
+ {
+ if (!strcmp (bfile, basename (st->filename)))
+ {
+ if (!st->fullname)
+ fullname = symtab_to_filename (st);
+ else
+ fullname = st->fullname;
+
+ if (!strcmp (file, fullname))
+ return st;
+ }
+ }
- if (s->fullname && *s->fullname)
- return s->fullname;
- return s->filename;
+ /* still no luck? look at psymtabs */
+ ALL_PSYMTABS (objfile, pt)
+ {
+ if (!strcmp (bfile, basename (pt->filename)))
+ {
+ st = PSYMTAB_TO_SYMTAB (pt);
+ if (st)
+ {
+ fullname = symtab_to_filename (st);
+ if (!strcmp (file, fullname))
+ return st;
+ }
+ }
+ }
+ return NULL;
}
+
+/* Look for the function that contains PC and return the source
+ (demangled) name for this function.
+
+ If no symbol is found, it returns an empty string. In either
+ case, memory is owned by gdb. Do not attempt to free it. */
+char *
+pc_function_name (pc)
+ CORE_ADDR pc;
+{
+ struct symbol *sym;
+ char *funcname = NULL;
+
+ /* First lookup the address in the symbol table... */
+ sym = find_pc_function (pc);
+ if (sym != NULL)
+ funcname = GDBTK_SYMBOL_SOURCE_NAME (sym);
+ else
+ {
+ /* ... if that fails, look it up in the minimal symbols. */
+ struct minimal_symbol *msym = NULL;
+
+ msym = lookup_minimal_symbol_by_pc (pc);
+ if (msym != NULL)
+ funcname = GDBTK_SYMBOL_SOURCE_NAME (msym);
+ }
+
+ if (funcname == NULL)
+ funcname = "";
+
+ return funcname;
+}
+
+static void
+setup_architecture_data ()
+{
+ /* don't trust REGISTER_BYTES to be zero. */
+ old_regs = xmalloc (REGISTER_BYTES + 1);
+ memset (old_regs, 0, REGISTER_BYTES + 1);
+}
+
+
+/* Local variables: */
+/* change-log-default-name: "ChangeLog-gdbtk" */
+/* End: */
diff --git a/gdb/gdbtk/generic/gdbtk-hooks.c b/gdb/gdbtk/generic/gdbtk-hooks.c
index cf7403469a4..3f0462bb181 100644
--- a/gdb/gdbtk/generic/gdbtk-hooks.c
+++ b/gdb/gdbtk/generic/gdbtk-hooks.c
@@ -1,7 +1,5 @@
-/* Startup code for Insight.
-
- Copyright (C) 1994, 1995, 1996, 1997, 1998, 2000, 200, 2002, 2003, 2004, 2008
- Free Software Foundation, Inc.
+/* Startup code for gdbtk.
+ Copyright 1994-1998, 2000 Free Software Foundation, Inc.
Written by Stu Grossman <grossman@cygnus.com> of Cygnus Support.
@@ -19,47 +17,47 @@
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
- Foundation, Inc., 51 Franklin Street, Fifth Floor,
- Boston, MA 02110-1301, USA. */
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
#include "defs.h"
+#include "symtab.h"
#include "inferior.h"
+#include "command.h"
+#include "bfd.h"
#include "symfile.h"
#include "objfiles.h"
+#include "target.h"
#include "gdbcore.h"
#include "tracepoint.h"
#include "demangle.h"
-#include "top.h"
-#include "annotate.h"
-#include "cli/cli-decode.h"
-#include "observer.h"
#ifdef _WIN32
#define WIN32_LEAN_AND_MEAN
#include <windows.h>
#endif
-/* tcl header files includes varargs.h unless HAS_STDARG is defined,
- but gdb uses stdarg.h, so make sure HAS_STDARG is defined. */
-#define HAS_STDARG 1
+#include <sys/stat.h>
-#include <itcl.h>
#include <tcl.h>
#include <tk.h>
+#include <itcl.h>
+#include <tix.h>
#include "guitcl.h"
#include "gdbtk.h"
+#include <stdarg.h>
#include <signal.h>
#include <fcntl.h>
-#ifdef HAVE_SYS_IOCTL_H
+#include "top.h"
#include <sys/ioctl.h>
-#endif
-#include <sys/time.h>
-
#include "gdb_string.h"
#include "dis-asm.h"
+#include <stdio.h>
#include "gdbcmd.h"
+#include "annotate.h"
+#include <sys/time.h>
volatile int in_fputs = 0;
@@ -67,38 +65,42 @@ volatile int in_fputs = 0;
that it should forcibly detach from the target. */
int gdbtk_force_detach = 0;
-/* From gdbtk-bp.c */
-extern void gdbtk_create_breakpoint (int);
-extern void gdbtk_delete_breakpoint (int);
-extern void gdbtk_modify_breakpoint (int);
-extern void gdbtk_create_tracepoint (int);
-extern void gdbtk_delete_tracepoint (int);
-extern void gdbtk_modify_tracepoint (int);
-
-static void gdbtk_architecture_changed (struct gdbarch *);
-static void gdbtk_trace_find (char *arg, int from_tty);
-static void gdbtk_trace_start_stop (int, int);
-static void gdbtk_attach (void);
-static void gdbtk_detach (void);
-static void gdbtk_file_changed (char *);
-static void gdbtk_exec_file_display (char *);
-static void gdbtk_call_command (struct cmd_list_element *, char *, int);
-static ptid_t gdbtk_wait (ptid_t, struct target_waitstatus *);
-int x_event (int);
-static int gdbtk_query (const char *, va_list);
-static void gdbtk_warning (const char *, va_list);
-static char *gdbtk_readline (char *);
+extern void (*pre_add_symbol_hook) PARAMS ((char *));
+extern void (*post_add_symbol_hook) PARAMS ((void));
+extern void (*selected_frame_level_changed_hook) PARAMS ((int));
+extern int (*ui_loop_hook) PARAMS ((int));
+
+static void gdbtk_create_tracepoint PARAMS ((struct tracepoint *));
+static void gdbtk_delete_tracepoint PARAMS ((struct tracepoint *));
+static void gdbtk_modify_tracepoint PARAMS ((struct tracepoint *));
+static void gdbtk_trace_find PARAMS ((char *arg, int from_tty));
+static void gdbtk_trace_start_stop PARAMS ((int, int));
+static void gdbtk_create_breakpoint PARAMS ((struct breakpoint *));
+static void gdbtk_delete_breakpoint PARAMS ((struct breakpoint *));
+static void gdbtk_modify_breakpoint PARAMS ((struct breakpoint *));
+static void gdbtk_attach PARAMS ((void));
+static void gdbtk_detach PARAMS ((void));
+static void gdbtk_file_changed PARAMS ((char *));
+static void gdbtk_exec_file_display PARAMS ((char *));
+static void tk_command_loop PARAMS ((void));
+static void gdbtk_call_command PARAMS ((struct cmd_list_element *, char *, int));
+static int gdbtk_wait PARAMS ((int, struct target_waitstatus *));
+int x_event PARAMS ((int));
+static int gdbtk_query PARAMS ((const char *, va_list));
+static void gdbtk_warning PARAMS ((const char *, va_list));
+static char *gdbtk_readline PARAMS ((char *));
static void gdbtk_readline_begin (char *format,...);
-static void gdbtk_readline_end (void);
-static void gdbtk_pre_add_symbol (const char *);
-static void gdbtk_print_frame_info (struct symtab *, int, int, int);
-static void gdbtk_post_add_symbol (void);
-static void gdbtk_register_changed (int regno);
-static void gdbtk_memory_changed (CORE_ADDR addr, int len);
-static void gdbtk_selected_frame_changed (int);
-static void gdbtk_context_change (int);
-static void gdbtk_error_begin (void);
-void report_error (void);
+static void gdbtk_readline_end PARAMS ((void));
+static void gdbtk_pre_add_symbol PARAMS ((char *));
+static void gdbtk_print_frame_info PARAMS ((struct symtab *, int, int, int));
+static void gdbtk_post_add_symbol PARAMS ((void));
+static void gdbtk_register_changed PARAMS ((int regno));
+static void gdbtk_memory_changed PARAMS ((CORE_ADDR addr, int len));
+static void tracepoint_notify PARAMS ((struct tracepoint *, const char *));
+static void gdbtk_selected_frame_changed PARAMS ((int));
+static void gdbtk_context_change PARAMS ((int));
+static void gdbtk_error_begin PARAMS ((void));
+static void report_error (void);
static void gdbtk_annotate_signal (void);
static void gdbtk_set_hook (struct cmd_list_element *cmdblk);
@@ -107,11 +109,9 @@ static void gdbtk_set_hook (struct cmd_list_element *cmdblk);
* See note there for details.
*/
-long gdbtk_read (struct ui_file *, char *, long);
void gdbtk_fputs (const char *, struct ui_file *);
static int gdbtk_load_hash (const char *, unsigned long);
-
-static ptid_t gdbtk_ptid;
+static void breakpoint_notify PARAMS ((struct breakpoint *, const char *));
/*
* gdbtk_add_hooks - add all the hooks to gdb. This will get called by the
@@ -121,51 +121,48 @@ static ptid_t gdbtk_ptid;
void
gdbtk_add_hooks (void)
{
- /* Gdb observers */
- observer_attach_breakpoint_created (gdbtk_create_breakpoint);
- observer_attach_breakpoint_modified (gdbtk_modify_breakpoint);
- observer_attach_breakpoint_deleted (gdbtk_delete_breakpoint);
- observer_attach_tracepoint_created (gdbtk_create_tracepoint);
- observer_attach_tracepoint_modified (gdbtk_modify_tracepoint);
- observer_attach_tracepoint_deleted (gdbtk_delete_tracepoint);
- observer_attach_architecture_changed (gdbtk_architecture_changed);
+ command_loop_hook = tk_command_loop;
+ call_command_hook = gdbtk_call_command;
+ set_hook = gdbtk_set_hook;
+ readline_begin_hook = gdbtk_readline_begin;
+ readline_hook = gdbtk_readline;
+ readline_end_hook = gdbtk_readline_end;
- /* Hooks */
- deprecated_call_command_hook = gdbtk_call_command;
- deprecated_set_hook = gdbtk_set_hook;
- deprecated_readline_begin_hook = gdbtk_readline_begin;
- deprecated_readline_hook = gdbtk_readline;
- deprecated_readline_end_hook = gdbtk_readline_end;
+ print_frame_info_listing_hook = gdbtk_print_frame_info;
+ query_hook = gdbtk_query;
+ warning_hook = gdbtk_warning;
- deprecated_print_frame_info_listing_hook = gdbtk_print_frame_info;
- deprecated_query_hook = gdbtk_query;
- deprecated_warning_hook = gdbtk_warning;
+ create_breakpoint_hook = gdbtk_create_breakpoint;
+ delete_breakpoint_hook = gdbtk_delete_breakpoint;
+ modify_breakpoint_hook = gdbtk_modify_breakpoint;
- deprecated_interactive_hook = gdbtk_interactive;
- deprecated_target_wait_hook = gdbtk_wait;
- deprecated_ui_load_progress_hook = gdbtk_load_hash;
+ interactive_hook = gdbtk_interactive;
+ target_wait_hook = gdbtk_wait;
+ ui_load_progress_hook = gdbtk_load_hash;
- deprecated_ui_loop_hook = x_event;
- deprecated_pre_add_symbol_hook = gdbtk_pre_add_symbol;
- deprecated_post_add_symbol_hook = gdbtk_post_add_symbol;
- deprecated_file_changed_hook = gdbtk_file_changed;
- specify_exec_file_hook (gdbtk_exec_file_display);
+ ui_loop_hook = x_event;
+ pre_add_symbol_hook = gdbtk_pre_add_symbol;
+ post_add_symbol_hook = gdbtk_post_add_symbol;
+ file_changed_hook = gdbtk_file_changed;
+ exec_file_display_hook = gdbtk_exec_file_display;
- deprecated_trace_find_hook = gdbtk_trace_find;
- deprecated_trace_start_stop_hook = gdbtk_trace_start_stop;
+ create_tracepoint_hook = gdbtk_create_tracepoint;
+ delete_tracepoint_hook = gdbtk_delete_tracepoint;
+ modify_tracepoint_hook = gdbtk_modify_tracepoint;
+ trace_find_hook = gdbtk_trace_find;
+ trace_start_stop_hook = gdbtk_trace_start_stop;
- deprecated_attach_hook = gdbtk_attach;
- deprecated_detach_hook = gdbtk_detach;
+ attach_hook = gdbtk_attach;
+ detach_hook = gdbtk_detach;
- deprecated_register_changed_hook = gdbtk_register_changed;
- deprecated_memory_changed_hook = gdbtk_memory_changed;
- deprecated_selected_frame_level_changed_hook = gdbtk_selected_frame_changed;
- deprecated_context_hook = gdbtk_context_change;
+ register_changed_hook = gdbtk_register_changed;
+ memory_changed_hook = gdbtk_memory_changed;
+ selected_frame_level_changed_hook = gdbtk_selected_frame_changed;
+ context_hook = gdbtk_context_change;
- deprecated_error_begin_hook = gdbtk_error_begin;
+ error_begin_hook = gdbtk_error_begin;
- deprecated_annotate_signal_hook = gdbtk_annotate_signal;
- deprecated_annotate_signalled_hook = gdbtk_annotate_signal;
+ annotate_signal_hook = gdbtk_annotate_signal;
}
/* These control where to put the gdb output which is created by
@@ -183,21 +180,14 @@ gdbtk_add_hooks (void)
instead of to the result_ptr.
* GDBTK_MAKES_LIST flag means add to the result as a list element.
-*/
+ */
gdbtk_result *result_ptr = NULL;
-
-/* If you want to restore an old value of result_ptr whenever cleanups
- are run, pass this function to make_cleanup, along with the value
- of result_ptr you'd like to reinstate. */
-void
-gdbtk_restore_result_ptr (void *old_result_ptr)
-{
- result_ptr = (gdbtk_result *) old_result_ptr;
-}
+
/* This allows you to Tcl_Eval a tcl command which takes
a command word, and then a single argument. */
+
int
gdbtk_two_elem_cmd (cmd_name, argv1)
char *cmd_name;
@@ -221,58 +211,6 @@ gdbtk_two_elem_cmd (cmd_name, argv1)
return result;
}
-struct ui_file *
-gdbtk_fileopenin (void)
-{
- struct ui_file *file = ui_file_new ();
- set_ui_file_read (file, gdbtk_read);
- return file;
-}
-
-struct ui_file *
-gdbtk_fileopen (void)
-{
- struct ui_file *file = ui_file_new ();
- set_ui_file_fputs (file, gdbtk_fputs);
- return file;
-}
-
-/* This handles input from the gdb console.
- */
-
-long
-gdbtk_read (struct ui_file *stream, char *buf, long sizeof_buf)
-{
- int result;
- size_t actual_len;
-
- if (stream == gdb_stdtargin)
- {
- result = Tcl_Eval (gdbtk_interp, "gdbtk_console_read");
- if (result != TCL_OK)
- {
- report_error ();
- actual_len = 0;
- }
- else
- actual_len = strlen (gdbtk_interp->result);
-
- /* Truncate the string if it is too big for the caller's buffer. */
- if (actual_len >= sizeof_buf)
- actual_len = sizeof_buf - 1;
-
- memcpy (buf, gdbtk_interp->result, actual_len);
- buf[actual_len] = '\0';
- return actual_len;
- }
- else
- {
- errno = EBADF;
- return 0;
- }
-}
-
-
/* This handles all the output from gdb. All the gdb printf_xxx functions
* eventually end up here. The output is either passed to the result_ptr
* where it will go to the result of some gdbtk command, or passed to the
@@ -294,18 +232,13 @@ gdbtk_read (struct ui_file *stream, char *buf, long sizeof_buf)
*/
void
-gdbtk_fputs (const char *ptr, struct ui_file *stream)
+gdbtk_fputs (ptr, stream)
+ const char *ptr;
+ struct ui_file *stream;
{
- if (gdbtk_disable_fputs)
- return;
-
in_fputs = 1;
- if (stream == gdb_stdlog)
- gdbtk_two_elem_cmd ("gdbtk_tcl_fputs_log", (char *) ptr);
- else if (stream == gdb_stdtarg)
- gdbtk_two_elem_cmd ("gdbtk_tcl_fputs_target", (char *) ptr);
- else if (result_ptr != NULL)
+ if (result_ptr != NULL)
{
if (result_ptr->flags & GDBTK_TO_RESULT)
{
@@ -345,12 +278,14 @@ gdbtk_fputs (const char *ptr, struct ui_file *stream)
*/
static void
-gdbtk_warning (const char *warning, va_list args)
+gdbtk_warning (warning, args)
+ const char *warning;
+ va_list args;
{
- char *buf;
- xvasprintf (&buf, warning, args);
+ char buf[200];
+
+ vsprintf (buf, warning, args);
gdbtk_two_elem_cmd ("gdbtk_tcl_warning", buf);
- free(buf);
}
@@ -363,7 +298,7 @@ gdbtk_warning (const char *warning, va_list args)
/* pop up a messagebox, or it can silently log the errors through */
/* the gdbtk dbug command. */
-void
+static void
report_error ()
{
TclDebug ('E', Tcl_GetVar (gdbtk_interp, "errorInfo", TCL_GLOBAL_ONLY));
@@ -376,33 +311,71 @@ report_error ()
*/
void
-gdbtk_ignorable_warning (const char *class, const char *warning)
+gdbtk_ignorable_warning (class, warning)
+ const char *class;
+ const char *warning;
{
- char *buf;
- xasprintf (&buf, "gdbtk_tcl_ignorable_warning {%s} {%s}", class, warning);
+ char buf[512];
+ sprintf (buf, "gdbtk_tcl_ignorable_warning {%s} {%s}", class, warning);
if (Tcl_Eval (gdbtk_interp, buf) != TCL_OK)
report_error ();
- free(buf);
}
static void
-gdbtk_register_changed (int regno)
+gdbtk_register_changed (regno)
+ int regno;
{
if (Tcl_Eval (gdbtk_interp, "gdbtk_register_changed") != TCL_OK)
report_error ();
}
static void
-gdbtk_memory_changed (CORE_ADDR addr, int len)
+gdbtk_memory_changed (addr, len)
+ CORE_ADDR addr;
+ int len;
{
if (Tcl_Eval (gdbtk_interp, "gdbtk_memory_changed") != TCL_OK)
report_error ();
}
-/* This hook is installed as the deprecated_ui_loop_hook, which is
- * used in several places to keep the gui alive (x_event runs gdbtk's
- * event loop). Users include:
+/* This function is called instead of gdb's internal command loop. This is the
+ last chance to do anything before entering the main Tk event loop.
+ At the end of the command, we enter the main loop. */
+
+static void
+tk_command_loop ()
+{
+ extern FILE *instream;
+
+ /* We no longer want to use stdin as the command input stream */
+ instream = NULL;
+
+ if (Tcl_Eval (gdbtk_interp, "gdbtk_tcl_preloop") != TCL_OK)
+ {
+ char *msg;
+
+ /* Force errorInfo to be set up propertly. */
+ Tcl_AddErrorInfo (gdbtk_interp, "");
+
+ msg = Tcl_GetVar (gdbtk_interp, "errorInfo", TCL_GLOBAL_ONLY);
+#ifdef _WIN32
+ MessageBox (NULL, msg, NULL, MB_OK | MB_ICONERROR | MB_TASKMODAL);
+#else
+ fputs_unfiltered (msg, gdb_stderr);
+#endif
+ }
+
+#ifdef _WIN32
+ close_bfds ();
+#endif
+
+ Tk_MainLoop ();
+}
+
+/* This hook is installed as the ui_loop_hook, which is used in several
+ * places to keep the gui alive (x_event runs gdbtk's event loop). Users
+ * include:
* - ser-tcp.c in socket reading code
* - ser-unix.c in serial port reading code
* - built-in simulators while executing
@@ -412,11 +385,11 @@ gdbtk_memory_changed (CORE_ADDR addr, int len)
* to an elaborate scheme to keep the gui alive.
*
* For simulators and socket or serial connections on all hosts, we
- * rely on deprecated_ui_loop_hook (x_event) to keep us going. If the
- * user requests a detach (as a result of pressing the stop button --
- * see comments before gdb_stop in gdbtk-cmds.c), it sets the global
- * GDBTK_FORCE_DETACH, which is the value that x_event returns to it's
- * caller. It is up to the caller of x_event to act on this
+ * rely on ui_loop_hook (x_event) to keep us going. If the user
+ * requests a detach (as a result of pressing the stop button -- see
+ * comments before gdb_stop in gdbtk-cmds.c), it sets the global
+ * GDBTK_FORCE_DETACH, which is the value that x_event returns to
+ * it's caller. It is up to the caller of x_event to act on this
* information.
*
* For native unix, we simply set an interval timer which calls
@@ -424,27 +397,18 @@ gdbtk_memory_changed (CORE_ADDR addr, int len)
* loop. See comments before gdbtk_start_timer and gdb_stop_timer
* in gdbtk.c.
*
- * For native windows (and a few other targets, like the v850 ICE), we
- * rely on the target_wait loops to call deprecated_ui_loop_hook to
- * keep us alive. */
+ * For native windows (and a few other targets, like the v850 ICE),
+ * we rely on the target_wait loops to call ui_loop_hook to keep us alive. */
int
-x_event (int signo)
+x_event (signo)
+ int signo;
{
static volatile int in_x_event = 0;
static Tcl_Obj *varname = NULL;
-
- /* Do nor re-enter this code or enter it while collecting gdb output. */
+ static int count = 0;
if (in_x_event || in_fputs)
return 0;
- /* Also, only do things while the target is running (stops and redraws).
- FIXME: We wold like to at least redraw at other times but this is bundled
- together in the TCL_WINDOW_EVENTS group and we would also process user
- input. We will have to prevent (unwanted) user input to be generated
- in order to be able to redraw (removing this test here). */
- if (!running_now)
- return 0;
-
in_x_event = 1;
gdbtk_force_detach = 0;
@@ -457,7 +421,7 @@ x_event (int signo)
int val;
if (varname == NULL)
{
-#if TCL_MAJOR_VERSION == 8 && (TCL_MINOR_VERSION < 1 || TCL_MINOR_VERSION > 2)
+#if TCL_MAJOR_VERSION == 8 && TCL_MINOR_VERSION < 1
Tcl_Obj *varnamestrobj = Tcl_NewStringObj ("download_cancel_ok", -1);
varname = Tcl_ObjGetVar2 (gdbtk_interp, varnamestrobj, NULL, TCL_GLOBAL_ONLY);
#else
@@ -485,16 +449,16 @@ static void
gdbtk_readline_begin (char *format,...)
{
va_list args;
- char *buf;
+ char buf[200];
va_start (args, format);
- xvasprintf (&buf, format, args);
+ vsprintf (buf, format, args);
gdbtk_two_elem_cmd ("gdbtk_tcl_readline_begin", buf);
- free(buf);
}
static char *
-gdbtk_readline (char *prompt)
+gdbtk_readline (prompt)
+ char *prompt;
{
int result;
@@ -524,12 +488,11 @@ gdbtk_readline_end ()
}
static void
-gdbtk_call_command (struct cmd_list_element *cmdblk,
- char *arg, int from_tty)
+gdbtk_call_command (cmdblk, arg, from_tty)
+ struct cmd_list_element *cmdblk;
+ char *arg;
+ int from_tty;
{
- struct cleanup *old_chain;
-
- old_chain = make_cleanup (null_cleanup, 0);
running_now = 0;
if (cmdblk->class == class_run || cmdblk->class == class_trace)
{
@@ -537,15 +500,13 @@ gdbtk_call_command (struct cmd_list_element *cmdblk,
running_now = 1;
if (!No_Update)
Tcl_Eval (gdbtk_interp, "gdbtk_tcl_busy");
- cmd_func (cmdblk, arg, from_tty);
+ (*cmdblk->function.cfunc) (arg, from_tty);
running_now = 0;
if (!No_Update)
Tcl_Eval (gdbtk_interp, "gdbtk_tcl_idle");
}
else
- cmd_func (cmdblk, arg, from_tty);
-
- do_cleanups (old_chain);
+ (*cmdblk->function.cfunc) (arg, from_tty);
}
/* Called after a `set' command succeeds. Runs the Tcl hook
@@ -557,10 +518,11 @@ gdbtk_set_hook (struct cmd_list_element *cmdblk)
{
Tcl_DString cmd;
char *p;
- char *buffer = NULL;
+ char buffer[30];
Tcl_DStringInit (&cmd);
- Tcl_DStringAppendElement (&cmd, "gdbtk_tcl_set_variable");
+ Tcl_DStringAppendElement (&cmd, "run_hooks");
+ Tcl_DStringAppendElement (&cmd, "gdb_set_hook");
/* Append variable name as sublist. */
Tcl_DStringStartSublist (&cmd);
@@ -568,7 +530,7 @@ gdbtk_set_hook (struct cmd_list_element *cmdblk)
while (p && *p)
{
char *q = strchr (p, ' ');
- char save = '\0';
+ char save;
if (q)
{
save = *q;
@@ -599,12 +561,12 @@ gdbtk_set_hook (struct cmd_list_element *cmdblk)
case var_uinteger:
case var_zinteger:
- xasprintf (&buffer, "%u", *(unsigned int *) cmdblk->var);
+ sprintf (buffer, "%u", *(unsigned int *) cmdblk->var);
Tcl_DStringAppendElement (&cmd, buffer);
break;
case var_integer:
- xasprintf (&buffer, "%d", *(int *) cmdblk->var);
+ sprintf (buffer, "%d", *(int *) cmdblk->var);
Tcl_DStringAppendElement (&cmd, buffer);
break;
@@ -618,22 +580,76 @@ gdbtk_set_hook (struct cmd_list_element *cmdblk)
report_error ();
Tcl_DStringFree (&cmd);
+}
- if (buffer != NULL)
- {
- free(buffer);
- }
+/* The next three functions use breakpoint_notify to allow the GUI
+ * to handle creating, deleting and modifying breakpoints. These three
+ * functions are put into the appropriate gdb hooks in gdbtk_init.
+ */
+
+static void
+gdbtk_create_breakpoint (b)
+ struct breakpoint *b;
+{
+ breakpoint_notify (b, "create");
+}
+
+static void
+gdbtk_delete_breakpoint (b)
+ struct breakpoint *b;
+{
+ breakpoint_notify (b, "delete");
+}
+
+static void
+gdbtk_modify_breakpoint (b)
+ struct breakpoint *b;
+{
+ breakpoint_notify (b, "modify");
+}
+
+/* This is the generic function for handling changes in
+ * a breakpoint. It routes the information to the Tcl
+ * command "gdbtk_tcl_breakpoint" in the form:
+ * gdbtk_tcl_breakpoint action b_number b_address b_line b_file
+ * On error, the error string is written to gdb_stdout.
+ */
+
+static void
+breakpoint_notify (b, action)
+ struct breakpoint *b;
+ const char *action;
+{
+ char buf[256];
+ int v;
+ struct symtab_and_line sal;
+ char *filename;
+
+ if (b->type != bp_breakpoint)
+ return;
+
+ /* We ensure that ACTION contains no special Tcl characters, so we
+ can do this. */
+ sal = find_pc_line (b->address, 0);
+ filename = symtab_to_filename (sal.symtab);
+ if (filename == NULL)
+ filename = "";
+
+ sprintf (buf, "gdbtk_tcl_breakpoint %s %d 0x%lx %d {%s} {%s} %d %d",
+ action, b->number, (long) b->address, b->line_number, filename,
+ bpdisp[b->disposition], b->enable, b->thread);
+
+ if (Tcl_Eval (gdbtk_interp, buf) != TCL_OK)
+ report_error ();
}
int
gdbtk_load_hash (const char *section, unsigned long num)
{
- char *buf;
- xasprintf (&buf, "Download::download_hash %s %ld", section, num);
+ char buf[128];
+ sprintf (buf, "Download::download_hash %s %ld", section, num);
if (Tcl_Eval (gdbtk_interp, buf) != TCL_OK)
report_error ();
- free(buf);
-
return atoi (gdbtk_interp->result);
}
@@ -641,9 +657,10 @@ gdbtk_load_hash (const char *section, unsigned long num)
/* This hook is called whenever we are ready to load a symbol file so that
the UI can notify the user... */
static void
-gdbtk_pre_add_symbol (const char *name)
+gdbtk_pre_add_symbol (name)
+ char *name;
{
- gdbtk_two_elem_cmd ("gdbtk_tcl_pre_add_symbol", (char *) name);
+ gdbtk_two_elem_cmd ("gdbtk_tcl_pre_add_symbol", name);
}
/* This hook is called whenever we finish loading a symbol file. */
@@ -657,36 +674,38 @@ gdbtk_post_add_symbol ()
/* This hook function is called whenever we want to wait for the
target. */
-static ptid_t
-gdbtk_wait (ptid_t ptid, struct target_waitstatus *ourstatus)
+static int
+gdbtk_wait (pid, ourstatus)
+ int pid;
+ struct target_waitstatus *ourstatus;
{
gdbtk_force_detach = 0;
gdbtk_start_timer ();
- ptid = target_wait (ptid, ourstatus);
+ pid = target_wait (pid, ourstatus);
gdbtk_stop_timer ();
- gdbtk_ptid = ptid;
- return ptid;
+ return pid;
}
/*
* This handles all queries from gdb.
* The first argument is a printf style format statement, the rest are its
* arguments. The resultant formatted string is passed to the Tcl function
- * "gdbtk_tcl_query".
+ * "gdbtk_tcl_query".
* It returns the users response to the query, as well as putting the value
* in the result field of the Tcl interpreter.
*/
static int
-gdbtk_query (const char *query, va_list args)
+gdbtk_query (query, args)
+ const char *query;
+ va_list args;
{
- char *buf;
+ char buf[200];
long val;
- xvasprintf (&buf, query, args);
+ vsprintf (buf, query, args);
gdbtk_two_elem_cmd ("gdbtk_tcl_query", buf);
- free(buf);
val = atol (gdbtk_interp->result);
return val;
@@ -694,9 +713,59 @@ gdbtk_query (const char *query, va_list args)
static void
-gdbtk_print_frame_info (struct symtab *s, int line,
- int stopline, int noerror)
+gdbtk_print_frame_info (s, line, stopline, noerror)
+ struct symtab *s;
+ int line;
+ int stopline;
+ int noerror;
+{
+ current_source_symtab = s;
+ current_source_line = line;
+}
+
+static void
+gdbtk_create_tracepoint (tp)
+ struct tracepoint *tp;
+{
+ tracepoint_notify (tp, "create");
+}
+
+static void
+gdbtk_delete_tracepoint (tp)
+ struct tracepoint *tp;
{
+ tracepoint_notify (tp, "delete");
+}
+
+static void
+gdbtk_modify_tracepoint (tp)
+ struct tracepoint *tp;
+{
+ tracepoint_notify (tp, "modify");
+}
+
+static void
+tracepoint_notify (tp, action)
+ struct tracepoint *tp;
+ const char *action;
+{
+ char buf[256];
+ int v;
+ struct symtab_and_line sal;
+ char *filename;
+
+ /* We ensure that ACTION contains no special Tcl characters, so we
+ can do this. */
+ sal = find_pc_line (tp->address, 0);
+
+ filename = symtab_to_filename (sal.symtab);
+ if (filename == NULL)
+ filename = "N/A";
+ sprintf (buf, "gdbtk_tcl_tracepoint %s %d 0x%lx %d {%s} %d", action, tp->number,
+ (long) tp->address, sal.line, filename, tp->pass_count);
+
+ if (Tcl_Eval (gdbtk_interp, buf) != TCL_OK)
+ report_error ();
}
/*
@@ -710,16 +779,18 @@ gdbtk_print_frame_info (struct symtab *s, int line,
*/
static void
-gdbtk_trace_find (char *arg, int from_tty)
+gdbtk_trace_find (arg, from_tty)
+ char *arg;
+ int from_tty;
{
Tcl_Obj *cmdObj;
cmdObj = Tcl_NewListObj (0, NULL);
Tcl_ListObjAppendElement (gdbtk_interp, cmdObj,
- Tcl_NewStringObj ("gdbtk_tcl_trace_find_hook", -1));
+ Tcl_NewStringObj ("gdbtk_tcl_trace_find_hook", -1));
Tcl_ListObjAppendElement (gdbtk_interp, cmdObj, Tcl_NewStringObj (arg, -1));
Tcl_ListObjAppendElement (gdbtk_interp, cmdObj, Tcl_NewIntObj (from_tty));
-#if TCL_MAJOR_VERSION == 8 && (TCL_MINOR_VERSION < 1 || TCL_MINOR_VERSION > 2)
+#if TCL_MAJOR_VERSION == 8 && TCL_MINOR_VERSION < 1
if (Tcl_GlobalEvalObj (gdbtk_interp, cmdObj) != TCL_OK)
report_error ();
#else
@@ -738,7 +809,9 @@ gdbtk_trace_find (char *arg, int from_tty)
*/
static void
-gdbtk_trace_start_stop (int start, int from_tty)
+gdbtk_trace_start_stop (start, from_tty)
+ int start;
+ int from_tty;
{
if (start)
@@ -749,37 +822,33 @@ gdbtk_trace_start_stop (int start, int from_tty)
}
static void
-gdbtk_selected_frame_changed (int level)
+gdbtk_selected_frame_changed (level)
+ int level;
{
-#if TCL_MAJOR_VERSION == 8 && TCL_MINOR_VERSION < 1
- char *a;
- xasprintf (&a, "%d", level);
- Tcl_SetVar (gdbtk_interp, "gdb_selected_frame_level", a, TCL_GLOBAL_ONLY);
- xfree (a);
-#else
- Tcl_SetVar2Ex (gdbtk_interp, "gdb_selected_frame_level", NULL,
- Tcl_NewIntObj (level), TCL_GLOBAL_ONLY);
-#endif
+ Tcl_UpdateLinkedVar (gdbtk_interp, "gdb_selected_frame_level");
}
/* Called when the current thread changes. */
/* gdb_context is linked to the tcl variable "gdb_context_id" */
static void
-gdbtk_context_change (int num)
+gdbtk_context_change (num)
+ int num;
{
gdb_context = num;
}
/* Called from file_command */
static void
-gdbtk_file_changed (char *filename)
+gdbtk_file_changed (filename)
+ char *filename;
{
gdbtk_two_elem_cmd ("gdbtk_tcl_file_changed", filename);
}
/* Called from exec_file_command */
static void
-gdbtk_exec_file_display (char *filename)
+gdbtk_exec_file_display (filename)
+ char *filename;
{
gdbtk_two_elem_cmd ("gdbtk_tcl_exec_file_display", filename);
}
@@ -797,7 +866,7 @@ gdbtk_error_begin ()
static void
gdbtk_annotate_signal ()
{
- char *buf;
+ char buf[128];
/* Inform gui that the target has stopped. This is
a necessary stop button evil. We don't want signal notification
@@ -805,11 +874,10 @@ gdbtk_annotate_signal ()
timeout. */
Tcl_Eval (gdbtk_interp, "gdbtk_stop_idle_callback");
- xasprintf (&buf, "gdbtk_signal %s {%s}", target_signal_to_name (stop_signal),
- target_signal_to_string (stop_signal));
+ sprintf (buf, "gdbtk_signal %s {%s}", target_signal_to_name (stop_signal),
+ target_signal_to_string (stop_signal));
if (Tcl_Eval (gdbtk_interp, buf) != TCL_OK)
report_error ();
- free(buf);
}
static void
@@ -829,16 +897,6 @@ gdbtk_detach ()
report_error ();
}
}
-
-/* Called from gdbarch_update_p whenever the architecture changes. */
-static void
-gdbtk_architecture_changed (struct gdbarch *ignore)
-{
- Tcl_Eval (gdbtk_interp, "gdbtk_tcl_architecture_changed");
-}
-
-ptid_t
-gdbtk_get_ptid (void)
-{
- return gdbtk_ptid;
-}
+/* Local variables: */
+/* change-log-default-name: "ChangeLog-gdbtk" */
+/* End: */
diff --git a/gdb/gdbtk/generic/gdbtk-variable.c b/gdb/gdbtk/generic/gdbtk-variable.c
new file mode 100644
index 00000000000..01aae3e12af
--- /dev/null
+++ b/gdb/gdbtk/generic/gdbtk-variable.c
@@ -0,0 +1,2417 @@
+/* Variable user interface layer for GDB, the GNU debugger.
+ Copyright 1999-2000 Free Software Foundation, Inc.
+
+This file is part of GDB.
+
+This program is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2 of the License, or
+(at your option) any later version.
+
+This program is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with this program; if not, write to the Free Software
+Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+
+#include "defs.h"
+#include "value.h"
+#include "expression.h"
+#include "frame.h"
+#include "valprint.h"
+#include "language.h"
+#include "tui/tui-file.h"
+
+#include <tcl.h>
+#include <tk.h>
+#include "gdbtk.h"
+#include "gdbtk-wrapper.h"
+
+#include <math.h>
+
+/* Enumeration for the format types */
+enum display_format
+{
+ FORMAT_NATURAL, /* What gdb actually calls 'natural' */
+ FORMAT_BINARY, /* Binary display */
+ FORMAT_DECIMAL, /* Decimal display */
+ FORMAT_HEXADECIMAL, /* Hex display */
+ FORMAT_OCTAL /* Octal display */
+};
+
+/* Languages supported by this variable system. */
+enum vlanguage { vlang_c = 0, vlang_cplus, vlang_java, vlang_end };
+
+/* Every variable keeps a linked list of its children, described
+ by the following structure. */
+struct variable_child {
+
+ /* Pointer to the child's data */
+ struct _gdb_variable *child;
+
+ /* Pointer to the next child */
+ struct variable_child *next;
+};
+
+/* Every root variable has one of these structures saved in its
+ gdb_variable. Members which must be free'd are noted. */
+struct variable_root {
+
+ /* Alloc'd expression for this parent. */
+ struct expression *exp;
+
+ /* Block for which this expression is valid */
+ struct block *valid_block;
+
+ /* The frame for this expression */
+ CORE_ADDR frame;
+
+ /* Language info for this variable and its children */
+ struct language_specific *lang;
+
+ /* The gdb_variable for this root node. */
+ struct _gdb_variable *root;
+};
+
+/* Every variable in the system has a structure of this type defined
+ for it. This structure holds all information necessary to manipulate
+ a particular object variable. Members which must be freed are noted. */
+struct _gdb_variable {
+
+ /* Alloc'd name of the variable for this object.. If this variable is a
+ child, then this name will be the child's source name.
+ (bar, not foo.bar) */
+ char *name;
+
+ /* The alloc'd name for this variable's object. This is here for
+ convenience when constructing this object's children. */
+ char *obj_name;
+
+ /* Index of this variable in its parent or -1 */
+ int index;
+
+ /* The type of this variable. This may NEVER be NULL. */
+ struct type *type;
+
+ /* The value of this expression or subexpression. This may be NULL. */
+ value_ptr value;
+
+ /* Did an error occur evaluating the expression or getting its value? */
+ int error;
+
+ /* The number of (immediate) children this variable has */
+ int num_children;
+
+ /* If this object is a child, this points to its immediate parent. */
+ struct _gdb_variable *parent;
+
+ /* A list of this object's children */
+ struct variable_child *children;
+
+ /* Description of the root variable. Points to root variable for children. */
+ struct variable_root *root;
+
+ /* The format of the output for this object */
+ enum display_format format;
+};
+
+typedef struct _gdb_variable gdb_variable;
+
+struct language_specific {
+
+ /* The language of this variable */
+ enum vlanguage language;
+
+ /* The number of children of PARENT. */
+ int (*number_of_children) PARAMS ((struct _gdb_variable *parent));
+
+ /* The name of the INDEX'th child of PARENT. */
+ char *(*name_of_child) PARAMS ((struct _gdb_variable *parent, int index));
+
+ /* The value_ptr of the root variable ROOT. */
+ value_ptr (*value_of_root) PARAMS ((struct _gdb_variable *root));
+
+ /* The value_ptr of the INDEX'th child of PARENT. */
+ value_ptr (*value_of_child) PARAMS ((struct _gdb_variable *parent, int index));
+
+ /* The type of the INDEX'th child of PARENT. */
+ struct type *(*type_of_child) PARAMS ((struct _gdb_variable *parent, int index));
+
+ /* Is VAR editable? */
+ int (*variable_editable) PARAMS ((struct _gdb_variable *var));
+
+ /* The current value of VAR is returned in *OBJ. */
+ int (*value_of_variable) PARAMS ((struct _gdb_variable *var, Tcl_Obj **obj));
+};
+
+struct vstack {
+ gdb_variable *var;
+ struct vstack *next;
+};
+
+/* A little convenience enum for dealing with C++/Java */
+enum vsections { v_public = 0, v_private, v_protected };
+
+/*
+ * Public functions defined in this file
+ */
+
+int gdb_variable_init PARAMS ((Tcl_Interp *));
+
+/*
+ * Private functions defined in this file
+ */
+
+/* Entries into this file */
+
+static int gdb_variable_command PARAMS ((ClientData, Tcl_Interp *, int,
+ Tcl_Obj *CONST[]));
+
+static int variable_obj_command PARAMS ((ClientData, Tcl_Interp *, int,
+ Tcl_Obj *CONST[]));
+
+/* Variable object subcommands */
+static int variable_create PARAMS ((Tcl_Interp *, int, Tcl_Obj *CONST[]));
+
+static void variable_delete PARAMS ((Tcl_Interp *, gdb_variable *));
+
+static Tcl_Obj *variable_children PARAMS ((Tcl_Interp *, gdb_variable *));
+
+static int variable_format PARAMS ((Tcl_Interp *, int, Tcl_Obj *CONST[],
+ gdb_variable *));
+
+static int variable_type PARAMS ((Tcl_Interp *, int, Tcl_Obj *CONST[],
+ gdb_variable *));
+
+static int variable_value PARAMS ((Tcl_Interp *, int, Tcl_Obj *CONST[],
+ gdb_variable *));
+
+static int variable_editable PARAMS ((gdb_variable *));
+
+static int my_value_of_variable PARAMS ((gdb_variable *var, Tcl_Obj **obj));
+
+static Tcl_Obj *variable_update PARAMS ((Tcl_Interp *interp, gdb_variable *var));
+
+/* Helper functions for the above subcommands. */
+
+static gdb_variable *create_variable PARAMS ((char *name, CORE_ADDR frame));
+
+static void delete_children PARAMS ((Tcl_Interp *, gdb_variable *, int));
+
+static void install_variable PARAMS ((Tcl_Interp *, char *, gdb_variable *));
+
+static void uninstall_variable PARAMS ((Tcl_Interp *, gdb_variable *));
+
+static gdb_variable *child_exists PARAMS ((gdb_variable *, char *));
+
+static gdb_variable *create_child PARAMS ((Tcl_Interp *, gdb_variable *,
+ int, char *));
+static char *name_of_child PARAMS ((gdb_variable *, int));
+
+static int number_of_children PARAMS ((gdb_variable *));
+
+static enum display_format variable_default_display PARAMS ((gdb_variable *));
+
+static void save_child_in_parent PARAMS ((gdb_variable *, gdb_variable *));
+
+static void remove_child_from_parent PARAMS ((gdb_variable *, gdb_variable *));
+
+/* Utility routines */
+
+static struct type *get_type PARAMS ((gdb_variable *var));
+
+static struct type *get_type_deref PARAMS ((gdb_variable *var));
+
+static struct type *get_target_type PARAMS ((struct type *));
+
+static Tcl_Obj *get_call_output PARAMS ((void));
+
+static void clear_gdb_output PARAMS ((void));
+
+static int call_gdb_type_print PARAMS ((value_ptr));
+
+static int call_gdb_val_print PARAMS ((value_ptr, int));
+
+static void variable_fputs (const char *, struct ui_file *);
+
+static void null_fputs (const char *, struct ui_file *);
+
+static int my_value_equal PARAMS ((gdb_variable *, value_ptr));
+
+static void vpush PARAMS ((struct vstack **pstack, gdb_variable *var));
+
+static gdb_variable *vpop PARAMS ((struct vstack **pstack));
+
+/* Language-specific routines. */
+
+static value_ptr value_of_child PARAMS ((gdb_variable *parent, int index));
+
+static value_ptr value_of_root PARAMS ((gdb_variable *var));
+
+static struct type *type_of_child PARAMS ((gdb_variable *var));
+
+static int type_changeable PARAMS ((gdb_variable *var));
+
+static int c_number_of_children PARAMS ((gdb_variable *var));
+
+static char *c_name_of_child PARAMS ((gdb_variable *parent, int index));
+
+static value_ptr c_value_of_root PARAMS ((gdb_variable *var));
+
+static value_ptr c_value_of_child PARAMS ((gdb_variable *parent, int index));
+
+static struct type *c_type_of_child PARAMS ((gdb_variable *parent, int index));
+
+static int c_variable_editable PARAMS ((gdb_variable *var));
+
+static int c_value_of_variable PARAMS ((gdb_variable *var, Tcl_Obj **obj));
+
+static int cplus_number_of_children PARAMS ((gdb_variable *var));
+
+static void cplus_class_num_children PARAMS ((struct type *type, int children[3]));
+
+static char *cplus_name_of_child PARAMS ((gdb_variable *parent, int index));
+
+static value_ptr cplus_value_of_root PARAMS ((gdb_variable *var));
+
+static value_ptr cplus_value_of_child PARAMS ((gdb_variable *parent, int index));
+
+static struct type *cplus_type_of_child PARAMS ((gdb_variable *parent, int index));
+
+static int cplus_variable_editable PARAMS ((gdb_variable *var));
+
+static int cplus_value_of_variable PARAMS ((gdb_variable *var, Tcl_Obj **obj));
+
+static int java_number_of_children PARAMS ((gdb_variable *var));
+
+static char *java_name_of_child PARAMS ((gdb_variable *parent, int index));
+
+static value_ptr java_value_of_root PARAMS ((gdb_variable *var));
+
+static value_ptr java_value_of_child PARAMS ((gdb_variable *parent, int index));
+
+static struct type *java_type_of_child PARAMS ((gdb_variable *parent, int index));
+
+static int java_variable_editable PARAMS ((gdb_variable *var));
+
+static int java_value_of_variable PARAMS ((gdb_variable *var, Tcl_Obj **obj));
+
+static enum vlanguage variable_language PARAMS ((gdb_variable *var));
+
+static gdb_variable *new_variable PARAMS ((void));
+
+static gdb_variable *new_root_variable (void);
+
+static void free_variable PARAMS ((gdb_variable *var));
+
+/* String representations of gdb's format codes */
+char *format_string[] = {"natural", "binary", "decimal", "hexadecimal", "octal"};
+
+/* Array of known source language routines. */
+static struct language_specific languages[vlang_end][sizeof(struct language_specific)] = {
+ { vlang_c, c_number_of_children, c_name_of_child, c_value_of_root,
+ c_value_of_child, c_type_of_child, c_variable_editable,
+ c_value_of_variable },
+ { vlang_cplus, cplus_number_of_children, cplus_name_of_child, cplus_value_of_root,
+ cplus_value_of_child, cplus_type_of_child, cplus_variable_editable,
+ cplus_value_of_variable },
+ { vlang_java, java_number_of_children, java_name_of_child, java_value_of_root,
+ java_value_of_child, java_type_of_child, java_variable_editable,
+ java_value_of_variable }};
+
+/* Mappings of display_format enums to gdb's format codes */
+int format_code[] = {0, 't', 'd', 'x', 'o'};
+
+/* This variable will hold the value of the output from gdb
+ for commands executed through call_gdb_* */
+static Tcl_Obj *fputs_obj;
+
+#if defined(FREEIF)
+# undef FREEIF
+#endif
+#define FREEIF(x) if (x != NULL) free((char *) (x))
+
+/* Is the variable X one of our "fake" children? */
+#define CPLUS_FAKE_CHILD(x) \
+((x) != NULL && (x)->type == NULL && (x)->value == NULL)
+
+/* Initialize the variable code. This function should be called once
+ to install and initialize the variable code into the interpreter. */
+int
+gdb_variable_init (interp)
+ Tcl_Interp *interp;
+{
+ Tcl_Command result;
+ static int initialized = 0;
+
+ if (!initialized)
+ {
+ result = Tcl_CreateObjCommand (interp, "gdb_variable", call_wrapper,
+ (ClientData) gdb_variable_command, NULL);
+ if (result == NULL)
+ return TCL_ERROR;
+
+ initialized = 1;
+ }
+
+ return TCL_OK;
+}
+
+/* This function defines the "gdb_variable" command which is used to
+ create variable objects. Its syntax includes:
+
+ gdb_variable create
+ gdb_variable create NAME
+ gdb_variable create -expr EXPR
+ gdb_variable create -frame FRAME
+ (it will also include permutations of the above options)
+
+ NAME = name of object to create. If no NAME, then automatically create
+ a name
+ EXPR = the gdb expression for which to create a variable. This will
+ be the most common usage.
+ FRAME = the frame defining the scope of the variable.
+*/
+static int
+gdb_variable_command (clientData, interp, objc, objv)
+ ClientData clientData;
+ Tcl_Interp *interp;
+ int objc;
+ Tcl_Obj *CONST objv[];
+{
+ static char *commands[] = { "create", "list", NULL };
+ enum commands_enum { VARIABLE_CREATE, VARIABLE_LIST };
+ int index, result;
+
+ if (objc < 2)
+ {
+ Tcl_WrongNumArgs (interp, 1, objv, "option ?arg...?");
+ return TCL_ERROR;
+ }
+
+ if (Tcl_GetIndexFromObj (interp, objv[1], commands, "options", 0,
+ &index) != TCL_OK)
+ {
+ return TCL_ERROR;
+ }
+
+ switch ((enum commands_enum) index)
+ {
+ case VARIABLE_CREATE:
+ result = variable_create (interp, objc - 2, objv + 2);
+ break;
+
+ default:
+ return TCL_ERROR;
+ }
+
+ return result;
+}
+
+/* This function implements the actual object command for each
+ variable object that is created (and each of its children).
+
+ Currently the following commands are implemented:
+ - delete delete this object and its children
+ - update update the variable and its children (root vars only)
+ - numChildren how many children does this object have
+ - children create the children and return a list of their objects
+ - name print out the name of this variable
+ - format query/set the display format of this variable
+ - type get the type of this variable
+ - value get/set the value of this variable
+ - editable is this variable editable?
+*/
+static int
+variable_obj_command (clientData, interp, objc, objv)
+ ClientData clientData;
+ Tcl_Interp *interp;
+ int objc;
+ Tcl_Obj *CONST objv[];
+{
+ enum commands_enum {
+ VARIABLE_DELETE,
+ VARIABLE_NUM_CHILDREN,
+ VARIABLE_CHILDREN,
+ VARIABLE_FORMAT,
+ VARIABLE_TYPE,
+ VARIABLE_VALUE,
+ VARIABLE_NAME,
+ VARIABLE_EDITABLE,
+ VARIABLE_UPDATE
+ };
+ static char *commands[] = {
+ "delete",
+ "numChildren",
+ "children",
+ "format",
+ "type",
+ "value",
+ "name",
+ "editable",
+ "update",
+ NULL
+ };
+ gdb_variable *var = (gdb_variable *) clientData;
+ int index, result;
+
+ if (objc < 2)
+ {
+ Tcl_WrongNumArgs (interp, 1, objv, "option ?arg...?");
+ return TCL_ERROR;
+ }
+
+ if (Tcl_GetIndexFromObj (interp, objv[1], commands, "options", 0,
+ &index) != TCL_OK)
+ return TCL_ERROR;
+
+ result = TCL_OK;
+ switch ((enum commands_enum) index)
+ {
+ case VARIABLE_DELETE:
+ if (objc > 2)
+ {
+ int len;
+ char *s = Tcl_GetStringFromObj (objv[2], &len);
+ if (*s == 'c' && strncmp (s, "children", len) == 0)
+ {
+ delete_children (interp, var, 1);
+ break;
+ }
+ }
+ variable_delete (interp, var);
+ break;
+
+ case VARIABLE_NUM_CHILDREN:
+ if (var->num_children == -1)
+ var->num_children = number_of_children (var);
+
+ Tcl_SetObjResult (interp, Tcl_NewIntObj (var->num_children));
+ break;
+
+ case VARIABLE_CHILDREN:
+ {
+ Tcl_Obj *children = variable_children (interp, var);
+ Tcl_SetObjResult (interp, children);
+ }
+ break;
+
+ case VARIABLE_FORMAT:
+ result = variable_format (interp, objc, objv, var);
+ break;
+
+ case VARIABLE_TYPE:
+ result = variable_type (interp, objc, objv, var);
+ break;
+
+ case VARIABLE_VALUE:
+ result = variable_value (interp, objc, objv, var);
+ break;
+
+ case VARIABLE_NAME:
+ {
+ /* If var->name has "-" in it, it's because we
+ needed to escape periods in the name... */
+ char *p, *name;
+ name = savestring (var->name, strlen (var->name));
+ p = name;
+ while (*p != '\000')
+ {
+ if (*p == '-')
+ *p = '.';
+ p++;
+ }
+ Tcl_SetObjResult (interp, Tcl_NewStringObj (name, -1));
+ free (name);
+ }
+ break;
+
+ case VARIABLE_EDITABLE:
+ Tcl_SetObjResult (interp, Tcl_NewIntObj (variable_editable (var)));
+ break;
+
+ case VARIABLE_UPDATE:
+ /* Only root variables can be updated */
+ if (var->parent == NULL)
+ {
+ Tcl_Obj *obj = variable_update (interp, var);
+ Tcl_SetObjResult (interp, obj);
+ }
+ result = TCL_OK;
+ break;
+
+ default:
+ return TCL_ERROR;
+ }
+
+ return result;
+}
+
+/*
+ * Variable object construction/destruction
+ */
+
+/* This function is responsible for processing the user's specifications
+ and constructing a variable object. */
+static int
+variable_create (interp, objc, objv)
+ Tcl_Interp *interp;
+ int objc;
+ Tcl_Obj *CONST objv[];
+{
+ enum create_opts { CREATE_EXPR, CREATE_FRAME };
+ static char *create_options[] = { "-expr", "-frame", NULL };
+ gdb_variable *var;
+ char *name;
+ char obj_name[31];
+ int index;
+ static int id = 0;
+ CORE_ADDR frame = (CORE_ADDR) -1;
+
+ /* REMINDER: This command may be invoked in the following ways:
+ gdb_variable create [NAME] [-expr EXPR] [-frame FRAME]
+
+ NAME = name of object to create. If no NAME, then automatically create
+ a name
+ EXPR = the gdb expression for which to create a variable. This will
+ be the most common usage.
+ FRAME = the address of the frame defining the variable's scope
+ */
+ name = NULL;
+ if (objc)
+ name = Tcl_GetStringFromObj (objv[0], NULL);
+ if (name == NULL || *name == '-')
+ {
+ /* generate a name for this object */
+ id++;
+ sprintf (obj_name, "var%d", id);
+ }
+ else
+ {
+ /* specified name for object */
+ strncpy (obj_name, name, 30);
+ objv++;
+ objc--;
+ }
+
+ /* Run through all the possible options for this command */
+ name = NULL;
+ while (objc > 0)
+ {
+ if (Tcl_GetIndexFromObj (interp, objv[0], create_options, "options",
+ 0, &index) != TCL_OK)
+ {
+ result_ptr->flags |= GDBTK_IN_TCL_RESULT;
+ return TCL_ERROR;
+ }
+
+ switch ((enum create_opts) index)
+ {
+ case CREATE_EXPR:
+ name = Tcl_GetStringFromObj (objv[1], NULL);
+ objc--;
+ objv++;
+ break;
+
+ case CREATE_FRAME:
+ {
+ char *str;
+ str = Tcl_GetStringFromObj (objv[1], NULL);
+ frame = parse_and_eval_address (str);
+ objc--;
+ objv++;
+ }
+ break;
+
+ default:
+ break;
+ }
+
+ objc--;
+ objv++;
+ }
+
+ /* Create the variable */
+ var = create_variable (name, frame);
+
+ if (var != NULL)
+ {
+ /* Install a command into the interpreter that represents this
+ object */
+ install_variable (interp, obj_name, var);
+ Tcl_SetObjResult (interp, Tcl_NewStringObj (obj_name, -1));
+ result_ptr->flags |= GDBTK_IN_TCL_RESULT;
+
+ return TCL_OK;
+ }
+
+ return TCL_ERROR;
+}
+
+/* Fill out a gdb_variable structure for the (root) variable being constructed. */
+static gdb_variable *
+create_variable (name, frame)
+ char *name;
+ CORE_ADDR frame;
+{
+ gdb_variable *var;
+ struct frame_info *fi, *old_fi;
+ struct block *block;
+ void (*old_fputs) (const char *, struct ui_file *);
+ gdb_result r;
+
+ var = new_root_variable ();
+ if (name != NULL)
+ {
+ char *p;
+ enum vlanguage lang;
+
+ /* Several of the GDB_* calls can cause messages to be displayed. We swallow
+ those here, because we don't need them (the "value" command will
+ show them). */
+ old_fputs = fputs_unfiltered_hook;
+ fputs_unfiltered_hook = null_fputs;
+
+ /* Parse and evaluate the expression, filling in as much
+ of the variable's data as possible */
+
+ /* Allow creator to specify context of variable */
+ r = GDB_OK;
+ if (frame == (CORE_ADDR) -1)
+ fi = selected_frame;
+ else
+ r = GDB_find_frame_addr_in_frame_chain (frame, &fi);
+
+ block = NULL;
+ if (fi != NULL)
+ r = GDB_get_frame_block (fi, &block);
+
+ p = name;
+ innermost_block = NULL;
+ r = GDB_parse_exp_1 (&p, block, 0, &(var->root->exp));
+ if (r != GDB_OK)
+ {
+ free_variable (var);
+
+ /* Restore the output hook to normal */
+ fputs_unfiltered_hook = old_fputs;
+
+ return NULL;
+ }
+
+ /* Don't allow variables to be created for types. */
+ if (var->root->exp->elts[0].opcode == OP_TYPE)
+ {
+ free_variable (var);
+
+ /* Restore the output hook to normal */
+ fputs_unfiltered_hook = old_fputs;
+
+ printf_unfiltered ("Attempt to use a type name as an expression.");
+ return NULL;
+ }
+
+ var->format = variable_default_display (var);
+ var->root->valid_block = innermost_block;
+ var->name = savestring (name, strlen (name));
+
+ /* When the frame is different from the current frame,
+ we must select the appropriate frame before parsing
+ the expression, otherwise the value will not be current.
+ Since select_frame is so benign, just call it for all cases. */
+ if (fi != NULL)
+ {
+ var->root->frame = FRAME_FP (fi);
+ old_fi = selected_frame;
+ GDB_select_frame (fi, -1);
+ }
+
+ if (GDB_evaluate_expression (var->root->exp, &var->value) == GDB_OK)
+ {
+ release_value (var->value);
+ if (VALUE_LAZY (var->value))
+ GDB_value_fetch_lazy (var->value);
+ }
+ else
+ var->value = evaluate_type (var->root->exp);
+
+ var->type = VALUE_TYPE (var->value);
+
+ /* Set language info */
+ lang = variable_language (var);
+ var->root->lang = languages[lang];
+
+ /* Set ourselves as our root */
+ var->root->root = var;
+
+ /* Reset the selected frame */
+ if (fi != NULL)
+ GDB_select_frame (old_fi, -1);
+
+
+ /* Restore the output hook to normal */
+ fputs_unfiltered_hook = old_fputs;
+ }
+
+ return var;
+}
+
+/* Install the given variable VAR into the tcl interpreter with
+ the object name NAME. */
+static void
+install_variable (interp, name, var)
+ Tcl_Interp *interp;
+ char *name;
+ gdb_variable *var;
+{
+ var->obj_name = savestring (name, strlen (name));
+ Tcl_CreateObjCommand (interp, name, variable_obj_command,
+ (ClientData) var, NULL);
+}
+
+/* Unistall the object VAR in the tcl interpreter. */
+static void
+uninstall_variable (interp, var)
+ Tcl_Interp *interp;
+ gdb_variable *var;
+{
+ Tcl_DeleteCommand (interp, var->obj_name);
+}
+
+/* Delete the variable object VAR and its children */
+static void
+variable_delete (interp, var)
+ Tcl_Interp *interp;
+ gdb_variable *var;
+{
+ /* Delete any children of this variable, too. */
+ delete_children (interp, var, 0);
+
+ /* If this variable has a parent, remove it from its parent's list */
+ if (var->parent != NULL)
+ {
+ remove_child_from_parent (var->parent, var);
+ }
+
+ uninstall_variable (interp, var);
+
+ /* Free memory associated with this variable */
+ free_variable (var);
+}
+
+/* Free any allocated memory associated with VAR. */
+static void free_variable (var)
+ gdb_variable *var;
+{
+ /* Free the expression if this is a root variable. */
+ if (var->root->root == var)
+ {
+ free_current_contents ((char **) &var->root->exp);
+ FREEIF (var->root);
+ }
+
+ FREEIF (var->name);
+ FREEIF (var->obj_name);
+ FREEIF (var);
+}
+
+/*
+ * Child construction/destruction
+ */
+
+/* Delete the children associated with the object VAR. If NOTIFY is set,
+ notify the parent object that this child was deleted. This is used as
+ a small optimization when deleting variables and their children. If the
+ parent is also being deleted, don't bother notifying it that its children
+ are being deleted. */
+static void
+delete_children (interp, var, notify)
+ Tcl_Interp *interp;
+ gdb_variable *var;
+ int notify;
+{
+ struct variable_child *vc;
+ struct variable_child *next;
+
+ for (vc = var->children; vc != NULL; vc = next)
+ {
+ if (!notify)
+ vc->child->parent = NULL;
+ variable_delete (interp, vc->child);
+ next = vc->next;
+ free (vc);
+ }
+}
+
+/* Return the number of children for a given variable.
+ The result of this function is defined by the language
+ implementation. The number of children returned by this function
+ is the number of children that the user will see in the variable
+ display. */
+static int
+number_of_children (var)
+ gdb_variable *var;
+{
+ return (*var->root->lang->number_of_children) (var);;
+}
+
+/* Return a list of all the children of VAR, creating them if necessary. */
+static Tcl_Obj *
+variable_children (interp, var)
+ Tcl_Interp *interp;
+ gdb_variable *var;
+{
+ Tcl_Obj *list;
+ gdb_variable *child;
+ char *name;
+ int i;
+
+ list = Tcl_NewListObj (0, NULL);
+ if (var->num_children == -1)
+ var->num_children = number_of_children (var);
+
+ for (i = 0; i < var->num_children; i++)
+ {
+ /* check if child exists */
+ name = name_of_child (var, i);
+ child = child_exists (var, name);
+ if (child == NULL)
+ child = create_child (interp, var, i, name);
+
+ if (child != NULL)
+ Tcl_ListObjAppendElement (NULL, list, Tcl_NewStringObj (child->obj_name, -1));
+ }
+
+ return list;
+}
+
+/* Does a child with the name NAME exist in VAR? If so, return its data.
+ If not, return NULL. */
+static gdb_variable *
+child_exists (var, name)
+ gdb_variable *var; /* Parent */
+ char *name; /* name of child */
+{
+ struct variable_child *vc;
+
+ for (vc = var->children; vc != NULL; vc = vc->next)
+ {
+ if (STREQ (vc->child->name, name))
+ return vc->child;
+ }
+
+ return NULL;
+}
+
+/* Create and install a child of the parent of the given name */
+static gdb_variable *
+create_child (interp, parent, index, name)
+ Tcl_Interp *interp;
+ gdb_variable *parent;
+ int index;
+ char *name;
+{
+ gdb_variable *child;
+ char *childs_name;
+
+ child = new_variable ();
+
+ /* name is allocated by name_of_child */
+ child->name = name;
+ child->index = index;
+ child->value = value_of_child (parent, index);
+ if (child->value == NULL || parent->error)
+ child->error = 1;
+ child->parent = parent;
+ child->root = parent->root;
+ childs_name = (char *) xmalloc ((strlen (parent->obj_name) + strlen (name) + 2)
+ * sizeof (char));
+ sprintf (childs_name, "%s.%s", parent->obj_name, name);
+ install_variable (interp, childs_name, child);
+ free (childs_name);
+
+ /* Save a pointer to this child in the parent */
+ save_child_in_parent (parent, child);
+
+ /* Note the type of this child */
+ child->type = type_of_child (child);
+
+ return child;
+}
+
+/* Save CHILD in the PARENT's data. */
+static void
+save_child_in_parent (parent, child)
+ gdb_variable *parent;
+ gdb_variable *child;
+{
+ struct variable_child *vc;
+
+ /* Insert the child at the top */
+ vc = parent->children;
+ parent->children =
+ (struct variable_child *) xmalloc (sizeof (struct variable_child));
+
+ parent->children->next = vc;
+ parent->children->child = child;
+}
+
+/* Remove the CHILD from the PARENT's list of children. */
+static void
+remove_child_from_parent (parent, child)
+ gdb_variable *parent;
+ gdb_variable *child;
+{
+ struct variable_child *vc, *prev;
+
+ /* Find the child in the parent's list */
+ prev = NULL;
+ for (vc = parent->children; vc != NULL; )
+ {
+ if (vc->child == child)
+ break;
+ prev = vc;
+ vc = vc->next;
+ }
+
+ if (prev == NULL)
+ parent->children = vc->next;
+ else
+ prev->next = vc->next;
+
+}
+
+/* What is the name of the INDEX'th child of VAR? Returns a malloc'd string. */
+static char *
+name_of_child (var, index)
+ gdb_variable *var;
+ int index;
+{
+ return (*var->root->lang->name_of_child) (var, index);
+}
+
+/* Update the values for a variable and its children. This is a
+ two-pronged attack. First, re-parse the value for the root's
+ expression to see if it's changed. Then go all the way
+ through its children, reconstructing them and noting if they've
+ changed.
+
+ Only root variables can be updated... */
+static Tcl_Obj *
+variable_update (interp, var)
+ Tcl_Interp *interp;
+ gdb_variable *var;
+{
+ void (*old_hook) (const char *, struct ui_file *);
+ Tcl_Obj *changed;
+ gdb_variable *v;
+ value_ptr new;
+ struct vstack *stack = NULL;
+ struct frame_info *old_fi;
+
+ /* Initialize a stack */
+ vpush (&stack, NULL);
+
+ /* Save the selected stack frame, since we will need to change it
+ in order to evaluate expressions. */
+ old_fi = selected_frame;
+
+ /* evaluate_expression can output errors to the screen,
+ so swallow them here. */
+ old_hook = fputs_unfiltered_hook;
+ fputs_unfiltered_hook = null_fputs;
+
+ changed = Tcl_NewListObj (0, NULL);
+
+ /* Update the root variable. value_of_root can return NULL
+ if the variable is no longer around, i.e. we stepped out of
+ the frame in which a local existed. */
+ new = value_of_root (var);
+ if (new == NULL)
+ return changed;
+
+ if (!my_value_equal (var, new))
+ {
+ /* Note that it's changed There a couple of exceptions here,
+ though. We don't want some types to be reported as "changed". */
+ if (type_changeable (var))
+ Tcl_ListObjAppendElement (interp, changed, Tcl_NewStringObj (var->obj_name, -1));
+ }
+
+ /* We must always keep around the new value for this root
+ variable expression, or we lose the updated children! */
+ value_free (var->value);
+ var->value = new;
+
+ /* Push the root's children */
+ if (var->children != NULL)
+ {
+ struct variable_child *c;
+ for (c = var->children; c != NULL; c = c->next)
+ vpush (&stack, c->child);
+ }
+
+ /* Walk through the children, reconstructing them all. */
+ v = vpop (&stack);
+ while (v != NULL)
+ {
+ /* Push any children */
+ if (v->children != NULL)
+ {
+ struct variable_child *c;
+ for (c = v->children; c != NULL; c = c->next)
+ vpush (&stack, c->child);
+ }
+
+ /* Update this variable */
+ new = value_of_child (v->parent, v->index);
+ if (type_changeable (v) && !my_value_equal (v, new))
+ {
+ /* Note that it's changed */
+ Tcl_ListObjAppendElement (interp, changed,
+ Tcl_NewStringObj (v->obj_name, -1));
+ }
+
+ /* We must always keep new values, since children depend on it. */
+ if (v->value != NULL)
+ value_free (v->value);
+ v->value = new;
+
+ /* Get next child */
+ v = vpop (&stack);
+ }
+
+ /* Restore the original fputs_hook. */
+ fputs_unfiltered_hook = old_hook;
+
+ /* Restore selected frame */
+ GDB_select_frame (old_fi, -1);
+
+ return changed;
+}
+
+/* What is the type of VAR? */
+static struct type *
+type_of_child (var)
+ gdb_variable *var;
+{
+
+ /* If the child had no evaluation errors, var->value
+ will be non-NULL and contain a valid type. */
+ if (var->value != NULL)
+ return VALUE_TYPE (var->value);
+
+ /* Otherwise, we must compute the type. */
+ return (*var->root->lang->type_of_child) (var->parent, var->index);
+}
+
+/* What is the value_ptr for the INDEX'th child of PARENT? */
+static value_ptr
+value_of_child (parent, index)
+ gdb_variable *parent;
+ int index;
+{
+ value_ptr value;
+ void (*old_hook) (const char *, struct ui_file *);
+
+ /* Same deal here as before. GDB can output error messages to the
+ screen while it attempts to work its way through the tree. */
+ old_hook = fputs_unfiltered_hook;
+ fputs_unfiltered_hook = null_fputs;
+
+ value = (*parent->root->lang->value_of_child) (parent, index);
+
+ /* If we're being lazy, fetch the real value of the variable. */
+ if (value != NULL && VALUE_LAZY (value))
+ GDB_value_fetch_lazy (value);
+
+ /* Restore output hook */
+ fputs_unfiltered_hook = old_hook;
+
+ return value;
+}
+
+/* What is the value_ptr of the root variable VAR? */
+static value_ptr
+value_of_root (var)
+ gdb_variable *var;
+{
+ return (*var->root->lang->value_of_root) (var);
+}
+
+/* This implements the format object command allowing
+ the querying or setting of the object's display format. */
+static int
+variable_format (interp, objc, objv, var)
+ Tcl_Interp *interp;
+ int objc;
+ Tcl_Obj *CONST objv[];
+ gdb_variable *var;
+{
+
+ if (objc > 2)
+ {
+ /* Set the format of VAR to given format */
+ int len;
+ char *fmt = Tcl_GetStringFromObj (objv[2], &len);
+ if (STREQN (fmt, "natural", len))
+ var->format = FORMAT_NATURAL;
+ else if (STREQN (fmt, "binary", len))
+ var->format = FORMAT_BINARY;
+ else if (STREQN (fmt, "decimal", len))
+ var->format = FORMAT_DECIMAL;
+ else if (STREQN (fmt, "hexadecimal", len))
+ var->format = FORMAT_HEXADECIMAL;
+ else if (STREQN (fmt, "octal", len))
+ var->format = FORMAT_OCTAL;
+ else
+ {
+ Tcl_Obj *obj = Tcl_NewStringObj (NULL, 0);
+ Tcl_AppendStringsToObj (obj, "unknown display format \"",
+ fmt, "\": must be: \"natural\", \"binary\""
+ ", \"decimal\", \"hexadecimal\", or \"octal\"",
+ NULL);
+ Tcl_SetObjResult (interp, obj);
+ return TCL_ERROR;
+ }
+ }
+ else
+ {
+ /* Report the current format */
+ Tcl_Obj *fmt;
+
+ fmt = Tcl_NewStringObj (format_string [(int) var->format], -1);
+ Tcl_SetObjResult (interp, fmt);
+ }
+
+ return TCL_OK;
+}
+
+/* What is the default display for this variable? We assume that
+ everything is "natural". Any exceptions? */
+static enum display_format
+variable_default_display (var)
+ gdb_variable *var;
+{
+ return FORMAT_NATURAL;
+}
+
+/* This function implements the type object command, which returns the type of a
+ variable in the interpreter (or an error). */
+static int
+variable_type (interp, objc, objv, var)
+ Tcl_Interp *interp;
+ int objc;
+ Tcl_Obj *CONST objv[];
+ gdb_variable *var;
+{
+ int result;
+ value_ptr val;
+ char *first, *last, *string;
+ Tcl_RegExp regexp;
+ gdb_result r;
+
+ /* For the "fake" variables, do not return a type. (It's type is
+ NULL, too.) */
+ if (CPLUS_FAKE_CHILD (var))
+ {
+ Tcl_ResetResult (interp);
+ return TCL_OK;
+ }
+
+ /* To print the type, we simply create a zero value_ptr and
+ cast it to our type. We then typeprint this variable. */
+ val = value_zero (var->type, not_lval);
+ result = call_gdb_type_print (val);
+ if (result == TCL_OK)
+ {
+ string = xstrdup (Tcl_GetStringFromObj (get_call_output (), NULL));
+ first = string;
+
+ /* gdb will print things out like "struct {...}" for anonymous structs.
+ In gui-land, we don't want the {...}, so we strip it here. */
+ regexp = Tcl_RegExpCompile (interp, "{...}");
+ if (Tcl_RegExpExec (interp, regexp, string, first))
+ {
+ /* We have an anonymous struct/union/class/enum */
+ Tcl_RegExpRange (regexp, 0, &first, &last);
+ if (*(first - 1) == ' ')
+ first--;
+ *first = '\0';
+ }
+
+ Tcl_SetObjResult (interp, Tcl_NewStringObj (string, -1));
+ FREEIF (string);
+ return TCL_OK;
+ }
+
+ Tcl_SetObjResult (interp, get_call_output ());
+ return result;
+}
+
+/* This function implements the value object command, which allows an object's
+ value to be queried or set. */
+static int
+variable_value (interp, objc, objv, var)
+ Tcl_Interp *interp;
+ int objc;
+ Tcl_Obj *CONST objv[];
+ gdb_variable *var;
+{
+ int result;
+ struct type *type;
+ value_ptr val;
+ Tcl_Obj *str;
+ gdb_result r;
+ int real_addressprint;
+ int offset = 0;
+
+ /* If we're setting the value of the variable, objv[2] will contain the
+ variable's new value. We need to first construct a legal expression
+ for this -- ugh! */
+ if (objc > 2)
+ {
+ /* Does this cover all the bases? */
+ struct expression *exp;
+ value_ptr value;
+ int saved_input_radix = input_radix;
+
+ if (variable_editable (var) && !var->error)
+ {
+ char *s;
+ int i;
+ value_ptr temp;
+
+ input_radix = 10; /* ALWAYS reset to decimal temporarily */
+ s = Tcl_GetStringFromObj (objv[2], NULL);
+ r = GDB_parse_exp_1 (&s, 0, 0, &exp);
+ if (r != GDB_OK)
+ return TCL_ERROR;
+ if (GDB_evaluate_expression (exp, &value) != GDB_OK)
+ return TCL_ERROR;
+
+ /* If our parent is "public", "private", or "protected", we could
+ be asking to modify the value of a baseclass. If so, we need to
+ adjust our address by the offset of our baseclass in the subclass,
+ since VALUE_ADDRESS (var->value) points at the start of the subclass.
+ For some reason, value_cast doesn't take care of this properly. */
+ temp = var->value;
+ if (var->parent != NULL && CPLUS_FAKE_CHILD (var->parent))
+ {
+ gdb_variable *super, *sub;
+ struct type *type;
+ super = var->parent->parent;
+ sub = super->parent;
+ if (sub != NULL)
+ {
+ /* Yes, it is a baseclass */
+ type = get_type_deref (sub);
+
+ if (super->index < TYPE_N_BASECLASSES (type))
+ {
+ temp = value_copy (var->value);
+ for (i = 0; i < super->index; i++)
+ offset += TYPE_LENGTH (TYPE_FIELD_TYPE (type, i));
+ }
+ }
+ }
+
+ VALUE_ADDRESS (temp) += offset;
+ val = value_assign (temp, value);
+ VALUE_ADDRESS (val) -= offset;
+ value_free (var->value);
+ release_value (val);
+ var->value = val;
+ input_radix = saved_input_radix;
+ }
+
+ Tcl_ResetResult (interp);
+ return TCL_OK;
+ }
+
+ result = my_value_of_variable (var, &str);
+ Tcl_SetObjResult (interp, str);
+
+ return result;
+}
+
+/* GDB already has a command called "value_of_variable". Sigh. */
+static int
+my_value_of_variable (var, obj)
+ gdb_variable *var;
+ Tcl_Obj **obj;
+{
+ return (*var->root->lang->value_of_variable) (var, obj);
+}
+
+/* Is this variable editable? Use the variable's type to make
+ this determination. */
+static int
+variable_editable (var)
+ gdb_variable *var;
+{
+ return (*var->root->lang->variable_editable) (var);
+}
+
+/*
+ * Call stuff. These functions are used to capture the output of gdb commands
+ * without going through the tcl interpreter.
+ */
+
+/* Retrieve gdb output in the buffer since last call. */
+static Tcl_Obj *
+get_call_output ()
+{
+ /* Clear the error flags, in case we errored. */
+ if (result_ptr != NULL)
+ result_ptr->flags &= ~GDBTK_ERROR_ONLY;
+ return fputs_obj;
+}
+
+/* Clear the output of the buffer. */
+static void
+clear_gdb_output ()
+{
+ if (fputs_obj != NULL)
+ Tcl_DecrRefCount (fputs_obj);
+
+ fputs_obj = Tcl_NewStringObj (NULL, -1);
+ Tcl_IncrRefCount (fputs_obj);
+}
+
+/* Call the gdb command "type_print", retaining its output in the buffer. */
+static int
+call_gdb_type_print (val)
+ value_ptr val;
+{
+ void (*old_hook) (const char *, struct ui_file *);
+ int result;
+
+ /* Save the old hook and install new hook */
+ old_hook = fputs_unfiltered_hook;
+ fputs_unfiltered_hook = variable_fputs;
+
+ /* Call our command with our args */
+ clear_gdb_output ();
+
+
+ if (GDB_type_print (val, "", gdb_stdout, -1) == GDB_OK)
+ result = TCL_OK;
+ else
+ result = TCL_ERROR;
+
+ /* Restore fputs hook */
+ fputs_unfiltered_hook = old_hook;
+
+ return result;
+}
+
+/* Call the gdb command "val_print", retaining its output in the buffer. */
+static int
+call_gdb_val_print (val, format)
+ value_ptr val;
+ int format;
+{
+ void (*old_hook) (const char *, struct ui_file *);
+ gdb_result r;
+ int result;
+
+ /* Save the old hook and install new hook */
+ old_hook = fputs_unfiltered_hook;
+ fputs_unfiltered_hook = variable_fputs;
+
+ /* Call our command with our args */
+ clear_gdb_output ();
+
+ if (VALUE_LAZY (val))
+ {
+ r = GDB_value_fetch_lazy (val);
+ if (r != GDB_OK)
+ {
+ fputs_unfiltered_hook = old_hook;
+ return TCL_ERROR;
+ }
+ }
+ r = GDB_val_print (VALUE_TYPE (val), VALUE_CONTENTS_RAW (val), VALUE_ADDRESS (val),
+ gdb_stdout, format, 1, 0, 0);
+ if (r == GDB_OK)
+ result = TCL_OK;
+ else
+ result = TCL_ERROR;
+
+ /* Restore fputs hook */
+ fputs_unfiltered_hook = old_hook;
+
+ return result;
+}
+
+/* The fputs_unfiltered_hook function used to save the output from one of the
+ call commands in this file. */
+static void
+variable_fputs (text, stream)
+ const char *text;
+ struct ui_file *stream;
+{
+ /* Just append everything to the fputs_obj... Issues with stderr/stdout? */
+ Tcl_AppendToObj (fputs_obj, (char *) text, -1);
+}
+
+/* Empty handler for the fputs_unfiltered_hook. Set the hook to this function
+ whenever the output is irrelevent. */
+static void
+null_fputs (text, stream)
+ const char *text;
+ struct ui_file *stream;
+{
+ return;
+}
+
+/*
+ * Miscellaneous utility functions.
+ */
+
+/* This returns the type of the variable. This skips past typedefs
+ and returns the real type of the variable. It also dereferences
+ pointers and references. */
+static struct type *
+get_type (var)
+ gdb_variable *var;
+{
+ struct type *type = NULL;
+ type = var->type;
+
+ while (type != NULL && TYPE_CODE (type) == TYPE_CODE_TYPEDEF)
+ type = TYPE_TARGET_TYPE (type);
+
+ return type;
+}
+
+/* This returns the type of the variable, dereferencing pointers, too. */
+static struct type *
+get_type_deref (var)
+ gdb_variable *var;
+{
+ struct type *type = NULL;
+
+ type = get_type (var);
+
+ if (type != NULL && (TYPE_CODE (type) == TYPE_CODE_PTR
+ || TYPE_CODE (type) == TYPE_CODE_REF))
+ type = get_target_type (type);
+
+ return type;
+}
+
+/* This returns the target type (or NULL) of TYPE, also skipping
+ past typedefs, just like get_type (). */
+static struct type *
+get_target_type (type)
+ struct type *type;
+{
+ if (type != NULL)
+ {
+ type = TYPE_TARGET_TYPE (type);
+ while (type != NULL && TYPE_CODE (type) == TYPE_CODE_TYPEDEF)
+ type = TYPE_TARGET_TYPE (type);
+ }
+
+ return type;
+}
+
+/* Get the language of variable VAR. */
+static enum vlanguage
+variable_language (var)
+ gdb_variable *var;
+{
+ enum vlanguage lang;
+
+ switch (var->root->exp->language_defn->la_language)
+ {
+ default:
+ case language_c:
+ lang = vlang_c;
+ break;
+ case language_cplus:
+ lang = vlang_cplus;
+ break;
+ case language_java:
+ lang = vlang_java;
+ break;
+ }
+
+ return lang;
+}
+
+/* This function is similar to gdb's value_equal, except that this
+ one is "safe" -- it NEVER longjmps. It determines if the VAR's
+ value is the same as VAL2. */
+static int
+my_value_equal (var, val2)
+ gdb_variable *var;
+ value_ptr val2;
+{
+ int r, err1, err2;
+ gdb_result result;
+
+ /* Special case: NULL values. If both are null, say
+ they're equal. */
+ if (var->value == NULL && val2 == NULL)
+ return 1;
+ else if (var->value == NULL || val2 == NULL)
+ return 0;
+
+ /* This is bogus, but unfortunately necessary. We must know
+ exactly what caused an error -- reading var->val or val2 -- so
+ that we can really determine if we think that something has changed. */
+ err1 = 0;
+ err2 = 0;
+ result = GDB_value_equal (var->value, var->value, &r);
+ if (result != GDB_OK)
+ err1 = 1;
+
+ result = GDB_value_equal (val2, val2, &r);
+ if (result != GDB_OK)
+ err2 = 1;
+
+ if (err1 != err2)
+ return 0;
+
+ if (GDB_value_equal (var->value, val2, &r) != GDB_OK)
+ {
+ /* An error occurred, this could have happened if
+ either val1 or val2 errored. ERR1 and ERR2 tell
+ us which of these it is. If both errored, then
+ we assume nothing has changed. If one of them is
+ valid, though, then something has changed. */
+ if (err1 == err2)
+ {
+ /* both the old and new values caused errors, so
+ we say the value did not change */
+ /* This is indeterminate, though. Perhaps we should
+ be safe and say, yes, it changed anyway?? */
+ return 1;
+ }
+ else
+ {
+ /* err2 replaces var->error since this new value
+ WILL replace the old one. */
+ var->error = err2;
+ return 0;
+ }
+ }
+
+ return r;
+}
+
+static void
+vpush (pstack, var)
+ struct vstack **pstack;
+ gdb_variable *var;
+{
+ struct vstack *s;
+
+ s = (struct vstack *) xmalloc (sizeof (struct vstack));
+ s->var = var;
+ s->next = *pstack;
+ *pstack = s;
+}
+
+static gdb_variable *
+vpop (pstack)
+ struct vstack **pstack;
+{
+ struct vstack *s;
+ gdb_variable *v;
+
+ if ((*pstack)->var == NULL && (*pstack)->next == NULL)
+ return NULL;
+
+ s = *pstack;
+ v = s->var;
+ *pstack = (*pstack)->next;
+ free (s);
+
+ return v;
+}
+
+/* Is VAR something that can change? Depending on language,
+ some variable's values never change. For example,
+ struct and unions never change values. */
+static int
+type_changeable (var)
+ gdb_variable *var;
+{
+ int r;
+ struct type *type;
+
+ r = 0;
+ if (!CPLUS_FAKE_CHILD (var))
+ {
+ type = get_type (var);
+ switch (TYPE_CODE (type))
+ {
+ case TYPE_CODE_STRUCT:
+ case TYPE_CODE_UNION:
+ r = 0;
+ break;
+
+ default:
+ r = 1;
+ }
+ }
+
+ return r;
+}
+
+/* Allocate memory and initialize a new variable */
+static gdb_variable *
+new_variable ()
+{
+ gdb_variable *var;
+
+ var = (gdb_variable *) xmalloc (sizeof (gdb_variable));
+ var->name = NULL;
+ var->obj_name = NULL;
+ var->index = -1;
+ var->type = NULL;
+ var->value = NULL;
+ var->error = 0;
+ var->num_children = -1;
+ var->parent = NULL;
+ var->children = NULL;
+ var->format = 0;
+ var->root = NULL;
+
+ return var;
+}
+
+/* Allocate memory and initialize a new root variable */
+static gdb_variable *
+new_root_variable (void)
+{
+ gdb_variable *var = new_variable ();
+ var->root = (struct variable_root *) xmalloc (sizeof (struct variable_root));;
+ var->root->lang = NULL;
+ var->root->exp = NULL;
+ var->root->valid_block = NULL;
+ var->root->frame = (CORE_ADDR) -1;
+ var->root->root = NULL;
+
+ return var;
+}
+
+/*
+ * Language-dependencies
+ */
+
+/* C */
+static int
+c_number_of_children (var)
+ gdb_variable *var;
+{
+ struct type *type;
+ struct type *target;
+ int children;
+
+ type = get_type (var);
+ target = get_target_type (type);
+ children = 0;
+
+ switch (TYPE_CODE (type))
+ {
+ case TYPE_CODE_ARRAY:
+ if (TYPE_LENGTH (type) > 0 && TYPE_LENGTH (target) > 0
+ && TYPE_ARRAY_UPPER_BOUND_TYPE (type) != BOUND_CANNOT_BE_DETERMINED)
+ children = TYPE_LENGTH (type) / TYPE_LENGTH (target);
+ else
+ children = -1;
+ break;
+
+ case TYPE_CODE_STRUCT:
+ case TYPE_CODE_UNION:
+ children = TYPE_NFIELDS (type);
+ break;
+
+ case TYPE_CODE_PTR:
+ /* This is where things get compilcated. All pointers have one child.
+ Except, of course, for struct and union ptr, which we automagically
+ dereference for the user and function ptrs, which have no children. */
+ switch (TYPE_CODE (target))
+ {
+ case TYPE_CODE_STRUCT:
+ case TYPE_CODE_UNION:
+ children = TYPE_NFIELDS (target);
+ break;
+
+ case TYPE_CODE_FUNC:
+ children = 0;
+ break;
+
+ default:
+ /* Don't dereference char* or void*. */
+ if (TYPE_NAME (target) != NULL
+ && (STREQ (TYPE_NAME (target), "char")
+ || STREQ (TYPE_NAME (target), "void")))
+ children = 0;
+ else
+ children = 1;
+ }
+ break;
+
+ default:
+ break;
+ }
+
+ return children;
+}
+
+static char *
+c_name_of_child (parent, index)
+ gdb_variable *parent;
+ int index;
+{
+ struct type *type;
+ struct type *target;
+ char *name;
+ char *string;
+
+ type = get_type (parent);
+ target = get_target_type (type);
+
+ switch (TYPE_CODE (type))
+ {
+ case TYPE_CODE_ARRAY:
+ {
+ /* We never get here unless parent->num_children is greater than 0... */
+ int len = 1;
+ while ((int) pow ((double) 10, (double) len) < index)
+ len++;
+ name = (char *) xmalloc (1 + len * sizeof (char));
+ sprintf (name, "%d", index);
+ }
+ break;
+
+ case TYPE_CODE_STRUCT:
+ case TYPE_CODE_UNION:
+ string = TYPE_FIELD_NAME (type, index);
+ name = savestring (string, strlen (string));
+ break;
+
+ case TYPE_CODE_PTR:
+ switch (TYPE_CODE (target))
+ {
+ case TYPE_CODE_STRUCT:
+ case TYPE_CODE_UNION:
+ string = TYPE_FIELD_NAME (target, index);
+ name = savestring (string, strlen (string));
+ break;
+
+ default:
+ name = (char *) xmalloc ((strlen (parent->name) + 2) * sizeof (char));
+ sprintf (name, "*%s", parent->name);
+ break;
+ }
+ }
+
+ return name;
+}
+
+static value_ptr
+c_value_of_root (var)
+ gdb_variable *var;
+{
+ value_ptr value, new_val;
+ struct frame_info *fi, *old_fi;
+ int within_scope;
+ gdb_result r;
+
+ /* Determine whether the variable is still around. */
+ if (var->root->valid_block == NULL)
+ within_scope = 1;
+ else
+ {
+ GDB_reinit_frame_cache ();
+ r = GDB_find_frame_addr_in_frame_chain (var->root->frame, &fi);
+ if (r != GDB_OK)
+ fi = NULL;
+ within_scope = fi != NULL;
+ /* FIXME: GDB_select_frame could fail */
+ if (within_scope)
+ GDB_select_frame (fi, -1);
+ }
+
+ if (within_scope)
+ {
+ struct type *type = get_type (var);
+ if (GDB_evaluate_expression (var->root->exp, &new_val) == GDB_OK)
+ {
+ if (VALUE_LAZY (new_val))
+ {
+ if (GDB_value_fetch_lazy (new_val) != GDB_OK)
+ var->error = 1;
+ else
+ var->error = 0;
+ }
+ }
+ else
+ var->error = 1;
+
+ release_value (new_val);
+ return new_val;
+ }
+
+ return NULL;
+}
+
+static value_ptr
+c_value_of_child (parent, index)
+ gdb_variable *parent;
+ int index;
+{
+ value_ptr value, temp;
+ struct type *type, *target;
+ gdb_result r;
+ char *name;
+
+ type = get_type (parent);
+ target = get_target_type (type);
+ name = name_of_child (parent, index);
+ temp = parent->value;
+ value = NULL;
+
+ if (temp != NULL)
+ {
+ switch (TYPE_CODE (type))
+ {
+ case TYPE_CODE_ARRAY:
+ r = GDB_value_slice (temp, index, 1, &value);
+ r = GDB_value_coerce_array (value, &temp);
+ r = GDB_value_ind (temp, &value);
+ break;
+
+ case TYPE_CODE_STRUCT:
+ case TYPE_CODE_UNION:
+ r = GDB_value_struct_elt (&temp, NULL, name, NULL, "vstructure", &value);
+ break;
+
+ case TYPE_CODE_PTR:
+ switch (TYPE_CODE (target))
+ {
+ case TYPE_CODE_STRUCT:
+ case TYPE_CODE_UNION:
+ r = GDB_value_struct_elt (&temp, NULL, name, NULL, "vstructure", &value);
+ break;
+
+ default:
+ r = GDB_value_ind (temp, &value);
+ break;
+ }
+ break;
+
+ default:
+ break;
+ }
+ }
+
+ if (value != NULL)
+ release_value (value);
+
+ return value;
+}
+
+static struct type *
+c_type_of_child (parent, index)
+ gdb_variable *parent;
+ int index;
+{
+ struct type *type;
+ gdb_result r;
+ char *name = name_of_child (parent, index);
+
+ switch (TYPE_CODE (parent->type))
+ {
+ case TYPE_CODE_ARRAY:
+ type = TYPE_TARGET_TYPE (parent->type);
+ break;
+
+ case TYPE_CODE_STRUCT:
+ case TYPE_CODE_UNION:
+ type = lookup_struct_elt_type (parent->type, name, 0);
+ break;
+
+ case TYPE_CODE_PTR:
+ switch (TYPE_CODE (TYPE_TARGET_TYPE (parent->type)))
+ {
+ case TYPE_CODE_STRUCT:
+ case TYPE_CODE_UNION:
+ type = lookup_struct_elt_type (parent->type, name, 0);
+ break;
+
+ default:
+ type = TYPE_TARGET_TYPE (parent->type);
+ break;
+ }
+
+ default:
+ break;
+ }
+
+ return type;
+}
+
+static int
+c_variable_editable (var)
+ gdb_variable *var;
+{
+ switch (TYPE_CODE (get_type (var)))
+ {
+ case TYPE_CODE_STRUCT:
+ case TYPE_CODE_UNION:
+ case TYPE_CODE_ARRAY:
+ case TYPE_CODE_FUNC:
+ case TYPE_CODE_MEMBER:
+ case TYPE_CODE_METHOD:
+ return 0;
+ break;
+
+ default:
+ return 1;
+ break;
+ }
+}
+
+static int
+c_value_of_variable (var, obj)
+ gdb_variable *var;
+ Tcl_Obj **obj;
+{
+ struct type *type;
+ value_ptr val;
+ int result;
+
+ if (var->value != NULL)
+ val = var->value;
+ else
+ {
+ /* This can happen if we attempt to get the value of a struct
+ member when the parent is an invalid pointer.
+
+ GDB reports the error as the error derived from accessing the
+ parent, but we don't have access to that here... */
+ *obj = Tcl_NewStringObj ("???", -1);
+ return TCL_ERROR;
+ }
+
+ /* BOGUS: if val_print sees a struct/class, it will print out its
+ children instead of "{...}" */
+ type = get_type (var);
+ result = TCL_OK;
+ switch (TYPE_CODE (type))
+ {
+ case TYPE_CODE_STRUCT:
+ case TYPE_CODE_UNION:
+ *obj = Tcl_NewStringObj ("{...}", -1);
+ break;
+
+ case TYPE_CODE_ARRAY:
+ {
+ char number[16];
+ *obj = Tcl_NewStringObj (NULL, 0);
+ sprintf (number, "%d", var->num_children);
+ Tcl_AppendStringsToObj (*obj, "[", number, "]", NULL);
+ }
+ break;
+
+ default:
+ result = call_gdb_val_print (val, format_code[(int) var->format]);
+ *obj = get_call_output ();
+ break;
+ }
+
+ return result;
+}
+
+
+/* C++ */
+
+static int
+cplus_number_of_children (var)
+ gdb_variable *var;
+{
+ struct type *type;
+ int children, dont_know;
+
+ dont_know = 1;
+ children = 0;
+
+ if (!CPLUS_FAKE_CHILD (var))
+ {
+ type = get_type_deref (var);
+
+ switch (TYPE_CODE (type))
+ {
+ case TYPE_CODE_STRUCT:
+ case TYPE_CODE_UNION:
+ {
+ int kids[3];
+
+ cplus_class_num_children (type, kids);
+ if (kids[v_public] != 0)
+ children++;
+ if (kids[v_private] != 0)
+ children++;
+ if (kids[v_protected] != 0)
+ children++;
+
+ /* Add any baseclasses */
+ children += TYPE_N_BASECLASSES (type);
+ dont_know = 0;
+
+ /* FIXME: save children in var */
+ }
+ break;
+ }
+ }
+ else
+ {
+ int kids[3];
+
+ type = get_type_deref (var->parent);
+
+ cplus_class_num_children (type, kids);
+ if (STREQ (var->name, "public"))
+ children = kids[v_public];
+ else if (STREQ (var->name, "private"))
+ children = kids[v_private];
+ else
+ children = kids[v_protected];
+ dont_know = 0;
+ }
+
+ if (dont_know)
+ children = c_number_of_children (var);
+
+ return children;
+}
+
+/* Compute # of public, private, and protected variables in this class.
+ That means we need to descend into all baseclasses and find out
+ how many are there, too. */
+static void
+cplus_class_num_children (type, children)
+ struct type *type;
+ int children[3];
+{
+ int i;
+
+ children[v_public] = 0;
+ children[v_private] = 0;
+ children[v_protected] = 0;
+
+ for (i = TYPE_N_BASECLASSES (type); i < TYPE_NFIELDS (type); i++)
+ {
+ /* If we have a virtual table pointer, omit it. */
+ if (TYPE_VPTR_BASETYPE (type) == type
+ && TYPE_VPTR_FIELDNO (type) == i)
+ continue;
+
+ if (TYPE_FIELD_PROTECTED (type, i))
+ children[v_protected]++;
+ else if (TYPE_FIELD_PRIVATE (type, i))
+ children[v_private]++;
+ else
+ children[v_public]++;
+ }
+}
+
+static char *
+cplus_name_of_child (parent, index)
+ gdb_variable *parent;
+ int index;
+{
+ char *name;
+ struct type *type;
+ int children[3];
+
+ if (CPLUS_FAKE_CHILD (parent))
+ {
+ /* Looking for children of public, private, or protected. */
+ type = get_type_deref (parent->parent);
+ }
+ else
+ type = get_type_deref (parent);
+
+ name = NULL;
+ switch (TYPE_CODE (type))
+ {
+ case TYPE_CODE_STRUCT:
+ case TYPE_CODE_UNION:
+ cplus_class_num_children (type, children);
+
+ if (CPLUS_FAKE_CHILD (parent))
+ {
+ /* FIXME: This assumes that type orders
+ inherited, public, private, protected */
+ int i = index + TYPE_N_BASECLASSES (type);
+ if (STREQ (parent->name, "private") || STREQ (parent->name, "protected"))
+ i += children[v_public];
+ if (STREQ (parent->name, "protected"))
+ i += children[v_private];
+
+ name = TYPE_FIELD_NAME (type, i);
+ }
+ else if (index < TYPE_N_BASECLASSES (type))
+ name = TYPE_FIELD_NAME (type, index);
+ else
+ {
+ /* Everything beyond the baseclasses can
+ only be "public", "private", or "protected" */
+ index -= TYPE_N_BASECLASSES (type);
+ switch (index)
+ {
+ case 0:
+ if (children[v_public] != 0)
+ {
+ name = "public";
+ break;
+ }
+ case 1:
+ if (children[v_private] != 0)
+ {
+ name = "private";
+ break;
+ }
+ case 2:
+ if (children[v_protected] != 0)
+ {
+ name = "protected";
+ break;
+ }
+ default:
+ /* error! */
+ break;
+ }
+ }
+ break;
+
+ default:
+ break;
+ }
+
+ if (name == NULL)
+ return c_name_of_child (parent, index);
+ else
+ {
+ if (name != NULL)
+ name = savestring (name, strlen (name));
+ }
+
+ return name;
+}
+
+static value_ptr
+cplus_value_of_root (var)
+ gdb_variable *var;
+{
+ return c_value_of_root (var);
+}
+
+static value_ptr
+cplus_value_of_child (parent, index)
+ gdb_variable *parent;
+ int index;
+{
+ struct type *type;
+ value_ptr value;
+ char *name;
+ gdb_result r;
+
+ if (CPLUS_FAKE_CHILD (parent))
+ type = get_type_deref (parent->parent);
+ else
+ type = get_type_deref (parent);
+
+ value = NULL;
+ name = name_of_child (parent, index);
+
+ switch (TYPE_CODE (type))
+ {
+ case TYPE_CODE_STRUCT:
+ case TYPE_CODE_UNION:
+ if (CPLUS_FAKE_CHILD (parent))
+ {
+ value_ptr temp = parent->parent->value;
+ r = GDB_value_struct_elt (&temp, NULL, name,
+ NULL, "cplus_structure", &value);
+ if (r == GDB_OK)
+ release_value (value);
+ }
+ else if (index >= TYPE_N_BASECLASSES (type))
+ {
+ /* public, private, or protected */
+ return NULL;
+ }
+ else
+ {
+ /* Baseclass */
+ if (parent->value != NULL)
+ {
+ value_ptr temp;
+ int i;
+
+ if (TYPE_CODE (VALUE_TYPE (parent->value)) == TYPE_CODE_PTR
+ || TYPE_CODE (VALUE_TYPE (parent->value)) == TYPE_CODE_REF)
+ GDB_value_ind (parent->value, &temp);
+ else
+ temp = parent->value;
+
+ r = GDB_value_cast (TYPE_FIELD_TYPE (type, index), temp, &value);
+ if (r == GDB_OK)
+ release_value (value);
+ }
+ }
+ break;
+ }
+
+ if (value == NULL)
+ return c_value_of_child (parent, index);
+
+ return value;
+}
+
+static struct type *
+cplus_type_of_child (parent, index)
+ gdb_variable *parent;
+ int index;
+{
+ struct type *type, *t;
+ gdb_result r;
+
+ t = get_type_deref (parent);
+ type = NULL;
+ switch (TYPE_CODE (t))
+ {
+ case TYPE_CODE_STRUCT:
+ case TYPE_CODE_UNION:
+ if (index >= TYPE_N_BASECLASSES (t))
+ {
+ /* special */
+ return NULL;
+ }
+ else
+ {
+ /* Baseclass */
+ type = TYPE_FIELD_TYPE (t, index);
+ }
+ break;
+
+ default:
+ break;
+ }
+
+ if (type == NULL)
+ return c_type_of_child (parent, index);
+
+ return type;
+}
+
+static int
+cplus_variable_editable (var)
+ gdb_variable *var;
+{
+ if (CPLUS_FAKE_CHILD (var))
+ return 0;
+
+ return c_variable_editable (var);
+}
+
+static int
+cplus_value_of_variable (var, obj)
+ gdb_variable *var;
+ Tcl_Obj **obj;
+{
+
+ /* If we have one of our special types, don't print out
+ any value. */
+ if (CPLUS_FAKE_CHILD (var))
+ {
+ *obj = Tcl_NewStringObj ("", -1);
+ return TCL_OK;
+ }
+
+ return c_value_of_variable (var, obj);
+}
+
+/* Java */
+
+static int
+java_number_of_children (var)
+ gdb_variable *var;
+{
+ return cplus_number_of_children (var);
+}
+
+static char *
+java_name_of_child (parent, index)
+ gdb_variable *parent;
+ int index;
+{
+ char *name, *p;
+
+ name = cplus_name_of_child (parent, index);
+ p = name;
+
+ while (*p != '\000')
+ {
+ if (*p == '.')
+ *p = '-';
+ p++;
+ }
+
+ return name;
+}
+
+static value_ptr
+java_value_of_root (var)
+ gdb_variable *var;
+{
+ return cplus_value_of_root (var);
+}
+
+static value_ptr
+java_value_of_child (parent, index)
+ gdb_variable *parent;
+ int index;
+{
+ return cplus_value_of_child (parent, index);
+}
+
+static struct type *
+java_type_of_child (parent, index)
+ gdb_variable *parent;
+ int index;
+{
+ return cplus_type_of_child (parent, index);
+}
+
+static int
+java_variable_editable (var)
+ gdb_variable *var;
+{
+ return cplus_variable_editable (var);
+}
+
+static int
+java_value_of_variable (var, obj)
+ gdb_variable *var;
+ Tcl_Obj **obj;
+{
+ return cplus_value_of_variable (var, obj);
+}
+
+/* Local variables: */
+/* change-log-default-name: "ChangeLog-gdbtk" */
+/* End: */
diff --git a/gdb/gdbtk/generic/gdbtk-varobj.c b/gdb/gdbtk/generic/gdbtk-varobj.c
index a527cd4b765..2fadc73bfc4 100644
--- a/gdb/gdbtk/generic/gdbtk-varobj.c
+++ b/gdb/gdbtk/generic/gdbtk-varobj.c
@@ -1,5 +1,5 @@
/* Variable user interface layer for GDB, the GNU debugger.
- Copyright (C) 1999, 2000, 2001, 2002, 2008 Free Software Foundation, Inc.
+ Copyright 1999 Free Software Foundation, Inc.
This file is part of GDB.
@@ -15,24 +15,22 @@
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
- Foundation, Inc., 51 Franklin Street, Fifth Floor,
- Boston, MA 02110-1301, USA. */
+ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#include "defs.h"
#include "value.h"
-#include "gdb_string.h"
+
#include "varobj.h"
#include <tcl.h>
#include "gdbtk.h"
-#include "gdbtk-cmds.h"
-#include "gdbtk-wrapper.h"
+
/*
* Public functions defined in this file
*/
-int gdb_variable_init (Tcl_Interp *);
+int gdb_variable_init PARAMS ((Tcl_Interp *));
/*
* Private functions defined in this file
@@ -40,54 +38,59 @@ int gdb_variable_init (Tcl_Interp *);
/* Entries into this file */
-static int gdb_variable_command (ClientData, Tcl_Interp *, int,
- Tcl_Obj * CONST[]);
+static int gdb_variable_command PARAMS ((ClientData, Tcl_Interp *, int,
+ Tcl_Obj * CONST[]));
-static int variable_obj_command (ClientData, Tcl_Interp *, int,
- Tcl_Obj * CONST[]);
+static int variable_obj_command PARAMS ((ClientData, Tcl_Interp *, int,
+ Tcl_Obj * CONST[]));
/* Variable object subcommands */
-static int variable_create (Tcl_Interp *, int, Tcl_Obj * CONST[]);
+static int variable_create PARAMS ((Tcl_Interp *, int, Tcl_Obj * CONST[]));
-static void variable_delete (Tcl_Interp *, struct varobj *, int);
+static void variable_delete PARAMS ((Tcl_Interp *, struct varobj *, int));
-static Tcl_Obj *variable_children (Tcl_Interp *, struct varobj *);
+static Tcl_Obj *variable_children PARAMS ((Tcl_Interp *, struct varobj *));
-static int variable_format (Tcl_Interp *, int, Tcl_Obj * CONST[],
- struct varobj *);
+static int variable_format PARAMS ((Tcl_Interp *, int, Tcl_Obj * CONST[],
+ struct varobj *));
-static int variable_type (Tcl_Interp *, int, Tcl_Obj * CONST[],
- struct varobj *);
+static int variable_type PARAMS ((Tcl_Interp *, int, Tcl_Obj * CONST[],
+ struct varobj *));
-static int variable_value (Tcl_Interp *, int, Tcl_Obj * CONST[],
- struct varobj *);
+static int variable_value PARAMS ((Tcl_Interp *, int, Tcl_Obj * CONST[],
+ struct varobj *));
-static Tcl_Obj *variable_update (Tcl_Interp * interp, struct varobj **var);
+static Tcl_Obj *variable_update PARAMS ((Tcl_Interp * interp, struct varobj * var));
/* Helper functions for the above subcommands. */
-static void install_variable (Tcl_Interp *, char *);
+static void install_variable PARAMS ((Tcl_Interp *, char *, struct varobj *));
-static void uninstall_variable (Tcl_Interp *, char *);
+static void uninstall_variable PARAMS ((Tcl_Interp *, char *));
/* String representations of gdb's format codes */
-static char *format_string[] =
- {"natural", "binary", "decimal", "hexadecimal", "octal"};
+char *format_string[] =
+{"natural", "binary", "decimal", "hexadecimal", "octal"};
+#if defined(FREEIF)
+#undef FREEIF
+#endif
+#define FREEIF(x) if (x != NULL) free((char *) (x))
/* Initialize the variable code. This function should be called once
to install and initialize the variable code into the interpreter. */
int
-gdb_variable_init (Tcl_Interp *interp)
+gdb_variable_init (interp)
+ Tcl_Interp *interp;
{
Tcl_Command result;
static int initialized = 0;
if (!initialized)
{
- result = Tcl_CreateObjCommand (interp, "gdb_variable", gdbtk_call_wrapper,
- (ClientData) gdb_variable_command, NULL);
+ result = Tcl_CreateObjCommand (interp, "gdb_variable", call_wrapper,
+ (ClientData) gdb_variable_command, NULL);
if (result == NULL)
return TCL_ERROR;
@@ -111,13 +114,16 @@ gdb_variable_init (Tcl_Interp *interp)
EXPR = the gdb expression for which to create a variable. This will
be the most common usage.
FRAME = the frame defining the scope of the variable.
-*/
+ */
static int
-gdb_variable_command (ClientData clientData, Tcl_Interp *interp,
- int objc, Tcl_Obj *CONST objv[])
+gdb_variable_command (clientData, interp, objc, objv)
+ ClientData clientData;
+ Tcl_Interp *interp;
+ int objc;
+ Tcl_Obj *CONST objv[];
{
- static const char *commands[] =
- {"create", "list", NULL};
+ static char *commands[] =
+ {"create", "list", NULL};
enum commands_enum
{
VARIABLE_CREATE, VARIABLE_LIST
@@ -162,10 +168,13 @@ gdb_variable_command (ClientData clientData, Tcl_Interp *interp,
- type get the type of this variable
- value get/set the value of this variable
- editable is this variable editable?
-*/
+ */
static int
-variable_obj_command (ClientData clientData, Tcl_Interp *interp,
- int objc, Tcl_Obj *CONST objv[])
+variable_obj_command (clientData, interp, objc, objv)
+ ClientData clientData;
+ Tcl_Interp *interp;
+ int objc;
+ Tcl_Obj *CONST objv[];
{
enum commands_enum
{
@@ -179,29 +188,21 @@ variable_obj_command (ClientData clientData, Tcl_Interp *interp,
VARIABLE_EDITABLE,
VARIABLE_UPDATE
};
- static const char *commands[] =
- {
- "delete",
- "numChildren",
- "children",
- "format",
- "type",
- "value",
- "name",
- "editable",
- "update",
- NULL
- };
- struct varobj *var;
- char *varobj_name;
+ static char *commands[] =
+ {
+ "delete",
+ "numChildren",
+ "children",
+ "format",
+ "type",
+ "value",
+ "name",
+ "editable",
+ "update",
+ NULL
+ };
+ struct varobj *var = (struct varobj *) clientData;
int index, result;
-
- /* Get the current handle for this variable token (name). */
- varobj_name = Tcl_GetStringFromObj (objv[0], NULL);
- if (varobj_name == NULL)
- return TCL_ERROR;
- var = varobj_get_handle (varobj_name);
-
if (objc < 2)
{
@@ -257,19 +258,19 @@ variable_obj_command (ClientData clientData, Tcl_Interp *interp,
{
char *name = varobj_get_expression (var);
Tcl_SetObjResult (interp, Tcl_NewStringObj (name, -1));
- xfree (name);
+ FREEIF (name);
}
break;
case VARIABLE_EDITABLE:
- Tcl_SetObjResult (interp,
- Tcl_NewIntObj (varobj_get_attributes (var) & 0x00000001 /* Editable? */ ));
+ Tcl_SetObjResult (interp, Tcl_NewIntObj (
+ varobj_get_attributes (var) & 0x00000001 /* Editable? */ ));
break;
case VARIABLE_UPDATE:
/* Only root variables can be updated */
{
- Tcl_Obj *obj = variable_update (interp, &var);
+ Tcl_Obj *obj = variable_update (interp, var);
Tcl_SetObjResult (interp, obj);
}
break;
@@ -288,20 +289,22 @@ variable_obj_command (ClientData clientData, Tcl_Interp *interp,
/* This function is responsible for processing the user's specifications
and constructing a variable object. */
static int
-variable_create (Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[])
+variable_create (interp, objc, objv)
+ Tcl_Interp *interp;
+ int objc;
+ Tcl_Obj *CONST objv[];
{
enum create_opts
{
CREATE_EXPR, CREATE_FRAME
};
- static const char *create_options[] =
- {"-expr", "-frame", NULL};
+ static char *create_options[] =
+ {"-expr", "-frame", NULL};
struct varobj *var;
char *name;
char *obj_name;
int index;
CORE_ADDR frame = (CORE_ADDR) -1;
- int how_specified = USE_SELECTED_FRAME;
/* REMINDER: This command may be invoked in the following ways:
gdb_variable create [NAME] [-expr EXPR] [-frame FRAME]
@@ -311,7 +314,7 @@ variable_create (Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[])
EXPR = the gdb expression for which to create a variable. This will
be the most common usage.
FRAME = the address of the frame defining the variable's scope
- */
+ */
name = NULL;
if (objc)
name = Tcl_GetStringFromObj (objv[0], NULL);
@@ -335,7 +338,7 @@ variable_create (Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[])
if (Tcl_GetIndexFromObj (interp, objv[0], create_options, "options",
0, &index) != TCL_OK)
{
- xfree (obj_name);
+ free (obj_name);
result_ptr->flags |= GDBTK_IN_TCL_RESULT;
return TCL_ERROR;
}
@@ -352,8 +355,7 @@ variable_create (Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[])
{
char *str;
str = Tcl_GetStringFromObj (objv[1], NULL);
- frame = string_to_core_addr (str);
- how_specified = USE_SPECIFIED_FRAME;
+ frame = parse_and_eval_address (str);
objc--;
objv++;
}
@@ -368,29 +370,31 @@ variable_create (Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[])
}
/* Create the variable */
- var = varobj_create (obj_name, name, frame, how_specified);
+ var = varobj_create (obj_name, name, frame);
if (var != NULL)
{
/* Install a command into the interpreter that represents this
object */
- install_variable (interp, obj_name);
+ install_variable (interp, obj_name, var);
Tcl_SetObjResult (interp, Tcl_NewStringObj (obj_name, -1));
result_ptr->flags |= GDBTK_IN_TCL_RESULT;
- xfree (obj_name);
+ free (obj_name);
return TCL_OK;
}
- xfree (obj_name);
+ free (obj_name);
return TCL_ERROR;
}
/* Delete the variable object VAR and its children */
/* If only_children_p, Delete only the children associated with the object. */
static void
-variable_delete (Tcl_Interp *interp, struct varobj *var,
- int only_children_p)
+variable_delete (interp, var, only_children_p)
+ Tcl_Interp *interp;
+ struct varobj *var;
+ int only_children_p;
{
char **dellist;
char **vc;
@@ -401,36 +405,40 @@ variable_delete (Tcl_Interp *interp, struct varobj *var,
while (*vc != NULL)
{
uninstall_variable (interp, *vc);
- xfree (*vc);
+ free (*vc);
vc++;
}
- xfree (dellist);
+ FREEIF (dellist);
}
/* Return a list of all the children of VAR, creating them if necessary. */
static Tcl_Obj *
-variable_children (Tcl_Interp *interp, struct varobj *var)
+variable_children (interp, var)
+ Tcl_Interp *interp;
+ struct varobj *var;
{
Tcl_Obj *list;
- VEC(varobj_p) *children;
- struct varobj *child;
+ struct varobj **childlist;
+ struct varobj **vc;
char *childname;
- int ix;
list = Tcl_NewListObj (0, NULL);
- children = varobj_list_children (var);
+ varobj_list_children (var, &childlist);
- for (ix = 0; VEC_iterate (varobj_p, children, ix, child); ++ix)
+ vc = childlist;
+ while (*vc != NULL)
{
- childname = varobj_get_objname (child);
+ childname = varobj_get_objname (*vc);
/* Add child to result list and install the Tcl command for it. */
Tcl_ListObjAppendElement (NULL, list,
Tcl_NewStringObj (childname, -1));
- install_variable (interp, childname);
+ install_variable (interp, childname, *vc);
+ vc++;
}
+ FREEIF (childlist);
return list;
}
@@ -438,65 +446,65 @@ variable_children (Tcl_Interp *interp, struct varobj *var)
/* NOTE: Only root variables can be updated... */
static Tcl_Obj *
-variable_update (Tcl_Interp *interp, struct varobj **var)
+variable_update (interp, var)
+ Tcl_Interp *interp;
+ struct varobj *var;
{
- int i;
Tcl_Obj *changed;
- VEC (varobj_update_result) *changes;
- varobj_update_result *r;
-
- if (GDB_varobj_update (var, 1, &changes) != GDB_OK)
- return Tcl_NewStringObj ("-1", -1);
+ struct varobj **changelist;
+ struct varobj **vc;
changed = Tcl_NewListObj (0, NULL);
- for (i = 0; VEC_iterate (varobj_update_result, changes, i, r); ++i)
- {
- switch (r->status)
- {
- case VAROBJ_IN_SCOPE:
- {
- Tcl_Obj *var
- = Tcl_NewStringObj (varobj_get_objname (r->varobj), -1);
- Tcl_ListObjAppendElement (NULL, changed, var);
- }
- break;
- case VAROBJ_NOT_IN_SCOPE:
- case VAROBJ_INVALID:
- /* These need to be (re-)implemented in the UI */
- break;
- }
+ /* varobj_update() can return -1 if the variable is no longer around,
+ i.e. we stepped out of the frame in which a local existed. */
+ if (varobj_update (var, &changelist) == -1)
+ return changed;
+
+ vc = changelist;
+ while (*vc != NULL)
+ {
+ /* Add changed variable object to result list */
+ Tcl_ListObjAppendElement (NULL, changed,
+ Tcl_NewStringObj (varobj_get_objname (*vc), -1));
+ vc++;
}
+ FREEIF (changelist);
return changed;
}
/* This implements the format object command allowing
the querying or setting of the object's display format. */
static int
-variable_format (Tcl_Interp *interp, int objc,
- Tcl_Obj *CONST objv[], struct varobj *var)
+variable_format (interp, objc, objv, var)
+ Tcl_Interp *interp;
+ int objc;
+ Tcl_Obj *CONST objv[];
+ struct varobj *var;
{
if (objc > 2)
{
/* Set the format of VAR to given format */
int len;
char *fmt = Tcl_GetStringFromObj (objv[2], &len);
- if (strncmp (fmt, "natural", len) == 0)
+ if (STREQN (fmt, "natural", len))
varobj_set_display_format (var, FORMAT_NATURAL);
- else if (strncmp (fmt, "binary", len) == 0)
+ else if (STREQN (fmt, "binary", len))
varobj_set_display_format (var, FORMAT_BINARY);
- else if (strncmp (fmt, "decimal", len) == 0)
+ else if (STREQN (fmt, "decimal", len))
varobj_set_display_format (var, FORMAT_DECIMAL);
- else if (strncmp (fmt, "hexadecimal", len) == 0)
+ else if (STREQN (fmt, "hexadecimal", len))
varobj_set_display_format (var, FORMAT_HEXADECIMAL);
- else if (strncmp (fmt, "octal", len) == 0)
+ else if (STREQN (fmt, "octal", len))
varobj_set_display_format (var, FORMAT_OCTAL);
else
{
- gdbtk_set_result (interp, "unknown display format \"",
- fmt, "\": must be: \"natural\", \"binary\""
- ", \"decimal\", \"hexadecimal\", or \"octal\"");
+ Tcl_Obj *obj = Tcl_NewStringObj (NULL, 0);
+ Tcl_AppendStringsToObj (obj, "unknown display format \"",
+ fmt, "\": must be: \"natural\", \"binary\""
+ ", \"decimal\", \"hexadecimal\", or \"octal\"", NULL);
+ Tcl_SetObjResult (interp, obj);
return TCL_ERROR;
}
}
@@ -507,7 +515,7 @@ variable_format (Tcl_Interp *interp, int objc,
/* FIXME: Use varobj_format_string[] instead */
fmt = Tcl_NewStringObj (
- format_string[(int) varobj_get_display_format (var)], -1);
+ format_string[(int) varobj_get_display_format (var)], -1);
Tcl_SetObjResult (interp, fmt);
}
@@ -517,12 +525,13 @@ variable_format (Tcl_Interp *interp, int objc,
/* This function implements the type object command, which returns the type of a
variable in the interpreter (or an error). */
static int
-variable_type (Tcl_Interp *interp, int objc,
- Tcl_Obj *CONST objv[], struct varobj *var)
+variable_type (interp, objc, objv, var)
+ Tcl_Interp *interp;
+ int objc;
+ Tcl_Obj *CONST objv[];
+ struct varobj *var;
{
- const char *first;
- const char *last;
- char *string;
+ char *first, *last, *string;
Tcl_RegExp regexp;
/* For the "fake" variables, do not return a type.
@@ -546,19 +555,22 @@ variable_type (Tcl_Interp *interp, int objc,
Tcl_RegExpRange (regexp, 0, &first, &last);
if (*(first - 1) == ' ')
first--;
- string[first - string] = '\0';
+ *first = '\0';
}
Tcl_SetObjResult (interp, Tcl_NewStringObj (string, -1));
- xfree (string);
+ FREEIF (string);
return TCL_OK;
}
/* This function implements the value object command, which allows an object's
value to be queried or set. */
static int
-variable_value (Tcl_Interp *interp, int objc,
- Tcl_Obj *CONST objv[], struct varobj *var)
+variable_value (interp, objc, objv, var)
+ Tcl_Interp *interp;
+ int objc;
+ Tcl_Obj *CONST objv[];
+ struct varobj *var;
{
char *r;
@@ -574,10 +586,7 @@ variable_value (Tcl_Interp *interp, int objc,
s = Tcl_GetStringFromObj (objv[2], NULL);
if (!varobj_set_value (var, s))
- {
- gdbtk_set_result (interp, "Could not assign expression to variable object");
- return TCL_ERROR;
- }
+ return TCL_ERROR;
}
Tcl_ResetResult (interp);
@@ -587,14 +596,11 @@ variable_value (Tcl_Interp *interp, int objc,
r = varobj_get_value (var);
if (r == NULL)
- {
- gdbtk_set_result (interp, "Could not read variable object value after assignment");
- return TCL_ERROR;
- }
+ return TCL_ERROR;
else
{
Tcl_SetObjResult (interp, Tcl_NewStringObj (r, -1));
- xfree (r);
+ FREEIF (r);
return TCL_OK;
}
}
@@ -604,16 +610,24 @@ variable_value (Tcl_Interp *interp, int objc,
/* Install the given variable VAR into the tcl interpreter with
the object name NAME. */
static void
-install_variable (Tcl_Interp *interp, char *name)
+install_variable (interp, name, var)
+ Tcl_Interp *interp;
+ char *name;
+ struct varobj *var;
{
Tcl_CreateObjCommand (interp, name, variable_obj_command,
- NULL, NULL);
+ (ClientData) var, NULL);
}
/* Unistall the object VAR in the tcl interpreter. */
static void
-uninstall_variable (Tcl_Interp *interp, char *varname)
+uninstall_variable (interp, varname)
+ Tcl_Interp *interp;
+ char *varname;
{
Tcl_DeleteCommand (interp, varname);
}
-
+
+/* Local variables: */
+/* change-log-default-name: "ChangeLog-gdbtk" */
+/* End: */
diff --git a/gdb/gdbtk/generic/gdbtk-wrapper.c b/gdb/gdbtk/generic/gdbtk-wrapper.c
index b2252fb2cc6..b18825e6a6f 100644
--- a/gdb/gdbtk/generic/gdbtk-wrapper.c
+++ b/gdb/gdbtk/generic/gdbtk-wrapper.c
@@ -1,5 +1,5 @@
/* longjmp-free interface between gdb and gdbtk.
- Copyright (C) 1999, 2000, 2002, 2008 Free Software Foundation, Inc.
+ Copyright (C) 1999-2000 Free Software Foundation, Inc.
This file is part of GDB.
@@ -15,127 +15,108 @@
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
- Foundation, Inc., 51 Franklin Street, Fifth Floor,
- Boston, MA 02110-1301, USA. */
+ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#include "defs.h"
#include "frame.h"
#include "value.h"
-#include "varobj.h"
-#include "block.h"
-#include "exceptions.h"
-#include "language.h"
#include "gdbtk-wrapper.h"
/*
* Wrapper functions exported to the world
*/
-gdb_result GDB_value_fetch_lazy (value_ptr);
+gdb_result GDB_value_fetch_lazy PARAMS ((value_ptr));
-gdb_result GDB_evaluate_expression (struct expression *, value_ptr *);
+gdb_result GDB_evaluate_expression PARAMS ((struct expression *, value_ptr *));
gdb_result GDB_type_print (value_ptr, char *, struct ui_file *, int);
-gdb_result GDB_val_print (struct type *type, char *valaddr,
+gdb_result GDB_val_print (struct type * type, char *valaddr,
CORE_ADDR address, struct ui_file *stream,
int format, int deref_ref, int recurse,
enum val_prettyprint pretty);
-gdb_result GDB_value_equal (value_ptr, value_ptr, int *);
+gdb_result GDB_select_frame PARAMS ((struct frame_info *, int));
-gdb_result GDB_parse_exp_1 (char **stringptr, struct block *block, int comma,
- struct expression **result);
+gdb_result GDB_value_equal PARAMS ((value_ptr, value_ptr, int *));
-gdb_result GDB_evaluate_type (struct expression *exp, value_ptr * result);
+gdb_result GDB_parse_exp_1 PARAMS ((char **stringptr, struct block * block, int comma,
+ struct expression ** result));
-gdb_result GDB_block_for_pc (CORE_ADDR pc, struct block **result);
+gdb_result GDB_evaluate_type PARAMS ((struct expression * exp, value_ptr * result));
-gdb_result GDB_block_innermost_frame (struct block *block,
- struct frame_info **result);
+gdb_result GDB_block_for_pc PARAMS ((CORE_ADDR pc, struct block ** result));
-gdb_result GDB_reinit_frame_cache (void);
+gdb_result GDB_block_innermost_frame PARAMS ((struct block * block,
+ struct frame_info ** result));
-gdb_result GDB_value_ind (value_ptr val, value_ptr * rval);
+gdb_result GDB_reinit_frame_cache PARAMS ((void));
-gdb_result GDB_value_slice (value_ptr val, int low, int num,
- value_ptr * rval);
+gdb_result GDB_find_frame_addr_in_frame_chain PARAMS ((CORE_ADDR addr,
+ struct frame_info ** result));
-gdb_result GDB_value_coerce_array (value_ptr val, value_ptr * rval);
+gdb_result GDB_value_ind PARAMS ((value_ptr val, value_ptr * rval));
-gdb_result GDB_value_struct_elt (value_ptr * argp, value_ptr * args,
- char *name, int *static_memfunc,
- char *err, value_ptr * rval);
+gdb_result GDB_value_slice PARAMS ((value_ptr val, int low, int num,
+ value_ptr * rval));
-gdb_result GDB_value_cast (struct type *type, value_ptr val,
- value_ptr * rval);
+gdb_result GDB_value_coerce_array PARAMS ((value_ptr val, value_ptr * rval));
-gdb_result GDB_get_frame_block (struct frame_info *fi, struct block **rval);
+gdb_result GDB_value_struct_elt PARAMS ((value_ptr * argp, value_ptr * args,
+ char *name, int *static_memfunc,
+ char *err, value_ptr * rval));
-gdb_result GDB_get_prev_frame (struct frame_info *fi,
- struct frame_info **result);
+gdb_result GDB_value_cast PARAMS ((struct type * type, value_ptr val, value_ptr * rval));
-gdb_result GDB_get_next_frame (struct frame_info *fi,
- struct frame_info **result);
-
-gdb_result GDB_find_relative_frame (struct frame_info *fi,
- int *start, struct frame_info **result);
-
-gdb_result GDB_get_current_frame (struct frame_info **result);
-
-gdb_result GDB_varobj_update (struct varobj **varp, int explicit,
- VEC (varobj_update_result) **changes);
+gdb_result GDB_get_frame_block PARAMS ((struct frame_info * fi, struct block ** rval));
/*
* Private functions for this file
*/
-static gdb_result call_wrapped_function (catch_errors_ftype *,
- struct gdb_wrapper_arguments *);
-
-static int wrap_type_print (char *);
-
-static int wrap_evaluate_expression (char *);
+static gdb_result call_wrapped_function PARAMS ((catch_errors_ftype *,
+ struct gdb_wrapper_arguments *));
-static int wrap_value_fetch_lazy (char *);
+static int wrap_type_print PARAMS ((char *));
-static int wrap_val_print (char *);
+static int wrap_evaluate_expression PARAMS ((char *));
-static int wrap_value_equal (char *);
+static int wrap_value_fetch_lazy PARAMS ((char *));
-static int wrap_parse_exp_1 (char *opaque_arg);
+static int wrap_val_print PARAMS ((char *));
-static int wrap_evaluate_type (char *opaque_arg);
+static int wrap_select_frame PARAMS ((char *));
-static int wrap_block_for_pc (char *opaque_arg);
+static int wrap_value_equal PARAMS ((char *));
-static int wrap_block_innermost_frame (char *opaque_arg);
+static int wrap_parse_exp_1 PARAMS ((char *opaque_arg));
-static int wrap_reinit_frame_cache (char *opaque_arg);
+static int wrap_evaluate_type PARAMS ((char *opaque_arg));
-static int wrap_value_ind (char *opaque_arg);
+static int wrap_block_for_pc PARAMS ((char *opaque_arg));
-static int wrap_value_slice (char *opaque_arg);
+static int wrap_block_innermost_frame PARAMS ((char *opaque_arg));
-static int wrap_value_coerce_array (char *opaque_arg);
+static int wrap_reinit_frame_cache PARAMS ((char *opaque_arg));
-static int wrap_value_struct_elt (char *opaque_arg);
+static int wrap_find_frame_addr_in_frame_chain PARAMS ((char *opaque_arg));
-static int wrap_value_cast (char *opaque_arg);
+static int wrap_value_ind PARAMS ((char *opaque_arg));
-static int wrap_get_frame_block (char *opaque_arg);
+static int wrap_value_slice PARAMS ((char *opaque_arg));
-static int wrap_get_prev_frame (char *opaque_arg);
+static int wrap_value_coerce_array PARAMS ((char *opaque_arg));
-static int wrap_get_next_frame (char *opaque_arg);
+static int wrap_value_struct_elt PARAMS ((char *opaque_arg));
-static int wrap_find_relative_frame (char *opaque_arg);
+static int wrap_value_cast PARAMS ((char *opaque_arg));
-static int wrap_get_current_frame (char *opaque_arg);
+static int wrap_get_frame_block PARAMS ((char *opaque_arg));
-static int wrap_varobj_update (char *opaque_arg);
-
static gdb_result
-call_wrapped_function (catch_errors_ftype *fn, struct gdb_wrapper_arguments *arg)
+call_wrapped_function (fn, arg)
+ catch_errors_ftype *fn;
+ struct gdb_wrapper_arguments *arg;
{
if (!catch_errors (fn, (char *) &arg, "", RETURN_MASK_ERROR))
{
@@ -147,60 +128,67 @@ call_wrapped_function (catch_errors_ftype *fn, struct gdb_wrapper_arguments *arg
}
gdb_result
-GDB_type_print (value_ptr val, char *varstring,
- struct ui_file *stream, int show)
+GDB_type_print (val, varstring, stream, show)
+ value_ptr val;
+ char *varstring;
+ struct ui_file *stream;
+ int show;
{
struct gdb_wrapper_arguments args;
- args.args[0].ptr = val;
- args.args[1].ptr = varstring;
- args.args[2].ptr = stream;
- args.args[3].integer = show;
+ args.args[0] = (char *) val;
+ args.args[1] = varstring;
+ args.args[2] = (char *) stream;
+ args.args[3] = (char *) show;
return call_wrapped_function ((catch_errors_ftype *) wrap_type_print, &args);
}
static int
-wrap_type_print (char *a)
+wrap_type_print (a)
+ char *a;
{
struct gdb_wrapper_arguments **args = (struct gdb_wrapper_arguments **) a;
- value_ptr val = (value_ptr) (*args)->args[0].ptr;
- char *varstring = (*args)->args[1].ptr;
- struct ui_file *stream = (struct ui_file *) (*args)->args[2].ptr;
- int show = (*args)->args[3].integer;
- type_print (value_type (val), varstring, stream, show);
+ value_ptr val = (value_ptr) (*args)->args[0];
+ char *varstring = (*args)->args[1];
+ struct ui_file *stream = (struct ui_file *) (*args)->args[2];
+ int show = (int) (*args)->args[3];
+ type_print (VALUE_TYPE (val), varstring, stream, show);
return 1;
}
gdb_result
-GDB_val_print (struct type *type,
- char *valaddr,
- CORE_ADDR address,
- struct ui_file *stream,
- int format,
- int deref_ref,
- int recurse,
- enum val_prettyprint pretty)
+GDB_val_print (type, valaddr, address, stream, format, deref_ref,
+ recurse, pretty)
+ struct type *type;
+ char *valaddr;
+ CORE_ADDR address;
+ struct ui_file *stream;
+ int format;
+ int deref_ref;
+ int recurse;
+ enum val_prettyprint pretty;
{
struct gdb_wrapper_arguments args;
- args.args[0].ptr = type;
- args.args[1].ptr = valaddr;
- args.args[2].ptr = &address;
- args.args[3].ptr = stream;
- args.args[4].integer = format;
- args.args[5].integer = deref_ref;
- args.args[6].integer = recurse;
- args.args[7].integer = pretty;
+ args.args[0] = (char *) type;
+ args.args[1] = (char *) valaddr;
+ args.args[2] = (char *) &address;
+ args.args[3] = (char *) stream;
+ args.args[4] = (char *) format;
+ args.args[5] = (char *) deref_ref;
+ args.args[6] = (char *) recurse;
+ args.args[7] = (char *) pretty;
return call_wrapped_function ((catch_errors_ftype *) wrap_val_print, &args);
}
static int
-wrap_val_print (char *a)
+wrap_val_print (a)
+ char *a;
{
struct gdb_wrapper_arguments **args = (struct gdb_wrapper_arguments **) a;
struct type *type;
- const gdb_byte *valaddr;
+ char *valaddr;
CORE_ADDR address;
struct ui_file *stream;
int format;
@@ -208,60 +196,90 @@ wrap_val_print (char *a)
int recurse;
enum val_prettyprint pretty;
- type = (struct type *) (*args)->args[0].ptr;
- valaddr = (gdb_byte *) (*args)->args[1].ptr;
- address = *(CORE_ADDR *) (*args)->args[2].ptr;
- stream = (struct ui_file *) (*args)->args[3].ptr;
- format = (*args)->args[4].integer;
- deref_ref = (*args)->args[5].integer;
- recurse = (*args)->args[6].integer;
- pretty = (enum val_prettyprint) (*args)->args[7].integer;
+ type = (struct type *) (*args)->args[0];
+ valaddr = (char *) (*args)->args[1];
+ address = *(CORE_ADDR *) (*args)->args[2];
+ stream = (struct ui_file *) (*args)->args[3];
+ format = (int) (*args)->args[4];
+ deref_ref = (int) (*args)->args[5];
+ recurse = (int) (*args)->args[6];
+ pretty = (enum val_prettyprint) (*args)->args[7];
val_print (type, valaddr, 0, address, stream, format, deref_ref,
- recurse, pretty, current_language);
+ recurse, pretty);
return 1;
}
gdb_result
-GDB_value_fetch_lazy (value_ptr value)
+GDB_value_fetch_lazy (value)
+ value_ptr value;
{
struct gdb_wrapper_arguments args;
- args.args[0].ptr = value;
+ args.args[0] = (char *) value;
return call_wrapped_function ((catch_errors_ftype *) wrap_value_fetch_lazy, &args);
}
static int
-wrap_value_fetch_lazy (char *a)
+wrap_value_fetch_lazy (a)
+ char *a;
{
struct gdb_wrapper_arguments **args = (struct gdb_wrapper_arguments **) a;
- value_fetch_lazy ((value_ptr) (*args)->args[0].ptr);
+ value_fetch_lazy ((value_ptr) (*args)->args[0]);
return 1;
}
gdb_result
-GDB_evaluate_expression (struct expression *exp, value_ptr *value)
+GDB_evaluate_expression (exp, value)
+ struct expression *exp;
+ value_ptr *value;
{
struct gdb_wrapper_arguments args;
gdb_result result;
- args.args[0].ptr = exp;
+ args.args[0] = (char *) exp;
result = call_wrapped_function ((catch_errors_ftype *) wrap_evaluate_expression, &args);
if (result != GDB_OK)
return result;
- *value = (value_ptr) args.result.ptr;
+ *value = (value_ptr) args.result;
return GDB_OK;
}
static int
-wrap_evaluate_expression (char *a)
+wrap_evaluate_expression (a)
+ char *a;
{
struct gdb_wrapper_arguments **args = (struct gdb_wrapper_arguments **) a;
- (*args)->result.ptr =
- evaluate_expression ((struct expression *) (*args)->args[0].ptr);
+ (*args)->result =
+ (char *) evaluate_expression ((struct expression *) (*args)->args[0]);
+ return 1;
+}
+
+gdb_result
+GDB_select_frame (fi, level)
+ struct frame_info *fi;
+ int level;
+{
+ struct gdb_wrapper_arguments args;
+
+ args.args[0] = (char *) fi;
+ args.args[1] = (char *) &level;
+
+ return call_wrapped_function ((catch_errors_ftype *) wrap_select_frame, &args);
+}
+
+static int
+wrap_select_frame (a)
+ char *a;
+{
+ struct gdb_wrapper_arguments **args = (struct gdb_wrapper_arguments **) a;
+ int level = *(int *) (*args)->args[1];
+ struct frame_info *fi = (struct frame_info *) (*args)->args[0];
+
+ select_frame (fi, level);
return 1;
}
@@ -274,143 +292,157 @@ GDB_value_equal (val1, val2, result)
struct gdb_wrapper_arguments args;
gdb_result r;
- args.args[0].ptr = val1;
- args.args[1].ptr = val2;
+ args.args[0] = (char *) val1;
+ args.args[1] = (char *) val2;
r = call_wrapped_function ((catch_errors_ftype *) wrap_value_equal, &args);
if (r != GDB_OK)
return r;
- *result = args.result.integer;
+ *result = (int) args.result;
return GDB_OK;
}
static int
-wrap_value_equal (char *a)
+wrap_value_equal (a)
+ char *a;
{
struct gdb_wrapper_arguments **args = (struct gdb_wrapper_arguments **) a;
value_ptr val1, val2;
- val1 = (value_ptr) (*args)->args[0].ptr;
- val2 = (value_ptr) (*args)->args[1].ptr;
+ val1 = (value_ptr) (*args)->args[0];
+ val2 = (value_ptr) (*args)->args[1];
- (*args)->result.integer = value_equal (val1, val2);
+ (*args)->result = (char *) value_equal (val1, val2);
return 1;
}
gdb_result
-GDB_parse_exp_1 (char **stringptr, struct block *block,
- int comma, struct expression **result)
+GDB_parse_exp_1 (stringptr, block, comma, result)
+ char **stringptr;
+ struct block *block;
+ int comma;
+ struct expression **result;
{
struct gdb_wrapper_arguments args;
gdb_result r;
- args.args[0].ptr = stringptr;
- args.args[1].ptr = block;
- args.args[2].integer = comma;
+ args.args[0] = (char *) stringptr;
+ args.args[1] = (char *) block;
+ args.args[2] = (char *) comma;
r = call_wrapped_function ((catch_errors_ftype *) wrap_parse_exp_1, &args);
if (r != GDB_OK)
return r;
- *result = (struct expression *) args.result.ptr;
+ *result = (struct expression *) args.result;
return GDB_OK;
}
static int
-wrap_parse_exp_1 (char *opaque_arg)
+wrap_parse_exp_1 (opaque_arg)
+ char *opaque_arg;
{
struct gdb_wrapper_arguments **args = (struct gdb_wrapper_arguments **) opaque_arg;
struct block *block;
char **stringptr;
int comma;
- stringptr = (char **) (*args)->args[0].ptr;
- block = (struct block *) (*args)->args[1].ptr;
- comma = (*args)->args[2].integer;
+ stringptr = (char **) (*args)->args[0];
+ block = (struct block *) (*args)->args[1];
+ comma = (int) (*args)->args[2];
- (*args)->result.ptr = parse_exp_1 (stringptr, block, comma);
+ (*args)->result = (char *) parse_exp_1 (stringptr, block, comma);
return 1;
}
gdb_result
-GDB_evaluate_type (struct expression *exp, value_ptr *result)
+GDB_evaluate_type (exp, result)
+ struct expression *exp;
+ value_ptr *result;
{
struct gdb_wrapper_arguments args;
gdb_result r;
- args.args[0].ptr = exp;
+ args.args[0] = (char *) exp;
r = call_wrapped_function ((catch_errors_ftype *) wrap_evaluate_type, &args);
if (r != GDB_OK)
return r;
- *result = (value_ptr) args.result.ptr;
+ *result = (value_ptr) args.result;
return GDB_OK;
}
static int
-wrap_evaluate_type (char *opaque_arg)
+wrap_evaluate_type (opaque_arg)
+ char *opaque_arg;
{
struct gdb_wrapper_arguments **args = (struct gdb_wrapper_arguments **) opaque_arg;
struct expression *exp;
- exp = (struct expression *) (*args)->args[0].ptr;
- (*args)->result.ptr = evaluate_type (exp);
+ exp = (struct expression *) (*args)->args[0];
+ (*args)->result = (char *) evaluate_type (exp);
return 1;
}
gdb_result
-GDB_block_for_pc (CORE_ADDR pc, struct block **result)
+GDB_block_for_pc (pc, result)
+ CORE_ADDR pc;
+ struct block **result;
{
struct gdb_wrapper_arguments args;
gdb_result r;
- args.args[0].ptr = &pc;
+ args.args[0] = (char *) &pc;
r = call_wrapped_function ((catch_errors_ftype *) wrap_block_for_pc, &args);
if (r != GDB_OK)
return r;
- *result = (struct block *) args.result.ptr;
+ *result = (struct block *) args.result;
return GDB_OK;
}
static int
-wrap_block_for_pc (char *opaque_arg)
+wrap_block_for_pc (opaque_arg)
+ char *opaque_arg;
{
struct gdb_wrapper_arguments **args = (struct gdb_wrapper_arguments **) opaque_arg;
CORE_ADDR pc;
- pc = *(CORE_ADDR *) (*args)->args[0].ptr;
- (*args)->result.ptr = block_for_pc (pc);
+ pc = *(CORE_ADDR *) (*args)->args[0];
+ (*args)->result = (char *) block_for_pc (pc);
return 1;
}
gdb_result
-GDB_block_innermost_frame (struct block *block, struct frame_info **result)
+GDB_block_innermost_frame (block, result)
+ struct block *block;
+ struct frame_info **result;
{
struct gdb_wrapper_arguments args;
gdb_result r;
- args.args[0].ptr = block;
+ args.args[0] = (char *) block;
r = call_wrapped_function ((catch_errors_ftype *) wrap_block_innermost_frame, &args);
if (r != GDB_OK)
return r;
- *result = (struct frame_info *) args.result.ptr;
+ *result = (struct frame_info *) args.result;
return GDB_OK;
}
static int
-wrap_block_innermost_frame (char *opaque_arg)
+wrap_block_innermost_frame (opaque_arg)
+ char *opaque_arg;
{
struct gdb_wrapper_arguments **args = (struct gdb_wrapper_arguments **) opaque_arg;
struct block *block;
- block = (struct block *) (*args)->args[0].ptr;
- (*args)->result.ptr = block_innermost_frame (block);
+ block = (struct block *) (*args)->args[0];
+ (*args)->result = (char *) block_innermost_frame (block);
return 1;
}
@@ -427,331 +459,254 @@ GDB_reinit_frame_cache ()
}
static int
-wrap_reinit_frame_cache (char *opaque_arg)
+wrap_reinit_frame_cache (opaque_arg)
+ char *opaque_arg;
{
reinit_frame_cache ();
return 1;
}
gdb_result
-GDB_value_ind (value_ptr val, value_ptr *rval)
+GDB_find_frame_addr_in_frame_chain (addr, result)
+ CORE_ADDR addr;
+ struct frame_info **result;
{
struct gdb_wrapper_arguments args;
gdb_result r;
- args.args[0].ptr = val;
+ args.args[0] = (char *) &addr;
- r = call_wrapped_function ((catch_errors_ftype *) wrap_value_ind, &args);
+ r = call_wrapped_function ((catch_errors_ftype *) wrap_find_frame_addr_in_frame_chain, &args);
if (r != GDB_OK)
return r;
- *rval = (value_ptr) args.result.ptr;
+ *result = (struct frame_info *) args.result;
return GDB_OK;
}
static int
-wrap_value_ind (char *opaque_arg)
+wrap_find_frame_addr_in_frame_chain (opaque_arg)
+ char *opaque_arg;
{
struct gdb_wrapper_arguments **args = (struct gdb_wrapper_arguments **) opaque_arg;
- value_ptr val;
+ CORE_ADDR addr;
- val = (value_ptr) (*args)->args[0].ptr;
- (*args)->result.ptr = value_ind (val);
+ addr = *(CORE_ADDR *) (*args)->args[0];
+ (*args)->result = (char *) find_frame_addr_in_frame_chain (addr);
return 1;
}
gdb_result
-GDB_value_slice (value_ptr val, int low, int num, value_ptr *rval)
+GDB_value_ind (val, rval)
+ value_ptr val;
+ value_ptr *rval;
{
struct gdb_wrapper_arguments args;
gdb_result r;
- args.args[0].ptr = val;
- args.args[1].integer = low;
- args.args[2].integer = num;
+ args.args[0] = (char *) val;
- r = call_wrapped_function ((catch_errors_ftype *) wrap_value_slice, &args);
+ r = call_wrapped_function ((catch_errors_ftype *) wrap_value_ind, &args);
if (r != GDB_OK)
return r;
- *rval = (value_ptr) args.result.ptr;
+ *rval = (value_ptr) args.result;
return GDB_OK;
}
static int
-wrap_value_slice (char *opaque_arg)
+wrap_value_ind (opaque_arg)
+ char *opaque_arg;
{
struct gdb_wrapper_arguments **args = (struct gdb_wrapper_arguments **) opaque_arg;
value_ptr val;
- int low, num;
- val = (value_ptr) (*args)->args[0].ptr;
- low = (*args)->args[1].integer;
- num = (*args)->args[2].integer;
- (*args)->result.ptr = value_slice (val, low, num);
+ val = (value_ptr) (*args)->args[0];
+ (*args)->result = (char *) value_ind (val);
return 1;
}
gdb_result
-GDB_value_coerce_array (val, rval)
+GDB_value_slice (val, low, num, rval)
value_ptr val;
+ int low;
+ int num;
value_ptr *rval;
{
struct gdb_wrapper_arguments args;
gdb_result r;
- args.args[0].ptr = val;
+ args.args[0] = (char *) val;
+ args.args[1] = (char *) &low;
+ args.args[2] = (char *) &num;
- r = call_wrapped_function ((catch_errors_ftype *) wrap_value_coerce_array,
- &args);
+ r = call_wrapped_function ((catch_errors_ftype *) wrap_value_slice, &args);
if (r != GDB_OK)
return r;
- *rval = (value_ptr) args.result.ptr;
+ *rval = (value_ptr) args.result;
return GDB_OK;
}
static int
-wrap_value_coerce_array (char *opaque_arg)
+wrap_value_slice (opaque_arg)
+ char *opaque_arg;
{
struct gdb_wrapper_arguments **args = (struct gdb_wrapper_arguments **) opaque_arg;
value_ptr val;
+ int low, num;
- val = (value_ptr) (*args)->args[0].ptr;
- (*args)->result.ptr = value_coerce_array (val);
- return 1;
-}
-
-gdb_result
-GDB_value_struct_elt (value_ptr *argp,
- value_ptr *args,
- char *name,
- int *static_memfunc,
- char *err,
- value_ptr *rval)
-{
- struct gdb_wrapper_arguments argss;
- gdb_result r;
-
- argss.args[0].ptr = argp;
- argss.args[1].ptr = args;
- argss.args[2].ptr = name;
- argss.args[3].ptr = static_memfunc;
- argss.args[4].ptr = err;
- r = call_wrapped_function ((catch_errors_ftype *) wrap_value_struct_elt, &argss);
- if (r != GDB_OK)
- return r;
-
- *rval = (value_ptr) argss.result.ptr;
- return GDB_OK;
-}
-
-static int
-wrap_value_struct_elt (char *opaque_arg)
-{
- struct gdb_wrapper_arguments **argss = (struct gdb_wrapper_arguments **) opaque_arg;
- value_ptr *argp, *args;
- char *name;
- int *static_memfunc;
- char *err;
-
- argp = (value_ptr *) (*argss)->args[0].ptr;
- args = (value_ptr *) (*argss)->args[1].ptr;
- name = (char *) (*argss)->args[2].ptr;
- static_memfunc = (int *) (*argss)->args[3].ptr;
- err = (char *) (*argss)->args[4].ptr;
-
- (*argss)->result.ptr = value_struct_elt (argp, args, name, static_memfunc, err);
+ val = (value_ptr) (*args)->args[0];
+ low = *(int *) (*args)->args[1];
+ num = *(int *) (*args)->args[2];
+ (*args)->result = (char *) value_slice (val, low, num);
return 1;
}
gdb_result
-GDB_value_cast (struct type *type, value_ptr val, value_ptr *rval)
+GDB_value_coerce_array (val, rval)
+ value_ptr val;
+ value_ptr *rval;
{
struct gdb_wrapper_arguments args;
gdb_result r;
- args.args[0].ptr = type;
- args.args[1].ptr = val;
+ args.args[0] = (char *) val;
- r = call_wrapped_function ((catch_errors_ftype *) wrap_value_cast, &args);
+ r = call_wrapped_function ((catch_errors_ftype *) wrap_value_coerce_array,
+ &args);
if (r != GDB_OK)
return r;
- *rval = (value_ptr) args.result.ptr;
+ *rval = (value_ptr) args.result;
return GDB_OK;
}
static int
-wrap_value_cast (char *opaque_arg)
+wrap_value_coerce_array (opaque_arg)
+ char *opaque_arg;
{
struct gdb_wrapper_arguments **args = (struct gdb_wrapper_arguments **) opaque_arg;
value_ptr val;
- struct type *type;
-
- type = (struct type *) (*args)->args[0].ptr;
- val = (value_ptr) (*args)->args[1].ptr;
- (*args)->result.ptr = value_cast (type, val);
+ val = (value_ptr) (*args)->args[0];
+ (*args)->result = (char *) value_coerce_array (val);
return 1;
}
gdb_result
-GDB_get_frame_block (struct frame_info *fi, struct block **rval)
+GDB_value_struct_elt (argp, args, name, static_memfunc, err, rval)
+ value_ptr *argp;
+ value_ptr *args;
+ char *name;
+ int *static_memfunc;
+ char *err;
+ value_ptr *rval;
{
- struct gdb_wrapper_arguments args;
+ struct gdb_wrapper_arguments argss;
gdb_result r;
- args.args[0].ptr = fi;
-
- r = call_wrapped_function ((catch_errors_ftype *) wrap_get_frame_block, &args);
+ argss.args[0] = (char *) argp;
+ argss.args[1] = (char *) args;
+ argss.args[2] = name;
+ argss.args[3] = (char *) static_memfunc;
+ argss.args[4] = err;
+ r = call_wrapped_function ((catch_errors_ftype *) wrap_value_struct_elt, &argss);
if (r != GDB_OK)
return r;
- *rval = (struct block *) args.result.ptr;
+ *rval = (value_ptr) argss.result;
return GDB_OK;
}
static int
-wrap_get_frame_block (char *opaque_arg)
+wrap_value_struct_elt (opaque_arg)
+ char *opaque_arg;
{
- struct gdb_wrapper_arguments **args = (struct gdb_wrapper_arguments **) opaque_arg;
- struct frame_info *fi;
+ struct gdb_wrapper_arguments **argss = (struct gdb_wrapper_arguments **) opaque_arg;
+ value_ptr *argp, *args;
+ char *name;
+ int *static_memfunc;
+ char *err;
- fi = (struct frame_info *) (*args)->args[0].ptr;
- (*args)->result.ptr = get_frame_block (fi, NULL);
+ argp = (value_ptr *) (*argss)->args[0];
+ args = (value_ptr *) (*argss)->args[1];
+ name = (*argss)->args[2];
+ static_memfunc = (int *) (*argss)->args[3];
+ err = (*argss)->args[4];
+ (*argss)->result = (char *) value_struct_elt (argp, args, name, static_memfunc, err);
return 1;
}
gdb_result
-GDB_get_prev_frame (struct frame_info *fi, struct frame_info **result)
+GDB_value_cast (type, val, rval)
+ struct type *type;
+ value_ptr val;
+ value_ptr *rval;
{
struct gdb_wrapper_arguments args;
gdb_result r;
- args.args[0].ptr = fi;
- r = call_wrapped_function ((catch_errors_ftype *) wrap_get_prev_frame, &args);
- if (r != GDB_OK)
- return r;
-
- *result = (struct frame_info *) args.result.ptr;
- return GDB_OK;
-}
-
-static int
-wrap_get_prev_frame (char *opaque_arg)
-{
- struct gdb_wrapper_arguments **args = (struct gdb_wrapper_arguments **) opaque_arg;
- struct frame_info *fi = (struct frame_info *) (*args)->args[0].ptr;
+ args.args[0] = (char *) type;
+ args.args[1] = (char *) val;
- (*args)->result.ptr = get_prev_frame (fi);
- return 1;
-}
-
-gdb_result
-GDB_get_next_frame (struct frame_info *fi, struct frame_info **result)
-{
- struct gdb_wrapper_arguments args;
- gdb_result r;
-
- args.args[0].ptr = fi;
- r = call_wrapped_function ((catch_errors_ftype *) wrap_get_next_frame, &args);
+ r = call_wrapped_function ((catch_errors_ftype *) wrap_value_cast, &args);
if (r != GDB_OK)
return r;
- *result = (struct frame_info *) args.result.ptr;
+ *rval = (value_ptr) args.result;
return GDB_OK;
}
static int
-wrap_get_next_frame (char *opaque_arg)
+wrap_value_cast (opaque_arg)
+ char *opaque_arg;
{
struct gdb_wrapper_arguments **args = (struct gdb_wrapper_arguments **) opaque_arg;
- struct frame_info *fi = (struct frame_info *) (*args)->args[0].ptr;
+ value_ptr val;
+ struct type *type;
+
+ type = (struct type *) (*args)->args[0];
+ val = (value_ptr) (*args)->args[1];
+ (*args)->result = (char *) value_cast (type, val);
- (*args)->result.ptr = get_next_frame (fi);
return 1;
}
gdb_result
-GDB_find_relative_frame (struct frame_info *fi, int *start,
- struct frame_info **result)
+GDB_get_frame_block (fi, rval)
+ struct frame_info *fi;
+ struct block **rval;
{
struct gdb_wrapper_arguments args;
gdb_result r;
- args.args[0].ptr = fi;
- args.args[1].ptr = start;
+ args.args[0] = (char *) fi;
- r = call_wrapped_function ((catch_errors_ftype *) wrap_find_relative_frame,
- &args);
+ r = call_wrapped_function ((catch_errors_ftype *) wrap_get_frame_block, &args);
if (r != GDB_OK)
return r;
- *result = (struct frame_info *) args.result.ptr;
+ *rval = (struct block *) args.result;
return GDB_OK;
}
static int
-wrap_find_relative_frame (char *opaque_arg)
+wrap_get_frame_block (opaque_arg)
+ char *opaque_arg;
{
struct gdb_wrapper_arguments **args = (struct gdb_wrapper_arguments **) opaque_arg;
- struct frame_info *fi = (struct frame_info *) (*args)->args[0].ptr;
- int *start = (int *) (*args)->args[1].ptr;
-
- (*args)->result.ptr = find_relative_frame (fi, start);
- return 1;
-}
-
-gdb_result
-GDB_get_current_frame (struct frame_info **result)
-{
- struct gdb_wrapper_arguments args;
- gdb_result r;
-
- r = call_wrapped_function ((catch_errors_ftype *) wrap_get_current_frame,
- &args);
- if (r != GDB_OK)
- return r;
-
- *result = (struct frame_info *) args.result.ptr;
- return GDB_OK;
-}
+ struct frame_info *fi;
-static int
-wrap_get_current_frame (char *opaque_arg)
-{
- struct gdb_wrapper_arguments **args = (struct gdb_wrapper_arguments **) opaque_arg;
+ fi = (struct frame_info *) (*args)->args[0];
+ (*args)->result = (char *) get_frame_block (fi);
- (*args)->result.ptr = get_current_frame ();
return 1;
}
+
-gdb_result
-GDB_varobj_update (struct varobj **varp, int explicit,
- VEC (varobj_update_result) **changes)
-{
- struct gdb_wrapper_arguments args;
- gdb_result r;
-
- args.args[0].ptr = varp;
- args.args[1].integer = explicit;
-
- r = call_wrapped_function ((catch_errors_ftype *) wrap_varobj_update, &args);
- if (r != GDB_OK)
- return r;
-
- *changes = args.result.ptr;
- return GDB_OK;
-}
-static int wrap_varobj_update (char *opaque_arg)
-{
- struct gdb_wrapper_arguments **args
- = (struct gdb_wrapper_arguments **) opaque_arg;
- struct varobj **varp = (struct varobj **) (*args)->args[0].ptr;
- int explicit = (*args)->args[1].integer;
- (*args)->result.ptr = varobj_update (varp, explicit);
- return 1;
-}
+/* Local variables: */
+/* change-log-default-name: "ChangeLog-gdbtk" */
+/* End: */
diff --git a/gdb/gdbtk/generic/gdbtk-wrapper.h b/gdb/gdbtk/generic/gdbtk-wrapper.h
index e9d290f5647..e70a12c6303 100644
--- a/gdb/gdbtk/generic/gdbtk-wrapper.h
+++ b/gdb/gdbtk/generic/gdbtk-wrapper.h
@@ -1,5 +1,5 @@
/* longjmp-free interface between gdb and gdbtk.
- Copyright (C) 1999, 2000, 2002, 2008 Free Software Foundation, Inc.
+ Copyright 1999-2000 Free Software Foundation, Inc.
This file is part of GDB. It contains routines to safely call common gdb
functions without the fear of longjmp'ing.
@@ -16,81 +16,58 @@ GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
-Foundation, Inc., 51 Franklin Street, Fifth Floor,
-Boston, MA 02110-1301, USA. */
+Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#ifndef GDBTK_WRAPPER_H
#define GDBTK_WRAPPER_H
-#include "vec.h"
-
/* Use this struct used to pass arguments to wrapper routines. We assume
(arbitrarily) that no gdb function takes more than ten arguments. */
struct gdb_wrapper_arguments {
/* Pointer to some result from the gdb function call, if any */
- union
- {
- int integer;
- void *ptr;
- } result;
+ char *result;
/* The list of arguments. */
- union
- {
- void *ptr;
- int integer;
- } args[10];
+ char *args[10];
};
-/* FIXME: cagney/2002-01-04: GDB no longer uses or supplies the
- value_ptr typedef. Provide one here to keep the Insight code
- immediatly happy. */
-typedef struct value *value_ptr;
-
/* Whenever any gdb function wrapper is called, its return status is: */
typedef enum gdb_wrapper_status { GDB_OK, GDB_ERROR } gdb_result;
/* This list of functions which have been wrapped. Please keep this list
in alphabetical order, using "GDB_" to prefix the actual name of the
function. */
-extern gdb_result GDB_evaluate_expression (struct expression *expr,
- value_ptr * val);
+extern gdb_result GDB_evaluate_expression PARAMS ((struct expression *expr, value_ptr *val));
+extern gdb_result GDB_select_frame PARAMS ((struct frame_info *fi, int level));
extern gdb_result GDB_type_print (value_ptr val, char *varstring,
struct ui_file *stream, int show);
extern gdb_result GDB_val_print (struct type *type, char *valaddr,
CORE_ADDR address, struct ui_file *stream,
int format, int deref_ref, int recurse,
enum val_prettyprint pretty);
-extern gdb_result GDB_value_fetch_lazy (value_ptr value);
-extern gdb_result GDB_value_equal (value_ptr val1, value_ptr val2,
- int *result);
-extern gdb_result GDB_parse_exp_1 (char **stringptr, struct block *block,
- int comma, struct expression **result);
-extern gdb_result GDB_evaluate_type (struct expression *exp,
- value_ptr * result);
-extern gdb_result GDB_block_for_pc (CORE_ADDR pc, struct block **result);
-extern gdb_result GDB_block_innermost_frame (struct block *block,
- struct frame_info **result);
-extern gdb_result GDB_reinit_frame_cache (void);
-extern gdb_result GDB_value_ind (value_ptr val, value_ptr * rval);
-extern gdb_result GDB_value_slice (value_ptr val, int low, int num,
- value_ptr * rval);
-extern gdb_result GDB_value_coerce_array (value_ptr val, value_ptr * rval);
-extern gdb_result GDB_value_struct_elt (value_ptr * argp, value_ptr * args,
- char *name, int *static_memfunc,
- char *err, value_ptr * rval);
-extern gdb_result GDB_value_cast (struct type *type, value_ptr val,
- value_ptr * rval);
-gdb_result GDB_get_frame_block (struct frame_info *fi, struct block **rval);
-extern gdb_result GDB_get_prev_frame (struct frame_info *fi,
- struct frame_info **result);
-extern gdb_result GDB_get_next_frame (struct frame_info *fi,
- struct frame_info **result);
-extern gdb_result GDB_find_relative_frame (struct frame_info *fi,
- int *start,
- struct frame_info **result);
-extern gdb_result GDB_get_current_frame (struct frame_info **result);
-extern gdb_result GDB_varobj_update (struct varobj **varp, int explicit,
- VEC (varobj_update_result) **changes);
+extern gdb_result GDB_value_fetch_lazy PARAMS ((value_ptr value));
+extern gdb_result GDB_value_equal PARAMS ((value_ptr val1, value_ptr val2, int *result));
+extern gdb_result GDB_parse_exp_1 PARAMS ((char **stringptr, struct block *block, int comma,
+ struct expression **result));
+extern gdb_result GDB_evaluate_type PARAMS ((struct expression *exp, value_ptr *result));
+extern gdb_result GDB_block_for_pc PARAMS ((CORE_ADDR pc, struct block **result));
+extern gdb_result GDB_block_innermost_frame PARAMS ((struct block *block,
+ struct frame_info **result));
+extern gdb_result GDB_reinit_frame_cache PARAMS ((void));
+extern gdb_result GDB_find_frame_addr_in_frame_chain PARAMS ((CORE_ADDR addr,
+ struct frame_info **result));
+extern gdb_result GDB_value_ind PARAMS ((value_ptr val, value_ptr *rval));
+extern gdb_result GDB_value_slice PARAMS ((value_ptr val, int low, int num,
+ value_ptr *rval));
+extern gdb_result GDB_value_coerce_array PARAMS ((value_ptr val, value_ptr *rval));
+extern gdb_result GDB_value_struct_elt PARAMS ((value_ptr *argp, value_ptr *args,
+ char *name, int *static_memfunc,
+ char *err, value_ptr *rval));
+extern gdb_result GDB_value_cast PARAMS ((struct type *type, value_ptr val,
+ value_ptr *rval));
+gdb_result GDB_get_frame_block PARAMS ((struct frame_info *fi, struct block **rval));
#endif /* GDBTK_WRAPPER_H */
-
+
+/* Local variables: */
+/* change-log-default-name: "ChangeLog-gdbtk" */
+/* End: */
diff --git a/gdb/gdbtk/generic/gdbtk.c b/gdb/gdbtk/generic/gdbtk.c
index 9f84e24a28d..87c60737e0a 100644
--- a/gdb/gdbtk/generic/gdbtk.c
+++ b/gdb/gdbtk/generic/gdbtk.c
@@ -1,6 +1,5 @@
-/* Startup code for Insight
- Copyright (C) 1994, 1995, 1996, 1997, 1998, 2001, 2002, 2003, 2004, 2006
- Free Software Foundation, Inc.
+/* Startup code for gdbtk.
+ Copyright 1994, 1995, 1996, 1997, 1998 Free Software Foundation, Inc.
Written by Stu Grossman <grossman@cygnus.com> of Cygnus Support.
@@ -18,97 +17,107 @@
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
- Foundation, Inc., 51 Franklin Street, Fifth Floor,
- Boston, MA 02110-1301, USA. */
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
#include "defs.h"
+#include "symtab.h"
#include "inferior.h"
+#include "command.h"
+#include "bfd.h"
#include "symfile.h"
#include "objfiles.h"
+#include "target.h"
#include "gdbcore.h"
#include "tracepoint.h"
#include "demangle.h"
#include "version.h"
-#include "top.h"
-#include "annotate.h"
-#include "exceptions.h"
+#include "tui/tui-file.h"
-#if defined(_WIN32) || defined(__CYGWIN__)
+#ifdef _WIN32
#define WIN32_LEAN_AND_MEAN
#include <windows.h>
#endif
-/* tcl header files includes varargs.h unless HAS_STDARG is defined,
- but gdb uses stdarg.h, so make sure HAS_STDARG is defined. */
-#define HAS_STDARG 1
+#include <sys/stat.h>
+#include <tcl.h>
+#include <tk.h>
#include <itcl.h>
+#include <tix.h>
#include <itk.h>
#include "guitcl.h"
#include "gdbtk.h"
+#include <signal.h>
#include <fcntl.h>
-#include <sys/stat.h>
-#ifdef HAVE_SYS_IOCTL_H
+#include "top.h"
#include <sys/ioctl.h>
-#endif
-#include <sys/time.h>
-#include <signal.h>
-
#include "gdb_string.h"
#include "dis-asm.h"
+#include <stdio.h>
#include "gdbcmd.h"
+#include "annotate.h"
+#include <sys/time.h>
+
#ifdef __CYGWIN32__
#include <sys/cygwin.h> /* for cygwin32_attach_handle_to_fd */
#endif
extern void _initialize_gdbtk (void);
-#ifndef __MINGW32__
+#ifndef __CYGWIN32__
/* For unix natives, we use a timer to periodically keep the gui alive.
See comments before x_event. */
static sigset_t nullsigmask;
static struct sigaction act1, act2;
static struct itimerval it_on, it_off;
+static void x_event_wrapper PARAMS ((int));
static void
-x_event_wrapper (int signo)
+x_event_wrapper (signo)
+ int signo;
{
x_event (signo);
}
#endif
-/*
- * This variable controls the interaction with an external editor.
- */
-
-char *external_editor_command = NULL;
-
-extern int Tktable_Init (Tcl_Interp * interp);
-
-void gdbtk_init (void);
+ /*
+ * These two variables control the interaction with an external editor.
+ * If enable_external_editor is set at startup, BEFORE Gdbtk_Init is run
+ * then the Tcl variable of the same name will be set, and a command will
+ * called external_editor_command will be invoked to call out to the
+ * external editor. We give a dummy version here to warn if it is not set.
+ */
+int enable_external_editor = 0;
+char *external_editor_command = "tk_dialog .warn-external \\\n\
+\"No command is specified.\nUse --tclcommand <tcl/file> or --external-editor <cmd> to specify a new command\" 0 Ok";
-static void gdbtk_init_1 (char *argv0);
+extern int Tktable_Init PARAMS ((Tcl_Interp * interp));
-void gdbtk_interactive (void);
+static void gdbtk_init PARAMS ((char *));
-static void cleanup_init (void *ignore);
+void gdbtk_interactive PARAMS ((void));
-static void tk_command (char *, int);
+static void cleanup_init PARAMS ((int));
-static int target_should_use_timer (struct target_ops *t);
+static void tk_command PARAMS ((char *, int));
-int target_is_native (struct target_ops *t);
+#ifndef __CYGWIN32__
+static int target_should_use_timer PARAMS ((struct target_ops * t));
+#endif
-int gdbtk_test (char *);
+int target_is_native PARAMS ((struct target_ops *t));
-static void view_command (char *, int);
+int gdbtk_test PARAMS ((char *));
/* Handle for TCL interpreter */
Tcl_Interp *gdbtk_interp = NULL;
+#ifndef __CYGWIN32__
static int gdbtk_timer_going = 0;
+#endif
/* linked variable used to tell tcl what the current thread is */
int gdb_context = 0;
@@ -122,9 +131,6 @@ int running_now;
interpreter when it goes idle at startup. Used with the testsuite. */
static char *gdbtk_source_filename = NULL;
-int gdbtk_disable_fputs = 1;
-
-static const char *argv0;
#ifndef _WIN32
@@ -136,19 +142,23 @@ static const char *argv0;
#if TCL_MAJOR_VERSION == 8 && TCL_MINOR_VERSION == 0
char *
-TclpAlloc (unsigned int size)
+TclpAlloc (size)
+ unsigned int size;
{
return xmalloc (size);
}
char *
-TclpRealloc (char *ptr, unsigned int size)
+TclpRealloc (ptr, size)
+ char *ptr;
+ unsigned int size;
{
return xrealloc (ptr, size);
}
void
-TclpFree (char *ptr)
+TclpFree (ptr)
+ char *ptr;
{
free (ptr);
}
@@ -169,13 +179,13 @@ void
close_bfds ()
{
struct objfile *o;
-
+
ALL_OBJFILES (o)
- {
- if (o->obfd != NULL)
- bfd_cache_close (o->obfd);
- }
-
+ {
+ if (o->obfd != NULL)
+ bfd_cache_close (o->obfd);
+ }
+
if (exec_bfd != NULL)
bfd_cache_close (exec_bfd);
}
@@ -192,10 +202,7 @@ void
TclDebug (char level, const char *fmt,...)
{
va_list args;
- char *buf;
- const char *v[3];
- char *merge;
- char *priority;
+ char buf[10000], *v[3], *merge, *priority;
switch (level)
{
@@ -214,19 +221,17 @@ TclDebug (char level, const char *fmt,...)
va_start (args, fmt);
-
- xvasprintf (&buf, fmt, args);
- va_end (args);
-
v[0] = "dbug";
v[1] = priority;
v[2] = buf;
+ vsprintf (buf, fmt, args);
+ va_end (args);
+
merge = Tcl_Merge (3, v);
if (Tcl_Eval (gdbtk_interp, merge) != TCL_OK)
Tcl_BackgroundError (gdbtk_interp);
Tcl_Free (merge);
- free(buf);
}
@@ -240,7 +245,8 @@ TclDebug (char level, const char *fmt,...)
*/
static void
-cleanup_init (void *ignore)
+cleanup_init (ignored)
+ int ignored;
{
if (gdbtk_interp != NULL)
Tcl_DeleteInterp (gdbtk_interp);
@@ -260,13 +266,13 @@ gdbtk_interactive ()
void
gdbtk_start_timer ()
{
+#ifndef __CYGWIN32__
static int first = 1;
if (first)
{
/* first time called, set up all the structs */
first = 0;
-#ifndef __MINGW32__
sigemptyset (&nullsigmask);
act1.sa_handler = x_event_wrapper;
@@ -286,57 +292,59 @@ gdbtk_start_timer ()
it_off.it_interval.tv_usec = 0;
it_off.it_value.tv_sec = 0;
it_off.it_value.tv_usec = 0;
-#endif
}
if (target_should_use_timer (&current_target))
{
if (!gdbtk_timer_going)
{
-#ifndef __MINGW32__
sigaction (SIGALRM, &act1, NULL);
setitimer (ITIMER_REAL, &it_on, NULL);
-#endif
gdbtk_timer_going = 1;
}
}
+#else /* __CYGWIN32__ */
return;
+#endif
}
/* Stop the timer if it is running. */
void
gdbtk_stop_timer ()
{
+#ifndef __CYGWIN32__
if (gdbtk_timer_going)
{
gdbtk_timer_going = 0;
-#ifndef __MINGW32__
setitimer (ITIMER_REAL, &it_off, NULL);
sigaction (SIGALRM, &act2, NULL);
-#endif
}
+#else /* __CYGWIN32__ */
return;
+#endif
}
+#ifndef __CYGWIN32__
/* Should this target use the timer? See comments before
x_event for the logic behind all this. */
static int
-target_should_use_timer (struct target_ops *t)
+target_should_use_timer (t)
+ struct target_ops *t;
{
return target_is_native (t);
}
+#endif /* !__CYGWIN32__ */
/* Is T a native target? */
int
-target_is_native (struct target_ops *t)
+target_is_native (t)
+ struct target_ops *t;
{
char *name = t->to_shortname;
- if (strcmp (name, "exec") == 0 || strcmp (name, "hpux-threads") == 0
- || strcmp (name, "child") == 0 || strcmp (name, "procfs") == 0
- || strcmp (name, "solaris-threads") == 0
- || strcmp (name, "linuxthreads") == 0
- || strcmp (name, "multi-thread") == 0)
+ if (STREQ (name, "exec") || STREQ (name, "hpux-threads")
+ || STREQ (name, "child") || STREQ (name, "procfs")
+ || STREQ (name, "solaris-threads") || STREQ (name, "linuxthreads"))
return 1;
return 0;
@@ -345,13 +353,13 @@ target_is_native (struct target_ops *t)
/* gdbtk_init installs this function as a final cleanup. */
static void
-gdbtk_cleanup (PTR dummy)
+gdbtk_cleanup (dummy)
+ PTR dummy;
{
Tcl_Eval (gdbtk_interp, "gdbtk_cleanup");
Tcl_Finalize ();
}
-
/* Initialize gdbtk. This involves creating a Tcl interpreter,
* defining all the Tcl commands that the GUI will use, pointing
* all the gdb "hooks" to the correct functions,
@@ -359,16 +367,25 @@ gdbtk_cleanup (PTR dummy)
* the Tcl based library files.
*/
-void
-gdbtk_init (void)
+static void
+gdbtk_init (argv0)
+ char *argv0;
{
struct cleanup *old_chain;
- char *s;
- int element_count;
- const char **exec_path;
- CONST char *internal_exec_name;
+ int found_main;
+ char s[5];
+ Tcl_Obj *auto_path_elem, *auto_path_name;
- old_chain = make_cleanup (cleanup_init, 0);
+ /* If there is no DISPLAY environment variable, Tk_Init below will fail,
+ causing gdb to abort. If instead we simply return here, gdb will
+ gracefully degrade to using the command line interface. */
+
+#ifndef _WIN32
+ if (getenv ("DISPLAY") == NULL)
+ return;
+#endif
+
+ old_chain = make_cleanup ((make_cleanup_func) cleanup_init, 0);
/* First init tcl and tk. */
Tcl_FindExecutable (argv0);
@@ -381,113 +398,15 @@ gdbtk_init (void)
if (!gdbtk_interp)
error ("Tcl_CreateInterp failed");
- /* We need to check if we are being run from
- a bin directory, if not then we may have to
- set some environment variables. */
-
- internal_exec_name = Tcl_GetNameOfExecutable ();
-
- Tcl_SplitPath ((char *) internal_exec_name, &element_count, &exec_path);
-
- if (strcmp (exec_path[element_count - 2], "bin") != 0)
- {
- /* We check to see if TCL_LIBRARY, TK_LIBRARY,
- ITCL_LIBRARY, ITK_LIBRARY, TIX_LIBRARY and maybe
- a couple other environment variables have been
- set (we don't want to override the User's settings).
- If the *_LIBRARY variable is not set, point it at
- the source directory. */
-
- static char set_libs_path_script[] = "\
- set srcDir [file dirname [file dirname $env(TCL_LIBRARY)]];\n\
-\
- if {![info exists env(TK_LIBRARY)]} {\n\
- set env(TK_LIBRARY) [file join $srcDir tk library]\n\
- }\n\
-\
- if {![info exists env(ITCL_LIBRARY)]} {\n\
- set env(ITCL_LIBRARY) [file join $srcDir itcl itcl library]\n\
- }\n\
-\
- if {![info exists env(ITK_LIBRARY)]} {\n\
- set env(ITK_LIBRARY) [file join $srcDir itcl itk library]\n\
- }\n\
-\
- if {![info exists env(IWIDGETS_LIBRARY)]} {\n\
- set env(IWIDGETS_LIBRARY)\
- [file join $srcDir itcl iwidgets generic]\n\
- }\n\
-\
- if {![info exists env(GDBTK_LIBRARY)]} {\n\
- set env(GDBTK_LIBRARY) [file join $srcDir gdb gdbtk library]\n\
- }\n\
-\
- # Append the directory with the itcl pkg index\n\
- if {[info exists env(TCLLIBPATH)]} {\n\
- append env(TCLLIBPATH) :[file joing $srcDir itcl]\n\
- } else {\n\
- set env(TCLLIBPATH) [file join $srcDir itcl]\n\
- }\n\
-\
- # We also need to append the iwidgets library path.\n\
- # Unfortunately, there is no IWIDGETS_LIBRARY.\n\
- set IWIDGETS_LIBRARY [file join $srcDir itcl iwidgets generic]\n";
-
- Tcl_Obj *commandObj;
-
- /* Before we can run our script we must set TCL_LIBRARY. */
- if (Tcl_GetVar2 (gdbtk_interp, "env", "TCL_LIBRARY", TCL_GLOBAL_ONLY) == NULL)
- {
- int i, count;
- char *src_dir = SRC_DIR;
- const char **src_path;
- const char **lib_path;
- Tcl_DString lib_dstring;
-
- Tcl_DStringInit (&lib_dstring);
-
-#ifdef __CYGWIN__
- /* SRC_DIR from configure is a posix path. Tcl really needs a
- windows path. */
- src_dir = (char *) alloca (cygwin_posix_to_win32_path_list_buf_size (SRC_DIR));
- cygwin_posix_to_win32_path_list (SRC_DIR, src_dir);
-#endif
- Tcl_SplitPath (src_dir, &count, &src_path);
-
- /* Append tcl/library to src_dir (src_dir=/foo/bar/gdb) */
- lib_path = (const char **) alloca ((count + 2) * sizeof (char *));
- for (i = 0; i < count - 1; i++)
- lib_path[i] = src_path[i];
- lib_path[i++] = "tcl";
- lib_path[i++] = "library";
- Tcl_JoinPath (i, lib_path, &lib_dstring);
-
- /* Set TCL_LIBRARY */
- Tcl_SetVar2 (gdbtk_interp, "env", "TCL_LIBRARY",
- Tcl_DStringValue (&lib_dstring) , TCL_GLOBAL_ONLY);
- Tcl_DStringFree (&lib_dstring);
- Tcl_Free ((char *) src_path);
- }
-
- commandObj = Tcl_NewStringObj (set_libs_path_script, -1);
- Tcl_IncrRefCount (commandObj);
- Tcl_EvalObj (gdbtk_interp, commandObj);
- Tcl_DecrRefCount (commandObj);
- }
-
- Tcl_Free ((char *) exec_path);
-
if (Tcl_Init (gdbtk_interp) != TCL_OK)
error ("Tcl_Init failed: %s", gdbtk_interp->result);
/* Set up some globals used by gdb to pass info to gdbtk
for start up options and the like */
- xasprintf (&s, "%d", inhibit_gdbinit);
+ sprintf (s, "%d", inhibit_gdbinit);
Tcl_SetVar2 (gdbtk_interp, "GDBStartup", "inhibit_prefs", s, TCL_GLOBAL_ONLY);
- free(s);
-
/* Note: Tcl_SetVar2() treats the value as read-only (making a
- copy). Unfortunately it does not mark the parameter as
+ copy). Unfortunatly it does not mark the parameter as
``const''. */
Tcl_SetVar2 (gdbtk_interp, "GDBStartup", "host_name", (char*) host_name, TCL_GLOBAL_ONLY);
Tcl_SetVar2 (gdbtk_interp, "GDBStartup", "target_name", (char*) target_name, TCL_GLOBAL_ONLY);
@@ -511,6 +430,11 @@ gdbtk_init (void)
Tcl_StaticPackage (gdbtk_interp, "Itk", Itk_Init,
(Tcl_PackageInitProc *) NULL);
+ if (Tix_Init (gdbtk_interp) != TCL_OK)
+ error ("Tix_Init failed: %s", gdbtk_interp->result);
+ Tcl_StaticPackage (gdbtk_interp, "Tix", Tix_Init,
+ (Tcl_PackageInitProc *) NULL);
+
if (Tktable_Init (gdbtk_interp) != TCL_OK)
error ("Tktable_Init failed: %s", gdbtk_interp->result);
@@ -520,31 +444,26 @@ gdbtk_init (void)
* These are the commands to do some Windows Specific stuff...
*/
-#ifdef __WIN32__
+#ifdef __CYGWIN32__
if (ide_create_messagebox_command (gdbtk_interp) != TCL_OK)
error ("messagebox command initialization failed");
/* On Windows, create a sizebox widget command */
-#if 0
if (ide_create_sizebox_command (gdbtk_interp) != TCL_OK)
error ("sizebox creation failed");
-#endif
if (ide_create_winprint_command (gdbtk_interp) != TCL_OK)
error ("windows print code initialization failed");
if (ide_create_win_grab_command (gdbtk_interp) != TCL_OK)
error ("grab support command initialization failed");
-#endif
-#ifdef __CYGWIN32__
/* Path conversion functions. */
if (ide_create_cygwin_path_command (gdbtk_interp) != TCL_OK)
error ("cygwin path command initialization failed");
if (ide_create_shell_execute_command (gdbtk_interp) != TCL_OK)
error ("cygwin shell execute command initialization failed");
-#endif
-
- /* Only for testing -- and only when it can't be done any
- other way. */
+#else
+ /* for now, this testing function is Unix only */
if (cyg_create_warp_pointer_command (gdbtk_interp) != TCL_OK)
error ("warp_pointer command initialization failed");
+#endif
/*
* This adds all the Gdbtk commands.
@@ -555,45 +474,37 @@ gdbtk_init (void)
error ("Gdbtk_Init failed: %s", gdbtk_interp->result);
}
- Tcl_StaticPackage (gdbtk_interp, "Insight", Gdbtk_Init, NULL);
+ Tcl_StaticPackage (gdbtk_interp, "Gdbtk", Gdbtk_Init, NULL);
+
+ /* This adds all the hooks that call up from the bowels of gdb
+ * back into Tcl-land...
+ */
+
+ gdbtk_add_hooks ();
/* Add a back door to Tk from the gdb console... */
add_com ("tk", class_obscure, tk_command,
"Send a command directly into tk.");
- add_com ("view", class_obscure, view_command,
- "View a location in the source window.");
-
/*
- * Set the variable for external editor:
+ * Set the variables for external editor:
*/
- if (external_editor_command != NULL)
- {
- Tcl_SetVar (gdbtk_interp, "external_editor_command",
- external_editor_command, 0);
- xfree (external_editor_command);
- external_editor_command = NULL;
- }
-
-#ifdef __CYGWIN32__
- (void) FreeConsole ();
-#endif
+ Tcl_SetVar (gdbtk_interp, "enable_external_editor",
+ enable_external_editor ? "1" : "0", 0);
+ Tcl_SetVar (gdbtk_interp, "external_editor_command",
+ external_editor_command, 0);
- discard_cleanups (old_chain);
-}
-
-void
-gdbtk_source_start_file (void)
-{
/* find the gdb tcl library and source main.tcl */
+
+ {
#ifdef NO_TCLPRO_DEBUGGER
- static char script[] = "\
+ static char script[] = "\
proc gdbtk_find_main {} {\n\
global Paths GDBTK_LIBRARY\n\
rename gdbtk_find_main {}\n\
- tcl_findLibrary insight 1.0 {} main.tcl GDBTK_LIBRARY GDBTKLIBRARY\n\
+ tcl_findLibrary gdb 1.0 {} main.tcl GDBTK_LIBRARY GDBTK_LIBRARY gdbtk/library gdbtcl {}\n\
set Paths(appdir) $GDBTK_LIBRARY\n\
}\n\
gdbtk_find_main";
@@ -609,41 +520,37 @@ proc gdbtk_find_main {} {\n\
} else {\n\
set debug_startup 0\n\
}\n\
- tcl_findLibrary insight 1.0 {} main.tcl GDBTK_LIBRARY GDBTK_LIBRARY\n\
+ tcl_findLibrary gdb 1.0 {} main.tcl GDBTK_LIBRARY GDBTK_LIBRARY gdbtk/library gdbtcl {} $debug_startup\n\
set Paths(appdir) $GDBTK_LIBRARY\n\
}\n\
gdbtk_find_main";
#endif /* NO_TCLPRO_DEBUGGER */
- /* now enable gdbtk to parse the output from gdb */
- gdbtk_disable_fputs = 0;
-
- if (Tcl_GlobalEval (gdbtk_interp, (char *) script) != TCL_OK)
- {
- const char *msg;
+ /* fputs_unfiltered_hook = NULL; *//* Force errors to stdout/stderr */
- /* Force errorInfo to be set up propertly. */
- Tcl_AddErrorInfo (gdbtk_interp, "");
- msg = Tcl_GetVar (gdbtk_interp, "errorInfo", TCL_GLOBAL_ONLY);
+ fputs_unfiltered_hook = gdbtk_fputs;
-#ifdef _WIN32
- /* On windows, display the error using a pop-up message box.
- If GDB wasn't started from the DOS prompt, the user won't
- get to see the failure reason. */
- MessageBox (NULL, msg, NULL, MB_OK | MB_ICONERROR | MB_TASKMODAL);
+ if (Tcl_GlobalEval (gdbtk_interp, (char *) script) != TCL_OK)
{
- struct gdb_exception e;
- e.reason = RETURN_ERROR;
- e.error = GENERIC_ERROR;
- e.message = msg;
- throw_exception (e);
- }
+ char *msg;
+
+ /* Force errorInfo to be set up propertly. */
+ Tcl_AddErrorInfo (gdbtk_interp, "");
+
+ msg = Tcl_GetVar (gdbtk_interp, "errorInfo", TCL_GLOBAL_ONLY);
+
+ fputs_unfiltered_hook = NULL; /* Force errors to stdout/stderr */
+
+#ifdef _WIN32
+ MessageBox (NULL, msg, NULL, MB_OK | MB_ICONERROR | MB_TASKMODAL);
#else
- /* FIXME: cagney/2002-04-17: Wonder what the lifetime of
- ``msg'' is - does it need a cleanup? */
- error ("%s", msg);
+ fputs_unfiltered (msg, gdb_stderr);
#endif
- }
+
+ error ("");
+
+ }
+ }
/* Now source in the filename provided by the --tclcommand option.
This is mostly used for the gdbtk testsuite... */
@@ -656,13 +563,9 @@ gdbtk_find_main";
free (gdbtk_source_filename);
free (script);
}
-}
-static void
-gdbtk_init_1 (char *arg0)
-{
- argv0 = arg0;
- deprecated_init_ui_hook = NULL;
+
+ discard_cleanups (old_chain);
}
/* gdbtk_test is used in main.c to validate the -tclcommand option to
@@ -670,7 +573,8 @@ gdbtk_init_1 (char *arg0)
startup procedure. */
int
-gdbtk_test (char *filename)
+gdbtk_test (filename)
+ char *filename;
{
if (access (filename, R_OK) != 0)
return 0;
@@ -684,12 +588,16 @@ gdbtk_test (char *filename)
void
_initialize_gdbtk ()
{
- /* Current_interpreter not set yet, so we must check
- if "interpreter_p" is set to "insight" to know if
- insight is GOING to run. */
- if (strcmp (interpreter_p, "insight") == 0)
- deprecated_init_ui_hook = gdbtk_init_1;
-#ifdef __CYGWIN__
+ if (use_windows)
+ {
+ /* Tell the rest of the world that Gdbtk is now set up. */
+
+ init_ui_hook = gdbtk_init;
+#ifdef __CYGWIN32__
+ (void) FreeConsole ();
+#endif
+ }
+#ifdef __CYGWIN32__
else
{
DWORD ft = GetFileType (GetStdHandle (STD_INPUT_HANDLE));
@@ -718,14 +626,15 @@ _initialize_gdbtk ()
}
static void
-tk_command (char *cmd, int from_tty)
+tk_command (cmd, from_tty)
+ char *cmd;
+ int from_tty;
{
int retval;
char *result;
struct cleanup *old_chain;
- /* Catch case of no argument, since this will make the tcl interpreter
- dump core. */
+ /* Catch case of no argument, since this will make the tcl interpreter dump core. */
if (cmd == NULL)
error_no_arg ("tcl command to interpret");
@@ -736,33 +645,13 @@ tk_command (char *cmd, int from_tty)
old_chain = make_cleanup (free, result);
if (retval != TCL_OK)
- error ("%s", result);
+ error (result);
printf_unfiltered ("%s\n", result);
do_cleanups (old_chain);
}
-
-static void
-view_command (char *args, int from_tty)
-{
- char *script;
- struct cleanup *old_chain;
-
- if (args != NULL)
- {
- xasprintf (&script,
- "[lindex [ManagedWin::find SrcWin] 0] location BROWSE_TAG [gdb_loc %s]",
- args);
- old_chain = make_cleanup (xfree, script);
- if (Tcl_Eval (gdbtk_interp, script) != TCL_OK)
- {
- Tcl_Obj *obj = Tcl_GetObjResult (gdbtk_interp);
- error ("%s", Tcl_GetStringFromObj (obj, NULL));
- }
-
- do_cleanups (old_chain);
- }
- else
- error ("Argument required (location to view)");
-}
+
+/* Local variables: */
+/* change-log-default-name: "ChangeLog-gdbtk" */
+/* End: */
diff --git a/gdb/gdbtk/generic/gdbtk.h b/gdb/gdbtk/generic/gdbtk.h
index e5e5d1da389..4ef0550ac69 100644
--- a/gdb/gdbtk/generic/gdbtk.h
+++ b/gdb/gdbtk/generic/gdbtk.h
@@ -1,6 +1,5 @@
/* Tcl/Tk interface routines header file.
- Copyright (C) 1994, 1995, 1996, 1997, 1998, 2000, 2001, 2003, 2008
- Free Software Foundation, Inc.
+ Copyright 1994-1998, 2000 Free Software Foundation, Inc.
Written by Stu Grossman <grossman@cygnus.com> of Cygnus Support.
@@ -19,11 +18,8 @@
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
- Foundation, Inc., 51 Franklin Street, Fifth Floor,
- Boston, MA 02110-1301, USA. */
-
-#ifndef _GDBTK_H
-#define _GDBTK_H
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
#ifdef _WIN32
#define GDBTK_PATH_SEP ";"
@@ -83,8 +79,14 @@ extern int load_in_progress;
extern Tcl_Interp *gdbtk_interp;
+/* These two are lookup tables for elements of the breakpoint structure that
+ gdbtk knows by string name. They are defined in gdbtk-cmds.c */
+
+extern char *bptypes[];
+extern char *bpdisp[];
+
/*
- * This structure controls how the gdb output is fed into gdbtk_call_wrapper invoked
+ * This structure controls how the gdb output is fed into call_wrapper invoked
* commands. See the explanation of gdbtk_fputs in gdbtk_hooks.c for more details.
*/
@@ -98,7 +100,6 @@ typedef struct gdbtk_result
gdbtk_result;
struct target_ops;
-struct ptid_t;
/* These defines give the allowed values for the gdbtk_result.flags field. */
@@ -115,7 +116,7 @@ struct ptid_t;
output of a call wrapped command directly in
the Tcl result if you want, but beware, it will
not then be preserved across recursive
- gdbtk_call_wrapper invocations. */
+ call_wrapper invocations. */
#define GDBTK_ERROR_STARTED 8 /* This one is just used in gdbtk_fputs. If we
see some output on stderr, we need to clear
the result we have been accumulating, or the
@@ -128,21 +129,15 @@ struct ptid_t;
/* This is a pointer to the gdbtk_result struct that
we are currently filling. We use the C stack to make a stack of these
structures for nested calls to gdbtk commands that are invoked through
- the gdbtk_call_wrapper mechanism. See that function for more details. */
+ the call_wrapper mechanism. See that function for more details. */
extern gdbtk_result *result_ptr;
-/* If you want to restore an old value of result_ptr whenever cleanups
- are run, pass this function to make_cleanup, along with the value
- of result_ptr you'd like to reinstate. */
-extern void gdbtk_restore_result_ptr (void *);
-
/* GDB context identifier */
extern int gdb_context;
-/* Internal flag used to tell callers of deprecated_ui_loop_hook
- whether they should detach from the target. See explanations before
- x_event and gdb_stop. */
+/* Internal flag used to tell callers of ui_loop_hook whether they should
+ detach from the target. See explanations before x_event and gdb_stop. */
extern int gdbtk_force_detach;
/*
@@ -151,18 +146,15 @@ extern int gdbtk_force_detach;
*/
extern int Gdbtk_Init (Tcl_Interp * interp);
-extern void gdbtk_stop_timer (void);
-extern void gdbtk_start_timer (void);
-extern void gdbtk_ignorable_warning (const char *, const char *);
-extern void gdbtk_interactive (void);
-extern int x_event (int);
-extern int gdbtk_two_elem_cmd (char *, char *);
-extern int target_is_native (struct target_ops *t);
+extern void gdbtk_stop_timer PARAMS ((void));
+extern void gdbtk_start_timer PARAMS ((void));
+extern void gdbtk_ignorable_warning PARAMS ((const char *, const char *));
+extern void gdbtk_interactive PARAMS ((void));
+extern int x_event PARAMS ((int));
+extern int gdbtk_two_elem_cmd PARAMS ((char *, char *));
+extern int call_wrapper PARAMS ((ClientData, Tcl_Interp *, int, Tcl_Obj * CONST[]));
+extern int target_is_native PARAMS ((struct target_ops *t));
extern void gdbtk_fputs (const char *, struct ui_file *);
-extern struct ui_file *gdbtk_fileopen (void);
-extern struct ui_file *gdbtk_fileopenin (void);
-extern int gdbtk_disable_fputs;
-extern ptid_t gdbtk_get_ptid (void);
#ifdef _WIN32
extern void close_bfds ();
@@ -176,17 +168,14 @@ extern void
#define GDBTK_SYMBOL_SOURCE_NAME(symbol) \
(SYMBOL_DEMANGLED_NAME (symbol) != NULL \
? SYMBOL_DEMANGLED_NAME (symbol) \
- : DEPRECATED_SYMBOL_NAME (symbol))
+ : SYMBOL_NAME (symbol))
/* gdbtk_add_hooks - add all the hooks to gdb. This will get called
by the startup code to fill in the hooks needed by core gdb. */
extern void gdbtk_add_hooks (void);
-/* Initialize Insight */
-extern void gdbtk_init (void);
-
-/* Start Insight. Insight must have already been initialized with a call
- to gdbtk_init. */
-extern void gdbtk_source_start_file (void);
-#endif /* !_GDBTK_H */
+
+/* Local variables: */
+/* change-log-default-name: "ChangeLog-gdbtk" */
+/* End: */
diff --git a/gdb/gdbtk/library/ChangeLog b/gdb/gdbtk/library/ChangeLog
new file mode 100644
index 00000000000..8e0ae9e3b8b
--- /dev/null
+++ b/gdb/gdbtk/library/ChangeLog
@@ -0,0 +1,6074 @@
+Fri Feb 4 23:19:03 2000 Andrew Cagney <cagney@b1.cygnus.com>
+
+ * gdb/gdbtcl2: Directory renamed to gdb/gdbtk/library.
+
+2000-01-12 Fernando Nasser <fnasser@totem.to.cygnus.com>
+
+ * targetselection.itb (init_target_db): Add the word "serial" to
+ the Angel target to make the distinction clear from the UDP connection.
+
+2000-01-05 Fernando Nasser <fnasser@totem.to.cygnus.com>
+
+ From Dave Vogel (dave@lightsurf.com):
+ * targetselection.itb (init_target_db, config_dialog): Add support
+ for selecting a target running the Angel monitor (RDI protocol)
+ over an UDP connection.
+ * interface.tcl (set_target_name): Set hostname when target is RDI
+ over UDP (see previous entry).
+
+1999-12-15 Fernando Nasser <fnasser@rtl.cygnus.com>
+
+ * variables.tcl: UnEdit any fields open to edit before colapsing
+ a tree branch (it was generating a Tcl exception and stack dump).
+
+1999-09-29 James Ingham <jingham@leda.cygnus.com>
+
+ * prefs.tcl (pref_read): Convert env(HOME) to a win32 path BEFORE
+ handing it to file join, so we won't look for a network drive.
+
+1999-09-23 James Ingham <jingham@leda.cygnus.com>
+
+ * toolbar.tcl (GDBToolBar): Typo.
+ (new_menu): Changed this to allow menus to be altered as well as
+ added.
+ (menu_exists): New method.
+ (clear_menu): New method.
+ (_load_src_images): Moved here from srcbar.tcl. Added Attach &
+ Detach classes. This is all still kind of ill-factored.
+ (In instance data): Made menu data arrays rather than dynamically
+ constructed variables.
+
+ * srcwin.itb (SrcWin::set_execution_status): Let gdb print the PC,
+ since Tcl's conversion may not be wide enough.
+
+ * srctextwin.ith: initialize the Cname variable.
+
+ * srctextwin.itb (SrcTextWin::location):
+ (SrcTextWin::location): Change address compare to a string
+ compare. These are always both hex in the same format, but on a
+ 64 bit host the conversion would fail.
+ (SrcTextWin::showBalloon): Catch all errors in the balloon help
+ but also report them to the debug window.
+ (SrcTextWin::LoadFromCache): Erase and reload dirty cached windows.
+
+ * srcbar.tcl (create_run_menu): Add "Attach", "Detach" and "Kill"
+ for native targets.
+ (do_attach): Attach to a native target.
+ (do_detach): Detach from a native target.
+ (do_kill): Kill a native target.
+
+ * memwin.itb (MemWin::toggle_enabled): Toggle the state of the
+ widget, as well as the color, so people can't edit when the window
+ doesn't contain valid memory.
+ (MemWin::update_address): Set the state to normal if we have
+ loaded valid memory.
+ (MemWin::BadExpr): Set the state to disabled on error.
+ (MemWin::incr_addr): Set the state to normal if a step succeeds.
+
+ * managedwin.itb (ManagedWin::open_dlg): New function. Preferred
+ function when you know you are opening a dialog.
+ (ManagedWin::_open): new function, contains the common bits of
+ opening windows & dialogs.
+ (ManagedWin::open): Use the _open function.
+ (ManagedWin::_create): Don't use Icon windows with modal dialogs.
+
+ * interface.tcl (gdbtk_cleanup): Set a shutting_down flag.
+ (gdbtk_tcl_fputs): Restore the fputs hook. This is trivial to do,
+ and ensures that no one will delete the hook behind our backs.
+ (gdbtk_tcl_fputs_error): ditto.
+ (_open_file): Make file parameter optional, and don't query if it
+ is provided.
+ (gdbtk_attached): New function. Called from attach hook.
+ (gdbtk_detached): New function. Called from detach hook.
+
+ * helpviewer.ith (HtmlViewer): Add the attach dialog to the list
+ of topics.
+
+ * srcbar.tcl (do_kill): Added the Kill menu item for killing the
+ inferior on native targets.
+
+1999-09-16 James Ingham <jingham@leda.cygnus.com>
+
+ * prefs.tcl (pref_set_defaults): define the wrap preference for
+ the console window.
+
+ * console.itb (Console::_paste): Add the "delete selection"
+ semantics so we can use this for all the Paste events.
+ (Console::_delete): New method, centralize delete handling so we
+ can protect against things like delete deleting a selection up in
+ the history region of the window.
+ (Console::_build_win): Change bindings to use _paste & _delete.
+ (Console::_build_win): wrap if told to by the wrap parameter.
+
+ * console.ith: Declare _delete.
+
+1999-09-16 Stan Shebs <shebs@andros.cygnus.com>
+
+ * targetselection.itb (TargetSelection::init_target_db): Remove
+ references to D10V target, use only standard remote for D10V.
+
+1999-09-15 James Ingham <jingham@leda.cygnus.com>
+
+ * console.itb (Console::_paste): Fix another "set foo [catch ...]"
+ idiom.
+ (Console::_build_win): Remove the extraneous posting of the
+ <<Paste>> event in handling B2-Release. Just call _paste.
+
+1999-09-10 James Ingham <jingham@leda.cygnus.com>
+ From Mumit Khan <khan@xraylith.wisc.edu>
+
+ * prefs.tcl (pref_set_defaults): Add main_names preference.
+ * interface.tcl (gdbtk_locate_main): New proc.
+ (run_executable): Use.
+ * srcwin.itb (SrcWin::_build_win): Use.
+ (SrcWin::location): Likewise.
+ (SrcWin::point_to_main): Likewise.
+
+1999-08-27 James Ingham <jingham@leda.cygnus.com>
+
+ * srctextwin.itb (SrcTextWin::FillAssembly): Use the new
+ gdb_load_disassembly.
+ (SrcTextWin::FillMixed): Use the new gdb_load_disassembly.
+
+ * interface.tcl (gdbtk_idle): Call gdbtk_restore_fputs at idle
+ time. This puts the gdbtk_fputs hook back in place, just in case
+ an error left it pointing to null.
+
+1999-08-11 Tom Tromey <tromey@cygnus.com>
+
+ * kod.itb (KodWin::build_win): Don't use Tix.
+ (Various): Changed as a result of build_win change.
+ (KodWin::destructor): Unset new globals. Also unset
+ kodActivePane.
+
+ * kod.ith (labh): Removed variable.
+
+ * kod.ith (set_os): Declare.
+ * kod.itb (KodWin::build_win): Don't use Tix labelled frame
+ widget or Tix paned widget. Removed size boxes from Windows
+ code.
+ (KodWin::constructor): Add `$this set' to gdb_set_hook.
+ (KodWin::destructor): Remove from hook.
+ (KodWin::set_os): New method.
+
+ * toolbar.tcl (GDBToolBar::destructor): Remove from gdb_set_hook.
+ (GDBToolBar::constructor): Add to gdb_set_hook.
+ (set_hook): New method.
+ (create_view_menu): Don't put kod onto menu.
+
+ * kod.itb (KodWin::display_object): Don't put `Details' message in
+ label; this messes up resize and doesn't really add anything.
+
+ * images/kod.gif, images2/kod.gif: Removed.
+ * toolbar.tcl (create_window_buttons): Removed kod button.
+ (add_menu_command): Don't load kod image.
+
+ * kod.itb: Renamed from kod.tcl. Restructured to follow new itcl
+ conventions.
+ * kod.ith: New file.
+
+ * toolbar.tcl (create_window_buttons): Use gdb_kod_cmd, not
+ gdb_kod_name.
+ (create_view_menu): Likewise.
+ * interface.tcl (initialize_gdbtk): Don't mention gdb_kod_name.
+
+ * targetselection.itb (TargetSelection::init_target_db): Added
+ Cisco targets. From Martin Hunt.
+
+ * kod.tcl (build_win): Use correct capitalization for buttons.
+
+1999-08-10 James Ingham <jingham@leda.cygnus.com>
+
+ * srctextwin.itb (SrcTextWin::constructor): Add the disassembly
+ flavor hook.
+ (SrcTextWin::disassembly_changed): New method, fix up all the
+ windows when the disassembly flavor changes.
+ (SrcTextWin::_mtime_changed): We were setting the filename:dirty
+ to 1 regardless of the result of the mtime check... Doh!
+ (SrcTextWin::reconfig): The setTabs call was assuming ALL windows
+ were source windows.
+ (SrcTextWin::do_tag_popup): Remove the balloon when the breakpoint
+ popups are posted as well.
+ (SrcTextWin::do_source_popup): Also handle the case where there is
+ a selection, but the point is not over it.
+
+ * srctextwin.itb (SrcTextWin::destructor): Remove it when the
+ object goes away.
+
+ * regwin.itb (RegWin::constructor): Add the disassembly_flavor_hook.
+ (RegWin::destructor): Remove it when the widget is destroyed.
+ (RegWin::disassembly_changed): New method, tell the widget it
+ needs to redisplay itself with the new register names.
+ (RegWin::reconfig): Actually do the reconstruction if the register
+ set names have changed.
+ * regwin.ith: Add declarations for the new methods.
+
+ * interface.tcl (gdbtk_tcl_disassembly_hook): New hook to support
+ changing the disassembly flavor.
+
+ * srctextwin.itb (SrcTextWin::getVariable): Use a selection in
+ preference to the word around the hit point, if there is one.
+ (SrcTextWin::do_source_popup): Really dismiss the balloon when you
+ popup a menu...
+
+1999-08-05 James Ingham <jingham@leda.cygnus.com>
+
+ * srctextwin.itb (SrcTextWin::showBalloon): Fix ShowBalloon. We
+ can't use "info line" to tell us whether we should post a balloon
+ over the current line, since gdb only considers the first line of
+ a statement executible, not the continuation lines. Instead, show
+ any line in the currently selected function. Sigh...
+
+1999-08-06 Tom Tromey <tromey@cygnus.com>
+
+ * interface.tcl (gdb_set_hook): New hook.
+
+1999-08-02 Tom Tromey <tromey@cygnus.com>
+
+ * managedwin.ith (window_name): Removed extraneous comma.
+
+1999-07-27 Keith Seitz <keiths@cygnus.com>
+
+ * variables.tcl: Rewrite to use new variable rewrite.
+ * locals.tcl: Ditto.
+ * watch.tcl: Ditto.
+ * srctextwin.itb (updateBalloon): Use new variable rewrite.
+ * blockframe.ith, blockframe.itb: New block and frame classes.
+ * data.ith, data,itb: New stack and queue classes (data structures).
+ * tclIndex: Rebuilt.
+
+1999-07-20 Jason Molenda (jsm@bugshack.cygnus.com)
+
+ * prefs.tcl (pref_set_defaults): Set tab_size to the univeral
+ standard of 8, not 4.
+
+1999-07-16 Stan Shebs <shebs@andros.cygnus.com>
+
+ * All files (*.tcl, *.itb, *.ith): Add GPL notices, regularize
+ copyright and header comments.
+
+1999-06-29 James Ingham <jingham@leda.cygnus.com>
+
+ * bpwin.itb (BpWin::bp_store): New proc, store away the current
+ breakpoint list into a gdb command file.
+ (BpWin::bp_restore): restore a breakpoint list from a command file.
+ (BpWin::build_win): Add menu items for store & restore breakpoints.
+
+1999-06-24 Keith Seitz <keiths@cygnus.com>
+
+ * srcwin.itb (SrcWin::destructor): Its "gdb_clear_file_hook",
+ not "gdb_clear_file".
+
+1999-06-23 James Ingham <jingham@leda.cygnus.com>
+
+ * srctextwin.itb (SrcTextWin::_mtime_changed): Catch the call to
+ mtime. This will fail when you are in assembly mode, and the file
+ is actually a function address.
+ (SrcTextWin::motion): Catch the call to showBalloon. There are
+ various things that can go wrong here, and we certainly don't want
+ the user to hear about them.
+
+1999-06-15 Keith Seitz <keiths@cygnus.com>
+
+ * interface.tcl (gdbtk_stop_idle_callback): Catch calls to
+ remove hook, since it could already be gone if we got a signal.
+
+ * srcwin.itb (busy): If there is no target and the
+ debugger is native, we should also let the user know
+ that his program is running.
+
+1999-06-11 James Ingham <jingham@leda.cygnus.com>
+
+ * interface.tcl (gdbtk_tcl_exec_file_display): Only call clear
+ file if there is a file loaded in the source window. This avoids
+ some flashing at startup.
+
+1999-06-10 Keith Seitz <keiths@cygnus.com>
+
+ * srctextwin.itb (do_source_popup): Clear the varBalloon tag
+ before mapping a popup onto the screen.
+ (showBalloon): The "-pc" option was removed from gdb_variable.
+ Provide equivalent functionality, and display popups again.
+
+ * interface.tcl (set_target): Don't call the target dialog
+ if there gdb_target_cmd is empty and we are a native debugger.
+ Don't set a default target -- force the gui to ask the first
+ time!
+ (run_executable): Set options after we have a target, not before.
+
+ * watch.tcl (destructor): Don't call no_inferior -- the window's
+ already been destroyed. Instead, run through our list of variables
+ and delete them.
+
+1999-06-10 James Ingham <jingham@leda.cygnus.com>
+
+ * srctextwin.itb (SrcTextWin::clear_file): Don't try to set the
+ text view back to the gdbtk_scratch_widget, this is very fragile.
+ (SrcTextWin::LoadFromCache): initialize the mtime correctly when
+ you add a window to the cache.
+ (SrcTextWin::LoadFromCache): don't add the ,asm,lib to the scratch
+ widget pane name.
+
+ * interface.tcl (gdbtk_tcl_exec_file_display): Only run
+ gdbtk_clear_file if the filename is not null. This avoids source
+ window flashing.
+
+ * srctextwin.itb (SrcTextWin::_mtime_changed): Set a dirty flag
+ when the mtime has changed so that you can know to reload the
+ source.
+ (SrcTextWin::LoadFromCache): Look at the dirty flag, and reload
+ from disk if it is set.
+
+1999-06-10 Keith Seitz <keiths@cygnus.com>
+
+ * watch.tcl (clear_file): New method.
+ * variables.tcl (constructor): Register gdb_clear_file hook.
+ (destructor): Unregister gdb_clear_file hook.
+ (clear_file): New method.
+ * targetselection.itb (init_target_db): Add Picobug monitor.
+ (fill_targets): Don't explicitly list every TCP target: deduce
+ it from the target database.
+ (native_debugging): Compare host and target triples.
+ * srcwin.ith (clear_file): Add declaration.
+ * srcwin.itb (constructor): Register gdb_clear_file hook.
+ (destructor): Unregister gdb_clear_file hook.
+ (clear_file): New method.
+ * srctextwin.ith (LoadFile): Add arg "mtime_changed".
+ (clear_file): Add declaration.
+ (_mtime_changed): Add declaration.
+ (_initialize_srctextwin): Add declaration.
+ (_clear_cache): Add declaration.
+ * srctextwin.itb (constructor): Move all initialization
+ to _intialize_srctextwin so that we can easily re-initialize.
+ (Stwc): Change layout to explicitly list panes
+ and mtimes.
+ (ClearTags): Catch calls removing tags. Needed when
+ loading new executables.
+ (_mtime_changed): New method.
+ (FillSource): Immitate command line gdb, checking
+ if a file has changed since it was last used. If it has, load
+ it into the cache.
+ (LoadFile): Add parameter to inform whether a file's
+ mtime has changed. Reload the cache if it has.
+ (clear_file): New method.
+ (_initialize_srctextwin): New method.
+ (_clear_cache): New method. Stubbed.
+ * main.tcl: Move initialization of state to initialize_gdbtk in
+ interface.tcl
+ * interface.tcl (gdbtk_tcl_exec_file_display): Don't reset source
+ windows or globals here -- the clear file hook will do that.
+ (set_exe_name): Always say the exe has changed, in case
+ the user reloads the same exe (which he's recompiled).
+ (set_exe): Don't call gdb_clear_file.
+ (set_target): Return string result codes.
+ (clear_file_hook): New hook.
+ (gdbtk_clear_file): New proc.
+ (initialize_gdbtk): New proc. Moved initialization of
+ globals (yich) here from main.tcl
+ * download.itb (download_it): When running set_target,
+ use new string return codes.
+
+ * interface.tcl (gdbtk_attach_target): New proc. Moved
+ contents of run_executable dealing with attaching to
+ a target here.
+ (run_executable): Use gdbtk_attach_target.
+ (connect): Remove and merge with gdbtk_attach_target.
+ * srcbar.tcl (do_connect): Use gdbtk_attach_target to
+ attach to the target.
+
+ * tclIndex: Regenerate.
+
+1999-06-07 James Ingham <jingham@leda.cygnus.com>
+
+ * memwin.ith (numbytes): Change the default to 0, which means
+ "depends on window size". This is really the useful value.
+
+ * memwin.itb (MemWin::newsize): Move getting the rheight to AFTER
+ the update idletasks. Otherwise the bbox call will return "" when
+ the window is being constructed.
+ (MemWin::reconfig): Set rheight back to "" to force it to be
+ recomputed. Both font changes and switch to "depends on window
+ size" could invalidate this.
+
+1999-06-08 Keith Seitz <keiths@cygnus.com>
+
+ * srcwin.itb (set_execution_status): Do not try to second
+ guess gdb_target_has_execution with gdb_running. Make
+ gdb_running follow it. We'll have to fix those targets
+ that do not set inferior_pid as they crawl out of the woodwork.
+
+1999-06-07 James Ingham <jingham@leda.cygnus.com>
+
+ * prefs.tcl (pref_set_defaults): Set the initial height and with
+ of the browser to 0 so the packer & gridder can get this right on
+ systems with different fonts. Fixes CR 100619.
+
+ * browserwin.itb (BrowserWin::_build_win): Don't set the height
+ and width of the file_box and func_box. This keeps them from
+ floating correctly when there is not stored default.
+
+1999-06-04 James Ingham <jingham@leda.cygnus.com>
+
+ * regwin.itb (RegWin::acceptEdit): Call gdbtk_update after
+ changing the register value so that the locals and watch window
+ will get updated if any of these variables are in registers. Fixes
+ CR 100670.
+
+1999-05-25 Keith Seitz <keiths@cygnus.com>
+
+ * variables.tcl (getLocals): Don't pass any args to
+ gdb_get_{locals, args} so that the currently selected frame is used.
+ (context_switch): New method.
+ * locals.tcl (getVariablesBlankPath): Don't catch call to getLocals.
+ getLocals will do it and return {} if an error occurs.
+ Always pass the frame of the variable to the variable backend,
+ assuming that the selected frame is the proper frame to use.
+ (update): Recognize context switches a little better.
+
+ * variables.tcl (cursor): New method.
+ (enable_ui): Use "cursor".
+ (disable_ui): Ditto.
+ (no_inferior): Ditto.
+ (open): Change toplevel's cursor when opening variables.
+
+1999-05-03 Martin Hunt <hunt@cygnus.com>
+
+ * toolbar.tcl (create_help_menu): Open About window as transient.
+
+ * main.tcl: Open About window as transient.
+
+ * about.tcl (About): Set window title.
+
+1999-04-27 James Ingham <jingham@cygnus.com>
+
+ * srcpref.itb (build_win): Pack the frame containing the
+ disassembly flavor chooser. Redid some of the other packing to
+ look a bit nicer too.
+
+ * srcpref.itb (save): Call apply and then close rather than
+ duplicating the apply code.
+
+1999-04-26 James Ingham <jingham@cygnus.com>
+
+ * modal.tcl (ModalDialog): Add the "expire" variable, and cancel
+ the dialog after the given time if set.
+
+ * managedwin.ith (destructor): Use the new quit_if_last method to
+ decide whether to quit the app or not. This way you can manage
+ create a splash screen and not quit the app when you take it down.
+ (quit_if_last): Add default implementation - returns 1.
+
+ * about.tcl (quit_if_last): Add the quit_if_last to the About box,
+ returning 0.
+
+ * main.tcl: Added a line to open a splash screen, but commented it
+ out for devo.
+
+1999-04-22 Keith Seitz <keiths@cygnus.com>
+
+ * targetselection.itb (port_list): ManagedWin has a proc named
+ "open". We really want the tcl command "::open" to open a port.
+
+1999-04-15 Martin Hunt <hunt@cygnus.com>
+
+ * prefs.tcl (pref_set_defaults): New pref, gdb/use_icons.
+ This is set if Unix should use gdbtk_icon.gif as an icon. Some
+ window managers, such as olvwm, have problems with it.
+ * managedwin.itb (ManagedWin::_create): Don't create icon
+ for Unix, unless gdb/use_icons is set.
+ * globalpref.itb (GlobalPref::build_win): Add a checkbutton to set
+ pref gdb/use_icons.
+
+ * managedwin.itb (ManagedWin::window_name): If iconname is
+ not specified, use window name.
+ (ManagedWin::_create): For Unix, call make_icon_window.
+ (ManagedWin::make_icon_window): New function. Makes a unix
+ icon.
+
+ * main.tcl: Set initial target to "exec" if running in
+ test mode.
+
+ * bpwin.itb (BpWin::constructor): Set icon name to "BPs".
+ * regwin.itb (BpWin::build_win): Set icon name to "Regs".
+ * srcwin.itb (SrcWin::_update_title): Set icon name to basename
+ of filename.
+ * variables.tcl (VariableWin::build_win): Set icon name to "Locals".
+
+1999-04-12 Keith Seitz <keiths@cygnus.com>
+
+ * variables.tcl (populate): Update the value of the parent variable's
+ children before stuffing them into the window. This makes sure
+ that the value of the variable is always current.
+
+1999-04-09 James Ingham <jingham@cygnus.com>
+
+ * memwin.itb (MemWin::incr_addr): Fix the increment-decrement
+ control. It would allow you to scroll into negative addresses,
+ which causes some simulators to crash. It would also increment
+ improperly in cases where the address value in hex corresponded to
+ a negative signed int.
+
+1999-04-07 Martin Hunt <hunt@cygnus.com>
+
+ * interface.tcl (gdbtk_signal): Don't set gdb_running to 0.
+
+1999-04-06 Martin Hunt <hunt@cygnus.com>
+
+ * targetselection.itb (TargetSelection::getname): Call init_target_db.
+ (TargetSelection::init_target_db): Add target mon2000. Set
+ most remote targets to default to downloading. Add new
+ baudrates for remote target. Other misc target fixes.
+ (save) Use "pref setd" in case pref is not created yet.
+ (TargetSelection::config_dialog): Gray out port number when
+ in exec mode.
+
+ * targetselection.ith: Add public proc init_target_db.
+
+ * srcwin.itb (SrcWin::set_execution_status): Don't print anything
+ if gdb_running is 0.
+
+ * srctextwin.itb (SrcTextWin::motion): Show variable values
+ even when not debugging. Needed so users can examine values after
+ a segfault.
+
+ * interface.tcl (set_target): If the target name is "",
+ use the default target name.
+ (run_executable): Set gdb_running correctly. Don't
+ allow downloading to "exec".
+ (gdbtk_signal): New function called from gdbtk_annotate_signal.
+ Sets gdb_running to 0 and pops up a dialog with the
+ signal name and description.
+
+ * main.tcl: Set initial target name to "". Set gdb_target_changed
+ so a dialog will always be forced the first time.
+
+ * download.itb (Download::download_it): Set gdb_loaded before
+ notifying src windows the download is done. Catch the notifications
+ in case the dialog has been closed.
+
+ * console.itb (Console::destructor): Set gdbtk_state(console)
+ to "" instead of unsetting it.
+
+1999-04-02 James Ingham <jingham@cygnus.com>
+
+ * memwin.itb (MemWin::build_win): Remove the -validate option from
+ the memory spinner. It was not appropriate, since you can type
+ expressions into the window.
+
+1999-04-02 Keith Seitz <keiths@cygnus.com>
+
+ * tclIndex: Rebuilt.
+ * toolbar.tcl (create_control_buttons): Use SrcWin's
+ inferior method to centralize control of inferior state.
+ (create_control_buttons): Ditto.
+ (source): Move SrcBar's public variable "source" here,
+ so that the toolbar can use that info, too.
+ * srcwin.itb (SrcWin::inferior): New public method
+ to consildate inferior control and dispatch to proper
+ handlers.
+ * srcwin.ith (SrcWin::inferior): Add declaration.
+ * srctextwin.itb (SrcTextWin::do_key): Use parent SrcWin's inferior
+ method to handle inferior state changes (run, step, next, etc).
+ * interface.tcl: Add procs to centralize inferior control:
+ gdbtk_step, gdbtk_next, gdbtk_stepi, gdbtk_nexti, gdbtk_run,
+ gdbtk_continue, gdbtk_finish, gdbtk_stop.
+ New stop button code (see comments before gdbtk_stop):
+ (gdbtk_stop_idle_callback): Idle callback for stop button.
+ (gdbtk_detach): New proc to forcibly detach from target.
+ * main.tcl: Initialize data used by stop button.
+ * srcbar.tcl (create_run_menu): Call SrcWin's inferior
+ method with button commands.
+ (source): Move "source" to Toolbar class.
+
+1999-03-29 Keith Seitz <keiths@cygnus.com>
+
+ * browserwin.itb (BrowserWin::do_all_bp): Fix quoting of break
+ command.
+ (BrowserWin::_toggle_bp): Ditto.
+
+1999-03-19 Keith Seitz <keiths@cygnus.com>
+
+ * download.itb (Download::download_it): Configure SrcWin's toolbar,
+ too, to a downloading state.
+ * srcbar.tcl (runstop): Change states from numbers to
+ strings to avoid confusion.
+ (_set_runstop): Change states from numbers to strings to
+ avoid confusion.
+ * srcwin.ith (toolbar): New public method.
+ * srcwin.itb: Change all references of runstop to use new strings
+ introduced into GDBSrcBar::_set_runstop.
+ (SrcWin::toolbar): New public method to configure the state of the toolbar.
+ * tclIndex: Regenerate.
+
+1999-03-18 Martin Hunt <hunt@cygnus.com>
+
+ * interface.tcl (set_target_name): Remove first argument.
+ If prompt is not set, still update gdb_target_cmd.
+ (set_target): Call set_target_name with prompt argument
+ set correctly.
+ (run_executable): Check for no exe name. Catch problems
+ with bad target names and prompt for new one.
+
+ * main.tcl: Set target name from prefs. If it is "",
+ the set "gdb_target_changed" to force it to be changed
+ later.
+
+ * prefs.tcl (pref_set_defaults): Don't set target default
+ to "exec". Leave the default unset.
+
+ * srcbar.tcl (create_menu_items): Update args to
+ set_target_name.
+
+1999-03-18 Keith Seitz <keiths@cygnus.com>
+
+ * prefs.tcl (pref_read): Change unix preference filename
+ to ".gdbtkinit". This bogosity has been around long enough.
+
+1999-03-16 Martin Hunt <hunt@cygnus.com>
+
+ * managedwin.itb (ManagedWin::_create): When running under
+ testsuite, don't resize.
+
+1999-03-13 James Ingham <jingham@cygnus.com>
+
+ * browserwin.itb (BrowserWin::search): If all the files are
+ selected in the file box, then don't pass the files argument.
+ This makes the function browser a little quicker. The main
+ slowdown, however, is sorting the resultant list. Maybe do this
+ in C to get this quicker?
+
+ * memwin.itb (MemWin::edit): Comment out the line that reads back
+ in the newly set memory value. Because of the chain of calls,
+ on Windows this causes some evil race that results in GDBTk
+ filling all the visible cells with the new value. I don't
+ understand it yet, so this is just a temporary fix.
+
+1999-03-12 James Ingham <jingham@cygnus.com>
+
+ * memwin.ith (MemWin): Add saved_addr to the class. This is where
+ we store the old address before we change addresses, so that we
+ can get back to a good state in case of errors.
+
+ * memwin.itb (MemWin::update_addr): gdb_get_mem does not always
+ return an error code when it hits an error. Catch that here.
+ (MemWin::update_address): Store away the old address, so we can
+ restore it if there is an error.
+ (MemWin::BadExpr): Restore the saved address in case of errors.
+
+
+1999-03-09 James Ingham <jingham@cygnus.com>
+
+ * Rebuilt tclIndex.
+
+1999-03-08 James Ingham <jingham@cygnus.com>
+
+ * srctextwin.itb (SrcTextWin::constructor): pc(funcname) was
+ changed to pc(func), but the initialization was not changed...
+
+ * download.ith (dont_remember_size): Download window should not
+ remember its size.
+
+ * interface.tcl (connect): Handle the case where set_target
+ returns 3...
+
+ * debugwin.itb (DebugWinDOpts::build_win): Replace $this delete
+ with delete object $this.
+ * tfind_args.tcl (build_win): Ditto...
+ * helpviewer.itb (HtmlViewer::_buildwin): Ditto...
+
+ * srcbar.tcl (GDBSrcBar): Reorder the Source & the page setup &
+ print menus...
+
+1999-03-04 Martin Hunt <hunt@cygnus.com>
+
+ * download.ith: New file.
+ * download.itb: New file. Implements itcl3 class and replaces
+ download.tcl.
+
+ * srcbar.tcl (create_menu_items): Call create_run_menu
+ without arguments.
+ (create_run_menu): Add Disconnect and Connect to Run menu
+ instead of file menu. Change download_it to Download::download_it.
+
+ * srctextwin.itb (do_key): Change binding to call
+ Download::download_it.
+
+ * debugwin.itb (DebugWinDOpts::build_win): Add ProcessWIn to list
+ of classes for filter.
+
+ * interface.tcl (set_target): No need to set window title.
+ (run_executable): Change download_it to Download::download_it
+
+1999-03-04 James Ingham <jingham@cygnus.com>
+
+ * modal.tcl (ModalDialog): Handle WM_DELETE_WINDOW by calling the
+ cancel method. Also set unpost_notification to different values
+ in unpost & the destructor, so if the object dies irregularly, you
+ know not to try to double destruct it.
+
+1999-03-03 James Ingham <jingham@cygnus.com>
+
+ * warning.tcl (WarningDlg::constructor):Destroy with unpost.
+
+ * util.tcl (get_disassembly_flavor, set_disassembly_flavor,
+ init_disassembly_flavor): Added these functions for the Intel P2
+ disassembly flavors.
+ (list_element_strcmp): New function for lsort -command on lists.
+
+ * tracedlg.tcl (TraceDlg): Change combobox callback to reflect new
+ after behavior.
+
+ * targetselction.itb (TargetSelection::save): If the target
+ is not valid, tell the user rather than simple refusing to go
+ away.
+ Also move stuff around to isolate the instance dependant stuff as
+ much as possible
+ Also replace delete with unpost.
+
+ * targetselection.ith (TargetSelection): Make as much of the
+ initialization stuff Class functions as possible. Then only
+ initialize it once.
+
+ * srcwin.ith (_update_title): initialize need_files.
+
+ * srcwin.itb (SrcWin::_build_win): I changed the combobox so it
+ ran its code in an idle handler, so we can take out all the after
+ idle... cruft here.
+
+ * srctextwin.ith (SrcTextWin): Added textheight variable so you
+ can adjust the height of the text display.
+
+ * srctextwin.itb (SrcTextWin::build_win): Don't hardcode the size
+ of the text window, set it with the textheight option instead.
+ Also replace childsite with "component text" wherever required.
+
+ * srcpref.itb (SrcPref::build_win, set_flavor): Added the Intel
+ disassembly flavor combobox. Added set_flavor method to support
+ this.
+ * srcpref.ith: Added declaration for set_flavor, and
+ disassembly_flavor instance variable.
+
+ * modal.tcl (ModalDialog::post, unpost): Added unpost method to
+ provide a more regular way to dismiss the dialogs. Just
+ destroying them was leading to funny destruction order bugs.
+ Added cancel method, which is what client code should call to
+ "force close" the dialog, so child classes can override, and do
+ some cleanup.
+
+ * memwin.itb (MemWin::destructor): Call the cancel method of the
+ Preferences dialog (if it is posted) rather than just destroying
+ it.
+
+ * mempref.itb (MemPref::ok): call unpost, since this is a modal
+ dialog.
+
+ * managedwin.itb (ManagedWin::reveal): Used to be called raise.
+ Don't reuse Tcl or Tk commands unless there is a really good
+ reason to...
+ (ManagedWin::destroy_toplevel): renamed from delete, which
+ conflicts both with the Itcl1.5 delete method, and the Itcl3.0
+ delete command... Also, don't use this as the way to destroy
+ ManagedWins, rather destroy the object and let the object take
+ care of removing its toplevel.
+ (ManagedWin::_create): Group all the windows with
+ . for WindowManagers that properly handle this.
+ (ManagedWin::_create): Use dont_remember_size
+ rather than the instance variable. Also, windows which don't
+ remember size are not necessarily transient.
+ (ManagedWin::_create): Only call post if the
+ ManagedWin also isa ModalDialog. It is clearer what is going on.
+ * managedwin.ith: Carry through the name changes.
+
+ * main.tcl: call init_disassembly_flavor for Intel assembly
+ flavors.
+
+ *main.tcl: Group . with . This is half of the work required to
+ play nice with WindowMaker. The other half waits till we can get
+ gdb to pass the command-line arguments to Tcl.
+
+ * interface.tcl: Add file_changed_hook to the hooks. The browser
+ window watches this and refreshes the file box if it changes.
+
+ * globalpref.ith (GlobalPref): This should be a modal dialog.
+ * globalpref.itb (GlobalPref::build_win): call update idletasks,
+ not update. Since we are calling update, there is no reason to
+ delay calling resize_font_item_height.
+ * globalpref.itb: Replace destroy toplevel with unpost.
+
+ * debugwin.itb (DebugWin::build_win): Replace childsite with
+ "component text"
+
+ * console.itb (Console::_build_win): Replace childsite with
+ "component text"
+
+ * browserwin.itb: Rewritten pretty completely.
+ * prefs.tcl (pref_set_defaults): add the browser preferences.
+
+ * prefs.tcl (pref_set_defaults): add the intel disassembly flavor
+ preference.
+
+ * about.tcl (About): This should be a modal dialog.
+
+1999-03-02 James Ingham <jingham@cygnus.com>
+
+ * globalpref.itb (GlobalPref::make_font_item): Don't do the
+ resize_font_item_height here, since an update can cause the resize
+ before all the windows are built. Delay to the end of build_win
+ instead.
+
+1999-02-24 James Ingham <jingham@cygnus.com>
+
+ * toolbar.tcl (remove_button): Specify the row in the toolbar from
+ which you are removing the item. On Windows, there are two rows
+ in the standard toolbar...
+
+1999-02-22 Martin Hunt <hunt@cygnus.com>
+
+ * warning.tcl (WarningDlg::constructor): Remove extra quote
+ that was causing loading of this module to fail.
+
+ * managedwin.itb (ManagedWin::_create): If the pack fails
+ (for example because the warning dialog reliazed it should
+ ignore the warning) print a warning debug message and return.
+ Also, while testing, tell the window manager to position
+ the window without asking the user for the position.
+
+1999-02-18 Martin Hunt <hunt@cygnus.com>
+
+ * srctextwin.itb (SrcTextWin::FillAssembly): As a last resort,
+ if the disassembly fails for some reason, switch to the scratch
+ pane and write in a message about not being able to disassemble.
+
+1999-02-18 Martin Hunt <hunt@cygnus.com>
+
+ * helpviewer.ith (HtmlViewer): Add thread and function
+ browser windows to help index.
+
+ * help/index.toc: Removed.
+
+1999-02-18 Martin Hunt <hunt@cygnus.com>
+
+ * help/thread.html: New file. Thread window online help.
+ * help/index.html: Add thread.html, and alphabetize list.
+ * help/source.html: Add index for thread_bp.
+
+1999-02-17 Martin Hunt <hunt@cygnus.com>
+
+ * globalpref.itb (GlobalPref::build_win): Add a checkbutton to
+ allow use of an internet browser to read help files.
+
+ * prefs.tcl (pref_set_defaults): Add preference gdb/help/browser.
+ Default is to use builtin html help.
+
+ * helpviewer.itb (HtmlViewer::open_help): New public proc.
+ Depending on preferences, opens help in external browser or
+ internal htmlviewer.
+
+ * toolbar.tcl (create_help_menu): Use HtmlViewer::open_help.
+
+1999-02-17 Martin Hunt <hunt@cygnus.com>
+
+ * managedwin.itb (ManagedWin::_create): Restore some lines that
+ were accidently checked in commented out.
+
+1999-02-17 Keith Seitz <keiths@cygnus.com>
+
+ * help/index.html: Add function browser.
+ * help/browser.html: New help file.
+
+1999-02-12 Martin Hunt <hunt@cygnus.com>
+
+ * managedwin.itb (ManagedWin::_create): If a window class defines a
+ public variable "nosize" the size will not be set, only the position.
+ * browserwin.ith (toggle_all_bp): Add public variable "nosize".
+
+1999-02-12 Martin Hunt <hunt@cygnus.com>
+
+ * process.ith: New file.
+ * process.itb: New file. Converted process.tcl to new itcl class.
+ * process.tcl: Deleted.
+
+ * warning.tcl (WarningDlg::constructor): Set the window name.
+
+1999-02-11 Martin Hunt <hunt@cygnus.com>
+
+ * variables.tcl (editEntry): Check that $variable is not empty.
+
+ * warning.tcl (WarningDlg::constructor): Put focus on the
+ "OK" button and bind it to <Return>.
+
+ * watch.tcl (add): If the user attempts to add a non-existent
+ variable to the watch-window, display an ignorable warning.
+
+ * interface.tcl (gdbtk_tcl_ignorable_warning): -transient
+ should not take an argument.
+ (set_target_name): Ditto.
+ * srcbar.tcl (create_menu_items): Ditto.
+ * memwin.itb (MemWin::create_prefs): Ditto.
+ * managedwin.itb (ManagedWin::_create): Ditto.
+
+1999-02-11 James Ingham <jingham@cygnus.com>
+
+ Move the Intel disassembly mode changes into devo.
+
+ * main.tcl: Init the disassembly flavor bits.
+ * prefs.tcl: Define disassembly-flavor
+ * srcpref.ith: Add current_disassembly_flavor instance variable
+ and set_flavor method.
+ * srcpref.itb (build_win): Add the disassembly_flavor combobox.
+ (apply): set the flavor, if applicable.
+ (set_flavor): New method.
+ * util.tcl: Add 3 new functions - get_disassembly_flavor,
+ list_disassembly_flavor and init_disassembly_flavor.
+
+1999-02-10 Martin Hunt <hunt@cygnus.com>
+
+ * srcwin.itb, download.tcl, main.tcl, srcbar.tcl: Removed old
+ IDE stuff.
+
+ * toolbar.tcl (create_help_menu): Updated Cygnus URL and
+ removed old IDE stuff.
+ (create_ide_buttons): Removed.
+
+1999-02-10 Martin Hunt <hunt@cygnus.com>
+
+ * managedwin.itb (ManagedWin::_create): Bind Alt-F4 to
+ always close the window.
+
+1999-02-10 Martin Hunt <hunt@cygnus.com>
+
+ * main.tcl: Removed old debugging preferences.
+ * prefs.tcl (pref_set_defaults): Ditto.
+
+1999-02-09 Martin Hunt <hunt@cygnus.com>
+
+ * managedwin.itb (ManagedWin::_create): Simplify raise
+ and post now that all windows use new manager.
+
+ * warning.tcl (WarningDlg): Rewrite of entire class to use
+ new itcl 3.0 class. Also now uses a "class name" to keep
+ track of which messages should be ignored. Uses tk_messageBox
+ of the message doesn't have -ignorable set.
+
+ * interface.tcl: Removed IDE stuff.
+ (gdbtk_tcl_ignorable_warning): Accept "class" argument and
+ use it when creating a WarningDlg. Use new ManagedWin::open.
+
+ * srctextwin.itb (SrcTextWin::set_tp_at_line): Fix TraceDlg
+ open command to use ManagedWin::open.
+
+ * srcpref.itb (SrcPref::build_win): Comment out line number
+ option. It wasn't very useful and did not become effective
+ until GDBtk was restarted.
+
+1999-02-09 James Ingham <jingham@cygnus.com>
+
+ * srctextwin.itb (build_win): Set the paned window background to
+ white so it looks better when you switch windows.
+
+ * mempref.itb (build_win): Use the libgui combobox for the bytes per
+ line field.
+
+ * mempref.itb: remove some global declarations that I missed when
+ I converted all the variables to instance data.
+
+ * variables.tcl (change_value): Catch one more place where $this
+ was being passed as a window name.
+
+ * TODO: Added some more items, and removed some that had been fixed.
+
+Mon Feb 8 12:27:16 1999 Keith Seitz <keiths@cygnus.com>
+
+ * interface.tcl (set_target_name): Fix switch syntax
+ error and getd the options preference in case it's not set.
+
+
+Thu Feb 4 11:55:43 1999 Keith Seitz <keiths@cygnus.com>
+
+ * targetselection.itb (_init_db): Add MIPS target.
+ (fill_targets): Ditto.
+
+Thu Feb 4 07:56:12 1999 Keith Seitz <keiths@cygnus.com>
+
+ * targetselection.itb: Set "TargetSelection::target_trace"
+ as the correct trace for gdb_loaded.
+ * targetselection.ith: Make "target_trace" a public proc.
+
+1999-02-03 Martin Hunt <hunt@cygnus.com>
+
+ * help/console.html: Cleaned up and added history and editing
+ commands.
+
+ * stackwin.itb (StackWin::build_win): Remove balloon help.
+
+ * console.itb (Console::_search_history): New function.
+ Does a pattern match on history buffer.
+ (Console::_rsearch_history): New function. Does a pattern
+ match on history buffer in the reverse direction.
+ (Console::_build_win): Bind Control-Up, Control-Down,
+ Shift-Up, and Shift-Down to search history instead of mess
+ up the console window. Bind Control-o to break to disable it.
+
+ * help/stack.html: Cleanup.
+
+ * help/source.html: Add a bunch of missing quotation marks.
+
+1999-02-03 Martin Hunt <hunt@cygnus.com>
+
+ * memwin.itb: Change from tixControl widget to iwidgets::spinint.
+ Fix problems with error dialogs.
+
+1999-02-02 Martin Hunt <hunt@cygnus.com>
+
+ * srctextwin.itb (SrcTextWin::do_source_popup): Even after fixing the
+ obvious syntax errors in this function, it didn't work. So I
+ simplified the logic. Now it will attempt to use whatever is selected.
+ If multiple lines are selected and tracing is enabled, it will set
+ tracepoints, otherwise it will try to extract a variable name from single
+ lines only.
+
+ * main.tcl: Only open debugwin if GDBTK_DEBUG > 1.
+
+ * toolbar.tcl (create_view_menu): Only add "Debug WIndow" menu
+ item if GDBTK_DEBUG is set.
+
+1999-02-02 Martin Hunt <hunt@cygnus.com>
+
+ * browserwin.itb (BrowserWin::_fill_source): Add lib argument
+ from gdb_loc to the call to $Source location.
+ (BrowserWin::_goto_func): Ditto.
+
+1999-02-01 James Ingham <jingham@cygnus.com>
+
+ * browserwin.itb (BrowserWin::_fill_source): Add a null lib
+ argument to the call to $Source location.
+
+1999-02-01 Martin Hunt <hunt@cygnus.com>
+
+ * prefs.tcl (pref_save): Change the list of sections back into
+ a list.
+
+1999-02-01 Martin Hunt <hunt@cygnus.com>
+
+ * srctextwin.itb (SrcTextWin::FillMixed): Simplify line formatting.
+ (SrcTextWin::continue_to_here): Call gdb_set_bp with new type arg.
+ (SrcTextWin::set_bp_at_line): Call gdb_set_bp with new type arg.
+ Use "catch" command and display error if there is one.
+
+1999-02-01 Martin Hunt <hunt@cygnus.com>
+
+ * srcwin.itb (SrcWin::goto_func): Dont attach filename if
+ there isn't a valid one.
+
+Fri Jan 29 20:01:30 1999 Fernando Nasser <fnasser@rtl.cygnus.com>
+
+ * main.tcl: Restored kod code lost with merge
+ * prefs.tcl: Ditto.
+ * srctextwin.tcl: Ditto.
+ * toolbar.tcl: Ditto
+ * kod.tcl: Adapted to the new branch.
+
+1999-01-28 Martin Hunt <hunt@cygnus.com>
+
+ * srcwin.itb (SrcWin::_build_win): Only call gdb_loc once.
+ (SrcWin::location): Update linespec for gdb_loc to include
+ the "lib" arg.
+
+ * srctextwin.itb (SrcTextWin::LoadFromCache): Add "lib"
+ argument. This is used to create a unique cache key so
+ we don't confuse the disassembly of a function in a shared
+ lib with the disassembly of its trampoline. Also updated
+ UnLoadFromCache, LoadFIle, FillSource, FillMixed, and FillAssembly
+ to pass this argument around.
+
+ * helpviewer.ith (HtmlViewer::constructor): Declare we have a
+ constructor.
+ (PageStack::constructor): Delete this declaration.
+
+ * helpviewer.itb (HtmlViewer::constructor): initialize args before
+ calling _buildwin
+
+ * main.tcl: Only open initial debug window if GDBTK_DEBUG
+ is set.
+
+ * help/debug.html: Add help for GDBTK_DEBUG
+
+Wed Jan 27 07:18:05 1999 Keith Seitz <keiths@cygnus.com>
+
+ * interface.tcl (gdbtk_pc_changed): Removed.
+ (gdbtk_register_changed): New procedure.
+ (gdbtk_memory_changed): New procedure.
+
+Mon Dec 21 14:12:14 1998 Keith Seitz <keiths@cygnus.com>
+
+ * manage.tcl (manage_create): Set window geometry after window is
+ created.
+
+ * prefs.tcl (pref_save): Save out preferences for memory window, too.
+
+Thu Dec 17 08:54:37 1998 Keith Seitz <keiths@cygnus.com>
+
+ * browser.tcl (fill_source): Strip off any function args
+ which could arise from C++ function names.
+ (search): Be careful of C++ functions with spaces in the name
+ returned from gdb_search.
+
+Tue Dec 15 13:24:42 1998 Keith Seitz <keiths@cygnus.com>
+
+ * prefs.tcl (escape_value, unescape_value): New procs to
+ escape equal signs in preference values.
+ (pref_read): Use unescape_value whenever prefs are read.
+ (pref_save): Use escape_value whenever prefs are saved..
+
+Tue Dec 15 11:07:01 1998 Keith Seitz <keiths@cygnus.com>
+
+ * process.tcl (build_win): Do not export the listbox's selection
+ as the X selection so that multiple listboxes can have selections
+ highlighted at the same time.
+
+ * stack.tcl (build_win): Ditto.
+
+Mon Dec 14 15:53:38 1998 Keith Seitz <keiths@cygnus.com>
+
+ * watch.tcl (update): Catch errors to getLocals, which could error
+ if no symbol table is loaded.
+
+ * locals.tcl (update): Ditto.
+
+1998-11-17 Fernando Nasser <fnasser@totem.to.cygnus.com>
+
+ * kod.tcl: fix <Double-1> command spec for listbox.
+
+1998-11-13 Martin M. Hunt <hunt@cygnus.com>
+
+ * srctextwin.tcl (bp): Pass "asm" argument to do_bp.
+ (do_bp): Use asm argument to determine whether to
+ check for multiple bps on the same src line. Remove
+ redundant "if" statement.
+
+1998-11-12 Martin M. Hunt <hunt@cygnus.com>
+
+ * srctextwin.tcl (do_bp): Fix multiple assembly
+ breakpoints mapping to the same line number.
+
+Thu Nov 12 15:20:15 1998 Jim Ingham <jingham@cygnus.com>
+
+ * console.tcl (complete): I added the ability to pass from_tty
+ from gdb_cmd to the underlying commands. Pass 1 when the
+ command is invoked from the console.
+
+ * interface.tcl (gdbtk_tcl_tstart, gdbtk_tcl_tstop): Run the
+ src window's do_tstop method rather than manipulating the
+ widgets by hand.
+
+ * src.tcl (build_win): Redo the packing so that the function
+ combobox doesn't push all the other combo-boxes off the screen
+ if it has a very long function name in it.
+
+ * srcbar.tcl (do_tstop): Added a mode that just changes the
+ GUI, which can be called from console hooks.
+
+ * srctextwin.tcl: Fixed some bugs I introduced in setting
+ breakpoints in the assembly & mixed mode windows. Dropped
+ the notion of joint breakpoint images for lines that have
+ breakpoints of two separate types. Too fragile.
+ Also added the "dont_change_appearance" flag, used in the
+ continue_to_here method to tell the GUI not to reflect the
+ temporary disabling of all the breakpoints.
+
+ * toolbar.tcl (insert_buttons): Added a little more error-checking.
+
+Wed Nov 11 08:40:04 1998 Fernando Nasser <fnasser@cygnus.com>
+
+ * kod.c: adjusted sizes and packing options of widgets
+
+1998-11-10 Fernando Nasser <fnasser@totem.to.cygnus.com>
+
+ * main.tcl: small fix to the kod code as requested by the maintainers
+ * kod.tcl: use show kod and info <kod cmd> as per spec
+
+Mon Nov 9 17:00:45 1998 Fernando Nasser <fnasser@cygnus.com>
+
+ * kod.tcl: New file that implements the Kernel Object Display window
+ * Makefile: added kod.tcl
+ * main.tcl: test for kod support
+ * manage.tcl (manage_init): support for kod
+ * prefs.tcl (pref_save, pref_set_defaults): ibid
+ * scrtextwin.tcl (config_win, do_key): ibid
+ * toolbar.tcl (_load_images, create_window_buttons,
+ create_view_menu): ibid
+ * tclIndex: regen
+
+Mon Nov 9 12:09:48 1998 Michael Snyder <msnyder@cleaver.cygnus.com>
+
+ * actiondlg.tcl: Customize the stack collect string to collect
+ the FP reg plus 64 words of stack mem. This will work for many
+ targets. As noted in earlier comment, we need a way to configure
+ this to the specific target.
+
+Wed Nov 4 12:41:42 1998 Jim Ingham <jingham@cygnus.com>
+
+ * actiondlg.tcl: Get the stack collect string from an instance
+ variable. Need to implement some way to get this from the
+ target settings...
+ * global_pref.tcl (toggle_tracing_mode): Add & remove hooks
+ when you go in and out of tracing mode. Also reset the B1
+ behavior when you leave tracing mode
+ * interface.tcl (gdbtk_tcl_trace_find_hook): Added the trace
+ find hook, so you can switch the GUI state when the tfind
+ command is used to enter & leave browse mode.
+ * srcbar.tcl (constructor, destructor trace_find_hook): Added
+ the trace_find_hook to the source toolbar, and added the
+ necessary hooks to handle it.
+ * srctextwin.tcl (trace_find_hook): Added a trace find hook to
+ the sourcebar as well.
+ * stack.tcl (update): protect against errors in gdb_stack.
+ Just return "NO STACK" if we couldn't get it.
+ * src_pref.tcl (constructor, cancel): Put all the saved prefs
+ in an array, on cancel, see if any have changed and only
+ rebuild the window if there have been changes.
+
+1998-11-03 Keith Seitz <keiths@cygnus.com>
+
+ * target.tcl: Add ice target.
+ (GdbLoadPref): Add "after_attaching" preference.
+ (set_saved): Add "after_attaching" preference.
+ (write_saved): Add "after_attaching" preference.
+ (change_target): Add "after_attaching" preference.
+ (build_win): Add "after_attaching" entry to options
+ frame.
+
+ * main.tcl (set_target_name): Add ice target.
+ (set_target): If an "after_attaching" preference exists,
+ run it.
+
+Mon Nov 2 13:24:10 1998 Jim Ingham <jingham@cygnus.com>
+
+ * bp.tcl (update): The hook function was passing more
+ arguments than this function expected.
+
+Mon Nov 2 11:16:10 1998 Jim Ingham <jingham@cygnus.com>
+
+ * toolbar.tcl: Added Tdump image.
+
+Fri Oct 30 17:36:05 1998 Jim Ingham <jingham@cygnus.com>
+
+ * src.tcl (set_execution_status): Changed status messages,
+ tracing is not the same as async debugging...
+
+Fri Oct 30 17:06:31 1998 Jim Ingham <jingham@cygnus.com>
+
+ * bp.tcl (bp_all): Only remove tracepoints in the tracepoint
+ window, and breakpoints in the breakpoint window.
+
+Fri Oct 30 11:22:23 1998 Jim Ingham <jingham@cygnus.com>
+
+ * actiondlg.tcl: Added special tag "Collect Stack". This
+ still needs to get hooked into the target database to deal
+ with targets that need to do something special to collect the
+ stack. Also moved some repeated code into loops.
+ * main.tcl (source_file): Source in a file of gdb commands.
+ * srcbar.tcl (constructor): Added source file menu entry, and
+ made stack buttons belong to both the Trace & Control classes.
+ * srctextwin.tcl (constructor): One too many separators in the
+ trace trace popup menu.
+ * tclIndex: regenerated.
+ * tfind_args.tcl: Added "tfind frame"
+ * toolbar.tcl (create_button): Allow a button to belong to
+ more than one class.
+ * toolbar.tcl (enable_ui): Eliminate redundant code, and allow
+ a button to belong to more than one class.
+ * toolbar.tcl (create_trace_menu): Added save tracepoints &
+ Tfind frame menu items.
+ * tracedlg.tcl: Added deletion of actions, and fixed a
+ the whiile-stepping combobox callback for the new combobox.
+ * util.tcl (save_trace_commands): new proc.
+
+1998-10-29 Michael Snyder <msnyder@demo-laptop2.cygnus.com>
+
+ * target.tcl: add /dev/cua0 for Linux.
+
+Tue Oct 27 13:46:03 1998 Jim Ingham <jingham@cygnus.com>
+
+ * Many little bug fixes all over in order to get tracing to work
+ along with normal program control.
+ * toolbar.tcl: Rewrote much of the code here to put commonly
+ used code into functions, and clean up adding menus and
+ buttons. Added the ability to disable particular menu items,
+ not just whole menus. Added the ability to delete and insert
+ buttons on the fly.
+ * srcbar.tcl: Pushed the changes to toolbar.tcl into this file.
+ * srctextwin.tcl: Changed the code dealing with breakpoints
+ and tracepoints to use the text tags more consistently. Use
+ only one set of menus for the whole widget, rather than having
+ a separate set for the SRC+ASM case. Rewrote a lot of the
+ code to separate out the tracing & program control functions.
+ * interface.tcl (gdbtk_tcl_breakpoint): pass more information
+ to the scrtextwin when a breakpoint changes state, so it can
+ do the right thing without having to guess...
+ * tracedlg.tcl (build_win): get the packing right so the
+ window expands correctly.
+ * main.tcl: do_tstop -> tstop, do_tstart -> tstart to avoid
+ confusion with the methods in ScrBar.tcl.
+ * prefs.tcl: Added two new preferences B1_Behavior to control
+ whether B1 sets breakpoints or tracepoints.
+ * src_prefs.tcl: Put in support for the B1_Behavior.
+ * global_prefs.tcl: Put back tracing checkbox.
+ * tdump.tcl: Fixed an incorrect (1 rather than 1.0) text
+ widget line specification.
+ * tfind_args.tcl (build_win): Bind return in the entry to the
+ OK button. Clear the entry field if the Type has changed.
+ * utils.tcl: Added comments for the debug commands.
+ * watch.tcl (build_win): Flash the OK button before invoking it.
+
+Wed Oct 28 16:19:57 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * srctextwin.tcl: Changed the _map cache to use
+ the variable Cname instead of the kludgy upvar alias.
+
+Mon Oct 26 21:08:54 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * srctextwin.tcl (motion): Show breakpoint balloons
+ even when not running.
+ (showBPBalloon): Check for null before displaying.
+
+Wed Oct 21 10:05:17 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * images/kod.gif: Added temporary kernel object display icon.
+
+Wed Oct 14 17:30:07 PDT 1998 Jim Ingham <jingham@cygnus.com>
+
+ * main.tcl (gdbtk_tcl_preloop): Fixed the code to set gdb_exe_name.
+ I seem to have dropped a variable...
+ * main.tcl (_open_file): Make the open file dialog truely
+ modal on windows.
+
+Wed Oct 14 14:29:17 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * target.tcl: Change default runlist for remote
+ targets to download.
+ (build_win): Add user-defined list of functions for
+ initial breakpoints.
+
+ * main.tcl (run_executable): Set user-defined initial
+ breakpoints.
+
+ * prefs.tcl (pref_set_defaults): Define new prefs
+ gdb/load/bp_at_func and gdb/load/bp_func. These are
+ user-defined initial breakpoints.
+
+Sat Oct 10 00:21:44 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * help/source.html: Add new images, add description of changes
+ to breakpoints and threads support. Fix typos.
+
+ * help/memory.html: Cleanup and add new information.
+
+ * help/breakpoint.html: Reformat.
+
+ * help/images: Add a bunch of new GIFs.
+
+1998-10-08 Keith Seitz <keiths@cygnus.com>
+
+ * main.tcl (run_executable): Do not call set_exe here, either.
+ (_open_file): Add some comments about using set_exe
+ here instead of in download_it and run_executable. Do not look
+ for main, either, since the file hooks will take care of that.
+
+ * interface.tcl (gdbtk_tcl_pre_add_symbol): Do not reset the
+ source windows here -- only show the user what is going on.
+ (gdbtk_tcl_post_add_symbol): Force the source windows' file
+ comboboxes to refill, since adding a symbol file may actually
+ expand the debugger's view of the world.
+ (gdbtk_tcl_file_changed): New hook proc. Called by file_changed_hook
+ in symfile.c, this hook will cause the source window to point
+ to main/entry. gdbtk_tcl_exec_file_display actually sets up
+ gdbtk for this.
+ (gdbtk_tcl_exec_file_display): Renamed from
+ gdbtk_tcl_exec_file_changed for clarity. This hook is called
+ from exec_file_display_hook in exec_file_command. This function
+ sets up gdbtk to use a new executable, including resetting the
+ debugger's state and source window(s). See comments in this file
+ for more information.
+
+ * download.tcl (download_it): Don't call set_exe here and
+ do not touch state variables gdb_target_changed -- run_executable
+ will do it. (In short, make download_it one step closer to only
+ doing the download!)
+
+1998-10-08 Keith Seitz <keiths@cygnus.com>
+
+ * variables.tcl (UnEdit): Fix quoting problems so that arrays may be
+ inspected/edited.
+ (edit): Ditto.
+
+Wed Oct 7 16:03:00 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * srctextwin.tcl (reconfig): Fix bindings.
+
+Wed Oct 7 13:07:00 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * manage.tcl (manage_create): Bind ALL source windows
+ Map and Unmap events.
+ (manage_delete): Small optimization.
+ (manage_iconify): When the last source window is iconified,
+ iconify all the support windows too. When any source
+ window is deiconified, deiconify everything.
+
+ * src.tcl (destructor): Destroy SrcTextWin too.
+
+Tue Oct 6 23:00:08 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * src.tcl (set_status): Display only the first line of
+ the message.
+ (build_win): Configure status window to a height of 1.
+
+ * srcbar.tcl (create_menu_items): Change "Open..."
+ menu item to call _open_file proc. Remove old
+ _open_file method.
+
+ * main.tcl (run_executable): If the run command fails
+ with a result of "No executable" then call _open_file.
+ (_open_file): New proc. Opens a file requester and
+ sets the executable name to the selected file.
+
+ * toolbar.tcl (create_menu_items): Add "..." to Source
+ and Global prefs menu item.
+
+Mon Oct 5 21:10:30 1998 Jim Ingham <jingham@cygnus.com>
+
+ * srctextwin.tcl (set_tracepoint): The filename variable
+ changed to current(filename) but this use was not updated.
+
+ * global_prefs: Added a global preference to turn on the
+ tracing. It only sets the tracing preference, and does
+ not cause gdb to relayout the toolbar yet...
+
+ * util.tcl: Fixed the comments for the little debug
+ thingie.
+
+ * util.tcl (auto_step): Added a way to cancel the
+ auto_stepping. This is not currently used, but with this
+ it could be...
+
+Mon Oct 5 00:43:11 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * srctextwin.tcl (SrcTextWin): Create a threaded image
+ with a color of [pref get gdb/src/thread_fg].
+ (bind_src_tags): Bind bp_tag <Motion> and <Leave> for
+ balloon help on breakpoints.
+ (config_win): A bunch of binding changes to support
+ balloon help breakpoints and setting multiple BPs
+ on a line. Add menu item for thread specific BPs.
+ (reconfig): Similar changes as above.
+ (register_balloon): Remove.
+ (updateBalloon): Cleanup and don't call register_balloon.
+ (do_bp): When a BP is deleted, call gdb_find_bp_at_line()
+ to see if there are any more BPs at the same line number.
+ Add "thread" BP type.
+ (bp_line): Accept an optional list of thread numbers to
+ set BPs on. Loop through the list setting BPs on each thread.
+ (motion): Accept a window and type argument. Call
+ showBPBalloon in type is not "var".
+ (showBPBalloon): New method.Opens a balloon with breakpoint
+ info in it.
+ (showballoon): Accept window parameter.
+ (ask_thread_bp): New. A thread selector dialog. Opens
+ a scrolled listbox with a list of threads and allows
+ the user to multiselect threads to set BPs on.
+ (do_thread_bp): New callback from ask_thread_bp()
+ listbox.
+
+ * src_pref.tcl: Replace disabled color selector with thread
+ fg selector. Disabled color should probably always be
+ black anyways.
+
+ * util.tcl (CygScrolledListbox): Temporary simple scrolled
+ listbox. Replace with a better one soon.
+
+ * prefs.tcl (pref_set_defaults): Set default for thread fg.
+
+ * bp.tcl (bp_add): For thread BPs, set the button color
+ correctly.
+
+ * tclIndex: Rebuilt.
+
+Fri Oct 2 17:07:32 1998 Jim Ingham <jingham@cygnus.com>
+
+ * util.tcl (debug namespace): Added helper functions
+ "trace_var", "remove_trace" & "remove_all_traces" which
+ watch a variable, and dump the stack, and its value when
+ it is touched... They are in the "debug" namespace.
+ *tclIndex: regenerate index.
+
+Fri Oct 2 14:02:25 1998 Jim Ingham <jingham@cygnus.com>
+
+ * main.tcl (gdbtk_tcl_preloop): Catch the error when no file
+ is given on the command line.
+
+1998-10-02 Keith Seitz <keiths@cygnus.com>
+
+ * srcbar.tcl (_open_file): Call SrcWin::point_to_main.
+ (_set_runstop): Catch the stop in case the user
+ aborts a session.
+
+ * srctextwin.tcl (destructor): New. Remove all previously added
+ hooks.
+
+ * src.tcl (point_to_main): New function. I got tired of typing
+ the same five lines over and over again.
+
+ * main.tcl (set_baud): Target baud preferences are stored as
+ [target name]-baud, not [target name]/baud.
+ (run_executable): Call SrcWin::point_to_main.
+ (gdbtk_tcl_preloop): Call SrcWin::point_to_main.
+
+ * interface.tcl (gdbtk_tcl_pre_add_symbol): Use "update idletasks", not
+ just "update".
+ (gdbtk_tcl_post_add_symbol): Rewrite to have better behavior
+ for symbol files which have been loaded. Use a small hack to work
+ with gdbtk_tcl_exec_file_changed so that we look for main only
+ when a new executable is loaded.
+ (gdbtk_tcl_exec_file_changed): New proc to do some necessary
+ setup when an exec file changes.
+
+ * tclIndex: Regenerate.
+
+Fri Oct 2 11:40:05 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * Makefile (TCL): Add modal.tcl.
+
+ * tclIndex: Rebuilt.
+
+1998-10-02 Keith Seitz <keiths@cygnus.com>
+
+ * srcbar.tcl (_set_runstop): Catch the stop in case the user
+ aborts a session.
+
+Thu Oct 1 18:58:11 1998 Jim Ingham <jingham@cygnus.com>
+
+ * main.tcl (gdbtk_tcl_preloop): We were using lindex on the
+ return value from info files, but if the directory had a space
+ in it, then the result was not a proper Tcl list, and so the
+ command would fail. Use regexp instead...
+
+Thu Oct 1 17:21:26 1998 Jim Ingham <jingham@cygnus.com>
+
+ * download.tcl (download_it): One more place where we used
+ "Foundry_Debugger" unconditionally... Stamped out.
+
+ * main.tcl (set_target): Don't put the "Trying to
+ communicate..." message in the window title, put it in the
+ status area, and remember to remove it when you are done.
+
+Wed Sep 30 21:32:39 1998 Jim Ingham <jingham@cygnus.com>
+
+ * srctextwin.tcl (insertBreakTag): There was a bug in the
+ method of inserting break tags. If a tag of the intended
+ type did not already exist, insertBreakTag would not set it.
+ This method is a little less flexible, but actually works
+ for all our uses.
+
+Wed Sep 30 19:42:43 1998 Jim Ingham <jingham@cygnus.com>
+
+ * src.tcl (set_execution_status): When the program has
+ terminated, most stubs detach. Then we need to set
+ gdb_target_changed here so gdb will know to reattack when
+ you press the Run button.
+
+ * memory.tcl (update_address): We caught the gdb_eval when you
+ give an address expression, but then only trapped the case
+ where you gave an invalid address or non-existant symbol.
+ Trap all the other errors as well...
+
+Wed Sep 30 16:55:53 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * bp.tcl: Add optional "thread" column and menu items
+ to turn it on and off.
+
+ * prefs.tcl (pref_set_defaults): Add gdb/bp/show_threads
+ preference used for toggling the display of the thread
+ column in the BP window. Default is 0 (off).
+
+1998-09-28 Keith Seitz <keiths@cygnus.com>
+
+ * download.tcl (download_it): Don't download if there is no executable...
+
+Mon Sep 28 14:23:39 1998 Jim Ingham <jingham@cygnus.com>
+
+ * modal.tcl: NEW FILE. Had to fix a bug in the dialogs
+ so I made a sub-class: ModalDialog. The bug was that
+ manage.tcl sets the WM_DELETE_WINDOW handler to be
+ "manage delete" of the window, which is wrong for these
+ windows, they need to unpost themselves first. Override
+ this in the post method.
+ * mem_pref.tcl: Subclass & remove the code that went into
+ the ModalDialog class.
+ * target.tcl: ditto.
+ * tclIndex: regenerate for the new class.
+
+Fri Sep 25 19:01:32 1998 Jim Ingham <jingham@cygnus.com>
+
+ * utils.tcl (freeze): Hacked the freeze method so that it comes closer
+ to working on Windows, but it still flashes. Use a post
+ method, like that im mem_prefs.tcl or target.tcl instead.
+ * mem_pref.tcl (post): Added post method, so you can use the
+ Windows EnableWindow call without sending your app into the
+ background when the dialog is dismissed.
+ * target.tcl (post): Added the same method to this class.
+ Really should subclass these. Will do this when we rework the
+ class hierarchy for Itcl3.0.
+ * memory.tcl (create_prefs): Use the new post method.
+ * main.tcl (set_target_name): Use the post method rather than
+ freeze.
+
+1998-09-25 Keith Seitz <keiths@cygnus.com>
+ * main.tcl (set_baud): Baud rates are saved in gdb/load/target-baud,
+ not gdb/load/target/baud.
+ (set_target): Attempt to silently detach before attaching.
+
+ * target.tcl: Add gdb_target entries for Angel and ARM Remote
+ protocols.
+
+1998-09-18 Keith Seitz <keiths@cygnus.com>
+
+ * interface.tcl (gdbtk_tcl_post_add_symbol): Force the source window
+ to 'main'; if that fails, let gdb guess based on stop_pc.
+
+1998-09-04 Keith Seitz <keiths@cygnus.com>
+
+ * srctextwin.tcl (SrcTextWin::destructor): Define and remove
+ previously installed hooks.
+
+ * browser.tcl (get_selection): Listbox indices start at zero!
+ Clear the selection if the user clicks below the last visible
+ item in the listbox.
+
+Thu Sep 3 16:43:43 1998 Jim Ingham <jingham@leda.cygnus.com>
+
+ * mem_prefs.tcl: Fixed the size & format radiogroups in
+ the memory preferences so that they match the format
+ options being sent to it by the memory window. Also
+ greyed out the format box when float or double is selected.
+ Also made sure we didn't re-enable any disabled widgets in
+ the idle function.
+
+Sun Aug 30 00:40:28 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * process.tcl: New file. Implement a process/thread selection
+ and display window.
+
+ * srctextwin.tcl (do_key): Add entry for thread/process
+ window.
+ (config_win): Bind "Thread List" to Control-H.
+ (FillSource): Fix bug when source is not found.
+
+ * toolbar.tcl (create_menu_items): Add Thread List to menu
+
+ * manage.tcl (manage_init): Add process window to
+ managed array.
+
+ * prefs.tcl (pref_save): Add "process" to window types to save.
+
+ * Makefile: Add process.tcl
+
+ * tclIndex: Rebuilt
+
+1998-08-28 Keith Seitz <keiths@cygnus.com>
+
+ * variables.tcl (edit): Format data so that C arrays are not
+ mistaken for tcl commands.
+ (UnEdit): Ditto.
+
+Thu Aug 27 14:13:09 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * main.tcl (run_executable): If the target is "sim"
+ then the pref "sim-opts" should be treated as target
+ options instead of command line arguments.
+
+Wed Aug 26 00:06:11 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * src.tcl (mode): Set the mode widget using entryset.
+ (build_win): Use default combobox selectbackground.
+
+ * srctextwin.tcl (FillMixed): Better error handling.
+ (LoadFIle): Stop harrassing users with worthless dialog boxes.
+
+ * main.tcl (run_executable): Set args when arguments are
+ given in the target dialog.
+
+ * helpViewer.tcl (insertHtml): Window may have been
+ closed while waiting for HTMLparse, so catch next commands
+ to prevent error message.
+
+ * images/stack.gif: Use the image from images2 because
+ it looks better.
+
+Tue Aug 25 16:09:02 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * src.tcl (build_win): Change fonts on comboboxes to src-font.
+
+ * global_pref.tcl: Change to new combobox.
+
+Tue Aug 25 11:41:43 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * srctextwin.tcl (insertBreakTag): Take an index
+ instead of a linenumber. Check for bp_tag and break_tag.
+ (display_breaks): Reset all lines back to break_tag
+ after deleting bp image. Fixes caching bug.
+ (do_bp): Fix up calls to insertBreakTag.
+
+Fri Aug 21 12:44:25 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * target.tcl (build_win): Remove tix stuff. Set maxheight
+ of comboboxes to 10. Remove all code to count elements
+ in comboboxes because the new one does it for us.
+ (fill_rates): Remove combobox height configure code.
+ (fill_targets): Same.
+
+ * src.tcl (build_win): Change combobox -height to
+ -maxheight for combobox 1.05.
+ (name, goto_func): Use combobox entryset instead of SetSilent.
+ (SetSilent): Deleted.
+
+ * srctextwin.tcl (FillSource): Fix change mode call when
+ no source is found.
+
+1998-08-20 Keith Seitz <keiths@cygnus.com>
+
+ * srctextwin.tcl (print): New method. Moved from src.tcl.
+
+ * srcbar.tcl (create_menu_items): Add page setup for non-ide again..
+
+ * src.tcl (build_win): Fix balloon help for new comboboxes.
+ (print): Move guts to srctextwin and invoke that method.
+
+ * target.tcl: Remove protected variable tcpmode.
+ Add "options" member for sim and exec targets. For sim, this is
+ options to pass to the simulator; for exec, command line arguments.
+ (build_win): Replace tix comboboxes with one from libgui.
+ (set_saved): Add target-options when appropriate.
+ (write_saved): Add target-options when appropriate.
+ (fill_rates): Modify to work with new combobox.
+ (fill_targets): Modify to work with new combobox.
+ (config_dialog): New method which maps/unmaps/relabels comboboxes
+ and entries for each target.
+ (change_target): Remove all code pertaining to mapping/unmapping/relabeling
+ comboboxes and entries and call config_dialog instead.
+ (change_baud): Remove all code pertaining to mapping/unmapping/relabeling
+ comboboxes and entries and call config_dialog instead.
+
+ * console.tcl (Console): Add key binding for TAB completion.
+ (find_lcp): New helper method for find_completion.
+ (find_completion): New helper method for complete.
+ (complete): New method (bound to tab key) which computes the completion
+ of the current command line.
+ (reset_tab): New method to reset the tab completion whenever a key
+ is pressed (forces complete to recompute the completions instead of
+ printing out the last list of completions).
+
+1998-08-18 Keith Seitz <keiths@cygnus.com>
+
+ * stack.tcl (update): Use new built-in command gdb_stack for
+ backtraces.
+ Use the global gdb_selected_frame_level to figure out which
+ line in the listbox should be highlighted.
+ ALWAYS highlight the selected frame.
+ Put a fencepost arount update so that we can prevent it from
+ being called twice when change_frame is used.
+ (change_frame): Protect call to gdbtk_update so that this object is
+ not updated twice.
+
+ * srctextwin.tcl (config_win): Copy the properties of the selection tag
+ into a new "search" tag that will be used by the search widget.
+ (search): Use the defined "search" tag to highlight found text.
+ Remove all search-tagged text from the window when an empty expression
+ is entered.
+
+Mon Aug 17 14:27:54 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * main.tcl (do_tstop): Require combobox package.
+
+ * src.tcl (build_win): Use new combobox.
+ (name): Changes for new combobox.
+ (goto_func): Changes for new combobox.
+ (FillNameCB): Changes for new combobox.
+ (FillFuncCB): Changes for new combobox.
+ (SetSilent): New method, like tixSetSilent.
+ (mode): Changes for new combobox.
+ (set_name): Changes for new combobox.
+ (reset): Changes for new combobox.
+
+ * srctextwin.tcl (FillSource): Call parent's mode method when
+ mode is changed to assembly.
+ (location): Call display_breaks only if flag is set.
+ (LoadFIle, FillAssembly, FillMixed): Set display_breaks flag.
+ (display_breaks): Set all breakpoints in a single pass.
+ (insertBreakTag): Check $stop before trying to remove tag.
+
+Mon Jul 27 12:35:31 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * interface.tcl (gdbtk_tcl_tracepoint): Make function match C
+ implementation by adding pass_count.
+
+Sat Jul 25 22:40:49 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * manage.tcl (manage_init): Change "loadpref" to "targetsel"
+ and change class name to TargetSelection. This avoids confusion
+ with the IDE GdbLoadPref class.
+ * target.tcl (TargetSelection): Change class name.
+ * main.tcl (set_target_name): Change "loadpref" to" targetsel"
+
+Fri Jul 24 14:37:49 1998 Keith Seitz <keiths@cygnus.com>
+
+ * util.tcl (bp_exists): New procedure.
+ * srctextwin.tcl (SrcTextWin::constructor): Add public vars
+ "parent" and "ignore_var_balloons" and initialize accordingly.
+ (config_win): Add binding for browser.
+ Add binding for up/down arrows to scroll more naturally.
+ (do_key): Add browser entry.
+ * browser.tcl: Add srctextwin into browser.
+ * prefs.tcl (pref_set_defaults): Add new preferences for the func
+ browser.
+ * tclIndex: Regenerate.
+
+Fri Jul 24 00:53:28 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * srctextwin.tcl (SrcTextWin): Initialize LineNums.
+ (setTabs): Set tabs correctly when in assembly mode
+ or when there are no linenumbers.
+ (bind_src_tags): Remove lineNum_tag bindings.
+ (config_win): Remove lineNum_tag and line_tag. Set
+ linenumbers to break_tag and bp_tag instead.
+ (FillAssembly): Don't use lineNum_tag.
+ (FillMixed): Don't use line_tag.
+ (LoadFile): Use new protected variable LineNums.
+ (insertBreakTag): Instead of trying to calculate the
+ correct location of the new tag, simply ask the widget
+ where the old one was.
+ (do_bp): Call insertBreakTag when bps are deleted.
+
+ * src.tcl (FillNameCB): Call gdb_listfiles with [pwd].
+
+Sat Jul 18 13:27:20 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * src.tcl (location): Change BROWSE_TAG to STACK_TAG.
+
+ * interface.tcl (gdbtk_quit): New function. Called by
+ cleanup code in GDB.
+
+Fri Jul 17 00:03:43 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * memory.tcl (build_win): Change address controlbox to
+ call update_address_cb.
+ (update_address_cb): New method. Handle address
+ controlbox callbacks. Set flag and call update_address.
+ (update_address): Call BadExpr on bad expressions.
+ Use local variable "ae" to set public variable addr_exp.
+ This fixes bug where widget forgets its address when
+ reconfigured. Set table background white when expression
+ is OK.
+ (BadExpr): When a bad expression is entered, create a
+ messagebox and set the table bg to gray.
+
+ * mem_pref.tcl (apply): Remove mystery debug line.
+
+Thu Jul 16 16:56:12 1998 Jim Ingham <jingham@cygnus.com>
+
+ * download.tcl, ide.tcl, interface.tcl, main.tcl, manage.tcl
+ srcbar.tcl, toolbar.tcl: Merged the IDE changes back into devo.
+
+Mon Jul 13 14:34:45 1998 Jim Ingham <jingham@cygnus.com>
+
+ * mem_pref.tcl (destructor): Remember to delete the variable
+ trace that implements the entry widget checking.
+
+Fri Jul 10 19:17:53 1998 Jim Ingham <jingham@cygnus.com>
+
+ * mem_pref.tcl: Changed the number of bytes entry widget so
+ that it only accepts +'ve integers, and protect against the
+ case where the user deletes the contents of this entry, then
+ closes the window. Also made the entry disabled when the
+ other radio button is selected.
+
+Wed Jul 8 23:20:33 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * srctextwin.tcl (FillSource): Fix code that
+ detects when no line numbers are available and we must use
+ assembly mode.
+
+Mon Jul 6 17:53:50 1998 Jim Ingham <jingham@cygnus.com>
+
+ * download.tcl, helpViewer.tcl, html_library.tcl, memory.tcl,
+ register.tcl, src.tcl, srctextwin.tcl, target.tcl,
+ tracedlg.tcl, util.tcl, variables.tcl, warning.tcl, watch.tcl:
+ With the Tcl 8.0 compiler, expr commands are more efficient if
+ you use:
+ expr {$foo + $bar}
+ instead of:
+ expr $foo + $bar
+ So I changed all the uses of expr to this form.
+
+
+Mon Jul 6 15:19:59 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * srctextwin.tcl (FillSource): Call Parent's mode method
+ to combobox will be updated.
+ * src.tcl (mode): Pass along second argument to mode_set.
+
+Wed Jul 1 15:09:47 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * srctextwin.tcl (location): Add missing parameter
+ to FillSource call in SRC+ASM.
+
+Wed Jul 1 11:07:21 1998 Jim Ingham <jingham@cygnus.com>
+
+ * main.tcl (gdbtk_preloop): Call gdbtk_idle on spec. If there was an
+ error in loading an executible specified on the command line,
+ then the pre_add_symbol hook would have called gdbtk_busy but
+ the corresponding call to gdbtk_idle would not have occured.
+
+ Also changed some catch calls so they didn't use
+ "catch {set foo [real_command]}"
+ but rather the more efficient:
+ "catch {real_command} foo"
+
+ * register.tcl: more catch cleanups
+ * src.tcl: more catch cleanups
+ * stack.tcl: more catch cleanups
+ * target.tcl: more catch cleanups
+ * tdump.tcl: more catch cleanups
+ * variables.tcl: more catch cleanups
+ * watch.tcl: more catch cleanups
+
+Wed Jul 1 12:21:55 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * src.tcl (build_win): Remove incorrect runstop
+ argument for srcbar.
+
+Wed Jul 1 11:25:48 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * floatbar.tcl: Deleted.
+ * Makefile: Removed floatbar.tcl
+ * tclIndex: Rebuilt.
+
+Wed Jul 1 11:19:05 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * toolbar.tcl (enable_ui): Now takes an argument and
+ handles disable_ui and no_inferior functions.
+ (disable_ui): Deleted.
+ (no_inferior): Deleted.
+ (constructor): Set idle, busy, and no_inferior hooks
+ to enable_ui.
+
+ * srcbar.tcl (_open_file): Fix for multiple source windows.
+
+Wed Jul 1 01:40:52 1998 Martin M. Hunt <hunt@cygnus.com>
+ * Makefile: Added srctextwin.tcl.
+ * tclIndex: Rebuilt.
+ * src.tcl: Major rewrite to move the source text window
+ into another object implemented in srctextwin.tcl. Every function
+ changed and many moved to srctextwin.tcl.
+ * srctextwin.tcl: New file.
+ * bp.tcl (goto_bp): Fix call to source widget.
+
+ * src_pref.tcl (build_win): Add line number
+ checkbutton. Layout needs changed.
+ * prefs.tcl (pref_set_defaults): Add linenum pref.
+
+Thu Jun 25 17:31:30 1998 Keith Seitz <keiths@cygnus.com>
+
+ * toolbar.tcl (create_menu_items): Add Function Browser menu item.
+
+ * tclIndex: Regenerate.
+
+ * Makefile: Add browser.tcl.
+
+ * util.tcl (do_test): New procedure for invoking a test in the
+ testsuite from the command line.
+ (gdbtk_read_defs): New procedure for reading in the testsuite definitions
+ file
+
+ * src.tcl (build_win): Create new entry for searching the source window.
+ This "feature" shares the screen with the download indicator.
+ (download_progress): If starting a download, unmap the search widget
+ and map the download progress indicator in its place. When downloading
+ is done, do the opposite.
+ (config_win): Bind the down and up arrow keys to directly scroll the
+ window.
+ (search): New method which searches for strings in the source window
+ and jumps to a particular line.
+ (set_state): Do not reset current_file to empty when an exe has been
+ downloaded.
+ (bp): Do not special case tracepoint debugging.
+
+ * manage.tcl (manage_init): Add elements for function browser.
+ (manage_create): If GDBTK_TEST_RUNNING is set in the environment,
+ place all windows on the screen at +0+0.
+
+ * prefs.tcl (pref_save): Add new preference category "search".
+ (pref_set_defaults): Add search preferences.
+
+ * tracedlg.tcl (TraceDlg::destructor): Destroy the actions dialog is
+ it exists.
+ (add_action): Save the object returned from the window manager when
+ the actions dialog is opened so that we can later destroy it if
+ necessary.
+ (done): Clear ActionsDlg when the actions dialog is destroyed.
+
+ * main.tcl (do_tstart): Do not disable the "Begin collection" menu
+ item when we issue a tstart.
+
+ * console.tcl (paste): New method which handles all Paste events for
+ this window.
+ (Console): Bind the middle mouse button on unix to generate a paste
+ event.
+ Override default binding for button-2 motion to allow easier pasting
+ into the window.
+ Bind the paste event to the method paste.
+
+Wed Jun 17 13:50:48 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * src.tcl (reconfig): Recognize tab size changes.
+
+ * src_pref.tcl (build_win): Add tab control. Remove extra frame.
+ Justify variable ballons text. Set activebackgrounds on
+ color buttons.
+
+Tue Jun 9 13:57:24 1998 Keith Seitz <keiths@cygnus.com>
+
+ * helpViewer.tcl (HtmlViewer): Display appropriate help based on the
+ preference gdb/mode.
+
+ * help/trace: Add help files for tracing.
+
+ * main.tcl (gdbtk_tcl_preloop): Call gdbtk_update so that the
+ source window fills files into the combobox.
+
+ * srcbar.tcl (_open_file): "cd" to directory, don't add it to the
+ search list. This never gets reset anywhere, so if multiple file
+ commands are added, we could get the wrong path. Call gdb_clear_file,
+ too.
+
+ * interface.tcl (gdbtk_tcl_pre_add_symbol): Call the reset method
+ of the source window, too.
+
+ * src.tcl (reset): New method used to clear the source window
+ whenever multiple file commands are used.
+
+ * tdump.tcl (update): Erase the contents of the tdump window
+ when displaying a new dump.
+
+ * stack.tcl (update): Errors from the backtrace can contain
+ backtrace info, too, so make sure we print as much of that as
+ possible.
+
+ * register.tcl (build_win): Do not allow editing in tracing
+ mode.
+ (reg_select): Do not allow editing in tracing mode.
+
+ * memory.tcl (update_address): Check that gdb's handling of chars and
+ char*s doesn't abort the update.
+
+ * variables.tcl (build_win): Disable editing in tracing mode.
+ (build_menu_helper): Disable editing in tracing mode.
+ (getLocals): Use the builtin functions gdb_get_locals and
+ gdb_get_args to get all local variables. Concat lists together.
+ (Variable::value): Set a default value for "radix" in case
+ the regsub fails.
+
+Tue Jun 9 00:00:18 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * interface.tcl (gdbtk_quit): No longer use quit_hook.
+ Just call "manage save".
+ * manage.tcl (manage): Remove manage quit.
+ (manage_quit): Deleted.
+ (manage_init): Remove quit_hook.
+ (manage_save): Use "Pref setd" instead of "pref set".
+ * prefs.tcl (pref_set_defaults): Remove quit_hook.
+ (pref_quit): Deleted.
+
+Mon Jun 8 16:15:33 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * target.tcl (set_check_button): Check for existence of
+ button before trying to set its state.
+
+Mon Jun 8 13:31:08 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * memory.tcl (build_win): Always Bind configure event to
+ newsize method. Change table widget to use incr_addr for
+ both incr and decr. Enable autorepeat.
+ (create_prefs): Set rheight (row height).
+ (newsize): Set rheight if necessary. Return if numbytes
+ is not zero.
+ (update_address): Move gdbtk_idle and gdbtk_busy calls to
+ update_addr.
+ (update_addr): Surround with gdbtk_idle and gdbtk_busy.
+ (incr_addr): Take an argument to indicate how much
+ to increment or decrement by.
+ (decr_addr): Deleted.
+
+Fri Jun 5 00:13:49 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * Change all references to GDBTK_IDE to IDE_ENABLED.
+
+Thu Jun 4 18:34:11 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * memory.tcl: Complete rewrite. Added many new features
+ and made it much faster.
+
+ * mem_pref.tcl (build_win): Set listbox width.
+
+ * images/check.gif: New image. Used in version of
+ memory window without a menubar.
+
+Thu Jun 4 10:53:33 1998 Elena Zannoni <ezannoni@kwikemart.cygnus.com>
+
+ * tclIndex: regenerated.
+
+ Merged (most recent first):
+
+ - Elena Zannoni <ezannoni@kwikemart.cygnus.com>
+
+ * tracedlg.tcl (ok): if the tracepoint does not exist (this can happen
+ if user is editing a tp and decides to remove it from tp window)
+ do not core dump, give an error message instead, and return.
+
+ * bp.tcl (get_actions): invoke trace dialog from tracepoint window,
+ passing filename and line as arguments, rather than address.
+
+ - Jeff Holcomb <jeffh@cygnus.com>
+
+ * main.tcl (set_baud): Change gdb/load/$gdb_target_name/baud
+ to gdb/load/${gdb_target_name}-baud.
+
+ - Elena Zannoni <ezannoni@kwikemart.cygnus.com>
+
+ * tdump.tcl (update): call tdump only if the current trace frame
+ number is not -1.
+
+ * interface.tcl (gdbtk_tcl_tstart): update menus entries only, do
+ not do actual command.
+ (gdbtk_tcl_tstopt): update menus entries only, do not do actual
+ command.
+ (gdbtk_tcl_warning): remove tdump warning message from list of not
+ displayed messages.
+
+ * main.tcl (do_tstart): catch error output from tstart and display
+ error dialog.
+ (do_tstop): catch error output from tstop and display error dialog.
+
+ * bp.tcl (bp_add): align properly the bpnum and passcount fields,
+ for the tracepoint window.
+
+ * main.tcl (set_exe): set file_done (new global state variable)
+ depending whether new file was read in or not.
+ (set_target_name): return 0 if user chose cancel from target setting
+ window displayed by 'connect'.
+ (set_target): if no target_cmd is specified call set_target_name and
+ ask user for it.
+ (async_connect): handle possible outcomes of set_target command,
+ issue appropriate messages to user.
+ Initialize file_done to 0.
+
+ * target.tcl (cancel): set gdb_target_name to CANCEL for use by
+ set_target_name.
+ Added public data 'exportcancel'.
+
+ * toolbar.tcl (do_async_connect): change menu items state only
+ if connect was successful.
+
+ * src.tcl (bp): modify condition for SOURCE case to display tp dot
+ after connecting to target.
+
+ * actiondlg.tcl (constructor): make dialog non modal.
+ (destructor): release grab not any longer necessary.
+ (change): make lsearch use exact pattern matching for entries
+ added to the collect list using the 'other' field. The new syntax
+ allows array elements to be specified and this messes up the
+ default glob style pattern matching.
+ (change_other): reject memranges (obsolete). Delegate validation
+ of user input to the lower levels, in gdb. I.e. keep everything
+ until the whole tracepoint is installed.
+
+ * tracedlg.tcl (gdb_add_tracepoint): call to gdb_actions is now
+ catching the errors (in case of incorrect syntax) and displaying
+ them to the user.
+
+ * main.tcl (set_target): Changed text of error message to mention
+ the Target Settings dialog.
+
+ * prefs.tcl: Set default preference for gdb/load/check to 0.
+
+ * target.tcl (build_win): disable comparison with executable for
+ 'exec' targets.
+ (set_check_button): new method. Enable/disable the check button
+ for comparing executable.
+ (change_target): call set_chack_button when target changes.
+ Set default preference gdb/load/check to 0.
+
+ * stack.tcl: set initial window width value to 40, so that window
+ looks better if opened before a stack exists.
+
+ - David Taylor <taylor@texas.cygnus.com>
+
+ * main.tcl (async_connect): remote-compare is now compare-sections.
+
+ - Elena Zannoni <ezannoni@kwikemart.cygnus.com>
+
+ * warning.tcl (constructor): call destructor if dialog doesn't
+ need to be displayed.
+
+ * console.tcl (invoke): make function get input and return if in
+ readline state, independently from the value of Running.
+
+ * src.tcl (set_state): set state of pop up menus only for synch
+ mode.
+
+ * tdump.tcl (build_win): simplify the window, eliminating pane.
+ This fixes resize problems.
+ (update): add call to see to display last thing outputted to the
+ window.
+
+ * tfind_args.tcl (do_it): call the tfind_cmd procedure.
+
+ * toolbar.tcl (create_menu_items): changed calls to tstart and tstop
+ to use do_tstart and do_tstop.
+
+ * srcbar.tcl (runstop): do not call _set_trace in asynch case,
+ just use _set_runstop always.
+ (_set_runstop): added handling for asynch mode cases.
+ (_set_trace): removed.
+
+ * main.tcl (do_tstart): new procedure to execute tstart command
+ update tstart/tstop button, and menu entries accordingly.
+ (do_tstop): new procedure for tstop, as above.
+ (run_executable): calls do_tstart in the asynch case.
+
+ * interface.tcl (gdbtk_tcl_tstart): new procedure to invoke
+ the tstart command
+ (gdbtk_tcl_tstop): new procedure to invoke the tstop command
+
+ * interface.tcl: (gdbtk_tcl_warning) do not display warning
+ about no current trace frame upon opening of tdump window.
+
+ * main.tcl: (run_executable) in asynch mode just call tstart,
+ connect is now done independently.
+ (async_connect) new procedure to connect and do comarison with
+ remote executable, in asynch mode. Sets up gui state globals.
+ (async_disconnect) new procedure to disconnect from target in
+ asynch mode. Sets up gui state globals.
+
+ * prefs.tcl: added new preference gdb/load/check
+
+ * srcbar.tcl: (create_buttons) tfind commands now use tfind_cmd
+ function
+
+ * target.tcl: added new preference gdb/load/check to execute an
+ automatic remote-compare command on connection to target in asynch
+ mode
+ (set_saved) set saved value for new preference
+ (write saved) write saved value for new preference
+ (build_win) set state of 'run to main', 'break at exit', 'display
+ dowload' to disabled for asynch mode target dialog.
+ Added new checkbutton for automatic comparison of remote exec.
+ Saved_check: new protected member
+
+ * tdump.tcl: (update) changed check for no frame, since 0 is legal
+ trace frame number.
+
+ * toolbar.tcl: (create_menu_items): added menus items 'connect to
+ target' and 'disconnect', in async mode. Changed to call tfind_cmd
+ to execute tfind commands
+ (do_async_connect): new method to connect to target in async mode.
+ (do_asynch_disconnect): new method to disconnect from target in
+ async mode.
+
+ * util.tcl: (tfind_cmd): new proc to execute a tfind command on
+ the target
+
+Thu May 28 12:49:29 1998 Keith Seitz <keiths@cygnus.com>
+
+ * target.tcl: Add sparclite target.
+ (fill_targets): Add sparclite target.
+
+ * main.tcl (set_target_name): Rearrange so that the default behavior
+ is to assume a remote-like target.
+
+ * src.tcl (browse_to): Helper function for BpWin::goto_bp which causes
+ the source window to show the specified location.
+
+ * bp.tcl (bp_add): Clean up repetitive code.
+ Add double-click binding which shows the breakpoint
+ in the source window.
+ (bp_select): Clean up repetitive code.
+ (goto_bp): New function.
+
+Sun May 24 14:05:27 1998 Keith Seitz <keiths@cygnus.com>
+
+ * src.tcl (reconfig): Remove the variable balloon selection in the text
+ widget, too, when we are disabling varialbe balloons.
+
+ * target.tcl: Add a "runlist" parameter to all gdb_target entries. This list
+ controls the default behavior of the run button.
+ (GdbLoadPref): Define the run preferences based on this target.
+ (build_win): Add a "more options" dropdown pane to allow users to modify the
+ behavior of the run button.
+ (set_saved): Add run button preferences.
+ (write_saved): Add run button preferences.
+ (fill_targets): Add the "pretty name" to the combo box, not gdb's internal
+ target name.
+ (change_target): Use get_target to translate the "pretty-name" to the
+ real target name.
+ (save): Write out saved values, too.
+ (get_target): New method to translate the "pretty-name" of a target into gdb's
+ internal name/
+ (toggle_more_options): New method to handle mapping and unmapping of the
+ "more options" pane.
+ (set_run): New method. Moved from src_pref.tcl.
+ (valid_target): Moved here from main.tcl.
+ (native_debugging): Moved here from main.tcl.
+ (change_target): Don't write_saved here -- wait until dialog is closed.
+
+ * src_pref.tcl (build_win): Use libgui's Labelledframe class instead of the
+ Tix labeled frame.
+ Remove the run button frame -- this has moved into the target selection dialog.
+ (set_run): Moved to targets.tcl.
+
+ * prefs.tcl (pref_set_defaults): Change default preferences for the run
+ button to only do a run. Target selection will reset these as appropriate.
+
+ * main.tcl (set_baud): Baud preferences are in TARGET-baud, not
+ TARGET/baud.
+ (run_executable): Remove special cases for exec targets.
+ (native_debugging,valid_target): Move to target.tcl.
+
+ * images/more.gif, images/less.gif: New images for drop frames.
+
+ * tclIndex: Regenerate.
+
+Wed May 20 13:43:00 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * toolbar.tcl (create_menu_items): Remove register prefs.
+
+ * images/stop.gif: Set transparent bit.
+
+Tue May 19 12:34:11 1998 Keith Seitz <keiths@cygnus.com>
+
+ * bp.tcl (bp_add): Use source window's colors. Use "file tail" not
+ "lindex [file split ] end".
+ (bp_modify): Use source window's colors. Use "file tail" not
+ "lindex [file split ] end".
+ (bp_remove): Call bp_select before we delete the breakpoint.
+
+ * main.tcl (run_executable): Encapsulate all calls to debugger
+ based on new run preferences.
+
+ * manage.tcl (manage_init): Change loadpref titles to "Target Selection"
+
+ * pref.tcl (build_win): Disable Help button until it works.
+
+ * prefs.tcl (pref_set_defaults): Define new run button preferences.
+ Lose stack and bp window color preferences -- use the source window
+ ones instead. Lose left_click, too.
+
+ * src.tcl: Remove all references to _Source_Left_Click and replace with new
+ protected variable Tracing. Define new protected variable UseVariableBalloons
+ so that we don't follow the preferences blindly. Replace all preference calls
+ for these two globals.
+ (reconfig): Allow reconfiguration of variable balloons and popup menu colors.
+ (config_win): Add binding for File Menu->Open.
+ (do_key): Add open key.
+
+ * src_pref.tcl (SrcPref): Save all newly added preferences.
+ (build_win): Add new preferences for mode, variable balloons,
+ lots of color choices.
+ (cancel): Reset all new preferences.
+ (pick): Allow passing of button in to make things a little easier.
+ (reconfig): Keep empty -- no need for this to reconfigure itself.
+ (set_run): New method to make sure someone does not try to run _and_
+ continue a target with the run button.
+
+ * stack.tcl (build_win): Use the source window's preferences to set colors.
+
+ * target.tcl (build_win): Disable Help button until it works.
+
+Mon May 18 15:25:00 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * html_library.tcl (HMstack): Remove stray 'g' that was
+ preventing autoloading.
+
+Mon May 18 13:17:30 1998 Keith Seitz <keiths@cygnus.com>
+
+ * helpViewer.tcl (HtmlViewer): Initialize glossary.
+ (glossaryPost): Fill in skeleton supplied by jingham.
+ (glossaryUnpost): Ditto.
+ (lookup): New method to lookup glossary definitions.
+ (HMset_image): Add special image names.
+
+Fri May 15 00:30:06 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * memory.tcl (update_address): Source window was never being
+ updated due to a faulty fencepost. I removed it. Was it
+ useful?
+
+Tue May 12 11:47:11 PDT 1998 James Ingham <jingham@leda.cygnus.com>
+
+ * helpViewer.tcl: Made the fonts for the viewer track the global
+ font preferences
+ *html_library.tcl: Use Tcl Font objects for the fonts rather than
+ building up X Font Specs.
+
+
+Thu May 7 16:03:32 1998 Keith Seitz <keiths@cygnus.com>
+
+ * toolbar.tcl (create_menu_items): Remove automatic stepping.
+ (create_menu_items): "Cygnus on the Web..." should point to GNUPro page...
+
+Wed May 6 20:18:34 1998 Keith Seitz <keiths@cygnus.com>
+
+ * main.tcl (set_target_name): Recognize d10v and m32r targets.
+ (valid_target): Change test to recognize all tcp targets.
+
+ * target.tcl: Add m32r and d10v tcp targets.
+
+Wed May 6 12:52:12 1998 Keith Seitz <keiths@cygnus.com>
+
+ * srcbar.tcl (create_menu_items): Install a page setup menu item for
+ non-ide debuggers.
+
+ * src.tcl (print): Don't call idewindow_freeze and idewindow_thaw
+ the ide is not running
+
+Wed May 6 10:41:30 1998 Elena Zannoni <ezannoni@kwikemart.cygnus.com>
+
+ * bp.tcl (get_actions): set bpnum to be the real tracepoint number,
+ not the selected row number.
+
+Tue May 5 04:07:12 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * target.tcl: Add D10V and M32R target.
+
+ * prefs.tcl (pref_set_defaults): Set debugging off
+ by default.
+
+Fri May 1 15:23:57 1998 Elena Zannoni <ezannoni@kwikemart.cygnus.com>
+
+ * main.tcl (valid_target) make 'remotetcp' a valid
+ target.
+
+Fri May 1 11:50:40 1998 Jim Ingham <jingham@leda.cygnus.com>
+
+ * helpViewer.tcl: Added the skeleton for the Glossary entries.
+ Fixed the zoom to top of page when rendering is complete nit.
+ Added a reconfig method to refresh the current page.
+ Compulsive reordering of methods.
+
+Thu Apr 30 00:04:52 1998 Martin M. Hunt <hunt@cygnus.com
+
+ * global_pref.tcl (change_icons): Remove debug line.
+
+ * toolbar.tcl: Change image names to end with _img
+ so they don't conflist with command names.
+ * srcbar.tcl: Same.
+
+Tue Apr 28 16:51:09 1998 Jim Ingham <jingham@leda.cygnus.com>
+
+ * html_library.tcl: The redefinition of tkFocusOK in this file
+ can cause an infinite recursion loop in autoloading tkFocusOK.
+ Change proc -> ::proc to hide the definition from itcl_mkindex
+ * tclIndex: remade without the reference to tkFocusOK.
+
+Tue Apr 28 16:51:09 1998 Jim Ingham <jingham@leda.cygnus.com>
+
+ * helpViewer.tcl: The index page now shows up properly in the
+ history list. Also added images for the fore, back and home
+ buttons, and removed the close button.
+
+ * manage.tcl: Moved the wm withdraw of a new toplevel before the
+ constructor is run in manage_create. This avoids flashing.
+
+ * main.tcl: Changed the tk application name of gdbtk from tk
+ to gdbtk.
+
+Mon Apr 27 14:18:01 1998 Elena Zannoni <ezannoni@kwikemart.cygnus.com>
+
+ * helpViewer.tcl: (constructor) Change 'Foreward' to 'Forward' and
+ calls to 'foreward' method to calls to 'foreward' method.
+ (forward) changed method name from 'foreward'.
+
+Thu Apr 23 19:02:25 1998 Keith Seitz <keiths@onions.cygnus.com>
+
+ * toolbar.tcl (create_menu_items): Use the new help viewer when not
+ using the IDE.
+
+ * helpViewer.tcl (HtmlViewer::constructor): Set default values for
+ previously passed-in variables.
+ (HtmlViewer::destructor): Destroy the toplevel, too.
+ (HMset_image): prepend the dir name "images" to the image path.
+
+Thu Apr 23 13:31:07 1998 Jim Ingham <jingham@leda.cygnus.com>
+
+ * html_library.tcl: First checkin
+ * helpViewer.tcl: First checkin
+ * manage.tcl (manage): Added the help veiwer to the windows
+ list. Aslo compulsively alphabetized the list...
+ * tclIndex Rebuilt for the new procs.
+
+Mon Apr 20 11:14:17 1998 Keith Seitz <keiths@onions.cygnus.com>
+
+ * global_pref.tcl (build_win): Add font selector for the status font.
+
+ * main.tcl (run_executable): Exec targets are always "loaded".
+
+Sat Apr 18 02:11:04 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * prefs.tcl (pref_read): Remove debug line.
+
+ * util.tcl (toggle_debug_mode): When enabling or
+ disabling debugging, also enable or disable error
+ reporting and stack traces.
+
+Sat Apr 18 01:13:03 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * srcbar.tcl (_toggle_updates): Cleanup.
+
+ * src.tcl (do_popup): Fix problems with selections. While
+ I'm messing with this code anyway, change how it works
+ so that the popup will contain the word that is under the cursor
+ if nothing is selected.
+
+ * toolbar.tcl (create_buttons): Bind button 3 to create
+ new windows when possible.
+
+ * stack.tcl (StackWin): Fix broken deiconify call.
+
+ * images/[console.gif, reg.gif]: Update.
+
+Fri Apr 17 10:34:23 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * src.tcl (location): Don't look up the full pathname
+ of each file added to the combobox.
+
+Fri Apr 17 09:58:59 1998 Keith Seitz <keiths@onions.cygnus.com>
+
+ * target.tcl (default_port): New proc. Returns a default port
+ based on host os.
+ (startup code): Use default port to determine the default port
+ to use for all hosts.
+ (build_win): Only set the target if it is valid.
+ For unix, use port names that correspond to the OS running.
+ Change gdb/load/$target-portnum to gdb/load/$target-port (typo?)
+ (get_target_list): Do not allow "exec" for cross debugging.
+ (save): Do not do dismiss dialog if the target is not valid.
+ (cancel): If exportcancel is set, set gdb_target_cmd to "CANCEL". This
+ will allow run_executable to cancel a run if the user cancels target
+ selection.
+ (exportcancel): New public data.
+
+ * main.tcl (set_target_name): Return status to caller so that the user
+ can cancel a run request when the target selection dialog is opened.
+ Do not modify gdb_exe_changed -- it has already been set proprely.
+ (set_target): If gdb_target_cmd is empty, call set_target_name to
+ set it.
+ Allow all set_target_name commands to cancel target selection.
+ (run_executable): Allow all set_target_name commands to cancel
+ target selection.
+ Always clear bp's at main and exit, since this proc will set them
+ for all targets now.
+ Save the bp number for the breakpoint installed at main and exit so
+ that we can reliably delete them if the user cancels any subsequent
+ target selection.
+ Whenever the run is canceled, delete the breakpoints at main and exit.
+ Move setting of breakpoints at main and exit from download_it here.
+ (valid_target): New proc. Returns true if the given target is a valid,
+ runnable target.
+ (native_debugging): New proc. Returns true if this gdb is not a cross
+ gdb.
+ (startup code): Do not call set_target_name here -- let run_executable
+ do it.
+
+ * interface.tcl (gdbtk_tcl_query): Update the display when this dialog
+ is dismissed.
+ (gdbtk_tcl_warning): Always show warnings in the debug window.
+
+ * download.tcl (download_it): Move setting breaks at main,exit to
+ run_executable in main.tcl.
+
+Thu Apr 16 11:28:01 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * main.tcl (set_target_name): Add "prompt" parameter
+ which allows this function to be called without it always
+ prompting for the target name. This allows it to quietly
+ initialize variables from preferences.
+ (set_target): Remove HACK_FIRST_HACK.
+ (run_executable): Check the result of [set_target].
+ If it fails, prompt for a new target and repeat.
+ (startup code): Remove HACK_FIRST_HACK.
+ Call set_target_name to initialize gdb_target_cmd from
+ preferences.
+
+ * toolbar.tcl (create_menu_items): Call set_target_name
+ for the target menu item. This will open the dialog and
+ then set the target command correctly.
+
+ * target.tcl (save): Set default target preference.
+
+Wed Apr 15 11:29:47 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * src.tcl (reconfig): Tell toolbar to reconfig.
+
+ * global_pref.tcl (build_win): Add support for changing
+ icons. Put fonts in a labelled frame.
+ (update_file): Removed.
+ (change_icons): Callback for icon combobox.
+
+ * srcbar.tcl (_load_src_images): Remove old target and
+ load images. Add reconfig parameter which reloads images.
+ Use global gdb_ImageDir.
+ (reconfig): New method.
+
+ * floatbar.tcl (create_buttons): Remove target image.
+ Use global gdb_ImageDir.
+
+ * toolbar.tcl (_load_images): Use global gdb_ImageDir.
+ Add reconfig parameter which reloads images.
+ (reconfig): Don't rebuild everything, just reload images.
+ (create_menu_items): Change "Fonts" preferences menu
+ item to "Global".
+
+ * prefs.tcl (pref_set_defaults): Save only basename in
+ gdb/ImageDir preference. Initialize global gdb_ImageDir.
+ (pref_read): Set gdb_ImageDir.
+
+ * memory.tcl (build_win): Use global gdb_ImageDir.
+
+ * manage.tcl (make_icon_window): Use global gdb_ImageDir.
+
+ * about.tcl (build_win): Use global gdb_ImageDir.
+
+ * images/icons.txt: New file; icon descriptions.
+ * images/vmake.gif: New file.
+ * images/vars.gif: New file.
+ * images/watch.gif: New file.
+ * images/bp.gif: New file.
+ * images/memory.gif: New file.
+
+ * images2/icons.txt: New file; icon descriptions.
+
+ * toolbar_pref.tcl: Removed.
+
+ * main.tcl (run_executable): If target is "exec" don't
+ show target dialog unless the run command fails.
+
+Wed Apr 15 13:15:22 1998 Elena Zannoni <ezannoni@kwikemart.cygnus.com>
+
+ * interface.tcl: (gdbtk_tcl_warning) changed to selectively
+ display warnings in the GUI.
+ (show_warning) new procedure. Displays warning dialogs.
+
+Wed Apr 15 07:13:04 1998 Keith Seitz <keiths@onions.cygnus.com>
+
+ * src.tcl (do_popup): Fix merge casualty -- revert to pre-3/22 version.
+ Don't allow tracepoint ranges to be set unless in asynch mode.
+
+Mon Apr 13 16:00:06 1998 Elena Zannoni <ezannoni@kwikemart.cygnus.com>
+
+ * warning.tcl: new file. Implements WarningDlg class, for warning
+ dialogs.
+
+ * tclIndex: regenerated
+
+ * Makefile: added new file warning.tcl
+
+ * manage.tcl: added new window warningdlg, for ignorable warnings.
+
+ * interface.tcl: (gdbtk_tcl_warning) new procedure. Creates a warning
+ dialog.
+ (gdbtk_tcl_ignorable_warning) new procedure. Creates a warning dialog.
+ The user can choose to not have this dialog pop up again during the
+ same debugging session.
+
+Mon Apr 13 13:04:20 1998 Keith Seitz <keiths@onions.cygnus.com>
+
+ * stack.tcl (StackWin::constructor): Withdraw toplevel before calling
+ all busy hooks; then build the window, go idle and pop the window onto
+ the screen.
+
+ * main.tcl (set_target_name): Use a regexp to match target names.
+ Add "sds" as a target.
+ (run_executable): Use gdb_immediate to run executable.
+
+Fri Apr 10 10:27:42 1998 Elena Zannoni <ezannoni@kwikemart.cygnus.com>
+
+ * bp.tcl: changed default value of public var tracepoints to be 0.
+
+Thu Apr 9 15:21:49 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * global_pref.tcl (destructor): Delete test fonts here instead of
+ in ok and cancel. This fixes bug when dialog was closed by
+ clicking on close gadget.
+
+ * src_pref.tcl (pick): When colors are changed, immediately
+ update the dialog.
+
+Thu Apr 9 04:03:27 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * target.tcl (build_win): Bind <Return> for cancel and help buttons.
+
+Wed Apr 8 10:57:14 1998 Elena Zannoni <ezannoni@kwikemart.cygnus.com>
+
+ * tdump.tcl: (update): show stuff on window only if current
+ trace frame is not null.
+
+ * variables.tcl: (build_win): get the current output-radix
+ (getVariables): decide the format to display a var based on Radix
+ VariableWin class: added protected member Radix
+ (value): decide display based on output-radix
+
+Wed Apr 8 06:17:42 1998 Keith Seitz <keiths@onions.cygnus.com>
+
+ * bp.tcl (get_actions): Open the trace dialog based on a tracepoint's
+ number.
+
+ * tracedlg.tcl (title): New method to title window based on mode.
+ (TraceDlg::constructor): After the interp is idle, title this window.
+ (build_win): Add support to simply pass a tracepoint number for editing.
+
+Tue Apr 7 12:49:45 1998 Keith Seitz <keiths@onions.cygnus.com>
+
+ * variables.tcl (VariableWin): We should deiconify after withdrawing...
+
+ * tracedlg.tcl (gdb_edit_tracepoint): Make necessary gdb_cmd changes
+ to support new API.
+ (gdb_add_tracepoint): Make necessary gdb_cmd changes to support new
+ API.
+
+ * tdump.tcl (update): Make necessary gdb_cmd changes to support new
+ API.
+ (TdumpWin::constructor): We should deiconify after we withdraw...
+ Change idle callback to an update callback.
+ (TdumpWin::destructor): Change idle callback to update callback.
+
+ * srcbar.tcl (_open_file): Make necessary gdb_cmd changes to support new
+ API.
+ (create_buttons): Change all tracing commands to use gdb_immediate.
+
+ * main.tcl (set_target_name): Add simulator target.
+
+ * src.tcl (mode): When changing modes, clear the line to pc mappings.
+ (location): Do not set current_addr if we are not running and gdb_loc
+ thinks we're at 0x0.
+ Clear the text-window-line to pc mapping when appropriate.
+ Revert display_breaks change for SRC+ASM mode.
+ (bp): Make sure mapping of PC to src window line exists before
+ attempting to set breakpoints/tracepoints.
+
+Fri Apr 3 13:57:42 1998 Elena Zannoni <ezannoni@kwikemart.cygnus.com>
+
+ * src.tcl: (do_key): added actions for key bindings in trace mode.
+ (config_win): added key bindings for trace mode.
+
+ * srcbar.tcl: (_set_trace) changed balloon contents for tstart/
+ tstop button.
+
+ * toolbar.tcl: (create_menu_items): changed names of menu items
+ tstart and tstop to 'Begin Collection' and 'End Collection'.
+ Changed name of Preference menu item from 'GDB' to 'Fonts'.
+ Changed name of File menu item from 'Debugger Preferences' to
+ 'Target Settings'.
+ Commented out Preference menu item 'Download'.
+ (create_buttons): tdump button, inserted text 'Td' in place of missing
+ icon.
+
+
+Tue Mar 31 17:20:59 1998 Ian Lance Taylor <ian@cygnus.com>
+
+ * Makefile (TCL): Add ide.tcl.
+ * tclIndex: Rebuild.
+
+Sun Mar 29 18:50:46 1998 Keith Seitz <keiths@onions.cygnus.com>
+
+ * tracedlg.tcl (build_win): Enable tracepoints at assembly addresses.
+ (add_action): Enable tracepoints at assembly addresses.
+ (ok): Enable tracepoints at assembly addresses.
+ (edit): Enable tracepoints at assembly addresses.
+ (gdb_add_tracepoint): Enable tracepoints at assembly addresses.
+
+ * srcbar.tcl (_open_file): If main () exists, show it.
+
+ * src.tcl (display_breaks): If we are displaying breaks in assembly,
+ clear the line and file specs.
+ (location): Use display_breaks to insert breaks and traces.
+ (bp): Rewrite. Actions are based on mode of the source window.
+ (bp_line): When setting a tracepoint in assembly, pass address
+ to set_tracepoint.
+ (set_tracepoint): Open trace dialog specifying either line or
+ address at which to set trace.
+ (tracepoint_range): Rewrite. Actions are based on the mode of the
+ source window. Now able to insert ranges of traces in any mode.
+
+ * actiondlg.tcl (ActionDlg::constructor): Enable widget via address
+ specification.
+ (ActionDlg::Line): Default to empty list.
+ (ActionDlg::Address): Add new memeber to enable assembly operation.
+
+Sun Mar 29 21:21:37 1998 Elena Zannoni <ezannoni@kwikemart.cygnus.com>
+
+ * bp.tcl: add tracepoint number to tracepoint window.
+ (build_win)(bp_add)(bp_select)(bp_modify)(bp_delete)
+
+ * manage.tcl: (manage_init) do not open windows not related to
+ current mode
+
+ * tdump.tcl: (reconfig) remove it
+ (config) add toplevel window, show window after it has been built.
+ (update) add calls to busy and idle hooks, add third argument to
+ gdb_cmd call
+
+Sun Mar 29 15:01:03 1998 Keith Seitz <keiths@onions.cygnus.com>
+
+ * srcbar.tcl (_set_trace): Use gdb_immediate to execute the "tstop".
+ Call run_executable when requesting a tstart.
+ (_open_file): Convert all paths under cygwin32 to a posix-compliant
+ pathname. Add this path to the source search list.
+
+ * src.tcl (set_execution_status): Change stop messages to support
+ tracing.
+ (tracepoint_range): Clear the selection when we set a range of
+ tracepoints.
+
+ * main.tcl (set_target): Use gdb_immediate so that the console gets
+ output of target command.
+ (run_executable): Use gdb_immediate for run command.
+ Include trace support.
+
+Sat Mar 28 15:50:01 1998 Keith Seitz <keiths@onions.cygnus.com>
+
+ * srcbar.tcl (create_menu_items): Put menu items in proper order.
+ (_open_file): Add exe file's directory to the default source
+ search path.
+
+Sat Mar 28 14:29:08 1998 Keith Seitz <keiths@onions.cygnus.com>
+
+ * srcbar.tcl (GDBSrcBar: runstop trace): If running async'ly, set
+ the run/stop button by calling _set_trace. Otherwise use _set_runstop.
+ (create_menu_items): Add file command to open a new exe.
+ (_open_file): New method to handle requests to open a new exe.
+
+ * main.tcl (set_target): If this is the first time running,
+ then show the download prefs dialog.
+
+Sat Mar 28 16:30:55 1998 Elena Zannoni <ezannoni@kwikemart.cygnus.com>
+
+ * tracedlg.tcl: (build_win) reinserted 'update idletasks' to
+ display Actions frame properly.
+
+ * actiondlg.tcl: (sort) moved "All Registers", "All Locals",
+ "All Arguments" to beginning of list.
+
+ * src.tcl: (line_is_executable) new method. Used in
+ tracepoint_range.
+
+Sat Mar 28 10:58:04 1998 Keith Seitz <keiths@onions.cygnus.com>
+
+ * tracedlg.tcl (gdb_edit_tracepoint): Don't let gdb_cmd call busy and
+ idle hooks.
+ (gdb_add_tracepoint): Ditto.
+
+ * src.tcl (config_win): Change exit key binding from 'q' to 'x.'
+ (goto_func): That's "file tail", not "file split."
+
+ * srcbar.tcl (_set_stepi): Don't do anything if we're debugging
+ asynchronously.
+
+Sat Mar 28 10:09:21 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * toolbar.tcl (create_menu_items): Change "Close Debugger"
+ menu item to "Exit".
+
+Sat Mar 28 02:38:51 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * src_pref.tcl (build_win): Fix Save and Apply buttons.
+ Change "Save" to "OK". Use standard_button_box.
+ (save): New method, save and exit.
+ (apply): New method; save and don't exit.
+ (cancel): New method; cancel all changes.
+
+ * src.tcl (reconfig): Reconfigure colors, too.
+
+ * global_pref.tcl (Globalpref): Fix deiconify call.
+ (build_win): Use standard_button_box. Set default to OK.
+ Remove unused stuff. Cleanup display.
+
+ * Makefile: Removed toolbar_pref.tcl.
+
+ * tclIndex: Rebuilt.
+
+ * srcbar.tcl (create_buttons): Make toolbar always attached
+ to source window.
+
+ * toolbar.tcl (build_win): Always display toolbar and
+ menubar attached to source window.
+
+ * prefs.tcl (pref_set_defaults): Removed toolbar prefs.
+
+ * manage.tcl (manage_init): Remove hack to change preferences
+ names.
+ (manage_init): Remove toolbar and toolbar prefs code.
+ (manage_create): Remove toolbar code.
+ (manage_open): Remove toolbar code.
+ (manage_find): Remove toolbar code.
+ (manage_delete): Remove toolbar code.
+ (manage_restart): Remove toolbar code.
+
+Fri Mar 27 19:52:53 1998 Keith Seitz <keiths@onions.cygnus.com>
+
+ * toolbar.tcl (create_menu_items): Do not disable preferences.
+
+ * src.tcl (reconfig): Rewrite to not destroy window.
+ Symbolic fonts are a blessing!
+ Pass the image handles for our breakdots to makeBreakDots.
+ (file): Move breakpoint/tracepoint insertion to a separate function...
+ (display_breaks): .... this one.
+ (location): Move the block which fills combo boxes to top in
+ case an error causes us to exit early.
+ (makeBreakDot): Accept an optional image handler so that it can be
+ configured instead of created.
+
+ * global_pref.tcl (build_win): Carry around a list of all changable
+ fonts in case more granularity is needed. (Windows cannot change
+ menu font...) Disable menu font for windows.
+ (ok): Check the list of changable fonts.
+ (cancel): Check the list of changable fonts.
+ (apply): Check the list of changable fonts.
+
+ * console.tcl (reconfig): New (empty) method to handle preference
+ changes.
+
+Fri Mar 27 16:08:57 1998 Keith Seitz <keiths@onions.cygnus.com>
+
+ * global_pref.tcl (ok): Must use preferences for comparison. Don't
+ "manage restart" unless needed.
+ (cancel): Don't configure the font -- changing the preference will do
+ it automagically.
+
+Fri Mar 27 14:21:02 1998 Keith Seitz <keiths@onions.cygnus.com>
+
+ * toolbar.tcl (create_menu_items): Use gdbtk_quit to initiate a quit.
+
+ * src.tcl (do_key): Use gdbtk_quit to initiate a quit.
+
+ * prefs.tcl (pref_save): Set a default value for WIN.
+ Don't "manage restart".
+ (pref_set_defaults): Register a quit hook to save preferences.
+ (pref_quit): Call pref_save to save all preferences when we quit.
+
+ * manage.tcl (manage): Add "quit".
+ (manage_init): Register a gdb_quit_hook.
+ (manage_delete): Instead of guessing when and what to ask to confirm
+ a quit, call gdbtk_quit.
+ (manage_quit): New procedure. This is called from the gdb_quit_hook to save
+ window active'ness and geometries by calling manage_save.
+
+ * interface.tcl: Define "gdb_quit_hook".
+ (gdbtk_quit): New procedure to call whenever a quit is requested.
+
+ * global_pref.tcl (ok): Do not save preferences here.
+
+Fri Mar 27 12:21:07 1998 Keith Seitz <keiths@onions.cygnus.com>
+
+ * tracedlg.tcl (TraceDlg): Wait until idle to deiconify ourselves.
+
+ * global_pref.tcl (Globalpref): Withdraw window before creating and
+ deiconify it when idle.
+ (cancel): Let the window manager destroy us.
+ (ok): Let the window manager destroy us.
+
+ * target.tcl (GdbLoadPref::constructor): Withdraw window before creating
+ and deiconfiy it when idle.
+
+ * memory.tcl (MemWin::constructor): Withdraw window before going
+ busy.
+
+ * register.tcl (RegWin::constructor): Withdraw window before going
+ busy.
+
+ * src.tcl (SrcWin::constructor): Withdraw window before creating and
+ deiconify it when idle.
+
+Fri Mar 27 10:52:30 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * target.tcl: Fix entry for temotetcp.
+
+ * main.tcl (set_target_name): Build correct gdb_target_cmd.
+
+Fri Mar 27 11:23:18 1998 Elena Zannoni <ezannoni@kwikemart.cygnus.com>
+
+ * target.tcl: (build_win) added call to change_target to
+ get the correct entry widgets when the dialog is opened.
+
+Fri Mar 27 01:43:41 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * target.tcl: Add simulator and remotetcp targets to
+ target database. Change all the gdb/load/$target/foo
+ preferences to gdb/load/$target-foo because the prefs
+ code expects gdb/section/varname. The extra slash confuses
+ it.
+ (set_saved): Add saved_portname and saved_hostname for TCP.
+ (write_saved): Add saved_portname and saved_hostname for TCP.
+ (fill_rates): change states of hostname and portnum entry widgets.
+ (fill_targets): Add fake remotetcp entry in target list.
+ (change_baud): When switching between tcp and serial targets
+ pack or forget the appropriate widgets.
+ (build_win): Create hostname and port number entry widgets.
+ (change_target): Update hostname and portnum widgets.
+
+ * prefs.tcl (pref_save): Add 'load' as a section to be saved.
+ Set gdb/load/target to 'exec'.
+
+ * manage.tcl (_manage_null_handler): Deleted.
+
+ * download.tcl (download_it): Don't call IDE functions
+ unless GDTK_IDE is set.
+
+ * main.tcl (gdbtk_tcl_preloop): Get name of executable
+ if one was supplied on command line.
+ (set_target_name): Save target name as preference.
+ (run_executable): Call set_target.
+
+Fri Mar 27 00:23:46 1998 Keith Seitz <keiths@onions.cygnus.com>
+
+ * src.tcl (location): Catch error of getting location of main.
+
+ * prefs.tcl (pref_set_defaults): Add gdb/toolbar/active.
+ Add trace for global/fixed font to update src-font.
+ (pref_read): Add code to deal with global preferences.
+ (pref_save): Add code to deal with global preferences.
+ (pref_src-font_trace): Trace function which set src-font to global/fixed.
+
+ * global_pref.tcl (build_win): Relayout font selectors and add a selections
+ for menu and default fonts.
+ Rename Save to OK and Quit to Cancel, renaming methods, too.
+ (font_changed): Add arguments to facilitate multiple fonts.
+ (reconfig): Define as empty.
+ (ok): Rewrite to facilitate multiple fonts.
+ (cancel): Rewrite to facilitate multiple fonts.
+ (apply): Rewrite to facilitate multiple fonts.
+
+ * manage.tcl (manage_restart): Call gdbtk_idle to reset the toolbar after
+ it is recreated.
+
+Thu Mar 26 23:49:26 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * tdump.tcl, tfind_args.tcl: New files.
+
+Thu Mar 26 22:29:28 1998 Elena Zannoni <ezannoni@kwikemart.cygnus.com>
+
+ * tracedlg.tcl: (config) commented out grab. Made window non-modal.
+ (destructor) do not release grab.
+ (done) do not reinstall grab.
+
+ * toolbar.tcl: (create_buttons) changed buttons for the tracepoint
+ case to open tdump window, and tracepoint window.
+ (create_menu_items) change Run menu to do tstart, tstop for tracepoint
+ case. Changed View menu to show tracepoint window for tracepoint case.
+ Changed 'Control' menu to 'Trace' menu for tracepoint case, with
+ tfind commands.
+
+ * srcbar.tcl: (create_buttons) changed the buttons for the
+ tracepoint case to do tfind commands.
+ (_set_trace) new method. Toggles tstart/tstop button.
+
+ * src.tcl: (config) decide defatul action for left click on
+ source based on 'mode' preference.
+ (bp_line) ditto.
+ (config_win) modify pop upmenu on source window to display only
+ 'set tracepoint'.
+
+ * prefs.tcl: (pref_set_defaults) added preference gdb/mode for
+ tracepoints or breakpoint display.
+
+ * manage.tcl: (manage_init) added tracepoint window, args windows
+ for tfind, tdump window.
+ (manage_open) use eval in call to manage_create.
+
+ * bp.tcl: (build_win) added PassCount to the display and modified
+ the menus for the tracepoint case to display actions.
+ (bp_add) display pass_count too in the tracepoint list.
+ (bp_select) changed indexes of menu entries to be entries names.
+ added field passcount to selection for tracepoints.
+ (bp_modify) added passcount for tracepoints.
+ (bp_delete) added passcount for tracepoints.
+ (get_actions) new method
+ Added new public member "tracepoints" to decide which kind of window
+ needs to be displayed.
+
+ * Makefile: added new files tfind_args.tcl and tdump.tcl.
+
+ * tclIndex: regenerated
+
+Thu Mar 26 14:23:00 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * main.tcl (set_target_name): Make target dialog always
+ on top.
+
+ * target.tcl (build_win): Bind Return to save.
+ (GdbLoadPref): Denter dialog on screen.
+
+Thu Mar 26 14:16:36 1998 Keith Seitz <keiths@onions.cygnus.com>
+
+ * memory.tcl (update_address): Catch errors to update_addr so that
+ we do not error and leave the GUI busy.
+
+Thu Mar 26 13:51:58 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * toolbar.tcl (create_menu_items): Remove "Cygnus
+ Foundry Tour" and "Submit a PR" from the menu.
+
+ * src.tcl (file): Set title to GDB.
+
+ * manage.tcl (manage_init): Set About name.
+
+ * main.tcl (set_target): Set title to GDB.
+
+ * interface.tcl (gdbtk_tcl_query): Set title correctly.
+
+ * Makefile: Remove download_pref.tcl.
+
+Thu Mar 26 11:33:02 1998 Keith Seitz <keiths@onions.cygnus.com>
+
+ * Makefile: Add target.tcl to list of sources.
+
+ * tclIndex: Rebuilt.
+
+ * target.tcl (GdbLoadPref): Trace changes to gdb_loaded.
+ (target_trace): New procedure. This is invoked by a write trace
+ to gdb_loaded.
+
+ * interface.tcl (gdbtk_busy): New procedure to run all busy hooks
+ (gdbtk_update): New procedure to run all update hooks
+ (gdbtk_idle): New procedure to run all idle hooks. Also runs the
+ no inferior hooks if no inferior has been created.
+ Rename old gdb_idle_hook to gdb_update_hook for clarity.
+ Change all references of run_hooks to use gdbtk_busy, gdbtk_idle, and
+ gdtk_update.
+
+ * download.tcl: Make busy/update/idle hook changes.
+
+ * main.tcl: Make busy/update/idle hook changes.
+ (set_exe): Clear gdb_loaded whenever a new exec file is selected.
+
+ * manage.tcl: Make busy/update/idle hook changes.
+
+ * mem_pref.tcl: Make busy/update/idle hook changes.
+
+ * memory.tcl: Make busy/update/idle hook changes.
+
+ * register.tcl: Make busy/update/idle hook changes.
+
+ * src.tcl: Make busy/update/idle hook changes.
+
+ * stack.tcl: Make busy/update/idle hook changes.
+
+ * variables.tcl: Make busy/update/idle hook changes.
+
+ Merged with Foundry 1.0:
+ Wed Mar 25 14:22:28 1998 Keith Seitz <keiths@onions.cygnus.com>
+
+ * register.tcl (reconfig): Call busy and idle hooks.
+
+ * memory.tcl (update_address): Call busy and idle hooks.
+
+ Wed Mar 25 11:38:49 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * src.tcl (location): Fix typo.
+
+ Tue Mar 24 21:03:01 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * src.tcl (location): If gdb_listfuncs returns an error, display
+ an error message that says the file was either not found or contained
+ no debugging information.
+ (location): When disassembling, put busy and idle calls before
+ and after. Set "NoRun" to indicate the busy hook should not
+ display the stop sign because the target isn't running, GDB may
+ just take a few seconds to do the disassembly.
+ (busy): Hack to support NoRun mode.
+
+ * srcbar.tcl (_set_runstop): Add another case to disable the
+ Run icon instead of changing it to a stop sign.
+
+ * main.tcl (set_exe): If the file has no debugging information,
+ display an error message and exit. This should only happen with
+ intentionally stripped files.
+
+ Tue Mar 24 17:04:36 1998 Keith Seitz <keiths@onions.cygnus.com>
+
+ * mem_pref.tcl (build_win): Keep track of all widgets that should be
+ disabled when busy.
+ (busy): New method which disables anything that could cause trouble.
+ (idle): New method which re-enables anything that "busy" disables.
+ (apply): Call busy and the busy hooks before doing update of memory
+ window. Then call idle and the idle callbacks when we are done.
+
+ Tue Mar 24 12:07:52 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * src.tcl (location): Filter out .s and .S files because
+ Foundry does not yet support assembly source debugging.
+
+ Tue Mar 24 08:50:46 1998 Keith Seitz <keiths@onions.cygnus.com>
+
+ * register.tcl (but3): Don't pop up the right-click menu if we are
+ running.
+
+ * download.tcl (download_it): Force an update so that all windows
+ are created and get their busy hooks called.
+
+ * console.tcl (invoke): Make sure we are not running.
+ (busy): New method.
+ (idle): New method.
+
+ Mon Mar 23 15:00:57 1998 Drew Moseley <dmoseley@cygnus.com>
+
+ * src.tcl: (location): Assume we are locating main() if the target is
+ not running and we can't figure out which function we are in.
+
+ * main.tcl (run_executable): Change to assembly mode when we try to
+ load a blank file. This usually means that source level debugging
+ was not enabled when this file was compiled.
+
+ Reverse the parameters to src method::location() method invocation so
+ they are in the correct order
+
+ Mon Mar 23 12:04:23 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * src.tcl (update): Comment out debug lines.
+
+ * main.tcl (set_target_name): If the target name changes,
+ force a new "file" command to be issued by setting
+ gdb_exe_changed.
+
+ Sat Mar 21 00:09:37 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * download.tcl (download_it): Remove call to run_idle_hooks.
+
+ * src.tcl (no_inferior): Call set_execution_status.
+
+ * bp.tcl (bp_modify, bp_delete): Change to take an entry
+ number.
+ (update): Sometimes "create" calls are for existing
+ breakpoints and should be "modified" calls. Detect this
+ and pass the entry number to bp_delete or bp_modify.
+
+ Fri Mar 20 22:50:55 1998 Tom Tromey <tromey@cygnus.com>
+
+ * console.tcl (insert): Remove all \r characters from string to be
+ inserted.
+
+ Fri Mar 20 01:55:14 1998 Keith Seitz <keiths@cygnus.com>
+
+ * watch.tcl (validateEntry): Fencepost for running.
+
+ * variables.tcl (VariableWin): Use "add_hook_before".
+ (idle_done): New gdb_idle_done_hook for this object.
+ (update): Don't call enable_ui here.
+ (enable_ui): Change cursor for this object.
+ (disable_ui): Ditto.
+ (no_inferior): Ditto.
+
+ * toolbar.tcl (GDBToolBar): Use "add_hook_before".
+
+ * stack.tcl (StackWin): Use "add_hook_before".
+ (StackWin): Encapsulate creation of this object with
+ busy and idle hooks so that the user gets some feedback and to
+ prevent other widgets from attempting to update.
+ (update): Add some sanity checking so that we do not update with
+ garbage in the window.
+ (idle_done): New gdb_idle_done_hook for this object.
+ (change_frame): Fencepost for running.
+ (busy): New gdb_busy_hook for this object.
+ (no_inferior): New gdb_no_inferior_hook for this object.
+ (cursor): New helper method to set the cursor of all subwindows.
+
+ * src.tcl (SrcWin): Use "add_hook_before".
+ (toggle_updates): Use "add_hook_before".
+ (stack): Encapsulate creation of the stack object with
+ busy and idle hooks so that the user gets some feedback and to
+ prevent other widgets from attempting to update.
+ (idle_done): New gdb_idle_done_hook for this object.
+ (set_execution_status): When Program is Terminated..., reset
+ gdb_running.
+ (config_win): Pull mouse pointer cursor assignments in text widget
+ out into a separate function.
+ (bind_src_tags): New method to set the cursor for the window's text
+ widget tags.
+ (disable_ui): Call bind_src_tags to change cursor to "watch".
+ (enable_ui): Ditto.
+ (no_inferior): Ditto.
+ (cursor): New helper method to set the cursor of all subwindows.
+
+ * register.tcl (RegWin): Encapsulate creation of this object with
+ busy and idle hooks so that the user gets some feedback and to
+ prevent other widgets from attempting to update.
+ Use "add_hook_before".
+ (reg_select_up): Fencepost for running.
+ (reg_select_down): Fencepost for running.
+ (reg_select_right): Fencepost for running.
+ (reg_select_left): Fencepost for running.
+ (reg_select): Fencepost for running.
+ (edit): Fencepost for running.
+ (idle_done): New gdb_idle_done_hook for this object.
+ (busy): New gdb_busy_hook for this object.
+
+ * memory.tcl (MemWin): Encapsulate creation of this object with
+ busy and idle hooks so that the user gets some feedback and to
+ prevent other widgets from attempting to update.
+ Use "add_hook_before".
+ (create_prefs): Fencepost for running.
+ (idle_done): New gdb_idle_done_hook for this object.
+ (edit): Fencepost for running.
+ (newsize): Fencepost for running.
+ (busy): New method to block UI while running inferior.
+ (do_popup): Fencepost for running.
+ (cursor): New method to change the cursor definition for this
+ object.
+
+ * manage.tcl (manage_init): Use "add_hook_before".
+
+ * main.tcl (run_executable): Use "run_idle_hooks".
+
+ * ide.tcl (gdbtk_ide_init): Don't create the source window here.
+
+ * interface.tcl: Define new hook "gdb_idle_done_hook" -- to be called
+ when the debugger does completely idle to allow input to objects
+ again.
+ (run_idle_hooks): New procedure to wrap the idle hooks.
+ (gdbtk_tcl_idle): Split the idle callbacks into two parts: one that
+ only updates widgets and one that tells widgets to accept input
+ again.
+
+ * download.tcl (Download): Use add_hook_before instead of add_hook.
+ (download_it): Use run_idle_hooks instead running the idle hooks
+ directly.
+
+ * bp.tcl (BpWin): Use add_hook_before instead of add_hook.
+
+ Wed Mar 18 18:59:00 1998 Sean Mahan <smahan@cygnus.com>
+
+ * download.tcl (download_hash): Added an 'update' so the
+ status bar would work on an MBX board.
+
+ Wed Mar 18 01:50:19 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * prefs.tcl (pref_set_defaults): Define gdb/src/tab_size
+ to default to a tab size of 4.
+
+ * src.tcl (setTabs): Set up tabs correctly.
+
+ * download.tcl (download_it): Set correct state after
+ user cancels download.
+
+ Tue Mar 17 12:30:23 1998 Tom Tromey <tromey@cygnus.com>
+
+ * console.tcl (throttle): New public variable.
+ (insert): Delete initial text when past the throttle limit.
+
+ Tue Mar 17 13:31:38 1998 Keith Seitz <keiths@onions.cygnus.com>
+
+ * ide.tcl (gdb_exit_check): Do not let gdb confirm the quit if we
+ are downloading.
+
+ Tue Mar 17 13:25:22 1998 Keith Seitz <keiths@onions.cygnus.com>
+
+ * console.tcl (insert): Force update of screen.
+
+ Mon Mar 16 10:22:00 1998 Sean Mahan <smahan@cygnus.com>
+
+ * toolbar.tcl (create_menu_items): Added 'Submit PR' to the
+ help menu. For PR15334
+
+ Sun Mar 15 15:01:27 1998 Tom Tromey <tromey@cygnus.com>
+
+ * interface.tcl (gdbtk_tcl_fputs): Don't call update.
+
+ * src.tcl (build_win): Changed capitalization on balloon help.
+
+ Fri Mar 13 10:01:48 1998 Keith Seitz <keiths@onions.cygnus.com>
+
+ * src.tcl (mode): Add a horizontal scrollbar to the assembly pane
+ of SRC+ASM mode when necessary.
+
+ Fri Mar 13 00:47:59 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * main.tcl (run_executable): Don't force downloads for sim.
+
+ * download.tcl (download_it): Don't bother calling calling set_baud
+ for sim.
+
+ * manage.tcl (manage_delete): Deregister the window before deleting
+ it to prevent those annoying bgerror messages.
+
+ Thu Mar 12 15:28:22 1998 Keith Seitz <keiths@onions.cygnus.com>
+
+ * download.tcl (Download): Define a list of all sections.
+ (update_download): Loop through the list of sections, updating the
+ current section's progress and marking any previously loaded sections
+ as done, if needed.
+ (do_download_hooks): New procedure.
+ (download_hash): Use a timer to force update of GUI at regular
+ intervals -- GUI should not update 10,000 times a second.
+
+ Tue Mar 10 06:32:24 1998 Keith Seitz <keiths@onions.cygnus.com>
+
+ * interface.tcl (gdbtk_tcl_query): Allow caller to specify the default
+ button. If none is specified, it is set to 'yes'.
+
+ * manage.tcl (manage_delete): While inferior is running, gdb_cmd returns
+ immediately, so we need to manually ask the user if he wants to quit.
+
+ Tue Mar 10 10:52:09 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * download.tcl (download_it): Change where old breakpoints
+ are cleared.
+ (done): Set focus on "OK" or delete.
+
+ Tue Mar 10 05:23:42 1998 Keith Seitz <keiths@onions.cygnus.com>
+
+ * src.tcl (do_key): New method to wrap all keypresses.
+ (mode): Use do_key method.
+ (config_win): Use do_key method.
+
+ Mon Mar 9 23:06:21 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * src.tcl (download_progress): Add an optional message
+ parameter to the function for use with error messages.
+ Don't set_status twice on cancel. Call update if
+ load fails.
+
+ * download.tcl (done): If 'msg' is set, it should be
+ displayed and download has failed. Update all source
+ windows.
+ (cancel): Don't delete window here. Let it get deleted
+ after call to method 'done'.
+ (download_it): If download failed, call done method
+ with error message. Force reissue of target command.
+ Handle set_target failures.
+
+ * main.tcl (set_target): Check result of target command
+ to see if the user cancelled the command.
+ (run_executable): Use gdb_program_has_run instead of
+ gdb_app_running, which was removed everywhere. Force
+ download when gdb_program_has_run. If user cancels download
+ before the download starts, preserve previous state.
+
+ Mon Mar 9 15:06:21 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * console.tcl (invoke): After gdb_immediate() finishes
+ check to see if the window is still there.
+
+ * main.tcl: Initialize gdbtk_state(console).
+
+ * interface.tcl: Remove some unused globals. Replace gdb_console
+ with gdbtk_state(console).
+ (gdbtk_tcl_readline_*): Don't set gdbtk_state(console) every
+ time. Let manage.tcl do it.
+
+ * manage.tcl (manage_create): Replace gdb_console with
+ gdbtk_state(console). Check for windows that were deleted,
+ but not actually gone yet.
+ (manage_delete): Replace gdb_console with gdbtk_state(console).
+
+ Mon Mar 9 09:08:11 1998 Keith Seitz <keiths@onions.cygnus.com>
+
+ * watch.tcl (build_win): Tweak layout of the entry and button,
+ switching to grid geometry manager.
+
+Thu Mar 26 01:22:23 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * target.tcl: New file. Implements target dialog.
+
+ * srcbar.tcl (_set_run): Remove because it was no longer used.
+
+ * util.tcl (freeze): Only call idewindow_freeze when
+ using the IDE.
+
+ * prefs.tcl (pref_set_defaults): Set default tab size to 4.
+
+ * src.tcl (location): If gdb_listfuncs cannot find
+ functions, display error message.
+ (setTabs): Set real tabs according to gdb/src/tab_size.
+
+ * main.tcl (set_exe): Check to see if file was stripped.
+ Cannot debug without some symbols.
+ (set_target_name): If target changes, set gdb_exe_changed
+ so new "file" command will be sent. When not using IDE,
+ display target requester.
+
+ * manage.tcl: Set loadpref to GdbLoadPref.
+
+Wed Mar 25 14:13:52 1998 Elena Zannoni <ezannoni@kwikemart.cygnus.com>
+
+ * manage.tcl (manage_init) added tracedlg and actiondlg windows.
+
+Wed Mar 25 14:08:51 1998 Elena Zannoni <ezannoni@kwikemart.cygnus.com>
+
+ * interface.tcl (gdbtk_tcl_pre_add_symbol): New procedure.
+ (gdbtk_tcl_post_add_symbol): New procedure.
+
+ * src.tcl (set_execution_status): Use "set_status" to write to the
+ status bar, not "set Status".
+
+Mon Mar 23 13:41:39 1998 Elena Zannoni <ezannoni@kwikemart.cygnus.com>
+
+ * memory.tcl: Changes to support new faster gdb_get_mem().
+ (do_popup): Add "Go To" and Open New Window" to the popup
+ menu.
+
+Sat Mar 21 21:18:06 1998 Elena Zannoni <ezannoni@kwikemart.cygnus.com>
+
+ Merged changes from Foundry (list follows in reverse chronological
+ order)
+
+ Sean Mahan <smahan@cygnus.com>
+ * download_pref.tcl (help): Added method to display context
+ sensitive help.
+
+ Keith Seitz <keiths@onions.cygnus.com>
+ * src.tcl (bp_line): Don't insert breakpoints if we're running.
+ (disable_ui): Disable selections. Workaround for TkTextDisplay bug.
+ (enable_ui): Enable selections.
+ (no_inferior): Enable selections.
+
+ Tom Tromey <tromey@cygnus.com>
+ * toolbar.tcl (create_menu_items): Use gdb_immediate, not gdb_cmd,
+ so that output appears in console window.
+ * src.tcl (bp_line): Use gdb_immediate when running "continue".
+ (mode): Use gdb_immediate, not gdb_cmd, so that output appears in
+ console window.
+ (config_win): Likewise.
+ * srcbar.tcl (create_buttons): Use gdb_immediate, not gdb_cmd, so
+ that output appears in console window.
+ * console.tcl (lvarpush): Removed.
+ (_insertion): New method.
+ (_saved_insertion): New private variable.
+ (constructor): Don't let user use mouse to put cursor outside
+ command line.
+ * src.tcl (build_win): Use global/status font on status bar.
+ * interface.tcl (gdbtk_tcl_query): Moved vwait out of `if'
+ statement -- must vwait in all cases, not just in case when
+ question is actually asked.
+
+ Keith Seitz <keiths@onions.cygnus.com>
+ * variables.tcl (deleteTree): Reset Locals and ChangeList, too.
+
+ Martin M. Hunt <hunt@cygnus.com>
+ * toolbar.tcl (enable_ui): Don't always set stepi and nexti
+ buttons on.
+
+ Keith Seitz <keiths@onions.cygnus.com>
+ * toolbar.tcl (no_inferior): Instead of enabling/disabling the
+ individual menus on Windows, disable each menu's entries.
+ (disable_ui): Ditto.
+ (enable_ui): Ditto.
+
+ Keith Seitz <keiths@onions.cygnus.com>
+ * manage.tcl (manage_delete): Catch destruction of the src window when
+ downloading and ask user if this is what he intends.
+ (manage_init): Don't install idle, busy, and no_inferior hooks. Allow gdb
+ to exit whenever the user wants to.
+ * srcbar.tcl (cancel_download): download_cancel_ok is a global.
+
+ Martin M. Hunt <hunt@cygnus.com>
+ * ide.tcl (receive_file_changed): Minor fix when a new
+ executable is built when GDB is running.
+
+ Martin M. Hunt <hunt@cygnus.com>
+ * bp.tcl (bp_delete): If a selected breakpoint is deleted,
+ set "selected" to 0.
+
+ Keith Seitz <keiths@onions.cygnus.com>
+ * srcbar.tcl (cancel_download): New method to cancel downloads. Needed
+ to cancel download dialog-enabled downloads.
+ (_set_runstop): Call cancel_download.
+ * download.tcl (Download::constructor): Make sure to set the toolbar
+ properly so that the Stop/Cancel button cancels a download.
+ (download_it): Force the CANCEL to all download_progress_hook's.
+ * src.tcl (download_progress): Add special section identifier for
+ canceled downloads.
+ (SrcWin::destructor): Pass the state_hook's command to remove_hook.
+
+ Sean Mahan <smahan@cygnus.com>
+ * toolbar.tcl (create_menu_items): Help menu follows "Help Topics"
+ standard (PR 15082).
+
+ Tom Tromey <tromey@cygnus.com>
+ * interface.tcl (gdbtk_tcl_query): Consolidate Windows case; must
+ `vwait' even when question is already being asked.
+
+ Martin M. Hunt <hunt@cygnus.com>
+ * interface.tcl (gdbtk_tcl_query): Only use ide_messageBox
+ on Windows.
+
+ Martin M. Hunt <hunt@cygnus.com>
+ * register.tcl: Catch several gdb_register commands
+ so errors don't bother us.
+ * variables.tcl (destructor): Remove all hooks.
+
+ Martin M. Hunt <hunt@cygnus.com>
+ * download.tcl (done): Don't let seconds be zero.
+ * manage.tcl (manage_disable_all): Don't ever disable "."
+
+ Martin M. Hunt <hunt@cygnus.com>
+ * main.tcl (run_executable): Removed delete_breakpoints
+ stuff.
+ * download.tcl (download_it): Removed delete_breakpoints
+ stuff. Clear any breakpoints at exit and main before
+ restarting. They get set again automatically if the
+ preferences say they should.
+ (Download): Don't call freeze on download window, because
+ it stops updating when we do.
+ (update): Renamed to update_download to avoid confusion.
+ * src.tcl (mode): When changing from SRC+ASM to another
+ mode, unset "awin".
+ (bp_line): On a "Continue to Here" don't try to
+ restore breakpoints that didn't exist before.
+
+ Tom Tromey <tromey@cygnus.com>
+ * interface.tcl (gdbtk_tcl_query): Set -parent on dialog.
+
+ Martin M. Hunt <hunt@cygnus.com>
+ * src.tcl (build_win): Set mode combobox width to 10.
+ (goto_func): If a function name is an unmangled one,
+ it is a C++ method so don't prepend filename when
+ setting location. This is a kludge, but we are limited
+ by the symtax the GDB command line parser will accept.
+ (location): When loading function combobox,
+ remember which names are unmangled. Change width of
+ function combobox dynamically to better accomodate
+ those long C++ names.
+
+ Martin M. Hunt <hunt@cygnus.com>
+ * src.tcl (bp_line): When doing a "continue to here",
+ first save states of all breakpoints then restore
+ when finished.
+ (config_win): Uncomment "Continue to Here" menu item.
+
+ Martin M. Hunt <hunt@cygnus.com>
+ * src.tcl (location): Use ide_cygwin_path on Windows
+ to change project root to the right format.
+
+ Drew Moseley <dmoseley@cygnus.com>
+ * main.tcl: (run_executable): Modified to call download_it
+ with the parameter indicating whether to delete breakpoints.
+ If GDB is loaded ($gdb_loaded == 1) and the app is running
+ ($gdb_app_running == 1) then we don't delete the breakpoints.
+ All other situations will require deleting the breakpoints.
+ This allows us to redownload and run the same executable w/o
+ losing the breakpoint information.
+ * download.tcl: (download_it): Modified this routine to
+ take a boolean parameter indicating whether to delete
+ the breakpoints before downloading.
+
+ Sean Mahan <smahan@cygnus.com>
+ * toolbar.tcl (create_menu_items): Couldn't use 'helpdir'
+ variable so used Paths(prefix) and added help.
+
+ Martin M. Hunt <hunt@cygnus.com>
+ * src.tcl (set_state): Turn off debugging.
+ (location): Map windows pathnames into form GDB uses
+ internally.
+ (bp_line): Use gdb_set_bp to set breakpoints on
+ a specific line in a file.
+
+ Martin M. Hunt <hunt@cygnus.com>
+ * stack.tcl (update): Skip over any empty elements
+ in parsing the stack line to get the correct PC.
+
+ Keith Seitz <keiths@onions.cygnus.com>
+ * download.tcl (download_it): Run gdb_busy_hook's.
+ If anything fails, make sure that the no_inferior_hook's are run.
+ Note errors that occur during downloading, ignoring the
+ "cancelled download" message. If an error occurs, set the
+ global gdb_download_error to the error message so that it can
+ be shown to the user later. Don't run the idle hooks if nothing
+ * src.tcl (download_progress): Do not rely on the value of
+ "download_cancel_ok" -- it is cleared in download_it.
+ Reorder code to take advantage of gdb_loaded and gdb_download_error
+ to determine if a download was canceled, successful, or failed due
+ to an error. Truncate the "DOWNLOAD FINISHED:" message so that it
+ will fit into the status bar given the recent font changes.
+ (busy): If gdb_loaded, set the status bar to read "Program is running."
+ Otherwise, don't touch it.
+ (config_win): Comment out "Continue to here" right-click menu item
+ until it can properly preserve breakpoint state.
+ (no_inferior): Configure the toolbar to -runstop 0. All of these
+ toolbar references should be done via the busy hook by the SrcBar
+ class itself someday...
+
+ Sean Mahan <smahan@cygnus.com>
+ * toolbar.tcl (create_menu_items): Added ability to launch
+ the tour help file from the help menu.
+
+ Martin M. Hunt <hunt@cygnus.com>
+ * manage.tcl, ide.tcl: Disable some debugging messages.
+
+ Martin M. Hunt <hunt@cygnus.com>
+ * src.tcl (set_state): When loaded state changes, invalidate
+ current file.
+
+ Martin M. Hunt <hunt@cygnus.com>
+ * src.tcl (SrcWin): Change default title to "Foundry Debugger".
+ (build_win): Change name and function combobox heights to 0.
+ Set status bar font to src-font.
+ (name): Rewrite to use _files array. This array allows us
+ to map full pathnames with short names that are easily displayed.
+ (file): Call set_name to update name combobox.
+ (location): Call set_name to update name combobox. When setting
+ the function combobox, adjust height to a maximum of 10. CLear
+ filename combobox if there is no valid filename. When setting the
+ filename combobox, adjust height to a maximum of 10. Create
+ _files array mapping full pathnames to short names. For IDE, use
+ vmake/source-files and project-root to build full pathnames.
+ When changing mode, save current line. Don't mark current line
+ with PC_TAG if gdb_running is 0.
+ (set_name): New function. Update the name combobox, using
+ the short name from _files if available.
+ * bp.tcl (bp_modify, bp_add): Use short file name from
+ _files global array.
+
+ Keith Seitz <keiths@onions.cygnus.com>
+ * variables.tcl (VariableWin): Add idle, busy, and no inferior hooks.
+ (selectionChanged): Use Running fencepost.
+ (updateNow): Use Running fencepost.
+ (editEntry): Use Running fencepost.
+ (postMenu): Use Running fencepost.
+ (setDisplay): Use Running fencepost.
+ (open): Use Running fencepost.
+ (close): Use Running fencepost.
+ (enable_ui): Define new procedure to install fencepost.
+ (disable_ui): Define new procedure to remove fencepost.
+ (no_inferior): Define new procedure to remove fencepost and clear tree.
+ (Running): New protected data. This is used as a fencepost in this object.
+ * main.tcl: Run gdb_no_inferior_hook's when done initializing.
+ * src.tcl (disable_ui): Disable the combo boxes, too.
+ (enable_ui): Enable the combo boxes, too.
+ * download.tcl (download_it): Run gdb_no_inferior_hooks, too.
+
+ Martin M. Hunt <hunt@cygnus.com>
+ * main.tcl: Move IDE help initialization to ide.tcl.
+ * ide.tcl (gdbtk_ide_init): Move help system
+ initialization here.
+
+ Sean Mahan <smahan@cygnus.com>
+ * main.tcl: Initialized help sub-system for the ide.
+
+ Tomy Hudson <thudson@thudson5.cygnus.com>
+ * prefs.tcl: Changed COM1 back to com1 per Martins request.
+
+ Martin M. Hunt <hunt@cygnus.com>
+ * src.tcl (file): Call gdb_loadfile to do most of the
+ work.
+
+ Tomy Hudson <thudson@thudson5.cygnus.com>
+ * prefs.tcl: Changed "com1" to "COM1"
+
+ <dmoseley@cygnus.com>
+ * main.tcl: (run_executable): Added code to test for app_running.
+ If the app has been started and the user requests a "run", then
+ we must redownload to ensure that the global initialized data is
+ handled properly.
+ * download.tcl: (download_it): See above note.
+
+ Sean Mahan <smahan@cygnus.com>
+ * toolbar.tcl (create_menu_items): changed "Tutorial" to "Cygnus
+ Foundry Tour" in the Help menu.
+
+ Tom Tromey <tromey@cygnus.com>
+ * memory.tcl (mem_del): "destroy forget" is invalid; use "destroy"
+ instead.
+ * interface.tcl (gdbtk_tcl_query): Only ask each question once.
+
+ Martin M. Hunt <hunt@cygnus.com>
+ * manage.tcl (manage_init): Initialize new global
+ _manage_enabled_flag to 1.
+ (manage_disable_all): Only disable if
+ _manage_enabled_flag is 1.
+ (manage_enable_all): Only enable if _manage_enabled_flag
+ is not 1.
+
+ Martin M. Hunt <hunt@cygnus.com>
+ * manage.tcl (manage_iconify): Check for toplevel
+ of "." before doing anything.
+ * main.tcl (set_target_name): Use "pref getd" in
+ case port is undefined.
+
+ Keith Seitz <keiths@onions.cygnus.com>
+ * toolbar.tcl (GDBToolBar::constructor): Add appropriate idle, busy, and
+ no-inferior hooks for this class.
+ (create_buttons): Add all buttons to two lists so we can disable or enable
+ them according to the inferior's run state.
+ (create_menu_items): Same with the menus.
+ * srcbar.tcl (create_buttons): Add all buttons to two lists so we can disable
+ or enable them according to the inferior's run state.
+ (create_menu_items): Same with the menus.
+ (_set_run): Don't do anything to disable UI elements: the idle, busy, and
+ no_inferior hooks will take care of it.
+ (_set_runstop): Don't do anything to disable UI elements: the idle, busy, and
+ no_inferior hooks will take care of it.
+ * manage.tcl (manage): Add two new manage protocols: enable_all and
+ disable_all.
+ (manage_disable_all): New procedure to disable window manager functions
+ such as window deletions.
+ (manage_enable_all): New procedure to undo any changes made by
+ manage_disable_all.
+ (_manage_set_property): New helper procedure for above.
+ (manage_init): Install this module's idle, busy, and no_inferior hooks.
+ * src.tcl (SrcWin::constructor): Add new no_inferior hook.
+ (disable_ui): New procedure to disable ui elements.
+ (enable_ui): New procedure to enable_ui elements.
+ (no_inferior): New procedure to reset GUI.
+ (SrcWin::Running): New protected variable. A fencepost for the above
+ hooks.
+ (do_popup): Use above fencepost.
+ (showBalloon): Use above fencepost.
+ * main.tcl: Define new hook " gdb_no_inferior_hook".
+
+ Martin M. Hunt <hunt@cygnus.com>
+ * src.tcl (SrcWin): Immediately set title name
+ to "Debugger".
+
+ Martin M. Hunt <hunt@cygnus.com>
+ * download_pref.tcl (LoadPref): Make window transient.
+
+ Martin M. Hunt <hunt@cygnus.com>
+ * register.tcl (build_win): Set scrollbars to auto
+ on Unix.
+ * stack.tcl (build_win): Set scrollbars to auto
+ on Unix.
+ * memory.tcl (build_win): Restore proper resize
+ functioning on Unix.
+ * bp.tcl (build_win): Fix problem with merging Tom's
+ sizebox change. Fix Tom's change so scrollbars aren't
+ always on on Unix, at least.
+ * interface.tcl (gdbtk_pc_changed): Called from GDB when
+ the PC is changed with a "set $pc" command.
+ (gdb_show_command, gdb_args, gdb_stack_trace,
+ gdb_docstring,gdb_stack_depth, gdb_stack_frame): Removed.
+
+ Martin M. Hunt <hunt@cygnus.com>
+ * memory.tcl (destructor): Destroy memory prefs window
+ if one exists.
+ (create_prefs): Make prefs window transient.
+ * util.tcl (freeze): Make keep_raised an option.
+
+ Martin M. Hunt <hunt@cygnus.com>
+ * ide.tcl (receive_file_changed): Ignore object file
+ changes. On source file changes, put up a messagebox
+ warning the user. Change both messageboxes to be system
+ modal, which seems to just mean they will be on top.
+
+ Martin M. Hunt <hunt@cygnus.com>
+ * download.tcl (download_it): Reset download_cancel flag.
+ * src.tcl: Create "tagtype" as a protected variable
+ containing the current tag mode; PC, BROWSE, or STACK.
+ Change all functions to use it.
+ (mode): Fix problem with changing modes
+ while browsing stack functions.
+ (name): Add good filenames to the combobox history.
+ (SrcWin): Turn off automatic history in name combobox.
+ (file): If filename is not found, but is part of sources,
+ put it in combobox followed by "(not found)"
+ (location): Reorder and restructure this function to
+ be more robust when files cannot be found or mode changes
+ are required. When stack browsing, highlight PC if it is
+ in the displayed area, and fix the off-by-1 problem
+ with PCs saved on the stack.
+ (update): Use lassign and new tagtype variable.
+ (set_execution_status): Change message formats for MIXED
+ and SRC+ASM modes.
+ (mode): Update toolbar and mode display before calling
+ location. Use tagtype so tag mode is preserved.
+ * bp.tcl (bp_type): Deselect line before changing its
+ type.
+
+ Tom Tromey <tromey@cygnus.com>
+ * bp.tcl (build_win): Use built-in sizebox of tixScrolledWindow.
+ * watch.tcl (console): Set Sizebox to 0.
+ * memory.tcl (build_win): Use built-in sizebox of
+ tixScrolledWindow.
+ * stack.tcl (build_win): Use built-in sizebox of
+ tixScrolledWindow.
+ * locals.tcl (build_win): Don't create sizebox.
+ * variables.tcl (build_win): Use built-in sizebox of
+ tixScrolledWindow.
+ (Sizebox): New instance variable.
+ * console.tcl (console): Use built-in sizebox of
+ tixScrolledWindow.
+ * register.tcl (build_win): Use built-in sizebox of
+ tixScrolledWindow.
+
+ Martin M. Hunt <hunt@cygnus.com>
+ * main.tcl (set_target_name): Set port based on target
+ name.
+ (set_baud): Set baud rate based on target name.
+ * srcbar.tcl: Change shortcuts to use () instead of <>.
+ * download.tcl (download_it): Set download_verbose
+ based on target name.
+ * src.tcl (build_win): Set height to 0 for name and
+ function comboboxes.
+ (location): In IDE, use vmake/source-files property
+ to fill name combobox.
+
+ Keith Seitz <keiths@onions.cygnus.com>
+ * variables.tcl (build_win): Set the variable window's
+ default size to 40 chars.
+
+ Martin M. Hunt <hunt@cygnus.com>
+ * src.tcl (set_state): When loaded state changes,
+ set program_has_run state to 0.
+
+ Martin M. Hunt <hunt@cygnus.com>
+ * src.tcl (set_status): Rewrite to handle temporary
+ status messages.
+ (set_execution_status): New function. Put a message
+ about the current program status in the status bar.
+ (trace_help): New function. Trace on changing ballon
+ help messages. Write them in the status bar.
+ * main.tcl (set_target): Comment out changing cursor.
+
+ Martin M. Hunt <hunt@cygnus.com>
+ * variables.tcl (changeValue): Trim string before
+ comparing with "".
+
+ Keith Seitz <keiths@onions.cygnus.com>
+ * console.tcl (constructor): Set no wrap mode.
+ * src.tcl (SrcWin::name): Make sure we ask gdb where the source file
+ is before asking the source window to open it.
+ (SrcWin::file): Do not ask gdb where the file is -- someone else
+ already has. Set the file selector to the filename only once and
+ only if successful finding the file.
+ (SrcWin::location): Add flag idicating that a file load has failed.
+ Resolves recursive loop with SrcWin::mode and SrcWin::location.
+ Make sure the file and function selectors are filled only once.
+ (SrcWin::mode): Add error flag to indicate that a file load failed.
+ Resolves recursive loop with SrcWin::location.
+ Make sure we exit with the proper mode set on the source window.
+ (SrcWin::current_addr): Define a default value of 0x0.
+ * console.tcl (invoke): Use new gdb_immediate command instead of
+ gdb_cmd.
+ (insert): Add all errors to the end of the text widget.
+ Send errors to end of text widget, not insertion pt.
+ (einsert): Send errors to end of text widget, not insertion pt.
+ * interface.tcl (gdbtk_tcl_readline_begin): Insert message into
+ command window so that the user sees messages like "Enter commands,
+ one per line. Enter 'end' when finished."
+ * main.tcl: Initialize gdbtk_state(readline).
+
+ Tom Tromey <tromey@cygnus.com>
+ * manage.tcl (manage_open): Force focus onto toplevel.
+ * mem_pref.tcl (build_win): Don't put <Return> binding on
+ toplevel; instead put focus on OK button.
+
+ Martin M. Hunt <hunt@cygnus.com>
+ * main.tcl (set_target_name): Replace "com1" with
+ the port name we really want to use.
+ * bp.tcl (build_win): Use place manager for sizebox
+ so it doesn't go away when window is resized.
+ * stack.tcl (build_win): Fix stack window.
+ * memory.tcl: Back out previous changes.
+ * locals.tcl (build_win): Use place manager for sizebox
+ so it doesn't go away when window is resized.
+
+ Tom Tromey <tromey@cygnus.com>
+ * mem_pref.tcl (build_win): Make OK button default.
+ * ide.tcl (gdbtk_ide_init): Set gdb_pretty_name. Track changes to
+ target-pretty-name property.
+ * src.tcl (update_title): Display pretty name for target.
+ * main.tcl (set_target): Display pretty name for target.
+ (gdb_pretty_name): New global.
+ * ide.tcl (target_pretty_name_changed): New proc.
+ (receive_file_changed): Display pretty name for target.
+ * download.tcl (download_it): Display pretty name for target.
+ (console): Likewise.
+
+ Thomas Hudson <thudson@cygnus.com>
+ * bp.tcl (build_win): Added frame and sizebox to bottom.
+ Returned geometry management to previous packing style
+ and window layout.
+ * stack.tcl (build_win): ditto
+ * memory.tcl (build_win): ditto
+ * watch.tcl (build_win): ditto
+ * locals.tcl (build_win): ditto
+
+ Martin M. Hunt <hunt@cygnus.com>
+ * manage.tcl (manage_iconify): Catch iconify command.
+ * download.tcl (download_it): If set_target fails,
+ set gdb_downloading to 0 and return.
+ * main.tcl (set_target): Handle target command timeouts.
+ Pop up messagebox. Set cursor to "watch". Set title
+ on source window. Return 0 on error.
+
+ Martin M. Hunt <hunt@cygnus.com>
+ * manage.tcl (manage_find): Fix to return a list of windows.
+ * console.tcl (Console): Fix sizebox so it doesn't create
+ a whole blank line and it doesn't mess up Unix.
+ * register.tcl (build_win): Change "Show" to "Display".
+
+ Tomy Hudson <thudson@cygnus.com>
+ * console.tcl (build_win) Added frame and ide_sizebox to
+ bottom of window.
+ * stack.tcl (build_win) Added frame and ide_sizebox to
+ bottom of window.
+ * watch.tcl (build_win) Added frame and ide_sizebox to
+ bottom of window.
+ * locals.tcl (build_win) Added frame and ide_sizebox to
+ bottom of window.
+
+ Tom Tromey <tromey@cygnus.com>
+ * memory.tcl (build_win): Updated -underline values.
+
+ Martin M. Hunt <hunt@cygnus.com>
+ * memory.tcl (init_addr_exp): New function. Set the
+ initial address expression to the location of .data
+ if it is defined. Otherwise use $pc.
+
+ Tom Tromey <tromey@cygnus.com>
+ * bp.tcl (build_win): Changed packing so content fills window.
+ Removed `g' and `a' frames. Changed gridding on labels.
+ (bp_add): Changed gridding on new entries.
+ * memory.tcl (build_win): Put spaces in front of all menu labels.
+
+ Martin M. Hunt <hunt@cygnus.com>
+ * download.tcl (download_it): Change error to messagebox.
+
+ Tom Tromey <tromey@cygnus.com>
+ * register.tcl (reg_display_list): Initialize to empty list.
+ (init_reg_display_vars): Don't unset reg_display_list; set it to
+ empty list.
+ (delete_from_display_list): Likewise.
+
+ Martin M. Hunt <hunt@cygnus.com>
+ * ide.tcl (ide_run_server, ide_do_run_server): Take
+ an optional argument to indicate if program should be
+ run or simply downloaded.
+ * console.tcl (Console): Enable scrollbars in both
+ directions.
+ * main.tcl: Moved keep_raised, sleep, and toggle_debug_mode
+ to util.tcl.
+ (set_exe): If exe changed, set gdb_target_changed
+ to force new target command to be sent.
+ (set_target_name): Check to see if gdb_target_changed.
+ (run_executable): If exe or target changed, set gdb_loaded to
+ 0, forcing a new download. If download only, try to
+ display function main in source window.
+ * util.tcl: New file.
+ * hooks.tcl: Removed. Use version in libide.
+ * Makefile: Add util.tcl.
+ * download.tcl (Download): Call freeze to make modal window.
+ (_map): Deleted.
+ (download_it): Call set_baud, then set_exe then set_target.
+ * mem_pref.tcl (build_win): Set default number of bytes
+ to 128.
+ * memory.tcl (build_win): Enable horizontal scrollbar
+ when in resize mode. Anchor to top-left. Use "nb" to
+ count actual number of bytes displayed, instead of "numbytes"
+ which will be 0 when in resize mode.
+ (delete_prefs): Deleted.
+ * src.tcl (mode): Update mode combobox with new mode name.
+ (location): In SRC+ASM mode if we step into a function without
+ source code, unhighlight everything in the source pane and let
+ the assembly pane show our current location.
+ (build_win): Enable scrollbars in both directions.
+ (set_state): Call update_title.
+ (update_title): Don't set title if the target or exe has changed.
+ (trace_variable): Couldn't figure out what this did that
+ could be useful so delete it and everything that references it.
+ * watch.tcl: Add description and copyright.
+ * variables.tcl, interface.tcl, locals.tcl: Add copyright.
+ * prefs.tcl, register.tcl: Add copyright.
+
+ Tomy Hudson <thudson@cygnus.com>
+ * register.tcl (reg_select_): Modified reg_select_* movement
+ methods to use the register display list instead of
+ a straight index.
+
+ Tomy Hudson <thudson@cygnus.com>
+ * register.tcl (unedit): Changed input focus to $ScrolledWin.$Editing
+ in unedit. This allows arrow and tab key bindings to work
+ after an edit.
+
+ Tomy Hudson <thudson@cygnus.com>
+ * register.tcl (build_win): Added key bindings and support
+ for tab and arrow keys, including four new methods;
+ reg_select_up,reg_select_down, reg_select_left, reg_select_right
+ * register.tcl (build_win): Added spacing frame and ide_sizebox
+ to window. Changed geometry manager to grid.
+
+ Martin M. Hunt <hunt@cygnus.com>
+ * stack.tcl (update): Only insert entries that have
+ length. Break when matching entry in listbox is found.
+ * src.tcl (config_win): Fix control-v binding so
+ it doesn't paste on Windows. Cancel <Delete>
+ binding.
+
+ Martin M. Hunt <hunt@cygnus.com>
+ * src.tcl (build_win): Force focus from toplevel
+ down to text window.
+ (mode): Restructure code to be clearer. Set focus
+ when done.
+
+ Tomy Hudson <thudson@cygnus.com>
+ * src.tcl (mode): Modified key bindings for MIXED mode
+ to be the same as ASSEMBLY mode
+
+ Martin M. Hunt <hunt@cygnus.com>
+ * manage.tcl (manage_init): set bp-save to 1.
+ * variables.tcl (changeValue): If new value is null,
+ cancel edit.
+
+ Tomy Hudson <thudson@cygnus.com>
+ * memory.tcl (do_popup): Added method do_popup. Changed binding of
+ button-3 to invoke popup menu.
+
+ Tomy Hudson <thudson@cygnus.com>
+ * src.tcl (do_popup): Removed check for space in variable name
+ that disabled popup menu items. Only check now is for "".
+
+ Tomy Hudson <thudson@cygnus.com>
+ * src.tcl (do_popup): Removed variable name from
+ popup menu items. Added check for sane variable in selection
+ to disable menu items when appropriate.
+
+ Martin M. Hunt <hunt@cygnus.com>
+ * bp.tcl (bp_delete): Destroy widgets in deleted
+ line.
+ * srcbar.tcl (_set_run): Enable View menu items
+ when download is finished.
+ * download_pref.tcl (LoadPref): Call loadprefs
+ with gdbrunning set to 1.
+
+ Tom Tromey <tromey@cygnus.com>
+ * ide.tcl (gdbtk_ide_init): Use property vmake/exelist, not
+ vmake-exelist.
+
+ Martin M. Hunt <hunt@cygnus.com>
+ * variables.tcl (build_menu_helper): Comment-out
+ Update menu.
+ (getVariables): Change variable name so it doesn't
+ get confused with window variables.
+ (postMenu): Comment-out Update entries.
+ (UnEdit): Unbind keys when unediting.
+ * memory.tcl (create_prefs): When prefs are already
+ open, raise and focus the window.
+ * bp.tcl (bp_type): Deselect current line when type changes.
+
+ Martin M. Hunt <hunt@cygnus.com>
+ * toolbar.tcl (create_menu_items): Call open_url for
+ web connections.
+ * src.tcl (name): When new file load fails, remove it
+ from combobox. When load succeeds, clear status message.
+ (location): Change how files are loaded into combobox.
+ Call new gdb_listfiles function.
+
+ Martin M. Hunt <hunt@cygnus.com>
+ * manage.tcl (manage_create): Give newly created windows
+ the focus on all platforms.
+ * mem_pref.tcl (destructor): Notify parent when exiting.
+ * srcbar.tcl (_set_run): Better state handling on
+ pulldowns and icons.
+ * src.tcl (build_win): Start with toolbar in right state.
+ * memory.tcl (MemWin): Withdraw window until finished.
+ (delete_prefs): New function.
+
+ Martin M. Hunt <hunt@cygnus.com>
+ * manage.tcl: For IDE, iconify all windows when source
+ window is iconified.
+ * mem_pref.tcl: Take out all the modal stuff.
+ Leave this window non-modal.
+ * download.tcl: Fix references to source window.
+ (Download): Make window modal and always on top.
+ * memory.tcl (destructor): Kill mem prefs window too.
+ * variables.tcl (changeValue): Clean up.
+ * register.tcl (acceptEdit): Change error messagebox.
+
+ Martin M. Hunt <hunt@cygnus.com>
+ * src.tcl (set_state): Disable items in breakpoint
+ popups.
+ (config_win): Change capitalization in popups.
+
+ Martin M. Hunt <hunt@cygnus.com>
+ * main.tcl: Major rewrite. Simplify. Move IDE
+ functions to new file. Add state variables and
+ hooks. Add copyright.
+ * ide.tcl: New file. IDE functions.
+ * download.tcl (download_it): Use new state variables.
+ * src.tcl: Use new state variables.
+ (constructor): Add state hook.
+ (set_state): Hook to enable/disable menus and icons.
+ * srcbar.tcl (runstop): Renamed from "running"
+ (running): Public variable to control icons.
+ (_set_runstop): Change Running man to stop sign.
+ (_set_run): Enable/disable icons depending on debugger
+ state.
+ * manage.tcl (create_closed): Deleted function.
+ (manage_create): Remove visibility argumnet.
+ (manage_delete): Remove special case for debugger prefs.
+ * prefs.tcl (pref_set_defaults): Remove gdb/advanced.
+ * hooks.tcl: Add copyright.
+ * Makefile: Add ide.tcl.
+
+ Tom Tromey <tromey@cygnus.com>
+ * download_pref.tcl (LoadPref): Inherit from GdbLoadPref.
+ (constructor): Rewritten.
+ (build_win): Removed.
+ (change_baud): Removed.
+ (save): Removed.
+ (cancel): Removed.
+ (config): Removed.
+ (reconfig): Removed.
+
+ Martin M. Hunt <hunt@cygnus.com>
+ * main.tcl (target_name_changed): Append correct
+ port name to target name.
+ (gdbtk_ide_init): Don't initialize IDE preferences.
+ Append port name to target name.
+ * toolbar.tcl (create_menu_items): Add Debugger Preferences
+ to File menu.
+ * pref.tcl: Remove all ide preferences functions.
+ * prefs.tcl (pref_set_defaults): Define gdb/load/port.
+ * download_pref.tcl: Added serial port selection.
+
+ Martin M. Hunt <hunt@cygnus.com>
+ * register.tcl (acceptEdit): Remove leading spaces from
+ values.
+ * src.tcl (config_win): New tag bp_tag. Like break_tag
+ except used when a bp is set on that line. Bind new menu
+ to bp_tag.
+ (insertBreakTag): Accept tag type. Remove old tag.
+ (do_bp): When a breakpoint is set, use bp_tag.
+
+ Tom Tromey <tromey@cygnus.com>
+ * pref.tcl (pref_ide_proc): Withdraw the toplevel, not the
+ window.
+
+ Tom Tromey <tromey@cygnus.com>
+ * tclIndex: Rebuilt.
+ * mem_pref.tcl (build_win): Use standard_button_box.
+ (_map): New method.
+ (constructor): Run _map on <Map> event.
+ * pref.tcl (pref_ide_proc): Use idewindow_check_freeze.
+ (pref_modal_dialog): Use idewindow_freeze and idewindow_thaw.
+ * hooks.tcl: Removed.
+ * Makefile (TCL): Removed hooks.tcl.
+
+ Tom Tromey <tromey@cygnus.com>
+ * main.tcl (ide_run_server): Quote call to ide_do_run_server.
+
+ Tom Tromey <tromey@cygnus.com>
+ * download_pref.tcl (build_win): Make OK button default. Invoke
+ when Return pressed.
+ * download_pref.tcl (build_win): Don't allow pref window to
+ resize. Use standard_button_box to lay out buttons.
+ * pref.tcl (pref_ide_proc): Handle window freezing.
+ (pref_modal_dialog): Freeze and thaw window around the grab.
+ (build_win): Use standard_button_box to lay out buttons. Don't
+ allow pref window to resize.
+
+ Ian Lance Taylor <ian@cygnus.com>
+ * src.tcl (src_ide_proc): Download the file in an idle callback.
+ Execute the idewindow command even if the download was cancelled.
+ * library/main.tcl (ide_run_server): Do everything in an idle
+ callback.
+ (ide_do_run_server): New procedure.
+
+ Martin M. Hunt <hunt@cygnus.com>
+ * src.tcl (bp_line): Use hasBP instead of validBPLine.
+ Allow type TC even if BP set.
+ (validBPLine): Renamed to hasBP.
+
+ Tom Tromey <tromey@cygnus.com>
+ * manage.tcl (manage_open): Special case "about" window when
+ running under IDE.
+
+ Martin M. Hunt <hunt@cygnus.com>
+ * main.tcl (set_target): Set the target again if the
+ executable has changed and executed a "file" command.
+ * memory.tcl (update_address): Accept numerical entries
+ and catch errors.
+ * download.tcl (Download): Cancel button should call
+ cancel method.
+ * main.tcl (run_executable): Fixed messageBox.
+
+ Tom Tromey <tromey@cygnus.com>
+ * floatbar.tcl (constructor): Added.
+ * srcbar.tcl (constructor): Added.
+ * toolbar.tcl (_ide_title): New instance variable.
+ (create_menu_items): Pass _ide_title to idewindmenu.
+
+ Martin M. Hunt <hunt@cygnus.com>
+ * main.tcl (toggle_debug_mode): Fix typo and print
+ debug message before disabling it.
+
+ Martin M. Hunt <hunt@cygnus.com>
+ * manage.tcl (manage_delete): Don't remove a window
+ from the active list until after it has already deleted
+ itself.
+ * toolbar.tcl (create_menu_items): Change Console shortcut
+ to Ctrl+N.
+ * src.tcl (config_win): Change Console shortcut to Ctrl+N.
+
+ Martin M. Hunt <hunt@cygnus.com>
+ * src.tcl: (do_bp): Catch errors.
+ (validBPLine): Valid lines have a "-" or an image.
+
+ Martin M. Hunt <hunt@cygnus.com>
+ * main.tcl (ide_run_server): Don't run executable if
+ download was cancelled. Reset cancelled flag.
+ (run_executable): Call download_it.
+ (download): Renamed download_it and moved to download.tcl.
+ (set_target): Don't set target if the name hasn't changed
+ from the last time.
+ * register.tcl (reg_select): Catch errors.
+ (delete_from_display_list): Enable menu item.
+ * src.tcl (build_win): Add progress bar for downloads.
+ (download_progress): New function. Callback to update
+ progress meter.
+ (src_ide_proc): Don't open src window if download
+ cancelled.
+ * toolbar.tcl (create_menu_items): Call download_it.
+ * srcbar.tcl (_set_run): New mode. Sets run button to stop
+ sign during downloads.
+ * prefs.tcl (pref_set_defaults): Define gdb/load/verbose.
+ * interface.tcl: Define new hook download_progress_hook.
+ * floatbar.tcl (create_buttons): Call download_it.
+ * download_pref.tcl: Add download dialog prefs.
+ * download.tcl (Download): Change back to old dialog
+ with each section listed seperately.
+ (download_hash): Use a hook.
+ (download_it): New function. Replaces old "download"
+ from main.tcl. Now deletes all breakpoints before
+ downloading and handles cancels correctly.
+
+ Martin M. Hunt <hunt@cygnus.com>
+ * main.tcl (download): Don't quote the executable name
+ with single quotes.
+
+ Tom Tromey <tromey@cygnus.com>
+ * src.tcl (src_ide_proc): Exit gdb when destroy request seen.
+
+ Ian Lance Taylor <ian@cygnus.com>
+ * main.tcl (gdbtk_ide_init): Use src_ide_proc for the source
+ window, rather than idewindow_proc. Remove extraneous line.
+ * src.tcl (src_ide_proc): New procedure, replacing open_src. Only
+ download if we are opening the source window.
+ (src_no_save): New procedure.
+ * main.tcl (gdbtk_ide_init): Initialize gdb_checking_for_exit.
+ Register gdb_exit_check as the exit check procedure.
+ (gdb_exit_check): New procedure.
+ * interface.tcl (gdbtk_tcl_query): If gdb_checking_for_exit, use a
+ system modal message box.
+ * src.tcl (build_win): Create a FocusIn binding to push focus down
+ from the top level.
+ * console.tcl: Change all control, alt, and unadorned character
+ bindings to use bind_plain_key.
+ * memory.tcl: Likewise.
+ * src.tcl: Likewise.
+ * variables.tcl: Likewise.
+ * src.tcl: Use bind_plain_key rather than explicitly ignoring Alt
+ bindings.
+ * src.tcl (print): Call idewindow_freeze and idewindow_thaw around
+ call to print menu.
+ * srcbar.tcl (create_menu_items): Likewise, around call to page
+ setup menu.
+ * main.tcl (gdbtk_ide_init): Use an underscore in generic window
+ name, to set the accelerator key.
+ (ide_run_server): Likewise.
+ * toolbar.tcl (create_buttons): Likewise.
+
+ Martin M. Hunt <hunt@cygnus.com>
+ * register.tcl (acceptEdit): If no value is entered,
+ set the cell to 0.
+
+ Ian Lance Taylor <ian@cygnus.com>
+ * src.tcl (config_win): Add ignored Alt bindings for all the
+ unmodified key bindings.
+ * download.tcl (constructor): Withdraw the window before doing
+ anything. Set the width of the label. Don't try to center the
+ window. Pass toplevels to wm transient. Run keep_raised after
+ 500. Don't call update.
+ (done): Use after rather than a busy loop.
+ (destructor): Cancel the after if it is defined.
+ (after_id): New protected variable.
+ * main.tcl (download): If download is already running, don't do
+ anything. If .load0.load exists, delete it before calling manage
+ create.
+ * main.tcl (gdbtk_ide_init): Use pref_ide_proc rather than
+ idewindow_proc when registering the preference window.
+ * download_pref.tcl (save, cancel): Call pref_ide_finished.
+ * pref.tcl (save, cancel): Likewise.
+ (pref_ide_proc): New procedure.
+ (pref_no_save): New procedure.
+ (pref_modal_dialog): New procedure.
+ (pref_ide_finished): New procedure.
+ * tclIndex: Rebuild.
+ * main.tcl (gdbtk_ide_init): Initialize gdb_download_cancelled.
+ (run_executable): Put a trace on gdb_download_cancelled. Change
+ the dialog box message. If the user cancels the download, clear
+ gdb_run_pending and just return without running.
+ (ide_do_run): Remove the traces on gdb_download_cancelled. If the
+ user cancelled the download, just clear gdb_run_pending.
+ (target_name_changed): Clear gdb_download_cancelled. Call
+ set_exe_name.
+ (download): If the executable is not up to date, ask whether the
+ user is really really sure. If the user cancels the download
+ using the dialog button, set gdb_download_cancelled, and don't set
+ the breakpoints or gdb_download_complete.
+ (set_exe_name): Clear gdb_download_cancelled.
+ (receive_file_changed): Ask whether we should download the new
+ executable.
+ * src.tcl (open_src): Don't download the file if
+ gdb_download_cancelled is set.
+ * interface.tcl (gdbtk_tcl_query): Pass -modal task to
+ tk_messageBox.
+ * main.tcl (set_exe_name): Tell the src window to go back to
+ looking at main if the file changes.
+ * src.tcl (update): Catch errors when calling gdb_loc.
+ * main.tcl (gdbtk_ide_init): Handle file-created, file-changed,
+ file-removed, and file-deleted events rather than process-ended
+ events.
+ (set_exe_name): Call gdb_clear_file even if the file does not
+ exist. Likewise for setting gdb_download_complete to zero.
+ (receive_file_changed): Rename from receive_process_ended. Only
+ check the executable mtime if the tail of the file name matches
+ the executable name.
+
+ Ian Lance Taylor <ian@cygnus.com>
+ * srcbar.tcl (create_menu_items): Change ``Print Setup...'' to
+ ``Page Setup...''. Pass -parent to ide_winprint page_setup.
+ * src.tcl (print): Pass -parent to send_printer.
+
+ Ian Lance Taylor <ian@cygnus.com>
+ * main.tcl: Move initialization code to end of file, after all
+ procedures have been defined.
+ (gdbtk_ide_init): New procedure to handle IDE initialization.
+ (gdbtk_tcl_preloop): Don't do anything if using the IDE.
+ (ide_run_server): Error if file does not exist. Use
+ idewindow_activate_by_name, rather than manage open. Do
+ everything after idle.
+ (run_executable): Clean up a bit. Consistently use ide_do_run.
+ (target_name_changed): Rename from target_name. Rename parameter
+ num to propset.
+ (download): Error if the file does not exist. Call set_exe_name.
+ Don't set gdb_download_mtime. Don't check whether gdb_run_pending
+ is 2.
+ (exe_name_changed): Rename from exe_name.
+ (set_exe_name): Set gdb_exe_mtime. Quote filename passed to
+ gdb_cmd.
+ (receive_process_ended): Don't check the data argument. Check
+ gdb_exe_set rather than gdb_download_complete. Check
+ gdb_exe_mtime rather than gdb_download_mtime.
+ * src.tcl (open_src): Set the location to main as well as
+ downloading the file. Don't set gdb_run_pending to 2.
+
+
+Tue Feb 10 17:50:37 1998 Keith Seitz <keiths@onions.cygnus.com>
+
+ * bp.tcl (build_win): Do not set the disabled foreground for menus. Insert
+ all tracepoints, too.
+ (bp_add): Handle tracepoints.
+ (bp_type): Handle tracepoints.
+ (update): Handle tracepoints.
+ (bp_all): Do tracepoints, too.
+ (Index_to_bptype): New protected variable to index type of break (breakpoint
+ or tracepoint) against index in window.
+ (bp_select): Disable/Enable menu items based on type.
+ (bp_able): Handle tracepoints.
+
+ * src.tcl (do_bp): Handle disabled tracepoints.
+
+ * actiondlg.tcl (change_other): Handle memranges and use info address to
+ validate entries.
+
+ * tracedlg.tcl (edit): Handle memranges when formatting data for
+ action dialog.
+
+Mon Jan 26 11:44:39 1998 Keith Seitz <keiths@onions.cygnus.com>
+
+ * src.tcl (fill_files): Don't check for file's existance -- let
+ SrcWin::name do that.
+
+ * actiondlg.tcl (change): Add everything that is specified, not
+ just the things about which we know.
+
+Sun Jan 25 01:01:32 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * stack.tcl (update): Only insert entries that have
+ length. Break when matching entry in listbox is found.
+
+ * src.tcl (fill_files): Don't call lsort. New listfiles
+ command sorts for us.
+
+ * variables.tcl (changeValue): If new value is null,
+ cancel edit.
+ (build_menu_helper): Comment-out Update menu.
+ (getVariables): Change variable name so it doesn't
+ get confused with window variables.
+ (postMenu): Comment-out Update entries.
+ (UnEdit): Unbind keys when unediting.
+
+Thu Jan 22 10:38:19 1998 Keith Seitz <keiths@cygnus.com>
+
+ * toolbar.tcl (create_menu_items): Disable preferences.
+
+ * prefs.tcl (pref_set_defaults): Attach the toolbar to the source window
+ by deafult.
+ * src.tcl (SrcWin::build_win): Turn off history for the file selector.
+ (SrcWin::name): Use SOURCEWIN_set_status to upate status.
+ Make sure we ask gdb where the source file is before asking
+ the source window to open it.
+ (SrcWin::file): Do not ask gdb where the file is -- someone else already has.
+ Set the file selector to the filename only once and only if
+ successful finding the file.
+ (SrcWin::fill_files): Sort the files before inserting into file selector.
+ (SrcWin::location): Add flag idicating that a file load has failed. Resolves
+ recursive loop with SrcWin::mode and SrcWin::location.
+ Make sure the file and function selectors are filled only once.
+ Use SOURCEWIN_set_status and SOURCEWIN_reset_status as appropriate.
+ (SrcWin::set_status): Add verbatim flag to allow a generic message to be
+ displayed.
+ (SrcWin::mode): Add error flag to indicate that a file load failed. Resolves
+ recursive loop with SrcWin::location.
+ Make sure we exit with the proper mode set on the source window.
+ (SrcWin::reset_status): New procedure.
+ (SrcWin::current_addr): Define a default value of 0x0.
+ (SrcWin::Status): New protected variable.
+ (SrcWin::bp_line): Check if breakpoint set in assembly-mode, too.
+ (SOURCEWIN_set_status): New procedure to temporarily set the status bar.
+ (SOURCEWIN_reset_status): New procedure which is called after the status bar
+ should be reset.
+ (SOURCEWIN_reinit): New procedure to reinitialize the source window. (To be
+ called when new symbol files are added and like).
+
+ * interface.tcl (gdbtk_tcl_query): Properly set the name of the
+ query dialog.
+ (gdbtk_tcl_pre_add_symbol): Hook called from gdbtk.c to inform user that
+ we are reading symbols.
+ (gdbtk_tcl_post_add_symbol): Hook called from gdbtk.c to inform user that
+ are finished reading symbols.
+
+ * src.tcl (SOURCEWIN_reinit): New procedure which updates the source window with
+ a default file, fills the file selectors, etc.
+ (SOURCEWIN_set_status): New procedure which can be used to set the status bar
+ on the source window.
+ (set_status): Add flag for setting the status as-is.
+
+ * main.tcl: Call SOURCEWIN_reinit to setup the source window on startup.
+
+
+Fri Jan 16 09:11:30 1998 Keith Seitz <keiths@onions.cygnus.com>
+
+ * src.tcl (SOURCEWIN_set_status): New procedure to allow anyone to set the
+ status bar text at the bottom of the source window.
+ (fill_files): Use a little more full-proof method (if slower) for eliminating
+ duplicates int the files combobox.
+
+ * interface.tcl (gdbtk_tcl_pre_add_symbol): New procedure called prior to
+ a symbol file is loaded.
+ (gdbtk_tcl_post_add_symbol): New procedure called after a symbol file is
+ loaded.
+
+Thu Jan 15 12:41:27 1998 Keith Seitz <keiths@onions.cygnus.com>
+
+ * console.tcl (invoke): Use new gdb_immediate command instead of gdb_cmd.
+
+Wed Dec 31 16:50:26 1998 Keith Seitz (keiths@onions.cygnus.com)
+
+ * actiondlg.tcl (change): handle '$' in register names.
+
+Wed Dec 10 13:17:21 1997 Keith Seitz <keiths@onions.cygnus.com>
+
+ * src.tcl (file): Insert tracepoint dots into the source window, too.
+
+ * tracedlg.tcl (build_win): Add an update to workaround a Tix/Tk bug when
+ mapping the dialog under X.
+
+ * console.tcl (insert): Add all errors to the end of the text widget.
+ (einsert): Send errors to end of text widget, not insertion pt.
+ (invoke): Send errors to end of text widget, not insertion pt.
+
+ * interface.tcl (gdbtk_tcl_readline_begin): Insert message into
+ command window so that the user sees messages like "Enter commands, one
+ per line. Enter 'end' when finished."
+
+ * actiondlg.tcl (change_other): Clear the entry on <Return>.
+ Add fencepost to avoid manipulating collect list twice which
+ could otherwise have undesired side effects.
+ Add some validation test for typed-in entries.
+ (ok): Call change_other to check the "Other" entry widget when the
+ dialog is dismissed.
+ (change): fix typo
+
+Mon Dec 8 15:07:51 1997 Keith Seitz <keiths@onions.cygnus.com>
+
+ * tracedlg.tcl (get_data): New method which gets the data associated
+ with an action.
+ (add_all_actions): Use the new get_data method.
+
+ * actiondlg.tcl (get_selections): Add "declaration" for i so that
+ its scope is not limited to for loop.
+
+Fri Dec 5 10:01:24 1997 Keith Seitz <keiths@pizza.cygnus.com>
+
+ * tracedlg.tcl (build_win): Add support for ranges of lines at which
+ tracepoint should be set.
+ (add_action): With ranges, use actions from first in tracepoint in the
+ range.
+ (ok): Set tracepoints for ranges, asking if it is ok to overwrite
+ any existing ones when necessary. Dismiss the dialog first -- or else
+ it could hang around forever.
+ (edit): With ranges, use actions of the first tracepoint.
+ TraceDlg::Lines: Renamed from TraceDlg::Line.
+ TraceDlg::New: New protected variable (indicates if there are any new
+ tracepoints being set with this dialog).
+ TraceDlg::Exists: New protected variable (indicates if there are any
+ existing tracepoints that may be overwritten -- so ask the user first).
+
+ * src.tcl (fill_files): Use gdb_find_file to test for the existence
+ of a file, not "file exists".
+ (do_popup): Filter the selection a little. If the selection is
+ multi-line selection, enable the tracepoint range option. Don't
+ display "add to watch" for EVERYTHING!
+ (validBPLine): Valid lines can have images on them, too.
+ (bp_line): Fallout of above: check if breakpoint exists before
+ deciding whether to clear it or set it.
+ (getVariable): Sllow LINE to be passed, so others can filter lines, too.
+ (set_tracepoint): Pass TraceDlg a list of lines -- only one line in this
+ case.
+ (tracepoint_range): New function to set tracepoint ranges.
+ (file): Use gdb_find_file to get the real filename.
+
+Wed Nov 26 15:02:43 1997 Keith Seitz <keiths@onions.cygnus.com>
+
+ * balloon.tcl, gettext.tcl: Remove obsolete files.
+
+ * console.tcl (invoke): Remove debug line.
+
+ * src.tcl (update): Remove debug line.
+
+ * prefs.tcl (pref_set_defaults): Turn debug mode off by deafult.
+
+Wed Nov 26 11:30:49 1997 Keith Seitz <keiths@onions.cygnus.com>
+
+ * main.tcl: Initialize gdbtk_state(readline).
+
+ * console.tcl (invoke): Check if we are in readline mode, so that
+ we wait for the user's input and set a global with the result.
+ (activate): Add prompt argument for readline's prompt.
+ (setprompt): Add prompt argument for readline's prompt.
+
+ * interface.tcl (gdbtk_tcl_readline): hack to get readline working
+
+ * lots: Merge with foundry's 11/18/97 build.
+
+ * console.tcl (setprompt): Get prompt from gdb.
+
+ * prefs.tcl (pref_set_defaults): Add tracepoint defaults.
+
+ * interface.tcl (gdbtk_tcl_tracepoint): New function which mimicks
+ gdbtk_tcl_breakpoint.
+
+ * src.tcl (constructor): Set default behavior of left click. Make
+ a tracepoint dot, too.
+ (fill_files): "New" function: ripped out of "location". It fills the
+ 'files' combo box on the bottom of the source window.
+ (location): Use fill_files to fill the files combo box.
+ (do_bp): Add support for tracepoints.
+ (bp_line): Add support for tracepoints.
+ (set_tracepoint): New function to set a tracepoint on a given line.
+ (config_win): Add "Set tracepoint here" to right-click menu.
+
+ * actiondlg.tcl: New file to help with tracepoint data collection actions.
+
+ * tracedlg.tcl: New file to help with tracepoints.
+
+Mon Nov 17 16:49:56 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * src.tcl (config_win): Remove stray character.
+
+Mon Nov 17 16:04:08 1997 Ian Lance Taylor <ian@cygnus.com>
+
+ * main.tcl (startup code: Use the first element from the
+ vmake-exelist list.
+ (exe_name): Likewise.
+ (gdbtk_tcl_preloop): Quote file name passed to file.
+ (download): Quote file name passed to load.
+
+Sun Nov 16 18:21:57 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * bp.tcl (build_win): Change headers to be raised.
+ Change resizing so that the bp grid doesn't change
+ size and is always in the upper left corner. Scrollbars
+ will appear if the window is shrunk too small.
+ (bp_add): Set checkbutton color differently if not
+ on Windows.
+
+ * manage.tcl (manage_init): About title should only
+ have Foundry in it if we are running Foundry.
+
+Fri Nov 14 11:15:29 1997 Jeff Holcomb <jeffh@cygnus.com>
+
+ * manage.tcl (manage_init): About window title is now "About
+ Cygnus Foundry".
+
+ * toolbar.tcl (create_menu_items): Changed "About Foundry
+ Debugger..." menu option to "About Cygnus Foundry...".
+
+Fri Nov 14 00:00:42 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * memory.tcl (toggle_enabled): Toggle the background
+ color when Auto Update is changed.
+
+ * download_pref.tcl (save): New method. Save new
+ defaults.
+
+ * pref.tcl (build_win): Don't delete subwidget.
+ (save): New method.
+
+ * manage.tcl (manage_init): Change preferences title.
+
+ * prefs.tcl (pref_set_defaults): Define gdb/advanced.
+ Used for testing advanced features.
+
+ * src.tcl (build_win): Set min size for top pane.
+ (mode): Set minimum size for pane2 when needed.
+
+ * toolbar.tcl (create_menu_items): Underline the
+ W in "Web", not the "e".
+
+Thu Nov 13 16:07:53 1997 Jeff Holcomb <jeffh@cygnus.com>
+
+ * download.tcl (done): Update window and show the window for
+ at least 3 seconds.
+ (constructor): Initialize start_time and last_num.
+
+Thu Nov 13 18:17:07 1997 Ian Lance Taylor <ian@cygnus.com>
+
+ * main.tcl (ide_run_server): Call run_executable.
+ (run_executable): New procedure, mostly from old ide_run_server.
+ If ! GDBTK_IDE, just execute a run command. In the case where
+ we've already downloaded, don't bother to do the run command after
+ idle. If downloading is not forced, ask whether we should do it.
+ * src.tcl (config_win): Call run_executable, not gdb_cmd run.
+ * srcbar.tcl (_set_run): Likewise.
+ * toolbar.tcl (create_menu_items): Likewise.
+
+ * main.tcl: Initialize gdb_exe_set. If IDE, arrange to receive
+ process-ended events.
+ (gdbtk_tcl_preloop): Don't try to read the file if it doesn't
+ exist.
+ (download): Don't try to download the file if it doesn't exist.
+ Set gdb_download_mtime.
+ (exe_name): Just call set_exe_name.
+ (set_exe_name): New procedure. Like old exe_name, but call
+ gdb_clear_file before running gdb file command, set gdb_exe_set,
+ and run gdb_idle_hook.
+ (receive_process_ended): New procedure.
+
+Thu Nov 13 13:35:32 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * prefs.tcl (pref_set_defaults): Set debug off by default.
+
+ * src.tcl (config_win): Bind Ctrl+P and Ctrl+D.
+ (update_title): Change window titlebar.
+
+ * srcbar.tcl (_set_run): Change balloon help for
+ stop and run icons.
+ (create_menu_items): Add accelerator for Print Source.
+
+ * toolbar.tcl (create_buttons): Change balloon help for
+ project icon.
+ (create_menu_items): Change access keys. Add accelerator
+ for Download.
+
+Thu Nov 13 10:47:04 1997 Jeff Holcomb <jeffh@cygnus.com>
+
+ * download.tcl (constructor): Fix text and button layout.
+ Don't allow resizing.
+
+Wed Nov 12 16:59:17 1997 Jeff Holcomb <jeffh@cygnus.com>
+
+ * download.tcl (constructor): Patch from Ian to redo the
+ download window and also cancel support.
+ (update): Ditto.
+ (done): Ditto.
+ (cancel): New method to handle canceling the download.
+ (download_hash): Cancel support.
+
+Wed Nov 12 13:11:20 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * memory.tcl (build_win): Change "Address" to "Addresses"
+ on menu and add separator.
+
+Tue Nov 11 11:00:25 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * download_pref.tcl (cancel): Must reset combobox
+ because dialog no longer gets deleted.
+
+Tue Nov 11 15:40:36 1997 Tom Tromey <tromey@cygnus.com>
+
+ * toolbar.tcl (create_menu_items): Underline "W", not "C", in
+ "Cygnus on the Web".
+
+Tue Nov 11 11:00:25 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * variables.tcl (edit): Disable menus when in editing mode.
+
+Tue Nov 11 02:00:25 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * variables.tcl (selectionChanged): When selection changes,
+ cancel any editing in progress.
+ (build_win): Set background in text styles.
+ (edit): Set background colors.
+ (UnEdit): Clear selection when done.
+
+Mon Nov 10 12:22:00 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * variables.tcl (build_win): Set background color.
+
+Mon Nov 10 05:30:00 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * about.tcl (build_win): Bind button one to close
+ the window.
+
+ * tclIndex: Rebuilt.
+
+Mon Nov 10 03:00:00 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * download_pref.tcl (build_win): Fix reading of initial
+ baud rate.
+
+ * download.tcl (Download): Call keep_raised.
+
+ * main.tcl (ide_do_run): Catch GDB commands.
+ (ide_run_server): Catch GDB commands.
+ (ide_do_run): Don't set gdb_download_complete to 0.
+ We don't need further downloads unless executable changes
+ or Download is selected from the menubar.
+ (keep_raised): Keep a window on top.
+
+ * src.tcl (config_win): Catch GDB commands.
+
+ * toolbar.tcl (create_menu_items): Catch GDB commands.
+ (create_menu_items): Remove automatic step.
+
+ * srcbar.tcl (_set_run): Catch GDB commands.
+
+ * stack.tcl (build_win): Change background color.
+
+ * bp.tcl: Change background color.
+ (destructor): Remove breakpoint change hook.
+ (bp_type): Fix problem with toggling temp to normal bps.
+ (build_win): Add popup menu.
+
+ * interface.tcl (gdbtk_tcl_query): Change title and type.
+
+Mon Nov 10 00:26:25 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * pref.tcl (build_win): OK button wasn't working.
+
+ * main.tcl: Rework all the "automatic" downloading stuff so
+ it doesn't download and run when only the preferences are
+ being displayed.
+
+ * src.tcl (open_src): Callback from IDE that opens
+ a source window when the bug is clicked on. Starts
+ up automatic download if necessary.
+
+ * tclIndex: Rebuilt.
+
+ * images2/bp.gif, stack.gif, up,gif, down.gif, bottom.gif:
+ Updated icons.
+
+Sun Nov 9 19:30:33 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * main.tcl (gdbtk_tcl_preloop): Remove uneeded if statement.
+ Remove calls to manage get_state.
+
+ * manage.tcl (manage_get_state): Remove.
+ (manage_init): Add save state to several windows.
+ (manage_create): Use ide_property instead of prefs to find window
+ geometry.
+ (manage_delete): Restructure to fix several bugs.
+ (manage_save): Use ide_property instead of prefs. Don't
+ call pref_save.
+ (manage_register_defaults): Remove calls to manage_get_state.
+
+ * tclIndex: Rebuilt.
+
+Sun Nov 9 16:34:44 1997 Tom Tromey <tromey@cygnus.com>
+
+ * pref.tcl (build_win): Removed View page.
+
+ * toolbar.tcl (create_menu_items): Debugger -> "Foundry Debugger";
+ Help menu now parallels vmake.
+ * manage.tcl (manage_init): GDBTK -> "Foundry Debugger".
+
+Sun Nov 9 18:24:18 1997 Ian Lance Taylor <ian@cygnus.com>
+
+ * memory.tcl (build_win): Use a single menu, remove ``Hide
+ menubar'' entry, add ^U binding.
+ * manage.tcl (manage_init): Change name of memory window from
+ ``Memory Dump'' to ``Memory''.
+
+ * srcbar.tcl (create_buttons): Remove toggle update button.
+
+ * src.tcl (update_title): Don't use colon if there is no file
+ name.
+
+ * main.tcl: If GDBTK_IDE, initialize gdb_download_complete.
+ (gdbtk_tcl_preloop): If GDBTK_IDE, call download.
+ (ide_run_server): Don't run if we already have a run request. If
+ download is complete, run program as an idle callback. Otherwise,
+ wait until the download is complete before running the program.
+ (ide_do_run): New procedure to support ide_run_server.
+ (download): Don't run program. Set gdb_download_complete.
+
+ * src.tcl (name): Give an error if the file does not exist.
+ (location): Only add files that exist to the file name combobox.
+
+Sun Nov 9 11:09:39 1997 Tom Tromey <tromey@cygnus.com>
+
+ * src.tcl (name): Use better error message.
+
+ * locals.tcl (build_win): New method.
+ * watch.tcl (build_win): Create menu. Watch -> "Add Watch".
+ (Menu): New instance variable.
+ (selectionChanged): New method.
+ (postMenu): "Stop Watching" -> Remove.
+ * variables.tcl (build_win): Set -ignoreinvoke on Tree widget, and
+ set -command to run editEntry method. Don't install <Double-1>
+ binding. Put headers on Tree widget. Run selectionChanged
+ method.
+ (editEntry): Renamed. Now takes entry name as argument.
+ (populate): Don't set -state disabled on new items.
+ (getSelection): New method.
+ (selectionChanged): New method.
+ (build_menu_helper): New method.
+ (postMenu): View->Format.
+ (build_win): Likewise.
+
+ * variables.tcl (editXY): Only edit if entry is not empty.
+
+ * srcbar.tcl (create_menu_items): Edit -> Open.
+ (create_buttons): Likewise.
+
+Thu Nov 6 11:00:41 1997 Tom Tromey <tromey@cygnus.com>
+
+ * manage.tcl (manage_delete): Special-case deletion of pref window.
+ (manage_create): Don't special-case deletion of pref window.
+
+Thu Nov 6 13:57:32 1997 Ian Lance Taylor <ian@cygnus.com>
+
+ * manage.tcl (manage_get_state): Return an empty string for a
+ withdrawn window and for the preferences window.
+
+ * main.tcl (exe_name): Don't do anything if the executable name
+ has not actually changed.
+
+Wed Nov 5 23:08:00 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * main.tcl (download): Always specify exact filename
+ to load.
+
+Wed Nov 5 00:31:53 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * manage.tcl (manage_delete): Only delete source window if
+ user answers yes to query.
+
+ * bp.tcl: Rewrite to include pulldown menu and new look.
+
+ * register.tcl: Rewrite to include pulldown menu and new look.
+
+ * stack.tcl: Open initial size wide enough to show all text.
+
+ * src.tcl: Modified popup window. Remove option to open
+ multiple source windows because the IDE window code doesn't
+ work with it.
+
+ * srcbar.tcl (_set_run): Change balloon message for Run.
+
+ * variables.tcl, watch.tcl: Use fixed font.
+
+ * toolbar.tcl (create_menu_items): Handle Close Debugger correctly.
+
+ * mem_pref.tcl: Put focus and grab on window.
+
+ * memory.tcl: Balloon message change.
+
+Mon Nov 3 11:04:44 1997 Tom Tromey <tromey@cygnus.com>
+
+ * main.tcl (gdbtk_tcl_preloop): Look at main even if IDE running.
+ (ide_run_server): Open src window.
+
+ * manage.tcl (manage_init): Don't recreate initial windows when
+ running under IDE.
+
+Fri Oct 31 00:00:04 1997 Tom Tromey <tromey@cygnus.com>
+
+ * pref.tcl (cancel): Use manage delete.
+ * toolbar.tcl (create_menu_items): Don't register debugger
+ preference window.
+ * manage.tcl (manage_register_defaults): Use idewindow, not
+ idewindow_proc.
+ (manage_delete): Don't deregister preference window.
+ (manage): Added find, create_closed methods.
+ (manage_create): Added visibility argument; changed all callers.
+ Special case destruction of pref window.
+ * main.tcl: IDE window callback proc is "manage find". Register
+ debugger preference window. Create closed src and pref windows
+ initially.
+ (gdbtk_tcl_preloop): Don't create source window in IDE mode.
+
+ * src.tcl (trace_variable): New method.
+ (constructor): Use variable traces to track target/exe changes.
+ (destructor): Remove variable traces.
+
+Thu Oct 30 12:50:28 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * mem_pref.tcl: Change buttons to OK/Cancel/Apply.
+ Minor cleanup.
+
+ * memory.tcl: New look. Added menubar.
+
+Tue Oct 28 23:03:00 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * toolbar.tcl (create_buttons): Clean up balloon help
+ for buttons.
+ (create_menu_items): Move print menu items to srcbar.tcl.
+ Cleanup labels.
+
+ * srcbar.tcl (create_menu_items): Add print menu items.
+ (create_buttons): Clean up balloon help for buttons.
+
+Tue Oct 28 17:26:15 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * toolbar.tcl (create_menu_items): Add print menu items.
+ (print): New function. Calls the proper print routine.
+
+ * src.tcl (print): New function. Dump the contents
+ of the text widget to a printer.
+
+Tue Oct 28 01:06:15 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * toolbar.tcl (create_menu_items): Add new
+ preferences menu code.
+
+ * pref.tcl (build_win): Remove all old ppreferences.
+ Add Connection and View preferences.
+ (cancel): New function. Restore previous values and
+ quit.
+
+ * manage.tcl (manage_delete): Unregister preferences
+ on exit.
+
+ * src.tcl (constructor): Add sizebox under Windows.
+
+ * download.tcl (constructor): Remove shortcuts on buttons.
+ Put focus on "OK" button.
+
+ * download_pref.tcl (cancel): New function. Restores
+ previous values.
+
+Tue Oct 21 15:28:29 1997 Tom Tromey <tromey@cygnus.com>
+
+ * main.tcl: Main window now named "Foundry Debugger".
+
+Fri Oct 24 14:03:00 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * manage.tcl (manage_menu): Deleted.
+ (manage_delete): Notify IDE when windows are deleted.
+ (manage_raise): New function.
+ (manage_create): Notify IDE when a window is created.
+
+ * download.tcl (constructor): Put focus on download
+ window.
+
+ * toolbar.tcl (create_menu_items): Make "Window" menu
+ and IDE managed-menu, but don't put anything in it.
+
+Fri Oct 24 12:28:43 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * toolbar.tcl (create_menu_items): Add View menu.
+
+ * src.tcl (config_win): Add accelerators for new View
+ menu.
+
+Wed Oct 22 21:30:52 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * download.tcl (Download): Make window local modal.
+ Raise it to top.
+
+ * srcbar.tcl (create_buttons): Change border size on
+ address and line labels. Change balloon help. Remove
+ vertical line.
+
+Mon Oct 20 10:12:23 1997 Tom Tromey <tromey@cygnus.com>
+
+ * toolbar.tcl (create_buttons): vmake window now named "Foundry
+ Project".
+
+Mon Oct 13 19:02:33 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * bp.tcl (bp_modify): Change color of checkbuttons.
+
+ * download.tcl (done): Write "DONE" on progress meters.
+
+Thu Oct 9 14:33:21 1997 Ian Lance Taylor <ian@cygnus.com>
+
+ * main.tcl: Call ide_window_register restorer.
+
+Thu Oct 9 12:46:25 1997 Tom Tromey <tromey@cygnus.com>
+
+ * src.tcl (updateBalloon): Changed name of balloon variable.
+ (showBalloon): Likewise. Use new "balloon show" command.
+ (SrcBalloon): Removed.
+ (TimeOut): Default is 1000 (1 second).
+
+Wed Oct 1 11:33:36 1997 Tom Tromey <tromey@cygnus.com>
+
+ * main.tcl: Use "manage get_state" as window saver.
+
+ * manage.tcl (manage): Added "restore", "get_state" options.
+ (manage_restore): New proc.
+ (manage_get_state): Likewise.
+ (manage_register_defaults): Use "manage get_state" as window
+ saver.
+
+Sun Sep 28 04:20:00 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * bp.tcl: Clean up the spacing to make the widget look better.
+
+ * download_pref.tcl: Show the initial baud rate correctly.
+
+ * download.tcl: Cleanup correctly when deleted.
+
+ * main.tcl (gdb_tcl_preloop): Set baud rate.
+ (ide_run_server): Delay download 1 second.
+ (demo_it): Do gdb "next" commands every 2 seconds.
+
+ * manage.tcl (manage_create): Withdraw window immediately then
+ deiconify it when done.
+
+ * prefs.tcl (pref_set_defaults): Don't define stack bg color.
+
+ * register.tcl: Withdraw window immediately so we don't have
+ to watch it slowly draw. Make it look more like memory window.
+
+ * src.tcl: Fix major bug where source window got lost when
+ the source file was not found. Reconfigures more smoothly.
+
+ * srcbar.tcl (create_menu_items): Comment out "Close Debugger"
+ menu item because it was broken.
+
+ * stack.tcl: Use the same background color as the other windows.
+
+ * toolbar.tcl: Add "Automatic Step" menu item.
+
+Fri Sep 26 21:10:11 1997 Keith Seitz <keiths@pizza.cygnus.com>
+
+ * download.tcl (done): display bytes loaded as an integer.
+
+Fri Sep 26 13:09:47 1997 Tom Tromey <tromey@cygnus.com>
+
+ * images2/edit.gif: Replaced.
+
+Fri Sep 26 00:42:00 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * main.tcl (ide_run_server): Just call download.
+ (download): First set baud rate then target. Then, depending
+ on preferences set a breakpoint at 'main' and 'exit' and run.
+ (set_baud): New function.
+
+ * download_pref.tcl (build_win) Add checkbuttons for "Run until
+ 'main'" and "Set breakpoint at 'exit'.
+ (change_baud): Set preference when baud changes.
+
+ * pref.tcl (reconfig): Correct problem with download options.
+
+ * prefs.tcl (pref_set_defaults): Define gdb/load/main,
+ gdb/load/exit, and gdb/load/baud.
+
+ * src.tcl (location): Fix a problem where the browse tag was
+ sometimes not deleted.
+
+ * manage.tcl: Add a window title for Download Options.
+
+Thu Sep 25 15:39:00 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * download_pref.tcl: New file. Creates a download options dialog.
+
+ * manage.tcl: Add download prefs window to list.
+
+ * toolbar.tcl: Add Download preferences to menu.
+
+ * pref.tcl: Add Download to tab notebook preferences.
+
+ * src.tcl: Set activebackground on popup to indicate color
+ of the breakpoint dot that will be set.
+
+Thu Sep 25 12:36:00 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * download.tcl (done): Make sure all indicators show download
+ completed, even if we weren't properly notified.
+
+ * manage.tcl: Better support for windows that want to set
+ their own titles.
+
+ * src.tcl (update_title): New function. Sets titlebar
+ to indicate current filename, and under IDE, executable and
+ target.
+
+ * images2/reg.gif: Updated image.
+
+Thu Sep 25 08:58:44 1997 Keith Seitz <keiths@onions.cygnus.com>
+
+ * src.tcl (config_win): don't focus src window on Enter events
+
+Thu Sep 25 03:11:00 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * main.tcl (ide_run_server): Set target and download automatically.
+ (download): Open a download window.
+
+ * download.tcl: New file. Implements a download window.
+
+ * manage.tcl (manage_init): Add download window.
+ (manage_create): If there is no title, don't try to set one and
+ don't try to set geometry.
+
+ * registers.tcl: Make it look more like memory window.
+
+ * toolbar.tcl, floatbar.tcl, srcbar.tcl: Update look of menus and toolbars
+ to be closer to prototype.
+
+ * Makefile: Add download.tcl.
+
+ * tclIndex: Rebuilt.
+
+ * images/memory.gif: Update.
+
+ * images/bp.gif: New file. Breakpoint icon.
+
+Wed Sep 24 07:43:47 1997 Keith Seitz <keiths@onions.cygnus.com>
+
+ * variables.tcl (VariableWin::build_win): add double-click binding to edit
+ (editXY): new method to support above
+
+ * prefs.tcl (pref_set_defaults): add register window pref for highlight color
+
+ * register.tcl (RegWin::constructor): set highlight and normal fg
+ (build_win): build window using grid geometry manager, not grid widget
+ (dimensions): new method
+ (fixLength): new method
+ (but3): use "Menu" (protected data)
+ (edit): use entry to edit values
+ (acceptEdit): new method
+ (unedit): new method
+ (update): change to use new grid layout and change highlighting
+ (reconfig): destroy scrolled window, too
+ ScrolledWin: new protected data
+ Menu: new protected data
+ Editing: new protected data
+
+Tue Sep 23 15:15:22 1997 Ian Lance Taylor <ian@cygnus.com>
+
+ * main.tcl: If GDBTK_IDE, withdraw . before making any calls
+ across the IDE backplane.
+ * manage.tcl (manage_init): If using a floating toolbar, and
+ GDBTK_IDE, deiconify . to undo the withdrawal.
+
+Tue Sep 23 01:31:00 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * main.tcl: Reorder calls to pref init and standard_look_and_feel.
+
+ * global_pref.tcl: Change font requester to modify both src-font
+ and global.fixed. Change to be compatible with latest libide font code.
+
+ * prefs.tcl: Changes to get working with latest libide font code.
+
+Mon Sep 22 15:16:00 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * memory.tcl: Add editing. Remove debugging lines.
+ Fix problems with resizing.
+
+ * mem_pref.tcl: Remove debugging line.
+
+Fri Sep 19 08:22:25 1997 Keith Seitz <keiths@onions.cygnus.com>
+
+ * variables.tcl (build_win): use preferences
+ (getAllClassMembers): new method
+ (getPath): update to support C++
+
+ * watch.tcl (build_win): augment parent class' build_win instead of replacing it
+
+ * stack.tcl (build_win): use preferences
+ (update): catch gdb_loc in case source window is not open yet
+
+ * prefs.tcl (pref_set_defaults): add new defaults for all previously
+ hard-coded fonts and colors
+
+ * global_pref.tcl (build_win): use preferences
+
+ * console.tcl (Console::constructor): use preferences
+
+ * bp.tcl (bp_add): use preferences
+ (bp_modify): use preferences
+
+
+ * src.tcl (SrcWin::constructor): use preferences
+ (build_win): use preferences
+ (config_win): use preferences, bind <Enter> to focus source window textbox
+ so that our keypresses always work
+ (SrcBalloon): new protected variable
+ (TimeOut): new common variable
+
+Wed Sep 17 13:54:29 1997 Tom Tromey <tromey@cygnus.com>
+
+ * toolbar.tcl (build_win): Use standard_toolbar.
+
+Wed Sep 17 13:52:00 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * src.tcl (config_win): Set bg color back to default.
+
+Tue Sep 16 23:10:00 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * images2/*: Delete unused icons.
+
+Tue Sep 16 21:30:40 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * bp.tcl (bp_add): Add some padding to space things
+ out more. Anchor labels to the right side.
+
+ * src.tcl: Fix problem where breakpoints were disappearing
+ when files changed.
+
+Tue Sep 16 17:45:05 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * manage.tcl: Change manage_create and manage_open to accept
+ a variable number of args. Add mem and mempref window types.
+ Fix pref save call.
+
+ * memory.tcl: New file. Implements a memory dump window.
+ Currently read-only.
+
+ * mem_pref.tcl: New file. Implements options dialog for
+ memory dump window.
+
+ * pref.tcl, toolbar_pref.tcl, register.tcl, src_pref.tcl,
+ global_pref.tcl, about.tcl: Make "attach" a public config
+ variable.
+
+ * main.tcl: Use standard_look_and_feel.
+
+ * Makefile, tclIndex: Rebuilt.
+
+ * images/check.gif: A check mark image.
+
+ * images/stop.gif: Fix transparency.
+
+Tue Sep 16 08:13:03 1997 Keith Seitz <keiths@onions.cygnus.com>
+
+ * src.tcl (getVariable): fix off by one error when a breakpoint
+ is set at a line
+ (hasBreakpoint): new method
+ (SrcWin): add idle hook for source balloons
+ (updateBalloon): new method
+ (showBalloon): use register_balloon
+ (register_balloon): new method
+
+Tue Sep 16 05:55:31 1997 Keith Seitz <keiths@onions.cygnus.com>
+
+ * watch.tcl (add): use a little more robust (if more obscure) method
+ of determining validity of a variable name
+ (label): translate % to $ in names
+
+ * variables.tcl (Variable::setType): allow for convenience variables
+ (Variable::isConvenience): new method
+ (Variable::displayHex): allow for convenience variables
+ (VariableWin::edit): do not eval $data when editing (for conv. vars)
+ (VariableWin::postMenu): use virtual method label to title popup
+
+Fri Sep 12 12:17:13 1997 Keith Seitz <keiths@onions.cygnus.com>
+
+ * variables.tcl (Variable::value): when no display style specified,
+ choose some reasonable default for the given type
+
+ * src.tcl (config_win): ad bindings to support variable balloons in source mode
+ (getVariable): new method
+ (cancelMotion): new method
+ (motion): new method
+ (showBalloon): new method
+ timeoutID: new protected variable
+ TimeOut: new protected variable
+
+Fri Sep 12 05:47:56 1997 Keith Seitz <keiths@onions.cygnus.com>
+
+ * variables.tcl (getLocals): return empty list when no locals present.
+
+Thu Sep 11 14:13:19 1997 Keith Seitz <keiths@onions.cygnus.com>
+
+ * variables.tcl (VariableWin::build_win): change popup construction
+ (VariableWin::postMenu): redo menu layout to use dynamic idices of
+ panes
+ (VariableWin::edit): new method
+ (VariableWin::UnEdit): new method
+ (VariableWin::changeValue): new method
+ (VariableWin::getPath): handle unamed unions/structs and arrays more
+ intelligently
+ VariableWin::Editing: new protected variable
+ VariableWin::EditEntry: new protected variable
+ (Variable::isOpenable): make sure we can open unions
+ (Variable::isUnamed): new method
+ (Variable::isUnion): new method
+ (Variable::setType): handle unions and unamed structs/unions better
+ (Variable::displayHex): unions, structs only display in hex
+ (Variable::isArray): new method
+ (Variable::isEnum): new method
+ (Variable::isEditable): new method
+ (Variable::value): enums now show symbol values, too. Analogous to char
+ and char*.
+
+ * watch.tcl (WatchWin::build_win): change popup construction
+ (WatchWin::postMenu): redo menu layout to use dynamic indices of panes
+
+
+Wed Sep 10 20:44:12 1997 Ian Lance Taylor <ian@cygnus.com>
+
+ * manage.tcl (manage_register_defaults): Rename from
+ manage_register_default. Take a list of windows.
+ (manage_menu): Invoke manage_register_defaults once as an idle
+ callback, rather than invoking manage_register_default in many
+ different idle callbacks.
+
+Wed Sep 10 00:49:23 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * src.tcl (edit): Don't start editor if we're not
+ debugging anything.
+
+ * main.tcl: Keep correct colorscheme for windows.
+
+Mon Sep 8 12:10:26 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * manage.tcl (manage_restart): Only restart toolbar once.
+
+ * global_pref.tcl: Minor fix.
+
+ * images2/vmake.gif: Fix transparency.
+
+Mon Sep 8 13:05:11 1997 Ian Lance Taylor <ian@cygnus.com>
+
+ * interface.tcl (gdbtk_tcl_query): Use tk_messageBox rather than
+ tk_dialog.
+
+ * main.tcl: Register check and exit handlers using new commands
+ provided by gdbtk.
+
+Mon Sep 8 03:01:25 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * global_pref.tcl (build_win): Some font fixes.
+
+Mon Sep 8 02:25:17 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * src.tcl: Make disabled breakpoints black.
+ Make comboboxes only use scrollbars when needed.
+
+ * interface.tcl (gdbtk_tcl_breakpoint): Change to support
+ changes in gdbtk.c. Supply breakpoint number to hooks.
+
+ * manage.tcl: Add breakpoint window. Add support for
+ dynamically attaching/detaching toolbars.
+
+ * bp.tcl: New file. Breakpoint window.
+
+ * main.tcl: Change palette for debugging.
+
+ * pref.tcl: New file. Preferences dialog.
+
+ * floatbar.tcl: Add target and download buttons.
+ Add spacing.
+
+ * srcbar.tcl, toolbar.tcl: Change to use flat icons. Work with
+ floating toolbar if requested.
+
+ * prefs.tcl: Define new preferences to force toolbar
+ to float or be attached to the source windows.
+
+ * global_pref.tcl: Remove icon requester.
+
+ * toolbar_pref.tcl: Add icon combobox. Add checkbuttons
+ for forcing toolbar to either float or be attached to src window.
+
+ * Makefile: Add bp.tcl
+
+ * images/*: Fix transparency and add new icons.
+
+ * images2/*: Add flat icons.
+
+Fri Sep 5 20:24:07 1997 Ian Lance Taylor <ian@cygnus.com>
+
+ * main.tcl: Register an exit handler when using the IDE.
+
+Thu Sep 4 11:47:38 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * ALL: Change preferences to use new preferences.
+ Change "dbug" calls to "debug".
+
+ * pref.tcl: New file. Local preferences read/write.
+
+ * gettext.tcl, debug.tcl, balloon.tcl: Delete. Use
+ versions from libide instead.
+
+Wed Sep 3 09:20:13 1997 Tom Tromey <tromey@cygnus.com>
+
+ * main.tcl (add): Pass idewindow_no_state to idewindow_proc.
+ * manage.tcl (manage_register_default): Pass idewindow_no_state to
+ idewindow_proc.
+
+Mon Aug 25 05:59:01 1997 Martin M. Hunt <hunt@pern.cygnus.com>
+
+ * images2/{finished.gif, finishedu.gif, nextd.gif nextu.gif,
+ stepd.gif, stepu.gif}: Use icons with straight brackets
+ instead of slanted.
+
+ * prefs.tcl (pref_set_defaults): Set default debugMode to 0.
+
+ * register.tcl (build_win): Change font to fixed and bg to white.
+
+ * src.tcl: Change all references to fonts to "src-font".
+
+ * global_pref.tcl: Change font requester to do src-font.
+
+ * srcbar.tcl: Change address and line labels to use
+ src-font and be sunken.
+
+ * stack.tcl: Chnage bg to white and fonr to src-font.
+
+Mon Aug 25 03:06:35 1997 Keith Seitz <keiths@pizza.cygnus.com>
+
+ * src.tcl: (set_status) check if inferior is running first, and reset
+ message for status window if it is not.
+
+
+Mon Aug 25 00:28:39 1997 Martin M. Hunt <hunt@pern.cygnus.com>
+
+ * srcbar.tcl: Change stack images to be consistent with others.
+
+ * images2/{upu.gif,upd.gif,bottomd.gif,bottomu.gif,downu.gif,
+ downd.gif}: New stack images.
+
+ * images2/edit[ud].gif: Correct quantization and transparency.
+
+ * manage.tcl (manage_delete): Kill gdb when all source windows
+ are deleted.
+ (manage_create): Only add IDE entries on the first source window.
+
+ * src.tcl (do_popup): Don't map window if already mapped. Fixes
+ problem with tk_popup. Change menu items.
+
+Mon Aug 25 00:24:43 1997 Keith Seitz <keiths@pizza.cygnus.com>
+
+ * src.tcl: (set_status) change to using gdb_target_has_execution to
+ determine if the target is running
+
+Sun Aug 24 23:02:19 1997 Tom Tromey <tromey@cygnus.com>
+
+ * toolbar.tcl (build_win): Make sure object is deleted when window
+ is destroyed.
+ (destructor): Don't destroy containing widget; just us.
+
+ * srcbar.tcl (create_menu_items): Added Exit item to menu.
+
+ * src.tcl (build_win): Use grid, not packer, to lay out main
+ window.
+ (mode): Pack new text widget into pane; don't repack the pane
+ itself.
+
+Sun Aug 24 22:06:30 1997 Keith Seitz <keiths@pizza.cygnus.com>
+
+ * varialbes.tcl: (build_win) set hlist font to 'tix option get
+ fixed_font', change selectBackground to Hlist background, select-
+ BorderWidth to 0, selectForeground to black. Use tk_popup instead of
+ tixPopup widget.
+ (postMenu) make necessary tk_popup changes, make sure functions are
+ only allowed to be displayed in hex.
+ (isFunction) new method
+ (displayHex) functions only displayable as hex
+ (value) extract the address of functions for value
+ * watch.tcl: (constructor) remove popup menu customization
+ (build_win) change from tixPopup to tk_popup, hack the
+ hlist options to use the correct font, etc as in variables.tcl,
+ (validateEntry) always erase the contents of the entry
+ (postMenu) make all changes to use tk_popup and move the "Stop
+ watching" menu addition here
+ (label) make sure that we use "foo.bar" and "foo->bar" correctly
+ (add) fix typo preventing recognition of variables already being
+ watched
+
+Sun Aug 24 18:49:16 1997 Martin M. Hunt <hunt@pern.cygnus.com>
+
+ * console.tcl (invoke): Don't display error messages in console window.
+ (constructor): Enable cut-and-paste. Fix intermittant bug.
+
+ * main.tcl (gdbtk_tcl_preloop): Don't automatically do anything
+ but issue the file command.
+ (download): Issue load command. Called when icon is selected.
+ (set_target): Issue target command. Called when target
+ icon is selected.
+
+ * srcbar.tcl: Add target and download buttons to toolbar.
+
+Sun Aug 24 20:30:41 1997 Ian Lance Taylor <ian@cygnus.com>
+
+ * main.tcl (gdbtk_tcl_preloop): If GDBTK_IDE, then automatically
+ set file and target based on properties. If using the simulator,
+ load the executable. Catch and ignore errors from setting the
+ source window to show main.
+
+Sun Aug 24 14:39:23 1997 Tom Tromey <tromey@cygnus.com>
+
+ * src.tcl (constructor): Don't set `editor'.
+ (location): Never update external editor.
+ (edit): Don't set `editor'.
+ (editor): Removed instance variable.
+
+ * images2/stepiu.gif, images2/stepid.gif, images2/nextiu.gif,
+ images2/nextid.gif: Installed new versions.
+
+ * srcbar.tcl (_toggle_updates): Pass $updatevalue to
+ updatecommand.
+ (destructor): Implemented.
+ (_set_stepi): New method.
+ (displaymode): Run _set_stepi when changed.
+ (updatevalue): Global state stored in global array.
+ (create_buttons): Create stepi, nexti buttons. Run _set_stepi.
+ (_load_src_images): Create stepi, nexti icons.
+
+ * images2/stepiu.gif, images2/stepid.gif, images2/nextiu.gif,
+ images2/nextid.gif: New images.
+ (create_buttons): Likewise.
+
+ * src.tcl (toggle_updates): Use $value, not $a.
+
+ * src.tcl (mode): Don't change commands on (nonexistent) step/next
+ buttons.
+
+ * toolbar.tcl (create_buttons): Added watch button.
+ (_load_images): Create watch images.
+ * images2/watchd.gif, images2/watchu.gif: New files.
+ * images2/varsd.gif, images2/varsu.gif: Changed.
+
+ * images2/*: Removed old images, added many new images.
+
+ * prefs.tcl (pref_set_defaults): Default images are in images2
+ directory.
+ * src.tcl (build_win): Make a GDBSrcBar.
+ (location): address and line information now in toolbar.
+ (mode): Set -displaymode on toolbar.
+ (update): Set -running on toolbar.
+ (busy): Likewise.
+ (edit): Now a method, not a proc.
+ (toggle_updates): Added "value" argument.
+ * Makefile (TCL): Added srcbar.tcl, floatbar.tcl.
+ * toolbar.tcl (create_buttons): New method.
+ (create_menu_items): Likewise.
+ (build_win): Run create_menu_items and create_buttons. Move most
+ of body into these methods. Removed Exit command from File menu.
+ (_loaded_images): New common variable.
+ (_load_images): New method.
+ (create_buttons): Run it.
+ (create_menu_items): Removed Tools menu.
+ (configure): Renamed from config.
+ * srcbar.tcl: New file. Implements toolbar attached to source
+ window.
+ * floatbar.tcl: New file. Implements floating toolbar.
+ * manage.tcl (manage_init): toolbar-type is GDBFloatBar.
+ (manage_init): Don't create toolbar if running under IDE.
+
+Sun Aug 24 13:05:22 1997 Martin M. Hunt <hunt@pern.cygnus.com>
+
+ * manage.tcl (manage_init): Remove idemenuname from
+ the _manage_objects array; it was redundant.
+ (manage_create): Stop notifying IDE about new transient
+ windows.
+
+Sun Aug 24 01:07:29 1997 Tom Tromey <tromey@cygnus.com>
+
+ * about.tcl, console.tcl, global_pref.tcl, prefs.tcl,
+ register.tcl, src.tcl, src_pref.tcl, stack.tcl, toolbar.tcl,
+ toolbar_pref.tcl: Added Copyright statement.
+
+ * Makefile (tags, TAGS): New targets.
+
+ * toolbar.tcl (build_win): Quit->Exit. Only display this item if
+ not using the IDE.
+
+Sat Aug 23 21:55:54 1997 Ian Lance Taylor <ian@cygnus.com>
+
+ * src.tcl (SrcWin update): Set command for stop icon.
+ (SrcWin busy): Likewise.
+
+ * manage.tcl: Move comments out of array initialization.
+
+Sat Aug 23 17:36:06 1997 Martin M. Hunt <hunt@pern.cygnus.com>
+
+ * src.tcl (name): Handle case where files are part of the
+ sources, but are unreadable.
+ (build_win): Set filename combobox size to default.
+
+ * manage.tcl: Remove breakpoint window from window list.
+
+Sat Aug 23 16:49:53 1997 Keith Seitz <keiths@onions.cygnus.com>
+
+ * src.tcl: remove old breakdot stuff
+ (reconfig) make sure we redraw the breakdots when font changes
+ (file) check for duplicate break-able lines
+ * variables.tcl: remove debug output
+ * watch.tcl: add entry field to enter watch expressions
+
+Sat Aug 23 17:44:45 1997 Ian Lance Taylor <ian@cygnus.com>
+
+ * manage.tcl (manage_create): Register the window if it is not
+ already registered, rather than if it is already registered.
+
+ * src.tcl (SrcWin config_win): Add special double and triple click
+ bindings to override standard text bindings in break dot area.
+
+ * prefs.tcl (pref_set_defaults): Set the global font to the Tix
+ default font. Set the src font to the Tix default fixed font.
+ * src.tcl (SrcWin config_win): Configure the text font.
+ * console.tcl (Console constructor): Set the cont to the Tix
+ fixed font.
+
+Fri Aug 22 20:42:51 1997 Keith Seitz <keiths@onions.cygnus.com>
+
+ * src.tcl: add breakpoint image that is text-size insensitive
+ change layout of source, assembly, and mixed windows to use
+ tabs, if possible, allowing more clickable area for toggling
+ breakpoints, etc.
+ * variables.tcl: (VariableWin::isFloat) new method
+ (VariableWin::value) make sure floats are output as floats
+ when user specifies "decimal" output
+
+Fri Aug 22 16:23:32 1997 Martin M. Hunt <hunt@pern.cygnus.com>
+
+ * src.tcl (goto_func): Catch errors.
+
+Fri Aug 22 16:35:39 1997 Ian Lance Taylor <ian@cygnus.com>
+
+ * main.tcl: Use underscores rather than dashes in variable names.
+ (ide_run_server): Make gdb_target_name global. Call file before
+ calling target. Call load before calling run.
+
+Fri Aug 22 12:15:06 1997 Martin M. Hunt <hunt@pern.cygnus.com>
+
+ * debug.tcl (dbug): Make debug window scrolled. Make it
+ work with standalone gdb.
+
+ * prefs.tcl (pref_save): Fix puts that were incorrectly
+ changed to dbug.
+
+Thu Aug 21 17:57:59 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * ALL: Change all "puts" to "dbug".
+
+ * debug.tcl: New file. Opens a window for debugging messages.
+
+Thu Aug 21 14:30:53 1997 Keith Seitz <keiths@onions.cygnus.com>
+
+ * watch.tcl: (add) strip commas, too
+
+Thu Aug 21 14:26:36 1997 Keith Seitz <keiths@onions.cygnus.com>
+
+ * variables.tcl: (buid_win) use listbox's font for font measuring
+
+Thu Aug 21 02:52:35 1997 Martin M. Hunt <hunt@pern.cygnus.com>
+
+ * src.tcl (name): Check source filenames and handle errors
+ if not found.
+
+ * variables.tcl (destructor): Display styles are not
+ objects so must be destroyed instead of deleted.
+ (name): comment out debugging line.
+
+ * main.tcl: Add stuff from standard_look_and_feel.
+
+ * prefs.tcl, manage.tcl: Minor cleanup.
+
+Thu Aug 21 00:39:35 1997 Martin M. Hunt <hunt@pern.cygnus.com>
+
+ * main.tcl (ide_run_server) New function. Starts GDB when
+ asked politely.
+ (target_name): New function. Watches for changes in the target
+ name.
+ (exe_name): New function. Watches for changes in the
+ executable name.
+
+ * console.tcl (insert, einsert): Scroll so the insertion
+ point can be seen.
+
+ * manage.tcl: SPecial hacks to create a global "console".
+ Needed because we can't have puts searching for a console
+ window everytime a puts arrives.
+
+ * interface.tcl (gdbtk_tcl_fputs, gdbtk_tcl_fputs_error):
+ Write to the console if one exists, and do an update.
+
+ * tclIndex: Rebuilt.
+
+Wed Aug 20 17:23:07 1997 Keith Seitz <keiths@onions.cygnus.com>
+
+ * variables.tcl: (Variable::setType VariableWin::getPath) handle types
+ with multiple names (unsigned char, long long unsigned int) properly
+ * locals.tcl: (update) comment out debug info
+
+Wed Aug 20 16:36:49 1997 Keith Seitz <keiths@pizza.cygnus.com>
+
+ * watch.tcl: (add) try to handle errors more gracefully
+ * variables.tcl: (value) make sure we handle bad pointer
+ dereferences nicely
+ (lots of places) switch to using 'ouput' instead of 'print'
+
+Wed Aug 20 11:43:35 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * src.tcl (file): Handle case where source files do
+ not have any lines which generate code.
+ (set_status): Keep status to one line.
+
+Wed Aug 20 00:00:52 1997 Tom Tromey <tromey@sanguine.cygnus.com>
+
+ * images2/build.gif, images2/file.gif, images2/reg.gif,
+ images2/stop.gif, images2/continue.gif, images2/finish.gif,
+ images2/next.gif, images2/step.gif, images2/run.gif: New files.
+
+Tue Aug 19 14:52:59 1997 Keith Seitz <keiths@onions.cygnus.com>
+
+ * tclIndex: rebuilt
+ * Makefile: add variables.tcl, watch.tcl, and locals.tcl
+ * manage.tcl: (manage_init): add locals window
+ * src.tcl: (do_popup): add binding for watch window
+ (addToWatch): new method
+ * locals.tcl: new file
+ * variables.tcl: new file
+ * watch.tcl: new file
+
+
+Mon Aug 18 01:28:19 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * manage.tcl: Change window names to have only first
+ char of each word capitalized.
+
+ * global_pref.tcl (get_file): Handle bad pathnames.
+
+Sun Aug 17 01:59:02 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * register.tcl (destructor): Call manage delete.
+ * global_pref.tcl (destructor): Call manage delete.
+ * prefs.tcl (destructor): Call manage delete.
+ * src_pref.tcl (destructor): Call manage delete.
+ * toolbar_pref.tcl (destructor): Call manage delete.
+
+ * manage.tcl: (manage_delete): Remove windows that
+ have been quit, rather than killed by window manager.
+
+ * src.tcl (location): Don't call gdb_listfuncs on
+ NULL filenames.
+
+Sun Aug 17 00:18:02 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * src.tcl: Major changes to support file browsing.
+ Also bug fixes for assembly mode, new comboboxes
+ for filename and function selection.
+
+ * src_pref.tcl: New file. Allows selection of
+ colors used in source display.
+
+ * prefs.tcl: Add new window type for src prefs.
+ Set default colors for source window.
+
+ * manage.tcl (manage_init): Add srcpref window type.
+ (manage_restart): Preserve window geometries on restarts.
+
+ * Makefile: Add src_pref.tcl.
+
+ * tclIndex: Rebuilt.
+
+ * toolbar.tcl: Add call to source prefs.
+
+ * main.tcl: Change initial "src file" call to
+ "src location".
+
+Thu Aug 14 15:49:02 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * manage.tcl (manage_create): Some fixes for IDE windows.
+
+Thu Aug 14 03:18:10 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * register.tcl, stack.tcl (destructor): Remove hook.
+
+ * manage.tcl: Mostly rewritten from scratch to be
+ more efficient and handle multiple windows of the same type.
+ (manage_open): New function opens or creates a window
+ as necessary.
+ (manage_create): Now always creates a new window.
+
+ * global_pref.tcl (build_win): Only put up font message
+ box on Unix systems.
+
+ * main.tcl: Change "manage create" calls to "manage open"
+
+ * src (destructor): Remove hooks.
+ (do_popup): Add a menu item to open another source window.
+
+ * toolbar.tcl (build_win): Change "manage create" calls to
+ "manage open". Bind button 3 on iconbar to "manage create".
+
+ * prefs.tcl: Changes required for new features in manage.tcl.
+
+ * tclIndex: Rebuilt.
+
+ * hooks.tcl (remove_hook): Fix.
+ (lremove): New function.
+
+Tue Aug 12 16:06:04 1997 Ian Lance Taylor <ian@cygnus.com>
+
+ * main.tcl: If running in the IDE, register the source window as
+ the generic gdb window.
+
+Tue Aug 12 01:42:10 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * global_pref.tcl (build_win): Add a font size control
+ widget, and a font preview window. Implement scanning
+ for fixed-width fonts and a font cache.
+ (font_changed): Save all font attributes in new-style
+ font description.
+
+ * balloon.tcl: Merge in latest changes from libide.
+
+ * prefs.tcl (pref): Rename variables to make function
+ clearer.
+ (pref_init): After reading in prefs file, create
+ all named fonts.
+ (pref_set_defaults): Set default font to {courier 12 roman}.
+
+Mon Aug 11 13:47:49 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * tclIndex: New file.
+
+ * Makefile: New file. Generates tclIndex when needed.
+
+ * manage.tcl (manage_init): Add an icon for GDB.
+ (manage_create): Bind Map and Unmap for toolbar toplevel.
+ Tell window manager to display icon if one exists.
+ (manage_iconify): Iconify or deiconify all windows.
+ (make_icon_window): Build a window with an icon in it.
+ (bind_for_toplevel_only): Local copy, because if you build
+ GDB without IDE you won't get the one in libide.
+
+ * main.tcl: Remove all the source commands.
+
+ * toolbar.tcl: Use "-menu" configuration option for toplevel.
+
+ * images/cygnus_icon.gif: A cygnus logo with GDB on it.
+ For Unix window managers.
+
+Fri Aug 8 16:01:20 1997 Ian Lance Taylor <ian@cygnus.com>
+
+ * manage.tcl (manage): Add menu subcommand.
+ (manage_init): Add -menu, -menuname, and -idemenuname options for
+ all the windows.
+ (manage_create): Register transient windows.
+ (manage_menu, manage_register_default): New procedures.
+ * toolbar.tcl (build_win): Call manage_menu to set up the window
+ menu.
+
+Thu Aug 7 16:51:43 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * stack.tcl: Bind button 1 to select current
+ frame. Add balloonhelp.
+
+Thu Aug 7 14:00:18 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * main.tcl, manage.tcl, toolbar.tcl: Add support
+ for stack window.
+
+ * stack.tcl, images/stack.gif: New files.
+
+ * ALL: Change "::" to "@@" for itcl1.5/tcl8.0. You
+ muct now use tcl8 for gdbtk to work.
+
+Tue Aug 5 12:10:43 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * register.tcl, global_pref.tcl: Change color "darkred"
+ to red so it will work on windows.
+
+Tue Aug 5 12:01:26 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * manage.tcl (manage_init): Unset prefs are now ""
+ instead of 0.
+
+Tue Aug 5 02:21:47 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * images*/run.gif: Change to green again.
+
+Tue Aug 5 01:42:56 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * main.tcl: Source register.tcl
+
+ * register.tcl: New file. Editable register window
+ and register preferences.
+
+ * toolbar.tcl: Add hooks for register prefs.
+
+ * manage.tcl: Add register window to list of windows.
+ Deiconify windows when requested.
+
+ * src.tcl: Minor changes.
+
+ * global_pref.tcl: Bind return key to image dir entry
+ widget.
+
+ * prefs.tcl: Add register prefs to notebook widget.
+ Change default for pref get to {} instead of 0.
+
+Fri Aug 1 14:21:25 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * images/*: Smaller toolbar icons. Fix some gifs
+ to be transparent.
+
+Thu Jul 31 01:20:51 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * src.tcl (mode): Don't try to display EDIT button
+ in any mode.
+
+Thu Jul 31 00:56:26 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * global_pref.tcl (build_win): Add ComboBox for simple font selection.
+
+ * prefs.tcl (pref_init): Allow "option" commands in init file.
+
+ * src.tcl: Remove EDIT button. Change fonts to use global font if
+ no src font is specified.
+
+ * toolbar.tcl: Enable Tools/Edit pulldown menu.
+
+Wed Jul 30 14:43:49 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * about.tcl (build_win): Set bg to white for Cygnus gif.
+
+Wed Jul 30 14:39:49 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * manage.tcl (manage_create): Fix window raising.
+
+Wed Jul 30 13:40:11 1997 Martin M. Hunt <hunt@cygnus.com>
+
+ * initial checkin.
+
diff --git a/gdb/gdbtk/library/Makefile b/gdb/gdbtk/library/Makefile
index c1e653b7944..53953ad9e0c 100644
--- a/gdb/gdbtk/library/Makefile
+++ b/gdb/gdbtk/library/Makefile
@@ -1,10 +1,10 @@
-TCL := $(wildcard *.tcl *.itcl *.ith *.itb)
+TCL := $(wildcard *.tcl *.ith *.itb)
-TCLSH = tclsh
+ITCL_SH = itclsh3.0
tclIndex: $(TCL) Makefile
- echo "package require Itcl; auto_mkindex `pwd` $(TCL)" | $(TCLSH)
+ echo "auto_mkindex `pwd` $(TCL)" | $(ITCL_SH)
tags: TAGS
TAGS: $(TCL)
diff --git a/gdb/gdbtk/library/about.tcl b/gdb/gdbtk/library/about.tcl
index 937b48051c8..292eecd7318 100644
--- a/gdb/gdbtk/library/about.tcl
+++ b/gdb/gdbtk/library/about.tcl
@@ -1,5 +1,5 @@
# About window for GDBtk.
-# Copyright (C) 1997, 1998, 1999, 2000, 2001 Red Hat, Inc.
+# Copyright 1997, 1998, 1999 Cygnus Solutions
#
# This program is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License (GPL) as published by
@@ -16,20 +16,19 @@
# Implements About window
# ----------------------------------------------------------------------
-itcl::class About {
+class About {
inherit ManagedWin ModalDialog
constructor {args} {
global gdb_ImageDir
set f [frame $itk_interior.f]
- label $f.image1 -bg #ee0000 -image \
+ label $f.image1 -bg white -image \
[image create photo -file [file join $gdb_ImageDir insight.gif]]
- message $f.m -bg #ee0000 -fg white -text [gdb_cmd {show version}] \
- -aspect 500 -relief flat
+ message $f.m -bg white -fg black -text [gdb_cmd {show version}] -aspect 500 -relief flat
pack $f.image1 $f.m $itk_interior.f -fill both -expand yes
pack $itk_interior
bind $f.image1 <1> [code $this unpost]
bind $f.m <1> [code $this unpost]
- window_name "About Red Hat Insight"
+ window_name "About Cygnus Insight"
}
# Don't quit if this is the last window. The only way that this can
diff --git a/gdb/gdbtk/library/actiondlg.tcl b/gdb/gdbtk/library/actiondlg.tcl
index 20314bfabf9..c446b7ed4fd 100644
--- a/gdb/gdbtk/library/actiondlg.tcl
+++ b/gdb/gdbtk/library/actiondlg.tcl
@@ -1,5 +1,5 @@
-# Tracepoint actions dialog for Insight.
-# Copyright (C) 1997, 1998, 1999, 2001 Red Hat, Inc.
+# Tracepoint actions dialog for GDBtk.
+# Copyright 1997, 1998, 1999 Cygnus Solutions
#
# This program is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License (GPL) as published by
@@ -12,18 +12,25 @@
# GNU General Public License for more details.
-itcl::class ActionDlg {
- inherit ManagedWin
-
+itcl_class ActionDlg {
# ------------------------------------------------------------------
# CONSTRUCTOR
# ------------------------------------------------------------------
- constructor {args} {
+ constructor {config} {
global _TStepCount _TOtherVariable
- eval itk_initialize $args
+ set class [$this info class]
+ set hull [namespace tail $this]
+ set old_name $this
+ ::rename $this $this-tmp-
+ ::frame $hull -class $class
+ ::rename $hull $old_name-win-
+ ::rename $this $old_name
+
+ set top [winfo toplevel [namespace tail $this]]
+ wm withdraw $top
- set Registers [gdb_reginfo name]
+ set Registers [gdb_regnames]
if {$Line != ""} {
set Locals [gdb_get_locals "$File:$Line"]
set Args [gdb_get_args "$File:$Line"]
@@ -45,7 +52,7 @@ itcl::class ActionDlg {
lappend Variables "All Registers"
lappend Variables "Collect Stack"
- build_win
+ build_win $this
# Set a default return status, in case we are destroyed
set _TOtherVariable {}
@@ -54,6 +61,9 @@ itcl::class ActionDlg {
if {"$Data" != {}} {
change 1 $Data
}
+
+ after idle [list wm deiconify $top]
+ # after idle grab $this
}
# ------------------------------------------------------------------
@@ -67,16 +77,18 @@ itcl::class ActionDlg {
# Note that this is okay: the callback (TraceDlg::done, usually) will
# ignore stray "cancel" callbacks
eval $Callback cancel
+
+ set top [winfo toplevel [namespace tail $this]]
+ destroy $this
+ destroy $top
}
# ------------------------------------------------------------------
# METHOD: build_win - build the Trace dialog box (cache this?)
# ------------------------------------------------------------------
- method build_win {} {
+ method build_win {f} {
global _TStepCount _TOtherVariable
- set f $itk_interior
-
# The two frames of this dialog
set bbox [frame $f.bbox]; # for holding OK,CANCEL buttons
set data [frame $f.data]; # for everything else
@@ -109,24 +121,20 @@ itcl::class ActionDlg {
# The Collect listbox
label $cFrame.lbl -text {Collect:}
- set CollectLB [iwidgets::scrolledlistbox $cFrame.lb -hscrollmode dynamic \
- -vscrollmode dynamic \
- -selectioncommand [code $this toggle_button_state 0] \
- -dblclickcommand [code $this change 0] \
- -selectmode extended \
- -exportselection false]
- [$CollectLB component listbox] configure -background gray92
+ tixScrolledListBox $cFrame.lb -scrollbar auto \
+ -browsecmd "$this toggle_button_state 0" \
+ -command "$this change 0"
+ set CollectLB [$cFrame.lb subwidget listbox]
+ $CollectLB configure -selectmode extended
pack $cFrame.lbl $cFrame.lb -side top -expand yes -pady 2
# The Variables listbox
label $vFrame.lbl -text {Variables:}
- set VariablesLB [iwidgets::scrolledlistbox $vFrame.lb -hscrollmode dynamic \
- -vscrollmode dynamic \
- -selectioncommand [code $this toggle_button_state 1] \
- -dblclickcommand [code $this change 1] \
- -selectmode extended \
- -exportselection false]
- [$VariablesLB component listbox] configure -background gray92
+ tixScrolledListBox $vFrame.lb -scrollbar auto \
+ -browsecmd "$this toggle_button_state 1" \
+ -command "$this change 1"
+ set VariablesLB [$vFrame.lb subwidget listbox]
+ $VariablesLB configure -selectmode extended
pack $vFrame.lbl $vFrame.lb -side top -expand yes -pady 2
# The button frame
@@ -167,16 +175,16 @@ itcl::class ActionDlg {
method toggle_button_state {add} {
- # This is invoked whenever a <1> event is generated in
+ # BUG in Tix.. This is invoked whenever a <1> event is generated in
# the listbox...
if {$add} {
- set a [$VariablesLB getcurselection]
+ set a [$VariablesLB curselection]
if {"$a" != ""} {
$AddButton configure -state normal
$RemoveButton configure -state disabled
}
} else {
- set a [$CollectLB getcurselection]
+ set a [$CollectLB curselection]
if {"$a" != ""} {
$AddButton configure -state disabled
$RemoveButton configure -state normal
@@ -666,7 +674,7 @@ itcl::class ActionDlg {
# METHOD: cancel - cancel the dialog and do not set the trace
# ------------------------------------------------------------------
method cancel {} {
- ::delete object $this
+ delete
}
method remove_special {list items} {
@@ -771,7 +779,7 @@ itcl::class ActionDlg {
debug "DATA = $data"
eval $Callback $command $steps [list $data]
- ::delete object $this
+ delete
}
@@ -784,27 +792,27 @@ itcl::class ActionDlg {
}
# PUBLIC DATA
- public variable File
- public variable Line {}
- public variable WhileStepping 0
- public variable Number
- public variable Callback
- public variable Data {}
- public variable Steps {}
- public variable Address {}
+ public File
+ public Line {}
+ public WhileStepping 0
+ public Number
+ public Callback
+ public Data {}
+ public Steps {}
+ public Address {}
# PROTECTED DATA
- protected variable WhileSteppingEntry
- protected variable CollectLB
- protected variable VariablesLB
- protected variable Variables {}
- protected variable Collect {}
- protected variable Locals
- protected variable Args
- protected variable Registers
- protected variable Others {}
- protected variable AddButton
- protected variable RemoveButton
- protected variable OtherEntry
- protected variable StackCollect {*(char*)$sp@64}
+ protected WhileSteppingEntry
+ protected CollectLB
+ protected VariablesLB
+ protected Variables {}
+ protected Collect {}
+ protected Locals
+ protected Args
+ protected Registers
+ protected Others {}
+ protected AddButton
+ protected RemoveButton
+ protected OtherEntry
+ protected StackCollect {*(char*)$sp@64}
}
diff --git a/gdb/gdbtk/library/attachdlg.itb b/gdb/gdbtk/library/attachdlg.itb
index 64ae195d7ae..8d066171b21 100644
--- a/gdb/gdbtk/library/attachdlg.itb
+++ b/gdb/gdbtk/library/attachdlg.itb
@@ -1,89 +1,80 @@
-# Attach Dialog for Insight.
-# Copyright (C) 1999, 2002, 2003, 2008 Red Hat, Inc.
#
-# This program is free software; you can redistribute it and/or modify it
-# under the terms of the GNU General Public License (GPL) as published by
-# the Free Software Foundation; either version 2 of the License, or (at
-# your option) any later version.
+# attachdlg.itb - itcl implementations for class AttachDlg
+# ----------------------------------------------------------------------
+# Implements Attach to process window...
+#
+# ----------------------------------------------------------------------
+# Copyright (C) 1999 Cygnus Solutions
#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
+body AttachDlg::constructor {args} {
-itcl::body AttachDlg::constructor {args} {
- eval itk_initialize $args
- window_name "Attach To Process"
build_win
+ eval itk_initialize $args
+
}
-itcl::body AttachDlg::build_win {} {
- # Frame
- itk_component add pid {
- iwidgets::labeledframe $itk_interior.f -labeltext "Choose Process" \
- -relief groove -borderwidth 2 -ipadx 6 -ipady 4
- }
+body AttachDlg::build_win {} {
+
+ # CHOOSE_PID: the list box with list or processes. Also an entry
+ # for typing in the PID by hand.
- # Listbox of processes
itk_component add choose_pid {
- iwidgets::scrolledlistbox [$itk_component(pid) childsite].pid \
- -visibleitems 30x15 -hscrollmode dynamic -vscrollmode dynamic\
- -exportselection 0 -selectioncommand [code $this select_pid] \
- -foreground $::Colors(textfg) -textbackground $::Colors(textbg) \
- -dblclickcommand [code $this doit]
+ iwidgets::scrolledlistbox $itk_interior.cpid -visibleitems 30x15 \
+ -labeltext "Choose process" -labelpos nw \
+ -labelrelief groove -labelborderwidth 2 \
+ -ipadx 8 -ipady 6 -childsitepos s -hscrollmode none \
+ -textbackground white -exportselection 0 \
+ -selectioncommand [code $this select_pid] \
+ -dblclickcommand [code $this doit]
}
- # Filter entryfield
itk_component add pid_filter {
- iwidgets::entryfield [$itk_component(pid) childsite].filt \
- -labeltext "Filter:" \
- -foreground $::Colors(textfg) -textbackground $::Colors(textbg) \
+ iwidgets::entryfield [$itk_component(choose_pid) childsite].filt \
+ -labeltext Filter: -textbackground white \
-focuscommand [code $this clear_pid_selection] \
-command [code $this filter_pid_selection]
}
- $itk_component(pid_filter) insert 0 *
- # seperator
itk_component add pid_sep {
- frame [$itk_component(pid) childsite].sep \
+ frame [$itk_component(choose_pid) childsite].sep \
-height 2 -borderwidth 1 -relief sunken
}
# PID_ENTRY: this is the PID entry box. You can enter the pid
# by hand here, or click on the listbox to have it entered for you.
+
itk_component add pid_entry {
- iwidgets::entryfield [$itk_component(pid) childsite].lab \
- -labeltext "PID:" -validate numeric \
- -foreground $::Colors(textfg) -textbackground $::Colors(textbg) \
+ iwidgets::entryfield [$itk_component(choose_pid) childsite].lab \
+ -labeltext PID: -validate numeric -textbackground white \
-focuscommand [code $this clear_pid_selection]
}
- pack $itk_component(choose_pid) -fill x -side top -pady 4
pack $itk_component(pid_filter) -fill x -side top -pady 4
pack $itk_component(pid_sep) -fill x -side top -pady 8
pack $itk_component(pid_entry) -fill x -side bottom -pady 4
+
itk_component add symbol_label {
iwidgets::labeledframe $itk_interior.sym -labeltext "Choose Exec file" \
- -labelpos nw -relief groove -borderwidth 2 \
+ -labelpos nw -labelrelief groove -labelborderwidth 2 \
-ipadx 8 -ipady 6
}
itk_component add symbol_file {
- iwidgets::entryfield [$itk_interior.sym childsite].f -labeltext "File:" \
- -foreground $::Colors(textfg) -textbackground $::Colors(textbg)
+ iwidgets::entryfield [$itk_interior.sym childsite].f -labeltext File: \
+ -textbackground white
}
pack $itk_component(symbol_file) -pady 4 -padx 4 -fill x
-
# can't use the -state in the entryfield, 'cause that affects the
# label as well...
- #$itk_component(symbol_file) component entry configure -state disabled
+ $itk_component(symbol_file) component entry configure -state disabled
+
$itk_component(symbol_file) configure -state normal
$itk_component(symbol_file) insert 0 $::gdb_exe_name
- #$itk_component(symbol_file) configure -state disabled
+ $itk_component(symbol_file) configure -state disabled
itk_component add symbol_browse {
- button [$itk_component(symbol_file) childsite].br -text "Choose..." \
+ button [$itk_component(symbol_file) childsite].br -text Choose... \
-command [code $this choose_symbol_file]
}
pack $itk_component(symbol_browse) -pady 4 -padx 4 -ipadx 4
@@ -93,35 +84,38 @@ itcl::body AttachDlg::build_win {} {
}
itk_component add cancel {
- button $itk_component(button_box).cancel -text "Cancel" \
+ button $itk_component(button_box).cancel -text Cancel \
-command [code $this cancel]
}
itk_component add ok {
- button $itk_component(button_box).ok -text "OK" -command [code $this doit]
+ button $itk_component(button_box).ok -text OK -command [code $this doit]
}
-# if {$::gdb_exe_name == ""} {
-# $itk_component(ok) configure -state disabled
-# }
+ if {$::gdb_exe_name == ""} {
+ $itk_component(ok) configure -state disabled
+ }
::standard_button_box $itk_component(button_box)
- pack $itk_component(button_box) -side bottom -fill x -pady 4 -padx 4
- pack $itk_component(symbol_label) -side bottom -fill x -pady 4 -padx 4
- pack $itk_component(pid) -fill both -expand 1 -pady 4 -padx 4
+ pack $itk_component(button_box) -side bottom -fill x \
+ -pady 4 -padx 4
+ pack $itk_component(choose_pid) -fill both -expand 1 -pady 4 -padx 4
+ pack $itk_component(symbol_label) -fill x -pady 4 -padx 4
after idle [list update idletasks; $this list_pids]
+
}
# ------------------------------------------------------------------
# METHOD: doit - This accepts the attach command.
# ------------------------------------------------------------------
-itcl::body AttachDlg::doit {} {
+body AttachDlg::doit {} {
set AttachDlg::last_button 1
set AttachDlg::last_pid [$itk_component(pid_entry) get]
set AttachDlg::symbol_file [$itk_component(symbol_file) get]
+ debug "About to unpost"
unpost
}
@@ -129,7 +123,7 @@ itcl::body AttachDlg::doit {} {
# METHOD: cancel - unpost the dialog box without attaching.
# ------------------------------------------------------------------
-itcl::body AttachDlg::cancel {} {
+body AttachDlg::cancel {} {
set AttachDlg::last_button 0
set AttachDlg::last_pid {}
unpost
@@ -139,13 +133,13 @@ itcl::body AttachDlg::cancel {} {
# METHOD: choose_symbol_file - Query for a new symbol file.
# ------------------------------------------------------------------
-itcl::body AttachDlg::choose_symbol_file {} {
+body AttachDlg::choose_symbol_file {} {
set file [tk_getOpenFile -parent . -title "Load New Executable"]
if {$file != ""} {
$itk_component(symbol_file) configure -state normal
$itk_component(symbol_file) clear
$itk_component(symbol_file) insert 0 $file
-# $itk_component(symbol_file) configure -state disabled
+ $itk_component(symbol_file) configure -state disabled
$itk_component(ok) configure -state active
}
}
@@ -158,18 +152,8 @@ itcl::body AttachDlg::choose_symbol_file {} {
# point we should steal some C code to do it by hand.
# ------------------------------------------------------------------
-itcl::body AttachDlg::list_pids {{pattern *}} {
- global gdbtk_platform
-
- switch $gdbtk_platform(os) {
- Linux {
- set ps_cmd "ps axw"
- }
- default {
- set ps_cmd "ps w"
- }
- }
- if {[catch {::open "|$ps_cmd" r} psH]} {
+body AttachDlg::list_pids {{expr {}}} {
+ if {[catch {::open "|ps w" r} psH]} {
set errTxt "Could not exec ps: $psH
You will have to enter the PID by hand."
ManagedWin::open WarningDlg -message [list $errTxt]
@@ -178,7 +162,7 @@ You will have to enter the PID by hand."
gets $psH header
set nfields [llength $header]
- set nfields_m_1 [expr {$nfields - 1}]
+ set nfields_m_1 [expr $nfields - 1]
set regexp {^ *([^ ]*) +}
for {set i 1} {$i < $nfields_m_1} {incr i} {
append regexp {[^ ]* +}
@@ -190,7 +174,7 @@ You will have to enter the PID by hand."
while {[gets $psH line] >= 0} {
regexp $regexp $line dummy PID COMMAND
- if {[string match $pattern $COMMAND]} {
+ if {$expr == "" || [regexp $expr $COMMAND dummy]} {
lappend pid_list [list $PID $COMMAND]
$itk_component(choose_pid) insert end $COMMAND
}
@@ -199,6 +183,7 @@ You will have to enter the PID by hand."
close $psH
$itk_component(choose_pid) selection set 0
select_pid
+
}
# ------------------------------------------------------------------
@@ -206,7 +191,7 @@ You will have to enter the PID by hand."
# and insert the associated PID into the entry form.
# ------------------------------------------------------------------
-itcl::body AttachDlg::select_pid {} {
+body AttachDlg::select_pid {} {
set hit [$itk_component(choose_pid) curselection]
if {$hit != ""} {
$itk_component(pid_entry) clear
@@ -218,7 +203,7 @@ itcl::body AttachDlg::select_pid {} {
# METHOD: clear_pid_selection - Clear the current PID selection.
# ------------------------------------------------------------------
-itcl::body AttachDlg::clear_pid_selection {} {
+body AttachDlg::clear_pid_selection {} {
$itk_component(choose_pid) selection clear 0 end
$itk_component(pid_entry) selection range 0 end
}
@@ -227,6 +212,7 @@ itcl::body AttachDlg::clear_pid_selection {} {
# METHOD: filter_pid_selection - Filters the pid box.
# ------------------------------------------------------------------
-itcl::body AttachDlg::filter_pid_selection {} {
+body AttachDlg::filter_pid_selection {} {
+
list_pids [$itk_component(pid_filter) get]
}
diff --git a/gdb/gdbtk/library/attachdlg.ith b/gdb/gdbtk/library/attachdlg.ith
index 71ee4876eb0..b0b6a1131af 100644
--- a/gdb/gdbtk/library/attachdlg.ith
+++ b/gdb/gdbtk/library/attachdlg.ith
@@ -6,7 +6,7 @@
# ----------------------------------------------------------------------
# Copyright (C) 1999 Cygnus Solutions
#
-itcl::class AttachDlg {
+class AttachDlg {
inherit ModalDialog ManagedWin
public {
@@ -21,7 +21,7 @@ itcl::class AttachDlg {
method cancel {}
method choose_symbol_file {}
method doit {}
- method list_pids {{pattern *}}
+ method list_pids {{expr {}}}
method select_pid {}
method clear_pid_selection {}
method filter_pid_selection {}
diff --git a/gdb/gdbtk/library/blockframe.itb b/gdb/gdbtk/library/blockframe.itb
index 6819c1f3847..2076f5dfc65 100644
--- a/gdb/gdbtk/library/blockframe.itb
+++ b/gdb/gdbtk/library/blockframe.itb
@@ -1,5 +1,5 @@
# Block and frame class implementations for GDBtk.
-# Copyright (C) 1997, 1998, 1999 Cygnus Solutions
+# Copyright 1997, 1998, 1999 Cygnus Solutions
#
# This program is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License (GPL) as published by
@@ -14,7 +14,7 @@
# ------------------------------------------------------------------
# Block
# ------------------------------------------------------------------
-itcl::body Block::constructor {start end args} {
+body Block::constructor {start end args} {
# Record runtime info about this block
set _start $start
@@ -24,7 +24,7 @@ itcl::body Block::constructor {start end args} {
}
# Destroy ourself.
-itcl::body Block::destructor {} {
+body Block::destructor {} {
# Each block is responsible for destroying its
# variables and removing them from the list of
@@ -36,12 +36,12 @@ itcl::body Block::destructor {} {
# Return a list of variables defined in this block
# This list is determined when we are created.
-itcl::body Block::variables {} {
+body Block::variables {} {
return $_variables
}
# Find the new variables for this block.
-itcl::body Block::_findVariables {} {
+body Block::_findVariables {} {
# Find the new variables for this block.
set variables [gdb_block_variables $_start $_end]
@@ -59,7 +59,7 @@ itcl::body Block::_findVariables {} {
return $vars
}
-itcl::body Block::update {} {
+body Block::update {} {
set changed {}
foreach var $_variables {
@@ -69,7 +69,7 @@ itcl::body Block::update {} {
return $changed
}
-itcl::body Block::info {} {
+body Block::info {} {
return [list $_start $_end]
}
@@ -77,7 +77,7 @@ itcl::body Block::info {} {
# ------------------------------------------------------------------
# Frame
# ------------------------------------------------------------------
-itcl::body Frame::constructor {addr} {
+body Frame::constructor {addr} {
set _addr $addr
@@ -87,14 +87,14 @@ itcl::body Frame::constructor {addr} {
}
-itcl::body Frame::destructor {} {
+body Frame::destructor {} {
# destroy our own blocks
foreach block $_blocks {
_removeBlock $block
}
}
-itcl::body Frame::_removeBlock {blockObj} {
+body Frame::_removeBlock {blockObj} {
set i [lsearch $_blocks $blockObj]
if {$i != -1} {
@@ -103,7 +103,7 @@ itcl::body Frame::_removeBlock {blockObj} {
}
}
-itcl::body Frame::_addBlock {block} {
+body Frame::_addBlock {block} {
set start [lindex $block 0]
set end [lindex $block 1]
@@ -113,14 +113,14 @@ itcl::body Frame::_addBlock {block} {
return $b
}
-itcl::body Frame::_createBlocks {blocks} {
+body Frame::_createBlocks {blocks} {
foreach block $blocks {
set b [_addBlock $block]
}
}
-itcl::body Frame::update {} {
+body Frame::update {} {
set vars {}
foreach block $_blocks {
@@ -130,7 +130,7 @@ itcl::body Frame::update {} {
return $vars
}
-itcl::body Frame::variables {} {
+body Frame::variables {} {
set vars {}
foreach block $_blocks {
@@ -140,7 +140,7 @@ itcl::body Frame::variables {} {
return $vars
}
-itcl::body Frame::new {} {
+body Frame::new {} {
# find any new variables. So get a list of all blocks,
# eliminate duplicates, and get those variables.
@@ -159,14 +159,14 @@ itcl::body Frame::new {} {
return $new
}
-itcl::body Frame::deleteOld {} {
+body Frame::deleteOld {} {
foreach block [_oldBlocks] {
_removeBlock $block
}
}
-itcl::body Frame::_oldBlocks {} {
+body Frame::_oldBlocks {} {
set blocks [gdb_get_blocks]
set oldObjs $_blocks
@@ -183,7 +183,7 @@ itcl::body Frame::_oldBlocks {} {
return $oldObjs
}
-itcl::body Frame::old {} {
+body Frame::old {} {
# All the variables in the blocks in old are now gone...
# We don't remove blocks here, since the frontend viewer
@@ -198,7 +198,7 @@ itcl::body Frame::old {} {
return $vars
}
-itcl::body Frame::_findBlock {block} {
+body Frame::_findBlock {block} {
foreach b $_blocks {
set info [$b info]
@@ -210,7 +210,7 @@ itcl::body Frame::_findBlock {block} {
return ""
}
-itcl::body Frame::_findBlockIndex {block} {
+body Frame::_findBlockIndex {block} {
set i 0
foreach b $_blocks {
diff --git a/gdb/gdbtk/library/blockframe.ith b/gdb/gdbtk/library/blockframe.ith
index 2a2457820d9..a147f7c60a7 100644
--- a/gdb/gdbtk/library/blockframe.ith
+++ b/gdb/gdbtk/library/blockframe.ith
@@ -1,5 +1,5 @@
# Class definitions for blocks and frames for GDBtk.
-# Copyright (C) 1997, 1998, 1999 Cygnus Solutions
+# Copyright 1997, 1998, 1999 Cygnus Solutions
#
# This program is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License (GPL) as published by
@@ -11,7 +11,7 @@
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
-itcl::class Block {
+class Block {
public {
method constructor {start end args}
@@ -33,7 +33,7 @@ itcl::class Block {
}
}
-itcl::class Frame {
+class Frame {
public {
method constructor {addr}
diff --git a/gdb/gdbtk/library/bpwin.itb b/gdb/gdbtk/library/bpwin.itb
index 027eba8e14a..17f85c05dc0 100644
--- a/gdb/gdbtk/library/bpwin.itb
+++ b/gdb/gdbtk/library/bpwin.itb
@@ -1,5 +1,5 @@
-# Breakpoint window for Insight.
-# Copyright (C) 1997, 1998, 1999, 2001, 2002, 2003, 2008 Red Hat, Inc.
+# Breakpoint window for GDBtk.
+# Copyright 1997, 1998, 1999 Cygnus Solutions
#
# This program is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License (GPL) as published by
@@ -15,9 +15,10 @@
# ------------------------------------------------------------------
# CONSTRUCTOR: create the main breakpoint window
# ------------------------------------------------------------------
-itcl::body BpWin::constructor {args} {
+body BpWin::constructor {args} {
window_name "Breakpoints" "BPs"
+ add_hook gdb_breakpoint_change_hook "$this update"
if {[pref getd gdb/bp/menu] != ""} {
set mbar 0
}
@@ -25,59 +26,52 @@ itcl::body BpWin::constructor {args} {
debug "Ready to build"
build_win
eval itk_initialize $args
-
- # The scrolledframe uses a canvas, which doesn't properly
- # calculate an initial size, so we must set a default
- # window size here. ManagedWin could override this still
- # if there is a user preference for the geometry.
- wm geometry $_top 350x165
debug "done building"
}
# ------------------------------------------------------------------
# DESTRUCTOR: destroy the breakpoint window
# ------------------------------------------------------------------
-itcl::body BpWin::destructor {} {}
+body BpWin::destructor {} {
+ remove_hook gdb_breakpoint_change_hook "$this update"
+}
# ------------------------------------------------------------------
# METHOD: build_win - build the main breakpoint window
# ------------------------------------------------------------------
-itcl::body BpWin::build_win {} {
- global _bp_en _bp_disp
- set bg1 $::Colors(bg)
-
- set hsmode dynamic
- set vsmode dynamic
+body BpWin::build_win {} {
+ global _bp_en _bp_disp tixOption tcl_platform
+ set bg1 $tixOption(input1_bg)
- # FIXME: The iwidgets scrolled frame is pretty useless.
- # When we get BLT, use its hiertable to do this.
- itk_component add sframe {
- iwidgets::scrolledframe $itk_interior.sf \
- -hscrollmode $hsmode -vscrollmode $vsmode
+ frame $itk_interior.f -bg $bg1
+ if {$tcl_platform(platform) == "windows"} {
+ tixScrolledWindow $itk_interior.f.sw -scrollbar both -sizebox 1
+ } else {
+ tixScrolledWindow $itk_interior.f.sw -scrollbar auto
}
-
- set twin [$itk_component(sframe) childsite]
+ set twin [$itk_interior.f.sw subwidget window]
+ $twin configure -bg $bg1
# write header
if {$tracepoints} {
label $twin.num0 -text "Num" -relief raised -bd 2 -anchor center \
- -font global/fixed
+ -font src-font
}
label $twin.thread0 -text "Thread" -relief raised -bd 2 -anchor center \
- -font global/fixed
+ -font src-font
label $twin.addr0 -text "Address" -relief raised -bd 2 -anchor center \
- -font global/fixed
+ -font src-font
label $twin.file0 -text "File" -relief raised -bd 2 -anchor center \
- -font global/fixed
+ -font src-font
label $twin.line0 -text "Line" -relief raised -bd 2 -anchor center \
- -font global/fixed
+ -font src-font
label $twin.func0 -text "Function" -relief raised -bd 2 -anchor center \
- -font global/fixed
+ -font src-font
if {$tracepoints} {
label $twin.pass0 -text "PassCount" -relief raised -borderwidth 2 \
- -anchor center -font global/fixed
+ -anchor center -font src-font
grid x $twin.num0 $twin.addr0 $twin.file0 $twin.line0 $twin.func0 $twin.pass0 \
-sticky new
} else {
@@ -174,43 +168,42 @@ itcl::body BpWin::build_win {} {
if { $tracepoints == 0 } {
# insert all breakpoints
foreach i [gdb_get_breakpoint_list] {
- set e [BreakpointEvent \#auto -action create -number $i]
- bp_add $e
- delete object $e
+ bp_add $i
}
} else {
# insert all tracepoints
foreach i [gdb_get_tracepoint_list] {
- set e [TracepointEvent \#auto -action create -number $i]
- bp_add $e 1
- delete object $e
+ bp_add $i 1
}
}
- pack $itk_component(sframe) -side left -expand true -fill both
+ pack $itk_interior.f.sw -side left -expand true -fill both
+ pack $itk_interior.f -side top -expand true -fill both
+
}
# ------------------------------------------------------------------
# METHOD: bp_add - add a breakpoint entry
# ------------------------------------------------------------------
-itcl::body BpWin::bp_add {bp_event {tracepoint 0}} {
- global _bp_en _bp_disp gdbtk_platform _files
-
- set number [$bp_event get number]
- set thread [$bp_event get thread]
- set disposition [$bp_event get disposition]
- set file [$bp_event get file]
-
+body BpWin::bp_add { bpnum {tracepoint 0}} {
+ global _bp_en _bp_disp tcl_platform _files
+
if {$tracepoint} {
- set diposition tracepoint
+ set bpinfo [gdb_get_tracepoint_info $bpnum]
+ lassign $bpinfo file func line pc enabled pass_count \
+ step_count thread hit_count actions
+ set disposition tracepoint
set bptype tracepoint
} else {
+ set bpinfo [gdb_get_breakpoint_info $bpnum]
+ lassign $bpinfo file func line pc type enabled disposition \
+ ignore_count commands cond thread hit_count
set bptype breakpoint
}
- debug "bp_add bpnum=$number thread=$thread show=$show_threads"
+ debug "bp_add bpnum=$bpnum thread=$thread show=$show_threads"
set i $next_row
- set _bp_en($i) [$bp_event get enabled]
+ set _bp_en($i) $enabled
set _bp_disp($i) $disposition
set temp($i) ""
switch $disposition {
@@ -227,19 +220,18 @@ itcl::body BpWin::bp_add {bp_event {tracepoint 0}} {
if {$thread != "-1"} {set color [pref get gdb/src/thread_fg]}
- if {$gdbtk_platform(platform) == "windows"} {
- checkbutton $twin.en$i -relief flat -variable _bp_en($i) \
+ if {$tcl_platform(platform) == "windows"} {
+ checkbutton $twin.en$i -relief flat -variable _bp_en($i) -bg $bg1 \
-activebackground $bg1 -command "$this bp_able $i" -fg $color
} else {
- checkbutton $twin.en$i -relief flat -variable _bp_en($i) \
- -command "$this bp_able $i" -activebackground $bg1 \
- -selectcolor $color -highlightbackground $bg1
+ checkbutton $twin.en$i -relief flat -variable _bp_en($i) -selectcolor $color \
+ -command "$this bp_able $i" -bg $bg1 -activebackground $bg1
}
if {$tracepoints} {
- label $twin.num$i -text "$number " -relief flat -anchor w -font global/fixed
+ label $twin.num$i -text "$bpnum " -relief flat -anchor e -font src-font -bg $bg1
}
- label $twin.addr$i -text "[gdb_CA_to_TAS [$bp_event get address]] " -relief flat -anchor w -font global/fixed -bg $bg1
+ label $twin.addr$i -text "$pc " -relief flat -anchor e -font src-font -bg $bg1
if {[info exists _files(short,$file)]} {
set file $_files(short,$file)
} else {
@@ -248,13 +240,14 @@ itcl::body BpWin::bp_add {bp_event {tracepoint 0}} {
}
if {$show_threads} {
if {$thread == "-1"} {set thread "ALL"}
- label $twin.thread$i -text "$thread " -relief flat -anchor w -font global/fixed
+ label $twin.thread$i -text "$thread " -relief flat -anchor e -font src-font -bg $bg1
}
- label $twin.file$i -text "$file " -relief flat -anchor w -font global/fixed
- label $twin.line$i -text "[$bp_event get line] " -relief flat -anchor w -font global/fixed
- label $twin.func$i -text "[$bp_event get function] " -relief flat -anchor w -font global/fixed
+ label $twin.file$i -text "$file " -relief flat -anchor e -font src-font -bg $bg1
+ label $twin.line$i -text "$line " -relief flat -anchor e -font src-font -bg $bg1
+ label $twin.func$i -text "$func " -relief flat -anchor e -font src-font -bg $bg1
+
if {$tracepoints} {
- label $twin.pass$i -text "[$bp_event get pass_count] " -relief flat -anchor w -font global/fixed
+ label $twin.pass$i -text "$pass_count " -relief flat -anchor e -font src-font -bg $bg1
}
if {$mbar} {
@@ -264,7 +257,6 @@ itcl::body BpWin::bp_add {bp_event {tracepoint 0}} {
foreach thing $zz {
bind $twin.${thing}${i} <1> "$this bp_select $i"
bind $twin.${thing}${i} <Double-1> "$this goto_bp $i"
- bind $twin.${thing}${i} <3> [code $this _select_and_popup $i %X %Y]
}
}
@@ -284,7 +276,7 @@ itcl::body BpWin::bp_add {bp_event {tracepoint 0}} {
# This used to be the last row. Fix it vertically again.
grid rowconfigure $twin $i -weight 0
- set index_to_bpnum($i) $number
+ set index_to_bpnum($i) $bpnum
set Index_to_bptype($i) $bptype
incr i
set next_row $i
@@ -295,7 +287,7 @@ itcl::body BpWin::bp_add {bp_event {tracepoint 0}} {
# METHOD: bp_store - stores away the breakpoints in a file of gdb
# commands
# ------------------------------------------------------------------
-itcl::body BpWin::bp_store {} {
+body BpWin::bp_store {} {
set out_file [tk_getSaveFile]
if {$out_file == ""} {
return
@@ -307,21 +299,18 @@ itcl::body BpWin::bp_store {} {
foreach breakpoint [gdb_get_breakpoint_list] {
# This is an lassign
foreach {file function line_no address type \
- enable_p disp ignore cmds cond thread hit_count user_spec} \
+ enable_p disp ignore cmds thread hit_count} \
[gdb_get_breakpoint_info $breakpoint] {
break
}
- if {$user_spec != ""} {
- set bp_specifier $user_spec
- } elseif {$file != ""} {
+ if {$file != ""} {
set filename [file tail $file]
set bp_specifier $filename:$line_no
} else {
set bp_specifier *$address
}
- # FIXME: doesn't handle watchpoints.
if {[string compare $disp "delete"] == 0} {
puts $outH "tbreak $bp_specifier"
} else {
@@ -342,7 +331,7 @@ itcl::body BpWin::bp_store {} {
# METHOD: bp_restore - restore the breakpoints from a file of gdb
# commands
# ------------------------------------------------------------------
-itcl::body BpWin::bp_restore {} {
+body BpWin::bp_restore {} {
set inH [tk_getOpenFile]
if {$inH == ""} {
return
@@ -356,8 +345,8 @@ itcl::body BpWin::bp_restore {} {
# ------------------------------------------------------------------
# METHOD: bp_select - select a row in the grid
# ------------------------------------------------------------------
-itcl::body BpWin::bp_select { r } {
- global _bp_en _bp_disp
+body BpWin::bp_select { r } {
+ global tixOption _bp_en _bp_disp
set zz [list addr file func line]
if {$tracepoints} {lappend zz num pass}
@@ -367,7 +356,8 @@ itcl::body BpWin::bp_select { r } {
set i $selected
foreach thing $zz {
- $twin.${thing}${i} configure -fg $::Colors(fg) -bg $bg1
+ $twin.${thing}${i} configure -fg $tixOption(fg) -bg $bg1
+ bind $twin.${thing}${i} <3> break
}
}
@@ -385,11 +375,16 @@ itcl::body BpWin::bp_select { r } {
$itk_interior.m.bp entryconfigure "Disabled" -state disabled
$itk_interior.m.bp entryconfigure "Remove" -state disabled
+ foreach thing $zz {
+ bind $twin.${thing}${r} <3> break
+ }
+
return
}
foreach thing $zz {
- $twin.${thing}${r} configure -fg $::Colors(sfg) -bg $::Colors(sbg)
+ $twin.${thing}${r} configure -fg $tixOption(select_fg) -bg $tixOption(select_bg)
+ bind $twin.${thing}${r} <3> "tk_popup $Menu %X %Y"
}
if {$tracepoints == 0} {
@@ -420,41 +415,27 @@ itcl::body BpWin::bp_select { r } {
}
# ------------------------------------------------------------------
-# NAME: private method BpWin::_select_and_popup
-# DESCRIPTION: Select the given breakpoint and popup the options
-# menu at the given location.
-#
-# ARGUMENTS: None
-# RETURNS: Nothing
-# ------------------------------------------------------------------
-itcl::body BpWin::_select_and_popup {bp X Y} {
- if {$selected != $bp} {
- bp_select $bp
- }
- tk_popup $Menu $X $Y
-}
-
-# ------------------------------------------------------------------
# METHOD: bp_modify - modify a breakpoint entry
# ------------------------------------------------------------------
-itcl::body BpWin::bp_modify {bp_event {tracepoint 0}} {
- global _bp_en _bp_disp gdbtk_platform _files
-
- set number [$bp_event get number]
- set thread [$bp_event get thread]
- set disposition [$bp_event get disposition]
- set file [$bp_event get file]
+body BpWin::bp_modify { bpnum {tracepoint 0} } {
+ global _bp_en _bp_disp tcl_platform _files
if {$tracepoint} {
+ set bpinfo [gdb_get_tracepoint_info $bpnum]
+ lassign $bpinfo file func line pc enabled pass_count \
+ step_count thread hit_count actions
set disposition tracepoint
set bptype tracepoint
} else {
+ set bpinfo [gdb_get_breakpoint_info $bpnum]
+ lassign $bpinfo file func line pc type enabled disposition \
+ ignore_count commands cond thread hit_count
set bptype breakpoint
}
set found 0
for {set i 1} {$i < $next_row} {incr i} {
- if { $number == $index_to_bpnum($i)
+ if { $bpnum == $index_to_bpnum($i)
&& "$Index_to_bptype($i)" == "$bptype"} {
incr found
break
@@ -462,12 +443,12 @@ itcl::body BpWin::bp_modify {bp_event {tracepoint 0}} {
}
if {!$found} {
- debug "ERROR: breakpoint number $number not found!"
+ debug "ERROR: breakpoint number $bpnum not found!"
return
}
- if {$_bp_en($i) != [$bp_event get enabled]} {
- set _bp_en($i) [$bp_event get enabled]
+ if {$_bp_en($i) != $enabled} {
+ set _bp_en($i) $enabled
}
if {$_bp_disp($i) != $disposition} {
@@ -485,15 +466,15 @@ itcl::body BpWin::bp_modify {bp_event {tracepoint 0}} {
if {$thread != "-1"} {set color [pref get gdb/src/thread_fg]}
- if {$gdbtk_platform(platform) == "windows"} then {
+ if {$tcl_platform(platform) == "windows"} then {
$twin.en$i configure -fg $color
} else {
$twin.en$i configure -selectcolor $color
}
if {$tracepoints} {
- $twin.num$i configure -text "$number "
+ $twin.num$i configure -text "$bpnum "
}
- $twin.addr$i configure -text "[gdb_CA_to_TAS [$bp_event get address]] "
+ $twin.addr$i configure -text "$pc "
if {[info exists _files(short,$file)]} {
set file $_files(short,$file)
} else {
@@ -505,17 +486,17 @@ itcl::body BpWin::bp_modify {bp_event {tracepoint 0}} {
$twin.thread$i configure -text "$thread "
}
$twin.file$i configure -text "$file "
- $twin.line$i configure -text "[$bp_event get line] "
- $twin.func$i configure -text "[$bp_event get function] "
+ $twin.line$i configure -text "$line "
+ $twin.func$i configure -text "$func "
if {$tracepoints} {
- $twin.pass$i configure -text "[$bp_event get pass_count] "
+ $twin.pass$i configure -text "$pass_count "
}
}
# ------------------------------------------------------------------
# METHOD: bp_able - enable/disable a breakpoint
# ------------------------------------------------------------------
-itcl::body BpWin::bp_able { i } {
+body BpWin::bp_able { i } {
global _bp_en
bp_select $i
@@ -538,7 +519,7 @@ itcl::body BpWin::bp_able { i } {
# ------------------------------------------------------------------
# METHOD: bp_remove - remove a breakpoint
# ------------------------------------------------------------------
-itcl::body BpWin::bp_remove { i } {
+body BpWin::bp_remove { i } {
bp_select $i
@@ -553,7 +534,7 @@ itcl::body BpWin::bp_remove { i } {
# ------------------------------------------------------------------
# METHOD: bp_type - change the breakpoint type (disposition)
# ------------------------------------------------------------------
-itcl::body BpWin::bp_type { i } {
+body BpWin::bp_type { i } {
if {$Index_to_bptype($i) != "breakpoint"} {
return
@@ -563,7 +544,7 @@ itcl::body BpWin::bp_type { i } {
#debug "bp_type $i $bpnum"
set bpinfo [gdb_get_breakpoint_info $bpnum]
lassign $bpinfo file func line pc type enabled disposition \
- ignore_count commands cond thread hit_count user_spec
+ ignore_count commands cond thread hit_count
bp_select $i
switch $disposition {
delete {
@@ -581,10 +562,9 @@ itcl::body BpWin::bp_type { i } {
# ------------------------------------------------------------------
# METHOD: bp_delete - delete a breakpoint
# ------------------------------------------------------------------
-itcl::body BpWin::bp_delete {bp_event} {
- set number [$bp_event get number]
+body BpWin::bp_delete { bpnum } {
for {set i 1} {$i < $next_row} {incr i} {
- if { $number == $index_to_bpnum($i) } {
+ if { $bpnum == $index_to_bpnum($i) } {
if {$tracepoints} {
grid forget $twin.en$i $twin.num$i $twin.addr$i $twin.file$i \
$twin.line$i $twin.func$i $twin.pass$i
@@ -607,43 +587,29 @@ itcl::body BpWin::bp_delete {bp_event} {
}
# ------------------------------------------------------------------
-# PUBLIC METHOD: breakpoint - Update widget when a breakpoint
-# event is received from the backend.
+# METHOD: update - update widget when a breakpoint changes
# ------------------------------------------------------------------
-itcl::body BpWin::breakpoint {bp_event} {
+body BpWin::update {action bpnum addr {linenum {}} {file {}} {type 0} args} {
+ #debug "bp update $action $bpnum $type"
- set action [$bp_event get action]
- #debug "bp update $action [$bp_event get number] [$bp_event get type]"
-
- switch $action {
- modify { bp_modify $bp_event 0 }
- create { bp_add $bp_event 0 }
- delete { bp_delete $bp_event }
- default { dbug E "Unknown breakpoint action: $action" }
+ if {$type == "tracepoint"} {
+ set tp 1
+ } else {
+ set tp 0
}
-}
-
-# ------------------------------------------------------------------
-# METHOD: tracepoint - Update widget when a tracepoint event
-# is received from the backend.
-# ------------------------------------------------------------------
-itcl::body BpWin::tracepoint {tp_event} {
-
- set action [$tp_event get action]
- #debug "tp update $action [$tp_event get number]"
switch $action {
- modify { bp_modify $tp_event 1 }
- create { bp_add $tp_event 1 }
- delete { bp_delete $tp_event }
- default { dbug E "Unknown tracepoint action: $action" }
+ modify { bp_modify $bpnum $tp}
+ create { bp_add $bpnum $tp}
+ delete { bp_delete $bpnum }
+ default { debug "Unknown breakpoint action: $action" }
}
}
# ------------------------------------------------------------------
# METHOD: bp_all - perform a command on all breakpoints
# ------------------------------------------------------------------
-itcl::body BpWin::bp_all { command } {
+body BpWin::bp_all { command } {
if {!$tracepoints} {
# Do all breakpoints
@@ -682,7 +648,7 @@ itcl::body BpWin::bp_all { command } {
# METHOD: get_actions - pops up the add trace dialog on a selected
# tracepoint
# ------------------------------------------------------------------
-itcl::body BpWin::get_actions {bpnum} {
+body BpWin::get_actions {bpnum} {
set bpnum $index_to_bpnum($bpnum)
set bpinfo [gdb_get_tracepoint_info $bpnum]
lassign $bpinfo file func line pc enabled pass_count \
@@ -695,7 +661,7 @@ itcl::body BpWin::get_actions {bpnum} {
# ------------------------------------------------------------------
# METHOD: toggle_threads - callback when show_threads is toggled
# ------------------------------------------------------------------
-itcl::body BpWin::toggle_threads {} {
+body BpWin::toggle_threads {} {
set show_threads [pref get gdb/bp/show_threads]
reconfig
}
@@ -703,11 +669,9 @@ itcl::body BpWin::toggle_threads {} {
# ------------------------------------------------------------------
# METHOD: reconfig - used when preferences change
# ------------------------------------------------------------------
-itcl::body BpWin::reconfig {} {
+body BpWin::reconfig {} {
if {[winfo exists $itk_interior.f]} { destroy $itk_interior.f }
if {[winfo exists $itk_interior.m]} { destroy $itk_interior.m }
- if {[winfo exists $itk_interior.sbox]} { destroy $itk_interior.sbox }
- if {[winfo exists $itk_interior.sf]} { destroy $itk_interior.sf }
if {[winfo exists $itk_interior.pop]} { destroy $itk_interior.pop }
build_win
}
@@ -715,7 +679,7 @@ itcl::body BpWin::reconfig {} {
# ------------------------------------------------------------------
# METHOD: goto_bp - show bp in source window
# ------------------------------------------------------------------
-itcl::body BpWin::goto_bp {r} {
+body BpWin::goto_bp {r} {
set bpnum $index_to_bpnum($r)
if {$tracepoints} {
set bpinfo [gdb_get_tracepoint_info $bpnum]
@@ -724,5 +688,10 @@ itcl::body BpWin::goto_bp {r} {
}
set pc [lindex $bpinfo 3]
- SrcWin::choose_and_display BROWSE_TAG [gdb_loc *$pc]
+ # !! FIXME: multiple source windows?
+ set src [lindex [ManagedWin::find SrcWin] 0]
+ set info [gdb_loc *$pc]
+ $src location BROWSE_TAG $info
}
+
+
diff --git a/gdb/gdbtk/library/bpwin.ith b/gdb/gdbtk/library/bpwin.ith
index fa005a65c62..d3b56f893ab 100644
--- a/gdb/gdbtk/library/bpwin.ith
+++ b/gdb/gdbtk/library/bpwin.ith
@@ -1,5 +1,5 @@
-# Breakpoint window class definition for Insight
-# Copyright (C) 1997, 1998, 1999, 2001 Red Hat, Inc.
+# Breakpoint window class definition for GDBtk.
+# Copyright 1997, 1998, 1999 Cygnus Solutions
#
# This program is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License (GPL) as published by
@@ -12,7 +12,7 @@
# GNU General Public License for more details.
-itcl::class BpWin {
+class BpWin {
inherit EmbeddedWin GDBWin
public {
@@ -26,15 +26,13 @@ itcl::class BpWin {
method bp_restore {}
method bp_store {}
method bp_type { i }
+ method update {action bpnum addr {linenum {}} {file {}} {type 0} args}
method bp_all { command }
method get_actions {bpnum}
method toggle_threads {}
method reconfig {}
method goto_bp {r}
- # GDB Events
- method breakpoint {event}
- method tracepoint {event}
}
private {
@@ -50,10 +48,9 @@ itcl::class BpWin {
variable show_threads ;#cached copy of [pref get gdb/bp/show_threads]
method build_win {}
- method bp_add {bp_event {tracepoint 0}}
- method bp_modify {bp_event {tracepoint 0}}
- method bp_delete {bp_event}
- method _select_and_popup {bp X Y}
+ method bp_add { bpnum {tracepoint 0}}
+ method bp_modify { bpnum {tracepoint 0} }
+ method bp_delete { bpnum }
}
}
diff --git a/gdb/gdbtk/library/browserwin.itb b/gdb/gdbtk/library/browserwin.itb
index d8f42db6faa..0b4ff2e177e 100644
--- a/gdb/gdbtk/library/browserwin.itb
+++ b/gdb/gdbtk/library/browserwin.itb
@@ -1,5 +1,5 @@
-# Browswer window for Insight.
-# Copyright (C) 1998, 1999, 2001, 2002, 2003 Red Hat, Inc.
+# Browswer window for GDBtk.
+# Copyright 1998, 1999 Cygnus Solutions
#
# This program is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License (GPL) as published by
@@ -13,38 +13,50 @@
# ----------------------------------------------------------------------
-# Implements Browser window for Insight
+# Implements Browser window for gdb
#
# ----------------------------------------------------------------------
-option add *BrowserWin.textBackground $::Colors(textbg)
-
# ------------------------------------------------------------------
# CONSTRUCTOR - create new browser window
# ------------------------------------------------------------------
-itcl::body BrowserWin::constructor {args} {
- debug
+
+option add *BrowserWin.textBackground white
+
+body BrowserWin::constructor {args} {
#eval itk_initialize $args
window_name "Function Browser"
- set _layout [pref get gdb/browser/layout]
set Current(filename) {}
set Current(function) {}
_build_win
eval itk_initialize $args
+
+ # Create the toplevel binding for this class
+ bind Configure_Browser_$this <Configure> [code $this _resize]
+
add_hook file_changed_hook [code $this _fill_file_box]
}
# ------------------------------------------------------------------
# DESTRUCTOR - destroy window containing widget
# ------------------------------------------------------------------
-itcl::body BrowserWin::destructor {} {
- debug
+body BrowserWin::destructor {} {
+
+ if {$resize_after != ""} {
+ after cancel $resize_after
+ }
if {$filter_trace_after != ""} {
after cancel $filter_trace_after
}
+ if {$MoreVisible} {
+ pref set gdb/browser/view_is_open 1
+ } else {
+ pref set gdb/browser/view_is_open 0
+ }
+
remove_hook file_changed_hook [code $this _fill_file_box]
trace vdelete [pref varname gdb/search/last_symbol] \
w [code $this _filter_trace_proc]
@@ -53,65 +65,320 @@ itcl::body BrowserWin::destructor {} {
# ------------------------------------------------------------------
# METHOD: _build_win - build the main browser window
# ------------------------------------------------------------------
-itcl::body BrowserWin::_build_win {} {
- debug
-
- # popup menu
- itk_component add popup {
- menu $itk_interior.pop -tearoff 0
- } {}
- set pop $itk_component(popup)
- $pop add command -label "Toggle Layout" -command [code $this _switch_layout]
- $pop add command -label "Help" -command "open_help browser.html"
- $pop add separator
- $pop add command -label "Close" -command "destroy [winfo toplevel $itk_interior]"
- bind [winfo toplevel $itk_interior] <3> "tk_popup $itk_component(popup) %X %Y"
-
- # Four Main Frames: filter, files, functions, and view (source)
- # Their layout depends on _layout
-
- if {$_layout == 1} {
- set p [cyg::panedwindow $itk_interior.p -orient vertical -height 5i \
- -width 5i]
- $p add left
- set p2 [cyg::panedwindow [$p childsite left].p]
-
- $p2 add file
- _build_file_frame [$p2 childsite file]
-
- $p2 add filter
- set f [frame [$p2 childsite filter].f]
- _build_filter_frame $f
- _build_function_frame $f
- pack $f -fill both -expand yes
- pack $p2 -fill both -expand yes
-
- $p add view
- _build_view_frame [$p childsite view]
+body BrowserWin::_build_win {} {
+ global PREFS_state gdb_ImageDir
- } else {
- set p [cyg::panedwindow $itk_interior.p -height 5i -width 5i]
- $p add top
- set f [frame [$p childsite top].f]
- _build_filter_frame $f
+ # Three frames: regexp, listboxes, and drop-down pane
+
+ itk_component add filter {
+ iwidgets::labeledframe $itk_interior.filter -labeltext "Filter" \
+ -labelrelief groove -labelborderwidth 2 -ipadx 6 -ipady 4
+ }
+
+ append labelUpdateCode [$itk_component(filter) clientHandlesConfigure 1] "\n"
+
+ itk_component add browser {
+ frame $itk_interior.browser
+ }
+
+ itk_component add view {
+ frame $itk_interior.view
+ }
+
+ # Set up the contents of the Filter frame
+
+ itk_component add filt_label {
+ label [$itk_component(filter) childsite].lbl -text {Show if function } \
+ -font src-font
+ }
+
+ itk_component add filt_type {
+ combobox::combobox [$itk_component(filter) childsite].type -height 4 \
+ -width 15 -editable 0 \
+ -command [code $this _set_filter_mode] \
+ -font src-font
+ } { }
+
+ # Fill the filter mode combo-box
+
+ foreach elem $filter_modes {
+ $itk_component(filt_type) list insert end $elem
+ }
+
+ set cur_filter_mode [pref get gdb/search/filter_mode]
+ if {[lsearch $filter_modes $cur_filter_mode] < 0} {
+ set cur_filter_mode [lindex $filter_modes 0]
+ }
+ $itk_component(filt_type) entryset $cur_filter_mode
+
+ itk_component add filt_entry {
+ entry [$itk_component(filter) childsite].ent -font src-font \
+ -textvariable [pref varname gdb/search/last_symbol] -background white
+ } {
+ usual Entry
+ rename -background -textbackground textBackground Background
+ }
+
+ # Watch keystrokes into the entry box and filter on them...
+
+ trace variable [pref varname gdb/search/last_symbol] w \
+ [code $this _filter_trace_proc]
+
+ pack $itk_component(filt_label) -side left
+ pack $itk_component(filt_type) -side left -padx 4 -fill y -pady 5
+ pack $itk_component(filt_entry) -side right -fill both -expand 1 \
+ -padx 6 -pady 5
+
+ # Files Listbox for the Browser frame
+ itk_component add file_box {
+ iwidgets::scrolledlistbox $itk_component(browser).files \
+ -selectmode extended -exportselection false \
+ -labeltext "Files" -labelpos nw -labelrelief groove \
+ -labelborderwidth 2 -ipadx 8 -ipady 6 \
+ -childsitepos s -hscrollmode none -textbackground white
+ }
+
+ append labelUpdateCode [$itk_component(file_box) clientHandlesConfigure 1] \
+ "\n"
+
+ bind [$itk_component(file_box) component listbox] <ButtonRelease-1> \
+ [code $this _process_file_selection %y]
+
+ itk_component add file_sep {
+ frame [$itk_component(file_box) childsite].sep -relief raised -height 2 \
+ -borderwidth 1
+ }
+
+ itk_component add file_hide {
+ checkbutton [$itk_component(file_box) childsite].hide \
+ -text {Hide .h files} \
+ -variable [pref varname gdb/browser/hide_h] \
+ -command [code $this _file_hide_h]
+ }
+
+ itk_component add file_all {
+ button [$itk_component(file_box) childsite].sel \
+ -text {Select All} -width 12 \
+ -command [code $this _select 1]
+ }
+
+ # Pack the file box in, and grid in the separate bits of the child-site.
+
+ pack $itk_component(file_box) -side left -fill both -expand yes \
+ -padx 5 -pady 5
+
+ grid $itk_component(file_sep) -column 0 -row 0 -columnspan 2 \
+ -sticky ew -pady 8
+ grid $itk_component(file_hide) -column 0 -row 1 -padx 5 -sticky w
+ grid $itk_component(file_all) -column 1 -row 1 -padx 5 -sticky e
+
+ grid columnconfigure [$itk_component(file_box) childsite] 0 -weight 1
+
+ # Functions Listbox for the Browser frame
+
+ itk_component add func_box {
+ iwidgets::scrolledlistbox $itk_component(browser).funcs \
+ -selectmode extended \
+ -exportselection false \
+ -labeltext "Functions" -labelpos nw -labelrelief groove \
+ -labelborderwidth 2 -ipadx 8 -ipady 6 \
+ -childsitepos s -hscrollmode none -textbackground white
+ }
+
+ append labelUpdateCode [$itk_component(func_box) clientHandlesConfigure 1] \
+ "\n"
+
+ bind [$itk_component(func_box) component listbox] <ButtonRelease-1> \
+ [code $this _process_func_selection %y]
+
+ itk_component add func_sep {
+ frame [$itk_component(func_box) childsite].sep -relief raised \
+ -height 2 -borderwidth 1
+ }
+
+ itk_component add func_bp_label {
+ label [$itk_component(func_box) childsite].bpl -text {Breakpoints:}
+ }
+
+ itk_component add func_add_bp {
+ button [$itk_component(func_box) childsite].abp -text {Set} \
+ -command [code $this do_all_bp 1]
+ }
+
+ itk_component add func_remove_bp {
+ button [$itk_component(func_box) childsite].rbp -text {Delete} \
+ -command [code $this do_all_bp 0]
+ }
+
+ # Pack in the Function box, and grid in the bits of the child-site
+
+ pack $itk_component(func_box) -side right -fill both -expand yes \
+ -padx 5 -pady 5
+
+ grid $itk_component(func_sep) -row 0 -column 0 -columnspan 3 \
+ -sticky ew -pady 8
+ grid $itk_component(func_bp_label) -row 1 -column 0 -padx 5
+ grid $itk_component(func_remove_bp) -row 1 -column 1 -padx 5
+ grid $itk_component(func_add_bp) -row 1 -column 2 -padx 5
- set browser [cyg::panedwindow $f.p -orient vertical]
- $browser add file
- _build_file_frame [$browser childsite file]
- $browser add function
- _build_function_frame [$browser childsite function]
+ grid columnconfigure [$itk_component(func_box) childsite] 1 -weight 1
+ grid columnconfigure [$itk_component(func_box) childsite] 2 -weight 1
- pack $browser -fill both -expand yes
- pack $f -fill both -expand yes
+ # "More" frame for viewing source
- $p add view
- _build_view_frame [$p childsite view]
+ if {[lsearch [image names] _MORE_] == -1} {
+ image create photo _MORE_ -file [file join $gdb_ImageDir more.gif]
+ image create photo _LESS_ -file [file join $gdb_ImageDir less.gif]
+ }
+
+ itk_component add view_vis {
+ frame $itk_interior.view.visible
+ }
+
+ itk_component add view_more {
+ button $itk_component(view_vis).btn -image _MORE_ -relief flat \
+ -command [code $this _toggle_more]
+ }
+
+ itk_component add view_label {
+ label $itk_component(view_vis).lbl -text {View Source}
+ }
+
+ itk_component add view_sep {
+ frame $itk_component(view_vis).sep -relief raised -borderwidth 1 -height 2
+ }
+
+ pack $itk_component(view_more) -side left -padx 10 -pady 10
+ pack $itk_component(view_label) -side left -padx 10 -pady 10
+ pack $itk_component(view_sep) -padx 4 -pady 10 -fill x -expand 1
+
+ grid columnconfigure $itk_component(view_vis) 2 -weight 1
+
+ pack $itk_component(view_vis) -side top -fill x -expand yes
+
+ # Key bindings for "visible" frames
+ bind_plain_key $itk_component(filt_entry) Return [list $this search]
+ bind $itk_component(func_box) <3> [code $this _toggle_bp %y]
+
+ # Construct hidden frame
+
+ itk_component add view_hidden {
+ frame $itk_interior.hidden
+ }
+
+ itk_component add view_src {
+ SrcTextWin $itk_component(view_hidden).src -Tracing 0 \
+ -parent $this -ignore_var_balloons 1
+ } {
+ rename -background -textbackground textBackground Background
+ }
+
+ $itk_component(view_src) configure -textheight 2i
+
+ itk_component add view_bottom {
+ frame $itk_component(view_hidden).bottom
+ }
+
+ itk_component add view_name {
+ label $itk_component(view_hidden).name -font src-font
+ }
+
+ itk_component add view_func {
+ combobox::combobox $itk_component(view_bottom).combo -maxheight 15 \
+ -font src-font \
+ -command [code $this _goto_func]
+ } {
+ # Should be able to do this, but can't cause the combobox doesn't
+ # fake up a MegaWidget well enough
+ #rename -background -textbackground textBackground Background
+ }
+
+ itk_component add view_mode {
+ combobox::combobox $itk_component(view_bottom).mode -width 9 \
+ -font src-font \
+ -command [code $this mode]
+ } {
+ #rename -background -textbackground textBackground Background
+ }
+
+ itk_component add view_search {
+ entry $itk_component(view_bottom).search -borderwidth 2 \
+ -font src-font -width 10 \
+ -background white
+ } {
+ rename -background -textbackground textBackground Background
+ }
+
+ # Pack all the components of view_hidden into the frame:
+
+ pack $itk_component(view_search) -side right -padx 5 -fill none \
+ -expand 1 -anchor e
+ pack $itk_component(view_mode) -side right -padx 5
+ pack $itk_component(view_func) -side left
+
+ pack $itk_component(view_name) -side top -fill x -padx 5 -pady 3
+ pack $itk_component(view_bottom) -side bottom -fill x -pady 3 -padx 5
+ pack $itk_component(view_src) -fill both -expand 1 -padx 5 -pady 3
+
+
+ # Fill combo boxes
+ $itk_component(view_mode) list insert end SOURCE
+ $itk_component(view_mode) list insert end ASSEMBLY
+ $itk_component(view_mode) list insert end MIXED
+
+ # don't allow SRC+ASM mode... $itk_component(view_mode) insert end SRC+ASM
+ $itk_component(view_mode) entryset [$itk_component(view_src) mode_get]
+
+ # Key bindings for hidden frame
+ bind_plain_key $itk_component(view_search) Return \
+ [code $this _search_src forwards]
+ bind_plain_key $itk_component(view_search) Shift-Return \
+ [code $this _search_src backwards]
+
+ # Now map everything onto the screen
+ grid $itk_component(filter) -column 0 -row 0 -padx 6 -pady 4 -sticky ew
+ grid $itk_component(browser) -column 0 -row 1 -sticky nsew
+ grid $itk_component(view) -column 0 -row 2 -pady 4 -padx 6 -sticky ew
+
+ # Now set up any initial values:
+
+ set MoreVisible [pref get gdb/browser/view_is_open]
+ set BrowserHeight [pref get gdb/browser/top_height]
+ set Width [pref get gdb/browser/width]
+
+ if {$BrowserHeight > 0} {
+ grid rowconfigure $itk_component(hull) $componentToRow(browser) \
+ -minsize $BrowserHeight
}
+ if {$Width > 0} {
+ grid columnconfigure $itk_component(hull) 0 -minsize $Width
+ }
+
+ grid rowconfigure $itk_component(hull) 1 -weight 1
+ grid columnconfigure $itk_component(hull) 0 -weight 1
+
+ update idletasks
+ eval $labelUpdateCode
+
+ if {$MoreVisible} {
+ debug "Got moreVisible at 1"
+ set MoreVisible 0
+ _toggle_more 1
+ }
+
# Fill file box
_fill_file_box
- pack $p -fill both -expand yes
+ after idle "
+ update idletasks
+ grid rowconfigure $itk_component(hull) 2 \
+ -minsize \[winfo height $itk_component(view)\]
+ "
+
+ # Finally set up the top level bindings:
+ _bind_toplevel 1
+
}
# ------------------------------------------------------------------
@@ -120,7 +387,7 @@ itcl::body BrowserWin::_build_win {} {
# box. The actual filtering is done in an after to avoid
# flashing too much if the user is typing quickly.
# ------------------------------------------------------------------
-itcl::body BrowserWin::_filter_trace_proc {v1 v2 mode} {
+body BrowserWin::_filter_trace_proc {v1 v2 mode} {
if {$filter_trace_after != ""} {
after cancel $filter_trace_after
}
@@ -131,7 +398,7 @@ itcl::body BrowserWin::_filter_trace_proc {v1 v2 mode} {
# METHOD: _filter_trace_after
# This is a wrapper around search, needed to pass to trace
# ------------------------------------------------------------------
-itcl::body BrowserWin::_filter_trace_after {} {
+body BrowserWin::_filter_trace_after {} {
set filter_trace_after ""
search
}
@@ -141,7 +408,7 @@ itcl::body BrowserWin::_filter_trace_after {} {
# Search for text or jump to a specific line
# in source window, going in the specified DIRECTION.
# ------------------------------------------------------------------
-itcl::body BrowserWin::_search_src {direction} {
+body BrowserWin::_search_src {direction} {
set exp [$itk_component(view_search) get]
$itk_component(view_src) search $exp $direction
}
@@ -151,7 +418,7 @@ itcl::body BrowserWin::_search_src {direction} {
# Search for functions matching regexp/pattern
# in specified files
# ------------------------------------------------------------------
-itcl::body BrowserWin::search {} {
+body BrowserWin::search {} {
set files [$itk_component(file_box) getcurselection]
@@ -159,7 +426,7 @@ itcl::body BrowserWin::search {} {
return
}
- _freeze_me
+ freeze_me
set filt_pat [format $filter_regexp($cur_filter_mode) \
[pref get gdb/search/last_symbol]]
@@ -174,7 +441,7 @@ itcl::body BrowserWin::search {} {
if {$err} {
debug "ERROR searching for [pref get gdb/search/last_symbol]: $matches"
- _thaw_me
+ thaw_me
return
}
@@ -187,7 +454,190 @@ itcl::body BrowserWin::search {} {
$itk_component(func_box) insert end [lindex $func 0]
set index_to_file([incr i]) [lindex $func 1]
}
- _thaw_me
+ thaw_me
+}
+
+# ------------------------------------------------------------------
+# METHOD: _toggle_more
+# Toggle display of source listing
+# ------------------------------------------------------------------
+body BrowserWin::_toggle_more {{in_constructor 0}} {
+
+ debug "Running toggle_more with MoreVisible: $MoreVisible"
+ # Temporarily disable the resize bindings before opening the window.
+ _bind_toplevel 0
+
+ set topHeight [winfo height $Top]
+ set topWidth [winfo width $Top]
+
+ if {!$MoreVisible} {
+
+ $itk_component(view_label) configure -text {Hide Source}
+ $itk_component(view_more) configure -image _LESS_
+ grid $itk_component(view_hidden) -row 3 -column 0 -sticky nsew \
+ -padx 6 -pady 4
+
+ # Check the stored height. Restore the view to this if it will fit on the
+ # screen. Otherwise, figure out how big to make it...
+
+ set height [pref get gdb/browser/view_height]
+ set bottom [expr {[winfo y $Top] + $topHeight}]
+
+ set extra [expr {[winfo screenheight $Top] - $bottom - 20}]
+
+ if {$height < 0} {
+ set default [winfo pixels $Top 3i]
+ set height [expr {$extra > $default ? $default : $extra}]
+ } else {
+ set height [expr {$extra > $height ? $height : $extra}]
+ }
+
+ wm geometry $Top ${topWidth}x[expr {$topHeight + $height}]
+ grid rowconfigure $itk_component(hull) $componentToRow(view_hidden) \
+ -weight 1
+ grid rowconfigure $itk_component(hull) $componentToRow(browser) -weight 0
+
+ pref set gdb/browser/view_height $height
+
+ set MoreVisible 1
+ update idletasks
+
+ # If we have a selected function, display it in the window
+
+ set f [$itk_component(func_box) getcurselection]
+
+ if {$f != ""} {
+ # FIXME - If there is more than 1 function selected, I just load the
+ # first. It would probably be better to load the one nearest to the
+ # middle of the current window on the listbox. But I am running out
+ # of time for this round...
+
+ if {[llength $f] > 1} {
+ set f [lindex $f 0]
+ }
+
+ _fill_source $f
+ } else {
+ # If no function was chosen, try the file box...
+
+ set f [$itk_component(file_box) getcurselection]
+ if { $f != "" } {
+ if {[llength $f] > 1} {
+ set f [lindex $f 0]
+ }
+ _fill_source $f 0
+ }
+ }
+ } else {
+ if {!$in_constructor} {
+ pref set gdb/browser/view_height \
+ [winfo height $itk_component(view_hidden)]
+ }
+
+ $itk_component(view_label) configure -text {View Source}
+ $itk_component(view_more) configure -image _MORE_
+
+ grid propagate $itk_component(func_box) 0
+ grid propagate $itk_component(file_box) 0
+
+ set newTopHeight [expr {$topHeight - \
+ [winfo height $itk_component(view_hidden)]}]
+ wm geometry $Top ${topWidth}x$newTopHeight
+
+ if {!$in_constructor} {
+ grid rowconfigure $itk_component(hull) $componentToRow(browser) -weight 1
+ grid forget $itk_component(view_hidden)
+ grid rowconfigure $itk_component(hull) $componentToRow(view_hidden) \
+ -minsize 0 -weight 0
+ }
+
+ set MoreVisible 0
+
+ # Flush the changes
+
+ update idletasks
+
+ grid propagate $itk_component(func_box) 1
+ grid propagate $itk_component(file_box) 1
+
+ }
+
+ # restore the bindings
+
+ _bind_toplevel 1
+
+}
+
+# ------------------------------------------------------------------
+# METHOD: _bind_toplevel
+# Setup the bindings for the toplevel.
+# ------------------------------------------------------------------
+body BrowserWin::_bind_toplevel {install} {
+
+ set bindings [bindtags $Top]
+ if {$install} {
+ bindtags $Top [linsert $bindings 0 Configure_Browser_$this]
+ } else {
+ set bindLoc [lsearch $bindings Configure_Browser_$this]
+ bindtags $Top [lreplace $bindings $bindLoc $bindLoc]
+ }
+}
+
+# ------------------------------------------------------------------
+# METHOD: _do_resize
+# Does the actual work of the resize.
+# ------------------------------------------------------------------
+body BrowserWin::_do_resize {} {
+
+ update idletasks
+ debug "Running _do_resize"
+
+ set width [winfo width $itk_component(hull)]
+ pref set gdb/browser/width $width
+ grid columnconfigure $itk_component(hull) 0 -minsize $width
+
+ if {$MoreVisible} {
+ set v_height [winfo height $itk_component(view_hidden)]
+ pref set gdb/browser/view_height $v_height
+ grid rowconfigure $itk_component(hull) $componentToRow(view_hidden) \
+ -minsize $v_height
+ grid rowconfigure $itk_component(hull) $componentToRow(browser)
+ } else {
+ set b_height [winfo height $itk_component(browser)]
+ pref set gdb/browser/top_height $b_height
+ grid rowconfigure $itk_component(hull) $componentToRow(browser) \
+ -minsize $b_height
+ }
+
+ eval $labelUpdateCode
+ pack propagate $Top 1
+
+ set resize_after ""
+
+}
+
+# ------------------------------------------------------------------
+# METHOD: _resize
+# Resize "itk_component(view_hidden)" after all configure events
+# ------------------------------------------------------------------
+body BrowserWin::_resize {} {
+
+ pack propagate $Top 0
+
+ if {$MoreVisible} {
+ grid rowconfigure $itk_component(hull) $componentToRow(view_hidden) \
+ -minsize 0
+ } else {
+ grid rowconfigure $itk_component(hull) 1 -minsize 0
+ }
+
+ grid columnconfigure $itk_component(hull) 0 -minsize 0
+
+ if {$resize_after != ""} {
+ after cancel $resize_after
+ }
+ set resize_after [after 100 "[code $this _do_resize]"]
+
}
# ------------------------------------------------------------------
@@ -195,7 +645,7 @@ itcl::body BrowserWin::search {} {
# This fills the func combo, and the more window if it
# is currently open with the hit in the File combobox.
# ------------------------------------------------------------------
-itcl::body BrowserWin::_process_file_selection {y} {
+body BrowserWin::_process_file_selection {y} {
set curIndex [$itk_component(file_box) nearest $y]
set curSelection [$itk_component(file_box) curselection]
@@ -217,6 +667,7 @@ itcl::body BrowserWin::_process_file_selection {y} {
}
search
+
}
# ------------------------------------------------------------------
@@ -224,7 +675,7 @@ itcl::body BrowserWin::_process_file_selection {y} {
# This points the more window to the hit in the Func combobox
# if it is currently open.
# ------------------------------------------------------------------
-itcl::body BrowserWin::_process_func_selection {y} {
+body BrowserWin::_process_func_selection {y} {
set curIndex [$itk_component(func_box) nearest $y]
set curSelection [$itk_component(func_box) curselection]
@@ -236,16 +687,17 @@ itcl::body BrowserWin::_process_func_selection {y} {
set fileName $index_to_file($curIndex)
_fill_source $funcName 1 $fileName
}
+
}
# ------------------------------------------------------------------
# METHOD: do_all_bp
# Toggle a bp at every selected function in FuncLB
# ------------------------------------------------------------------
-itcl::body BrowserWin::do_all_bp {onp} {
+body BrowserWin::do_all_bp {onp} {
set funcs [$itk_component(func_box) getcurselection]
- _freeze_me
+ freeze_me
foreach f $funcs {
if {[catch {gdb_loc $f} linespec]} {
@@ -263,7 +715,7 @@ itcl::body BrowserWin::do_all_bp {onp} {
catch {gdb_cmd "delete $bpnum"}
}
}
- _thaw_me
+ thaw_me
}
# ------------------------------------------------------------------
@@ -271,7 +723,7 @@ itcl::body BrowserWin::do_all_bp {onp} {
# Toggle bp at function specified by the given Y
# coordinate in the listbox
# ------------------------------------------------------------------
-itcl::body BrowserWin::_toggle_bp {y} {
+body BrowserWin::_toggle_bp {y} {
set f [$itk_component(func_box) get [$itk_component(func_box) nearest $y]]
if {$f != ""} {
@@ -292,9 +744,9 @@ itcl::body BrowserWin::_toggle_bp {y} {
# ------------------------------------------------------------------
# METHOD: _select
-# Un/Highlight all files in the files list
+# (Un/Highlight all files in the files list
# ------------------------------------------------------------------
-itcl::body BrowserWin::_select {highlight} {
+body BrowserWin::_select {highlight} {
if {$highlight} {
$itk_component(file_box) selection set 0 end
} else {
@@ -307,7 +759,7 @@ itcl::body BrowserWin::_select {highlight} {
# METHOD: _set_filter_mode
# React to changes in the filter mode
# ------------------------------------------------------------------
-itcl::body BrowserWin::_set_filter_mode {w mode} {
+body BrowserWin::_set_filter_mode {w mode} {
if {[string compare $mode $cur_filter_mode] != 0} {
set cur_filter_mode $mode
pref set gdb/search/filter_mode $mode
@@ -319,9 +771,11 @@ itcl::body BrowserWin::_set_filter_mode {w mode} {
# METHOD: _file_hide_h
# Run when the "Hide .h files" preference is chosen.
# ------------------------------------------------------------------
-itcl::body BrowserWin::_file_hide_h {} {
+body BrowserWin::_file_hide_h {} {
+
_fill_file_box
search
+
}
# ------------------------------------------------------------------
@@ -329,7 +783,12 @@ itcl::body BrowserWin::_file_hide_h {} {
# Helper function to fill the srctextwin
# when needed.
# ------------------------------------------------------------------
-itcl::body BrowserWin::_fill_source {f {funcp 1} {filename ""}} {
+body BrowserWin::_fill_source {f {funcp 1} {filename ""}} {
+
+ if {!$MoreVisible } {
+ return
+ }
+
if {($funcp && [string compare $f $Current(function)]) \
|| [string compare $f $Current(filename)]} {
if {!$funcp} {
@@ -346,19 +805,19 @@ itcl::body BrowserWin::_fill_source {f {funcp 1} {filename ""}} {
lassign $linespec foo funcname name line addr pc_addr lib
set file_changed [string compare $Current(filename) $name]
+ # fill srctextwin
if {$file_changed} {
# Set the file name label:
$itk_component(view_name) configure -text $name:
- _freeze_me
+ freeze_me
}
- # fill srctextwin
$itk_component(view_src) location BROWSE_TAG $name $funcname \
$line $addr $pc_addr lib
if {$file_changed} {
- _thaw_me
+ thaw_me
}
set Current(function) $funcname
@@ -369,6 +828,7 @@ itcl::body BrowserWin::_fill_source {f {funcp 1} {filename ""}} {
}
# Set current function in combo box
$itk_component(view_func) entryset $f
+
}
}
@@ -377,7 +837,7 @@ itcl::body BrowserWin::_fill_source {f {funcp 1} {filename ""}} {
# Function called by srctextwin when the display
# mode changes
# ------------------------------------------------------------------
-itcl::body BrowserWin::mode {w {mode ""} {go 1}} {
+body BrowserWin::mode {w {mode ""} {go 1}} {
if {$mode != ""} {
$itk_component(view_src) mode_set $mode $go
$itk_component(view_mode) entryset $mode
@@ -389,7 +849,7 @@ itcl::body BrowserWin::mode {w {mode ""} {go 1}} {
# Callback for the function combo box which
# sets the srctextwin looking at the given function (VAL)
# ------------------------------------------------------------------
-itcl::body BrowserWin::_goto_func {w {val ""}} {
+body BrowserWin::_goto_func {w {val ""}} {
if {$val != ""} {
set mang 0
if {[info exists _mangled_func($val)]} {
@@ -411,12 +871,11 @@ itcl::body BrowserWin::_goto_func {w {val ""}} {
}
}
}
-
# ------------------------------------------------------------------
# METHOD: _fill_file_box
# This private method fills the file listbox
# ------------------------------------------------------------------
-itcl::body BrowserWin::_fill_file_box {} {
+body BrowserWin::_fill_file_box {} {
# It would be cool if gdb_listfiles took a regexp to match,
# but it doesn't...
@@ -436,24 +895,23 @@ itcl::body BrowserWin::_fill_file_box {} {
}
search
}
-
# ------------------------------------------------------------------
# METHOD: _fill_funcs_combo
# This private method fills the functions combo box
# with all the functions in NAME.
# ------------------------------------------------------------------
-itcl::body BrowserWin::_fill_funcs_combo {name} {
+body BrowserWin::_fill_funcs_combo {name} {
$itk_component(view_func) list delete 0 end
if {$name != ""} {
set maxlen 10
if {[catch {gdb_listfuncs $name} listfuncs]} {
tk_messageBox -icon error -default ok \
- -title "GDB" -type ok \
+ -title "GDB" -type ok -modal system \
-message "This file can not be found or does not contain\ndebugging information."
return
}
- foreach f [lsort $listfuncs] {
+ foreach f $listfuncs {
lassign $f func mang
if {$func == "global constructors keyed to main"} {continue}
set _mangled_func($func) $mang
@@ -462,270 +920,6 @@ itcl::body BrowserWin::_fill_funcs_combo {name} {
set maxlen [string length $func]
}
}
- # limit size to 40 chars because if we don't set a reasonable limit
- # then the combobox can be wider than the screen
- if {$maxlen > 40} {set maxlen 40}
-
$itk_component(view_func) configure -width [expr {$maxlen + 1}]
}
}
-
-# ------------------------------------------------------------------
-# METHOD: _build_filter_frame
-# This private method builds the filter frame
-# ------------------------------------------------------------------
-itcl::body BrowserWin::_build_filter_frame {parent} {
-
- itk_component add filter {
- iwidgets::labeledframe $parent.filter -labeltext "Function Filter" \
- -relief groove -borderwidth 2 -ipadx 6 -ipady 4
- }
-
- # Set up the contents of the Filter frame
- if {$_layout == 2} {
- itk_component add filt_label {
- label [$itk_component(filter) childsite].lbl -text "Show if function " \
- -font global/fixed
- }
- }
-
- itk_component add filt_type {
- combobox::combobox [$itk_component(filter) childsite].type -height 4 \
- -width 15 -editable 0 \
- -command [code $this _set_filter_mode] \
- -font global/fixed
- } {
- rename -background -textbackground textBackground Background
- }
-
- # Fill the filter mode combo-box
- foreach elem $filter_modes {
- $itk_component(filt_type) list insert end $elem
- }
-
- set cur_filter_mode [pref get gdb/search/filter_mode]
- if {[lsearch $filter_modes $cur_filter_mode] < 0} {
- set cur_filter_mode [lindex $filter_modes 0]
- }
- $itk_component(filt_type) entryset $cur_filter_mode
-
- itk_component add filt_entry {
- entry [$itk_component(filter) childsite].ent -font global/fixed \
- -textvariable [pref varname gdb/search/last_symbol]
- } {}
- bind_plain_key $itk_component(filt_entry) Return [list $this search]
-
- # Watch keystrokes into the entry box and filter on them...
- trace variable [pref varname gdb/search/last_symbol] w \
- [code $this _filter_trace_proc]
-
- if {$_layout == 2} {
- pack $itk_component(filt_label) -side left
- }
- pack $itk_component(filt_type) -side left -padx 4 -fill y -pady 5
- pack $itk_component(filt_entry) -side right -fill both -expand 1 \
- -padx 6 -pady 5
-
- pack $itk_component(filter) -fill x -anchor n -pady 3
-}
-
-# ------------------------------------------------------------------
-# METHOD: _build_file_frame
-# This private method builds the files frame
-# ------------------------------------------------------------------
-itcl::body BrowserWin::_build_file_frame {parent} {
-
- # Labeled Frame
- itk_component add file_frame {
- iwidgets::labeledframe $parent.file -labeltext "Files" \
- -relief groove -borderwidth 2 -ipadx 6 -ipady 4
- }
-
- # Listbox with files
- itk_component add file_box {
- iwidgets::scrolledlistbox [$itk_component(file_frame) childsite].listbox \
- -selectmode extended -exportselection false \
- -hscrollmode dynamic -vscrollmode dynamic -foreground $::Colors(textfg) \
- -textbackground $::Colors(textbg)
- } {}
-
- bind [$itk_component(file_box) component listbox] <ButtonRelease-1> \
- [code $this _process_file_selection %y]
-
- itk_component add file_sep {
- frame [$itk_component(file_frame) childsite].sep -relief raised -height 2 \
- -borderwidth 1
- }
-
- itk_component add file_hide {
- checkbutton [$itk_component(file_frame) childsite].hide \
- -text "Hide .h files" \
- -variable [pref varname gdb/browser/hide_h] \
- -command [code $this _file_hide_h]
- }
-
- itk_component add file_all {
- button [$itk_component(file_frame) childsite].sel \
- -text "Select All" \
- -command [code $this _select 1]
- }
-
- # pack all the pieces
- grid $itk_component(file_box) -column 0 -row 0 -columnspan 2 \
- -sticky news
- grid $itk_component(file_sep) -column 0 -row 1 -columnspan 2 \
- -sticky ew -pady 8
- grid $itk_component(file_hide) -column 0 -row 2 -padx 5 -sticky w
- grid $itk_component(file_all) -column 1 -row 2 -padx 5 -sticky e
-
- grid columnconfigure [$itk_component(file_frame) childsite] 0 -weight 1
- grid rowconfigure [$itk_component(file_frame) childsite] 0 -weight 1
-
- # finally pack the main frame
- pack $itk_component(file_frame) -side left -fill both -expand yes
-}
-
-# ------------------------------------------------------------------
-# METHOD: _build_function_frame
-# This private method builds the functions frame
-# ------------------------------------------------------------------
-itcl::body BrowserWin::_build_function_frame {parent} {
-
- # Labeled Frame
- itk_component add func_frame {
- iwidgets::labeledframe $parent.file -labeltext "Function" \
- -relief groove -borderwidth 2 -ipadx 6 -ipady 4
- }
-
- # Functions Listbox
- itk_component add func_box {
- iwidgets::scrolledlistbox [$itk_component(func_frame) childsite].listbox \
- -selectmode extended -hscrollmode dynamic -vscrollmode dynamic \
- -exportselection false -foreground $::Colors(textfg) \
- -textbackground $::Colors(textbg)
- } {}
-
- bind [$itk_component(func_box) component listbox] <ButtonRelease-1> \
- [code $this _process_func_selection %y]
- bind $itk_component(func_box) <3> [code $this _toggle_bp %y]
-
- itk_component add func_sep {
- frame [$itk_component(func_frame) childsite].sep -relief raised \
- -height 2 -borderwidth 1
- }
-
- itk_component add func_add_bp {
- button [$itk_component(func_frame) childsite].abp -text "Set BP" \
- -command [code $this do_all_bp 1]
- }
-
- itk_component add func_remove_bp {
- button [$itk_component(func_frame) childsite].rbp -text "Delete BP" \
- -command [code $this do_all_bp 0]
- }
-
- # pack all the pieces
- grid $itk_component(func_box) -column 0 -row 0 -columnspan 2 -sticky news
- grid $itk_component(func_sep) -row 1 -column 0 -columnspan 2 \
- -sticky ew -pady 8
- grid $itk_component(func_remove_bp) -row 2 -column 0 -padx 5 -sticky w
- grid $itk_component(func_add_bp) -row 2 -column 1 -padx 5 -sticky e
-
- grid columnconfigure [$itk_component(func_frame) childsite] 0 -weight 1
- grid rowconfigure [$itk_component(func_frame) childsite] 0 -weight 1
-
- # finally pack the main frame
- pack $itk_component(func_frame) -fill both -expand yes
-}
-
-# ------------------------------------------------------------------
-# METHOD: _build_view_frame
-# This private method builds the view frame
-# ------------------------------------------------------------------
-itcl::body BrowserWin::_build_view_frame {parent} {
- itk_component add view {
- frame $parent.view
- }
-
- itk_component add view_src {
- SrcTextWin $itk_component(view).src -Tracing 0 \
- -parent $this -ignore_var_balloons 0
- } {
- rename -background -textbackground textBackground Background
- }
-
- itk_component add view_bottom {
- frame $itk_component(view).bottom
- }
-
- itk_component add view_name {
- label $itk_component(view).name -font global/fixed
- }
-
- itk_component add view_func {
- combobox::combobox $itk_component(view_bottom).combo -maxheight 15\
- -font global/fixed -command [code $this _goto_func]
- } {
- rename -background -textbackground textBackground Background
- }
-
- itk_component add view_mode {
- combobox::combobox $itk_component(view_bottom).mode -width 9 \
- -font global/fixed -command [code $this mode]
- } {
- rename -background -textbackground textBackground Background
- }
-
- itk_component add view_search {
- entry $itk_component(view_bottom).search -borderwidth 2 \
- -font global/fixed -width 10 -background $::Colors(textbg)
- } {}
-
- # Pack all the components of view into the frame:
- pack $itk_component(view_func) -side left -anchor w
- pack $itk_component(view_mode) -side left -padx 5
- pack $itk_component(view_search) -side right -padx 5 -expand 1 -anchor e
- pack $itk_component(view_name) -side top -fill x -padx 5 -pady 3
- pack $itk_component(view_bottom) -side bottom -fill x -pady 3 -padx 5
- pack $itk_component(view_src) -fill both -expand 1 -padx 5 -pady 3
-
- # Fill combo boxes
- $itk_component(view_mode) list insert end SOURCE
- $itk_component(view_mode) list insert end ASSEMBLY
- $itk_component(view_mode) list insert end MIXED
- # don't allow SRC+ASM mode... $itk_component(view_mode) insert end SRC+ASM
- $itk_component(view_mode) entryset [$itk_component(view_src) mode_get]
-
- # Key bindings
- bind_plain_key $itk_component(view_search) Return \
- [code $this _search_src forwards]
- bind_plain_key $itk_component(view_search) Shift-Return \
- [code $this _search_src backwards]
-
- pack $itk_component(view) -fill both -expand yes
-}
-
-# ------------------------------------------------------------------
-# METHOD: _switch_layout
-# Switch between different layouts
-#
-# ------------------------------------------------------------------
-itcl::body BrowserWin::_switch_layout {} {
- # only 2 right now, so toggle
- if {$_layout == 1} {
- set _layout 2
- } else {
- set _layout 1
- }
- pref set gdb/browser/layout $_layout
- destroy $itk_interior.p
- destroy $itk_component(popup)
- set Current(filename) {}
- set Current(function) {}
- if {$filter_trace_after != ""} {
- after cancel $filter_trace_after
- }
- trace vdelete [pref varname gdb/search/last_symbol] \
- w [code $this _filter_trace_proc]
- _build_win
-}
diff --git a/gdb/gdbtk/library/browserwin.ith b/gdb/gdbtk/library/browserwin.ith
index 8e36a70707f..3ea41b3e106 100644
--- a/gdb/gdbtk/library/browserwin.ith
+++ b/gdb/gdbtk/library/browserwin.ith
@@ -1,5 +1,5 @@
-# Browser window class definition for Insight.
-# Copyright (C) 1998, 1999, 2003 Red Hat, Inc.
+# Browser window class definition for GDBtk.
+# Copyright 1998, 1999 Cygnus Solutions
#
# This program is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License (GPL) as published by
@@ -11,7 +11,7 @@
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
-itcl::class BrowserWin {
+class BrowserWin {
inherit EmbeddedWin
public {
@@ -25,7 +25,9 @@ itcl::class BrowserWin {
}
private {
+ method _bind_toplevel {install}
method _build_win {}
+ method _do_resize {}
method _file_hide_h {}
method _fill_file_box {}
method _fill_funcs_combo {name}
@@ -35,23 +37,25 @@ itcl::class BrowserWin {
method _goto_func {w {val ""}}
method _process_file_selection {y}
method _process_func_selection {y}
+ method _resize {}
method _search_src {direction}
method _select {highlight}
method _set_filter_mode {w mode}
method _toggle_bp {y}
- method _build_filter_frame {parent}
- method _build_file_frame {parent}
- method _build_function_frame {parent}
- method _build_view_frame {parent}
- method _switch_layout
+ method _toggle_more {{in_constructor 0}}
variable cur_filter_mode
+
+ variable MoreVisible 0; #whether viewing source
+ variable TopHalfHeight 0
+ variable BottomHalfHeight 0
+ variable CollapsedHeight 0; #height of the window when collapsed
variable Current;
variable labelUpdateCode ""
variable index_to_file
variable _mangled_func
+ variable resize_after ""
variable filter_trace_after ""
- variable _layout
common componentToRow
array set componentToRow {
@@ -60,7 +64,7 @@ itcl::class BrowserWin {
view 2
view_hidden 3
}
-
+
common filter_modes [list "starts with" \
"contains" \
"ends with" \
@@ -73,5 +77,8 @@ itcl::class BrowserWin {
"matches regexp" %s
}
}
-}
+ protected proc dont_remember_size {} {
+ return 1
+ }
+}
diff --git a/gdb/gdbtk/library/console.itb b/gdb/gdbtk/library/console.itb
index 63a2baf44a1..bc98f0a1dd6 100644
--- a/gdb/gdbtk/library/console.itb
+++ b/gdb/gdbtk/library/console.itb
@@ -1,5 +1,5 @@
-# Console window for Insight
-# Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003 Red Hat, Inc.
+# Console window for GDBtk
+# Copyright 1998, 1999 Cygnus Solutions
#
# This program is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License (GPL) as published by
@@ -12,57 +12,50 @@
# GNU General Public License for more details.
-itcl::body Console::constructor {args} {
+body Console::constructor {args} {
global gdbtk_state
window_name "Console Window"
debug "$args"
_build_win
eval itk_initialize $args
- add_hook gdb_no_inferior_hook [list $this idle dummy]
-
- # There are a bunch of console prefs that have no UI
- # for the user to modify them. In the event that the user
- # really wants to change them, they will have to be modified
- # in prefs.tcl or by editing .gdbtkinit. When these prefs
- # gain a prefs UI, the user may change them dynamically
- # and the console window will need notification that they
- # have changed. Add them to the following list and
- # Console::_update_option.
- foreach option {gdb/console/wrap} {
- pref add_hook $option [code $this _update_option]
- }
-
+ add_hook gdb_busy_hook [list $this busy]
+ add_hook gdb_idle_hook [list $this idle]
+ add_hook gdb_no_inferior_hook [list $this idle]
set gdbtk_state(console) $this
}
-itcl::body Console::destructor {} {
+body Console::destructor {} {
global gdbtk_state
set gdbtk_state(console) ""
- remove_hook gdb_no_inferior_hook [list $this idle dummy]
+ remove_hook gdb_busy_hook [list $this busy]
+ remove_hook gdb_idle_hook [list $this idle]
+ remove_hook gdb_no_inferior_hook [list $this idle]
}
-
-itcl::body Console::_build_win {} {
- iwidgets::scrolledtext $itk_interior.stext \
+
+body Console::_build_win {} {
+ iwidgets::scrolledtext $itk_interior.stext -hscrollmode dynamic \
-vscrollmode dynamic -textbackground white
set _twin [$itk_interior.stext component text]
- _set_wrap [pref get gdb/console/wrap]
+ if {[pref get gdb/console/wrap]} {
+ $_twin configure -wrap word
+ } else {
+ $_twin configure -wrap none
+ }
$_twin tag configure prompt_tag -foreground [pref get gdb/console/prompt_fg]
$_twin tag configure err_tag -foreground [pref get gdb/console/error_fg]
- $_twin tag configure log_tag -foreground [pref get gdb/console/log_fg]
- $_twin tag configure target_tag -foreground [pref get gdb/console/target_fg]
- $_twin configure -font [pref get gdb/console/font] \
- -bg $::Colors(textbg) -fg $::Colors(textfg)
-
+ $_twin configure -font [pref get gdb/console/font]
+
#
# bind editing keys for console window
#
bind $_twin <Return> "$this invoke; break"
- bind_plain_key $_twin Control-m "$this invoke; break"
- bind_plain_key $_twin Control-j "$this invoke; break"
+
+ # disable this
+ bind_plain_key $_twin Control-o "break"
# History control.
bind_plain_key $_twin Control-p "[code $this _previous]; break"
@@ -73,8 +66,7 @@ itcl::body Console::_build_win {} {
bind $_twin <Home> "[code $this _first]; break"
bind $_twin <Meta-greater> "[code $this _last]; break"
bind $_twin <End> "[code $this _last]; break"
- bind_plain_key $_twin Control-o "[code $this _operate_and_get_next]; break"
-
+
# Tab completion
bind_plain_key $_twin KeyPress-Tab "[code $this _complete]; break"
@@ -96,21 +88,18 @@ itcl::body Console::_build_win {} {
# Control-a moves to start of line.
bind_plain_key $_twin Control-a {
%W mark set insert {cmdmark + 1 char}
- %W see {insert linestart}
break
}
# Control-u deletes to start of line.
bind_plain_key $_twin Control-u {
%W delete {cmdmark + 1 char} insert
- %W see {insert linestart}
}
-
+
# Control-w deletes previous word.
bind_plain_key $_twin Control-w {
if {[%W compare {insert -1c wordstart} > cmdmark]} {
%W delete {insert -1c wordstart} insert
- %W see insert
}
}
@@ -124,19 +113,13 @@ itcl::body Console::_build_win {} {
# movement. We only need to do this after events we do not
# explicitly override. Note that since the edit line is always the
# last line, we can't possibly go past it, so we don't bother
- # checking that. Note also that we check for a binding which is
- # simply `;'; this lets us handle keys already bound via
- # bind_plain_key.
+ # checking that.
foreach event [bind Text] {
- if {[string match *Key* $event]
- && ([bind $_twin $event] == ""
- || [bind $_twin $event] == ";")} {
- bind $_twin $event [bind Text $event]
- bind $_twin $event {+
+ if {[string match *Key* $event] && [bind $_twin $event] == ""} {
+ bind $_twin $event {
if {[%W compare insert <= {cmdmark + 1 char}]} {
%W mark set insert {cmdmark + 1 char}
}
- break
}
}
}
@@ -147,7 +130,7 @@ itcl::body Console::_build_win {} {
# the saved insertion point.
set pretag pre-$_twin
bind $_twin <1> [format {
- if {[%%W compare [tk::TextClosestGap %%W %%x %%y] <= cmdmark]} {
+ if {[%%W compare [tkTextClosestGap %%W %%x %%y] <= cmdmark]} {
%s _insertion [%%W index insert]
} else {
%s _insertion {}
@@ -160,7 +143,7 @@ itcl::body Console::_build_win {} {
} $this $this $this]
# FIXME: has inside information.
bind $_twin <ButtonRelease-1> [format {
- tk::CancelRepeat
+ tkCancelRepeat
if {[%s _insertion] != ""} {
%%W mark set insert [%s _insertion]
}
@@ -174,27 +157,25 @@ itcl::body Console::_build_win {} {
# drags a little "fuzzy".
bind $_twin <B2-Motion> {
if {!$tk_strictMotif} {
- if {($tk::Priv(x) - 2 < %x < $tk::Priv(x) + 2) \
- || ($tk::Priv(y) - 2 < %y < $tk::Priv(y) + 2)} {
- set tk::Priv(mouseMoved) 1
+ if {($tkPriv(x) - 2 < %x < $tkPriv(x) + 2) \
+ || ($tkPriv(y) - 2 < %y < $tkPriv(y) + 2)} {
+ set tkPriv(mouseMoved) 1
}
- if {$tk::Priv(mouseMoved)} {
+ if {$tkPriv(mouseMoved)} {
%W scan dragto %x %y
}
}
break
}
bind $_twin <ButtonRelease-2> [format {
- if {!$tk::Priv(mouseMoved) || $tk_strictMotif} {
+ if {!$tkPriv(mouseMoved) || $tk_strictMotif} {
%s
break
}
} [code $this _paste 1]]
bind $_twin <<Paste>> "[code $this _paste 0]; break"
bind $_twin <<PasteSelection>> "[code $this _paste 0]; break"
- bind_plain_key $_twin Control-c "event generate $_twin <<Copy>>"
- bind_plain_key $_twin Control-v "[code $this _paste 1]; break"
-
+
_setprompt
pack $itk_interior.stext -expand yes -fill both
@@ -202,29 +183,24 @@ itcl::body Console::_build_win {} {
}
-itcl::body Console::idle {event} {
+body Console::idle {} {
set _running 0
- $_top configure -cursor {}
}
-# ------------------------------------------------------------------
-# METHOD: busy - busy event handler
-# ------------------------------------------------------------------
-itcl::body Console::busy {event} {
+body Console::busy {} {
set _running 1
- $_top configure -cursor watch
}
# ------------------------------------------------------------------
# METHOD: insert - insert new text in the text widget
# ------------------------------------------------------------------
-itcl::body Console::insert {line {tag ""}} {
+body Console::insert {line} {
if {$_needNL} {
$_twin insert {insert linestart} "\n"
}
# Remove all \r characters from line.
set line [join [split $line \r] {}]
- $_twin insert {insert -1 line lineend} $line $tag
+ $_twin insert {insert -1 line lineend} $line
set nlines [lindex [split [$_twin index end] .] 0]
if {$nlines > $throttle} {
@@ -237,29 +213,23 @@ itcl::body Console::insert {line {tag ""}} {
::update idletasks
}
+#-------------------------------------------------------------------
+# METHOD: einsert - insert error text in the text widget
# ------------------------------------------------------------------
-# NAME: ConsoleWin::_operate_and_get_next
-# DESCRIPTION: Invokes the current command and, if this
-# command came from the history, arrange for
-# the next history command to be inserted once this
-# command is finished.
-#
-# ARGUMENTS: None
-# RETURNS: Nothing
-# ------------------------------------------------------------------
-itcl::body Console::_operate_and_get_next {} {
- if {$_histElement >= 0} {
- # _pendingHistElement will be used after the new history element
- # is pushed. So we must increment it.
- set _pendingHistElement [expr {$_histElement + 1}]
+body Console::einsert {line} {
+ debug $line
+ if {$_needNL} {
+ $_twin insert end "\n"
}
- invoke
+ $_twin insert end $line err_tag
+ $_twin see insert
+ set _needNL 0
}
#-------------------------------------------------------------------
# METHOD: _previous - recall the previous command
# ------------------------------------------------------------------
-itcl::body Console::_previous {} {
+body Console::_previous {} {
if {$_histElement == -1} {
# Save partial command.
set _partialCommand [$_twin get {cmdmark + 1 char} {cmdmark lineend}]
@@ -279,7 +249,7 @@ itcl::body Console::_previous {} {
#-------------------------------------------------------------------
# METHOD: _search_history - search history for match
# ------------------------------------------------------------------
-itcl::body Console::_search_history {} {
+body Console::_search_history {} {
set str [$_twin get {cmdmark + 1 char} {cmdmark lineend}]
if {$_histElement == -1} {
@@ -304,7 +274,7 @@ itcl::body Console::_search_history {} {
#-------------------------------------------------------------------
# METHOD: _rsearch_history - search history in reverse for match
# ------------------------------------------------------------------
-itcl::body Console::_rsearch_history {} {
+body Console::_rsearch_history {} {
if {$_histElement != -1} {
set str $_partialCommand
set num [expr $_histElement - 1]
@@ -332,7 +302,7 @@ itcl::body Console::_rsearch_history {} {
#-------------------------------------------------------------------
# METHOD: _next - recall the next command (scroll forward)
# ------------------------------------------------------------------
-itcl::body Console::_next {} {
+body Console::_next {} {
if {$_histElement == -1} {
# FIXME flash window.
return
@@ -350,7 +320,7 @@ itcl::body Console::_next {} {
#-------------------------------------------------------------------
# METHOD: _last - get the last history element
# ------------------------------------------------------------------
-itcl::body Console::_last {} {
+body Console::_last {} {
set _histElement 0
_next
}
@@ -358,7 +328,7 @@ itcl::body Console::_last {} {
#-------------------------------------------------------------------
# METHOD: _first - get the first (earliest) history element
# ------------------------------------------------------------------
-itcl::body Console::_first {} {
+body Console::_first {} {
set _histElement [expr {[llength $_history] - 1}]
_previous
}
@@ -368,68 +338,25 @@ itcl::body Console::_first {} {
#-------------------------------------------------------------------
# METHOD: _setprompt - put a prompt at the beginning of a line
# ------------------------------------------------------------------
-itcl::body Console::_setprompt {{prompt {}}} {
- if {$prompt == ""} {
+body Console::_setprompt {{prompt {}}} {
+ if {$_invoking} {
+ set prompt ""
+ } elseif {"$prompt" != ""} {
+ # nothing
+ } else {
#set prompt [pref get gdb/console/prompt]
set prompt [gdb_prompt]
- } elseif {$prompt == "none"} {
- set prompt ""
}
-
- $_twin delete {insert linestart} {insert lineend}
+
$_twin insert {insert linestart} $prompt prompt_tag
$_twin mark set cmdmark "insert -1 char"
$_twin see insert
-
- if {$_pendingHistElement >= 0} {
- set _histElement $_pendingHistElement
- set _pendingHistElement -1
- _next
- }
-}
-
-#-------------------------------------------------------------------
-# METHOD: gets - get a line of input from the console
-# ------------------------------------------------------------------
-itcl::body Console::gets {} {
- set _input_mode 1
-# _setprompt "(input) "
- _setprompt none
- $_twin delete insert end
- $_twin mark set cmdmark {insert -1 char}
-
- bind_plain_key $_twin Control-d "$this invoke 1; break"
- bind_plain_key $_twin Control-c "[code $this _cancel]; break"
-
- vwait [scope _input_result]
- set _input_mode 0
- bind_plain_key $_twin Control-c "event generate $_twin <<Copy>>"
- activate
- if {$_input_error} {
- set _input_error 0
- return -code error ""
- }
- return $_input_result
-}
-
-#-------------------------------------------------------------------
-# METHOD: cancel - cancel input when ^C is hit
-# ------------------------------------------------------------------
-itcl::body Console::_cancel {} {
- if {$_input_mode} {
- set _needNL 1
- $_twin mark set insert {insert lineend}
- $_twin insert {insert lineend} "^C\n"
- incr _invoking
- set _input_error 1
- set _input_result ""
- }
}
#-------------------------------------------------------------------
# METHOD: activate - run this after a command is run
# ------------------------------------------------------------------
-itcl::body Console::activate {{prompt {}}} {
+body Console::activate {{prompt {}}} {
if {$_invoking > 0} {
incr _invoking -1
_setprompt $prompt
@@ -439,22 +366,11 @@ itcl::body Console::activate {{prompt {}}} {
#-------------------------------------------------------------------
# METHOD: invoke - invoke a command
# ------------------------------------------------------------------
-itcl::body Console::invoke {{controld 0}} {
+body Console::invoke {} {
global gdbtk_state
- set text [$_twin get {cmdmark + 1 char} end ]
-
- if { "[string range $text 0 1]" == "tk" } {
- if {! [info complete $text] } {
- $_twin insert {insert lineend} " \\\n"
- $_twin see insert
- return
- }
- }
-
incr _invoking
-
- set text [string trimright $text \n]
+ set text [$_twin get {cmdmark + 1 char} {cmdmark lineend}]
if {$text == ""} {
set text [lindex $_history 0]
$_twin insert {insert lineend} $text
@@ -470,13 +386,6 @@ itcl::body Console::invoke {{controld 0}} {
}
}
- if {$_input_mode} {
- if {!$controld} {append text \n}
- set _input_result $text
- set _needNL 1
- return
- }
-
# Only push new nonempty history items.
if {$text != "" && [lindex $_history 0] != $text} {
lvarpush _history $text
@@ -526,7 +435,7 @@ itcl::body Console::invoke {{controld 0}} {
#-------------------------------------------------------------------
# PRIVATE METHOD: _delete - Handle a Delete of some sort.
# ------------------------------------------------------------------
-itcl::body Console::_delete {{right 0}} {
+body Console::_delete {{right 0}} {
# If we are deleting to the right, and we have this turned off,
# delete to the right.
@@ -564,7 +473,7 @@ itcl::body Console::_delete {{right 0}} {
#-------------------------------------------------------------------
# PRIVATE METHOD: _insertion - Set or get saved insertion point
# ------------------------------------------------------------------
-itcl::body Console::_insertion {args} {
+body Console::_insertion {args} {
if {! [llength $args]} {
return $_saved_insertion
} else {
@@ -575,7 +484,7 @@ itcl::body Console::_insertion {args} {
# ------------------------------------------------------------------
# METHOD: _paste - paste the selection into the console window
# ------------------------------------------------------------------
-itcl::body Console::_paste {{check_primary 1}} {
+body Console::_paste {{check_primary 1}} {
set sel {}
if {!$check_primary || [catch {selection get} sel] || $sel == ""} {
@@ -595,11 +504,16 @@ itcl::body Console::_paste {{check_primary 1}} {
}
}
+# public method for testing only
+body Console::get_text {} {
+ return $_twin
+}
+
# ------------------------------------------------------------------
# METHOD: _find_lcp - Return the longest common prefix in SLIST.
# Can be empty string.
# ------------------------------------------------------------------
-itcl::body Console::_find_lcp {slist} {
+body Console::_find_lcp {slist} {
# Handle trivial cases where list is empty or length 1
if {[llength $slist] <= 1} {return [lindex $slist 0]}
@@ -622,7 +536,7 @@ itcl::body Console::_find_lcp {slist} {
# METHOD: _find_completion - Look through COMPLETIONS to generate
# the suffix needed to do command
# ------------------------------------------------------------------
-itcl::body Console::_find_completion {cmd completions} {
+body Console::_find_completion {cmd completions} {
# Get longest common prefix
set lcp [_find_lcp $completions]
set cmd_len [string length $cmd]
@@ -633,7 +547,7 @@ itcl::body Console::_find_completion {cmd completions} {
# ------------------------------------------------------------------
# METHOD: _complete - Command line completion
# ------------------------------------------------------------------
-itcl::body Console::_complete {} {
+body Console::_complete {} {
set command_line [$_twin get {cmdmark + 1 char} {cmdmark lineend}]
set choices [gdb_cmd "complete $command_line" 1]
@@ -649,10 +563,10 @@ itcl::body Console::_complete {} {
# is one match, complete the command and print a space.
# If two or more matches, complete the command and beep.
# If no match, just beep.
- switch [llength $choices] {
+ switch {[llength $choices]} {
0 {}
1 {
- $_twin insert end "$completion "
+ _twin insert end "$completion "
set _saw_tab 0
return
}
@@ -686,62 +600,7 @@ itcl::body Console::_complete {} {
# METHOD: _reset_tab - Helper method for tab completion. Used
# to reset the tab when a key is pressed.
# ------------------------------------------------------------------
-itcl::body Console::_reset_tab {} {
+body Console::_reset_tab {} {
bind $_twin <KeyPress> {}
set _saw_tab 0
}
-
-
-# ------------------------------------------------------------------
-# METHOD: _set_wrap - Set wrap mode
-# ------------------------------------------------------------------
-itcl::body Console::_set_wrap {wrap} {
- if { $wrap } {
- set hsm none
- set wv char
- } else {
- set hsm dynamic
- set wv none
- }
-
- $itk_interior.stext configure -hscrollmode $hsm
- $_twin configure -wrap $wv
-}
-
-# ------------------------------------------------------------------
-# METHOD: _update_option - Update in response to preference change
-# ------------------------------------------------------------------
-itcl::body Console::_update_option {name value} {
- switch -- $name {
- gdb/console/wrap {
- _set_wrap $value
- }
-
- gdb/console/prompt_fg {
- $_twin tag configure prompt_tag -foreground $value
- }
-
- gdb/console/error_fg {
- $_twin tag configure err_tag -foreground $value
- }
- }
-}
-
-# ------------------------------------------------------------------
-# NAME: public method Console::test
-# DESCRIPTION: Executes the given command
-#
-# ARGUMENTS: Command to run
-# RETURNS: Return value of command
-#
-# NOTES: This will only run if env(GDBTK_TEST_RUNNING)==1.
-# FOR TESTING ONLY
-# ------------------------------------------------------------------
-itcl::body Console::test {args} {
- global env
-
- if {[info exists env(GDBTK_TEST_RUNNING)] && $env(GDBTK_TEST_RUNNING) == 1} {
- return [eval $args]
- }
-}
-
diff --git a/gdb/gdbtk/library/console.ith b/gdb/gdbtk/library/console.ith
index bf834f3223e..047991368c7 100644
--- a/gdb/gdbtk/library/console.ith
+++ b/gdb/gdbtk/library/console.ith
@@ -1,5 +1,5 @@
# Console window class definition for GDBtk.
-# Copyright (C) 1998, 1999, 2000, 2001, 2002 Red Hat, Inc.
+# Copyright 1998, 1999 Cygnus Solutions
#
# This program is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License (GPL) as published by
@@ -17,8 +17,8 @@
# blocks.
# ----------------------------------------------------------------------
-itcl::class Console {
- inherit EmbeddedWin GDBEventHandler
+class Console {
+ inherit EmbeddedWin
public {
#Approximate maximum number of lines allowed in widget
@@ -26,18 +26,14 @@ itcl::class Console {
method constructor {args}
method destructor {}
- method insert {line {tag ""}}
- method invoke {{controld 0}}
+ method idle {}
+ method busy {}
+ method insert {line}
+ method einsert {line}
+ method invoke {}
method _insertion {args}
+ method get_text {}
method activate {{prompt {}}}
- method test {args}
- method gets {}
-
- #
- # GDB Events
- #
- method busy {event}
- method idle {event}
}
private {
@@ -50,13 +46,8 @@ itcl::class Console {
variable _saved_insertion ""
variable _running 0
variable _saw_tab 0
- variable _pendingHistElement -1
- variable _input_mode 0
- variable _input_result ""
- variable _input_error 0
method _build_win {}
- method _cancel {}
method _complete {}
method _delete {{left 0}}
method _find_completion {cmd completions}
@@ -64,14 +55,11 @@ itcl::class Console {
method _first {}
method _last {}
method _next {}
- method _operate_and_get_next {}
method _paste {{check_primary 1}}
method _previous {}
method _reset_tab {}
method _search_history {}
method _rsearch_history {}
method _setprompt {{prompt {}}}
- method _set_wrap {wrap}
- method _update_option {name value}
}
}
diff --git a/gdb/gdbtk/library/data.itb b/gdb/gdbtk/library/data.itb
new file mode 100644
index 00000000000..ba756753824
--- /dev/null
+++ b/gdb/gdbtk/library/data.itb
@@ -0,0 +1,48 @@
+# Data-type class implementations for GDBtk.
+# Copyright 1997, 1998, 1999 Cygnus Solutions
+#
+# This program is free software; you can redistribute it and/or modify it
+# under the terms of the GNU General Public License (GPL) as published by
+# the Free Software Foundation; either version 2 of the License, or (at
+# your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+
+# ------------------------------------------------------------------
+# Stack
+# ------------------------------------------------------------------
+body Stack::constructor {} {
+ set _stack {}
+}
+
+body Stack::push {args} {
+ set _stack [concat $_stack $args]
+}
+
+body Stack::destructor {} {
+}
+
+body Stack::pop {} {
+ set thing [lindex $_stack end]
+ set _stack [lreplace $_stack end end]
+ return $thing
+}
+
+# ------------------------------------------------------------------
+# Queue
+# ------------------------------------------------------------------
+body Queue::constructor {} {
+}
+
+body Queue::destructor {} {
+}
+
+body Queue::pop {} {
+ set thing [lindex $_stack 0]
+ set _stack [lreplace $_stack 0 0]
+ return $thing
+}
+
diff --git a/gdb/gdbtk/library/data.ith b/gdb/gdbtk/library/data.ith
new file mode 100644
index 00000000000..cf2e2c51e42
--- /dev/null
+++ b/gdb/gdbtk/library/data.ith
@@ -0,0 +1,42 @@
+# Data-type class definitions for GDBtk.
+# Copyright 1997, 1998, 1999 Cygnus Solutions
+#
+# This program is free software; you can redistribute it and/or modify it
+# under the terms of the GNU General Public License (GPL) as published by
+# the Free Software Foundation; either version 2 of the License, or (at
+# your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+
+# Generic Stack
+class Stack {
+
+ public {
+ method constructor {}
+ method destructor {}
+
+ # Pop the stack. Empty string means empty stack.
+ method pop {}
+
+ # Push ARGS onto the stack.
+ method push {args}
+ }
+
+ protected variable _stack
+}
+
+# Generic Queue
+class Queue {
+ inherit Stack
+
+ public {
+ method constructor {}
+ method destructor {}
+
+ # Pop the queue. Empty string means empty queue.
+ method pop {}
+ }
+}
diff --git a/gdb/gdbtk/library/debugwin.itb b/gdb/gdbtk/library/debugwin.itb
index 623f044dafd..7ba9b7d0bea 100644
--- a/gdb/gdbtk/library/debugwin.itb
+++ b/gdb/gdbtk/library/debugwin.itb
@@ -1,5 +1,5 @@
# Debug window for GDBtk.
-# Copyright (C) 1998, 1999, 2000, 2001, 2002 Red Hat, Inc.
+# Copyright 1998, 1999 Cygnus Solutions
#
# This program is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License (GPL) as published by
@@ -21,11 +21,12 @@
#
# ARGS: None are used yet.
# -----------------------------------------------------------------------------
-itcl::body DebugWin::constructor {args} {
- debug $args
- window_name "Insight Debug" "Debug"
+body DebugWin::constructor {args} {
+ debug ""
+ window_name "GDBTK Debug" "Debug"
build_win
+ incr numTopWins
}
# -----------------------------------------------------------------------------
@@ -37,24 +38,10 @@ itcl::body DebugWin::constructor {args} {
#
# ARGS: None
# -----------------------------------------------------------------------------
-itcl::body DebugWin::destructor {} {
+body DebugWin::destructor {} {
# notify debug code that window is going away
::debug::debugwin ""
-}
-
-# -----------------------------------------------------------------------------
-# NAME: DebugWin::reconfig
-#
-# SYNOPSIS: Reconfigure callback
-#
-# DESC: Fixes up window colors
-#
-# ARGS: None
-# -----------------------------------------------------------------------------
-itcl::body DebugWin::reconfig {} {
- # This keeps the Debug window using its unique black background.
- # Otherwise, a reconfigure event will color it to match the other windows
- $itk_interior.s configure -textbackground black
+ incr numTopWins -1
}
# -----------------------------------------------------------------------------
@@ -66,7 +53,7 @@ itcl::body DebugWin::reconfig {} {
# file, if it exists. Notifies the debug functions in ::debug
# to send output here.
# -----------------------------------------------------------------------------
-itcl::body DebugWin::build_win {} {
+body DebugWin::build_win {} {
global gdb_ImageDir GDBTK_LIBRARY
set top [winfo toplevel $itk_interior]
@@ -74,9 +61,7 @@ itcl::body DebugWin::build_win {} {
# initialize the gdbtk_de array
if {![info exists ::gdbtk_de]} {
set ::gdbtk_de(ALL) 1
- set ::gdbtk_de(ERRORS_ONLY) 0
set ::gdbtk_de(others) 0
- set ::gdbtk_de(filter_var) ALL
}
# create menubar
@@ -118,7 +103,8 @@ itcl::body DebugWin::build_win {} {
$menu add cascade -menu $menu.help -label "Help" -underline 0
set m [menu $menu.help]
$m add command -label "Debugging Functions" -underline 0 \
- -command {open_help debug.html}
+ -command {ManagedWin::open HtmlViewer -force -file debug.html \
+ -topics {{{"Debug Functions" debug.html}}}}
$top configure -menu $menu
@@ -143,6 +129,7 @@ itcl::body DebugWin::build_win {} {
# override the window delete procedure so the messages are
# turned off first.
wm protocol $top WM_DELETE_WINDOW "::debug::debugwin {};destroy $top"
+
}
# -----------------------------------------------------------------------------
@@ -159,34 +146,17 @@ itcl::body DebugWin::build_win {} {
# func - function name of caller
# msg - message to display
# -----------------------------------------------------------------------------
-itcl::body DebugWin::puts {level cls func msg} {
+body DebugWin::puts {level cls func msg} {
+
# filter. check if we should display this message
# for now we always let high-level messages through
- if {$level == "I"} {
-
- # errors and warnings only
- if {$::gdbtk_de(ERRORS_ONLY)} { return }
-
- # ALL classes except those set
- if {$::gdbtk_de(ALL)} {
- if {[info exists ::gdbtk_de($cls)]} {
- if {$::gdbtk_de($cls)} {
- return
- }
- } elseif {$::gdbtk_de(others)} {
- return
- }
- }
-
- # ONLY the classes set
- if {!$::gdbtk_de(ALL)} {
- if {[info exists ::gdbtk_de($cls)]} {
- if {!$::gdbtk_de($cls)} {
- return
- }
- } elseif {!$::gdbtk_de(others)} {
+ if {!$::gdbtk_de(ALL) && $level == "I"} {
+ if {[info exists ::gdbtk_de($cls)]} {
+ if {!$::gdbtk_de($cls)} {
return
}
+ } elseif {!$::gdbtk_de(others)} {
+ return
}
}
@@ -211,7 +181,7 @@ itcl::body DebugWin::puts {level cls func msg} {
# func - function name
# ar - function arguments
# -----------------------------------------------------------------------------
-itcl::body DebugWin::put_trace {enter level func ar} {
+body DebugWin::put_trace {enter level func ar} {
set x [expr {$level * 2 - 2}]
if {$enter} {
$_t insert end "[string range $_bigstr 0 $x]$func " trace "$ar\n" args
@@ -229,7 +199,7 @@ itcl::body DebugWin::put_trace {enter level func ar} {
# DESC: Reads the contents of the debug log file, if it exists, into
# the DebugWin.
# -----------------------------------------------------------------------------
-itcl::body DebugWin::loadlog {} {
+body DebugWin::loadlog {} {
$_t delete 0.0 end
# Now load in log file, if possible.
# this is rather rude, using the logfile variable in the debug namespace
@@ -262,7 +232,7 @@ itcl::body DebugWin::loadlog {} {
#
# DESC: Re-sources all the .itb files.
# -----------------------------------------------------------------------------
-itcl::body DebugWin::_source_all {} {
+body DebugWin::_source_all {} {
foreach f [glob [file join $::GDBTK_LIBRARY *.itb]] {
source $f
}
@@ -275,7 +245,7 @@ itcl::body DebugWin::_source_all {} {
#
# DESC: Clears out the content of the debug window.
# -----------------------------------------------------------------------------
-itcl::body DebugWin::_clear {} {
+body DebugWin::_clear {} {
$_t delete 1.0 end
}
@@ -286,7 +256,7 @@ itcl::body DebugWin::_clear {} {
#
# DESC: Changes the background of the current contents of the window.
# -----------------------------------------------------------------------------
-itcl::body DebugWin::_mark_old {} {
+body DebugWin::_mark_old {} {
$_t tag add marked 1.0 "end - 1c"
}
@@ -297,7 +267,7 @@ itcl::body DebugWin::_mark_old {} {
#
# DESC: Changes the background of the current contents of the window.
# -----------------------------------------------------------------------------
-itcl::body DebugWin::_save_contents {} {
+body DebugWin::_save_contents {} {
set file [tk_getSaveFile -title "Choose debug window dump file" \
-parent [winfo toplevel $itk_interior]]
if {$file == ""} {
@@ -321,7 +291,7 @@ itcl::body DebugWin::_save_contents {} {
#
# DESC: Creates the Debug Window Options Dialog.
# -----------------------------------------------------------------------------
-itcl::body DebugWinDOpts::constructor {args} {
+body DebugWinDOpts::constructor {args} {
window_name "Debug Window Options"
build_win
eval itk_initialize $args
@@ -335,7 +305,7 @@ itcl::body DebugWinDOpts::constructor {args} {
#
# DESC: Destroys the Debug Window Options Dialog.
# -----------------------------------------------------------------------------
-itcl::body DebugWinDOpts::destructor {} {
+body DebugWinDOpts::destructor {} {
}
@@ -348,42 +318,29 @@ itcl::body DebugWinDOpts::destructor {} {
# user to select which information is displayed in the debug
# window and (eventually) how it looks.
# -----------------------------------------------------------------------------
-itcl::body DebugWinDOpts::build_win {} {
+body DebugWinDOpts::build_win {} {
wm title [winfo toplevel $itk_interior] "Debug Display Options"
# initialize here so we can resource this file and update the list
set _classes {DebugWin RegWin SrcBar SrcWin ToolBar WatchWin EmbeddedWin \
- ManagedWin GDBWin StackWin SrcTextWin global \
- BpWin TargetSelection ModalDialog ProcessWin \
- GDBEventHandler MemWin VarTree}
- set _classes [concat [lsort $_classes] others]
-
+ ManagedWin GDBWin StackWin SrcTextWin VariableWin global BPWin \
+ TargetSelection ModalDialog ProcessWin}
set f [frame $itk_interior.f]
set btns [frame $itk_interior.buttons]
- iwidgets::Labeledframe $f.display -labelpos nw -labeltext {Classes}
- set fr [$f.display childsite]
- radiobutton $fr.0 -text "Messages from ALL classes EXCEPT those selected below" \
- -variable ::gdbtk_de(filter_var) -value ALL -command [code $this _all]
- radiobutton $fr.1 -text "Messages from ONLY those classes selected below" \
- -variable ::gdbtk_de(filter_var) -value ONLY -command [code $this _all]
- radiobutton $fr.2 -text "Only WARNINGS and ERRORS" \
- -variable ::gdbtk_de(filter_var) -value ERRORS -command [code $this _all]
-
- grid $fr.0 -sticky w -padx 5 -pady 5
- grid $fr.1 -sticky w -padx 5 -pady 5
- grid $fr.2 -sticky w -padx 5 -pady 5
-
- iwidgets::Labeledframe $f.classes
+ iwidgets::Labeledframe $f.classes -labelpos nw -labeltext {Classes}
set fr [$f.classes childsite]
- set i 0
- foreach cls $_classes {
+ checkbutton $fr.0 -text ALL -variable ::gdbtk_de(ALL) -command [code $this _all]
+ set i 1
+ foreach cls [lsort $_classes] {
if {![info exists ::gdbtk_de($cls)]} {
set ::gdbtk_de($cls) 0
}
checkbutton $fr.$i -text $cls -variable ::gdbtk_de($cls)
incr i
}
+ checkbutton $fr.$i -text others -variable ::gdbtk_de(others)
+ incr i
set k [expr 3*(int($i/3))]
set more [expr $i - $k]
@@ -397,13 +354,12 @@ itcl::body DebugWinDOpts::build_win {} {
2 { grid $fr.$j $fr.[expr $j+1] x -sticky w -padx 5 -pady 5}
}
- pack $f.display -side top -expand 1 -fill both
pack $f.classes -side top -expand 1 -fill both
- button $btns.ok -text [gettext OK] -width 7 -command [code $this _apply 1] \
+ button $btns.ok -text [gettext OK] -width 7 -command [code delete object $this] \
-default active
button $btns.apply -text "Apply to All" -width 7 \
- -command [code $this _apply 0]
+ -command [code $this _apply]
if {$::debug::logfile == "" || $::debug::logfile == "stdout"} {
$btns.apply configure -state disabled
}
@@ -426,38 +382,12 @@ itcl::body DebugWinDOpts::build_win {} {
# DESC: Callback for selecting ALL classes. If the user selects ALL,
# deselect all the individual class checkbuttons.
# -----------------------------------------------------------------------------
-itcl::body DebugWinDOpts::_all {} {
- switch $::gdbtk_de(filter_var) {
- ALL {
- set ::gdbtk_de(ALL) 1
- set ::gdbtk_de(ERRORS_ONLY) 0
- #enable class buttons
- set num 0
- foreach class $_classes {
- [$itk_interior.f.classes childsite].$num configure -state normal
- incr num
- }
- }
- ONLY {
- set ::gdbtk_de(ALL) 0
- set ::gdbtk_de(ERRORS_ONLY) 0
- #enable class buttons
- set num 0
- foreach class $_classes {
- [$itk_interior.f.classes childsite].$num configure -state normal
- incr num
- }
- }
- ERRORS {
- set ::gdbtk_de(ALL) 0
- set ::gdbtk_de(ERRORS_ONLY) 1
- # disable class buttons
- set num 0
- foreach class $_classes {
- [$itk_interior.f.classes childsite].$num configure -state disabled
- incr num
- }
+body DebugWinDOpts::_all {} {
+ if {$::gdbtk_de(ALL)} {
+ foreach cls $_classes {
+ set ::gdbtk_de($cls) 0
}
+ set ::gdbtk_de(others) 0
}
}
@@ -471,13 +401,9 @@ itcl::body DebugWinDOpts::_all {} {
# log file through the new filter into the debug window. The
# button is disabled if there is no log file.
# -----------------------------------------------------------------------------
-itcl::body DebugWinDOpts::_apply { done } {
+body DebugWinDOpts::_apply {} {
set dw [ManagedWin::find DebugWin]
- debug $dw
if {$dw != ""} {
$dw loadlog
}
- if {$done} {
- delete object $this
- }
}
diff --git a/gdb/gdbtk/library/debugwin.ith b/gdb/gdbtk/library/debugwin.ith
index b6a961d6c5b..c9734c232e5 100644
--- a/gdb/gdbtk/library/debugwin.ith
+++ b/gdb/gdbtk/library/debugwin.ith
@@ -1,5 +1,5 @@
# Debug window class definition for GDBtk.
-# Copyright (C) 1998, 1999 Cygnus Solutions
+# Copyright 1998, 1999 Cygnus Solutions
#
# This program is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License (GPL) as published by
@@ -25,7 +25,7 @@
# This window is for developers.
#
# -----------------------------------------------------------------------------
-itcl::class DebugWin {
+class DebugWin {
inherit ManagedWin
private {
@@ -42,11 +42,6 @@ itcl::class DebugWin {
method _clear {}
method _mark_old {}
method _save_contents {}
- method reconfig {}
- }
-
- protected {
- method _ignore_on_save {} { return 1 }
}
public {
@@ -72,7 +67,7 @@ itcl::class DebugWin {
# This window is for developers.
#
# -----------------------------------------------------------------------------
-itcl::class DebugWinDOpts {
+class DebugWinDOpts {
inherit ManagedWin
public {
@@ -80,14 +75,11 @@ itcl::class DebugWinDOpts {
method destructor {}
}
- protected {
- method _ignore_on_save { return 1 }
- }
-
private {
variable _classes
method build_win {}
method _all {}
- method _apply {done}
+ method _apply {}
}
+
}
diff --git a/gdb/gdbtk/library/download.itb b/gdb/gdbtk/library/download.itb
index f20aecf07f3..c4de6d4723e 100644
--- a/gdb/gdbtk/library/download.itb
+++ b/gdb/gdbtk/library/download.itb
@@ -1,5 +1,5 @@
-# Download class implementation for Insight.
-# Copyright (C) 1999, 2001 Red Hat, Inc.
+# Download class implementation for GDBtk.
+# Copyright 1999 Cygnus Solutions
#
# This program is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License (GPL) as published by
@@ -17,7 +17,7 @@
#
# ----------------------------------------------------------------------
-itcl::body Download::constructor {args} {
+body Download::constructor {args} {
global gdb_pretty_name
debug $args
eval itk_initialize $args
@@ -31,30 +31,28 @@ itcl::body Download::constructor {args} {
set i 0
while {$i <$num_sections} {
- iwidgets::feedback $f.meter$i -steps $num_steps
- grid forget [$f.meter$i component percentage]
+ tixMeter $f.meter$i -value 0 -text 0
label $f.sec$i -text [lindex $section(names) $i] -anchor w
label $f.num$i -text $bytes($i) -anchor e
grid $f.sec$i $f.meter$i $f.num$i -padx 4 -pady 4 -sticky news
incr i
}
- grid columnconfigure $f 1 -weight 1
+
+ grid $itk_interior.dload -padx 5 -pady 5
+ grid $itk_interior.stat -padx 5 -pady 5
+ grid $itk_interior.f -padx 5 -pady 5
button $itk_interior.cancel -text Cancel -command "$this cancel" \
-state active -width 10
-
- pack $itk_interior.dload -padx 5 -pady 5 -side top -fill x -expand yes
- pack $itk_interior.stat -padx 5 -pady 5 -expand yes
- pack $itk_interior.f -padx 5 -pady 5 -fill x -expand yes
-
- pack $itk_interior.cancel -padx 5 -pady 5 -side bottom
- ::update idletasks
+ grid $itk_interior.cancel -padx 5 -pady 5
+# grid $itk_interior
+
}
# ------------------------------------------------------------------
# METHOD: update_download - update the download meters
# ------------------------------------------------------------------
-itcl::body Download::update_download { sec num tot } {
+body Download::update_download { sec num tot } {
# Loop through all the sections, marking each as either done or
# updating its meter. This will mark all previous sections prior to
@@ -63,36 +61,21 @@ itcl::body Download::update_download { sec num tot } {
set i $section($s)
if {$s == $sec} {
- # Advance feedback meter. The iwidgets meter leaves a lot to
- # be desired. No way to query the current setting. No way to
- # set the state of the meter by percentage. It only understands
- # steps, and we must be careful not to step the widget past the
- # the configured number of steps, or else the meter will be
- # set wrong. How lame.
- set steps [expr {$num / $bytes($i) * $num_steps}]
- if {[expr {$completed_steps($s) + $steps}] > $num_steps} {
- set steps [expr {$num_steps - $completed_steps($s)}]
- }
- incr completed_steps($s) $steps
- $itk_interior.f.meter$i step $steps
+ $itk_interior.f.meter$i config -value [expr {$num / $bytes($i)}] -text $num
break
} else {
- # Section already loaded. Make sure meter is at 100%.
- if {$completed_steps($s) < $num_steps} {
- set steps [expr {$num_steps - $completed_steps($s)}]
- set completed_steps($s) $num_steps
- $itk_interior.f.meter$i step $steps
+ if {[expr {double([$itk_interior.f.meter$i cget -value])}] != 1.0} {
+ $itk_interior.f.meter$i config -value 1.0 -text [expr {int($bytes($i))}]
}
}
}
-
::update
}
# ------------------------------------------------------------------
# METHOD: done - notification that the download is really complete
# ------------------------------------------------------------------
-itcl::body Download::done { {msg ""} } {
+body Download::done { {msg ""} } {
bell
if {$msg == ""} {
@@ -106,11 +89,7 @@ itcl::body Download::done { {msg ""} } {
# set all indicators to FULL
foreach sec $section(names) {
set i $section($sec)
- if {$completed_steps($sec) < $num_steps} {
- set steps [expr {$num_steps - $completed_steps($sec)}]
- set completed_steps($sec) $num_steps
- $itk_interior.f.meter$i step $steps
- }
+ $itk_interior.f.meter$i config -value 1.0 -text "DONE"
}
} else {
# download failed
@@ -127,7 +106,7 @@ itcl::body Download::done { {msg ""} } {
# ------------------------------------------------------------------
# METHOD: cancel - cancel the download
# ------------------------------------------------------------------
-itcl::body Download::cancel {} {
+body Download::cancel {} {
debug "canceling the download"
set ::download_cancel_ok 1
}
@@ -135,15 +114,15 @@ itcl::body Download::cancel {} {
# ------------------------------------------------------------------
# DESTRUCTOR - destroy window containing widget
# ------------------------------------------------------------------
-itcl::body Download::destructor {} {
+body Download::destructor {} {
remove_hook download_progress_hook "$this update_download"
}
-itcl::body Download::do_download_hooks {} {
+body Download::do_download_hooks {} {
set ::download_timer(ok) 1
}
-itcl::body Download::download_hash { section num } {
+body Download::download_hash { section num } {
global download_timer
debug "sec=$section num=$num tot=$total_bytes ok=$::download_cancel_ok"
::update
@@ -152,7 +131,7 @@ itcl::body Download::download_hash { section num } {
after cancel $download_timer(timer)
}
- set download_timer(timer) [after 100 Download::do_download_hooks]
+ set download_timer(timer) [after 333 Download::do_download_hooks]
if {![info exists download_timer(ok)] || $download_timer(ok)} {
run_hooks download_progress_hook $section $num $total_bytes
::update
@@ -164,25 +143,25 @@ itcl::body Download::download_hash { section num } {
}
# Download the executable. Return zero for success, and non-zero for error.
-itcl::body Download::download_it { } {
+body Download::download_it { } {
global gdb_exe_name gdb_downloading gdb_loaded
global gdb_target_name gdb_pretty_name
- global gdb_running gdbtk_platform
-
+ global gdb_running
+
debug "exe=$gdb_exe_name downloading=$gdb_downloading"
debug " loaded=$gdb_loaded target=$gdb_target_name running=$gdb_running"
-
+
if {$gdb_downloading || $gdb_exe_name == ""} {
return 0
}
-
+
set gdb_downloading 1
set gdb_loaded 0
# Make sure the source window has had time to be created
::update
-
+
gdbtk_busy
-
+
# Only places that load files should do set_exe
#set_exe
switch [set_target] {
@@ -205,22 +184,17 @@ itcl::body Download::download_it { } {
return 1
}
}
-
- if {[string compare $gdbtk_platform(os) "cygwin"] == 0} {
- set f [ide_cygwin_path to_win32 $gdb_exe_name]
- } else {
- set f $gdb_exe_name
- }
- if {! [file exists $f]} {
- tk_messageBox -icon error -title GDB -type ok \
+
+ if {! [file exists $gdb_exe_name]} {
+ tk_messageBox -icon error -title GDB -type ok -modal task\
-message "Request to download non-existent executable $gdb_exe_name"
set gdb_downloading 0
gdbtk_idle
return 0
}
-
+
debug "downloading $gdb_exe_name"
-
+
set target $gdb_target_name
# get load info and total up number of bytes
@@ -239,13 +213,13 @@ itcl::body Download::download_it { } {
set b [lindex $x 1]
set bytes($i) [expr {double($b)}]
incr total_bytes $b
- set completed_steps($s) 0
incr i
}
set num_sections $i
set ::download_cancel_ok 0
set ::download_start_time [clock seconds]
+
if {[pref getd gdb/load/$target-verbose] == "1"} {
# open a detailed download dialog window
@@ -258,7 +232,7 @@ itcl::body Download::download_it { } {
}
set download_dialog ""
}
-
+
set download_error ""
debug "starting load"
::update idletasks
@@ -271,7 +245,7 @@ itcl::body Download::download_it { } {
}
set ::download_cancel_ok 1
}
-
+
debug "Done loading"
set gdb_downloading 0
@@ -286,7 +260,7 @@ itcl::body Download::download_it { } {
catch {$download_dialog done}
}
}
-
+
foreach src [ManagedWin::find SrcWin] {
if {$download_error == "CANCEL"} {
$src download_progress CANCEL 1 1
diff --git a/gdb/gdbtk/library/download.ith b/gdb/gdbtk/library/download.ith
index a7ac2ad0fc9..9add1e71dad 100644
--- a/gdb/gdbtk/library/download.ith
+++ b/gdb/gdbtk/library/download.ith
@@ -1,5 +1,5 @@
-# Download class definition for Insight
-# Copyright (C) 1999, 2001 Red Hat, Inc.
+# Download class definition for GDBtk.
+# Copyright 1999 Cygnus Solutions
#
# This program is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License (GPL) as published by
@@ -12,7 +12,7 @@
# GNU General Public License for more details.
-itcl::class Download {
+class Download {
inherit ManagedWin
protected {
@@ -20,12 +20,6 @@ itcl::class Download {
common section
common bytes
common num_sections
- common num_steps 100
-
- # completed steps in feedback meter (iwidget::feedback is lame)
- common completed_steps
-
- method _ignore_on_save {} { return 1 }
proc dont_remember_size {} { return 1}
}
public {
diff --git a/gdb/gdbtk/library/embeddedwin.ith b/gdb/gdbtk/library/embeddedwin.ith
index 2cda6af6e08..5018cc6f972 100644
--- a/gdb/gdbtk/library/embeddedwin.ith
+++ b/gdb/gdbtk/library/embeddedwin.ith
@@ -1,5 +1,5 @@
# EmbeddedWin class definition for GDBtk.
-# Copyright (C) 1998, 1999, 2001 Red Hat
+# Copyright 1998, 1999 Cygnus Solutions
#
# This program is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License (GPL) as published by
@@ -12,14 +12,14 @@
# GNU General Public License for more details.
-itcl::class EmbeddedWin {
+class EmbeddedWin {
inherit ManagedWin
constructor {args} {
- debug "$args"
+ debug "EmbeddedWin::constructor $args"
}
destructor {
- debug
+ debug "EmbeddedWin::destructor"
}
}
diff --git a/gdb/gdbtk/library/gdbwin.ith b/gdb/gdbtk/library/gdbwin.ith
index 99895a09ab6..06c7d2d1369 100644
--- a/gdb/gdbtk/library/gdbwin.ith
+++ b/gdb/gdbtk/library/gdbwin.ith
@@ -1,5 +1,5 @@
-# GDBwin class definition for Insight.
-# Copyright (C) 1998, 1999, 2001 Red Hat, Inc.
+# GDBwin class definition for GDBtk.
+# Copyright 1998, 1999 Cygnus Solutions
#
# This program is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License (GPL) as published by
@@ -12,14 +12,15 @@
# GNU General Public License for more details.
-itcl::class GDBWin {
- inherit GDBEventHandler
+class GDBWin {
+ private variable _state
+ public method update
constructor {args} {
- debug "$args"
+ debug "GDBWin::constructor $args"
}
destructor {
- debug
+ debug "GDBWin::destructor"
}
}
diff --git a/gdb/gdbtk/library/globalpref.itb b/gdb/gdbtk/library/globalpref.itb
index ee70384c71b..cd61e90694e 100644
--- a/gdb/gdbtk/library/globalpref.itb
+++ b/gdb/gdbtk/library/globalpref.itb
@@ -1,5 +1,5 @@
-# Global preference class implementation for Insight.
-# Copyright (C) 1997, 1998, 1999, 2002, 2003, 2004, 2008 Red Hat
+# Global preference class implementation for GDBtk.
+# Copyright 1997, 1998, 1999 Cygnus Solutions
#
# This program is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License (GPL) as published by
@@ -18,9 +18,9 @@
# ----------------------------------------------------------------------
# ------------------------------------------------------------------
-# METHOD: _init - set up the tracing labels info
+# PROC: _init - set up the tracing labels info
# ------------------------------------------------------------------
-itcl::body GlobalPref::_init {} {
+body GlobalPref::_init {} {
if {$inited} {
return
}
@@ -41,42 +41,29 @@ itcl::body GlobalPref::_init {} {
}
# ------------------------------------------------------------------
-# METHOD: init_var - initialize preference variables
-# ------------------------------------------------------------------
-itcl::body GlobalPref::_init_var {} {
- set vlist {gdb/ImageDir gdb/console/wrap gdb/mode gdb/use_icons gdb/compat gdb/use_color_schemes}
-
- foreach var $vlist {
- set _saved($var) [pref get $var]
- set _new($var) $_saved($var)
- }
-}
-
-# ------------------------------------------------------------------
# METHOD: constructor - create the Global Preferences object
# ------------------------------------------------------------------
-itcl::body GlobalPref::constructor {args} {
+body GlobalPref::constructor {args} {
window_name "Global Preferences"
_init
- _init_var
- _build_win
+ build_win
eval itk_initialize $args
}
# ------------------------------------------------------------------
# METHOD: destructor - destroy the Global Preferences object
# ------------------------------------------------------------------
-itcl::body GlobalPref::destructor {} {
- foreach thunk $_fonts {
+body GlobalPref::destructor {} {
+ foreach thunk $Fonts {
font delete test-$thunk-font
}
}
# ------------------------------------------------------------------
-# METHOD: _build_win - build the dialog
+# METHOD: build_win - build the dialog
# ------------------------------------------------------------------
-itcl::body GlobalPref::_build_win {} {
- global gdbtk_platform GDBTK_LIBRARY
+body GlobalPref::build_win {} {
+ global tcl_platform GDBTK_LIBRARY
debug
frame $itk_interior.f
frame $itk_interior.x
@@ -86,22 +73,22 @@ itcl::body GlobalPref::_build_win {} {
frame $frame.icons
label $frame.icons.lab -text "Icons "
combobox::combobox $frame.icons.cb -editable 0 -maxheight 10\
- -command [code $this _change_icons] -bg $::Colors(textbg)
+ -command [code $this change_icons]
# get list of icon directories
- set curdir [pwd]
- set _icondirlist ""
+ set icondirlist ""
cd $GDBTK_LIBRARY
foreach foo [glob -- *] {
if {[file isdirectory $foo] && [file exists [file join $foo "icons.txt"]]} {
- lappend _icondirlist $foo
+ lappend icondirlist $foo
}
}
-
+
set width 14
# load combobox
- foreach dir $_icondirlist {
- if {![string compare $dir $_saved(gdb/ImageDir)]} {
+ set imagedir [pref get gdb/ImageDir]
+ foreach dir $icondirlist {
+ if {![string compare $dir $imagedir]} {
set cdir 1
} else {
set cdir 0
@@ -109,7 +96,6 @@ itcl::body GlobalPref::_build_win {} {
set foo [file join $dir "icons.txt"]
if {[catch {::open $foo r} fid]} {
# failed
- dbug E "couldn't open $foo:$fid"
if {$cdir} {$frame.icons.cb entryset "unknown icons"}
$frame.icons.cb list insert end "unknown icons"
} else {
@@ -125,7 +111,7 @@ itcl::body GlobalPref::_build_win {} {
}
}
$frame.icons.cb configure -width $width
- cd $curdir
+
# searching for fixed font families take a long time
# therefore, we cache the font names. The font cache
@@ -133,24 +119,8 @@ itcl::body GlobalPref::_build_win {} {
# to rescan the font list, without deleting the entry from the
# init file.
set font_cache [pref get gdb/font_cache]
-
- # get list of fonts, removing some that typically
- # are not useful or cause tk problems
- set fam [lremove [font families] "open look glyph"]
- set fam [lremove $fam "open look cursor"]
- set fam [lremove $fam "song ti"]
- set fam [lremove $fam "clearlyu"]
- set fam [lremove $fam "clearlyu alternate glyphs"]
- set fam [lremove $fam "clearlyu arabic extra"]
- set fam [lremove $fam "clearlyu ligature"]
- set fam [lremove $fam "clearlyu pua"]
- set fam [lremove $fam "fangsong ti"]
- set fam [lremove $fam "newspaper"]
- set fam [lremove $fam "palatino linotype"]
- set fam [lsort $fam]
-
if {$font_cache == ""} {
- if {$gdbtk_platform(platform) == "unix"} {
+ if {$tcl_platform(platform) == "unix"} {
toplevel .c
wm title .c "Scanning for fonts"
message .c.m -width 3i -text "Scanning system for fonts\n\nPlease wait..." \
@@ -163,99 +133,81 @@ itcl::body GlobalPref::_build_win {} {
::raise .c
::update
}
-
+ set fam [font families]
foreach fn $fam {
if {[font metrics [list $fn] -fixed] == 1} {
lappend font_cache $fn
}
}
pref set gdb/font_cache $font_cache
- if {[winfo exists .c]} { destroy .c }
+ if {$tcl_platform(platform) == "unix"} { destroy .c }
}
Labelledframe $frame.d -text "Fonts"
set f [$frame.d get_frame]
- _make_font_item $f fixed "Fixed Font:" $font_cache
+ make_font_item $f fixed "Fixed Font:" $font_cache
- if {$gdbtk_platform(platform) != "windows"} {
+ if {$tcl_platform(platform) != "windows"} {
# Cannot change the windows menu font ourselves
- _make_font_item $f menu "Menu Font:" $fam
+ make_font_item $f menu "Menu Font:" [font families]
}
- _make_font_item $f default "Default Font:" $fam
- _make_font_item $f status "Status Bar Font:" $fam
-
-
- iwidgets::Labeledframe $frame.misc -labelpos nw -labeltext "Misc"
- set f [$frame.misc childsite]
+ make_font_item $f default "Default Font:" [font families]
+ make_font_item $f status "Status Bar Font:" [font families]
# This is the tracing preference
set tracing_cb [pref get gdb/mode]
if { ![info exists tracing_labels($tracing_cb)]} {
- dbug E "Got unknown mode value: $tracing_cb"
+ debug "Got unknown mode value: $tracing_cb"
set tracing_labels($tracing_cb) "Unknown gdb mode..."
}
- checkbutton $f.tracing -variable [scope _new(gdb/mode)] \
+ frame $frame.tracing
+ checkbutton $frame.tracing.cb -variable [scope tracing_cb] \
-text $tracing_labels($tracing_cb) \
- -command [code $this _toggle_tracing $f.tracing] \
+ -command [code $this toggle_tracing $frame.tracing.cb] \
-width $tracing_labels(max_len) -anchor w
+ pack $frame.tracing.cb -pady 10 -side left -fill none
- # use_icons
- if {$gdbtk_platform(platform) == "unix"} {
- checkbutton $f.use_icons \
- -text "Use builtin image as icon." -variable [scope _new(gdb/use_icons)]
+ # help browser preferences
+ if {$tcl_platform(platform) == "windows"} {
+ set help_text "Use Internet Browser to View Help Files"
+ } else {
+ set help_text "Use Netscape to View Help Files"
}
+ frame $frame.browser
+ checkbutton $frame.browser.cb \
+ -text $help_text -variable [pref varname gdb/help/browser]
+ pack $frame.browser.cb -pady 10 -side left -fill none
- # console wrap
- checkbutton $f.consolewrap -text "Wrap text in console window" \
- -variable [scope _new(gdb/console/wrap)]
-
- # colored backgrounds
- checkbutton $f.use_cs -text "Enable Color Schemes" \
- -variable [scope _new(gdb/use_color_schemes)]
-
- grid $f.tracing -sticky w -padx 5 -pady 5
-
- if {$gdbtk_platform(platform) == "unix"} {
- grid $f.use_icons -sticky w -padx 5 -pady 5
- }
- grid $f.consolewrap -sticky w -padx 5 -pady 5
- grid $f.use_cs -sticky w -padx 5 -pady 5
-
- if {$gdbtk_platform(platform) == "unix"} {
- # Compatibility frame
- iwidgets::Labeledframe $frame.compat -labelpos nw -labeltext "OS Compatibility"
- set fc [$frame.compat childsite]
- radiobutton $fc.0 -text "GNOME" -value "GNOME" -variable [scope _new(gdb/compat)]
- radiobutton $fc.1 -text "KDE" -value "KDE" -variable [scope _new(gdb/compat)]
- radiobutton $fc.2 -text "default" -value "default" -variable [scope _new(gdb/compat)]
- grid $fc.0 -sticky w -padx 5 -pady 5
- grid $fc.1 -sticky w -padx 5 -pady 5
- grid $fc.2 -sticky w -padx 5 -pady 5
- grid [label $fc.warn -text "Restart required for all\nchanges to take effect"] -sticky w
+ # use_icons
+ if {$tcl_platform(platform) == "unix"} {
+ frame $frame.use_icons
+ checkbutton $frame.use_icons.cb \
+ -text "Use builtin image as icon." -variable [pref varname gdb/use_icons]
+ pack $frame.use_icons.cb -pady 10 -side left -fill none
}
- # pack it all
pack $frame.icons.lab $frame.icons.cb -side left
- grid $frame.icons x -sticky w -pady 10
- grid $frame.d -columnspan 2 -sticky w
- if {$gdbtk_platform(platform) == "unix"} {
- grid $frame.compat $frame.misc -sticky we
- } else {
- grid $frame.misc x -sticky we
+ pack $frame.icons -side top -padx 10 -pady 10
+ pack $frame.tracing -side top -fill x -expand 0 -side bottom
+ pack $frame.browser -side top -fill x -expand 0 -side bottom
+ if {$tcl_platform(platform) == "unix"} {
+ pack $frame.use_icons -side top -fill x -expand 0 -side bottom
}
+ pack $frame.d -side top -fill both -expand yes
# make buttons
- button $itk_interior.x.ok -text OK -underline 0 -width 7 -command [code $this _ok]
- button $itk_interior.x.apply -text Apply -width 7 -underline 0 -command [code $this _apply]
- button $itk_interior.x.cancel -text Cancel -width 7 -underline 0 -command [code $this _cancel]
+ button $itk_interior.x.ok -text OK -underline 0 -width 7 -command [code $this ok]
+ button $itk_interior.x.apply -text Apply -width 7 -underline 0 -command [code $this apply]
+ button $itk_interior.x.cancel -text Cancel -width 7 -underline 0 -command [code $this cancel]
pack $itk_interior.x.ok $itk_interior.x.apply $itk_interior.x.cancel -side left
standard_button_box $itk_interior.x
-
pack $itk_interior.x -fill x -padx 5 -pady 5 -side bottom
- pack $itk_interior.f -fill both -expand yes -padx 5 -pady 5
+
+
+ pack $itk_interior.f -fill both -expand yes -padx 10 -pady 5
bind $itk_interior.x.ok <Return> \
"$itk_interior.x.ok flash; $itk_interior.x.ok invoke"
@@ -265,50 +217,46 @@ itcl::body GlobalPref::_build_win {} {
::update idletasks
- _resize_font_item_height
+ resize_font_item_height
pack propagate $itk_interior.f 0
}
# ------------------------------------------------------------------
-# PRIVATE METHOD: _make_font_item
+# PRIVATE METHOD: make_font_item
# ------------------------------------------------------------------
-itcl::body GlobalPref::_make_font_item {f name label font_list} {
+body GlobalPref::make_font_item {f name label font_list} {
# create ComboBox with font name
- lappend _fonts $name
+ lappend Fonts $name
- set _original($name,family) [font actual global/$name -family]
- set _original($name,size) [font actual global/$name -size]
- font create test-$name-font -family $_original($name,family) \
- -size $_original($name,size)
+ set Original($name,family) [font actual global/$name -family]
+ set Original($name,size) [font actual global/$name -size]
+ font create test-$name-font -family $Original($name,family) \
+ -size $Original($name,size)
label $f.${name}x -text $label
-
- combobox::combobox $f.${name}n -editable 0 -value $_original($name,family) \
- -command [code $this _change_font $name] -bg $::Colors(textbg)
-
+
+ combobox::combobox $f.${name}n -editable 0 -value $Original($name,family) \
+ -command [code $this wfont_changed family $name]
+
foreach a $font_list {
$f.${name}n list insert end $a
}
- itk_component add $name-size {
- iwidgets::spinint $f.${name}s -labeltext "Size:" -range {6 18} -step 1 \
- -fixed 2 -width 2 -textvariable [scope _size($name)] -wrap 0 \
- -increment [code $this _change_size up $name] \
- -decrement [code $this _change_size down $name] \
- -textbackground $::Colors(textbg)
- } {}
+ tixControl $f.${name}s -label Size: -integer true -max 18 -min 6 \
+ -value $Original(${name},size) -command [code $this font_changed size $name]
+ [$f.${name}s subwidget entry] configure -width 2
label $f.${name}l -text ABCDEFabcdef0123456789 -font test-$name-font
- set _size($name) $_original($name,size)
-
+
grid $f.${name}x $f.${name}n $f.${name}s $f.${name}l -sticky we -padx 5 -pady 5
grid columnconfigure $f 3 -weight 1
+
}
# ------------------------------------------------------------------
-# PRIVATE METHOD: _resize_font_item_height
+# PRIVATE METHOD: resize_font_item_height
# ------------------------------------------------------------------
-itcl::body GlobalPref::_resize_font_item_height {} {
- foreach font $_fonts {
+body GlobalPref::resize_font_item_height {} {
+ foreach font $Fonts {
set master [$itk_interior.f.d get_frame]
set row [gridCGet $master.${font}l -row]
grid rowconfigure $master $row -minsize [lindex [grid bbox $master 0 $row 3 $row ] 3]
@@ -316,73 +264,73 @@ itcl::body GlobalPref::_resize_font_item_height {} {
}
# ------------------------------------------------------------------
-# PRIVATE METHOD: _change_icons
+# PRIVATE METHOD: change_icons
# ------------------------------------------------------------------
-itcl::body GlobalPref::_change_icons {w args} {
- set index [$w curselection]
+body GlobalPref::change_icons {w args} {
+ global gdb_ImageDir GDBTK_LIBRARY
+ set index [$w list curselection]
if {$index != ""} {
- set _new(gdb/ImageDir) [lindex $_icondirlist $index]
+ set dir [lindex $icondirlist $index]
+ pref set gdb/ImageDir $dir
+ set gdb_ImageDir [file join $GDBTK_LIBRARY $dir]
+ ManagedWin::restart
}
}
# ------------------------------------------------------------------
-# NAME: private method GlobalPref::_change_font
-# DESCRIPTION: Change the given font's family
-#
-# ARGUMENTS:
-# font - the font whose family is to be
-# changed
-# stupid - the comobox widget which changed
-# implementation - the new value of the combobox
-# RETURNS: Nothing
-#
-# NOTES: The combobox has a really non-standard callback
-# mechanism: it always adds two args to the callback.
+# PRIVATE METHOD: wfont_changed - callback from font comboboxes
+# PRIVATE METHOD: font_changed - callback from font tixControls
# ------------------------------------------------------------------
-itcl::body GlobalPref::_change_font {font stupid implementation} {
- font configure test-$font-font -family $implementation
+body GlobalPref::wfont_changed {attribute font w val} {
+ font_changed $attribute $font $val
+}
+
+body GlobalPref::font_changed {attribute font val} {
+ # val will be a size or a font name
+
+ switch $attribute {
+ size {
+ set oldval [font configure test-$font-font -size]
+ font configure test-$font-font -size $val
+ }
+
+ family {
+ set oldval [font configure test-$font-font -family]
+ font configure test-$font-font -family $val
+ }
+
+ default { debug "GlobalPref::font_changed -- invalid change" }
+ }
}
# ------------------------------------------------------------------
-# NAME: private method GlobalPref::_change_size
-# DESCRIPTION: Change the given font's size
-#
-# ARGUMENTS:
-# direction - the direction of the change (up/down)
-# font - the font that is changing
-# RETURNS: Nothing
-#
-# NOTES: See comments for purpose of "direction". Sigh.
+# METHOD: toggle_tracing_mode - toggles the tracing mode on and off
# ------------------------------------------------------------------
-itcl::body GlobalPref::_change_size {direction font} {
-
- # Almost as stupid as the comobox, the iwidgets::spinint class
- # will not treat its -increment and -decrement commands
- # as command callbacks. Instead it OVERRIDES all behavior.
- # Thus, we need to call the stupid spinint's callback.
- $itk_component($font-size) $direction
- font configure test-$font-font -size $_size($font)
+body GlobalPref::toggle_tracing_mode {} {
+ pref set gdb/mode $tracing_cb
+ # Reset the button-1 behavior if you are going out of trace mode.
+ if {!$tracing_cb} {
+ pref set gdb/B1_behavior 1
+ }
}
-
-itcl::body GlobalPref::_toggle_tracing {win} {
- debug
- $win configure -text $tracing_labels($_new(gdb/mode))
+body GlobalPref::toggle_tracing {win} {
+ debug foo
+ $win configure -text $tracing_labels($tracing_cb)
}
# ------------------------------------------------------------------
-# METHOD: _ok - called to accept settings and close dialog
+# METHOD: ok - called to accept settings and close dialog
# ------------------------------------------------------------------
-itcl::body GlobalPref::_ok {} {
- _apply 1
+body GlobalPref::ok {} {
+ apply 1
}
# ------------------------------------------------------------------
-# METHOD: _apply - apply current settings to the screen
+# METHOD: apply - apply current settings to the screen
# ------------------------------------------------------------------
-itcl::body GlobalPref::_apply {{deleteMe 0}} {
- debug
- set changed_something 0
+body GlobalPref::apply {{deleteMe 0}} {
+ set commands {}
# If you are not destroying the window, then make sure to
# propagate the geometry info from the font frame, so that changing
@@ -393,89 +341,61 @@ itcl::body GlobalPref::_apply {{deleteMe 0}} {
pack propagate $itk_interior.f 1
}
- foreach thunk $_fonts {
+ foreach thunk $Fonts {
set font [font configure test-$thunk-font]
if {[pref get global/font/$thunk] != $font} {
- pref set global/font/$thunk $font
+ lappend commands [list pref set global/font/$thunk $font]
}
}
- foreach var [array names _new] {
- if {$_new($var) != [pref get $var]} {
- debug "$var = $_new($var)"
-
- if {$var == "gdb/mode"} {
- if {!$_new(gdb/mode)} { pref set gdb/B1_behavior 1 }
- } elseif {$var == "gdb/ImageDir"} {
- set ::gdb_ImageDir [file join $::GDBTK_LIBRARY $_new($var)]
- }
- pref set $var $_new($var)
- set changed_something 1
- }
+ if {[pref get gdb/mode] != $tracing_cb} {
+ lappend commands toggle_tracing_mode
}
- if {$changed_something} {
- if {$deleteMe} { unpost }
+ if {[llength $commands] > 0} {
+ foreach command $commands {
+ eval $command
+ }
+ if {$deleteMe} {
+ unpost
+ }
ManagedWin::restart
return
}
- if {$deleteMe} {
- unpost
+ if {$deleteMe} {
+ unpost
} else {
after idle "
update idletasks
- [code $this _resize_font_item_height]
+ [code $this resize_font_item_height]
pack propagate $itk_interior.f 0
"
}
}
# ------------------------------------------------------------------
-# METHOD: _cancel - forget current settings -- reset to original
+# METHOD: cancel - forget current settings -- reset to original
# state and close preferences
# ------------------------------------------------------------------
-itcl::body GlobalPref::_cancel {} {
- debug
- set changed_something 0
-
+body GlobalPref::cancel {} {
# Reset fonts if different
- foreach thunk $_fonts {
+ set commands {}
+ foreach thunk $Fonts {
set family [font configure global/$thunk -family]
set size [font configure global/$thunk -size]
- if {$_original($thunk,family) != $family || $_original($thunk,size) != $size} {
- pref set global/font/$thunk \
- [list -family $_original($thunk,family) -size $_original($thunk,size)]
- set changed_something 1
+ if {$Original($thunk,family) != $family || $Original($thunk,size) != $size} {
+ lappend commands [list pref set global/font/$thunk \
+ [list -family $Original($thunk,family) -size $Original($thunk,size)]]
}
}
- foreach var [array names _saved] {
- if {$_saved($var) != [pref get $var]} {
- debug "$var = $_saved($var)"
-
- if {$var == "gdb/mode"} {
- if {!$_saved(gdb/mode)} { pref set gdb/B1_behavior 1 }
- } elseif {$var == "gdb/ImageDir"} {
- set ::gdb_ImageDir [file join $::GDBTK_LIBRARY $_saved($var)]
- }
- pref set $var $_saved($var)
- set changed_something 1
+ if {[llength $commands] > 0} {
+ foreach command $commands {
+ eval $command
}
}
-
- if {$changed_something} {
+ if {[llength $commands] > 0} {
ManagedWin::restart
}
unpost
}
-
-# ------------------------------------------------------------------
-# METHOD: cancel - override modal dialog cancel method.
-# The cancel method is actually called when
-# the window is closed. Name needs fixed.
-# ------------------------------------------------------------------
-itcl::body GlobalPref::cancel {} {
- # when the window is closed, we want the preferences selected to
- # be applied.
- _apply 1
-}
diff --git a/gdb/gdbtk/library/globalpref.ith b/gdb/gdbtk/library/globalpref.ith
index 2f89a70ce88..34ef45e77a0 100644
--- a/gdb/gdbtk/library/globalpref.ith
+++ b/gdb/gdbtk/library/globalpref.ith
@@ -1,5 +1,5 @@
# Global preference class definition for GDBtk.
-# Copyright (C) 1998, 1999 Cygnus Solutions
+# Copyright 1998, 1999 Cygnus Solutions
#
# This program is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License (GPL) as published by
@@ -12,36 +12,34 @@
# GNU General Public License for more details.
-itcl::class GlobalPref {
+class GlobalPref {
inherit ManagedWin ModalDialog
private {
- variable _new
- variable _saved
- variable _icondirlist ""
- variable _original ;# Original font settings
- variable _size ;# Array tracking spinint values
- variable _fonts ;# List of all available fonts for editing
+ variable icondirlist ""
+ variable Original ;# Original settings
+ variable Fonts ;# List of all available fonts for editing
common tracing_labels
common inited 0
+ variable tracing_cb
- method _init {}
- method _init_var {}
- method _build_win {}
- method _make_font_item {f name label font_list}
- method _resize_font_item_height {}
- method _change_icons {w args}
- method _change_font {font stupid implementation}
- method _change_size {direction font}
- method _ok {}
- method _apply {{deleteMe 0}}
- method _cancel {}
+ proc _init {}
+ method build_win {}
+ method make_font_item {f name label font_list}
+ method resize_font_item_height {}
+ method change_icons {w args}
+ method wfont_changed {attribute font w val}
+ method font_changed {attribute font val}
+ method toggle_tracing_mode {}
+ method ok {}
+ method apply {{deleteMe 0}}
method cancel {}
- method _toggle_tracing {win}
+ method toggle_tracing {win}
}
public {
method constructor {args}
method destructor {}
}
+
}
diff --git a/gdb/gdbtk/library/help/browser.html b/gdb/gdbtk/library/help/browser.html
index df9203beedc..a6a731f9925 100644
--- a/gdb/gdbtk/library/help/browser.html
+++ b/gdb/gdbtk/library/help/browser.html
@@ -3,75 +3,80 @@
<TITLE>Function Browser Help</TITLE>
</HEAD>
<BODY>
-<H1>The Function Browser</H1>
-<img src="images/browser1.png" alt="layout1" width=164 height=171 align="right" border=0>
-<img src="images/browser2.png" alt="layout2" width=164 height=170 align="right" border=0>
-
-<h2>Overview</h2>
-<p>The Function Browser may be used to search for specific functions
+<CENTER><H1>The Function Browser</H1></CENTER>
+<BR>The Function Browser may be used to search for specific functions
in the executable, allowing the user to easily browse through source
code and set and clear breakpoints at anywhere in the executable
-with ease. Its powerful regular expression searches allow the user
-to easily set breakpoints on multiple functions at once.</p>
-<p>The Function Browser has two different layouts. Both layouts contain the same four sections;
-Files, Function Filter, Functions, and Source Display.</p>
+with ease.
+
+<H3><A HREF="#display">Function Browser Display</A></H3>
+<UL>
+ <LI><A HREF="#display_search">Searching for a Function</A>
+ <LI><A HREF="#display_limit">Limiting the Search</A>
+ <LI><A HREF="#display_break">Toggling Breakpoints</A>
+ <LI><A HREF="#display_source">Viewing Source Code</A>
+</UL></P>
+
+<H2><A NAME="display">Function Browser Display</A></H2>
+The Function Browser display shows all the current search
+parameters specified by the user: search type, search expression,
+and files to search.
-<h3>Files</h3>
-<p>The Files section displays a list of all the source files. The files are
-read from the debug information in the program being debugged. To see
-the list of functions in a file, click on it. The function list should appear
-in the Functions Display and the source should appear in the Source Display.
-You can select multiple files by using the Control or Shift keys while
-clicking the left mouse button. When multiple files are selected, all the functions in those files
-are displayed in the Functions Display.
-</p>
-<p>At the bottom of the Files Display, you should see a checkbutton labelled "Hide .h files"
-and a button labelled "Select All". Checking "Hide .h files" will remove all
-files ending in ".h" from the Files Display. Clicking "Select All" will select all files
-in the Files Display.</p>
+<H4><A NAME="display_search">Searching for a Function</A></H4>
+To search for a function, enter
+the name of the function into the "Search for" field at the top
+of the Function Browser and press the Enter key on the keyboard
+or press the Search button in the lower right-hand corner. The
+Function Browser searches through every file contained in the
+executable (including libraries and included files) for the
+specified function. If the function is found in the executable's
+symbol table, the Functions listing will contain the function's
+name.
-<h3>Function Filter</h3>
-<p>Above the Function Display you should see a section labelled "Function Filter".
-The purpose of this section is to apply a filter to the list of functions in the Functions Display.
-For example, if you click "Select All" in the Files Display, then many hundreds of functions
-could appear in the Functions Display. To see all functions containing the string "print", for example, click on the combobox in the Function Filter and select "contains".
-Then type "print" into the box to the right and hit the enter or return key. You should see the Function
-Display updated with a list of all functions containing "print".</p>
+<H4><A NAME="display_limit">Limiting the Search</A></H4>
+Searches are not confined to one specific function. The Function
+Browser is capable of searching for any function which matches
+the expression entered into the "Search for" field. For example,
+to list all functions which start with the letters c, y, and g,
+enter "cyg" into the search field and press enter. Every function
+which begins with these three letters is displayed. To search
+for all functions which do <I>not</I> begin with the letters "a",
+"b", and "c", enter the regular expression "^[^a-c]" into the search
+field, click the "Use regular expression" checkbox, and then click
+Search (or press the Enter key on the keyboard). The Browser returns
+the names of all matching functions.
-<p>Insight remember what the last filter you used was and will always open the Function
-Browser window with the last filter settings.
-</p>
+<P>Additionally, any search may be limited in two more ways:
+the Browser may be configured to search only specified files and
+list only static functions.</P>
-<h3>Function Display</h3>
-<p>The Function Display contains the list of functions in the files that have been
-selected in the Files Display, after running them through any filter settings in the Filter Display.
-There are two buttons at the bottom of the display that allow you so set or delete breakpoints on every function
-in the Function Display in one operation.
-</p>
-<p>For example, to set a breakpoint of every function name containing "print", follow the example in the Function Filter section to
-get a list of all functions containing "print". Then simply click the "Set BP" button.</p>
+<P>To search specific files only, select the files to be searched
+using the Files list. To select all files for searching, click the
+Select All button at the bottom of the Files listing. Note that
+the Select All button changes to Select None, allowing the user to
+deselect all selected files. With no files selected, the Browser
+will search all files in the project.</P>
-<h3>Source Display</h3>
-<p>The Source Display shows the source code for any file selected in the File Display. If a function
-is selected in the Function Display, the first line of that function containing
-executable code will be highlighted. If no source file is found, then the function will be
-displayed disassembled.</p>
+<P>To search for static functions only, click the "Only show
+functions declared 'static'" before searching.</P>
-<p>At the bottom of the window are two comboboxes and a text field. The combobox on the far left
-contains the function name or file location to display. Normally this is just output for your information, however
-you can type the name of any function into this box to see its source.
-</p>
-<p>To the right of this is another combobox that allows you to toggle between source and assembly.
-</p>
-<p>To the far right is an empty field. You can type a string in it and hit enter to
-search the current source file for any string.</p>
-<p>In the source window itself, you can set breakpoints just like the source window.</p>
-<h3>Popup Menu</h3>
-<p>If you click the right mouse button while over the File Browser, you should get a simple menu
-with three options; <i>Toggle Layout</i>, <i>Help</i>, and <i>Close</i>. <i>Toggle Layout</i>
-switches you between the two different Browser Window layouts. Choose the one you like best;
-Insight will remember it between sessions. <i>Help</i> pops up this help window. <i>Close</i> closes the Function Browser.
-</p>
+<H4><A NAME="display_break">Toggling Breakpoints</A></H4>
+There are numerous ways to toggle
+breakpoints on functions using the Function Browser. To toggle the
+breakpoint at all listed matches in the Functions list, press the
+Toggle Breakpoint button. To toggle a breakpoint at some subset
+of functions listed in the Functions list, click the right mouse
+button on each function's name in the list. The last way to toggle
+breakpoints using the function browser involves viewing the function's
+source code.
+<H4><A NAME="display_source">Viewing Source Code</A></H4>
+To view the source code for a function,
+select the function in the Functions list and click the "View Source"
+dropdown (if it is not already dropped down). A Source Viewer
+similar to the <A HREF="source.html#display">Source Window Display</A>
+appears at the bottom. Toggle breakpoints as described in
+<A HREF="source.html#setting_a_breakpoint">Setting a Breakpoint</A>
+in <A HREF="source.html">Source Window Help</A>.
</BODY>
</HTML>
diff --git a/gdb/gdbtk/library/help/debug.html b/gdb/gdbtk/library/help/debug.html
index 528a868ff5f..11b9979deca 100644
--- a/gdb/gdbtk/library/help/debug.html
+++ b/gdb/gdbtk/library/help/debug.html
@@ -1,18 +1,16 @@
<HTML>
<HEAD>
-<TITLE>Internal Debugging Help</TITLE>
+<TITLE>Debugging Help</TITLE>
</HEAD>
<BODY>
-<H2>Insight Internal Debugging Functions</H2>
-<H3>Overview</H3>
-<P> This describes the basic internal functions for debugging Insight.
-This information is for Insight developers trying to debug Insight,
-not for users trying to debug other programs.</P>
+<H2>GDBTK Debugging Functions</H2>
+<H4>Overview</H4>
+<P> This describes the basic internal functions for debugging GDBTK.</P>
-<H3>Environment Variables</H3>
-<P><b>GDBTK_DEBUG</b> - Setting this variable controls the Debug
+<H4>Environment Variables</H4>
+<P><BOLD>GDBTK_DEBUG</BOLD> - Setting this variable controls the Debug
window.</P>
-<P><b>GDBTK_DEBUG</b> may have the following values:</P>
+<P><BOLD>GDBTK_DEBUG</BOLD> may have the following values:</P>
<DL>
<DT>0 or unset</DT>
<DD>The Debug window is not opened and not listed on the menu. (You
@@ -24,10 +22,10 @@ may still open it by typing Ctrl-U in the source window.)</DD>
</DL>
<HR>
-<P><b>GDBTK_TRACE</b> - This variable determines if tracing is enabled.
-Tracing may only be enabled at GDBTK startup. Changing <b>GDBTK_TRACE</b>
+<P><BOLD>GDBTK_TRACE</BOLD> - This variable determines if tracing is enbabled.
+Tracing may only be enabled at GDBTK startup. Changing <BOLD>GDBTK_TRACE</BOLD>
while GDBTK is running has no effect.</P>
-<P><b>GDBTK_TRACE</b> may have the following values:</P>
+<P><BOLD>GDBTK_TRACE</BOLD> may have the following values:</P>
<DL>
<DT>0 or unset</DT>
<DD>Tracing is not enabled.</DD>
@@ -36,42 +34,42 @@ while GDBTK is running has no effect.</P>
so in the Debug Window or from the console. (The command to do this is "tk
::debug::trace_start).</DD>
<DT>2</DT>
-<DD>Tracing is enabled and started immediately.</DD>
+<DD>Tracing is enabled and started immediately.</DT>
</DL>
-<P><b>GDBTK_DEBUGFILE</b> - This variable contains an optional filename
+<P><BOLD>GDBTK_DEBUGFILE</BOLD> - This variable contains an optional filename
where GDBTK will write all debugging information. This information will include
the output of all "debug" and "dbug" commands, as well as tracing, if it is
enabled. The value of
-<b>GDBTK_DEBUGFILE</b> will not change what is displayed in the Debug
+<BOLD>GDBTK_DEBUGFILE</BOLD> will not change what is displayed in the Debug
Window, with one exception; when the Debug Window is opened, it will read
-the contents of <b>GDBTK_DEBUGFILE</b> (if it is set and not "stdout").
-<P><b>GDBTK_DEBUGFILE</b> may have the following values:</P>
+the contents of <BOLD>GDBTK_DEBUGFILE</BOLD> (if it is set and not "stdout").
+<P><BOLD>GDBTK_DEBUGFILE</BOLD> may have the following values:</P>
<DL>
<DT>unset</DT>
<DD>No information will be logged.</DD>
-<DT><i>filename</i></DT>
-<DD>Debugging information will be logged to <i>filename</i>.
+<DT><italic>filename</italic></DT>
+<DD>Debugging information will be logged to <italic>filename</italic>.
<DT>"stdout"</DT>
<DD>Debugging information will be written to stdout</DD>
</DL>
<HR>
-<H3>Tcl Debugging Functions</H3>
+<H4>Tcl Debugging Functions</H4>
<P> All debugging functions have been moved into debug.tcl in the ::debug
namespace. "debug" and "dbug" are imported into the global namespace.</P>
<P> The following are the standard debug message functions.</P>
-<pre>
+<code>
# -----------------------------------------------------------------------------
# NAME: debug::debug
#
# SYNOPSIS: debug { {msg ""} }
#
-# DESC: Writes a message to the proper output. The priority of the
+# DESC: Writes a message to the proper output. The priority of the
# message is assumed to be "I" (informational). This function
# is provided for compatibility with the previous debug function.
# For higher priority messages, use dbug.
#
-# ARGS: msg - Message to be displayed.
+# ARGS: msg - Message to be displayed.
# -----------------------------------------------------------------------------
# -----------------------------------------------------------------------------
@@ -89,14 +87,14 @@ namespace. "debug" and "dbug" are imported into the global namespace.</P>
# "E" - Error
# "X" - Fatal Error
# ----------------------------------------------------------------------------
-</pre>
+</code>
<P> These next functions are used to trace variables, which should not be
confused with the functions tracing.<P>
-<pre>
+<code>
# ----------------------------------------------------------------------------
# NAME: debug::trace_var
# SYNOPSIS: debug::trace_var {varName mode}
-# DESC: Sets up variable trace. When the trace is activated,
+# DESC: Sets up variable trace. When the trace is activated,
# debugging messages will be displayed.
# ARGS: varName - the variable name
# mode - one of more of the following letters
@@ -114,10 +112,10 @@ confused with the functions tracing.<P>
# SYNOPSIS: debug::remove_all_traces
# DESC: Removes all traces set up with "trace_var".
# ----------------------------------------------------------------------------
-</pre>
-<P> The following two functions may be used to start and stop tracing
+</code>
+<P> The following two functions may be used to start and stop tracing
programmatically.</P>
-<pre>
+<code>
# -----------------------------------------------------------------------------
# NAME: ::debug::trace_start
# SYNOPSIS: ::debug::trace_start
@@ -128,6 +126,6 @@ programmatically.</P>
# SYNOPSIS: ::debug::trace_stop
# DESC: Stops logging of function trace information.
# -----------------------------------------------------------------------------
-</pre>
+</code>
</BODY>
</HTML>
diff --git a/gdb/gdbtk/library/help/help.html b/gdb/gdbtk/library/help/help.html
index 7cf93c3cedd..3a3640da1a1 100644
--- a/gdb/gdbtk/library/help/help.html
+++ b/gdb/gdbtk/library/help/help.html
@@ -11,16 +11,14 @@ this window.</P>
<P>Help Window topics:
<UL>
- <LI><A HREF="#menus">Menus</A>
- <UL>
- <LI><A HREF="#menus_file">File Menu</A></LI>
- <LI><A HREF="#menus_topics">Topics Menu</A></LI>
- </LI>
- <LI><A HREF="#display">Help Display</A>
- <UL>
- <LI><A HREF="#display_nav">Navigating the Help Window</A></LI>
- <LI><A HREF="#display_link">Definition and Page Links</A></LI>
- </UL></LI>
+ <LI><UL><A HREF="#menus">Menus</A>
+ <LI><A HREF="#menus_file">File Menu</A>
+ <LI><A HREF="#menus_topics">Topics Menu</A>
+ </UL>
+ <LI><UL><A HREF="#display">Help Display</A>
+ <LI><A HREF="#display_nav">Navigating the Help Window</A>
+ <LI><A HREF="#display_link">Definition and Page Links</A>
+ </UL>
</UL></P>
<H2><A NAME="menus">Menus</A></H2>
diff --git a/gdb/gdbtk/library/help/images/index.gif b/gdb/gdbtk/library/help/images/index.gif
new file mode 100644
index 00000000000..34d116b6300
--- /dev/null
+++ b/gdb/gdbtk/library/help/images/index.gif
Binary files differ
diff --git a/gdb/gdbtk/library/help/index.html b/gdb/gdbtk/library/help/index.html
index 9d7177cf259..33571af34ed 100644
--- a/gdb/gdbtk/library/help/index.html
+++ b/gdb/gdbtk/library/help/index.html
@@ -1,35 +1,49 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN">
-<html>
-<head>
- <title>Insight Index</title>
- <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
- <meta name="GENERATOR" content="Quanta Plus">
-</head>
-<body>
-<img src="images/insightbwr.png" width=300 height=120 border=0>
+<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
+<HTML>
+<HEAD>
+ <META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=iso-8859-1">
+ <META NAME="GENERATOR" CONTENT="Mozilla/4.07 [en] (X11; I; Linux 2.0.35 i686) [Netscape]">
+ <TITLE>Help Index</TITLE>
+</HEAD>
+<BODY TEXT="#000000" BGCOLOR="#FFFFFF" LINK="#0000EE" VLINK="#551A8B" ALINK="#FF0000">
+
+<CENTER><IMG SRC="images/index.gif" HEIGHT=123 WIDTH=335></CENTER>
+
<UL>
-<LI><A HREF="breakpoint.html">Breakpoint Window</A></LI>
-<LI><A HREF="console.html">Console Window</A></LI>
-<LI><A HREF="browser.html">Function Browser</A></LI>
-<LI><A HREF="locals.html">Locals Window</A></LI>
-<LI><A HREF="memory.html">Memory Window</A></LI>
-<LI><A HREF="register.html">Register Window</A></LI>
-<LI><A HREF="session.html">Sessions</A></LI>
-<LI><A HREF="source.html">Source Window</A></LI>
-<LI><A HREF="stack.html">Stack Window</A></LI>
-<LI><A HREF="target.html">Target Window</A></LI>
-<LI><A HREF="thread.html">Thread Window</A></LI>
-<LI><A HREF="watch.html">Watch Window</A></LI>
+<LI>
+<A HREF="breakpoint.html">Breakpoint Window</A></LI>
+
+<LI>
+<A HREF="console.html">Console Window</A></LI>
+
+<LI>
+<A HREF="browser.html">Function Browser</A></LI>
+
+<LI>
+<A HREF="locals.html">Locals Window</A></LI>
+
+<LI>
+<A HREF="memory.html">Memory Window</A></LI>
+
+<LI>
+<A HREF="register.html">Register Window</A></LI>
+
+<LI>
+<A HREF="source.html">Source Window</A></LI>
+
+<LI>
+<A HREF="stack.html">Stack Window</A></LI>
+
+<LI>
+<A HREF="target.html">Target Window</A></LI>
+
+<LI>
+<A HREF="thread.html">Thread Window</A></LI>
+
+<LI>
+<A HREF="watch.html">Watch Window</A></LI>
+
</UL>
-<hr>
-<h2>For Developers Only</h2>
-<ul>
-<li><a href="debug.html">"Internal Debugging Functions</a></li>
-</ul>
-<hr>
-<br>
-<a href="http://sources.redhat.com/insight/" name="Insight Home Page">Insight Home Page</a>
-<br><br><hr><br>
<A HREF="license.html">GNU General Public License</A>
-</body>
-</html>
+</BODY>
+</HTML>
diff --git a/gdb/gdbtk/library/help/locals.html b/gdb/gdbtk/library/help/locals.html
index 5612b7de296..058f94fd65f 100644
--- a/gdb/gdbtk/library/help/locals.html
+++ b/gdb/gdbtk/library/help/locals.html
@@ -1,47 +1,90 @@
<HTML>
<HEAD>
-<TITLE>Local Variables Help</TITLE>
+<TITLE>Locals Window Help</TITLE>
</HEAD>
<BODY>
-<H1>The Local Variables Window</H1>
+<H1>The Locals Window</H1>
<H2>Overview</H2>
-<p>The Local Variables Window displays all local variables in scope. It may be used to
-visualize and edit local variables. To open the Local Variables window, click on
-small house icon on the toolbar, or select "Local Variables" under the View
-pulldown menu.</p>
+<P>The Locals Window displays all local variables in scope. It may be used to
+visualize and edit local variables.</P>
-<H3>Locals Display</H3>
+<P>Locals Window topics:
+<UL>
+ <LI><UL><A HREF="#menus">Variable Menu</A>
+ <LI><A HREF="#menus_edit">Edit</A>
+ <LI><A HREF="#menus_fmt">Format</A>
+ </UL>
+ <LI><UL><A HREF="#display">Locals Display</A>
+ <LI><A HREF="#display_deref">Dereferencing Pointers</A>
+ <LI><A HREF="#display_struct">Viewing a Structure or Class</A>
+ <LI><A HREF="#display_edit">Editing a Variable</A>
+ <LI><A HREF="#display_popup">Locals Pop-up Menu</A>
+ </UL>
+</UL></P>
-<p>Pointers, structures, and classes appear in the display with small expansion
-box before their names. To dereference pointers or
-view the members of classes or structures, click
+<H3><A NAME="menus">Variable Menu</A></H3>
+The Variable Menu gives on-screen access to the funtions of the Locals Window.
+To use any of these functions, first use the left mouse button to select a
+variable from the display. Then select:
+
+<DL>
+ <DT><A NAME="menus_edit">Edit</A>
+ <DD>Edit the value of the variable
+ <DT><A NAME="menus_fmt">Format</A>
+ <DD>Change the display format of the variable
+</DL>
+
+<H3><A NAME="display">Locals Display</A></H4>
+The Locals Window Display consists of a scrolled listbox which contains all
+local variables, one per line. To use any of the functions of the Locals Window,
+use the left mouse button to select any element from the Display.
+
+<P>Pointers, structures, and classes appear in the display with small exapansion
+box before their names. To <A NAME="display_deref">dereference pointers</A> or
+<A NAME="display_struct">view the members of classes or structures</A>, click
the closed expansion box (which appears as a small plus sign, "+") to "expand"
the listing. The expansion box changes to a minus sign, "-", indicating that the
display is now open. Pointers, structures and classes may be expanded recursively
-to allow multiple pointer dereferences and embedded structure viewing.</p>
+to allow multiple pointer dereferences and embedded structure viewing.
<P>The Locals Display updates after every execution of the program and highlights
-in green those variables whose values have changed.</P>
+in blue those variables whose values have changed.</P>
<P>The Locals Window will, by default, display all pointers in hexadecimal and all
other variables in decimal. To change the display format for a variable, select
-the Format option from the popup-menu.</P>
+the Format option from either the Variable Menu or the <A HREF="#display_popup">
+Locals Pop-up Menu</A>.
+<BR>
-<H3>Editing a Variable</H3>
-<p>To edit a variable, either double-click the left mouse button on the value of the variable in
-the display or select the Edit option from the pop-up menu. To abort editing a variable's value,
-simply press the escape key on the keyboard. The variable's original value is restored.</p>
+<H4><A NAME="display_edit">Editing a Variable</A></H4>
+To edit a variable, either double-click the left mouse button on the variable in
+the Display or select the Edit option from either the Variable Menu or the Locals
+Pop-up Menu. To abort editing a variable's value, simply press the escape key on
+the keybaord. The variable's original value is restored.
+<BR>
-<H3>Local Variable Pop-up Menu</H3>
-<p>The pop-up menu provides quick access to the functions of the Local Variables Window.
-To use the pop-up menu, click the right mouse button while over a variable.</p>
+<H4><A NAME="display_popup">Locals Pop-up Menu</A></H4>
+The Locals Pop-up Menu provides quick access to the functions of the Locals Window.
+To use the Locals Pop-up Menu, first select a variable from the Display (by clicking
+the left mouse button on it) and click the right mouse button, choosing from the
+pop-up:
<DL>
- <dt>Format<dd>Change the display format of the variable.</dd></dt>
- <dt>Edit<dd>Edit the variable's value.</dd></dt>
- <dt>Delete<dd>Remove the variable from the display.</dd></dt>
- <dt>Dump Memory<dd>Open a Memory Window with the variable's value as an aaddress.</dd></dt>
- <dt>Help<dd>Open this help page.</dd></dt>
- <dt>Close<dd>Close the Local Variables Window.</dd></dt>
+ <DT>Edit
+ <DD>Edit the variable's value. See <A HREF="#display_edit"> Editing a Variable
+ </A>
+ <DT>Format
+ <DD>Change the display format of the variable. The variable may be displayed
+ as:
+ <DL>
+ <DT>Hex
+ <DD>hexadecimal (base 16)
+ <DT>Decimal
+ <DD>decimal (base 10)
+ <DT>Binary
+ <DD>binary (base 2)
+ <DT>Octal
+ <DD>octal (base 8)
+ </DL>
</DL>
</BODY>
</HTML>
diff --git a/gdb/gdbtk/library/help/memory.html b/gdb/gdbtk/library/help/memory.html
index afa2fe8fb47..492974f5478 100644
--- a/gdb/gdbtk/library/help/memory.html
+++ b/gdb/gdbtk/library/help/memory.html
@@ -232,9 +232,7 @@ of bytes. By default, the Memory Window shows 128 bytes of memory.
Miscellaneous memory preferences include the option to display the ASCII
representation of the memory, including what character to use for non-ASCII
bytes (the "control" character). Additionally, users may specify the number
-of bytes per row, either by typing a number into the box or by choosing one
-from the list. The default is sixteen bytes per row. If the entered value is
-not a multiple of the cell size then it will be automatically rounded up. The
-maximum permitted value is 150 (before rounding).
+of bytes per row, either four, eight, sixteen, or thirty-two. The default
+is sixteen bytes per row.
</BODY>
</HTML>
diff --git a/gdb/gdbtk/library/help/reg_pref.html b/gdb/gdbtk/library/help/reg_pref.html
new file mode 100644
index 00000000000..b21a5747df2
--- /dev/null
+++ b/gdb/gdbtk/library/help/reg_pref.html
@@ -0,0 +1,20 @@
+<HTML>
+<HEAD>
+<TITLE>Register Window Preferences Help</TITLE>
+</HEAD>
+<BODY>
+<H1>Register Window Preferences</H1>
+<H3>Overview</H3>
+<P>Not yet done.</P>
+
+<P>Register Window Preferences topics:
+<UL>
+ <LI><UL><A HREF="#">stuff</A>
+ <LI><A HREF="#">stuff</A>
+ <LI><A HREF="#">stuff</A>
+ </UL>
+</UL></P>
+
+<H3><A NAME="">stuff</A></H3>
+</BODY>
+</HTML>
diff --git a/gdb/gdbtk/library/help/register.html b/gdb/gdbtk/library/help/register.html
index 06513445eee..b8fff0ec187 100644
--- a/gdb/gdbtk/library/help/register.html
+++ b/gdb/gdbtk/library/help/register.html
@@ -4,45 +4,111 @@
</HEAD>
<BODY>
<H1>The Register Window</H1>
-<P>The Register Window lists registers and their contents for
+<H2>Overview</H2>
+<P>The Register Window lists all the registers and their contents for
the selected stack frame. It permits viewing the contents of registers
in different formats, editing register values, and some display
customizations.</P>
-<img src="images/reg.png" alt="register window" width=387 height=370 align="middle" border=0>
-
-<p>In the image above, you can see all the registers on the left and their values on the right.
-At the top is an option menu to allow you to choose what group of registers to display.
-The groups names are preset according to the architecture being debugged. The default is "all".
-Registers highlighted in green have recently changed.
-</p>
<P>The Register Window will update the register contents in the display
to match the stack frame currently being viewed in the <A HREF="source.html">
-Source Window</A> and <A HREF="stack.html">Stack Window</A>.</P>
-<p>Each time the program stops, the register window will automatically update.
-Registers that have changed since the last stop will be displayed in green.</p>
+Source Window</A> and <A HREF="stack.html">Stack Winodw</A>.</P>
+
+<P>Register Window topics:
+<UL>
+ <LI><UL><A HREF="#menus">Register Menu</A>
+ <LI><A HREF="#menus_edit">Edit</A>
+ <LI><A HREF="#menus_fmt">Format</A>
+ <LI><A HREF="#menus_remove">Remove from Display</A>
+ <LI><A HREF="#menus_all">Display All Registers</A>
+ </UL>
+ <LI><UL><A HREF="#display">Register Display</A>
+ <LI><A HREF="#display_nav">Navigating the Register Display</A>
+ <LI><A HREF="#display_popup">Register Pop-up Menu</A>
+ <LI><A HREF="#display_edit">Editing a Register</A>
+ <LI><A HREF="#display_format">Changing the Display Format of
+ a Register</A>
+ <LI><A HREF="#display_remove">Removing a Register
+ from the display</A>
+ <LI><A HREF="#display_all">Displaying all Registers</A>
+ </UL>
+</UL></P>
+<H3><A NAME="menus">Register Menu</A></H3>
+The Register Menu provides on-screen access to the functionality of the
+Register Window. To use any item from this menu, first use the mouse and
+select (click the left mouse button) on any register cell. Users may then
+select:
+<BR>
+<DL>
+ <DT><A NAME="menus_edit"><A HREF="#display_edit">Edit</A></A>
+ <DD>Edit the contents of the selected register
+ <DT><A NAME="menus_fmt"><A HREF="#display_format">Format</A></A>
+ <DD>Change the display format of the selected register
+ <DT><A NAME="menus_remove"><A HREF="#display_remove">Remove
+ from Display</A></A>
+ <DD>Remove the selected register from the Register
+ Window Display
+ <DT><A NAME="menus_all"><A HREF="#display_all">Display All
+ Registers</A></A>
+ <DD>Display all registers in the Display. This item
+ is only available when a register was previously
+ removed from the Display.
+</DL>
+<H3><A NAME="display">Register Display</A></H3>
+The Register Display contains name and value pairs for each register
+available on the target hardware. These "cells" are layed out as a
+spreadsheet for ease of use.
-<H3>The Register Pop-up Menu</H3>
-<img src="images/reg_menu.png" alt="register popup menu" width=396 height=388 border=0>
-<P>
-To activate the pop-up menu, click the right mouse button over a register.
-This will allow you change the way the register is displayed, or to remove
-it from the display. Or you can add the register to the watch window.
-For integer registers, you can also open a memory window at the
-location pointed to by the register.</P>
+<P><A NAME="display_nav"></A>To navigate the Register Display, use either
+the mouse and left mouse button or the arrow keys on the keyboard to
+highlight the appropriate cell. Users may then use the <A HREF="#menus">
+Register Menu</A> or use the Register Pop-up Menu to access special display
+and editing options for the Register Window.</P>
+<BR>
-<H3>Editing a Register</H3>
-<P>
-To edit a register, simply click on it with the left mouse button. Type
-in the new value and hit enter. You can enter a decimal, hex, or float number and
-the type will be converted if possible. You may also enter an expression to be evaluated.
-For example, to set $r3 to the same as $r4, edit $r3 and enter "$r4" as the value. In the same
-way, you can set $pc to "main".
-The value of the register is set to the current value of the expression; it will not be reevaluated
-if the expression's value later changes.
-</P>
-<P>Press the escape key on the keyboard to cancel your edit.</P>
+<H4><A NAME="display_popup">The Register Pop-up Menu</A></H4>
+All of the special functions of the register window are accessed through
+the Register Pop-up Menu. To use the Menu, simply select a register (see
+<A HREF="#display_nav">Navigating the Register Display</A>) and click the
+right mouse button. The Menu offers:
+<DL>
+ <DT><A NAME="display_edit">Edit</A>
+ <DD>Edit the contents of the selected register. This item
+ is also accessible by simply double-clicking the left
+ mouse button on any register in the Display. The value
+ of the register is set to the entered value -- the debugger
+ does diffferentiate between decimal, hexadecimal, octal,
+ and binary input. Press the escape key on the keyboard
+ to cancel.
+ <DT><A NAME="display_format">Format</A>
+ <DD><DL>Change the display format of the register. Valid display types
+ are:
+ <DT>Hex
+ <DD>The register's contents are displayed in
+ hexadecimal (base 16).
+ <DT>Decimal
+ <DD>The value is shown as
+ a decimal number (base 10).
+ <DT>Natural
+ <DD>The register is displayed in its natural format.
+ <DT>Binary
+ <DD>The contents of the register are displayed
+ as a binary number (base 2).
+ <DT>Octal
+ <DD>The register's contents are shown in octal (base 8).
+ <DT>Raw
+ <DD>The raw contents of the register are shown.
+ </DL>
+ <DT><A NAME="display_remove">Remove</A>
+ <DD>Remove the selected register from the display. To display
+ the removed register again, select the "Display All Registers"
+ option from the Register Menu or the Register Pop-up Menu.
+ <DT><A NAME="display_all">Display All Registers</A>
+ <DD>Causes the Register Window Display to show all registers,
+ including those which were previously "removed". This menu
+ item is only available when removed registers exist.
+</DL>
</BODY>
</HTML>
diff --git a/gdb/gdbtk/library/help/source.html b/gdb/gdbtk/library/help/source.html
index 0e04eac6579..c37091a9460 100644
--- a/gdb/gdbtk/library/help/source.html
+++ b/gdb/gdbtk/library/help/source.html
@@ -60,32 +60,24 @@ the program, and allows visualization of the program execution.
<DL>
<DT>Open</DT>
<DD>Opens a file selection dialog to select the executable to debug</DD>
-<DT>Close</DT>
-<DD>Closes a previously opened executable file</DD>
-<DT>Source</DT>
-<DD>Reads and executes GDB commands from a text file</DD>
<DT>Target Settings...</DT>
<DD>Opens the <A HREF="target.html">Target Selection Dialog</A> to edit target
settings</DD>
<DT>Page Setup</DT>
<DD>(Windows only) Opens the Windows Page Setup dialog to configure printing</DD>
<DT>Print</DT>
-<DD>Print the contents of the Source Window Display</DD>
+<DD>(Windows only) Print the contents of the Source Window Display</DD>
<DT>Exit</DT>
<DD>Exits the debugger</DD>
</DL>
<H4><A NAME="menus_run"></A>Run Menu</H4>
<DL>
-<DT>Connect to target</DT>
-<DD>Connect to the target specified in the <A HREF="target.html">Target Selection Dialog</A>. Open the dialog if there are no current settings.</DD>
<DT>Download</DT>
<DD>Initiates download of the executable onto the target via the protocol specified
in the <A HREF="target.html">Target Selection Dialog</A></DD>
<DT>Run</DT>
<DD>Runs or re-runs the program</DD>
-<DT>Disconnect</DT>
-<DD>Close a previously opened connection</DD>
</DL>
<H4><A NAME="menus_view"></A>View Menu</H4>
diff --git a/gdb/gdbtk/library/help/target.html b/gdb/gdbtk/library/help/target.html
index b56821b0cff..2f81fb6720e 100644
--- a/gdb/gdbtk/library/help/target.html
+++ b/gdb/gdbtk/library/help/target.html
@@ -4,39 +4,33 @@
</HEAD>
<BODY>
<H1>The Target Selection Dialog</H1>
-<h2>Overview</h2>
+<H3>Overview</H3>
<P>The Target Selection Dialog allows users to specify the debug target,
the interface used to connect to the target, and some useful run
options.</P>
-<P>
-<h3><A HREF="#select">Selecting a Target</A></h3>
+<P>Target Selection topics:
<UL>
-<LI><A HREF="#select">Specifying a Target</A></LI>
-<LI><A HREF="#select_int">Choosing a Connection Interface</A></LI>
-</UL>
-
-<h3><A HREF="#options">Options</A></h3>
-<UL>
-<LI><A HREF="#options_run_until_main">Run until 'main'</A></LI>
-<LI><A HREF="#options_bp_at_exit">Set breakpoint at 'exit'</A></LI>
-<LI><A HREF="#options_set_bp_at">Set user-specifid breakpoint</A></LI>
-<LI><A HREF="#options_download_dialog">Display Download Dialog</A></LI>
-<LI><A HREF="#options_use_xterm">Use xterm for inferior's tty (unix only)
- </A></LI>
-</UL>
-
-<h3><A HREF="#more_options">More Options</A></h3>
-<UL>
-<LI><A HREF="#more_options_attach">Attach to Target</A></LI>
-<LI><A HREF="#more_options_load">Download Program</A></LI>
-<LI><A HREF="#more_options_run">Run Program</A></LI>
-<LI><A HREF="#more_options_cont">Continue from Last Stop</A></LI>
+ <LI><UL><A HREF="#select">Selecting a Target</A>
+ <LI><A HREF="#select_tar">Specifying a Target</A>
+ <LI><A HREF="#select_int">Choosing a Connection Interface</A>
+ </UL>
+ <LI><UL><A HREF="#options">Options</A>
+ <LI><A HREF="#options_run_until_main">Run until 'main'</A>
+ <LI><A HREF="#options_bp_at_exit">Set breakpoint at 'exit'</A>
+ <LI><A HREF="#options_download_dialog">Display Download Dialog</A>
+ </UL>
+ <LI><UL><A HREF="#more_options">More Options</A>
+ <LI><A HREF="#more_options_attach">Attach to Target</A>
+ <LI><A HREF="#more_options_load">Download Program</A>
+ <LI><A HREF="#more_options_run">Run Program</A>
+ <LI><A HREF="#more_options_cont">Continue from Last Stop</A>
+ </UL>
</UL></P>
<H3><A NAME="select">Selecting a Target</A></H3>
Selecting a target involves choosing a target for debugging and setting connection
-interface options for the target.
+interface options for the target.
<P>Common targets include: "Exec" for native debuggers, "Remote/Serial" for establishing
a connection to a target board via a serial line, "Remote/TCP" for TCP connections,
@@ -50,7 +44,7 @@ and port number of the machine to which to connect. Depending upon configuration
there may be numerous serial- and TCP-based connections. These always follow the
naming convention <I>target</I>/Serial and <I>target</I>/TCP.</P>
-<P>To select a target, choose one of the available targets
+<P>To <A NAME="select_tar"> select a target</A>, choose one of the available targets
from the dropdown menu in the Connection Frame. Then <A NAME="#select_int">specify
the interface options</A> for this target: selecting the baudrate and serial port
from the dropdown menus (serial targets only) or entering the hostname and port number
@@ -59,18 +53,13 @@ from the dropdown menus (serial targets only) or entering the hostname and port
<H3><A NAME="options">Options</A></H3>
Three run options which may be selected include:
<DL>
- <DT><A NAME="options_run_until_main">Run until 'main'</A>
+ <DT><A NAME="options_run_until_main">Run until 'main'
<DD>Sets a breakpoint at main()
- <DT><A NAME="options_bp_at_exit">Set breakpoint at 'exit'</A>
+ <DT><A NAME="options_bp_at_exit">Set breakpoint at 'exit'
<DD>Sets a breakpoint at exit()
- <DT><A NAME="options_set_bp_at">Set breakpoint at</A>
- <DD>Sets a breakpoint at a user-specified locaiton</A>
- <DT><A NAME="options_download_dialog">Display Download Dialog</A>
+ <DT><A NAME="options_download_dialog">Display Download Dialog
<DD>Displays a dialog showing the progress of the download to
the target section by section
- <DT><A NAME="options_use_xterm">Use xterm as inferior's tty</A>
- <DD>Causes insight to open a tty for inferior I/O (unix versions
- only)
</DL>
<BR>
<H3><A NAME="more_options">More Options</A></H3>
@@ -78,7 +67,7 @@ Several additional run options may be set for each target from the Target Select
Dialog. These options govern the behavior of the debugger's
<A NAME="source.html#run_button">Run Button</A>. The debugger automatically selects
default values for these options whenever a target is selected with the dropdown menu
-in the Connection Frame. To modify this default behavior, click the small triangle
+in the Connection Frame. To modify this default bahavior, click the small triangle
next to "More Options" at the bottom of the dialog. The Run Options for the current
target are displayed, allowing modification of the actions for the target. When the
"OK" button is selected, these settings are saved and will be used as the default
diff --git a/gdb/gdbtk/library/help/trace/locals.html b/gdb/gdbtk/library/help/trace/locals.html
index 05998244d96..d0b1d2940e0 100644
--- a/gdb/gdbtk/library/help/trace/locals.html
+++ b/gdb/gdbtk/library/help/trace/locals.html
@@ -54,8 +54,8 @@ in blue those variables whose values have changed.</P>
other variables in decimal. To change the default display of variables, use the
"set output-radix" command in the console window. (Type "help set output-radix" in the
console window for help. To make this change permanent, it must be added to the user's
-init file -- .gdbinit.) To change the display format for a variable,
-select the Format option from either the Variable Menu or the
+init file -- .gdbinit under unix and gdb.ini under Windows.) To change the display
+format for a variable, select the Format option from either the Variable Menu or the
<A HREF="#display_popup">Locals Pop-up Menu</A>.
<BR>
diff --git a/gdb/gdbtk/library/help/trace/watch.html b/gdb/gdbtk/library/help/trace/watch.html
index d980327ed74..373ad183a96 100644
--- a/gdb/gdbtk/library/help/trace/watch.html
+++ b/gdb/gdbtk/library/help/trace/watch.html
@@ -89,7 +89,7 @@ in blue those variables whose values have changed.</P>
other variables in decimal. To change the default display of variables, use the
"set output-radix" command in the console window. (Type "help set output-radix" in the
console window for help. To make this change permanent, it must be added to the user's
-init file -- .gdbinit.) To change the display
+init file -- .gdbinit under unix and gdb.ini under Windows.) To change the display
format for a variable, select the Format option from either the Variable Menu or the
<A HREF="#display_popup">Watch Pop-up Menu</A>.
<BR>
diff --git a/gdb/gdbtk/library/help/watch.html b/gdb/gdbtk/library/help/watch.html
index 01e253b1883..51734404534 100644
--- a/gdb/gdbtk/library/help/watch.html
+++ b/gdb/gdbtk/library/help/watch.html
@@ -4,25 +4,53 @@
</HEAD>
<BODY>
<H1>The Watch Window</H1>
-<img src="images/watch.png" alt="Watch Window Image" width=545 height=308 border=0>
-<H2>Overview</H2>
-
+<H3>Overview</H3>
<P>The Watch Window may be used to inspect and edit any expression, including
global variables, static variables, local variables, function arguments,
-and registers. All expressions in scope are displayed with the expression in
-blue, the expression type in red, and the expression value in black. When an
-expression value changes, it is displayed in green. Expressions that are not
-in scope are all gray.</P>
+and registers.</P>
+
+<P>Watch Window topics:
+<UL>
+ <LI><UL><A HREF="#menus">Watch Menu</A>
+ <LI><A HREF="#menus_edit">Edit</A>
+ <LI><A HREF="#menus_fmt">Format</A>
+ <LI><A HREF="#menus_remove">Remove</A>
+ </UL>
+ <LI><UL><A HREF="#new">Adding Watch Expressions</A>
+ <LI><A HREF="#new_ent">In the Watch Window</A>
+ <LI><A HREF="#new_src">In the Source Window</A>
+ <LI><A HREF="#new_cast">Casting Pointers</A>
+ </UL>
+ <LI><UL><A HREF="#display">Watch Display</A>
+ <LI><A HREF="#display_deref">Dereferencing Pointers</A>
+ <LI><A HREF="#display_struct">Viewing a Structure or Class</A>
+ <LI><A HREF="#display_edit">Editing an Expression</A>
+ <LI><A HREF="#display_popup">Watch Pop-up Menu</A>
+ </UL>
+</UL></P>
+
+<H3><A NAME="menus">Watch Menu</A></H3>
+The Watch Menu gives on-screen access to the funtions of the Watch Window.
+To use any of these functions, first use the left mouse button to select an
+expression from the display. Then select:
+<DL>
+ <DT><A NAME="menus_edit">Edit</A>
+ <DD>Edit the value of the expression
+ <DT><A NAME="menus_fmt">Format</A>
+ <DD>Change the display format of the expression
+ <DT><A NAME="menus_remove">Remove</A>
+ <DD>Remove the expression from the Watch Window
+</DL>
-<H3>Adding Watch Expressions</H3>
-<p>To add an expression to the Watch Window, simply enter
+<H3><A NAME="new">Adding Watch Expressions</A></H3>
+<A NAME="new_ent">To add an expression to the Watch Window</A>, simply enter
the expression into the entry at the bottom of the window and press return
or click the "Add Watch" button. The expression is validated and added to the
-Watch Window Display.</p>
+Watch Window Display.
-<P>To add an expression to the Watch Window from the
-<A HREF="source.html">Source Window</A>, use the
+<P><A NAME="new_src">To add an expression to the Watch Window from the
+<A HREF="source.html">Source Window</A></A>, use the
"<A HREF="source.html#add_to_watch">Add to Watch</A>" option of the
<A HREF="source.html#display_popup">Source Window Pop-up Menu</A>.</P>
@@ -37,50 +65,65 @@ enter the name of the register preceded with a dollar sign ($) into the
Entry. For example, to watch the PC register, enter "<CODE>$pc</CODE>" into
the Watch Window Entry. The program counter is added to the Display.</P>
-<P>To cast pointers, simply enter the cast into the
+<P><A NAME="new_cast">To cast pointers</A>, simply enter the cast into the
Watch Window Entry at the bottom of the window. Use the same syntax for the
cast that the source file uses. If the source file uses C, the a simple
cast of "<CODE>ptr</CODE>" of type "<CODE>void *</CODE>" can be cast to type
"<CODE>my_struct</CODE>" by entering "<CODE>(my_struct *) ptr</CODE>" into
the Entry.</P>
-<H3>Watch Display</H3>
-<p>The Watch Window Display consists of a scrolled listbox which contains all
+<H3><A NAME="display">Watch Display</A></H3>
+The Watch Window Display consists of a scrolled listbox which contains all
watch expressions, one per line. To use any of the functions of the Watch
-Window, use the left mouse button to select any element from the Display.</p>
+Window, use the left mouse button to select any element from the Display.
<P>Pointers, structures, and classes appear in the display with a small
-exapansion box before their names. To dereference
-pointers or view the members of classes or
-structures, click the closed expansion box (which appears as a small
+exapansion box before their names. To <A NAME="display_deref">dereference
+pointers</A> or <A NAME="display_struct">view the members of classes or
+structures</A>, click the closed expansion box (which appears as a small
plus sign, "+") to "expand" the listing. The expansion box changes to a
minus sign, "-", indicating that the display is now open. Pointers,
structures and classes may be expanded recursively to allow multiple pointer
-derefernces and embedded structure viewing.</P>
+derefernces and embedded structure viewing.
<P>The Watch Display updates after every execution of the program and
-highlights in green those expressions whose values have changed.</P>
+highlights in blue those expressions whose values have changed.</P>
<P>The Watch Window will, by default, display all pointers and registers in
hexadecimal and all other expressions in decimal. To change the display
-format for an expression, select the Format option from the pop-up menu.</P>
+format for an expression, select the Format option from either the Watch Menu
+or the <A HREF="#display_popup">Watch Pop-up Menu</A>.
+<BR>
-<H3>Editing an Expression</H3>
-<p>To edit an expression, either double-click the left mouse button on the expression
-in the Display or select the Edit option from the popup-menu. To abort editing
-an expression's value, simply press
-the escape key on the keyboard. The expression's original value is restored.</p>
+<H4><A NAME="display_edit">Editing an Expression</A></H4>
+To edit an expression, either double-click the left mouse button on the expression
+in the Display or select the Edit option from either the Watch Menu or
+the Watch Pop-up Menu. To abort editing an expression's value, simply press
+the escape key on the keybaord. The expression's original value is restored.
+<BR>
-<H3>Watch Pop-up Menu</H3>
-<p>The pop-up menu provides quick access to the functions of the Watch Window.
-To use the pop-up menu, click the right mouse button while over a variable.</p>
+<H4><A NAME="display_popup">Watch Pop-up Menu</A></H4>
+The Watch Pop-up Menu provides quick access to the functions of the Watch Window.
+To use the Locals Pop-up Menu, first select an expression from the Display (by
+clicking the left mouse button on it) and click the right mouse button, choosing
+from the pop-up:
<DL>
- <dt>Format<dd>Change the display format of the variable.</dd></dt>
- <dt>Edit<dd>Edit the variable's value.</dd></dt>
- <dt>Delete<dd>Remove the variable from the display.</dd></dt>
- <dt>Dump Memory<dd>Open a Memory Window with the variable's value as an aaddress.</dd></dt>
- <dt>Help<dd>Open this help page.</dd></dt>
- <dt>Close<dd>Close the Local Variables Window.</dd></dt>
+ <DT>Edit
+ <DD>Edit the expression's value. See <A HREF="#display_edit">
+ Editing an Expression</A>
+ <DT>Format
+ <DD>Change the display format of the expression. The expression may be
+ displayed as:
+ <DL>
+ <DT>Hex
+ <DD>hexadecimal (base 16)
+ <DT>Decimal
+ <DD>decimal (base 10)
+ <DT>Binary
+ <DD>binary (base 2)
+ <DT>Octal
+ <DD>octal (base 8)
+ </DL>
</DL>
</BODY>
</HTML>
diff --git a/gdb/gdbtk/library/helpviewer.itb b/gdb/gdbtk/library/helpviewer.itb
new file mode 100644
index 00000000000..a366b689979
--- /dev/null
+++ b/gdb/gdbtk/library/helpviewer.itb
@@ -0,0 +1,286 @@
+# Viewer for HTML help info
+# Copyright 1998, 1999 Cygnus Solutions
+#
+# This program is free software; you can redistribute it and/or modify it
+# under the terms of the GNU General Public License (GPL) as published by
+# the Free Software Foundation; either version 2 of the License, or (at
+# your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+
+
+# -----------------------------------------------------------------------------
+# NAME:
+# HtmlViewer::constructor
+#
+# SYNOPSIS:
+# constructor args
+#
+# DESC:
+# Creates the Help Viewer window.
+# -----------------------------------------------------------------------------
+body HtmlViewer::constructor {args} {
+ window_name "Help"
+ eval itk_initialize $args
+ _buildwin
+}
+
+
+# -----------------------------------------------------------------------------
+# NAME:
+# private method HtmlViewer::_buildwin
+#
+# SYNOPSIS:
+# _buildwin args
+#
+# DESC:
+# This function is called by the constructor to build the widget. It
+# creates pulldown menus, buttons, a stack, and a scrolledhtml widget.
+# Finally it loads help/index.html. This last step should change if
+# this widget is ever used for anything but help.
+# -----------------------------------------------------------------------------
+body HtmlViewer::_buildwin {} {
+ global GDBTK_LIBRARY gdb_ImageDir
+
+ set _links [PageStack \#auto]
+
+ # create pulldown menu
+ set menu [menu $itk_interior.m -tearoff 0]
+ $menu add cascade -menu $menu.file -label "File" -underline 0
+ set _m [menu $menu.file]
+ $_m add command -label "Back" -underline 0 -command "$this back"
+ $_m add command -label "Forward" -underline 0 -command "$this forward"
+ $_m add command -label "Home" -underline 0 -command "$this link $file"
+ $_m add separator
+ $_m add command -label "Close" -underline 0 -command "delete object $this"
+ $menu add cascade -menu $menu.topic -label "Topics" -underline 0
+ set _t [menu $menu.topic]
+ foreach t $topics {
+ $_t add command -label [lindex $t 0] -command "$this link [lindex $t 1]"
+ }
+ [winfo toplevel $itk_interior] configure -menu $menu
+
+ # create buttons
+ set _f [frame $itk_interior.b]
+ button $_f.back -command "$this back" \
+ -image [image create photo -file [file join $gdb_ImageDir back.gif]]
+ button $_f.fore -command "$this forward" \
+ -image [image create photo -file [file join $gdb_ImageDir fore.gif]]
+ button $_f.home -command "$this link $file" \
+ -image [image create photo -file [file join $gdb_ImageDir home.gif]]
+ standard_toolbar $_f $_f.back $_f.fore $_f.home
+
+ _enable 0 back fore
+
+ # create html widget
+ set _html [iwidgets::scrolledhtml $itk_interior.a -linkcommand "$this link"]
+
+ # get things going by loading index.html
+ $_html import [file join $GDBTK_LIBRARY help $file]
+ $_links push $file
+
+ pack $_f -side top -fill x
+ pack $_html -expand yes -fill both
+
+}
+
+# -----------------------------------------------------------------------------
+# NAME: public method PageStack::push
+# SYNOPSIS: push val
+# DESC: Pushes a value onto the stack.
+# -----------------------------------------------------------------------------
+body PageStack::push {val} {
+ incr _ptr
+ incr _max
+ if {$_ptr < $_max} {
+ set _max $_ptr
+ }
+ set _stack($_ptr) $val
+}
+
+# -----------------------------------------------------------------------------
+# NAME: public method PageStack::back
+# SYNOPSIS: back
+# DESC: Moves the stack pointer back by one.
+# RETURNS: Returns the value on the stack, or 0 on error.
+# -----------------------------------------------------------------------------
+body PageStack::back {} {
+ if {$_ptr > 0} {
+ incr _ptr -1
+ return $_stack($_ptr)
+ }
+ return 0
+}
+
+# -----------------------------------------------------------------------------
+# NAME: public method PageStack::next
+# SYNOPSIS: next
+# DESC: Moves the stack pointer forward by one.
+# RETURNS: Returns the value on the stack, or 0 on error.
+# -----------------------------------------------------------------------------
+body PageStack::next {} {
+ if {$_ptr < $_max} {
+ incr _ptr
+ return $_stack($_ptr)
+ }
+ return 0
+}
+
+# -----------------------------------------------------------------------------
+# NAME: public method PageStack:more
+# SYNOPSIS: more
+# DESC: Indicates if the stack pointer is not at the top.
+# RETURNS: Returns 1 if PageStack::next will suceed, 0 otherwise.
+# -----------------------------------------------------------------------------
+body PageStack::more {} {
+ if {$_ptr < $_max} {
+ return 1
+ }
+ return 0
+}
+
+# -----------------------------------------------------------------------------
+# NAME: public method PageStack:less
+# SYNOPSIS: less
+# DESC: Indicates if the stack pointer is not at the bottom of stack.
+# RETURNS: Returns 1 if PageStack::back will suceed, 0 otherwise.
+# -----------------------------------------------------------------------------
+body PageStack::less {} {
+ if {$_ptr > 0} {
+ return 1
+ }
+ return 0
+}
+
+# -----------------------------------------------------------------------------
+# NAME: public method PageStack:current
+# SYNOPSIS: current
+# RETURNS: Returns the current value on the stack.
+# -----------------------------------------------------------------------------
+body PageStack::current {} {
+ if {$_ptr > 0} {
+ return $_stack($_ptr)
+ }
+ return 0
+}
+
+# ------------------------------------------------------------------------------
+# NAME:
+# private method HtmlViewer::_enable
+#
+# SYNOPSIS:
+# _enable { on args }
+#
+# DESC:
+# Enables or disables buttons and menus.
+#
+# ARGS:
+# on - "1" to enable, "0" to disable
+# args - things to enable/disable. May include "back",
+# "fore", and "home"
+#
+# ------------------------------------------------------------------------------
+body HtmlViewer::_enable { on args } {
+ if {$on} {
+ set state normal
+ } else {
+ set state disabled
+ }
+
+ foreach a $args {
+ switch $a {
+ back {
+ # set state of "back"
+ $_m entryconfigure 0 -state $state
+ $_f.back configure -state $state
+ }
+ fore {
+ # set state of "forward"
+ $_m entryconfigure 1 -state $state
+ $_f.fore configure -state $state
+ }
+ home {
+ # set state of "home"
+ $_m entryconfigure 2 -state $state
+ $_f.home configure -state $state
+ }
+ }
+ }
+}
+
+# ------------------------------------------------------------------------------
+# NAME: public method HtmlViewer::back
+# SYNOPSIS: back
+# DESC: Moves to the previous page
+# ------------------------------------------------------------------------------
+body HtmlViewer::back {} {
+ set res [$_links back]
+ if {$res != 0} {
+ load $res
+ if {![$_links less]} {
+ _enable 0 back
+ }
+ }
+}
+
+# ------------------------------------------------------------------------------
+# NAME: public method HtmlViewer::forward
+# SYNOPSIS: forward
+# DESC: Moves to the next page
+# ------------------------------------------------------------------------------
+body HtmlViewer::forward {} {
+ set res [$_links next]
+ if {$res != 0} {
+ load $res
+ if {![$_links more]} {
+ _enable 0 fore
+ }
+ }
+}
+
+# ------------------------------------------------------------------------------
+# NAME: public method HtmlViewer::link
+# SYNOPSIS: link page
+# ARDS: page - link to the page to load
+# DESC: Saves the page on the stack and calls the "load" method
+# ------------------------------------------------------------------------------
+body HtmlViewer::link {page} {
+ if {$page != [$_links current]} {
+ $_links push $page
+ load $page
+ if {![$_links more]} {
+ _enable 0 fore
+ }
+ }
+}
+
+# ------------------------------------------------------------------------------
+# NAME: private method HtmlViewer::load
+# SYNOPSIS: load link
+# DESC: Disables menus and buttons, sets cursor, loads a page into
+# the html widget, then resets cursor and enables the menus
+# and buttons
+# ------------------------------------------------------------------------------
+body HtmlViewer::load {link} {
+ _enable 0 back fore home
+ $itk_interior configure -cursor watch
+ $_html import -link $link
+ $itk_interior configure -cursor ""
+ _enable 1 back fore home
+}
+
+# ------------------------------------------------------------------------------
+# NAME: public proc HtmlViewer::open_help
+# SYNOPSIS: HtmlViewer::open_help file
+# DESC: If the prefs are set to use a browser, attempts
+# to do so. Otherwise, uses builtin HtmlViewer class.
+# ------------------------------------------------------------------------------
+body HtmlViewer::open_help {hfile} {
+ set link file://[file join $::GDBTK_LIBRARY help $hfile]
+ if {![pref get gdb/help/browser] || ![::open_url $link]} {
+ ManagedWin::open HtmlViewer -file $hfile
+ }
+}
diff --git a/gdb/gdbtk/library/helpviewer.ith b/gdb/gdbtk/library/helpviewer.ith
new file mode 100644
index 00000000000..1959a718227
--- /dev/null
+++ b/gdb/gdbtk/library/helpviewer.ith
@@ -0,0 +1,97 @@
+# HtmlViewer class definition
+# Copyright 1998, 1999 Cygnus Solutions
+#
+# This program is free software; you can redistribute it and/or modify it
+# under the terms of the GNU General Public License (GPL) as published by
+# the Free Software Foundation; either version 2 of the License, or (at
+# your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+
+
+# -----------------------------------------------------------------------------
+# NAME:
+# class HtmlViewer
+#
+# DESC:
+# This class implements a simple HTML browser. It has both pulldown
+# menus and buttons for navigating. It uses the scrolledhtml iwidget
+# to do its rendering.
+#
+# NOTES:
+# Currently used as a help window.
+#
+# -----------------------------------------------------------------------------
+class HtmlViewer {
+ inherit EmbeddedWin
+
+ public {
+ variable topics {
+ {index index.html}
+ {"Attach Dialog" attach.html}
+ {"Breakpoint Window" breakpoint.html}
+ {"Console Window" console.html }
+ {"Function Browser" browser.html }
+ {"Locals Window" locals.html }
+ {"Memory Window" memory.html}
+ {"Register Window" register.html}
+ {"Source Window" source.html}
+ {"Stack Window" stack.html}
+ {"Target Window" target.html }
+ {"Thread Window" thread.html }
+ {"Watch Window" watch.html}
+ }
+ variable file "index.html"
+ method back {}
+ method forward {}
+ method link {link}
+ method load {link}
+ method close {}
+ method constructor {args}
+ proc open_help {file}
+ }
+
+ private {
+ variable _html
+ variable _links
+ variable _m
+ variable _f
+
+ method _enable {on args}
+ method _buildwin {}
+ }
+
+}
+
+# -----------------------------------------------------------------------------
+# NAME:
+# class PageStack
+#
+# DESC:
+# Implements a stack-like class for saving and recalling items
+# like pages in a help browser. It differs from a traditional
+# stack only by the 'back' and 'next' methods which move up and
+# down the stack without disturbing it, unlike 'push' and 'pop'.
+#
+# NOTES:
+# Currently used by the HtmlViewer class.
+#
+# -----------------------------------------------------------------------------
+class PageStack {
+ private {
+ variable _ptr -1
+ variable _max -1
+ variable _stack
+ }
+ public {
+ method push {val}
+ method back {}
+ method next {}
+ method more {}
+ method less {}
+ method current {}
+ }
+}
diff --git a/gdb/gdbtk/library/images/back.gif b/gdb/gdbtk/library/images/back.gif
new file mode 100644
index 00000000000..94602b4ac78
--- /dev/null
+++ b/gdb/gdbtk/library/images/back.gif
Binary files differ
diff --git a/gdb/gdbtk/library/images/build.gif b/gdb/gdbtk/library/images/build.gif
new file mode 100644
index 00000000000..de301b272c1
--- /dev/null
+++ b/gdb/gdbtk/library/images/build.gif
Binary files differ
diff --git a/gdb/gdbtk/library/images/cygnus.gif b/gdb/gdbtk/library/images/cygnus.gif
new file mode 100644
index 00000000000..292fecc627f
--- /dev/null
+++ b/gdb/gdbtk/library/images/cygnus.gif
Binary files differ
diff --git a/gdb/gdbtk/library/images/file.gif b/gdb/gdbtk/library/images/file.gif
new file mode 100644
index 00000000000..5e667f32133
--- /dev/null
+++ b/gdb/gdbtk/library/images/file.gif
Binary files differ
diff --git a/gdb/gdbtk/library/images/fore.gif b/gdb/gdbtk/library/images/fore.gif
new file mode 100644
index 00000000000..2eb9f76107d
--- /dev/null
+++ b/gdb/gdbtk/library/images/fore.gif
Binary files differ
diff --git a/gdb/gdbtk/library/images/gdbtk.gif b/gdb/gdbtk/library/images/gdbtk.gif
new file mode 100644
index 00000000000..83c4cc155d9
--- /dev/null
+++ b/gdb/gdbtk/library/images/gdbtk.gif
Binary files differ
diff --git a/gdb/gdbtk/library/images/insight.gif b/gdb/gdbtk/library/images/insight.gif
index fa5cfe19617..c3d93dcdef8 100644
--- a/gdb/gdbtk/library/images/insight.gif
+++ b/gdb/gdbtk/library/images/insight.gif
Binary files differ
diff --git a/gdb/gdbtk/library/images/opt.gif b/gdb/gdbtk/library/images/opt.gif
new file mode 100644
index 00000000000..c5ad520f27e
--- /dev/null
+++ b/gdb/gdbtk/library/images/opt.gif
Binary files differ
diff --git a/gdb/gdbtk/library/images/tools.gif b/gdb/gdbtk/library/images/tools.gif
new file mode 100644
index 00000000000..cd0d1c7f805
--- /dev/null
+++ b/gdb/gdbtk/library/images/tools.gif
Binary files differ
diff --git a/gdb/gdbtk/library/images/tools2_3d.gif b/gdb/gdbtk/library/images/tools2_3d.gif
new file mode 100644
index 00000000000..5141fb62304
--- /dev/null
+++ b/gdb/gdbtk/library/images/tools2_3d.gif
Binary files differ
diff --git a/gdb/gdbtk/library/images/vmake.gif b/gdb/gdbtk/library/images/vmake.gif
new file mode 100644
index 00000000000..509d98a11a0
--- /dev/null
+++ b/gdb/gdbtk/library/images/vmake.gif
Binary files differ
diff --git a/gdb/gdbtk/library/images2/back.gif b/gdb/gdbtk/library/images2/back.gif
new file mode 100644
index 00000000000..67dd57e8ea9
--- /dev/null
+++ b/gdb/gdbtk/library/images2/back.gif
Binary files differ
diff --git a/gdb/gdbtk/library/images2/build.gif b/gdb/gdbtk/library/images2/build.gif
new file mode 100644
index 00000000000..6e4f7f2166b
--- /dev/null
+++ b/gdb/gdbtk/library/images2/build.gif
Binary files differ
diff --git a/gdb/gdbtk/library/images2/cygnus.gif b/gdb/gdbtk/library/images2/cygnus.gif
new file mode 100644
index 00000000000..292fecc627f
--- /dev/null
+++ b/gdb/gdbtk/library/images2/cygnus.gif
Binary files differ
diff --git a/gdb/gdbtk/library/images2/file.gif b/gdb/gdbtk/library/images2/file.gif
new file mode 100644
index 00000000000..247c722234b
--- /dev/null
+++ b/gdb/gdbtk/library/images2/file.gif
Binary files differ
diff --git a/gdb/gdbtk/library/images2/fore.gif b/gdb/gdbtk/library/images2/fore.gif
new file mode 100644
index 00000000000..9a43be0eb86
--- /dev/null
+++ b/gdb/gdbtk/library/images2/fore.gif
Binary files differ
diff --git a/gdb/gdbtk/library/images2/gdbtk.gif b/gdb/gdbtk/library/images2/gdbtk.gif
new file mode 100644
index 00000000000..83c4cc155d9
--- /dev/null
+++ b/gdb/gdbtk/library/images2/gdbtk.gif
Binary files differ
diff --git a/gdb/gdbtk/library/images2/insight.gif b/gdb/gdbtk/library/images2/insight.gif
index fa5cfe19617..c3d93dcdef8 100644
--- a/gdb/gdbtk/library/images2/insight.gif
+++ b/gdb/gdbtk/library/images2/insight.gif
Binary files differ
diff --git a/gdb/gdbtk/library/images2/load.gif b/gdb/gdbtk/library/images2/load.gif
new file mode 100644
index 00000000000..c97a9bfc00e
--- /dev/null
+++ b/gdb/gdbtk/library/images2/load.gif
Binary files differ
diff --git a/gdb/gdbtk/library/images2/opt.gif b/gdb/gdbtk/library/images2/opt.gif
new file mode 100644
index 00000000000..3f0d365e402
--- /dev/null
+++ b/gdb/gdbtk/library/images2/opt.gif
Binary files differ
diff --git a/gdb/gdbtk/library/images2/tools.gif b/gdb/gdbtk/library/images2/tools.gif
new file mode 100644
index 00000000000..cd0d1c7f805
--- /dev/null
+++ b/gdb/gdbtk/library/images2/tools.gif
Binary files differ
diff --git a/gdb/gdbtk/library/images2/tools2_3d.gif b/gdb/gdbtk/library/images2/tools2_3d.gif
new file mode 100644
index 00000000000..5141fb62304
--- /dev/null
+++ b/gdb/gdbtk/library/images2/tools2_3d.gif
Binary files differ
diff --git a/gdb/gdbtk/library/images2/vmake.gif b/gdb/gdbtk/library/images2/vmake.gif
new file mode 100644
index 00000000000..509d98a11a0
--- /dev/null
+++ b/gdb/gdbtk/library/images2/vmake.gif
Binary files differ
diff --git a/gdb/gdbtk/library/interface.tcl b/gdb/gdbtk/library/interface.tcl
index e2287438025..3ff3d55b96f 100644
--- a/gdb/gdbtk/library/interface.tcl
+++ b/gdb/gdbtk/library/interface.tcl
@@ -1,5 +1,5 @@
# Interface between GDB and Insight.
-# Copyright (C) 1997, 1998, 1999, 2001, 2002, 2004, 2008 Red Hat, Inc.
+# Copyright 1997, 1998, 1999 Cygnus Solutions
#
# This program is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License (GPL) as published by
@@ -16,27 +16,14 @@
global gdbtk_state
set gdbtk_state(busyCount) 0
-# *** DEPRECATED: Use GDBEventHandler::breakpoint instead.
# This is run when a breakpoint changes. The arguments are the
# action, the breakpoint number, and the breakpoint info.
-#define_hook gdb_breakpoint_change_hook
+define_hook gdb_breakpoint_change_hook
-# *** DEPRECATED: Use GDBEventHandler::set_variable instead.
# This is run when a `set' command successfully completes in gdb. The
# first argument is the gdb variable name (as a Tcl list). The second
# argument is the new value.
-#define_hook gdb_set_hook
-
-# ------------------------------------------------------------
-# PROC: gdbtk_tcl_set_variable - A "set" command was issued
-# in gdb to change an internal variable. Notify
-# gui.
-# ------------------------------------------------------------
-proc gdbtk_tcl_set_variable {var val} {
- set e [SetVariableEvent \#auto -variable $var -value $val]
- GDBEventHandler::dispatch $e
- delete object $e
-}
+define_hook gdb_set_hook
####################################################################
# #
@@ -47,7 +34,6 @@ proc gdbtk_tcl_set_variable {var val} {
# For debugging purposes, please put debug statements at the very
# beginning and ends of all GUI state hooks.
-# *** DEPRECATED: Use GDBEventHandler::busy instead.
# GDB_BUSY_HOOK
# This hook is used to register a callback when the UI should
# be disabled because the debugger is either busy or talking
@@ -55,9 +41,8 @@ proc gdbtk_tcl_set_variable {var val} {
#
# All callbacks should disable ALL user input which could cause
# any state changes in either the target or the debugger.
-#define_hook gdb_busy_hook
+define_hook gdb_busy_hook
-# *** DEPRECATED: Use GDBEventHandler::idle instead.
# GDB_IDLE_HOOK
# This hook is used to register a callback when the UI should
# be enabled because the debugger is no longer busy.
@@ -67,11 +52,10 @@ proc gdbtk_tcl_set_variable {var val} {
# time delays when enabling the UI.
define_hook gdb_idle_hook
-# *** DEPRECATED: Use GDBEventHandler::update instead.
# GDB_UPDATE_HOOK
# This hook is used to register a callback to update the widget
# when debugger state has changed.
-#define_hook gdb_update_hook
+define_hook gdb_update_hook
# GDB_NO_INFERIOR_HOOK
# This hook is used to register a callback which should be invoked
@@ -100,7 +84,7 @@ define_hook gdb_trace_find_hook
# ------------------------------------------------------------------
proc gdbtk_tcl_preloop { } {
- global gdb_exe_name gdb_current_directory
+ global gdb_exe_name
set_baud
@@ -109,39 +93,33 @@ proc gdbtk_tcl_preloop { } {
# then we will have called pre_add_symbol, which would set us to busy,
# but not the corresponding post_add_symbol. Do this here just in case...
after idle gdbtk_idle
- ManagedWin::startup
-
- if {$gdb_exe_name != ""} {
- # At startup, file_changed_hook is called too late for us, so we
- # must notice the initial session by hand. If the arguments exist
- # -- if the user used `gdb --args' -- then we want the new
- # arguments and pwd to override what is set in the session.
- set current_args [gdb_get_inferior_args]
- set current_dir $gdb_current_directory
- Session::notice_file_change
- set_baud
- if {[string length $current_args] > 0} {
- gdb_set_inferior_args $current_args
- gdb_cmd "cd $current_dir"
- }
+ set src [ManagedWin::open SrcWin]
+ debug "In preloop, with src: \"$src\" & error: \"$::errorInfo\""
+ SrcWin::point_to_main
+ set msg ""
+ catch {gdb_cmd "info files"} msg
+ set line1 [string range $msg 0 [string first \n $msg]]
+ if {[regexp {Symbols from "(.*)"\.} $line1 dummy name]} {
+ set gdb_exe_name $name
}
-
gdbtk_update
}
# ------------------------------------------------------------------
-# PROCEDURE: gdbtk_busy - Dispatch a busy event
+# PROCEDURE: gdbtk_busy - run all busy hooks
#
# Use this procedure from within GUI code to indicate that
# the debugger is busy, either running the inferior or
-# talking to the target.
+# talking to the target. This will call all the registered
+# gdb_busy_hook's.
# ------------------------------------------------------------------
proc gdbtk_busy {} {
- set e [BusyEvent \#auto]
- GDBEventHandler::dispatch $e
- delete object $e
+ set err [catch {run_hooks gdb_busy_hook} txt]
+ if {$err} {
+ debug "gdbtk_busy ERROR: $txt"
+ }
# Force the screen to update
update
@@ -155,41 +133,21 @@ proc gdbtk_busy {} {
# that could change target state.
# ------------------------------------------------------------------
proc gdbtk_update {} {
-
- set e [UpdateEvent \#auto]
- GDBEventHandler::dispatch $e
- delete object $e
+ set err [catch {run_hooks gdb_update_hook} txt]
+ if {$err} {
+ debug "gdbtk_update ERROR: $txt"
+ }
# Force the screen to update
update
}
# ------------------------------------------------------------------
-# PROCEDURE: gdbtk_update_safe - run all update hooks in a safe way
-#
-# Use this procedure to force all widgets to update
-# themselves. This hook is usually run after command
-# that could change target state.
-# Like gdbtk_update but safe to be used in "after idle"
-# which is used in update hooks.
-# ------------------------------------------------------------------
-proc gdbtk_update_safe {} {
- global gdb_running
-
- # Fencepost: Do not update if we are running the target
- # We get here because script commands may have changed memory or
- # registers and "after idle" events registered as a consequence
- # If we try to update while the target is running we are doomed.
- if {!$gdb_running} {
- gdbtk_update
- }
-}
-
-# ------------------------------------------------------------------
-# PROCEDURE: gdbtk_idle - dispatch IdleEvent
+# PROCEDURE: gdbtk_idle - run all idle hooks
#
-# Use this procedure to free the UI for more user input.
-# This should only be run AFTER all communication with
+# Use this procedure to run all the gdb_idle_hook's,
+# which should free the UI for more user input. This
+# hook should only be run AFTER all communication with
# the target has halted, otherwise the risk of two (or
# more) widgets talking to the target arises.
# ------------------------------------------------------------------
@@ -199,35 +157,33 @@ proc gdbtk_idle {} {
# Put the unfiltered hook back in place, just in case
# somebody swapped it out, and then died before they
# could replace it.
- gdb_restore_fputs
- set err [catch {run_hooks gdb_idle_hook}]
- if {$err} {
- dbug E "Error running gdb_idle_hook: $::errorInfo"
+ gdb_restore_fputs
+ set err [catch {run_hooks gdb_idle_hook} txt]
+ if {$err} {
+ debug "gdbtk_idle 1 ERROR: $txt"
}
-
- set e [IdleEvent \#auto]
- GDBEventHandler::dispatch $e
- delete object $e
-
+
if {!$gdb_running} {
set err [catch {run_hooks gdb_no_inferior_hook} txt]
if {$err} {
- dbug E "no_inferior_hook error: $txt"
+ debug "gdbtk_idle 2 ERROR: $txt"
}
- }
-
+ }
# Force the screen to update
update
}
define_hook download_progress_hook
+# Random hook of procs to call just before exiting.
+define_hook gdb_quit_hook
+
# ------------------------------------------------------------------
# PROCEDURE: gdbtk_quit_check - Ask if the user really wants to quit.
# ------------------------------------------------------------------
proc gdbtk_quit_check {} {
- global gdb_downloading gdb_running gdb_exe_name
+ global gdb_downloading gdb_running
if {$gdb_downloading} {
set msg "Downloading to target,\n really close the debugger?"
@@ -235,44 +191,29 @@ proc gdbtk_quit_check {} {
return 0
}
} elseif {$gdb_running} {
- # While we are running the inferior, gdb_cmd is fenceposted and
- # returns immediately. Therefore, we need to ask here. Do we need
- # to stop the target, too?
+ # While we are running the inferior, gdb_cmd is fenceposted and returns
+ # immediately. Therefore, we need to ask here. Do we need to stop the target,
+ # too?
set msg "A debugging session is active.\n"
append msg "Do you still want to close the debugger?"
if {![gdbtk_tcl_query $msg no]} {
return 0
}
}
-
return 1
}
# ------------------------------------------------------------------
# PROCEDURE: gdbtk_quit - Quit the debugger
# Call this procedure anywhere the user can request to quit.
-# This procedure will ask all the right questions before
-# exiting.
+# This procedure will ask all the right questions and run
+# all the gdb_quit_hooks before exiting.
# ------------------------------------------------------------------
proc gdbtk_quit {} {
if {[gdbtk_quit_check]} {
- gdbtk_force_quit
- }
-}
-
-# ------------------------------------------------------------------
-# PROCEDURE: gdbtk_force_quit - Quit the debugger immediately
-# ------------------------------------------------------------------
-proc gdbtk_force_quit {} {
- # If we don't delete source windows, GDB hooks will
- # try to update them as we exit
- foreach win [ManagedWin::find SrcWin] {
- delete object $win
+ pref_save
+ gdb_force_quit
}
- # Calling gdb_force_quit is probably not necessary here
- # because it should have been called when the source window(s)
- # were deleted, but just in case...
- gdb_force_quit
}
# ------------------------------------------------------------------
@@ -280,28 +221,15 @@ proc gdbtk_force_quit {} {
# before exiting. Last chance to cleanup!
# ------------------------------------------------------------------
proc gdbtk_cleanup {} {
- global gdb_exe_name
-
- # Save the session
- if {$gdb_exe_name != ""} {
- Session::save
- }
-
- # This is a sign that it is too late to be doing updates, etc...
- set ::gdb_shutting_down 1
-
- # Shutdown the window manager and save all preferences
- # This way a "quit" in the console window will cause
- # preferences to be saved.
- ManagedWin::shutdown
- pref_save
+ # This is a sign that it is too late to be doing updates, etc...
+ set ::gdb_shutting_down 1
}
# ------------------------------------------------------------------
# PROC: gdbtk_tcl_query -
# ------------------------------------------------------------------
proc gdbtk_tcl_query {message {default yes}} {
- global gdb_checking_for_exit gdbtk_state gdbtk_platform
+ global gdb_checking_for_exit gdbtk_state tcl_platform
# FIXME We really want a Help button here. But Tk's brain-damaged
# modal dialogs won't really allow it. Should have async dialog
@@ -317,7 +245,7 @@ proc gdbtk_tcl_query {message {default yes}} {
set modal "system"
}
- if {$gdbtk_platform(platform) == "windows"} {
+ if {$tcl_platform(platform) == "windows"} {
# On Windows, we want to only ask each question once.
# If we're already asking the question, just wait for the answer
# to come back.
@@ -347,7 +275,7 @@ proc gdbtk_tcl_query {message {default yes}} {
# question.
set r [tk_messageBox -icon warning -default $default \
-message $message -title $title \
- -type yesno -parent .]
+ -type yesno -modal $modal -parent .]
}
update idletasks
@@ -365,9 +293,6 @@ proc gdbtk_tcl_warning {message} {
switch -regexp $message {
"Unable to find dynamic linker breakpoint function.*" {return}
- "Internal error.*" { gdbtk_tcl_fputs_error $message }
- "incomplete CFI.*" { gdbtk_tcl_fputs_error $message }
- "RTTI symbol not found for class.*" { gdbtk_tcl_fputs_error $message }
default {show_warning $message}
}
}
@@ -376,33 +301,22 @@ proc gdbtk_tcl_warning {message} {
# PROC: show_warning -
# ------------------------------------------------------------------
proc show_warning {message} {
- global gdbtk_platform
+ global tcl_platform
# FIXME We really want a Help button here. But Tk's brain-damaged
# modal dialogs won't really allow it. Should have async dialog
# here.
set title "GDB"
set modal "task"
-
-# On Windows, we use ide_messageBox which runs the Win32 MessageBox function
-# in another thread. This permits a program which handles IDE requests from
-# other programs to not return from the request until the MessageBox completes.
-# This is not possible without using another thread, since the MessageBox
-# function call will be running its own event loop, and will be higher on the
-# stack than the IDE request.
-#
-# On Unix tk_messageBox runs in the regular Tk event loop, so
-# another thread is not required.
-
- if {$gdbtk_platform(platform) == "windows"} {
- ide_messageBox [list set r] -icon warning \
+ if {$tcl_platform(platform) == "windows"} {
+ ide_messageBox -icon warning \
-default ok -message $message -title $title \
-type ok -modal $modal -parent .
} else {
set r [tk_messageBox -icon warning -default ok \
-message $message -title $title \
- -type ok -parent .]
+ -type ok -modal $modal -parent .]
}
}
@@ -422,7 +336,7 @@ proc gdbtk_tcl_fputs {message} {
# Restore the fputs hook, in case anyone forgot to put it back...
gdb_restore_fputs
- if {[info exists gdbtk_state(console)] && $gdbtk_state(console) != ""} {
+ if {$gdbtk_state(console) != ""} {
$gdbtk_state(console) insert $message
}
}
@@ -435,48 +349,20 @@ proc echo {args} {
}
# ------------------------------------------------------------------
-# PROC: gdbtk_tcl_fputs_error - write an error message
+# PROC: gdbtk_tcl_fputs_error -
# ------------------------------------------------------------------
proc gdbtk_tcl_fputs_error {message} {
- if {[info exists ::gdbtk_state(console)] && $::gdbtk_state(console) != ""} {
- $::gdbtk_state(console) insert $message err_tag
- update
- }
-}
+ global gdbtk_state
+ # Restore the fputs hook, in case anyone forgot to put it back...
+ gdb_restore_fputs
-# ------------------------------------------------------------------
-# PROC: gdbtk_tcl_fputs_log - write a log message
-# ------------------------------------------------------------------
-proc gdbtk_tcl_fputs_log {message} {
- if {[info exists ::gdbtk_state(console)] && $::gdbtk_state(console) != ""} {
- $::gdbtk_state(console) insert $message log_tag
+ if {$gdbtk_state(console) != ""} {
+ $gdbtk_state(console) einsert $message
update
}
}
# ------------------------------------------------------------------
-# PROC: gdbtk_tcl_fputs_target - write target output
-# ------------------------------------------------------------------
-proc gdbtk_tcl_fputs_target {message} {
- if {$::gdbtk_state(console) == ""} {
- ManagedWin::open Console -force
- }
- $::gdbtk_state(console) insert $message target_tag
- update
-}
-
-
-# ------------------------------------------------------------------
-# PROC: gdbtk_tcl_fputs_target_err - write target error output
-# ------------------------------------------------------------------
-proc gdbtk_tcl_fputs_target_err {message} {
- if {$::gdbtk_state(console) == ""} {
- ManagedWin::open Console -force
- }
- $::gdbtk_state(console) insert $message err_tag
-}
-
-# ------------------------------------------------------------------
# PROC: gdbtk_tcl_flush -
# ------------------------------------------------------------------
proc gdbtk_tcl_flush {} {
@@ -499,32 +385,26 @@ proc gdbtk_tcl_end_variable_annotation {} {
}
# ------------------------------------------------------------------
-# PROC: gdbtk_tcl_breakpoint - A breakpoint was changed -- notify
-# gui.
+# PROC: gdbtk_tcl_breakpoint -
# ------------------------------------------------------------------
-proc gdbtk_tcl_breakpoint {action bpnum} {
-# debug "BREAKPOINT: $action $bpnum"
- set e [BreakpointEvent \#auto -action $action -number $bpnum]
- GDBEventHandler::dispatch $e
- delete object $e
+proc gdbtk_tcl_breakpoint {action bpnum addr line file bp_type enabled thread} {
+# debug "BREAKPOINT: $action $bpnum $addr $line $file $bp_type $enabled $thread "
+ run_hooks gdb_breakpoint_change_hook $action $bpnum $addr $line $file $bp_type $enabled $thread
}
# ------------------------------------------------------------------
-# PROC: gdbtk_tcl_tracepoint - A tracepoint was changed -- notify
-# gui.
+# PROC: gdbtk_tcl_tracepoint -
# ------------------------------------------------------------------
-proc gdbtk_tcl_tracepoint {action tpnum} {
-# debug "TRACEPOINT: $action $tpnum"
- set e [TracepointEvent \#auto -action $action -number $tpnum]
- GDBEventHandler::dispatch $e
- delete object $e
+proc gdbtk_tcl_tracepoint {action tpnum addr line file pass_count} {
+# debug "TRACEPOINT: $action $tpnum $addr $line $file $pass_count"
+ run_hooks gdb_breakpoint_change_hook $action $tpnum $addr $line $file tracepoint
}
# ------------------------------------------------------------------
# PROC: gdbtk_tcl_trace_find_hook -
# ------------------------------------------------------------------
proc gdbtk_tcl_trace_find_hook {arg from_tty} {
-# debug "$arg $from_tty"
+# debug "Running trace find hook with $arg $from_tty"
run_hooks gdb_trace_find_hook $arg $from_tty
}
@@ -543,21 +423,8 @@ proc gdbtk_tcl_trace_find_hook {arg from_tty} {
# ------------------------------------------------------------------
proc gdb_run_readline_command {command args} {
global gdbtk_state
- debug "$command $args"
- set gdbtk_state(readlineArgs) $args
- set gdbtk_state(readlineShowUser) 1
- gdb_cmd $command
-}
-
-# ------------------------------------------------------------------
-# PROC: gdb_run_readline_command_no_output
-# Run a readline command, but don't show the commands to the user.
-# ------------------------------------------------------------------
-proc gdb_run_readline_command_no_output {command args} {
- global gdbtk_state
- debug "$command $args"
+# debug "run readline_command $command $args"
set gdbtk_state(readlineArgs) $args
- set gdbtk_state(readlineShowUser) 0
gdb_cmd $command
}
@@ -566,9 +433,9 @@ proc gdb_run_readline_command_no_output {command args} {
# ------------------------------------------------------------------
proc gdbtk_tcl_readline_begin {message} {
global gdbtk_state
-# debug
+# debug "readline begin"
set gdbtk_state(readline) 0
- if {$gdbtk_state(console) != "" && $gdbtk_state(readlineShowUser)} {
+ if {$gdbtk_state(console) != ""} {
$gdbtk_state(console) insert $message
}
}
@@ -578,13 +445,11 @@ proc gdbtk_tcl_readline_begin {message} {
# ------------------------------------------------------------------
proc gdbtk_tcl_readline {prompt} {
global gdbtk_state
-# debug "prompt=$prompt"
+# debug "gdbtk_tcl_readline $prompt"
if {[info exists gdbtk_state(readlineArgs)]} {
# Not interactive, so pop the list, and print element.
set cmd [lvarpop gdbtk_state(readlineArgs)]
- if {$gdbtk_state(console) != "" && $gdbtk_state(readlineShowUser)} {
- $gdbtk_state(console) insert $cmd
- }
+ command::insert_command $cmd
} else {
# Interactive.
# debug "interactive"
@@ -604,9 +469,10 @@ proc gdbtk_tcl_readline {prompt} {
# ------------------------------------------------------------------
proc gdbtk_tcl_readline_end {} {
global gdbtk_state
-# debug
+# debug "readline_end"
catch {unset gdbtk_state(readlineArgs)}
- catch {unset gdbtk_state(readlineActive)}
+ unset gdbtk_state(readlineActive)
+ command::end_multi_line_input
}
# ------------------------------------------------------------------
@@ -679,7 +545,7 @@ proc gdbtk_tcl_display {action number {value {}}} {
# the user has changed the contents of a register.
# ------------------------------------------------------------------
proc gdbtk_register_changed {} {
- after idle gdbtk_update_safe
+ after idle gdbtk_update
}
# ------------------------------------------------------------------
@@ -689,7 +555,7 @@ proc gdbtk_register_changed {} {
# the program's variables).
# ------------------------------------------------------------------
proc gdbtk_memory_changed {} {
- after idle gdbtk_update_safe
+ after idle gdbtk_update
}
####################################################################
@@ -705,10 +571,10 @@ proc gdbtk_memory_changed {} {
# - file_changed_hook #
# Called in file_command. The tcl hook is #
# "gdbtk_tcl_file_changed" #
-# - deprecated_pre_add_symbol_hook #
+# - pre_add_symbol_hook #
# Called in symbol_file_add before loading. The tcl #
# hook is "gdbtk_tcl_pre_add_symbol" #
-# - deprecated_post_add_symbol_hook #
+# - post_add_symbol_hook #
# Called in symbol_file_add when finished loading #
# a symbol file. The tcl hook is #
# "gdbtk_tcl_post_add_symbol" #
@@ -760,17 +626,8 @@ proc gdbtk_tcl_post_add_symbol {} {
# ------------------------------------------------------------------
proc gdbtk_tcl_file_changed {filename} {
- if {$filename == ""} {
- gdb_clear_file
- catch {run_hooks gdb_clear_file_hook}
- set ::gdb_exe_name ""
- set ::gdb_loaded 0
- set ::gdb_running 0
- gdbtk_update
- } else {
- SrcWin::point_to_main
- run_hooks file_changed_hook
- }
+ SrcWin::point_to_main
+ run_hooks file_changed_hook
}
# ------------------------------------------------------------------
@@ -784,7 +641,7 @@ proc gdbtk_tcl_file_changed {filename} {
# commands, then we cannot look for main.
# ------------------------------------------------------------------
proc gdbtk_tcl_exec_file_display {filename} {
- global gdb_exe_changed
+ global gdb_loaded gdb_running gdb_exe_name gdb_target_changed
# DO NOT CALL set_exe here!
@@ -797,14 +654,7 @@ proc gdbtk_tcl_exec_file_display {filename} {
# set_exe calls file command with the filename in
# quotes, so we need to strip them here.
- # We need to make sure that we turn filename into
- # an absolute path or sessions won't work.
- if {[file tail $filename] == $filename} {
- # want full pathname
- set filename [file join $::gdb_current_directory $filename]
- }
- set_exe_name $filename
- set gdb_exe_changed 0
+ set gdb_exe_name [string trim $filename \']
SrcWin::point_to_main
}
@@ -823,39 +673,20 @@ proc gdbtk_tcl_exec_file_display {filename} {
# 3: source line number
# 4: address
# 5: current PC - which will often be the same as address, but not when
-# we are browsing, or walking the stack.
# 6: shared library name if the pc is in a shared lib
+# we are browsing, or walking the stack.
#
# ------------------------------------------------------------------
-proc gdbtk_locate_main {{init ""}} {
- global _main_cache gdb_exe_name
- debug
-
- if {$init == "" && $_main_cache != ""} {
- #debug "returning $_main_cache from cache"
- return $_main_cache
- }
- set _main_cache {}
-
+proc gdbtk_locate_main {} {
set main_names [pref get gdb/main_names]
+ debug "gdbtk_locate_main: Searching $main_names"
foreach main $main_names {
- if {![catch {gdb_loc $main} linespec]} {
- set _main_cache $linespec
- break
+ if {![catch {gdb_search functions $main -static 1}] \
+ && ![catch {gdb_loc $main} linespec]} {
+ return $linespec
}
}
- if {$_main_cache == {}
- && ![catch gdb_entry_point entry_point]
- && ![catch {gdb_loc "*$entry_point"} linespec]} {
- set _main_cache $linespec
- }
-
- # need to see if result is valid
- lassign $_main_cache file func ffile line addr rest
- if {$addr == 0x0 && $func == {}} { set _main_cache {} }
-
- #debug "returning $_main_cache"
- return $_main_cache
+ return {}
}
##############################################
@@ -869,8 +700,7 @@ proc gdbtk_locate_main {{init ""}} {
# ------------------------------------------------------------------
proc set_exe_name {exe} {
global gdb_exe_name gdb_exe_changed
- #debug "exe=$exe gdb_exe_name=$gdb_exe_name"
-
+ #debug "set_exe_name: exe=$exe gdb_exe_name=$gdb_exe_name"
set gdb_exe_name $exe
set gdb_exe_changed 1
}
@@ -887,7 +717,7 @@ proc set_exe {} {
if {$gdb_exe_name == ""} { return }
set err [catch {gdb_cmd "file '$gdb_exe_name'" 1} msg]
if {$err} {
- dbug E "$msg"
+ debug "set_exe ERROR: $msg"
set l [split $msg :]
set errtxt [join [lrange $l 1 end] :]
set msg "Error loading \"$gdb_exe_name\":\n"
@@ -899,8 +729,11 @@ proc set_exe {} {
return
} elseif {[string match {*no debugging symbols found*} $msg]} {
tk_messageBox -icon error -default ok \
- -title "GDB" -type ok \
+ -title "GDB" -type ok -modal system \
-message "This executable has no debugging information."
+ set gdb_exe_name {}
+ set file_done 0
+ return
}
# force new target command
@@ -916,7 +749,7 @@ proc set_exe {} {
# ------------------------------------------------------------------
proc _open_file {{file ""}} {
- global gdb_running gdb_downloading gdbtk_platform
+ global gdb_running gdb_downloading tcl_platform
if {$gdb_running || $gdb_downloading} {
# We are already running/downloading something..
@@ -943,11 +776,9 @@ proc _open_file {{file ""}} {
ide_grab_support enable_all
# If no one had the focus before, leave it that way (since I
- # am not sure how this could happen... Also, the vwait in
- # tk_getOpenFile could have allowed the curFocus window to actually
- # be destroyed, so make sure it is still around.
+ # am not sure how this could happen...
- if {$curFocus != "" && [winfo exists $curFocus]} {
+ if {$curFocus != ""} {
raise [winfo toplevel $curFocus]
focus $curFocus
}
@@ -962,7 +793,7 @@ proc _open_file {{file ""}} {
}
# Add the base dir for this file to the source search path.
set root [file dirname $file]
- if {$gdbtk_platform(os) == "cygwin"} {
+ if {$tcl_platform(platform) == "windows"} {
set root [ide_cygwin_path to_posix $root]
set file [ide_cygwin_path to_posix $file]
}
@@ -982,42 +813,11 @@ proc _open_file {{file ""}} {
gdbtk_idle
return 0
}
-
+
return 1
}
# ------------------------------------------------------------------
-# _close_file - close the current executable and prepare for
-# another executable.
-# ------------------------------------------------------------------
-proc _close_file {} {
-
- # If there is already an inferior, ask him if he wants to close
- # the file. If there is already an exec file loaded (and not run)
- # also ask, but don't ask twice.
- set okay 1
- if {[gdb_target_has_execution]} {
- set okay [gdbtk_tcl_query "Program is already running.\nClose file anyway?"]
- } elseif {$::gdb_exe_name != ""} {
- set okay [gdbtk_tcl_query "Program already loaded.\nClose file anyway?"]
- } else {
- # No exec file yet
- return
- }
-
- if {$okay} {
- Session::save
- gdb_clear_file
- gdbtk_tcl_file_changed ""
-
- # Print out a little message to all console windows
- foreach cw [ManagedWin::find Console] {
- $cw insert "No executable file now.\n"
- }
- }
-}
-
-# ------------------------------------------------------------------
# PROC: set_target_name - Update the target name.
#
# This function will prompt for a new target and update
@@ -1073,7 +873,7 @@ proc set_target_name {{prompt 1}} {
}
set hostname [pref getd gdb/load/$target-hostname]
if {$hostname == ""} {
- set hostname [pref getd gdb/load/default-hostname]
+ set hostname [pref get gdb/load/default-hostname]
}
# replace "com1" with the real port name
set targ [lrep $targ "com1" $port]
@@ -1097,8 +897,8 @@ proc set_target_name {{prompt 1}} {
# ------------------------------------------------------------------
proc set_target {} {
global gdb_target_cmd gdb_target_changed gdb_pretty_name gdb_target_name
- #debug "gdb_target_changed=$gdb_target_changed gdb_target_cmd=\"$gdb_target_cmd\""
- #debug "gdb_target_name=$gdb_target_name"
+# debug "gdb_target_changed=$gdb_target_changed gdb_target_cmd=\"$gdb_target_cmd\""
+# debug "gdb_target_name=$gdb_target_name"
if {$gdb_target_cmd == "" && ![TargetSelection::native_debugging]} {
if {$gdb_target_name == ""} {
set prompt 1
@@ -1121,10 +921,8 @@ proc set_target {} {
update
catch {gdb_cmd "detach"}
debug "CONNECTING TO TARGET: $gdb_target_cmd"
- gdbtk_busy
set err [catch {gdb_immediate "target $gdb_target_cmd"} msg ]
$srcWin set_status
- gdbtk_idle
if {$err} {
if {[string first "Program not killed" $msg] != -1} {
@@ -1134,7 +932,7 @@ proc set_target {} {
set dialog_title "GDB"
set debugger_name "GDB"
tk_messageBox -icon error -title $dialog_title -type ok \
- -message "$msg\n\n$debugger_name cannot connect to the target board\
+ -modal task -message "$msg\n\n$debugger_name cannot connect to the target board\
using [lindex $gdb_target_cmd 1].\nVerify that the board is securely connected and, if\
necessary,\nmodify the port setting with the debugger preferences."
return ERROR
@@ -1142,7 +940,7 @@ necessary,\nmodify the port setting with the debugger preferences."
if {![catch {pref get gdb/load/$gdb_target_name-after_attaching} aa] && $aa != ""} {
if {[catch {gdb_cmd $aa} err]} {
- catch {[ManagedWin::find Console] insert $err err_tag}
+ catch {[ManagedWin::find Console] einsert $err}
}
}
set gdb_target_changed 0
@@ -1160,7 +958,7 @@ necessary,\nmodify the port setting with the debugger preferences."
proc run_executable { {auto_start 1} } {
global gdb_loaded gdb_downloading gdb_target_name
global gdb_exe_changed gdb_target_changed gdb_program_has_run
- global gdb_running gdb_exe_name gdbtk_platform
+ global gdb_running gdb_exe_name
# debug "auto_start=$auto_start gdb_target_name=$gdb_target_name"
@@ -1185,8 +983,7 @@ proc run_executable { {auto_start 1} } {
# Attach
if {$gdb_target_name == "" || [pref get gdb/src/run_attach]} {
- set r [gdbtk_attach_remote]
- if {$r == "ATTACH_CANCELED" || $r == "ATTACH_ERROR"} {
+ if {[gdbtk_attach_target] == "ATTACH_CANCELED"} {
return
}
}
@@ -1250,18 +1047,10 @@ proc run_executable { {auto_start 1} } {
set gdb_args [pref getd gdb/load/$gdb_target_name-opts]
if { $gdb_args != ""} {
debug "set args $gdb_args"
- gdb_set_inferior_args $gdb_args
+ catch {gdb_cmd "set args $gdb_args"}
}
}
- # If the user requested it, start an xterm for use as the
- # inferior's tty.
- if {$gdbtk_platform(platform) != "windows"
- && [pref getd gdb/process/xtermtty] == "yes"} {
- tty::create
- }
-
- #
# Run
if {$auto_start} {
@@ -1300,7 +1089,7 @@ proc run_executable { {auto_start 1} } {
} else {
SrcWin::point_to_main
}
-
+
gdbtk_update
gdbtk_idle
} elseif {[pref get gdb/mode]} {
@@ -1312,7 +1101,7 @@ proc run_executable { {auto_start 1} } {
}
# ------------------------------------------------------------------
-# PROC: gdbtk_attach_remote - attach to the target
+# PROC: gdbtk_attach_target - attach to the target
# This proc returns the following status messages:
#
# ATTACH_ERROR: An error occurred connecting to target.
@@ -1321,7 +1110,7 @@ proc run_executable { {auto_start 1} } {
# ATTACH_TARGET_UNCHANGED: Successfully attached, target unchanged.
# UNKNOWN: An unknown error occurred.
# ------------------------------------------------------------------
-proc gdbtk_attach_remote {} {
+proc gdbtk_attach_target {} {
global gdb_loaded
debug "Attaching...."
@@ -1365,66 +1154,6 @@ proc gdbtk_attach_remote {} {
}
# ------------------------------------------------------------------
-# PROC: gdbtk_connect: connect to a remote target
-# in asynch mode if async is 1
-# ------------------------------------------------------------------
-proc gdbtk_connect {{async 0}} {
- global file_done
-
- debug "async=$async"
-
- gdbtk_busy
-
- set result [gdbtk_attach_remote]
- switch $result {
- ATTACH_ERROR {
- set successful 0
- }
-
- ATTACH_TARGET_CHANGED {
- if {[pref get gdb/load/check] && $file_done} {
- set err [catch {gdb_cmd "compare-sections"} errTxt]
- if {$err} {
- set successful 0
- tk_messageBox -title "Error" -message $errTxt \
- -icon error -type ok
- break
- }
- }
-
- tk_messageBox -title "GDB" -message "Successfully connected" \
- -icon info -type ok
- set successful 1
- }
-
- ATTACH_CANCELED {
- tk_messageBox -title "GDB" -message "Connection Canceled" -icon info \
- -type ok
- set successful 0
- }
-
- ATTACH_TARGET_UNCHANGED {
- tk_messageBox -title "GDB" -message "Successfully connected" \
- -icon info -type ok
- set successful 1
- }
-
- default {
- dbug E "Unhandled response from gdbtk_attach_remote: \"$result\""
- set successful 0
- }
- }
-
- gdbtk_idle
-
- # Whenever we attach, we need to do an update
- if {$successful} {
- gdbtk_attached
- }
- return $successful
-}
-
-# ------------------------------------------------------------------
# PROC: gdbtk_step - step the target
# ------------------------------------------------------------------
proc gdbtk_step {} {
@@ -1466,7 +1195,7 @@ proc gdbtk_nexti {} {
catch {gdb_immediate nexti}
}
-# ------------------------------------------------------------------
+ # ------------------------------------------------------------------
# PROC: gdbtk_attached
# ------------------------------------------------------------------
#
@@ -1496,16 +1225,15 @@ proc gdbtk_detached {} {
# the debugger must be able to keep gui alive while target_wait is
# blocking (so that the user can interrupt or detach from it).
#
-# The best solution for this is to capture gdb deep down where it can
-# block. For _any_ target board, this will be in either serial or
-# socket code. These places call deprecated_ui_loop_hook to keep us
-# alive. For native unix, we use an interval timer. Simulators either
-# call deprecated_ui_loop_hook directly (older sims, at least) or they
-# call gdb's os_poll_quit callback, where we insert a call to
-# deprecated_ui_loop_hook. Some targets (like v850ice and windows
-# native) require a call to deprecated_ui_loop_hook directly in
-# target_wait. See comments before gdb_stop and x_event to find out
-# more about how this is accomplished.
+# The best solution for this is to capture gdb deep down where it
+# can block. For _any_ target board, this will be in either
+# serial or socket code. These places call ui_loop_hook to
+# keep us alive. For native unix, we use an interval timer.
+# Simulators either call ui_loop_hook directly (older sims, at least)
+# or they call gdb's os_poll_quit callback, where we insert a call
+# to ui_loop_hook. Some targets (like v850ice and windows native)
+# require a call to ui_loop_hook directly in target_wait. See comments
+# before gdb_stop and x_event to find out more about how this is accomplished.
#
# The stop button's behavior:
# Pressing the stop button should attempt to stop the target. If, after
@@ -1517,7 +1245,7 @@ proc gdbtk_stop {} {
if {$_gdbtk_stop(timer) == ""} {
add_hook gdb_idle_hook gdbtk_stop_idle_callback
- set _gdbtk_stop(timer) [after 15000 gdbtk_detach]
+ set _gdbtk_stop(timer) [after 3000 gdbtk_detach]
catch {gdb_stop}
}
}
@@ -1574,43 +1302,10 @@ proc gdbtk_detach {} {
# PROC: gdbtk_run
# ------------------------------------------------------------------
proc gdbtk_run {} {
- if {$::gdb_running == 1} {
- set msg "A program is currently being debugged.\n"
- append msg "Do you want to restart?"
- if {![gdbtk_tcl_query $msg no]} {
- # NO
- return
- }
- }
run_executable
}
# ------------------------------------------------------------------
-# PROC: gdbtk_attach_native: attach to a running target
-# ------------------------------------------------------------------
-proc gdbtk_attach_native {} {
- ManagedWin::open_dlg AttachDlg ;#-transient
-
- debug "ManagedWin got [AttachDlg::last_button] [AttachDlg::pid]"
-
- if {[AttachDlg::last_button]} {
- set pid [AttachDlg::pid]
- set symbol_file [AttachDlg::symbol_file]
- if {$symbol_file != "" && ![_open_file $symbol_file]} {
- ManagedWin::open WarningDlg -transient \
- -message "Could not load symbols from $symbol_file."
- return
- }
-
- if {[catch {gdb_cmd "attach $pid"} result]} {
- ManagedWin::open WarningDlg -transient \
- -message [list "Could not attach to $pid:\n$result"]
- return
- }
- }
-}
-
-# ------------------------------------------------------------------
# PROC: set_baud - Tell GDB the baud rate.
# ------------------------------------------------------------------
proc set_baud {} {
@@ -1632,9 +1327,9 @@ proc do_state_hook {varname ind op} {
}
# ------------------------------------------------------------------
-# PROC: gdbtk_disconnect -
+# PROC: disconnect -
# ------------------------------------------------------------------
-proc gdbtk_disconnect {{async 0}} {
+proc disconnect {{async 0}} {
global gdb_loaded gdb_target_changed
catch {gdb_cmd "detach"}
# force a new target command to do something
@@ -1728,9 +1423,9 @@ define_hook gdb_clear_file_hook
proc gdbtk_clear_file {} {
global gdb_target_name
- debug
+ dbug W "GDBTK_CLEAR_FILE"
# Give widgets a chance to clean up
- catch {run_hooks gdb_clear_file_hook}
+ run_hooks gdb_clear_file_hook
# Save the target name in case the user has already selected a
# target. No need to force the user to select it again.
@@ -1779,12 +1474,8 @@ proc initialize_gdbtk {} {
# Only do this once...
set gdbtk_state(readline) 0
set gdbtk_state(console) ""
- set gdbtk_state(readlineShowUser) 1
}
- # flush cache for gdbtk_locate_main
- gdbtk_locate_main 1
-
# check for existence of a kod command and get it's name and
# text for menu entry
set gdb_kod_cmd ""
@@ -1810,20 +1501,3 @@ proc initialize_gdbtk {} {
set gdb_target_changed 1
}
-# The architecture changed. Inform the UI.
-proc gdbtk_tcl_architecture_changed {} {
- set e [ArchChangedEvent \#auto]
- GDBEventHandler::dispatch $e
- delete object $e
-}
-
-proc gdbtk_console_read {} {
- if {$::gdbtk_state(console) == ""} {
- ManagedWin::open Console -force
- } else {
- raise [namespace tail $::gdbtk_state(console)]
- }
- set result [$::gdbtk_state(console) gets]
- debug "result=$result"
- return $result
-}
diff --git a/gdb/gdbtk/library/kod.itb b/gdb/gdbtk/library/kod.itb
index 3140733d483..f2770fdf5cf 100644
--- a/gdb/gdbtk/library/kod.itb
+++ b/gdb/gdbtk/library/kod.itb
@@ -1,5 +1,5 @@
-# Kernel Object Display Window for Insight.
-# Copyright (C) 1998, 1999, 2001 Red Hat, Inc.
+# Kernel Object Display Window for GDBtk.
+# Copyright (C) 1998, 1999 Cygnus Solutions
#
# This program is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License (GPL) as published by
@@ -18,7 +18,7 @@
# ------------------------------------------------------------------
# CONSTRUCTOR - create new process window
# ------------------------------------------------------------------
-itcl::body KodWin::constructor {args} {
+body KodWin::constructor {args} {
#
# Create a window with the same name as this object
#
@@ -31,12 +31,18 @@ itcl::body KodWin::constructor {args} {
gdbtk_busy
build_win
gdbtk_idle
+
+ # Add hooks for this object
+ add_hook gdb_update_hook [code $this update]
+ add_hook gdb_busy_hook [code $this busy]
+ add_hook gdb_idle_hook [code $this idle]
+ add_hook gdb_set_hook [code $this set_os]
}
# ------------------------------------------------------------------
# METHOD: build_win - build the main KOD window
# ------------------------------------------------------------------
-itcl::body KodWin::build_win {} {
+body KodWin::build_win {} {
# FIXME: rename this variable.
global kodActivePane
@@ -133,7 +139,7 @@ itcl::body KodWin::build_win {} {
pack $tp.tf -side top -expand yes -fill both -padx 5 -pady 5
pack $tp.bf -side top -expand no -fill x -padx 5 -pady 5
pack $itk_interior.pw -side bottom -expand yes -fill both
- wm minsize $_top 450 500
+ wm minsize $Top 450 500
# Initialize button state variables for idle (called before update)
set BState(BDisplay) disabled
@@ -143,13 +149,13 @@ itcl::body KodWin::build_win {} {
# window_name "Kernel Objects"
- update dummy
+ update
}
# ------------------------------------------------------------------
# METHOD: update - update widget when something changes
# ------------------------------------------------------------------
-itcl::body KodWin::update {event} {
+body KodWin::update {} {
debug "updating kod window"
@@ -168,7 +174,7 @@ itcl::body KodWin::update {event} {
# We get here from a press on the Display button or
# from a <Double-1> on a line of the list of objects
# ------------------------------------------------------------------
-itcl::body KodWin::display {} {
+body KodWin::display {} {
upvar \#0 $this table_vals
if {!$Running && [$lf.s cget -rows] > 1} {
gdbtk_busy
@@ -179,7 +185,7 @@ itcl::body KodWin::display {} {
set LevelCmd($level) $LevelCmd([expr $level-1])
append LevelCmd($level) $object
debug "kod command for level $level is now: $LevelCmd($level)"
- update dummy
+ update
# Run idle hooks and cause all other widgets to update
gdbtk_idle
}
@@ -188,7 +194,7 @@ itcl::body KodWin::display {} {
# ------------------------------------------------------------------
# METHOD: display_list - display list of objects
# ------------------------------------------------------------------
-itcl::body KodWin::display_list {} {
+body KodWin::display_list {} {
upvar \#0 $this table_vals
debug "displaying list of objects"
@@ -276,7 +282,7 @@ itcl::body KodWin::display_list {} {
# When called from update we have to reissue the gdb
# command to get fresh data
# ------------------------------------------------------------------
-itcl::body KodWin::display_object {{cmd ""} {obj ""}} {
+body KodWin::display_object {{cmd ""} {obj ""}} {
debug "Displaying object details..."
upvar $obj objects
global kodActivePane
@@ -343,7 +349,7 @@ itcl::body KodWin::display_object {{cmd ""} {obj ""}} {
# ------------------------------------------------------------------
# METHOD: clear - clear detail panes and reset pane selection
# ------------------------------------------------------------------
-itcl::body KodWin::clear {} {
+body KodWin::clear {} {
debug "going to clear detail panes and pane selection"
$t1 configure -state normal
$t2 configure -state normal
@@ -361,30 +367,30 @@ itcl::body KodWin::clear {} {
# ------------------------------------------------------------------
# METHOD: top - go to the list of types of objects (top level)
# ------------------------------------------------------------------
-itcl::body KodWin::top {} {
+body KodWin::top {} {
debug "going to top from level $level"
if {$level > 0} {
set level 0
- update dummy
+ update
}
}
# ------------------------------------------------------------------
# METHOD: up - go to the list of objects which led to the current one
# ------------------------------------------------------------------
-itcl::body KodWin::up {} {
+body KodWin::up {} {
debug "going up from level $level..."
if {$level > 0} {
incr level -1
debug "...to level $level"
- update dummy
+ update
}
}
# ------------------------------------------------------------------
# DESTRUCTOR - destroy window containing widget
# ------------------------------------------------------------------
-itcl::body KodWin::destructor {} {
+body KodWin::destructor {} {
upvar \#0 $this table_vals $this-pane1 pane1_vals $this-pane2 pane2_vals
global kodActivePane
@@ -392,49 +398,50 @@ itcl::body KodWin::destructor {} {
catch {unset pane1_vals}
catch {unset pane2_vals}
catch {unset kodActivePane}
+
+ remove_hook gdb_update_hook [code $this update]
+ remove_hook gdb_idle_hook [code $this idle]
+ remove_hook gdb_busy_hook [code $this busy]
+ remove_hook gdb_set_hook [code $this set_os]
}
# ------------------------------------------------------------------
-# PUBLIC METHOD: set_variable - called when user runs `set os'
-# command
+# METHOD: set - called when user runs `set os' command
# ------------------------------------------------------------------
-itcl::body KodWin::set_variable {event} {
-
- set value [$event get value]
- if {[$event get variable] == "os" && $value != ""} {
+body KodWin::set_os {var value} {
+ if {$var == "os" && $value != ""} {
set LevelCmd(0) "info $value "
set level 0
- update dummy
+ update
}
}
# ------------------------------------------------------------------
# METHOD: reconfig - used when preferences change
# ------------------------------------------------------------------
-itcl::body KodWin::reconfig {} {
+body KodWin::reconfig {} {
destroy $itk_interior.bf
destroy $titl
build_win
}
# ------------------------------------------------------------------
-# METHOD: busy - BusyEvent handler
+# METHOD: busy - gdb_busy_hook
#
# This method should accomplish blocking
# - clicks in the window
# - change mouse pointer
# ------------------------------------------------------------------
-itcl::body KodWin::busy {event} {
+body KodWin::busy {} {
set Running 1
_disable_buttons
cursor watch
}
# ------------------------------------------------------------------
-# METHOD: idle - idle event handler. Run when the target is not
-# running
+# METHOD: idle - idle hook. Run when the target is not running
# ------------------------------------------------------------------
-itcl::body KodWin::idle {event} {
+body KodWin::idle {} {
set Running 0
_restore_buttons
cursor {}
@@ -445,15 +452,15 @@ itcl::body KodWin::idle {event} {
# This is a convenience method which simply sets the mouse
# pointer to the given glyph.
# ------------------------------------------------------------------
-itcl::body KodWin::cursor {glyph} {
- $_top configure -cursor $glyph
+body KodWin::cursor {glyph} {
+ $Top configure -cursor $glyph
}
# ------------------------------------------------------------------
# PRIVATE METHOD: _disable_buttons - disable all buttons
# Used when we are busy and can't take another event
# ------------------------------------------------------------------
-itcl::body KodWin::_disable_buttons {} {
+body KodWin::_disable_buttons {} {
$BTop configure -state disabled
$BUp configure -state disabled
$BDisplay configure -state disabled
@@ -465,7 +472,7 @@ itcl::body KodWin::_disable_buttons {} {
# previous states.
# Used when we are busy and can't take another event
# ------------------------------------------------------------------
-itcl::body KodWin::_restore_buttons {} {
+body KodWin::_restore_buttons {} {
$BTop configure -state $BState(BTop)
$BUp configure -state $BState(BUp)
$BDisplay configure -state $BState(BDisplay)
diff --git a/gdb/gdbtk/library/kod.ith b/gdb/gdbtk/library/kod.ith
index f2dfefb3cdf..d66167007fc 100644
--- a/gdb/gdbtk/library/kod.ith
+++ b/gdb/gdbtk/library/kod.ith
@@ -1,5 +1,5 @@
-# Kernel Object Display Window definition for Insight.
-# Copyright (C) 1999, 2001 Red Hat, Inc.
+# Kernel Object Display Window definition for GDBtk.
+# Copyright (C) 1999 Cygnus Solutions
#
# This program is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License (GPL) as published by
@@ -11,7 +11,7 @@
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
-itcl::class KodWin {
+class KodWin {
inherit EmbeddedWin GDBWin
private {
@@ -36,28 +36,24 @@ itcl::class KodWin {
variable BState
variable Running 0
method build_win {}
+ method update {}
method display {}
method display_list {}
method display_object {{cmd ""} {obj ""}}
method clear {}
method top {}
method up {}
+ method busy {}
+ method idle {}
method cursor {glyph}
method _disable_buttons {}
method _restore_buttons {}
+ method set_os {var value}
}
public {
method constructor {args}
method destructor {}
method reconfig {}
-
- #
- # Gdb Events
- #
- method set_variable {event}
- method busy {event}
- method idle {event}
- method update {event}
}
}
diff --git a/gdb/gdbtk/library/locals.tcl b/gdb/gdbtk/library/locals.tcl
index 8d7fde949a4..50bd9aeced3 100644
--- a/gdb/gdbtk/library/locals.tcl
+++ b/gdb/gdbtk/library/locals.tcl
@@ -1,5 +1,5 @@
-# Local Variable Window for Insight.
-# Copyright (C) 2002, 2003, 2006 Red Hat
+# Local variable window for GDBtk.
+# Copyright 1997, 1998, 1999 Cygnus Solutions
#
# This program is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License (GPL) as published by
@@ -12,159 +12,112 @@
# GNU General Public License for more details.
-# ----------------------------------------------------------------------
-# Implements local variables windows for gdb.
-# ----------------------------------------------------------------------
-
-itcl::class LocalsWin {
- inherit EmbeddedWin GDBWin
- # ------------------------------------------------------------------
- # CONSTRUCTOR - create new locals window
- # ------------------------------------------------------------------
- constructor {args} {
- debug
-
- gdbtk_busy
- build_win $itk_interior
- gdbtk_idle
-
- add_hook gdb_no_inferior_hook "$this no_inferior"
- add_hook gdb_clear_file_hook [code $this clear_file]
- add_hook file_changed_hook [code $this clear_file]
-
- update dummy
- }
-
-
- # ------------------------------------------------------------------
- # PUBLIC METHOD: busy - BusyEvent handler
- # Disable all ui elements that could affect gdb's state
- # ------------------------------------------------------------------
- method busy {event} {
- debug
- cursor watch
- }
-
- # Re-enable the UI
- method idle {event} {
- debug
- cursor {}
- }
-
- # ------------------------------------------------------------------
- # METHOD: no_inferior
- # Reset this object.
- # ------------------------------------------------------------------
- method no_inferior {} {
- debug
- cursor {}
- catch {delete object $_frame}
- set _frame {}
- $tree remove all
- }
-
- # ------------------------------------------------------------------
- # METHOD: cursor - change the toplevel's cursor
- # ------------------------------------------------------------------
- method cursor {what} {
- [winfo toplevel [namespace tail $this]] configure -cursor $what
- ::update idletasks
- }
-
-
- # ------------------------------------------------------------------
- # METHOD: build_win - build window for variables.
- # ------------------------------------------------------------------
- method build_win {f} {
- #debug "$f"
-
- set tree [VarTree $f.tree -type "local"]
- pack $f.tree -expand yes -fill both
- pack $f -expand yes -fill both
-
- window_name "Local Variables"
- ::update idletasks
- }
-
-
- # ------------------------------------------------------------------
- # METHOD: clear_file - Clear out state so that a new executable
- # can be loaded. For LocalWins, this means doing
- # everything that no_inferior does.
- # ------------------------------------------------------------------
- method clear_file {} {
- no_inferior
- }
-
- # ------------------------------------------------------------------
- # DESTRUCTOR - delete locals window
- # ------------------------------------------------------------------
- destructor {
- debug
- set tree {}
-
- # Remove this window and all hooks
- remove_hook gdb_no_inferior_hook "$this no_inferior"
- remove_hook gdb_clear_file_hook [code $this clear_file]
- remove_hook file_changed_hook [code $this clear_file]
- }
-
- method context_switch {} {
- debug
-
- set err [catch {gdb_selected_frame} current_frame]
- #debug "1: err=$err; _frame=\"$_frame\"; current_frame=\"$current_frame\""
-
- if {$err && $_frame != ""} {
- # No current frame
- debug "no current frame"
- catch {delete object $_frame}
- set _frame {}
- return 1
- } elseif {$current_frame == "" && $_frame == ""} {
- #debug "2"
- return 0
- } elseif {$_frame == "" || $current_frame != [$_frame address]} {
- # We've changed frames. If we knew something about
- # the stack layout, we could be more intelligent about
- # destroying variables, but we don't know that here (yet).
- debug "switching to frame at $current_frame"
-
- # Destroy the old frame and create the new one
- catch {destroy $_frame}
- set _frame [Frame ::\#auto $current_frame]
- debug "created new frame: $_frame at [$_frame address]"
- return 1
+class LocalsWin {
+ inherit VariableWin
+
+ # ------------------------------------------------------------------
+ # CONSTRUCTOR - create new locals window
+ # ------------------------------------------------------------------
+ constructor {args} {
+ update
+ }
+
+ # ------------------------------------------------------------------
+ # DESTRUCTOR - delete locals window
+ # ------------------------------------------------------------------
+ destructor {
+ }
+
+ method build_win {f} {
+ global tcl_platform
+ build_menu_helper Variable
+ if {$tcl_platform(platform) == "windows"} {
+ frame $f.f
+ VariableWin::build_win $f.f
+ pack $f.f -expand yes -fill both -side top
+ frame $f.stat
+ pack $f.stat -side bottom -fill x
+ } else {
+ VariableWin::build_win $f
+ }
+ }
+
+
+ # ------------------------------------------------------------------
+ # METHOD: reconfig
+ # Overrides VarialbeWin::reconfig method. Have to make sure the locals
+ # will get redrawn after everything is destroyed...
+ # ------------------------------------------------------------------
+ method reconfig {} {
+ VariableWin::reconfig
+ populate {}
+ }
+
+ # ------------------------------------------------------------------
+ # METHOD: getVariablesBlankPath
+ # Overrides VarialbeWin::getVariablesBlankPath. For a Locals Window,
+ # this method returns a list of local variables.
+ # ------------------------------------------------------------------
+ method getVariablesBlankPath {} {
+ global Update
+ debug "LocalsWin::getVariablesBlankPath"
+
+ return [$_frame variables]
+ }
+
+ method update {} {
+ global Update Display
+
+ debug "START LOCALS UPDATE CALLBACK"
+ # Check that a context switch has not occured
+ if {[context_switch]} {
+ debug "CONTEXT SWITCH"
+
+ # our context has changed... repopulate with new variables
+ # destroy the old tree and create a new one
+ #
+ # We need to be more intelligent about saving window state
+ # when browsing the stack or stepping into new frames, but
+ # for now, we'll have to settle for just getting this working.
+ deleteTree
+ set ChangeList {}
+
+ # context_switch will have already created the new frame for
+ # us, so all we need to do is shove stuff into the window.
+ debug "_frame=$_frame"
+ if {$_frame != ""} {
+ debug "vars=[$_frame variables]"
+ }
+ if {$_frame != "" && [$_frame variables] != ""} {
+ populate {}
+ }
+ }
+
+ # Erase old variables
+ if {$_frame != ""} {
+ foreach var [$_frame old] {
+ $Hlist delete entry $var
+ $_frame deleteOld
+ unset Update($this,$var)
+ }
+
+ # Add new variables
+ foreach var [$_frame new] {
+ set Update($this,$var) 1
+ $Hlist add $var \
+ -itemtype text \
+ -text [label $var]
+ if {[$var numChildren] > 0} {
+ # Make sure we get this labeled as openable
+ $Tree setmode $var open
+ }
+ }
+ }
+
+ # Update variables in window
+ VariableWin::update
+
+ debug "END LOCALS UPDATE CALLBACK"
}
-
- # Nothing changed
- #debug "3"
- return 0
- }
-
-
- method update {event} {
- debug
-
- # Check that a context switch has not occured
- if {[context_switch]} {
- debug "CONTEXT SWITCH"
-
- # delete variables in tree
- $tree remove all
-
- if {$_frame != ""} {
- $tree add [$_frame variables]
- }
- } else {
- if {$_frame == ""} {return}
- # check for any new variables in the same frame
- $tree add [$_frame new]
- }
- after idle [code $tree update]
- }
-
- protected variable Entry
- protected variable tree
- protected variable _frame {}
}
+
diff --git a/gdb/gdbtk/library/main.tcl b/gdb/gdbtk/library/main.tcl
index 9be258eb6e5..7b18e5ab2c3 100644
--- a/gdb/gdbtk/library/main.tcl
+++ b/gdb/gdbtk/library/main.tcl
@@ -1,5 +1,5 @@
# GDBtk (Insight) entry point
-# Copyright (C) 1997, 1998, 1999, 2002, 2003, 2004, 2008 Red Hat, Inc.
+# Copyright 1997, 1998, 1999 Cygnus Solutions
#
# This program is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License (GPL) as published by
@@ -28,67 +28,36 @@
#set tcl_traceCompile 1
# Add gdb's Tcl library directory to the end of the auto-load search path, if
-# it isn't already on the path.
-# Also, add the plugins directory if it exists.
+# it isn't already on the path:
# Note: GDBTK_LIBRARY will be set in tcl_findLibrary before main.tcl is called.
-set gdb_plugins ""
if {[info exists auto_path]} {
if {[lsearch -exact $auto_path $GDBTK_LIBRARY] < 0} {
lappend auto_path $GDBTK_LIBRARY
}
-
- # Add default plugins directory, which will be [name of exe]/../../lib/insight1.0
- set exename [info nameofexecutable]
- set dir [file join [file dirname [file dirname $exename]] lib insight1.0]
- if {[file exists $dir]} {
- lappend gdb_plugins $dir
- lappend auto_path $dir
- }
- # Add any user-specified plugins directories
- if {[info exists env(INSIGHT_PLUGINS)]} {
- set dirs [split $env(INSIGHT_PLUGINS) :]
- lappend gdb_plugins $dirs
- lappend auto_path $dirs
- }
}
-
# Require the packages we need. Most are loaded already, but this will catch
# any odd errors... :
-
-foreach p {{Tcl 8.0} {Tk 8.0} {Itcl 3.0} {Itk 3.0} {Gdbtk 1.0} {combobox 2.2} {debug 1.0}} {
- if {[catch {package require [lindex $p 0] [lindex $p 1]} msg]} {
- if {![info exists ::env(GDBTK_TEST_RUNNING)] || $::env(GDBTK_TEST_RUNNING) == 0} {
- if {$::tcl_platform(platform) != "windows"} {
- puts stderr "Error: $msg"
- }
- catch {tk_messageBox -title Error -message $msg -icon error -type ok}
- }
- exit -1
- } else {
- #puts "Loaded [lindex $p 0] $msg"
- }
-}
+package require Tcl 8.0
+package require Tk 8.0
+package require Itcl 3.0
+package require Itk 3.0
+package require Gdbtk 1.0
+package require combobox 1.0
namespace import itcl::*
+
namespace import debug::*
-# Finally, load Iwidgets
-if {[info exists IWIDGETS_LIBRARY]} {
- lappend auto_path $IWIDGETS_LIBRARY
-}
-if {[catch {package require Iwidgets} msg]} {
- if {![info exists ::env(GDBTK_TEST_RUNNING)] || $::env(GDBTK_TEST_RUNNING) == 0} {
- if {$::tcl_platform(platform) != "windows"} {
- puts stderr "Error: $msg"
- }
- catch {tk_messageBox -title Error -message $msg -icon error -type ok}
- }
- exit -1
+if {![find_iwidgets_library]} {
+ tk_messageBox -title Error -message "Could not find the Iwidgets libraries.
+Got nameofexec: [info nameofexecutable]
+Error(s) were: \n$errMsg" \
+ -icon error -type ok
+ exit
}
-
# Environment variables controlling debugging:
# GDBTK_TRACE
# unset or 0 no tracing
@@ -116,36 +85,18 @@ if {[info exists env(GDBTK_TRACE)] && $env(GDBTK_TRACE) != 0} {
}
}
-if {[info exists env(GDBTK_DEBUG)] && $env(GDBTK_DEBUG) != 0} {
- if {[info exists env(GDBTK_DEBUGFILE)]} {
- ::debug::logfile $env(GDBTK_DEBUGFILE)
- } else {
- ::debug::logfile "insight.log"
- }
+if {[info exists env(GDBTK_DEBUGFILE)]} {
+ ::debug::logfile $env(GDBTK_DEBUGFILE)
}
-# For testing
-set _test(interactive) 0
-
-# Set up platform globals. We replace Tcl's tcl_platform with
-# our own version which knows the difference between cygwin and
-# mingw.
-global gdbtk_platform
-set gdbtk_platform(platform) $tcl_platform(platform)
-switch $tcl_platform(platform) {
- windows {
- if {[llength [info commands ide_cygwin_path]] == 0} {
- set gdbtk_platform(os) "mingw"
- } else {
- set gdbtk_platform(os) "cygwin"
- }
- }
-
- default {
- set gdbtk_platform(os) $tcl_platform(os)
- }
+if {$tcl_platform(platform) == "unix"} {
+# tix resetoptions TK TK
+# tk_setPalette tan
+ tix resetoptions TixGray [tix cget -fontset]
}
-set gdbtk_platform(osVersion) $tcl_platform(osVersion)
+
+# initialize state variables
+initialize_gdbtk
# set traces on state variables
trace variable gdb_running w do_state_hook
@@ -167,12 +118,6 @@ pref_read
init_disassembly_flavor
-# initialize state variables
-initialize_gdbtk
-
-# Arrange for session code to notice when file changes.
-add_hook file_changed_hook Session::notice_file_change
-
ManagedWin::init
# This stuff will help us play nice with WindowMaker's AppIcons.
@@ -180,6 +125,13 @@ ManagedWin::init
# wm command . [concat $argv0 $argv]
wm group . .
+# Open debug window if testsuite is not running and GDBTK_DEBUG is set
+if {![info exists env(GDBTK_TEST_RUNNING)] || !$env(GDBTK_TEST_RUNNING)} {
+ if {[info exists env(GDBTK_DEBUG)] && $env(GDBTK_DEBUG) > 1} {
+ ManagedWin::open DebugWin
+ }
+}
+
# some initial commands to get gdb in the right mode
gdb_cmd {set height 0}
gdb_cmd {set width 0}
@@ -200,12 +152,5 @@ update
# Uncomment the next line if you want a splash screen at startup...
# ManagedWin::open About -transient -expire 5000
-# initialize IPC to enable multiple Insight's to communicate
-# with each other.
-set iipc 0
-if {[pref get gdb/ipc/enabled]} {
- set ::insight_ipc [Iipc \#auto]
-}
-
gdbtk_idle
diff --git a/gdb/gdbtk/library/managedwin.itb b/gdb/gdbtk/library/managedwin.itb
index 6a651961805..3dbb635b28d 100644
--- a/gdb/gdbtk/library/managedwin.itb
+++ b/gdb/gdbtk/library/managedwin.itb
@@ -1,5 +1,5 @@
-# Managed window for Insight.
-# Copyright (C) 1998, 1999, 2000, 2001, 2002, 2004, 2008 Red Hat, Inc.
+# Managed window for GDBtk.
+# Copyright 1998, 1999 Cygnus Solutions
#
# This program is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License (GPL) as published by
@@ -12,178 +12,48 @@
# GNU General Public License for more details.
-# ------------------------------------------------------------
-# PUBLIC METHOD: constructor
-# ------------------------------------------------------------
-itcl::body ManagedWin::constructor {args} {
- #debug "$this args=$args"
- set _top [winfo toplevel $itk_interior]
-}
-
-# ------------------------------------------------------------
-# PUBLIC METHOD: destructor
-# ------------------------------------------------------------
-itcl::body ManagedWin::destructor {} {
- # If no toplevels remain, quit. However, check the quit_if_last
- # flag since we might be doing something like displaying a
- # splash screen at startup...
-
- if {!$numTopWins && [quit_if_last]} {
- if {$::iipc && [pref get gdb/ipc/exit]} {
- $::insight_ipc send quit
- }
- gdb_force_quit
- } else {
- destroy_toplevel
- }
-}
+body ManagedWin::reconfig {} {}
-# ------------------------------------------------------------
-# PUBLIC METHOD: window_name - Set the name of the window
-# (and optionally its icon's name).
-# ------------------------------------------------------------
-itcl::body ManagedWin::window_name {wname {iname ""}} {
- if {$wname != ""} {
- set _wname $wname
- } else {
- set wname $_wname
- }
- if {$iname != ""} {
- set _iname $iname
- } else {
- set iname $_iname
- }
-
- if {$win_instance != ""} {
- append wname " \[$win_instance\]"
- if {$iname != ""} {
- append iname " \[$win_instance\]"
- }
- }
- wm title $_top $wname
+body ManagedWin::window_name {wname {iname ""}} {
+ set top [winfo toplevel [namespace tail $this]]
+ wm title $top $wname
if {$iname != ""} {
- wm iconname $_top $iname
+ wm iconname $top $iname
} else {
- wm iconname $_top $wname
+ wm iconname $top $wname
}
}
-# ------------------------------------------------------------
-# PUBLIC METHOD: window_instance - Set the string to be
-# appended to each window title for this instance of Insight
-# ------------------------------------------------------------
-itcl::body ManagedWin::window_instance {ins} {
- set win_instance $ins
- foreach obj [itcl_info objects -isa ManagedWin] {
- debug "$obj ManagedWin::_wname"
- $obj window_name ""
- }
-}
-# ------------------------------------------------------------
-# PUBLIC METHOD: pickle - This is the base class pickle
-# method. It returns a command that can be used to recreate
-# this particular window.
-# ------------------------------------------------------------
-itcl::body ManagedWin::pickle {} {
- return [list ManagedWin::open [namespace tail [info class]]]
-}
-
-# ------------------------------------------------------------
-# PUBLIC METHOD: reveal
-# ------------------------------------------------------------
-itcl::body ManagedWin::reveal {} {
+body ManagedWin::reveal {} {
# Do this update to flush all changes before deiconifying the window.
update idletasks
- raise $_top
- wm deiconify $_top
-
- # Some window managers (on unix) fail to honor the geometry unless
- # the window is visible.
- if {[info exists ::$_top._init_geometry]} {
- upvar ::$_top._init_geometry gm
- if {$::gdbtk_platform(platform) == "unix"} {
- wm geometry $_top $gm
- }
- unset ::$_top._init_geometry
- }
+ set top [winfo toplevel [namespace tail $this]]
+ wm deiconify $top
- # There used to be a `focus -force' here, but using -force is
- # unfriendly, so it was removed. It was then replaced with a simple
- # `focus $top'. However, this has no useful effect -- it just
- # resets the subwindow of $top which has the `potential' focus.
- # This can actually be confusing to the user.
-
- # NOT for Windows, though. Without the focus, we get, eg. a
- # register window on top of the source window, but the source window
- # will have the focus. This is not the proper model for Windows.
- if {$::gdbtk_platform(platform) == "windows"} {
- focus -force [focus -lastfor $_top]
- }
+ # I don't understand this next line and no one commented it, so it's gone.
+ #focus -force [focus -lastfor $top]
+
+ focus $top
+ raise $top
}
-# ------------------------------------------------------------
-# PUBLIC PROC: restart
-# ------------------------------------------------------------
-itcl::body ManagedWin::restart {} {
+body ManagedWin::restart {} {
# This is needed in case we've called "gdbtk_busy" before the restart.
# This will configure the stop/run button as necessary
after idle gdbtk_idle
# call the reconfig method for each object
- foreach obj [itcl_info objects -isa ManagedWin] {
+ foreach obj $manage_active {
if {[catch {$obj reconfig} msg]} {
dbug W "reconfig failed for $obj - $msg"
}
}
}
-# ------------------------------------------------------------------
-# PUBLIC PROC: shutdown - This writes all the active windows to
-# the preferences file, so they can be restored at startup.
-# FIXME: Currently assumes only ONE window per type...
-# ------------------------------------------------------------------
-itcl::body ManagedWin::shutdown {} {
- set activeWins {}
- foreach win [itcl_info objects -isa ManagedWin] {
- if {![$win isa ModalDialog] && ![$win _ignore_on_save]} {
- set g [wm geometry [winfo toplevel [namespace tail $win]]]
- pref setd gdb/geometry/[namespace tail $win] $g
- lappend activeWins [$win pickle]
- }
- }
- pref set gdb/window/active $activeWins
-}
-
-# ------------------------------------------------------------------
-# PUBLIC PROC: startup - This restores all the windows that were
-# opened at shutdown.
-# FIXME: Currently assumes only ONE window per type...
-# ------------------------------------------------------------------
-itcl::body ManagedWin::startup {} {
- debug "Got active list [pref get gdb/window/active]"
-
- foreach cmd [pref get gdb/window/active] {
- eval $cmd
- }
- # If we open the source window, and a source window already exists,
- # then we end up raising it twice during startup. This yields an
- # annoying effect for the user: if the user tries the bury the
- # source window during startup, it will raise itself again. This
- # explains why we first check to see if a source window exists
- # before trying to create it -- raising the window is an inevitable
- # side effect of the creation process.
- if {[llength [find SrcWin]] == 0} {
- ManagedWin::open SrcWin
- }
-}
-
-# ------------------------------------------------------------
-# PUBLIC PROC: open_dlg
-# ------------------------------------------------------------
-itcl::body ManagedWin::open_dlg {class args} {
+body ManagedWin::open_dlg {class args} {
set newwin [eval _open $class $args]
if {$newwin != ""} {
@@ -192,16 +62,13 @@ itcl::body ManagedWin::open_dlg {class args} {
}
}
-# ------------------------------------------------------------
-# PUBLIC PROC: open
-# ------------------------------------------------------------
-itcl::body ManagedWin::open {class args} {
+
+body ManagedWin::open {class args} {
set newwin [eval _open $class $args]
if {$newwin != ""} {
if {[$newwin isa ModalDialog]} {
- parse_args [list {expire 0}]
- after idle "$newwin reveal; $newwin post 0 $expire"
+ after idle "$newwin reveal; $newwin post"
} else {
after idle "$newwin reveal"
}
@@ -210,17 +77,14 @@ itcl::body ManagedWin::open {class args} {
return $newwin
}
-# ------------------------------------------------------------
-# PRIVATE PROC: _open
-# ------------------------------------------------------------
-itcl::body ManagedWin::_open { class args } {
+body ManagedWin::_open { class args } {
debug "$class $args"
parse_args force
-
+
if {!$force} {
# check all windows for one of this type
- foreach obj [itcl_info objects -isa ManagedWin] {
+ foreach obj $manage_active {
if {[$obj isa $class]} {
$obj reveal
return $obj
@@ -232,10 +96,7 @@ itcl::body ManagedWin::_open { class args } {
return [eval _create $class $args]
}
-# ------------------------------------------------------------
-# PRIVATE PROC: _create
-# ------------------------------------------------------------
-itcl::body ManagedWin::_create { class args } {
+body ManagedWin::_create { class args } {
set win [string tolower $class]
debug "win=$win args=$args"
@@ -274,34 +135,31 @@ itcl::body ManagedWin::_create { class args } {
return ""
}
- wm maxsize $top $_screenwidth $_screenheight
+ wm maxsize $top $screenwidth $screenheight
wm minsize $top 20 20
- update idletasks
-
+
if {$over != ""} {
- # center new window
- center_window $top -over [winfo toplevel [namespace tail $over]]
+ # center new window over widget
+ set t [winfo toplevel [namespace tail $over]]
+ set cx [expr {[winfo rootx $t] + [winfo width $t] / 2}]
+ set cy [expr {[winfo rooty $t] + [winfo height $t] / 2}]
+ set x [expr {$cx - [winfo reqwidth $top] / 2}]
+ set y [expr {$cy - [winfo reqheight $top] / 2}]
+ wm geometry $top +$x+$y
} elseif {$center} {
- center_window $top
+ # center the window on the screen
+ set x [expr {[winfo screenwidth $top] / 2 - [winfo reqwidth $top] / 2}]
+ set y [expr {[winfo screenheight $top] / 2 - [winfo reqheight $top] / 2}]
+ wm geometry $top +$x+$y
}
-
+
if {$transient} {
wm resizable $top 0 0
-
- # If a SrcWin is around, use its toplevel as the master for
- # the transient. Otherwise use ".". (The splash screen will
- # need ".", for example.)
- set srcs [ManagedWin::find SrcWin]
- if {[llength $srcs] > 0} {
- set w [winfo toplevel [namespace tail [lindex $srcs 0]]]
- } else {
- set w .
- }
- wm transient $top $w
- } elseif {$::gdbtk_platform(platform) == "unix"} {
+ wm transient $top .
+ } elseif {$::tcl_platform(platform) == "unix"} {
# Modal dialogs DONT get Icons...
if {[pref get gdb/use_icons] && ![$newwin isa ModalDialog]} {
- set icon [_make_icon_window ${top}_icon]
+ set icon [make_icon_window ${top}_icon]
wm iconwindow $top $icon
bind $icon <Double-1> "$newwin reveal"
}
@@ -324,10 +182,10 @@ itcl::body ManagedWin::_create { class args } {
set w 0; set h 0; set x 0; set y 0
if {![catch {scan $g "%dx%d%d%d" w h x y} res]} {
if {$x < 0} {
- set x [expr $_screenwidth + $x]
+ set x [expr $screenwidth + $x]
}
if {$y < 0} {
- set y [expr $_screenheight + $y]
+ set y [expr $screenheight + $y]
}
# If the window is transient, then don't reset its size, since
@@ -343,10 +201,9 @@ itcl::body ManagedWin::_create { class args } {
} else {
set g "${w}x${h}+${x}+${y}"
}
- if {[expr $x+50] < $_screenwidth && [expr $y+20] < $_screenheight} {
- wm positionfrom $top user
+ if {[expr $x+50] < $screenwidth && [expr $y+20] < $screenheight} {
wm geometry $top $g
- set ::$top._init_geometry $g
+ wm positionfrom $top user
}
}
}
@@ -357,13 +214,10 @@ itcl::body ManagedWin::_create { class args } {
return $newwin
}
-# ------------------------------------------------------------
-# PUBLIC PROC: find
-# ------------------------------------------------------------
-itcl::body ManagedWin::find { win } {
+body ManagedWin::find { win } {
debug "$win"
set res ""
- foreach obj [itcl_info objects -isa ManagedWin] {
+ foreach obj $manage_active {
if {[$obj isa $win]} {
lappend res $obj
}
@@ -371,44 +225,38 @@ itcl::body ManagedWin::find { win } {
return $res
}
-# ------------------------------------------------------------
-# PUBLIC PROC: init
-# ------------------------------------------------------------
-itcl::body ManagedWin::init {} {
+body ManagedWin::enable { on } {
+}
+
+
+body ManagedWin::init {} {
+ debug
wm withdraw .
- set _screenheight [winfo screenheight .]
- set _screenwidth [winfo screenwidth .]
+ set screenheight [winfo screenheight .]
+ set screenwidth [winfo screenwidth .]
}
-# ------------------------------------------------------------
-# PUBLIC METHOD: destroy_toplevel
-# ------------------------------------------------------------
-itcl::body ManagedWin::destroy_toplevel {} {
- after idle "update idletasks;destroy $_top"
+body ManagedWin::destroy_toplevel {} {
+ after idle "update idletasks;destroy $Top"
}
-# ------------------------------------------------------------
-# PROTECTED METHOD: _freeze_me
-# ------------------------------------------------------------
-itcl::body ManagedWin::_freeze_me {} {
- $_top configure -cursor watch
+body ManagedWin::freeze_me {} {
+ $Top configure -cursor watch
::update idletasks
}
-# ------------------------------------------------------------
-# PROTECTED METHOD: _thaw_me
-# ------------------------------------------------------------
-itcl::body ManagedWin::_thaw_me {} {
+body ManagedWin::thaw_me {} {
- $_top configure -cursor {}
+ $Top configure -cursor {}
::update idletasks
}
# ------------------------------------------------------------------
-# PRIVATE PROC: _make_icon_window - create a small window with an
-# icon in it for use by certain Unix window managers.
+# make_icon_window - create a small window with an icon in
+# it for use by certain Unix window managers.
# ------------------------------------------------------------------
-itcl::body ManagedWin::_make_icon_window {name {file "gdbtk_icon"}} {
+
+body ManagedWin::make_icon_window {name {file "gdbtk_icon"}} {
if {![winfo exists $name]} {
toplevel $name
label $name.im -image \
diff --git a/gdb/gdbtk/library/managedwin.ith b/gdb/gdbtk/library/managedwin.ith
index aae0a676108..a25cee41e9a 100644
--- a/gdb/gdbtk/library/managedwin.ith
+++ b/gdb/gdbtk/library/managedwin.ith
@@ -1,5 +1,5 @@
# Managed window class definition for GDBtk.
-# Copyright (C) 1998, 1999, 2000, 2001 Red Hat, Inc.
+# Copyright 1998, 1999 Cygnus Solutions
#
# This program is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License (GPL) as published by
@@ -12,61 +12,91 @@
# GNU General Public License for more details.
-itcl::class ManagedWin {
+class ManagedWin {
inherit itk::Widget
public {
- method constructor {args}
- method destructor {}
-
- method reconfig {} {}
+ method reconfig {}
method destroy_toplevel {}
method quit_if_last {} {return 1}
- method pickle {}
+ method enable {on}
method reveal {}
method window_name {wname {iname ""}}
- proc window_instance {ins}
+ variable nosize 0
+
proc find {win}
- proc open {class args}
+ proc open {args}
proc open_dlg {class args}
proc init {}
proc restart {}
- proc startup {}
- proc shutdown {}
-
- common win_instance ""
}
protected {
- # The Tk's toplevel window for this ManagedWin
- variable _top
+ proc dont_remember_size {} {
+ return 0
+ }
+ method freeze_me {}
+ method thaw_me {}
- # Variable which holds the geometry of this window
- variable _geometry {}
+ variable Top
+ }
+
+ private {
+ proc _create {class args}
+ proc _open {class args}
+ proc make_icon_window {name {file "gdbtk_icon"}}
+ }
+
+ protected {
+ # manage_active - list of active window objects
+ common manage_active ""
# this is the counter of TopLevelWins open
# when it hits 0, exit.
common numTopWins 0
- common _screenwidth
- common _screenheight
+ common screenwidth
+ common screenheight
+ common mainwindow
+ }
- method _freeze_me {}
- method _thaw_me {}
+ constructor {args} {
+ debug "$this args=$args"
+ lappend manage_active $this
+ set Top [winfo toplevel $itk_interior]
+
+ }
- # Should this window be reopened when we startup?
- method _ignore_on_save {} { return 0 }
+ destructor {
- # Should this window's size be remembered?
- proc dont_remember_size {} { return 0 }
- }
+ set infoList [after info]
+
+ # remove object from list
+ set i [lsearch -exact $manage_active $this]
+ if {$i != -1} {
+ set manage_active [lreplace $manage_active $i $i]
+ }
+
+ # save geometry
+ set g [wm geometry [winfo toplevel [namespace tail $this]]]
+ pref setd gdb/geometry/[namespace tail $this] $g
+
+ # If no toplevels remain, quit. However, check the quit_if_last
+ # flag since we might be doing something like displaying a
+ # splash screen at startup...
+
+ if {!$numTopWins && [quit_if_last]} {
+ # save window positions of remaining windows
+ foreach obj $manage_active {
+ set g [wm geometry [winfo toplevel [namespace tail $obj]]]
+ pref setd gdb/geometry/[namespace tail $obj] $g
+ }
+ pref_save
+ gdb_force_quit
+ } else {
+ destroy_toplevel
+ }
+ }
- private {
- proc _create {class args}
- proc _open {class args}
- proc _make_icon_window {name {file "gdbtk_icon"}}
- variable _wname {}
- variable _iname {}
- }
}
diff --git a/gdb/gdbtk/library/mempref.itb b/gdb/gdbtk/library/mempref.itb
index 85937c7aabd..74be3a925fc 100644
--- a/gdb/gdbtk/library/mempref.itb
+++ b/gdb/gdbtk/library/mempref.itb
@@ -1,5 +1,5 @@
-# Memory display preferences window for Insight.
-# Copyright (C) 1998, 1999, 2002, 2003, 2006 Red Hat
+# Memory display preferences window for GDBtk.
+# Copyright 1998, 1999 Cygnus Solutions
#
# This program is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License (GPL) as published by
@@ -15,7 +15,7 @@
# ------------------------------------------------------------------
# METHOD: constructor - build the dialog
# ------------------------------------------------------------------
-itcl::body MemPref::constructor {args} {
+body MemPref::constructor {args} {
window_name "Memory Preferences"
@@ -41,7 +41,6 @@ itcl::body MemPref::constructor {args} {
set gnumbytes $numbytes
set gbpr $bpr
- set gbprlist [list 4 8 16 32 64 128]
set gascii $ascii
set gascii_char $ascii_char
@@ -58,14 +57,14 @@ itcl::body MemPref::constructor {args} {
# ------------------------------------------------------------------
# METHOD: destructor - destroy the dialog
# ------------------------------------------------------------------
-itcl::body MemPref::destructor {} {
+body MemPref::destructor {} {
trace vdelete [scope gnumbytes] w [code $this check_numbytes]
}
# ------------------------------------------------------------------
# METHOD: build_win - build the dialog
# ------------------------------------------------------------------
-itcl::body MemPref::build_win {} {
+body MemPref::build_win {} {
frame $itk_interior.f
set f [frame $itk_interior.f.a]
@@ -154,12 +153,14 @@ itcl::body MemPref::build_win {} {
label $fr.2.l -text "Bytes Per Row "
set Widgets(b-bytes_per_row) [::combobox::combobox $fr.2.c \
-command [code $this set_bytes_per_row] \
- -width 4 -editable 1 -font global/fixed \
- -bg $::Colors(textbg)]
- foreach item $gbprlist {
- $fr.2.c list insert end $item
- }
- $fr.2.c configure -value $gbpr
+ -width 4 -editable 0 -font src-font]
+ $fr.2.c list insert end 4
+ $fr.2.c list insert end 8
+ $fr.2.c list insert end 16
+ $fr.2.c list insert end 32
+ $fr.2.c list insert end 64
+ $fr.2.c list insert end 128
+ $fr.2.c configure -value 16
pack $fr.2.l -side left -anchor e
pack $fr.2.c -side right
@@ -204,7 +205,7 @@ itcl::body MemPref::build_win {} {
# ------------------------------------------------------------------
# METHOD: busy - make the widget unusable
# ------------------------------------------------------------------
-itcl::body MemPref::busy {} {
+body MemPref::busy {} {
set top [winfo toplevel $itk_interior]
$top configure -cursor watch
@@ -220,7 +221,7 @@ itcl::body MemPref::busy {} {
# ------------------------------------------------------------------
# METHOD: idle - make the widget useable
# ------------------------------------------------------------------
-itcl::body MemPref::idle {} {
+body MemPref::idle {} {
set top [winfo toplevel $itk_interior]
$top configure -cursor {}
@@ -232,7 +233,7 @@ itcl::body MemPref::idle {} {
# ------------------------------------------------------------------
# METHOD: ok - apply and quit
# ------------------------------------------------------------------
-itcl::body MemPref::ok {} {
+body MemPref::ok {} {
apply
unpost
}
@@ -240,14 +241,14 @@ itcl::body MemPref::ok {} {
# ------------------------------------------------------------------
# METHOD: cancel - just close the dialog w/o saving changes
# ------------------------------------------------------------------
-itcl::body MemPref::cancel {} {
+body MemPref::cancel {} {
unpost
}
# ------------------------------------------------------------------
# METHOD: check_numbytes - a trace to make sure gnumbytes is an int > 0
# ------------------------------------------------------------------
-itcl::body MemPref::check_numbytes {var index mode} {
+body MemPref::check_numbytes {var index mode} {
upvar \#0 $var true
if {($true != "") && ([catch {expr {(int($true) != double($true)) || $true <= 0}} val]
|| $val)} {
@@ -261,44 +262,15 @@ itcl::body MemPref::check_numbytes {var index mode} {
# ------------------------------------------------------------------
# METHOD: set_bytes_per_row - combobox callback to set the bytes per row
# ------------------------------------------------------------------
-itcl::body MemPref::set_bytes_per_row {w value} {
- if {[string is integer -strict $value] && [expr {$value != 0}]} {
- # The input is a value number.
- set gbpr $value
- set gbpr [string trim $gbpr]
-
- # Too high a number will cause a Segmentation fault.
- if {[expr {$gbpr > 150}]} {set gbpr 150}
-
- # Insert the value into the combo box list, if it isn't there already.
- set found [lsearch $gbprlist $gbpr]
-
- if {$found == -1} {
- lappend gbprlist $gbpr
- $Widgets(b-bytes_per_row) list insert end $gbpr
- }
-
- set s $gsize
- if {$s == 3} {set s 4}
- if {$s == 5} {set s 8}
- set rem [expr {$gbpr % $s}]
- if {$rem != 0} {
- # The bytes-per-row is not a multiple of the size.
- set gbpr [expr {$gbpr + ($s - $rem)}]
- }
- }
-
- # Set the display to the new value. This may be different if the input
- # was zero or not a number, or if the user entered any whitespace.
- $Widgets(b-bytes_per_row) delete 0 end
- $Widgets(b-bytes_per_row) insert end $gbpr
+body MemPref::set_bytes_per_row {w value} {
+ set gbpr $value
}
# ------------------------------------------------------------------
# METHOD: toggle_size_control - toggle the state of the entry box as the
# control method changes
# ------------------------------------------------------------------
-itcl::body MemPref::toggle_size_control {} {
+body MemPref::toggle_size_control {} {
if {$gvar} {
$Widgets(e-numbytes) configure -state normal \
@@ -314,7 +286,7 @@ itcl::body MemPref::toggle_size_control {} {
# ------------------------------------------------------------------
# METHOD: apply - apply changes to the parent window
# ------------------------------------------------------------------
-itcl::body MemPref::apply {} {
+body MemPref::apply {} {
busy
gdbtk_busy
@@ -345,9 +317,6 @@ itcl::body MemPref::apply {} {
}
}
- # Ensure the value has been read from the text field.
- set_bytes_per_row "" [$Widgets(b-bytes_per_row) get]
-
# pass all the changed values back to parent
debug "$win configChange -size $size -numbytes $numbytes \
-format $format -ascii $gascii \
@@ -367,11 +336,7 @@ itcl::body MemPref::apply {} {
# ------------------------------------------------------------------
# METHOD: enable_format - turn on the format radio buttons
# ------------------------------------------------------------------
-itcl::body MemPref::enable_format {} {
- # First ensure bytes per row is a multiple of the size.
- # Use the value of the widget, not $gbpr to ensure the typed value is kept.
- set_bytes_per_row "" [$Widgets(b-bytes_per_row) get]
-
+body MemPref::enable_format {} {
if {!$format_disabled} {
return
}
@@ -386,11 +351,7 @@ itcl::body MemPref::enable_format {} {
# ------------------------------------------------------------------
# METHOD: disable_format - turn off the format radio buttons
# ------------------------------------------------------------------
-itcl::body MemPref::disable_format {} {
- # First ensure bytes per row is a multiple of the size.
- # Use the value of the widget, not $gbpr to ensure the typed value is kept.
- set_bytes_per_row "" [$Widgets(b-bytes_per_row) get]
-
+body MemPref::disable_format {} {
if {$format_disabled} {
return
}
@@ -404,7 +365,7 @@ itcl::body MemPref::disable_format {} {
# ------------------------------------------------------------------
# METHOD: pick - pick colors
# ------------------------------------------------------------------
-itcl::body MemPref::pick {lab} {
+body MemPref::pick {lab} {
set new_color [tk_chooseColor -initialcolor $color -title "Choose color"]
if {$new_color != $color && $new_color != ""} {
set color $new_color
@@ -416,7 +377,7 @@ itcl::body MemPref::pick {lab} {
# ------------------------------------------------------------------
# METHOD: reconfig - used when preferences change
# ------------------------------------------------------------------
-itcl::body MemPref::reconfig {} {
+body MemPref::reconfig {} {
# for now, just delete and recreate
destroy $itk_interior.f
build_win
diff --git a/gdb/gdbtk/library/mempref.ith b/gdb/gdbtk/library/mempref.ith
index d1f5f723949..77c62a3670a 100644
--- a/gdb/gdbtk/library/mempref.ith
+++ b/gdb/gdbtk/library/mempref.ith
@@ -1,5 +1,5 @@
# Memory display preferences window class definition for GDBtk.
-# Copyright (C) 1998, 1999 Cygnus Solutions
+# Copyright 1998, 1999 Cygnus Solutions
#
# This program is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License (GPL) as published by
@@ -12,7 +12,7 @@
# GNU General Public License for more details.
-itcl::class MemPref {
+class MemPref {
inherit ModalDialog ManagedWin
public {
@@ -47,7 +47,6 @@ itcl::class MemPref {
variable gformat
variable gnumbytes
variable gbpr
- variable gbprlist
variable gascii
variable gascii_char
variable gvar
diff --git a/gdb/gdbtk/library/memwin.itb b/gdb/gdbtk/library/memwin.itb
index fb9f578d898..eed59a4b3a7 100644
--- a/gdb/gdbtk/library/memwin.itb
+++ b/gdb/gdbtk/library/memwin.itb
@@ -1,69 +1,55 @@
-# Memory display window class definition for Insight.
-# Copyright (C) 1998, 1999, 2001, 2002, 2005, 2008 Red Hat, Inc.
-#
-# This program is free software; you can redistribute it and/or modify it
-# under the terms of the GNU General Public License (GPL) as published by
-# the Free Software Foundation; either version 2 of the License, or (at
-# your option) any later version.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-
# ------------------------------------------------------------------
# METHOD: constructor - build the dialog
# ------------------------------------------------------------------
-itcl::body MemWin::constructor {args} {
+body MemWin::constructor {args} {
global _mem
debug $args
eval itk_initialize $args
-
+
set top [winfo toplevel $itk_interior]
gdbtk_busy
-
+
set _mem($this,enabled) 1
-
+ set bg white
+
if {![info exists type(1)]} {
set type(1) char
set type(2) short
set type(4) int
set type(8) "long long"
}
-
+
if {[pref getd gdb/mem/menu] != ""} {
set mbar 0
}
-
- # Load defaults from preferences.
- set size [pref getd gdb/mem/size]
- set numbytes [pref getd gdb/mem/numbytes]
- set format [pref getd gdb/mem/format]
- set ascii [pref getd gdb/mem/ascii]
- set ascii_char [pref getd gdb/mem/ascii_char]
- set bytes_per_row [pref getd gdb/mem/bytes_per_row]
- set color [pref getd gdb/mem/color]
-
+
init_addr_exp
build_win
gdbtk_idle
+
+ add_hook gdb_update_hook "$this update"
+ add_hook gdb_busy_hook [list $this busy]
+ add_hook gdb_idle_hook [list $this idle]
}
# ------------------------------------------------------------------
# METHOD: destructor - destroy the dialog
# ------------------------------------------------------------------
-itcl::body MemWin::destructor {} {
+body MemWin::destructor {} {
if {[winfo exists $prefs_win]} {
$prefs_win cancel
}
+ remove_hook gdb_update_hook "$this update"
+ remove_hook gdb_busy_hook [list $this busy]
+ remove_hook gdb_idle_hook [list $this idle]
}
# ------------------------------------------------------------------
# METHOD: build_win - build the main memory window
# ------------------------------------------------------------------
-itcl::body MemWin::build_win {} {
- global gdb_ImageDir _mem ${this}_memval
+body MemWin::build_win {} {
+ global tcl_platform gdb_ImageDir _mem ${this}_memval
set maxlen 0
set maxalen 0
@@ -72,13 +58,12 @@ itcl::body MemWin::build_win {} {
if { $mbar } {
menu $itk_interior.m -tearoff 0
$top configure -menu $itk_interior.m
- $itk_interior.m add cascade -menu $itk_interior.m.addr \
- -label "Addresses" -underline 0
+ $itk_interior.m add cascade -menu $itk_interior.m.addr -label "Addresses" -underline 0
set m [menu $itk_interior.m.addr]
$m add check -label " Auto Update" -variable _mem($this,enabled) \
-underline 1 -command "after idle $this toggle_enabled"
$m add command -label " Update Now" -underline 1 \
- -command [code $this _update_address 1] -accelerator {Ctrl+U}
+ -command "$this update_address" -accelerator {Ctrl+U}
$m add separator
$m add command -label " Preferences..." -underline 1 \
-command "$this create_prefs"
@@ -93,7 +78,7 @@ itcl::body MemWin::build_win {} {
set Numrows [expr {$numbytes / $bytes_per_row}]
}
set numrows [expr {$Numrows + 1}]
-
+
set Numcols [expr {$bytes_per_row / $size}]
if {$ascii} {
set numcols [expr {$Numcols + 2}]
@@ -101,53 +86,44 @@ itcl::body MemWin::build_win {} {
set numcols [expr {$Numcols + 1}]
}
- itk_component add table {
- ::table $itk_interior.t -titlerows 1 -titlecols 1 -variable ${this}_memval \
- -roworigin -1 -colorigin -1 -bg $::Colors(textbg) -fg $::Colors(textfg) \
- -browsecmd "$this changed_cell %s %S" -font global/fixed\
- -colstretch unset -rowstretch unset -selectmode single \
- -xscrollcommand "$itk_interior.sx set" -resizeborders none \
- -cols $numcols -rows $numrows -autoclear 1
- } {
- keep -foreground
- keep -insertbackground
- keep -highlightcolor
- keep -highlightbackground
- }
+ table $itk_interior.t -titlerows 1 -titlecols 1 -variable ${this}_memval \
+ -roworigin -1 -colorigin -1 -bg $bg \
+ -browsecmd "$this changed_cell %s %S" -font src-font\
+ -colstretch unset -rowstretch unset -selectmode single \
+ -xscrollcommand "$itk_interior.sx set" -resizeborders none \
+ -cols $numcols -rows $numrows -autoclear 1
if {$numbytes} {
- $itk_component(table) configure -yscrollcommand "$itk_interior.sy set"
- scrollbar $itk_interior.sy -command [list $itk_component(table) yview]
+ $itk_interior.t configure -yscrollcommand "$itk_interior.sy set"
+ scrollbar $itk_interior.sy -command [list $itk_interior.t yview]
} else {
- $itk_component(table) configure -rowstretchmode none
+ $itk_interior.t configure -rowstretchmode none
}
- scrollbar $itk_interior.sx -command [list $itk_component(table) xview] -orient horizontal
- $itk_component(table) tag config sel -bg [$itk_component(table) cget -bg] -relief sunken
- $itk_component(table) tag config active -relief sunken -wrap 0 \
- -bg $::Colors(sbg) -fg $::Colors(sfg)
- $itk_component(table) tag config title -bg $::Colors(bg) -fg $::Colors(fg)
+ scrollbar $itk_interior.sx -command [list $itk_interior.t xview] -orient horizontal
+ $itk_interior.t tag config sel -bg [$itk_interior.t cget -bg] -relief sunken
+ $itk_interior.t tag config active -bg lightgray -relief sunken -wrap 0
# rebind all events that use tkTableMoveCell to our local version
# because we don't want to move into the ASCII column if it exists
- bind $itk_component(table) <Up> "$this memMoveCell %W -1 0; break"
- bind $itk_component(table) <Down> "$this memMoveCell %W 1 0; break"
- bind $itk_component(table) <Left> "$this memMoveCell %W 0 -1; break"
- bind $itk_component(table) <Right> "$this memMoveCell %W 0 1; break"
- bind $itk_component(table) <Return> "$this memMoveCell %W 0 1; break"
- bind $itk_component(table) <KP_Enter> "$this memMoveCell %W 0 1; break"
+ bind $itk_interior.t <Up> "$this memMoveCell %W -1 0; break"
+ bind $itk_interior.t <Down> "$this memMoveCell %W 1 0; break"
+ bind $itk_interior.t <Left> "$this memMoveCell %W 0 -1; break"
+ bind $itk_interior.t <Right> "$this memMoveCell %W 0 1; break"
+ bind $itk_interior.t <Return> "$this memMoveCell %W 0 1; break"
+ bind $itk_interior.t <KP_Enter> "$this memMoveCell %W 0 1; break"
# bind button 3 to popup
- bind $itk_component(table) <3> "$this do_popup %X %Y"
+ bind $itk_interior.t <3> "$this do_popup %X %Y"
# bind Paste and button2 to the paste function
# this is necessary because we want to not just paste the
# data into the cell, but we also have to write it
# out to real memory
- bind $itk_component(table) <ButtonRelease-2> [format {after idle %s paste %s %s} $this %x %y]
- bind $itk_component(table) <<Paste>> [format {after idle %s paste %s %s} $this %x %y]
+ bind $itk_interior.t <ButtonRelease-2> [format {after idle %s paste %s %s} $this %x %y]
+ bind $itk_interior.t <<Paste>> [format {after idle %s paste %s %s} $this %x %y]
- menu $itk_component(table).menu -tearoff 0
- bind_plain_key $top Control-u [code $this _update_address 1]
+ menu $itk_interior.t.menu -tearoff 0
+ bind_plain_key $top Control-u "$this update_address"
# bind resize events
bind $itk_interior <Configure> "$this newsize %h"
@@ -156,26 +132,27 @@ itcl::body MemWin::build_win {} {
iwidgets::spinint $itk_interior.f.cntl -labeltext " Address " -width 20 \
-command "after idle $this update_address_cb" \
-increment "after idle $this incr_addr -1" \
- -decrement "after idle $this incr_addr 1" -foreground $::Colors(textfg) \
- -validate {} -textbackground $::Colors(textbg)
+ -decrement "after idle $this incr_addr 1" \
+ -validate {} \
+ -textbackground white
+
$itk_interior.f.cntl delete 0 end
$itk_interior.f.cntl insert end $addr_exp
- label $itk_interior.f.endian -text "Target is [gdbtk_endian] endian"
-
balloon register [$itk_interior.f.cntl childsite].uparrow \
"Scroll Up (Decrement Address)"
balloon register [$itk_interior.f.cntl childsite].downarrow \
"Scroll Down (Increment Address)"
+
if {!$mbar} {
- button $itk_interior.f.upd -command [code $this _update_address 1] \
+ button $itk_interior.f.upd -command "$this update_address" \
-image [image create photo -file [::file join $gdb_ImageDir check.gif]]
balloon register $itk_interior.f.upd "Update Now"
checkbutton $itk_interior.cb -variable _mem($this,enabled) -command "$this toggle_enabled"
balloon register $itk_interior.cb "Toggles Automatic Display Updates"
- grid $itk_interior.f.upd $itk_interior.f.cntl $itk_interior.f.endian -sticky ew -padx 5
+ grid $itk_interior.f.upd $itk_interior.f.cntl -sticky ew -padx 5
} else {
- grid $itk_interior.f.cntl x $itk_interior.f.endian -sticky e
+ grid $itk_interior.f.cntl x -sticky w
grid columnconfigure $itk_interior.f 1 -weight 1
}
@@ -192,7 +169,7 @@ itcl::body MemWin::build_win {} {
# fill initial display
if {$nb} {
- _update_address 0
+ update_address
}
if {!$mbar} {
@@ -201,7 +178,7 @@ itcl::body MemWin::build_win {} {
} else {
grid $itk_interior.f -row 0 -column 0 -sticky news
}
- grid $itk_component(table) -row 1 -column 0 -sticky news
+ grid $itk_interior.t -row 1 -column 0 -sticky news
if {$numbytes} { grid $itk_interior.sy -row 1 -column 1 -sticky ns }
grid $itk_interior.sx -sticky ew
grid columnconfig $itk_interior 0 -weight 1
@@ -214,26 +191,26 @@ itcl::body MemWin::build_win {} {
# ------------------------------------------------------------------
# METHOD: paste - paste callback. Update cell contents after paste
# ------------------------------------------------------------------
-itcl::body MemWin::paste {x y} {
- edit [$itk_component(table) index @$x,$y]
+body MemWin::paste {x y} {
+ edit [$itk_interior.t index @$x,$y]
}
# ------------------------------------------------------------------
# METHOD: validate - because the control widget wants this
# ------------------------------------------------------------------
-itcl::body MemWin::validate {val} {
+body MemWin::validate {val} {
return $val
}
# ------------------------------------------------------------------
# METHOD: create_prefs - create memory preferences dialog
# ------------------------------------------------------------------
-itcl::body MemWin::create_prefs {} {
+body MemWin::create_prefs {} {
if {$Running} { return }
# make sure row height is set
if {$rheight == ""} {
- set rheight [lindex [$itk_component(table) bbox 0,0] 3]
+ set rheight [lindex [$itk_interior.t bbox 0,0] 3]
}
set prefs_win [ManagedWin::open MemPref -force -over $this\
@@ -246,21 +223,21 @@ itcl::body MemWin::create_prefs {} {
# ------------------------------------------------------------------
# METHOD: changed_cell - called when moving from one cell to another
# ------------------------------------------------------------------
-itcl::body MemWin::changed_cell {from to} {
+body MemWin::changed_cell {from to} {
#debug "moved from $from to $to"
- #debug "value = [$itk_component(table) get $from]"
+ #debug "value = [$itk_interior.t get $from]"
if {$saved_value != ""} {
- if {$saved_value != [$itk_component(table) get $from]} {
+ if {$saved_value != [$itk_interior.t get $from]} {
edit $from
}
}
- set saved_value [$itk_component(table) get $to]
+ set saved_value [$itk_interior.t get $to]
}
# ------------------------------------------------------------------
# METHOD: edit - edit a cell
# ------------------------------------------------------------------
-itcl::body MemWin::edit { cell } {
+body MemWin::edit { cell } {
global _mem ${this}_memval
#debug "edit $cell"
@@ -269,11 +246,11 @@ itcl::body MemWin::edit { cell } {
set rc [split $cell ,]
set row [lindex $rc 0]
set col [lindex $rc 1]
- set val [$itk_component(table) get $cell]
+ set val [$itk_interior.t get $cell]
if {$col == $Numcols} {
# editing the ASCII field
- set addr [gdb_incr_addr $current_addr [expr {$bytes_per_row * $row}]]
+ set addr [expr {$current_addr + $bytes_per_row * $row}]
set start_addr $addr
# calculate number of rows to modify
@@ -288,42 +265,34 @@ itcl::body MemWin::edit { cell } {
# now process each char, one at a time
foreach c [split $val ""] {
if {$c != $ascii_char} {
- scan $c %c char
- if {[catch {gdb_set_mem $addr [format %02x $char] 1} res]} {
- error_dialog $res
-
- # reset value
- set ${this}_memval($row,$col) $saved_value
- return
- }
+ if {$c == "'"} {set c "\\'"}
+ catch {gdb_cmd "set *(char *)($addr) = '$c'"}
}
- set addr [gdb_incr_addr $addr]
+ incr addr
}
set addr $start_addr
set nextval 0
# now read back the data and update the widget
- catch {gdb_update_mem ${this}_memval $addr $format $size $nb $bytes_per_row $ascii_char} vals
+ catch {gdb_get_mem $addr $format $size $nb $bytes_per_row $ascii_char} vals
+ for {set n 0} {$n < $nb} {incr n $bytes_per_row} {
+ set ${this}_memval($row,-1) [format "0x%x" $addr]
+ for { set col 0 } { $col < [expr {$bytes_per_row / $size}] } { incr col } {
+ set ${this}_memval($row,$col) [lindex $vals $nextval]
+ incr nextval
+ }
+ set ${this}_memval($row,$col) [lindex $vals $nextval]
+ incr nextval
+ incr addr $bytes_per_row
+ incr row
+ }
return
}
# calculate address based on row and column
- set addr [gdb_incr_addr $current_addr [expr {$bytes_per_row * $row + $size * $col}]]
- #debug " edit $row,$col $addr = $val"
-
- # Pad the value with zeros, if necessary
- set s [expr {$size * 2}]
- set val [format "0x%0${s}x" $val]
-
- # set memory
- #debug "set_mem $addr $val $size"
- if {[catch {gdb_set_mem $addr $val $size} res]} {
- error_dialog $res
-
- # reset value
- set ${this}_memval($row,$col) $saved_value
- return
- }
-
+ set addr [expr {$current_addr + $bytes_per_row * $row + $size * $col}]
+ #debug " edit $row,$col [format "%x" $addr] = $val"
+ #set memory
+ catch {gdb_cmd "set *($type($size) *)($addr) = $val"} res
# read it back
# FIXME - HACK ALERT - This call causes trouble with remotes on Windows.
# This routine is in fact called from within an idle handler triggered by
@@ -333,7 +302,7 @@ itcl::body MemWin::edit { cell } {
# line out. It will only matter if the write did not succeed, and this was
# not a very good way to tell the user about that anyway...
#
- # catch {gdb_update_mem $addr $format $size $size $size ""} val
+ # catch {gdb_get_mem $addr $format $size $size $size ""} val
# delete whitespace in response
set val [string trimright $val]
set val [string trimleft $val]
@@ -344,71 +313,65 @@ itcl::body MemWin::edit { cell } {
# ------------------------------------------------------------------
# METHOD: toggle_enabled - called when enable is toggled
# ------------------------------------------------------------------
-itcl::body MemWin::toggle_enabled {} {
+body MemWin::toggle_enabled {} {
global _mem
if {$Running} { return }
if {$_mem($this,enabled)} {
- _update_address 1
+ update_address
+ set bg white
set state normal
- set bg $::Colors(textbg)
} else {
- set bg $::Colors(bg)
+ set bg gray
set state disabled
}
- $itk_component(table) config -background $bg -state $state
+ $itk_interior.t config -background $bg -state $state
}
# ------------------------------------------------------------------
# METHOD: update - update widget after every PC change
# ------------------------------------------------------------------
-itcl::body MemWin::update {event} {
+body MemWin::update {} {
global _mem
if {$_mem($this,enabled)} {
- _update_address 0
+ update_address
}
}
# ------------------------------------------------------------------
# METHOD: idle - memory window is idle, so enable menus
# ------------------------------------------------------------------
-itcl::body MemWin::idle {event} {
+body MemWin::idle {} {
# Fencepost
set Running 0
# Cursor
cursor {}
- if {[winfo exists $itk_interior.m.addr]} {
- # Enable menus
- if {$mbar} {
- for {set i 0} {$i <= [$itk_interior.m.addr index last]} {incr i} {
- if {[$itk_interior.m.addr type $i] != "separator"} {
- $itk_interior.m.addr entryconfigure $i -state normal
- }
- }
+ # Enable menus
+ if {$mbar} {
+ for {set i 0} {$i <= [$itk_interior.m.addr index last]} {incr i} {
+ if {[$itk_interior.m.addr type $i] != "separator"} {
+ $itk_interior.m.addr entryconfigure $i -state normal
+ }
}
-
- # Enable control
- $itk_interior.f.cntl configure -state normal
}
+
+ # Enable control
+ $itk_interior.f.cntl configure -state normal
}
# ------------------------------------------------------------------
-# METHOD: busy - BusyEvent handler
-# Disable menus 'cause we're busy updating things.
+# METHOD: busy - disable menus 'cause we're busy updating things
# ------------------------------------------------------------------
-itcl::body MemWin::busy {event} {
+body MemWin::busy {} {
# Fencepost
set Running 1
# cursor
cursor watch
- # go away if window is not finished drawing
- if {![winfo exists $itk_interior.f.cntl]} { return }
-
# Disable menus
if {$mbar} {
for {set i 0} {$i <= [$itk_interior.m.addr index last]} {incr i} {
@@ -426,8 +389,7 @@ itcl::body MemWin::busy {event} {
# METHOD: newsize - calculate how many rows to display when the
# window is resized.
# ------------------------------------------------------------------
-itcl::body MemWin::newsize {height} {
-
+body MemWin::newsize {height} {
if {$dont_size || $Running} {
return
}
@@ -438,45 +400,38 @@ itcl::body MemWin::newsize {height} {
# make sure row height is set
if {$rheight == ""} {
- set rheight [lindex [$itk_component(table) bbox 0,0] 3]
+ set rheight [lindex [$itk_interior.t bbox 0,0] 3]
}
- set theight [winfo height $itk_component(table)]
+ set theight [winfo height $itk_interior.t]
set Numrows [expr {$theight / $rheight}]
- $itk_component(table) configure -rows $Numrows
- _update_address 1
- }
-}
-
-itcl::body MemWin::_update_address {make_busy} {
- if {$make_busy} {
- gdbtk_busy
- }
- update_address [string trimleft [$itk_interior.f.cntl get]]
- if {$make_busy} {
- gdbtk_idle
+ $itk_interior.t configure -rows $Numrows
+ update_addr
}
}
# ------------------------------------------------------------------
# METHOD: update_address_cb - address entry widget callback
# ------------------------------------------------------------------
-itcl::body MemWin::update_address_cb {} {
+body MemWin::update_address_cb {} {
set new_entry 1
- _update_address 1
+ update_address [$itk_interior.f.cntl get]
}
# ------------------------------------------------------------------
# METHOD: update_address - update address and data displayed
# ------------------------------------------------------------------
-itcl::body MemWin::update_address {addr} {
+body MemWin::update_address { {ae ""} } {
+ if {$ae == ""} {
+ set addr_exp [string trimleft [$itk_interior.f.cntl get]]
+ } else {
+ set addr_exp $ae
+ }
- set bad_expr 0
set saved_addr $current_addr
- if {[string match {[a-zA-Z_&0-9\*]*} $addr]} {
+ if {[string match {[a-zA-Z_&0-9\*]*} $addr_exp]} {
# Looks like an expression
- set retVal [catch {gdb_eval "$addr" x} current_addr]
- #debug "retVal=$retVal current_addr=$current_addr"
+ set retVal [catch {gdb_eval "$addr_exp"} current_addr]
if {$retVal || [string match "No symbol*" $current_addr] || \
[string match "Invalid *" $current_addr]} {
BadExpr $current_addr
@@ -488,63 +443,65 @@ itcl::body MemWin::update_address {addr} {
return
}
}
- } elseif {[regexp {\$[a-zA-Z_]} $addr]} {
+ } elseif {[string match {\$*} $addr_exp]} {
# Looks like a local variable
- set retVal [catch {gdb_eval "$addr" x} current_addr]
- #debug "retVal=$retVal current_addr=$current_addr"
- if {$retVal} {
- BadExpr $current_addr
- return
+ catch {gdb_eval "$addr_exp"} current_addr
+ if {$current_addr == "No registers.\n"} {
+ # we asked for a register value and debugging hasn't started yet
+ return
}
if {$current_addr == "void"} {
- BadExpr "No Local Variable Named \"$addr\""
+ BadExpr "No Local Variable Named \"$addr_ex\""
return
}
} else {
# something really strange, like "0.1" or ""
- BadExpr "Can't Evaluate \"$addr\""
+ BadExpr "Can't Evaluate \"$addr_expr\""
return
}
- # Check for spaces - this can happen with gdb_eval and $pc, for example.
+ # Check for spaces
set index [string first \ $current_addr]
if {$index != -1} {
incr index -1
set current_addr [string range $current_addr 0 $index]
}
- set addr_exp $addr
-
# set table background
- $itk_component(table) config -bg $::Colors(textbg) -state normal
+ $itk_interior.t config -bg white -state normal
catch {update_addr}
}
# ------------------------------------------------------------------
# METHOD: BadExpr - handle a bad expression
# ------------------------------------------------------------------
-itcl::body MemWin::BadExpr {errTxt} {
+body MemWin::BadExpr {errTxt} {
if {$new_entry} {
tk_messageBox -type ok -icon error -message $errTxt
set new_entry 0
}
# set table background to gray
- $itk_component(table) config -bg $::Colors(bg) -state disabled
+ $itk_interior.t config -bg gray -state disabled
set current_addr $saved_addr
set saved_addr ""
- set bad_expr 1
}
# ------------------------------------------------------------------
# METHOD: incr_addr - callback from control widget to increment
# the current address.
# ------------------------------------------------------------------
-itcl::body MemWin::incr_addr {num} {
+body MemWin::incr_addr {num} {
+
if {$current_addr == ""} {
return
}
set old_addr $current_addr
- set current_addr [gdb_incr_addr $current_addr [expr {$bytes_per_row * $num}]]
+
+ # You have to be careful with address calculations here, since the memory
+ # space of the target may be bigger than a long, which will cause Tcl to
+ # overflow. Let gdb do the calculations instead.
+
+ set current_addr [gdb_cmd "printf \"%u\", $current_addr + $num * $bytes_per_row"]
# A memory address less than zero is probably not a good thing...
#
@@ -555,56 +512,87 @@ itcl::body MemWin::incr_addr {num} {
set current_addr $old_addr
return
}
- $itk_component(table) config -bg $::Colors(textbg) -state normal
+ $itk_interior.t config -background white -state normal
+ update_addr
$itk_interior.f.cntl clear
- $itk_interior.f.cntl insert 0 $current_addr
- _update_address 1
+ $itk_interior.f.cntl insert 0 [format "0x%x" $current_addr]
}
# ------------------------------------------------------------------
# METHOD: update_addr - read in data starting at $current_addr
-# This is just a helper function for update_address.
+# This is just a helper function for update_address.
# ------------------------------------------------------------------
-itcl::body MemWin::update_addr {} {
+body MemWin::update_addr {} {
global _mem ${this}_memval
- set row 0
+ gdbtk_busy
+ set addr $current_addr
+
+ set row 0
if {$numbytes == 0} {
set nb [expr {$Numrows * $bytes_per_row}]
} else {
set nb $numbytes
}
+ set nextval 0
+ set num [expr {$bytes_per_row / $size}]
if {$ascii} {
- set retVal [catch {gdb_update_mem ${this}_memval $current_addr $format $size $nb $bytes_per_row $ascii_char} vals]
-
+ set asc $ascii_char
} else {
- set retVal [catch {gdb_update_mem ${this}_memval $current_addr $format $size $nb $bytes_per_row} vals]
+ set asc ""
}
-
- if {$retVal || [llength $vals] != 3} {
+ set retVal [catch {gdb_get_mem $addr $format \
+ $size $nb $bytes_per_row $asc} vals]
+
+ if {$retVal || [llength $vals] == 0} {
+ # FIXME gdb_get_mem does not always return an error when addr is invalid.
BadExpr "Couldn't get memory at address: \"$addr\""
- debug "gdb_update_mem returned return code: $retVal and value: \"$vals\""
+ gdbtk_idle
+ debug "gdb_get_mem returned return code: $retVal and value: \"$vals\""
return
}
- # set default column width to the max in the data columns
- $itk_component(table) configure -colwidth [lindex $vals 1]
+ set mlen 0
+ for {set n 0} {$n < $nb} {incr n $bytes_per_row} {
+ set x [format "0x%x" $addr]
+ if {[string length $x] > $mlen} {
+ set mlen [string length $x]
+ }
+ set ${this}_memval($row,-1) $x
+ for { set col 0 } { $col < $num } { incr col } {
+ set x [lindex $vals $nextval]
+ if {[string length $x] > $maxlen} {set maxlen [string length $x]}
+ set ${this}_memval($row,$col) $x
+ incr nextval
+ }
+ if {$ascii} {
+ set x [lindex $vals $nextval]
+ if {[string length $x] > $maxalen} {set maxalen [string length $x]}
+ set ${this}_memval($row,$col) $x
+ incr nextval
+ }
+ incr addr $bytes_per_row
+ incr row
+ }
+ # set default column width to the max in the data columns
+ $itk_interior.t configure -colwidth [expr {$maxlen + 1}]
# set border column width
- $itk_component(table) width -1 [lindex $vals 0]
-
- # set ascii column width
+ $itk_interior.t width -1 [expr {$mlen + 1}]
if {$ascii} {
- $itk_component(table) width $Numcols [lindex $vals 2]
+ # set ascii column width
+ $itk_interior.t width $Numcols [expr {$maxalen + 1}]
}
+
+ gdbtk_idle
}
# ------------------------------------------------------------------
# METHOD: hidemb - hide the menubar. NOT CURRENTLY USED
# ------------------------------------------------------------------
-itcl::body MemWin::hidemb {} {
+body MemWin::hidemb {} {
set mbar 0
reconfig
}
@@ -612,18 +600,17 @@ itcl::body MemWin::hidemb {} {
# ------------------------------------------------------------------
# METHOD: reconfig - used when preferences change
# ------------------------------------------------------------------
-itcl::body MemWin::reconfig {} {
+body MemWin::reconfig {} {
debug
set addr_exp [string trimright [string trimleft $addr_exp]]
set wh [winfo height $top]
-
+
if [winfo exists $itk_interior.m] { destroy $itk_interior.m }
if [winfo exists $itk_interior.cb] { destroy $itk_interior.cb }
if [winfo exists $itk_interior.f.upd] { destroy $itk_interior.f.upd }
if [winfo exists $itk_interior.sy] { destroy $itk_interior.sy }
- destroy $itk_interior.f.cntl $itk_interior.f $itk_component(table) \
- $itk_interior.sx
-
+ destroy $itk_interior.f.cntl $itk_interior.f $itk_interior.t $itk_interior.sx
+
set dont_size 1
# If the fonts change, then you will need to recompute the
@@ -632,15 +619,6 @@ itcl::body MemWin::reconfig {} {
set rheight ""
- # Update preferences to reflect new reality
- pref setd gdb/mem/size $size
- pref setd gdb/mem/numbytes $numbytes
- pref setd gdb/mem/format $format
- pref setd gdb/mem/ascii $ascii
- pref setd gdb/mem/ascii_char $ascii_char
- pref setd gdb/mem/bytes_per_row $bytes_per_row
- pref setd gdb/mem/color $color
-
build_win
set dont_size 0
::update
@@ -653,31 +631,30 @@ itcl::body MemWin::reconfig {} {
# ------------------------------------------------------------------
# METHOD: do_popup - Display popup menu
# ------------------------------------------------------------------
-itcl::body MemWin::do_popup {X Y} {
+body MemWin::do_popup {X Y} {
if {$Running} { return }
- $itk_component(table).menu delete 0 end
- $itk_component(table).menu add check -label "Auto Update" -variable _mem($this,enabled) \
+ $itk_interior.t.menu delete 0 end
+ $itk_interior.t.menu add check -label "Auto Update" -variable _mem($this,enabled) \
-underline 0 -command "$this toggle_enabled"
- $itk_component(table).menu add command -label "Update Now" -underline 0 \
- -command [code $this _update_address 1]
- $itk_component(table).menu add command -label "Go To [$itk_component(table) curvalue]" -underline 0 \
- -command "$this goto [$itk_component(table) curvalue]"
- $itk_component(table).menu add command -label "Open New Window at [$itk_component(table) curvalue]" -underline 0 \
- -command [list ManagedWin::open MemWin -force -addr_exp [$itk_component(table) curvalue]]
- $itk_component(table).menu add separator
- $itk_component(table).menu add command -label "Preferences..." -underline 0 \
+ $itk_interior.t.menu add command -label "Update Now" -underline 0 \
+ -command "$this update_address"
+ $itk_interior.t.menu add command -label "Go To [$itk_interior.t curvalue]" -underline 0 \
+ -command "$this goto [$itk_interior.t curvalue]"
+ $itk_interior.t.menu add command -label "Open New Window at [$itk_interior.t curvalue]" -underline 0 \
+ -command [list ManagedWin::open -force MemWin -addr_exp [$itk_interior.t curvalue]]
+ $itk_interior.t.menu add separator
+ $itk_interior.t.menu add command -label "Preferences..." -underline 0 \
-command "$this create_prefs"
- tk_popup $itk_component(table).menu $X $Y
+ tk_popup $itk_interior.t.menu $X $Y
}
# ------------------------------------------------------------------
# METHOD: goto - change the address of the current memory window
# ------------------------------------------------------------------
-itcl::body MemWin::goto { addr } {
+body MemWin::goto { addr } {
set current_addr $addr
$itk_interior.f.cntl delete 0 end
$itk_interior.f.cntl insert end $addr
- _update_address 1
}
# ------------------------------------------------------------------
@@ -685,7 +662,7 @@ itcl::body MemWin::goto { addr } {
# On startup, if the public variable "addr_exp" was not set,
# then set it to the start of ".data" if found, otherwise "$pc"
# ------------------------------------------------------------------
-itcl::body MemWin::init_addr_exp {} {
+body MemWin::init_addr_exp {} {
if {$addr_exp == ""} {
set err [catch {gdb_cmd "info file"} result]
if {!$err} {
@@ -707,10 +684,10 @@ itcl::body MemWin::init_addr_exp {} {
# ------------------------------------------------------------------
# METHOD: cursor - set the cursor
# ------------------------------------------------------------------
-itcl::body MemWin::cursor {glyph} {
+body MemWin::cursor {glyph} {
# Set cursor for all labels
# for {set i 0} {$i < $bytes_per_row} {incr i $size} {
- # $itk_component(table).h.$i configure -cursor $glyph
+ # $itk_interior.t.h.$i configure -cursor $glyph
# }
$top configure -cursor $glyph
}
@@ -728,7 +705,7 @@ itcl::body MemWin::cursor {glyph} {
# x - +1 to move down one cell, -1 to move up one cell.
# y - +1 to move right one cell, -1 to move left one cell.
-itcl::body MemWin::memMoveCell {w x y} {
+body MemWin::memMoveCell {w x y} {
if {[catch {$w index active row} r]} return
set c [$w index active col]
if {$ascii && ($c == $Numcols)} {
@@ -760,17 +737,3 @@ itcl::body MemWin::memMoveCell {w x y} {
$w see active
}
-# ------------------------------------------------------------
-# PUBLIC METHOD: error_dialog - Open and error dialog.
-# Arguments:
-# msg - The message to display in the dialog
-# modality - The dialog modailty. Default: task
-# type - The dialog type (tk_messageBox).
-# Default: ok
-# ------------------------------------------------------------
-itcl::body MemWin::error_dialog {msg {modality task} {type ok}} {
- set parent [winfo toplevel [namespace tail $this]]
- tk_messageBox -icon error -title Error -type $type \
- -message $msg -parent $parent
-}
-
diff --git a/gdb/gdbtk/library/memwin.ith b/gdb/gdbtk/library/memwin.ith
index c7ec92d17c9..fd2bc0d93fe 100644
--- a/gdb/gdbtk/library/memwin.ith
+++ b/gdb/gdbtk/library/memwin.ith
@@ -1,5 +1,5 @@
-# Memory display window class definition for Insight.
-# Copyright (C) 1998, 1999, 2001, 2002 Red Hat, Inc.
+# Memory display window class definition for GDBtk.
+# Copyright 1998, 1999 Cygnus Solutions
#
# This program is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License (GPL) as published by
@@ -12,12 +12,11 @@
# GNU General Public License for more details.
-itcl::class MemWin {
+class MemWin {
inherit EmbeddedWin GDBWin
private {
variable saved_addr ""
- variable bad_expr 0
variable current_addr ""
variable dont_size 0
variable mbar 1
@@ -37,7 +36,6 @@ itcl::class MemWin {
method build_win {}
method init_addr_exp {}
method cursor {glyph}
- method _update_address {make_busy}
}
public {
@@ -62,9 +60,12 @@ itcl::class MemWin {
method changed_cell {from to}
method edit {cell}
method toggle_enabled {}
+ method update {}
+ method idle {}
+ method busy {}
method newsize {height}
method update_address_cb {}
- method update_address {addr_exp}
+ method update_address { {ae ""} }
method BadExpr {errTxt}
method incr_addr {num}
method update_addr
@@ -73,13 +74,5 @@ itcl::class MemWin {
method do_popup {x y}
method goto {addr}
method memMoveCell {w x y}
- method error_dialog {msg {modality task} {type ok}}
-
- #
- # GDB Events
- #
- method busy {event}
- method idle {event}
- method update {event}
}
}
diff --git a/gdb/gdbtk/library/modal.tcl b/gdb/gdbtk/library/modal.tcl
index ecaafe6928a..e2c09eb0fd7 100644
--- a/gdb/gdbtk/library/modal.tcl
+++ b/gdb/gdbtk/library/modal.tcl
@@ -1,5 +1,5 @@
# Modal dialog class for GDBtk.
-# Copyright (C) 1998, 1999 Cygnus Solutions
+# Copyright 1998, 1999 Cygnus Solutions
#
# This program is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License (GPL) as published by
@@ -23,7 +23,7 @@
#
# ----------------------------------------------------------------------
-itcl::class ModalDialog {
+class ModalDialog {
# This is the variable we vwait on when the dialog is posted.
# It is set to 1 in the unpost method, and to -1 in the destructor.
@@ -56,7 +56,7 @@ itcl::class ModalDialog {
# ------------------------------------------------------------------
# METHOD: post - posts the dialog box...
# ------------------------------------------------------------------
- public method post {{on_top 0} {expire 0}} {
+ public method post {{on_top 0}} {
debug "POST $this"
set top [winfo toplevel [namespace tail $this]]
diff --git a/gdb/gdbtk/library/prefs.tcl b/gdb/gdbtk/library/prefs.tcl
index 2a709248b2c..bc69b131f53 100644
--- a/gdb/gdbtk/library/prefs.tcl
+++ b/gdb/gdbtk/library/prefs.tcl
@@ -1,5 +1,5 @@
-# Local preferences functions for Insight.
-# Copyright (C) 1997, 1998, 1999, 2002, 2003, 2004, 2008 Red Hat
+# Local preferences functions for GDBtk.
+# Copyright 1997, 1998, 1999 Cygnus Solutions
#
# This program is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License (GPL) as published by
@@ -32,10 +32,10 @@
proc pref_read {} {
global prefs_init_filename env gdb_ImageDir GDBTK_LIBRARY GDBStartup
- global gdbtk_platform
+ global tcl_platform
if {[info exists env(HOME)]} {
- if {$gdbtk_platform(os) == "cygwin"} {
+ if {$tcl_platform(platform) == "windows"} {
set home [ide_cygwin_path to_win32 $env(HOME)]
} else {
set home $env(HOME)
@@ -44,18 +44,17 @@ proc pref_read {} {
set home ""
}
- if {$gdbtk_platform(platform) == "windows"} {
+ if {$tcl_platform(platform) == "windows"} {
set prefs_init_filename "gdbtk.ini"
} else {
set prefs_init_filename ".gdbtkinit"
}
- if {!$GDBStartup(inhibit_prefs) \
- || [info exists env(INSIGHT_FORCE_READ_PREFERENCES)]} {
+ if {!$GDBStartup(inhibit_prefs)} {
set file_opened 0
if {[file exists $prefs_init_filename]} {
if {[catch {open $prefs_init_filename r} fd]} {
- dbug E "$fd"
+ debug "$fd"
return
}
set file_opened 1
@@ -63,7 +62,7 @@ proc pref_read {} {
set name [file join $home $prefs_init_filename]
if {[file exists $name]} {
if {[catch {open $name r} fd]} {
- dbug E "$fd"
+ debug "$fd"
return
}
set prefs_init_filename $name
@@ -73,61 +72,46 @@ proc pref_read {} {
if {$file_opened == "1"} {
set section gdb
- set version 0
while {[gets $fd line] >= 0} {
switch -regexp -- $line {
{^[ \t\n]*#.*} {
- # Comment. We recognize one magic comment that includes
- # the version number.
- if {[regexp -- "^# GDBtkInitVersion: (\[0-9\]+)\$" $line \
- dummy v]} {
- set version $v
- }
+ ;# comment; ignore it
}
{^[ \t\n]*$} {
;# empty line; ignore it
}
- {^[ \t\n]*\[.*\]} {
+ {\[.*\]} {
regexp {\[(.*)\]} $line match section
}
- {^[ \t\n]*option.*} {
+ {[ \t\n]*option.*} {
set line [string trimleft $line]
eval $line
}
default {
- set a ""
- set name ""
- set val ""
regexp "\[ \t\n\]*\(.+\)=\(.+\)" $line a name val
- if {$a == "" || $name == ""} {
- dbug W "Cannot parse line: $line"
- } else {
- # Must unescape equal signs in val
- set val [unescape_value $val $version]
- if {$section == "gdb"} {
- pref setd gdb/$name $val
- } elseif {$section == "global" && [regexp "^font/" $name]} {
- set name [split $name /]
- set f global/
- append f [join [lrange $name 1 end] /]
- if {[lsearch [font names] $f] == -1} {
- # new font
- eval define_font $f $val
- } else {
- # existing font
- pref set global/font/[join [lrange $name 1 end] /] $val
- }
- } elseif {$section == "global"} {
- pref setd $section/$name $val
+ # Must unescape equal signs in val
+ set val [unescape_value $val]
+ if {$section == "gdb"} {
+ pref setd gdb/$name $val
+ } elseif {$section == "global" && [regexp "^font/" $name]} {
+ set name [split $name /]
+ set f global/
+ append f [join [lrange $name 1 end] /]
+ if {[lsearch [font names] $f] == -1} {
+ # new font
+ eval define_font $f $val
} else {
- # backwards compatibility. recognize old src-font name
- if {$val == "src-font"} {set val "global/fixed"}
- pref setd gdb/$section/$name $val
+ # existing font
+ pref set global/font/[join [lrange $name 1 end] /] $val
}
+ } elseif {$section == "global"} {
+ pref setd $section/$name $val
+ } else {
+ pref setd gdb/$section/$name $val
}
}
}
@@ -136,23 +120,9 @@ proc pref_read {} {
} elseif {$home != ""} {
set prefs_init_filename [file join $home $prefs_init_filename]
}
-
+
# now set global options
set gdb_ImageDir [file join $GDBTK_LIBRARY [pref get gdb/ImageDir]]
-
- }
-
- # finally set colors, from system if possible
- if {[pref get gdb/use_color_schemes] != "1"} {
- pref_set_colors $home
- } else {
- global Colors
- # These colors are the same for all schemes
- set Colors(textfg) black
- set Colors(fg) black
- set Colors(sbg) \#4c59a5
- set Colors(sfg) white
- set_bg_colors
}
}
@@ -160,19 +130,17 @@ proc pref_read {} {
# PROC: pref_save - save preferences to a file and delete window
# ------------------------------------------------------------------
proc pref_save {{win {}}} {
- global prefs_init_filename GDBStartup env
+ global prefs_init_filename GDBStartup
- if {!$GDBStartup(inhibit_prefs)
- || [info exists env(INSIGHT_FORCE_READ_PREFERENCES)]} {
+ if {!$GDBStartup(inhibit_prefs)} {
debug "pref_save $prefs_init_filename"
if {[catch {open $prefs_init_filename w} fd]} {
debug "ERROR: $fd"
return
}
-
+
puts $fd "\# GDBtk Init file"
- puts $fd {# GDBtkInitVersion: 1}
set plist [pref list]
# write out global options
@@ -193,32 +161,24 @@ proc pref_save {{win {}}} {
puts $fd "\[gdb\]"
foreach var $plist {
set t [split $var /]
- # We use the funny join/lreplace code because the session code
- # can generate a key where [lindex $t 2] is empty but there is
- # still stuff after that. This happens because the session code
- # uses filenames, which can start with `/'.
- if {[lindex $t 0] == "gdb"
- && [string compare [join [lreplace $t 0 1] /] ""] == 0} {
+ if {[lindex $t 0] == "gdb" && [lindex $t 2] == ""} {
set x [lindex $t 1]
- set v [escape_value [pref get $var]]
- if {$x != "" && $v != ""} {
+ if {$x != ""} {
+ set v [escape_value [pref get $var]]
puts $fd "\t$x=$v"
}
}
}
- # now loop through all sections writing out values
- # FIXME: this is broken. We should discover the list
- # dynamically.
- lappend secs load console src reg stack locals watch bp search \
- process geometry help browser kod window session mem bg ipc
+ #now loop through all sections writing out values
+ lappend secs load console src reg stack locals watch bp search process geometry help browser kod
foreach section $secs {
puts $fd "\[$section\]"
foreach var $plist {
set t [split $var /]
if {[lindex $t 0] == "gdb" && [lindex $t 1] == $section} {
- set x [join [lrange $t 2 end] /]
+ set x [lindex $t 2]
set v [escape_value [pref get $var]]
if {$x != "" && $v != ""} {
puts $fd "\t$x=$v"
@@ -239,45 +199,22 @@ proc pref_save {{win {}}} {
# prefs to a file
# -------------------------------------------------------
proc escape_value {val} {
- # We use a URL-style quoting. We encode `=', `%', the `[]'
- # characters and newlines. We use a cute trick here: we regsub in
- # command expressions which we then expand using subst.
- if {[info tclversion] >= 8.1} {
- set expr {([\[\]=%\n])}
- } else {
- set expr "(\[\]\[=%\n\])"
+
+ if {[regsub -all -- = $val {!%} newval]} {
+ return $newval
}
- regsub -all -- $expr $val \
- {[format "%%%02x" [scan {\1} %c x; set x]]} newval
- return [subst -nobackslashes -novariables $newval]
+
+ return $val
}
# -------------------------------------------------------
# PROC: unescape_value - unescape all equal signs for
-# reading prefs from a file. VERSION is the version
-# number of the encoding.
-# version 0 only encoded `='.
-# version 1 correctly encoded more values
+# reading prefs from a file
# -------------------------------------------------------
-proc unescape_value {val version} {
- switch -exact -- $version {
- 0 {
- # Old-style encoding.
- if {[regsub -all -- {!%} $val = newval]} {
- return $newval
- }
- }
+proc unescape_value {val} {
- 1 {
- # Version 1 uses URL encoding.
- regsub -all -- "%(..)" $val \
- {[format %c 0x\1]} newval
- return [subst -nobackslashes -novariables $newval]
- }
-
- default {
- error "Unknown encoding version $version"
- }
+ if {[regsub -all -- {!%} $val = newval]} {
+ return $newval
}
return $val
@@ -287,8 +224,7 @@ proc unescape_value {val version} {
# PROC: pref_set_defaults - set up default values
# ------------------------------------------------------------------
proc pref_set_defaults {} {
- global GDBTK_LIBRARY gdbtk_platform gdb_ImageDir
- debug
+ global GDBTK_LIBRARY tcl_platform gdb_ImageDir
# Gdb global defaults
pref define gdb/ImageDir images2
@@ -297,19 +233,10 @@ proc pref_set_defaults {} {
pref define gdb/mode 0; # 0 no tracing, 1 tracing enabled
pref define gdb/control_target 1; # 0 can't control target (EMC), 1 can
pref define gdb/B1_behavior 1; # 0 means set/clear breakpoints,
- # 1 means set/clear tracepoints.
+ # 1 means set/clear tracepoints.
pref define gdb/use_icons 1; # For Unix, use gdbtk_icon.gif as an icon
- # some window managers can't deal with it.
+ # some window managers can't deal with it.
- # OS compatibility. Valid values are "Windows", "GNOME", "KDE", and "default"
- if {$gdbtk_platform(platform) == "windows"} {
- pref define gdb/compat "Windows"
- } elseif {$gdbtk_platform(platform) == "unix"} {
- pref define gdb/compat "GNOME"
- } else {
- pref define gdb/compat "default"
- }
-
# set download and execution options
pref define gdb/load/verbose 0
pref define gdb/load/main 1
@@ -318,34 +245,30 @@ proc pref_set_defaults {} {
pref define gdb/load/bp_at_func 0
pref define gdb/load/bp_func ""
pref define gdb/load/baud 38400
- if {$gdbtk_platform(platform) == "windows"} {
+ if {$tcl_platform(platform) == "windows"} {
pref define gdb/load/port com1
} else {
pref define gdb/load/port "/dev/ttyS0"
}
- # The list of active windows:
- pref define gdb/window/active {}
-
# Console defaults
pref define gdb/console/prompt "(gdb) "
pref define gdb/console/deleteLeft 1
pref define gdb/console/wrap 0
pref define gdb/console/prompt_fg DarkGreen
pref define gdb/console/error_fg red
- pref define gdb/console/log_fg green
- pref define gdb/console/target_fg blue
- pref define gdb/console/font global/fixed
+ pref define gdb/console/font src-font
# Source window defaults
pref define gdb/src/PC_TAG green
pref define gdb/src/STACK_TAG gold
pref define gdb/src/BROWSE_TAG \#9595e2
+ pref define gdb/src/active 1
pref define gdb/src/handlebg red
pref define gdb/src/bp_fg red
pref define gdb/src/temp_bp_fg orange
pref define gdb/src/disabled_fg black
- pref define gdb/src/font global/fixed
+ pref define gdb/src/font src-font
pref define gdb/src/break_fg black
pref define gdb/src/source2_fg navy
pref define gdb/src/variableBalloons 1
@@ -353,7 +276,6 @@ proc pref_set_defaults {} {
pref define gdb/src/tab_size 8
pref define gdb/src/linenums 1
pref define gdb/src/thread_fg pink
- pref define gdb/src/top_control 1; # 1 srctextwin controls on top, 0 bottom
# Define the run button's functions. These are defined here in case
# we do a "run" with an exec target (which never causes target.tcl to
@@ -368,15 +290,23 @@ proc pref_set_defaults {} {
pref define gdb/src/disassembly-flavor ""
+ # set up src-font
+ set val [pref get global/font/fixed]
+ eval font create src-font $val
+
+ # Trace the global/font/fixed preference
+ pref add_hook global/font/fixed pref_src-font_trace
+
# Variable Window defaults
- pref define gdb/variable/font global/fixed
+ pref define gdb/variable/font src-font
+ pref define gdb/variable/highlight_fg blue
pref define gdb/variable/disabled_fg gray
# Stack Window
- pref define gdb/stack/font global/fixed
-
+ pref define gdb/stack/font src-font
+
# Register Window
- pref define gdb/reg/rows 16
+ pref define gdb/reg/highlight_fg blue
# Global Prefs Dialogs
pref define gdb/global_prefs/save_fg red
@@ -388,377 +318,26 @@ proc pref_set_defaults {} {
pref define gdb/search/filter_mode "starts with"
pref define gdb/browser/hide_h 0
- pref define gdb/browser/layout 2
+ pref define gdb/browser/width 0
+ pref define gdb/browser/top_height 0
+ pref define gdb/browser/view_height -1
+ pref define gdb/browser/view_is_open 0
# BP (breakpoint)
pref define gdb/bp/show_threads 0
# Help
- pref define gdb/help/browsername ""
+ pref define gdb/help/browser 0
# Kernel Objects (kod)
pref define gdb/kod/show_icon 0
# Various possible "main" functions. What's for Java?
- pref define gdb/main_names [list main MAIN___ MAIN__ cyg_user_start cyg_start ]
-
- # These are the classes of warning dialogs, and whether the user plans
- # to ignore them.
- pref define gdb/warnings/signal 0
-
- # Memory window.
- pref define gdb/mem/size 4
- pref define gdb/mem/numbytes 0
- pref define gdb/mem/format x
- pref define gdb/mem/ascii 1
- pref define gdb/mem/ascii_char .
- pref define gdb/mem/bytes_per_row 16
- pref define gdb/mem/color green
-
- # External editor.
- pref define gdb/editor ""
-
- # background colors
- set ::gdb_bg_num 0
- pref define gdb/use_color_schemes 1
- pref define gdb/bg/0 \#ffffff
- pref define gdb/bg/1 \#ffffd0
- pref define gdb/bg/2 \#ffd0ff
- pref define gdb/bg/3 \#ffd0d0
- pref define gdb/bg/4 \#d0ffff
- pref define gdb/bg/5 \#d0ffd0
- pref define gdb/bg/6 \#d0d0ff
- pref define gdb/bg/7 \#d0d0d0
- pref define gdb/bg/8 \#ffffb0
- pref define gdb/bg/9 \#ffb0ff
- pref define gdb/bg/10 \#ffb0b0
- pref define gdb/bg/11 \#b0ffff
- pref define gdb/bg/12 \#b0ffb0
- pref define gdb/bg/13 \#b0b0ff
- pref define gdb/bg/14 \#b0b0b0
- pref define gdb/bg/15 \#d0b0d0
-
- # IPC prefs
- # set prefs based on GDB version?
- #set vers [lindex [split [lindex [split [gdb_cmd "show version"]] end-1 ] \"] 1]
- pref define gdb/ipc/enabled 0
- pref define gdb/ipc/port 9909
- pref define gdb/ipc/stop_button 1
- pref define gdb/ipc/step_button 1
- pref define gdb/ipc/cont_button 1
- pref define gdb/ipc/run_button 1
- pref define gdb/ipc/exit 1
-}
-
-
-##########################################################################
-#
-# Everything below this point is code to try to determine the current OS
-# color scheme and use that. It mostly works, but is not very compatible
-# with the use of multiple color schemes for different instances of Insight.
-#
-##########################################################################
-proc pref_set_colors {home} {
- # set color palette
-
- # In the past, tk widgets got their color information from Windows or
- # the X resource database. Unfortunately Insight is a mixture of widgets
- # from all over and was coded first in tcl and later in itcl. So lots of
- # color inheritance is broken or wrong. And Insight has some special color
- # requirements. We also have to deal with new Unix desktops that don't use the Xrdb.
- # To enable us to fix that without hardcoding colors, we create a color
- # array here and use it as needed to force widgets to the correct colors.
-
- global Colors
- debug
-
- # UNIX colors
-
- # For KDE3 (and probably earlier versions) when the user sets
- # a color scheme from the KDE control center, the appropriate color
- # information is set in the X resource database. Well, most of it
- # is there but it is missing some settings, so we will carefully
- # adjust things.
- #
- # For GNOME, we read .gtkrc or .gtkrc-1.2-gnome2 and parse it
- # for the color information. We cannot really get this right,
- # but with luck we can read enough to get the colors to mostly match.
-
- # If there is no information, we provide reasonable defaults.
-
- # If some theme sets the text foreground and background to something unusual
- # then Insight won't be able to display sources and highlight things properly.
- # Therefore we will not change the textfg and textbg.
-
- switch [pref get gdb/compat] {
-
- "Windows" {
- debug "loading OS colors for Windows"
- set Colors(fg) SystemButtonText
- set Colors(bg) SystemButtonFace
- #set Colors(textfg) SystemWindowText
- #set Colors(textbg) SystemWindow
- set Colors(textfg) black
- set Colors(textbg) white
- set Colors(sfg) SystemHighlightText
- set Colors(sbg) SystemHighlight
- pref_set_option_db 0
- }
-
- "KDE" {
- debug "loading OS colors for KDE"
-
- pref_load_default
- # try loading "~/.gtkrc-kde"
- if {[pref_load_gnome $home [list .gtkrc-kde]]} {
- debug "loaded gnome file"
- pref_set_option_db 0
- debug "loaded option file"
- } else {
- # no .gtkrc-kde so assume X defaults have been set
-
- # create an empty entry widget so we can query its colors
- entry .e
-
- # text background
- # set Colors(textbg) [option get .e background {}]
- set Colors(textbg) white
-
- # text foreground
- #set Colors(textfg) [option get .e foreground {}]
- set Colors(textfg) black
-
- # background
- set Colors(bg) [option get . background {}]
- if {$Colors(bg) == ""} {set Colors(bg) lightgray}
-
- # foreground
- set Colors(fg) [option get . foreground {}]
- if {$Colors(fg) == ""} {set Colors(fg) black}
-
- # selectBackground
- set Colors(sbg) [option get .e selectBackground {}]
- if {$Colors(sbg) == ""} {set Colors(sbg) blue}
-
- # selectForeground
- set Colors(sfg) [option get .e selectForeground {}]
- if {$Colors(sfg) == ""} {set Colors(sfg) white}
-
- destroy .e
- pref_set_option_db 1
- }
- }
-
- "GNOME" {
- pref_load_default
- pref_load_gnome $home
- pref_set_option_db 0
- }
-
- "default" {
- pref_load_default
- pref_set_option_db 1
- }
- }
-}
-
-proc pref_load_default {} {
- global Colors
- debug "loading default colors"
-
- set Colors(textbg) white
- set Colors(textfg) black
- set Colors(bg) lightgray
- set Colors(fg) black
-
- # selectBackground
- set Colors(sbg) blue
-
- # selectForeground
- set Colors(sfg) white
+ pref define gdb/main_names [list MAIN___ MAIN__ main]
}
-
-# load GNOME colors and fonts, if possible.
-proc pref_load_gnome {home {possible_names {}}} {
- debug "loading OS colors for GNOME"
-
- if {$possible_names == ""} {
- set possible_names {.gtkrc .gtkrc-1.2-gnome2}
- }
-
- set found 0
- foreach name $possible_names {
- debug "home=$home name=$name"
- set fname [file join $home $name]
- debug "fname=$fname"
- if {[file exists $fname]} {
- if {[catch {open $fname r} fd]} {
- dbug W "cannot open $fname: $fd"
- return 0
- }
- set found 1
- break
- }
- }
- if {$found} {
- set found [load_gnome_file $fd]
- close $fd
- }
- return $found
-}
-
-proc load_gnome_file {fd} {
- global Colors
- set found 0
-
- while {[gets $fd line] >= 0} {
- if {[regexp {include \"([^\"]*)} $line foo incname]} {
- debug "include $incname $found"
- if {$found == 0 && [file exists $incname]} {
- if {[catch {open $incname r} fd2]} {
- dbug W "cannot open $incname: $fd2"
- } else {
- set found [load_gnome_file $fd2]
- close $fd2
- if {$found} {
- return $found
- }
- }
- }
- continue
- } elseif {[regexp "\[ \t\n\]*\(.+\) = \(.+\)" $line a name val] == 0} {
- continue
- }
-
- if {[regexp "\"#......\"" $val a] == 1} {
- set val [lindex $a 0]
- } else {
- set res [scan $val "\{ %f, %f, %f \}" r g b]
- if {$res != 3} {
- continue
- }
- set r [expr int($r*255)]
- set g [expr int($g*255)]
- set b [expr int($b*255)]
- set val [format "\#%02x%02x%02x" $r $g $b]
- }
-
- debug "name=\"$name\" val=\"$val\""
-
- # This is a bit of a hack and probably only
- # works for trivial cases. Scan for colors and
- # use the first one found.
- switch [string trimright $name] {
- {bg[NORMAL]} {
- set found 1
- if {![info exists new(bg)]} {
- debug "setting bg to $val"
- set new(bg) $val
- }
- }
- {base[NORMAL]} {
- #if {![info exists new(textbg)]} {
- # set new(textbg) $val
- #}
- }
- {text[NORMAL]} {
- #if {![info exists new(textfg)]} {
- # set new(textfg) $val
- #}
- }
- {fg[NORMAL]} {
- if {![info exists new(fg)]} {
- set new(fg) $val
- }
- }
- {fg[ACTIVE]} {
- if {![info exists new(afg)]} {
- set new(afg) $val
- }
- }
- {bg[SELECTED]} {
- if {![info exists new(sbg)]} {
- set new(sbg) $val
- }
- }
- {base[SELECTED]} {
- if {![info exists new(sbg)]} {
- set new(sbg) $val
- }
- }
- {fg[SELECTED]} {
- if {![info exists new(sfg)]} {
- set new(sfg) $val
- }
- }
- {fg[INSENSITIVE]} {
- if {![info exists new(dfg)]} {
- set new(dfg) $val
- }
- }
- {bg[PRELIGHT]} {
- set Colors(prelight) $val
- }
- {base[PRELIGHT]} {
- set Colors(prelight) $val
- }
- }
- }
-
- foreach c {fg bg sfg sbg dfg} {
- if {[info exists new($c)]} {
- set Colors($c) $new($c)
- }
- }
- return 1
-}
-
-
-# load the colors into the tcl option database
-proc pref_set_option_db {makebg} {
- global Colors
-
- # The color of text that indicates changed items
- # We standardize on one color here so that changed
- # items don't blend into any OS color scheme
- set Colors(change) "green"
-
- option add *background $Colors(bg)
- option add *buttonBackground $Colors(bg)
- option add *Text*background $Colors(textbg)
- option add *Entry*background $Colors(textbg)
- option add *foreground $Colors(fg)
- option add *Text*foreground $Colors(textfg)
- option add *Entry*foreground $Colors(textfg)
-
- option add *highlightBackground $Colors(bg)
- option add *selectBackground $Colors(sbg)
-
- if {$::gdbtk_platform(platform) == "unix"} {
- option add *activeBackground $Colors(sbg)
- }
-
- option add *selectForeground $Colors(sfg)
- option add *Menu*activeForeground $Colors(sfg)
-
- if {[info exists Colors(prelight)]} {
- option add *Button*activeBackground $Colors(prelight)
- }
- if {[info exists Colors(dfg)]} {
- option add *disabledForeground $Colors(dfg)
- }
-
- if {$makebg} {
- # calculate trough and activebackground as 90% of background
- set dbg [recolor $::Colors(bg) 90]
- option add *activeBackground $dbg
- option add *troughColor $dbg
- }
-
- # Change the default select color for checkbuttons, etc to match
- # selectBackground.
- if {$::gdbtk_platform(platform) == "unix"} {
- option add *selectColor $Colors(sbg)
- }
+# This traces the global/fixed font and forces src-font to
+# to be the same.
+proc pref_src-font_trace {varname val} {
+ eval font configure src-font $val
}
diff --git a/gdb/gdbtk/library/process.itb b/gdb/gdbtk/library/process.itb
index 2670b055dfb..07638d5ab4f 100644
--- a/gdb/gdbtk/library/process.itb
+++ b/gdb/gdbtk/library/process.itb
@@ -1,5 +1,5 @@
-# Process window for Insight.
-# Copyright (C) 1998, 1999, 2001, 2002, 2008 Red Hat, Inc.
+# Process window for GDBtk.
+# Copyright 1998, 1999 Cygnus Solutions
#
# This program is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License (GPL) as published by
@@ -18,7 +18,8 @@
#
# ----------------------------------------------------------------------
-itcl::body ProcessWin::constructor {args} {
+body ProcessWin::constructor {args} {
+ set top [winfo toplevel $itk_interior]
window_name "Processes"
gdbtk_busy
@@ -26,45 +27,53 @@ itcl::body ProcessWin::constructor {args} {
gdbtk_idle
# Add hooks for this object
+ add_hook gdb_update_hook [code $this update]
+ add_hook gdb_busy_hook [code $this busy]
add_hook gdb_no_inferior_hook [code $this idle]
+ add_hook gdb_idle_hook [code $this idle]
}
# ------------------------------------------------------------------
# METHOD: build_win - build the main process window
# ------------------------------------------------------------------
-itcl::body ProcessWin::build_win {} {
-
- itk_component add slbox {
- iwidgets::scrolledlistbox $itk_interior.slbox \
- -background $::Colors(bg) \
- -selectbackground $::Colors(sbg) -selectforeground $::Colors(sfg) \
- -textfont global/fixed \
- -exportselection false \
- -selectioncommand [code $this change_context]
- } {}
- [$itk_component(slbox) component listbox] configure \
- -bg $::Colors(textbg) -fg $::Colors(textfg)
- update dummy
-
- pack $itk_component(slbox) -side left -expand yes -fill both
+body ProcessWin::build_win {} {
+ global tixOption tcl_platform
+ if {$tcl_platform(platform) == "windows"} {
+ tixScrolledListBox $itk_interior.s -scrollbar both -sizebox 1
+ } else {
+ tixScrolledListBox $itk_interior.s -scrollbar auto
+ }
+ set lb [$itk_interior.s subwidget listbox]
+ $lb configure -selectmode single -bg $tixOption(input1_bg) \
+ -selectbackground green \
+ -selectforeground black \
+ -font src-font \
+ -exportselection false
+ update
+ balloon register $lb "Click on a line to change context"
+
+ # bind mouse button 1 to change the current context
+ bind $lb <ButtonPress-1> [code $this change_context %y]
+ bind $lb <ButtonRelease-1> break
+
+ pack $itk_interior.s -side left -expand yes -fill both
}
# ------------------------------------------------------------------
# METHOD: update - update widget when something changes
# ------------------------------------------------------------------
-itcl::body ProcessWin::update {event} {
+body ProcessWin::update {} {
if {!$protect_me} {
- $itk_component(slbox) delete 0 end
+ $lb delete 0 end
if {[catch {gdb_cmd "info thread"} threads]} {
# failed. leave window blank
return
}
- set threads [split $threads \n]
- debug "processWin update: \n$threads"
+ #debug "processWin update: \n$threads"
if {[llength $threads] == 0} {
# no processes/threads listed.
return
@@ -73,7 +82,7 @@ itcl::body ProcessWin::update {event} {
# insert each line one at a time
set active -1
set num_threads 0
- foreach line $threads {
+ foreach line [split $threads \n] {
# Active line starts with "*"
if {[string index $line 0] == "*"} {
# strip off leading "*"
@@ -82,7 +91,7 @@ itcl::body ProcessWin::update {event} {
}
# scan for GDB ID number at start of line
if {[scan $line "%d" id($num_threads)] == 1} {
- $itk_component(slbox) insert end $line
+ $lb insert end $line
incr num_threads
}
}
@@ -90,8 +99,8 @@ itcl::body ProcessWin::update {event} {
# highlight the active thread
if {$active >= 0} {
set active_thread $id($active)
- $itk_component(slbox) selection set $active
- $itk_component(slbox) see $active
+ $lb selection set $active
+ $lb see $active
}
}
}
@@ -100,12 +109,12 @@ itcl::body ProcessWin::update {event} {
# METHOD: change_context - change the current context (active thread)
# This method is currently ONLY called from the mouse binding
# ------------------------------------------------------------------
-itcl::body ProcessWin::change_context {} {
- if {!$Running && [$itk_component(slbox) size] != 0} {
+body ProcessWin::change_context {y} {
+ if {!$Running && [$lb size] != 0} {
gdbtk_busy
- set sel [$itk_component(slbox) curselection]
- set idnum $id($sel)
- #debug "change_context to line $sel id=$idnum"
+ set linenum [$lb nearest $y]
+ set idnum $id($linenum)
+ #debug "change_context to line $linenum id=$idnum"
catch {gdb_cmd "thread $idnum"}
# Run idle hooks and cause all widgets to update
set protect_me 1
@@ -118,35 +127,37 @@ itcl::body ProcessWin::change_context {} {
# ------------------------------------------------------------------
# DESTRUCTOR - destroy window containing widget
# ------------------------------------------------------------------
-itcl::body ProcessWin::destructor {} {
+body ProcessWin::destructor {} {
+ remove_hook gdb_update_hook [code $this update]
+ remove_hook gdb_idle_hook [code $this idle]
+ remove_hook gdb_busy_hook [code $this busy]
remove_hook gdb_no_inferior_hook [code $this no_inferior]
}
# ------------------------------------------------------------------
# METHOD: reconfig - used when preferences change
# ------------------------------------------------------------------
-itcl::body ProcessWin::reconfig {} {
+body ProcessWin::reconfig {} {
destroy $itk_interior.s
- if {[winfo exists $itk_interior.slbox]} { destroy $itk_interior.slbox }
build_win
}
# ------------------------------------------------------------------
-# METHOD: busy - BusyEvent handler
+# METHOD: busy - gdb_busy_hook
#
# This method should accomplish blocking
# - clicks in the window
# - change mouse pointer
# ------------------------------------------------------------------
-itcl::body ProcessWin::busy {event} {
+body ProcessWin::busy {} {
set Running 1
cursor watch
}
# ------------------------------------------------------------------
-# METHOD: idle - handle IdleEvent
+# METHOD: idle - idle hook. Run when the target is not running
# ------------------------------------------------------------------
-itcl::body ProcessWin::idle {event} {
+body ProcessWin::idle {} {
set Running 0
cursor {}
}
@@ -156,6 +167,6 @@ itcl::body ProcessWin::idle {event} {
# This is a convenience method which simply sets the mouse
# pointer to the given glyph.
# ------------------------------------------------------------------
-itcl::body ProcessWin::cursor {glyph} {
- $_top configure -cursor $glyph
+body ProcessWin::cursor {glyph} {
+ $top configure -cursor $glyph
}
diff --git a/gdb/gdbtk/library/process.ith b/gdb/gdbtk/library/process.ith
index 5e1106ac92f..d9b8fece4ee 100644
--- a/gdb/gdbtk/library/process.ith
+++ b/gdb/gdbtk/library/process.ith
@@ -1,5 +1,5 @@
-# Process window class definition for Insight.
-# Copyright (C) 1998, 1999, 2001 Red Hat, Inc.
+# Process window class definition for GDBtk.
+# Copyright 1998, 1999 Cygnus Solutions
#
# This program is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License (GPL) as published by
@@ -12,30 +12,29 @@
# GNU General Public License for more details.
-itcl::class ProcessWin {
+class ProcessWin {
inherit EmbeddedWin GDBWin
private {
+ variable top
+ variable lb
variable id
variable Running 0
variable protect_me 0
method build_win {}
- method change_context {}
+ method change_context {y}
method cursor {glyph}
+ method change_frame {y}
+ method update {}
+ method busy {}
+ method idle {}
}
public {
method reconfig {}
method constructor {args}
method destructor {}
-
- #
- # GDB Events
- #
- method busy {event}
- method idle {event}
- method update {event}
}
-}
+} \ No newline at end of file
diff --git a/gdb/gdbtk/library/regwin.itb b/gdb/gdbtk/library/regwin.itb
index 54e515f41b8..2515498c06e 100644
--- a/gdb/gdbtk/library/regwin.itb
+++ b/gdb/gdbtk/library/regwin.itb
@@ -1,8 +1,5 @@
-# Register display window for Insight.
-# Copyright (C) 1998, 1999, 2001, 2002, 2003, 2004, 2007 Red Hat, Inc.
-#
-# Written by Keith Seitz (keiths@redhat.com)
-# and Martin Hunt (hunt@redhat.com)
+# Register display window for GDBtk.
+# Copyright 1998, 1999 Cygnus Solutions
#
# This program is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License (GPL) as published by
@@ -14,1038 +11,575 @@
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
-# TODO
-#
-# Must fix:
-# o Edit menus -- weirdo interaction with tkTable. Seems okay on windows.
-# Needs more testing on unix (popup edit menu item).
-#
-# Want really badly:
-# o Multiple selections
-# o Multiple displays
-# o Better resizing
-# o Register groups (gdb and user-defined)
-# o format register values before inserting into table?
-# (Instead of displaying "0x0", we should use "0x00000000" on
-# machines with 32-bit regs, "0x0000000000000000" on machines
-# with 64-bit regs, etc. Maybe user-defined formats, i.e.,
-# "0x0000 0000 0000 0000 0000 0000"?)
# ------------------------------------------------------------------
-# NAME: RegWin::constructor
-# DESCRIPTION: Create a new register window
-#
-# ARGUMENTS: None
-# RETURNS: Nothing
+# CONSTRUCTOR - create new register window
# ------------------------------------------------------------------
-itcl::body RegWin::constructor {args} {
-
- eval itk_initialize $args
-
+body RegWin::constructor {args} {
+ global tixOption
+ debug "RegWin::constructor"
+ wm withdraw [winfo toplevel $itk_interior]
gdbtk_busy
-
- window_name "Registers" "Regs"
- _build_win
- _layout_table
-
- # Clear gdb's changed list
- catch {gdb_reginfo changed}
-
+
+ set NormalForeground $tixOption(fg)
+ set HighlightForeground [pref get gdb/reg/highlight_fg]
+
+ if {[pref getd gdb/reg/menu] != ""} {
+ set mbar 0
+ }
+
+ init_reg_display_vars 1
+ build_win
+ eval itk_initialize $args
+
gdbtk_idle
+ add_hook gdb_update_hook "$this update"
+ add_hook gdb_busy_hook [list $this busy]
+ add_hook gdb_idle_hook [list $this idle]
+ if {[get_disassembly_flavor] != ""} {
+ add_hook gdb_set_hook [code $this handle_set_hook]
+ }
}
# ------------------------------------------------------------------
-# NAME: RegWin::destructor
-# DESCRIPTION: Destroys the register window
-#
-# ARGUMENTS: None
-# RETURNS: Nothing
+# DESTRUCTOR - destroy window containing widget
# ------------------------------------------------------------------
-itcl::body RegWin::destructor {} {
- debug
+body RegWin::destructor {} {
+ debug "RegWin::destructor"
+ remove_hook gdb_update_hook "$this update"
+ remove_hook gdb_busy_hook [list $this busy]
+ remove_hook gdb_idle_hook [list $this idle]
+ if {[get_disassembly_flavor] != ""} {
+ remove_hook gdb_set_hook [code $this handle_set_hook]
+ }
}
+
+
# ------------------------------------------------------------------
-# NAME: RegWin::_load_prefs
-# DESCRIPTION: Load register preferences
-#
-# ARGUMENTS: None
-# RETURNS: Nothing
+# METHOD: build_win - build the main register window
# ------------------------------------------------------------------
-itcl::body RegWin::_load_prefs {} {
- debug
-
- # Find out largest register name length.
- set _max_label_width 0; # for reg labels
- set _reg_display_list {}
- set _register(hidden) {}
-
- set regs [gdb_reginfo group $_group]
- foreach r [gdb_reginfo name -numbers $regs] {
- set nm [lindex $r 0]
- set rn [lindex $r 1]
- set size [string length $nm]
- if {$size > $_max_label_width} {
- set _max_label_width $size
+body RegWin::build_win {} {
+ global reg_display tixOption tcl_platform
+
+ set dim [dimensions]
+ set nRows [lindex $dim 0]
+ set nCols [lindex $dim 1]
+ if {$tcl_platform(platform) == "windows"} {
+ tixScrolledWindow $itk_interior.scrolled -scrollbar both -sizebox 1
+ } else {
+ tixScrolledWindow $itk_interior.scrolled -scrollbar auto
+ }
+ set ScrolledWin [$itk_interior.scrolled subwidget window]
+ # Create labels
+ set row 0
+ set col 0
+
+ set regMaxLen 0
+ foreach r [gdb_regnames] {
+ set l [string length $r]
+ if {$l > $regMaxLen} {
+ set regMaxLen $l
}
-
- # Set type from prefs or default to first in list of types
- set _types($rn) [gdb_reginfo type $rn]
- set tp [pref getd gdb/reg/${nm}-type]
- set _type($rn,name) ""
- if {$tp != ""} {
- foreach t $_types($rn) {
- if {[lindex $t 0] == $tp} {
- set _type($rn,name) $tp
- set _type($rn,addr) [lindex $t 1]
- set _type($rn,code) [lindex $t 2]
- break
- }
- }
+ }
+
+ set vmax 0
+ foreach r $reg_display_list {
+ if {[catch {gdb_fetch_registers $reg_display($r,format) $r} values($r)]} {
+ set values($r) ""
+ } else {
+ set values($r) [string trim $values($r) \ ]
}
- if {$_type($rn,name) == ""} {
- # either not set or couldn't find it in list of types
- set _type($rn,name) [lindex [lindex $_types($rn) 0] 0]
- set _type($rn,addr) [lindex [lindex $_types($rn) 0] 1]
- set _type($rn,code) [lindex [lindex $_types($rn) 0] 2]
+ set l [string length $values($r)]
+ if {$l > $vmax} {
+ set vmax $l
}
-
- # Check preferences for format
- set _format($rn) [pref getd gdb/reg/${nm}-format]
- if {$_format($rn) == ""} {
- # no preference set. Set it to hex or float
- if {$_type($rn,code) == "int"} {
- set _format($rn) "x"
- } else {
- set _format($rn) "f"
- }
- pref setd gdb/reg/${nm}-format $_format($rn)
+ }
+
+ foreach r $reg_display_list {
+ if {$row == $nRows} {
+ grid columnconfigure $ScrolledWin $col -weight 1
+ set row 0
+ incr col
}
- gdb_reginfo format $rn $_type($rn,addr) $_format($rn)
-
- # Check if the user prefers not to show this register
- if {[pref getd gdb/reg/$nm] == "no"} {
- set _cell($rn) hidden
- lappend _register(hidden) $rn
- } else {
- lappend _reg_display_list $rn
+ frame $ScrolledWin.$r -takefocus 1
+ bind $ScrolledWin.$r <Up> "$this reg_select_up"
+ bind $ScrolledWin.$r <Down> "$this reg_select_down"
+ bind $ScrolledWin.$r <Tab> "$this reg_select_down"
+ bind $ScrolledWin.$r <Left> "$this reg_select_left"
+ bind $ScrolledWin.$r <Right> "$this reg_select_right"
+ if {![pref get gdb/mode]} {
+ bind $ScrolledWin.$r <Return> "$this edit $r"
}
-
- # assume editable, for now
- set _editable($rn) 1
- }
-
- incr _max_label_width 2; # padding
-}
-
-
-#
-# Table layout/display methods
-#
-
-# ------------------------------------------------------------------
-# NAME: private method RegWin::_build_win
-# DESCRIPTION: Builds the register window from widgets
-#
-# ARGUMENTS: None
-# RETURNS: Nothing
-#
-# NOTES: This method should only be called once for
-# each RegWin. To change the layout of the table
-# in the window, use RegWin::_layout_table.
-# ------------------------------------------------------------------
-itcl::body RegWin::_build_win {} {
-
- # Create scrollbars and table
- itk_component add vscroll {
- scrollbar $itk_interior.vs -orient vertical
- }
- itk_component add hscroll {
- scrollbar $itk_interior.hs -orient horizontal
- }
-
- itk_component add table {
- ::table $itk_interior.tbl -variable [scope _data] \
- -browsecmd [code $this _select_cell %S] -font global/fixed \
- -colstretch unset -rowstretch unset -selectmode single \
- -resizeborders none -multiline false -colwidth 18 \
- -autoclear 0 -bg $::Colors(bg) \
- -padx 5 -xscrollcommand [code $itk_component(hscroll) set] \
- -yscrollcommand [code $itk_component(vscroll) set]
- } {
- keep -foreground
- keep -insertbackground
- keep -highlightcolor
- keep -highlightbackground
- }
- bind $itk_component(table) <Up> \
- [format "%s; break" [code $this _move up]]
- bind $itk_component(table) <Down> \
- [format "%s; break" [code $this _move down]]
- bind $itk_component(table) <Left> \
- [format "%s; break" [code $this _move left]]
- bind $itk_component(table) <Right> \
- [format "%s; break" [code $this _move right]]
- bind $itk_component(table) <3> \
- [code $this _but3 %x %y %X %Y]
- bind $itk_component(table) <Double-1> break
- bind $itk_component(table) <1> \
- [code $this _edit %x %y]
- bind $itk_component(table) <Return> \
- [format "%s; break" [code $this _accept_edit]]
- bind $itk_component(table) <KP_Enter> \
- [format "%s; break" [code $this _accept_edit]]
- bind $itk_component(table) <Escape> \
- [code $this _unedit]
-
- $itk_component(hscroll) configure -command [code $itk_component(table) xview]
- $itk_component(vscroll) configure -command [code $itk_component(table) yview]
-
-
- # Create/configure tags for various display styles
- # normal - the "normal" display style
- # highlight - changed registers are highlighted
- # sel - the selection fg/bg should conform to standard
- # header - used on the register name cells and empty cells
- # edit - used on a cell being edited
- $itk_component(table) tag configure normal \
- -state disabled -bg $::Colors(textbg) -fg $::Colors(textfg)
- $itk_component(table) tag configure sel -bg $::Colors(sbg) -fg $::Colors(sfg)
- $itk_component(table) tag configure highlight -bg $::Colors(change) -fg black
- $itk_component(table) tag raise highlight
- $itk_component(table) tag configure header \
- -anchor w -state disabled -relief raised
- $itk_component(table) tag configure disabled \
- -state disabled
- $itk_component(table) tag raise active
- $itk_component(table) tag configure edit \
- -state normal
- $itk_component(table) tag raise edit
- $itk_component(table) tag raise sel
-
- itk_component add frame {
- frame $itk_interior.m
+
+ label $ScrolledWin.$r.lbl -text [fixLength $reg_display($r,name) $regMaxLen left] \
+ -relief solid -bd 1 -font src-font
+ label $ScrolledWin.$r.val -anchor e -text [fixLength $values($r) $vmax right] \
+ -relief ridge -bd 1 -font src-font -bg $tixOption(input1_bg)
+
+ grid $ScrolledWin.$r.lbl $ScrolledWin.$r.val -sticky nsew
+ grid columnconfigure $ScrolledWin.$r 1 -weight 1
+ grid $ScrolledWin.$r -colum $col -row $row -sticky nsew
+ # grid rowconfigure $ScrolledWin $row -weight 1
+ bind $ScrolledWin.$r.val <1> "$this reg_select $r"
+ bind $ScrolledWin.$r.lbl <1> "$this reg_select $r"
+ bind $ScrolledWin.$r.val <3> "$this but3 $r %X %Y"
+ bind $ScrolledWin.$r.lbl <3> "$this but3 $r %X %Y"
+ if {![pref get gdb/mode]} {
+ bind $ScrolledWin.$r.lbl <Double-1> "$this edit $r"
+ bind $ScrolledWin.$r.val <Double-1> "$this edit $r"
+ }
+ incr row
}
- iwidgets::optionmenu $itk_component(frame).opt -labeltext "Group:" \
- -labelpos w -command [code $this _select_group]
- eval $itk_component(frame).opt insert end [gdb_reginfo grouplist]
- $itk_component(frame).opt select "all"
+ grid columnconfigure $ScrolledWin $col -weight 1
- pack $itk_component(frame).opt -anchor nw
- grid $itk_component(frame) -row 0 -columnspan 2 -sticky news
- grid $itk_component(table) -row 1 -column 0 -sticky news
- grid $itk_component(vscroll) -row 1 -column 1 -sticky ns
- grid $itk_component(hscroll) -row 2 -column 0 -sticky ew
- grid columnconfigure $itk_interior 0 -weight 1
- grid rowconfigure $itk_interior 0 -weight 0
- grid rowconfigure $itk_interior 1 -weight 1
-
- # Add popup menu - we populate it in the event handler
- itk_component add popup {
- menu $itk_interior.pop -tearoff 0
- } {}
-}
-
-# ------------------------------------------------------------------
-# NAME: private method RegWin::_layout_table
-# DESCRIPTION: Configures and lays out the table
-#
-# ARGUMENTS: None
-# RETURNS: Nothing
-#
-# NOTES: Uses preferences to determine if/how a register
-# is displayed
-# ------------------------------------------------------------------
-itcl::body RegWin::_layout_table {} {
- debug
-
- if {[info exists _cell]} {
- unset _cell
- unset _register
- }
- # Clear any column spans
- foreach span [$itk_component(table) spans] {
- $itk_component(table) spans $span 0,0
- }
-
- _load_prefs
-
- # Fill data array with register names.
- #
- # The table is indexed by (row,col). All odd columns will contain
- # register values and all even columns will contain the labels.
- #
- set x 0
- set y 0
-
- # get register list
- set regs [gdb_reginfo name -numbers $_reg_display_list]
-
- # Set table dimensions
- set num [llength $regs]
- set _rows [pref get gdb/reg/rows]
- set _cols [expr $num / $_rows]
- if {[expr $num % $_rows] != 0} { incr _cols }
- set _cols [expr 2 * $_cols]
- $itk_component(table) configure -cols $_cols -rows $_rows
-
- # get values
- if {[catch {gdb_reginfo value $_reg_display_list} values]} {
- dbug W "values=$values"
- set values ""
- }
- set i 0
-
- # now build table
- foreach r $regs {
- set name [lindex $r 0]
- set rn [lindex $r 1]
-
- set _cell($rn) "$y,[expr {$x+1}]"
- set _register($_cell($rn)) $rn
- set _data($y,$x) $name
- set _data($_cell($rn)) [lindex $values $i]
- incr i
-
- # Go to next row/column
- incr y
- if {$y == $_rows} {
- set _col_size([expr {$x+1}]) 0
-
- # Size the column
- if {$::gdb_running} {
- _size_column [expr {$x+1}] 1
- }
-
- $itk_component(table) width $x $_max_label_width
- $itk_component(table) tag col header $x
- $itk_component(table) tag col normal [expr {$x+1}]
-
- set y 0
- incr x 2
+
+ if { $mbar } {
+ menu $itk_interior.m -tearoff 0
+ [winfo toplevel $itk_interior] configure -menu $itk_interior.m
+ $itk_interior.m add cascade -menu $itk_interior.m.reg -label "Register" -underline 0
+ set m [menu $itk_interior.m.reg]
+ if {![pref get gdb/mode]} {
+ $m add command -label "Edit" -underline 0 -state disabled
}
+ $m add cascade -menu $itk_interior.m.reg.format -label "Format" -underline 0
+ set f [menu $itk_interior.m.reg.format]
+ $f add radio -label "Hex" -value x -underline 0 -state disabled \
+ -command "$this update"
+ $f add radio -label "Decimal" -value d -underline 0 -state disabled \
+ -command "$this update"
+ $f add radio -label "Natural" -value {} -underline 0 -state disabled \
+ -command "$this update"
+ $f add radio -label "Binary" -value t -underline 0 -state disabled \
+ -command "$this update"
+ $f add radio -label "Octal" -value o -underline 0 -state disabled \
+ -command "$this update"
+ $f add radio -label "Raw" -value r -underline 0 -state disabled \
+ -command "$this update"
+ $m add command -label "Remove from Display" -underline 0 -state disabled
+ $m add separator
+ $m add command -label "Display All Registers" -underline 0 -state disabled \
+ -command "$this display_all"
}
+
+ set Menu [menu $ScrolledWin.pop -tearoff 0]
+ set disabled_fg [$Menu cget -fg]
+ $Menu configure -disabledforeground $disabled_fg
+
+ # Clear gdb's changed list
+ catch {gdb_changed_register_list}
+
+ pack $itk_interior.scrolled -anchor nw -fill both -expand yes
+
+ window_name "Registers" "Regs"
+}
- # Mark empty cells
- while {$y != $_rows && $x != $_cols} {
- set _data($y,$x) ""
- set _data($y,[expr {$x+1}]) ""
- $itk_component(table) spans $y,$x 0,1
- $itk_component(table) tag cell header $y,$x
- set _col_size([expr {$x+1}]) 0
-
- incr y
- if {$y == $_rows} {
- # Size the column
- if {$::gdb_running} {
- _size_column [expr {$x+1}] 1
- }
- $itk_component(table) width $x $_max_label_width
- $itk_component(table) tag col header $x
- $itk_component(table) tag col normal [expr {$x+1}]
-
- set y 0
- incr x 2
+# ------------------------------------------------------------------------------
+# NAME: init_reg_display_vars
+# DESC: Initialize the list of registers displayed.
+# args - not used
+# RETURNS:
+# NOTES:
+# ------------------------------------------------------------------------------
+body RegWin::init_reg_display_vars {args} {
+ global reg_display max_regs
+ set reg_display_list {}
+ set regnames [gdb_regnames]
+ set i 1
+ set rn 0
+ foreach r $regnames {
+ set reg_display($rn,name) $r
+ set format [pref getd gdb/reg/$r-format]
+ if {$format == ""} { set format x }
+ set reg_display($rn,format) $format
+ if {$args != "" && [pref getd gdb/reg/$r] == "no"} {
+ set reg_display($rn,line) 0
+ } else {
+ set reg_display($rn,line) $i
+ lappend reg_display_list $rn
+ incr i
}
+ incr rn
}
+ set num_regs [expr {$i - 1}]
+ set max_regs $rn
+ set reg_names_dirty 0
}
-# ------------------------------------------------------------------
-# NAME: private method RegWin::_size_cell_column
-# DESCRIPTION: Resize the column for a given cell.
-#
-# ARGUMENTS:
-# cell - the cell whose column is to be resized
-# down - whether the resizing should size the column
-# down or just up.
-# RETURNS: Nothing
-#
-# NOTES: See _size_column for the reasoning for the "down"
-# option.
-# ------------------------------------------------------------------
-itcl::body RegWin::_size_cell_column {cell down} {
-
- set col [string trim [lindex [split $cell ,] 1] ()]
- _size_column $col $down
-}
-
-# ------------------------------------------------------------------
-# NAME: private method RegWin::_size_column
-# DESCRIPTION: Resize the given column
-#
-# ARGUMENTS:
-# col - the column to be resized
-# down - whether the resizing should size the column
-# RETURNS: down or just up.
-#
-# NOTES: The down option allows column sizes to change down
-# as well as up. For most cases, this is what is
-# wanted. However, when the user is stepping, it is
-# really annoying to see the column sizes changing.
-# It's bad enough we must size up, but going down
-# is just too much. Consequently, when updating the
-# contents of the table, we specify that the columns
-# should not downsize. This helps mitigate the
-# annoyance.
-# ------------------------------------------------------------------
-itcl::body RegWin::_size_column {col down} {
-
- set max 0
- foreach cell [array names _data *,$col] {
- set len [string length $_data($cell)]
- if {$len > $max} { set max $len }
- }
-
- if {($down && $max != $_col_size($col))
- || (!$down && $max > $_col_size($col))} {
- set _col_size($col) $max
- $itk_component(table) width $col [expr {$max + 2}]
-
- # Force the table to update itself
- after idle event generate $itk_component(table) <Configure> \
- -width [winfo width $itk_component(table)]
+body RegWin::handle_set_hook {var value} {
+ switch $var {
+ disassembly-flavor {
+ disassembly_changed
+ }
}
}
-# ------------------------------------------------------------------
-# NAME: private method RegWin::reconfig
-# DESCRIPTION: Reconfigures register window when a preference
-# changes.
-#
-# ARGUMENTS: None
-# RETURNS: Nothing
-#
-# ------------------------------------------------------------------
-itcl::body RegWin::reconfig {} {
- $itk_component(table) tag configure normal \
- -state disabled -bg $::Colors(textbg) -fg $::Colors(textfg)
+body RegWin::disassembly_changed {} {
+ set reg_names_dirty 1
}
-
-
-#
-# Table event handlers and related methods
-#
-
-# ------------------------------------------------------------------
-# NAME: private method RegWin::_accept_edit
-# DESCRIPTION: Change a register's value
-#
-# ARGUMENTS: None
-# RETURNS: Nothing
-#
-# NOTES: Event handler for <Enter> and <KP_Enter>
-# in table
-# ------------------------------------------------------------------
-itcl::body RegWin::_accept_edit {} {
- debug
- set cell [$itk_component(table) tag cell edit]
- if {[llength $cell] == 1 && [info exists _register($cell)]} {
- # Select the same cell again. This forces the table
- # to keep this value. Otherwise, we'll never see it...
- _select_cell $cell
- set rn $_register($cell)
- set n [gdb_reginfo name $rn]
- if {[llength $_types($rn)] > 1} {
- append n ".$_type($rn,name)"
- }
- set v [string trim [$itk_component(table) curvalue] \ \r\n]
- debug "n=$n v=$v"
- if {$v != ""} {
- if {[catch {gdb_cmd "set \$${n}=$v"} result]} {
- tk_messageBox -icon error -type ok -message $result \
- -title "Error in Expression" -parent $_top
+# ------------------------------------------------------------------------------
+# NAME: save_reg_display_vars
+# DESC: save the list of displayed registers to the preferences file.
+# ------------------------------------------------------------------------------
+body RegWin::save_reg_display_vars {} {
+ global reg_display max_regs
+ set rn 0
+ while {$rn < $max_regs} {
+ set name $reg_display($rn,name)
+ if {$reg_display($rn,line) == 0} {
+ pref setd gdb/reg/$name no
+ } else {
+ pref setd gdb/reg/$name {}
}
+ if {$reg_display($rn,format) != "x"} {
+ pref setd gdb/reg/$name-format $reg_display($rn,format)
+ } else {
+ pref setd gdb/reg/$name-format {}
}
-
- # Always update the register, even for error conditions. This
- # will ensure that the cell's old value is restored to the table.
- _update_register $_register($cell)
- _size_cell_column $cell 1
+ incr rn
}
-
- _unedit
+ pref_save ""
}
# ------------------------------------------------------------------
-# NAME: private method RegWin::_add_to_watch
-# DESCRIPTION: Add a register to the watch window
-#
-# ARGUMENTS: rn - the register number to add to the WatchWin
-# RETURNS: Nothing
-#
-# NOTES: Only works with one WatchWin...
+# PUBLIC METHOD: reg_select_up
# ------------------------------------------------------------------
-itcl::body RegWin::_add_to_watch {rn} {
- [ManagedWin::open WatchWin] add "\$[gdb_reginfo name $rn]"
+body RegWin::reg_select_up { } {
+ if { $selected == -1 || $Running} {
+ return
+ }
+ set current_index [lsearch -exact $reg_display_list $selected]
+ set new_reg [lindex $reg_display_list [expr {$current_index - 1}]]
+ if { $new_reg != {} } {
+ $this reg_select $new_reg
+ }
}
# ------------------------------------------------------------------
-# NAME: private method RegWin::_add_to_watch
-# DESCRIPTION: Add a register to the watch window
-#
-# ARGUMENTS: rn - the register number to add to the WatchWin
-# RETURNS: Nothing
-#
-# NOTES: Only works with one WatchWin...
+# PUBLIC METHOD: reg_select_down
# ------------------------------------------------------------------
-itcl::body RegWin::_open_memory {rn} {
- ManagedWin::open MemWin -force -addr_exp $_data($_cell($rn))
+body RegWin::reg_select_down { } {
+ if { $selected == -1 || $Running} {
+ return
+ }
+ set current_index [lsearch -exact $reg_display_list $selected]
+ set new_reg [lindex $reg_display_list [expr {$current_index + 1}]]
+ if { $new_reg != {} } {
+ $this reg_select $new_reg
+ }
}
# ------------------------------------------------------------------
-# NAME: private method RegWin::_but3
-# DESCRIPTION: Configure the popup menu before posting it
-#
-# ARGUMENTS: x - x-coordinate of buttonpress
-# y - y-coordinate
-# X - x-root coordinate
-# Y - y-root coordinate
-# RETURNS: Nothing
+# PUBLIC METHOD: reg_select_right
# ------------------------------------------------------------------
-itcl::body RegWin::_but3 {x y X Y} {
-
- # Only post the menu when we're not executing the inferior,
- # the inferior is in a runnable state, and we're not in a disabled
- # cell.
- if {!$_running && $::gdb_running} {
-
- # Select the register
- set cell [_select_cell [$itk_component(table) index @$x,$y]]
- if {[info exists _register($cell)]} {
- set rn $_register($cell)
- set name [gdb_reginfo name $rn]
- $itk_component(popup) delete 0 end
- $itk_component(popup) add command -label $name -state disabled
- $itk_component(popup) add separator
- if {[llength $_types($rn)] > 1} {
- foreach t $_types($rn) {
- $itk_component(popup) add radio -label [lindex $t 0] \
- -variable [scope _type($rn,addr)] \
- -value [lindex $t 1] \
- -command [code $this _change_format $rn [lindex $t 0]]
- }
- $itk_component(popup) add separator
- }
-
- $itk_component(popup) add radio -label "Hex" \
- -variable [scope _format($rn)] -value x \
- -command [code $this _change_format $rn]
-
- if {$_type($rn,code) == "int"} {
- $itk_component(popup) add radio -label "Decimal" \
- -variable [scope _format($rn)] -value d \
- -command [code $this _change_format $rn]
- $itk_component(popup) add radio -label "Unsigned" \
- -variable [scope _format($rn)] -value u \
- -command [code $this _change_format $rn]
- } elseif {$_type($rn,code) == "float"} {
- $itk_component(popup) add radio -label "Floating Point" \
- -variable [scope _format($rn)] -value f \
- -command [code $this _change_format $rn]
- }
- $itk_component(popup) add separator
-
- if {$_editable($rn)} {
- set state normal
- } else {
- set state disabled
- }
-
- if {$_type($rn,code) == "int"} {
- $itk_component(popup) add command \
- -label "Open Memory Window" -command [code $this _open_memory $rn]
- }
- $itk_component(popup) add command \
- -label "Add to Watch" -command [code $this _add_to_watch $rn]
- $itk_component(popup) add separator
- $itk_component(popup) add command \
- -label "Remove from Display" \
- -command [code $this _delete_from_display $rn]
- if {[llength $_register(hidden)] != 0} {
- $itk_component(popup) add command -label "Display all Registers" \
- -command [code $this _display_all]
- }
-
- # Help
- $itk_component(popup) add separator
- $itk_component(popup) add command \
- -label "Help" -command {open_help register.html}
-
- # Close
- $itk_component(popup) add separator
- $itk_component(popup) add command -label "Close" \
- -underline 0 -command [code delete object $this]
-
- tk_popup $itk_component(popup) $X $Y
- }
+body RegWin::reg_select_right { } {
+ if { $selected == -1 || $Running} {
+ return
+ }
+ set current_index [lsearch -exact $reg_display_list $selected]
+ set new_reg [lindex $reg_display_list [expr {$current_index + $nRows}]]
+ if { $new_reg != {} } {
+ $this reg_select $new_reg
}
}
# ------------------------------------------------------------------
-# NAME: private method RegWin::_delete_from_display
-# DESCRIPTION: Remove a register from the display
-#
-# ARGUMENTS: rn - the register number to remove
-# RETURNS: Nothing
+# PUBLIC METHOD: reg_select_left
# ------------------------------------------------------------------
-itcl::body RegWin::_delete_from_display {rn} {
-
- # Mark the cell as hidden
- set index [lsearch $_reg_display_list $rn]
- if {$index != -1} {
- pref setd gdb/reg/[gdb_reginfo name $rn] no
- set _reg_display_list [lreplace $_reg_display_list $index $index]
-
- # Relayout table
- _layout_table
+body RegWin::reg_select_left { } {
+ if { $selected == -1 || $Running} {
+ return
+ }
+ set current_index [lsearch -exact $reg_display_list $selected]
+ set new_reg [lindex $reg_display_list [expr {$current_index - $nRows}]]
+ if { $new_reg != {} } {
+ $this reg_select $new_reg
}
}
# ------------------------------------------------------------------
-# NAME: private method RegWin::_display_all
-# DESCRIPTION: Display all registers in the window
-#
-# ARGUMENTS: None
-# RETURNS: Nothing
+# PUBLIC METHOD: reg_select - select a register
# ------------------------------------------------------------------
-itcl::body RegWin::_display_all {} {
-
- # Unhide all hidden registers
- foreach r $_register(hidden) {
- pref setd gdb/reg/[gdb_reginfo name $r] {}
+body RegWin::reg_select { r } {
+ global tixOption
+
+ if {$Running} { return }
+ if {$selected != -1} {
+ catch {$ScrolledWin.$selected.lbl configure -fg $tixOption(fg) -bg $tixOption(bg)}
+ catch {$ScrolledWin.$selected.val configure -fg $tixOption(fg) \
+ -bg $tixOption(input1_bg)}
}
-
- # Note which register is active and restore it
- if {[catch {$itk_component(table) index active} cell]} {
- set active {}
- } else {
- set active $_register($cell)
+
+ # if we click on the same line, unselect it and return
+ if {$selected == $r} {
+ set selected -1
+ $itk_interior.m.reg entryconfigure 0 -state disabled
+ $itk_interior.m.reg entryconfigure 2 -state disabled
+ for {set i 0} {$i < 6} {incr i} {
+ $itk_interior.m.reg.format entryconfigure $i -state disabled
+ }
+ return
+ }
+
+ if {$Editing != -1} {
+ unedit
+ }
+
+ $ScrolledWin.$r.lbl configure -fg $tixOption(select_fg) -bg $tixOption(select_bg)
+ $ScrolledWin.$r.val configure -fg $tixOption(fg) -bg $tixOption(bg)
+
+ if {![pref get gdb/mode]} {
+ $itk_interior.m.reg entryconfigure 0 -state normal -command "$this edit $r"
}
- _layout_table
- if {$active != ""} {
- $itk_component(table) activate $_cell($active)
+ $itk_interior.m.reg entryconfigure 2 -state normal \
+ -command "$this delete_from_display_list $r"
+ for {set i 0} {$i < 6} {incr i} {
+ $itk_interior.m.reg.format entryconfigure $i -state normal \
+ -variable reg_display($r,format)
}
+ focus -force $ScrolledWin.$r
+ set selected $r
}
# ------------------------------------------------------------------
-# NAME: private method RegWin::_edit
-# DESCRIPTION: Enables a cell for editing
-#
-# ARGUMENTS:
-# x - the x coordinate of the button press
-# y - the y coordinate of the button press
-# RETURNS: Nothing
-#
-# NOTES: Event handler for <1> in table.
-#
+# PRIVATE METHOD: dimensions - determine square-like dimensions for
+# register window
# ------------------------------------------------------------------
-itcl::body RegWin::_edit {x y} {
- _select_cell [$itk_component(table) index @$x,$y]
+body RegWin::dimensions {} {
+ set rows 16
+ # set rows [expr int(floor(sqrt($num_regs)))]
+ set cols [expr {int(ceil(sqrt($num_regs)))}]
+
+ return [list $rows $cols]
}
+# ------------------------------------------------------------------------------
+# NAME:
+# private method RegWin::fixLength
+#
+# SYNOPSIS:
+# fixLength {s size where}
+#
+# DESC:
+# Makes a string into a fixed-length string, inserting spaces as
+# necessary. If 'where' is "left" spaces will be added to the left,
+# if 'where' is "right" spaces will be added to the right.
+# ARGS:
+# s - input string
+# size - size of string to output
+# where - "left" or "right"
+#
+# RETURNS:
+# Padded string of length 'size'
+#
+# NOTES:
+# This should really be a proc, not a method.
+# ------------------------------------------------------------------------------
+body RegWin::fixLength {s size where} {
+ set blank " "
+ set len [string length $s]
+ set bl [expr {$size - $len}]
+ set b [string range $blank 0 $bl]
+
+ switch $where {
+ left { set fl "$s$b"}
+ right { set fl "$b$s"}
+ }
+ return $fl
+}
# ------------------------------------------------------------------
-# NAME: private method _move
-# DESCRIPTION: Handle arrow key events in table
-#
-# ARGUMENTS: direction - "up", "down", "left", "right"
-# RETURNS: Nothing
-#
-# NOTES: Event handler for <Up>, <Down>, <Left>, <Right>
-# in table. This is needed because the table
-# has some rather strange bindings for moving
-# the insertion cursor when editing a cell.
-# This method will move to the next cell when
-# we're not editing, or it will move the icursor
-# if we are editing.
+# PUBLIC METHOD: but3 - generate and display a popup window on button 3
+# over the register value
# ------------------------------------------------------------------
-itcl::body RegWin::_move {direction} {
-
- debug $direction
-
- # If there is no active cell, the table will call error
- if {[catch {$itk_component(table) index active row} row]} {
- return
- }
-
- if {[$itk_component(table) tag cell edit] != ""} {
- # Editing
-
- switch $direction {
- up {
- # Go to beginning
- $itk_component(table) icursor 0
- }
-
- down {
- # Go to end
- $itk_component(table) icursor end
- }
-
- left {
- # Go left one character
- set ic [$itk_component(table) icursor]
- if {$ic > 0} {
- $itk_component(table) icursor [expr {$ic - 1}]
- }
- }
-
- right {
- # Go right one character
- set ic [$itk_component(table) icursor]
- if {$ic < [$itk_component(table) icursor end] } {
- $itk_component(table) icursor [expr {$ic + 1}]
- }
- }
- }
-
- } else {
- # Not editing
-
- set col [$itk_component(table) index active col]
-
- switch $direction {
- up {
- incr row -1
- if {$row < 0} {
- # go to bottom
- set row $_rows
- }
- }
-
- down {
- incr row 1
- if {$row == $_rows} {
- # go to top
- set row 0
- }
- }
-
- left {
- incr col -2
- if {$col < 0} {
- # go to right
- set col [expr {$_cols -1}]
- }
- }
-
- right {
- incr col 2
- if {$col > $_cols} {
- # go to left
- set col 0
- }
- }
+body RegWin::but3 {rn X Y} {
+ global reg_display max_regs
+
+ if {!$Running} {
+ $Menu delete 0 end
+ $Menu add command -label $reg_display($rn,name) -state disabled
+ $Menu add separator
+ $Menu add radio -label "Hex" -command "$this update" \
+ -value x -variable reg_display($rn,format)
+ $Menu add radio -label "Decimal" -command "$this update" \
+ -value d -variable reg_display($rn,format)
+ $Menu add radio -label "Natural" -command "$this update" \
+ -value {} -variable reg_display($rn,format)
+ $Menu add radio -label "Binary" -command "$this update" \
+ -value t -variable reg_display($rn,format) -underline 0
+ $Menu add radio -label "Octal" -command "$this update" \
+ -value o -variable reg_display($rn,format)
+ $Menu add radio -label "Raw" -command "$this update" \
+ -value r -variable reg_display($rn,format)
+ $Menu add separator
+ $Menu add command -command "$this delete_from_display_list $rn" \
+ -label "Remove $reg_display($rn,name) from Display"
+ if {$max_regs != $num_regs} {
+ $Menu add separator
+ $Menu add command -command "$this display_all" \
+ -label "Display all registers"
}
-
- # clear the selection
- # FIXME: multiple selections?
- $itk_component(table) selection clear all
-
- _select_cell $row,$col
+ tk_popup $Menu $X $Y
}
}
-
# ------------------------------------------------------------------
-# NAME: private method RegWin::_select_cell
-# DESCRIPTION: Selects a given cell in the table
-#
-# ARGUMENTS:
-# cell - the table index to select
-# RETURNS: The actual cell selected
-#
-# NOTES: Adjusts the cell index so that it always
-# selects the value cell for a register
+# PUBLIC METHOD: display_all - add all registers to the display list
# ------------------------------------------------------------------
-itcl::body RegWin::_select_cell {cell} {
-
- # Abort an edit
- _unedit
-
- # check if going to label. If so, highlight next
- set row [lindex [split $cell ,] 0]
- set col [lindex [split $cell ,] 1]
- if {[expr {$col % 2}] == 0} {
- # going onto a label
- incr col 1
- }
- set cell "$row,$col"
-
- # Make the selected cell the active one
- $itk_component(table) activate $row,$col
- $itk_component(table) see active
-
- # Select this cell and its label
- # FIXME: multiple selections?
- $itk_component(table) selection clear all
- $itk_component(table) selection set $cell $row,[expr {$col-1}]
-
- # Now mark the cell as being edited.
- if {$::gdb_running && [info exists _register($cell)]} {
- $itk_component(table) tag cell edit $cell
- }
-
- focus $itk_component(table)
-
- return $cell
+body RegWin::display_all {} {
+ init_reg_display_vars
+ $itk_interior.m.reg entryconfigure 4 -state disabled
+ reconfig
}
# ------------------------------------------------------------------
-# NAME: private method RegWin::_unedit
-# DESCRIPTION: Cancels an edit
-#
-# ARGUMENTS: None
-# RETURNS: Nothing
+# PUBLIC METHOD: delete_from_display_list - remove a register from the
+# display list
# ------------------------------------------------------------------
-itcl::body RegWin::_unedit {} {
-
- # clear the tag
- set cell [$itk_component(table) tag cell edit]
-
- if {$cell != ""} {
- $itk_component(table) selection clear all
- $itk_component(table) tag cell normal $cell
- focus $itk_component(table)
+body RegWin::delete_from_display_list {rn} {
+ global reg_display max_regs
+ set reg_display($rn,line) 0
+ set reg_display_list {}
+ set rn 0
+ set i 0
+ while {$rn < $max_regs} {
+ if {$reg_display($rn,line) > 0} {
+ lappend reg_display_list $rn
+ incr i
+ set reg_display($rn,line) $i
+ }
+ incr rn
}
+ set num_regs $i
+ reconfig
+ $itk_interior.m.reg entryconfigure 4 -state normal
}
-#
-# Register operations
-#
-
# ------------------------------------------------------------------
-# NAME: private method RegWin::_get_value
-# DESCRIPTION: Get the value of a register
-#
-# ARGUMENTS: rn - the register number whose value should be
-# fetched
-# RETURNS: The register's value or ""
-#
-# NOTES:
+# PUBLIC METHOD: edit - edit a cell
# ------------------------------------------------------------------
-itcl::body RegWin::_get_value {rn} {
- if {[catch {gdb_reginfo value $rn} value]} {
- dbug W "\"gdb_reginfo value $rn\" returned $value"
- set value ""
- } else {
- set value [string trim $value \ ]
- }
- return $value
+body RegWin::edit {r} {
+ global reg_display
+ if {$Running} { return }
+ unedit
+
+ set Editing $r
+ set txt [$ScrolledWin.$r.val cget -text]
+ set len [string length $txt]
+ set entry [entry $ScrolledWin.$r.ent -width $len -bd 0 -font src-font]
+ $entry insert 0 $txt
+
+ grid remove $ScrolledWin.$r.val
+ grid $entry -row 0 -col 1
+ bind $entry <Return> "$this acceptEdit $r"
+ bind $entry <Escape> "$this unedit"
+ $entry selection to end
+ focus $entry
}
# ------------------------------------------------------------------
-# NAME: private method RegWin::_change_format
-# DESCRIPTION: Change the display format of the register
-#
-# ARGUMENTS: rn - the register number to change
-# newtype - type name (optional if just format changed)
-#
-# RETURNS: Nothing
-#
-# NOTES:
+# PUBLIC METHOD: acceptEdit - callback invoked when enter key pressed
+# in an editing entry
# ------------------------------------------------------------------
-itcl::body RegWin::_change_format {rn {newtype {}}} {
-
- set name [gdb_reginfo name $rn]
-
- if {$newtype != ""} {
- set _type($rn,name) $newtype
- pref setd gdb/reg/${name}-type $newtype
- }
+body RegWin::acceptEdit {r} {
+ global reg_display
- gdb_reginfo format $rn $_type($rn,addr) $_format($rn)
-
- # Set the new format in prefs.
- pref setd gdb/reg/${name}-format $_format($rn)
-
- _update_register $rn
- _size_cell_column $_cell($rn) 1
-
- # Show the active cell in case it's moved as a result
- # of resizing the columns.
- $itk_component(table) see active
+ set value [string trimleft [$ScrolledWin.$r.ent get]]
+ debug "value=${value}="
+ if {$value == ""} {
+ set value 0
+ }
+ if {[catch {gdb_cmd "set \$$reg_display($r,name)=$value"} result]} {
+ tk_messageBox -icon error -type ok -message $result \
+ -title "Error in Expression" -parent $this
+ focus $ScrolledWin.$r.ent
+ $ScrolledWin.$r.ent selection to end
+ } else {
+ unedit
+ gdbtk_update
+ }
}
# ------------------------------------------------------------------
-# NAME: private_method RegWin::_update_register
-# DESCRIPTION: Updates the value of a register and refreshes
-# the table
-#
-# ARGUMENTS:
-# rn - the register number to update
-# RETURNS: Nothing
+# PUBLIC METHOD: unedit - clear any editing entry on the screen
# ------------------------------------------------------------------
-itcl::body RegWin::_update_register {rn} {
- set _data($_cell($rn)) [_get_value $rn]
+body RegWin::unedit {} {
+ if {$Editing != -1} {
+ destroy $ScrolledWin.$Editing.ent
+
+ # Fill the entry with the old label, updating value
+ grid $ScrolledWin.$Editing.val -column 1 -row 0
+ focus -force $ScrolledWin.$Editing
+ set Editing -1
+ update
+ }
}
# ------------------------------------------------------------------
-# NAME: private_method RegWin::_select_group
-# DESCRIPTION: Changes the register group. Callback
-#
-# ARGUMENTS:
-#
-# RETURNS: Nothing
+# PRIVATE METHOD: update - update widget when PC changes
# ------------------------------------------------------------------
-itcl::body RegWin::_select_group {} {
- set gr [$itk_component(frame).opt get]
- debug $gr
- if {$gr == ""} {
- return
+body RegWin::update {} {
+ global reg_display
+ debug "START REGISTER UPDATE CALLBACK"
+ if {$reg_display_list == ""
+ || [catch {eval gdb_changed_register_list $reg_display_list} changed_reg_list]} {
+ set changed_reg_list {}
}
-
- # Change anything on the old change list back to normal
- foreach r $_change_list {
- if {[info exists _cell($r)] && $_cell($r) != "hidden"} {
- $itk_component(table) tag cell normal $_cell($r)
+
+ set vmax 0
+ foreach r $reg_display_list {
+ if {[catch {gdb_fetch_registers $reg_display($r,format) $r} values($r)]} {
+ set values($r) ""
+ } else {
+ set values($r) [string trim $values($r) \ ]
}
- }
-
- set _group $gr
- _layout_table
-
- # highlight changed registers if they still exist in the new group
- foreach r $_change_list {
- if {[info exists _cell($r)] && $_cell($r) != "hidden" && $_data($_cell($r)) != ""} {
- $itk_component(table) tag cell highlight $_cell($r)
+ set l [string length $values($r)]
+ if {$l > $vmax} {
+ set vmax $l
}
}
-
- # Clear gdb's change list
- catch {gdb_reginfo changed}
-}
-
-
-#
-# Gdb Events
-#
-
-# ------------------------------------------------------------------
-# NAME: public method RegWin::arch_changed
-# DESCRIPTION: ArchChangedEvent handler
-#
-# ARGUMENTS: event - the ArchChangedEvent (not used)
-# RETURNS: Nothing
-# ------------------------------------------------------------------
-itcl::body RegWin::arch_changed {event} {
-
- # Update internal register caches
- gdb_reg_arch_changed
-
- # Relayout the table
- _layout_table
-
- # Clear gdb's change list
- catch {gdb_reginfo changed}
-}
-
-# ------------------------------------------------------------------
-# NAME: public method RegWin::busy
-# DESCRIPTION: BusyEvent handler
-#
-# ARGUMENTS: event - the BusyEvent (not used)
-# RETURNS: Nothing
-# ------------------------------------------------------------------
-itcl::body RegWin::busy {event} {
-
- # Abort any edit. Need to check if the table is constructed,
- # since we call gdbtk_busy when we're created...
- if {[info exists itk_component(table)]} {
- _unedit
+
+ foreach r $reg_display_list {
+ if {[lsearch -exact $changed_reg_list $r] != -1} {
+ set fg $HighlightForeground
+ } else {
+ set fg $NormalForeground
+ }
+ $ScrolledWin.$r.val configure -text [fixLength $values($r) $vmax right] \
+ -fg $fg
}
-
- # Set fencepost
- set _running 1
-
- # Set cursor
- $_top configure -cursor watch
+ debug "END REGISTER UPDATE CALLBACK"
}
-# ------------------------------------------------------------------
-# NAME: public method RegWin::idle
-# DESCRIPTION: IdleEvent handler
-#
-# ARGUMENTS: event - the IdleEvent (not used)
-# RETURNS: Nothing
-# ------------------------------------------------------------------
-itcl::body RegWin::idle {event} {
-
- # Clear fencepost
- set _running 0
-
- # Reset cursor
- $_top configure -cursor {}
+body RegWin::idle {} {
+ [winfo toplevel $itk_interior] configure -cursor {}
+ set Running 0
}
# ------------------------------------------------------------------
-# NAME: public method RegWin::set_variable
-# DESCRIPTION: SetVariableEvent handler
-#
-# ARGUMENTS: None
-# RETURNS: Nothing
+# PRIVATE METHOD: reconfig - used when preferences change
# ------------------------------------------------------------------
-itcl::body RegWin::set_variable {event} {
- switch [$event get variable] {
- disassembly-flavor {
- _layout_table
- }
+body RegWin::reconfig {} {
+ if {$reg_names_dirty} {
+ init_reg_display_vars
}
+ destroy $Menu $itk_interior.g $itk_interior.scrolled $itk_interior.m
+ gdbtk_busy
+ build_win
+ gdbtk_idle
}
-
+
# ------------------------------------------------------------------
-# NAME: public method RegWin::update
-# DESCRIPTION: UpdateEvent handler
-#
-# ARGUMENTS: event - the UpdateEvent (not used)
-# RETURNS: Nothing
+# PRIVATE METHOD: busy - gdb_busy_hook
# ------------------------------------------------------------------
-itcl::body RegWin::update {event} {
- debug
-
- # Change anything on the old change list back to normal
- foreach r $_change_list {
- if {[info exists _cell($r)] && $_cell($r) != "hidden"} {
- $itk_component(table) tag cell normal $_cell($r)
- }
- }
-
- # Now update and highlight the newly changed values
- set _change_list {}
- if {![catch {gdb_reginfo changed $_reg_display_list} changed]} {
- set _change_list $changed
- }
-
- # Problem: if the register was invalid (i.e, we were not running),
- # its old value will probably be "0x0". Now if we run and its real
- # value is "0x0", then it will appear as a blank in the register
- # window. Safegaurd against that here by adding any such register
- # which is not already in the change list.
- foreach r $_reg_display_list {
- if {$_data($_cell($r)) == "" && [lsearch $_change_list $r] == -1} {
- lappend _change_list $r
- }
- }
-
- # Tag the changed cells and resize the columns
- set cols {}
- foreach r $_change_list {
- _update_register $r
-
- if {$_data($_cell($r)) != ""} {
- $itk_component(table) tag cell highlight $_cell($r)
- }
- set col [lindex [split $_cell($r) ,] 1]
- if {[lsearch $cols $col] == -1} {
- lappend cols $col
- }
- }
+body RegWin::busy {} {
+ # Cancel edits
+ unedit
- foreach col $cols {
- set col [string trim $col ()]
- _size_column $col 0
- }
-
- debug "END REGISTER UPDATE CALLBACK"
+ # Fencepost
+ set Running 1
+
+ # cursor
+ [winfo toplevel $itk_interior] configure -cursor watch
}
diff --git a/gdb/gdbtk/library/regwin.ith b/gdb/gdbtk/library/regwin.ith
index 4a7faf81125..e779f85b0f8 100644
--- a/gdb/gdbtk/library/regwin.ith
+++ b/gdb/gdbtk/library/regwin.ith
@@ -1,8 +1,5 @@
-# Register display window class definition for Insight.
-# Copyright (C) 1998, 1999, 2001 Red Hat, Inc.
-#
-# Written by Keith Seitz (keiths@redhat.com)
-# based on work by Martin Hunt (hunt@redhat.com)
+# Register display window class definition for GDBtk.
+# Copyright 1998, 1999 Cygnus Solutions
#
# This program is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License (GPL) as published by
@@ -15,89 +12,57 @@
# GNU General Public License for more details.
-itcl::class RegWin {
+class RegWin {
inherit EmbeddedWin GDBWin
private {
- variable _change_list {}
- variable _menuitems
-
- # Display data for the table
- variable _data
-
- # Mapping of table cell index to register number
- variable _register
-
- # the register group that is displayed
- variable _group "all"
-
- # Mapping of register number to table cell index. "hidden" if
- # the register was "removed" from the display.
- variable _cell
-
- # Is REGNUM editable?
- variable _editable
-
- # List of possible display types for the registers (indexed by regnum)
- variable _types
- # The display type to use for each register (indexed by regnum)
- variable _type
- # The display format to use for each register (indexed by regnum)
- variable _format
-
- # The list of registers we're displaying
- variable _reg_display_list {}
-
- # Size of columns
- variable _col_size
- variable _max_label_width
-
- # Dimensions
- variable _rows
- variable _cols
-
- # Fencepost
- variable _running 0
-
-
- # Table layout/display methods
- method _build_win {}
- method _layout_table {}
- method _load_prefs {}
- method _size_cell_column {cell down}
- method _size_column {col down}
-
- # Table event handlers and related methods
- method _accept_edit {}
- method _add_to_watch {rn}
- method _but3 {x y X Y}
- method _delete_from_display {rn}
- method _display_all {}
- method _edit {x y}
- method _move {direction}
- method _open_memory {rn}
- method _select_group {}
- method _select_cell {cell}
- method _unedit {}
-
- # Register operations
- method _get_value {rn}
- method _change_format {rn {t {}}}
- method _update_register {rn}
- }
+ variable reg_display_list {}
+ variable num_regs 0
+ variable nRows
+ variable nCols
+ variable changed_reg_list {}
+ variable oldValue
+ variable ScrolledWin
+ variable Menu
+ variable Editing -1
+ variable selected -1
+ variable mbar 1
+ variable reg_names_dirty 0
+ variable Running 0
+
+ common HighlightForeground {}
+ common NormalForeground {}
+
+ method init_reg_display_vars {args}
+ method handle_set_hook {var val}
+ method disassembly_changed {}
+ method dimensions {}
+ method fixLength {s size where}
+ method build_win {}
+ }
public {
+ proc save_reg_display_vars {}
+
method constructor {args}
method destructor {}
-
- #
- # Gdb Events
- #
- method busy {event}
- method idle {event}
- method set_variable {event}
- method update {event}
- method arch_changed {event}
+ method reg_select_up {}
+ method reg_select_down {}
+ method reg_select_right {}
+ method reg_select_left {}
+ method reg_select { r }
+ method but3 {rn X Y}
+ method display_all {}
+ method delete_from_display_list {rn}
+ method edit {r}
+ method acceptEdit {r}
+ method unedit {}
+ method update {}
+ method idle {}
method reconfig {}
+ method busy {}
}
+
+
}
+
diff --git a/gdb/gdbtk/library/srcbar.tcl b/gdb/gdbtk/library/srcbar.tcl
new file mode 100644
index 00000000000..93177521884
--- /dev/null
+++ b/gdb/gdbtk/library/srcbar.tcl
@@ -0,0 +1,643 @@
+# GDBSrcBar
+# Copyright 1997, 1998, 1999 Cygnus Solutions
+#
+# This program is free software; you can redistribute it and/or modify it
+# under the terms of the GNU General Public License (GPL) as published by
+# the Free Software Foundation; either version 2 of the License, or (at
+# your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+
+
+# ----------------------------------------------------------------------
+# Implements a toolbar that is attached to a source window.
+#
+# PUBLIC ATTRIBUTES:
+#
+#
+# METHODS:
+#
+# config ....... used to change public attributes
+#
+# PRIVATE METHODS
+#
+# X11 OPTION DATABASE ATTRIBUTES
+#
+#
+# ----------------------------------------------------------------------
+
+class GDBSrcBar {
+ inherit GDBToolBar
+
+ # ------------------------------------------------------------------
+ # CONSTRUCTOR - create widget
+ # ------------------------------------------------------------------
+ constructor {src args} {
+ GDBToolBar::constructor $src
+ } {
+ eval itk_initialize $args
+ add_hook gdb_trace_find_hook "$this trace_find_hook"
+ }
+
+ # ------------------------------------------------------------------
+ # DESTRUCTOR - destroy window containing widget
+ # ------------------------------------------------------------------
+ destructor {
+ global GDBSrcBar_state
+ unset GDBSrcBar_state($this)
+ remove_hook gdb_trace_find_hook "$this trace_find_hook"
+ }
+
+ #
+ # PUBLIC DATA
+ #
+
+ # This is the command that should be run when the `update'
+ # checkbutton is toggled. The current value of the checkbutton is
+ # appended to the command.
+ public variable updatecommand {}
+
+ # This controls whether the `update' checkbutton is turned on or
+ # off.
+ public variable updatevalue 0 {
+ global GDBSrcBar_state
+ ::set GDBSrcBar_state($this) $updatevalue
+ }
+
+ # This holds the text that is shown in the address label.
+ public variable address {} {
+ if {$ButtonFrame != "" && [winfo exists $ButtonFrame.addr]} {
+ $ButtonFrame.addr configure -text $address -font src-font
+ }
+ }
+
+ # This holds the text that is shown in the line label.
+ public variable line {} {
+ if {$ButtonFrame != "" && [winfo exists $ButtonFrame.line]} {
+ $ButtonFrame.line configure -text $line
+ }
+ }
+
+ # This holds the source window's display mode. Valid values are
+ # SOURCE, ASSEMBLY, SRC+ASM, and MIXED.
+ public variable displaymode SOURCE {
+ if {$ButtonFrame != ""} {
+ _set_stepi
+ }
+ }
+
+ # This is true if the inferior is running, or false if it is
+ # stopped.
+ public variable runstop normal {
+ if {$ButtonFrame != ""} {
+ _set_runstop
+ }
+ }
+
+ # The next three determine the state of the application when Tracing is enabled.
+
+ public variable Tracing 0 ;# Is tracing enabled for this gdb?
+ public variable Browsing 0 ;# Are we currently browsing a trace experiment?
+ public variable Collecting 0 ;# Are we currently collecting a trace experiment?
+
+ # ------------------------------------------------------------------
+ # METHOD: create_menu_items - Add some menu items to the menubar.
+ # Returns 1 if any items added.
+ # This overrides the method in GDBToolBar.
+ # ------------------------------------------------------------------
+ public method create_menu_items {} {
+ global enable_external_editor tcl_platform
+
+ set m [new_menu file "File" 0]
+
+ if {[info exists enable_external_editor] && $enable_external_editor} {
+ add_menu_command None "Edit Source" \
+ [list $this _apply_source edit]
+ }
+ add_menu_command Other "Open..." \
+ "_open_file" -underline 0 -accelerator "Ctrl+O"
+
+ add_menu_command Other "Source..." \
+ "source_file" -underline 0
+
+ add_menu_separator
+
+ if {$tcl_platform(platform) == "windows"} {
+ add_menu_command None "Page Setup..." \
+ [format {
+ set top %s
+ ide_winprint page_setup -parent $top
+ } [winfo toplevel [namespace tail $this]]] \
+ -underline 8
+ add_menu_command None "Print Source..." \
+ "$this _apply_source print" \
+ -underline 0 -accelerator "Ctrl+P"
+ add_menu_separator
+
+ }
+
+ add_menu_command Other "Target Settings..." "set_target_name" \
+ -underline 0
+ add_menu_separator
+ add_menu_command None "Exit" gdbtk_quit -underline 1
+
+ create_run_menu
+
+ create_view_menu
+
+ if {[pref get gdb/control_target]} {
+ create_control_menu
+
+ }
+
+ if {[pref get gdb/mode]} {
+ create_trace_menu
+ }
+
+ new_menu pref "Preferences" 0
+
+ add_menu_command Other "Global..." \
+ "ManagedWin::open GlobalPref -transient" -underline 0
+
+ add_menu_command Other "Source..." \
+ "ManagedWin::open SrcPref -transient" -underline 0
+
+ create_help_menu
+ return 1
+ }
+
+ # ------------------------------------------------------------------
+ # METHOD: create_buttons - Add some buttons to the toolbar. Returns
+ # list of buttons in form acceptable to
+ # standard_toolbar.
+ # This overrides the method in GDBToolBar.
+ # ------------------------------------------------------------------
+ public method create_buttons {} {
+ global enable_external_editor
+
+ add_button stop None {} {}
+ _set_runstop
+
+ if {[pref get gdb/mode]} {
+ add_button tstop Control [list $this do_tstop] "Start Collection" \
+ -image Movie_on_img
+
+ add_button view Other [list $this set_control_mode 1] \
+ "Switch to Browse Mode" -image watch_movie_img
+
+ add_button_separator
+
+ }
+
+ if {[pref get gdb/control_target]} {
+ create_control_buttons
+ if {[pref get gdb/mode]} {
+ create_trace_buttons 0
+ }
+ } elseif {[get pref gdb/mode]} {
+
+ #
+ # If we don't control the target, then we might as well
+ # put a copy of the trace controls on the source window.
+ #
+ create_trace_buttons 1
+ }
+
+ add_button_separator
+
+ create_window_buttons
+
+ # Random bits of obscurity...
+ bind $Buttons(reg) <Button-3> "ManagedWin::open RegWin -force"
+ bind $Buttons(mem) <Button-3> "ManagedWin::open MemWin -force"
+ bind $Buttons(watch) <Button-3> "ManagedWin::open WatchWin -force"
+ bind $Buttons(vars) <Button-3> "ManagedWin::open LocalsWin -force"
+
+ add_button_separator
+
+ if {[info exists enable_external_editor] && $enable_external_editor} {
+ add_button edit Other [list $this _apply_source edit] "Edit Source" \
+ -image edit_img
+
+ add_button_separator
+ }
+
+ add_label addr $address "Address" -width 10 -relief sunken -bd 1 -anchor e \
+ -font src-font
+
+ add_label line $line "Line Number" -width 6 -relief sunken -bd 1 -anchor e \
+ -font src-font
+
+ button_right_justify
+
+ create_stack_buttons
+
+ # This feature has been disabled for now.
+ # checkbutton $ButtonFrame.upd -command "$this _toggle_updates" \
+ # -variable GDBSrcBar_state($this)
+ # lappend button_list $ButtonFrame.upd
+ # global GDBSrcBar_state
+ # ::set GDBSrcBar_state($this) $updatevalue
+ # balloon register $ButtonFrame.upd "Toggle Window Updates"
+
+ }
+
+ # ------------------------------------------------------------------
+ # METHOD: _toggle_updates - Run when the update checkbutton is
+ # toggled. Private method.
+ # ------------------------------------------------------------------
+ public method _toggle_updates {} {
+ global GDBSrcBar_state
+ if {$updatecommand != ""} {
+ uplevel \#0 $updatecommand $GDBSrcBar_state($this)
+ }
+ }
+
+ # ------------------------------------------------------------------
+ # METHOD: cancel_download
+ # ------------------------------------------------------------------
+ public method cancel_download {} {
+ global download_dialog download_cancel_ok
+
+ if {"$download_dialog" != ""} {
+ $download_dialog cancel
+ } else {
+ set download_cancel_ok 1
+ }
+ }
+
+ # ------------------------------------------------------------------
+ # METHOD: create_run_menu - Creates the standard run menu,
+ # or reconfigures it if it already exists.
+ # ------------------------------------------------------------------
+
+ method create_run_menu {} {
+
+ if {![menu_exists Run]} {
+ set run_menu [new_menu run "Run" 0]
+ } else {
+ set run_menu [clear_menu Run]
+ }
+
+ set is_native [TargetSelection::native_debugging]
+
+ # If we are on a Unix target, put in the attach options. "ps" doesn't
+ # give me the Windows PID yet, and the attach also seems flakey, so
+ # I will hold off on the Windows implementation for now.
+
+ if {$is_native} {
+ if {[string compare $::tcl_platform(platform) windows] != 0} {
+ add_menu_command Attach "Attach to process" \
+ [code $this do_attach $run_menu] \
+ -underline 0 -accelerator "Ctrl+A"
+ }
+ } else {
+ add_menu_command Other "Connect to target" \
+ "$this do_connect $run_menu" -underline 0
+ }
+
+ if {[pref get gdb/control_target]} {
+ if {!$is_native} {
+ add_menu_command Other "Download" Download::download_it \
+ -underline 0 -accelerator "Ctrl+D"
+ }
+ add_menu_command Other "Run" [code $source inferior run] -underline 0 \
+ -accelerator R
+ }
+
+ if {$is_native} {
+ if {[string compare $::tcl_platform(platform) windows] != 0} {
+ add_menu_command Detach "Detach" [code $this do_detach $run_menu] \
+ -underline 0 -state disabled
+ }
+ } else {
+ add_menu_command Other "Disconnect" \
+ [code $this do_disconnect $run_menu] -underline 0 -state disabled
+ }
+
+ if {$is_native} {
+ add_menu_separator
+ add_menu_command Control "Kill" [code $this do_kill $run_menu] \
+ -underline 0 -state disabled
+ }
+
+ if { [pref get gdb/mode] } {
+ add_menu_separator
+ add_menu_command Other "Start collection" "$this do_tstop" \
+ -underline 0 -accelerator "Ctrl+B"
+
+ add_menu_command Other "Stop collection" "$this do_tstop" \
+ -underline 0 -accelerator "Ctrl+E" -state disabled
+ }
+
+ }
+
+ # ------------------------------------------------------------------
+ # METHOD: create_stack_buttons - Creates the up down bottom stack buttons
+ # ------------------------------------------------------------------
+
+ method create_stack_buttons {} {
+
+ add_button down {Trace Control} [list $this _apply_source stack down] \
+ "Down Stack Frame" -image down_img
+
+ add_button up {Trace Control} [list $this _apply_source stack up] \
+ "Up Stack Frame" -image up_img
+
+ add_button bottom {Trace Control} [list $this _apply_source stack bottom] \
+ "Go to Bottom of Stack" -image bottom_img
+
+ }
+
+ # ------------------------------------------------------------------
+ # METHOD: _set_runstop - Set state of run/stop button.
+ # ------------------------------------------------------------------
+ public method _set_runstop {} {
+ switch $runstop {
+ busy {
+ $ButtonFrame.stop configure -state disabled
+ }
+ downloading {
+ $ButtonFrame.stop configure -state normal -image stop_img \
+ -command [code $this cancel_download]
+ balloon register $ButtonFrame.stop "Stop"
+ }
+ running {
+ $ButtonFrame.stop configure -state normal -image stop_img \
+ -command [code $source inferior stop]
+ balloon register $ButtonFrame.stop "Stop"
+
+ }
+ normal {
+ $ButtonFrame.stop configure -state normal -image run_img \
+ -command [code $source inferior run]
+ balloon register $ButtonFrame.stop "Run (R)"
+ }
+ default {
+ debug "SrcBar::_set_runstop - unknown state $runstop ($running)"
+ }
+ }
+ }
+
+
+ # ------------------------------------------------------------------
+ # METHOD: _set_stepi - Set state of stepi/nexti buttons.
+ # ------------------------------------------------------------------
+ public method _set_stepi {} {
+
+ # Only do this in synchronous mode
+ if {!$Tracing} {
+ # In source-only mode, disable these buttons. Otherwise, enable
+ # them.
+ if {$displaymode == "SOURCE"} {
+ set state disabled
+ } else {
+ set state normal
+ }
+ $ButtonFrame.stepi configure -state $state
+ $ButtonFrame.nexti configure -state $state
+ }
+ }
+
+ # ------------------------------------------------------------------
+ # METHOD: _apply_source - Forward some method call to the source window.
+ # ------------------------------------------------------------------
+ public method _apply_source {args} {
+ if {$source != ""} {
+ eval $source $args
+ }
+ }
+
+ # ------------------------------------------------------------------
+ # METHOD: trace_find_hook - response to the tfind command. If the
+ # command puts us in a new mode, then switch modes...
+ # ------------------------------------------------------------------
+ method trace_find_hook {mode from_tty} {
+ debug "in trace_find_hook, mode: $mode, from_tty: $from_tty, Browsing: $Browsing"
+ if {[string compare $mode -1] == 0} {
+ if {$Browsing} {
+ set_control_mode 0
+ }
+ } else {
+ if {!$Browsing} {
+ set_control_mode 1
+ }
+ }
+ }
+ # ------------------------------------------------------------------
+ # METHOD: set_control_mode - sets up the srcbar for browsing
+ # a trace experiment.
+ # mode: 1 => browse mode
+ # 0 => control mode
+ # ------------------------------------------------------------------
+ method set_control_mode {mode} {
+ debug "set_control_mode called with mode $mode"
+ if {$mode} {
+ set Browsing 1
+ $Buttons(view) configure -image run_expt_img -command "$this set_control_mode 0"
+ balloon register $Buttons(view) "Switch to Control mode"
+ # Now swap out the buttons...
+ swap_button_lists $Trace_control_buttons $Run_control_buttons
+ enable_ui 1
+ } else {
+ if {$Browsing} {
+ tfind_cmd {tfind none}
+ }
+ set Browsing 0
+ $Buttons(view) configure -image watch_movie_img -command "$this set_control_mode 1"
+ balloon register $Buttons(view) "Switch to Browse mode"
+ # Now swap out the buttons...
+ swap_button_lists $Run_control_buttons $Trace_control_buttons
+ enable_ui 1
+ }
+ run_hooks control_mode_hook $Browsing
+ }
+
+
+ # ------------------------------------------------------------------
+ # METHOD: reconfig - reconfigure the srcbar
+ # ------------------------------------------------------------------
+ public method reconfig {} {
+ _load_src_images 1
+ GDBToolBar::reconfig
+ }
+
+ # ------------------------------------------------------------------
+ # METHOD: do_attach: attach to a running target
+ # ------------------------------------------------------------------
+ method do_attach {menu} {
+ ManagedWin::open_dlg AttachDlg ;#-transient
+
+ debug "ManagedWin got [AttachDlg::last_button] [AttachDlg::pid]"
+
+ if {[AttachDlg::last_button]} {
+ set pid [AttachDlg::pid]
+ set symbol_file [AttachDlg::symbol_file]
+ if {![_open_file $symbol_file]} {
+ ManagedWin::open WarningDlg -transient \
+ -message "Could not load symbols from $symbol_file."
+ return
+ }
+
+ if {[catch {gdb_cmd "attach $pid"} result]} {
+ ManagedWin::open WarningDlg -transient \
+ -message [list "Could not attach to $pid:\n$result"]
+ return
+ }
+
+ }
+
+ }
+
+ # ------------------------------------------------------------------
+ # METHOD: do_detach: detach from a running target
+ # ------------------------------------------------------------------
+ method do_detach {menu} {
+ ::disconnect
+ gdbtk_idle
+ }
+
+ # ------------------------------------------------------------------
+ # METHOD: do_kill: kill the current target
+ # ------------------------------------------------------------------
+ method do_kill {menu} {
+ gdb_cmd "kill"
+ run_hooks gdb_no_inferior_hook
+ }
+
+ # ------------------------------------------------------------------
+ # METHOD: do_connect: connect to a remote target
+ # in asynch mode if async is 1
+ # ------------------------------------------------------------------
+ method do_connect {menu {async 0}} {
+ global file_done
+
+ debug "do_connect: menu=$menu async=$async"
+
+ gdbtk_busy
+
+ set result [gdbtk_attach_target]
+ switch $result {
+ ATTACH_ERROR {
+ set successful 0
+ }
+
+ ATTACH_TARGET_CHANGED {
+ if {[pref get gdb/load/check] && $file_done} {
+ set err [catch {gdb_cmd "compare-sections"} errTxt]
+ if {$err} {
+ set successful 0
+ tk_messageBox -title "Error" -message $errTxt \
+ -icon error -type ok
+ break
+ }
+ }
+
+ tk_messageBox -title "GDB" -message "Successfully connected" \
+ -icon info -type ok
+ set successful 1
+ }
+
+ ATTACH_CANCELED {
+ tk_messageBox -title "GDB" -message "Connection Canceled" -icon info \
+ -type ok
+ set successful 0
+ }
+
+ ATTACH_TARGET_UNCHANGED {
+ tk_messageBox -title "GDB" -message "Successfully connected" \
+ -icon info -type ok
+ set successful 1
+ }
+
+ default {
+ dbug E "Unhandled response from gdbtk_attach_target: \"$result\""
+ set successful 0
+ }
+ }
+
+ gdbtk_idle
+
+ if {$successful} {
+ $menu entryconfigure "Connect to target" -state disabled
+ $menu entryconfigure "Disconnect" -state normal
+ } else {
+ $menu entryconfigure "Connect to target" -state normal
+ $menu entryconfigure "Disconnect" -state disabled
+ }
+
+ # Whenever we attach, we need to do an update
+ gdbtk_update
+ }
+
+
+ # ------------------------------------------------------------------
+ # METHOD: do_disconnect: disconnect from a remote target
+ # in asynch mode if async is 1.
+ #
+ # ------------------------------------------------------------------
+ method do_disconnect {menu {async 0}} {
+ debug "$menu $async"
+ #
+ # For now, these are the same, but they might be different...
+ #
+
+ disconnect $async
+
+ $menu entryconfigure "Connect to target" -state normal
+ $menu entryconfigure "Disconnect" -state disabled
+ }
+
+ # ------------------------------------------------------------------
+ # METHOD: do_tstop: Change the GUI state, then do the tstop or
+ # tstart command, whichever is appropriate.
+ #
+ # ------------------------------------------------------------------
+ method do_tstop {} {
+ debug "do_tstop called... Collecting is $Collecting"
+
+ if {!$Collecting} {
+ #
+ # Start the trace experiment
+ #
+
+ if {$Browsing} {
+ set ret [tk_MessageBox -title "Warning" -message \
+"You are currently browsing a trace experiment.
+This command will clear the results of that experiment.
+Do you want to continue?" \
+ -icon warning -type okcancel -default ok]
+ if {[string compare $ret cancel] == 0} {
+ return
+ }
+ set_control_mode 1
+ }
+ if {[tstart]} {
+ $Buttons(tstop) configure -image Movie_off_img
+ balloon register $Buttons(tstop) "End Collection"
+ set Collecting 1
+ } else {
+ tk_messageBox -title Error -message "Error downloading tracepoint info" \
+ -icon error -type ok
+ }
+ } else {
+ #
+ # Stop the trace experiment
+ #
+
+ if {[tstop]} {
+ $Buttons(tstop) configure -image Movie_on_img
+ balloon register $Buttons(tstop) "Start Collection"
+ set Collecting 0
+ }
+ }
+ }
+
+ #
+ # PROTECTED DATA
+ #
+ common menu_titles
+}
diff --git a/gdb/gdbtk/library/srcpref.itb b/gdb/gdbtk/library/srcpref.itb
index 6b7499351c4..374a32c7fc1 100644
--- a/gdb/gdbtk/library/srcpref.itb
+++ b/gdb/gdbtk/library/srcpref.itb
@@ -1,5 +1,5 @@
-# Source preferences dialog for Insight.
-# Copyright (C) 1998, 1999, 2002, 2003 Red Hat
+# Source preferences dialog for GDBtk.
+# Copyright 1998, 1999 Cygnus Solutions
#
# This program is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License (GPL) as published by
@@ -15,34 +15,31 @@
# ------------------------------------------------------------------
# CONSTRUCTOR - create new source preferences window
# ------------------------------------------------------------------
-itcl::body SrcPref::constructor {args} {
+body SrcPref::constructor {args} {
window_name "Source Preferences"
- _init_var
- _build_win
-}
-# ------------------------------------------------------------------
-# METHOD: init_var - initialize preference variables
-# ------------------------------------------------------------------
-itcl::body SrcPref::_init_var {} {
- set vlist {gdb/src/PC_TAG gdb/src/STACK_TAG gdb/src/BROWSE_TAG
- gdb/src/run_attach gdb/src/run_load gdb/src/run_run
- gdb/src/run_cont gdb/src/bp_fg gdb/src/temp_bp_fg
- gdb/src/trace_fg gdb/src/thread_fg gdb/src/variableBalloons
- gdb/src/source2_fg gdb/src/tab_size gdb/mode gdb/editor
- gdb/B1_behavior}
-
- foreach var $vlist {
- set _saved($var) [pref get $var]
- set _new($var) $_saved($var)
- }
+ build_win
+ set saved(gdb/src/PC_TAG) [pref get gdb/src/PC_TAG]
+ set saved(gdb/src/STACK_TAG) [pref get gdb/src/STACK_TAG]
+ set saved(gdb/src/BROWSE_TAG) [pref get gdb/src/BROWSE_TAG]
+ set saved(gdb/src/run_attach) [pref get gdb/src/run_attach]
+ set saved(gdb/src/run_load) [pref get gdb/src/run_load]
+ set saved(gdb/src/run_run) [pref get gdb/src/run_run]
+ set saved(gdb/src/run_cont) [pref get gdb/src/run_cont]
+ set saved(gdb/src/bp_fg) [pref get gdb/src/bp_fg]
+ set saved(gdb/src/temp_bp_fg) [pref get gdb/src/temp_bp_fg]
+ set saved(gdb/src/trace_fg) [pref get gdb/src/trace_fg]
+ set saved(gdb/src/thread_fg) [pref get gdb/src/thread_fg]
+ set saved(gdb/src/variableBalloons) [pref get gdb/src/variableBalloons]
+ set saved(gdb/src/source2_fg) [pref get gdb/src/source2_fg]
+ set saved(gdb/src/tab_size) [pref get gdb/src/tab_size]
+ set saved(gdb/mode) [pref get gdb/mode]
}
-
# ------------------------------------------------------------------
# METHOD: build_win - build the dialog
# ------------------------------------------------------------------
-itcl::body SrcPref::_build_win {} {
+body SrcPref::build_win {} {
frame $itk_interior.f
frame $itk_interior.f.a
frame $itk_interior.f.b
@@ -102,7 +99,7 @@ itcl::body SrcPref::_build_win {} {
# Debug Mode frame
Labelledframe $f.rmv.mode -anchor nw -text "Mouse Button-1 Behavior"
set w [$f.rmv.mode get_frame]
-
+ set var [pref varname gdb/B1_behavior]
if {[pref get gdb/mode]} {
set state normal
} else {
@@ -110,22 +107,22 @@ itcl::body SrcPref::_build_win {} {
set state disabled
}
- radiobutton $w.async -text "Set/Clear Tracepoints" \
- -variable [scope _new(gdb/B1_behavior)] -value 0 -state $state
- radiobutton $w.sync -text "Set/Clear Breakpoints" \
- -variable [scope _new(gdb/B1_behavior)] -value 1 -state $state
-
+ radiobutton $w.async -text "Set/Clear Tracepoints" -variable $var \
+ -value 0 -state $state
+ radiobutton $w.sync -text "Set/Clear Breakpoints" -variable $var \
+ -value 1 -state $state
+
pack $w.async $w.sync -side top
# Variable Balloons
Labelledframe $f.rmv.var -anchor nw -text "Variable Balloons"
set w [$f.rmv.var get_frame]
- set var _new(gdb/src/variableBalloons)
- radiobutton $w.var_on -text "On " -variable [scope $var] -value 1
- radiobutton $w.var_off -text "Off" -variable [scope $var] -value 0
+ set var [pref varname gdb/src/variableBalloons]
+ radiobutton $w.var_on -text "On " -variable $var -value 1
+ radiobutton $w.var_off -text "Off" -variable $var -value 0
pack $w.var_on $w.var_off -side top
- grid $f.rmv.mode -sticky nsew -pady 5 -row 0 -column 0
- grid $f.rmv.var -sticky nsew -pady 5 -row 0 -column 2
+ grid $f.rmv.mode -sticky nsew -pady 5 -row 0 -col 0
+ grid $f.rmv.var -sticky nsew -pady 5 -row 0 -col 2
grid columnconfigure $f.rmv 0 -weight 1
grid columnconfigure $f.rmv 1 -minsize 4
grid columnconfigure $f.rmv 2 -weight 1
@@ -134,13 +131,9 @@ itcl::body SrcPref::_build_win {} {
frame $f.x
# Tab size
- itk_component add size {
- iwidgets::spinint $f.x.size -labeltext "Tab Size" -range {1 16} \
- -step 1 -fixed 2 -width 2 -textvariable [scope _new(gdb/src/tab_size)] \
- -wrap 0 -textbackground $::Colors(textbg)
- }
- $f.x.size delete 0 end
- $f.x.size insert end $_saved(gdb/src/tab_size)
+ tixControl $f.x.size -label "Tab Size" -integer true -max 16 -min 1 \
+ -variable [pref varname gdb/src/tab_size] \
+ -options { entry.width 2 entry.font src-font}
# Linenumbers
# commented out because this option isn't really useful
@@ -158,31 +151,23 @@ itcl::body SrcPref::_build_win {} {
set have_disassembly_flavor 1
frame $f.dis
label $f.dis.l -text "Disassembly Flavor: "
- combobox::combobox $f.dis.combo -maxheight 15 -width 15 \
- -font global/fixed -editable 0 -command [code $this _set_flavor] \
- -bg $::Colors(textbg)
+ combobox::combobox $f.dis.combo -maxheight 15 -width 15 -font src-font -editable 0 \
+ -command [code $this set_flavor]
foreach elem $vals {
$f.dis.combo list insert end $elem
}
- set _saved_disassembly_flavor [get_disassembly_flavor]
- $f.dis.combo entryset $_saved_disassembly_flavor
+ set current_disassembly_flavor [get_disassembly_flavor]
+ $f.dis.combo entryset $current_disassembly_flavor
pack $f.dis.l -side left
pack $f.dis.combo -side left -padx 4
} else {
- set _saved_disassembly_flavor ""
+ set current_disassembly_flavor ""
}
- # External editor.
- frame $f.exted
- label $f.exted.l -text "External Editor: "
- entry $f.exted.e -width 40 -textvariable [scope _new(gdb/editor)]
- pack $f.exted.l -side left
- pack $f.exted.e -side left -padx 4
-
pack $f.colors -fill both -expand 1
pack $f.rmv -fill both -expand yes
pack $f.x -fill x -expand yes
@@ -191,8 +176,6 @@ itcl::body SrcPref::_build_win {} {
pack $f.dis -side top -fill x -padx 4
}
- pack $f.exted -side top -fill x -padx 4 -pady 4
-
button $itk_interior.f.b.ok -text OK -width 7 -underline 0 -command [code $this _save]
button $itk_interior.f.b.apply -text Apply -width 7 -underline 0 -command [code $this _apply]
button $itk_interior.f.b.quit -text Cancel -width 7 -underline 0 -command [code $this _cancel]
@@ -203,28 +186,18 @@ itcl::body SrcPref::_build_win {} {
# ------------------------------------------------------------------
# METHOD: apply - apply changes
# ------------------------------------------------------------------
-itcl::body SrcPref::_apply {} {
- foreach var [array names _new] {
- if {$_new($var) != [pref get $var]} {
- #debug "$var = $_new($var)"
- pref set $var $_new($var)
- }
- }
- if {$_new_disassembly_flavor != ""} {
- gdb_cmd "set disassembly-flavor $_new_disassembly_flavor"
- pref set gdb/src/disassembly-flavor $_new_disassembly_flavor
+body SrcPref::_apply {} {
+ if {$current_disassembly_flavor != ""} {
+ gdb_cmd "set disassembly-flavor $current_disassembly_flavor"
+ pref set gdb/src/disassembly-flavor $current_disassembly_flavor
}
ManagedWin::restart
}
-itcl::body SrcPref::cancel {} {
- _save
-}
-
# ------------------------------------------------------------------
-# METHOD: _cancel
+# METHOD: cancel
# ------------------------------------------------------------------
-itcl::body SrcPref::_cancel {} {
+body SrcPref::_cancel {} {
set any_changed 0
foreach elem [array names _saved] {
@@ -234,44 +207,39 @@ itcl::body SrcPref::_cancel {} {
pref set $elem $_saved($elem)
}
}
-
- if {$_new_disassembly_flavor != ""} {
- set any_changed 1
- gdb_cmd "set disassembly-flavor $_saved_disassembly_flavor"
- pref set gdb/src/disassembly-flavor $_saved_disassembly_flavor
- }
if {$any_changed} {
- ManagedWin::restart
+ _save
+ } else {
+ unpost
}
- unpost
}
# ------------------------------------------------------------------
# METHOD: save - apply changes and quit
# ------------------------------------------------------------------
-itcl::body SrcPref::_save {} {
+body SrcPref::_save {} {
_apply
unpost
}
# ------------------------------------------------------------------
-# METHOD: _set_flavor - sets the disassembly flavor. The set disassembly-flavor
+# METHOD: set_flavor - sets the disassembly flavor. The set disassembly-flavor
# gdb command is already known to exist, so I don't have to check...
# ------------------------------------------------------------------
-itcl::body SrcPref::_set_flavor {w new_mode} {
+body SrcPref::set_flavor {w new_mode} {
$w entryset $new_mode
- set _new_disassembly_flavor $new_mode
+ set current_disassembly_flavor $new_mode
}
# ------------------------------------------------------------------
# METHOD: pick - pick colors
# ------------------------------------------------------------------
-itcl::body SrcPref::_pick {color win tag} {
+body SrcPref::_pick {color win tag} {
set new_color [tk_chooseColor -initialcolor $color -title "Choose color"]
if {$new_color != $color && $new_color != {}} {
- set _new(gdb/src/$tag) $new_color
+ pref set gdb/src/$tag $new_color
$win configure -activebackground $new_color -bg $new_color
}
}
diff --git a/gdb/gdbtk/library/srcpref.ith b/gdb/gdbtk/library/srcpref.ith
index a42f7ba7fde..0c45e1ef407 100644
--- a/gdb/gdbtk/library/srcpref.ith
+++ b/gdb/gdbtk/library/srcpref.ith
@@ -1,5 +1,5 @@
# Source preferences dialog class definition for GDBtk.
-# Copyright (C) 1998, 1999 Cygnus Solutions
+# Copyright 1998, 1999 Cygnus Solutions
#
# This program is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License (GPL) as published by
@@ -12,23 +12,19 @@
# GNU General Public License for more details.
-itcl::class SrcPref {
+class SrcPref {
inherit ManagedWin ModalDialog
private {
- variable _saved ;# These are the saved values...
- variable _new ;# These are the changed values
- variable _saved_disassembly_flavor
- variable _new_disassembly_flavor ""
+ variable _saved ;# These are the saved values...
+ variable current_disassembly_flavor ""
+ method build_win {}
method _apply {}
- method _build_win {}
method _cancel {}
- method _init_var {}
- method _pick {color win tag}
method _save {}
- method _set_flavor {w new_mode}
- method cancel {}
+ method set_flavor {w new_mode}
+ method _pick {color win tag}
}
public {
diff --git a/gdb/gdbtk/library/srctextwin.itb b/gdb/gdbtk/library/srctextwin.itb
index 7e4acb38d6c..5edb7a34e13 100644
--- a/gdb/gdbtk/library/srctextwin.itb
+++ b/gdb/gdbtk/library/srctextwin.itb
@@ -1,5 +1,5 @@
-# Paned text widget for source code, for Insight
-# Copyright (C) 1997, 1998, 1999, 2001, 2002, 2008 Red Hat, Inc.
+ # Paned text widget for source code, for GDBtk.
+# Copyright 1997, 1998, 1999 Cygnus Solutions
#
# This program is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License (GPL) as published by
@@ -21,7 +21,7 @@
# ------------------------------------------------------------------
# CONSTRUCTOR - create new source text window
# ------------------------------------------------------------------
-itcl::body SrcTextWin::constructor {args} {
+body SrcTextWin::constructor {args} {
eval itk_initialize $args
set top [winfo toplevel $itk_interior]
if {$parent == {}} {
@@ -60,11 +60,17 @@ itcl::body SrcTextWin::constructor {args} {
build_win
# add hooks
+ add_hook gdb_breakpoint_change_hook "$this bp"
+
if {$Tracing} {
add_hook control_mode_hook "$this set_control_mode"
add_hook gdb_trace_find_hook "$this trace_find_hook"
}
+ if {[get_disassembly_flavor] != ""} {
+ add_hook gdb_set_hook [code $this handle_set_hook]
+ }
+
if {$UseVariableBalloons} {
add_hook gdb_idle_hook "$this updateBalloon"
}
@@ -76,13 +82,17 @@ itcl::body SrcTextWin::constructor {args} {
# ------------------------------------------------------------------
# DESTRUCTOR - destroy window containing widget
# ------------------------------------------------------------------
-itcl::body SrcTextWin::destructor {} {
+body SrcTextWin::destructor {} {
+ remove_hook gdb_breakpoint_change_hook "$this bp"
if {$Tracing} {
remove_hook control_mode_hook "$this set_control_mode"
}
if {$UseVariableBalloons} {
remove_hook gdb_idle_hook "$this updateBalloon"
}
+ if {[get_disassembly_flavor] != ""} {
+ remove_hook gdb_set_hook [code $this handle_set_hook]
+ }
}
# ------------------------------------------------------------------
@@ -90,7 +100,7 @@ itcl::body SrcTextWin::destructor {} {
# need to do here is to remove the trace tags, if we are exiting
# trace mode
# ------------------------------------------------------------------
-itcl::body SrcTextWin::trace_find_hook {mode from_tty} {
+body SrcTextWin::trace_find_hook {mode from_tty} {
if {[string compare $mode -1] == 0} {
if {$Browsing} {
$twin tag remove STACK_TAG 1.0 end
@@ -103,7 +113,7 @@ itcl::body SrcTextWin::trace_find_hook {mode from_tty} {
# browsing -> mode = 1
# controlling -> mode = 0
# ------------------------------------------------------------------
-itcl::body SrcTextWin::set_control_mode {mode} {
+body SrcTextWin::set_control_mode {mode} {
# debug "Setting control mode of $twin to $mode"
if {$mode} {
set Browsing 1
@@ -153,7 +163,7 @@ itcl::body SrcTextWin::set_control_mode {mode} {
# browse_disabled - a similar list for menus that should be disabled
# when you are browsing a trace expt.
#
-itcl::body SrcTextWin::build_popups {} {
+body SrcTextWin::build_popups {} {
set popups(bp) $itk_interior.bp_menu
set popups(tp) $itk_interior.tp_menu
@@ -161,8 +171,7 @@ itcl::body SrcTextWin::build_popups {} {
set popups(tp_browse) $itk_interior.tp_browse_menu
set popups(break_rgn) $itk_interior.break_menu
set popups(source) $itk_interior.src_menu
- set popups(disabled_bp) $itk_interior.disabled_bp_menu
-
+
# This is a scratch popup menu we use when we are not over a bp...
if {![winfo exists $popups(source)]} {
menu $popups(source) -tearoff 0
@@ -180,8 +189,6 @@ itcl::body SrcTextWin::build_popups {} {
addPopup break_rgn "Continue to Here" "$this continue_to_here" \
[pref get gdb/src/PC_TAG] 0 0
- addPopup break_rgn "Jump to Here" "$this jump_to_here" \
- [pref get gdb/src/PC_TAG] 0 0
$popups(break_rgn) add separator
addPopup break_rgn "Set Breakpoint" "$this set_bp_at_line" $bp_fg
@@ -208,16 +215,11 @@ itcl::body SrcTextWin::build_popups {} {
menu $popups(bp) -tearoff 0
if {!$Browsing && [pref get gdb/control_target]} {
- addPopup bp "Continue to Here" "$this continue_to_here" {} 0 0
- addPopup bp "Jump to Here" "$this jump_to_here" {} 0 0
+ addPopup bp "Continue to Here" "$this continue_to_here" green 0 0
$popups(bp) add separator
-
- addPopup bp "Disable Breakpoint" "$this enable_disable_at_line disable" \
- $bp_fg
- $popups(bp) add separator
}
- addPopup bp "Delete Breakpoint" "$this remove_bp_at_line"
+ addPopup bp "Delete Breakpoint" "$this remove_bp_at_line" $bp_fg
# Currently you cannot set a tracepoint and a breakpoint at the same line...
#
@@ -234,7 +236,6 @@ itcl::body SrcTextWin::build_popups {} {
if {[pref get gdb/control_target]} {
addPopup tp "Continue to Here" "$this continue_to_here" green 0 0
- addPopup tp "Jump to Here" "$this jump_to_here" {} 0 0
# $popups(tp) add separator
# Currently you cannot set a tracepoint and a breakpoint at the same line...
@@ -267,11 +268,9 @@ itcl::body SrcTextWin::build_popups {} {
if {!$Browsing && [pref get gdb/control_target]} {
addPopup bp_and_tp "Continue to Here" "$this continue_to_here" \
green 0 0
- addPopup bp_and_tp "Jump to Here" "$this jump_to_here" \
- green 0 0
$popups(bp_and_tp) add separator
}
-
+
addPopup bp_and_tp "Delete Breakpoint" "$this remove_bp_at_line" $bp_fg
if {$Tracing} {
addPopup bp_and_tp "Modify Tracepoint" "$this set_tp_at_line" $tp_fg
@@ -279,17 +278,7 @@ itcl::body SrcTextWin::build_popups {} {
"$this remove_tp_at_line" $tp_fg
}
}
-
- if {![winfo exists $popups(disabled_bp)]} {
- menu $popups(disabled_bp) -tearoff 0
-
- addPopup disabled_bp "Enable Breakpoint" \
- "$this enable_disable_at_line enable" $bp_fg
-
- $popups(disabled_bp) add separator
- addPopup disabled_bp "Delete Breakpoint" "$this remove_bp_at_line"
- }
-
+
if {![winfo exists $popups(tp_browse)]} {
# this popup is on a tracepoint when browsing.
@@ -298,13 +287,14 @@ itcl::body SrcTextWin::build_popups {} {
addPopup tp_browse "Next hit Here" "$this next_hit_at_line" \
green
}
+
}
# ------------------------------------------------------------------
# METHOD: build_win - build the main source paned window
# ------------------------------------------------------------------
-itcl::body SrcTextWin::build_win {} {
- cyg::panedwindow $itk_interior.p
+body SrcTextWin::build_win {} {
+ cyg::panedwindow $itk_interior.p -background white
set _tpane pane$filenum
incr filenum
@@ -314,7 +304,7 @@ itcl::body SrcTextWin::build_win {} {
set Stwc(gdbtk_scratch_widget:pane) $_tpane
set Stwc(gdbtk_scratch_widget:dirty) 0
- set twinp [iwidgets::scrolledtext $pane1.st \
+ set twinp [iwidgets::scrolledtext $pane1.st -textbackground white \
-hscrollmode dynamic -vscrollmode dynamic]
set twin [$twinp component text]
pack $twinp -fill both -expand yes
@@ -326,7 +316,7 @@ itcl::body SrcTextWin::build_win {} {
# METHOD: SetRunningState - set state based on if GDB is running or not.
# This disables the popup menus when GDB is not running yet.
# ------------------------------------------------------------------
-itcl::body SrcTextWin::SetRunningState {state} {
+body SrcTextWin::SetRunningState {state} {
# debug "$state"
foreach elem $popups(run_disabled) {
$popups([lindex $elem 0]) entryconfigure [lindex $elem 1] -state $state
@@ -336,7 +326,7 @@ itcl::body SrcTextWin::SetRunningState {state} {
# ------------------------------------------------------------------
# METHOD: enable - enable or disable bindings and change cursor
# ------------------------------------------------------------------
-itcl::body SrcTextWin::enable {on} {
+body SrcTextWin::enable {on} {
if {$on} {
set Running 0
set glyph ""
@@ -349,19 +339,19 @@ itcl::body SrcTextWin::enable {on} {
set status disabled
}
- if {[winfo exists $twin]} {
- bind $twin <B1-Motion> $bnd
- bind $twin <Double-1> $bnd
- bind $twin <Triple-1> $bnd
- enable_disable_src_tags $twin $status
- $twin configure -cursor $glyph
- }
-
+ bind $twin <B1-Motion> $bnd
+ bind $twin <Double-1> $bnd
+ bind $twin <Triple-1> $bnd
+ enable_disable_src_tags $twin $status
if {$bwin != ""} {
bind $bwin <B1-Motion> $bnd
bind $bwin <Double-1> $bnd
bind $bwin <Triple-1> $bnd
enable_disable_src_tags $bwin $status
+ }
+
+ $twin configure -cursor $glyph
+ if {$bwin != ""} {
$bwin configure -cursor $glyph
}
}
@@ -369,7 +359,7 @@ itcl::body SrcTextWin::enable {on} {
# ------------------------------------------------------------------
# PROC: makeBreakDot - make the break dot for the screen
# ------------------------------------------------------------------
-itcl::body SrcTextWin::makeBreakDot {size colorList {image {}}} {
+body SrcTextWin::makeBreakDot {size colorList {image {}}} {
if {$size > 32} {
set size 32
} elseif {$size < 1} {
@@ -405,12 +395,12 @@ itcl::body SrcTextWin::makeBreakDot {size colorList {image {}}} {
# ------------------------------------------------------------------
# METHOD: setTabs - set the tabs for the assembly/src windows
# ------------------------------------------------------------------
-itcl::body SrcTextWin::setTabs {win {asm S}} {
- set fsize [font measure [pref get gdb/src/font] "W"]
+body SrcTextWin::setTabs {win {asm ""}} {
+ set fsize [font measure src-font "W"]
set tsize [pref get gdb/src/tab_size]
set rest ""
- if {[string compare $asm "S"] != 0} {
+ if {$asm != ""} {
set first [expr {$fsize * 12}]
set second [expr {$fsize * 13}]
set third [expr {$fsize * 34}]
@@ -441,7 +431,7 @@ itcl::body SrcTextWin::setTabs {win {asm S}} {
$win configure -tabs $tablist
}
-itcl::body SrcTextWin::enable_disable_src_tags {win how} {
+body SrcTextWin::enable_disable_src_tags {win how} {
switch $how {
normal {
@@ -490,25 +480,25 @@ itcl::body SrcTextWin::enable_disable_src_tags {win how} {
# ------------------------------------------------------------------
# METHOD: config_win - configure the source or assembly text window
# ------------------------------------------------------------------
-itcl::body SrcTextWin::config_win {win {asm S}} {
+body SrcTextWin::config_win {win {asm ""}} {
# debug "$win $asm Tracing=$Tracing Browsing=$Browsing"
- $win config -borderwidth 2 -insertwidth 0 -wrap none
+ $win config -borderwidth 2 -insertwidth 0 -wrap none -bg white
# font
set font [pref get gdb/src/font]
- $win configure -font $font -bg $::Colors(textbg) -fg $::Colors(textfg)
+ $win configure -font $font
setTabs $win $asm
-
+
# set up some tags. should probably be done differently
# !! change bg?
- $win tag configure break_rgn_tag
+ $win tag configure break_rgn_tag -foreground [pref get gdb/src/break_fg]
foreach type $bp_types {
- $win tag configure ${type}_tag
+ $win tag configure ${type}_tag -foreground [pref get gdb/src/break_fg]
}
- $win tag configure tp_tag
+ $win tag configure tp_tag -foreground [pref get gdb/src/break_fg]
$win tag configure source_tag2 -foreground [pref get gdb/src/source2_fg]
$win tag configure PC_TAG -background [pref get gdb/src/PC_TAG]
$win tag configure STACK_TAG -background [pref get gdb/src/STACK_TAG]
@@ -531,13 +521,7 @@ itcl::body SrcTextWin::config_win {win {asm S}} {
$win tag bind break_rgn_tag <Button-3> \
"$this do_tag_popup break_rgn %X %Y %y; break"
foreach type $bp_types {
- if {$type == "disabled_bp"} then {
- set tag disabled_bp
- } else {
- set tag bp
- }
- $win tag bind ${type}_tag <Button-3> \
- "$this do_tag_popup $tag %X %Y %y; break"
+ $win tag bind ${type}_tag <Button-3> "$this do_tag_popup bp %X %Y %y; break"
}
$win tag bind tp_tag <Button-3> "$this do_tag_popup tp %X %Y %y; break"
$win tag bind bp_and_tp_tag <Button-3> "$this do_tag_popup bp_and_tp %X %Y %y; break"
@@ -579,7 +563,7 @@ itcl::body SrcTextWin::config_win {win {asm S}} {
bind_plain_key $win x "$this do_key quit; break"
if {!$Browsing && [pref get gdb/control_target]} {
- if {[string compare $asm "S"] != 0} {
+ if {$asm != ""} {
bind_plain_key $win s "$this do_key stepi; break"
bind_plain_key $win n "$this do_key nexti; break"
} else {
@@ -594,9 +578,7 @@ itcl::body SrcTextWin::config_win {win {asm S}} {
bind_plain_key $win Control-p "$this do_key print"
bind_plain_key $win Control-u "$this do_key debug; break"
bind_plain_key $win Control-o [list $this do_key open]
- bind_plain_key $win Control-a [list $this do_key attach]
- bind_plain_key $win Control-w [code $this do_key close]
-
+
if {!$Browsing && [pref get gdb/control_target]} {
# Ctrl+F5 is another accelerator for Run
bind_plain_key $win Control-F5 "$this do_key run"
@@ -655,7 +637,7 @@ itcl::body SrcTextWin::config_win {win {asm S}} {
bind_plain_key $win Control-s "$this do_key stack"
bind_plain_key $win Control-r "$this do_key registers"
bind_plain_key $win Control-m "$this do_key memory"
- bind_plain_key $win Control-t "$this do_key watch"
+ bind_plain_key $win Control-w "$this do_key watch"
bind_plain_key $win Control-l "$this do_key locals"
bind_plain_key $win Control-k "$this do_key kod"
if { !$Tracing } {
@@ -680,17 +662,12 @@ itcl::body SrcTextWin::config_win {win {asm S}} {
# Up/Down arrow key bindings
bind_plain_key $win Up [list %W yview scroll -1 units]
bind_plain_key $win Down [list %W yview scroll +1 units]
-
- # After loading a new file, focus sometimes gets lost
- # so point it back to this window if it doesn't already
- # point elsewhere.
- if {[focus -displayof $win] == ""} {focus $win}
}
# ------------------------------------------------------------------
# METHOD: addPopup - adds a popup to one of the source popup menus
# ------------------------------------------------------------------
-itcl::body SrcTextWin::addPopup {menu label command {abg {}} {browse 1} {run 1}} {
+body SrcTextWin::addPopup {menu label command {abg {}} {browse 1} {run 1}} {
if {$abg == ""} {
$popups($menu) add command -label $label -command $command
@@ -708,14 +685,11 @@ itcl::body SrcTextWin::addPopup {menu label command {abg {}} {browse 1} {run 1}}
}
}
-
# ------------------------------------------------------------------
-# PUBLIC METHOD: set_variable - Handle changes in the gdb variables
+# METHOD: handle_set_hook - Handle changes in the gdb variables
# changed through the "set" gdb command.
# ------------------------------------------------------------------
-itcl::body SrcTextWin::set_variable {event} {
- set var [$event get variable]
- set val [$event get value]
+body SrcTextWin::handle_set_hook {var val} {
debug "Set hook got called with $var $val"
switch $var {
disassembly-flavor {
@@ -729,7 +703,7 @@ itcl::body SrcTextWin::set_variable {event} {
# mark all the cached assembly windows dirty, and force the
# visible window to be redisplayed.
# ------------------------------------------------------------------
-itcl::body SrcTextWin::disassembly_changed {} {
+body SrcTextWin::disassembly_changed {} {
foreach name [array names Stwc *:pane] {
debug "Looking at $name"
set vals [split $name ,]
@@ -749,11 +723,11 @@ itcl::body SrcTextWin::disassembly_changed {} {
# ------------------------------------------------------------------
# METHOD: reconfig - used when preferences change
# ------------------------------------------------------------------
-itcl::body SrcTextWin::reconfig {} {
+body SrcTextWin::reconfig {} {
# debug
# Make sure we redo the break images when we reconfigure
- set size [font measure [pref get gdb/src/font] "W"]
+ set size [font measure src-font "W"]
makeBreakDot $size [pref get gdb/src/bp_fg] $break_images(bp)
makeBreakDot $size [pref get gdb/src/temp_bp_fg] $break_images(temp_bp)
makeBreakDot $size [pref get gdb/src/disabled_fg] $break_images(disabled_bp)
@@ -827,7 +801,7 @@ itcl::body SrcTextWin::reconfig {} {
# ------------------------------------------------------------------
# METHOD: updateBalloon - we have gone idle, update the balloon
# ------------------------------------------------------------------
-itcl::body SrcTextWin::updateBalloon {} {
+body SrcTextWin::updateBalloon {} {
set err [catch {$_balloon_var update} changed]
catch {$_balloon_var name} var
@@ -841,7 +815,7 @@ itcl::body SrcTextWin::updateBalloon {} {
}
}
-itcl::body SrcTextWin::balloon_value {variable} {
+body SrcTextWin::balloon_value {variable} {
catch {$variable value} value
set value [string trim $value \ \r\t\n]
@@ -866,7 +840,7 @@ itcl::body SrcTextWin::balloon_value {variable} {
# ------------------------------------------------------------------
# METHOD: ClearTags - clear all tags
# ------------------------------------------------------------------
-itcl::body SrcTextWin::ClearTags {} {
+body SrcTextWin::ClearTags {} {
foreach tag {PC_TAG BROWSE_TAG STACK_TAG} {
catch {
$twin tag remove $tag $current(line).2 $current(line).end
@@ -883,22 +857,13 @@ itcl::body SrcTextWin::ClearTags {} {
# METHOD: _mtime_changed - check if the modtime for a file
# has changed.
# ------------------------------------------------------------------
-itcl::body SrcTextWin::_mtime_changed {filename} {
- global gdbtk_platform
+body SrcTextWin::_mtime_changed {filename} {
+ set f [gdb_find_file $filename]
- if [catch {gdb_find_file $filename} f] {
- set r 1
- } elseif {$f == ""} {
+ if {$f == ""} {
set r 1
} else {
- if {[string compare $gdbtk_platform(os) "cygwin"] == 0} {
- set f [ide_cygwin_path to_win32 $f]
- }
- if {[catch {file mtime $f} mtime]} {
- debug "Could not stat file \"$f\" - \"$mtime\""
- # The return code is not of much significance in this case
- return 1
- }
+ set mtime [file mtime $f]
if {![info exists Stwc($filename:mtime)]} {
debug "no mtime. resetting to zero"
set Stwc($filename:mtime) 0
@@ -920,7 +885,7 @@ itcl::body SrcTextWin::_mtime_changed {filename} {
# ------------------------------------------------------------------
# METHOD: FillSource - fill a window with source
# ------------------------------------------------------------------
-itcl::body SrcTextWin::FillSource {w tagname filename funcname line addr pc_addr lib} {
+body SrcTextWin::FillSource {w tagname filename funcname line addr pc_addr lib} {
global gdb_running
upvar ${w}win win
@@ -935,17 +900,12 @@ itcl::body SrcTextWin::FillSource {w tagname filename funcname line addr pc_addr
if {![LoadFile $w $filename $lib $mtime]} {
# failed to find source file
dbug W "Changing to ASSEMBLY"
-
- # We have to update this data here (it is also done by the caller)
- # because we want to call mode, which calls mode_set, which calls
- # location using these values.
set current(line) $line
set current(tag) $tagname
set current(addr) $addr
set current(funcname) $funcname
set current(filename) $filename
set current(lib) $lib
-
set oldmode SOURCE
$parent mode "" ASSEMBLY
return
@@ -981,18 +941,13 @@ itcl::body SrcTextWin::FillSource {w tagname filename funcname line addr pc_addr
return
}
# no source; switch to assembly
- dbug W "no source file; switch to assembly"
-
- # We have to update this data here (it is also done by the caller)
- # because we want to call mode, which calls mode_set, which calls
- # location using these values.
+# debug "no source file; switch to assembly"
set current(line) $line
set current(tag) $tagname
set current(addr) $addr
set current(funcname) $funcname
set current(filename) $filename
set current(lib) $lib
-
set oldmode $current(mode)
$parent mode "" ASSEMBLY
}
@@ -1000,7 +955,7 @@ itcl::body SrcTextWin::FillSource {w tagname filename funcname line addr pc_addr
# ------------------------------------------------------------------
# METHOD: FillAssembly - fill a window with disassembled code
# ------------------------------------------------------------------
-itcl::body SrcTextWin::FillAssembly {w tagname filename funcname line addr pc_addr lib} {
+body SrcTextWin::FillAssembly {w tagname filename funcname line addr pc_addr lib} {
global gdb_running
upvar ${w}win win
upvar _${w}pane pane
@@ -1024,9 +979,8 @@ itcl::body SrcTextWin::FillAssembly {w tagname filename funcname line addr pc_ad
|| ([info exists Stwc($addr:dirty)] && $Stwc($addr:dirty))} {
set mode_changed 0
set oldpane $pane
- set result [LoadFromCache $w $addr A $lib]
- if {$result == 1} {
- #debug "Disassembling at $addr"
+ if {[LoadFromCache $w $addr A $lib]} {
+ #debug [format "Disassembling at %x" $addr]
#debug "cf=$current(filename) name=$filename"
if {[catch {gdb_load_disassembly $win nosource \
[scope _map] $Cname $addr} mess]} {
@@ -1036,29 +990,40 @@ itcl::body SrcTextWin::FillAssembly {w tagname filename funcname line addr pc_ad
set pane $Stwc(gdbtk_scratch_widget:pane)
set win [[$itk_interior.p childsite $pane].st component text]
$win delete 0.0 end
- $win insert 0.0 "$mess"
+ $win insert 0.0 "Unable to Read Instructions at $addr"
if {$oldpane != "" && $oldpane != $pane} {
$itk_interior.p replace $oldpane $pane
} else {
$itk_interior.p show $pane
}
} else {
- debug "address range is $mess"
+ foreach {asm_lo_addr asm_hi_addr} $mess {break}
+ debug "Got low address: $asm_lo_addr and high: $asm_hi_addr"
}
- } elseif {$result == 0} {
- debug "LoadFromCache returned 0"
- } else {
- # This branch should not ever happen. In assembly mode, there
- # are no checks in LoadFromCache that can fail.
- debug "LoadFromCache returned -1"
}
set current(filename) $filename
set do_display_breaks 1
}
# highlight proper line number
- _highlightAsmLine $win $addr $pc_addr $tagname $filename $funcname
-
+ if {[info exists _map($Cname,pc=$addr)]} {
+ # if current file has PC, highlight that too
+ if {$gdb_running && $tagname != "PC_TAG" && $pc(filename) == $filename
+ && $pc(func) == $funcname} {
+ set pc(asm_line) $_map($Cname,pc=$pc_addr)
+ $win tag add PC_TAG $pc(asm_line).2 $pc(asm_line).end
+ }
+ set current(asm_line) $_map($Cname,pc=$addr)
+ # don't set browse tag if it is at PC
+ if {$pc_addr != $addr || $tagname == "PC_TAG"} {
+ # HACK. In STACK mode we usually want the previous instruction
+ # but not when we are browsing a trace experiment.
+ if {[string compare $tagname "STACK_TAG"] == 0 && !$Browsing} {
+ incr current(asm_line) -1
+ }
+ $win tag add $tagname $current(asm_line).2 $current(asm_line).end
+ }
+ }
display_line $win $current(asm_line)
}
@@ -1066,12 +1031,14 @@ itcl::body SrcTextWin::FillAssembly {w tagname filename funcname line addr pc_ad
# ------------------------------------------------------------------
# METHOD: FillMixed - fill a window with mixed source and assembly
# ------------------------------------------------------------------
-itcl::body SrcTextWin::FillMixed {w tagname filename funcname line addr pc_addr lib} {
+body SrcTextWin::FillMixed {w tagname filename funcname line addr pc_addr lib} {
global gdb_running
upvar ${w}win win
upvar _${w}pane pane
# debug "$win $tagname $filename $funcname $line $addr $pc_addr"
+ set asm_lo_addr ""
+
if {$funcname == ""} {
set oldpane $pane
set pane $Stwc(gdbtk_scratch_widget:pane)
@@ -1088,7 +1055,7 @@ itcl::body SrcTextWin::FillMixed {w tagname filename funcname line addr pc_addr
set mode_changed 0
set oldpane $pane
if {[LoadFromCache $w $funcname M $lib]} {
- # debug "Disassembling at $addr"
+ # debug [format "Disassembling at %x" $addr]
if {[catch {gdb_load_disassembly $win source \
[scope _map] $Cname $addr} mess] } {
# print some intelligent error message
@@ -1104,76 +1071,39 @@ itcl::body SrcTextWin::FillMixed {w tagname filename funcname line addr pc_addr
$parent mode "" ASSEMBLY
return
} else {
- debug "address range is $mess"
+ foreach {asm_lo_addr asm_hi_addr} $mess {break}
+ debug "Got low address: $asm_lo_addr and high: $asm_hi_addr"
}
}
set current(filename) $filename
# now set the breakpoints
set do_display_breaks 1
}
-
# highlight proper line number
- _highlightAsmLine $win $addr $pc_addr $tagname $filename $funcname
- display_line $win $current(asm_line)
-}
-
-# ------------------------------------------------------------------
-# METHOD: _highlightAsmLine - highlight the current execution line
-# in one of the assembly modes
-# ------------------------------------------------------------------
-itcl::body SrcTextWin::_highlightAsmLine {win addr pc_addr \
- tagname filename funcname} {
- global gdb_running
-
- # Some architectures allow multiple instructions in each asm source
- # line...
if {[info exists _map($Cname,pc=$addr)]} {
- set current(asm_line) $_map($Cname,pc=$addr)
- } else {
- set x [gdb_incr_addr $current(addr) -2]
- if {[info exists _map($Cname,pc=$x)]} {
- set current(asm_line) $_map($Cname,pc=$x)
- }
- }
-
- # if current file has PC, highlight that too
- if {$gdb_running && $tagname != "PC_TAG" && $pc(filename) == $filename
- && $pc(func) == $funcname} {
- set pc(asm_line) $_map($Cname,pc=$pc_addr)
- $win tag add PC_TAG $pc(asm_line).2 $pc(asm_line).end
- }
-
- # don't set browse tag if it is at PC
- if {$pc_addr != $addr || $tagname == "PC_TAG"} {
- # HACK. In STACK mode we usually want the previous instruction
- # but not when we are browsing a trace experiment.
- if {[string compare $tagname "STACK_TAG"] == 0 && !$Browsing} {
- incr current(asm_line) -1
- }
- $win tag add $tagname $current(asm_line).2 $current(asm_line).end
- }
-}
-
-# ------------------------------------------------------------------
-# METHOD: set_tag - update tag to STACK without making other changes
-# ------------------------------------------------------------------
-itcl::body SrcTextWin::set_tag_to_stack {} {
- foreach window [list $twin $bwin] {
- if {$window == ""} then {
- continue
+ # if current file has PC, highlight that too
+ if {$gdb_running && $tagname != "PC_TAG" && $pc(filename) == $filename
+ && $pc(func) == $funcname} {
+ set pc(asm_line) $_map($Cname,pc=$pc_addr)
+ $win tag add PC_TAG $pc(asm_line).2 $pc(asm_line).end
}
- foreach {start end} [$window tag ranges PC_TAG] {
- $window tag remove PC_TAG $start $end
- $window tag add STACK_TAG $start $end
+ set current(asm_line) $_map($Cname,pc=$addr)
+# debug "current(asm_line) = $current(asm_line)"
+ if {$pc_addr != $addr || $tagname == "PC_TAG"} {
+ # HACK. In STACK mode we usually want the previous instruction
+ if {$tagname == "STACK_TAG"} {
+ incr current(asm_line) -1
+ }
+ $win tag add $tagname $current(asm_line).2 $current(asm_line).end
}
}
- set current(tag) STACK_TAG
+ display_line $win $current(asm_line)
}
# ------------------------------------------------------------------
# METHOD: location - display a location in a file
# ------------------------------------------------------------------
-itcl::body SrcTextWin::location {tagname filename funcname line addr pc_addr lib} {
+body SrcTextWin::location {tagname filename funcname line addr pc_addr lib} {
# debug "$tagname $filename $line $addr $pc_addr, mode=$current(mode) oldmode=$oldmode cf=$current(filename) lib=$lib"
ClearTags
@@ -1192,21 +1122,13 @@ itcl::body SrcTextWin::location {tagname filename funcname line addr pc_addr lib
if {$oldmode != "" \
&& [string compare $filename $current(filename)] != 0} {
-
- if [catch {gdb_find_file $filename} fullname] {
- dbug W "$filename: $fullname"
- set fullname ""
- }
-
- if {$fullname != ""} {
+ if {[gdb_find_file $filename] != ""} {
set tmp $oldmode
set oldmode ""
$parent mode "" $tmp 0
}
}
- set oldpane $_tpane
-
switch $current(mode) {
SOURCE {
FillSource t $tagname $filename $funcname $line $addr $pc_addr $lib
@@ -1228,13 +1150,6 @@ itcl::body SrcTextWin::location {tagname filename funcname line addr pc_addr lib
}
}
}
-
- # After switching panes, clear the previous pane's cursor so that it isn't
- # used as the default when no other cursors are set.
- if { "$oldpane" != "$_tpane" } {
- $twin configure -cursor ""
- }
-
set current(line) $line
set current(tag) $tagname
set current(addr) $addr
@@ -1250,19 +1165,15 @@ itcl::body SrcTextWin::location {tagname filename funcname line addr pc_addr lib
# ------------------------------------------------------------------
# METHOD: LoadFile - loads in a new source file
# ------------------------------------------------------------------
-itcl::body SrcTextWin::LoadFile {w name lib mtime_changed} {
- debug "$name $current(filename) $current(mode)"
+body SrcTextWin::LoadFile {w name lib mtime_changed} {
+# debug "$name $current(filename) $current(mode)"
upvar ${w}win win
upvar _${w}pane pane
set oldpane $pane
- set result [LoadFromCache $w $name "S" $lib]
- if {$result == -1} {
- # This is a source file we could not find the source for...
- return 0
- } elseif {$result == 1 || $mtime_changed} {
+ if {[LoadFromCache $w $name "" $lib] || $mtime_changed} {
$win delete 0.0 end
- debug "READING $name"
+# debug "READING $name"
if {[catch {gdb_loadfile $win $name $Linenums} msg]} {
dbug W "Error opening $name: $msg"
#if {$msg != ""} {
@@ -1283,7 +1194,7 @@ itcl::body SrcTextWin::LoadFile {w name lib mtime_changed} {
# METHOD: display_line - make sure a line is displayed and near the center
# ------------------------------------------------------------------
-itcl::body SrcTextWin::display_line { win line } {
+body SrcTextWin::display_line { win line } {
::update idletasks
# keep line near center of display
set pixHeight [winfo height $win]
@@ -1306,7 +1217,7 @@ itcl::body SrcTextWin::display_line { win line } {
# uses current(filename) in SOURCE mode
# ------------------------------------------------------------------
-itcl::body SrcTextWin::display_breaks {} {
+body SrcTextWin::display_breaks {} {
# debug
# clear any previous breakpoints
@@ -1351,7 +1262,7 @@ itcl::body SrcTextWin::display_breaks {} {
# METHOD: insertBreakTag - insert the right amount of tag chars
# into the text window WIN, at line linenum.
# ------------------------------------------------------------------
-itcl::body SrcTextWin::insertBreakTag {win linenum tag} {
+body SrcTextWin::insertBreakTag {win linenum tag} {
# debug "$win $linenum $tag"
# Get the tags at the current line.
@@ -1370,11 +1281,12 @@ itcl::body SrcTextWin::insertBreakTag {win linenum tag} {
$linenum.0 "$linenum.0 lineend"] 1]
$win tag remove break_rgn_tag $linenum.0 "$linenum.0 lineend"
$win delete $linenum.0
-
+
# Strip the "_tag" off the end of the tag to get the image name.
$win image create $linenum.0 -image $break_images($img_name)
$win tag add $tag $linenum.0 $stop
} else {
+
set other_tag [lindex $tag_list \
[lsearch -glob $tag_list {*[bt]p_tag}]]
if {$other_tag == ""} {
@@ -1395,7 +1307,7 @@ itcl::body SrcTextWin::insertBreakTag {win linenum tag} {
# from the given line. If this is the last break tag on the
# line reinstall the break_rgn_tag
# ------------------------------------------------------------------
-itcl::body SrcTextWin::removeBreakTag {win linenum tag } {
+body SrcTextWin::removeBreakTag {win linenum tag } {
# debug "$win $linenum $tag"
set tag_list [$win tag names $linenum.0]
@@ -1445,37 +1357,15 @@ itcl::body SrcTextWin::removeBreakTag {win linenum tag } {
}
# ------------------------------------------------------------------
-# PUBLIC METHOD: breakpoint - Handle a breakpoint create, delete,
-# or modify event from the backend.
-# ------------------------------------------------------------------
-itcl::body SrcTextWin::breakpoint {bp_event} {
-
- bp [$bp_event get action] [$bp_event get number] [$bp_event get address] \
- [$bp_event get line] [$bp_event get file] [$bp_event get disposition] \
- [$bp_event get enabled] [$bp_event get thread]
-}
-
-# ------------------------------------------------------------------
-# PUBLIC METHOD: tracepoint - Handle a tracepoint create, delete,
-# modify event from the backend.
-# ------------------------------------------------------------------
-itcl::body SrcTextWin::tracepoint {tp_event} {
-
- bp [$tp_event get action] [$tp_event get number] [$tp_event get address] \
- [$tp_event get line] [$tp_event get file] tracepoint \
- [$tp_event get pass_count]
-}
-
-# ------------------------------------------------------------------
# METHOD: bp - set and remove breakpoints
#
# if $addr is valid, the breakpoint will be set in the assembly or
# mixed window at that address. If $line and $file are valid,
# a breakpoint will be set in the source window if appropriate.
# ------------------------------------------------------------------
-itcl::body SrcTextWin::bp {action bpnum addr {linenum {}} {file {}} {type 0} {enabled 0} {thread -1}} {
+body SrcTextWin::bp {action bpnum addr {linenum {}} {file {}} {type 0} {enabled 0} {thread -1}} {
# debug "$action addr=$addr line=$linenum file=$file type=$type current(filename)=$current(filename)"
-
+
switch $current(mode) {
SOURCE {
if {[string compare $file $current(filename)] == 0 && $linenum != {}} {
@@ -1512,25 +1402,17 @@ itcl::body SrcTextWin::bp {action bpnum addr {linenum {}} {file {}} {type 0} {en
# ------------------------------------------------------------------
# METHOD: do_bp - bp helper function
# ------------------------------------------------------------------
-itcl::body SrcTextWin::do_bp { win action linenum type bpnum enabled thread asm} {
+body SrcTextWin::do_bp { win action linenum type bpnum enabled thread asm} {
# debug "$action line=$linenum type=$type bpnum=$bpnum enabled=$enabled thread=$thread"
-
+
if {$dont_change_appearance} {
return
}
- if {$action == "delete" && [string compare $type tracepoint] != 0} {
+ if {!$asm && $action == "delete" && [string compare $type tracepoint] != 0} {
# make sure there are no more breakpoints on
# this line.
- if {!$asm} {
- set bps [gdb_find_bp_at_line $current(filename) $linenum]
- } else {
- if {[info exists _map($Cname,line=$linenum)]} {
- set bps [gdb_find_bp_at_addr $_map($Cname,line=$linenum)]
- } else {
- set bps {}
- }
- }
+ set bps [gdb_find_bp_at_line $current(filename) $linenum]
if {[llength $bps] > 0} {
foreach b $bps {
if {$b != $bpnum} {
@@ -1564,42 +1446,38 @@ itcl::body SrcTextWin::do_bp { win action linenum type bpnum enabled thread asm}
set type thread
}
}
-
+
switch $type {
donttouch {
set tag_type bp_tag
- set remove_type disabled_bp_tag
}
delete {
set tag_type temp_bp_tag
}
disabled_bp {
set tag_type disabled_bp_tag
- set remove_type bp_tag
}
tracepoint {
set tag_type tp_tag
- set remove_type disabled_tp_tag
}
disabled_tracepoint {
set tag_type disabled_tp_tag
- set remove_type tp_tag
}
thread {
set tag_type thread_bp_tag
}
default {
- dbug E "UNKNOWN BP TYPE action=\"$action\" type=\"$type\""
+ dbug E "UNKNOWN BP TYPE $action $type"
$win insert $linenum.0 "X" bp_tag
set tag_type bp_tag
}
}
-
+
if {[string compare $action "delete"] == 0} {
removeBreakTag $win $linenum $tag_type
} else {
- if {[string compare $action "modify"] == 0 && $remove_type != ""} {
- removeBreakTag $win $linenum $remove_type
+ if {[string compare $action "modify"] == 0} {
+ removeBreakTag $win $linenum $tag_type
}
insertBreakTag $win $linenum $tag_type
}
@@ -1609,7 +1487,7 @@ itcl::body SrcTextWin::do_bp { win action linenum type bpnum enabled thread asm}
# ------------------------------------------------------------------
# METHOD: hasBP - see if a line number has a breakpoint set
# ------------------------------------------------------------------
-itcl::body SrcTextWin::hasBP {win line} {
+body SrcTextWin::hasBP {win line} {
if {$win == ""} {
set win $popups(saved_win)
}
@@ -1623,7 +1501,7 @@ itcl::body SrcTextWin::hasBP {win line} {
# ------------------------------------------------------------------
# METHOD: hasTP - see if a line number has a tracepoint set
# ------------------------------------------------------------------
-itcl::body SrcTextWin::hasTP {win line} {
+body SrcTextWin::hasTP {win line} {
if {$win == ""} {
set win $popups(saved_win)
}
@@ -1635,7 +1513,7 @@ itcl::body SrcTextWin::hasTP {win line} {
}
# ------------------------------------------------------------------
-# METHOD: report_source_location
+# METHOD: report_current_location
#
# This function reports the "current" location in the source
# window, where current means what gdb_loc would return, if
@@ -1645,7 +1523,7 @@ itcl::body SrcTextWin::hasTP {win line} {
# Return:
# The gdb_loc result for the location found
# ------------------------------------------------------------------
-itcl::body SrcTextWin::report_source_location {} {
+body SrcTextWin::report_source_location {} {
if {$current(filename) == ""} {
error "No source file in window"
@@ -1712,7 +1590,7 @@ itcl::body SrcTextWin::report_source_location {} {
# set_cmd - for convenience, this is the command needed to set a
# breakpoint at this address.
# ------------------------------------------------------------------
-itcl::body SrcTextWin::lookup_line {win y} {
+body SrcTextWin::lookup_line {win y} {
#debug "$win $y"
if {$y == -1} {
set y $popups(saved_y)
@@ -1766,7 +1644,7 @@ itcl::body SrcTextWin::lookup_line {win y} {
#
# The threads parameter is not currently used.
# ------------------------------------------------------------------
-itcl::body SrcTextWin::continue_to_here {{win {}} {y -1} {threads -1}} {
+body SrcTextWin::continue_to_here {{win {}} {y -1} {threads -1}} {
# Look up the line... This foreach is an lassign...
foreach {name line addr type set_cmd} [lookup_line $win $y] {
@@ -1792,57 +1670,11 @@ itcl::body SrcTextWin::continue_to_here {{win {}} {y -1} {threads -1}} {
}
# ------------------------------------------------------------------
-# METHOD: jump_to_here - Advance to the line pointed to by the
-# y coordinate in the window win. If win is {} or y is -1, the values
-# saved in the popups array are used.
-#
-# The threads parameter is not currently used.
-# ------------------------------------------------------------------
-itcl::body SrcTextWin::jump_to_here {{win {}} {y -1} {threads -1}} {
-
- # Look up the line... This foreach is an lassign...
- foreach {name line addr type set_cmd} [lookup_line $win $y] {
- break
- }
-
- # Unfortunately we cant set the pc to a linespec and we have to do a
- # trick with a temporary breakpoint and the jump command.
- # FIXME: Get the address from the linespec.
- # FIXME: Even in the case we do have an address, I was not able to just
- # change the PC and get things updated wright. While I work on that,
- # I will use the temp breakpoint and jump trick for that case as well.
-
- set dont_change_appearance 1
-
- foreach i [gdb_get_breakpoint_list] {
- set enabled($i) [lindex [gdb_get_breakpoint_info $i] 5]
- }
- gdb_cmd "disable"
-
- if {$type == "asm"} {
- gdb_immediate "tbreak *$addr"
- gdb_immediate "jump *$addr"
- } else {
- eval $set_cmd temp $threads
- gdb_immediate "jump $name:$line"
- }
- gdb_cmd "enable"
- foreach i [gdb_get_breakpoint_list] {
- if {![info exists enabled($i)]} {
- gdb_cmd "delete $i"
- } elseif {!$enabled($i)} {
- gdb_cmd "disable $i"
- }
- }
- set dont_change_appearance 0
-}
-
-# ------------------------------------------------------------------
# METHOD: set_bp_at_line - called when an empty break tag is clicked on
#
# When "threads" is set it means to set a bp on each thread in the list.
# ------------------------------------------------------------------
-itcl::body SrcTextWin::set_bp_at_line {{type N} {win {}} {y -1} {threads "-1"}} {
+body SrcTextWin::set_bp_at_line {{type N} {win {}} {y -1} {threads "-1"}} {
# debug "$win $y $type $current(filename) Tracing=$Tracing"
if {$Running} {return}
@@ -1869,75 +1701,25 @@ itcl::body SrcTextWin::set_bp_at_line {{type N} {win {}} {y -1} {threads "-1"}}
}
# ------------------------------------------------------------------
-# METHOD: enable_disable_at_line - Enable or disable breakpoint
-# ------------------------------------------------------------------
-itcl::body SrcTextWin::enable_disable_at_line {action} {
- if {$Running} {
- return
- }
-
- # FIXME: should this work on $bwin as well? In that case we'd need
- # a `win' argument...
-
- set y $popups(saved_y)
-
- $twin tag remove _show_variable 1.0 end
- set line [lindex [split [$twin index @0,$y] .] 0]
- set bps ""
-
- switch $current(mode) {
- SRC+ASM {
- }
- ASSEMBLY {
- if {[info exists _map($Cname,line=$line)]} {
- set addr $_map($Cname,line=$line)
- set bps [gdb_find_bp_at_addr $addr]
- } else {
- return
- }
- }
- MIXED {
- if {[info exists _map($Cname,line=$line)]} {
- set addr $_map($Cname,line=$line)
- set bps [gdb_find_bp_at_addr $addr]
- } else {
- return
- }
- }
- }
-
- if {$bps == ""} {
- set bps [gdb_find_bp_at_line $current(filename) $line]
- }
-
- # ACTION is `enable' or `disable'
- gdb_cmd "$action $bps"
-}
-
-# ------------------------------------------------------------------
# METHOD: remove_bp_at_line - called when a bp tag is clicked on
#
# when "threads" is set it means to set a bp on each thread in the list.
# ------------------------------------------------------------------
-itcl::body SrcTextWin::remove_bp_at_line {{win {}} {y -1}} {
+body SrcTextWin::remove_bp_at_line {{win {}} {y -1}} {
if {$Running} {return}
# Look up the line... This foreach is an lassign...
-
+
foreach {name line addr type} [lookup_line $win $y] {
break
}
-
- # FIXME: if there are multiple bp/tp at a single line,
- # we will (right now) always take the first one we find...
- switch $type {
- src { set bps [gdb_find_bp_at_line $name $addr] }
- asm { set bps [gdb_find_bp_at_addr $addr] }
+
+ if {[string compare $type src] == 0} {
+ gdb_cmd "clear $name:$addr"
+ } else {
+ gdb_cmd "clear *$addr"
}
-
- set number [lindex $bps 0]
- gdb_cmd "delete $number"
}
@@ -1946,7 +1728,7 @@ itcl::body SrcTextWin::remove_bp_at_line {{win {}} {y -1}} {
#
# when "threads" is set it means to set a bp on each thread in the list.
# ------------------------------------------------------------------
-itcl::body SrcTextWin::set_tp_at_line {{win {}} {y -1}} {
+body SrcTextWin::set_tp_at_line {{win {}} {y -1}} {
# debug "$win $y $current(filename) Tracing=$Tracing"
if {$Running} {return}
@@ -1972,7 +1754,7 @@ itcl::body SrcTextWin::set_tp_at_line {{win {}} {y -1}} {
# given by win & y...
#
# ------------------------------------------------------------------
-itcl::body SrcTextWin::next_hit_at_line {{win {}} {y -1}} {
+body SrcTextWin::next_hit_at_line {{win {}} {y -1}} {
# debug "$win $y $current(filename) Tracing=$Tracing"
if {!$Browsing} {return}
@@ -2002,7 +1784,7 @@ itcl::body SrcTextWin::next_hit_at_line {{win {}} {y -1}} {
#
# when "threads" is set it means to set a bp on each thread in the list.
# ------------------------------------------------------------------
-itcl::body SrcTextWin::remove_tp_at_line {{win {}} {y -1}} {
+body SrcTextWin::remove_tp_at_line {{win {}} {y -1}} {
if {$Running} {return}
@@ -2033,7 +1815,7 @@ Error was: $errTxt"
# METHOD: do_tag_popup - The tag bind function for breakpoint popups
# ------------------------------------------------------------------
-itcl::body SrcTextWin::do_tag_popup {name X Y y} {
+body SrcTextWin::do_tag_popup {name X Y y} {
# debug "$name $X $Y $y"
@@ -2056,7 +1838,7 @@ itcl::body SrcTextWin::do_tag_popup {name X Y y} {
# METHOD: do_source_popup - tag bind function for source popups
# ------------------------------------------------------------------
-itcl::body SrcTextWin::do_source_popup { X Y x y } {
+body SrcTextWin::do_source_popup { X Y x y } {
if {$Running || [winfo ismapped $popups(source)]} {
return
}
@@ -2127,8 +1909,6 @@ itcl::body SrcTextWin::do_source_popup { X Y x y } {
-command [list $this addToWatch $variable]
$popups(source) add command -label "Dump Memory at $variable" \
-command [list ManagedWin::open MemWin -force -addr_exp $variable]
- $popups(source) add command -label "Set Breakpoint at $variable" \
- -command [list gdb_cmd "break $variable"]
$popups(source) add separator
}
}
@@ -2136,26 +1916,28 @@ itcl::body SrcTextWin::do_source_popup { X Y x y } {
$popups(source) add command -label "Open Another Source Window" \
-command {ManagedWin::open SrcWin -force}
- $popups(source) add command -label "Open Source in external editor" \
- -command [code $parent edit]
-
+ if {[info exists ::enable_external_editor] && $::enable_external_editor} {
+ $popups(source) add command -label "Open Source in external editor" \
+ -command [list $parent edit]
+ }
+
tk_popup $popups(source) $X $Y
}
# ------------------------------------------------------------------
# METHOD: addToWatch - add a variable to the watch window
# ------------------------------------------------------------------
-itcl::body SrcTextWin::addToWatch {var} {
+body SrcTextWin::addToWatch {var} {
[ManagedWin::open WatchWin] add $var
}
# ------------------------------------------------------------------
# METHOD: do_key -- wrapper for all key bindings
# ------------------------------------------------------------------
-itcl::body SrcTextWin::do_key {key} {
+body SrcTextWin::do_key {key} {
if {!$Running} {
switch $key {
- print { print $top }
+ print { print }
download { Download::download_it }
run { $parent inferior run }
stack { ManagedWin::open StackWin }
@@ -2182,12 +1964,10 @@ itcl::body SrcTextWin::do_key {key} {
tfind_line { catch {gdb_immediate "tfind line"} }
tfind_tp { catch {gdb_immediate "tfind tracepoint"} }
open { catch {_open_file} }
- close { catch {_close_file} }
browser { catch {ManagedWin::open BrowserWin} }
thread_list { catch {ManagedWin::open ProcessWin} }
debug { catch {ManagedWin::open DebugWin} }
kod { catch {ManagedWin::open KodWin} }
- attach { catch {gdbtk_attach_native} }
default {
dbug E "Unknown key binding: \"$key\""
}
@@ -2200,15 +1980,15 @@ itcl::body SrcTextWin::do_key {key} {
# ------------------------------------------------------------------
# METHOD: mode_get - get the source mode
# ------------------------------------------------------------------
-itcl::body SrcTextWin::mode_get {} {
+body SrcTextWin::mode_get {} {
return $current(mode)
}
# ------------------------------------------------------------------
# METHOD: mode_set - change the source mode
# ------------------------------------------------------------------
-itcl::body SrcTextWin::mode_set {new_mode {go 1}} {
- debug "$new_mode"
+body SrcTextWin::mode_set {new_mode {go 1}} {
+# debug "$new_mode"
if {$new_mode != $current(mode)} {
@@ -2232,7 +2012,7 @@ itcl::body SrcTextWin::mode_set {new_mode {go 1}} {
# METHOD: cancelMotion - cancel any pending motion callbacks for
# the source window's variable balloons
# ------------------------------------------------------------------
-itcl::body SrcTextWin::cancelMotion {} {
+body SrcTextWin::cancelMotion {} {
catch {after cancel $timeoutID}
}
@@ -2240,7 +2020,7 @@ itcl::body SrcTextWin::cancelMotion {} {
# METHOD: motion - callback for mouse motion within the source
# window's text widget
# ------------------------------------------------------------------
-itcl::body SrcTextWin::motion {type win x y} {
+body SrcTextWin::motion {type win x y} {
global gdb_running
cancelMotion
@@ -2266,7 +2046,7 @@ itcl::body SrcTextWin::motion {type win x y} {
# ------------------------------------------------------------------
# METHOD: showBPBalloon - show BP information in a balloon
# ------------------------------------------------------------------
-itcl::body SrcTextWin::showBPBalloon {win x y} {
+body SrcTextWin::showBPBalloon {win x y} {
if {$Running} { return }
$win tag remove _show_variable 1.0 end
set line [lindex [split [$win index @0,$y] .] 0]
@@ -2310,39 +2090,23 @@ itcl::body SrcTextWin::showBPBalloon {win x y} {
foreach b $bps {
set bpinfo [gdb_get_breakpoint_info $b]
lassign $bpinfo file func linenum addr type enabled disposition \
- ignore_count commands cond thread hit_count user_specification
+ ignore_count commands cond thread hit_count
+ if {$thread == "-1"} {set thread "all"}
set file [lindex [file split $file] end]
if {$enabled} {
set enabled "ENA"
} else {
set enabled "DIS"
}
-
- if {$need_lf} {append str \n}
-
- append str [format "breakpoint %d at %s:%d (%s)\n %s %s %s" \
- $b $file $linenum $addr $enabled $type $disposition]
-
- if {$thread != "-1"} {
- append str "\n threads: $thread"
- }
-
- if {$ignore_count != 0} {
- append str "\n ignore: $ignore_count"
- }
-
- if {$cond != ""} {
- append str "\n condition: $cond"
- }
-
- if {$commands != ""} {
- if {[string length $commands] > 50} {
- append str "\n commands: [string range $commands 0 50] ..."
- } else {
- append str "\n commands: $commands"
- }
+ if {$cond == ""} {set cond "none"}
+ if {$need_lf} {
+ append str \n
+ } else {
+ set need_lf 1
}
- set need_lf 1
+ append str [format "breakpoint %d at %s:%d (%#x)\n\t%s %s %s %s %s" \
+ $b $file $linenum $addr $enabled $type $disposition \
+ threads=$thread cond=$cond]
}
# Scope out which break type is set here, and use the tag to get
@@ -2363,7 +2127,7 @@ itcl::body SrcTextWin::showBPBalloon {win x y} {
# METHOD: showBalloon - (possibly) show a variable's value in
# a balloon-help widget
# ------------------------------------------------------------------
-itcl::body SrcTextWin::showBalloon {win x y} {
+body SrcTextWin::showBalloon {win x y} {
if {$Running} { return }
$twin tag remove _show_variable 1.0 end
@@ -2430,7 +2194,7 @@ itcl::body SrcTextWin::showBalloon {win x y} {
# METHOD: getVariable - get the name of the 'variable' under the
# mouse pointer in the text widget
# ------------------------------------------------------------------
-itcl::body SrcTextWin::getVariable {x y {line {}}} {
+body SrcTextWin::getVariable {x y {line {}}} {
#debug "$x $y $line"
set hit_point [$twin index @$x,$y]
@@ -2508,7 +2272,7 @@ itcl::body SrcTextWin::getVariable {x y {line {}}} {
# ------------------------------------------------------------------
# METHOD: trace_help - update statusbar with ballon help message
# ------------------------------------------------------------------
-itcl::body SrcTextWin::trace_help {args} {
+body SrcTextWin::trace_help {args} {
upvar #0 ${this}_balloon a
if {$a == ""} {
$parent set_status
@@ -2517,7 +2281,7 @@ itcl::body SrcTextWin::trace_help {args} {
}
}
-itcl::body SrcTextWin::line_is_executable {win line} {
+body SrcTextWin::line_is_executable {win line} {
# there should be an image or a "-" on the line
set res [catch {$win image cget $line.0 -image}]
if {!$res || [$win get $line.0] == "-"} {
@@ -2530,7 +2294,7 @@ itcl::body SrcTextWin::line_is_executable {win line} {
# METHOD: tracepoint_range - create tracepoints at every line in
# a range of lines on the screen
# ------------------------------------------------------------------
-itcl::body SrcTextWin::tracepoint_range {win low high} {
+body SrcTextWin::tracepoint_range {win low high} {
# debug "$win $low $high"
switch $current(mode) {
@@ -2603,7 +2367,7 @@ itcl::body SrcTextWin::tracepoint_range {win low high} {
# METHOD: search - search for text or jump to a specific line
# in source window, going in the specified DIRECTION.
# ------------------------------------------------------------------
-itcl::body SrcTextWin::search {exp direction} {
+body SrcTextWin::search {exp direction} {
if {$exp != ""} {
set result {}
if {[regexp {^@([0-9]+)} $exp dummy index]} {
@@ -2653,23 +2417,17 @@ itcl::body SrcTextWin::search {exp direction} {
# name name to look for in cache. This will be a filename if
# we are filling in a source window, or an address
# otherwise.
-# asm 'S' for source,
-# 'A' for assembly mode
-# 'M' for mixed mode.
+# asm 'A' for assembly mode, 'M' for mixed mode.
# lib library name
#
# RETURNS: 0 - read from cache
# 1 - created new (blank) widget
-# -1 - could not find the contents you are trying to load,
-# so far this only happens for "Source" files.
#
# NOTES: If you call this and a new widget is created which cannot be
# filled in later due to errors, call UnLoadFromCache.
# -----------------------------------------------------------------------------
-
-itcl::body SrcTextWin::LoadFromCache {w name asm lib} {
+body SrcTextWin::LoadFromCache {w name asm lib} {
debug "LoadFromCache $w $name $asm"
- global gdbtk_platform
upvar ${w}win win
upvar _${w}pane pane
@@ -2679,11 +2437,9 @@ itcl::body SrcTextWin::LoadFromCache {w name asm lib} {
set full_name $name
}
- set loadingSource [expr ![string compare $asm "S"]]
-
set oldpane $pane
if {[info exists Stwc($full_name:pane)]} {
- debug "READING CACHE $full_name->$Stwc($full_name:pane)"
+ #debug "READING CACHE $full_name->$Stwc($full_name:pane)"
set pane $Stwc($full_name:pane)
if {$oldpane != ""} {
$itk_interior.p replace $oldpane $pane
@@ -2691,7 +2447,7 @@ itcl::body SrcTextWin::LoadFromCache {w name asm lib} {
$itk_interior.p show $pane
}
set win [[$itk_interior.p childsite $pane].st component text]
- if {!$loadingSource} {
+ if {$asm != ""} {
set Cname $full_name
}
@@ -2708,37 +2464,17 @@ itcl::body SrcTextWin::LoadFromCache {w name asm lib} {
}
} else {
- debug "name=$name"
- # If we are trying to load a source file, check the time
- # to see if we need to update it. If we can't stat the
- # file then we probably can't open it either, so error
- # out.
-
- if {$loadingSource} {
- if {[string compare $gdbtk_platform(os) "cygwin"] == 0} {
- set f [ide_cygwin_path to_win32 $name]
- } else {
- set f $name
- }
- if {[catch {file mtime $f} file_time]} {
- debug "Could not stat file \"$f\" - \"$file_time\""
- return -1
- } else {
- set Stwc($full_name:pane) pane$filenum
- set Stwc($name:mtime) $file_time
- }
- } else {
- # FIXME: This is wrong. For Assembly files we need to
- # check whether the executable is newer than the cached
- # disassembly. For mixed files, we need to check BOTH
- # the source file mtime, and the executable time.
-
- set Stwc($full_name:pane) pane$filenum
+ #debug "name=$name"
+ set Stwc($full_name:pane) pane$filenum
+ # Sometimes we get in here with no source file, in which case
+ # name is a hex address. Catch the error from this.
+ if {[catch {file mtime $name} file_time]} {
+ debug "Could not stat file: $name in LoadFromCache: $file_time"
set Stwc($name:mtime) 0
+ } else {
+ set Stwc($name:mtime) $file_time
}
- set Stwc($full_name:pane) pane$filenum
-
set Stwc($name:dirty) 0
incr filenum
@@ -2751,7 +2487,7 @@ itcl::body SrcTextWin::LoadFromCache {w name asm lib} {
-hscrollmode dynamic -vscrollmode dynamic]
set win [$st component text]
- if {!$loadingSource} {
+ if {$asm != ""} {
set Cname $full_name
}
pack $st -expand yes -fill both
@@ -2769,33 +2505,26 @@ itcl::body SrcTextWin::LoadFromCache {w name asm lib} {
# there is a problem with filling the widget.
# ------------------------------------------------------------------
-itcl::body SrcTextWin::UnLoadFromCache {w oldpane name asm lib} {
+body SrcTextWin::UnLoadFromCache {w oldpane name asm lib} {
# debug "$w $oldpane $name"
upvar ${w}win win
upvar _${w}pane pane
# debug "pane=$pane win=$win"
-
- set full_name ${name},${asm},${lib}
+ append name "," $asm "," $lib
$itk_interior.p delete $pane
- foreach elem [array names Stwc $full_name:*] {
- unset Stwc($elem)
- }
- foreach elem [array names Stwc $name:*] {
- unset Stwc($elem)
- }
-
- if {$oldpane != ""} {
- $itk_interior.p show $oldpane
- set pane $oldpane
- set win [[$itk_interior.p childsite $pane].st component text]
- }
+ unset Stwc($name:pane)
+ unset Stwc($name:dirty)
+ unset Stwc($name:mtime)
+ $itk_interior.p show $oldpane
+ set pane $oldpane
+ set win [[$itk_interior.p childsite $pane].st component text]
}
# ------------------------------------------------------------------
# METHOD: print - print the contents of the text widget
# ------------------------------------------------------------------
-itcl::body SrcTextWin::print {top} {
+body SrcTextWin::print {top} {
# FIXME
send_printer -ascii [$twin get 1.0 end] -parent $top
}
@@ -2803,7 +2532,7 @@ itcl::body SrcTextWin::print {top} {
# ------------------------------------------------------------------
# METHOD: ask_thread_bp - prompt for thread(s) for BP
# ------------------------------------------------------------------
-itcl::body SrcTextWin::ask_thread_bp {} {
+body SrcTextWin::ask_thread_bp {} {
# debug
if {[catch {gdb_cmd "info thread"} threads]} {
# failed. Just leave
@@ -2818,11 +2547,8 @@ itcl::body SrcTextWin::ask_thread_bp {} {
set a [toplevel .[gensym]]
wm title $a "Thread Selection"
-
- iwidgets::scrolledlistbox $a.slb \
- -vscrollmode dynamic -hscrollmode dynamic \
- -selectmode multiple -textfont global/fixed
-
+ CygScrolledListbox $a.slb -selectmode multiple -height $num_threads
+
set i [expr $num_threads - 1]
set width 0
foreach line $threads {
@@ -2836,21 +2562,19 @@ itcl::body SrcTextWin::ask_thread_bp {} {
if {[string length $line] > $width} {
set width [string length $line]
}
- $a.slb insert 0 $line
+ $a.slb.list insert 0 $line
incr i -1
}
}
- $a.slb configure -visibleitems ${width}x$num_threads
- [$a.slb component listbox] configure -bg $::Colors(textbg) -fg $::Colors(textfg)
+ $a.slb.list configure -width $width
frame $a.b
button $a.b.ok -text OK -underline 0 -width 7 \
- -command "$this do_thread_bp $a.slb"
+ -command "$this do_thread_bp $a.slb.list"
button $a.b.cancel -text Cancel -width 7 -underline 0 -command "destroy $a"
pack $a.b.ok $a.b.cancel -side left
standard_button_box $a.b
pack $a.b -fill x -expand yes -side bottom -padx 5 -pady 5
- center_window $a -over [winfo toplevel [namespace tail $this]]
pack $a.slb -side top -fill both -expand yes
bind $a.b.ok <Return> "$a.b.ok flash; $a.b.ok invoke"
focus $a.b.ok
@@ -2859,7 +2583,7 @@ itcl::body SrcTextWin::ask_thread_bp {} {
# ------------------------------------------------------------------
# METHOD: do_thread_bp - callback from thread selection
# ------------------------------------------------------------------
-itcl::body SrcTextWin::do_thread_bp {listbox} {
+body SrcTextWin::do_thread_bp {listbox} {
# debug "$listbox [$listbox curselection]"
set x ""
foreach i [$listbox curselection] {
@@ -2871,7 +2595,7 @@ itcl::body SrcTextWin::do_thread_bp {listbox} {
# public method for testing use only!
-itcl::body SrcTextWin::test_get {var} {
+body SrcTextWin::test_get {var} {
if {[array exists $var]} {
return [array get $var]
} else {
@@ -2880,13 +2604,6 @@ itcl::body SrcTextWin::test_get {var} {
}
# ------------------------------------------------------------------
-# METHOD: get_file - Return name of current file.
-# ------------------------------------------------------------------
-itcl::body SrcTextWin::get_file {} {
- return $current(filename)
-}
-
-# ------------------------------------------------------------------
# METHOD: clear_file - Clear out state so that user may load
# new executable. For the SrcTextWin class, this means:
#
@@ -2894,7 +2611,7 @@ itcl::body SrcTextWin::get_file {} {
# Delete the variable balloon if it exists.
# Clear the screen.
# ------------------------------------------------------------------
-itcl::body SrcTextWin::clear_file {} {
+body SrcTextWin::clear_file {} {
debug "In clear_file"
# delete all caches
@@ -2921,7 +2638,7 @@ itcl::body SrcTextWin::clear_file {} {
}
-itcl::body SrcTextWin::_initialize_srctextwin {} {
+body SrcTextWin::_initialize_srctextwin {} {
set pc(filename) ""
set pc(func) ""
set pc(line) 0
@@ -2941,7 +2658,10 @@ itcl::body SrcTextWin::_initialize_srctextwin {} {
# ------------------------------------------------------------------
# METHOD: _clear_cache - Clear the cache
# ------------------------------------------------------------------
-itcl::body SrcTextWin::_clear_cache {} {
+body SrcTextWin::_clear_cache {} {
+ # This doesn't work, and it's so darn entangled that it's nearly
+ # impossible.
+ return
# display empty scratch frame
set pane $Stwc(gdbtk_scratch_widget:pane)
@@ -2953,19 +2673,11 @@ itcl::body SrcTextWin::_clear_cache {} {
foreach p [array names Stwc *:pane] {
set p [lindex [split $p :] 0]
if {$p != "gdbtk_scratch_widget"} {
- catch {
- #debug "clearing cache: \"$p\""
- $itk_interior.p delete $Stwc($p:pane)
- unset Stwc($p:pane)
- unset Stwc($p:mtime)
- }
+ catch {$itk_interior.p delete $Stwc($p:pane)}
+ unset Stwc($p:pane)
+ unset Stwc($p:mtime)
}
}
-
- _initialize_srctextwin
- set filenum 0
- set Cname ""
- set _tpane pane$filenum
- incr filenum
- set _bpane ""
}
+
+
diff --git a/gdb/gdbtk/library/srctextwin.ith b/gdb/gdbtk/library/srctextwin.ith
index fae89ad294b..a9f2bfbb825 100644
--- a/gdb/gdbtk/library/srctextwin.ith
+++ b/gdb/gdbtk/library/srctextwin.ith
@@ -1,5 +1,5 @@
-# SrcTextWin class definition, for Insight
-# Copyright (C) 1997, 1998, 1999, 2001 Red Hat, Inc.
+# SrcTextWin class definition, for GDBtk.
+# Copyright 1997, 1998, 1999 Cygnus Solutions
#
# This program is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License (GPL) as published by
@@ -12,8 +12,8 @@
# GNU General Public License for more details.
-itcl::class SrcTextWin {
- inherit itk::Widget GDBWin
+class SrcTextWin {
+ inherit itk::Widget
public {
variable Tracing ;# 1 if we are running in trace mode
@@ -36,9 +36,9 @@ itcl::class SrcTextWin {
method build_win {}
method SetRunningState {state}
method enable {on}
- method setTabs {win {asm S}}
+ method setTabs {win {asm ""}}
method enable_disable_src_tags {win how}
- method config_win {win {asm S}}
+ method config_win {win {asm ""}}
method addPopup {menu label command {abg {}} {browse 1} {run 1}}
method updateBalloon {}
method ClearTags {}
@@ -58,10 +58,8 @@ itcl::class SrcTextWin {
method report_source_location {}
method lookup_line {win y}
method continue_to_here {{win {}} {y -1} {threads -1}}
- method jump_to_here {{win {}} {y -1} {threads -1}}
method set_bp_at_line {{type N} {win {}} {y -1} {threads "-1"}}
method remove_bp_at_line {{win {}} {y -1}}
- method enable_disable_at_line {action}
method set_tp_at_line {{win {}} {y -1}}
method next_hit_at_line {{win {}} {y -1}}
method remove_tp_at_line {{win {}} {y -1}}
@@ -87,15 +85,11 @@ itcl::class SrcTextWin {
method do_thread_bp {listbox}
method test_get {var}
method clear_file {}
- method get_file {}
- method set_tag_to_stack {}
-
- # GDB Events
- method breakpoint {event}
- method tracepoint {event}
- method set_variable {event}
}
+ protected {
+ method handle_set_hook {var val}
+ }
private {
variable top ;# toplevel window
variable twin ;# top text window of pane
@@ -133,7 +127,6 @@ itcl::class SrcTextWin {
method _mtime_changed {filename}
method _initialize_srctextwin {}
method _clear_cache {}
- method _highlightAsmLine {win addr pc_addr tagname filename funcname} {}
proc makeBreakDot {size colorList {image {}}}
}
diff --git a/gdb/gdbtk/library/srcwin.itb b/gdb/gdbtk/library/srcwin.itb
index 0f42852f2ed..a822c5deae7 100644
--- a/gdb/gdbtk/library/srcwin.itb
+++ b/gdb/gdbtk/library/srcwin.itb
@@ -1,6 +1,5 @@
-# Source window for Insight.
-# Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2008,
-# 2006 Red Hat, Inc.
+# Source window for GDBtk.
+# Copyright 1997, 1998, 1999 Cygnus Solutions
#
# This program is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License (GPL) as published by
@@ -16,24 +15,32 @@
# ------------------------------------------------------------------
# CONSTRUCTOR - create new source window
# ------------------------------------------------------------------
-itcl::body SrcWin::constructor {args} {
+body SrcWin::constructor {args} {
debug "$args"
eval itk_initialize $args
set top [winfo toplevel $itk_interior]
-
+
_update_title ""
-
+
+ # On Windows, create a sizebox.
+ if {$::tcl_platform(platform) == "windows"} {
+ ide_sizebox $itk_interior.sizebox
+ }
+
set Tracing [pref get gdb/mode]
set current(filename) ""
-
+
if {[catch {_build_win} mssg]} {
dbug E "_build_win returned: $::errorInfo"
}
-
+
# add special delete handler
wm protocol $top WM_DELETE_WINDOW "[code $this _exit]"
-
+
# add hooks
+ add_hook gdb_update_hook "$this update"
+ add_hook gdb_busy_hook "$this busy"
+ add_hook gdb_idle_hook "$this idle"
add_hook gdb_no_inferior_hook "$this no_inferior"
add_hook download_progress_hook "$this download_progress"
add_hook state_hook [code $this _set_state]
@@ -41,119 +48,82 @@ itcl::body SrcWin::constructor {args} {
after idle "
update idletasks
$this sizeWinByChild toolbar"
-
- lappend window_list $this
}
# ------------------------------------------------------------------
# DESTRUCTOR - destroy window containing widget
# ------------------------------------------------------------------
-itcl::body SrcWin::destructor {} {
+body SrcWin::destructor {} {
debug
+ remove_hook gdb_update_hook "$this update"
+ remove_hook gdb_busy_hook "$this busy"
remove_hook gdb_no_inferior_hook "$this no_inferior"
+ remove_hook gdb_idle_hook "$this idle"
remove_hook download_progress_hook "$this download_progress"
remove_hook state_hook [code $this _set_state]
remove_hook gdb_clear_file_hook [code $this clear_file]
- set window_list [lremove $window_list $this]
- if {$pc_window == $this} then {
- set pc_window ""
- }
}
# ------------------------------------------------------------------
# PRIVATE METHOD: _build_win - build the main source window
# ------------------------------------------------------------------
-itcl::body SrcWin::_build_win {} {
+body SrcWin::_build_win {} {
global gdb_downloading gdb_running gdb_loaded
# build source toolbar
set _toolbar [conAdd toolbar -resizable 0]
- SrcBar $_toolbar $this \
+ GDBSrcBar $_toolbar $this \
-updatecommand [list $this toggle_updates] \
-updatevalue $do_updates
- pack $_toolbar -expand 1 -fill both
- # if user likes control on bottom...
- if {! [pref get gdb/src/top_control]} {
+ # add a SrcTextWin container
+ set srcwin [conAdd src]
+ set twin [SrcTextWin $srcwin -Tracing $Tracing -parent $this]
+ pack $srcwin -expand 1 -fill both
- # add a SrcTextWin container
- set srcwin [conAdd src]
- set twin [SrcTextWin $srcwin -Tracing $Tracing -parent $this]
- pack $srcwin -expand 1 -fill both
-
- # add status line
- set _status [conAdd status -resizable 0]
- label $_status -relief sunken -bd 3 -font global/status -height 1
- pack $_status -expand 1 -fill both
- }
+ # add status line
+ set _status [conAdd status -resizable 0]
+ label $_status -relief sunken -bd 3 -font global/status -height 1
+ pack $_status -expand 1 -fill both
# add a status bar container
set _statbar [conAdd stat -resizable 0]
frame $_statbar
pack $_statbar -expand 1 -fill both
- combobox::combobox $_statbar.name -maxheight 15 -font global/fixed\
- -command [code $this _name] -bg $::Colors(textbg)
+ combobox::combobox $_statbar.name -maxheight 15 -font src-font\
+ -command [code $this _name]
set need_files 1
- combobox::combobox $_statbar.func -maxheight 15 -font global/fixed\
- -command [code $this goto_func] -bg $::Colors(textbg)
+ combobox::combobox $_statbar.func -maxheight 15 -font src-font\
+ -command [code $this goto_func]
combobox::combobox $_statbar.mode -width 9 -editable false \
- -font global/fixed -command [code $this mode] -bg $::Colors(textbg)
+ -font src-font -command [code $this mode]
$_statbar.mode list insert end SOURCE
$_statbar.mode list insert end ASSEMBLY
$_statbar.mode list insert end MIXED
$_statbar.mode list insert end SRC+ASM
- # Workaround: the three comboboxes above sometimes display with
- # height of one pixel. Inserting an invisible frame with the required
- # height "fixes" this...
- frame $_statbar.strut -height 24 -width 10
+ # Search/download progress frame
+ frame $_statbar.frame
+ entry $_statbar.frame.search -bd 3 -font src-font -width 10
+ bind_plain_key $_statbar.frame.search \
+ Return [code $this _search forwards]
+ bind_plain_key $_statbar.frame.search \
+ Shift-Return [code $this _search backwards]
+ canvas $_statbar.frame.progress -relief sunken -borderwidth 2 \
+ -highlightthickness 0 -takefocus 0 -width 100 -height 0 -confine 1
+ $_statbar.frame.progress create rectangle 0 0 0 \
+ [winfo height $_statbar.frame.progress] -outline blue -fill blue -tags rect
+
+ pack $_statbar.frame -side right -pady 4 -padx 10 -fill y -expand 1 -anchor e
pack $_statbar.mode -side right -padx 10 -pady 4
- pack $_statbar.name $_statbar.func $_statbar.strut \
- -side left -pady 4 -padx 10
+ pack $_statbar.name $_statbar.func -side left -pady 4 -padx 10
- # if user likes control on top...
- if {[pref get gdb/src/top_control]} {
-
- # add a SrcTextWin container
- set srcwin [conAdd src]
- set twin [SrcTextWin $srcwin -Tracing $Tracing -parent $this]
- pack $srcwin -expand 1 -fill both
-
- # add status line
- set _status [conAdd status -resizable 0]
- set _statusframe [frame $_status]
- set _status $_statusframe.con
- label $_status -relief sunken -bd 3 -font global/status -height 1 \
- -anchor w
-
- # add download progress meter
- canvas $_statusframe.progress -relief sunken -borderwidth 2 \
- -highlightthickness 0 -takefocus 0 -width 100 -height 0 -confine 1
- $_statusframe.progress create rectangle 0 0 0 \
- [winfo height $_statusframe.progress] -outline blue -fill blue -tags rect
-
- # add address and line number indicators
- label $_statusframe.addr -text "" -width 10 -relief sunken \
- -bd 1 -anchor e -font global/fixed
- label $_statusframe.line -text "" -width 6 -relief sunken \
- -bd 1 -anchor e -font global/fixed
-
- balloon register $_statusframe.addr "Address"
- balloon register $_statusframe.line "Line number"
-
- pack $_statusframe -expand 1 -fill both
- grid $_status -row 0 -column 1 -sticky news -pady 2 -padx 2
- grid $_statusframe.addr -row 0 -column 3 -sticky nes -pady 4
- grid $_statusframe.line -row 0 -column 4 -sticky nws -pady 4
- grid columnconfigure $_statusframe 1 -weight 10
- grid columnconfigure $_statusframe 2 -minsize 5
- grid columnconfigure $_statusframe 5 -minsize 5
- }
+ pack $_statbar.frame.search -fill x -expand yes
set_execution_status
@@ -163,6 +133,7 @@ itcl::body SrcWin::_build_win {} {
balloon register $_statbar.func.$i "Current function name"
balloon register $_statbar.mode.$i "Source mode"
}
+ balloon register $_statbar.frame.search "Search for text"
balloon variable $_status ${twin}_balloon
$_statbar.mode entryset [$twin mode_get]
@@ -171,10 +142,10 @@ itcl::body SrcWin::_build_win {} {
# If this is a new widget and the program is
# not yet being debugged, load the file with "main" in it.
if {$gdb_running} {
- if {[catch {gdb_loc} loc]} {
- # Nothing we can do but leave the window empty.
- } else {
- _update $loc
+ update
+ } else {
+ if {[set linespec [gdbtk_locate_main]] != ""} {
+ location BROWSE_TAG $linespec
}
}
}
@@ -183,7 +154,7 @@ itcl::body SrcWin::_build_win {} {
# ------------------------------------------------------------------
# PUBLIC METHOD: _set_state - do things when program state changes
# ------------------------------------------------------------------
-itcl::body SrcWin::_set_state {varname} {
+body SrcWin::_set_state {varname} {
global gdb_running gdb_downloading gdb_loaded gdb_program_has_run
debug "$varname l=$gdb_loaded d=$gdb_downloading r=$gdb_running"
@@ -207,13 +178,13 @@ itcl::body SrcWin::_set_state {varname} {
# ------------------------------------------------------------------
# PUBLIC METHOD: download_progress - update the progress meter when downloading
# ------------------------------------------------------------------
-itcl::body SrcWin::download_progress { section num tot {msg ""} } {
+body SrcWin::download_progress { section num tot {msg ""} } {
global download_start_time download_cancel_ok gdb_loaded
#debug "$section $num $tot $msg"
if {$last_section_start == 0} {
- grid forget $_statusframe.addr $_statusframe.line
- grid $_statusframe.progress -row 0 -column 4 -padx 4 -sticky news
+ pack forget $_statbar.frame.search
+ pack $_statbar.frame.progress -fill both -expand yes
::update idletasks
}
@@ -238,7 +209,7 @@ itcl::body SrcWin::download_progress { section num tot {msg ""} } {
set_status "Downloading section $section - $num bytes"
}
- set canvas $_statusframe.progress
+ set canvas $_statbar.frame.progress
set height [winfo height $canvas]
if {$last_done} {
set width [winfo width $canvas]
@@ -250,7 +221,7 @@ itcl::body SrcWin::download_progress { section num tot {msg ""} } {
if {$last_done == $tot || $section == "CANCEL"} {
$_toolbar configure -runstop normal
if {!$gdb_loaded} {
- ::update
+ update
# errored or canceled
if {$msg != ""} {
set_status "DOWNLOAD FAILED: $msg"
@@ -265,9 +236,8 @@ itcl::body SrcWin::download_progress { section num tot {msg ""} } {
set last_done 0
set last_section_start 0
- grid forget $_statusframe.progress
- grid $_statusframe.addr -row 0 -column 3 -sticky new -pady 4
- grid $_statusframe.line -row 0 -column 4 -sticky nws -pady 4
+ pack forget $_statbar.frame.progress
+ pack $_statbar.frame.search -fill x -expand yes
::update idletasks
}
}
@@ -275,7 +245,7 @@ itcl::body SrcWin::download_progress { section num tot {msg ""} } {
# ------------------------------------------------------------------
# PUBLIC METHOD: reconfig - used when preferences change
# ------------------------------------------------------------------
-itcl::body SrcWin::reconfig {} {
+body SrcWin::reconfig {} {
debug
$_toolbar reconfig
$twin reconfig
@@ -288,17 +258,13 @@ itcl::body SrcWin::reconfig {} {
# It is the only way that files can be inserted into the file list
# once the debugger is started.
# ------------------------------------------------------------------
-itcl::body SrcWin::_name {w {val ""}} {
+body SrcWin::_name {w {val ""}} {
global _files
debug "$w $val"
if {$val != ""} {
if {![info exists _files(short,$val)]} {
if {![info exists _files(full,$val)]} {
- if [catch {gdb_find_file $val} full] {
- set_status "Cannot find source file \"$val\": $full"
- $_statbar.name entryset [lindex [file split $current(filename)] end]
- return
- }
+ set full [gdb_find_file $val]
if {$full == ""} {
set_status "Cannot find source file \"$val\""
$_statbar.name entryset [lindex [file split $current(filename)] end]
@@ -320,7 +286,14 @@ itcl::body SrcWin::_name {w {val ""}} {
# ------------------------------------------------------------------
# PRIVATE PUBLIC METHOD: toggle_updates - update toggle callback
# ------------------------------------------------------------------
-itcl::body SrcWin::toggle_updates {value} {
+body SrcWin::toggle_updates {value} {
+ if {$value} {
+ add_hook gdb_update_hook "$this update"
+ add_hook gdb_busy_hook "$this busy"
+ } else {
+ remove_hook gdb_update_hook "$this update"
+ remove_hook gdb_busy_hook "$this busy"
+ }
# save state in do_updates so it will be preserved
# in window reconfigs
set do_updates $value
@@ -329,7 +302,7 @@ itcl::body SrcWin::toggle_updates {value} {
# ------------------------------------------------------------------
# PRIVATE PUBLIC METHOD: goto_func - function combobox callback
# ------------------------------------------------------------------
-itcl::body SrcWin::goto_func {w {val ""}} {
+body SrcWin::goto_func {w {val ""}} {
if {$val != ""} {
set mang 0
if {[info exists _mangled_func($val)]} {
@@ -360,12 +333,11 @@ itcl::body SrcWin::goto_func {w {val ""}} {
# This method needs to be public, since other parts of
# the gui can cause new symbols to be read.
# ------------------------------------------------------------------
-itcl::body SrcWin::fillNameCB {} {
+body SrcWin::fillNameCB {} {
global _files
set allfiles [gdb_listfiles]
+ debug "gdb_listfiles returned $allfiles"
foreach f $allfiles {
- # FIXME: If you reactivate this code add a catch as gdb_find_file can err
- # (P.S.: I don't know why this is commented out)
#set fullname [gdb_find_file $f]
#set _files(full,$f) $fullname
#set _files(short,$fullname) $f
@@ -381,18 +353,18 @@ itcl::body SrcWin::fillNameCB {} {
# This method needs to be public, since other parts of
# the gui can cause new symbols to be read.
# ------------------------------------------------------------------
-itcl::body SrcWin::fillFuncCB {name} {
+body SrcWin::fillFuncCB {name} {
$_statbar.func list delete 0 end
if {$name != ""} {
set maxlen 10
if {[catch {gdb_listfuncs $name} listfuncs]} {
tk_messageBox -icon error -default ok \
- -title "GDB" -type ok \
+ -title "GDB" -type ok -modal system \
-message "This file can not be found or does not contain\ndebugging information."
_set_name ""
return
}
- foreach f [lsort -increasing $listfuncs] {
+ foreach f $listfuncs {
lassign $f func mang
set _mangled_func($func) $mang
$_statbar.func list insert end $func
@@ -414,13 +386,13 @@ itcl::body SrcWin::fillFuncCB {name} {
# 3: source line number
# 4: address
# 5: current PC - which will often be the same as address, but not when
-# we are browsing, or walking the stack.
# 6: shared library name if the pc is in a shared lib
+# we are browsing, or walking the stack.
#
# linespec will be "{} {} {} 0 0x0 0x0" when GDB has not started debugging.
# ------------------------------------------------------------------
-itcl::body SrcWin::location {tag linespec} {
- global gdb_running gdb_exe_name _files
+body SrcWin::location {tag linespec} {
+ global gdb_running gdb_exe_name _files tcl_platform
# We need to keep track of changes to the line, filename, function name
# and address so we can keep the widgets up-to-date. Otherwise we
@@ -463,19 +435,8 @@ itcl::body SrcWin::location {tag linespec} {
fillFuncCB $name
}
- # get a proper address string to display
- set textaddr [gdb_CA_to_TAS $addr]
-
# set address and line widgets
- if {[string length $textaddr] > 8} {
- # 64-bit address
- set width 16
- } else {
- # 32-bit address
- set width 8
- }
- $_statusframe.addr configure -text $textaddr -font global/fixed -width $width
- $_statusframe.line configure -text $line
+ $_toolbar configure -address $addr -line $line
# set function combobox
$_statbar.func entryset $funcname
@@ -489,7 +450,7 @@ itcl::body SrcWin::location {tag linespec} {
# ------------------------------------------------------------------
# PUBLIC METHOD: stack - handle stack commands
# ------------------------------------------------------------------
-itcl::body SrcWin::stack {cmd} {
+body SrcWin::stack {cmd} {
if {$cmd == "bottom"} {
set cmd "frame 0"
}
@@ -502,22 +463,26 @@ itcl::body SrcWin::stack {cmd} {
}
# ------------------------------------------------------------------
-# METHOD: _update - update widget when PC changes
+# PUBLIC METHOD: update - update widget when PC changes
# ------------------------------------------------------------------
-itcl::body SrcWin::_update {loc} {
- debug "loc=$loc"
- # See if name combobox needs filled.
- if {$need_files} {
- fillNameCB
+body SrcWin::update {} {
+ if {[catch {gdb_loc} loc]} {
+ set_execution_status
+ } else {
+ debug "loc=$loc"
+ # See if name combobox needs filled.
+ if {$need_files} {
+ fillNameCB
+ }
+ location "" $loc
}
- location "" $loc
}
# ------------------------------------------------------------------
# PUBLIC METHOD: idle - callback for gdbtk_idle
# Called when the target is idle, so enable all buttons.
# ------------------------------------------------------------------
-itcl::body SrcWin::idle {event} {
+body SrcWin::idle {} {
$_toolbar configure -runstop normal
enable_ui 1
}
@@ -525,7 +490,7 @@ itcl::body SrcWin::idle {event} {
# ------------------------------------------------------------------
# PUBLIC METHOD: mode - set mode to SOURCE, ASSEMBLY, MIXED, SRC+ASM
# ------------------------------------------------------------------
-itcl::body SrcWin::mode {w new_mode {go 1}} {
+body SrcWin::mode {w new_mode {go 1}} {
gdbtk_busy
$_statbar.mode entryset $new_mode
catch {$twin mode_set $new_mode $go} errorVal
@@ -536,7 +501,7 @@ itcl::body SrcWin::mode {w new_mode {go 1}} {
# ------------------------------------------------------------------
# PRIVATE METHOD: _update_title - update title bar
# ------------------------------------------------------------------
-itcl::body SrcWin::_update_title {name} {
+body SrcWin::_update_title {name} {
set fn [lindex [::file split $name] end]
if {$fn == ""} {
set prefix ""
@@ -549,44 +514,26 @@ itcl::body SrcWin::_update_title {name} {
# ------------------------------------------------------------------
# PUBLIC METHOD: busy - disable things when gdb is busy
# ------------------------------------------------------------------
-itcl::body SrcWin::busy {event} {
+body SrcWin::busy {} {
global gdb_loaded gdb_target_name
# debug "gdb_loaded=$gdb_loaded, gdb_target_name=$gdb_target_name"
- if {$do_updates} {
- enable_ui 0
- if {$Running} {
- $_toolbar configure -runstop running
- if {$gdb_loaded || \
- ([TargetSelection::native_debugging] && $gdb_target_name != "remote")} {
- set_status "Program is running."
- }
- } else {
- $_toolbar configure -runstop busy
- }
- }
-}
-
-# ------------------------------------------------------------------
-# PUBLIC METHOD: update - The inferior's state has changed.
-# ------------------------------------------------------------------
-itcl::body SrcWin::update {event} {
-
- # FIXME: This is kinda lame. We need to run this only once
- # as it is now written, so only the first window in the list
- # will actually call choose_and_update.
- # This is still better than before, since it will not
- # matter if this window is destroyed: as long as _a_
- # SrcWin exists, this will get called.
- if {[lindex $window_list 0] == $this} {
- choose_and_update
+ enable_ui 0
+ if {$Running} {
+ $_toolbar configure -runstop running
+ if {$gdb_loaded || \
+ ([TargetSelection::native_debugging] && $gdb_target_name != "remote")} {
+ set_status "Program is running."
+ }
+ } else {
+ $_toolbar configure -runstop busy
}
}
# ------------------------------------------------------------------
# PRIVATE METHOD: _set_name - set the name in the name combobox and in the title
# ------------------------------------------------------------------
-itcl::body SrcWin::_set_name { val {found 1} } {
+body SrcWin::_set_name { val {found 1} } {
global _files
_update_title $val
if {![info exists _files(short,$val)]} {
@@ -610,7 +557,7 @@ itcl::body SrcWin::_set_name { val {found 1} } {
# If "tmp" is set, the status change will not be saved.
# ------------------------------------------------------------------
-itcl::body SrcWin::set_status { {msg ""} {tmp 0} } {
+body SrcWin::set_status { {msg ""} {tmp 0} } {
set msg [lindex [split $msg \n] 0]
if {$tmp} {
$_status configure -text $msg
@@ -626,7 +573,7 @@ itcl::body SrcWin::set_status { {msg ""} {tmp 0} } {
# PUBLIC METHOD: set_execution_status - write the current execution state
# to the status line
# ------------------------------------------------------------------
-itcl::body SrcWin::set_execution_status { {line ""} {pc ""}} {
+body SrcWin::set_execution_status { {line ""} {pc ""}} {
global gdb_running gdb_loaded gdb_program_has_run gdb_target_changed
#debug "line=$line pc=$pc [gdb_target_has_execution] running=$gdb_running loaded=$gdb_loaded"
set message ""
@@ -670,8 +617,6 @@ itcl::body SrcWin::set_execution_status { {line ""} {pc ""}} {
}
}
- set pc [gdb_CA_to_TAS $pc]
-
if {$line == "" || $line == 0} {
if {$pc == "" || $pc == 0} {
if {$Tracing} {
@@ -680,7 +625,7 @@ itcl::body SrcWin::set_execution_status { {line ""} {pc ""}} {
set message "Program stopped."
}
} else {
- set message "Program stopped at 0x$pc"
+ set message [gdb_cmd "printf \"Program stopped at %lx\",$pc"]
}
} else {
if {$Tracing} {
@@ -689,9 +634,9 @@ itcl::body SrcWin::set_execution_status { {line ""} {pc ""}} {
set msg "Program stopped"
}
switch [$twin mode_get] {
- ASSEMBLY {set message "$msg at 0x$pc" }
- MIXED {set message "$msg at line $line, 0x$pc" }
- SRC+ASM {set message "$msg at line $line, 0x$pc" }
+ ASSEMBLY {set message [gdb_cmd "printf \"$msg at 0x%lx\",$pc"] }
+ MIXED {set message [gdb_cmd "printf \"$msg at line $line, 0x%lx\",$pc"] }
+ SRC+ASM {set message [gb_cmd "printf \"$msg at line $line, 0x%lx\",$pc"] }
default {set message "$msg at line $line" }
}
}
@@ -702,27 +647,33 @@ itcl::body SrcWin::set_execution_status { {line ""} {pc ""}} {
# ------------------------------------------------------------------
# PUBLIC METHOD: edit - invoke external editor
# ------------------------------------------------------------------
-itcl::body SrcWin::edit {} {
- global external_editor_command
+body SrcWin::edit {} {
+ global enable_external_editor external_editor_command
# If external editor is enabled, pass the file to the specified command
-
+
if {$current(filename) == ""} {
tk_dialog .warn {Edit} {No file is loaded in the source window.} error 0 Ok
return
}
-
+
if {[catch {$twin report_source_location} loc_info]} {
tk_dialog .warn "Edit" "No source file selected" error 0 Ok
return
}
-
- Editor::edit $loc_info
+
+
+ if {[info exists enable_external_editor] && $enable_external_editor} {
+ if {[catch {eval $external_editor_command edit $loc_info} err]} {
+ tk_dialog .warn-sn "Edit" $err error 0 Ok
+ }
+ return
+ }
}
# ------------------------------------------------------------------
# PUBLIC METHOD: print - print the contents of the text widget
# ------------------------------------------------------------------
-itcl::body SrcWin::print {} {
+body SrcWin::print {} {
# Call the SrcTextWin's print public method
$twin print $top
}
@@ -731,7 +682,7 @@ itcl::body SrcWin::print {} {
# PUBLIC METHOD: enable_ui
# Enable all UI elements for user interaction.
# ------------------------------------------------------------------
-itcl::body SrcWin::enable_ui { on } {
+body SrcWin::enable_ui { on } {
#debug "$on"
if {$on} {
set Running 0
@@ -767,7 +718,7 @@ itcl::body SrcWin::enable_ui { on } {
#
# Change mouse pointer to normal
# ------------------------------------------------------------------
-itcl::body SrcWin::no_inferior {} {
+body SrcWin::no_inferior {} {
#debug
set_execution_status
enable_ui 1
@@ -776,7 +727,7 @@ itcl::body SrcWin::no_inferior {} {
# ------------------------------------------------------------------
# PUBLIC METHOD: reset - reset the source window
# ------------------------------------------------------------------
-itcl::body SrcWin::reset {} {
+body SrcWin::reset {} {
set current(filename) ""
set need_files 1
set do_updates 1
@@ -795,12 +746,14 @@ itcl::body SrcWin::reset {} {
}
# ------------------------------------------------------------------
-# PUBLIC METHOD: search - search for a STRING or jump to a specific line
+# PRIVATE METHOD: _search - search for text or jump to a specific line
# in source window, going in the specified DIRECTION.
# ------------------------------------------------------------------
-itcl::body SrcWin::search {direction string} {
+body SrcWin::_search {direction} {
+ set exp [$_statbar.frame.search get]
+ #debug "searching $direction for \"$exp\""
set_status
- set_status [$twin search $string $direction] 1
+ set_status [$twin search $exp $direction] 1
}
# ------------------------------------------------------------------
@@ -808,7 +761,7 @@ itcl::body SrcWin::search {direction string} {
# Proc that may be called to point some source window to
# main (or an entry point?). (see gdbtk_tcl_exec_file_changed)
# ------------------------------------------------------------------
-itcl::body SrcWin::point_to_main {} {
+body SrcWin::point_to_main {} {
# We need to force this to some default location. Assume main and
# if that fails, let the source window guess (via gdb_loc using stop_pc).
set src [lindex [ManagedWin::find SrcWin] 0]
@@ -820,7 +773,7 @@ itcl::body SrcWin::point_to_main {} {
}
}
-itcl::body SrcWin::_exit {} {
+body SrcWin::_exit {} {
debug
if {[llength [ManagedWin::find SrcWin]] == 1} {
if {![gdbtk_quit_check]} {
@@ -831,7 +784,7 @@ itcl::body SrcWin::_exit {} {
}
# public method for testing use only!
-itcl::body SrcWin::test_get {var {private_func 0}} {
+body SrcWin::test_get {var {private_func 0}} {
debug $var
if {$private_func} {
return [code $this $var]
@@ -851,7 +804,7 @@ itcl::body SrcWin::test_get {var {private_func 0}} {
# running - Stop button appears, allowing user to stop executing target
# downloading - Stop button appears, allowing user to interrupt downloading
# normal - Run button appears, allowing user to run/re-run exe
-itcl::body SrcWin::toolbar {state} {
+body SrcWin::toolbar {state} {
$_toolbar configure -runstop $state
}
@@ -871,46 +824,23 @@ itcl::body SrcWin::toolbar {state} {
#
# FIXME: This should really be in an object which describes gdb's state.
# Unfortunately, this doesn't exist, so it's here for now.
-itcl::body SrcWin::inferior {action} {
-
- # Check to see if this action is forwarded to other Insight instances
- if {$::iipc} {
- switch $action {
- step -
- next -
- stepi -
- nexti -
- finish {
- if {[pref get gdb/ipc/step_button]} {
- $::insight_ipc send $action
- }
- }
- continue {
- if {[pref get gdb/ipc/cont_button]} {
- $::insight_ipc send $action
- }
- }
- run {
- if {[pref get gdb/ipc/run_button]} {
- $::insight_ipc send $action
- }
- }
- stop {
- if {[pref get gdb/ipc/stop_button]} {
- $::insight_ipc send $action
- }
- }
- }
- }
+body SrcWin::inferior {action} {
switch $action {
step { gdbtk_step }
+
next { gdbtk_next }
+
finish { gdbtk_finish }
+
continue { gdbtk_continue }
+
stepi { gdbtk_stepi }
+
nexti { gdbtk_nexti }
+
run { gdbtk_run }
+
stop { gdbtk_stop }
}
}
@@ -925,11 +855,11 @@ itcl::body SrcWin::inferior {action} {
# - clear status (done by no_inferior)
# - allow SrcTextWin to clear_file
# ------------------------------------------------------------------
-itcl::body SrcWin::clear_file {} {
+body SrcWin::clear_file {} {
# Reset to Source mode
if {[$twin mode_get] != "SOURCE"} {
- mode {} SOURCE 0
+ mode {} SOURCE
}
no_inferior
@@ -938,121 +868,3 @@ itcl::body SrcWin::clear_file {} {
# run srctextwin clear_file
$twin clear_file
}
-
-# ------------------------------------------------------------------
-# METHOD: get_file
-# Return name of displayed file, or empty string if no file.
-# ------------------------------------------------------------------
-itcl::body SrcWin::get_file {} {
- if {$twin == ""} {
- return ""
- } else {
- return [$twin get_file]
- }
-}
-
-# ------------------------------------------------------------------
-# METHOD: is_fixed
-# Return boolean indicating whether this window is fixed.
-# ------------------------------------------------------------------
-itcl::body SrcWin::is_fixed {} {
- return 0
-}
-
-# ------------------------------------------------------------------
-# METHOD: get_top
-# Return toplevel
-# ------------------------------------------------------------------
-itcl::body SrcWin::get_top {} {
- return $top
-}
-
-# ------------------------------------------------------------------
-# METHOD: _set_tag_to_stack
-# Set tag to `stack' and update the underlying window.
-# ------------------------------------------------------------------
-itcl::body SrcWin::_set_tag_to_stack {} {
- set tag STACK_TAG
- if {$twin != ""} then {
- $twin set_tag_to_stack
- }
-}
-
-# ------------------------------------------------------------------
-# METHOD: _choose_window
-# Choose the right source window.
-# ------------------------------------------------------------------
-itcl::body SrcWin::_choose_window {file} {
- # Find the next available source window. The rules are:
- # 1. LRU overall
- # 2. Skip iconified windows
- # 3. If a window already shows the file, use it. Prefer the
- # window currently showing the PC
- # 4. If the window is fixed, skip it
- if {$pc_window != ""} then {
- if {[$pc_window get_file] == $file} then {
- return $pc_window
- }
- }
-
- set choice ""
- foreach win $window_list {
- if {[wm state [$win get_top]] != "normal"} then {
- continue
- }
-
- if {[$win get_file] == ""
- || [$win get_file] == $file
- || ! [$win is_fixed]} then {
- set choice $win
- break
- }
- }
-
- # If we didn't find an available window, then pick the current PC
- # window.
- if {$choice == ""} then {
- set choice $pc_window
- }
-
- set window_list [lremove $window_list $choice]
- lappend window_list $choice
-
- return $choice
-}
-
-# ------------------------------------------------------------------
-# METHOD: choose_and_update
-# Choose the right source window and then cause it to be updated
-# ------------------------------------------------------------------
-itcl::body SrcWin::choose_and_update {} {
- if {$pc_window == ""} then {
- set pc_window [lindex $window_list 0]
- }
-
- if {$pc_window == ""} then {
- # Nothing.
- } elseif {[catch {gdb_loc} loc]} {
- $pc_window set_execution_status
- } else {
- set prev $pc_window
- set file [lindex $loc 2]
- set pc_window [_choose_window $file]
- debug "chose window $pc_window"
- $pc_window _update $loc
- if {$pc_window != $prev} then {
- $pc_window reveal
- $prev _set_tag_to_stack
- }
- }
-}
-
-# ------------------------------------------------------------------
-# METHOD: choose_and_display
-# Choose the right source window for a given file
-# ------------------------------------------------------------------
-itcl::body SrcWin::choose_and_display {tag linespec} {
- set file [lindex $linespec 2]
- set window [_choose_window $file]
- $window location $tag $linespec
-}
diff --git a/gdb/gdbtk/library/srcwin.ith b/gdb/gdbtk/library/srcwin.ith
index 03e9b4ee8e4..f955158d445 100644
--- a/gdb/gdbtk/library/srcwin.ith
+++ b/gdb/gdbtk/library/srcwin.ith
@@ -1,5 +1,5 @@
# Source window class definition for GDBtk.
-# Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002 Red Hat, Inc.
+# Copyright 1997, 1998, 1999 Cygnus Solutions
#
# This program is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License (GPL) as published by
@@ -23,10 +23,11 @@
# should be returned and SrcWin should figure out what to do.
# ----------------------------------------------------------------------
-itcl::class SrcWin {
+class SrcWin {
inherit TopLevelWin GDBWin
public {
+ method busy {}
method constructor {args}
method destructor {}
method download_progress { section num tot {msg ""} }
@@ -35,6 +36,7 @@ itcl::class SrcWin {
method fillNameCB {}
method fillFuncCB {name}
method goto_func {w {val ""}}
+ method idle {}
method location {tag linespec}
method mode {w new_mode {go 1}}
method no_inferior {}
@@ -46,40 +48,25 @@ itcl::class SrcWin {
method stack {cmd}
method test_get {var {private_func 0}}
method toggle_updates {value}
+ method update {}
method toolbar {state}
method inferior {action}
method clear_file {}
- method get_file {}
- method is_fixed {}
- method search {direction string}
- proc choose_and_update {}
- proc choose_and_display {tag linespec}
proc point_to_main {}
-
- #
- # GDB Events
- #
- method busy {event}
- method idle {event}
- method update {event}
}
private {
method _build_win {}
method _exit {}
method _name {w {val ""}}
+ method _search {direction}
method _set_name { val {found 1} }
method _set_state {varname}
method _update_title {name}
- method _update {loc}
- method get_top {}
- method _set_tag_to_stack {}
- proc _choose_window {file}
variable _statbar
variable _status
variable _toolbar
- variable _statusframe
variable top
variable twin
variable current
@@ -88,17 +75,12 @@ itcl::class SrcWin {
variable _mangled_func
variable Tracing
variable saved_msg "" ;# static
-
+
# statics used for downloads
variable last_section ""
variable last_section_start 0
variable last_done 0
-
- # These keep track of the current PC window and the list of all
- # source windows.
- common window_list ""
- common pc_window ""
-
+
# fenceposts
variable Running 0
variable NoRun 0
diff --git a/gdb/gdbtk/library/stackwin.itb b/gdb/gdbtk/library/stackwin.itb
index 4fc18ca37a8..58675df3836 100644
--- a/gdb/gdbtk/library/stackwin.itb
+++ b/gdb/gdbtk/library/stackwin.itb
@@ -1,5 +1,5 @@
-# Stack window for Insight.
-# Copyright (C) 1997, 1998, 1999, 2002, 2003, 2008 Red Hat
+# Stack window for GDBtk.
+# Copyright 1997, 1998, 1999 Cygnus Solutions
#
# This program is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License (GPL) as published by
@@ -15,37 +15,49 @@
# ------------------------------------------------------------------
# CONSTRUCTOR - create new stack window
# ------------------------------------------------------------------
-itcl::body StackWin::constructor {args} {
+body StackWin::constructor {args} {
gdbtk_busy
build_win
gdbtk_idle
+ add_hook gdb_update_hook [code $this update]
+ add_hook gdb_busy_hook [code $this busy]
add_hook gdb_no_inferior_hook [code $this no_inferior]
+ add_hook gdb_idle_hook [code $this idle]
}
# ------------------------------------------------------------------
# DESTRUCTOR - destroy window containing widget
# ------------------------------------------------------------------
-itcl::body StackWin::destructor {} {
+body StackWin::destructor {} {
+ remove_hook gdb_update_hook [code $this update]
+ remove_hook gdb_idle_hook [code $this idle]
+ remove_hook gdb_busy_hook [code $this busy]
remove_hook gdb_no_inferior_hook [code $this no_inferior]
}
# ------------------------------------------------------------------
# METHOD: build_win - build the main register window
# ------------------------------------------------------------------
-itcl::body StackWin::build_win {} {
-
- itk_component add slb {
- iwidgets::scrolledlistbox $itk_interior.s \
- -vscrollmode dynamic -hscrollmode dynamic \
- -selectmode single -exportselection false -visibleitems 30x15 \
- -textfont global/fixed -selectioncommand [code $this change_frame]
+body StackWin::build_win {} {
+ global tixOption tcl_platform
+ if {$tcl_platform(platform) == "windows"} {
+ tixScrolledListBox $itk_interior.s -scrollbar both -sizebox 1
+ } else {
+ tixScrolledListBox $itk_interior.s -scrollbar auto
}
-
- [$itk_component(slb) component listbox] configure \
- -bg $::Colors(textbg) -fg $::Colors(textfg)
-
- update dummy
+ set lb [$itk_interior.s subwidget listbox]
+ $lb configure -selectmode single -bg $tixOption(input1_bg) \
+ -selectbackground [pref get gdb/src/STACK_TAG] \
+ -selectforeground black \
+ -font src-font \
+ -exportselection false
+ update
+ $lb configure -width $maxwidth
+
+ # bind mouse button 1 to change the stack frame
+ bind $lb <ButtonPress-1> [code $this change_frame %y]
+ bind $lb <ButtonRelease-1> break
pack $itk_interior.s -side left -expand yes -fill both
@@ -56,10 +68,12 @@ itcl::body StackWin::build_win {} {
# ------------------------------------------------------------------
# METHOD: update - update widget when PC changes
# ------------------------------------------------------------------
-itcl::body StackWin::update {event} {
+body StackWin::update {} {
global gdb_selected_frame_level
if {!$protect_me} {
+ set lb [$itk_interior.s subwidget listbox]
+
# The gdb_stack command might fail, for instance if you are browsing
# a trace experiment, and the stack has not been collected.
@@ -69,12 +83,12 @@ itcl::body StackWin::update {event} {
}
if {[llength $frames] == 0} {
- $itk_component(slb) delete 0 end
- $itk_component(slb) insert end {NO STACK}
+ $lb delete 0 end
+ $lb insert end {NO STACK}
return
}
- $itk_component(slb) delete 0 end
+ $lb delete 0 end
set levels 0
foreach frame $frames {
set len [string length $frame]
@@ -82,7 +96,7 @@ itcl::body StackWin::update {event} {
if {$len > $maxwidth} {
set maxwidth $len
}
- $itk_component(slb) insert end $frame
+ $lb insert end $frame
incr levels
}
@@ -90,28 +104,30 @@ itcl::body StackWin::update {event} {
# window is looking at some location other than the
# bottom of the stack. If so, highlight the stack frame
set level [expr {$levels - $gdb_selected_frame_level - 1}]
- $itk_component(slb) selection set $level
- $itk_component(slb) see $level
+ $lb selection set $level
+ $lb see $level
}
}
-itcl::body StackWin::idle {event} {
+body StackWin::idle {} {
set Running 0
cursor {}
}
# ------------------------------------------------------------------
# METHOD: change_frame - change the current frame
-# This method is currently ONLY called from the mouse binding
+# This body StackWin::is currently ONLY called from the mouse binding
# ------------------------------------------------------------------
-itcl::body StackWin::change_frame {} {
+body StackWin::change_frame {y} {
+ set lb [$itk_interior.s subwidget listbox]
- if {!$Running && [$itk_component(slb) size] != 0} {
+ if {!$Running && [$lb size] != 0} {
gdbtk_busy
- set sel [$itk_component(slb) curselection]
- set size [$itk_component(slb) size]
- set frame_num [expr {$size - $sel - 1}]
- catch {gdb_cmd "frame $frame_num"}
+ set lb [$itk_interior.s subwidget listbox]
+ set linenum [$lb nearest $y]
+ set size [$lb size]
+ set linenum [expr {$size - $linenum - 1}]
+ catch {gdb_cmd "frame $linenum"}
# Run idle hooks and cause all widgets to update
set protect_me 1
@@ -124,17 +140,19 @@ itcl::body StackWin::change_frame {} {
# ------------------------------------------------------------------
# METHOD: reconfig - used when preferences change
# ------------------------------------------------------------------
-itcl::body StackWin::reconfig {} {
+body StackWin::reconfig {} {
destroy $itk_interior.s
build_win
}
# ------------------------------------------------------------------
-# PUBLIC METHOD: busy - BusyEvent handler
-# This method should cause blocking of clicks in
-# the window and change mouse pointer.
+# METHOD: busy - gdb_busy_hook
+#
+# This body StackWin::should accomplish blocking
+# - clicks in the window
+# - change mouse pointer
# ------------------------------------------------------------------
-itcl::body StackWin::busy {event} {
+body StackWin::busy {} {
set Running 1
cursor watch
}
@@ -142,17 +160,17 @@ itcl::body StackWin::busy {event} {
# ------------------------------------------------------------------
# METHOD: no_inferior - gdb_no_inferior_hook
# ------------------------------------------------------------------
-itcl::body StackWin::no_inferior {} {
+body StackWin::no_inferior {} {
set Running 0
cursor {}
}
# ------------------------------------------------------------------
# METHOD: cursor - set the window cursor
-# This is a convenience method which simply sets the mouse
+# This is a convenience body StackWin::which simply sets the mouse
# pointer to the given glyph.
# ------------------------------------------------------------------
-itcl::body StackWin::cursor {glyph} {
+body StackWin::cursor {glyph} {
set top [winfo toplevel $itk_interior]
$top configure -cursor $glyph
}
diff --git a/gdb/gdbtk/library/stackwin.ith b/gdb/gdbtk/library/stackwin.ith
index b639746175d..af7132e9e1e 100644
--- a/gdb/gdbtk/library/stackwin.ith
+++ b/gdb/gdbtk/library/stackwin.ith
@@ -1,5 +1,5 @@
# Stack window class definition for GDBtk.
-# Copyright (C) 1997, 1998, 1999 Cygnus Solutions
+# Copyright 1997, 1998, 1999 Cygnus Solutions
#
# This program is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License (GPL) as published by
@@ -16,7 +16,7 @@
# Implements stack window for gdb
# ----------------------------------------------------------------------
-itcl::class StackWin {
+class StackWin {
inherit EmbeddedWin GDBWin
private {
@@ -25,21 +25,17 @@ itcl::class StackWin {
variable protect_me 0
method build_win {}
method cursor {glyph}
- method change_frame {}
+ method change_frame {y}
+ method update {}
+ method busy {}
method no_inferior {}
+ method idle {}
}
public {
method reconfig {}
method constructor {args}
method destructor {}
-
- #
- # GDB Events
- #
- method busy {event}
- method idle {event}
- method update {event}
}
}
diff --git a/gdb/gdbtk/library/targetselection.itb b/gdb/gdbtk/library/targetselection.itb
index 7f9d531ff45..f7630872c16 100644
--- a/gdb/gdbtk/library/targetselection.itb
+++ b/gdb/gdbtk/library/targetselection.itb
@@ -1,5 +1,5 @@
-# Target selection dialog for Insight.
-# Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2008 Red Hat, Inc.
+# Target selection dialog for GDBtk.
+# Copyright 1997, 1998, 1999 Cygnus Solutions
#
# This program is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License (GPL) as published by
@@ -19,13 +19,14 @@
# ------------------------------------------------------------------
# CONSTRUCTOR - create new target selection window
# ------------------------------------------------------------------
-itcl::body TargetSelection::constructor {args} {
+body TargetSelection::constructor {args} {
eval itk_initialize $args
+ set top [winfo toplevel $itk_interior]
_init
build_win
}
-itcl::body TargetSelection::getname {target name} {
+body TargetSelection::getname {target name} {
# Init target database if we haven't already done so
init_target_db
@@ -37,18 +38,13 @@ itcl::body TargetSelection::getname {target name} {
}
}
-itcl::body TargetSelection::init_target_db {} {
+body TargetSelection::init_target_db {} {
# check to see if we already initialized this database
if {$db_inited} {
return
}
set db_inited 1
- # We really need to have the preferences defined, too,
- # otherwise set_target and company won't work properly
- # unless the user has first opened a TargetSelection dialog.
- _init_prefs
-
# Target Database
# Set the following members:
# TARGET,pretty-name: Name to display to user
@@ -97,7 +93,7 @@ itcl::body TargetSelection::init_target_db {} {
# Remote
set gdb_target(remote,pretty-name) "Remote/Serial"
set gdb_target(remote,defbaud) "9600"
- set gdb_target(remote,baud-rates) {9600 19200 38400 57600 115200}
+ set gdb_target(remote,baud-rates) {9600 19200 38400 57600}
set gdb_target(remote,cmd) "remote com1"
set gdb_target(remote,runlist) {1 1 0 1}
set gdb_target(remote,after_attaching) {}
@@ -202,34 +198,6 @@ itcl::body TargetSelection::init_target_db {} {
set gdb_target(mipstcp,runlist) {1 1 0 1}
set gdb_target(mipstcp,after_attaching) {}
- # PMON
- set gdb_target(pmon,pretty-name) "PMON/Serial"
- set gdb_target(pmon,defbaud) "9600"
- set gdb_target(pmon,baud-rates) {9600 19200 38400}
- set gdb_target(pmon,cmd) "pmon com1"
- set gdb_target(pmon,runlist) {1 1 0 1}
- set gdb_target(pmon,after_attaching) {}
- set gdb_target(pmontcp,pretty-name) "PMON/TCP"
- set gdb_target(pmontcp,defbaud) "TCP"
- set gdb_target(pmontcp,baud-rates) {}
- set gdb_target(pmontcp,cmd) "pmon tcpX"
- set gdb_target(pmontcp,runlist) {1 1 0 1}
- set gdb_target(pmontcp,after_attaching) {}
-
- # DDB
- set gdb_target(ddb,pretty-name) "DDB/Serial"
- set gdb_target(ddb,defbaud) "19200"
- set gdb_target(ddb,baud-rates) {9600 19200 38400}
- set gdb_target(ddb,cmd) "ddb com1"
- set gdb_target(ddb,runlist) {1 1 0 1}
- set gdb_target(ddb,after_attaching) {}
- set gdb_target(ddbtcp,pretty-name) "DDB/TCP"
- set gdb_target(ddbtcp,defbaud) "TCP"
- set gdb_target(ddbtcp,baud-rates) {}
- set gdb_target(ddbtcp,cmd) "ddb tcpX"
- set gdb_target(ddbtcp,runlist) {1 1 0 1}
- set gdb_target(ddbtcp,after_attaching) {}
-
# Picobug
set gdb_target(picobug,pretty-name) "Picobug/Serial"
set gdb_target(picobug,defbaud) "19200"
@@ -257,36 +225,12 @@ itcl::body TargetSelection::init_target_db {} {
set gdb_target(ciscotcp,cmd) "cisco tcpX"
set gdb_target(ciscotcp,runlist) {1 0 0 0}
set gdb_target(ciscotcp,after_attaching) "set os cisco"
-
- # VxWorks
- set gdb_target(vxworks,pretty-name) "VxWorks RDB"
- set gdb_target(vxworks,defbaud) "ETH"
- set gdb_target(vxworks,baud-rates) {}
- set gdb_target(vxworks,cmd) "vxworks ethX"
- set gdb_target(vxworks,runlist) { 1 0 1 1}
- set gdb_target(vxworks,after_attaching) { sym vxWorks.st }
-
- # GDBServer, libremote, rda, etc
- set gdb_target(gdbserver,pretty-name) "GDBserver"
- set gdb_target(gdbserver,pretty-name) "GDBserver/Serial"
- set gdb_target(gdbserver,defbaud) "9600"
- set gdb_target(gdbserver,baud-rates) {9600 19200 38400 57600 115200}
- set gdb_target(gdbserver,cmd) "remote com1"
- set gdb_target(gdbserver,runlist) {1 0 0 1}
- set gdb_target(gdbserver,after_attaching) {}
- set gdb_target(gdbservertcp,pretty-name) "GDBserver/TCP"
- set gdb_target(gdbservertcp,defbaud) "TCP"
- set gdb_target(gdbservertcp,baud-rates) {}
- set gdb_target(gdbservertcp,cmd) "remote tcpX"
- set gdb_target(gdbservertcp,runlist) {1 0 0 1}
- set gdb_target(gdbservertcp,after_attaching) {}
}
-itcl::body TargetSelection::default_port {} {
- global gdbtk_platform
- switch -regexp $gdbtk_platform(os) {
- cygwin { set port /dev/com1 }
- mingw { set port COM1 }
+body TargetSelection::default_port {} {
+ global tcl_platform
+ switch -regexp $tcl_platform(os) {
+ Windows { set port com1 }
Linux { set port /dev/ttyS0 }
SunOS { set port /dev/ttya }
AIX { set port /dev/foo1 }
@@ -296,10 +240,9 @@ itcl::body TargetSelection::default_port {} {
NetBSD { set port /dev/foo1 }
HP-UX {
# Special case...
- switch -regexp $gdbtk_platform(osVersion) {
+ switch -regexp $tcl_platform(osVersion) {
A.09 { set port /dev/tty00 }
- B.10 -
- B.11 { set port /dev/tty0p0 }
+ B.10 { set port /dev/tty0p0 }
}
}
default { set port /dev/ttya }
@@ -309,7 +252,7 @@ itcl::body TargetSelection::default_port {} {
}
-itcl::body TargetSelection::_init_prefs {} {
+body TargetSelection::_init_prefs {} {
if {$prefs_inited} {
return
@@ -328,10 +271,9 @@ itcl::body TargetSelection::_init_prefs {} {
pref define gdb/load/default-port [default_port]
pref define gdb/load/default-hostname ""
pref define gdb/load/default-after_attaching {}
- pref define gdb/load/default-portname 32767
}
-itcl::body TargetSelection::_init_target {} {
+body TargetSelection::_init_target {} {
global gdb_target_name
set target_list [get_target_list]
set target $gdb_target_name
@@ -368,7 +310,7 @@ itcl::body TargetSelection::_init_target {} {
}
}
-itcl::body TargetSelection::_init {} {
+body TargetSelection::_init {} {
if {!$trace_inited} {
# Trace all gdb_loaded changes based on target
@@ -377,6 +319,7 @@ itcl::body TargetSelection::_init {} {
set trace_inited 1
init_target_db ;# initialize database
+ _init_prefs ;# initialize load prefs
_init_target ;# initialize target prefs
set_saved
@@ -390,8 +333,8 @@ itcl::body TargetSelection::_init {} {
# ------------------------------------------------------------------
# METHOD: build_win - build the dialog
# ------------------------------------------------------------------
-itcl::body TargetSelection::build_win {} {
- global gdbtk_platform PREFS_state gdb_ImageDir gdb_target_name
+body TargetSelection::build_win {} {
+ global tcl_platform PREFS_state gdb_ImageDir gdb_target_name
set f [frame $itk_interior.f]
set opts [frame $itk_interior.moreoptions]
@@ -405,13 +348,13 @@ itcl::body TargetSelection::build_win {} {
# target name
label $fr.tarl -text [gettext "Target:"]
combobox::combobox $fr.tar -editable 0 -command [code $this change_target] \
- -width $Width -maxheight 10 -bg $::Colors(textbg)
+ -width $Width -maxheight 10
# baud rate combobox
label $fr.cbl -text [gettext "Baud Rate:"]
combobox::combobox $fr.cb -editable 0 -command [code $this change_baud] \
-textvariable [pref varname gdb/load/$target-baud] -width $Width \
- -maxheight 10 -bg $::Colors(textbg)
+ -maxheight 10
if {[catch {gdb_cmd "show remotebaud"} res]} {
set baud [pref get gdb/load/$target-baud]
@@ -432,7 +375,7 @@ itcl::body TargetSelection::build_win {} {
-width $Width
# port combobox
- if {$gdbtk_platform(platform) == "windows"} {
+ if {$tcl_platform(platform) == "windows"} {
set editable 0
} else {
set editable 1
@@ -441,19 +384,19 @@ itcl::body TargetSelection::build_win {} {
label $fr.portl -text [gettext "Port:"]
combobox::combobox $fr.port -editable $editable \
-textvariable [pref varname gdb/load/$target-port] \
- -width $Width -maxheight 10 -bg $::Colors(textbg)
+ -width $Width -maxheight 10
# load baud rates into combobox
fill_rates
# load port combobox
- if {$gdbtk_platform(platform) == "windows"} {
+ if {$tcl_platform(platform) == "windows"} {
foreach val [port_list] {
$fr.port list insert end $val
}
} else {
# fixme: how do I find valid values for these????
- switch $gdbtk_platform(os) {
+ switch $tcl_platform(os) {
Linux { set ports [list /dev/cua0 /dev/ttyS0 /dev/ttyS1 /dev/ttyS2 /dev/ttyS3]}
SunOS { set ports [list /dev/ttya /dev/ttyb] }
AIX { set ports [list /dev/foo1 /dev/foo2] }
@@ -463,10 +406,9 @@ itcl::body TargetSelection::build_win {} {
NetBSD { set ports [list /dev/foo1 /dev/foo2] }
HP-UX {
# Special case...
- switch -regexp $gdbtk_platform(osVersion) {
+ switch -regexp $tcl_platform(osVersion) {
A.09 { set ports [list /dev/tty00 /dev/tty01] }
- B.10 -
- B.11 { set ports [list /dev/tty0p0 /dev/tty1p0] }
+ B.10 { set ports [list /dev/tty0p0 /dev/tty1p0] }
}
}
default { set ports [list UNKNOWN UNKNOWN] }
@@ -491,12 +433,6 @@ itcl::body TargetSelection::build_win {} {
checkbutton $f.fr.verb -text [gettext "Display Download Dialog"] \
-variable [pref varname gdb/load/$target-verbose]
- if {$gdbtk_platform(platform) == "unix"} {
- checkbutton $f.fr.xterm -text [gettext "Use xterm as inferior's tty"] \
- -variable [pref varname gdb/process/xtermtty] \
- -onvalue yes -offvalue no
- }
-
if {![pref get gdb/control_target]} {
$f.fr.main configure -state disabled
$f.fr.exit configure -state disabled
@@ -521,9 +457,6 @@ itcl::body TargetSelection::build_win {} {
pack $f.fr.bp.at_func $f.fr.bp.func -side left
grid $f.fr.bp -sticky w -padx 5 -pady 5
grid $f.fr.verb -sticky w -padx 5 -pady 5
- if {$gdbtk_platform(platform) == "unix"} {
- grid $f.fr.xterm -sticky w -padx 5 -pady 5
- }
if {![pref get gdb/control_target]} {
grid $f.fr.check -sticky w -padx 5 -pady 5
}
@@ -554,31 +487,21 @@ itcl::body TargetSelection::build_win {} {
set var [pref varname gdb/src/run_load]
checkbutton $frame.load -text {Download Program} -variable $var
- set rm_frame [iwidgets::labeledframe $frame.run_method -labelpos nw -labeltext "Run Method" ]
- set RunMethod [ $rm_frame childsite ]
-
set var [pref varname gdb/src/run_cont]
- radiobutton $RunMethod.cont -text {Continue from Last Stop} -value 1 -variable $var \
+ checkbutton $frame.cont -text {Continue from Last Stop} -variable $var \
-command [code $this set_run run]
set var [pref varname gdb/src/run_run]
- radiobutton $RunMethod.run -text {Run Program} -value 1 -variable $var \
+ checkbutton $frame.run -text {Run Program} -variable $var \
-command [code $this set_run cont]
# The after attaching command entry
set _after_entry [entry $frame.aftere]
label $frame.afterl -text {Command to issue after attaching:}
-
- grid $frame.attach -column 0 -row 1 -padx 10 -sticky w
- grid $frame.load -column 0 -row 2 -padx 10 -sticky w
-
- grid $RunMethod.run -column 0 -row 1 -sticky w -ipady 2
- grid $RunMethod.cont -column 0 -row 2 -sticky w -ipady 2
-
- grid $rm_frame -column 1 -row 1 -rowspan 2 -sticky nsew -ipady 2
-
- grid $frame.afterl -row 4 -sticky we -columnspan 2 -ipady 2
- grid $frame.aftere -sticky we -columnspan 2 -ipady 2
+ grid $frame.attach $frame.run -sticky w
+ grid $frame.load $frame.cont -sticky w
+ grid $frame.afterl -sticky we -columnspan 2
+ grid $frame.aftere -sticky we -columnspan 2
grid columnconfigure $frame 0 -weight 1
grid columnconfigure $frame 1 -weight 1
@@ -595,8 +518,8 @@ itcl::body TargetSelection::build_win {} {
-default active
button $btns.cancel -text [gettext Cancel] -width 7 \
-command [code $this cancel]
- button $btns.help -text [gettext Help] -width 7 -command [code $this help]
-
+ button $btns.help -text [gettext Help] -width 7 -command [code $this help] \
+ -state disabled
standard_button_box $btns
bind $btns.ok <Return> "$btns.ok flash; $btns.ok invoke"
bind $btns.cancel <Return> "$btns.cancel flash; $btns.cancel invoke"
@@ -622,7 +545,7 @@ itcl::body TargetSelection::build_win {} {
# ------------------------------------------------------------------
# METHOD: set_saved - set saved values
# ------------------------------------------------------------------
-itcl::body TargetSelection::set_saved {} {
+body TargetSelection::set_saved {} {
set saved_baud [pref get gdb/load/$target-baud]
set saved_port [pref get gdb/load/$target-port]
set saved_main [pref get gdb/load/main]
@@ -645,7 +568,7 @@ itcl::body TargetSelection::set_saved {} {
# ------------------------------------------------------------------
# METHOD: write_saved - write saved values to preferences
# ------------------------------------------------------------------
-itcl::body TargetSelection::write_saved {} {
+body TargetSelection::write_saved {} {
pref setd gdb/load/$target-baud $saved_baud
pref setd gdb/load/$target-port $saved_port
pref setd gdb/load/main $saved_main
@@ -667,7 +590,7 @@ itcl::body TargetSelection::write_saved {} {
# ------------------------------------------------------------------
# METHOD: fill_rates - fill baud rate combobox
# ------------------------------------------------------------------
-itcl::body TargetSelection::fill_rates {} {
+body TargetSelection::fill_rates {} {
$fr.cb list delete 0 end
if {$gdb_target($target,baud-rates) != ""} {
@@ -680,7 +603,7 @@ itcl::body TargetSelection::fill_rates {} {
# ------------------------------------------------------------------
# METHOD: fill_targets - fill target combobox
# ------------------------------------------------------------------
-itcl::body TargetSelection::fill_targets {} {
+body TargetSelection::fill_targets {} {
#[$fr.tar subwidget listbox] delete 0 end
$fr.tar list delete 0 end
@@ -700,7 +623,7 @@ itcl::body TargetSelection::fill_targets {} {
# METHOD: config_dialog - Convenience method to map/unmap/rename
# components onto the screen based on target T.
# ------------------------------------------------------------------
-itcl::body TargetSelection::config_dialog {t} {
+body TargetSelection::config_dialog {t} {
pref define gdb/load/$t-verbose [pref get gdb/load/verbose]
$f.fr.verb config -variable [pref varname gdb/load/$t-verbose]
# Map the correct entries and comboboxes onto the screen
@@ -796,18 +719,9 @@ itcl::body TargetSelection::config_dialog {t} {
# ------------------------------------------------------------------
# METHOD: change_target - callback for target combobox
# ------------------------------------------------------------------
-itcl::body TargetSelection::change_target {w {name ""}} {
+body TargetSelection::change_target {w {name ""}} {
if {$name == ""} {return}
set target [get_target $name]
-
- if { "$target" == "exec" } {
- $RunMethod.run configure -state disabled -value 1
- $RunMethod.cont configure -state disabled
- } else {
- $RunMethod.run configure -state normal
- $RunMethod.cont configure -state normal
- }
-
debug "$target"
set defbaud $gdb_target($target,defbaud)
pref define gdb/load/$target-baud $defbaud
@@ -853,10 +767,9 @@ itcl::body TargetSelection::change_target {w {name ""}} {
# PRIVATE METHOD: change_baud - called when the baud rate is changed.
# If GDB is running, set baud rate in GDB and read it back.
# ------------------------------------------------------------------
-itcl::body TargetSelection::change_baud {w {baud ""}} {
+body TargetSelection::change_baud {w {baud ""}} {
if {$baud != ""} {
- if {([string compare $baud "TCP"] != 0)
- && ([string compare $baud "ETH"] != 0)} {
+ if {[string compare $baud "TCP"] != 0} {
gdb_cmd "set remotebaud $baud"
if {[catch {gdb_cmd "show remotebaud"} res]} {
set newbaud 0
@@ -878,34 +791,24 @@ itcl::body TargetSelection::change_baud {w {baud ""}} {
# ------------------------------------------------------------------
# METHOD: port_list - return a list of valid ports for Windows
# ------------------------------------------------------------------
-itcl::body TargetSelection::port_list {} {
- global gdbtk_platform
- if {[string compare $gdbtk_platform(os) "cygwin"] == 0} {
- set device "/dev/com"
- } else {
- set device "COM"
- }
+body TargetSelection::port_list {} {
set plist ""
# Scan com1 - com8 trying to open each one.
# If permission is denied that means it is in use,
# which is OK because we may be using it or the user
# may be setting up the remote target manually with
# a terminal program.
- set quit 0
- for {set i 1} {!$quit} {incr i} {
+ for {set i 1} {$i < 9} { incr i} {
if {[catch { set fd [::open COM$i: RDWR] } msg]} {
# Failed. Find out why.
if {[string first "permission denied" $msg] != -1} {
# Port is there, but busy right now. That's OK.
- lappend plist $device$i
- } elseif {$i > 4} {
- # if we've scanned the first 4 ports, then quit when we find no more
- set quit 1
+ lappend plist com$i
}
} else {
# We got it. Now close it and add to list.
close $fd
- lappend plist $device$i
+ lappend plist com$i
}
}
return $plist
@@ -915,31 +818,28 @@ itcl::body TargetSelection::port_list {} {
# METHOD: get_target_list - return a list of targets supported
# by this GDB. Parses the output of "help target"
# ------------------------------------------------------------------
-itcl::body TargetSelection::get_target_list {} {
+body TargetSelection::get_target_list {} {
set native [native_debugging]
set names ""
- set res [gdb_cmd "help target"]; # this just screams MI...
-
- # targets are listed with lines like "target NAME -- DESCRIPTION"
+ set res [gdb_cmd "help target"]
foreach line [split $res \n] {
- if {[scan $line "target %s --" name] == 1} {
+ if {![string compare [lindex $line 0] "target"]} {
+ set name [lindex $line 1]
+
# For cross debuggers, do not allow the target "exec"
if {$name == "exec" && !$native} {
continue
}
-
lappend names $name
}
}
-
- lappend names gdbserver
- return [lsort $names]
+ return $names
}
# ------------------------------------------------------------------
# METHOD: save - save values
# ------------------------------------------------------------------
-itcl::body TargetSelection::save {} {
+body TargetSelection::save {} {
global gdb_target_name
set err [catch {
set_saved
@@ -961,7 +861,7 @@ itcl::body TargetSelection::save {} {
# ------------------------------------------------------------------
# METHOD: cancel - restore previous values
# ------------------------------------------------------------------
-itcl::body TargetSelection::cancel {} {
+body TargetSelection::cancel {} {
global gdb_target_name
catch {gdb_cmd "set remotebaud $saved_baud"}
@@ -978,7 +878,7 @@ itcl::body TargetSelection::cancel {} {
# ------------------------------------------------------------------
# METHOD: set_check_button - enable/disable compare-section command
# ------------------------------------------------------------------
-itcl::body TargetSelection::set_check_button {name} {
+body TargetSelection::set_check_button {name} {
if {[winfo exists $itk_interior.f.fr.check]} {
if { $name == "exec" } {
$itk_interior.f.fr.check configure -state disabled
@@ -991,14 +891,13 @@ itcl::body TargetSelection::set_check_button {name} {
# ------------------------------------------------------------------
# METHOD: help - launches context sensitive help.
# ------------------------------------------------------------------
-itcl::body TargetSelection::help {} {
- open_help target.html
+body TargetSelection::help {} {
}
# ------------------------------------------------------------------
# METHOD: reconfig - used when preferences change
# ------------------------------------------------------------------
-itcl::body TargetSelection::reconfig {} {
+body TargetSelection::reconfig {} {
# for now, just delete and recreate
destroy $itk_interior.f
build_win
@@ -1008,7 +907,7 @@ itcl::body TargetSelection::reconfig {} {
# METHOD: get_target - get the internal name of a target from the
# pretty-name
# ------------------------------------------------------------------
-itcl::body TargetSelection::get_target {name} {
+body TargetSelection::get_target {name} {
set t {}
set list [array get gdb_target *,pretty-name]
set i [lsearch -exact $list $name]
@@ -1025,7 +924,7 @@ itcl::body TargetSelection::get_target {name} {
# METHOD: toggle_more_options -- toggle displaying the More/Fewer
# Options pane
# ------------------------------------------------------------------
-itcl::body TargetSelection::toggle_more_options {} {
+body TargetSelection::toggle_more_options {} {
if {[$MoreLabel cget -text] == "More Options"} {
$MoreLabel configure -text "Fewer Options"
$MoreButton configure -image _LESS_
@@ -1044,7 +943,7 @@ itcl::body TargetSelection::toggle_more_options {} {
# METHOD: set_run - set the run button. Make sure not both run and
# continue are selected.
# ------------------------------------------------------------------
-itcl::body TargetSelection::set_run {check_which} {
+body TargetSelection::set_run {check_which} {
global PREFS_state
set var [pref varname gdb/src/run_$check_which]
global $var
@@ -1059,7 +958,7 @@ itcl::body TargetSelection::set_run {check_which} {
# and possible more) whenever the value of gdb_loaded
# is changed based on the current target.
# ------------------------------------------------------------------
-itcl::body TargetSelection::target_trace {variable index op} {
+body TargetSelection::target_trace {variable index op} {
global gdb_target_name gdb_loaded
switch $gdb_target_name {
@@ -1072,11 +971,7 @@ itcl::body TargetSelection::target_trace {variable index op} {
}
# Returns 1 if TARGET is a _runnable_ target for this gdb.
-itcl::body TargetSelection::valid_target {target} {
-
- # always allow gdbserver
- if {$target == "gdbserver"} {return 1}
-
+body TargetSelection::valid_target {target} {
set err [catch {gdb_cmd "help target $target"}]
if {$target == "exec" && ![native_debugging]} {
set err 1
@@ -1092,7 +987,7 @@ itcl::body TargetSelection::valid_target {target} {
}
# Returns 1 if this is not a cross debugger.
-itcl::body TargetSelection::native_debugging {} {
+body TargetSelection::native_debugging {} {
global GDBStartup
set r [string compare $GDBStartup(host_name) $GDBStartup(target_name)]
diff --git a/gdb/gdbtk/library/targetselection.ith b/gdb/gdbtk/library/targetselection.ith
index a7c9182491d..654328fccae 100644
--- a/gdb/gdbtk/library/targetselection.ith
+++ b/gdb/gdbtk/library/targetselection.ith
@@ -1,5 +1,5 @@
# Target selection dialog class definition for GDBtk.
-# Copyright (C) 1997, 1998, 1999 Cygnus Solutions
+# Copyright 1997, 1998, 1999 Cygnus Solutions
#
# This program is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License (GPL) as published by
@@ -12,7 +12,7 @@
# GNU General Public License for more details.
-itcl::class TargetSelection {
+class TargetSelection {
inherit ModalDialog ManagedWin
private {
@@ -55,8 +55,6 @@ itcl::class TargetSelection {
variable MoreButton
variable MoreFrame
variable MoreLabel
-
- variable RunMethod
proc _init_prefs {}
proc default_port {}
@@ -68,6 +66,7 @@ itcl::class TargetSelection {
method config_dialog {t}
method fill_rates {}
method fill_targets {}
+ method get_target_list {}
method get_target {name}
method help {}
method _init {}
@@ -89,7 +88,6 @@ itcl::class TargetSelection {
method constructor {args}
method reconfig {}
- proc get_target_list {}
proc native_debugging {}
proc getname {target name}
proc init_target_db {}
diff --git a/gdb/gdbtk/library/tclIndex b/gdb/gdbtk/library/tclIndex
index 03ad77e86a5..73ea49ca0ed 100644
--- a/gdb/gdbtk/library/tclIndex
+++ b/gdb/gdbtk/library/tclIndex
@@ -8,18 +8,12 @@
set auto_index(About) [list source [file join $dir about.tcl]]
set auto_index(ActionDlg) [list source [file join $dir actiondlg.tcl]]
-set auto_index(::Editor::edit) [list source [file join $dir editor.tcl]]
-set auto_index(open_help) [list source [file join $dir helpviewer.tcl]]
-set auto_index(prompt_helpname) [list source [file join $dir helpviewer.tcl]]
-set auto_index(gdbtk_tcl_set_variable) [list source [file join $dir interface.tcl]]
set auto_index(gdbtk_tcl_preloop) [list source [file join $dir interface.tcl]]
set auto_index(gdbtk_busy) [list source [file join $dir interface.tcl]]
set auto_index(gdbtk_update) [list source [file join $dir interface.tcl]]
-set auto_index(gdbtk_update_safe) [list source [file join $dir interface.tcl]]
set auto_index(gdbtk_idle) [list source [file join $dir interface.tcl]]
set auto_index(gdbtk_quit_check) [list source [file join $dir interface.tcl]]
set auto_index(gdbtk_quit) [list source [file join $dir interface.tcl]]
-set auto_index(gdbtk_force_quit) [list source [file join $dir interface.tcl]]
set auto_index(gdbtk_cleanup) [list source [file join $dir interface.tcl]]
set auto_index(gdbtk_tcl_query) [list source [file join $dir interface.tcl]]
set auto_index(gdbtk_tcl_warning) [list source [file join $dir interface.tcl]]
@@ -28,9 +22,6 @@ set auto_index(gdbtk_tcl_ignorable_warning) [list source [file join $dir interfa
set auto_index(gdbtk_tcl_fputs) [list source [file join $dir interface.tcl]]
set auto_index(echo) [list source [file join $dir interface.tcl]]
set auto_index(gdbtk_tcl_fputs_error) [list source [file join $dir interface.tcl]]
-set auto_index(gdbtk_tcl_fputs_log) [list source [file join $dir interface.tcl]]
-set auto_index(gdbtk_tcl_fputs_target) [list source [file join $dir interface.tcl]]
-set auto_index(gdbtk_tcl_fputs_target_err) [list source [file join $dir interface.tcl]]
set auto_index(gdbtk_tcl_flush) [list source [file join $dir interface.tcl]]
set auto_index(gdbtk_tcl_start_variable_annotation) [list source [file join $dir interface.tcl]]
set auto_index(gdbtk_tcl_end_variable_annotation) [list source [file join $dir interface.tcl]]
@@ -38,7 +29,6 @@ set auto_index(gdbtk_tcl_breakpoint) [list source [file join $dir interface.tcl]
set auto_index(gdbtk_tcl_tracepoint) [list source [file join $dir interface.tcl]]
set auto_index(gdbtk_tcl_trace_find_hook) [list source [file join $dir interface.tcl]]
set auto_index(gdb_run_readline_command) [list source [file join $dir interface.tcl]]
-set auto_index(gdb_run_readline_command_no_output) [list source [file join $dir interface.tcl]]
set auto_index(gdbtk_tcl_readline_begin) [list source [file join $dir interface.tcl]]
set auto_index(gdbtk_tcl_readline) [list source [file join $dir interface.tcl]]
set auto_index(gdbtk_tcl_readline_end) [list source [file join $dir interface.tcl]]
@@ -57,12 +47,10 @@ set auto_index(gdbtk_locate_main) [list source [file join $dir interface.tcl]]
set auto_index(set_exe_name) [list source [file join $dir interface.tcl]]
set auto_index(set_exe) [list source [file join $dir interface.tcl]]
set auto_index(_open_file) [list source [file join $dir interface.tcl]]
-set auto_index(_close_file) [list source [file join $dir interface.tcl]]
set auto_index(set_target_name) [list source [file join $dir interface.tcl]]
set auto_index(set_target) [list source [file join $dir interface.tcl]]
set auto_index(run_executable) [list source [file join $dir interface.tcl]]
-set auto_index(gdbtk_attach_remote) [list source [file join $dir interface.tcl]]
-set auto_index(gdbtk_connect) [list source [file join $dir interface.tcl]]
+set auto_index(gdbtk_attach_target) [list source [file join $dir interface.tcl]]
set auto_index(gdbtk_step) [list source [file join $dir interface.tcl]]
set auto_index(gdbtk_next) [list source [file join $dir interface.tcl]]
set auto_index(gdbtk_finish) [list source [file join $dir interface.tcl]]
@@ -75,19 +63,15 @@ set auto_index(gdbtk_stop) [list source [file join $dir interface.tcl]]
set auto_index(gdbtk_stop_idle_callback) [list source [file join $dir interface.tcl]]
set auto_index(gdbtk_detach) [list source [file join $dir interface.tcl]]
set auto_index(gdbtk_run) [list source [file join $dir interface.tcl]]
-set auto_index(gdbtk_attach_native) [list source [file join $dir interface.tcl]]
set auto_index(set_baud) [list source [file join $dir interface.tcl]]
set auto_index(do_state_hook) [list source [file join $dir interface.tcl]]
-set auto_index(gdbtk_disconnect) [list source [file join $dir interface.tcl]]
+set auto_index(disconnect) [list source [file join $dir interface.tcl]]
set auto_index(tstart) [list source [file join $dir interface.tcl]]
set auto_index(tstop) [list source [file join $dir interface.tcl]]
set auto_index(source_file) [list source [file join $dir interface.tcl]]
set auto_index(gdbtk_signal) [list source [file join $dir interface.tcl]]
set auto_index(gdbtk_clear_file) [list source [file join $dir interface.tcl]]
set auto_index(initialize_gdbtk) [list source [file join $dir interface.tcl]]
-set auto_index(gdbtk_tcl_architecture_changed) [list source [file join $dir interface.tcl]]
-set auto_index(gdbtk_console_read) [list source [file join $dir interface.tcl]]
-set auto_index(Iipc) [list source [file join $dir ipc.tcl]]
set auto_index(LocalsWin) [list source [file join $dir locals.tcl]]
set auto_index(ModalDialog) [list source [file join $dir modal.tcl]]
set auto_index(pref_read) [list source [file join $dir prefs.tcl]]
@@ -95,25 +79,14 @@ set auto_index(pref_save) [list source [file join $dir prefs.tcl]]
set auto_index(escape_value) [list source [file join $dir prefs.tcl]]
set auto_index(unescape_value) [list source [file join $dir prefs.tcl]]
set auto_index(pref_set_defaults) [list source [file join $dir prefs.tcl]]
-set auto_index(pref_set_colors) [list source [file join $dir prefs.tcl]]
-set auto_index(pref_load_default) [list source [file join $dir prefs.tcl]]
-set auto_index(pref_load_gnome) [list source [file join $dir prefs.tcl]]
-set auto_index(load_gnome_file) [list source [file join $dir prefs.tcl]]
-set auto_index(pref_set_option_db) [list source [file join $dir prefs.tcl]]
-set auto_index(::Session::_exe_name) [list source [file join $dir session.tcl]]
-set auto_index(::Session::_serialize_bps) [list source [file join $dir session.tcl]]
-set auto_index(::Session::_recreate_bps) [list source [file join $dir session.tcl]]
-set auto_index(::Session::save) [list source [file join $dir session.tcl]]
-set auto_index(::Session::load) [list source [file join $dir session.tcl]]
-set auto_index(::Session::notice_file_change) [list source [file join $dir session.tcl]]
-set auto_index(::Session::delete) [list source [file join $dir session.tcl]]
-set auto_index(::Session::list_names) [list source [file join $dir session.tcl]]
+set auto_index(pref_src-font_trace) [list source [file join $dir prefs.tcl]]
+set auto_index(GDBSrcBar) [list source [file join $dir srcbar.tcl]]
set auto_index(TdumpWin) [list source [file join $dir tdump.tcl]]
+set auto_index(TfindArgs) [list source [file join $dir tfind_args.tcl]]
+set auto_index(GDBToolBar) [list source [file join $dir toolbar.tcl]]
set auto_index(TraceDlg) [list source [file join $dir tracedlg.tcl]]
set auto_index(gdb_add_tracepoint) [list source [file join $dir tracedlg.tcl]]
set auto_index(gdb_edit_tracepoint) [list source [file join $dir tracedlg.tcl]]
-set auto_index(::tty::create) [list source [file join $dir tty.tcl]]
-set auto_index(::tty::destroy) [list source [file join $dir tty.tcl]]
set auto_index(keep_raised) [list source [file join $dir util.tcl]]
set auto_index(sleep) [list source [file join $dir util.tcl]]
set auto_index(auto_step) [list source [file join $dir util.tcl]]
@@ -123,46 +96,35 @@ set auto_index(save_trace_commands) [list source [file join $dir util.tcl]]
set auto_index(do_test) [list source [file join $dir util.tcl]]
set auto_index(gdbtk_read_defs) [list source [file join $dir util.tcl]]
set auto_index(bp_exists) [list source [file join $dir util.tcl]]
+set auto_index(CygScrolledListbox) [list source [file join $dir util.tcl]]
set auto_index(gridCGet) [list source [file join $dir util.tcl]]
+set auto_index(find_iwidgets_library) [list source [file join $dir util.tcl]]
set auto_index(get_disassembly_flavor) [list source [file join $dir util.tcl]]
set auto_index(list_disassembly_flavors) [list source [file join $dir util.tcl]]
set auto_index(init_disassembly_flavor) [list source [file join $dir util.tcl]]
set auto_index(list_element_strcmp) [list source [file join $dir util.tcl]]
-set auto_index(gdbtk_endian) [list source [file join $dir util.tcl]]
-set auto_index(set_bg_colors) [list source [file join $dir util.tcl]]
-set auto_index(r_setcolors) [list source [file join $dir util.tcl]]
-set auto_index(recolor) [list source [file join $dir util.tcl]]
+set auto_index(VariableWin) [list source [file join $dir variables.tcl]]
+set auto_index(::VariableWin::getLocals) [list source [file join $dir variables.tcl]]
set auto_index(WarningDlg) [list source [file join $dir warning.tcl]]
set auto_index(::WarningDlg::constructor) [list source [file join $dir warning.tcl]]
set auto_index(WatchWin) [list source [file join $dir watch.tcl]]
-set auto_index(GDBMenuBar) [list source [file join $dir gdbmenubar.itcl]]
-set auto_index(GDBToolBar) [list source [file join $dir gdbtoolbar.itcl]]
-set auto_index(PluginWindow) [list source [file join $dir pluginwin.itcl]]
-set auto_index(SrcBar) [list source [file join $dir srcbar.itcl]]
set auto_index(AttachDlg) [list source [file join $dir attachdlg.ith]]
set auto_index(Block) [list source [file join $dir blockframe.ith]]
set auto_index(Frame) [list source [file join $dir blockframe.ith]]
set auto_index(BpWin) [list source [file join $dir bpwin.ith]]
set auto_index(BrowserWin) [list source [file join $dir browserwin.ith]]
+set auto_index(::BrowserWin::dont_remember_size) [list source [file join $dir browserwin.ith]]
set auto_index(Console) [list source [file join $dir console.ith]]
-set auto_index(CSPref) [list source [file join $dir cspref.ith]]
+set auto_index(Stack) [list source [file join $dir data.ith]]
+set auto_index(Queue) [list source [file join $dir data.ith]]
set auto_index(DebugWin) [list source [file join $dir debugwin.ith]]
set auto_index(DebugWinDOpts) [list source [file join $dir debugwin.ith]]
set auto_index(Download) [list source [file join $dir download.ith]]
-set auto_index(GDBEventHandler) [list source [file join $dir ehandler.ith]]
-set auto_index(::GDBEventHandler::dispatch) [list source [file join $dir ehandler.ith]]
set auto_index(EmbeddedWin) [list source [file join $dir embeddedwin.ith]]
-set auto_index(GDBEvent) [list source [file join $dir gdbevent.ith]]
-set auto_index(BreakpointEvent) [list source [file join $dir gdbevent.ith]]
-set auto_index(TracepointEvent) [list source [file join $dir gdbevent.ith]]
-set auto_index(SetVariableEvent) [list source [file join $dir gdbevent.ith]]
-set auto_index(BusyEvent) [list source [file join $dir gdbevent.ith]]
-set auto_index(IdleEvent) [list source [file join $dir gdbevent.ith]]
-set auto_index(UpdateEvent) [list source [file join $dir gdbevent.ith]]
-set auto_index(ArchChangedEvent) [list source [file join $dir gdbevent.ith]]
set auto_index(GDBWin) [list source [file join $dir gdbwin.ith]]
set auto_index(GlobalPref) [list source [file join $dir globalpref.ith]]
-set auto_index(IPCPref) [list source [file join $dir ipcpref.ith]]
+set auto_index(HtmlViewer) [list source [file join $dir helpviewer.ith]]
+set auto_index(PageStack) [list source [file join $dir helpviewer.ith]]
set auto_index(KodWin) [list source [file join $dir kod.ith]]
set auto_index(ManagedWin) [list source [file join $dir managedwin.ith]]
set auto_index(MemPref) [list source [file join $dir mempref.ith]]
@@ -175,7 +137,6 @@ set auto_index(SrcWin) [list source [file join $dir srcwin.ith]]
set auto_index(StackWin) [list source [file join $dir stackwin.ith]]
set auto_index(TargetSelection) [list source [file join $dir targetselection.ith]]
set auto_index(TopLevelWin) [list source [file join $dir toplevelwin.ith]]
-set auto_index(VarTree) [list source [file join $dir vartree.ith]]
set auto_index(::AttachDlg::constructor) [list source [file join $dir attachdlg.itb]]
set auto_index(::AttachDlg::build_win) [list source [file join $dir attachdlg.itb]]
set auto_index(::AttachDlg::doit) [list source [file join $dir attachdlg.itb]]
@@ -211,14 +172,12 @@ set auto_index(::BpWin::bp_add) [list source [file join $dir bpwin.itb]]
set auto_index(::BpWin::bp_store) [list source [file join $dir bpwin.itb]]
set auto_index(::BpWin::bp_restore) [list source [file join $dir bpwin.itb]]
set auto_index(::BpWin::bp_select) [list source [file join $dir bpwin.itb]]
-set auto_index(::BpWin::_select_and_popup) [list source [file join $dir bpwin.itb]]
set auto_index(::BpWin::bp_modify) [list source [file join $dir bpwin.itb]]
set auto_index(::BpWin::bp_able) [list source [file join $dir bpwin.itb]]
set auto_index(::BpWin::bp_remove) [list source [file join $dir bpwin.itb]]
set auto_index(::BpWin::bp_type) [list source [file join $dir bpwin.itb]]
set auto_index(::BpWin::bp_delete) [list source [file join $dir bpwin.itb]]
-set auto_index(::BpWin::breakpoint) [list source [file join $dir bpwin.itb]]
-set auto_index(::BpWin::tracepoint) [list source [file join $dir bpwin.itb]]
+set auto_index(::BpWin::update) [list source [file join $dir bpwin.itb]]
set auto_index(::BpWin::bp_all) [list source [file join $dir bpwin.itb]]
set auto_index(::BpWin::get_actions) [list source [file join $dir bpwin.itb]]
set auto_index(::BpWin::toggle_threads) [list source [file join $dir bpwin.itb]]
@@ -231,6 +190,10 @@ set auto_index(::BrowserWin::_filter_trace_proc) [list source [file join $dir br
set auto_index(::BrowserWin::_filter_trace_after) [list source [file join $dir browserwin.itb]]
set auto_index(::BrowserWin::_search_src) [list source [file join $dir browserwin.itb]]
set auto_index(::BrowserWin::search) [list source [file join $dir browserwin.itb]]
+set auto_index(::BrowserWin::_toggle_more) [list source [file join $dir browserwin.itb]]
+set auto_index(::BrowserWin::_bind_toplevel) [list source [file join $dir browserwin.itb]]
+set auto_index(::BrowserWin::_do_resize) [list source [file join $dir browserwin.itb]]
+set auto_index(::BrowserWin::_resize) [list source [file join $dir browserwin.itb]]
set auto_index(::BrowserWin::_process_file_selection) [list source [file join $dir browserwin.itb]]
set auto_index(::BrowserWin::_process_func_selection) [list source [file join $dir browserwin.itb]]
set auto_index(::BrowserWin::do_all_bp) [list source [file join $dir browserwin.itb]]
@@ -243,18 +206,13 @@ set auto_index(::BrowserWin::mode) [list source [file join $dir browserwin.itb]]
set auto_index(::BrowserWin::_goto_func) [list source [file join $dir browserwin.itb]]
set auto_index(::BrowserWin::_fill_file_box) [list source [file join $dir browserwin.itb]]
set auto_index(::BrowserWin::_fill_funcs_combo) [list source [file join $dir browserwin.itb]]
-set auto_index(::BrowserWin::_build_filter_frame) [list source [file join $dir browserwin.itb]]
-set auto_index(::BrowserWin::_build_file_frame) [list source [file join $dir browserwin.itb]]
-set auto_index(::BrowserWin::_build_function_frame) [list source [file join $dir browserwin.itb]]
-set auto_index(::BrowserWin::_build_view_frame) [list source [file join $dir browserwin.itb]]
-set auto_index(::BrowserWin::_switch_layout) [list source [file join $dir browserwin.itb]]
set auto_index(::Console::constructor) [list source [file join $dir console.itb]]
set auto_index(::Console::destructor) [list source [file join $dir console.itb]]
set auto_index(::Console::_build_win) [list source [file join $dir console.itb]]
set auto_index(::Console::idle) [list source [file join $dir console.itb]]
set auto_index(::Console::busy) [list source [file join $dir console.itb]]
set auto_index(::Console::insert) [list source [file join $dir console.itb]]
-set auto_index(::Console::_operate_and_get_next) [list source [file join $dir console.itb]]
+set auto_index(::Console::einsert) [list source [file join $dir console.itb]]
set auto_index(::Console::_previous) [list source [file join $dir console.itb]]
set auto_index(::Console::_search_history) [list source [file join $dir console.itb]]
set auto_index(::Console::_rsearch_history) [list source [file join $dir console.itb]]
@@ -262,31 +220,25 @@ set auto_index(::Console::_next) [list source [file join $dir console.itb]]
set auto_index(::Console::_last) [list source [file join $dir console.itb]]
set auto_index(::Console::_first) [list source [file join $dir console.itb]]
set auto_index(::Console::_setprompt) [list source [file join $dir console.itb]]
-set auto_index(::Console::gets) [list source [file join $dir console.itb]]
-set auto_index(::Console::_cancel) [list source [file join $dir console.itb]]
set auto_index(::Console::activate) [list source [file join $dir console.itb]]
set auto_index(::Console::invoke) [list source [file join $dir console.itb]]
set auto_index(::Console::_delete) [list source [file join $dir console.itb]]
set auto_index(::Console::_insertion) [list source [file join $dir console.itb]]
set auto_index(::Console::_paste) [list source [file join $dir console.itb]]
+set auto_index(::Console::get_text) [list source [file join $dir console.itb]]
set auto_index(::Console::_find_lcp) [list source [file join $dir console.itb]]
set auto_index(::Console::_find_completion) [list source [file join $dir console.itb]]
set auto_index(::Console::_complete) [list source [file join $dir console.itb]]
set auto_index(::Console::_reset_tab) [list source [file join $dir console.itb]]
-set auto_index(::Console::_set_wrap) [list source [file join $dir console.itb]]
-set auto_index(::Console::_update_option) [list source [file join $dir console.itb]]
-set auto_index(::Console::test) [list source [file join $dir console.itb]]
-set auto_index(::CSPref::constructor) [list source [file join $dir cspref.itb]]
-set auto_index(::CSPref::_init_var) [list source [file join $dir cspref.itb]]
-set auto_index(::CSPref::_build_win) [list source [file join $dir cspref.itb]]
-set auto_index(::CSPref::_apply) [list source [file join $dir cspref.itb]]
-set auto_index(::CSPref::_cancel) [list source [file join $dir cspref.itb]]
-set auto_index(::CSPref::_save) [list source [file join $dir cspref.itb]]
-set auto_index(::CSPref::reconfig) [list source [file join $dir cspref.itb]]
-set auto_index(::CSPref::_pick) [list source [file join $dir cspref.itb]]
+set auto_index(::Stack::constructor) [list source [file join $dir data.itb]]
+set auto_index(::Stack::push) [list source [file join $dir data.itb]]
+set auto_index(::Stack::destructor) [list source [file join $dir data.itb]]
+set auto_index(::Stack::pop) [list source [file join $dir data.itb]]
+set auto_index(::Queue::constructor) [list source [file join $dir data.itb]]
+set auto_index(::Queue::destructor) [list source [file join $dir data.itb]]
+set auto_index(::Queue::pop) [list source [file join $dir data.itb]]
set auto_index(::DebugWin::constructor) [list source [file join $dir debugwin.itb]]
set auto_index(::DebugWin::destructor) [list source [file join $dir debugwin.itb]]
-set auto_index(::DebugWin::reconfig) [list source [file join $dir debugwin.itb]]
set auto_index(::DebugWin::build_win) [list source [file join $dir debugwin.itb]]
set auto_index(::DebugWin::puts) [list source [file join $dir debugwin.itb]]
set auto_index(::DebugWin::put_trace) [list source [file join $dir debugwin.itb]]
@@ -308,38 +260,34 @@ set auto_index(::Download::destructor) [list source [file join $dir download.itb
set auto_index(::Download::do_download_hooks) [list source [file join $dir download.itb]]
set auto_index(::Download::download_hash) [list source [file join $dir download.itb]]
set auto_index(::Download::download_it) [list source [file join $dir download.itb]]
-set auto_index(::GDBEventHandler::dispatch) [list source [file join $dir ehandler.itb]]
-set auto_index(::BreakpointEvent::get) [list source [file join $dir gdbevent.itb]]
-set auto_index(::BreakpointEvent::_init) [list source [file join $dir gdbevent.itb]]
-set auto_index(::BreakpointEvent::number) [list source [file join $dir gdbevent.itb]]
-set auto_index(::TracepointEvent::get) [list source [file join $dir gdbevent.itb]]
-set auto_index(::TracepointEvent::_init) [list source [file join $dir gdbevent.itb]]
-set auto_index(::TracepointEvent::number) [list source [file join $dir gdbevent.itb]]
-set auto_index(::TracepointEvent::get) [list source [file join $dir gdbevent.itb]]
-set auto_index(::SetVariableEvent::get) [list source [file join $dir gdbevent.itb]]
-set auto_index(::UpdateEvent::constructor) [list source [file join $dir gdbevent.itb]]
-set auto_index(::UpdateEvent::get) [list source [file join $dir gdbevent.itb]]
set auto_index(::GlobalPref::_init) [list source [file join $dir globalpref.itb]]
-set auto_index(::GlobalPref::_init_var) [list source [file join $dir globalpref.itb]]
set auto_index(::GlobalPref::constructor) [list source [file join $dir globalpref.itb]]
set auto_index(::GlobalPref::destructor) [list source [file join $dir globalpref.itb]]
-set auto_index(::GlobalPref::_build_win) [list source [file join $dir globalpref.itb]]
-set auto_index(::GlobalPref::_make_font_item) [list source [file join $dir globalpref.itb]]
-set auto_index(::GlobalPref::_resize_font_item_height) [list source [file join $dir globalpref.itb]]
-set auto_index(::GlobalPref::_change_icons) [list source [file join $dir globalpref.itb]]
-set auto_index(::GlobalPref::_change_font) [list source [file join $dir globalpref.itb]]
-set auto_index(::GlobalPref::_change_size) [list source [file join $dir globalpref.itb]]
-set auto_index(::GlobalPref::_toggle_tracing) [list source [file join $dir globalpref.itb]]
-set auto_index(::GlobalPref::_ok) [list source [file join $dir globalpref.itb]]
-set auto_index(::GlobalPref::_apply) [list source [file join $dir globalpref.itb]]
-set auto_index(::GlobalPref::_cancel) [list source [file join $dir globalpref.itb]]
+set auto_index(::GlobalPref::build_win) [list source [file join $dir globalpref.itb]]
+set auto_index(::GlobalPref::make_font_item) [list source [file join $dir globalpref.itb]]
+set auto_index(::GlobalPref::resize_font_item_height) [list source [file join $dir globalpref.itb]]
+set auto_index(::GlobalPref::change_icons) [list source [file join $dir globalpref.itb]]
+set auto_index(::GlobalPref::wfont_changed) [list source [file join $dir globalpref.itb]]
+set auto_index(::GlobalPref::font_changed) [list source [file join $dir globalpref.itb]]
+set auto_index(::GlobalPref::toggle_tracing_mode) [list source [file join $dir globalpref.itb]]
+set auto_index(::GlobalPref::toggle_tracing) [list source [file join $dir globalpref.itb]]
+set auto_index(::GlobalPref::ok) [list source [file join $dir globalpref.itb]]
+set auto_index(::GlobalPref::apply) [list source [file join $dir globalpref.itb]]
set auto_index(::GlobalPref::cancel) [list source [file join $dir globalpref.itb]]
-set auto_index(::IPCPref::constructor) [list source [file join $dir ipcpref.itb]]
-set auto_index(::IPCPref::_init_var) [list source [file join $dir ipcpref.itb]]
-set auto_index(::IPCPref::_build_win) [list source [file join $dir ipcpref.itb]]
-set auto_index(::IPCPref::_apply) [list source [file join $dir ipcpref.itb]]
-set auto_index(::IPCPref::_cancel) [list source [file join $dir ipcpref.itb]]
-set auto_index(::IPCPref::_save) [list source [file join $dir ipcpref.itb]]
+set auto_index(::HtmlViewer::constructor) [list source [file join $dir helpviewer.itb]]
+set auto_index(::HtmlViewer::_buildwin) [list source [file join $dir helpviewer.itb]]
+set auto_index(::PageStack::push) [list source [file join $dir helpviewer.itb]]
+set auto_index(::PageStack::back) [list source [file join $dir helpviewer.itb]]
+set auto_index(::PageStack::next) [list source [file join $dir helpviewer.itb]]
+set auto_index(::PageStack::more) [list source [file join $dir helpviewer.itb]]
+set auto_index(::PageStack::less) [list source [file join $dir helpviewer.itb]]
+set auto_index(::PageStack::current) [list source [file join $dir helpviewer.itb]]
+set auto_index(::HtmlViewer::_enable) [list source [file join $dir helpviewer.itb]]
+set auto_index(::HtmlViewer::back) [list source [file join $dir helpviewer.itb]]
+set auto_index(::HtmlViewer::forward) [list source [file join $dir helpviewer.itb]]
+set auto_index(::HtmlViewer::link) [list source [file join $dir helpviewer.itb]]
+set auto_index(::HtmlViewer::load) [list source [file join $dir helpviewer.itb]]
+set auto_index(::HtmlViewer::open_help) [list source [file join $dir helpviewer.itb]]
set auto_index(::KodWin::constructor) [list source [file join $dir kod.itb]]
set auto_index(::KodWin::build_win) [list source [file join $dir kod.itb]]
set auto_index(::KodWin::update) [list source [file join $dir kod.itb]]
@@ -350,32 +298,28 @@ set auto_index(::KodWin::clear) [list source [file join $dir kod.itb]]
set auto_index(::KodWin::top) [list source [file join $dir kod.itb]]
set auto_index(::KodWin::up) [list source [file join $dir kod.itb]]
set auto_index(::KodWin::destructor) [list source [file join $dir kod.itb]]
-set auto_index(::KodWin::set_variable) [list source [file join $dir kod.itb]]
+set auto_index(::KodWin::set_os) [list source [file join $dir kod.itb]]
set auto_index(::KodWin::reconfig) [list source [file join $dir kod.itb]]
set auto_index(::KodWin::busy) [list source [file join $dir kod.itb]]
set auto_index(::KodWin::idle) [list source [file join $dir kod.itb]]
set auto_index(::KodWin::cursor) [list source [file join $dir kod.itb]]
set auto_index(::KodWin::_disable_buttons) [list source [file join $dir kod.itb]]
set auto_index(::KodWin::_restore_buttons) [list source [file join $dir kod.itb]]
-set auto_index(::ManagedWin::constructor) [list source [file join $dir managedwin.itb]]
-set auto_index(::ManagedWin::destructor) [list source [file join $dir managedwin.itb]]
+set auto_index(::ManagedWin::reconfig) [list source [file join $dir managedwin.itb]]
set auto_index(::ManagedWin::window_name) [list source [file join $dir managedwin.itb]]
-set auto_index(::ManagedWin::window_instance) [list source [file join $dir managedwin.itb]]
-set auto_index(::ManagedWin::pickle) [list source [file join $dir managedwin.itb]]
set auto_index(::ManagedWin::reveal) [list source [file join $dir managedwin.itb]]
set auto_index(::ManagedWin::restart) [list source [file join $dir managedwin.itb]]
-set auto_index(::ManagedWin::shutdown) [list source [file join $dir managedwin.itb]]
-set auto_index(::ManagedWin::startup) [list source [file join $dir managedwin.itb]]
set auto_index(::ManagedWin::open_dlg) [list source [file join $dir managedwin.itb]]
set auto_index(::ManagedWin::open) [list source [file join $dir managedwin.itb]]
set auto_index(::ManagedWin::_open) [list source [file join $dir managedwin.itb]]
set auto_index(::ManagedWin::_create) [list source [file join $dir managedwin.itb]]
set auto_index(::ManagedWin::find) [list source [file join $dir managedwin.itb]]
+set auto_index(::ManagedWin::enable) [list source [file join $dir managedwin.itb]]
set auto_index(::ManagedWin::init) [list source [file join $dir managedwin.itb]]
set auto_index(::ManagedWin::destroy_toplevel) [list source [file join $dir managedwin.itb]]
-set auto_index(::ManagedWin::_freeze_me) [list source [file join $dir managedwin.itb]]
-set auto_index(::ManagedWin::_thaw_me) [list source [file join $dir managedwin.itb]]
-set auto_index(::ManagedWin::_make_icon_window) [list source [file join $dir managedwin.itb]]
+set auto_index(::ManagedWin::freeze_me) [list source [file join $dir managedwin.itb]]
+set auto_index(::ManagedWin::thaw_me) [list source [file join $dir managedwin.itb]]
+set auto_index(::ManagedWin::make_icon_window) [list source [file join $dir managedwin.itb]]
set auto_index(::MemPref::constructor) [list source [file join $dir mempref.itb]]
set auto_index(::MemPref::destructor) [list source [file join $dir mempref.itb]]
set auto_index(::MemPref::build_win) [list source [file join $dir mempref.itb]]
@@ -404,7 +348,6 @@ set auto_index(::MemWin::update) [list source [file join $dir memwin.itb]]
set auto_index(::MemWin::idle) [list source [file join $dir memwin.itb]]
set auto_index(::MemWin::busy) [list source [file join $dir memwin.itb]]
set auto_index(::MemWin::newsize) [list source [file join $dir memwin.itb]]
-set auto_index(::MemWin::_update_address) [list source [file join $dir memwin.itb]]
set auto_index(::MemWin::update_address_cb) [list source [file join $dir memwin.itb]]
set auto_index(::MemWin::update_address) [list source [file join $dir memwin.itb]]
set auto_index(::MemWin::BadExpr) [list source [file join $dir memwin.itb]]
@@ -417,7 +360,6 @@ set auto_index(::MemWin::goto) [list source [file join $dir memwin.itb]]
set auto_index(::MemWin::init_addr_exp) [list source [file join $dir memwin.itb]]
set auto_index(::MemWin::cursor) [list source [file join $dir memwin.itb]]
set auto_index(::MemWin::memMoveCell) [list source [file join $dir memwin.itb]]
-set auto_index(::MemWin::error_dialog) [list source [file join $dir memwin.itb]]
set auto_index(::ProcessWin::constructor) [list source [file join $dir process.itb]]
set auto_index(::ProcessWin::build_win) [list source [file join $dir process.itb]]
set auto_index(::ProcessWin::update) [list source [file join $dir process.itb]]
@@ -429,39 +371,34 @@ set auto_index(::ProcessWin::idle) [list source [file join $dir process.itb]]
set auto_index(::ProcessWin::cursor) [list source [file join $dir process.itb]]
set auto_index(::RegWin::constructor) [list source [file join $dir regwin.itb]]
set auto_index(::RegWin::destructor) [list source [file join $dir regwin.itb]]
-set auto_index(::RegWin::_load_prefs) [list source [file join $dir regwin.itb]]
-set auto_index(::RegWin::_build_win) [list source [file join $dir regwin.itb]]
-set auto_index(::RegWin::_layout_table) [list source [file join $dir regwin.itb]]
-set auto_index(::RegWin::_size_cell_column) [list source [file join $dir regwin.itb]]
-set auto_index(::RegWin::_size_column) [list source [file join $dir regwin.itb]]
+set auto_index(::RegWin::build_win) [list source [file join $dir regwin.itb]]
+set auto_index(::RegWin::init_reg_display_vars) [list source [file join $dir regwin.itb]]
+set auto_index(::RegWin::handle_set_hook) [list source [file join $dir regwin.itb]]
+set auto_index(::RegWin::disassembly_changed) [list source [file join $dir regwin.itb]]
+set auto_index(::RegWin::save_reg_display_vars) [list source [file join $dir regwin.itb]]
+set auto_index(::RegWin::reg_select_up) [list source [file join $dir regwin.itb]]
+set auto_index(::RegWin::reg_select_down) [list source [file join $dir regwin.itb]]
+set auto_index(::RegWin::reg_select_right) [list source [file join $dir regwin.itb]]
+set auto_index(::RegWin::reg_select_left) [list source [file join $dir regwin.itb]]
+set auto_index(::RegWin::reg_select) [list source [file join $dir regwin.itb]]
+set auto_index(::RegWin::dimensions) [list source [file join $dir regwin.itb]]
+set auto_index(::RegWin::fixLength) [list source [file join $dir regwin.itb]]
+set auto_index(::RegWin::but3) [list source [file join $dir regwin.itb]]
+set auto_index(::RegWin::display_all) [list source [file join $dir regwin.itb]]
+set auto_index(::RegWin::delete_from_display_list) [list source [file join $dir regwin.itb]]
+set auto_index(::RegWin::edit) [list source [file join $dir regwin.itb]]
+set auto_index(::RegWin::acceptEdit) [list source [file join $dir regwin.itb]]
+set auto_index(::RegWin::unedit) [list source [file join $dir regwin.itb]]
+set auto_index(::RegWin::update) [list source [file join $dir regwin.itb]]
+set auto_index(::RegWin::idle) [list source [file join $dir regwin.itb]]
set auto_index(::RegWin::reconfig) [list source [file join $dir regwin.itb]]
-set auto_index(::RegWin::_accept_edit) [list source [file join $dir regwin.itb]]
-set auto_index(::RegWin::_add_to_watch) [list source [file join $dir regwin.itb]]
-set auto_index(::RegWin::_open_memory) [list source [file join $dir regwin.itb]]
-set auto_index(::RegWin::_but3) [list source [file join $dir regwin.itb]]
-set auto_index(::RegWin::_delete_from_display) [list source [file join $dir regwin.itb]]
-set auto_index(::RegWin::_display_all) [list source [file join $dir regwin.itb]]
-set auto_index(::RegWin::_edit) [list source [file join $dir regwin.itb]]
-set auto_index(::RegWin::_move) [list source [file join $dir regwin.itb]]
-set auto_index(::RegWin::_select_cell) [list source [file join $dir regwin.itb]]
-set auto_index(::RegWin::_unedit) [list source [file join $dir regwin.itb]]
-set auto_index(::RegWin::_get_value) [list source [file join $dir regwin.itb]]
-set auto_index(::RegWin::_change_format) [list source [file join $dir regwin.itb]]
-set auto_index(::RegWin::_update_register) [list source [file join $dir regwin.itb]]
-set auto_index(::RegWin::_select_group) [list source [file join $dir regwin.itb]]
-set auto_index(::RegWin::arch_changed) [list source [file join $dir regwin.itb]]
set auto_index(::RegWin::busy) [list source [file join $dir regwin.itb]]
-set auto_index(::RegWin::idle) [list source [file join $dir regwin.itb]]
-set auto_index(::RegWin::set_variable) [list source [file join $dir regwin.itb]]
-set auto_index(::RegWin::update) [list source [file join $dir regwin.itb]]
set auto_index(::SrcPref::constructor) [list source [file join $dir srcpref.itb]]
-set auto_index(::SrcPref::_init_var) [list source [file join $dir srcpref.itb]]
-set auto_index(::SrcPref::_build_win) [list source [file join $dir srcpref.itb]]
+set auto_index(::SrcPref::build_win) [list source [file join $dir srcpref.itb]]
set auto_index(::SrcPref::_apply) [list source [file join $dir srcpref.itb]]
-set auto_index(::SrcPref::cancel) [list source [file join $dir srcpref.itb]]
set auto_index(::SrcPref::_cancel) [list source [file join $dir srcpref.itb]]
set auto_index(::SrcPref::_save) [list source [file join $dir srcpref.itb]]
-set auto_index(::SrcPref::_set_flavor) [list source [file join $dir srcpref.itb]]
+set auto_index(::SrcPref::set_flavor) [list source [file join $dir srcpref.itb]]
set auto_index(::SrcPref::_pick) [list source [file join $dir srcpref.itb]]
set auto_index(::SrcTextWin::constructor) [list source [file join $dir srctextwin.itb]]
set auto_index(::SrcTextWin::destructor) [list source [file join $dir srctextwin.itb]]
@@ -476,7 +413,7 @@ set auto_index(::SrcTextWin::setTabs) [list source [file join $dir srctextwin.it
set auto_index(::SrcTextWin::enable_disable_src_tags) [list source [file join $dir srctextwin.itb]]
set auto_index(::SrcTextWin::config_win) [list source [file join $dir srctextwin.itb]]
set auto_index(::SrcTextWin::addPopup) [list source [file join $dir srctextwin.itb]]
-set auto_index(::SrcTextWin::set_variable) [list source [file join $dir srctextwin.itb]]
+set auto_index(::SrcTextWin::handle_set_hook) [list source [file join $dir srctextwin.itb]]
set auto_index(::SrcTextWin::disassembly_changed) [list source [file join $dir srctextwin.itb]]
set auto_index(::SrcTextWin::reconfig) [list source [file join $dir srctextwin.itb]]
set auto_index(::SrcTextWin::updateBalloon) [list source [file join $dir srctextwin.itb]]
@@ -486,16 +423,12 @@ set auto_index(::SrcTextWin::_mtime_changed) [list source [file join $dir srctex
set auto_index(::SrcTextWin::FillSource) [list source [file join $dir srctextwin.itb]]
set auto_index(::SrcTextWin::FillAssembly) [list source [file join $dir srctextwin.itb]]
set auto_index(::SrcTextWin::FillMixed) [list source [file join $dir srctextwin.itb]]
-set auto_index(::SrcTextWin::_highlightAsmLine) [list source [file join $dir srctextwin.itb]]
-set auto_index(::SrcTextWin::set_tag_to_stack) [list source [file join $dir srctextwin.itb]]
set auto_index(::SrcTextWin::location) [list source [file join $dir srctextwin.itb]]
set auto_index(::SrcTextWin::LoadFile) [list source [file join $dir srctextwin.itb]]
set auto_index(::SrcTextWin::display_line) [list source [file join $dir srctextwin.itb]]
set auto_index(::SrcTextWin::display_breaks) [list source [file join $dir srctextwin.itb]]
set auto_index(::SrcTextWin::insertBreakTag) [list source [file join $dir srctextwin.itb]]
set auto_index(::SrcTextWin::removeBreakTag) [list source [file join $dir srctextwin.itb]]
-set auto_index(::SrcTextWin::breakpoint) [list source [file join $dir srctextwin.itb]]
-set auto_index(::SrcTextWin::tracepoint) [list source [file join $dir srctextwin.itb]]
set auto_index(::SrcTextWin::bp) [list source [file join $dir srctextwin.itb]]
set auto_index(::SrcTextWin::do_bp) [list source [file join $dir srctextwin.itb]]
set auto_index(::SrcTextWin::hasBP) [list source [file join $dir srctextwin.itb]]
@@ -503,9 +436,7 @@ set auto_index(::SrcTextWin::hasTP) [list source [file join $dir srctextwin.itb]
set auto_index(::SrcTextWin::report_source_location) [list source [file join $dir srctextwin.itb]]
set auto_index(::SrcTextWin::lookup_line) [list source [file join $dir srctextwin.itb]]
set auto_index(::SrcTextWin::continue_to_here) [list source [file join $dir srctextwin.itb]]
-set auto_index(::SrcTextWin::jump_to_here) [list source [file join $dir srctextwin.itb]]
set auto_index(::SrcTextWin::set_bp_at_line) [list source [file join $dir srctextwin.itb]]
-set auto_index(::SrcTextWin::enable_disable_at_line) [list source [file join $dir srctextwin.itb]]
set auto_index(::SrcTextWin::remove_bp_at_line) [list source [file join $dir srctextwin.itb]]
set auto_index(::SrcTextWin::set_tp_at_line) [list source [file join $dir srctextwin.itb]]
set auto_index(::SrcTextWin::next_hit_at_line) [list source [file join $dir srctextwin.itb]]
@@ -531,7 +462,6 @@ set auto_index(::SrcTextWin::print) [list source [file join $dir srctextwin.itb]
set auto_index(::SrcTextWin::ask_thread_bp) [list source [file join $dir srctextwin.itb]]
set auto_index(::SrcTextWin::do_thread_bp) [list source [file join $dir srctextwin.itb]]
set auto_index(::SrcTextWin::test_get) [list source [file join $dir srctextwin.itb]]
-set auto_index(::SrcTextWin::get_file) [list source [file join $dir srctextwin.itb]]
set auto_index(::SrcTextWin::clear_file) [list source [file join $dir srctextwin.itb]]
set auto_index(::SrcTextWin::_initialize_srctextwin) [list source [file join $dir srctextwin.itb]]
set auto_index(::SrcTextWin::_clear_cache) [list source [file join $dir srctextwin.itb]]
@@ -548,12 +478,11 @@ set auto_index(::SrcWin::fillNameCB) [list source [file join $dir srcwin.itb]]
set auto_index(::SrcWin::fillFuncCB) [list source [file join $dir srcwin.itb]]
set auto_index(::SrcWin::location) [list source [file join $dir srcwin.itb]]
set auto_index(::SrcWin::stack) [list source [file join $dir srcwin.itb]]
-set auto_index(::SrcWin::_update) [list source [file join $dir srcwin.itb]]
+set auto_index(::SrcWin::update) [list source [file join $dir srcwin.itb]]
set auto_index(::SrcWin::idle) [list source [file join $dir srcwin.itb]]
set auto_index(::SrcWin::mode) [list source [file join $dir srcwin.itb]]
set auto_index(::SrcWin::_update_title) [list source [file join $dir srcwin.itb]]
set auto_index(::SrcWin::busy) [list source [file join $dir srcwin.itb]]
-set auto_index(::SrcWin::update) [list source [file join $dir srcwin.itb]]
set auto_index(::SrcWin::_set_name) [list source [file join $dir srcwin.itb]]
set auto_index(::SrcWin::set_status) [list source [file join $dir srcwin.itb]]
set auto_index(::SrcWin::set_execution_status) [list source [file join $dir srcwin.itb]]
@@ -562,20 +491,13 @@ set auto_index(::SrcWin::print) [list source [file join $dir srcwin.itb]]
set auto_index(::SrcWin::enable_ui) [list source [file join $dir srcwin.itb]]
set auto_index(::SrcWin::no_inferior) [list source [file join $dir srcwin.itb]]
set auto_index(::SrcWin::reset) [list source [file join $dir srcwin.itb]]
-set auto_index(::SrcWin::search) [list source [file join $dir srcwin.itb]]
+set auto_index(::SrcWin::_search) [list source [file join $dir srcwin.itb]]
set auto_index(::SrcWin::point_to_main) [list source [file join $dir srcwin.itb]]
set auto_index(::SrcWin::_exit) [list source [file join $dir srcwin.itb]]
set auto_index(::SrcWin::test_get) [list source [file join $dir srcwin.itb]]
set auto_index(::SrcWin::toolbar) [list source [file join $dir srcwin.itb]]
set auto_index(::SrcWin::inferior) [list source [file join $dir srcwin.itb]]
set auto_index(::SrcWin::clear_file) [list source [file join $dir srcwin.itb]]
-set auto_index(::SrcWin::get_file) [list source [file join $dir srcwin.itb]]
-set auto_index(::SrcWin::is_fixed) [list source [file join $dir srcwin.itb]]
-set auto_index(::SrcWin::get_top) [list source [file join $dir srcwin.itb]]
-set auto_index(::SrcWin::_set_tag_to_stack) [list source [file join $dir srcwin.itb]]
-set auto_index(::SrcWin::_choose_window) [list source [file join $dir srcwin.itb]]
-set auto_index(::SrcWin::choose_and_update) [list source [file join $dir srcwin.itb]]
-set auto_index(::SrcWin::choose_and_display) [list source [file join $dir srcwin.itb]]
set auto_index(::StackWin::constructor) [list source [file join $dir stackwin.itb]]
set auto_index(::StackWin::destructor) [list source [file join $dir stackwin.itb]]
set auto_index(::StackWin::build_win) [list source [file join $dir stackwin.itb]]
@@ -614,26 +536,3 @@ set auto_index(::TargetSelection::set_run) [list source [file join $dir targetse
set auto_index(::TargetSelection::target_trace) [list source [file join $dir targetselection.itb]]
set auto_index(::TargetSelection::valid_target) [list source [file join $dir targetselection.itb]]
set auto_index(::TargetSelection::native_debugging) [list source [file join $dir targetselection.itb]]
-set auto_index(::VarTree::constructor) [list source [file join $dir vartree.itb]]
-set auto_index(::VarTree::destructor) [list source [file join $dir vartree.itb]]
-set auto_index(::VarTree::build) [list source [file join $dir vartree.itb]]
-set auto_index(::VarTree::buildlayer) [list source [file join $dir vartree.itb]]
-set auto_index(::VarTree::add) [list source [file join $dir vartree.itb]]
-set auto_index(::VarTree::remove) [list source [file join $dir vartree.itb]]
-set auto_index(::VarTree::update_var) [list source [file join $dir vartree.itb]]
-set auto_index(::VarTree::update) [list source [file join $dir vartree.itb]]
-set auto_index(::VarTree::drawselection) [list source [file join $dir vartree.itb]]
-set auto_index(::VarTree::clicked) [list source [file join $dir vartree.itb]]
-set auto_index(::VarTree::setselection) [list source [file join $dir vartree.itb]]
-set auto_index(::VarTree::closed) [list source [file join $dir vartree.itb]]
-set auto_index(::VarTree::open) [list source [file join $dir vartree.itb]]
-set auto_index(::VarTree::close) [list source [file join $dir vartree.itb]]
-set auto_index(::VarTree::edit) [list source [file join $dir vartree.itb]]
-set auto_index(::VarTree::unedit) [list source [file join $dir vartree.itb]]
-set auto_index(::VarTree::changeValue) [list source [file join $dir vartree.itb]]
-set auto_index(::VarTree::_change_format) [list source [file join $dir vartree.itb]]
-set auto_index(::VarTree::_but3) [list source [file join $dir vartree.itb]]
-set auto_index(::VarTree::_do_default_menu) [list source [file join $dir vartree.itb]]
-set auto_index(::VarTree::_sort) [list source [file join $dir vartree.itb]]
-set auto_index(::VarTree::_compare) [list source [file join $dir vartree.itb]]
-set auto_index(::VarTree::_init_data) [list source [file join $dir vartree.itb]]
diff --git a/gdb/gdbtk/library/tdump.tcl b/gdb/gdbtk/library/tdump.tcl
index 9086d2223bf..94c1310457c 100644
--- a/gdb/gdbtk/library/tdump.tcl
+++ b/gdb/gdbtk/library/tdump.tcl
@@ -1,5 +1,5 @@
-# Trace dump window for Insight
-# Copyright (C) 1998, 1999, 2001, 2002, 2004, 2008 Red Hat, Inc.
+# Trace dump window for GDBtk.
+# Copyright 1998, 1999 Cygnus Solutions
#
# This program is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License (GPL) as published by
@@ -28,16 +28,29 @@
#
# ----------------------------------------------------------------------
-itcl::class TdumpWin {
- inherit ManagedWin GDBWin
-
+itcl_class TdumpWin {
# ------------------------------------------------------------------
# CONSTRUCTOR - create new tdump window
# ------------------------------------------------------------------
- constructor {args} {
- window_name "Trace Dump"
+ constructor {config} {
+ #
+ # Create a window with the same name as this object
+ #
+ set class [$this info class]
+ set hull [namespace tail $this]
+ set old_name $this
+ ::rename $this $this-tmp-
+ ::frame $hull -class $class
+ ::rename $hull $old_name-win-
+ ::rename $this $old_name
+
+ set top [winfo toplevel [namespace tail $this]]
+ wm withdraw $top
+
build_win
- eval itk_initialize $args
+ add_hook gdb_update_hook "$this update"
+ after idle [list wm deiconify $top]
+
}
@@ -45,29 +58,29 @@ itcl::class TdumpWin {
# METHOD: build_win - build the main tdump window
# ------------------------------------------------------------------
method build_win {} {
- itk_component add stext {
- iwidgets::scrolledtext $itk_interior.stext -hscrollmode dynamic \
- -vscrollmode dynamic -textfont global/fixed \
- -background $::Colors(bg)
- } {}
- [$itk_component(stext) component text] configure \
- -background $::Colors(bg)
- pack $itk_component(stext) -side left -expand yes -fill both
- update dummy
+
+ tixScrolledText [namespace tail $this].stext -scrollbar y -height 200 -width 500
+ set twin [[namespace tail $this].stext subwidget text]
+
+ # make window non editable
+ $twin configure -insertwidth 0
+
+ pack append [namespace tail $this] [namespace tail $this].stext {left expand fill}
+ update
}
# ------------------------------------------------------------------
# METHOD: update - update widget when PC changes
# ------------------------------------------------------------------
- method update {event} {
+ method update {} {
#debug "tdump: update"
gdbtk_busy
set tframe_num [gdb_get_trace_frame_num]
if { $tframe_num!=-1 } {
debug "doing tdump"
- $itk_component(stext) delete 1.0 end
+ $twin delete 1.0 end
if {[catch {gdb_cmd "tdump $tframe_num" 0} tdump_output]} {
tk_messageBox -title "Error" -message $tdump_output -icon error \
@@ -75,19 +88,38 @@ itcl::class TdumpWin {
} else {
#debug "tdum output is $tdump_output"
- $itk_component(stext) insert end $tdump_output
- $itk_component(stext) see insert
+ $twin insert end $tdump_output
+ $twin see insert
}
}
gdbtk_idle
}
# ------------------------------------------------------------------
+ # DESTRUCTOR - destroy window containing widget
+ # ------------------------------------------------------------------
+ destructor {
+ remove_hook gdb_update_hook "$this update"
+ set top [winfo toplevel [namespace tail $this]]
+ destroy $this
+ destroy $top
+ }
+
+ # ------------------------------------------------------------------
+ # METHOD: config - used to change public attributes
+ # ------------------------------------------------------------------
+ method config {config} {}
+
+ # ------------------------------------------------------------------
# METHOD: reconfig - used when preferences change
# ------------------------------------------------------------------
method reconfig {} {
- if {[winfo exists $itk_interior.stext]} { destroy $itk_interior.stext }
- build_win
}
+
+ #
+ # PROTECTED DATA
+ #
+ protected maxwidth 0
+ protected twin
}
diff --git a/gdb/gdbtk/library/tfind_args.tcl b/gdb/gdbtk/library/tfind_args.tcl
index 67e00e7ed54..d90447a65a2 100644
--- a/gdb/gdbtk/library/tfind_args.tcl
+++ b/gdb/gdbtk/library/tfind_args.tcl
@@ -1,5 +1,5 @@
# TfindArgs
-# Copyright (C) 1998, 1999 Cygnus Solutions
+# Copyright 1998, 1999 Cygnus Solutions
#
# This program is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License (GPL) as published by
diff --git a/gdb/gdbtk/library/toolbar.tcl b/gdb/gdbtk/library/toolbar.tcl
new file mode 100644
index 00000000000..592058907b2
--- /dev/null
+++ b/gdb/gdbtk/library/toolbar.tcl
@@ -0,0 +1,845 @@
+# Menu, toolbar, and status window for GDBtk.
+# Copyright 1997, 1998, 1999 Cygnus Solutions
+#
+# This program is free software; you can redistribute it and/or modify it
+# under the terms of the GNU General Public License (GPL) as published by
+# the Free Software Foundation; either version 2 of the License, or (at
+# your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+
+
+# Implements a menu, toolbar, and status window for GDB
+# This class has methods for adding buttons & menus, and
+# a collection of methods for the standard GDB menu sets
+# and button sets. It does not actually add any buttons or
+# menus on its own, however.
+
+class GDBToolBar {
+ inherit itk::Widget
+
+ # ------------------------------------------------------------------
+ # CONSTRUCTOR - create new console window
+ # ------------------------------------------------------------------
+ constructor {src} {
+ set source $src
+ _load_images
+ _load_src_images
+
+ build_win
+ add_hook gdb_idle_hook "$this enable_ui 1"
+ add_hook gdb_busy_hook "$this enable_ui 0"
+ add_hook gdb_no_inferior_hook "$this enable_ui 2"
+ add_hook gdb_set_hook "$this set_hook"
+ }
+
+ # ------------------------------------------------------------------
+ # METHOD: build_win - build the main toolbar window
+ # ------------------------------------------------------------------
+ public method build_win {} {
+
+ set OtherMenus {}
+ set ControlMenus {}
+ set OtherButtons {}
+ set ControlButtons {}
+
+ set Menu [menu $itk_interior.m -tearoff 0]
+ if {! [create_menu_items]} {
+ destroy $Menu
+ set Menu {}
+ } else {
+ [winfo toplevel $itk_interior] configure -menu $Menu
+ }
+
+ # Make a subframe so that the menu can't accidentally conflict
+ # with a name created by some subclass.
+ set ButtonFrame [frame $itk_interior.t]
+ create_buttons
+
+ if {! [llength $button_list]} {
+ destroy $ButtonFrame
+ } else {
+ eval standard_toolbar $ButtonFrame $button_list
+ pack $ButtonFrame $itk_interior -fill both -expand true
+ }
+ }
+
+ # ------------------------------------------------------------------
+ # DESTRUCTOR - destroy window containing widget
+ # ------------------------------------------------------------------
+ destructor {
+ remove_hook gdb_idle_hook "$this enable_ui 1"
+ remove_hook gdb_busy_hook "$this enable_ui 0"
+ remove_hook gdb_no_inferior_hook "$this enable_ui 2"
+ remove_hook gdb_set_hook "$this set_hook"
+ #destroy $this
+ }
+
+ # ------------------------------------------------------------------
+ # METHOD: reconfig - used when preferences change
+ # ------------------------------------------------------------------
+ public method reconfig {} {
+ debug "toolbar::reconfig"
+ _load_images 1
+ }
+
+ public method _set_stepi {} {
+ }
+
+ # ------------------------------------------------------------------
+ # METHOD: create_buttons - Add some buttons to the toolbar. Returns
+ # list of buttons in form acceptable to
+ # standard_toolbar.
+ # ------------------------------------------------------------------
+ public method create_buttons {} {
+ _load_images
+ create_buttons
+ }
+
+ method add_label {name text balloon args} {
+ set lname $ButtonFrame.$name
+ eval label $lname -text \$text $args
+ balloon register $lname $balloon
+ lappend button_list $lname
+ }
+
+
+ # ------------------------------------------------------------------
+ # METHOD: create_button - Creates all the bookkeeping for a button,
+ # without actually inserting it in the toolbar.
+ # ------------------------------------------------------------------
+ method create_button {name class command balloon args} {
+ set bname $ButtonFrame.$name
+ set Buttons($name) $bname
+
+ eval button $bname -command \$command $args
+ balloon register $bname $balloon
+ foreach elem $class {
+ switch $elem {
+ None {}
+ default {
+ lappend ${elem}Buttons $bname
+ }
+ }
+ }
+
+ return $bname
+ }
+
+ # ------------------------------------------------------------------
+ # METHOD: add_button - Creates a button, and inserts it at the end
+ # of the button list. Call this when the toolbar is being
+ # set up, but has not yet been made.
+ # ------------------------------------------------------------------
+ method add_button {name class command balloon args} {
+
+ lappend button_list [eval create_button \$name \$class \$command \$balloon $args]
+
+ }
+
+ # ------------------------------------------------------------------
+ # METHOD: insert_button - Inserts button "name" before button "before".
+ # the toolbar must be made, and the buttons must have been created
+ # before you run this.
+ # ------------------------------------------------------------------
+ method insert_button {name before} {
+
+ if {[string first "-" $name] == 0} {
+ set name [string range $name 1 end]
+ set add_sep 1
+ } else {
+ set add_sep 0
+ }
+
+ if {![info exists Buttons($name)] || ![info exists Buttons($before)]} {
+ error "insert_buttons called with non-existant button"
+ }
+
+ set before_col [gridCGet $Buttons($before) -column]
+ set before_row [gridCGet $Buttons($before) -row]
+
+ set slaves [grid slaves $ButtonFrame]
+
+ set incr [expr 1 + $add_sep]
+ foreach slave $slaves {
+ set slave_col [gridCGet $slave -column]
+ if {$slave_col >= $before_col} {
+ grid configure $slave -column [expr $slave_col + $incr]
+ }
+ }
+ if {$add_sep} {
+ grid $Buttons(-$name) -column $before_col -row $before_row
+ }
+
+ # Now grid our button. Have to put in the pady since this button
+ # may not have been originally inserted by the libgui toolbar
+ # proc.
+
+ grid $Buttons($name) -column [expr $before_col + $add_sep] \
+ -row $before_row -pady 2
+
+ }
+
+ method remove_button {name} {
+
+ if {[string first "-" $name] == 0} {
+ set name [string range $name 1 end]
+ set remove_sep 1
+ } else {
+ set remove_sep 0
+ }
+
+ if {![info exists Buttons($name)] } {
+ error "remove_buttons called with non-existant button $name"
+ }
+
+ set name_col [gridCGet $Buttons($name) -column]
+ set name_row [gridCGet $Buttons($name) -row]
+
+ grid remove $Buttons($name)
+ if {$remove_sep} {
+ set Buttons(-$name) [grid slaves $ButtonFrame \
+ -column [expr $name_col - 1] \
+ -row $name_row]
+ grid remove $Buttons(-$name)
+ }
+
+ set slaves [grid slaves $ButtonFrame -row $name_row]
+
+ foreach slave $slaves {
+ set slave_col [gridCGet $slave -column]
+ if {$slave_col > $name_col} {
+ grid configure $slave -column [expr $slave_col - 1]
+ }
+ }
+ }
+
+ method add_button_separator {} {
+ lappend button_list -
+ }
+
+ method button_right_justify {} {
+ lappend button_list --
+ }
+
+ method swap_button_lists {in_list out_list} {
+ # Now swap out the buttons...
+ set first_out [lindex $out_list 0]
+ if {[info exists Buttons($first_out)] && [grid info $Buttons($first_out)] != ""} {
+ foreach button $in_list {
+ insert_button $button $first_out
+ }
+ foreach button $out_list {
+ remove_button $button
+ }
+ } elseif {[info exists Buttons($first_out)]} {
+ debug "Error in swap_button_list - $first_out not gridded..."
+ } else {
+ debug "Button $first_out is not in button list"
+ }
+ }
+
+ ############################################################
+ # The next set of commands control the menubar associated with the
+ # toolbar. Currently, only sequential addition of submenu's and menu
+ # entries is allowed. Here's what you do. First, create a submenu
+ # with the "new_menu" command. This submenu is the targeted menu.
+ # Subsequent calls to add_menu_separator, and add_menu_command add
+ # separators and commands to the end of this submenu.
+ # If you need to edit a submenu, call clear_menu and then add all the
+ # items again.
+ #
+ # Each menu command also has a class list. Transitions between states
+ # of gdb will enable and disable different classes of menus.
+ #
+ # FIXME - support insert_command, and also cascade menus, whenever
+ # we need it...
+ # FIXME - The toolbar and the Menubar support are glommed together in
+ # one class for historical reasons, but there is no good reason for this.
+ ############################################################
+
+ # ------------------------------------------------------------------
+ # METHOD: create_menu_items - Add some menu items to the menubar.
+ # Returns 1 if any items added.
+ #
+ # num = number of last menu entry
+ # ------------------------------------------------------------------
+ method create_menu_items {} {
+ # Empty - This is overridden in child classes.
+ }
+
+ # ------------------------------------------------------------------
+ # METHOD: new_menu - Add a new cascade menu to the Toolbar's main menu.
+ # Also target this menu for subsequent add_menu_command
+ # calls.
+ #
+ # name - the token for the new menu
+ # label - The label used for the label
+ # underline - the index of the underlined character for this menu item.
+ #
+ # RETURNS: then item number of the menu.
+ # ------------------------------------------------------------------
+ method new_menu {name label underline} {
+ set current_menu $Menu.$name
+ set menu_list($name) [$Menu add cascade -menu $current_menu \
+ -label $label -underline $underline]
+ menu $current_menu -tearoff 0
+
+ set item_number -1
+ return $current_menu
+ }
+
+ # ------------------------------------------------------------------
+ # METHOD: menu_exists - Report whether a menu keyed by NAME exists.
+ #
+ # name - the token for the menu sought
+ #
+ # RETURNS: 1 if the menu exists, 0 otherwise.
+ # ------------------------------------------------------------------
+ method menu_exists {name} {
+ return [info exists menu_list($name)]
+
+ }
+
+ # ------------------------------------------------------------------
+ # METHOD: clear_menu - Deletes the items from one of the cascade menus
+ # in the Toolbar's main menu. Also makes this menu
+ # the target menu.
+ #
+ # name - the token for the new menu
+ #
+ # RETURNS: then item number of the menu, or "" if the menu is not found.
+ # ------------------------------------------------------------------
+ method clear_menu {name} {
+ if {[info exists menu_list($name)]} {
+ set current_menu [$Menu entrycget $menu_list($name) -menu]
+ $current_menu delete 0 end
+ set item_number -1
+ return $current_menu
+ } else {
+ return ""
+ }
+ }
+
+
+ # ------------------------------------------------------------------
+ # METHOD: add_menu_separator - Adds a menu separator to the currently
+ # targeted submenu of the Toolbar's main menu.
+ #
+ # ------------------------------------------------------------------
+ method add_menu_separator {} {
+ incr item_number
+ $current_menu add separator
+ }
+
+ # ------------------------------------------------------------------
+ # METHOD: add_menu_command - Adds a menu command item to the currently
+ # targeted submenu of the Toolbar's main menu.
+ #
+ # class - The class of the command, used for disabling entries.
+ # label - The text for the command.
+ # command - The command for the menu entry
+ # args - Passed to the menu entry creation command (eval'ed)
+ # ------------------------------------------------------------------
+ method add_menu_command {class label command args} {
+
+ eval $current_menu add command -label \$label -command \$command \
+ $args
+
+ incr item_number
+
+ switch $class {
+ None {}
+ default {
+ foreach elem $class {
+ lappend menu_classes($elem) [list $current_menu $item_number]
+ }
+ }
+ }
+ }
+
+
+ # ------------------------------------------------------------------
+ # METHOD: _load_images - Load standard images. Private method.
+ # ------------------------------------------------------------------
+ public method _load_images { {reconfig 0} } {
+ global gdb_ImageDir
+ if {!$reconfig && $_loaded_images} {
+ return
+ }
+ set _loaded_images 1
+
+ lappend imgs console reg stack vmake vars watch memory bp
+ foreach name $imgs {
+ image create photo ${name}_img -file [file join $gdb_ImageDir ${name}.gif]
+ }
+ }
+
+
+ # ------------------------------------------------------------------
+ # METHOD: _load_src_images - Load standard images. Private method.
+ # ------------------------------------------------------------------
+ method _load_src_images { {reconf 0} } {
+ global gdb_ImageDir
+
+ if {!$reconf && $_loaded_src_images} {
+ return
+ }
+ set _loaded_src_images 1
+
+ foreach name {run stop step next finish continue edit \
+ stepi nexti up down bottom Movie_on Movie_off \
+ next_line next_check next_hit rewind prev_hit \
+ watch_movie run_expt tdump tp} {
+ image create photo ${name}_img -file [file join $gdb_ImageDir ${name}.gif]
+ }
+ }
+
+ # ------------------------------------------------------------------
+ # METHOD: enable_ui - enable/disable the appropriate buttons and menus
+ # Called from the busy, idle, and no_inferior hooks.
+ #
+ # on must be:
+ # value Control Other Trace State
+ # 0 off off off gdb is busy
+ # 1 on on off gdb has inferior, and is idle
+ # 2 off on off gdb has no inferior, and is idle
+ # ------------------------------------------------------------------
+ public method enable_ui {on} {
+ global tcl_platform
+ debug "Toolbar::enable_ui $on - Browsing=$Browsing"
+
+ # Do the enabling so that all the disabling happens first, this way if a
+ # button belongs to two groups, enabling takes precedence, which is probably right.
+
+ switch $on {
+ 0 {
+ set enable_list {Control disabled \
+ Other disabled \
+ Trace disabled \
+ Attach disabled \
+ Detach disabled}
+ }
+ 1 {
+ if {!$Browsing} {
+ set enable_list {Trace disabled \
+ Control normal \
+ Other normal \
+ Attach disabled \
+ Detach normal }
+ # set the states of stepi and nexti correctly
+ _set_stepi
+ } else {
+ set enable_list {Control disabled Other normal Trace normal}
+ }
+
+ }
+ 2 {
+ set enable_list {Control disabled \
+ Trace disabled \
+ Other normal \
+ Attach normal \
+ Detach disabled }
+ }
+ default {
+ debug "Unknown type: $on in enable_ui"
+ return
+ }
+ }
+
+ debug "Enable list is: $enable_list"
+ foreach {type state} $enable_list {
+ if {[info exists ${type}Buttons]} {
+ foreach button [set ${type}Buttons] {
+ $button configure -state $state
+ }
+ }
+ if {[info exists menu_classes($type)]} {
+ change_menu_state $menu_classes($type) $state
+ }
+ }
+
+ }
+
+ # ------------------------------------------------------------------
+ # METHOD: change_menu_state - Does the actual job of enabling menus...
+ # Pass normal or disabled for the state.
+ # ------------------------------------------------------------------
+ method change_menu_state {menuList state} {
+
+ foreach elem $menuList {
+ [lindex $elem 0] entryconfigure [lindex $elem 1] -state $state
+ }
+ }
+
+
+ #
+ # The next set of functions are the generic button groups that gdb uses.
+ # Then toolbars that derive from this class can just mix and match
+ # from the standard set as they please.
+ #
+
+ # ------------------------------------------------------------------
+ # METHOD: create_control_buttons - Creates the step, continue, etc buttons.
+ # ------------------------------------------------------------------
+
+ method create_control_buttons {} {
+ add_button step Control [code $source inferior step] \
+ "Step (S)" -image step_img
+
+ add_button next Control [code $source inferior next] \
+ "Next (N)" -image next_img
+
+ add_button finish Control [code $source inferior finish] \
+ "Finish (F)" -image finish_img
+
+ add_button continue Control [code $source inferior continue] \
+ "Continue (C)" -image continue_img
+
+ # A spacer before the assembly-level items looks good. It helps
+ # to indicate that these are somehow different.
+ add_button_separator
+
+ add_button stepi Control [code $source inferior stepi] \
+ "Step Asm Inst (S)" -image stepi_img
+
+ add_button nexti Control [code $source inferior nexti] \
+ "Next Asm Inst (N)" -image nexti_img
+
+ _set_stepi
+
+ set Run_control_buttons {step next finish continue -stepi nexti}
+
+ }
+
+ # ------------------------------------------------------------------
+ # METHOD: create_trace_buttons - Creates the next hit, etc.
+ # ------------------------------------------------------------------
+
+ method create_trace_buttons {{show 0}} {
+
+ if {$show} {
+ set command add_button
+ } else {
+ set command create_button
+ }
+
+ $command tfindstart Trace {tfind_cmd "tfind start"} "First Hit <F>" \
+ -image rewind_img
+
+ $command tfind Trace {tfind_cmd tfind} "Next Hit <N>" -image next_hit_img
+
+ $command tfindprev Trace {tfind_cmd "tfind -"} "Previous Hit <P>" \
+ -image prev_hit_img
+
+ $command tfindline Trace {tfind_cmd "tfind line"} "Next Line Hit <L>" \
+ -image next_line_img
+
+ $command tfindtp Trace { tfind_cmd "tfind tracepoint"} \
+ "Next Hit Here <H>" -image next_check_img
+
+ set Trace_control_buttons {tfindstart tfind tfindprev tfindline tfindtp}
+
+ # This is a bit of a hack, but I need to bind the standard_toolbar bindings
+ # and appearances to these externally, since I am not inserting them in
+ # the original toolbar... Have to add a method to the libgui toolbar to do this.
+
+ if {!$show} {
+ foreach name $Trace_control_buttons {
+ # Make sure the button acts the way we want, not the default Tk
+ # way.
+ set button $Buttons($name)
+ $button configure -takefocus 0 -highlightthickness 0 \
+ -relief flat -borderwidth 1
+ set index [lsearch -exact [bindtags $button] Button]
+ bindtags $button [lreplace [bindtags $button] $index $index \
+ ToolbarButton]
+ }
+ }
+ }
+
+
+ # ------------------------------------------------------------------
+ # METHOD: create_window_buttons - Creates the registers, etc, buttons
+ # ------------------------------------------------------------------
+
+ method create_window_buttons {} {
+ add_button reg Other {ManagedWin::open RegWin} "Registers (Ctrl+R)" -image reg_img
+
+ add_button mem Other {ManagedWin::open MemWin} "Memory (Ctrl+M)" -image memory_img
+
+ add_button stack Other {ManagedWin::open StackWin} "Stack (Ctrl+S)" -image stack_img
+
+ add_button watch Other {ManagedWin::open WatchWin} "Watch Expressions (Ctrl+W)" \
+ -image watch_img
+
+ add_button vars Other {ManagedWin::open LocalsWin} "Local Variables (Ctrl+L)" \
+ -image vars_img
+
+ if {[pref get gdb/control_target]} {
+ add_button bp Other {ManagedWin::open BpWin} "Breakpoints (Ctrl+B)" -image bp_img
+ }
+
+ if {[pref get gdb/mode]} {
+ add_button tp Other {ManagedWin::open BpWin -tracepoints 1} \
+ "Tracepoints (Ctrl+T)" -image tp_img
+
+ add_button tdump Trace {ManagedWin::open TdumpWin} "Tdump (Ctrl+D)" -image tdump_img
+ }
+
+ add_button con Other {ManagedWin::open Console} "Console (Ctrl+N)" \
+ -image console_img
+ }
+
+ #
+ # The next set of functions create the common menu groupings that
+ # are used in gdb menus.
+ #
+
+
+ # ------------------------------------------------------------------
+ # METHOD: create_view_menu - Creates the standard view menu
+ # ------------------------------------------------------------------
+
+ method create_view_menu {} {
+ new_menu view "View" 0
+
+ add_menu_command Other "Stack" {ManagedWin::open StackWin} \
+ -underline 0 -accelerator "Ctrl+S"
+
+ add_menu_command Other "Registers" {ManagedWin::open RegWin} \
+ -underline 0 -accelerator "Ctrl+R"
+
+ add_menu_command Other "Memory" {ManagedWin::open MemWin} \
+ -underline 0 -accelerator "Ctrl+M"
+
+ add_menu_command Other "Watch Expressions" {ManagedWin::open WatchWin} \
+ -underline 0 -accelerator "Ctrl+W"
+ add_menu_command Other "Local Variables" {ManagedWin::open LocalsWin} \
+ -underline 0 -accelerator "Ctrl+L"
+
+ if {[pref get gdb/control_target]} {
+ add_menu_command Other "Breakpoints" \
+ {ManagedWin::open BpWin -tracepoints 0} \
+ -underline 0 -accelerator "Ctrl+B"
+ }
+
+ if {[pref get gdb/mode]} {
+ add_menu_command Other "Tracepoints" \
+ {ManagedWin::open BpWin -tracepoints 1} \
+ -underline 0 -accelerator "Ctrl+T"
+ add_menu_command Other "Tdump" {ManagedWin::open TdumpWin} \
+ -underline 2 -accelerator "Ctrl+U"
+
+ }
+
+ add_menu_command Other "Console" {ManagedWin::open Console} \
+ -underline 2 -accelerator "Ctrl+N"
+
+ add_menu_command Other "Function Browser" {ManagedWin::open BrowserWin} \
+ -underline 1 -accelerator "Ctrl+F"
+ add_menu_command Other "Thread List" {ManagedWin::open ProcessWin} \
+ -underline 0 -accelerator "Ctrl+H"
+ if {[info exists ::env(GDBTK_DEBUG)] && $::env(GDBTK_DEBUG)} {
+ add_menu_separator
+ add_menu_command Other "Debug Window" {ManagedWin::open DebugWin} \
+ -underline 3 -accelerator "Ctrl+U"
+ }
+ }
+
+ # ------------------------------------------------------------------
+ # METHOD: create_control_menu - Creates the standard control menu
+ # ------------------------------------------------------------------
+
+ method create_control_menu {} {
+ new_menu cntrl "Control" 0
+
+ add_menu_command Control "Step" [code $source inferior step] \
+ -underline 0 -accelerator S
+
+ add_menu_command Control "Next" [code $source inferior next] \
+ -underline 0 -accelerator N
+
+ add_menu_command Control "Finish" [code $source inferior finish] \
+ -underline 0 -accelerator F
+
+ add_menu_command Control "Continue" \
+ [code $source inferior continue] \
+ -underline 0 -accelerator C
+
+ add_menu_separator
+ add_menu_command Control "Step Asm Inst" \
+ [code $source inferior stepi] \
+ -underline 1 -accelerator S
+
+ add_menu_command Control "Next Asm Inst" \
+ [code $source inferior nexti] \
+ -underline 1 -accelerator N
+
+ # add_menu_separator
+ # add_menu_command Other "Automatic Step" auto_step
+
+ }
+
+ # ------------------------------------------------------------------
+ # METHOD: create_trace_menu - Creates the standard trace menu
+ # ------------------------------------------------------------------
+
+ method create_trace_menu {} {
+ new_menu trace "Trace" 0
+
+ add_menu_command Other "Save Trace Commands..." "save_trace_commands" \
+ -underline 0
+
+ add_menu_separator
+
+ add_menu_command Trace "Next Hit" {tfind_cmd tfind} \
+ -underline 0 -accelerator N
+
+ add_menu_command Trace "Previous Hit" {tfind_cmd "tfind -"} \
+ -underline 0 -accelerator P
+
+ add_menu_command Trace "First Hit" {tfind_cmd "tfind start"} \
+ -underline 0 -accelerator F
+
+ add_menu_command Trace "Next Line Hit" {tfind_cmd "tfind line"} \
+ -underline 5 -accelerator L
+
+ add_menu_command Trace "Next Hit Here" {tfind_cmd "tfind tracepoint"} \
+ -underline 9 -accelerator H
+
+ add_menu_separator
+ add_menu_command Trace "Tfind Line..." \
+ "ManagedWin::open TfindArgs -Type LN" \
+ -underline 9 -accelerator E
+
+ add_menu_command Trace "Tfind PC..." \
+ "ManagedWin::open TfindArgs -Type PC" \
+ -underline 7 -accelerator C
+
+ add_menu_command Trace "Tfind Tracepoint..." \
+ "ManagedWin::open TfindArgs -Type TP" \
+ -underline 6 -accelerator T
+
+ add_menu_command Trace "Tfind Frame..." \
+ "ManagedWin::open TfindArgs -Type FR" \
+ -underline 6 -accelerator F
+ }
+
+ # ------------------------------------------------------------------
+ # METHOD: create_help_menu - Creates the standard help menu
+ # ------------------------------------------------------------------
+ method create_help_menu {} {
+ new_menu help "Help" 0
+ add_menu_command Other "Help Topics" {HtmlViewer::open_help index.html} \
+ -underline 0
+ add_menu_command Other "Cygnus on the Web" \
+ {open_url http://www.cygnus.com/gnupro/} -underline 14
+ add_menu_separator
+ add_menu_command Other "About GDB..." {ManagedWin::open About -transient} \
+ -underline 0
+ }
+
+ # ------------------------------------------------------------------
+ # METHOD: set_hook - run when user enters a `set' command.
+ # ------------------------------------------------------------------
+ method set_hook {varname value} {
+ debug "Got $varname = $value"
+ if {$varname == "os"} {
+ set save_menu $current_menu
+ set current_menu $Menu.view
+ set title "Kernel Objects"
+ if {[catch {$current_menu index $title} index]} {
+ set index none
+ }
+ if {$value == ""} {
+ # No OS, so remove KOD from View menu.
+ if {$index != "none"} {
+ $current_menu delete $index
+ }
+ } else {
+ # Add KOD to View menu, but only if it isn't already there.
+ if {$index == "none"} {
+ add_menu_command Other $title {ManagedWin::open KodWin} \
+ -underline 0 -accelerator "Ctrl+K"
+ }
+ }
+ set current_menu $save_menu
+
+ global gdb_kod_cmd
+ set gdb_kod_cmd $value
+ }
+ }
+
+ #
+ # PROTECTED DATA
+ #
+
+ #
+ # FIXME - Need to break the images into the sets needed for
+ # each button group, and load them when the button group is
+ # created.
+
+ # This is set if we've already loaded the standard images.
+ private common _loaded_images 0
+
+ # This is set if we've already loaded the standard images. Private
+ # variable.
+ private common _loaded_src_images 0
+
+ #
+ # PUBLIC DATA
+ #
+
+ # This is a handle on our parent source window.
+ protected variable source {}
+
+ public variable Tracing 0 ;# Is tracing enabled for this gdb?
+ public variable Browsing 0 ;# Are we currently browsing a trace experiment?
+ public variable Collecting 0 ;# Are we currently collecting a trace experiment?
+
+ # The list of all control buttons (ones which should be disabled when
+ # not running anything or when inferior is running)
+ protected variable ControlButtons {}
+
+ # The list of all other buttons (which are disabled when inderior is
+ # running)
+ protected variable OtherButtons {}
+
+ # The list of buttons that are enabled when we are in trace browse
+ # mode...
+ protected variable TraceButtons {}
+
+ # This is the list of buttons that are being built up
+ #
+ private variable button_list {}
+
+ #
+ # This is an array of buttons names -> Tk Window names
+ #
+
+ protected variable Buttons
+
+ # The main window's menu
+ private variable Menu
+
+ #The frame to contain the buttons:
+ protected variable ButtonFrame
+
+ # This array holds the menu classes. The key is the class name,
+ # and the value is the list of menus belonging to this class.
+
+ protected variable menu_classes
+
+ # These buttons go in the control area when we are browsing
+ protected variable Trace_control_buttons
+
+ # And these go in the control area when we are running
+ protected variable Run_control_buttons
+
+ protected variable item_number -1
+ protected variable current_menu {}
+}
diff --git a/gdb/gdbtk/library/toplevelwin.ith b/gdb/gdbtk/library/toplevelwin.ith
index 3cd8f93b373..2b947d2a7fe 100644
--- a/gdb/gdbtk/library/toplevelwin.ith
+++ b/gdb/gdbtk/library/toplevelwin.ith
@@ -1,5 +1,5 @@
# TopLevelWin class definition for GDBtk.
-# Copyright (C) 1998, 1999 Cygnus Solutions
+# Copyright 1998, 1999 Cygnus Solutions
#
# This program is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License (GPL) as published by
@@ -12,7 +12,7 @@
# GNU General Public License for more details.
-itcl::class TopLevelWin {
+class TopLevelWin {
inherit ManagedWin
private variable frame ""
diff --git a/gdb/gdbtk/library/tracedlg.tcl b/gdb/gdbtk/library/tracedlg.tcl
index 1a84b41c8b8..3650f715044 100644
--- a/gdb/gdbtk/library/tracedlg.tcl
+++ b/gdb/gdbtk/library/tracedlg.tcl
@@ -1,5 +1,5 @@
-# Trace configuration dialog for Insight
-# Copyright (C) 1997, 1998, 1999, 2001, 2002, 2003 Red Hat, Inc.
+# Trace configuration dialog for GDBtk.
+# Copyright 1997, 1998, 1999 Cygnus Solutions
#
# This program is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License (GPL) as published by
@@ -26,17 +26,28 @@
# either one if a tracepoint was set/edited successfully or zero if
# the user bails out (cancel or destroy buttons).
-itcl::class TraceDlg {
- inherit ManagedWin
-
+itcl_class TraceDlg {
# ------------------------------------------------------------------
# CONSTRUCTOR: create new trace dialog
# ------------------------------------------------------------------
- constructor {args} {
-
- eval itk_initialize $args
- build_win
- title
+ constructor {config} {
+ #
+ # Create a window with the same name as this object
+ #
+ set class [$this info class]
+ set hull [namespace tail $this]
+ set old_name $this
+ ::rename $this $this-tmp-
+ ::frame $hull -class $class
+ ::rename $hull $old_name-win-
+ ::rename $this $old_name
+
+ set top [winfo toplevel [namespace tail $this]]
+ wm withdraw $top
+ build_win $this
+ after idle [list wm deiconify $top]
+ after idle [list $this title]
+# after idle grab $this
}
# ------------------------------------------------------------------
@@ -45,17 +56,21 @@ itcl::class TraceDlg {
destructor {
# Remove this window and all hooks
+# grab release $this
if {$ActionsDlg != ""} {
- catch {delete object $ActionsDlg}
+ catch {manage delete $ActionsDlg}
}
+ set top [winfo toplevel [namespace tail $this]]
+ destroy $top
+ destroy $this
}
# ------------------------------------------------------------------
# METHOD: build_win - build the Trace dialog box (cache this?)
# ------------------------------------------------------------------
- method build_win {} {
+ method build_win {f} {
+ global _TPassCount
- set f $itk_interior
# Need to set the title to either "Add Tracepoint" or "Edit Tracepoint",
# depending on the location of the given tracepoint.
@@ -178,10 +193,10 @@ itcl::class TraceDlg {
# The three frames of this dialog
set bbox [frame $f.bbox]; # for holding OK,CANCEL DELETE buttons
- Labelledframe $f.exp -text "Experiment"
- set exp [$f.exp get_frame]; # the "Experiment" frame
- Labelledframe $f.act -text "Actions"
- set act [$f.act get_frame]; # the "Actions" frame
+ tixLabelFrame $f.exp -label "Experiment"
+ set exp [$f.exp subwidget frame]; # the "Experiment" frame
+ tixLabelFrame $f.act -label "Actions"
+ set act [$f.act subwidget frame]; # the "Actions" frame
# Setup the button box
button $bbox.ok -text OK -command "$this ok" -width 6
@@ -250,7 +265,7 @@ itcl::class TraceDlg {
# Do not allow this until we clean up the action dialog...
tk_messageBox -type ok -icon error \
-message "Cannot set tracepoint ranges across functions!"
- after idle [code delete object $this]
+ after idle manage delete $this
}
#set functions [join $functions ,]
label $exp.funlbl -text {Function:}
@@ -301,21 +316,18 @@ itcl::class TraceDlg {
pack $pass_frame.ent -side right -padx 10 -pady 5
# Actions
- set ActionLB $act_frame.lb
- iwidgets::scrolledlistbox $act_frame.lb -hscrollmode dynamic \
- -vscrollmode dynamic -selectmode multiple -exportselection 0 \
- -dblclickcommand [code $this edit] \
- -selectioncommand [code $this set_delete_action_state $ActionLB $new_frame.del_but] \
- -background $::Colors(bg)
- [$ActionLB component listbox] configure -background $::Colors(bg)
+ tixScrolledListBox $act_frame.lb -scrollbar auto
+ set ActionLB [$act_frame.lb subwidget listbox]
+ $ActionLB configure -selectmode multiple -exportselection 0
label $act_frame.lbl -text {Actions}
pack $act_frame.lbl -side top
pack $act_frame.lb -side bottom -fill both -expand 1 -padx 5 -pady 5
+ $act_frame.lb configure -command "$this edit" \
+ -browsecmd "$this set_delete_action_state $ActionLB $new_frame.del_but"
# New actions
- combobox::combobox $new_frame.combo -maxheight 15 -editable 0 \
- -font global/fixed -command [code $this set_action_type] \
- -bg $::Colors(textbg)
+ combobox::combobox $new_frame.combo -maxheight 15 -editable 0 -font src-font \
+ -command [code $this set_action_type]
$new_frame.combo list insert end collect while-stepping
$new_frame.combo entryset collect
@@ -366,15 +378,15 @@ itcl::class TraceDlg {
#debug "ADDING ACTION FOR $File:[lindex $Lines 0]"
if {$Lines != {}} {
- set ActionsDlg [eval ManagedWin::open ActionDlg -File $File \
+ set ActionsDlg [eval manage create actiondlg -File $File \
-Line [lindex $Lines 0] \
-WhileStepping $whilestepping -Number [lindex $Number 0]\
- -Callback "\\\{$this done\\\}" $step_args]
+ -Callback \"$this done\" $step_args]
} else {
- set ActionsDlg [eval ManagedWin::open ActionDlg -File $File \
+ set ActionsDlg [eval manage create actiondlg -File $File \
-Address [lindex $Addresses 0] \
-WhileStepping $whilestepping -Number [lindex $Number 0]\
- -Callback "\\\{$this done\\\}" $step_args]
+ -Callback \"$this done\" $step_args]
}
}
@@ -449,7 +461,7 @@ itcl::class TraceDlg {
# METHOD: cancel - cancel the dialog and do not set the trace
# ------------------------------------------------------------------
method cancel {} {
- ::delete object $this
+ manage delete $this
}
# ------------------------------------------------------------------
@@ -487,7 +499,7 @@ itcl::class TraceDlg {
set tpnum [gdb_tracepoint_exists "$File:$line"]
if {$tpnum == -1} {
tk_messageBox -type ok -icon error -message "Tracepoint was deleted"
- ::delete object $this
+ manage delete $this
return
}
}
@@ -522,15 +534,14 @@ itcl::class TraceDlg {
continue
}
}
- if {$New == 0 && $Exists == 1} {
- set num [gdb_tracepoint_exists "$File:$Line"]
- if {$num == -1} {
- tk_messageBox -type ok -icon error -message "Tracepoint was deleted"
- ::delete object $this
- return
- }
- }
-
+ if {$New == 0 && $Exists == 1} {
+ set num [gdb_tracepoint_exists "$File:$Line"]
+ if {$num == -1} {
+ tk_messageBox -type ok -icon error -message "Tracepoint was deleted"
+ manage delete $this
+ return
+ }
+ }
#debug "Editing tracepoint \#$Number: $_TPassCount $actions"
set err [catch {gdb_edit_tracepoint $number $_TPassCount $actions} errTxt]
}
@@ -546,7 +557,7 @@ itcl::class TraceDlg {
}
}
- ::delete object $this
+ manage delete $this
}
method cmd {line} {
@@ -557,7 +568,7 @@ itcl::class TraceDlg {
debug "deleting tracepoint $Number"
set err [catch {gdb_cmd "delete tracepoints $Number"} errTxt]
debug "done deleting tracepoint $Number"
- ::delete object $this
+ manage delete $this
}
method get_data {action} {
@@ -624,51 +635,49 @@ itcl::class TraceDlg {
method edit {} {
set Selection [$ActionLB curselection]
- if {$Selection != ""} {
- set action [$ActionLB get $Selection]
- if [regexp "collect" $action] {
- scan $action "collect: %s" data
- set steps 0
- set whilestepping 0
- } elseif [regexp "while-stepping" $action] {
- scan $action "while-stepping (%d): %s" steps data
- set whilestepping 1
- } else {
- debug "unknown action: $action"
- return
- }
+ set action [$ActionLB get $Selection]
+ if [regexp "collect" $action] {
+ scan $action "collect: %s" data
+ set steps 0
+ set whilestepping 0
+ } elseif [regexp "while-stepping" $action] {
+ scan $action "while-stepping (%d): %s" steps data
+ set whilestepping 1
+ } else {
+ debug "unknown action: $action"
+ return
+ }
- set data [split $data ,]
- set len [llength $data]
- set real_data {}
- set special 0
- for {set i 0} {$i < $len} {incr i} {
- set a [lindex $data $i]
- if {[string range $a 0 1] == "\$("} {
- set special 1
- set b $a
- } elseif {$special} {
- lappend b $a
- if {[string index $a [expr {[string length $a]-1}]] == ")"} {
- lappend real_data [join $b ,]
- set special 0
- }
- } else {
- lappend real_data $a
+ set data [split $data ,]
+ set len [llength $data]
+ set real_data {}
+ set special 0
+ for {set i 0} {$i < $len} {incr i} {
+ set a [lindex $data $i]
+ if {[string range $a 0 1] == "\$("} {
+ set special 1
+ set b $a
+ } elseif {$special} {
+ lappend b $a
+ if {[string index $a [expr {[string length $a]-1}]] == ")"} {
+ lappend real_data [join $b ,]
+ set special 0
}
- }
-
- # !! lindex $Lines 0 -- better way?
- if {$Lines != {}} {
- ManagedWin::open ActionDlg -File $File -Line [lindex $Lines 0] \
- -WhileStepping $whilestepping -Number [lindex $Number 0] \
- -Callback [list [code $this done]] -Data $real_data -Steps $steps
} else {
- ManagedWin::open ActionDlg -File $File -Address [lindex $Addresses 0] \
- -WhileStepping $whilestepping -Number [lindex $Number 0] \
- -Callback [list [code $this done]] -Data $real_data -Steps $steps
+ lappend real_data $a
}
}
+
+ # !! lindex $Lines 0 -- better way?
+ if {$Lines != {}} {
+ manage create actiondlg -File $File -Line [lindex $Lines 0] \
+ -WhileStepping $whilestepping -Number [lindex $Number 0] \
+ -Callback "$this done" -Data $real_data -Steps $steps
+ } else {
+ manage create actiondlg -File $File -Address [lindex $Addresses 0] \
+ -WhileStepping $whilestepping -Number [lindex $Number 0] \
+ -Callback "$this done" -Data $real_data -Steps $steps
+ }
}
method get_selection {} {
@@ -695,23 +704,23 @@ itcl::class TraceDlg {
}
# PUBLIC DATA
- public variable File {}
- public variable Lines {}
- public variable Addresses {}
- public variable Number {}
+ public File {}
+ public Lines {}
+ public Addresses {}
+ public Number {}
# PROTECTED DATA
- protected variable Delete
- protected variable _TPassCount
- protected variable ActionType {}
- protected variable ActionLB
- protected variable Actions
- protected variable WhileStepping 0
- protected variable Selection {}
- protected variable New 0; # set whenever there is a new tp to add
- protected variable Exists 0; # set whenever a tracepoint in the range exists
- protected variable Dismissed 0; # has this dialog been dismissed already?
- protected variable ActionsDlg {}
+ protected Delete
+ protected _TPassCount
+ protected ActionType {}
+ protected ActionLB
+ protected Actions
+ protected WhileStepping 0
+ protected Selection {}
+ protected New 0; # set whenever there is a new tp to add
+ protected Exists 0; # set whenever a tracepoint in the range exists
+ protected Dismissed 0; # has this dialog been dismissed already?
+ protected ActionsDlg {}
}
proc gdb_add_tracepoint {where passes actions {addr {}}} {
diff --git a/gdb/gdbtk/library/util.tcl b/gdb/gdbtk/library/util.tcl
index 764ce62b08e..dc8007d92f5 100644
--- a/gdb/gdbtk/library/util.tcl
+++ b/gdb/gdbtk/library/util.tcl
@@ -1,5 +1,5 @@
-# Utilities for Insight.
-# Copyright (C) 1997, 1998, 1999, 2004 Red Hat
+# Utilities for GDBtk.
+# Copyright 1997, 1998, 1999 Cygnus Solutions
#
# This program is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License (GPL) as published by
@@ -30,8 +30,8 @@
# A helper procedure to keep a window on top.
proc keep_raised {top} {
if {[winfo exists $top]} {
- raise $top
wm deiconify $top
+ raise $top
after 1000 [info level 0]
}
}
@@ -79,7 +79,7 @@ proc tfind_cmd {command} {
set err [catch {gdb_cmd $command} msg]
if {$err || [regexp "Target failed to find requested trace frame" $msg]} {
tk_messageBox -icon error -title "GDB" -type ok \
- -message $msg
+ -modal task -message $msg
gdbtk_idle
return
} else {
@@ -154,7 +154,7 @@ proc gdbtk_read_defs {} {
tk_messageBox -icon error -message "Cannot load defs file:\n$errTxt" -type ok
return 0
} else {
- puts stderr "cannot load defs files: $errTxt\ntry setting DEFS"
+ puts stdout "cannot load defs files: $errTxt\ntry setting DEFS"
exit 1
}
}
@@ -175,7 +175,7 @@ proc bp_exists {linespec} {
foreach bpnum $bps {
set bpinfo [gdb_get_breakpoint_info $bpnum]
lassign $bpinfo file func line pc type enabled disposition \
- ignore_count commands cond thread hit_count user_specification
+ ignore_count commands cond thread hit_count
if {$filename == $file && $function == $func && $addr == $pc} {
return $bpnum
}
@@ -185,6 +185,28 @@ proc bp_exists {linespec} {
}
+# Scrolled Listbox - this could be in libgui,
+# but we'll probably just start using new iwidgets stuff
+# soon so keep it here temporarily. This is based on
+# code from Welch's book.
+
+proc CygScrolledListbox { win args } {
+ frame $win
+ # Create listbox attached to scrollbars, pass thru $args
+ eval {listbox $win.list -yscrollcommand [list $win.sy set]} $args
+ scrollbar $win.sy -orient vertical -command [list $win.list yview]
+
+ # Create padding based on the scrollbar width and border
+ set pad [expr [$win.sy cget -width] + 2* \
+ ([$win.sy cget -bd] + \
+ [$win.sy cget -highlightthickness])]
+
+ frame $win.pad -width $pad -height $pad
+ pack $win.sy -side right -fill y
+ pack $win.list -side left -fill both -expand true
+ return $win.list
+}
+
# gridCGet - This provides the missing grid cget
# command.
@@ -194,6 +216,75 @@ proc gridCGet {slave option} {
}
# ------------------------------------------------------------------
+# PROC: find_iwidgets_library - Find the IWidgets library.
+#
+# This is a little bit of bogosity which is necessary so we
+# can find the iwidgets libraries if we are not installed:
+# The problem is that the iwidgets are really weird. The init file is
+# in the build tree, but all the library files are in the source tree...
+#
+# ------------------------------------------------------------------
+proc find_iwidgets_library {} {
+
+ set IwidgetsOK 1
+
+ if {[catch {package require Iwidgets 3.0} errMsg]} {
+
+ # OK, we are not installed or this would have succeeded...
+ # Lets try to do it by hand:
+ set IwidgetsOK 0
+
+ set iwidgetsSrcDir [glob -nocomplain [file join \
+ [file dirname [file dirname $::tcl_library]] \
+ itcl iwidgets*]]
+
+ # Canonicalize the executable's directory name. It turns out that on Solaris,
+ # info nameofexecutable returns /foo/bar/real_dir/./gdb when gdb is launched from
+ # another gdb session, so we have to fix this up.
+
+ set exec_name [info nameofexecutable]
+ set curdir [pwd]
+ cd [file dirname $exec_name]
+ set exec_name [pwd]
+ cd $curdir
+
+ set iwidgetsBuildDir [glob -nocomplain [file join \
+ [file dirname $exec_name] \
+ itcl iwidgets*]]
+
+ if {[llength $iwidgetsSrcDir] == 1 && [llength $iwidgetsBuildDir] == 1} {
+ # The lindex is necessary because the path may have spaces in it...
+ set initFile [file join [lindex $iwidgetsBuildDir 0] \
+ $::tcl_platform(platform) iwidgets.tcl]
+ set libDir [file join [lindex $iwidgetsSrcDir 0] generic]
+ if {[file exists $initFile] && [file isdirectory $libDir]} {
+ if {![catch {source $initFile} err]} {
+ # Now fix up the stuff the Iwidgets init file got wrong...
+ set libPos [lsearch $::auto_path [file join $::iwidgets::library scripts]]
+ if {$libPos >= 0} {
+ set auto_path [lreplace $::auto_path $libPos $libPos $libDir]
+ } else {
+ lappend ::auto_path $libDir
+ }
+ set ::iwidgets::library $libDir
+ set IwidgetsOK 1
+ } else {
+ append errMsg "\nError in iwidgets.tcl file: $err"
+ }
+ }
+ } else {
+ append errMsg "\nCould not find in-place versions of the Iwidgets files\n"
+ append errMsg "Looked at: [file join [file dirname\
+ [file dirname $::tcl_library]] itcl iwidgets*]\n"
+ append errMsg "and: [file join [file dirname \
+ [info nameofexecutable]] itcl iwidgets*]\n"
+ }
+
+ }
+ return $IwidgetsOK
+}
+
+# ------------------------------------------------------------------
# PROC: get_disassembly_flavor - gets the current disassembly flavor.
# The set disassembly-flavor command is assumed to exist. This
# will error out if it does not.
@@ -253,79 +344,3 @@ proc list_element_strcmp {index first second} {
return [string compare $theFirst $theSecond]
}
-
-# ------------------------------------------------------------------
-# PROC: gdbtk_endian - returns BIG or LITTLE depending on target
-# endianess
-# ------------------------------------------------------------------
-
-proc gdbtk_endian {} {
- if {[catch {gdb_cmd "show endian"} result]} {
- return "UNKNOWN"
- }
- if {[regexp {.*big endian} $result]} {
- set result "BIG"
- } elseif {[regexp {.*little endian} $result]} {
- set result "LITTLE"
- } else {
- set result "UNKNOWN"
- }
- return $result
-}
-
-# ------------------------------------------------------------------
-# PROC: set_bg_colors - set background and text background for
-# all windows.
-# ------------------------------------------------------------------
-proc set_bg_colors {{num ""}} {
- debug $num
-
- if {$num != ""} {
- set ::gdb_bg_num $num
- }
- set ::Colors(textbg) [pref get gdb/bg/$::gdb_bg_num]
-
- # calculate background as 80% of textbg
- set ::Colors(bg) [recolor $::Colors(textbg) 80]
-
- # calculate trough and activebackground as 90% of background
- set dbg [recolor $::Colors(bg) 90]
-
- r_setcolors . -background $::Colors(bg)
- r_setcolors . -highlightbackground $::Colors(bg)
- r_setcolors . -textbackground $::Colors(textbg)
- r_setcolors . -troughcolor $dbg
- r_setcolors . -activebackground $dbg
-
- pref_set_option_db 1
- ManagedWin::restart
-}
-
-# ------------------------------------------------------------------
-# PROC: r_setcolors - recursively set background and text background for
-# all windows.
-# ------------------------------------------------------------------
-proc r_setcolors {w option color} {
- debug "$w $option $color"
-
- # exception(s)
- if {![catch {$w isa Balloon} result] && $result == "1"} {
- return
- }
- catch {$w config $option $color}
-
- foreach child [winfo children $w] {
- r_setcolors $child $option $color
- }
-}
-
-# ------------------------------------------------------------------
-# PROC: recolor - returns a darker or lighter color
-# ------------------------------------------------------------------
-proc recolor {color percent} {
- set c [winfo rgb . $color]
- return [format #%02x%02x%02x [expr {($percent * [lindex $c 0]) / 25600}] \
- [expr {($percent * [lindex $c 1]) / 25600}] [expr {($percent * [lindex $c 2]) / 25600}]]
-}
-
-
diff --git a/gdb/gdbtk/library/variables.tcl b/gdb/gdbtk/library/variables.tcl
new file mode 100644
index 00000000000..a1f15e2741d
--- /dev/null
+++ b/gdb/gdbtk/library/variables.tcl
@@ -0,0 +1,959 @@
+# Variable display window for GDBtk.
+# Copyright 1997, 1998, 1999 Cygnus Solutions
+#
+# This program is free software; you can redistribute it and/or modify it
+# under the terms of the GNU General Public License (GPL) as published by
+# the Free Software Foundation; either version 2 of the License, or (at
+# your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+
+
+# ----------------------------------------------------------------------
+# Implements variable windows for gdb. LocalsWin and WatchWin both
+# inherit from this class. You need only override the method
+# 'getVariablesBlankPath' and a few other things...
+# ----------------------------------------------------------------------
+
+class VariableWin {
+ inherit EmbeddedWin GDBWin
+ protected variable Sizebox 1
+
+ # ------------------------------------------------------------------
+ # CONSTRUCTOR - create new watch window
+ # ------------------------------------------------------------------
+ constructor {args} {
+ #
+ # Create a window with the same name as this object
+ #
+ gdbtk_busy
+ set _queue [Queue \#auto]
+ build_win $itk_interior
+ gdbtk_idle
+
+ add_hook gdb_update_hook "$this update"
+ add_hook gdb_busy_hook "$this disable_ui"
+ add_hook gdb_no_inferior_hook "$this no_inferior"
+ add_hook gdb_idle_hook [list $this idle]
+ add_hook gdb_clear_file_hook [code $this clear_file]
+ }
+
+ # ------------------------------------------------------------------
+ # METHOD: build_win - build the watch window
+ # ------------------------------------------------------------------
+ method build_win {f} {
+ global tixOption tcl_platform Display
+ # debug "VariableWin::build_win"
+ set width [font measure src-font "W"]
+ # Choose the default width to be...
+ set width [expr {40 * $width}]
+ if {$tcl_platform(platform) == "windows"} {
+ set scrollmode both
+ } else {
+ set scrollmode auto
+ }
+
+ debug "tree=$f.tree"
+ set Tree [tixTree $f.tree \
+ -opencmd "$this open" \
+ -closecmd "$this close" \
+ -ignoreinvoke 1 \
+ -width $width \
+ -browsecmd [list $this selectionChanged] \
+ -scrollbar $scrollmode \
+ -sizebox $Sizebox]
+ if {![pref get gdb/mode]} {
+ $Tree configure -command [list $this editEntry]
+ }
+ set Hlist [$Tree subwidget hlist]
+
+ # FIXME: probably should use columns instead.
+ $Hlist configure -header 1
+
+ set l [expr {$EntryLength - $Length - [string length "Name"]}]
+ # Ok, this is as hack as it gets
+ set blank " "
+ $Hlist header create 0 -itemtype text \
+ -text "Name[string range $blank 0 $l]Value"
+
+ # Configure the look of the tree
+ set sbg [$Hlist cget -bg]
+ set fg [$Hlist cget -fg]
+ set bg $tixOption(input1_bg)
+ set width [font measure src-font $LengthString]
+ $Hlist configure -indent $width -bg $bg \
+ -selectforeground $fg -selectbackground $sbg \
+ -selectborderwidth 0 -separator . -font src-font
+
+ # Get display styles
+ set normal_fg [$Hlist cget -fg]
+ set highlight_fg [pref get gdb/variable/highlight_fg]
+ set disabled_fg [pref get gdb/variable/disabled_fg]
+ set NormalTextStyle [tixDisplayStyle text -refwindow $Hlist \
+ -bg $bg -fg $normal_fg -font src-font]
+ set HighlightTextStyle [tixDisplayStyle text -refwindow $Hlist \
+ -bg $bg -fg $highlight_fg -font src-font]
+ set DisabledTextStyle [tixDisplayStyle text -refwindow $Hlist \
+ -bg $bg -fg $disabled_fg -font src-font]
+
+ if {[catch {gdb_cmd "show output-radix"} msg]} {
+ set Radix 10
+ } else {
+ regexp {[0-9]+} $msg Radix
+ }
+
+
+ # Update the tree display
+ update
+ pack $Tree -expand yes -fill both
+
+ # Create the popup menu for this widget
+ bind $Hlist <3> "$this postMenu %X %Y"
+ bind $Hlist <KeyPress-space> [code $this toggleView]
+
+ # Do not use the tixPopup widget...
+ set Popup [menu $f.menu -tearoff 0]
+ set disabled_foreground [$Popup cget -foreground]
+ $Popup configure -disabledforeground $disabled_foreground
+ set ViewMenu [menu $Popup.view]
+
+ # Populate the view menu
+ $ViewMenu add radiobutton -label "Hex" -variable Display($this) \
+ -value hexadecimal
+ $ViewMenu add radiobutton -label "Decimal" -variable Display($this) \
+ -value decimal
+ $ViewMenu add radiobutton -label "Binary" -variable Display($this) \
+ -value binary
+ $ViewMenu add radiobutton -label "Octal" -variable Display($this) \
+ -value octal
+ $ViewMenu add radiobutton -label "Natural" -variable Display($this) \
+ -value natural
+
+ $Popup add command -label "dummy" -state disabled
+ $Popup add separator
+ $Popup add cascade -label "Format" -menu $ViewMenu
+ # $Popup add checkbutton -label "Auto Update"
+ # $Popup add command -label "Update Now"
+ if {![pref get gdb/mode]} {
+ $Popup add command -label "Edit"
+ }
+
+ # Make sure to update menu info.
+ selectionChanged ""
+
+ window_name "Local Variables" "Locals"
+ }
+
+ # ------------------------------------------------------------------
+ # DESTRUCTOR - destroy window containing widget
+ # ------------------------------------------------------------------
+ destructor {
+ # debug "VariableWin::destructor"
+ # Make sure to clean up the frame
+ catch {destroy $_frame}
+
+ # Delete the display styles used with this window
+ destroy $NormalTextStyle
+ destroy $HighlightTextStyle
+ destroy $DisabledTextStyle
+
+ # Remove this window and all hooks
+ remove_hook gdb_update_hook "$this update"
+ remove_hook gdb_busy_hook "$this disable_ui"
+ remove_hook gdb_no_inferior_hook "$this no_inferior"
+ remove_hook gdb_idle_hook [list $this idle]
+ remove_hook gdb_clear_file_hook [code $this clear_file]
+ }
+
+ # ------------------------------------------------------------------
+ # METHOD: clear_file - Clear out state and prepare for loading
+ # a new executable.
+ # ------------------------------------------------------------------
+ method clear_file {} {
+ no_inferior
+ }
+
+ # ------------------------------------------------------------------
+ # METHOD: reconfig - used when preferences change
+ # ------------------------------------------------------------------
+ method reconfig {} {
+ # debug "VariableWin::reconfig"
+ foreach win [winfo children $itk_interior] {
+ destroy $win
+ }
+
+ build_win $itk_interior
+ }
+
+ # ------------------------------------------------------------------
+ # METHOD: build_menu_helper - Create the menu for a subclass.
+ # ------------------------------------------------------------------
+ method build_menu_helper {first} {
+ global Display
+ menu [namespace tail $this].mmenu
+
+ [namespace tail $this].mmenu add cascade -label $first -underline 0 -menu [namespace tail $this].mmenu.var
+
+ menu [namespace tail $this].mmenu.var
+ if {![pref get gdb/mode]} {
+ [namespace tail $this].mmenu.var add command -label Edit -underline 0 -state disabled \
+ -command [format {
+ %s editEntry [%s getSelection]
+ } $this $this]
+ }
+ [namespace tail $this].mmenu.var add cascade -label Format -underline 0 \
+ -menu [namespace tail $this].mmenu.var.format
+
+ menu [namespace tail $this].mmenu.var.format
+ foreach label {Hex Decimal Binary Octal Natural} fmt {hexadecimal decimal binary octal natural} {
+ [namespace tail $this].mmenu.var.format add radiobutton \
+ -label $label -underline 0 \
+ -value $fmt -variable Display($this) \
+ -command [format {
+ %s setDisplay [%s getSelection] %s
+ } $this $this $fmt]
+ }
+
+ # [namespace tail $this].mmenu add cascade -label Update -underline 0 -menu [namespace tail $this].mmenu.update
+ # menu [namespace tail $this].mmenu.update
+
+ # The -variable is set when a selection is made in the tree.
+ # [namespace tail $this].mmenu.update add checkbutton -label "Auto Update" -underline 0 \
+ # -command [format {
+ # %s toggleUpdate [%s getSelection]
+ # } $this $this]
+ # [namespace tail $this].mmenu.update add command -label "Update Now" -underline 0 \
+ # -accelerator "Ctrl+U" -command [format {
+ # %s updateNow [%s getSelection]
+ # } $this $this]
+
+ set top [winfo toplevel [namespace tail $this]]
+ $top configure -menu [namespace tail $this].mmenu
+ bind_plain_key $top Control-u [format {
+ if {!$Running} {
+ if {[%s getSelection] != ""} {
+ %s updateNow [%s getSelection]
+ }
+ }
+ } $this $this $this]
+
+ return [namespace tail $this].mmenu.var
+ }
+
+ # Return the current selection, or the empty string if none.
+ method getSelection {} {
+ return [$Hlist info selection]
+ }
+
+ # This is called when a selection is made. It updates the main
+ # menu.
+ method selectionChanged {variable} {
+ global Display
+
+ if {$Running} {
+ # Clear the selection, too
+ $Hlist selection clear
+ return
+ }
+
+ # if something is being edited, cancel it
+ if {[info exists EditEntry]} {
+ UnEdit
+ }
+
+ if {$variable == ""} {
+ set state disabled
+ } else {
+ set state normal
+ }
+
+ foreach menu [list [namespace tail $this].mmenu.var [namespace tail $this].mmenu.var.format ] {
+ set i [$menu index last]
+ while {$i >= 0} {
+ if {[$menu type $i] != "cascade"} {
+ $menu entryconfigure $i -state $state
+ }
+ incr i -1
+ }
+ }
+
+ if {$variable != "" && [$variable editable]} {
+ set state normal
+ } else {
+ set state disabled
+ }
+
+ if {$variable != ""} {
+ set Display($this) [$variable format]
+ }
+
+ foreach label {Hex Decimal Binary Octal Natural} {
+ [namespace tail $this].mmenu.var.format entryconfigure $label
+ if {$label != "Hex"} {
+ [namespace tail $this].mmenu.var.format entryconfigure $label -state $state
+ }
+ }
+ # [namespace tail $this].mmenu.update entryconfigure 0 -variable Update($this,$name)
+ }
+
+ method updateNow {variable} {
+ # debug "VariableWin::updateNow $variable"
+
+ if {!$Running} {
+ set text [label $variable]
+ $Hlist entryconfigure $variable -itemtype text -text $text
+ }
+ }
+
+ method getEntry {x y} {
+ set realY [expr {$y - [winfo rooty $Hlist]}]
+
+ # Get the tree entry which we are over
+ return [$Hlist nearest $realY]
+ }
+
+ method editEntry {variable} {
+ if {!$Running} {
+ if {$variable != "" && [$variable editable]} {
+ edit $variable
+ }
+ }
+ }
+
+ method postMenu {X Y} {
+ global Update Display
+ # debug "VariableWin::postMenu"
+
+ # Quicky for menu posting problems.. How to unpost and post??
+
+ if {[winfo ismapped $Popup] || $Running} {
+ return
+ }
+
+ set variable [getEntry $X $Y]
+ if {[string length $variable] > 0} {
+ # Configure menu items
+ # the title is always first..
+ #set labelIndex [$Popup index "dummy"]
+ set viewIndex [$Popup index "Format"]
+ # set autoIndex [$Popup index "Auto Update"]
+ # set updateIndex [$Popup index "Update Now"]
+ set noEdit [catch {$Popup index "Edit"} editIndex]
+
+ # Retitle and set update commands
+ $Popup entryconfigure 0 -label "[$variable name]"
+ # $Popup entryconfigure $autoIndex -command "$this toggleUpdate \{$entry\}" \
+ -variable Update($this,$entry)
+ # $Popup entryconfigure $updateIndex -command "$this updateNow \{$entry\}"
+
+ # Edit pane
+ if {$variable != "" && [$variable editable]} {
+ if {!$noEdit} {
+ $Popup delete $editIndex
+ }
+ if {![pref get gdb/mode]} {
+ $Popup add command -label Edit -command "$this edit \{$variable\}"
+ }
+ } else {
+ if {!$noEdit} {
+ $Popup delete $editIndex
+ }
+ }
+
+ # Set view menu
+ set Display($this) [$variable format]
+ foreach i {0 1 2 3 4} fmt {hexadecimal decimal binary octal natural} {
+ debug "configuring entry $i ([$ViewMenu entrycget $i -label]) to $fmt"
+ $ViewMenu entryconfigure $i \
+ -command "$this setDisplay \{$variable\} $fmt"
+ }
+
+ tk_popup $Popup $X $Y
+ }
+ }
+
+ # ------------------------------------------------------------------
+ # METHOD edit -- edit a variable
+ # ------------------------------------------------------------------
+ method edit {variable} {
+ global Update tixOption
+
+ # disable menus
+ selectionChanged ""
+ debug "editing \"$variable\""
+
+ set fg [$Hlist cget -foreground]
+ set bg [$Hlist cget -background]
+
+ if {$Editing == ""} {
+ # Must create the frame
+ set Editing [frame $Hlist.frame -bg $bg -bd 0 -relief flat]
+ set lbl [::label $Editing.lbl -fg $fg -bg $bg -font src-font]
+ set ent [entry $Editing.ent -bg $tixOption(bg) -font src-font]
+ pack $lbl $ent -side left
+ }
+
+ if {[info exists EditEntry]} {
+ # We already are editing something... So reinstall it first
+ # I guess we discard any changes?
+ UnEdit
+ }
+
+ # Update the label/entry widgets for this instance
+ set Update($this,$variable) 1
+ set EditEntry $variable
+ set label [label $variable 1]; # do not append value
+ $Editing.lbl configure -text "$label "
+ $Editing.ent delete 0 end
+
+ # Strip the pointer type, text, etc, from pointers, and such
+ set err [catch {$variable value} text]
+ if {$err} {return}
+ if {[$variable format] == "natural"} {
+ # Natural formats must be stripped. They often contain
+ # things like strings and characters after them.
+ set index [string first \ $text]
+ if {$index != -1} {
+ set text [string range $text 0 [expr {$index - 1}]]
+ }
+ }
+ $Editing.ent insert 0 $text
+
+ # Find out what the previous entry is
+ set previous [getPrevious $variable]
+
+ close $variable
+ $Hlist delete entry $variable
+
+ set cmd [format { \
+ %s add {%s} %s -itemtype window -window %s \
+ } $Hlist $variable $previous $Editing]
+ eval $cmd
+
+ if {[$variable numChildren] > 0} {
+ $Tree setmode $variable open
+ }
+
+ # Set focus to entry
+ focus $Editing.ent
+ $Editing.ent selection to end
+
+ # Setup key bindings
+ bind $Editing.ent <Return> "$this changeValue"
+ bind $Hlist <Return> "$this changeValue"
+ bind $Editing.ent <Escape> "$this UnEdit"
+ bind $Hlist <Escape> "$this UnEdit"
+ }
+
+ method getPrevious {variable} {
+ set prev [$Hlist info prev $variable]
+ set parent [$Hlist info parent $variable]
+
+ if {$prev != ""} {
+ # A problem occurs with PREV if its parent is not the same as the entry's
+ # parent. For example, consider these variables in the window:
+ # + foo struct {...}
+ # - bar struct {...}
+ # a 1
+ # b 2
+ # local 0
+ # if you attempt to edit "local", previous will be set at "bar.b", not
+ # "struct bar"...
+ if {[$Hlist info parent $prev] != $parent} {
+ # This is the problem!
+ # Find this object's sibling in that parent and place it there.
+ set children [$Hlist info children $parent]
+ set p {}
+ foreach child $children {
+ if {$child == $variable} {
+ break
+ }
+ set p $child
+ }
+
+ if {$p == {}} {
+ # This is the topmost child
+ set previous "-before [lindex $children 1]"
+ } else {
+ set previous "-after $p"
+ }
+ } else {
+ set previous "-after \{$prev\}"
+ }
+ } else {
+ # this is the first!
+ set previous "-at 0"
+ }
+
+ if {$prev == "$parent"} {
+ # This is the topmost-member of a sub-grouping..
+ set previous "-at 0"
+ }
+
+ return $previous
+ }
+
+ method UnEdit {} {
+ set previous [getPrevious $EditEntry]
+
+ $Hlist delete entry $EditEntry
+ set cmd [format {\
+ %s add {%s} %s -itemtype text -text {%s} \
+ } $Hlist $EditEntry $previous [label $EditEntry]]
+ eval $cmd
+ if {[$EditEntry numChildren] > 0} {
+ $Tree setmode $EditEntry open
+ }
+
+ # Unbind
+ bind $Hlist <Return> {}
+ bind $Hlist <Escape> {}
+ if {$Editing != ""} {
+ bind $Editing.ent <Return> {}
+ bind $Editing.ent <Escape> {}
+ }
+
+ unset EditEntry
+ selectionChanged ""
+ }
+
+ method changeValue {} {
+ # Get the old value
+ set new [string trim [$Editing.ent get] \ \r\n]
+ if {$new == ""} {
+ UnEdit
+ return
+ }
+
+ if {[catch {$EditEntry value $new} errTxt]} {
+ tk_messageBox -icon error -type ok -message $errTxt \
+ -title "Error in Expression" -parent [winfo toplevel $itk_interior]
+ focus $Editing.ent
+ $Editing.ent selection to end
+ } else {
+ UnEdit
+
+ # Get rid of entry... and replace it with new value
+ focus $Tree
+ }
+ }
+
+
+ # ------------------------------------------------------------------
+ # METHOD: toggleView: Toggle open/close the current selection.
+ # ------------------------------------------------------------------
+ method toggleView {} {
+
+ set v [getSelection]
+ set mode [$Tree getmode $v]
+
+ # In the tixTree widget, "open" means "openable", not that it is open...
+
+ debug "mode=$mode"
+ switch $mode {
+ open {
+ $Tree setmode $v close
+ open $v
+ }
+
+ close {
+ $Tree setmode $v open
+ close $v
+ }
+
+ default {
+ dbug E "What happened?"
+ }
+ }
+ }
+
+ method toggleUpdate {variable} {
+ global Update
+
+ if {$Update($this,$variable)} {
+ # Must update value
+ $Hlist entryconfigure $variable \
+ -style $NormalTextStyle \
+ -text [label $variable]
+ } else {
+ $Hlist entryconfigure $variable \
+ -style $DisabledTextStyle
+ }
+ ::update
+ }
+
+ method setDisplay {variable format} {
+ debug "$variable $format"
+ if {!$Running} {
+ $variable format $format
+ set ::Display($this) $format
+ $Hlist entryconfigure $variable -text [label $variable]
+ }
+ }
+
+ # ------------------------------------------------------------------
+ # METHOD: label - used to label the entries in the tree
+ # ------------------------------------------------------------------
+ method label {variable {noValue 0}} {
+ # Ok, this is as hack as it gets
+ set blank " "
+ # Use protected data Length to determine how big variable
+ # name should be. This should clean the display up a little
+ set name [$variable name]
+ set indent [llength [split $variable .]]
+ set indent [expr {$indent * $Length}]
+ set len [string length $name]
+ set l [expr {$EntryLength - $len - $indent}]
+ set label "$name[string range $blank 0 $l]"
+ #debug "label=$label $noValue"
+ if {$noValue} {
+ return $label
+ }
+
+ set err [catch {$variable value} value]
+ set value [string trim $value \ \r\t\n]
+ #debug "err=$err value=$value"
+
+ # Insert the variable's type for things like ptrs, etc.
+ set type [$variable type]
+ if {!$err} {
+ if {$value == "{...}"} {
+ set val " $type $value"
+ } elseif {[string first * $type] != -1} {
+ set val " ($type) $value"
+ } elseif {[string first \[ $type] != -1} {
+ set val " $type"
+ } else {
+ set val " $value"
+ }
+ } else {
+ set val " $value"
+ }
+
+ return "$label $val"
+ }
+
+ # ------------------------------------------------------------------
+ # METHOD: open - used to open an entry in the variable tree
+ # ------------------------------------------------------------------
+ method open {path} {
+ global Update
+ # We must lookup all the variables for this struct
+ # debug "VariableWin::open $path"
+
+ if {!$Running} {
+ # Do not open disabled paths
+ if {$Update($this,$path)} {
+ cursor watch
+ populate $path
+ cursor {}
+ }
+ } else {
+ $Tree setmode $path open
+ }
+ }
+
+ # ------------------------------------------------------------------
+ # METHOD: close - used to close an entry in the variable tree
+ # ------------------------------------------------------------------
+ method close {path} {
+ global Update
+ debug "VariableWin::close $path"
+ # Close the path and destroy all the entry widgets
+
+ # Cancel any edits
+ if {[info exists EditEntry]} {
+ UnEdit
+ }
+
+ if {!$Running} {
+ # Only update when we we are not disabled
+ if {$Update($this,$path)} {
+
+ # Delete the offspring of this entry
+ $Hlist delete offspring $path
+ }
+ } else {
+ $Tree setmode $path close
+ }
+ }
+
+ method isVariable {var} {
+
+ set err [catch {gdb_cmd "output $var"} msg]
+ if {$err
+ || [regexp -nocase "no symbol|syntax error" $msg]} {
+ return 0
+ }
+
+ return 1
+ }
+
+ # OVERRIDE THIS METHOD
+ method getVariablesBlankPath {} {
+ debug "You forgot to override getVariablesBlankPath!!"
+ return {}
+ }
+
+ method cmd {cmd} {
+ eval $cmd
+ }
+
+ # ------------------------------------------------------------------
+ # METHOD: populate - populate an entry in the tree
+ # ------------------------------------------------------------------
+ method populate {parent} {
+ global Update
+ debug "VariableWin::populate \"$parent\""
+
+ if {[string length $parent] == 0} {
+ set variables [getVariablesBlankPath]
+ } else {
+ set variables [$parent children]
+ }
+
+ debug "variables=$variables"
+ eval $_queue push $variables
+ for {set variable [$_queue pop]} {$variable != ""} {set variable [$_queue pop]} {
+ debug "inserting variable: $variable"
+ set Update($this,$variable) 1
+
+ $Hlist add $variable \
+ -itemtype text \
+ -text [label $variable]
+ if {[$variable numChildren] > 0} {
+ # Make sure we get this labeled as openable
+ $Tree setmode $variable open
+ }
+
+ # Special case: If we see "public" with no value or type, then we
+ # have one of our special c++/java children. Open it automagically
+ # for the user.
+ if {[string compare [$variable name] "public"] == 0
+ && [$variable type] == "" && [$variable value] == ""} {
+ eval $_queue push [$variable children]
+ $Tree setmode $variable close
+ }
+ }
+
+ debug "done with populate"
+ }
+
+ # Get all current locals
+ proc getLocals {} {
+
+ set vars {}
+ set err [catch {gdb_get_args} v]
+ if {!$err} {
+ set vars [concat $vars $v]
+ }
+
+ set err [catch {gdb_get_locals} v]
+ if {!$err} {
+ set vars [concat $vars $v]
+ }
+
+ debug "--getLocals:\n$vars\n--getLocals"
+ return [lsort $vars]
+ }
+
+ method context_switch {} {
+ set err [catch {gdb_selected_frame} current_frame]
+ debug "1: err=$err; _frame=\"$_frame\"; current_frame=\"$current_frame\""
+ if {$err && $_frame != ""} {
+ # No current frame
+ debug "no current frame"
+ catch {destroy $_frame}
+ set _frame {}
+ return 1
+ } elseif {$current_frame == "" && $_frame == ""} {
+ debug "2"
+ return 0
+ } elseif {$_frame == "" || $current_frame != [$_frame address]} {
+ # We've changed frames. If we knew something about
+ # the stack layout, we could be more intelligent about
+ # destroying variables, but we don't know that here (yet).
+ debug "switching to frame at $current_frame"
+
+ # Destroy the old frame and create the new one
+ catch {destroy $_frame}
+ set _frame [Frame ::\#auto $current_frame]
+ debug "created new frame: $_frame at [$_frame address]"
+ return 1
+ }
+
+ # Nothing changed
+ debug "3"
+ return 0
+ }
+
+ # OVERRIDE THIS METHOD and call it from there
+ method update {} {
+ global Update
+ debug "VariableWin::update"
+
+ # First, reset color on label to black
+ foreach w $ChangeList {
+ catch {
+ $Hlist entryconfigure $w -style $NormalTextStyle
+ }
+ }
+
+ # Tell toplevel variables to update themselves. This will
+ # give us a list of all the variables in the table that
+ # have changed values.
+ set ChangeList {}
+ set variables [$Hlist info children {}]
+ foreach var $variables {
+ # debug "VARIABLE: $var ($Update($this,$var))"
+ set ChangeList [concat $ChangeList [$var update]]
+ }
+
+ foreach var $ChangeList {
+ $Hlist entryconfigure $var \
+ -style $HighlightTextStyle \
+ -text [label $var]
+ }
+ }
+
+ method idle {} {
+ # Re-enable the UI
+ enable_ui
+ }
+
+ # RECURSION!!
+ method displayedVariables {top} {
+ # debug "VariableWin::displayedVariables"
+ set variableList {}
+ set variables [$Hlist info children $top]
+ foreach var $variables {
+ set mode [$Tree getmode $var]
+ if {$mode == "close"} {
+ set moreVars [displayedVariables $var]
+ lappend variableList [join $moreVars]
+ }
+ lappend variableList $var
+ }
+
+ return [join $variableList]
+ }
+
+ method deleteTree {} {
+ global Update
+ debug "deleteTree"
+ # debug "VariableWin::deleteTree"
+# set variables [displayedVariables {}]
+
+ # Delete all HList entries
+ $Hlist delete all
+
+ # Delete the variable objects
+# foreach i [array names Variables] {
+# $Variables($i) delete
+# unset Variables($i)
+# catch {unset Update($this,$i)}
+# }
+ }
+
+ # ------------------------------------------------------------------
+ # METHOD: enable_ui
+ # Enable all ui elements.
+ # ------------------------------------------------------------------
+ method enable_ui {} {
+
+ # Clear fencepost
+ set Running 0
+ cursor {}
+ }
+
+ # ------------------------------------------------------------------
+ # METHOD: disable_ui
+ # Disable all ui elements that could affect gdb's state
+ # ------------------------------------------------------------------
+ method disable_ui {} {
+
+ # Set fencepost
+ set Running 1
+
+ # Cancel any edits
+ if {[info exists EditEntry]} {
+ UnEdit
+ }
+
+ # Change cursor
+ cursor watch
+ }
+
+ # ------------------------------------------------------------------
+ # METHOD: no_inferior
+ # Reset this object.
+ # ------------------------------------------------------------------
+ method no_inferior {} {
+
+ # Clear out the Hlist
+ deleteTree
+
+ # Clear fencepost
+ set Running 0
+ set _frame {}
+ cursor {}
+ }
+
+ # ------------------------------------------------------------------
+ # METHOD: cursor - change the toplevel's cursor
+ # ------------------------------------------------------------------
+ method cursor {what} {
+ [winfo toplevel [namespace tail $this]] configure -cursor $what
+ ::update idletasks
+ }
+
+ #
+ # PUBLIC DATA
+ #
+
+ #
+ # PROTECTED DATA
+ #
+
+ # the tixTree widget for this class
+ protected variable Tree {}
+
+ # the hlist of this widget
+ protected variable Hlist {}
+
+ # entry widgets which need to have their color changed back to black
+ # when idle (used in conjunction with update)
+ protected variable ChangeList {}
+
+ protected variable ViewMenu
+ protected variable Popup
+
+ # These are for setting the indent level to an number of characters.
+ # This will help clean the tree a little
+ common EntryLength 15
+ common Length 1
+ common LengthString " "
+
+ # These should be common... but deletion?
+ # Display styles for HList
+ protected variable HighlightTextStyle
+ protected variable NormalTextStyle
+ protected variable DisabledTextStyle
+
+ protected variable Radix
+
+ # Frame object for the selected frame
+ protected variable _frame {}
+
+ protected variable Editing {}
+ protected variable EditEntry
+
+ # Fencepost for enable/disable_ui and idle/busy hooks.
+ protected variable Running 0
+
+ # little queue for convenience
+ protected variable _queue {}
+}
diff --git a/gdb/gdbtk/library/warning.tcl b/gdb/gdbtk/library/warning.tcl
index 0b510594645..1aee2830a98 100644
--- a/gdb/gdbtk/library/warning.tcl
+++ b/gdb/gdbtk/library/warning.tcl
@@ -1,5 +1,5 @@
# Warning dialog for GDBtk.
-# Copyright (C) 1998, 1999 Cygnus Solutions
+# Copyright 1998, 1999 Cygnus Solutions
#
# This program is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License (GPL) as published by
@@ -31,7 +31,7 @@
# -----------------------------------------------------------------------------
#
-itcl::class WarningDlg {
+class WarningDlg {
inherit ManagedWin ModalDialog
public {
@@ -50,7 +50,7 @@ itcl::class WarningDlg {
# DESC:
# Creates the warning dialog.
# -----------------------------------------------------------------------------
-itcl::body WarningDlg::constructor {args} {
+body WarningDlg::constructor {args} {
debug $args
window_name "Warning"
eval itk_initialize $args
diff --git a/gdb/gdbtk/library/watch.tcl b/gdb/gdbtk/library/watch.tcl
index 33fb5ee25c6..0c227d1e977 100644
--- a/gdb/gdbtk/library/watch.tcl
+++ b/gdb/gdbtk/library/watch.tcl
@@ -1,5 +1,5 @@
-# Watch window for Insight.
-# Copyright (C) 2002, 2003, 2006 Red Hat
+# Watch window for GDBtk.
+# Copyright 1997, 1998, 1999 Cygnus Solutions
#
# This program is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License (GPL) as published by
@@ -13,96 +13,83 @@
# ----------------------------------------------------------------------
-# Implements watch windows for gdb.
+# Implements watch windows for gdb. Inherits the VariableWin
+# class from variables.tcl.
# ----------------------------------------------------------------------
-itcl::class WatchWin {
- inherit EmbeddedWin GDBWin
+class WatchWin {
+ inherit VariableWin
+
# ------------------------------------------------------------------
- # CONSTRUCTOR - create new watch window
+ # CONSTRUCTOR - create new locals window
# ------------------------------------------------------------------
constructor {args} {
- debug
+ set Sizebox 0
- gdbtk_busy
- build_win $itk_interior
- gdbtk_idle
-
- add_hook gdb_no_inferior_hook "$this no_inferior"
- add_hook gdb_clear_file_hook [code $this clear_file]
- add_hook file_changed_hook [code $this clear_file]
+ # Only allow one watch window for now...
+ if {$init} {
+ set init 0
+ }
}
-
# ------------------------------------------------------------------
- # PUBLIC METHOD: busy - BusyEvent handler
- # Disable all ui elements that could affect gdb's state
+ # METHOD: build_win - build window for watch. This supplants the
+ # one in VariableWin, so that we can add the entry at the
+ # bottom.
# ------------------------------------------------------------------
- method busy {event} {
- debug
- set Running 1
- cursor watch
- }
+ method build_win {f} {
+ global tcl_platform
+ #debug "WatchWin::build_win $f"
- # Re-enable the UI
- method idle {event} {
- debug
- set Running 0
- cursor {}
- }
+ set Menu [build_menu_helper Watch]
+ $Menu add command -label Remove -underline 0 \
+ -command [format {
+ %s remove [%s getSelection]
+ } $this $this]
- # ------------------------------------------------------------------
- # METHOD: no_inferior
- # Reset this object.
- # ------------------------------------------------------------------
- method no_inferior {} {
- debug
- cursor {}
- set Running 0
- foreach var $Watched {
- $var delete
- }
- $tree remove all
- }
-
- # ------------------------------------------------------------------
- # METHOD: cursor - change the toplevel's cursor
- # ------------------------------------------------------------------
- method cursor {what} {
- [winfo toplevel [namespace tail $this]] configure -cursor $what
- ::update idletasks
- }
-
-
- # ------------------------------------------------------------------
- # METHOD: build_win - build window for watch.
- # ------------------------------------------------------------------
- method build_win {f} {
- #debug "$f"
-
set f [::frame $f.f]
set treeFrame [frame $f.top]
set entryFrame [frame $f.expr]
-
- set tree [VarTree $treeFrame.tree]
- pack $tree -expand yes -fill both
-
- set Entry [entry $entryFrame.ent -font global/fixed]
- button $entryFrame.but -text "Add Watch" -command [code $this validateEntry]
+ VariableWin::build_win $treeFrame
+ set Entry [entry $entryFrame.ent -font src-font]
+ button $entryFrame.but -text "Add Watch" -command "$this validateEntry"
pack $f -fill both -expand yes
grid $entryFrame.ent -row 0 -column 0 -sticky news -padx 2
grid $entryFrame.but -row 0 -column 1 -padx 2
grid columnconfigure $entryFrame 0 -weight 1
grid columnconfigure $entryFrame 1
+ if {$tcl_platform(platform) == "windows"} {
+ grid columnconfigure $entryFrame 1 -pad 20
+ ide_sizebox [namespace tail $this].sizebox
+ place [namespace tail $this].sizebox -relx 1 -rely 1 -anchor se
+ }
+
grid $treeFrame -row 0 -column 0 -sticky news
grid $entryFrame -row 1 -column 0 -padx 5 -pady 5 -sticky news
grid columnconfigure $f 0 -weight 1
grid rowconfigure $f 0 -weight 1
- window_name "Watch"
+ window_name "Watch Expressions"
::update idletasks
# Binding for the entry
bind $entryFrame.ent <Return> "$entryFrame.but flash; $entryFrame.but invoke"
+
+ }
+
+ method selectionChanged {entry} {
+ VariableWin::selectionChanged $entry
+
+ set state disabled
+ set entry [getSelection]
+ foreach var $Watched {
+ set name [lindex $var 0]
+ if {"$name" == "$entry"} {
+ set state normal
+ break
+ }
+ }
+
+ $Menu entryconfigure last -state $state
}
method validateEntry {} {
@@ -111,59 +98,125 @@ itcl::class WatchWin {
set variable [$Entry get]
debug "Got $variable, going to add"
set ok [add $variable]
- debug "Added... with ok: $ok"
+ debug "Added... with ok: $ok"
+
$Entry delete 0 end
}
}
# ------------------------------------------------------------------
# METHOD: clear_file - Clear out state so that a new executable
- # can be loaded. For WatchWins, this means doing
- # everything that no_inferior does.
+ # can be loaded. For WatchWins, this means deleting
+ # the Watched list, in addition to the normal
+ # VariableWin stuff.
# ------------------------------------------------------------------
method clear_file {} {
- debug
- no_inferior
+ VariableWin::clear_file
+ set Watched {}
}
# ------------------------------------------------------------------
# DESTRUCTOR - delete watch window
# ------------------------------------------------------------------
destructor {
- debug
- set tree {}
+ foreach var $Watched {
+ $var delete
+ }
+ }
- # Remove this window and all hooks
- remove_hook gdb_no_inferior_hook "$this no_inferior"
- remove_hook gdb_clear_file_hook [code $this clear_file]
- remove_hook file_changed_hook [code $this clear_file]
+ method postMenu {X Y} {
+# debug "WatchWin::postMenu $x $y"
+ set entry [getEntry $X $Y]
+
+ # Disable "Remove" if we are not applying this to the parent
+ set found 0
foreach var $Watched {
- $var delete
+ set name [lindex $var 0]
+ if {"$name" == "$entry"} {
+ set found 1
+ break
+ }
+ }
+
+ # Ok, nasty, but a sad reality...
+ set noStop [catch {$Popup index "Remove"} i]
+ if {!$noStop} {
+ $Popup delete $i
+ }
+ if {$found} {
+ $Popup add command -label "Remove" -command "$this remove \{$entry\}"
}
+
+ VariableWin::postMenu $X $Y
}
method remove {entry} {
- debug $entry
+ global Display Update
# Remove this entry from the list of watched variables
- set Watched [lremove $Watched $entry]
+ set i [lsearch -exact $Watched $entry]
+ if {$i == -1} {
+ debug "WHAT HAPPENED?"
+ return
+ }
+ set Watched [lreplace $Watched $i $i]
+
+ set list [$Hlist info children $entry]
+ lappend list $entry
+ $Hlist delete entry $entry
- $entry remove
$entry delete
}
+ # ------------------------------------------------------------------
+ # METHOD: getVariablesBlankPath
+ # Overrides VarialbeWin::getVariablesBlankPath. For a Watch Window,
+ # this method returns a list of watched variables.
+ #
+ # ONLY return items that need to be added to the Watch Tree
+ # (or use deleteTree)
+ # ------------------------------------------------------------------
+ method getVariablesBlankPath {} {
+# debug "WatchWin::getVariablesBlankPath"
+ set list {}
+
+ set variables [displayedVariables {}]
+ foreach var $variables {
+ set name [$var name]
+ set on($name) 1
+ }
+
+ foreach var $Watched {
+ set name [$var name]
+ if {![info exists on($name)]} {
+ lappend list $var
+ }
+ }
- method update {event} {
- $tree update
+ return $list
}
+ method update {} {
+ global Update Display
+ debug "START WATCH UPDATE CALLBACK"
+ catch {populate {}} msg
+ catch {VariableWin::update} msg
+ debug "Did VariableWin::update with return \"$msg\""
+
+ # Make sure all variables are marked as _not_ Openable?
+ debug "END WATCH UPDATE CALLBACK"
+ }
+
+ method showMe {} {
+ debug "Watched: $Watched"
+ }
# ------------------------------------------------------------------
# METHOD: add - add a variable to the watch window
# ------------------------------------------------------------------
method add {name} {
- debug "Trying to add \"$name\" to watch"
+ debug "Trying to add \"$name\" to watch"
# Strip all the junk after the first \n
set var [split $name \n]
@@ -197,22 +250,21 @@ itcl::class WatchWin {
debug "In add, going to add $name"
# make one last attempt to get errors
set err [catch {set foo($name) 1}]
- debug "err1=$err"
set err [expr {$err + [catch {expr {$foo($name) + 1}}]}]
- debug "err2=$err"
if {!$err} {
- set var [gdb_variable create -expr $name]
- debug "var=$var"
- $tree add $var
- lappend Watched $var
- return 1
+ set var [gdb_variable create -expr $name]
+ set ::Update($this,$var) 1
+ lappend Watched $var
+ update
+ return 1
}
- }
+ }
+
return 0
}
protected variable Entry
protected variable Watched {}
- protected variable tree
- protected variable Running
+ protected variable Menu {}
+ protected common init 1
}
diff --git a/gdb/main.c b/gdb/main.c
index 6c9baa34c21..eb058bb1a27 100644
--- a/gdb/main.c
+++ b/gdb/main.c
@@ -255,6 +255,11 @@ captured_main (void *data)
{"command", required_argument, 0, 'x'},
{"version", no_argument, &print_version, 1},
{"x", required_argument, 0, 'x'},
+#ifdef GDBTK
+ {"tclcommand", required_argument, 0, 'z'},
+ {"enable-external-editor", no_argument, 0, 'y'},
+ {"editor-command", required_argument, 0, 'w'},
+#endif
{"ui", required_argument, 0, 'i'},
{"interpreter", required_argument, 0, 'i'},
{"i", required_argument, 0, 'i'},
@@ -334,6 +339,40 @@ captured_main (void *data)
cmdsize * sizeof (*cmdarg));
}
break;
+#ifdef GDBTK
+ case 'z':
+ {
+ extern int gdbtk_test PARAMS ((char *));
+ if (!gdbtk_test (optarg))
+ {
+ fprintf_unfiltered (gdb_stderr, "%s: unable to load tclcommand file \"%s\"",
+ argv[0], optarg);
+ exit (1);
+ }
+ break;
+ }
+ case 'y':
+ {
+ /*
+ * This enables the edit/button in the main window, even
+ * when IDE_ENABLED is set to false. In this case you must
+ * use --tclcommand to specify a tcl/script to be called,
+ * Tcl/Variable to store the edit/command is:
+ * external_editor
+ */
+ enable_external_editor = 1;
+ break;
+ }
+ case 'w':
+ {
+ /*
+ * if editor command is enabled, both flags are set
+ */
+ enable_external_editor = 1;
+ external_editor_command = xstrdup (optarg);
+ break;
+ }
+#endif /* GDBTK */
case 'd':
dirarg[ndir++] = optarg;
if (ndir >= dirsize)
diff --git a/gdb/testsuite/ChangeLog b/gdb/testsuite/ChangeLog
index cfc2c906886..a48ff61c539 100644
--- a/gdb/testsuite/ChangeLog
+++ b/gdb/testsuite/ChangeLog
@@ -991,6 +991,80 @@ Fri Mar 12 18:06:21 1999 Stan Shebs <shebs@andros.cygnus.com>
commands. They're not germane to this test, and they don't work
that way on remote targets.
+1999-03-03 James Ingham <jingham@cygnus.com>
+
+ * browser.test: Fixed up to match the new function browser.
+ This is not done yet...
+
+ * srcwin.test: Check for errors when the bbox is called for a text
+ item that is not on screen (so bbox is ""). Return something more
+ useful.
+
+1999-03-01 James Ingham <jingham@cygnus.com>
+
+ * Changelog entries merged over from gdb development branch.
+
+ 1999-01-12 Martin Hunt <hunt@cygnus.com>
+
+ * gdb.gdbtk/srcwin.test: Add a bunch of tests for the source
+ window filename and function comboboxes. Add in stack tests.
+
+ 1999-01-11 Martin Hunt <hunt@cygnus.com>
+
+ * gdb.gdbtk/srcwin.test: New file. Source Window tests.
+ * gdb.gdbtk/srcwin.exp: New file. Source Window tests.
+
+ Wed Jan 6 09:22:52 1999 Keith Seitz <keiths@cygnus.com>
+
+ * gdb.gdbtk/c_variable.test (c_variable-1.9): Add new
+ test to check for creation of a variable that is really a type.
+ (c_variable-7.81): Use "output" instead of "print" to get PC.
+ Include missing bits of test.
+
+ * gdb.gdbtk/cpp_variable.test (cpp_variable-1.6): Default format
+ is now "natural", not "hexadecimal"
+ (cpp_variable-2.22): Ditto.
+ (cpp_variable-2.24): Force format to hex before getting value.
+
+ * gdb.gdbtk/cpp_variable.exp: Supply missing arg to gdbtk_analyze_results.
+
+ Tue Jan 5 12:40:52 1999 Keith Seitz <keiths@cygnus.com>
+
+ * gdb.gdbtk/c_variable.c, c_variable.test, c_variable.exp: New C
+ language tests for variable object interface.
+
+ * gdb.gdbtk/cpp_variable.h, cpp_variable.cc, cpp_variable.test,
+ cpp_variable.exp: New C++ language tests for variable object
+ interface.
+
+ * gdb.gdbtk/Makefile.in (EXECUTABLES): Add c_variable and cpp_variable.
+
+ Tue Jan 5 12:33:47 1999 Keith Seitz <keiths@cygnus.com>
+
+ * lib/gdb.exp (gdbtk_analyze_results): Generic function
+ for outputting results of test run.
+
+ * gdb.gdbtk/defs (gdbtk_test): Handle xpass and xfail.
+ (gdbtk_test_error): New proc which handles error aborts.
+
+ * gdb.gdbtk/console.exp: Use gdbtk_analyze_results.
+ Check if we have a valid DISPLAY before running.
+ * gdb.gdbtk/browser.exp: Ditto.
+
+ 1998-12-07 Martin M. Hunt <hunt@cygnus.com>
+
+ * lib/gdb.exp (gdbtk_start): Fix path for itcl library.
+ * gdb.gdbtk/browser.test: Change "manage open" to ManagedWin::open.
+ * gdb.gdbtk/console.test: Same.
+ * gdb.gdbtk/*: Update from devo.
+
+ Fri Jul 24 14:57:19 1998 Keith Seitz <keiths@cygnus.com>
+
+ * gdb.gdbtk/Makefile.in: Add new example program "stack".
+ * gdb.gdbtk/browser.test,browser.exp: Add browser window
+ tests.
+ * gdb.gdbtk/stack1.c,stack2.c: Test case for browser window.
+
1999-02-25 Felix Lee <flee@cygnus.com>
* lib/gdb.exp (debug_format): initialize
@@ -1519,6 +1593,23 @@ Thurs Jul 9 11:08:31 1998 Dawn Perchik <dawn@cygnus.com>
* gdb.base/commands.exp: Break up infrun_breakpoint_command_test
into two parts to get around a synchronization problem in expect.
+Sun Jun 28 22:34:34 1998 Martin M. Hunt <hunt@cygnus.com>
+
+ * gdb.gdbtk/simple.c (main): Make main return an
+ int so compiler will stop complaining.
+
+Fri Jun 26 14:27:13 1998 Keith Seitz <keiths@cygnus.com>
+
+ * lib/gdb.exp (gdbtk_start): Add startup for gdbtk.
+
+ * configure.in: Add options for gdbtk testsuite.
+
+ * configure: Regenerate.
+
+ * gdb.gdbtk: New directory to hold gdbtk tests.
+
+ * gdb.gdbtk/console.{exp, test}: New console window tests.
+
Fri Jun 26 14:52:47 1998 Peter Schauer <pes@regent.e-technik.tu-muenchen.de>
diff --git a/gdb/testsuite/configure b/gdb/testsuite/configure
index 19ddd895ac2..a64d42ee0e8 100755
--- a/gdb/testsuite/configure
+++ b/gdb/testsuite/configure
@@ -709,6 +709,42 @@ if test "${shared}" = "true"; then
fi
# End stuff to support --enable-shared
+# Start stuff to support --enable-gdbtk
+# Check whether --enable-gdbtk or --disable-gdbtk was given.
+if test "${enable_gdbtk+set}" = set; then
+ enableval="$enable_gdbtk"
+ case "${enableval}" in
+ yes)
+ case "$host" in
+ *go32*)
+ enable_gdbtk=no ;;
+ *windows*)
+ enable_gdbtk=no ;;
+ *)
+ enable_gdbtk=yes ;;
+ esac ;;
+ no)
+ enable_gdbtk=no ;;
+ *)
+ { echo "configure: error: bad value ${enableval} given for gdbtk option" 1>&2; exit 1; } ;;
+esac
+else
+
+# Default is on for everything but go32 and windows
+case "$host" in
+ *go32* | *windows*)
+ ;;
+ *)
+ enable_gdbtk=yes ;;
+ esac
+
+fi
+
+
+if test "${enable_gdbtk}" = "yes"; then
+ configdirs="${configdirs} gdb.gdbtk"
+fi
+# End stuff to support --enable-shared
# configure the subdirectories too
subdirs="$configdirs"
diff --git a/gdb/testsuite/configure.in b/gdb/testsuite/configure.in
index 96e9de727ca..b69c05120dd 100644
--- a/gdb/testsuite/configure.in
+++ b/gdb/testsuite/configure.in
@@ -71,6 +71,38 @@ if test "${shared}" = "true"; then
fi
AC_SUBST(RPATH_ENVVAR)
# End stuff to support --enable-shared
+# Start stuff to support --enable-gdbtk
+AC_ARG_ENABLE(gdbtk,
+[ --enable-gdbtk ],
+[case "${enableval}" in
+ yes)
+ case "$host" in
+ *go32*)
+ enable_gdbtk=no ;;
+ *windows*)
+ enable_gdbtk=no ;;
+ *)
+ enable_gdbtk=yes ;;
+ esac ;;
+ no)
+ enable_gdbtk=no ;;
+ *)
+ AC_MSG_ERROR(bad value ${enableval} given for gdbtk option) ;;
+esac],
+[
+# Default is on for everything but go32 and windows
+case "$host" in
+ *go32* | *windows*)
+ ;;
+ *)
+ enable_gdbtk=yes ;;
+ esac
+])
+
+if test "${enable_gdbtk}" = "yes"; then
+ configdirs="${configdirs} gdb.gdbtk"
+fi
+# End stuff to support --enable-shared
# configure the subdirectories too
AC_CONFIG_SUBDIRS($configdirs)
diff --git a/gdb/testsuite/gdb.gdbtk/ChangeLog-gdbtk b/gdb/testsuite/gdb.gdbtk/ChangeLog-gdbtk
new file mode 100644
index 00000000000..298d90e6f8a
--- /dev/null
+++ b/gdb/testsuite/gdb.gdbtk/ChangeLog-gdbtk
@@ -0,0 +1,83 @@
+1999-09-17 Fernando Nasser <fnasser@totem.to.cygnus.com>
+
+ * testsuite/gdb.gdbtk/cpp_variable.test: Add test (2.75) to verify
+ that a baseclass member value was effectively changed.
+
+1999-09-17 Fernando Nasser <fnasser@totem.to.cygnus.com>
+
+ * testsuite/gdb.gdbtk/cpp_variable.test: Update for new variable
+ code.
+
+1999-09-17 Fernando Nasser <fnasser@totem.to.cygnus.com>
+
+ * testsuite/gdb.gdbtk/c_variable.test: Update for new variable
+ code.
+
+1999-09-17 Fernando Nasser <fnasser@totem.to.cygnus.com>
+
+ * testsuite/gdb.gdbtk/cpp_variable.h (class V): Add type to
+ virtual function declaration.
+
+1999-06-08 Fernando Nasser <fnasser@totem.to.cygnus.com>
+
+ * browser.exp: Use untested and not warning when DISPLAY is not found.
+ * c_variable.exp: Same.
+ * console.exp: Same.
+ * cpp_variable.exp: Same.
+ * srcwin.exp: Same.
+
+
+1999-04-12 Keith Seitz <keiths@cygnus.com>
+
+ * cpp_variable.exp: Pass the "c++" flag to gdb_compile so
+ that it can grab the right compiler.
+
+1999-03-16 Martin Hunt <hunt@cygnus.com>
+
+ * srcwin.test (srcwin-4.5): Change variable name
+ to $b so test will run again.
+
+1999-02-22 Martin Hunt <hunt@cygnus.com>
+
+ * srcwin.test (move_mouse_to): Fix typo.
+
+1999-02-03 Martin Hunt <hunt@cygnus.com>
+
+ * console.test (clear_command_line): Add tests 1.5 - 1.8,
+ which test the new Shift-Up and Shift-Down bindings.
+
+1999-02-01 Martin Hunt <hunt@cygnus.com>
+
+ * srcwin.test (srcwin-4.3): Fix bp test.
+
+1999-01-29 Martin Hunt <hunt@cygnus.com>
+
+ * srcwin.test (click): New function that generates an event
+ at a location.
+ (srcwin-4.4): New test. Simulate a click on a line and
+ check for breakpoint set.
+ (srcwin-4.5): New test. Right-click on a line and select "Continue
+ to Here" from popup.
+
+ * srcwin.exp: Source srcwin3.test, which will test source window
+ assembly debugging on executables built without "-g".
+
+1999-01-29 Martin Hunt <hunt@cygnus.com>
+
+ * srcwin.exp: Add srcwin2.test, which are basically the same
+ tests as srcwin.test, but run with a missing source file.
+
+ * srcwin2.test: New file.
+
+ * srcwin.test: Add tests for setting breakpoints in the source window,
+ testing BP balloons, variable balloons, and mixed-mode disassembly
+ of include files.
+
+
+Local Variables:
+mode: change-log
+left-margin: 8
+fill-column: 74
+version-control: never
+End:
+
diff --git a/gdb/testsuite/gdb.gdbtk/Makefile.in b/gdb/testsuite/gdb.gdbtk/Makefile.in
index 4df262ac964..09fed6d2694 100644
--- a/gdb/testsuite/gdb.gdbtk/Makefile.in
+++ b/gdb/testsuite/gdb.gdbtk/Makefile.in
@@ -1,10 +1,7 @@
VPATH = @srcdir@
srcdir = @srcdir@
-EXEEXT = @EXEEXT@
-
-EXECUTABLES = simple$(EXEEXT) stack$(EXEEXT) c_variable$(EXEEXT) \
- cpp_variable$(EXEEXT)
+EXECUTABLES = simple stack c_variable cpp_variable
# uuencoded format to avoid SCCS/RCS problems with binary files.
CROSS_EXECUTABLES =
@@ -32,5 +29,5 @@ distclean maintainer-clean realclean: clean
-rm -f *-init.exp
-rm -fr *.log summary detail *.plog *.sum *.psum site.*
-Makefile : $(srcdir)/Makefile.in $(srcdir)/configure.ac
+Makefile : $(srcdir)/Makefile.in $(srcdir)/configure.in
$(SHELL) ./config.status --recheck
diff --git a/gdb/testsuite/gdb.gdbtk/browser.exp b/gdb/testsuite/gdb.gdbtk/browser.exp
index 475bdb506a1..649fc7bb42c 100644
--- a/gdb/testsuite/gdb.gdbtk/browser.exp
+++ b/gdb/testsuite/gdb.gdbtk/browser.exp
@@ -1,24 +1,16 @@
-# Copyright 1998, 1999, 2001, 2004 Red Hat, Inc.
#
-# This program is free software; you can redistribute it and/or modify it
-# under the terms of the GNU General Public License (GPL) as published by
-# the Free Software Foundation; either version 2 of the License, or (at
-# your option) any later version.
+# Check if we have a display
#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
+if {![info exists ::env(DISPLAY)]} {
+ untested "No DISPLAY -- skipping test"
+} else {
-load_lib ../gdb.gdbtk/insight-support.exp
-
-if {[gdbtk_initialize_display]} {
if {$tracelevel} {
strace $tracelevel
}
#
- # test browser window
+ # test console window
#
set prms_id 0
set bug_id 0
@@ -37,5 +29,5 @@ if {[gdbtk_initialize_display]} {
set results [split $results \n]
# Analyze results
- gdbtk_done $results
+ gdbtk_analyze_results $results
}
diff --git a/gdb/testsuite/gdb.gdbtk/browser.test b/gdb/testsuite/gdb.gdbtk/browser.test
index 9e358dab1a5..832ad3633df 100644
--- a/gdb/testsuite/gdb.gdbtk/browser.test
+++ b/gdb/testsuite/gdb.gdbtk/browser.test
@@ -1,5 +1,4 @@
-# Browser Window Tests
-# Copyright 1998, 2001 Red Hat, Inc.
+# Copyright (C) 1998 Cygnus Solutions
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
@@ -56,10 +55,7 @@ proc do_search {} {
proc set_search_mode {val} {
global browser
pref set gdb/search/filter_mode $val
-
- # Use configure instead of entryset: need to have
- # combobox's command fire
- $browser component filt_type configure -value $val
+ $browser component filt_type entryset $val
}
# Highlight a file
@@ -99,11 +95,8 @@ proc clear {} {
##### #####
# Load the test executable
-set program [file join $objdir stack]
-if {[catch {gdbtk_test_file $program} t]} {
- # This isn't a test case, since if this fails, we're hosed.
- gdbtk_test_error "loading \"$program\": $t"
-}
+set file [file join $objdir stack]
+gdb_cmd "file $file"
# Open a browser
set browser [ManagedWin::open BrowserWin]
@@ -360,7 +353,7 @@ gdbtk_test browser-3.5 {all functions matching "func_1" in stack1.c - "mode cont
clear
select stack1.c
do_search
-} {func_1 func_10 func_11 func_12 func_13 func_14 func_15 static_func_1 static_func_10 static_func_11 static_func_12 static_func_13 static_func_14 static_func_15}
+} {func_1 func_10 func_11 func_12 func_13 func_14 func_15 static_func_1 static_func_10 static_func_11 static_func_12 static_func_13 static_func_14 static_func_15 }
# Test: browser-3.6
# Desc: Check all functions matching "func_1" in stack2.c - mode contains
@@ -476,13 +469,13 @@ if {$test_ran} {
}
# Test: browser-4.4
-# Desc: Check for all functions matching "func_1" - mode ends with
+# Desc: Check for all functions matching "func" - mode ends with
gdbtk_test browser-4.4 {all functions matching "func_1" - "mode ends with"} {
set_search_mode "ends with"
set_regexp "func_1"
select_all
do_search
-} {func_1 static_func_1}
+} {func_1 func_10 func_11 func_12 func_13 func_14 func_15 static_func_1 static_func_10 static_func_11 static_func_12 static_func_13 static_func_14 static_func_15}
# Test: browser-4.5
# Desc: Check all functions matching "func_1" in stack1.c - mode ends with
@@ -492,7 +485,7 @@ gdbtk_test browser-4.5 {all functions matching "func_1" in stack1.c - "mode ends
clear
select stack1.c
do_search
-} {func_1 static_func_1}
+} {func_1 func_10 func_11 func_12 func_13 func_14 func_15 static_func_1 static_func_10 static_func_11 static_func_12 static_func_13 static_func_14 static_func_15 }
if {$test_ran} {
clear
}
@@ -562,7 +555,6 @@ gdbtk_test browser-5.12 {all functions matching regexp "func" in stack2.c} {
gdbtk_test browser-5.13 {all functions matching regexp "\_1$"} {
set_search_mode "matches regexp"
set_regexp {\_1$}
- select_all
do_search
} {extern_func1_1 func_1 static_func_1}
@@ -616,27 +608,18 @@ gdbtk_test browser-6.1 {select button - select all} {
expr {[llength $m] >= 2}
} {1}
-# Test: browser-6.2
-# Desc: Check that search expressions are saved
-gdbtk_test browser-6.2 {save last search expression} {
- set_regexp hello
- select_all
- do_search
- pref get gdb/search/last_symbol
-} {hello}
-
# Test: browser-7.1
# Desc: Toggle all bps on
gdbtk_test browser-7.1 {toggle_all_bp on} {
set_regexp {\_1$}
set_search_mode "matches regexp"
select_all
- set funcs [do_search]
-
- # select all to set bp on
- $browser component func_box selection set 0 end
+ do_search
$browser component func_add_bp invoke
+ set_regexp .*
+ set funcs [do_search]
+
set bps {}
foreach f $funcs {
if {![catch {gdb_loc $f} ls]} {
@@ -646,26 +629,29 @@ gdbtk_test browser-7.1 {toggle_all_bp on} {
}
}
- catch {gdb_cmd "delete" 0}
+ for {set i 0} {$i < 20} {incr i} {
+ catch {gdb_cmd "delete $i"}
+ }
+
join [lsort $bps]
} {extern_func1_1 func_1 static_func_1}
# Test: browser-7.2
-# Desc: Toggle some bps off
-gdbtk_test browser-7.2 {toggle_some_bp off} {
+# Desc: Toggle all bps off
+gdbtk_test browser-7.2 {toggle_all_bp off} {
set_regexp {\_1$}
set_search_mode "matches regexp"
select_all
- set funcs [do_search]
-
- $browser component func_box selection set 0 end
+ do_search
$browser component func_add_bp invoke
- # Turn off all the "static_func_*" bps
- set_regexp {^static.*_1$}
+ set_regexp .*
+ set funcs [do_search]
+
+ # Turn off all static bps
+ set_regexp {\_1$}
do_search
- $browser component func_box selection set 0 end
- $browser component func_remove_bp invoke
+ $browser component func_remove_bp
set bps {}
foreach f $funcs {
if {![catch {gdb_loc $f} ls]} {
@@ -675,11 +661,22 @@ gdbtk_test browser-7.2 {toggle_some_bp off} {
}
}
- catch {gdb_cmd "delete" 0}
+ for {set i 0} {$i < 20} {incr i} {
+ catch {gdb_cmd "delete $i"}
+ }
join [lsort $bps]
} {extern_func1_1 func_1}
+# Test: browser-6.1
+# Desc: Check that search expressions are saved
+gdbtk_test browser-6.1 {save last search expression} {
+ set_regexp hello
+ select_all
+ do_search
+ pref get gdb/search/last_symbol
+} {hello}
+
#
# Exit
#
diff --git a/gdb/testsuite/gdb.gdbtk/c_variable.c b/gdb/testsuite/gdb.gdbtk/c_variable.c
index 0c0efc24bcf..461d5cee2fa 100644
--- a/gdb/testsuite/gdb.gdbtk/c_variable.c
+++ b/gdb/testsuite/gdb.gdbtk/c_variable.c
@@ -1,5 +1,3 @@
-#include <stdlib.h>
-
struct _simple_struct {
int integer;
unsigned int unsigned_integer;
diff --git a/gdb/testsuite/gdb.gdbtk/c_variable.exp b/gdb/testsuite/gdb.gdbtk/c_variable.exp
index 0fcd652e2be..8452034fe83 100644
--- a/gdb/testsuite/gdb.gdbtk/c_variable.exp
+++ b/gdb/testsuite/gdb.gdbtk/c_variable.exp
@@ -1,18 +1,10 @@
-# Copyright 1999, 2001, 2004 Red Hat, Inc.
#
-# This program is free software; you can redistribute it and/or modify it
-# under the terms of the GNU General Public License (GPL) as published by
-# the Free Software Foundation; either version 2 of the License, or (at
-# your option) any later version.
+# Check if we have a display
#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
+if {![info exists ::env(DISPLAY)]} {
+ untested "No DISPLAY -- skipping test"
+} else {
-load_lib ../gdb.gdbtk/insight-support.exp
-
-if {[gdbtk_initialize_display]} {
if {$tracelevel} {
strace $tracelevel
}
@@ -38,5 +30,5 @@ if {[gdbtk_initialize_display]} {
set results [split $results \n]
# Analyze results
- gdbtk_done $results
+ gdbtk_analyze_results $results
}
diff --git a/gdb/testsuite/gdb.gdbtk/c_variable.test b/gdb/testsuite/gdb.gdbtk/c_variable.test
index 625ac7c017d..098c9240ea4 100644
--- a/gdb/testsuite/gdb.gdbtk/c_variable.test
+++ b/gdb/testsuite/gdb.gdbtk/c_variable.test
@@ -1,5 +1,4 @@
-# Varobj Tests (C language)
-# Copyright 1998, 2001, 2003 Red Hat, Inc.
+# Copyright (C) 1998 Cygnus Solutions
#
# This Program Is Free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
@@ -16,7 +15,7 @@
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
# Please email any bugs, comments, and/or additions to this file to:
-# insight@sources.redhat.com
+# bug-gdb@prep.ai.mit.edu
# This file was written by Keith Seitz (keiths@cygnus.com)
@@ -26,11 +25,18 @@ if {![gdbtk_read_defs]} {
}
global objdir test_ran
+global tcl_platform
# Load in a file
-set program [file join $objdir c_variable]
-if {[catch {gdbtk_test_file $program} t]} {
- # This isn't a test case, since if this fails, we're hosed.
+if {$tcl_platform(platform) == "windows"} {
+ set program [file join $objdir c_variable.exe]
+} else {
+ set program [file join $objdir c_variable]
+}
+
+# This isn't a test case, since if this fails, we're hosed.
+if {[catch {gdb_cmd "file $program"} t]} {
+ # an error occured loading the file
gdbtk_test_error "loading \"$program\": $t"
}
@@ -40,17 +46,22 @@ if {[catch {gdbtk_test_file $program} t]} {
proc check_update {} {
global var
- set out {}
set changed {}
+ set unchanged {}
+ set out {}
+ #FIXME: Should get a list of root variables instead of using the array
foreach ind [array names var] {
- set ret [$var($ind) update]
- if {$ret == -1} {
- lappend out $ind
- } elseif {$ret != ""} {
- lappend changed $ret
+ set changed [concat $changed [$var($ind) update]]
+ }
+
+ foreach ind [array names var] {
+ set ix [lsearch -exact $changed $var($ind)]
+ if {$ix < 0} {
+ lappend unchanged $var($ind)
}
}
- return [list $changed $out]
+
+ return [list $changed $unchanged $out]
}
# proc to create a variable
@@ -168,9 +179,10 @@ gdbtk_test c_variable-1.3 {create out of scope variable} {
create_variable argc
} {1}
+## FIXME: natives only
# Break in main and run
gdb_cmd "break do_locals_tests"
-gdbtk_test_run
+gdb_cmd "run"
# Test: c_variable-1.4
# Desc: create local variables
@@ -195,7 +207,7 @@ gdbtk_test c_variable-1.6 {create lpsimple->integer} {
} {0}
# Test: c_variable-1.7
-# Desc: create lsimple.integer
+# Desc: ceate lsimple.integer
gdbtk_test c_variable-1.7 {create lsimple.integer} {
create_variable lsimple.integer
} {0}
@@ -224,7 +236,7 @@ gdbtk_test c_variable-1.9 {create type name} {
# Desc: check whether values changed at do_block_tests
gdbtk_test c_variable-2.1 {check whether values changed at do_block_tests} {
check_update
-} {{} {}}
+} {{} {lsimple.character lsimple.integer lpsimple lsimple lcharacter lpcharacter global_simple linteger lpinteger lfloat lpfloat func llong lplong lpsimple->integer ldouble lpdouble} {}}
# Step over "linteger = 1234;"
gdb_cmd "step"
@@ -233,7 +245,7 @@ gdb_cmd "step"
# Desc: check whether only linteger changed values
gdbtk_test c_variable-2.2 {check whether only linteger changed values} {
check_update
-} {linteger {}}
+} {linteger {lsimple.character lsimple.integer lpsimple lsimple lcharacter lpcharacter global_simple lpinteger lfloat lpfloat func llong lplong lpsimple->integer ldouble lpdouble} {}}
# Step over "lpinteger = &linteger;"
gdb_cmd "step"
@@ -242,7 +254,7 @@ gdb_cmd "step"
# Desc: check whether only lpinteger changed
gdbtk_test c_variable-2.3 {check whether only lpinteger changed} {
check_update
-} {lpinteger {}}
+} {lpinteger {lsimple.character lsimple.integer lpsimple lsimple lcharacter lpcharacter global_simple linteger lfloat lpfloat func llong lplong lpsimple->integer ldouble lpdouble} {}}
# Step over "lcharacter = 'a';"
gdb_cmd "step"
@@ -251,7 +263,7 @@ gdb_cmd "step"
# Desc: check whether only lcharacter changed
gdbtk_test c_variable-2.4 {check whether only lcharacter changed} {
check_update
-} {lcharacter {}}
+} {lcharacter {lsimple.character lsimple.integer lpsimple lsimple lpcharacter global_simple linteger lpinteger lfloat lpfloat func llong lplong lpsimple->integer ldouble lpdouble} {}}
# Step over "lpcharacter = &lcharacter;"
gdb_cmd "step"
@@ -260,7 +272,7 @@ gdb_cmd "step"
# Desc: check whether only lpcharacter changed
gdbtk_test c_variable-2.5 {check whether only lpcharacter changed} {
check_update
-} {lpcharacter {}}
+} {lpcharacter {lsimple.character lsimple.integer lpsimple lsimple lcharacter global_simple linteger lpinteger lfloat lpfloat func llong lplong lpsimple->integer ldouble lpdouble} {}}
# Step over:
# llong = 2121L;
@@ -281,7 +293,7 @@ for {set i 0} {$i < 9} {incr i} {
# lsimple.unsigned_character lsimple.integer lsimple.character changed
gdbtk_test c_variable-2.6 {check whether llong -- lsimple.character changed} {
check_update
-} {{lsimple.character lsimple.integer lfloat lpfloat llong lplong ldouble lpdouble} {}}
+} {{lsimple.character lsimple.integer lfloat lpfloat llong lplong ldouble lpdouble} {lpsimple lsimple lcharacter lpcharacter global_simple linteger lpinteger func lpsimple->integer} {}}
# Step over:
# lsimple.signed_character = 21;
@@ -296,7 +308,7 @@ for {set i 0} {$i < 4} {incr i} {
# Desc: check whether lsimple.signed_character, lsimple.char_ptr, lpsimple, func changed
gdbtk_test c_variable-2.7 {check whether lsimple.signed_character, lsimple.char_ptr, lpsimple, func changed} {
check_update
-} {{lpsimple func lpsimple->integer} {}}
+} {{lpsimple func lpsimple->integer} {lsimple.character lsimple.integer lsimple lcharacter lpcharacter global_simple linteger lpinteger lfloat lpfloat llong lplong ldouble lpdouble} {}}
# Step over
# linteger = 4321;
@@ -318,7 +330,7 @@ for {set i 0} {$i < 8} {incr i} {
# changed (they are the same)
gdbtk_test c_variable-2.8 {check whether linteger -- lsimple.integer changed} {
check_update
-} {{lsimple.character lsimple.integer lcharacter linteger lfloat llong lpsimple->integer ldouble} {}}
+} {{lsimple.character lsimple.integer lcharacter linteger lfloat llong lpsimple->integer ldouble} {lpsimple lsimple lpcharacter global_simple lpinteger lpfloat func lplong lpdouble} {}}
gdb_cmd "break subroutine1"
gdb_cmd "continue"
@@ -342,8 +354,6 @@ gdbtk_test c_variable-2.11 {create do_locals_tests local in subroutine1} {
create_variable linteger
} {1}
-# Step over
-# global_simple.integer = i + 3;
gdb_cmd "step"
# Test: c_variable-2.12
@@ -353,38 +363,31 @@ gdb_cmd "step"
# special case that, since it is not what a human expects to see.
gdbtk_test c_variable-2.12 {change global_simple.integer} {
check_update
-} {{} {lsimple.character lsimple.integer lpsimple lsimple lcharacter lpcharacter linteger lpinteger lfloat lpfloat func llong lplong lpsimple->integer ldouble lpdouble}}
+} {{} {lsimple.character lsimple.integer lpsimple lsimple i lcharacter lpcharacter global_simple linteger lpinteger lfloat lpfloat l func llong lplong lpsimple->integer ldouble lpdouble} {}}
-# Step over
-# i = 212;
gdb_cmd "step"
# Test: c_variable-2.13
# Desc: change subroutine1 local i
gdbtk_test c_variable-2.13 {change subroutine1 local i} {
check_update
-} {i {lsimple.character lsimple.integer lpsimple lsimple lcharacter lpcharacter linteger lpinteger lfloat lpfloat func llong lplong lpsimple->integer ldouble lpdouble}}
+} {i {lsimple.character lsimple.integer lpsimple lsimple lcharacter lpcharacter global_simple linteger lpinteger lfloat lpfloat l func llong lplong lpsimple->integer ldouble lpdouble} {}}
-# Step over
-# *l = 12
gdb_cmd "step"
-# This test is no longer valid, since varobj now forces
-# re-evaluation in the current frame by default.
# Test: c_variable-2.14
# Desc: change do_locals_tests local llong
-#gdbtk_test c_variable-2.14 {change do_locals_tests local llong} {
-# check_update
-#} {llong {}}
+gdbtk_test c_variable-2.14 {change do_locals_tests local llong} {
+ check_update
+} {llong {lsimple.character lsimple.integer lpsimple lsimple i lcharacter lpcharacter global_simple linteger lpinteger lfloat lpfloat l func lplong lpsimple->integer ldouble lpdouble} {}}
-# Leave subroutine1
gdb_cmd "next"
# Test: c_variable-2.15
# Desc: check for out of scope subroutine1 locals
-gdbtk_test c_variable-2.15 {check for out of scope subroutine1 locals} {
- lindex [check_update] 1
-} {i l}
+gdbtk_test *c_variable-2.15 {check for out of scope subroutine1 locals (ops, we don't have a out-of-scope list yet)} {
+ check_update
+} {{} {lsimple.character lsimple.integer lpsimple lsimple lcharacter lpcharacter global_simple linteger lpinteger lfloat lpfloat func llong lplong lpsimple->integer ldouble lpdouble} {i l}}
# Test: c_variable-2.16
# Desc: names of all editable variables
@@ -435,7 +438,7 @@ gdb_cmd "step"
# Desc: check foo, cb changed
gdbtk_test c_variable-3.4 {check foo,cb changed} {
check_update
-} {{foo cb} {}}
+} {{foo cb} {} {}}
# step to "foo = 321;"
gdb_cmd "step"
@@ -463,15 +466,10 @@ gdbtk_test c_variable-3.6 {create foo2} {
# Test: c_variable-3.7
# Desc: check that outer foo in scope and inner foo out of scope
-
-# Disabled for now because varobjs don't work this way. If you create a varobj named "foo"
-# it will display the correct value for any variable named "foo" in scope. So inner_foo
-# is not out of scope because there is another variable named "foo" in scope. It is
-# instead marked as changed.
-
-#gdbtk_test *c_variable-3.7 {check that outer foo in scope and inner foo out of scope} {
-# check_update
-#} {{} inner_foo}
+# Note: also a known gdb problem
+gdbtk_test *c_variable-3.7 {check that outer foo in scope and inner foo out of scope (known gdb problem)} {
+ check_update
+} {{} {foo2 foo cb} inner_foo}
delete_variable inner_foo
@@ -480,18 +478,18 @@ gdb_cmd "step"
# Test: c_variable-3.8
# Desc: check that foo2 out of scope
-gdbtk_test c_variable-3.8 {check that foo2 out of scope} {
+gdbtk_test *c_variable-3.8 {check that foo2 out of scope (known gdb problem} {
check_update
-} {{} foo2}
+} {{} {foo cb} foo2}
# step to "cb = 21;"
gdb_cmd "step"
# Test: c_variable-3.9
# Desc: check that only cb is in scope
-gdbtk_test c_variable-3.9 {check that only cb is in scope} {
+gdbtk_test *c_variable-3.9 {check that only cb is in scope (known gdb problem)} {
check_update
-} {{} {foo foo2}}
+} {{} cb {foo2 foo}}
# Test: c_variable-3.10
# Desc: names of editable variables
@@ -563,13 +561,13 @@ gdbtk_test c_variable-4.8 {number of children of struct_declarations.character}
# Desc: children of struct_declarations.char_ptr
gdbtk_test c_variable-4.9 {children of struct_declarations.char_ptr} {
get_children struct_declarations.char_ptr
-} {*char_ptr}
+} {}
# Test: c_variable-4.10
# Desc: number of children of struct_declarations.char_ptr
gdbtk_test c_variable-4.10 {number of children of struct_declarations.char_ptr} {
$var(struct_declarations.char_ptr) numChildren
-} {1}
+} {0}
# Test: c_variable-4.11
# Desc: children of struct_declarations.long_int
@@ -792,13 +790,13 @@ gdbtk_test c_variable-4.46 {number of children of struct_declarations.u1.a} {
# Desc: children of struct_declarations.u1.b
gdbtk_test c_variable-4.47 {children of struct_declarations.u1.b} {
get_children struct_declarations.u1.b
-} {*b}
+} {}
# Test: c_variable-4.48
# Desc: number of children of struct_declarations.u1.b
gdbtk_test c_variable-4.48 {number of children of struct_declarations.u1.b} {
$var(struct_declarations.u1.b) numChildren
-} {1}
+} {0}
# Test: c_variable-4.49
# Desc: children of struct_declarations.u1.c
@@ -1175,7 +1173,7 @@ delete_variable weird
# Desc: check that nothing changed
gdbtk_test c_variable-5.1 {check that nothing changed} {
check_update
-} {{} {struct_declarations.s2.i.3 struct_declarations.func_ptr_ptr struct_declarations.s2.i.4 struct_declarations.s2.i.5 struct_declarations.s2.i.6 struct_declarations.func_ptr struct_declarations.s2.i.7 struct_declarations.s2.i.8 struct_declarations.s2.i.9 struct_declarations.s2.u2.u1s1.d struct_declarations.func_ptr_struct struct_declarations.s2.u2.u1s1.e struct_declarations.u1 struct_declarations.char_ptr.*char_ptr struct_declarations.long_int struct_declarations.s2.u2.u1s2.func struct_declarations.integer struct_declarations.s2.u2 struct_declarations.s2.u2.u1s1.e.0 struct_declarations.s2.u2.u1s1.e.1 struct_declarations.long_array.0 struct_declarations.s2.u2.u1s1.e.2 struct_declarations.long_array.1 struct_declarations.u1.a struct_declarations.s2.u2.u1s1.e.3 struct_declarations.long_array.2 struct_declarations.u1.b struct_declarations.s2.u2.u1s1.e.4 struct_declarations.long_array.3 struct_declarations.u1.c struct_declarations.s2.u2.u1s1.e.5 struct_declarations.long_array.4 struct_declarations.u1.d struct_declarations.u1.b.*b struct_declarations.int_ptr_ptr.*int_ptr_ptr.**int_ptr_ptr struct_declarations.s2.u2.u1s1.e.6 struct_declarations.long_array.5 struct_declarations.s2.u2.u1s1.e.7 struct_declarations.long_array.6 struct_declarations.s2.u2.u1s1.e.8 struct_declarations.long_array.7 struct_declarations.s2.u2.u1s1.e.9 struct_declarations.long_array.8 struct_declarations.character struct_declarations.long_array.9 struct_declarations.int_ptr_ptr.*int_ptr_ptr struct_declarations.s2.u2.u1s1.func struct_declarations.s2.u2.u1s2.array_ptr struct_declarations.s2.u2.f struct_declarations.s2.u2.u1s1.foo struct_declarations.s2.u2.u1s1 struct_declarations.s2.u2.u1s2.array_ptr.0 struct_declarations.char_ptr struct_declarations.s2.u2.u1s2 struct_declarations.s2.u2.u1s2.array_ptr.1 struct_declarations.int_ptr_ptr struct_declarations.s2 struct_declarations.long_array struct_declarations.s2.g struct_declarations.s2.i.0 struct_declarations.s2.h struct_declarations.s2.i.1 struct_declarations.s2.i struct_declarations.s2.i.2}}
+} {{} {struct_declarations.s2.i.3 struct_declarations.func_ptr_ptr struct_declarations.s2.i.4 struct_declarations.s2.i.5 struct_declarations.s2.i.6 struct_declarations.func_ptr struct_declarations.s2.i.7 struct_declarations.s2.i.8 struct_declarations.s2.i.9 struct_declarations.s2.u2.u1s1.d struct_declarations.func_ptr_struct struct_declarations.s2.u2.u1s1.e struct_declarations.u1 struct_declarations.long_int struct_declarations.s2.u2.u1s2.func struct_declarations.integer struct_declarations.s2.u2 struct_declarations.s2.u2.u1s1.e.0 struct_declarations.s2.u2.u1s1.e.1 struct_declarations.long_array.0 struct_declarations.s2.u2.u1s1.e.2 struct_declarations.long_array.1 struct_declarations.u1.a struct_declarations.s2.u2.u1s1.e.3 struct_declarations.long_array.2 struct_declarations.u1.b struct_declarations.s2.u2.u1s1.e.4 struct_declarations.long_array.3 struct_declarations.u1.c struct_declarations.s2.u2.u1s1.e.5 struct_declarations.long_array.4 struct_declarations.u1.d struct_declarations.int_ptr_ptr.*int_ptr_ptr.**int_ptr_ptr struct_declarations.s2.u2.u1s1.e.6 struct_declarations.long_array.5 struct_declarations.s2.u2.u1s1.e.7 struct_declarations.long_array.6 struct_declarations.s2.u2.u1s1.e.8 struct_declarations.long_array.7 struct_declarations.s2.u2.u1s1.e.9 struct_declarations.long_array.8 struct_declarations.character struct_declarations.long_array.9 struct_declarations.int_ptr_ptr.*int_ptr_ptr struct_declarations.s2.u2.u1s1.func struct_declarations.s2.u2.u1s2.array_ptr struct_declarations.s2.u2.f struct_declarations.s2.u2.u1s1.foo struct_declarations struct_declarations.s2.u2.u1s1 struct_declarations.s2.u2.u1s2.array_ptr.0 struct_declarations.char_ptr struct_declarations.s2.u2.u1s2 struct_declarations.s2.u2.u1s2.array_ptr.1 struct_declarations.int_ptr_ptr struct_declarations.s2 struct_declarations.long_array struct_declarations.s2.g struct_declarations.s2.i.0 struct_declarations.s2.h struct_declarations.s2.i.1 struct_declarations.s2.i struct_declarations.s2.i.2} {}}
# Step over "struct_declarations.integer = 123;"
gdb_cmd "step"
@@ -1184,7 +1182,7 @@ gdb_cmd "step"
# Desc: check that integer changed
gdbtk_test c_variable-5.2 {check that integer changed} {
check_update
-} {struct_declarations.integer {struct_declarations.s2.i.3 struct_declarations.func_ptr_ptr struct_declarations.s2.i.4 struct_declarations.s2.i.5 struct_declarations.s2.i.6 struct_declarations.func_ptr struct_declarations.s2.i.7 struct_declarations.s2.i.8 struct_declarations.s2.i.9 struct_declarations.s2.u2.u1s1.d struct_declarations.func_ptr_struct struct_declarations.s2.u2.u1s1.e struct_declarations.u1 struct_declarations.char_ptr.*char_ptr struct_declarations.long_int struct_declarations.s2.u2.u1s2.func struct_declarations.integer struct_declarations.s2.u2 struct_declarations.s2.u2.u1s1.e.0 struct_declarations.s2.u2.u1s1.e.1 struct_declarations.long_array.0 struct_declarations.s2.u2.u1s1.e.2 struct_declarations.long_array.1 struct_declarations.u1.a struct_declarations.s2.u2.u1s1.e.3 struct_declarations.long_array.2 struct_declarations.u1.b struct_declarations.s2.u2.u1s1.e.4 struct_declarations.long_array.3 struct_declarations.u1.c struct_declarations.s2.u2.u1s1.e.5 struct_declarations.long_array.4 struct_declarations.u1.d struct_declarations.u1.b.*b struct_declarations.int_ptr_ptr.*int_ptr_ptr.**int_ptr_ptr struct_declarations.s2.u2.u1s1.e.6 struct_declarations.long_array.5 struct_declarations.s2.u2.u1s1.e.7 struct_declarations.long_array.6 struct_declarations.s2.u2.u1s1.e.8 struct_declarations.long_array.7 struct_declarations.s2.u2.u1s1.e.9 struct_declarations.long_array.8 struct_declarations.character struct_declarations.long_array.9 struct_declarations.int_ptr_ptr.*int_ptr_ptr struct_declarations.s2.u2.u1s1.func struct_declarations.s2.u2.u1s2.array_ptr struct_declarations.s2.u2.f struct_declarations.s2.u2.u1s1.foo struct_declarations.s2.u2.u1s1 struct_declarations.s2.u2.u1s2.array_ptr.0 struct_declarations.char_ptr struct_declarations.s2.u2.u1s2 struct_declarations.s2.u2.u1s2.array_ptr.1 struct_declarations.int_ptr_ptr struct_declarations.s2 struct_declarations.long_array struct_declarations.s2.g struct_declarations.s2.i.0 struct_declarations.s2.h struct_declarations.s2.i.1 struct_declarations.s2.i struct_declarations.s2.i.2}}
+} {struct_declarations.integer {struct_declarations.s2.i.3 struct_declarations.func_ptr_ptr struct_declarations.s2.i.4 struct_declarations.s2.i.5 struct_declarations.s2.i.6 struct_declarations.func_ptr struct_declarations.s2.i.7 struct_declarations.s2.i.8 struct_declarations.s2.i.9 struct_declarations.s2.u2.u1s1.d struct_declarations.func_ptr_struct struct_declarations.s2.u2.u1s1.e struct_declarations.u1 struct_declarations.long_int struct_declarations.s2.u2.u1s2.func struct_declarations.s2.u2 struct_declarations.s2.u2.u1s1.e.0 struct_declarations.s2.u2.u1s1.e.1 struct_declarations.long_array.0 struct_declarations.s2.u2.u1s1.e.2 struct_declarations.long_array.1 struct_declarations.u1.a struct_declarations.s2.u2.u1s1.e.3 struct_declarations.long_array.2 struct_declarations.u1.b struct_declarations.s2.u2.u1s1.e.4 struct_declarations.long_array.3 struct_declarations.u1.c struct_declarations.s2.u2.u1s1.e.5 struct_declarations.long_array.4 struct_declarations.u1.d struct_declarations.int_ptr_ptr.*int_ptr_ptr.**int_ptr_ptr struct_declarations.s2.u2.u1s1.e.6 struct_declarations.long_array.5 struct_declarations.s2.u2.u1s1.e.7 struct_declarations.long_array.6 struct_declarations.s2.u2.u1s1.e.8 struct_declarations.long_array.7 struct_declarations.s2.u2.u1s1.e.9 struct_declarations.long_array.8 struct_declarations.character struct_declarations.long_array.9 struct_declarations.int_ptr_ptr.*int_ptr_ptr struct_declarations.s2.u2.u1s1.func struct_declarations.s2.u2.u1s2.array_ptr struct_declarations.s2.u2.f struct_declarations.s2.u2.u1s1.foo struct_declarations struct_declarations.s2.u2.u1s1 struct_declarations.s2.u2.u1s2.array_ptr.0 struct_declarations.char_ptr struct_declarations.s2.u2.u1s2 struct_declarations.s2.u2.u1s2.array_ptr.1 struct_declarations.int_ptr_ptr struct_declarations.s2 struct_declarations.long_array struct_declarations.s2.g struct_declarations.s2.i.0 struct_declarations.s2.h struct_declarations.s2.i.1 struct_declarations.s2.i struct_declarations.s2.i.2} {}}
# Step over:
# weird->char_ptr = "hello";
@@ -1198,7 +1196,7 @@ for {set i 0} {$i < 3} {incr i} {
# Desc: check that char_ptr changed
gdbtk_test c_variable-5.3 {check that char_ptr changed} {
check_update
-} {{{struct_declarations.char_ptr struct_declarations.char_ptr.*char_ptr}} {struct_declarations.s2.i.3 struct_declarations.func_ptr_ptr struct_declarations.s2.i.4 struct_declarations.s2.i.5 struct_declarations.s2.i.6 struct_declarations.func_ptr struct_declarations.s2.i.7 struct_declarations.s2.i.8 struct_declarations.s2.i.9 struct_declarations.s2.u2.u1s1.d struct_declarations.func_ptr_struct struct_declarations.s2.u2.u1s1.e struct_declarations.u1 struct_declarations.char_ptr.*char_ptr struct_declarations.long_int struct_declarations.s2.u2.u1s2.func struct_declarations.integer struct_declarations.s2.u2 struct_declarations.s2.u2.u1s1.e.0 struct_declarations.s2.u2.u1s1.e.1 struct_declarations.long_array.0 struct_declarations.s2.u2.u1s1.e.2 struct_declarations.long_array.1 struct_declarations.u1.a struct_declarations.s2.u2.u1s1.e.3 struct_declarations.long_array.2 struct_declarations.u1.b struct_declarations.s2.u2.u1s1.e.4 struct_declarations.long_array.3 struct_declarations.u1.c struct_declarations.s2.u2.u1s1.e.5 struct_declarations.long_array.4 struct_declarations.u1.d struct_declarations.u1.b.*b struct_declarations.int_ptr_ptr.*int_ptr_ptr.**int_ptr_ptr struct_declarations.s2.u2.u1s1.e.6 struct_declarations.long_array.5 struct_declarations.s2.u2.u1s1.e.7 struct_declarations.long_array.6 struct_declarations.s2.u2.u1s1.e.8 struct_declarations.long_array.7 struct_declarations.s2.u2.u1s1.e.9 struct_declarations.long_array.8 struct_declarations.character struct_declarations.long_array.9 struct_declarations.int_ptr_ptr.*int_ptr_ptr struct_declarations.s2.u2.u1s1.func struct_declarations.s2.u2.u1s2.array_ptr struct_declarations.s2.u2.f struct_declarations.s2.u2.u1s1.foo struct_declarations.s2.u2.u1s1 struct_declarations.s2.u2.u1s2.array_ptr.0 struct_declarations.char_ptr struct_declarations.s2.u2.u1s2 struct_declarations.s2.u2.u1s2.array_ptr.1 struct_declarations.int_ptr_ptr struct_declarations.s2 struct_declarations.long_array struct_declarations.s2.g struct_declarations.s2.i.0 struct_declarations.s2.h struct_declarations.s2.i.1 struct_declarations.s2.i struct_declarations.s2.i.2}}
+} {struct_declarations.char_ptr {struct_declarations.s2.i.3 struct_declarations.func_ptr_ptr struct_declarations.s2.i.4 struct_declarations.s2.i.5 struct_declarations.s2.i.6 struct_declarations.func_ptr struct_declarations.s2.i.7 struct_declarations.s2.i.8 struct_declarations.s2.i.9 struct_declarations.s2.u2.u1s1.d struct_declarations.func_ptr_struct struct_declarations.s2.u2.u1s1.e struct_declarations.u1 struct_declarations.long_int struct_declarations.s2.u2.u1s2.func struct_declarations.integer struct_declarations.s2.u2 struct_declarations.s2.u2.u1s1.e.0 struct_declarations.s2.u2.u1s1.e.1 struct_declarations.long_array.0 struct_declarations.s2.u2.u1s1.e.2 struct_declarations.long_array.1 struct_declarations.u1.a struct_declarations.s2.u2.u1s1.e.3 struct_declarations.long_array.2 struct_declarations.u1.b struct_declarations.s2.u2.u1s1.e.4 struct_declarations.long_array.3 struct_declarations.u1.c struct_declarations.s2.u2.u1s1.e.5 struct_declarations.long_array.4 struct_declarations.u1.d struct_declarations.int_ptr_ptr.*int_ptr_ptr.**int_ptr_ptr struct_declarations.s2.u2.u1s1.e.6 struct_declarations.long_array.5 struct_declarations.s2.u2.u1s1.e.7 struct_declarations.long_array.6 struct_declarations.s2.u2.u1s1.e.8 struct_declarations.long_array.7 struct_declarations.s2.u2.u1s1.e.9 struct_declarations.long_array.8 struct_declarations.character struct_declarations.long_array.9 struct_declarations.int_ptr_ptr.*int_ptr_ptr struct_declarations.s2.u2.u1s1.func struct_declarations.s2.u2.u1s2.array_ptr struct_declarations.s2.u2.f struct_declarations.s2.u2.u1s1.foo struct_declarations struct_declarations.s2.u2.u1s1 struct_declarations.s2.u2.u1s2.array_ptr.0 struct_declarations.s2.u2.u1s2 struct_declarations.s2.u2.u1s2.array_ptr.1 struct_declarations.int_ptr_ptr struct_declarations.s2 struct_declarations.long_array struct_declarations.s2.g struct_declarations.s2.i.0 struct_declarations.s2.h struct_declarations.s2.i.1 struct_declarations.s2.i struct_declarations.s2.i.2} {}}
# Step over "struct_declarations.int_ptr_ptr = &foo;"
gdb_cmd "step"
@@ -1207,7 +1205,7 @@ gdb_cmd "step"
# Desc: check that int_ptr_ptr and children changed
gdbtk_test c_variable-5.4 {check that int_ptr_ptr and children changed} {
check_update
-} {{{struct_declarations.int_ptr_ptr struct_declarations.int_ptr_ptr.*int_ptr_ptr struct_declarations.int_ptr_ptr.*int_ptr_ptr.**int_ptr_ptr}} {struct_declarations.s2.i.3 struct_declarations.func_ptr_ptr struct_declarations.s2.i.4 struct_declarations.s2.i.5 struct_declarations.s2.i.6 struct_declarations.func_ptr struct_declarations.s2.i.7 struct_declarations.s2.i.8 struct_declarations.s2.i.9 struct_declarations.s2.u2.u1s1.d struct_declarations.func_ptr_struct struct_declarations.s2.u2.u1s1.e struct_declarations.u1 struct_declarations.char_ptr.*char_ptr struct_declarations.long_int struct_declarations.s2.u2.u1s2.func struct_declarations.integer struct_declarations.s2.u2 struct_declarations.s2.u2.u1s1.e.0 struct_declarations.s2.u2.u1s1.e.1 struct_declarations.long_array.0 struct_declarations.s2.u2.u1s1.e.2 struct_declarations.long_array.1 struct_declarations.u1.a struct_declarations.s2.u2.u1s1.e.3 struct_declarations.long_array.2 struct_declarations.u1.b struct_declarations.s2.u2.u1s1.e.4 struct_declarations.long_array.3 struct_declarations.u1.c struct_declarations.s2.u2.u1s1.e.5 struct_declarations.long_array.4 struct_declarations.u1.d struct_declarations.u1.b.*b struct_declarations.int_ptr_ptr.*int_ptr_ptr.**int_ptr_ptr struct_declarations.s2.u2.u1s1.e.6 struct_declarations.long_array.5 struct_declarations.s2.u2.u1s1.e.7 struct_declarations.long_array.6 struct_declarations.s2.u2.u1s1.e.8 struct_declarations.long_array.7 struct_declarations.s2.u2.u1s1.e.9 struct_declarations.long_array.8 struct_declarations.character struct_declarations.long_array.9 struct_declarations.int_ptr_ptr.*int_ptr_ptr struct_declarations.s2.u2.u1s1.func struct_declarations.s2.u2.u1s2.array_ptr struct_declarations.s2.u2.f struct_declarations.s2.u2.u1s1.foo struct_declarations.s2.u2.u1s1 struct_declarations.s2.u2.u1s2.array_ptr.0 struct_declarations.char_ptr struct_declarations.s2.u2.u1s2 struct_declarations.s2.u2.u1s2.array_ptr.1 struct_declarations.int_ptr_ptr struct_declarations.s2 struct_declarations.long_array struct_declarations.s2.g struct_declarations.s2.i.0 struct_declarations.s2.h struct_declarations.s2.i.1 struct_declarations.s2.i struct_declarations.s2.i.2}}
+} {{struct_declarations.int_ptr_ptr struct_declarations.int_ptr_ptr.*int_ptr_ptr struct_declarations.int_ptr_ptr.*int_ptr_ptr.**int_ptr_ptr} {struct_declarations.s2.i.3 struct_declarations.func_ptr_ptr struct_declarations.s2.i.4 struct_declarations.s2.i.5 struct_declarations.s2.i.6 struct_declarations.func_ptr struct_declarations.s2.i.7 struct_declarations.s2.i.8 struct_declarations.s2.i.9 struct_declarations.s2.u2.u1s1.d struct_declarations.func_ptr_struct struct_declarations.s2.u2.u1s1.e struct_declarations.u1 struct_declarations.long_int struct_declarations.s2.u2.u1s2.func struct_declarations.integer struct_declarations.s2.u2 struct_declarations.s2.u2.u1s1.e.0 struct_declarations.s2.u2.u1s1.e.1 struct_declarations.long_array.0 struct_declarations.s2.u2.u1s1.e.2 struct_declarations.long_array.1 struct_declarations.u1.a struct_declarations.s2.u2.u1s1.e.3 struct_declarations.long_array.2 struct_declarations.u1.b struct_declarations.s2.u2.u1s1.e.4 struct_declarations.long_array.3 struct_declarations.u1.c struct_declarations.s2.u2.u1s1.e.5 struct_declarations.long_array.4 struct_declarations.u1.d struct_declarations.s2.u2.u1s1.e.6 struct_declarations.long_array.5 struct_declarations.s2.u2.u1s1.e.7 struct_declarations.long_array.6 struct_declarations.s2.u2.u1s1.e.8 struct_declarations.long_array.7 struct_declarations.s2.u2.u1s1.e.9 struct_declarations.long_array.8 struct_declarations.character struct_declarations.long_array.9 struct_declarations.s2.u2.u1s1.func struct_declarations.s2.u2.u1s2.array_ptr struct_declarations.s2.u2.f struct_declarations.s2.u2.u1s1.foo struct_declarations struct_declarations.s2.u2.u1s1 struct_declarations.s2.u2.u1s2.array_ptr.0 struct_declarations.char_ptr struct_declarations.s2.u2.u1s2 struct_declarations.s2.u2.u1s2.array_ptr.1 struct_declarations.s2 struct_declarations.long_array struct_declarations.s2.g struct_declarations.s2.i.0 struct_declarations.s2.h struct_declarations.s2.i.1 struct_declarations.s2.i struct_declarations.s2.i.2} {}}
# Step over "weird->long_array[0] = 1234;"
gdb_cmd "step"
@@ -1216,7 +1214,7 @@ gdb_cmd "step"
# Desc: check that long_array[0] changed
gdbtk_test c_variable-5.5 {check that long_array[0] changed} {
check_update
-} {struct_declarations.long_array.0 {struct_declarations.s2.i.3 struct_declarations.func_ptr_ptr struct_declarations.s2.i.4 struct_declarations.s2.i.5 struct_declarations.s2.i.6 struct_declarations.func_ptr struct_declarations.s2.i.7 struct_declarations.s2.i.8 struct_declarations.s2.i.9 struct_declarations.s2.u2.u1s1.d struct_declarations.func_ptr_struct struct_declarations.s2.u2.u1s1.e struct_declarations.u1 struct_declarations.char_ptr.*char_ptr struct_declarations.long_int struct_declarations.s2.u2.u1s2.func struct_declarations.integer struct_declarations.s2.u2 struct_declarations.s2.u2.u1s1.e.0 struct_declarations.s2.u2.u1s1.e.1 struct_declarations.long_array.0 struct_declarations.s2.u2.u1s1.e.2 struct_declarations.long_array.1 struct_declarations.u1.a struct_declarations.s2.u2.u1s1.e.3 struct_declarations.long_array.2 struct_declarations.u1.b struct_declarations.s2.u2.u1s1.e.4 struct_declarations.long_array.3 struct_declarations.u1.c struct_declarations.s2.u2.u1s1.e.5 struct_declarations.long_array.4 struct_declarations.u1.d struct_declarations.u1.b.*b struct_declarations.int_ptr_ptr.*int_ptr_ptr.**int_ptr_ptr struct_declarations.s2.u2.u1s1.e.6 struct_declarations.long_array.5 struct_declarations.s2.u2.u1s1.e.7 struct_declarations.long_array.6 struct_declarations.s2.u2.u1s1.e.8 struct_declarations.long_array.7 struct_declarations.s2.u2.u1s1.e.9 struct_declarations.long_array.8 struct_declarations.character struct_declarations.long_array.9 struct_declarations.int_ptr_ptr.*int_ptr_ptr struct_declarations.s2.u2.u1s1.func struct_declarations.s2.u2.u1s2.array_ptr struct_declarations.s2.u2.f struct_declarations.s2.u2.u1s1.foo struct_declarations.s2.u2.u1s1 struct_declarations.s2.u2.u1s2.array_ptr.0 struct_declarations.char_ptr struct_declarations.s2.u2.u1s2 struct_declarations.s2.u2.u1s2.array_ptr.1 struct_declarations.int_ptr_ptr struct_declarations.s2 struct_declarations.long_array struct_declarations.s2.g struct_declarations.s2.i.0 struct_declarations.s2.h struct_declarations.s2.i.1 struct_declarations.s2.i struct_declarations.s2.i.2}}
+} {struct_declarations.long_array.0 {struct_declarations.s2.i.3 struct_declarations.func_ptr_ptr struct_declarations.s2.i.4 struct_declarations.s2.i.5 struct_declarations.s2.i.6 struct_declarations.func_ptr struct_declarations.s2.i.7 struct_declarations.s2.i.8 struct_declarations.s2.i.9 struct_declarations.s2.u2.u1s1.d struct_declarations.func_ptr_struct struct_declarations.s2.u2.u1s1.e struct_declarations.u1 struct_declarations.long_int struct_declarations.s2.u2.u1s2.func struct_declarations.integer struct_declarations.s2.u2 struct_declarations.s2.u2.u1s1.e.0 struct_declarations.s2.u2.u1s1.e.1 struct_declarations.s2.u2.u1s1.e.2 struct_declarations.long_array.1 struct_declarations.u1.a struct_declarations.s2.u2.u1s1.e.3 struct_declarations.long_array.2 struct_declarations.u1.b struct_declarations.s2.u2.u1s1.e.4 struct_declarations.long_array.3 struct_declarations.u1.c struct_declarations.s2.u2.u1s1.e.5 struct_declarations.long_array.4 struct_declarations.u1.d struct_declarations.int_ptr_ptr.*int_ptr_ptr.**int_ptr_ptr struct_declarations.s2.u2.u1s1.e.6 struct_declarations.long_array.5 struct_declarations.s2.u2.u1s1.e.7 struct_declarations.long_array.6 struct_declarations.s2.u2.u1s1.e.8 struct_declarations.long_array.7 struct_declarations.s2.u2.u1s1.e.9 struct_declarations.long_array.8 struct_declarations.character struct_declarations.long_array.9 struct_declarations.int_ptr_ptr.*int_ptr_ptr struct_declarations.s2.u2.u1s1.func struct_declarations.s2.u2.u1s2.array_ptr struct_declarations.s2.u2.f struct_declarations.s2.u2.u1s1.foo struct_declarations struct_declarations.s2.u2.u1s1 struct_declarations.s2.u2.u1s2.array_ptr.0 struct_declarations.char_ptr struct_declarations.s2.u2.u1s2 struct_declarations.s2.u2.u1s2.array_ptr.1 struct_declarations.int_ptr_ptr struct_declarations.s2 struct_declarations.long_array struct_declarations.s2.g struct_declarations.s2.i.0 struct_declarations.s2.h struct_declarations.s2.i.1 struct_declarations.s2.i struct_declarations.s2.i.2} {}}
# Step over "struct_declarations.long_array[1] = 2345;"
gdb_cmd "step"
@@ -1225,7 +1223,7 @@ gdb_cmd "step"
# Desc: check that long_array[1] changed
gdbtk_test c_variable-5.6 {check that long_array[1] changed} {
check_update
-} {struct_declarations.long_array.1 {struct_declarations.s2.i.3 struct_declarations.func_ptr_ptr struct_declarations.s2.i.4 struct_declarations.s2.i.5 struct_declarations.s2.i.6 struct_declarations.func_ptr struct_declarations.s2.i.7 struct_declarations.s2.i.8 struct_declarations.s2.i.9 struct_declarations.s2.u2.u1s1.d struct_declarations.func_ptr_struct struct_declarations.s2.u2.u1s1.e struct_declarations.u1 struct_declarations.char_ptr.*char_ptr struct_declarations.long_int struct_declarations.s2.u2.u1s2.func struct_declarations.integer struct_declarations.s2.u2 struct_declarations.s2.u2.u1s1.e.0 struct_declarations.s2.u2.u1s1.e.1 struct_declarations.long_array.0 struct_declarations.s2.u2.u1s1.e.2 struct_declarations.long_array.1 struct_declarations.u1.a struct_declarations.s2.u2.u1s1.e.3 struct_declarations.long_array.2 struct_declarations.u1.b struct_declarations.s2.u2.u1s1.e.4 struct_declarations.long_array.3 struct_declarations.u1.c struct_declarations.s2.u2.u1s1.e.5 struct_declarations.long_array.4 struct_declarations.u1.d struct_declarations.u1.b.*b struct_declarations.int_ptr_ptr.*int_ptr_ptr.**int_ptr_ptr struct_declarations.s2.u2.u1s1.e.6 struct_declarations.long_array.5 struct_declarations.s2.u2.u1s1.e.7 struct_declarations.long_array.6 struct_declarations.s2.u2.u1s1.e.8 struct_declarations.long_array.7 struct_declarations.s2.u2.u1s1.e.9 struct_declarations.long_array.8 struct_declarations.character struct_declarations.long_array.9 struct_declarations.int_ptr_ptr.*int_ptr_ptr struct_declarations.s2.u2.u1s1.func struct_declarations.s2.u2.u1s2.array_ptr struct_declarations.s2.u2.f struct_declarations.s2.u2.u1s1.foo struct_declarations.s2.u2.u1s1 struct_declarations.s2.u2.u1s2.array_ptr.0 struct_declarations.char_ptr struct_declarations.s2.u2.u1s2 struct_declarations.s2.u2.u1s2.array_ptr.1 struct_declarations.int_ptr_ptr struct_declarations.s2 struct_declarations.long_array struct_declarations.s2.g struct_declarations.s2.i.0 struct_declarations.s2.h struct_declarations.s2.i.1 struct_declarations.s2.i struct_declarations.s2.i.2}}
+} {struct_declarations.long_array.1 {struct_declarations.s2.i.3 struct_declarations.func_ptr_ptr struct_declarations.s2.i.4 struct_declarations.s2.i.5 struct_declarations.s2.i.6 struct_declarations.func_ptr struct_declarations.s2.i.7 struct_declarations.s2.i.8 struct_declarations.s2.i.9 struct_declarations.s2.u2.u1s1.d struct_declarations.func_ptr_struct struct_declarations.s2.u2.u1s1.e struct_declarations.u1 struct_declarations.long_int struct_declarations.s2.u2.u1s2.func struct_declarations.integer struct_declarations.s2.u2 struct_declarations.s2.u2.u1s1.e.0 struct_declarations.s2.u2.u1s1.e.1 struct_declarations.long_array.0 struct_declarations.s2.u2.u1s1.e.2 struct_declarations.u1.a struct_declarations.s2.u2.u1s1.e.3 struct_declarations.long_array.2 struct_declarations.u1.b struct_declarations.s2.u2.u1s1.e.4 struct_declarations.long_array.3 struct_declarations.u1.c struct_declarations.s2.u2.u1s1.e.5 struct_declarations.long_array.4 struct_declarations.u1.d struct_declarations.int_ptr_ptr.*int_ptr_ptr.**int_ptr_ptr struct_declarations.s2.u2.u1s1.e.6 struct_declarations.long_array.5 struct_declarations.s2.u2.u1s1.e.7 struct_declarations.long_array.6 struct_declarations.s2.u2.u1s1.e.8 struct_declarations.long_array.7 struct_declarations.s2.u2.u1s1.e.9 struct_declarations.long_array.8 struct_declarations.character struct_declarations.long_array.9 struct_declarations.int_ptr_ptr.*int_ptr_ptr struct_declarations.s2.u2.u1s1.func struct_declarations.s2.u2.u1s2.array_ptr struct_declarations.s2.u2.f struct_declarations.s2.u2.u1s1.foo struct_declarations struct_declarations.s2.u2.u1s1 struct_declarations.s2.u2.u1s2.array_ptr.0 struct_declarations.char_ptr struct_declarations.s2.u2.u1s2 struct_declarations.s2.u2.u1s2.array_ptr.1 struct_declarations.int_ptr_ptr struct_declarations.s2 struct_declarations.long_array struct_declarations.s2.g struct_declarations.s2.i.0 struct_declarations.s2.h struct_declarations.s2.i.1 struct_declarations.s2.i struct_declarations.s2.i.2} {}}
# Step over "weird->long_array[2] = 3456;"
gdb_cmd "step"
@@ -1234,7 +1232,7 @@ gdb_cmd "step"
# Desc: check that long_array[2] changed
gdbtk_test c_variable-5.7 {check that long_array[2] changed} {
check_update
-} {struct_declarations.long_array.2 {struct_declarations.s2.i.3 struct_declarations.func_ptr_ptr struct_declarations.s2.i.4 struct_declarations.s2.i.5 struct_declarations.s2.i.6 struct_declarations.func_ptr struct_declarations.s2.i.7 struct_declarations.s2.i.8 struct_declarations.s2.i.9 struct_declarations.s2.u2.u1s1.d struct_declarations.func_ptr_struct struct_declarations.s2.u2.u1s1.e struct_declarations.u1 struct_declarations.char_ptr.*char_ptr struct_declarations.long_int struct_declarations.s2.u2.u1s2.func struct_declarations.integer struct_declarations.s2.u2 struct_declarations.s2.u2.u1s1.e.0 struct_declarations.s2.u2.u1s1.e.1 struct_declarations.long_array.0 struct_declarations.s2.u2.u1s1.e.2 struct_declarations.long_array.1 struct_declarations.u1.a struct_declarations.s2.u2.u1s1.e.3 struct_declarations.long_array.2 struct_declarations.u1.b struct_declarations.s2.u2.u1s1.e.4 struct_declarations.long_array.3 struct_declarations.u1.c struct_declarations.s2.u2.u1s1.e.5 struct_declarations.long_array.4 struct_declarations.u1.d struct_declarations.u1.b.*b struct_declarations.int_ptr_ptr.*int_ptr_ptr.**int_ptr_ptr struct_declarations.s2.u2.u1s1.e.6 struct_declarations.long_array.5 struct_declarations.s2.u2.u1s1.e.7 struct_declarations.long_array.6 struct_declarations.s2.u2.u1s1.e.8 struct_declarations.long_array.7 struct_declarations.s2.u2.u1s1.e.9 struct_declarations.long_array.8 struct_declarations.character struct_declarations.long_array.9 struct_declarations.int_ptr_ptr.*int_ptr_ptr struct_declarations.s2.u2.u1s1.func struct_declarations.s2.u2.u1s2.array_ptr struct_declarations.s2.u2.f struct_declarations.s2.u2.u1s1.foo struct_declarations.s2.u2.u1s1 struct_declarations.s2.u2.u1s2.array_ptr.0 struct_declarations.char_ptr struct_declarations.s2.u2.u1s2 struct_declarations.s2.u2.u1s2.array_ptr.1 struct_declarations.int_ptr_ptr struct_declarations.s2 struct_declarations.long_array struct_declarations.s2.g struct_declarations.s2.i.0 struct_declarations.s2.h struct_declarations.s2.i.1 struct_declarations.s2.i struct_declarations.s2.i.2}}
+} {struct_declarations.long_array.2 {struct_declarations.s2.i.3 struct_declarations.func_ptr_ptr struct_declarations.s2.i.4 struct_declarations.s2.i.5 struct_declarations.s2.i.6 struct_declarations.func_ptr struct_declarations.s2.i.7 struct_declarations.s2.i.8 struct_declarations.s2.i.9 struct_declarations.s2.u2.u1s1.d struct_declarations.func_ptr_struct struct_declarations.s2.u2.u1s1.e struct_declarations.u1 struct_declarations.long_int struct_declarations.s2.u2.u1s2.func struct_declarations.integer struct_declarations.s2.u2 struct_declarations.s2.u2.u1s1.e.0 struct_declarations.s2.u2.u1s1.e.1 struct_declarations.long_array.0 struct_declarations.s2.u2.u1s1.e.2 struct_declarations.long_array.1 struct_declarations.u1.a struct_declarations.s2.u2.u1s1.e.3 struct_declarations.u1.b struct_declarations.s2.u2.u1s1.e.4 struct_declarations.long_array.3 struct_declarations.u1.c struct_declarations.s2.u2.u1s1.e.5 struct_declarations.long_array.4 struct_declarations.u1.d struct_declarations.int_ptr_ptr.*int_ptr_ptr.**int_ptr_ptr struct_declarations.s2.u2.u1s1.e.6 struct_declarations.long_array.5 struct_declarations.s2.u2.u1s1.e.7 struct_declarations.long_array.6 struct_declarations.s2.u2.u1s1.e.8 struct_declarations.long_array.7 struct_declarations.s2.u2.u1s1.e.9 struct_declarations.long_array.8 struct_declarations.character struct_declarations.long_array.9 struct_declarations.int_ptr_ptr.*int_ptr_ptr struct_declarations.s2.u2.u1s1.func struct_declarations.s2.u2.u1s2.array_ptr struct_declarations.s2.u2.f struct_declarations.s2.u2.u1s1.foo struct_declarations struct_declarations.s2.u2.u1s1 struct_declarations.s2.u2.u1s2.array_ptr.0 struct_declarations.char_ptr struct_declarations.s2.u2.u1s2 struct_declarations.s2.u2.u1s2.array_ptr.1 struct_declarations.int_ptr_ptr struct_declarations.s2 struct_declarations.long_array struct_declarations.s2.g struct_declarations.s2.i.0 struct_declarations.s2.h struct_declarations.s2.i.1 struct_declarations.s2.i struct_declarations.s2.i.2} {}}
# Step over:
# struct_declarations.long_array[3] = 4567;
@@ -1252,7 +1250,7 @@ for {set i 0} {$i < 7} {incr i} {
# Desc: check that long_array[3-9] changed
gdbtk_test c_variable-5.8 {check that long_array[3-9] changed} {
check_update
-} {{{struct_declarations.long_array.3 struct_declarations.long_array.4 struct_declarations.long_array.5 struct_declarations.long_array.6 struct_declarations.long_array.7 struct_declarations.long_array.8 struct_declarations.long_array.9}} {struct_declarations.s2.i.3 struct_declarations.func_ptr_ptr struct_declarations.s2.i.4 struct_declarations.s2.i.5 struct_declarations.s2.i.6 struct_declarations.func_ptr struct_declarations.s2.i.7 struct_declarations.s2.i.8 struct_declarations.s2.i.9 struct_declarations.s2.u2.u1s1.d struct_declarations.func_ptr_struct struct_declarations.s2.u2.u1s1.e struct_declarations.u1 struct_declarations.char_ptr.*char_ptr struct_declarations.long_int struct_declarations.s2.u2.u1s2.func struct_declarations.integer struct_declarations.s2.u2 struct_declarations.s2.u2.u1s1.e.0 struct_declarations.s2.u2.u1s1.e.1 struct_declarations.long_array.0 struct_declarations.s2.u2.u1s1.e.2 struct_declarations.long_array.1 struct_declarations.u1.a struct_declarations.s2.u2.u1s1.e.3 struct_declarations.long_array.2 struct_declarations.u1.b struct_declarations.s2.u2.u1s1.e.4 struct_declarations.long_array.3 struct_declarations.u1.c struct_declarations.s2.u2.u1s1.e.5 struct_declarations.long_array.4 struct_declarations.u1.d struct_declarations.u1.b.*b struct_declarations.int_ptr_ptr.*int_ptr_ptr.**int_ptr_ptr struct_declarations.s2.u2.u1s1.e.6 struct_declarations.long_array.5 struct_declarations.s2.u2.u1s1.e.7 struct_declarations.long_array.6 struct_declarations.s2.u2.u1s1.e.8 struct_declarations.long_array.7 struct_declarations.s2.u2.u1s1.e.9 struct_declarations.long_array.8 struct_declarations.character struct_declarations.long_array.9 struct_declarations.int_ptr_ptr.*int_ptr_ptr struct_declarations.s2.u2.u1s1.func struct_declarations.s2.u2.u1s2.array_ptr struct_declarations.s2.u2.f struct_declarations.s2.u2.u1s1.foo struct_declarations.s2.u2.u1s1 struct_declarations.s2.u2.u1s2.array_ptr.0 struct_declarations.char_ptr struct_declarations.s2.u2.u1s2 struct_declarations.s2.u2.u1s2.array_ptr.1 struct_declarations.int_ptr_ptr struct_declarations.s2 struct_declarations.long_array struct_declarations.s2.g struct_declarations.s2.i.0 struct_declarations.s2.h struct_declarations.s2.i.1 struct_declarations.s2.i struct_declarations.s2.i.2}}
+} {{struct_declarations.long_array.3 struct_declarations.long_array.4 struct_declarations.long_array.5 struct_declarations.long_array.6 struct_declarations.long_array.7 struct_declarations.long_array.8 struct_declarations.long_array.9} {struct_declarations.s2.i.3 struct_declarations.func_ptr_ptr struct_declarations.s2.i.4 struct_declarations.s2.i.5 struct_declarations.s2.i.6 struct_declarations.func_ptr struct_declarations.s2.i.7 struct_declarations.s2.i.8 struct_declarations.s2.i.9 struct_declarations.s2.u2.u1s1.d struct_declarations.func_ptr_struct struct_declarations.s2.u2.u1s1.e struct_declarations.u1 struct_declarations.long_int struct_declarations.s2.u2.u1s2.func struct_declarations.integer struct_declarations.s2.u2 struct_declarations.s2.u2.u1s1.e.0 struct_declarations.s2.u2.u1s1.e.1 struct_declarations.long_array.0 struct_declarations.s2.u2.u1s1.e.2 struct_declarations.long_array.1 struct_declarations.u1.a struct_declarations.s2.u2.u1s1.e.3 struct_declarations.long_array.2 struct_declarations.u1.b struct_declarations.s2.u2.u1s1.e.4 struct_declarations.u1.c struct_declarations.s2.u2.u1s1.e.5 struct_declarations.u1.d struct_declarations.int_ptr_ptr.*int_ptr_ptr.**int_ptr_ptr struct_declarations.s2.u2.u1s1.e.6 struct_declarations.s2.u2.u1s1.e.7 struct_declarations.s2.u2.u1s1.e.8 struct_declarations.s2.u2.u1s1.e.9 struct_declarations.character struct_declarations.int_ptr_ptr.*int_ptr_ptr struct_declarations.s2.u2.u1s1.func struct_declarations.s2.u2.u1s2.array_ptr struct_declarations.s2.u2.f struct_declarations.s2.u2.u1s1.foo struct_declarations struct_declarations.s2.u2.u1s1 struct_declarations.s2.u2.u1s2.array_ptr.0 struct_declarations.char_ptr struct_declarations.s2.u2.u1s2 struct_declarations.s2.u2.u1s2.array_ptr.1 struct_declarations.int_ptr_ptr struct_declarations.s2 struct_declarations.long_array struct_declarations.s2.g struct_declarations.s2.i.0 struct_declarations.s2.h struct_declarations.s2.i.1 struct_declarations.s2.i struct_declarations.s2.i.2} {}}
# Step over "weird->func_ptr = nothing;"
gdb_cmd "step"
@@ -1261,7 +1259,7 @@ gdb_cmd "step"
# Desc: check that func_ptr changed
gdbtk_test c_variable-5.9 {check that func_ptr changed} {
check_update
-} {struct_declarations.func_ptr {struct_declarations.s2.i.3 struct_declarations.func_ptr_ptr struct_declarations.s2.i.4 struct_declarations.s2.i.5 struct_declarations.s2.i.6 struct_declarations.func_ptr struct_declarations.s2.i.7 struct_declarations.s2.i.8 struct_declarations.s2.i.9 struct_declarations.s2.u2.u1s1.d struct_declarations.func_ptr_struct struct_declarations.s2.u2.u1s1.e struct_declarations.u1 struct_declarations.char_ptr.*char_ptr struct_declarations.long_int struct_declarations.s2.u2.u1s2.func struct_declarations.integer struct_declarations.s2.u2 struct_declarations.s2.u2.u1s1.e.0 struct_declarations.s2.u2.u1s1.e.1 struct_declarations.long_array.0 struct_declarations.s2.u2.u1s1.e.2 struct_declarations.long_array.1 struct_declarations.u1.a struct_declarations.s2.u2.u1s1.e.3 struct_declarations.long_array.2 struct_declarations.u1.b struct_declarations.s2.u2.u1s1.e.4 struct_declarations.long_array.3 struct_declarations.u1.c struct_declarations.s2.u2.u1s1.e.5 struct_declarations.long_array.4 struct_declarations.u1.d struct_declarations.u1.b.*b struct_declarations.int_ptr_ptr.*int_ptr_ptr.**int_ptr_ptr struct_declarations.s2.u2.u1s1.e.6 struct_declarations.long_array.5 struct_declarations.s2.u2.u1s1.e.7 struct_declarations.long_array.6 struct_declarations.s2.u2.u1s1.e.8 struct_declarations.long_array.7 struct_declarations.s2.u2.u1s1.e.9 struct_declarations.long_array.8 struct_declarations.character struct_declarations.long_array.9 struct_declarations.int_ptr_ptr.*int_ptr_ptr struct_declarations.s2.u2.u1s1.func struct_declarations.s2.u2.u1s2.array_ptr struct_declarations.s2.u2.f struct_declarations.s2.u2.u1s1.foo struct_declarations.s2.u2.u1s1 struct_declarations.s2.u2.u1s2.array_ptr.0 struct_declarations.char_ptr struct_declarations.s2.u2.u1s2 struct_declarations.s2.u2.u1s2.array_ptr.1 struct_declarations.int_ptr_ptr struct_declarations.s2 struct_declarations.long_array struct_declarations.s2.g struct_declarations.s2.i.0 struct_declarations.s2.h struct_declarations.s2.i.1 struct_declarations.s2.i struct_declarations.s2.i.2}}
+} {struct_declarations.func_ptr {struct_declarations.s2.i.3 struct_declarations.func_ptr_ptr struct_declarations.s2.i.4 struct_declarations.s2.i.5 struct_declarations.s2.i.6 struct_declarations.s2.i.7 struct_declarations.s2.i.8 struct_declarations.s2.i.9 struct_declarations.s2.u2.u1s1.d struct_declarations.func_ptr_struct struct_declarations.s2.u2.u1s1.e struct_declarations.u1 struct_declarations.long_int struct_declarations.s2.u2.u1s2.func struct_declarations.integer struct_declarations.s2.u2 struct_declarations.s2.u2.u1s1.e.0 struct_declarations.s2.u2.u1s1.e.1 struct_declarations.long_array.0 struct_declarations.s2.u2.u1s1.e.2 struct_declarations.long_array.1 struct_declarations.u1.a struct_declarations.s2.u2.u1s1.e.3 struct_declarations.long_array.2 struct_declarations.u1.b struct_declarations.s2.u2.u1s1.e.4 struct_declarations.long_array.3 struct_declarations.u1.c struct_declarations.s2.u2.u1s1.e.5 struct_declarations.long_array.4 struct_declarations.u1.d struct_declarations.int_ptr_ptr.*int_ptr_ptr.**int_ptr_ptr struct_declarations.s2.u2.u1s1.e.6 struct_declarations.long_array.5 struct_declarations.s2.u2.u1s1.e.7 struct_declarations.long_array.6 struct_declarations.s2.u2.u1s1.e.8 struct_declarations.long_array.7 struct_declarations.s2.u2.u1s1.e.9 struct_declarations.long_array.8 struct_declarations.character struct_declarations.long_array.9 struct_declarations.int_ptr_ptr.*int_ptr_ptr struct_declarations.s2.u2.u1s1.func struct_declarations.s2.u2.u1s2.array_ptr struct_declarations.s2.u2.f struct_declarations.s2.u2.u1s1.foo struct_declarations struct_declarations.s2.u2.u1s1 struct_declarations.s2.u2.u1s2.array_ptr.0 struct_declarations.char_ptr struct_declarations.s2.u2.u1s2 struct_declarations.s2.u2.u1s2.array_ptr.1 struct_declarations.int_ptr_ptr struct_declarations.s2 struct_declarations.long_array struct_declarations.s2.g struct_declarations.s2.i.0 struct_declarations.s2.h struct_declarations.s2.i.1 struct_declarations.s2.i struct_declarations.s2.i.2} {}}
# Delete all variables
delete_all_variables
@@ -1319,13 +1317,13 @@ gdbtk_test c_variable-5.16 {number of children of *(*(psnp->char_ptr))} {
# Desc: children of *(*(*(psnp->char_ptr)))
gdbtk_test c_variable-5.17 {children of *(*(*(psnp->char_ptr)))} {
get_children psnp->char_ptr.*psnp->char_ptr.**psnp->char_ptr.***psnp->char_ptr
-} {****psnp->char_ptr}
+} {}
# Test: c_variable-5.18
# Desc: number of children of *(*(*(psnp->char_ptr)))
gdbtk_test c_variable-5.18 {number of children of *(*(*(psnp->char_ptr)))} {
$var(psnp->char_ptr.*psnp->char_ptr.**psnp->char_ptr.***psnp->char_ptr) numChildren
-} {1}
+} {0}
# Test: c_variable-5.19
# Desc: create psnp->long_ptr
@@ -1475,13 +1473,13 @@ gdbtk_test c_variable-5.42 {number of children of **psnp->ptrs[0]->next->char_pt
# Desc: children of ***psnp->ptrs[0]->next->char_ptr
gdbtk_test c_variable-5.43 {children of ***psnp->ptrs[0]->next->char_ptr} {
get_children psnp->ptrs.0.next.char_ptr.*char_ptr.**char_ptr.***char_ptr
-} {****char_ptr}
+} {}
# Test: c_variable-5.44
# Desc: number of children of ***psnp->ptrs[0]->next->char_ptr
gdbtk_test c_variable-5.44 {number of children of ***psnp->ptrs[0]->next->char_ptr} {
$var(psnp->ptrs.0.next.char_ptr.*char_ptr.**char_ptr.***char_ptr) numChildren
-} {1}
+} {0}
# Test: c_variable-5.45
# Desc: children of psnp->ptrs[0]->next->next
@@ -1502,7 +1500,7 @@ gdb_cmd "step"
# Desc: check that psnp->char_ptr (and [0].char_ptr) changed
gdbtk_test c_variable-5.47 {check that psnp->char_ptr (and [0].char_ptr) changed} {
check_update
-} {{psnp->ptrs.0.char_ptr {psnp->char_ptr psnp->char_ptr.*psnp->char_ptr psnp->char_ptr.*psnp->char_ptr.**psnp->char_ptr psnp->char_ptr.*psnp->char_ptr.**psnp->char_ptr.***psnp->char_ptr psnp->char_ptr.*psnp->char_ptr.**psnp->char_ptr.***psnp->char_ptr.****psnp->char_ptr}} {psnp->ptrs.0.next psnp->ptrs.0.next.ptrs psnp->ptrs.0.next.next psnp->ptrs.0.next.next.char_ptr psnp->ptrs.0.next.next.long_ptr psnp->ptrs.0.next.char_ptr.*char_ptr.**char_ptr.***char_ptr psnp->char_ptr.*psnp->char_ptr.**psnp->char_ptr.***psnp->char_ptr.****psnp->char_ptr psnp->char_ptr.*psnp->char_ptr.**psnp->char_ptr psnp->ptrs.0.next.char_ptr.*char_ptr.**char_ptr psnp->ptrs.0.next.char_ptr psnp->ptrs.0.next.long_ptr psnp->ptrs.0.next.next.ptrs psnp->ptrs.0.next.char_ptr.*char_ptr psnp->long_ptr.*psnp->long_ptr.**psnp->long_ptr.***psnp->long_ptr.****psnp->long_ptr psnp->ptrs.0.next.next.next psnp->char_ptr.*psnp->char_ptr.**psnp->char_ptr.***psnp->char_ptr psnp->char_ptr.*psnp->char_ptr psnp->ptrs.0.next.next.ptrs.0 psnp->long_ptr.*psnp->long_ptr.**psnp->long_ptr.***psnp->long_ptr psnp->long_ptr.*psnp->long_ptr psnp->ptrs.0.next.next.ptrs.1 psnp->ptrs.0.next.next.ptrs.2 psnp->ptrs.0.char_ptr psnp->ptrs.0.long_ptr psnp->ptrs.0.next.char_ptr.*char_ptr.**char_ptr.***char_ptr.****char_ptr psnp->ptrs.0.ptrs psnp->ptrs.0 psnp->ptrs.1 psnp->ptrs.2 psnp->long_ptr.*psnp->long_ptr.**psnp->long_ptr}}
+} {{psnp->ptrs.0.char_ptr psnp->char_ptr psnp->char_ptr.*psnp->char_ptr psnp->char_ptr.*psnp->char_ptr.**psnp->char_ptr psnp->char_ptr.*psnp->char_ptr.**psnp->char_ptr.***psnp->char_ptr} {psnp->ptrs.0.next psnp->ptrs.0.next.ptrs psnp->ptrs.0.next.next psnp->ptrs.0.next.next.char_ptr psnp->ptrs.0.next.next.long_ptr psnp->ptrs.0.next.char_ptr.*char_ptr.**char_ptr.***char_ptr psnp->ptrs.0.next.char_ptr.*char_ptr.**char_ptr psnp->ptrs.0.next.char_ptr psnp->ptrs.0.next.long_ptr psnp->ptrs.0.next.next.ptrs psnp->ptrs.0.next.char_ptr.*char_ptr psnp->ptrs psnp->long_ptr.*psnp->long_ptr.**psnp->long_ptr.***psnp->long_ptr.****psnp->long_ptr psnp->ptrs.0.next.next.next psnp->ptrs.0.next.next.ptrs.0 psnp->long_ptr.*psnp->long_ptr.**psnp->long_ptr.***psnp->long_ptr psnp->long_ptr.*psnp->long_ptr psnp->ptrs.0.next.next.ptrs.1 psnp->ptrs.0.next.next.ptrs.2 psnp->ptrs.0.long_ptr psnp->long_ptr psnp->ptrs.0.ptrs psnp->ptrs.0 psnp->ptrs.1 psnp->ptrs.2 psnp->long_ptr.*psnp->long_ptr.**psnp->long_ptr} {}}
# Step over "snp1.char_ptr = &c3;"
gdb_cmd "step"
@@ -1511,7 +1509,7 @@ gdb_cmd "step"
# Desc: check that psnp->next->char_ptr (and [1].char_ptr) changed
gdbtk_test c_variable-5.48 {check that psnp->next->char_ptr (and [1].char_ptr) changed} {
check_update
-} {{{psnp->ptrs.0.next.char_ptr psnp->ptrs.0.next.char_ptr.*char_ptr psnp->ptrs.0.next.char_ptr.*char_ptr.**char_ptr psnp->ptrs.0.next.char_ptr.*char_ptr.**char_ptr.***char_ptr psnp->ptrs.0.next.char_ptr.*char_ptr.**char_ptr.***char_ptr.****char_ptr}} {psnp->ptrs.0.next psnp->ptrs.0.next.ptrs psnp->ptrs.0.next.next psnp->ptrs.0.next.next.char_ptr psnp->ptrs.0.next.next.long_ptr psnp->ptrs.0.next.char_ptr.*char_ptr.**char_ptr.***char_ptr psnp->char_ptr.*psnp->char_ptr.**psnp->char_ptr.***psnp->char_ptr.****psnp->char_ptr psnp->char_ptr.*psnp->char_ptr.**psnp->char_ptr psnp->ptrs.0.next.char_ptr.*char_ptr.**char_ptr psnp->ptrs.0.next.char_ptr psnp->ptrs.0.next.long_ptr psnp->ptrs.0.next.next.ptrs psnp->ptrs.0.next.char_ptr.*char_ptr psnp->long_ptr.*psnp->long_ptr.**psnp->long_ptr.***psnp->long_ptr.****psnp->long_ptr psnp->ptrs.0.next.next.next psnp->char_ptr.*psnp->char_ptr.**psnp->char_ptr.***psnp->char_ptr psnp->char_ptr.*psnp->char_ptr psnp->ptrs.0.next.next.ptrs.0 psnp->long_ptr.*psnp->long_ptr.**psnp->long_ptr.***psnp->long_ptr psnp->long_ptr.*psnp->long_ptr psnp->ptrs.0.next.next.ptrs.1 psnp->ptrs.0.next.next.ptrs.2 psnp->ptrs.0.char_ptr psnp->ptrs.0.long_ptr psnp->ptrs.0.next.char_ptr.*char_ptr.**char_ptr.***char_ptr.****char_ptr psnp->ptrs.0.ptrs psnp->ptrs.0 psnp->ptrs.1 psnp->ptrs.2 psnp->long_ptr.*psnp->long_ptr.**psnp->long_ptr}}
+} {{psnp->ptrs.0.next.char_ptr psnp->ptrs.0.next.char_ptr.*char_ptr psnp->ptrs.0.next.char_ptr.*char_ptr.**char_ptr psnp->ptrs.0.next.char_ptr.*char_ptr.**char_ptr.***char_ptr} {psnp->ptrs.0.next psnp->ptrs.0.next.ptrs psnp->ptrs.0.next.next psnp->ptrs.0.next.next.char_ptr psnp->ptrs.0.next.next.long_ptr psnp->char_ptr.*psnp->char_ptr.**psnp->char_ptr psnp->ptrs.0.next.long_ptr psnp->ptrs.0.next.next.ptrs psnp->ptrs psnp->long_ptr.*psnp->long_ptr.**psnp->long_ptr.***psnp->long_ptr.****psnp->long_ptr psnp->ptrs.0.next.next.next psnp->char_ptr.*psnp->char_ptr.**psnp->char_ptr.***psnp->char_ptr psnp->char_ptr.*psnp->char_ptr psnp->ptrs.0.next.next.ptrs.0 psnp->long_ptr.*psnp->long_ptr.**psnp->long_ptr.***psnp->long_ptr psnp->long_ptr.*psnp->long_ptr psnp->ptrs.0.next.next.ptrs.1 psnp->ptrs.0.next.next.ptrs.2 psnp->ptrs.0.char_ptr psnp->ptrs.0.long_ptr psnp->char_ptr psnp->long_ptr psnp->ptrs.0.ptrs psnp->ptrs.0 psnp->ptrs.1 psnp->ptrs.2 psnp->long_ptr.*psnp->long_ptr.**psnp->long_ptr} {}}
# Step over "snp2.char_ptr = &a3;"
gdb_cmd "step"
@@ -1520,7 +1518,7 @@ gdb_cmd "step"
# Desc: check that psnp->next->next->char_ptr (and [2].char_ptr) changed
gdbtk_test c_variable-5.49 {heck that psnp->next->next->char_ptr (and [2].char_ptr) changed} {
check_update
-} {psnp->ptrs.0.next.next.char_ptr {psnp->ptrs.0.next psnp->ptrs.0.next.ptrs psnp->ptrs.0.next.next psnp->ptrs.0.next.next.char_ptr psnp->ptrs.0.next.next.long_ptr psnp->ptrs.0.next.char_ptr.*char_ptr.**char_ptr.***char_ptr psnp->char_ptr.*psnp->char_ptr.**psnp->char_ptr.***psnp->char_ptr.****psnp->char_ptr psnp->char_ptr.*psnp->char_ptr.**psnp->char_ptr psnp->ptrs.0.next.char_ptr.*char_ptr.**char_ptr psnp->ptrs.0.next.char_ptr psnp->ptrs.0.next.long_ptr psnp->ptrs.0.next.next.ptrs psnp->ptrs.0.next.char_ptr.*char_ptr psnp->long_ptr.*psnp->long_ptr.**psnp->long_ptr.***psnp->long_ptr.****psnp->long_ptr psnp->ptrs.0.next.next.next psnp->char_ptr.*psnp->char_ptr.**psnp->char_ptr.***psnp->char_ptr psnp->char_ptr.*psnp->char_ptr psnp->ptrs.0.next.next.ptrs.0 psnp->long_ptr.*psnp->long_ptr.**psnp->long_ptr.***psnp->long_ptr psnp->long_ptr.*psnp->long_ptr psnp->ptrs.0.next.next.ptrs.1 psnp->ptrs.0.next.next.ptrs.2 psnp->ptrs.0.char_ptr psnp->ptrs.0.long_ptr psnp->ptrs.0.next.char_ptr.*char_ptr.**char_ptr.***char_ptr.****char_ptr psnp->ptrs.0.ptrs psnp->ptrs.0 psnp->ptrs.1 psnp->ptrs.2 psnp->long_ptr.*psnp->long_ptr.**psnp->long_ptr}}
+} {psnp->ptrs.0.next.next.char_ptr {psnp->ptrs.0.next psnp->ptrs.0.next.ptrs psnp->ptrs.0.next.next psnp->ptrs.0.next.next.long_ptr psnp->ptrs.0.next.char_ptr.*char_ptr.**char_ptr.***char_ptr psnp->char_ptr.*psnp->char_ptr.**psnp->char_ptr psnp->ptrs.0.next.char_ptr.*char_ptr.**char_ptr psnp->ptrs.0.next.char_ptr psnp->ptrs.0.next.long_ptr psnp->ptrs.0.next.next.ptrs psnp->ptrs.0.next.char_ptr.*char_ptr psnp->ptrs psnp->long_ptr.*psnp->long_ptr.**psnp->long_ptr.***psnp->long_ptr.****psnp->long_ptr psnp->ptrs.0.next.next.next psnp->char_ptr.*psnp->char_ptr.**psnp->char_ptr.***psnp->char_ptr psnp->char_ptr.*psnp->char_ptr psnp->ptrs.0.next.next.ptrs.0 psnp->long_ptr.*psnp->long_ptr.**psnp->long_ptr.***psnp->long_ptr psnp->long_ptr.*psnp->long_ptr psnp->ptrs.0.next.next.ptrs.1 psnp->ptrs.0.next.next.ptrs.2 psnp->ptrs.0.char_ptr psnp->ptrs.0.long_ptr psnp->char_ptr psnp->long_ptr psnp->ptrs.0.ptrs psnp->ptrs.0 psnp->ptrs.1 psnp->ptrs.2 psnp->long_ptr.*psnp->long_ptr.**psnp->long_ptr} {}}
# Step over "snp0.long_ptr = &y3;"
gdb_cmd "step"
@@ -1529,7 +1527,7 @@ gdb_cmd "step"
# Desc: check that psnp->long_ptr (and [0].long_ptr) changed
gdbtk_test c_variable-5.50 {check that psnp->long_ptr (and [0].long_ptr) changed} {
check_update
-} {{psnp->ptrs.0.long_ptr {psnp->long_ptr psnp->long_ptr.*psnp->long_ptr psnp->long_ptr.*psnp->long_ptr.**psnp->long_ptr psnp->long_ptr.*psnp->long_ptr.**psnp->long_ptr.***psnp->long_ptr psnp->long_ptr.*psnp->long_ptr.**psnp->long_ptr.***psnp->long_ptr.****psnp->long_ptr}} {psnp->ptrs.0.next psnp->ptrs.0.next.ptrs psnp->ptrs.0.next.next psnp->ptrs.0.next.next.char_ptr psnp->ptrs.0.next.next.long_ptr psnp->ptrs.0.next.char_ptr.*char_ptr.**char_ptr.***char_ptr psnp->char_ptr.*psnp->char_ptr.**psnp->char_ptr.***psnp->char_ptr.****psnp->char_ptr psnp->char_ptr.*psnp->char_ptr.**psnp->char_ptr psnp->ptrs.0.next.char_ptr.*char_ptr.**char_ptr psnp->ptrs.0.next.char_ptr psnp->ptrs.0.next.long_ptr psnp->ptrs.0.next.next.ptrs psnp->ptrs.0.next.char_ptr.*char_ptr psnp->long_ptr.*psnp->long_ptr.**psnp->long_ptr.***psnp->long_ptr.****psnp->long_ptr psnp->ptrs.0.next.next.next psnp->char_ptr.*psnp->char_ptr.**psnp->char_ptr.***psnp->char_ptr psnp->char_ptr.*psnp->char_ptr psnp->ptrs.0.next.next.ptrs.0 psnp->long_ptr.*psnp->long_ptr.**psnp->long_ptr.***psnp->long_ptr psnp->long_ptr.*psnp->long_ptr psnp->ptrs.0.next.next.ptrs.1 psnp->ptrs.0.next.next.ptrs.2 psnp->ptrs.0.char_ptr psnp->ptrs.0.long_ptr psnp->ptrs.0.next.char_ptr.*char_ptr.**char_ptr.***char_ptr.****char_ptr psnp->ptrs.0.ptrs psnp->ptrs.0 psnp->ptrs.1 psnp->ptrs.2 psnp->long_ptr.*psnp->long_ptr.**psnp->long_ptr}}
+} {{psnp->ptrs.0.long_ptr psnp->long_ptr psnp->long_ptr.*psnp->long_ptr psnp->long_ptr.*psnp->long_ptr.**psnp->long_ptr psnp->long_ptr.*psnp->long_ptr.**psnp->long_ptr.***psnp->long_ptr psnp->long_ptr.*psnp->long_ptr.**psnp->long_ptr.***psnp->long_ptr.****psnp->long_ptr} {psnp->ptrs.0.next psnp->ptrs.0.next.ptrs psnp->ptrs.0.next.next psnp->ptrs.0.next.next.char_ptr psnp->ptrs.0.next.next.long_ptr psnp->ptrs.0.next.char_ptr.*char_ptr.**char_ptr.***char_ptr psnp->char_ptr.*psnp->char_ptr.**psnp->char_ptr psnp->ptrs.0.next.char_ptr.*char_ptr.**char_ptr psnp->ptrs.0.next.char_ptr psnp->ptrs.0.next.long_ptr psnp->ptrs.0.next.next.ptrs psnp->ptrs.0.next.char_ptr.*char_ptr psnp->ptrs psnp->ptrs.0.next.next.next psnp->char_ptr.*psnp->char_ptr.**psnp->char_ptr.***psnp->char_ptr psnp->char_ptr.*psnp->char_ptr psnp->ptrs.0.next.next.ptrs.0 psnp->ptrs.0.next.next.ptrs.1 psnp->ptrs.0.next.next.ptrs.2 psnp->ptrs.0.char_ptr psnp->char_ptr psnp->ptrs.0.ptrs psnp->ptrs.0 psnp->ptrs.1 psnp->ptrs.2} {}}
# Step over "snp1.long_ptr = &x3;"
gdb_cmd "step"
@@ -1538,7 +1536,7 @@ gdb_cmd "step"
# Desc: check that psnp->next->long_ptr (and [1].long_ptr) changed
gdbtk_test c_variable-5.51 {check that psnp->next->long_ptr (and [1].long_ptr) changed} {
check_update
-} {psnp->ptrs.0.next.long_ptr {psnp->ptrs.0.next psnp->ptrs.0.next.ptrs psnp->ptrs.0.next.next psnp->ptrs.0.next.next.char_ptr psnp->ptrs.0.next.next.long_ptr psnp->ptrs.0.next.char_ptr.*char_ptr.**char_ptr.***char_ptr psnp->char_ptr.*psnp->char_ptr.**psnp->char_ptr.***psnp->char_ptr.****psnp->char_ptr psnp->char_ptr.*psnp->char_ptr.**psnp->char_ptr psnp->ptrs.0.next.char_ptr.*char_ptr.**char_ptr psnp->ptrs.0.next.char_ptr psnp->ptrs.0.next.long_ptr psnp->ptrs.0.next.next.ptrs psnp->ptrs.0.next.char_ptr.*char_ptr psnp->long_ptr.*psnp->long_ptr.**psnp->long_ptr.***psnp->long_ptr.****psnp->long_ptr psnp->ptrs.0.next.next.next psnp->char_ptr.*psnp->char_ptr.**psnp->char_ptr.***psnp->char_ptr psnp->char_ptr.*psnp->char_ptr psnp->ptrs.0.next.next.ptrs.0 psnp->long_ptr.*psnp->long_ptr.**psnp->long_ptr.***psnp->long_ptr psnp->long_ptr.*psnp->long_ptr psnp->ptrs.0.next.next.ptrs.1 psnp->ptrs.0.next.next.ptrs.2 psnp->ptrs.0.char_ptr psnp->ptrs.0.long_ptr psnp->ptrs.0.next.char_ptr.*char_ptr.**char_ptr.***char_ptr.****char_ptr psnp->ptrs.0.ptrs psnp->ptrs.0 psnp->ptrs.1 psnp->ptrs.2 psnp->long_ptr.*psnp->long_ptr.**psnp->long_ptr}}
+} {psnp->ptrs.0.next.long_ptr {psnp->ptrs.0.next psnp->ptrs.0.next.ptrs psnp->ptrs.0.next.next psnp->ptrs.0.next.next.char_ptr psnp->ptrs.0.next.next.long_ptr psnp->ptrs.0.next.char_ptr.*char_ptr.**char_ptr.***char_ptr psnp->char_ptr.*psnp->char_ptr.**psnp->char_ptr psnp->ptrs.0.next.char_ptr.*char_ptr.**char_ptr psnp->ptrs.0.next.char_ptr psnp->ptrs.0.next.next.ptrs psnp->ptrs.0.next.char_ptr.*char_ptr psnp->ptrs psnp->long_ptr.*psnp->long_ptr.**psnp->long_ptr.***psnp->long_ptr.****psnp->long_ptr psnp->ptrs.0.next.next.next psnp->char_ptr.*psnp->char_ptr.**psnp->char_ptr.***psnp->char_ptr psnp->char_ptr.*psnp->char_ptr psnp->ptrs.0.next.next.ptrs.0 psnp->long_ptr.*psnp->long_ptr.**psnp->long_ptr.***psnp->long_ptr psnp->long_ptr.*psnp->long_ptr psnp->ptrs.0.next.next.ptrs.1 psnp->ptrs.0.next.next.ptrs.2 psnp->ptrs.0.char_ptr psnp->ptrs.0.long_ptr psnp->char_ptr psnp->long_ptr psnp->ptrs.0.ptrs psnp->ptrs.0 psnp->ptrs.1 psnp->ptrs.2 psnp->long_ptr.*psnp->long_ptr.**psnp->long_ptr} {}}
# Step over "snp2.long_ptr = &z3;"
gdb_cmd "step"
@@ -1547,13 +1545,13 @@ gdb_cmd "step"
# Desc: check that psnp->next->next->long_ptr (and [2].long_ptr) changed
gdbtk_test c_variable-5.52 {check that psnp->next->next->long_ptr (and [2].long_ptr) changed} {
check_update
-} {psnp->ptrs.0.next.next.long_ptr {psnp->ptrs.0.next psnp->ptrs.0.next.ptrs psnp->ptrs.0.next.next psnp->ptrs.0.next.next.char_ptr psnp->ptrs.0.next.next.long_ptr psnp->ptrs.0.next.char_ptr.*char_ptr.**char_ptr.***char_ptr psnp->char_ptr.*psnp->char_ptr.**psnp->char_ptr.***psnp->char_ptr.****psnp->char_ptr psnp->char_ptr.*psnp->char_ptr.**psnp->char_ptr psnp->ptrs.0.next.char_ptr.*char_ptr.**char_ptr psnp->ptrs.0.next.char_ptr psnp->ptrs.0.next.long_ptr psnp->ptrs.0.next.next.ptrs psnp->ptrs.0.next.char_ptr.*char_ptr psnp->long_ptr.*psnp->long_ptr.**psnp->long_ptr.***psnp->long_ptr.****psnp->long_ptr psnp->ptrs.0.next.next.next psnp->char_ptr.*psnp->char_ptr.**psnp->char_ptr.***psnp->char_ptr psnp->char_ptr.*psnp->char_ptr psnp->ptrs.0.next.next.ptrs.0 psnp->long_ptr.*psnp->long_ptr.**psnp->long_ptr.***psnp->long_ptr psnp->long_ptr.*psnp->long_ptr psnp->ptrs.0.next.next.ptrs.1 psnp->ptrs.0.next.next.ptrs.2 psnp->ptrs.0.char_ptr psnp->ptrs.0.long_ptr psnp->ptrs.0.next.char_ptr.*char_ptr.**char_ptr.***char_ptr.****char_ptr psnp->ptrs.0.ptrs psnp->ptrs.0 psnp->ptrs.1 psnp->ptrs.2 psnp->long_ptr.*psnp->long_ptr.**psnp->long_ptr}}
+} {psnp->ptrs.0.next.next.long_ptr {psnp->ptrs.0.next psnp->ptrs.0.next.ptrs psnp->ptrs.0.next.next psnp->ptrs.0.next.next.char_ptr psnp->ptrs.0.next.char_ptr.*char_ptr.**char_ptr.***char_ptr psnp->char_ptr.*psnp->char_ptr.**psnp->char_ptr psnp->ptrs.0.next.char_ptr.*char_ptr.**char_ptr psnp->ptrs.0.next.char_ptr psnp->ptrs.0.next.long_ptr psnp->ptrs.0.next.next.ptrs psnp->ptrs.0.next.char_ptr.*char_ptr psnp->ptrs psnp->long_ptr.*psnp->long_ptr.**psnp->long_ptr.***psnp->long_ptr.****psnp->long_ptr psnp->ptrs.0.next.next.next psnp->char_ptr.*psnp->char_ptr.**psnp->char_ptr.***psnp->char_ptr psnp->char_ptr.*psnp->char_ptr psnp->ptrs.0.next.next.ptrs.0 psnp->long_ptr.*psnp->long_ptr.**psnp->long_ptr.***psnp->long_ptr psnp->long_ptr.*psnp->long_ptr psnp->ptrs.0.next.next.ptrs.1 psnp->ptrs.0.next.next.ptrs.2 psnp->ptrs.0.char_ptr psnp->ptrs.0.long_ptr psnp->char_ptr psnp->long_ptr psnp->ptrs.0.ptrs psnp->ptrs.0 psnp->ptrs.1 psnp->ptrs.2 psnp->long_ptr.*psnp->long_ptr.**psnp->long_ptr} {}}
# Test: c_variable-5.53
# Desc: names of editable variables
gdbtk_test c_variable-5.53 {names of editable variables} {
editable_variables
-} {{psnp->ptrs.0.next psnp->ptrs.0.next.next psnp->ptrs.0.next.next.char_ptr psnp->ptrs.0.next.next.long_ptr psnp->ptrs.0.next.char_ptr.*char_ptr.**char_ptr.***char_ptr psnp->char_ptr.*psnp->char_ptr.**psnp->char_ptr.***psnp->char_ptr.****psnp->char_ptr psnp->char_ptr.*psnp->char_ptr.**psnp->char_ptr psnp->ptrs.0.next.char_ptr.*char_ptr.**char_ptr psnp->ptrs.0.next.char_ptr psnp->ptrs.0.next.long_ptr psnp->ptrs.0.next.char_ptr.*char_ptr psnp->long_ptr.*psnp->long_ptr.**psnp->long_ptr.***psnp->long_ptr.****psnp->long_ptr psnp->ptrs.0.next.next.next psnp->char_ptr.*psnp->char_ptr.**psnp->char_ptr.***psnp->char_ptr psnp->char_ptr.*psnp->char_ptr psnp->ptrs.0.next.next.ptrs.0 psnp->long_ptr.*psnp->long_ptr.**psnp->long_ptr.***psnp->long_ptr psnp->long_ptr.*psnp->long_ptr psnp->ptrs.0.next.next.ptrs.1 psnp->ptrs.0.next.next.ptrs.2 psnp->ptrs.0.char_ptr psnp->ptrs.0.long_ptr psnp->char_ptr psnp->ptrs.0.next.char_ptr.*char_ptr.**char_ptr.***char_ptr.****char_ptr psnp->long_ptr psnp->ptrs.0 psnp->ptrs.1 psnp->ptrs.2 psnp->long_ptr.*psnp->long_ptr.**psnp->long_ptr} {psnp->ptrs.0.next.ptrs psnp->ptrs.0.next.next.ptrs psnp->ptrs psnp->ptrs.0.ptrs}}
+} {{psnp->ptrs.0.next psnp->ptrs.0.next.next psnp->ptrs.0.next.next.char_ptr psnp->ptrs.0.next.next.long_ptr psnp->ptrs.0.next.char_ptr.*char_ptr.**char_ptr.***char_ptr psnp->char_ptr.*psnp->char_ptr.**psnp->char_ptr psnp->ptrs.0.next.char_ptr.*char_ptr.**char_ptr psnp->ptrs.0.next.char_ptr psnp->ptrs.0.next.long_ptr psnp->ptrs.0.next.char_ptr.*char_ptr psnp->long_ptr.*psnp->long_ptr.**psnp->long_ptr.***psnp->long_ptr.****psnp->long_ptr psnp->ptrs.0.next.next.next psnp->char_ptr.*psnp->char_ptr.**psnp->char_ptr.***psnp->char_ptr psnp->char_ptr.*psnp->char_ptr psnp->ptrs.0.next.next.ptrs.0 psnp->long_ptr.*psnp->long_ptr.**psnp->long_ptr.***psnp->long_ptr psnp->long_ptr.*psnp->long_ptr psnp->ptrs.0.next.next.ptrs.1 psnp->ptrs.0.next.next.ptrs.2 psnp->ptrs.0.char_ptr psnp->ptrs.0.long_ptr psnp->char_ptr psnp->long_ptr psnp->ptrs.0 psnp->ptrs.1 psnp->ptrs.2 psnp->long_ptr.*psnp->long_ptr.**psnp->long_ptr} {psnp->ptrs.0.next.ptrs psnp->ptrs.0.next.next.ptrs psnp->ptrs psnp->ptrs.0.ptrs}}
##### #####
# #
@@ -1686,7 +1684,7 @@ gdbtk_test c_variable-6.22 {type of weird and children} {
}
set types
-} {{weird_struct *} {char *} char {void (*)(void)} {struct _struct_decl *(*)(int, char *, long int)} {struct _struct_decl (*)(int, char *, long int)} {int **} int {long int [10]} {long int} struct union}
+} {{weird_struct *} {char *} char {void (*)()} {struct _struct_decl *(*)()} {struct _struct_decl (*)()} {int **} int {long int [10]} {long int} struct union}
# Test: c_variable-6.23
# Desc: change format of weird.func_ptr and weird.func_ptr_ptr
@@ -1757,15 +1755,15 @@ gdbtk_test c_variable-6.30 {create more children of weird} {
}
lsort [array names var]
-} {weird weird.char_ptr weird.char_ptr.*char_ptr weird.character weird.func_ptr weird.func_ptr_ptr weird.func_ptr_struct weird.int_ptr_ptr weird.int_ptr_ptr.*int_ptr_ptr weird.int_ptr_ptr.*int_ptr_ptr.**int_ptr_ptr weird.integer weird.long_array weird.long_array.0 weird.long_array.1 weird.long_array.2 weird.long_array.3 weird.long_array.4 weird.long_array.5 weird.long_array.6 weird.long_array.7 weird.long_array.8 weird.long_array.9 weird.long_int weird.s2 weird.s2.g weird.s2.h weird.s2.i weird.s2.i.0 weird.s2.i.1 weird.s2.i.2 weird.s2.i.3 weird.s2.i.4 weird.s2.i.5 weird.s2.i.6 weird.s2.i.7 weird.s2.i.8 weird.s2.i.9 weird.s2.u2 weird.s2.u2.f weird.s2.u2.u1s1 weird.s2.u2.u1s2 weird.u1 weird.u1.a weird.u1.b weird.u1.b.*b weird.u1.c weird.u1.d}
+} {weird weird.char_ptr weird.character weird.func_ptr weird.func_ptr_ptr weird.func_ptr_struct weird.int_ptr_ptr weird.int_ptr_ptr.*int_ptr_ptr weird.int_ptr_ptr.*int_ptr_ptr.**int_ptr_ptr weird.integer weird.long_array weird.long_array.0 weird.long_array.1 weird.long_array.2 weird.long_array.3 weird.long_array.4 weird.long_array.5 weird.long_array.6 weird.long_array.7 weird.long_array.8 weird.long_array.9 weird.long_int weird.s2 weird.s2.g weird.s2.h weird.s2.i weird.s2.i.0 weird.s2.i.1 weird.s2.i.2 weird.s2.i.3 weird.s2.i.4 weird.s2.i.5 weird.s2.i.6 weird.s2.i.7 weird.s2.i.8 weird.s2.i.9 weird.s2.u2 weird.s2.u2.f weird.s2.u2.u1s1 weird.s2.u2.u1s2 weird.u1 weird.u1.a weird.u1.b weird.u1.c weird.u1.d}
# Test: c_variable-6.31
# Desc: check that all children of weird change
# Ok, obviously things like weird.s2 and weird.u1 will not change!
-gdbtk_test c_variable-6.31 {check that all children of weird change (ops, we are now reporting array names as changed in this case - seems harmless though)} {
+gdbtk_test *c_variable-6.31 {check that all children of weird change (ops, we are now reporting array names as changed in this case - seems harmless though)} {
$var(weird) value 0x2121
check_update
-} {{{weird weird.integer weird.character weird.char_ptr weird.char_ptr.*char_ptr weird.long_int weird.int_ptr_ptr weird.int_ptr_ptr.*int_ptr_ptr weird.long_array.0 weird.long_array.1 weird.long_array.2 weird.long_array.3 weird.long_array.4 weird.long_array.5 weird.long_array.6 weird.long_array.7 weird.long_array.8 weird.long_array.9 weird.func_ptr weird.func_ptr_struct weird.func_ptr_ptr weird.u1.a weird.u1.b weird.u1.c weird.u1.d weird.s2.u2.f weird.s2.g weird.s2.h weird.s2.i.0 weird.s2.i.1 weird.s2.i.2 weird.s2.i.3 weird.s2.i.4 weird.s2.i.5 weird.s2.i.6 weird.s2.i.7 weird.s2.i.8 weird.s2.i.9}} {weird.char_ptr weird.s2.u2.f weird.int_ptr_ptr.*int_ptr_ptr.**int_ptr_ptr weird.s2.g weird.s2.h weird.s2.i weird.func_ptr_ptr weird.func_ptr weird.s2.u2 weird.int_ptr_ptr weird.long_int weird.character weird.s2.u2.u1s1 weird.s2.u2.u1s2 weird.long_array.0 weird.u1.a weird.long_array.1 weird.s2 weird.func_ptr_struct weird.u1.b weird.long_array.2 weird.long_array weird.u1.c weird.long_array.3 weird.u1.d weird.long_array.4 weird.long_array.5 weird.s2.i.0 weird.long_array.6 weird.s2.i.1 weird.long_array.7 weird.s2.i.2 weird.long_array.8 weird.s2.i.3 weird.long_array.9 weird.s2.i.4 weird.integer weird.s2.i.5 weird.s2.i.6 weird.s2.i.7 weird.s2.i.8 weird.int_ptr_ptr.*int_ptr_ptr weird.s2.i.9 weird.char_ptr.*char_ptr weird.u1 weird.u1.b.*b}}
+} {{weird.integer weird.character weird.char_ptr weird.long_int weird.int_ptr_ptr weird.int_ptr_ptr.*int_ptr_ptr weird.int_ptr_ptr.*int_ptr_ptr.**int_ptr_ptr weird.long_array.0 weird.long_array.1 weird.long_array.2 weird.long_array.3 weird.long_array.4 weird.long_array.5 weird.long_array.6 weird.long_array.7 weird.long_array.8 weird.long_array.9 weird.func_ptr weird.func_ptr_struct weird.func_ptr_ptr weird.u1.a weird.u1.b weird.u1.c weird.u1.d weird.s2.u2.f weird.s2.g weird.s2.h weird.s2.i.0 weird.s2.i.1 weird.s2.i.2 weird.s2.i.3 weird.s2.i.4 weird.s2.i.5 weird.s2.i.6 weird.s2.i.7 weird.s2.i.8 weird.s2.i.9} {weird.s2.i weird.s2.u2 weird weird.s2.u2.u1s1 weird.s2.u2.u1s2 weird.s2 weird.long_array weird.u1} {}}
delete_variable weird
@@ -2066,6 +2064,3 @@ gdbtk_test c_variable-7.81 {create variables in different scopes} {
# Exit
#
gdbtk_test_done
-
-#Local Variables:
-#mode: tcl
diff --git a/gdb/testsuite/gdb.gdbtk/configure b/gdb/testsuite/gdb.gdbtk/configure
index 16dc537ba46..c65cbd9d2a5 100644
--- a/gdb/testsuite/gdb.gdbtk/configure
+++ b/gdb/testsuite/gdb.gdbtk/configure
@@ -1,288 +1,26 @@
#! /bin/sh
+
# Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.59.
+# Generated automatically using autoconf version 2.12.2
+# Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc.
#
-# Copyright (C) 2003 Free Software Foundation, Inc.
# This configure script is free software; the Free Software Foundation
# gives unlimited permission to copy, distribute and modify it.
-## --------------------- ##
-## M4sh Initialization. ##
-## --------------------- ##
-
-# Be Bourne compatible
-if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
- emulate sh
- NULLCMD=:
- # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
- # is contrary to our usage. Disable this feature.
- alias -g '${1+"$@"}'='"$@"'
-elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
- set -o posix
-fi
-DUALCASE=1; export DUALCASE # for MKS sh
-
-# Support unset when possible.
-if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
- as_unset=unset
-else
- as_unset=false
-fi
-
-
-# Work around bugs in pre-3.0 UWIN ksh.
-$as_unset ENV MAIL MAILPATH
-PS1='$ '
-PS2='> '
-PS4='+ '
-
-# NLS nuisances.
-for as_var in \
- LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \
- LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \
- LC_TELEPHONE LC_TIME
-do
- if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then
- eval $as_var=C; export $as_var
- else
- $as_unset $as_var
- fi
-done
-
-# Required to use basename.
-if expr a : '\(a\)' >/dev/null 2>&1; then
- as_expr=expr
-else
- as_expr=false
-fi
-
-if (basename /) >/dev/null 2>&1 && test "X`basename / 2>&1`" = "X/"; then
- as_basename=basename
-else
- as_basename=false
-fi
-
-
-# Name of the executable.
-as_me=`$as_basename "$0" ||
-$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
- X"$0" : 'X\(//\)$' \| \
- X"$0" : 'X\(/\)$' \| \
- . : '\(.\)' 2>/dev/null ||
-echo X/"$0" |
- sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/; q; }
- /^X\/\(\/\/\)$/{ s//\1/; q; }
- /^X\/\(\/\).*/{ s//\1/; q; }
- s/.*/./; q'`
-
-
-# PATH needs CR, and LINENO needs CR and PATH.
-# Avoid depending upon Character Ranges.
-as_cr_letters='abcdefghijklmnopqrstuvwxyz'
-as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
-as_cr_Letters=$as_cr_letters$as_cr_LETTERS
-as_cr_digits='0123456789'
-as_cr_alnum=$as_cr_Letters$as_cr_digits
-
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- echo "#! /bin/sh" >conf$$.sh
- echo "exit 0" >>conf$$.sh
- chmod +x conf$$.sh
- if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
- PATH_SEPARATOR=';'
- else
- PATH_SEPARATOR=:
- fi
- rm -f conf$$.sh
-fi
-
-
- as_lineno_1=$LINENO
- as_lineno_2=$LINENO
- as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
- test "x$as_lineno_1" != "x$as_lineno_2" &&
- test "x$as_lineno_3" = "x$as_lineno_2" || {
- # Find who we are. Look in the path if we contain no path at all
- # relative or not.
- case $0 in
- *[\\/]* ) as_myself=$0 ;;
- *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
-done
-
- ;;
- esac
- # We did not find ourselves, most probably we were run as `sh COMMAND'
- # in which case we are not to be found in the path.
- if test "x$as_myself" = x; then
- as_myself=$0
- fi
- if test ! -f "$as_myself"; then
- { echo "$as_me: error: cannot find myself; rerun with an absolute path" >&2
- { (exit 1); exit 1; }; }
- fi
- case $CONFIG_SHELL in
- '')
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for as_base in sh bash ksh sh5; do
- case $as_dir in
- /*)
- if ("$as_dir/$as_base" -c '
- as_lineno_1=$LINENO
- as_lineno_2=$LINENO
- as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
- test "x$as_lineno_1" != "x$as_lineno_2" &&
- test "x$as_lineno_3" = "x$as_lineno_2" ') 2>/dev/null; then
- $as_unset BASH_ENV || test "${BASH_ENV+set}" != set || { BASH_ENV=; export BASH_ENV; }
- $as_unset ENV || test "${ENV+set}" != set || { ENV=; export ENV; }
- CONFIG_SHELL=$as_dir/$as_base
- export CONFIG_SHELL
- exec "$CONFIG_SHELL" "$0" ${1+"$@"}
- fi;;
- esac
- done
-done
-;;
- esac
-
- # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
- # uniformly replaced by the line number. The first 'sed' inserts a
- # line-number line before each line; the second 'sed' does the real
- # work. The second script uses 'N' to pair each line-number line
- # with the numbered line, and appends trailing '-' during
- # substitution so that $LINENO is not a special case at line end.
- # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
- # second 'sed' script. Blame Lee E. McMahon for sed's syntax. :-)
- sed '=' <$as_myself |
- sed '
- N
- s,$,-,
- : loop
- s,^\(['$as_cr_digits']*\)\(.*\)[$]LINENO\([^'$as_cr_alnum'_]\),\1\2\1\3,
- t loop
- s,-$,,
- s,^['$as_cr_digits']*\n,,
- ' >$as_me.lineno &&
- chmod +x $as_me.lineno ||
- { echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2
- { (exit 1); exit 1; }; }
-
- # Don't try to exec as it changes $[0], causing all sort of problems
- # (the dirname of $[0] is not the place where we might find the
- # original and so on. Autoconf is especially sensible to this).
- . ./$as_me.lineno
- # Exit status is that of the last command.
- exit
-}
-
-
-case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
- *c*,-n*) ECHO_N= ECHO_C='
-' ECHO_T=' ' ;;
- *c*,* ) ECHO_N=-n ECHO_C= ECHO_T= ;;
- *) ECHO_N= ECHO_C='\c' ECHO_T= ;;
-esac
-
-if expr a : '\(a\)' >/dev/null 2>&1; then
- as_expr=expr
-else
- as_expr=false
-fi
-
-rm -f conf$$ conf$$.exe conf$$.file
-echo >conf$$.file
-if ln -s conf$$.file conf$$ 2>/dev/null; then
- # We could just check for DJGPP; but this test a) works b) is more generic
- # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
- if test -f conf$$.exe; then
- # Don't use ln at all; we don't have any links
- as_ln_s='cp -p'
- else
- as_ln_s='ln -s'
- fi
-elif ln conf$$.file conf$$ 2>/dev/null; then
- as_ln_s=ln
-else
- as_ln_s='cp -p'
-fi
-rm -f conf$$ conf$$.exe conf$$.file
-
-if mkdir -p . 2>/dev/null; then
- as_mkdir_p=:
-else
- test -d ./-p && rmdir ./-p
- as_mkdir_p=false
-fi
-as_executable_p="test -f"
-
-# Sed expression to map a string onto a valid CPP name.
-as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
-
-# Sed expression to map a string onto a valid variable name.
-as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
-
-
-# IFS
-# We need space, tab and new line, in precisely that order.
-as_nl='
-'
-IFS=" $as_nl"
-
-# CDPATH.
-$as_unset CDPATH
-
-
-# Name of the host.
-# hostname on some systems (SVR3.2, Linux) returns a bogus exit status,
-# so uname gets run too.
-ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
-
-exec 6>&1
-
-#
-# Initializations.
-#
+# Defaults:
+ac_help=
ac_default_prefix=/usr/local
-ac_config_libobj_dir=.
-cross_compiling=no
-subdirs=
-MFLAGS=
-MAKEFLAGS=
-SHELL=${CONFIG_SHELL-/bin/sh}
-
-# Maximum number of lines to put in a shell here document.
-# This variable seems obsolete. It should probably be removed, and
-# only ac_max_sed_lines should be used.
-: ${ac_max_here_lines=38}
-
-# Identity of this package.
-PACKAGE_NAME=
-PACKAGE_TARNAME=
-PACKAGE_VERSION=
-PACKAGE_STRING=
-PACKAGE_BUGREPORT=
-
-ac_unique_file="defs"
-ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS CC build build_cpu build_vendor build_os host host_cpu host_vendor host_os target target_cpu target_vendor target_os LIBOBJS LTLIBOBJS'
-ac_subst_files=''
+# Any additions from configure.in:
# Initialize some variables set by options.
-ac_init_help=
-ac_init_version=false
# The variables have the same names as the options, with
# dashes changed to underlines.
-cache_file=/dev/null
+build=NONE
+cache_file=./config.cache
exec_prefix=NONE
+host=NONE
no_create=
+nonopt=NONE
no_recursion=
prefix=NONE
program_prefix=NONE
@@ -291,15 +29,10 @@ program_transform_name=s,x,x,
silent=
site=
srcdir=
+target=NONE
verbose=
x_includes=NONE
x_libraries=NONE
-
-# Installation directory options.
-# These are left unexpanded so users can "make install exec_prefix=/foo"
-# and all the variables that are supposed to be based on exec_prefix
-# by default will actually change.
-# Use braces instead of parens because sh, perl, etc. also accept them.
bindir='${exec_prefix}/bin'
sbindir='${exec_prefix}/sbin'
libexecdir='${exec_prefix}/libexec'
@@ -313,9 +46,17 @@ oldincludedir='/usr/include'
infodir='${prefix}/info'
mandir='${prefix}/man'
+# Initialize some other variables.
+subdirs=
+MFLAGS= MAKEFLAGS=
+SHELL=${CONFIG_SHELL-/bin/sh}
+# Maximum number of lines to put in a shell here document.
+ac_max_here_lines=12
+
ac_prev=
for ac_option
do
+
# If the previous option needs an argument, assign it.
if test -n "$ac_prev"; then
eval "$ac_prev=\$ac_option"
@@ -323,59 +64,59 @@ do
continue
fi
- ac_optarg=`expr "x$ac_option" : 'x[^=]*=\(.*\)'`
+ case "$ac_option" in
+ -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
+ *) ac_optarg= ;;
+ esac
# Accept the important Cygnus configure options, so we can diagnose typos.
- case $ac_option in
+ case "$ac_option" in
-bindir | --bindir | --bindi | --bind | --bin | --bi)
ac_prev=bindir ;;
-bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
- bindir=$ac_optarg ;;
+ bindir="$ac_optarg" ;;
-build | --build | --buil | --bui | --bu)
- ac_prev=build_alias ;;
+ ac_prev=build ;;
-build=* | --build=* | --buil=* | --bui=* | --bu=*)
- build_alias=$ac_optarg ;;
+ build="$ac_optarg" ;;
-cache-file | --cache-file | --cache-fil | --cache-fi \
| --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
ac_prev=cache_file ;;
-cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
| --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
- cache_file=$ac_optarg ;;
-
- --config-cache | -C)
- cache_file=config.cache ;;
+ cache_file="$ac_optarg" ;;
-datadir | --datadir | --datadi | --datad | --data | --dat | --da)
ac_prev=datadir ;;
-datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
| --da=*)
- datadir=$ac_optarg ;;
+ datadir="$ac_optarg" ;;
-disable-* | --disable-*)
- ac_feature=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
+ ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
# Reject names that are not valid shell variable names.
- expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
- { echo "$as_me: error: invalid feature name: $ac_feature" >&2
- { (exit 1); exit 1; }; }
- ac_feature=`echo $ac_feature | sed 's/-/_/g'`
- eval "enable_$ac_feature=no" ;;
+ if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
+ { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
+ fi
+ ac_feature=`echo $ac_feature| sed 's/-/_/g'`
+ eval "enable_${ac_feature}=no" ;;
-enable-* | --enable-*)
- ac_feature=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
+ ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
# Reject names that are not valid shell variable names.
- expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
- { echo "$as_me: error: invalid feature name: $ac_feature" >&2
- { (exit 1); exit 1; }; }
- ac_feature=`echo $ac_feature | sed 's/-/_/g'`
- case $ac_option in
- *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
+ if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
+ { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
+ fi
+ ac_feature=`echo $ac_feature| sed 's/-/_/g'`
+ case "$ac_option" in
+ *=*) ;;
*) ac_optarg=yes ;;
esac
- eval "enable_$ac_feature='$ac_optarg'" ;;
+ eval "enable_${ac_feature}='$ac_optarg'" ;;
-exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
| --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
@@ -384,47 +125,95 @@ do
-exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
| --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
| --exec=* | --exe=* | --ex=*)
- exec_prefix=$ac_optarg ;;
+ exec_prefix="$ac_optarg" ;;
-gas | --gas | --ga | --g)
# Obsolete; use --with-gas.
with_gas=yes ;;
- -help | --help | --hel | --he | -h)
- ac_init_help=long ;;
- -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
- ac_init_help=recursive ;;
- -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
- ac_init_help=short ;;
+ -help | --help | --hel | --he)
+ # Omit some internal or obsolete options to make the list less imposing.
+ # This message is too long to be a string in the A/UX 3.1 sh.
+ cat << EOF
+Usage: configure [options] [host]
+Options: [defaults in brackets after descriptions]
+Configuration:
+ --cache-file=FILE cache test results in FILE
+ --help print this message
+ --no-create do not create output files
+ --quiet, --silent do not print \`checking...' messages
+ --version print the version of autoconf that created configure
+Directory and file names:
+ --prefix=PREFIX install architecture-independent files in PREFIX
+ [$ac_default_prefix]
+ --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
+ [same as prefix]
+ --bindir=DIR user executables in DIR [EPREFIX/bin]
+ --sbindir=DIR system admin executables in DIR [EPREFIX/sbin]
+ --libexecdir=DIR program executables in DIR [EPREFIX/libexec]
+ --datadir=DIR read-only architecture-independent data in DIR
+ [PREFIX/share]
+ --sysconfdir=DIR read-only single-machine data in DIR [PREFIX/etc]
+ --sharedstatedir=DIR modifiable architecture-independent data in DIR
+ [PREFIX/com]
+ --localstatedir=DIR modifiable single-machine data in DIR [PREFIX/var]
+ --libdir=DIR object code libraries in DIR [EPREFIX/lib]
+ --includedir=DIR C header files in DIR [PREFIX/include]
+ --oldincludedir=DIR C header files for non-gcc in DIR [/usr/include]
+ --infodir=DIR info documentation in DIR [PREFIX/info]
+ --mandir=DIR man documentation in DIR [PREFIX/man]
+ --srcdir=DIR find the sources in DIR [configure dir or ..]
+ --program-prefix=PREFIX prepend PREFIX to installed program names
+ --program-suffix=SUFFIX append SUFFIX to installed program names
+ --program-transform-name=PROGRAM
+ run sed PROGRAM on installed program names
+EOF
+ cat << EOF
+Host type:
+ --build=BUILD configure for building on BUILD [BUILD=HOST]
+ --host=HOST configure for HOST [guessed]
+ --target=TARGET configure for TARGET [TARGET=HOST]
+Features and packages:
+ --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
+ --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
+ --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
+ --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
+ --x-includes=DIR X include files are in DIR
+ --x-libraries=DIR X library files are in DIR
+EOF
+ if test -n "$ac_help"; then
+ echo "--enable and --with options recognized:$ac_help"
+ fi
+ exit 0 ;;
-host | --host | --hos | --ho)
- ac_prev=host_alias ;;
+ ac_prev=host ;;
-host=* | --host=* | --hos=* | --ho=*)
- host_alias=$ac_optarg ;;
+ host="$ac_optarg" ;;
-includedir | --includedir | --includedi | --included | --include \
| --includ | --inclu | --incl | --inc)
ac_prev=includedir ;;
-includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
| --includ=* | --inclu=* | --incl=* | --inc=*)
- includedir=$ac_optarg ;;
+ includedir="$ac_optarg" ;;
-infodir | --infodir | --infodi | --infod | --info | --inf)
ac_prev=infodir ;;
-infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
- infodir=$ac_optarg ;;
+ infodir="$ac_optarg" ;;
-libdir | --libdir | --libdi | --libd)
ac_prev=libdir ;;
-libdir=* | --libdir=* | --libdi=* | --libd=*)
- libdir=$ac_optarg ;;
+ libdir="$ac_optarg" ;;
-libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
| --libexe | --libex | --libe)
ac_prev=libexecdir ;;
-libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
| --libexe=* | --libex=* | --libe=*)
- libexecdir=$ac_optarg ;;
+ libexecdir="$ac_optarg" ;;
-localstatedir | --localstatedir | --localstatedi | --localstated \
| --localstate | --localstat | --localsta | --localst \
@@ -433,19 +222,19 @@ do
-localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
| --localstate=* | --localstat=* | --localsta=* | --localst=* \
| --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
- localstatedir=$ac_optarg ;;
+ localstatedir="$ac_optarg" ;;
-mandir | --mandir | --mandi | --mand | --man | --ma | --m)
ac_prev=mandir ;;
-mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
- mandir=$ac_optarg ;;
+ mandir="$ac_optarg" ;;
-nfp | --nfp | --nf)
# Obsolete; use --without-fp.
with_fp=no ;;
-no-create | --no-create | --no-creat | --no-crea | --no-cre \
- | --no-cr | --no-c | -n)
+ | --no-cr | --no-c)
no_create=yes ;;
-no-recursion | --no-recursion | --no-recursio | --no-recursi \
@@ -459,26 +248,26 @@ do
-oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
| --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
| --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
- oldincludedir=$ac_optarg ;;
+ oldincludedir="$ac_optarg" ;;
-prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
ac_prev=prefix ;;
-prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
- prefix=$ac_optarg ;;
+ prefix="$ac_optarg" ;;
-program-prefix | --program-prefix | --program-prefi | --program-pref \
| --program-pre | --program-pr | --program-p)
ac_prev=program_prefix ;;
-program-prefix=* | --program-prefix=* | --program-prefi=* \
| --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
- program_prefix=$ac_optarg ;;
+ program_prefix="$ac_optarg" ;;
-program-suffix | --program-suffix | --program-suffi | --program-suff \
| --program-suf | --program-su | --program-s)
ac_prev=program_suffix ;;
-program-suffix=* | --program-suffix=* | --program-suffi=* \
| --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
- program_suffix=$ac_optarg ;;
+ program_suffix="$ac_optarg" ;;
-program-transform-name | --program-transform-name \
| --program-transform-nam | --program-transform-na \
@@ -495,7 +284,7 @@ do
| --program-transfo=* | --program-transf=* \
| --program-trans=* | --program-tran=* \
| --progr-tra=* | --program-tr=* | --program-t=*)
- program_transform_name=$ac_optarg ;;
+ program_transform_name="$ac_optarg" ;;
-q | -quiet | --quiet | --quie | --qui | --qu | --q \
| -silent | --silent | --silen | --sile | --sil)
@@ -505,7 +294,7 @@ do
ac_prev=sbindir ;;
-sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
| --sbi=* | --sb=*)
- sbindir=$ac_optarg ;;
+ sbindir="$ac_optarg" ;;
-sharedstatedir | --sharedstatedir | --sharedstatedi \
| --sharedstated | --sharedstate | --sharedstat | --sharedsta \
@@ -516,57 +305,58 @@ do
| --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
| --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
| --sha=* | --sh=*)
- sharedstatedir=$ac_optarg ;;
+ sharedstatedir="$ac_optarg" ;;
-site | --site | --sit)
ac_prev=site ;;
-site=* | --site=* | --sit=*)
- site=$ac_optarg ;;
+ site="$ac_optarg" ;;
-srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
ac_prev=srcdir ;;
-srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
- srcdir=$ac_optarg ;;
+ srcdir="$ac_optarg" ;;
-sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
| --syscon | --sysco | --sysc | --sys | --sy)
ac_prev=sysconfdir ;;
-sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
| --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
- sysconfdir=$ac_optarg ;;
+ sysconfdir="$ac_optarg" ;;
-target | --target | --targe | --targ | --tar | --ta | --t)
- ac_prev=target_alias ;;
+ ac_prev=target ;;
-target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
- target_alias=$ac_optarg ;;
+ target="$ac_optarg" ;;
-v | -verbose | --verbose | --verbos | --verbo | --verb)
verbose=yes ;;
- -version | --version | --versio | --versi | --vers | -V)
- ac_init_version=: ;;
+ -version | --version | --versio | --versi | --vers)
+ echo "configure generated by autoconf version 2.12.2"
+ exit 0 ;;
-with-* | --with-*)
- ac_package=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
+ ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
# Reject names that are not valid shell variable names.
- expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
- { echo "$as_me: error: invalid package name: $ac_package" >&2
- { (exit 1); exit 1; }; }
+ if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
+ { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
+ fi
ac_package=`echo $ac_package| sed 's/-/_/g'`
- case $ac_option in
- *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
+ case "$ac_option" in
+ *=*) ;;
*) ac_optarg=yes ;;
esac
- eval "with_$ac_package='$ac_optarg'" ;;
+ eval "with_${ac_package}='$ac_optarg'" ;;
-without-* | --without-*)
- ac_package=`expr "x$ac_option" : 'x-*without-\(.*\)'`
+ ac_package=`echo $ac_option|sed -e 's/-*without-//'`
# Reject names that are not valid shell variable names.
- expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
- { echo "$as_me: error: invalid package name: $ac_package" >&2
- { (exit 1); exit 1; }; }
- ac_package=`echo $ac_package | sed 's/-/_/g'`
- eval "with_$ac_package=no" ;;
+ if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
+ { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
+ fi
+ ac_package=`echo $ac_package| sed 's/-/_/g'`
+ eval "with_${ac_package}=no" ;;
--x)
# Obsolete; use --with-x.
@@ -577,110 +367,99 @@ do
ac_prev=x_includes ;;
-x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
| --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
- x_includes=$ac_optarg ;;
+ x_includes="$ac_optarg" ;;
-x-libraries | --x-libraries | --x-librarie | --x-librari \
| --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
ac_prev=x_libraries ;;
-x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
| --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
- x_libraries=$ac_optarg ;;
+ x_libraries="$ac_optarg" ;;
- -*) { echo "$as_me: error: unrecognized option: $ac_option
-Try \`$0 --help' for more information." >&2
- { (exit 1); exit 1; }; }
+ -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
;;
- *=*)
- ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
- # Reject names that are not valid shell variable names.
- expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null &&
- { echo "$as_me: error: invalid variable name: $ac_envvar" >&2
- { (exit 1); exit 1; }; }
- ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`
- eval "$ac_envvar='$ac_optarg'"
- export $ac_envvar ;;
-
*)
- # FIXME: should be removed in autoconf 3.0.
- echo "$as_me: WARNING: you should use --build, --host, --target" >&2
- expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
- echo "$as_me: WARNING: invalid host type: $ac_option" >&2
- : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
+ if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
+ echo "configure: warning: $ac_option: invalid host type" 1>&2
+ fi
+ if test "x$nonopt" != xNONE; then
+ { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
+ fi
+ nonopt="$ac_option"
;;
esac
done
if test -n "$ac_prev"; then
- ac_option=--`echo $ac_prev | sed 's/_/-/g'`
- { echo "$as_me: error: missing argument to $ac_option" >&2
- { (exit 1); exit 1; }; }
+ { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
fi
-# Be sure to have absolute paths.
-for ac_var in exec_prefix prefix
-do
- eval ac_val=$`echo $ac_var`
- case $ac_val in
- [\\/$]* | ?:[\\/]* | NONE | '' ) ;;
- *) { echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2
- { (exit 1); exit 1; }; };;
- esac
-done
+trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
+
+# File descriptor usage:
+# 0 standard input
+# 1 file creation
+# 2 errors and warnings
+# 3 some systems may open it to /dev/tty
+# 4 used on the Kubota Titan
+# 6 checking for... messages and results
+# 5 compiler messages saved in config.log
+if test "$silent" = yes; then
+ exec 6>/dev/null
+else
+ exec 6>&1
+fi
+exec 5>./config.log
+
+echo "\
+This file contains any messages produced by compilers while
+running configure, to aid debugging if configure makes a mistake.
+" 1>&5
-# Be sure to have absolute paths.
-for ac_var in bindir sbindir libexecdir datadir sysconfdir sharedstatedir \
- localstatedir libdir includedir oldincludedir infodir mandir
+# Strip out --no-create and --no-recursion so they do not pile up.
+# Also quote any args containing shell metacharacters.
+ac_configure_args=
+for ac_arg
do
- eval ac_val=$`echo $ac_var`
- case $ac_val in
- [\\/$]* | ?:[\\/]* ) ;;
- *) { echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2
- { (exit 1); exit 1; }; };;
+ case "$ac_arg" in
+ -no-create | --no-create | --no-creat | --no-crea | --no-cre \
+ | --no-cr | --no-c) ;;
+ -no-recursion | --no-recursion | --no-recursio | --no-recursi \
+ | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
+ *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
+ ac_configure_args="$ac_configure_args '$ac_arg'" ;;
+ *) ac_configure_args="$ac_configure_args $ac_arg" ;;
esac
done
-# There might be people who depend on the old broken behavior: `$host'
-# used to hold the argument of --host etc.
-# FIXME: To remove some day.
-build=$build_alias
-host=$host_alias
-target=$target_alias
-
-# FIXME: To remove some day.
-if test "x$host_alias" != x; then
- if test "x$build_alias" = x; then
- cross_compiling=maybe
- echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
- If a cross compiler is detected then cross compile mode will be used." >&2
- elif test "x$build_alias" != "x$host_alias"; then
- cross_compiling=yes
- fi
-fi
-
-ac_tool_prefix=
-test -n "$host_alias" && ac_tool_prefix=$host_alias-
+# NLS nuisances.
+# Only set these to C if already set. These must not be set unconditionally
+# because not all systems understand e.g. LANG=C (notably SCO).
+# Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'!
+# Non-C LC_CTYPE values break the ctype check.
+if test "${LANG+set}" = set; then LANG=C; export LANG; fi
+if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
+if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi
+if test "${LC_CTYPE+set}" = set; then LC_CTYPE=C; export LC_CTYPE; fi
-test "$silent" = yes && exec 6>/dev/null
+# confdefs.h avoids OS command line length limits that DEFS can exceed.
+rm -rf conftest* confdefs.h
+# AIX cpp loses on an empty file, so make sure it contains at least a newline.
+echo > confdefs.h
+# A filename unique to this package, relative to the directory that
+# configure is in, which we can look for to find out if srcdir is correct.
+ac_unique_file=defs
# Find the source files, if location was not specified.
if test -z "$srcdir"; then
ac_srcdir_defaulted=yes
# Try the directory containing this script, then its parent.
- ac_confdir=`(dirname "$0") 2>/dev/null ||
-$as_expr X"$0" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
- X"$0" : 'X\(//\)[^/]' \| \
- X"$0" : 'X\(//\)$' \| \
- X"$0" : 'X\(/\)' \| \
- . : '\(.\)' 2>/dev/null ||
-echo X"$0" |
- sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
- /^X\(\/\/\)[^/].*/{ s//\1/; q; }
- /^X\(\/\/\)$/{ s//\1/; q; }
- /^X\(\/\).*/{ s//\1/; q; }
- s/.*/./; q'`
+ ac_prog=$0
+ ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
+ test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
srcdir=$ac_confdir
if test ! -r $srcdir/$ac_unique_file; then
srcdir=..
@@ -690,427 +469,13 @@ else
fi
if test ! -r $srcdir/$ac_unique_file; then
if test "$ac_srcdir_defaulted" = yes; then
- { echo "$as_me: error: cannot find sources ($ac_unique_file) in $ac_confdir or .." >&2
- { (exit 1); exit 1; }; }
+ { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
else
- { echo "$as_me: error: cannot find sources ($ac_unique_file) in $srcdir" >&2
- { (exit 1); exit 1; }; }
+ { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
fi
fi
-(cd $srcdir && test -r ./$ac_unique_file) 2>/dev/null ||
- { echo "$as_me: error: sources are in $srcdir, but \`cd $srcdir' does not work" >&2
- { (exit 1); exit 1; }; }
-srcdir=`echo "$srcdir" | sed 's%\([^\\/]\)[\\/]*$%\1%'`
-ac_env_build_alias_set=${build_alias+set}
-ac_env_build_alias_value=$build_alias
-ac_cv_env_build_alias_set=${build_alias+set}
-ac_cv_env_build_alias_value=$build_alias
-ac_env_host_alias_set=${host_alias+set}
-ac_env_host_alias_value=$host_alias
-ac_cv_env_host_alias_set=${host_alias+set}
-ac_cv_env_host_alias_value=$host_alias
-ac_env_target_alias_set=${target_alias+set}
-ac_env_target_alias_value=$target_alias
-ac_cv_env_target_alias_set=${target_alias+set}
-ac_cv_env_target_alias_value=$target_alias
-
-#
-# Report the --help message.
-#
-if test "$ac_init_help" = "long"; then
- # Omit some internal or obsolete options to make the list less imposing.
- # This message is too long to be a string in the A/UX 3.1 sh.
- cat <<_ACEOF
-\`configure' configures this package to adapt to many kinds of systems.
-
-Usage: $0 [OPTION]... [VAR=VALUE]...
-
-To assign environment variables (e.g., CC, CFLAGS...), specify them as
-VAR=VALUE. See below for descriptions of some of the useful variables.
-
-Defaults for the options are specified in brackets.
-
-Configuration:
- -h, --help display this help and exit
- --help=short display options specific to this package
- --help=recursive display the short help of all the included packages
- -V, --version display version information and exit
- -q, --quiet, --silent do not print \`checking...' messages
- --cache-file=FILE cache test results in FILE [disabled]
- -C, --config-cache alias for \`--cache-file=config.cache'
- -n, --no-create do not create output files
- --srcdir=DIR find the sources in DIR [configure dir or \`..']
-
-_ACEOF
-
- cat <<_ACEOF
-Installation directories:
- --prefix=PREFIX install architecture-independent files in PREFIX
- [$ac_default_prefix]
- --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
- [PREFIX]
-
-By default, \`make install' will install all the files in
-\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
-an installation prefix other than \`$ac_default_prefix' using \`--prefix',
-for instance \`--prefix=\$HOME'.
-
-For better control, use the options below.
-
-Fine tuning of the installation directories:
- --bindir=DIR user executables [EPREFIX/bin]
- --sbindir=DIR system admin executables [EPREFIX/sbin]
- --libexecdir=DIR program executables [EPREFIX/libexec]
- --datadir=DIR read-only architecture-independent data [PREFIX/share]
- --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
- --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
- --localstatedir=DIR modifiable single-machine data [PREFIX/var]
- --libdir=DIR object code libraries [EPREFIX/lib]
- --includedir=DIR C header files [PREFIX/include]
- --oldincludedir=DIR C header files for non-gcc [/usr/include]
- --infodir=DIR info documentation [PREFIX/info]
- --mandir=DIR man documentation [PREFIX/man]
-_ACEOF
-
- cat <<\_ACEOF
-
-System types:
- --build=BUILD configure for building on BUILD [guessed]
- --host=HOST cross-compile to build programs to run on HOST [BUILD]
- --target=TARGET configure for building compilers for TARGET [HOST]
-_ACEOF
-fi
-
-if test -n "$ac_init_help"; then
-
- cat <<\_ACEOF
-
-_ACEOF
-fi
-
-if test "$ac_init_help" = "recursive"; then
- # If there are subdirs, report their specific --help.
- ac_popdir=`pwd`
- for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
- test -d $ac_dir || continue
- ac_builddir=.
-
-if test "$ac_dir" != .; then
- ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
- # A "../" for each directory in $ac_dir_suffix.
- ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
-else
- ac_dir_suffix= ac_top_builddir=
-fi
-
-case $srcdir in
- .) # No --srcdir option. We are building in place.
- ac_srcdir=.
- if test -z "$ac_top_builddir"; then
- ac_top_srcdir=.
- else
- ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
- fi ;;
- [\\/]* | ?:[\\/]* ) # Absolute path.
- ac_srcdir=$srcdir$ac_dir_suffix;
- ac_top_srcdir=$srcdir ;;
- *) # Relative path.
- ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
- ac_top_srcdir=$ac_top_builddir$srcdir ;;
-esac
-
-# Do not use `cd foo && pwd` to compute absolute paths, because
-# the directories may not exist.
-case `pwd` in
-.) ac_abs_builddir="$ac_dir";;
-*)
- case "$ac_dir" in
- .) ac_abs_builddir=`pwd`;;
- [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";;
- *) ac_abs_builddir=`pwd`/"$ac_dir";;
- esac;;
-esac
-case $ac_abs_builddir in
-.) ac_abs_top_builddir=${ac_top_builddir}.;;
-*)
- case ${ac_top_builddir}. in
- .) ac_abs_top_builddir=$ac_abs_builddir;;
- [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
- *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
- esac;;
-esac
-case $ac_abs_builddir in
-.) ac_abs_srcdir=$ac_srcdir;;
-*)
- case $ac_srcdir in
- .) ac_abs_srcdir=$ac_abs_builddir;;
- [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
- *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
- esac;;
-esac
-case $ac_abs_builddir in
-.) ac_abs_top_srcdir=$ac_top_srcdir;;
-*)
- case $ac_top_srcdir in
- .) ac_abs_top_srcdir=$ac_abs_builddir;;
- [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
- *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
- esac;;
-esac
-
- cd $ac_dir
- # Check for guested configure; otherwise get Cygnus style configure.
- if test -f $ac_srcdir/configure.gnu; then
- echo
- $SHELL $ac_srcdir/configure.gnu --help=recursive
- elif test -f $ac_srcdir/configure; then
- echo
- $SHELL $ac_srcdir/configure --help=recursive
- elif test -f $ac_srcdir/configure.ac ||
- test -f $ac_srcdir/configure.in; then
- echo
- $ac_configure --help
- else
- echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
- fi
- cd $ac_popdir
- done
-fi
-
-test -n "$ac_init_help" && exit 0
-if $ac_init_version; then
- cat <<\_ACEOF
-
-Copyright (C) 2003 Free Software Foundation, Inc.
-This configure script is free software; the Free Software Foundation
-gives unlimited permission to copy, distribute and modify it.
-_ACEOF
- exit 0
-fi
-exec 5>config.log
-cat >&5 <<_ACEOF
-This file contains any messages produced by compilers while
-running configure, to aid debugging if configure makes a mistake.
+srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
-It was created by $as_me, which was
-generated by GNU Autoconf 2.59. Invocation command line was
-
- $ $0 $@
-
-_ACEOF
-{
-cat <<_ASUNAME
-## --------- ##
-## Platform. ##
-## --------- ##
-
-hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
-uname -m = `(uname -m) 2>/dev/null || echo unknown`
-uname -r = `(uname -r) 2>/dev/null || echo unknown`
-uname -s = `(uname -s) 2>/dev/null || echo unknown`
-uname -v = `(uname -v) 2>/dev/null || echo unknown`
-
-/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
-/bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
-
-/bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
-/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
-/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
-hostinfo = `(hostinfo) 2>/dev/null || echo unknown`
-/bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
-/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
-/bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
-
-_ASUNAME
-
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- echo "PATH: $as_dir"
-done
-
-} >&5
-
-cat >&5 <<_ACEOF
-
-
-## ----------- ##
-## Core tests. ##
-## ----------- ##
-
-_ACEOF
-
-
-# Keep a trace of the command line.
-# Strip out --no-create and --no-recursion so they do not pile up.
-# Strip out --silent because we don't want to record it for future runs.
-# Also quote any args containing shell meta-characters.
-# Make two passes to allow for proper duplicate-argument suppression.
-ac_configure_args=
-ac_configure_args0=
-ac_configure_args1=
-ac_sep=
-ac_must_keep_next=false
-for ac_pass in 1 2
-do
- for ac_arg
- do
- case $ac_arg in
- -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
- -q | -quiet | --quiet | --quie | --qui | --qu | --q \
- | -silent | --silent | --silen | --sile | --sil)
- continue ;;
- *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
- ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
- esac
- case $ac_pass in
- 1) ac_configure_args0="$ac_configure_args0 '$ac_arg'" ;;
- 2)
- ac_configure_args1="$ac_configure_args1 '$ac_arg'"
- if test $ac_must_keep_next = true; then
- ac_must_keep_next=false # Got value, back to normal.
- else
- case $ac_arg in
- *=* | --config-cache | -C | -disable-* | --disable-* \
- | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
- | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
- | -with-* | --with-* | -without-* | --without-* | --x)
- case "$ac_configure_args0 " in
- "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
- esac
- ;;
- -* ) ac_must_keep_next=true ;;
- esac
- fi
- ac_configure_args="$ac_configure_args$ac_sep'$ac_arg'"
- # Get rid of the leading space.
- ac_sep=" "
- ;;
- esac
- done
-done
-$as_unset ac_configure_args0 || test "${ac_configure_args0+set}" != set || { ac_configure_args0=; export ac_configure_args0; }
-$as_unset ac_configure_args1 || test "${ac_configure_args1+set}" != set || { ac_configure_args1=; export ac_configure_args1; }
-
-# When interrupted or exit'd, cleanup temporary files, and complete
-# config.log. We remove comments because anyway the quotes in there
-# would cause problems or look ugly.
-# WARNING: Be sure not to use single quotes in there, as some shells,
-# such as our DU 5.0 friend, will then `close' the trap.
-trap 'exit_status=$?
- # Save into config.log some information that might help in debugging.
- {
- echo
-
- cat <<\_ASBOX
-## ---------------- ##
-## Cache variables. ##
-## ---------------- ##
-_ASBOX
- echo
- # The following way of writing the cache mishandles newlines in values,
-{
- (set) 2>&1 |
- case `(ac_space='"'"' '"'"'; set | grep ac_space) 2>&1` in
- *ac_space=\ *)
- sed -n \
- "s/'"'"'/'"'"'\\\\'"'"''"'"'/g;
- s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='"'"'\\2'"'"'/p"
- ;;
- *)
- sed -n \
- "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
- ;;
- esac;
-}
- echo
-
- cat <<\_ASBOX
-## ----------------- ##
-## Output variables. ##
-## ----------------- ##
-_ASBOX
- echo
- for ac_var in $ac_subst_vars
- do
- eval ac_val=$`echo $ac_var`
- echo "$ac_var='"'"'$ac_val'"'"'"
- done | sort
- echo
-
- if test -n "$ac_subst_files"; then
- cat <<\_ASBOX
-## ------------- ##
-## Output files. ##
-## ------------- ##
-_ASBOX
- echo
- for ac_var in $ac_subst_files
- do
- eval ac_val=$`echo $ac_var`
- echo "$ac_var='"'"'$ac_val'"'"'"
- done | sort
- echo
- fi
-
- if test -s confdefs.h; then
- cat <<\_ASBOX
-## ----------- ##
-## confdefs.h. ##
-## ----------- ##
-_ASBOX
- echo
- sed "/^$/d" confdefs.h | sort
- echo
- fi
- test "$ac_signal" != 0 &&
- echo "$as_me: caught signal $ac_signal"
- echo "$as_me: exit $exit_status"
- } >&5
- rm -f core *.core &&
- rm -rf conftest* confdefs* conf$$* $ac_clean_files &&
- exit $exit_status
- ' 0
-for ac_signal in 1 2 13 15; do
- trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
-done
-ac_signal=0
-
-# confdefs.h avoids OS command line length limits that DEFS can exceed.
-rm -rf conftest* confdefs.h
-# AIX cpp loses on an empty file, so make sure it contains at least a newline.
-echo >confdefs.h
-
-# Predefined preprocessor variables.
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_NAME "$PACKAGE_NAME"
-_ACEOF
-
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_TARNAME "$PACKAGE_TARNAME"
-_ACEOF
-
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_VERSION "$PACKAGE_VERSION"
-_ACEOF
-
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_STRING "$PACKAGE_STRING"
-_ACEOF
-
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
-_ACEOF
-
-
-# Let the site file select an alternate cache file if it wants to.
# Prefer explicitly selected file to automatically selected ones.
if test -z "$CONFIG_SITE"; then
if test "x$prefix" != xNONE; then
@@ -1121,103 +486,39 @@ if test -z "$CONFIG_SITE"; then
fi
for ac_site_file in $CONFIG_SITE; do
if test -r "$ac_site_file"; then
- { echo "$as_me:$LINENO: loading site script $ac_site_file" >&5
-echo "$as_me: loading site script $ac_site_file" >&6;}
- sed 's/^/| /' "$ac_site_file" >&5
+ echo "loading site script $ac_site_file"
. "$ac_site_file"
fi
done
if test -r "$cache_file"; then
- # Some versions of bash will fail to source /dev/null (special
- # files actually), so we avoid doing that.
- if test -f "$cache_file"; then
- { echo "$as_me:$LINENO: loading cache $cache_file" >&5
-echo "$as_me: loading cache $cache_file" >&6;}
- case $cache_file in
- [\\/]* | ?:[\\/]* ) . $cache_file;;
- *) . ./$cache_file;;
- esac
- fi
+ echo "loading cache $cache_file"
+ . $cache_file
else
- { echo "$as_me:$LINENO: creating cache $cache_file" >&5
-echo "$as_me: creating cache $cache_file" >&6;}
- >$cache_file
-fi
-
-# Check that the precious variables saved in the cache have kept the same
-# value.
-ac_cache_corrupted=false
-for ac_var in `(set) 2>&1 |
- sed -n 's/^ac_env_\([a-zA-Z_0-9]*\)_set=.*/\1/p'`; do
- eval ac_old_set=\$ac_cv_env_${ac_var}_set
- eval ac_new_set=\$ac_env_${ac_var}_set
- eval ac_old_val="\$ac_cv_env_${ac_var}_value"
- eval ac_new_val="\$ac_env_${ac_var}_value"
- case $ac_old_set,$ac_new_set in
- set,)
- { echo "$as_me:$LINENO: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
-echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
- ac_cache_corrupted=: ;;
- ,set)
- { echo "$as_me:$LINENO: error: \`$ac_var' was not set in the previous run" >&5
-echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
- ac_cache_corrupted=: ;;
- ,);;
- *)
- if test "x$ac_old_val" != "x$ac_new_val"; then
- { echo "$as_me:$LINENO: error: \`$ac_var' has changed since the previous run:" >&5
-echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
- { echo "$as_me:$LINENO: former value: $ac_old_val" >&5
-echo "$as_me: former value: $ac_old_val" >&2;}
- { echo "$as_me:$LINENO: current value: $ac_new_val" >&5
-echo "$as_me: current value: $ac_new_val" >&2;}
- ac_cache_corrupted=:
- fi;;
- esac
- # Pass precious variables to config.status.
- if test "$ac_new_set" = set; then
- case $ac_new_val in
- *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
- ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
- *) ac_arg=$ac_var=$ac_new_val ;;
- esac
- case " $ac_configure_args " in
- *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
- *) ac_configure_args="$ac_configure_args '$ac_arg'" ;;
- esac
- fi
-done
-if $ac_cache_corrupted; then
- { echo "$as_me:$LINENO: error: changes in the environment can compromise the build" >&5
-echo "$as_me: error: changes in the environment can compromise the build" >&2;}
- { { echo "$as_me:$LINENO: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
-echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
- { (exit 1); exit 1; }; }
+ echo "creating cache $cache_file"
+ > $cache_file
fi
ac_ext=c
+# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
+ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
+cross_compiling=$ac_cv_prog_cc_cross
+
+ac_exeext=
+ac_objext=o
+if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
+ # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
+ if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
+ ac_n= ac_c='
+' ac_t=' '
+ else
+ ac_n=-n ac_c= ac_t=
+ fi
+else
+ ac_n= ac_c='\c' ac_t=
+fi
@@ -1233,1016 +534,367 @@ for ac_dir in `cd $srcdir;pwd`/../../.. $srcdir/`cd $srcdir;pwd`/../../..; do
ac_aux_dir=$ac_dir
ac_install_sh="$ac_aux_dir/install.sh -c"
break
- elif test -f $ac_dir/shtool; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/shtool install -c"
- break
fi
done
if test -z "$ac_aux_dir"; then
- { { echo "$as_me:$LINENO: error: cannot find install-sh or install.sh in \`cd $srcdir;pwd\`/../../.. $srcdir/\`cd $srcdir;pwd\`/../../.." >&5
-echo "$as_me: error: cannot find install-sh or install.sh in \`cd $srcdir;pwd\`/../../.. $srcdir/\`cd $srcdir;pwd\`/../../.." >&2;}
- { (exit 1); exit 1; }; }
+ { echo "configure: error: can not find install-sh or install.sh in `cd $srcdir;pwd`/../../.. $srcdir/`cd $srcdir;pwd`/../../.." 1>&2; exit 1; }
fi
-ac_config_guess="$SHELL $ac_aux_dir/config.guess"
-ac_config_sub="$SHELL $ac_aux_dir/config.sub"
-ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure.
+ac_config_guess=$ac_aux_dir/config.guess
+ac_config_sub=$ac_aux_dir/config.sub
+ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
-# Make sure we can run config.sub.
-$ac_config_sub sun4 >/dev/null 2>&1 ||
- { { echo "$as_me:$LINENO: error: cannot run $ac_config_sub" >&5
-echo "$as_me: error: cannot run $ac_config_sub" >&2;}
- { (exit 1); exit 1; }; }
-
-echo "$as_me:$LINENO: checking build system type" >&5
-echo $ECHO_N "checking build system type... $ECHO_C" >&6
-if test "${ac_cv_build+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
-else
- ac_cv_build_alias=$build_alias
-test -z "$ac_cv_build_alias" &&
- ac_cv_build_alias=`$ac_config_guess`
-test -z "$ac_cv_build_alias" &&
- { { echo "$as_me:$LINENO: error: cannot guess build type; you must specify one" >&5
-echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
- { (exit 1); exit 1; }; }
-ac_cv_build=`$ac_config_sub $ac_cv_build_alias` ||
- { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_build_alias failed" >&5
-echo "$as_me: error: $ac_config_sub $ac_cv_build_alias failed" >&2;}
- { (exit 1); exit 1; }; }
-fi
-echo "$as_me:$LINENO: result: $ac_cv_build" >&5
-echo "${ECHO_T}$ac_cv_build" >&6
-build=$ac_cv_build
-build_cpu=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
-build_vendor=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
-build_os=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
-
-
-echo "$as_me:$LINENO: checking host system type" >&5
-echo $ECHO_N "checking host system type... $ECHO_C" >&6
-if test "${ac_cv_host+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
-else
- ac_cv_host_alias=$host_alias
-test -z "$ac_cv_host_alias" &&
- ac_cv_host_alias=$ac_cv_build_alias
-ac_cv_host=`$ac_config_sub $ac_cv_host_alias` ||
- { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_host_alias failed" >&5
-echo "$as_me: error: $ac_config_sub $ac_cv_host_alias failed" >&2;}
- { (exit 1); exit 1; }; }
+# Do some error checking and defaulting for the host and target type.
+# The inputs are:
+# configure --host=HOST --target=TARGET --build=BUILD NONOPT
+#
+# The rules are:
+# 1. You are not allowed to specify --host, --target, and nonopt at the
+# same time.
+# 2. Host defaults to nonopt.
+# 3. If nonopt is not specified, then host defaults to the current host,
+# as determined by config.guess.
+# 4. Target and build default to nonopt.
+# 5. If nonopt is not specified, then target and build default to host.
-fi
-echo "$as_me:$LINENO: result: $ac_cv_host" >&5
-echo "${ECHO_T}$ac_cv_host" >&6
-host=$ac_cv_host
-host_cpu=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
-host_vendor=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
-host_os=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
-
-
-echo "$as_me:$LINENO: checking target system type" >&5
-echo $ECHO_N "checking target system type... $ECHO_C" >&6
-if test "${ac_cv_target+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
-else
- ac_cv_target_alias=$target_alias
-test "x$ac_cv_target_alias" = "x" &&
- ac_cv_target_alias=$ac_cv_host_alias
-ac_cv_target=`$ac_config_sub $ac_cv_target_alias` ||
- { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_target_alias failed" >&5
-echo "$as_me: error: $ac_config_sub $ac_cv_target_alias failed" >&2;}
- { (exit 1); exit 1; }; }
+# The aliases save the names the user supplied, while $host etc.
+# will get canonicalized.
+case $host---$target---$nonopt in
+NONE---*---* | *---NONE---* | *---*---NONE) ;;
+*) { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; } ;;
+esac
+
+# Make sure we can run config.sub.
+if ${CONFIG_SHELL-/bin/sh} $ac_config_sub sun4 >/dev/null 2>&1; then :
+else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
fi
-echo "$as_me:$LINENO: result: $ac_cv_target" >&5
-echo "${ECHO_T}$ac_cv_target" >&6
-target=$ac_cv_target
-target_cpu=`echo $ac_cv_target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
-target_vendor=`echo $ac_cv_target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
-target_os=`echo $ac_cv_target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
+echo $ac_n "checking host system type""... $ac_c" 1>&6
+echo "configure:575: checking host system type" >&5
-# The aliases save the names the user supplied, while $host etc.
-# will get canonicalized.
-test -n "$target_alias" &&
+host_alias=$host
+case "$host_alias" in
+NONE)
+ case $nonopt in
+ NONE)
+ if host_alias=`${CONFIG_SHELL-/bin/sh} $ac_config_guess`; then :
+ else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; }
+ fi ;;
+ *) host_alias=$nonopt ;;
+ esac ;;
+esac
+
+host=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $host_alias`
+host_cpu=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
+host_vendor=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
+host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
+echo "$ac_t""$host" 1>&6
+
+echo $ac_n "checking target system type""... $ac_c" 1>&6
+echo "configure:596: checking target system type" >&5
+
+target_alias=$target
+case "$target_alias" in
+NONE)
+ case $nonopt in
+ NONE) target_alias=$host_alias ;;
+ *) target_alias=$nonopt ;;
+ esac ;;
+esac
+
+target=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $target_alias`
+target_cpu=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
+target_vendor=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
+target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
+echo "$ac_t""$target" 1>&6
+
+echo $ac_n "checking build system type""... $ac_c" 1>&6
+echo "configure:614: checking build system type" >&5
+
+build_alias=$build
+case "$build_alias" in
+NONE)
+ case $nonopt in
+ NONE) build_alias=$host_alias ;;
+ *) build_alias=$nonopt ;;
+ esac ;;
+esac
+
+build=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $build_alias`
+build_cpu=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
+build_vendor=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
+build_os=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
+echo "$ac_t""$build" 1>&6
+
+test "$host_alias" != "$target_alias" &&
test "$program_prefix$program_suffix$program_transform_name" = \
NONENONEs,x,x, &&
program_prefix=${target_alias}-
-
-
- ac_config_files="$ac_config_files Makefile"
-cat >confcache <<\_ACEOF
+trap '' 1 2 15
+cat > confcache <<\EOF
# This file is a shell script that caches the results of configure
# tests run on this system so they can be shared between configure
-# scripts and configure runs, see configure's option --config-cache.
-# It is not useful on other systems. If it contains results you don't
-# want to keep, you may remove or edit it.
+# scripts and configure runs. It is not useful on other systems.
+# If it contains results you don't want to keep, you may remove or edit it.
#
-# config.status only pays attention to the cache file if you give it
-# the --recheck option to rerun configure.
+# By default, configure uses ./config.cache as the cache file,
+# creating it if it does not exist already. You can give configure
+# the --cache-file=FILE option to use a different cache file; that is
+# what configure does when it calls configure scripts in
+# subdirectories, so they share the cache.
+# Giving --cache-file=/dev/null disables caching, for debugging configure.
+# config.status only pays attention to the cache file if you give it the
+# --recheck option to rerun configure.
#
-# `ac_cv_env_foo' variables (set or unset) will be overridden when
-# loading this file, other *unset* `ac_cv_foo' will be assigned the
-# following values.
-
-_ACEOF
-
+EOF
# The following way of writing the cache mishandles newlines in values,
# but we know of no workaround that is simple, portable, and efficient.
# So, don't put newlines in cache variables' values.
# Ultrix sh set writes to stderr and can't be redirected directly,
# and sets the high bit in the cache file unless we assign to the vars.
-{
- (set) 2>&1 |
- case `(ac_space=' '; set | grep ac_space) 2>&1` in
- *ac_space=\ *)
- # `set' does not quote correctly, so add quotes (double-quote
- # substitution turns \\\\ into \\, and sed turns \\ into \).
- sed -n \
- "s/'/'\\\\''/g;
- s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
- ;;
- *)
- # `set' quotes correctly as required by POSIX, so do not add quotes.
- sed -n \
- "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
- ;;
- esac;
-} |
- sed '
- t clear
- : clear
- s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
- t end
- /^ac_cv_env/!s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
- : end' >>confcache
-if diff $cache_file confcache >/dev/null 2>&1; then :; else
+(set) 2>&1 |
+ case `(ac_space=' '; set) 2>&1 | grep ac_space` in
+ *ac_space=\ *)
+ # `set' does not quote correctly, so add quotes (double-quote substitution
+ # turns \\\\ into \\, and sed turns \\ into \).
+ sed -n \
+ -e "s/'/'\\\\''/g" \
+ -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
+ ;;
+ *)
+ # `set' quotes correctly as required by POSIX, so do not add quotes.
+ sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
+ ;;
+ esac >> confcache
+if cmp -s $cache_file confcache; then
+ :
+else
if test -w $cache_file; then
- test "x$cache_file" != "x/dev/null" && echo "updating cache $cache_file"
- cat confcache >$cache_file
+ echo "updating cache $cache_file"
+ cat confcache > $cache_file
else
echo "not updating unwritable cache $cache_file"
fi
fi
rm -f confcache
+trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
+
test "x$prefix" = xNONE && prefix=$ac_default_prefix
# Let make expand exec_prefix.
test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
-# VPATH may cause trouble with some makes, so we remove $(srcdir),
-# ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
-# trailing colons and then remove the whole line if VPATH becomes empty
-# (actually we leave an empty line to preserve line numbers).
+# Any assignment to VPATH causes Sun make to only execute
+# the first set of double-colon rules, so remove it if not needed.
+# If there is a colon in the path, we need to keep it.
if test "x$srcdir" = x.; then
- ac_vpsub='/^[ ]*VPATH[ ]*=/{
-s/:*\$(srcdir):*/:/;
-s/:*\${srcdir}:*/:/;
-s/:*@srcdir@:*/:/;
-s/^\([^=]*=[ ]*\):*/\1/;
-s/:*$//;
-s/^[^=]*=[ ]*$//;
-}'
+ ac_vpsub='/^[ ]*VPATH[ ]*=[^:]*$/d'
fi
+trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
+
# Transform confdefs.h into DEFS.
# Protect against shell expansion while executing Makefile rules.
# Protect against Makefile macro expansion.
-#
-# If the first sed substitution is executed (which looks for macros that
-# take arguments), then we branch to the quote section. Otherwise,
-# look for a macro that doesn't take arguments.
-cat >confdef2opt.sed <<\_ACEOF
-t clear
-: clear
-s,^[ ]*#[ ]*define[ ][ ]*\([^ (][^ (]*([^)]*)\)[ ]*\(.*\),-D\1=\2,g
-t quote
-s,^[ ]*#[ ]*define[ ][ ]*\([^ ][^ ]*\)[ ]*\(.*\),-D\1=\2,g
-t quote
-d
-: quote
-s,[ `~#$^&*(){}\\|;'"<>?],\\&,g
-s,\[,\\&,g
-s,\],\\&,g
-s,\$,$$,g
-p
-_ACEOF
-# We use echo to avoid assuming a particular line-breaking character.
-# The extra dot is to prevent the shell from consuming trailing
-# line-breaks from the sub-command output. A line-break within
-# single-quotes doesn't work because, if this script is created in a
-# platform that uses two characters for line-breaks (e.g., DOS), tr
-# would break.
-ac_LF_and_DOT=`echo; echo .`
-DEFS=`sed -n -f confdef2opt.sed confdefs.h | tr "$ac_LF_and_DOT" ' .'`
-rm -f confdef2opt.sed
-
-
-ac_libobjs=
-ac_ltlibobjs=
-for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
- # 1. Remove the extension, and $U if already installed.
- ac_i=`echo "$ac_i" |
- sed 's/\$U\././;s/\.o$//;s/\.obj$//'`
- # 2. Add them.
- ac_libobjs="$ac_libobjs $ac_i\$U.$ac_objext"
- ac_ltlibobjs="$ac_ltlibobjs $ac_i"'$U.lo'
-done
-LIBOBJS=$ac_libobjs
-
-LTLIBOBJS=$ac_ltlibobjs
-
-
-
+cat > conftest.defs <<\EOF
+s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%-D\1=\2%g
+s%[ `~#$^&*(){}\\|;'"<>?]%\\&%g
+s%\[%\\&%g
+s%\]%\\&%g
+s%\$%$$%g
+EOF
+DEFS=`sed -f conftest.defs confdefs.h | tr '\012' ' '`
+rm -f conftest.defs
+
+
+# Without the "./", some shells look in PATH for config.status.
: ${CONFIG_STATUS=./config.status}
-ac_clean_files_save=$ac_clean_files
-ac_clean_files="$ac_clean_files $CONFIG_STATUS"
-{ echo "$as_me:$LINENO: creating $CONFIG_STATUS" >&5
-echo "$as_me: creating $CONFIG_STATUS" >&6;}
-cat >$CONFIG_STATUS <<_ACEOF
-#! $SHELL
-# Generated by $as_me.
+
+echo creating $CONFIG_STATUS
+rm -f $CONFIG_STATUS
+cat > $CONFIG_STATUS <<EOF
+#! /bin/sh
+# Generated automatically by configure.
# Run this file to recreate the current configuration.
+# This directory was configured as follows,
+# on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
+#
+# $0 $ac_configure_args
+#
# Compiler output produced by configure, useful for debugging
-# configure, is in config.log if it exists.
-
-debug=false
-ac_cs_recheck=false
-ac_cs_silent=false
-SHELL=\${CONFIG_SHELL-$SHELL}
-_ACEOF
-
-cat >>$CONFIG_STATUS <<\_ACEOF
-## --------------------- ##
-## M4sh Initialization. ##
-## --------------------- ##
-
-# Be Bourne compatible
-if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
- emulate sh
- NULLCMD=:
- # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
- # is contrary to our usage. Disable this feature.
- alias -g '${1+"$@"}'='"$@"'
-elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
- set -o posix
-fi
-DUALCASE=1; export DUALCASE # for MKS sh
-
-# Support unset when possible.
-if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
- as_unset=unset
-else
- as_unset=false
-fi
+# configure, is in ./config.log if it exists.
-
-# Work around bugs in pre-3.0 UWIN ksh.
-$as_unset ENV MAIL MAILPATH
-PS1='$ '
-PS2='> '
-PS4='+ '
-
-# NLS nuisances.
-for as_var in \
- LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \
- LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \
- LC_TELEPHONE LC_TIME
+ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
+for ac_option
do
- if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then
- eval $as_var=C; export $as_var
- else
- $as_unset $as_var
- fi
+ case "\$ac_option" in
+ -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
+ echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
+ exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
+ -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
+ echo "$CONFIG_STATUS generated by autoconf version 2.12.2"
+ exit 0 ;;
+ -help | --help | --hel | --he | --h)
+ echo "\$ac_cs_usage"; exit 0 ;;
+ *) echo "\$ac_cs_usage"; exit 1 ;;
+ esac
done
-# Required to use basename.
-if expr a : '\(a\)' >/dev/null 2>&1; then
- as_expr=expr
-else
- as_expr=false
-fi
+ac_given_srcdir=$srcdir
-if (basename /) >/dev/null 2>&1 && test "X`basename / 2>&1`" = "X/"; then
- as_basename=basename
-else
- as_basename=false
-fi
+trap 'rm -fr `echo "Makefile" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
+EOF
+cat >> $CONFIG_STATUS <<EOF
+# Protect against being on the right side of a sed subst in config.status.
+sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g;
+ s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF
+$ac_vpsub
+$extrasub
+s%@SHELL@%$SHELL%g
+s%@CFLAGS@%$CFLAGS%g
+s%@CPPFLAGS@%$CPPFLAGS%g
+s%@CXXFLAGS@%$CXXFLAGS%g
+s%@DEFS@%$DEFS%g
+s%@LDFLAGS@%$LDFLAGS%g
+s%@LIBS@%$LIBS%g
+s%@exec_prefix@%$exec_prefix%g
+s%@prefix@%$prefix%g
+s%@program_transform_name@%$program_transform_name%g
+s%@bindir@%$bindir%g
+s%@sbindir@%$sbindir%g
+s%@libexecdir@%$libexecdir%g
+s%@datadir@%$datadir%g
+s%@sysconfdir@%$sysconfdir%g
+s%@sharedstatedir@%$sharedstatedir%g
+s%@localstatedir@%$localstatedir%g
+s%@libdir@%$libdir%g
+s%@includedir@%$includedir%g
+s%@oldincludedir@%$oldincludedir%g
+s%@infodir@%$infodir%g
+s%@mandir@%$mandir%g
+s%@CC@%$CC%g
+s%@host@%$host%g
+s%@host_alias@%$host_alias%g
+s%@host_cpu@%$host_cpu%g
+s%@host_vendor@%$host_vendor%g
+s%@host_os@%$host_os%g
+s%@target@%$target%g
+s%@target_alias@%$target_alias%g
+s%@target_cpu@%$target_cpu%g
+s%@target_vendor@%$target_vendor%g
+s%@target_os@%$target_os%g
+s%@build@%$build%g
+s%@build_alias@%$build_alias%g
+s%@build_cpu@%$build_cpu%g
+s%@build_vendor@%$build_vendor%g
+s%@build_os@%$build_os%g
-# Name of the executable.
-as_me=`$as_basename "$0" ||
-$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
- X"$0" : 'X\(//\)$' \| \
- X"$0" : 'X\(/\)$' \| \
- . : '\(.\)' 2>/dev/null ||
-echo X/"$0" |
- sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/; q; }
- /^X\/\(\/\/\)$/{ s//\1/; q; }
- /^X\/\(\/\).*/{ s//\1/; q; }
- s/.*/./; q'`
-
-
-# PATH needs CR, and LINENO needs CR and PATH.
-# Avoid depending upon Character Ranges.
-as_cr_letters='abcdefghijklmnopqrstuvwxyz'
-as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
-as_cr_Letters=$as_cr_letters$as_cr_LETTERS
-as_cr_digits='0123456789'
-as_cr_alnum=$as_cr_Letters$as_cr_digits
-
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- echo "#! /bin/sh" >conf$$.sh
- echo "exit 0" >>conf$$.sh
- chmod +x conf$$.sh
- if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
- PATH_SEPARATOR=';'
+CEOF
+EOF
+
+cat >> $CONFIG_STATUS <<\EOF
+
+# Split the substitutions into bite-sized pieces for seds with
+# small command number limits, like on Digital OSF/1 and HP-UX.
+ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script.
+ac_file=1 # Number of current file.
+ac_beg=1 # First line for current file.
+ac_end=$ac_max_sed_cmds # Line after last line for current file.
+ac_more_lines=:
+ac_sed_cmds=""
+while $ac_more_lines; do
+ if test $ac_beg -gt 1; then
+ sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file
else
- PATH_SEPARATOR=:
- fi
- rm -f conf$$.sh
-fi
-
-
- as_lineno_1=$LINENO
- as_lineno_2=$LINENO
- as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
- test "x$as_lineno_1" != "x$as_lineno_2" &&
- test "x$as_lineno_3" = "x$as_lineno_2" || {
- # Find who we are. Look in the path if we contain no path at all
- # relative or not.
- case $0 in
- *[\\/]* ) as_myself=$0 ;;
- *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
-done
-
- ;;
- esac
- # We did not find ourselves, most probably we were run as `sh COMMAND'
- # in which case we are not to be found in the path.
- if test "x$as_myself" = x; then
- as_myself=$0
- fi
- if test ! -f "$as_myself"; then
- { { echo "$as_me:$LINENO: error: cannot find myself; rerun with an absolute path" >&5
-echo "$as_me: error: cannot find myself; rerun with an absolute path" >&2;}
- { (exit 1); exit 1; }; }
+ sed "${ac_end}q" conftest.subs > conftest.s$ac_file
fi
- case $CONFIG_SHELL in
- '')
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for as_base in sh bash ksh sh5; do
- case $as_dir in
- /*)
- if ("$as_dir/$as_base" -c '
- as_lineno_1=$LINENO
- as_lineno_2=$LINENO
- as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
- test "x$as_lineno_1" != "x$as_lineno_2" &&
- test "x$as_lineno_3" = "x$as_lineno_2" ') 2>/dev/null; then
- $as_unset BASH_ENV || test "${BASH_ENV+set}" != set || { BASH_ENV=; export BASH_ENV; }
- $as_unset ENV || test "${ENV+set}" != set || { ENV=; export ENV; }
- CONFIG_SHELL=$as_dir/$as_base
- export CONFIG_SHELL
- exec "$CONFIG_SHELL" "$0" ${1+"$@"}
- fi;;
- esac
- done
-done
-;;
- esac
-
- # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
- # uniformly replaced by the line number. The first 'sed' inserts a
- # line-number line before each line; the second 'sed' does the real
- # work. The second script uses 'N' to pair each line-number line
- # with the numbered line, and appends trailing '-' during
- # substitution so that $LINENO is not a special case at line end.
- # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
- # second 'sed' script. Blame Lee E. McMahon for sed's syntax. :-)
- sed '=' <$as_myself |
- sed '
- N
- s,$,-,
- : loop
- s,^\(['$as_cr_digits']*\)\(.*\)[$]LINENO\([^'$as_cr_alnum'_]\),\1\2\1\3,
- t loop
- s,-$,,
- s,^['$as_cr_digits']*\n,,
- ' >$as_me.lineno &&
- chmod +x $as_me.lineno ||
- { { echo "$as_me:$LINENO: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&5
-echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2;}
- { (exit 1); exit 1; }; }
-
- # Don't try to exec as it changes $[0], causing all sort of problems
- # (the dirname of $[0] is not the place where we might find the
- # original and so on. Autoconf is especially sensible to this).
- . ./$as_me.lineno
- # Exit status is that of the last command.
- exit
-}
-
-
-case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
- *c*,-n*) ECHO_N= ECHO_C='
-' ECHO_T=' ' ;;
- *c*,* ) ECHO_N=-n ECHO_C= ECHO_T= ;;
- *) ECHO_N= ECHO_C='\c' ECHO_T= ;;
-esac
-
-if expr a : '\(a\)' >/dev/null 2>&1; then
- as_expr=expr
-else
- as_expr=false
-fi
-
-rm -f conf$$ conf$$.exe conf$$.file
-echo >conf$$.file
-if ln -s conf$$.file conf$$ 2>/dev/null; then
- # We could just check for DJGPP; but this test a) works b) is more generic
- # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
- if test -f conf$$.exe; then
- # Don't use ln at all; we don't have any links
- as_ln_s='cp -p'
+ if test ! -s conftest.s$ac_file; then
+ ac_more_lines=false
+ rm -f conftest.s$ac_file
else
- as_ln_s='ln -s'
+ if test -z "$ac_sed_cmds"; then
+ ac_sed_cmds="sed -f conftest.s$ac_file"
+ else
+ ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file"
+ fi
+ ac_file=`expr $ac_file + 1`
+ ac_beg=$ac_end
+ ac_end=`expr $ac_end + $ac_max_sed_cmds`
fi
-elif ln conf$$.file conf$$ 2>/dev/null; then
- as_ln_s=ln
-else
- as_ln_s='cp -p'
-fi
-rm -f conf$$ conf$$.exe conf$$.file
-
-if mkdir -p . 2>/dev/null; then
- as_mkdir_p=:
-else
- test -d ./-p && rmdir ./-p
- as_mkdir_p=false
-fi
-
-as_executable_p="test -f"
-
-# Sed expression to map a string onto a valid CPP name.
-as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
-
-# Sed expression to map a string onto a valid variable name.
-as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
-
-
-# IFS
-# We need space, tab and new line, in precisely that order.
-as_nl='
-'
-IFS=" $as_nl"
-
-# CDPATH.
-$as_unset CDPATH
-
-exec 6>&1
-
-# Open the log real soon, to keep \$[0] and so on meaningful, and to
-# report actual input values of CONFIG_FILES etc. instead of their
-# values after options handling. Logging --version etc. is OK.
-exec 5>>config.log
-{
- echo
- sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
-## Running $as_me. ##
-_ASBOX
-} >&5
-cat >&5 <<_CSEOF
-
-This file was extended by $as_me, which was
-generated by GNU Autoconf 2.59. Invocation command line was
-
- CONFIG_FILES = $CONFIG_FILES
- CONFIG_HEADERS = $CONFIG_HEADERS
- CONFIG_LINKS = $CONFIG_LINKS
- CONFIG_COMMANDS = $CONFIG_COMMANDS
- $ $0 $@
-
-_CSEOF
-echo "on `(hostname || uname -n) 2>/dev/null | sed 1q`" >&5
-echo >&5
-_ACEOF
-
-# Files that config.status was made for.
-if test -n "$ac_config_files"; then
- echo "config_files=\"$ac_config_files\"" >>$CONFIG_STATUS
-fi
-
-if test -n "$ac_config_headers"; then
- echo "config_headers=\"$ac_config_headers\"" >>$CONFIG_STATUS
-fi
-
-if test -n "$ac_config_links"; then
- echo "config_links=\"$ac_config_links\"" >>$CONFIG_STATUS
-fi
-
-if test -n "$ac_config_commands"; then
- echo "config_commands=\"$ac_config_commands\"" >>$CONFIG_STATUS
-fi
-
-cat >>$CONFIG_STATUS <<\_ACEOF
-
-ac_cs_usage="\
-\`$as_me' instantiates files from templates according to the
-current configuration.
-
-Usage: $0 [OPTIONS] [FILE]...
-
- -h, --help print this help, then exit
- -V, --version print version number, then exit
- -q, --quiet do not print progress messages
- -d, --debug don't remove temporary files
- --recheck update $as_me by reconfiguring in the same conditions
- --file=FILE[:TEMPLATE]
- instantiate the configuration file FILE
-
-Configuration files:
-$config_files
-
-Report bugs to <bug-autoconf@gnu.org>."
-_ACEOF
-
-cat >>$CONFIG_STATUS <<_ACEOF
-ac_cs_version="\\
-config.status
-configured by $0, generated by GNU Autoconf 2.59,
- with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
-
-Copyright (C) 2003 Free Software Foundation, Inc.
-This config.status script is free software; the Free Software Foundation
-gives unlimited permission to copy, distribute and modify it."
-srcdir=$srcdir
-_ACEOF
-
-cat >>$CONFIG_STATUS <<\_ACEOF
-# If no file are specified by the user, then we need to provide default
-# value. By we need to know if files were specified by the user.
-ac_need_defaults=:
-while test $# != 0
-do
- case $1 in
- --*=*)
- ac_option=`expr "x$1" : 'x\([^=]*\)='`
- ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'`
- ac_shift=:
- ;;
- -*)
- ac_option=$1
- ac_optarg=$2
- ac_shift=shift
- ;;
- *) # This is not an option, so the user has probably given explicit
- # arguments.
- ac_option=$1
- ac_need_defaults=false;;
- esac
-
- case $ac_option in
- # Handling of the options.
-_ACEOF
-cat >>$CONFIG_STATUS <<\_ACEOF
- -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
- ac_cs_recheck=: ;;
- --version | --vers* | -V )
- echo "$ac_cs_version"; exit 0 ;;
- --he | --h)
- # Conflict between --help and --header
- { { echo "$as_me:$LINENO: error: ambiguous option: $1
-Try \`$0 --help' for more information." >&5
-echo "$as_me: error: ambiguous option: $1
-Try \`$0 --help' for more information." >&2;}
- { (exit 1); exit 1; }; };;
- --help | --hel | -h )
- echo "$ac_cs_usage"; exit 0 ;;
- --debug | --d* | -d )
- debug=: ;;
- --file | --fil | --fi | --f )
- $ac_shift
- CONFIG_FILES="$CONFIG_FILES $ac_optarg"
- ac_need_defaults=false;;
- --header | --heade | --head | --hea )
- $ac_shift
- CONFIG_HEADERS="$CONFIG_HEADERS $ac_optarg"
- ac_need_defaults=false;;
- -q | -quiet | --quiet | --quie | --qui | --qu | --q \
- | -silent | --silent | --silen | --sile | --sil | --si | --s)
- ac_cs_silent=: ;;
-
- # This is an error.
- -*) { { echo "$as_me:$LINENO: error: unrecognized option: $1
-Try \`$0 --help' for more information." >&5
-echo "$as_me: error: unrecognized option: $1
-Try \`$0 --help' for more information." >&2;}
- { (exit 1); exit 1; }; } ;;
-
- *) ac_config_targets="$ac_config_targets $1" ;;
-
- esac
- shift
done
-
-ac_configure_extra_args=
-
-if $ac_cs_silent; then
- exec 6>/dev/null
- ac_configure_extra_args="$ac_configure_extra_args --silent"
-fi
-
-_ACEOF
-cat >>$CONFIG_STATUS <<_ACEOF
-if \$ac_cs_recheck; then
- echo "running $SHELL $0 " $ac_configure_args \$ac_configure_extra_args " --no-create --no-recursion" >&6
- exec $SHELL $0 $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
-fi
-
-_ACEOF
-
-
-
-
-
-cat >>$CONFIG_STATUS <<\_ACEOF
-for ac_config_target in $ac_config_targets
-do
- case "$ac_config_target" in
- # Handling of arguments.
- "Makefile" ) CONFIG_FILES="$CONFIG_FILES Makefile" ;;
- *) { { echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5
-echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
- { (exit 1); exit 1; }; };;
- esac
-done
-
-# If the user did not use the arguments to specify the items to instantiate,
-# then the envvar interface is used. Set only those that are not.
-# We use the long form for the default assignment because of an extremely
-# bizarre bug on SunOS 4.1.3.
-if $ac_need_defaults; then
- test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
+if test -z "$ac_sed_cmds"; then
+ ac_sed_cmds=cat
fi
+EOF
-# Have a temporary directory for convenience. Make it in the build tree
-# simply because there is no reason to put it here, and in addition,
-# creating and moving files from /tmp can sometimes cause problems.
-# Create a temporary directory, and hook for its removal unless debugging.
-$debug ||
-{
- trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
- trap '{ (exit 1); exit 1; }' 1 2 13 15
-}
-
-# Create a (secure) tmp directory for tmp files.
-
-{
- tmp=`(umask 077 && mktemp -d -q "./confstatXXXXXX") 2>/dev/null` &&
- test -n "$tmp" && test -d "$tmp"
-} ||
-{
- tmp=./confstat$$-$RANDOM
- (umask 077 && mkdir $tmp)
-} ||
-{
- echo "$me: cannot create a temporary directory in ." >&2
- { (exit 1); exit 1; }
-}
-
-_ACEOF
-
-cat >>$CONFIG_STATUS <<_ACEOF
-
-#
-# CONFIG_FILES section.
-#
-
-# No need to generate the scripts if there are no CONFIG_FILES.
-# This happens for instance when ./config.status config.h
-if test -n "\$CONFIG_FILES"; then
- # Protect against being on the right side of a sed subst in config.status.
- sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g;
- s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >\$tmp/subs.sed <<\\CEOF
-s,@SHELL@,$SHELL,;t t
-s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t
-s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t
-s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t
-s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t
-s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t
-s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t
-s,@exec_prefix@,$exec_prefix,;t t
-s,@prefix@,$prefix,;t t
-s,@program_transform_name@,$program_transform_name,;t t
-s,@bindir@,$bindir,;t t
-s,@sbindir@,$sbindir,;t t
-s,@libexecdir@,$libexecdir,;t t
-s,@datadir@,$datadir,;t t
-s,@sysconfdir@,$sysconfdir,;t t
-s,@sharedstatedir@,$sharedstatedir,;t t
-s,@localstatedir@,$localstatedir,;t t
-s,@libdir@,$libdir,;t t
-s,@includedir@,$includedir,;t t
-s,@oldincludedir@,$oldincludedir,;t t
-s,@infodir@,$infodir,;t t
-s,@mandir@,$mandir,;t t
-s,@build_alias@,$build_alias,;t t
-s,@host_alias@,$host_alias,;t t
-s,@target_alias@,$target_alias,;t t
-s,@DEFS@,$DEFS,;t t
-s,@ECHO_C@,$ECHO_C,;t t
-s,@ECHO_N@,$ECHO_N,;t t
-s,@ECHO_T@,$ECHO_T,;t t
-s,@LIBS@,$LIBS,;t t
-s,@CC@,$CC,;t t
-s,@build@,$build,;t t
-s,@build_cpu@,$build_cpu,;t t
-s,@build_vendor@,$build_vendor,;t t
-s,@build_os@,$build_os,;t t
-s,@host@,$host,;t t
-s,@host_cpu@,$host_cpu,;t t
-s,@host_vendor@,$host_vendor,;t t
-s,@host_os@,$host_os,;t t
-s,@target@,$target,;t t
-s,@target_cpu@,$target_cpu,;t t
-s,@target_vendor@,$target_vendor,;t t
-s,@target_os@,$target_os,;t t
-s,@LIBOBJS@,$LIBOBJS,;t t
-s,@LTLIBOBJS@,$LTLIBOBJS,;t t
-CEOF
+cat >> $CONFIG_STATUS <<EOF
-_ACEOF
-
- cat >>$CONFIG_STATUS <<\_ACEOF
- # Split the substitutions into bite-sized pieces for seds with
- # small command number limits, like on Digital OSF/1 and HP-UX.
- ac_max_sed_lines=48
- ac_sed_frag=1 # Number of current file.
- ac_beg=1 # First line for current file.
- ac_end=$ac_max_sed_lines # Line after last line for current file.
- ac_more_lines=:
- ac_sed_cmds=
- while $ac_more_lines; do
- if test $ac_beg -gt 1; then
- sed "1,${ac_beg}d; ${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
- else
- sed "${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
- fi
- if test ! -s $tmp/subs.frag; then
- ac_more_lines=false
- else
- # The purpose of the label and of the branching condition is to
- # speed up the sed processing (if there are no `@' at all, there
- # is no need to browse any of the substitutions).
- # These are the two extra sed commands mentioned above.
- (echo ':t
- /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && cat $tmp/subs.frag) >$tmp/subs-$ac_sed_frag.sed
- if test -z "$ac_sed_cmds"; then
- ac_sed_cmds="sed -f $tmp/subs-$ac_sed_frag.sed"
- else
- ac_sed_cmds="$ac_sed_cmds | sed -f $tmp/subs-$ac_sed_frag.sed"
- fi
- ac_sed_frag=`expr $ac_sed_frag + 1`
- ac_beg=$ac_end
- ac_end=`expr $ac_end + $ac_max_sed_lines`
- fi
- done
- if test -z "$ac_sed_cmds"; then
- ac_sed_cmds=cat
- fi
-fi # test -n "$CONFIG_FILES"
-
-_ACEOF
-cat >>$CONFIG_STATUS <<\_ACEOF
-for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue
+CONFIG_FILES=\${CONFIG_FILES-"Makefile"}
+EOF
+cat >> $CONFIG_STATUS <<\EOF
+for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
# Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
- case $ac_file in
- - | *:- | *:-:* ) # input from stdin
- cat >$tmp/stdin
- ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
- ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
- *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
- ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
- * ) ac_file_in=$ac_file.in ;;
+ case "$ac_file" in
+ *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
+ ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
+ *) ac_file_in="${ac_file}.in" ;;
esac
- # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories.
- ac_dir=`(dirname "$ac_file") 2>/dev/null ||
-$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
- X"$ac_file" : 'X\(//\)[^/]' \| \
- X"$ac_file" : 'X\(//\)$' \| \
- X"$ac_file" : 'X\(/\)' \| \
- . : '\(.\)' 2>/dev/null ||
-echo X"$ac_file" |
- sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
- /^X\(\/\/\)[^/].*/{ s//\1/; q; }
- /^X\(\/\/\)$/{ s//\1/; q; }
- /^X\(\/\).*/{ s//\1/; q; }
- s/.*/./; q'`
- { if $as_mkdir_p; then
- mkdir -p "$ac_dir"
+ # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories.
+
+ # Remove last slash and all that follows it. Not all systems have dirname.
+ ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
+ if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
+ # The file is in a subdirectory.
+ test ! -d "$ac_dir" && mkdir "$ac_dir"
+ ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
+ # A "../" for each directory in $ac_dir_suffix.
+ ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
else
- as_dir="$ac_dir"
- as_dirs=
- while test ! -d "$as_dir"; do
- as_dirs="$as_dir $as_dirs"
- as_dir=`(dirname "$as_dir") 2>/dev/null ||
-$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
- X"$as_dir" : 'X\(//\)[^/]' \| \
- X"$as_dir" : 'X\(//\)$' \| \
- X"$as_dir" : 'X\(/\)' \| \
- . : '\(.\)' 2>/dev/null ||
-echo X"$as_dir" |
- sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
- /^X\(\/\/\)[^/].*/{ s//\1/; q; }
- /^X\(\/\/\)$/{ s//\1/; q; }
- /^X\(\/\).*/{ s//\1/; q; }
- s/.*/./; q'`
- done
- test ! -n "$as_dirs" || mkdir $as_dirs
- fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
-echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
- { (exit 1); exit 1; }; }; }
-
- ac_builddir=.
-
-if test "$ac_dir" != .; then
- ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
- # A "../" for each directory in $ac_dir_suffix.
- ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
-else
- ac_dir_suffix= ac_top_builddir=
-fi
+ ac_dir_suffix= ac_dots=
+ fi
-case $srcdir in
- .) # No --srcdir option. We are building in place.
- ac_srcdir=.
- if test -z "$ac_top_builddir"; then
- ac_top_srcdir=.
- else
- ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
- fi ;;
- [\\/]* | ?:[\\/]* ) # Absolute path.
- ac_srcdir=$srcdir$ac_dir_suffix;
- ac_top_srcdir=$srcdir ;;
+ case "$ac_given_srcdir" in
+ .) srcdir=.
+ if test -z "$ac_dots"; then top_srcdir=.
+ else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
+ /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
*) # Relative path.
- ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
- ac_top_srcdir=$ac_top_builddir$srcdir ;;
-esac
-
-# Do not use `cd foo && pwd` to compute absolute paths, because
-# the directories may not exist.
-case `pwd` in
-.) ac_abs_builddir="$ac_dir";;
-*)
- case "$ac_dir" in
- .) ac_abs_builddir=`pwd`;;
- [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";;
- *) ac_abs_builddir=`pwd`/"$ac_dir";;
- esac;;
-esac
-case $ac_abs_builddir in
-.) ac_abs_top_builddir=${ac_top_builddir}.;;
-*)
- case ${ac_top_builddir}. in
- .) ac_abs_top_builddir=$ac_abs_builddir;;
- [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
- *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
- esac;;
-esac
-case $ac_abs_builddir in
-.) ac_abs_srcdir=$ac_srcdir;;
-*)
- case $ac_srcdir in
- .) ac_abs_srcdir=$ac_abs_builddir;;
- [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
- *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
- esac;;
-esac
-case $ac_abs_builddir in
-.) ac_abs_top_srcdir=$ac_top_srcdir;;
-*)
- case $ac_top_srcdir in
- .) ac_abs_top_srcdir=$ac_abs_builddir;;
- [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
- *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
- esac;;
-esac
+ srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
+ top_srcdir="$ac_dots$ac_given_srcdir" ;;
+ esac
+ echo creating "$ac_file"
+ rm -f "$ac_file"
+ configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
+ case "$ac_file" in
+ *Makefile*) ac_comsub="1i\\
+# $configure_input" ;;
+ *) ac_comsub= ;;
+ esac
- if test x"$ac_file" != x-; then
- { echo "$as_me:$LINENO: creating $ac_file" >&5
-echo "$as_me: creating $ac_file" >&6;}
- rm -f "$ac_file"
- fi
- # Let's still pretend it is `configure' which instantiates (i.e., don't
- # use $as_me), people would be surprised to read:
- # /* config.h. Generated by config.status. */
- if test x"$ac_file" = x-; then
- configure_input=
- else
- configure_input="$ac_file. "
- fi
- configure_input=$configure_input"Generated from `echo $ac_file_in |
- sed 's,.*/,,'` by configure."
-
- # First look for the input files in the build tree, otherwise in the
- # src tree.
- ac_file_inputs=`IFS=:
- for f in $ac_file_in; do
- case $f in
- -) echo $tmp/stdin ;;
- [\\/$]*)
- # Absolute (can't be DOS-style, as IFS=:)
- test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
-echo "$as_me: error: cannot find input file: $f" >&2;}
- { (exit 1); exit 1; }; }
- echo "$f";;
- *) # Relative
- if test -f "$f"; then
- # Build tree
- echo "$f"
- elif test -f "$srcdir/$f"; then
- # Source tree
- echo "$srcdir/$f"
- else
- # /dev/null tree
- { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
-echo "$as_me: error: cannot find input file: $f" >&2;}
- { (exit 1); exit 1; }; }
- fi;;
- esac
- done` || { (exit 1); exit 1; }
-_ACEOF
-cat >>$CONFIG_STATUS <<_ACEOF
- sed "$ac_vpsub
-$extrasub
-_ACEOF
-cat >>$CONFIG_STATUS <<\_ACEOF
-:t
-/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
-s,@configure_input@,$configure_input,;t t
-s,@srcdir@,$ac_srcdir,;t t
-s,@abs_srcdir@,$ac_abs_srcdir,;t t
-s,@top_srcdir@,$ac_top_srcdir,;t t
-s,@abs_top_srcdir@,$ac_abs_top_srcdir,;t t
-s,@builddir@,$ac_builddir,;t t
-s,@abs_builddir@,$ac_abs_builddir,;t t
-s,@top_builddir@,$ac_top_builddir,;t t
-s,@abs_top_builddir@,$ac_abs_top_builddir,;t t
-" $ac_file_inputs | (eval "$ac_sed_cmds") >$tmp/out
- rm -f $tmp/stdin
- if test x"$ac_file" != x-; then
- mv $tmp/out $ac_file
- else
- cat $tmp/out
- rm -f $tmp/out
- fi
+ ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
+ sed -e "$ac_comsub
+s%@configure_input@%$configure_input%g
+s%@srcdir@%$srcdir%g
+s%@top_srcdir@%$top_srcdir%g
+" $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file
+fi; done
+rm -f conftest.s*
-done
-_ACEOF
+EOF
+cat >> $CONFIG_STATUS <<EOF
-cat >>$CONFIG_STATUS <<\_ACEOF
+EOF
+cat >> $CONFIG_STATUS <<\EOF
-{ (exit 0); exit 0; }
-_ACEOF
+exit 0
+EOF
chmod +x $CONFIG_STATUS
-ac_clean_files=$ac_clean_files_save
-
-
-# configure is writing to config.log, and then calls config.status.
-# config.status does its own redirection, appending to config.log.
-# Unfortunately, on DOS this fails, as config.log is still kept open
-# by configure, so config.status won't be able to write to it; its
-# output is simply discarded. So we exec the FD to /dev/null,
-# effectively closing config.log, so it can be properly (re)opened and
-# appended to by config.status. When coming back to configure, we
-# need to make the FD available again.
-if test "$no_create" != yes; then
- ac_cs_success=:
- ac_config_status_args=
- test "$silent" = yes &&
- ac_config_status_args="$ac_config_status_args --quiet"
- exec 5>/dev/null
- $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
- exec 5>>config.log
- # Use ||, not &&, to avoid exiting from the if with $? = 1, which
- # would make configure fail if this is the last instruction.
- $ac_cs_success || { (exit 1); exit 1; }
-fi
+rm -fr confdefs* $ac_clean_files
+test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1
diff --git a/gdb/testsuite/gdb.gdbtk/configure.in b/gdb/testsuite/gdb.gdbtk/configure.in
new file mode 100644
index 00000000000..4c408e8c828
--- /dev/null
+++ b/gdb/testsuite/gdb.gdbtk/configure.in
@@ -0,0 +1,14 @@
+dnl Process this file file with autoconf to produce a configure script.
+dnl This file is a shell script fragment that supplies the information
+dnl necessary to tailor a template configure script into the configure
+dnl script appropriate for this directory. For more information, check
+dnl any existing configure script.
+
+AC_PREREQ(2.5)
+AC_INIT(defs)
+
+CC=${CC-cc}
+AC_SUBST(CC)
+AC_CONFIG_AUX_DIR(`cd $srcdir;pwd`/../../..)
+AC_CANONICAL_SYSTEM
+AC_OUTPUT(Makefile)
diff --git a/gdb/testsuite/gdb.gdbtk/console.exp b/gdb/testsuite/gdb.gdbtk/console.exp
index b17eaa11ee7..1d50c661ab6 100644
--- a/gdb/testsuite/gdb.gdbtk/console.exp
+++ b/gdb/testsuite/gdb.gdbtk/console.exp
@@ -1,18 +1,10 @@
-# Copyright 1998, 1999, 2001, 2004 Red Hat, Inc.
#
-# This program is free software; you can redistribute it and/or modify it
-# under the terms of the GNU General Public License (GPL) as published by
-# the Free Software Foundation; either version 2 of the License, or (at
-# your option) any later version.
+# Check if we have a display
#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
+if {![info exists ::env(DISPLAY)]} {
+ untested "No DISPLAY -- skipping test"
+} else {
-load_lib ../gdb.gdbtk/insight-support.exp
-
-if {[gdbtk_initialize_display]} {
if {$tracelevel} {
strace $tracelevel
}
@@ -38,5 +30,5 @@ if {[gdbtk_initialize_display]} {
set results [split $results \n]
# Analyze results
- gdbtk_done $results
+ gdbtk_analyze_results $results
}
diff --git a/gdb/testsuite/gdb.gdbtk/console.test b/gdb/testsuite/gdb.gdbtk/console.test
index 41e79465cd2..d24dd6b51eb 100644
--- a/gdb/testsuite/gdb.gdbtk/console.test
+++ b/gdb/testsuite/gdb.gdbtk/console.test
@@ -1,4 +1,4 @@
-# Copyright (C) 1998, 1999, 2002 Red Hat, Inc.
+# Copyright (C) 1998, 1999 Cygnus Solutions
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
@@ -28,7 +28,7 @@ if {![gdbtk_read_defs]} {
global objdir test_ran
global console text
set console [ManagedWin::open Console]
-set text [$console test set _twin]
+set text [$console get_text]
##### #####
# #
@@ -108,7 +108,7 @@ gdbtk_test console-paste-1 {paste X text} {
text .test_text
.test_text insert end "this is some pasted text"
.test_text tag add sel 1.0 {1.0 lineend}
- event generate .test_text <<Copy>>
+
event generate $text <<Paste>>
get_cmd_line
} {(gdb) this is some pasted text}
@@ -150,8 +150,7 @@ gdbtk_test console-history-1.1 {up history once} {
console_command {show remotelogbase}
console_command {help quit}
console_command {help si}
- # this doesn't seem to work reliably: event generate $text <Up>
- $console test _previous
+ event generate $text <Up>
get_cmd_line
} {(gdb) help si}
if {$test_ran} {
@@ -176,10 +175,8 @@ gdbtk_test console-history-1.2 {up history twice} {
console_command {show remotelogbase}
console_command {help quit}
console_command {help si}
- # this doesn't seem to work reliably: event generate $text <Up>
- # this doesn't seem to work reliably: event generate $text <Up>
- $console test _previous
- $console test _previous
+ event generate $text <Up>
+ event generate $text <Up>
get_cmd_line
} {(gdb) help quit}
if {$test_ran} {
@@ -206,8 +203,7 @@ gdbtk_test console-history-1.3 {up history four times} {
console_command {help si}
for {set i 0} {$i < 4} {incr i} {
- # this doesn't seem to work reliably: event generate $text <Up>
- $console test _previous
+ event generate $text <Up>
}
get_cmd_line
} {(gdb) show remotedevice}
@@ -234,8 +230,7 @@ gdbtk_test console-history-1.4 {up fourteen times} {
console_command {help quit}
console_command {help si}
for {set i 0} {$i < 14} {incr i} {
- # this doesn't seem to work reliably: event generate $text <Up>
- $console test _previous
+ event generate $text <Up>
}
get_cmd_line
} {(gdb) show annotate}
@@ -256,12 +251,9 @@ gdbtk_test console-history-1.5 {up search} {
console_command {help si}
$text insert end "sh"
- # this doesn't seem to work reliably: event generate $text <Shift-Up>
- # this doesn't seem to work reliably: event generate $text <Shift-Up>
- # this doesn't seem to work reliably: event generate $text <Shift-Up>
- $console test _search_history
- $console test _search_history
- $console test _search_history
+ event generate $text <Shift-Up>
+ event generate $text <Shift-Up>
+ event generate $text <Shift-Up>
get_cmd_line
} {(gdb) show annotate}
@@ -269,10 +261,8 @@ gdbtk_test console-history-1.5 {up search} {
# Test: console-history-1.6
# Desc: Exercise the down-history search functionality
gdbtk_test console-history-1.6 {down search} {
- # this doesn't seem to work reliably: event generate $text <Shift-Down>
- # this doesn't seem to work reliably: event generate $text <Shift-Down>
- $console test _rsearch_history
- $console test _rsearch_history
+ event generate $text <Shift-Down>
+ event generate $text <Shift-Down>
get_cmd_line
} {(gdb) show remotelogbase}
@@ -280,10 +270,8 @@ gdbtk_test console-history-1.6 {down search} {
# Desc: Down-history search to bottom
# We go back down until the original partialcommand is displayed
gdbtk_test console-history-1.7 {down search to bottom} {
- # this doesn't seem to work reliably: event generate $text <Shift-Down>
- # this doesn't seem to work reliably: event generate $text <Shift-Down>
- $console test _rsearch_history
- $console test _rsearch_history
+ event generate $text <Shift-Down>
+ event generate $text <Shift-Down>
get_cmd_line
} {(gdb) sh}
@@ -292,8 +280,7 @@ gdbtk_test console-history-1.7 {down search to bottom} {
# We go up until there are no matches
gdbtk_test console-history-1.8 {up search to top} {
for {set i 0} {$i < 100} {incr i} {
- # this doesn't seem to work reliably: event generate $text <Shift-Up>
- $console test _search_history
+ event generate $text <Shift-Up>
}
get_cmd_line
} {(gdb) show annotate}
@@ -322,11 +309,9 @@ gdbtk_test console-history-2.1 {down once} {
console_command {help si}
for {set i 0} {$i < 14} {incr i} {
- # this doesn't seem to work reliably: event generate $text <Up>
- $console test _previous
+ event generate $text <Up>
}
- # this doesn't seem to work reliably: event generate $text <Down>
- $console test _next
+ event generate $text <Down>
get_cmd_line
} {(gdb) show complaints}
if {$test_ran} {
@@ -353,14 +338,11 @@ gdbtk_test console-history-2.2 {down twice} {
console_command {help si}
for {set i 0} {$i < 14} {incr i} {
- # this doesn't seem to work reliably: event generate $text <Up>
- $console test _previous
+ event generate $text <Up>
}
- # this doesn't seem to work reliably: event generate $text <Down>
- # this doesn't seem to work reliably: event generate $text <Down>
- $console test _next
- $console test _next
+ event generate $text <Down>
+ event generate $text <Down>
get_cmd_line
} {(gdb) show confirm}
if {$test_ran} {
@@ -387,13 +369,11 @@ gdbtk_test console-history-2.3 {down four times} {
console_command {help si}
for {set i 0} {$i < 14} {incr i} {
- # this doesn't seem to work reliably: event generate $text <Up>
- $console test _previous
+ event generate $text <Up>
}
for {set i 0} {$i < 4} {incr i} {
- # this doesn't seem to work reliably: event generate $text <Down>
- $console test _next
+ event generate $text <Down>
}
get_cmd_line
} {(gdb) show language}
@@ -420,13 +400,11 @@ gdbtk_test console-history-2.4 {down infinitely} {
console_command {help quit}
console_command {help si}
for {set i 0} {$i < 14} {incr i} {
- # this doesn't seem to work reliably: event generate $text <Up>
- $console test _previous
+ event generate $text <Up>
}
for {set i 0} {$i < 20} {incr i} {
- # this doesn't seem to work reliably: event generate $text <Down>
- $console test _next
+ event generate $text <Down>
}
get_cmd_line
} {(gdb) }
@@ -489,3 +467,8 @@ if {$test_ran} {
# Exit
#
gdbtk_test_done
+
+# Local variables:
+# mode: tcl
+# change-log-default-name: "ChangeLog-gdbtk"
+# End:
diff --git a/gdb/testsuite/gdb.gdbtk/cpp_variable.exp b/gdb/testsuite/gdb.gdbtk/cpp_variable.exp
index a7764f67199..ed5ca35dc67 100644
--- a/gdb/testsuite/gdb.gdbtk/cpp_variable.exp
+++ b/gdb/testsuite/gdb.gdbtk/cpp_variable.exp
@@ -1,48 +1,34 @@
-# Copyright 1999, 2001, 2004 Red Hat, Inc.
#
-# This program is free software; you can redistribute it and/or modify it
-# under the terms of the GNU General Public License (GPL) as published by
-# the Free Software Foundation; either version 2 of the License, or (at
-# your option) any later version.
+# Check if we have a display
#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
+if {![info exists ::env(DISPLAY)]} {
+ untested "No DISPLAY -- skipping test"
+} else {
-load_lib ../gdb.gdbtk/insight-support.exp
-
-if {[gdbtk_initialize_display]} {
if {$tracelevel} {
strace $tracelevel
}
- set results {}
- if {[skip_cplus_tests]} {
- # Target doesn't have c++ support
- verbose "No C++ support -- skipping test"
- } else {
- #
- # test variable API
- #
- set prms_id 0
- set bug_id 0
-
- set testfile "cpp_variable"
- set srcfile ${testfile}.cc
- set binfile ${objdir}/${subdir}/${testfile}
- set r [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug c++}]
- if { $r != "" } {
- gdb_suppress_entire_file \
- "Testcase compile failed, so some tests in this file will automatically fail."
- }
+ #
+ # test variable API
+ #
+ set prms_id 0
+ set bug_id 0
- # Start with a fresh gdbtk
- gdb_exit
- set results [gdbtk_start [file join $srcdir $subdir ${testfile}.test]]
- set results [split $results \n]
+ set testfile "cpp_variable"
+ set srcfile ${testfile}.cc
+ set binfile ${objdir}/${subdir}/${testfile}
+ set r [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug c++}]
+ if { $r != "" } {
+ gdb_suppress_entire_file \
+ "Testcase compile failed, so some tests in this file will automatically fail."
}
+ # Start with a fresh gdbtk
+ gdb_exit
+ set results [gdbtk_start [file join $srcdir $subdir ${testfile}.test]]
+ set results [split $results \n]
+
# Analyze results
- gdbtk_done $results
+ gdbtk_analyze_results $results
}
diff --git a/gdb/testsuite/gdb.gdbtk/cpp_variable.test b/gdb/testsuite/gdb.gdbtk/cpp_variable.test
index d2de6f3deea..5f9c2732fd2 100644
--- a/gdb/testsuite/gdb.gdbtk/cpp_variable.test
+++ b/gdb/testsuite/gdb.gdbtk/cpp_variable.test
@@ -1,5 +1,4 @@
-# Varobj Tests (C++ language)
-# Copyright (C) 1998, 2003 Red Hat, Inc.
+# Copyright (C) 1998 Cygnus Solutions
#
# This Program Is Free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
@@ -16,7 +15,7 @@
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
# Please email any bugs, comments, and/or additions to this file to:
-# insight@sources.redhat.com
+# bug-gdb@prep.ai.mit.edu
# This file was written by Keith Seitz (keiths@cygnus.com)
@@ -26,11 +25,18 @@ if {![gdbtk_read_defs]} {
}
global objdir test_ran
+global tcl_platform
# Load in a file
-set program [file join $objdir cpp_variable]
-if {[catch {gdbtk_test_file $program} t]} {
- # This isn't a test case, since if this fails, we're hosed.
+if {$tcl_platform(platform) == "windows"} {
+ set program [file join $objdir cpp_variable.exe]
+} else {
+ set program [file join $objdir cpp_variable]
+}
+
+# This isn't a test case, since if this fails, we're hosed.
+if {[catch {gdb_cmd "file $program"} t]} {
+ # an error occured loading the file
gdbtk_test_error "loading \"$program\": $t"
}
@@ -40,19 +46,23 @@ if {[catch {gdbtk_test_file $program} t]} {
proc check_update {} {
global var
- set out {}
set changed {}
+ set unchanged {}
+ set out {}
+ #FIXME: Should get a list of root variables instead of using the array
+ foreach ind [array names var] {
+ set changed [concat $changed [$var($ind) update]]
+ }
+
foreach ind [array names var] {
- set ret [$var($ind) update]
- if {$ret == -1} {
- lappend out $ind
- } elseif {$ret != ""} {
- lappend changed $ret
+ set ix [lsearch -exact $changed $var($ind)]
+ if {$ix < 0} {
+ lappend unchanged $var($ind)
}
}
- return [list $changed $out]
-}
+ return [list $changed $unchanged $out]
+}
# proc to create a variable
proc create_variable {expr} {
@@ -140,19 +150,13 @@ proc delete_all_variables {} {
# run to "do_simple_class_tests"
gdb_cmd "break do_simple_class_tests"
-gdbtk_test_run
+gdb_cmd "run"
# Test: cpp_variable-1.1
# Desc: stopped in do_simple_class_tests
gdbtk_test cpp_variable-1.1 {stopped in do_simple_class_tests} {
- # G++ can output "do_simple_class_tests(void)". Strip the "(void)" part.
- set loc [lindex [gdb_loc] 1]
- set index [string first \( $loc]
- if {$index > 0} {
- set loc [string range $loc 0 [expr {$index-1}]]
- }
- set loc
-} {do_simple_class_tests}
+ lindex [gdb_loc] 1
+} {do_simple_class_tests(void)}
# Test: cpp_variable-1.2
# Desc: create variable v
@@ -196,23 +200,16 @@ gdbtk_test cpp_variable-1.6 {format of v} {
$var(v) format
} {natural}
-set value {}
-catch {$var(v) value} value
+set value [$var(v) value]
-# Test: cpp_variable-1.6a
-# Desc: Step over "V *v = new V;"
-gdbtk_test cpp_variable-1.6a {step over "V *v = new V;"} {
- catch {gdb_cmd "next"}
-} {0}
+# Step over "V *v = new V;"
+gdb_cmd "next"
# Test: cpp_variable-1.7
# Desc: check value of v changed
gdbtk_test cpp_variable-1.7 {check value of v changed} {
- set changes [check_update]
- # It is undefined whether the children will change values
- # or not, so ignore them.
- expr {[lsearch [lindex [lindex $changes 0] 0] v] != -1}
-} {1}
+ check_update
+} {{v v.public.v_pub_int v.public.v_pub_charp v.private.v_priv_int v.private.v_priv_charp} {v.VB v.VC v.private v.public v.VA} {}}
# Test: cpp_variable-1.8
# Desc: check values of v
@@ -245,22 +242,13 @@ gdbtk_test cpp_variable-2.2 {format of v.v_pub_int} {
$var(v.public.v_pub_int) format
} {natural}
-# Test: cpp_variable-2.2a
-# Desc: set variable v->v_pub_int=2112
-gdbtk_test cpp_variable-2.2a {set variable v.v_pub_int=2112} {
- set err [catch {gdb_cmd "set variable v.v_pub_int=2112"} txt]
- if {$err} {
- set txt
- } else {
- set err
- }
-} {0}
+gdb_cmd "set variable v.v_pub_int=2112"
# Test: cpp_variable-2.3
# Desc: value of v.v_pub_int changed
gdbtk_test cpp_variable-2.3 {value of v.v_pub_int changed} {
check_update
-} {v.public.v_pub_int {v.private.v_priv_charp v.VB v.private.v_priv_int v.VC v.public.v_pub_charp v.public.v_pub_int v.private v.public v.VA}}
+} {v.public.v_pub_int {v.private.v_priv_charp v.VB v.private.v_priv_int v.VC v.public.v_pub_charp v v.private v.public v.VA} {}}
# Test: cpp_variable-2.4
# Desc: value of v.v_pub_int
@@ -325,22 +313,13 @@ gdbtk_test cpp_variable-2.22 {format of v.v_priv_charp} {
$var(v.private.v_priv_charp) format
} {natural}
-# Test: cpp_variable-2.22a
-# Desc: set variable v->v_priv_charp=2112
-gdbtk_test cpp_variable-2.22a {set variable v->v_priv_charp=2112} {
- set err [catch {gdb_cmd "set variable v->v_priv_charp=2112"} txt]
- if {$err} {
- set txt
- } else {
- set err
- }
-} {0}
+gdb_cmd "set variable v.v_priv_charp=2112"
# Test: cpp_variable-2.23
# Desc: value of v.v_priv_charp changed
gdbtk_test cpp_variable-2.23 {value of v.v_priv_charp changed} {
check_update
-} {{{v.public.v_pub_int v.private.v_priv_charp}} {v.private.v_priv_charp v.VB v.private.v_priv_int v.VC v.public.v_pub_charp v.public.v_pub_int v.private v.public v.VA}}
+} {v.private.v_priv_charp {v.VB v.private.v_priv_int v.VC v.public.v_pub_charp v v.public.v_pub_int v.private v.public v.VA} {}}
# Test: cpp_variable-2.24
# Desc: value of v.v_priv_charp
@@ -380,13 +359,13 @@ gdbtk_test cpp_variable-2.28 {change value of v.v_priv_charp (hexadecimal)} {
# Desc: number of children of v_priv_charp
gdbtk_test cpp_variable-2.29 {number of children of v_priv_charp} {
$var(v.private.v_priv_charp) numChildren
-} {1}
+} {0}
# Test: cpp_variable-2.30
# Desc: children of v.v_priv_charp
gdbtk_test cpp_variable-2.30 {children of v.v_priv_charp} {
get_children v.private.v_priv_charp
-} {*v_priv_charp}
+} {}
# Test: cpp_variable-2.31
# Desc: v.v_priv_int editable
@@ -410,7 +389,7 @@ gdbtk_test cpp_variable-2.42 {format of v.VA} {
# Desc: value of v.VA changed
gdbtk_test cpp_variable-2.43 {value of v.VA changed} {
check_update
-} {v.private.v_priv_charp {v.private.v_priv_charp v.VB v.private.v_priv_int v.VC v.public.v_pub_charp v.private.v_priv_charp.*v_priv_charp v.public.v_pub_int v.private v.public v.VA}}
+} {{} {v.private.v_priv_charp v.VB v.private.v_priv_int v.VC v.public.v_pub_charp v v.public.v_pub_int v.private v.public v.VA} {}}
# Test: cpp_variable-2.44
# Desc: value of v.VA
@@ -483,7 +462,7 @@ gdbtk_test cpp_variable-2.62 {format of v.VB} {
# Desc: value of v.VB changed
gdbtk_test cpp_variable-2.63 {value of v.VB changed} {
check_update
-} {{} {v.VA.protected v.private.v_priv_charp.*v_priv_charp v.VA.private v.VA.public.va_pub_int v.private.v_priv_int v.public.v_pub_int v.VA.public.va_pub_charp v.private.v_priv_charp v.VA.public v.public.v_pub_charp v.VA.private.va_priv_int v.VA v.public v.VB v.VC v.VA.protected.bar v.VA.private.va_priv_charp v.private}}
+} {{} {v.VA.protected v.VA.private v.VA.public.va_pub_int v.private.v_priv_int v v.public.v_pub_int v.VA.public.va_pub_charp v.private.v_priv_charp v.VA.public v.public.v_pub_charp v.VA.private.va_priv_int v.VA v.public v.VB v.VC v.VA.protected.bar v.VA.private.va_priv_charp v.private} {}}
# Test: cpp_variable-2.64
# Desc: value of v.VB
@@ -548,22 +527,13 @@ gdbtk_test cpp_variable-2.71 {v.VB.vb_pub_int editable} {
$var(v.VB.public.vb_pub_int) editable
} {1}
-# Test: cpp_variable-2.71a
-# Desc: set variable v->vb_pub_int=2112
-gdbtk_test cpp_variable-2.71a {set variable v->v_pub_int=2112} {
- set err [catch {gdb_cmd "set variable v->vb_pub_int=2112"} txt]
- if {$err} {
- set txt
- } else {
- set err
- }
-} {0}
+gdb_cmd "set variable v.vb_pub_int=2112"
# Test: cpp_variable-2.72
# Desc: value of v.vb_pub_int changed
gdbtk_test cpp_variable-2.72 {value of v.vb_pub_int changed} {
check_update
-} {v.VB.public.vb_pub_int {v.VB.public v.VA.protected v.private.v_priv_charp.*v_priv_charp v.VA.private v.VB.private.vb_priv_int v.VB.private v.VA.public.va_pub_int v.private.v_priv_int v.VB.public.vb_pub_int v.public.v_pub_int v.VB.private.vb_priv_charp v.VA.public.va_pub_charp v.private.v_priv_charp v.VA.public v.public.v_pub_charp v.VA.private.va_priv_int v.VA v.public v.VB v.VC v.VA.protected.bar v.VA.private.va_priv_charp v.private}}
+} {v.VB.public.vb_pub_int {v.VB.public v.VA.protected v.VA.private v.VB.private.vb_priv_int v.VB.private v.VA.public.va_pub_int v.private.v_priv_int v v.public.v_pub_int v.VB.private.vb_priv_charp v.VA.public.va_pub_charp v.private.v_priv_charp v.VA.public v.public.v_pub_charp v.VA.private.va_priv_int v.VA v.public v.VB v.VC v.VA.protected.bar v.VA.private.va_priv_charp v.private} {}}
# Test: cpp_variable-2.73
# Desc: value of v.VB.vb_pub_int
@@ -589,6 +559,4 @@ gdbtk_test cpp_variable-2.75 {changed value of v.VB.public.vb_pub_int} {
#
gdbtk_test_done
-#Local Variables:
-#mode: tcl
diff --git a/gdb/testsuite/gdb.gdbtk/defs b/gdb/testsuite/gdb.gdbtk/defs
index 8e3fe5b4531..a4f20c60f81 100644
--- a/gdb/testsuite/gdb.gdbtk/defs
+++ b/gdb/testsuite/gdb.gdbtk/defs
@@ -1,11 +1,10 @@
# This file contains support code for the gdbtk test suite.
-# Copyright 2001 Red Hat, Inc.
#
# Based on the Tcl testsuite support code, portions of this file
# are Copyright (c) 1990-1994 The Regents of the University of California and
# Copyright (c) 1994-1996 Sun Microsystems, Inc.
#
-global _test env srcdir objdir
+global srcdir _test env srcdir objdir
if {![info exists srcdir]} {
if {[info exists env(SRCDIR)]} {
@@ -31,7 +30,7 @@ if {![info exists _test(verbose)]} {
if {[info exists env(GDBTK_VERBOSE)]} {
set _test(verbose) $env(GDBTK_VERBOSE)
} else {
- set _test(verbose) 0
+ set _test(verbose)
}
}
if {![info exists _test(tests)]} {
@@ -56,81 +55,6 @@ if {[info exists env(GDBTK_LOGFILE)]} {
# window manager does not interfere. This is reset in gdbtk_test_done.
set env(GDBTK_TEST_RUNNING) 1
-# The gdb "file" command to use for gdbtk testing
-# NOTE: This proc appends ".exe" to all windows' programs
-proc gdbtk_test_file {filename} {
- global tcl_platform
-
- if {$tcl_platform(platform) == "windows"} {
- append filename ".exe"
- }
-
- set err [catch {gdb_cmd "file $filename" 1} text]
- if {$err} {
- error $text
- }
-
- return $text
-}
-
-proc gdbtk_test_run {{prog_args {}}} {
- global env
-
- # Get the target_info array from the testsuite
- array set target_info $env(TARGET_INFO)
-
- # We get the target ready by:
- # 1. Run all init commands
- # 2. Issue target command
- # 3. Issue load command
- # 4. Issue run command
- foreach cmd $target_info(init) {
- set err [catch {gdb_cmd $cmd 0} txt]
- if {$err} {
- _report_error "Target initialization command \"$cmd\" failed: $txt"
- return 0
- }
- }
-
- if {$target_info(target) != ""} {
- set err [catch {gdb_cmd $target_info(target) 0} txt]
- if {$err} {
- _report_error "Failed to connect to target: $txt"
- return 0
- }
- }
-
- if {$target_info(load) != ""} {
- set err [catch {gdb_cmd $target_info(load) 0} txt]
- if {$err} {
- _report_error "Failed to load: $txt"
- return 0
- }
- }
-
- if {$target_info(run) != ""} {
- set err [catch {gdb_cmd $target_info(run) 0} txt]
- if {$err} {
- _report_error "Could not run target with \"$target_info(run)\": $txt"
- return 0
- }
- }
-
- return 1
-}
-
-proc _report_error {msg} {
- global _test
-
- if {[info exists _test(interactive)] && $_test(interactive)} {
- # Dialog
- tk_messageBox -message $msg -icon error -type ok
- } else {
- # to stderr
- puts stderr $msg
- }
-}
-
proc gdbtk_print_verbose {status name description script code answer} {
global _test
@@ -276,14 +200,14 @@ proc gdbtk_dotests {file args} {
proc gdbtk_test_done {} {
global _test env
-
+
if {$_test(logfile) != ""} {
close $_test(logfile)
}
set env(GDBTK_TEST_RUNNING) 0
if {![info exists _test(interactive)] || !$_test(interactive)} {
- gdbtk_force_quit
+ gdb_force_quit
}
}
@@ -292,15 +216,3 @@ proc gdbtk_test_error {desc} {
puts "ERROR \{$desc\} \{\} \{\}"
gdbtk_test_done
}
-
-# Override the warning dialog. We don't want to see them.
-rename show_warning real_show_warning
-proc show_warning {msg} {
- global _test
-
- set str "INSIGHT TESTSUITE WARNING: $msg"
- puts stdout $str
- if {$_test(logfile) != ""} {
- puts $_test(logfile) $str
- }
-}
diff --git a/gdb/testsuite/gdb.gdbtk/simple.c b/gdb/testsuite/gdb.gdbtk/simple.c
index c4d4ef5a0a0..b35cd58851b 100644
--- a/gdb/testsuite/gdb.gdbtk/simple.c
+++ b/gdb/testsuite/gdb.gdbtk/simple.c
@@ -1,6 +1,3 @@
-#include <string.h>
-#include <stdlib.h>
-
int
main(int argc, char * argv[])
{
@@ -15,7 +12,7 @@ main(int argc, char * argv[])
{
int j = i % 3;
int k = 3 - j;
- strncpy (&a[i], &b[k], j);
+ strncpy (a[i], b[k], j);
foo = (long) j * k / i + 2 * k * k * k;
}
return 0;
diff --git a/gdb/testsuite/gdb.gdbtk/srcwin.exp b/gdb/testsuite/gdb.gdbtk/srcwin.exp
index c9267d805e3..e3dc07dff87 100644
--- a/gdb/testsuite/gdb.gdbtk/srcwin.exp
+++ b/gdb/testsuite/gdb.gdbtk/srcwin.exp
@@ -1,18 +1,9 @@
-# Copyright 1999, 2001 Red Hat, Inc.
#
-# This program is free software; you can redistribute it and/or modify it
-# under the terms of the GNU General Public License (GPL) as published by
-# the Free Software Foundation; either version 2 of the License, or (at
-# your option) any later version.
+# Check if we have a display
#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-
-load_lib ../gdb.gdbtk/insight-support.exp
-
-if {[gdbtk_initialize_display]} {
+if {![info exists ::env(DISPLAY)]} {
+ untested "No DISPLAY -- skipping test"
+} else {
if {$tracelevel} {
strace $tracelevel
}
@@ -24,38 +15,32 @@ if {[gdbtk_initialize_display]} {
set bug_id 0
set testfile "list"
- set s1 "$srcdir/$subdir/list0.c"
- set sources "$s1 $srcdir/$subdir/list1.c"
set binfile $objdir/$subdir/$testfile
- if {[file exists $s1.save]} {
- catch {file delete $s1}
- file rename $s1.save $s1
- }
- set r [gdb_compile $sources "$binfile" executable debug]
+ set r [gdb_compile "$srcdir/gdb.base/list0.c $srcdir/gdb.base/list1.c" "$binfile" executable debug]
if { $r != "" } {
gdb_suppress_entire_file \
"Testcase compile failed, so some tests in this file will automatically fail."
}
-
+
# Start with a fresh gdbtk
gdb_exit
set results [gdbtk_start [file join $srcdir $subdir srcwin.test]]
set results [split $results \n]
- set all_results $results
+ # Analyze results
+ gdbtk_analyze_results $results
# move file with "main" out of the way
- file rename $s1 $s1.save
-
+ file rename $srcdir/gdb.base/list0.c $srcdir/gdb.base/list0.c.save
# run slightly different set of tests
gdb_exit
set results [gdbtk_start [file join $srcdir $subdir srcwin2.test]]
set results [split $results \n]
- set all_results [concat $all_results $results]
-
- # restore file
- file rename $s1.save $s1
+ #restore file
+ file rename $srcdir/gdb.base/list0.c.save $srcdir/gdb.base/list0.c
+ # Analyze results
+ gdbtk_analyze_results $results
- set r [gdb_compile $sources "$binfile" executable ""]
+ set r [gdb_compile "$srcdir/gdb.base/list0.c $srcdir/gdb.base/list1.c" "$binfile" executable ""]
if { $r != "" } {
gdb_suppress_entire_file \
"Testcase compile failed, so some tests in this file will automatically fail."
@@ -64,8 +49,11 @@ if {[gdbtk_initialize_display]} {
gdb_exit
set results [gdbtk_start [file join $srcdir $subdir srcwin3.test]]
set results [split $results \n]
- set all_results [concat $all_results $results]
-
# Analyze results
- gdbtk_done $all_results
+ gdbtk_analyze_results $results
}
+
+# Local variables:
+# mode: tcl
+# change-log-default-name: "ChangeLog-gdbtk"
+# End:
diff --git a/gdb/testsuite/gdb.gdbtk/srcwin.test b/gdb/testsuite/gdb.gdbtk/srcwin.test
index eaa9ba8530e..bc1ec9d78a2 100644
--- a/gdb/testsuite/gdb.gdbtk/srcwin.test
+++ b/gdb/testsuite/gdb.gdbtk/srcwin.test
@@ -1,4 +1,4 @@
-# Copyright (C) 1999, 2001 Red Hat, Inc.
+# Copyright (C) 1999 Cygnus Solutions
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
@@ -48,7 +48,7 @@ proc move_mouse_to {win bbox} {
return 1
}
-proc click {win bbox bnum} {
+proc click {win bbox event} {
if {![move_mouse_to $win $bbox]} {
return 0
}
@@ -57,10 +57,7 @@ proc click {win bbox bnum} {
set x [expr [lindex $bbox 0] + [lindex $bbox 2] / 2]
set y [expr [lindex $bbox 1] + [lindex $bbox 3] / 2]
- if {[catch {event generate $win <Button-$bnum> -x $x -y $y} result]} {
- return 0
- }
- if {[catch {event generate $win <ButtonRelease-$bnum> -x $x -y $y} result]} {
+ if {[catch {event generate $win $event -x $x -y $y} result]} {
return 0
}
return 1
@@ -74,10 +71,16 @@ proc click {win bbox bnum} {
##### #####
# Load the test executable
-set program [file join $objdir list]
-if {[catch {gdbtk_test_file $program} t]} {
- # This isn't a test case, since if this fails, we're hosed.
- gdbtk_test_error "loading \"$program\": $t"
+if {$tcl_platform(platform) == "windows"} {
+ set file [file join $objdir list.exe]
+} else {
+ set file [file join $objdir list]
+}
+
+# This isn't a test case, since if this fails, we're hosed.
+if {[catch {gdb_cmd "file $file" 1} t]} {
+ # an error occured loading the file
+ gdbtk_test_error "loading \"$file\": $t"
}
set srcwin [ManagedWin::open SrcWin]
@@ -86,7 +89,7 @@ set twin [$stw test_get twin]
# get things started
gdb_cmd "break main"
-gdbtk_test_run
+run_executable
# Test: srcwin-1.1
# Desc: Check for something in source window
@@ -224,20 +227,20 @@ gdbtk_test srcwin-1.13 "assembly->source mode change" {
# Desc: check contents of filename combobox
gdbtk_test srcwin-2.1 "check contents of filename combobox" {
set statbar [$srcwin test_get _statbar]
- set names [$statbar.name list get 0 end]
+ set names [$statbar.name listget 0 end]
set r 0
- foreach f {list0.c list1.c} {
+ foreach f {list0.c list1.c list0.h} {
if {[lsearch $names $f] != -1} {
incr r
}
}
set r
-} {2}
+} {3}
# Test: srcwin-2.2
# Desc: check contents of function combobox
gdbtk_test srcwin-2.2 "check contents of function combobox" {
- set names [$statbar.func list get 0 end]
+ set names [$statbar.func listget 0 end]
set r 0
foreach f {main foo unused} {
if {[lsearch $names $f] != -1} {
@@ -260,7 +263,7 @@ gdbtk_test srcwin-2.3 "goto filename" {
# Test: srcwin-2.4
# Desc: check contents of function combobox
gdbtk_test srcwin-2.4 "check contents of function combobox" {
- set names [$statbar.func list get 0 end]
+ set names [$statbar.func listget 0 end]
set r 0
foreach f {bar long_line oof unused} {
if {[lsearch $names $f] != -1} {
@@ -293,7 +296,7 @@ gdbtk_test srcwin-2.6 "goto function bar" {
foreach {k v i} $z {
if {$k == "tagon"} {
if {$v == "BROWSE_TAG"} {
- if {$i == "10.2"} {
+ if {$i == "5.2"} {
incr r
} else {
incr r 5
@@ -337,9 +340,9 @@ gdbtk_test srcwin-2.7 "goto function oof" {
foreach {k v i} $z {
if {$k == "tagon"} {
if {$v == "BROWSE_TAG"} {
- if {$i == "38.2"} {
+ if {$i == "32.2"} {
set line_number [$twin get "$i wordstart" "$i wordend"]
- if {$line_number == "38"} {
+ if {$line_number == "32"} {
incr r
} else {
incr r -100
@@ -472,7 +475,7 @@ gdbtk_test srcwin-2.10 "step" {
foreach {k v i} $z {
if {$k == "tagon"} {
if {$v == "PC_TAG"} {
- if {$i == "9.2"} {
+ if {$i == "8.2"} {
incr r
} else {
incr r 5
@@ -516,7 +519,7 @@ gdbtk_test srcwin-2.11 "set BP and continue" {
foreach {k v i} $z {
if {$k == "tagon"} {
if {$v == "PC_TAG"} {
- if {$i == "38.2"} {
+ if {$i == "32.2"} {
incr r
} else {
incr r 5
@@ -562,16 +565,14 @@ gdbtk_test srcwin-3.1 "stack up (1)" {
foreach {k v i} $z {
if {$k == "tagon"} {
if {$v == "PC_TAG"} {
- # return n + 1;
- if {$i == "38.2"} {
+ if {$i == "32.2"} {
incr r
} else {
incr r 5
}
}
if {$v == "STACK_TAG"} {
- # oof (67);
- if {$i == "26.2"} {
+ if {$i == "22.2"} {
incr r
} else {
incr r 10
@@ -610,16 +611,14 @@ gdbtk_test srcwin-3.2 "stack up (2)" {
foreach {k v i} $z {
if {$k == "tagon"} {
if {$v == "PC_TAG"} {
- # return n + 1;
- if {$i == "38.2"} {
+ if {$i == "32.2"} {
incr r
} else {
incr r 5
}
}
if {$v == "STACK_TAG"} {
- # long_line ();
- if {$i == "12.2"} {
+ if {$i == "7.2"} {
incr r
} else {
incr r 10
@@ -658,7 +657,7 @@ gdbtk_test srcwin-3.3 "stack up (3)" {
foreach {k v i} $z {
if {$k == "tagon"} {
if {$v == "STACK_TAG"} {
- if {$i == "9.2"} {
+ if {$i == "8.2"} {
incr r
} else {
incr r 5
@@ -715,47 +714,45 @@ gdbtk_test srcwin-3.4 "stack up (4)" {
set r
} {1}
-# Disabled for now because there are different correct results.
-# Test should be rewritten to include those.
# Test: srcwin-3.5
# Desc: "stack up" when we are at the top
-#gdbtk_test srcwin-3.5 "stack up when at the top" {
-# $srcwin stack up
-# set r 0
-# set name [$statbar.name get]
-# set func [$statbar.func get]
-#
+gdbtk_test srcwin-3.5 "stack up when at the top" {
+ $srcwin stack up
+ set r 0
+ set name [$statbar.name get]
+ set func [$statbar.func get]
+
# check contents of name and function comboboxes
-# if {$name != "list0.c"} {set r -1}
-# if {$func != "main"} {set r -2}
+ if {$name != "list0.c"} {set r -1}
+ if {$func != "main"} {set r -2}
# check that the correct file is displayed
-# set twin [$stw test_get twin]
-# set a [$twin get 1.0 end]
-# if {[string compare $file1(source) $a]} {set r -3}
+ set twin [$stw test_get twin]
+ set a [$twin get 1.0 end]
+ if {[string compare $file1(source) $a]} {set r -3}
# check for PC_TAG and STACK_TAG on correct lines
-# if {$r == 0} {
-# if {![catch {set z [$twin dump -tag 1.0 end]}]} {
-# foreach {k v i} $z {
-# if {$k == "tagon"} {
-# if {$v == "STACK_TAG"} {
-# if {$i == "12.2"} {
-# incr r
-# } else {
-# incr r 5
-# }
-# }
-# if {$v == "PC_TAG"} {incr r 10}
-# if {$v == "BROWSE_TAG"} {incr r 100}
-# }
-# }
-# } else {
-# set r -4
-# }
-# }
-# set r
-#} {1}
+ if {$r == 0} {
+ if {![catch {set z [$twin dump -tag 1.0 end]}]} {
+ foreach {k v i} $z {
+ if {$k == "tagon"} {
+ if {$v == "STACK_TAG"} {
+ if {$i == "12.2"} {
+ incr r
+ } else {
+ incr r 5
+ }
+ }
+ if {$v == "PC_TAG"} {incr r 10}
+ if {$v == "BROWSE_TAG"} {incr r 100}
+ }
+ }
+ } else {
+ set r -4
+ }
+ }
+ set r
+} {1}
# Test: srcwin-3.6
# Desc: "stack down" test
@@ -780,7 +777,7 @@ gdbtk_test srcwin-3.6 "stack down" {
foreach {k v i} $z {
if {$k == "tagon"} {
if {$v == "STACK_TAG"} {
- if {$i == "9.2"} {
+ if {$i == "8.2"} {
incr r
} else {
incr r 5
@@ -820,7 +817,7 @@ gdbtk_test srcwin-3.7 "stack bottom" {
foreach {k v i} $z {
if {$k == "tagon"} {
if {$v == "PC_TAG"} {
- if {$i == "38.2"} {
+ if {$i == "32.2"} {
incr r
} else {
incr r 5
@@ -860,7 +857,7 @@ gdbtk_test srcwin-3.8 "stack down when at bottom" {
foreach {k v i} $z {
if {$k == "tagon"} {
if {$v == "PC_TAG"} {
- if {$i == "38.2"} {
+ if {$i == "32.2"} {
incr r
} else {
incr r 5
@@ -900,7 +897,7 @@ gdbtk_test srcwin-4.1 "set BP in another file" {
foreach {k v i} $z {
if {$k == "tagon"} {
if {$v == "BROWSE_TAG"} {
- if {$i == "9.2"} {
+ if {$i == "8.2"} {
incr r
} else {
incr r 5
@@ -909,7 +906,7 @@ gdbtk_test srcwin-4.1 "set BP in another file" {
if {$v == "STACK_TAG"} {incr r 10}
if {$v == "PC_TAG"} {incr r 100}
} elseif {$k == "image"} {
- if {$i == "9.0"} {
+ if {$i == "8.0"} {
incr r
} else {
set r -200
@@ -953,7 +950,7 @@ gdbtk_test srcwin-4.2 "temporary BP" {
foreach {k v i} $z {
if {$k == "tagon"} {
if {$v == "BROWSE_TAG"} {
- if {$i == "9.2"} {
+ if {$i == "8.2"} {
incr r
} else {
incr r 5
@@ -962,7 +959,7 @@ gdbtk_test srcwin-4.2 "temporary BP" {
if {$v == "STACK_TAG"} {incr r 10}
if {$v == "PC_TAG"} {incr r 100}
} elseif {$k == "image"} {
- if {$i == "9.0"} {
+ if {$i == "8.0"} {
incr r
} else {
set r -200
@@ -982,7 +979,7 @@ gdbtk_test srcwin-4.2 "temporary BP" {
foreach {k v i} $z {
if {$k == "tagon"} {
if {$v == "PC_TAG"} {
- if {$i == "9.2"} {
+ if {$i == "8.2"} {
incr r
} else {
incr r 5
@@ -1019,7 +1016,7 @@ gdbtk_test srcwin-4.3 "BP Balloons" {
foreach {k v i} $z {
if {$k == "tagon"} {
if {$v == "PC_TAG"} {
- if {$i == "9.2"} {
+ if {$i == "8.2"} {
incr r
} else {
incr r 5
@@ -1081,19 +1078,19 @@ gdbtk_test srcwin-4.3 "BP Balloons" {
gdbtk_test srcwin-4.4 "Click on line to set BP" {
set r 0
- # click mouse button 1 at index 20.1
- if {![click $twin [$twin bbox 20.1] 1]} {
- set r "Click failed on line 20.1"
+ # click mouse button 1 at index 14.1
+ if {![click $twin [$twin bbox 14.1] <Button-1>]} {
+ set r "Click failed on line 14.1"
} else {
- # now look for BP at line 20
+ # now look for BP at line 14
foreach bpnum [gdb_get_breakpoint_list] {
set bpinfo [gdb_get_breakpoint_info $bpnum]
lassign $bpinfo file func line pc type enabled disposition \
ignore_count commands cond thread hit_count
set file [lindex [file split $file] end]
if {$file == "list0.h"} {
- if {$line == "20"} {
+ if {$line == "14"} {
if {$enabled == "1"} {incr r}
if {$func == "foo"} {incr r}
if {$type == "breakpoint"} {incr r}
@@ -1109,36 +1106,65 @@ gdbtk_test srcwin-4.4 "Click on line to set BP" {
# Test: srcwin-4.5
# Desc: Continue till here popup
gdbtk_test srcwin-4.5 "Continue till here popup" {
+ set r
set twin [$stw test_get twin]
- # Get coordinates of line 16
- set b [$twin bbox 16.1]
- set y [expr {[lindex $b 1] + ([lindex $b 3] / 2)}]
-
- # Continue to here
- $stw continue_to_here $twin $y
-
- # Where is the PC_TAG?
- set pcs {}
- set tags [$twin tag ranges PC_TAG]
- foreach {start end} $tags {
- lappend pcs [expr {int($start)}]
- }
-
- # Where are breakpoints?
- set bps {}
- set imgs [$twin dump -image 1.0 end]
- foreach {foo bar line} $imgs {
- lappend bps $line
+ # click mouse button 1 at index 12.1
+ set b [$twin bbox 12.1]
+ if {![click $twin $b <ButtonPress-3>]} {
+ set r "Click failed on $b"
+ } else {
+
+ # Hack. Just release the botton 10 pixels to the right and below
+ # where the press was. This should select the first entry in the
+ # popup menu, "Continue to Here". This should be made more robust.
+ if {[llength $b] == 4} {
+ set x [expr [lindex $b 0] + [lindex $b 2] / 2 + 10]
+ set y [expr [lindex $b 1] + [lindex $b 3] / 2 + 10]
+ if {![click $twin [list $x $y 0 0] <ButtonRelease-3>]} {
+ set r "Click failed at $x $y"
+ } else {
+
+ # check for PC_TAG on the correct line
+ if {$r == 0} {
+ if {![catch {set z [$twin dump 1.0 end]}]} {
+ foreach {k v i} $z {
+ if {$k == "tagon"} {
+ if {$v == "PC_TAG"} {
+ if {$i == "12.2"} {
+ incr r
+ } else {
+ incr r 5
+ }
+ }
+ if {$v == "STACK_TAG"} {incr r 10}
+ if {$v == "BROWSE_TAG"} {incr r 100}
+ } elseif {$k == "image"} {
+ switch $i {
+ 10.0 {incr r}
+ 12.0 {incr r}
+ 14.0 {incr r}
+ default {incr r 1000}
+ }
+ }
+ }
+ } else {
+ set r -4
+ }
+ }
+ }
+ } else {
+ set r "Line 12.1 was not visible..."
+ }
+ # should have seen on PC_TAG at line 12, plus BP images at 10.0, 12.0 and 14.0
}
-
- list $pcs $bps
-} {16 {10.0 20.0}}
+ set r
+} {4}
# 5.1 balloon variables
# Test: srcwin-5.1
# Desc: variable balloon test
-# continues to BP at line 20 and checks to see that value was updated
+# continues to BP at line 14 and checks to see that value was updated
gdbtk_test srcwin-5.1 "variable balloon test" {
# move pointer out of the way
warp_pointer . 0 0
@@ -1146,14 +1172,13 @@ gdbtk_test srcwin-5.1 "variable balloon test" {
set twin [$stw test_get twin]
# move pointer to variable "x" and check balloon
- set index [string first "x++" [$twin get 20.0 20.end]]
- move_mouse_to $twin [$twin bbox 20.$index]
+ set index [string first "x++" [$twin get 10.0 10.end]]
+ move_mouse_to $twin [$twin bbox 10.$index]
sleep 1
if {[winfo ismapped $balloon]} {
- if {![string compare "x=9" [$balloon.label cget -text]]} {incr r}
+ if {![string compare "x=6" [$balloon.label cget -text]]} {incr r}
gdb_immediate "continue" 1
- sleep 1
- if {![string compare "x=13" [$balloon.label cget -text]]} {incr r}
+ if {![string compare "x=8" [$balloon.label cget -text]]} {incr r}
} else {
set r -1
}
@@ -1164,9 +1189,8 @@ gdbtk_test srcwin-5.1 "variable balloon test" {
# 6.1 mixed mode disassembly of include file
# Test: srcwin-6.1
# Desc: Some versions of GDBtk can't do mixed-mode disassembly of a function
-# that is in an include file. PR# mi/1101
-
-gdbtk_test srcwin-6.1 "mixed mode disassembly of include file (mi/1101)" {
+# that is in an include file.
+gdbtk_test srcwin-6.1 "mixed mode disassembly of include file" {
set r 0
$srcwin mode "" MIXED
@@ -1190,3 +1214,8 @@ gdbtk_test srcwin-6.1 "mixed mode disassembly of include file (mi/1101)" {
} {1}
gdbtk_test_done
+
+# Local variables:
+# mode: tcl
+# change-log-default-name: "ChangeLog-gdbtk"
+# End:
diff --git a/gdb/testsuite/gdb.gdbtk/srcwin2.test b/gdb/testsuite/gdb.gdbtk/srcwin2.test
index ee693e269cb..395ce0b3138 100644
--- a/gdb/testsuite/gdb.gdbtk/srcwin2.test
+++ b/gdb/testsuite/gdb.gdbtk/srcwin2.test
@@ -1,4 +1,4 @@
-# Copyright (C) 1999, 2001 Red Hat, Inc.
+# Copyright (C) 1999 Cygnus Solutions
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
@@ -38,10 +38,16 @@ global objdir srcdir
##### #####
# Load the test executable
-set program [file join $objdir list]
-if {[catch {gdbtk_test_file $program} t]} {
- # This isn't a test case, since if this fails, we're hosed.
- gdbtk_test_error "loading \"$program\": $t"
+if {$tcl_platform(platform) == "windows"} {
+ set file [file join $objdir list.exe]
+} else {
+ set file [file join $objdir list]
+}
+
+# This isn't a test case, since if this fails, we're hosed.
+if {[catch {gdb_cmd "file $file" 1} t]} {
+ # an error occured loading the file
+ gdbtk_test_error "loading \"$file\": $t"
}
set srcwin [ManagedWin::open SrcWin]
@@ -51,7 +57,7 @@ set statbar [$srcwin test_get _statbar]
# get things started
gdb_cmd "break main"
-gdbtk_test_run
+run_executable
# Test: srcwin2-1.1
# Desc: Check for something in source window
@@ -81,11 +87,10 @@ gdbtk_test srcwin2-1.3 "assembly->mixed mode change" {
set twin [$stw test_get twin]
set file1(mixed) [$twin get 1.0 end]
# mixed != assembly because the lines with source should
- # be noted, even if source in unavailable. This behaviour is
- # different for different debug formats, so we accept either.
- if {$file1(mixed) == ""} {set r -1}
+ # be noted, even if source in unavailable.
+ if {$file1(mixed) == $file1(assembly)} {set r -1}
if {[$statbar.mode get] != "MIXED"} {set r -2}
- set r
+ set r
} {0}
# Test: srcwin2-1.4
@@ -216,20 +221,20 @@ gdbtk_test srcwin2-1.13 "assembly->source mode change" {
# Test: srcwin2-2.1
# Desc: check contents of filename combobox
gdbtk_test srcwin2-2.1 "check contents of filename combobox" {
- set names [$statbar.name list get 0 end]
+ set names [$statbar.name listget 0 end]
set r 0
- foreach f {list0.c list1.c} {
+ foreach f {list0.c list1.c list0.h} {
if {[lsearch $names $f] != -1} {
incr r
}
}
set r
-} {2}
+} {3}
# Test: srcwin2-2.2
# Desc: check contents of function combobox
gdbtk_test srcwin2-2.2 "check contents of function combobox" {
- set names [$statbar.func list get 0 end]
+ set names [$statbar.func listget 0 end]
set r 0
foreach f {main foo unused} {
if {[lsearch $names $f] != -1} {
@@ -252,7 +257,7 @@ gdbtk_test srcwin2-2.3 "goto filename" {
# Test: srcwin2-2.4
# Desc: check contents of function combobox
gdbtk_test srcwin2-2.4 "check contents of function combobox" {
- set names [$statbar.func list get 0 end]
+ set names [$statbar.func listget 0 end]
set r 0
foreach f {bar long_line oof unused} {
if {[lsearch $names $f] != -1} {
@@ -278,14 +283,14 @@ gdbtk_test srcwin2-2.6 "goto function bar" {
# now get a dump of all tags and check that only one line is
# marked BROWSE_TAG and no lines are STACK_TAG or PC_TAG.
- # We know that list1.c should have BROWSE_TAG set at index 10.2
+ # We know that list1.c should have BROWSE_TAG set at index 5.2
# for function "bar". If list1.c is changed or the layout of the source
# window is changed, this must be updated.
if {![catch {set z [$twin dump -tag 1.0 end]}]} {
foreach {k v i} $z {
if {$k == "tagon"} {
if {$v == "BROWSE_TAG"} {
- if {$i == "10.2"} {
+ if {$i == "5.2"} {
incr r
} else {
incr r 5
@@ -322,16 +327,16 @@ gdbtk_test srcwin2-2.7 "goto function oof" {
# now get a dump of all tags and check that only one line is
# marked BROWSE_TAG and no lines are STACK_TAG or PC_TAG.
- # We know that list1.c should have BROWSE_TAG set at index 38.2
+ # We know that list1.c should have BROWSE_TAG set at index 32.2
# for function "oof". If list1.c is changed or the layout of the source
# window is changed, this must be updated.
if {![catch {set z [$twin dump -tag 1.0 end]}]} {
foreach {k v i} $z {
if {$k == "tagon"} {
if {$v == "BROWSE_TAG"} {
- if {$i == "38.2"} {
+ if {$i == "32.2"} {
set line_number [$twin get "$i wordstart" "$i wordend"]
- if {$line_number == "38"} {
+ if {$line_number == "32"} {
incr r
} else {
incr r -100
@@ -421,7 +426,7 @@ gdbtk_test srcwin2-2.11 "set BP and continue" {
foreach {k v i} $z {
if {$k == "tagon"} {
if {$v == "PC_TAG"} {
- if {$i == "38.2"} {
+ if {$i == "32.2"} {
incr r
} else {
incr r 5
@@ -467,14 +472,14 @@ gdbtk_test srcwin2-3.1 "stack up (1)" {
foreach {k v i} $z {
if {$k == "tagon"} {
if {$v == "PC_TAG"} {
- if {$i == "38.2"} {
+ if {$i == "32.2"} {
incr r
} else {
incr r 5
}
}
if {$v == "STACK_TAG"} {
- if {$i == "26.2"} {
+ if {$i == "22.2"} {
incr r
} else {
incr r 10
@@ -513,14 +518,14 @@ gdbtk_test srcwin2-3.2 "stack up (2)" {
foreach {k v i} $z {
if {$k == "tagon"} {
if {$v == "PC_TAG"} {
- if {$i == "38.2"} {
+ if {$i == "32.2"} {
incr r
} else {
incr r 5
}
}
if {$v == "STACK_TAG"} {
- if {$i == "12.2"} {
+ if {$i == "7.2"} {
incr r
} else {
incr r 10
@@ -559,7 +564,7 @@ gdbtk_test srcwin2-3.3 "stack up (3)" {
foreach {k v i} $z {
if {$k == "tagon"} {
if {$v == "STACK_TAG"} {
- if {$i == "9.2"} {
+ if {$i == "8.2"} {
incr r
} else {
incr r 5
@@ -612,44 +617,41 @@ gdbtk_test srcwin2-3.4 "stack up (4)" {
set r
} {1}
-
-# Disabled for now because there are different correct results.
-# Test should be rewritten to include those.
# Test: srcwin2-3.5
# Desc: "stack up" when we are at the top
-#gdbtk_test srcwin2-3.5 "stack up when at the top" {
-# $srcwin stack up
-# set r 0
-# set name [$statbar.name get]
-# set func [$statbar.func get]
+gdbtk_test srcwin2-3.5 "stack up when at the top" {
+ $srcwin stack up
+ set r 0
+ set name [$statbar.name get]
+ set func [$statbar.func get]
# check contents of name and function comboboxes
-# if {$name != "list0.c"} {set r -1}
-# if {$func != "main"} {set r -2}
+ if {$name != "list0.c"} {set r -1}
+ if {$func != "main"} {set r -2}
# check that the correct file is displayed
-# set twin [$stw test_get twin]
-# set a [$twin get 1.0 end]
-# if {[string compare $file1(source) $a]} {set r -3}
+ set twin [$stw test_get twin]
+ set a [$twin get 1.0 end]
+ if {[string compare $file1(source) $a]} {set r -3}
# check for STACK_TAG
-# if {$r == 0} {
-# if {![catch {set z [$twin dump -tag 1.0 end]}]} {
-# foreach {k v i} $z {
-# if {$k == "tagon"} {
-# if {$v == "STACK_TAG"} {
-# incr r
-# }
-# if {$v == "PC_TAG"} {incr r 10}
-# if {$v == "BROWSE_TAG"} {incr r 100}
-# }
-# }
-# } else {
-# set r -4
-# }
-# }
-# set r
-#} {1}
+ if {$r == 0} {
+ if {![catch {set z [$twin dump -tag 1.0 end]}]} {
+ foreach {k v i} $z {
+ if {$k == "tagon"} {
+ if {$v == "STACK_TAG"} {
+ incr r
+ }
+ if {$v == "PC_TAG"} {incr r 10}
+ if {$v == "BROWSE_TAG"} {incr r 100}
+ }
+ }
+ } else {
+ set r -4
+ }
+ }
+ set r
+} {1}
# Test: srcwin2-3.6
# Desc: "stack down" test
@@ -674,7 +676,7 @@ gdbtk_test srcwin2-3.6 "stack down" {
foreach {k v i} $z {
if {$k == "tagon"} {
if {$v == "STACK_TAG"} {
- if {$i == "9.2"} {
+ if {$i == "8.2"} {
incr r
} else {
incr r 5
@@ -714,7 +716,7 @@ gdbtk_test srcwin2-3.7 "stack bottom" {
foreach {k v i} $z {
if {$k == "tagon"} {
if {$v == "PC_TAG"} {
- if {$i == "38.2"} {
+ if {$i == "32.2"} {
incr r
} else {
incr r 5
@@ -754,7 +756,7 @@ gdbtk_test srcwin2-3.8 "stack down when at bottom" {
foreach {k v i} $z {
if {$k == "tagon"} {
if {$v == "PC_TAG"} {
- if {$i == "38.2"} {
+ if {$i == "32.2"} {
incr r
} else {
incr r 5
@@ -794,7 +796,7 @@ gdbtk_test srcwin2-4.1 "set BP in another file" {
foreach {k v i} $z {
if {$k == "tagon"} {
if {$v == "BROWSE_TAG"} {
- if {$i == "9.2"} {
+ if {$i == "8.2"} {
incr r
} else {
incr r 5
@@ -803,7 +805,7 @@ gdbtk_test srcwin2-4.1 "set BP in another file" {
if {$v == "STACK_TAG"} {incr r 10}
if {$v == "PC_TAG"} {incr r 100}
} elseif {$k == "image"} {
- if {$i == "9.0"} {
+ if {$i == "8.0"} {
incr r
} else {
set r -200
@@ -847,7 +849,7 @@ gdbtk_test srcwin2-4.2 "temporary BP" {
foreach {k v i} $z {
if {$k == "tagon"} {
if {$v == "BROWSE_TAG"} {
- if {$i == "9.2"} {
+ if {$i == "8.2"} {
incr r
} else {
incr r 5
@@ -856,7 +858,7 @@ gdbtk_test srcwin2-4.2 "temporary BP" {
if {$v == "STACK_TAG"} {incr r 10}
if {$v == "PC_TAG"} {incr r 100}
} elseif {$k == "image"} {
- if {$i == "9.0"} {
+ if {$i == "8.0"} {
incr r
} else {
set r -200
@@ -876,7 +878,7 @@ gdbtk_test srcwin2-4.2 "temporary BP" {
foreach {k v i} $z {
if {$k == "tagon"} {
if {$v == "PC_TAG"} {
- if {$i == "9.2"} {
+ if {$i == "8.2"} {
incr r
} else {
incr r 5
@@ -897,3 +899,8 @@ gdbtk_test srcwin2-4.2 "temporary BP" {
} {3}
gdbtk_test_done
+
+# Local variables:
+# mode: tcl
+# change-log-default-name: "ChangeLog-gdbtk"
+# End:
diff --git a/gdb/testsuite/gdb.gdbtk/srcwin3.test b/gdb/testsuite/gdb.gdbtk/srcwin3.test
index b9a1617bb5c..c329e9ca096 100644
--- a/gdb/testsuite/gdb.gdbtk/srcwin3.test
+++ b/gdb/testsuite/gdb.gdbtk/srcwin3.test
@@ -1,4 +1,4 @@
-# Copyright (C) 1999, 2001 Red Hat, Inc.
+# Copyright (C) 1999 Cygnus Solutions
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
@@ -39,10 +39,16 @@ global objdir srcdir
##### #####
# Load the test executable
-set program [file join $objdir list]
-if {[catch {gdbtk_test_file $program} t]} {
- # This isn't a test case, since if this fails, we're hosed.
- gdbtk_test_error "loading \"$program\": $t"
+if {$tcl_platform(platform) == "windows"} {
+ set file [file join $objdir list.exe]
+} else {
+ set file [file join $objdir list]
+}
+
+# This isn't a test case, since if this fails, we're hosed.
+if {[catch {gdb_cmd "file $file" 1} t]} {
+ # an error occured loading the file
+ gdbtk_test_error "loading \"$file\": $t"
}
set srcwin [ManagedWin::open SrcWin]
@@ -52,7 +58,7 @@ set statbar [$srcwin test_get _statbar]
# get things started
gdb_cmd "break main"
-gdbtk_test_run
+run_executable
# Test: srcwin3-1.1
# Desc: Check for something in source window
@@ -215,7 +221,7 @@ gdbtk_test srcwin3-1.13 "assembly->source mode change" {
# Desc: check contents of function combobox
# There won't be any because we have no debug info
gdbtk_test srcwin3-2.2 "check contents of function combobox" {
- set names [$statbar.func list get 0 end]
+ set names [$statbar.func listget 0 end]
llength $names
} {0}
@@ -535,43 +541,41 @@ gdbtk_test srcwin3-3.4 "stack up (4)" {
set r
} {1}
-# Disabled for now because there are different correct results.
-# Test should be rewritten to include those.
# Test: srcwin3-3.5
# Desc: "stack up" when we are at the top
-#gdbtk_test srcwin3-3.5 "stack up when at the top" {
-# $srcwin stack up
-# set r 0
-# set name [$statbar.name get]
-# set func [$statbar.func get]
+gdbtk_test srcwin3-3.5 "stack up when at the top" {
+ $srcwin stack up
+ set r 0
+ set name [$statbar.name get]
+ set func [$statbar.func get]
# check contents of name and function comboboxes
-# if {$name != ""} {set r -1}
-# if {$func != "main"} {set r -2}
+ if {$name != ""} {set r -1}
+ if {$func != "main"} {set r -2}
# check that the correct file is displayed
-# set twin [$stw test_get twin]
-# set a [$twin get 1.0 end]
-# if {[string compare $source(main) $a]} {set r -3}
+ set twin [$stw test_get twin]
+ set a [$twin get 1.0 end]
+ if {[string compare $source(main) $a]} {set r -3}
# check for STACK_TAG
-# if {$r == 0} {
-# if {![catch {set z [$twin dump -tag 1.0 end]}]} {
-# foreach {k v i} $z {
-# if {$k == "tagon"} {
-# if {$v == "STACK_TAG"} {
-# incr r
-# }
-# if {$v == "PC_TAG"} {incr r 10}
-# if {$v == "BROWSE_TAG"} {incr r 100}
-# }
-# }
-# } else {
-# set r -4
-# }
-# }
-# set r
-#} {1}
+ if {$r == 0} {
+ if {![catch {set z [$twin dump -tag 1.0 end]}]} {
+ foreach {k v i} $z {
+ if {$k == "tagon"} {
+ if {$v == "STACK_TAG"} {
+ incr r
+ }
+ if {$v == "PC_TAG"} {incr r 10}
+ if {$v == "BROWSE_TAG"} {incr r 100}
+ }
+ }
+ } else {
+ set r -4
+ }
+ }
+ set r
+} {1}
# Test: srcwin3-3.6
# Desc: "stack down" test
@@ -787,3 +791,8 @@ gdbtk_test srcwin3-4.2 "temporary BP" {
} {3}
gdbtk_test_done
+
+# Local variables:
+# mode: tcl
+# change-log-default-name: "ChangeLog-gdbtk"
+# End:
diff --git a/gdb/testsuite/gdb.gdbtk/stack1.c b/gdb/testsuite/gdb.gdbtk/stack1.c
index c6bff6a62a3..389260a22a5 100644
--- a/gdb/testsuite/gdb.gdbtk/stack1.c
+++ b/gdb/testsuite/gdb.gdbtk/stack1.c
@@ -1,5 +1,3 @@
-#include <stdlib.h>
-
/* Functions defined in other files */
extern void extern_func1_1 (int a, char *b, unsigned long c);
diff --git a/gdb/testsuite/lib/gdb.exp b/gdb/testsuite/lib/gdb.exp
index 2ef42bf3db9..94cd40a0917 100644
--- a/gdb/testsuite/lib/gdb.exp
+++ b/gdb/testsuite/lib/gdb.exp
@@ -1584,3 +1584,104 @@ proc rerun_to_main {} {
}
}
+# From dejagnu:
+# srcdir = testsuite src dir (e.g., devo/gdb/testsuite)
+# objdir = testsuite obj dir (e.g., gdb/testsuite)
+# subdir = subdir of testsuite (e.g., gdb.gdbtk)
+#
+# To gdbtk:
+# env(DEFS)=the "defs" files (e.g., devo/gdb/testsuite/gdb.gdbtk/defs)
+# env(SRCDIR)=directory containing the test code (e.g., *.test)
+# env(OBJDIR)=directory which contains any executables
+# (e.g., gdb/testsuite/gdb.gdbtk)
+proc gdbtk_start {test} {
+ global verbose
+ global GDB
+ global GDBFLAGS
+ global env srcdir subdir objdir
+
+ gdb_stop_suppressing_tests;
+
+ verbose "Starting $GDB -nx -q --tclcommand=$test"
+
+ set real_test [which $test]
+ if {$real_test == 0} {
+ perror "$test is not found"
+ exit 1
+ }
+
+ if {![is_remote host]} {
+ if { [which $GDB] == 0 } {
+ perror "$GDB does not exist."
+ exit 1
+ }
+ }
+
+ set wd [pwd]
+ cd [file join $srcdir .. gdbtcl2]
+ set env(GDBTK_LIBRARY) [pwd]
+ cd [file join $srcdir .. .. tcl library]
+ set env(TCL_LIBRARY) [pwd]
+ cd [file join $srcdir .. .. tk library]
+ set env(TK_LIBRARY) [pwd]
+ cd [file join $srcdir .. .. tix library]
+ set env(TIX_LIBRARY) [pwd]
+ cd [file join $srcdir .. .. itcl itcl library]
+ set env(ITCL_LIBRARY) [pwd]
+ cd [file join .. $srcdir .. .. libgui library]
+ set env(CYGNUS_GUI_LIBRARY) [pwd]
+ cd $wd
+ cd [file join $srcdir $subdir]
+ set env(DEFS) [file join [pwd] defs]
+ cd $wd
+ cd [file join $objdir $subdir]
+ set env(OBJDIR) [pwd]
+ cd $wd
+ cd $srcdir
+ set env(SRCDIR) [pwd]
+ cd $wd
+ set env(GDBTK_VERBOSE) 1
+ set env(GDBTK_LOGFILE) [file join $objdir gdb.log]
+ set env(GDBTK_TEST_RUNNING) 1
+ set err [catch {exec $GDB -nx -q --tclcommand=$test} res]
+ if { $err } {
+ perror "Execing $GDB failed: $res"
+ exit 1;
+ }
+ return $res
+}
+
+# gdbtk tests call this function to print out the results of the
+# tests. The argument is a proper list of lists of the form:
+# {status name description msg}. All of these things typically
+# come from the testsuite harness.
+proc gdbtk_analyze_results {results} {
+ foreach test $results {
+ set status [lindex $test 0]
+ set name [lindex $test 1]
+ set description [lindex $test 2]
+ set msg [lindex $test 3]
+
+ switch $status {
+ PASS {
+ pass "$description ($name)"
+ }
+
+ FAIL {
+ fail "$description ($name)"
+ }
+
+ ERROR {
+ perror "$name"
+ }
+
+ XFAIL {
+ xfail "$description ($name)"
+ }
+
+ XPASS {
+ xpass "$description ($name)"
+ }
+ }
+ }
+}
diff --git a/gdb/v850ice.c b/gdb/v850ice.c
index 4e187c0bea2..dba9514db6d 100644
--- a/gdb/v850ice.c
+++ b/gdb/v850ice.c
@@ -31,6 +31,7 @@
#include "value.h"
#include "command.h"
+#include <tcl.h>
#include <windows.h>
#include <winuser.h> /* for WM_USER */
@@ -119,6 +120,8 @@ static int ice_nexti PARAMS ((char *));
static void togdb_force_update PARAMS ((void));
+static void view_source PARAMS ((CORE_ADDR));
+
static void do_gdb (char *, char *, void (*func) PARAMS ((char *, int)), int);
@@ -131,6 +134,7 @@ long (__stdcall * RegisterClient) PARAMS ((HWND));
long (__stdcall * UnregisterClient) PARAMS ((void));
+extern Tcl_Interp *gdbtk_interp;
/* Globals local to this file only */
static int ice_open = 0; /* Is ICE open? */
@@ -256,6 +260,7 @@ v850ice_wndproc (hwnd, message, wParam, lParam)
MessageBox (0, "Address resolution\nNot implemented", "GDB", MB_OK);
break;
case WM_SOURCE:
+ view_source ((CORE_ADDR) lParam);
break;
case WM_STATE_CHANGE:
switch (wParam)
@@ -837,7 +842,12 @@ ice_cont (c)
printf_filtered ("continue (ice)\n");
ReplyMessage ((LRESULT) 1);
+ if (gdbtk_interp == NULL)
+ {
continue_command (NULL, 1);
+ }
+ else
+ Tcl_Eval (gdbtk_interp, "gdb_immediate continue");
return 1;
}
@@ -855,7 +865,12 @@ do_gdb (cmd, str, func, count)
{
printf_unfiltered (str);
+ if (gdbtk_interp == NULL)
+ {
func (NULL, 0);
+ }
+ else
+ Tcl_Eval (gdbtk_interp, cmd);
}
}
@@ -896,8 +911,22 @@ v850ice_command (arg, from_tty)
static void
togdb_force_update (void)
{
+ if (gdbtk_interp != NULL)
+ Tcl_Eval (gdbtk_interp, "gdbtk_update");
}
+static void
+view_source (addr)
+ CORE_ADDR addr;
+{
+ char c[256];
+
+ if (gdbtk_interp != NULL)
+ {
+ sprintf (c, "catch {set src [lindex [ManagedWin::find SrcWin] 0]\n$src location BROWSE [gdb_loc *0x%x]}", addr);
+ Tcl_Eval (gdbtk_interp, c);
+ }
+}
/* Define the target subroutine names */
diff --git a/itcl/itcl/unix/confdefs.h b/itcl/itcl/unix/confdefs.h
new file mode 100644
index 00000000000..8b137891791
--- /dev/null
+++ b/itcl/itcl/unix/confdefs.h
@@ -0,0 +1 @@
+
diff --git a/itcl/itcl/unix/config.log b/itcl/itcl/unix/config.log
new file mode 100644
index 00000000000..bfe54388460
--- /dev/null
+++ b/itcl/itcl/unix/config.log
@@ -0,0 +1,12 @@
+This file contains any messages produced by compilers while
+running configure, to aid debugging if configure makes a mistake.
+
+configure:628: checking for a BSD compatible install
+configure:681: checking for ranlib
+configure:716: checking for gcc
+configure:826: checking whether the C compiler (gcc ) works
+configure:840: gcc -o conftest conftest.c 1>&5
+configure:860: checking whether the C compiler (gcc ) is a cross-compiler
+configure:865: checking whether we are using GNU C
+configure:874: gcc -E conftest.c
+configure:893: checking whether gcc accepts -g
diff --git a/tk/doc/tk4.0.ps b/tk/doc/tk4.0.ps
new file mode 100644
index 00000000000..d79642d1124
--- /dev/null
+++ b/tk/doc/tk4.0.ps
@@ -0,0 +1,4602 @@
+%!
+%%BoundingBox: (atend)
+%%Pages: (atend)
+%%DocumentFonts: (atend)
+%%EndComments
+%%BeginProlog
+%
+% FrameMaker postscript_prolog 3.0, for use with FrameMaker 3.0
+% This postscript_prolog file is Copyright (c) 1986-1991 Frame Technology
+% Corporation. All rights reserved. This postscript_prolog file may be
+% freely copied and distributed in conjunction with documents created using
+% FrameMaker.
+% NOTE
+% This file fixes the problem with NeWS printers dithering color output.
+% Any questions should be sent to mickey@magickingdom.eng.sun.com
+%
+% Known Problems:
+% Due to bugs in Transcript, the 'PS-Adobe-' is omitted from line 1
+/FMversion (3.0) def
+% Set up Color vs. Black-and-White
+
+/FMPrintInColor { % once-thru loop gimmick
+ % See if we're a NeWSprint printer
+ /currentcanvas where {
+ pop systemdict /separationdict known
+ exit
+ } if
+% originally had the following, which should always be false:
+% /currentcanvas where {
+% pop currentcanvas /Color known {
+% currentcanvas /Color get
+% exit
+% } if
+% } if
+ systemdict /colorimage known
+ systemdict /currentcolortransfer known and
+exit } loop def
+
+% Uncomment the following line to force b&w on color printer
+% /FMPrintInColor false def
+/FrameDict 195 dict def
+systemdict /errordict known not {/errordict 10 dict def
+ errordict /rangecheck {stop} put} if
+% The readline in 23.0 doesn't recognize cr's as nl's on AppleTalk
+FrameDict /tmprangecheck errordict /rangecheck get put
+errordict /rangecheck {FrameDict /bug true put} put
+FrameDict /bug false put
+mark
+% Some PS machines read past the CR, so keep the following 3 lines together!
+currentfile 5 string readline
+00
+0000000000
+cleartomark
+errordict /rangecheck FrameDict /tmprangecheck get put
+FrameDict /bug get {
+ /readline {
+ /gstring exch def
+ /gfile exch def
+ /gindex 0 def
+ {
+ gfile read pop
+ dup 10 eq {exit} if
+ dup 13 eq {exit} if
+ gstring exch gindex exch put
+ /gindex gindex 1 add def
+ } loop
+ pop
+ gstring 0 gindex getinterval true
+ } def
+ } if
+/FMVERSION {
+ FMversion ne {
+ /Times-Roman findfont 18 scalefont setfont
+ 100 100 moveto
+ (FrameMaker version does not match postscript_prolog!)
+ dup =
+ show showpage
+ } if
+ } def
+/FMLOCAL {
+ FrameDict begin
+ 0 def
+ end
+ } def
+ /gstring FMLOCAL
+ /gfile FMLOCAL
+ /gindex FMLOCAL
+ /orgxfer FMLOCAL
+ /orgproc FMLOCAL
+ /organgle FMLOCAL
+ /orgfreq FMLOCAL
+ /yscale FMLOCAL
+ /xscale FMLOCAL
+ /manualfeed FMLOCAL
+ /paperheight FMLOCAL
+ /paperwidth FMLOCAL
+/FMDOCUMENT {
+ array /FMfonts exch def
+ /#copies exch def
+ FrameDict begin
+ 0 ne dup {setmanualfeed} if
+ /manualfeed exch def
+ /paperheight exch def
+ /paperwidth exch def
+ /yscale exch def
+ /xscale exch def
+ currenttransfer cvlit /orgxfer exch def
+ currentscreen cvlit /orgproc exch def
+ /organgle exch def /orgfreq exch def
+ setpapername
+ manualfeed {true} {papersize} ifelse
+ {manualpapersize} {false} ifelse
+ {desperatepapersize} if
+ end
+ } def
+ /pagesave FMLOCAL
+ /orgmatrix FMLOCAL
+ /landscape FMLOCAL
+/FMBEGINPAGE {
+ FrameDict begin
+ /pagesave save def
+ 3.86 setmiterlimit
+ /landscape exch 0 ne def
+ landscape {
+ 90 rotate 0 exch neg translate pop
+ }
+ {pop pop}
+ ifelse
+ xscale yscale scale
+ /orgmatrix matrix def
+ gsave
+ } def
+/FMENDPAGE {
+ grestore
+ pagesave restore
+ end
+ showpage
+ } def
+/FMFONTDEFINE {
+ FrameDict begin
+ findfont
+ ReEncode
+ 1 index exch
+ definefont
+ FMfonts 3 1 roll
+ put
+ end
+ } def
+/FMFILLS {
+ FrameDict begin
+ array /fillvals exch def
+ end
+ } def
+/FMFILL {
+ FrameDict begin
+ fillvals 3 1 roll put
+ end
+ } def
+/FMNORMALIZEGRAPHICS {
+ newpath
+ 0.0 0.0 moveto
+ 1 setlinewidth
+ 0 setlinecap
+ 0 0 0 sethsbcolor
+ 0 setgray
+ } bind def
+ /fx FMLOCAL
+ /fy FMLOCAL
+ /fh FMLOCAL
+ /fw FMLOCAL
+ /llx FMLOCAL
+ /lly FMLOCAL
+ /urx FMLOCAL
+ /ury FMLOCAL
+/FMBEGINEPSF {
+ end
+ /FMEPSF save def
+ /showpage {} def
+ FMNORMALIZEGRAPHICS
+ [/fy /fx /fh /fw /ury /urx /lly /llx] {exch def} forall
+ fx fy translate
+ rotate
+ fw urx llx sub div fh ury lly sub div scale
+ llx neg lly neg translate
+ } bind def
+/FMENDEPSF {
+ FMEPSF restore
+ FrameDict begin
+ } bind def
+FrameDict begin
+/setmanualfeed {
+%%BeginFeature *ManualFeed True
+ statusdict /manualfeed true put
+%%EndFeature
+ } def
+/max {2 copy lt {exch} if pop} bind def
+/min {2 copy gt {exch} if pop} bind def
+/inch {72 mul} def
+/pagedimen {
+ paperheight sub abs 16 lt exch
+ paperwidth sub abs 16 lt and
+ {/papername exch def} {pop} ifelse
+ } def
+ /papersizedict FMLOCAL
+/setpapername {
+ /papersizedict 14 dict def
+ papersizedict begin
+ /papername /unknown def
+ /Letter 8.5 inch 11.0 inch pagedimen
+ /LetterSmall 7.68 inch 10.16 inch pagedimen
+ /Tabloid 11.0 inch 17.0 inch pagedimen
+ /Ledger 17.0 inch 11.0 inch pagedimen
+ /Legal 8.5 inch 14.0 inch pagedimen
+ /Statement 5.5 inch 8.5 inch pagedimen
+ /Executive 7.5 inch 10.0 inch pagedimen
+ /A3 11.69 inch 16.5 inch pagedimen
+ /A4 8.26 inch 11.69 inch pagedimen
+ /A4Small 7.47 inch 10.85 inch pagedimen
+ /B4 10.125 inch 14.33 inch pagedimen
+ /B5 7.16 inch 10.125 inch pagedimen
+ end
+ } def
+/papersize {
+ papersizedict begin
+ /Letter {lettertray letter} def
+ /LetterSmall {lettertray lettersmall} def
+ /Tabloid {11x17tray 11x17} def
+ /Ledger {ledgertray ledger} def
+ /Legal {legaltray legal} def
+ /Statement {statementtray statement} def
+ /Executive {executivetray executive} def
+ /A3 {a3tray a3} def
+ /A4 {a4tray a4} def
+ /A4Small {a4tray a4small} def
+ /B4 {b4tray b4} def
+ /B5 {b5tray b5} def
+ /unknown {unknown} def
+ papersizedict dup papername known {papername} {/unknown} ifelse get
+ end
+ /FMdicttop countdictstack 1 add def
+ statusdict begin stopped end
+ countdictstack -1 FMdicttop {pop end} for
+ } def
+/manualpapersize {
+ papersizedict begin
+ /Letter {letter} def
+ /LetterSmall {lettersmall} def
+ /Tabloid {11x17} def
+ /Ledger {ledger} def
+ /Legal {legal} def
+ /Statement {statement} def
+ /Executive {executive} def
+ /A3 {a3} def
+ /A4 {a4} def
+ /A4Small {a4small} def
+ /B4 {b4} def
+ /B5 {b5} def
+ /unknown {unknown} def
+ papersizedict dup papername known {papername} {/unknown} ifelse get
+ end
+ stopped
+ } def
+/desperatepapersize {
+ statusdict /setpageparams known
+ {
+ paperwidth paperheight 0 1
+ statusdict begin
+ {setpageparams} stopped pop
+ end
+ } if
+ } def
+/savematrix {
+ orgmatrix currentmatrix pop
+ } bind def
+/restorematrix {
+ orgmatrix setmatrix
+ } bind def
+/dmatrix matrix def
+/dpi 72 0 dmatrix defaultmatrix dtransform
+ dup mul exch dup mul add sqrt def
+/freq dpi 18.75 div 8 div round dup 0 eq {pop 1} if 8 mul dpi exch div def
+/sangle 1 0 dmatrix defaultmatrix dtransform exch atan def
+/DiacriticEncoding [
+/.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef
+/.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef
+/.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef
+/.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef
+/.notdef /.notdef /.notdef /.notdef /space /exclam /quotedbl
+/numbersign /dollar /percent /ampersand /quotesingle /parenleft
+/parenright /asterisk /plus /comma /hyphen /period /slash /zero /one
+/two /three /four /five /six /seven /eight /nine /colon /semicolon
+/less /equal /greater /question /at /A /B /C /D /E /F /G /H /I /J /K
+/L /M /N /O /P /Q /R /S /T /U /V /W /X /Y /Z /bracketleft /backslash
+/bracketright /asciicircum /underscore /grave /a /b /c /d /e /f /g /h
+/i /j /k /l /m /n /o /p /q /r /s /t /u /v /w /x /y /z /braceleft /bar
+/braceright /asciitilde /.notdef /Adieresis /Aring /Ccedilla /Eacute
+/Ntilde /Odieresis /Udieresis /aacute /agrave /acircumflex /adieresis
+/atilde /aring /ccedilla /eacute /egrave /ecircumflex /edieresis
+/iacute /igrave /icircumflex /idieresis /ntilde /oacute /ograve
+/ocircumflex /odieresis /otilde /uacute /ugrave /ucircumflex
+/udieresis /dagger /.notdef /cent /sterling /section /bullet
+/paragraph /germandbls /registered /copyright /trademark /acute
+/dieresis /.notdef /AE /Oslash /.notdef /.notdef /.notdef /.notdef
+/yen /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef
+/ordfeminine /ordmasculine /.notdef /ae /oslash /questiondown
+/exclamdown /logicalnot /.notdef /florin /.notdef /.notdef
+/guillemotleft /guillemotright /ellipsis /.notdef /Agrave /Atilde
+/Otilde /OE /oe /endash /emdash /quotedblleft /quotedblright
+/quoteleft /quoteright /.notdef /.notdef /ydieresis /Ydieresis
+/fraction /currency /guilsinglleft /guilsinglright /fi /fl /daggerdbl
+/periodcentered /quotesinglbase /quotedblbase /perthousand
+/Acircumflex /Ecircumflex /Aacute /Edieresis /Egrave /Iacute
+/Icircumflex /Idieresis /Igrave /Oacute /Ocircumflex /.notdef /Ograve
+/Uacute /Ucircumflex /Ugrave /dotlessi /circumflex /tilde /macron
+/breve /dotaccent /ring /cedilla /hungarumlaut /ogonek /caron
+] def
+/ReEncode {
+ dup
+ length
+ dict begin
+ {
+ 1 index /FID ne
+ {def}
+ {pop pop} ifelse
+ } forall
+ 0 eq {/Encoding DiacriticEncoding def} if
+ currentdict
+ end
+ } bind def
+/graymode true def
+ /bwidth FMLOCAL
+ /bpside FMLOCAL
+ /bstring FMLOCAL
+ /onbits FMLOCAL
+ /offbits FMLOCAL
+ /xindex FMLOCAL
+ /yindex FMLOCAL
+ /x FMLOCAL
+ /y FMLOCAL
+/setpattern {
+ /bwidth exch def
+ /bpside exch def
+ /bstring exch def
+ /onbits 0 def /offbits 0 def
+ freq sangle landscape {90 add} if
+ {/y exch def
+ /x exch def
+ /xindex x 1 add 2 div bpside mul cvi def
+ /yindex y 1 add 2 div bpside mul cvi def
+ bstring yindex bwidth mul xindex 8 idiv add get
+ 1 7 xindex 8 mod sub bitshift and 0 ne
+ {/onbits onbits 1 add def 1}
+ {/offbits offbits 1 add def 0}
+ ifelse
+ }
+ setscreen
+ {} settransfer
+ offbits offbits onbits add div FMsetgray
+ /graymode false def
+ } bind def
+/grayness {
+ FMsetgray
+ graymode not {
+ /graymode true def
+ orgxfer cvx settransfer
+ orgfreq organgle orgproc cvx setscreen
+ } if
+ } bind def
+ /HUE FMLOCAL
+ /SAT FMLOCAL
+ /BRIGHT FMLOCAL
+ /Colors FMLOCAL
+FMPrintInColor
+
+ {
+ /HUE 0 def
+ /SAT 0 def
+ /BRIGHT 0 def
+ % array of arrays Hue and Sat values for the separations [HUE BRIGHT]
+ /Colors
+ [[0 0 ] % black
+ [0 0 ] % white
+ [0.00 1.0] % red
+ [0.37 1.0] % green
+ [0.60 1.0] % blue
+ [0.50 1.0] % cyan
+ [0.83 1.0] % magenta
+ [0.16 1.0] % comment / yellow
+ ] def
+
+ /BEGINBITMAPCOLOR {
+ BITMAPCOLOR} def
+ /BEGINBITMAPCOLORc {
+ BITMAPCOLORc} def
+ /BEGINBITMAPTRUECOLOR {
+ BITMAPTRUECOLOR } def
+ /BEGINBITMAPTRUECOLORc {
+ BITMAPTRUECOLORc } def
+ /K {
+ Colors exch get dup
+ 0 get /HUE exch store
+ 1 get /BRIGHT exch store
+ HUE 0 eq BRIGHT 0 eq and
+ {1.0 SAT sub setgray}
+ {HUE SAT BRIGHT sethsbcolor}
+ ifelse
+ } def
+ /FMsetgray {
+ /SAT exch 1.0 exch sub store
+ HUE 0 eq BRIGHT 0 eq and
+ {1.0 SAT sub setgray}
+ {HUE SAT BRIGHT sethsbcolor}
+ ifelse
+ } bind def
+ }
+
+ {
+ /BEGINBITMAPCOLOR {
+ BITMAPGRAY} def
+ /BEGINBITMAPCOLORc {
+ BITMAPGRAYc} def
+ /BEGINBITMAPTRUECOLOR {
+ BITMAPTRUEGRAY } def
+ /BEGINBITMAPTRUECOLORc {
+ BITMAPTRUEGRAYc } def
+ /FMsetgray {setgray} bind def
+ /K {
+ pop
+ } def
+ }
+ifelse
+/normalize {
+ transform round exch round exch itransform
+ } bind def
+/dnormalize {
+ dtransform round exch round exch idtransform
+ } bind def
+/lnormalize {
+ 0 dtransform exch cvi 2 idiv 2 mul 1 add exch idtransform pop
+ } bind def
+/H {
+ lnormalize setlinewidth
+ } bind def
+/Z {
+ setlinecap
+ } bind def
+ /fillvals FMLOCAL
+/X {
+ fillvals exch get
+ dup type /stringtype eq
+ {8 1 setpattern}
+ {grayness}
+ ifelse
+ } bind def
+/V {
+ gsave eofill grestore
+ } bind def
+/N {
+ stroke
+ } bind def
+/M {newpath moveto} bind def
+/E {lineto} bind def
+/D {curveto} bind def
+/O {closepath} bind def
+ /n FMLOCAL
+/L {
+ /n exch def
+ newpath
+ normalize
+ moveto
+ 2 1 n {pop normalize lineto} for
+ } bind def
+/Y {
+ L
+ closepath
+ } bind def
+ /x1 FMLOCAL
+ /x2 FMLOCAL
+ /y1 FMLOCAL
+ /y2 FMLOCAL
+ /rad FMLOCAL
+/R {
+ /y2 exch def
+ /x2 exch def
+ /y1 exch def
+ /x1 exch def
+ x1 y1
+ x2 y1
+ x2 y2
+ x1 y2
+ 4 Y
+ } bind def
+/RR {
+ /rad exch def
+ normalize
+ /y2 exch def
+ /x2 exch def
+ normalize
+ /y1 exch def
+ /x1 exch def
+ newpath
+ x1 y1 rad add moveto
+ x1 y2 x2 y2 rad arcto
+ x2 y2 x2 y1 rad arcto
+ x2 y1 x1 y1 rad arcto
+ x1 y1 x1 y2 rad arcto
+ closepath
+ 16 {pop} repeat
+ } bind def
+/C {
+ grestore
+ gsave
+ R
+ clip
+ } bind def
+ /FMpointsize FMLOCAL
+/F {
+ FMfonts exch get
+ FMpointsize scalefont
+ setfont
+ } bind def
+/Q {
+ /FMpointsize exch def
+ F
+ } bind def
+/T {
+ moveto show
+ } bind def
+/RF {
+ rotate
+ 0 ne {-1 1 scale} if
+ } bind def
+/TF {
+ gsave
+ moveto
+ RF
+ show
+ grestore
+ } bind def
+/P {
+ moveto
+ 0 32 3 2 roll widthshow
+ } bind def
+/PF {
+ gsave
+ moveto
+ RF
+ 0 32 3 2 roll widthshow
+ grestore
+ } bind def
+/S {
+ moveto
+ 0 exch ashow
+ } bind def
+/SF {
+ gsave
+ moveto
+ RF
+ 0 exch ashow
+ grestore
+ } bind def
+/B {
+ moveto
+ 0 32 4 2 roll 0 exch awidthshow
+ } bind def
+/BF {
+ gsave
+ moveto
+ RF
+ 0 32 4 2 roll 0 exch awidthshow
+ grestore
+ } bind def
+/G {
+ gsave
+ newpath
+ normalize translate 0.0 0.0 moveto
+ dnormalize scale
+ 0.0 0.0 1.0 5 3 roll arc
+ closepath fill
+ grestore
+ } bind def
+/A {
+ gsave
+ savematrix
+ newpath
+ 2 index 2 div add exch 3 index 2 div sub exch
+ normalize 2 index 2 div sub exch 3 index 2 div add exch
+ translate
+ scale
+ 0.0 0.0 1.0 5 3 roll arc
+ restorematrix
+ stroke
+ grestore
+ } bind def
+ /x FMLOCAL
+ /y FMLOCAL
+ /w FMLOCAL
+ /h FMLOCAL
+ /xx FMLOCAL
+ /yy FMLOCAL
+ /ww FMLOCAL
+ /hh FMLOCAL
+ /FMsaveobject FMLOCAL
+ /FMoptop FMLOCAL
+ /FMdicttop FMLOCAL
+/BEGINPRINTCODE {
+ /FMdicttop countdictstack 1 add def
+ /FMoptop count 4 sub def
+ /FMsaveobject save def
+ userdict begin
+ /showpage {} def
+ FMNORMALIZEGRAPHICS
+ 3 index neg 3 index neg translate
+ } bind def
+/ENDPRINTCODE {
+ count -1 FMoptop {pop pop} for
+ countdictstack -1 FMdicttop {pop end} for
+ FMsaveobject restore
+ } bind def
+/gn {
+ 0
+ { 46 mul
+ cf read pop
+ 32 sub
+ dup 46 lt {exit} if
+ 46 sub add
+ } loop
+ add
+ } bind def
+ /str FMLOCAL
+/cfs {
+ /str sl string def
+ 0 1 sl 1 sub {str exch val put} for
+ str def
+ } bind def
+/ic [
+ 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0223
+ 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0223
+ 0
+ {0 hx} {1 hx} {2 hx} {3 hx} {4 hx} {5 hx} {6 hx} {7 hx} {8 hx} {9 hx}
+ {10 hx} {11 hx} {12 hx} {13 hx} {14 hx} {15 hx} {16 hx} {17 hx} {18 hx}
+ {19 hx} {gn hx} {0} {1} {2} {3} {4} {5} {6} {7} {8} {9} {10} {11} {12}
+ {13} {14} {15} {16} {17} {18} {19} {gn} {0 wh} {1 wh} {2 wh} {3 wh}
+ {4 wh} {5 wh} {6 wh} {7 wh} {8 wh} {9 wh} {10 wh} {11 wh} {12 wh}
+ {13 wh} {14 wh} {gn wh} {0 bl} {1 bl} {2 bl} {3 bl} {4 bl} {5 bl} {6 bl}
+ {7 bl} {8 bl} {9 bl} {10 bl} {11 bl} {12 bl} {13 bl} {14 bl} {gn bl}
+ {0 fl} {1 fl} {2 fl} {3 fl} {4 fl} {5 fl} {6 fl} {7 fl} {8 fl} {9 fl}
+ {10 fl} {11 fl} {12 fl} {13 fl} {14 fl} {gn fl}
+ ] def
+ /sl FMLOCAL
+ /val FMLOCAL
+ /ws FMLOCAL
+ /im FMLOCAL
+ /bs FMLOCAL
+ /cs FMLOCAL
+ /len FMLOCAL
+ /pos FMLOCAL
+/ms {
+ /sl exch def
+ /val 255 def
+ /ws cfs
+ /im cfs
+ /val 0 def
+ /bs cfs
+ /cs cfs
+ } bind def
+400 ms
+/ip {
+ is
+ 0
+ cf cs readline pop
+ { ic exch get exec
+ add
+ } forall
+ pop
+
+ } bind def
+/wh {
+ /len exch def
+ /pos exch def
+ ws 0 len getinterval im pos len getinterval copy pop
+ pos len
+ } bind def
+/bl {
+ /len exch def
+ /pos exch def
+ bs 0 len getinterval im pos len getinterval copy pop
+ pos len
+ } bind def
+/s1 1 string def
+/fl {
+ /len exch def
+ /pos exch def
+ /val cf s1 readhexstring pop 0 get def
+ pos 1 pos len add 1 sub {im exch val put} for
+ pos len
+ } bind def
+/hx {
+ 3 copy getinterval
+ cf exch readhexstring pop pop
+ } bind def
+ /h FMLOCAL
+ /w FMLOCAL
+ /d FMLOCAL
+ /lb FMLOCAL
+ /bitmapsave FMLOCAL
+ /is FMLOCAL
+ /cf FMLOCAL
+/wbytes {
+ dup
+ 8 eq {pop} {1 eq {7 add 8 idiv} {3 add 4 idiv} ifelse} ifelse
+ } bind def
+/BEGINBITMAPBWc {
+ 1 {} COMMONBITMAPc
+ } bind def
+/BEGINBITMAPGRAYc {
+ 8 {} COMMONBITMAPc
+ } bind def
+/BEGINBITMAP2BITc {
+ 2 {} COMMONBITMAPc
+ } bind def
+/COMMONBITMAPc {
+ /r exch def
+ /d exch def
+ gsave
+ translate rotate scale /h exch def /w exch def
+ /lb w d wbytes def
+ sl lb lt {lb ms} if
+ /bitmapsave save def
+ r
+ /is im 0 lb getinterval def
+ ws 0 lb getinterval is copy pop
+ /cf currentfile def
+ w h d [w 0 0 h neg 0 h]
+ {ip} image
+ bitmapsave restore
+ grestore
+ } bind def
+/BEGINBITMAPBW {
+ 1 {} COMMONBITMAP
+ } bind def
+/BEGINBITMAPGRAY {
+ 8 {} COMMONBITMAP
+ } bind def
+/BEGINBITMAP2BIT {
+ 2 {} COMMONBITMAP
+ } bind def
+/COMMONBITMAP {
+ /r exch def
+ /d exch def
+ gsave
+ translate rotate scale /h exch def /w exch def
+ /bitmapsave save def
+ r
+ /is w d wbytes string def
+ /cf currentfile def
+ w h d [w 0 0 h neg 0 h]
+ {cf is readhexstring pop} image
+ bitmapsave restore
+ grestore
+ } bind def
+ /proc1 FMLOCAL
+ /proc2 FMLOCAL
+ /newproc FMLOCAL
+/Fmcc {
+ /proc2 exch cvlit def
+ /proc1 exch cvlit def
+ /newproc proc1 length proc2 length add array def
+ newproc 0 proc1 putinterval
+ newproc proc1 length proc2 putinterval
+ newproc cvx
+} bind def
+/ngrayt 256 array def
+/nredt 256 array def
+/nbluet 256 array def
+/ngreent 256 array def
+ /gryt FMLOCAL
+ /blut FMLOCAL
+ /grnt FMLOCAL
+ /redt FMLOCAL
+ /indx FMLOCAL
+ /cynu FMLOCAL
+ /magu FMLOCAL
+ /yelu FMLOCAL
+ /k FMLOCAL
+ /u FMLOCAL
+/colorsetup {
+ currentcolortransfer
+ /gryt exch def
+ /blut exch def
+ /grnt exch def
+ /redt exch def
+ 0 1 255 {
+ /indx exch def
+ /cynu 1 red indx get 255 div sub def
+ /magu 1 green indx get 255 div sub def
+ /yelu 1 blue indx get 255 div sub def
+ /k cynu magu min yelu min def
+ /u k currentundercolorremoval exec def
+ nredt indx 1 0 cynu u sub max sub redt exec put
+ ngreent indx 1 0 magu u sub max sub grnt exec put
+ nbluet indx 1 0 yelu u sub max sub blut exec put
+ ngrayt indx 1 k currentblackgeneration exec sub gryt exec put
+ } for
+ {255 mul cvi nredt exch get}
+ {255 mul cvi ngreent exch get}
+ {255 mul cvi nbluet exch get}
+ {255 mul cvi ngrayt exch get}
+ setcolortransfer
+ {pop 0} setundercolorremoval
+ {} setblackgeneration
+ } bind def
+ /tran FMLOCAL
+/fakecolorsetup {
+ /tran 256 string def
+ 0 1 255 {/indx exch def
+ tran indx
+ red indx get 77 mul
+ green indx get 151 mul
+ blue indx get 28 mul
+ add add 256 idiv put} for
+ currenttransfer
+ {255 mul cvi tran exch get 255.0 div}
+ exch Fmcc settransfer
+} bind def
+/BITMAPCOLOR {
+ /d 8 def
+ gsave
+ translate rotate scale /h exch def /w exch def
+ /bitmapsave save def
+ colorsetup
+ /is w d wbytes string def
+ /cf currentfile def
+ w h d [w 0 0 h neg 0 h]
+ {cf is readhexstring pop} {is} {is} true 3 colorimage
+ bitmapsave restore
+ grestore
+ } bind def
+/BITMAPCOLORc {
+ /d 8 def
+ gsave
+ translate rotate scale /h exch def /w exch def
+ /lb w d wbytes def
+ sl lb lt {lb ms} if
+ /bitmapsave save def
+ colorsetup
+ /is im 0 lb getinterval def
+ ws 0 lb getinterval is copy pop
+ /cf currentfile def
+ w h d [w 0 0 h neg 0 h]
+ {ip} {is} {is} true 3 colorimage
+ bitmapsave restore
+ grestore
+ } bind def
+/BITMAPTRUECOLORc {
+ gsave
+ translate rotate scale /h exch def /w exch def
+ /bitmapsave save def
+
+ /is w string def
+
+ ws 0 w getinterval is copy pop
+ /cf currentfile def
+ w h 8 [w 0 0 h neg 0 h]
+ {ip} {gip} {bip} true 3 colorimage
+ bitmapsave restore
+ grestore
+ } bind def
+/BITMAPTRUECOLOR {
+ gsave
+ translate rotate scale /h exch def /w exch def
+ /bitmapsave save def
+ /is w string def
+ /gis w string def
+ /bis w string def
+ /cf currentfile def
+ w h 8 [w 0 0 h neg 0 h]
+ { cf is readhexstring pop }
+ { cf gis readhexstring pop }
+ { cf bis readhexstring pop }
+ true 3 colorimage
+ bitmapsave restore
+ grestore
+ } bind def
+/BITMAPTRUEGRAYc {
+ gsave
+ translate rotate scale /h exch def /w exch def
+ /bitmapsave save def
+
+ /is w string def
+
+ ws 0 w getinterval is copy pop
+ /cf currentfile def
+ w h 8 [w 0 0 h neg 0 h]
+ {ip gip bip w gray} image
+ bitmapsave restore
+ grestore
+ } bind def
+/ww FMLOCAL
+/r FMLOCAL
+/g FMLOCAL
+/b FMLOCAL
+/i FMLOCAL
+/gray {
+ /ww exch def
+ /b exch def
+ /g exch def
+ /r exch def
+ 0 1 ww 1 sub { /i exch def r i get .299 mul g i get .587 mul
+ b i get .114 mul add add r i 3 -1 roll floor cvi put } for
+ r
+ } bind def
+/BITMAPTRUEGRAY {
+ gsave
+ translate rotate scale /h exch def /w exch def
+ /bitmapsave save def
+ /is w string def
+ /gis w string def
+ /bis w string def
+ /cf currentfile def
+ w h 8 [w 0 0 h neg 0 h]
+ { cf is readhexstring pop
+ cf gis readhexstring pop
+ cf bis readhexstring pop w gray} image
+ bitmapsave restore
+ grestore
+ } bind def
+/BITMAPGRAY {
+ 8 {fakecolorsetup} COMMONBITMAP
+ } bind def
+/BITMAPGRAYc {
+ 8 {fakecolorsetup} COMMONBITMAPc
+ } bind def
+/ENDBITMAP {
+ } bind def
+end
+ /ALDsave FMLOCAL
+ /ALDmatrix matrix def ALDmatrix currentmatrix pop
+/StartALD {
+ /ALDsave save def
+ savematrix
+ ALDmatrix setmatrix
+ } bind def
+/InALD {
+ restorematrix
+ } bind def
+/DoneALD {
+ ALDsave restore
+ } bind def
+%%EndProlog
+%%BeginSetup
+(3.0) FMVERSION
+1 1 612 792 0 1 13 FMDOCUMENT
+0 0 /Helvetica-Bold FMFONTDEFINE
+1 0 /Times-Bold FMFONTDEFINE
+2 0 /Times-Italic FMFONTDEFINE
+3 0 /Times-Roman FMFONTDEFINE
+4 0 /Helvetica FMFONTDEFINE
+5 0 /Courier FMFONTDEFINE
+6 0 /Courier-Oblique FMFONTDEFINE
+32 FMFILLS
+0 0 FMFILL
+1 0.1 FMFILL
+2 0.3 FMFILL
+3 0.5 FMFILL
+4 0.7 FMFILL
+5 0.9 FMFILL
+6 0.97 FMFILL
+7 1 FMFILL
+8 <0f1e3c78f0e1c387> FMFILL
+9 <0f87c3e1f0783c1e> FMFILL
+10 <cccccccccccccccc> FMFILL
+11 <ffff0000ffff0000> FMFILL
+12 <8142241818244281> FMFILL
+13 <03060c183060c081> FMFILL
+14 <8040201008040201> FMFILL
+16 1 FMFILL
+17 0.9 FMFILL
+18 0.7 FMFILL
+19 0.5 FMFILL
+20 0.3 FMFILL
+21 0.1 FMFILL
+22 0.03 FMFILL
+23 0 FMFILL
+24 <f0e1c3870f1e3c78> FMFILL
+25 <f0783c1e0f87c3e1> FMFILL
+26 <3333333333333333> FMFILL
+27 <0000ffff0000ffff> FMFILL
+28 <7ebddbe7e7dbbd7e> FMFILL
+29 <fcf9f3e7cf9f3f7e> FMFILL
+30 <7fbfdfeff7fbfdfe> FMFILL
+%%EndSetup
+%%Page: "1" 1
+%%BeginPaperSize: Letter
+%%EndPaperSize
+612 792 0 FMBEGINPAGE
+98.1 675 512.1 675 2 L
+7 X
+0 K
+V
+2 H
+0 Z
+0 X
+N
+98.1 450 512.1 450 2 L
+7 X
+V
+2 Z
+0 X
+N
+98.1 108 512.1 126 R
+7 X
+V
+0 10 Q
+0 X
+(1) 506.54 119.33 T
+1 24 Q
+-0.48 (Tk4.0 Overview and Porting Guide) 152.1 605 S
+2 12 Q
+(John Ouster) 152.1 563 T
+(hout) 210.84 563 T
+98.1 135 512.1 423 R
+7 X
+V
+3 10 Q
+0 X
+(Tk version 4.0 is a major new release with many improvements, new features, and bug) 152.1 416.33 T
+(\336xes. This document provides an introduction to the new features and describes the most) 152.1 404.33 T
+-0.18 (common problems you are likely to encounter when porting scripts from Tk 3.6, the previ-) 152.1 392.33 P
+(ous release. This is) 152.1 380.33 T
+2 F
+(not) 230.66 380.33 T
+3 F
+( an introduction to Tk: I assume that you are already familiar with) 243.43 380.33 T
+(Tk 3.6 as described in the book) 152.1 368.33 T
+2 F
+(T) 279.79 368.33 T
+(cl and the Tk T) 284.43 368.33 T
+(oolkit) 343.48 368.33 T
+3 F
+(.) 366.24 368.33 T
+-0.26 (The good news about Tk 4.0 is that it has many improvements over Tk 3.6. Here are a) 170.1 356.33 P
+(few of the most important new features:) 152.1 344.33 T
+3 12 Q
+(\245) 152.1 329.33 T
+3 10 Q
+(Tk 4.0 includes a general-purpose mechanism for manipulating color images \050Tk 3.6) 162.9 329.33 T
+(supports only monochrome images\051.) 162.9 317.33 T
+3 12 Q
+(\245) 152.1 302.33 T
+3 10 Q
+-0.17 (The text widget in Tk 4.0 includes many new features such as tab stops, embedded win-) 162.9 302.33 P
+(dows, horizontal scrolling, and many new formatting options.) 162.9 290.33 T
+3 12 Q
+(\245) 152.1 275.33 T
+3 10 Q
+(The binding mechanism in Tk 4.0 is much more powerful in Tk 3.6.) 162.9 275.33 T
+3 12 Q
+(\245) 152.1 260.33 T
+3 10 Q
+(Motif compliance is much better) 162.9 260.33 T
+(. For example, there is now support for keyboard tra-) 292.82 260.33 T
+(versal and focus highlights.) 162.9 248.33 T
+3 12 Q
+(\245) 152.1 233.33 T
+3 10 Q
+(Many widgets have been improved. For example, buttons and labels can display multi-) 162.9 233.33 T
+(line justi\336ed text, and scales can handle real values.) 162.9 221.33 T
+(The bad news about Tk 4.0 is that it contains several incompatibilities with Tk 3.6.) 170.1 206.33 T
+(Ever since the \336rst release of Tk I have assumed that there would eventually be a major) 152.1 194.33 T
+(new release of Tk with substantial incompatibilities. I knew that I wouldn\325) 152.1 182.33 T
+(t be able to get) 450.06 182.33 T
+(all of the features of Tk right the \336rst time; rather than live forever with all of my early) 152.1 170.33 T
+(mistakes, I wanted to have a chance to correct them. Tk 4.0 is that correction. I apologize) 152.1 158.33 T
+-0.05 (for the incompatibilities, but I hope they improve Tk enough to justify the dif) 152.1 146.33 P
+-0.05 (\336culties you) 460.55 146.33 P
+44.1 351 98.1 423 C
+35.1 360 197.1 414 R
+7 X
+0 K
+V
+1 9 Q
+0 X
+(FIGURE 1) 35.1 408 T
+(T) 35.1 387 T
+(ABLE 1) 40.43 387 T
+26.1 351 125.1 423 R
+7 X
+V
+40.5 63 571.5 729 C
+FMENDPAGE
+%%EndPage: "1" 2
+%%Page: "2" 2
+612 792 0 FMBEGINPAGE
+0 10 Q
+0 X
+0 K
+(2) 98.1 668.33 T
+4 F
+(Tk4.0 Overview and Porting Guide) 359.34 668.33 T
+98.1 660.6 512.1 660.6 2 L
+0.25 H
+0 Z
+N
+98.1 135 512.1 639 R
+7 X
+V
+3 F
+0 X
+(encounter during porting. Tk 4.0 is a one-time correction: we will try very hard to avoid) 152.1 632.33 T
+(substantial incompatibilities \050especially in Tk\325) 152.1 620.3 T
+(s T) 337 620.3 T
+(cl-level interfaces\051 in future releases.) 348.79 620.3 T
+-0.4 (Sections 1-1) 170.1 608.3 P
+-0.4 (1 cover the major areas of change in Tk 4.0: bindings, focus, text widgets,) 219.02 608.3 P
+-0 (Motif compliance, other widget changes, images, color management, event handling, sup-) 152.1 596.26 P
+(port for multiple displays, the) 152.1 584.23 T
+5 F
+(send) 273.14 584.23 T
+3 F
+( command, and the selection. Section 12 summarizes) 297.13 584.23 T
+(several smaller changes. Section 13 lists all of the incompatibilities that af) 152.1 572.19 T
+(fect T) 448.4 572.19 T
+(cl scripts,) 471.29 572.19 T
+-0.02 (along with suggestions for how to deal with them. The explanations here are not intended) 152.1 560.16 P
+(to be comprehensive, but rather to introduce you to the issues; for complete information) 152.1 548.12 T
+(on new or modi\336ed commands, refer to the reference documentation that comes with the) 152.1 536.09 T
+(distribution.) 152.1 524.05 T
+98.1 480.7 512.1 483.72 C
+152.1 481.92 512.1 481.92 2 L
+0.5 H
+2 Z
+0 X
+0 K
+N
+98.1 482.21 143.1 482.21 2 L
+0 Z
+N
+40.5 63 571.5 729 C
+0 12 Q
+0 X
+0 K
+(1) 134.63 487.72 T
+(Bindings) 152.1 487.72 T
+3 10 Q
+-0.35 (The changes for Tk 4.0 that are most likely to af) 152.1 464.03 P
+-0.35 (fect existing T) 341.31 464.03 P
+-0.35 (cl scripts are those related to) 397.64 464.03 P
+(bindings. The new binding mechanism in Tk 4.0 is much more powerful than that of Tk) 152.1 452 T
+(3.6, particularly in the way it allows behaviors to be combined, but several incompatible) 152.1 439.96 T
+(changes were required to implement the new features. These changes are likely to break) 152.1 427.93 T
+(most Tk 3.6 scripts. Fortunately) 152.1 415.89 T
+(, it is relatively easy to upgrade your bindings to work) 279.16 415.89 T
+(under Tk 4.0.) 152.1 403.86 T
+-0.27 (The basic mechanism for bindings is the same as in Tk 3.6. A binding associates a T) 170.1 391.86 P
+-0.27 (cl) 502.65 391.86 P
+(script with a particular event \050or sequence of events\051 occurring in one or more windows;) 152.1 379.82 T
+-0.11 (the script will be invoked automatically whenever the event sequence occurs in any of the) 152.1 367.79 P
+-0.13 (speci\336ed windows. The Tk 4.0 binding mechanism has three major feature changes. First,) 152.1 355.75 P
+(there is a more general mechanism for specifying the relationship between windows and) 152.1 343.72 T
+(bindings, called) 152.1 331.68 T
+2 F
+(binding tags) 217.89 331.68 T
+3 F
+(. Second, the con\337ict resolution mechanism \050which is) 267.6 331.68 T
+(invoked when more than one binding matches an event\051 has been changed to allow more) 152.1 319.65 T
+(than one binding script to execute for a single event. Third, the) 152.1 307.61 T
+5 F
+(Any) 405.81 307.61 T
+3 F
+( modi\336er is now) 423.8 307.61 T
+(implicit in all binding patterns. These changes are discussed separately in the subsections) 152.1 295.58 T
+(that follow) 152.1 283.54 T
+(.) 195.04 283.54 T
+-0.16 (Overall, the main ef) 170.1 271.54 P
+-0.16 (fect of Tk 4.0\325) 249.37 271.54 P
+-0.16 (s binding changes is that it allows more bindings to) 306.06 271.54 P
+(trigger than Tk 3.6 does. Feedback from the T) 152.1 259.51 T
+(cl/Tk community about the Tk 3.6 binding) 335.71 259.51 T
+(mechanism indicated that it was too conservative about triggering bindings. This caused) 152.1 247.47 T
+(the system to lose behaviors relatively easily and made the binding structure fragile. It) 152.1 235.44 T
+-0.35 (appears to be easier to deal with too many binding invocations than too few) 152.1 223.4 P
+-0.35 (, so Tk 4.0 tries) 449.17 223.4 P
+(to err in this direction.) 152.1 211.37 T
+0 F
+(1.1) 127.41 181.37 T
+(Binding tags) 152.1 181.37 T
+3 F
+(In Tk 3.6 you specify the window\050s\051 for a binding in one of three ways:) 152.1 165.37 T
+3 12 Q
+(\245) 152.1 150.37 T
+3 10 Q
+(Y) 162.9 150.37 T
+(ou give the name of a window) 169.12 150.37 T
+(, such as) 289.49 150.37 T
+5 F
+(.a.b.c) 326.13 150.37 T
+3 F
+(, in which case the binding applies) 362.11 150.37 T
+(only to that window) 162.9 138.33 T
+(.) 242.49 138.33 T
+FMENDPAGE
+%%EndPage: "2" 3
+%%Page: "3" 3
+612 792 0 FMBEGINPAGE
+4 10 Q
+0 X
+0 K
+(1 Bindings) 98.1 668.33 T
+0 F
+(3) 506.54 668.33 T
+98.1 660.6 512.1 660.6 2 L
+0.25 H
+0 Z
+N
+98.1 135 512.1 639 R
+7 X
+V
+3 12 Q
+0 X
+(\245) 152.1 632.33 T
+3 10 Q
+-0.06 (Y) 162.9 632.33 P
+-0.06 (ou give the name of a class, such as) 169.12 632.33 P
+5 F
+-0.15 (Button) 313.45 632.33 P
+3 F
+-0.06 (, in which case the binding applies to all) 349.43 632.33 P
+(the windows of that class.) 162.9 620.33 T
+3 12 Q
+(\245) 152.1 605.33 T
+3 10 Q
+(Y) 162.9 605.33 T
+(ou specify) 169.12 605.33 T
+5 F
+(all) 212.97 605.33 T
+3 F
+(, in which case the binding applies to all windows.) 230.96 605.33 T
+-0.3 (In Tk4.0 you specify the window\050s\051 using a more general mechanism called a) 170.1 590.33 P
+2 F
+-0.3 (binding) 479.35 590.33 P
+(tag) 152.1 578.33 T
+3 F
+(. A binding tag may be an arbitrary string, but if it starts with a \322.\323 then it must be the) 164.87 578.33 T
+(name of a window) 152.1 566.33 T
+(. If you specify a class name or) 225.56 566.33 T
+5 F
+(all) 352.4 566.33 T
+3 F
+( as a binding tag, it will usually) 370.39 566.33 T
+-0.1 (have the same ef) 152.1 554.33 P
+-0.1 (fect as in Tk 3.6, but you may also specify other strings that were not per-) 218.51 554.33 P
+(mitted in Tk 3.6.) 152.1 542.33 T
+-0.07 (Each window in Tk 4.0 has a list of binding tags. When an event occurs in a window) 170.1 530.33 P
+-0.07 (,) 507.17 530.33 P
+-0.19 (Tk fetches the window\325) 152.1 518.33 P
+-0.19 (s binding tags and matches the event against all of the bindings for) 245.62 518.33 P
+-0.09 (any of the tags. By default, the binding tags for a window consist of the window name, its) 152.1 506.33 P
+-0.14 (class name, the name of its nearest toplevel ancestor) 152.1 494.33 P
+-0.14 (, and) 359.61 494.33 P
+5 F
+-0.33 (all) 381.26 494.33 P
+3 F
+-0.14 (. For example, a button win-) 399.25 494.33 P
+(dow named) 152.1 482.33 T
+5 F
+(.b) 200.95 482.33 T
+3 F
+( will have the tags) 212.95 482.33 T
+5 9 Q
+(.b Button . all) 179.1 468 T
+3 10 Q
+(by default and all of the following bindings will apply to the window:) 152.1 454.33 T
+5 9 Q
+(bind .b <Enter> {identify "press here to exit"}) 179.1 440 T
+(bind Button <Button-Release-1> {%W invoke}) 179.1 430 T
+(bind all <Help> {help %W}) 179.1 420 T
+3 10 Q
+(So far) 152.1 406.33 T
+(, this mechanism produces the same behavior as in Tk 3.6 except that bindings cre-) 175.85 406.33 T
+(ated for a toplevel also apply to its descendants \050see Section 1.5 for more on this issue\051.) 152.1 394.33 T
+(Y) 170.1 382.33 T
+(ou can use the) 176.32 382.33 T
+5 F
+(bindtags) 235.71 382.33 T
+3 F
+( command to change the binding tags for a window or) 283.69 382.33 T
+(their order) 152.1 370.33 T
+(. For example, the command) 193.46 370.33 T
+5 9 Q
+(bindtags .b {.b MyButton all}) 179.1 356 T
+3 10 Q
+(will change the binding tags for) 152.1 342.33 T
+5 F
+(.b) 281.46 342.33 T
+3 F
+( to the three values in the list. This provides a simple) 293.45 342.33 T
+(way to make radical changes the behavior of a window) 152.1 330.33 T
+(. After the above command is) 371.55 330.33 T
+(invoked none of the) 152.1 318.33 T
+5 F
+(Button) 234.26 318.33 T
+3 F
+( class bindings will apply to) 270.24 318.33 T
+5 F
+(.b) 384.63 318.33 T
+3 F
+(. Instead, bindings for) 396.63 318.33 T
+5 F
+-0.81 (MyButton) 152.1 306.33 P
+3 F
+-0.34 ( will apply; this might give the button a totally dif) 200.07 306.33 P
+-0.34 (ferent set of behaviors than a) 395.88 306.33 P
+(normal button. In addition, the) 152.1 294.33 T
+5 F
+(bindtags) 276.75 294.33 T
+3 F
+( command removes the \322.\323 tag, so bindings on) 324.72 294.33 T
+(\322.\323 will not apply to) 152.1 282.33 T
+5 F
+(.b) 234.27 282.33 T
+3 F
+(.) 246.27 282.33 T
+(Y) 170.1 270.33 T
+(ou can also place additional tags on a window with the) 176.32 270.33 T
+5 F
+(bindtags) 397.55 270.33 T
+3 F
+( command to) 445.53 270.33 T
+(combine a number of behaviors. For example,) 152.1 258.33 T
+5 9 Q
+(bindtags .b {.b MyButton Button . all}) 179.1 244 T
+3 10 Q
+(gives) 152.1 230.33 T
+5 F
+(.b) 175.7 230.33 T
+3 F
+( the behaviors of) 187.69 230.33 T
+5 F
+(MyButton) 257.08 230.33 T
+3 F
+( bindings as well as those speci\336ed by) 305.06 230.33 T
+5 F
+(Button) 459.96 230.33 T
+3 F
+(bindings.) 152.1 218.33 T
+(Overall, binding tags are similar to the tag mechanisms already used internally by) 170.1 206.33 T
+(canvas and text widgets in Tk 3.6, except that binding tags apply to windows instead of) 152.1 194.33 T
+(graphical objects or textual characters.) 152.1 182.33 T
+FMENDPAGE
+%%EndPage: "3" 4
+%%Page: "4" 4
+612 792 0 FMBEGINPAGE
+0 10 Q
+0 X
+0 K
+(4) 98.1 668.33 T
+4 F
+(Tk4.0 Overview and Porting Guide) 359.34 668.33 T
+98.1 660.6 512.1 660.6 2 L
+0.25 H
+0 Z
+N
+98.1 135 512.1 639 R
+7 X
+V
+0 F
+0 X
+(1.2) 127.41 632.33 T
+(Con\337ict resolution) 152.1 632.33 T
+3 F
+(It is possible for several bindings to match a particular event. In Tk 3.6 at most one event) 152.1 616.33 T
+(is actually allowed to trigger: a set of con\337ict resolution rules determines the winner) 152.1 604.22 T
+(. In) 488.27 604.22 T
+(general, a more speci\336c binding takes precedence over a less speci\336c binding. For exam-) 152.1 592.11 T
+-0.27 (ple, any binding for a speci\336c widget takes precedence over any class or) 152.1 580 P
+5 F
+-0.66 (all) 439.96 580 P
+3 F
+-0.27 ( binding, and) 457.95 580 P
+(a binding on) 152.1 567.89 T
+5 F
+(<Control-a>) 204.57 567.89 T
+3 F
+( takes precedence over a binding on) 270.54 567.89 T
+5 F
+(<KeyPress>.) 416.24 567.89 T
+3 F
+-0.26 (The mechanism for con\337ict resolution is similar in Tk 4.0 except that one binding can) 170.1 555.89 P
+-0.35 (trigger for) 152.1 543.78 P
+2 F
+-0.35 (each) 194.7 543.78 P
+3 F
+-0.35 ( binding tag on the window where the event occurs. The bindings trigger in) 213.57 543.78 P
+(the order of the tags. Thus if button) 152.1 531.67 T
+5 F
+(.b) 296.17 531.67 T
+3 F
+( has the default binding tags, one binding for) 308.16 531.67 T
+5 F
+(.b) 489.71 531.67 T
+3 F
+(can trigger) 152.1 519.56 T
+(, followed by one for) 194.72 519.56 T
+5 F
+(Button) 281.32 519.56 T
+3 F
+(, followed by one for \322) 317.3 519.56 T
+5 F
+(.) 408.34 519.56 T
+3 F
+(\323, followed by one for) 414.34 519.56 T
+5 F
+(all) 152.1 507.44 T
+3 F
+(. If there are no matching bindings for a given tag then none will trigger) 170.09 507.44 T
+(, and if there) 456.98 507.44 T
+(are several matching bindings for a given tag then a single one is chosen using the same) 152.1 495.33 T
+(rules as in Tk 3.6.) 152.1 483.22 T
+(The philosophy behind binding tags in Tk 4.0 is that each binding tag corresponds to) 170.1 471.22 T
+(an independent behavior) 152.1 459.11 T
+(, so bindings with dif) 249.96 459.11 T
+(ferent tags should usually be additive. Sup-) 334.46 459.11 T
+(pose you de\336ned the following binding:) 152.1 447 T
+5 9 Q
+(bind .b <Enter> {puts "press here to exit"}) 179.1 432.67 T
+3 10 Q
+(This binding will add to the behavior de\336ned by the Button class binding for) 152.1 419 T
+5 F
+(<Enter>) 460.81 419 T
+3 F
+(.) 502.79 419 T
+(In Tk 3.6, the widget-speci\336c binding will replace the class binding, which will break the) 152.1 406.89 T
+(behavior of the button so that it no longer has normal button behavior) 152.1 394.78 T
+(.) 429.71 394.78 T
+(Sometimes there need to be interactions between binding tags. For example, you) 170.1 382.78 T
+(might wish to keep most of the default button behavior for) 152.1 370.67 T
+5 F
+(.b) 388.34 370.67 T
+3 F
+( but replace the default) 400.33 370.67 T
+(behavior for) 152.1 358.56 T
+5 F
+(<ButtonRelease>) 203.72 358.56 T
+3 F
+( with some other behavior) 293.67 358.56 T
+(. T) 397.49 358.56 T
+(o allow bindings to be) 407.9 358.56 T
+-0.17 (overridden, Tk 4.0 allows the) 152.1 346.44 P
+5 F
+-0.41 (break) 271.44 346.44 P
+3 F
+-0.17 ( command to be invoked from inside a binding. This) 301.43 346.44 P
+(causes all remaining binding tags for that binding to be skipped. Consider the following) 152.1 334.33 T
+(binding:) 152.1 322.22 T
+5 9 Q
+(bind .b <ButtonRelease-1> {myRelease .b; break}) 179.1 307.89 T
+3 10 Q
+-0.21 (This will cause the) 152.1 294.22 P
+5 F
+-0.5 (myRelease) 228.99 294.22 P
+3 F
+-0.21 ( procedure to be invoked, then the) 282.96 294.22 P
+5 F
+-0.5 (break) 420.28 294.22 P
+3 F
+-0.21 ( command will) 450.26 294.22 P
+-0.37 (cause the class binding for the event to be skipped \050assuming that the widget name appears) 152.1 282.11 P
+(before its class in the binding tags for) 152.1 270 T
+5 F
+(.b) 304.78 270 T
+3 F
+(\051, along with any bindings for other tags.) 316.77 270 T
+2 F
+(Note:) 119.09 254 T
+-0.07 (Y) 152.1 254 P
+-0.07 (ou cannot invoke) 156.74 254 P
+6 F
+-0.17 (break) 227.31 254 P
+2 F
+-0.07 ( fr) 257.29 254 P
+-0.07 (om within the) 266.02 254 P
+6 F
+-0.17 (myRelease) 322.73 254 P
+2 F
+-0.07 ( pr) 376.7 254 P
+-0.07 (ocedur) 387.64 254 P
+-0.07 (e in the above example:) 415.03 254 P
+-0.02 (this will generate a T) 152.1 242.89 P
+-0.02 (cl err) 236.05 242.89 P
+-0.02 (or) 257.59 242.89 P
+-0.02 (. However) 265.37 242.89 P
+-0.02 (, you can invoke the command \322) 305.31 242.89 P
+6 F
+-0.05 (return -code) 434.25 242.89 P
+(break) 152.1 231.78 T
+2 F
+(\323 in the pr) 182.08 231.78 T
+(ocedur) 223.64 231.78 T
+(e to achieve the same effect as the) 251.03 231.78 T
+6 F
+(break) 389.25 231.78 T
+2 F
+( in the binding script.) 419.23 231.78 T
+0 F
+(1.3) 127.41 202.78 T
+(Implicit Any) 152.1 202.78 T
+3 F
+-0.13 (In Tk 3.6 extraneous modi\336ers prevent a binding from matching an event. For example, if) 152.1 186.78 P
+(a binding is de\336ned for) 152.1 174.67 T
+5 F
+(<Button-1>) 247.32 174.67 T
+3 F
+( and the mouse button is pressed with the) 307.29 174.67 T
+5 F
+(Num-) 474.68 174.67 T
+(Lock) 152.1 162.56 T
+3 F
+( key down, then the binding will not match. If you want a binding to trigger even) 176.09 162.56 T
+(when extraneous modi\336ers are present, you must specify the) 152.1 150.45 T
+5 F
+(Any) 396.37 150.45 T
+3 F
+( modi\336er) 414.36 150.45 T
+(, as in) 450.33 150.45 T
+5 F
+(<Any-) 476.42 150.45 T
+(Button-1>) 152.1 138.33 T
+3 F
+(.) 206.07 138.33 T
+FMENDPAGE
+%%EndPage: "4" 5
+%%Page: "5" 5
+612 792 0 FMBEGINPAGE
+4 10 Q
+0 X
+0 K
+(1 Bindings) 98.1 668.33 T
+0 F
+(5) 506.54 668.33 T
+98.1 660.6 512.1 660.6 2 L
+0.25 H
+0 Z
+N
+98.1 135 512.1 639 R
+7 X
+V
+3 F
+0 X
+-0.06 (In Tk 4.0, all bindings have the) 170.1 632.33 P
+5 F
+-0.15 (Any) 297.08 632.33 P
+3 F
+-0.06 ( modi\336er present implicitly) 315.08 632.33 P
+-0.06 (. The) 423.35 632.33 P
+5 F
+-0.15 (Any) 446.26 632.33 P
+3 F
+-0.06 ( modi\336er is) 464.25 632.33 P
+(still allowed for compatibility) 152.1 620.33 T
+(, but it has no meaning. Thus a binding for) 270.55 620.33 T
+5 F
+(<Button-1>) 443.23 620.33 T
+3 F
+(will match a button press event even if) 152.1 608.33 T
+5 F
+(NumLock) 309.21 608.33 T
+3 F
+(,) 351.19 608.33 T
+5 F
+(Shift) 356.19 608.33 T
+3 F
+(,) 386.17 608.33 T
+5 F
+(Control) 391.17 608.33 T
+3 F
+(, or any combina-) 433.15 608.33 T
+(tion of them. If you wish for a binding not to trigger when a modi\336er is present, you can) 152.1 596.33 T
+(just de\336ne an empty binding for that modi\336er combination. For example,) 152.1 584.33 T
+5 9 Q
+(bind .b <Control-ButtonPress-1> {# this script is a no-op}) 179.1 570 T
+3 10 Q
+(creates a binding that will trigger on mouse button presses when the) 152.1 556.33 T
+5 F
+(Control) 426.36 556.33 T
+3 F
+( key is) 468.34 556.33 T
+-0.22 (down. If there is also a) 152.1 544.33 P
+5 F
+-0.52 (<ButtonPress-1>) 244.35 544.33 P
+3 F
+-0.22 ( binding for) 334.3 544.33 P
+5 F
+-0.52 (.b) 383.35 544.33 P
+3 F
+-0.22 (, it will no longer be invoked) 395.34 544.33 P
+-0.02 (if the) 152.1 532.33 P
+5 F
+-0.05 (Control) 175.37 532.33 P
+3 F
+-0.02 ( key is down, due to the con\337ict resolution rules. The script for the above) 217.35 532.33 P
+(binding is just a T) 152.1 520.33 T
+(cl comment, so it has no ef) 223.59 520.33 T
+(fect when it is invoked. Alternatively) 330.84 520.33 T
+(, you) 478.98 520.33 T
+(could use) 152.1 508.33 T
+5 F
+(%s) 192.63 508.33 T
+3 F
+( in the binding script to extract the modi\336er state, then test to see that only) 204.62 508.33 T
+(desired modi\336ers are present.) 152.1 496.33 T
+0 F
+(1.4) 127.41 466.33 T
+(Porting problems: widget bindings vs. class bindings) 152.1 466.33 T
+3 F
+-0.38 (Y) 152.1 450.33 P
+-0.38 (ou are likely to encounter two problems with bindings when you port Tk 3.6 scripts to Tk) 158.32 450.33 P
+-0.18 (4.0: widget bindings vs. class bindings, and events on top-level windows. This section dis-) 152.1 438.33 P
+(cusses the \336rst problem and the following section discusses the second problem.) 152.1 426.33 T
+(In Tk 3.6, if a widget-speci\336c binding matches an event then no class binding will) 170.1 414.33 T
+-0.15 (trigger for the event; in Tk 4.0 both bindings will trigger) 152.1 402.33 P
+-0.15 (. Because of this change, you will) 375.75 402.33 P
+-0.09 (need to modify most of your widget-speci\336c bindings in one of two ways. If a widget-spe-) 152.1 390.33 P
+(ci\336c binding in Tk 3.6 was intended to supplement the class binding, this could only be) 152.1 378.33 T
+(done by duplicating the code of the class binding in the widget binding script. This dupli-) 152.1 366.33 T
+-0.02 (cated code is no longer necessary in Tk 4.0 and will probably interfere with the new class) 152.1 354.33 P
+(bindings in Tk 4.0; you should remove the duplicated class code, leaving only the widget-) 152.1 342.33 T
+(speci\336c code in the binding script. If a widget-speci\336c binding in Tk 3.6 was intended to) 152.1 330.33 T
+-0.17 (override the class binding, this will no longer occur by default in Tk 4.0; you should add a) 152.1 318.33 P
+5 F
+-0.54 (break) 152.1 306.33 P
+3 F
+-0.22 ( command at the end of the binding script to prevent the class binding from trigger-) 182.08 306.33 P
+(ing. If a widget binding in Tk 3.6 didn\325) 152.1 294.33 T
+(t con\337ict with a class binding, then you will not) 308.49 294.33 T
+(need to modify it for Tk 4.0. For example, a widget binding for) 152.1 282.33 T
+5 F
+(<Help>) 407.49 282.33 T
+3 F
+( in a text widget) 443.47 282.33 T
+(would not need to be modi\336ed, since it doesn\325) 152.1 270.33 T
+(t con\337ict with a class binding.) 336.53 270.33 T
+0 F
+(1.5) 127.41 240.33 T
+(Porting problems: events on top-levels) 152.1 240.33 T
+3 F
+-0.26 (The second binding problem you are likely to encounter in porting Tk 3.6 scripts to Tk 4.0) 152.1 224.33 P
+(is that in Tk 4.0 a binding on a toplevel will match events on any of the internal windows) 152.1 212.33 T
+(within that top-level. For example, suppose you have a binding created as follows:) 152.1 200.33 T
+5 9 Q
+(toplevel .t) 179.1 186 T
+(button .t.b1 ...) 179.1 176 T
+(button .t.b2 ...) 179.1 166 T
+(bind .t <Enter> action) 179.1 156 T
+FMENDPAGE
+%%EndPage: "5" 6
+%%Page: "6" 6
+612 792 0 FMBEGINPAGE
+0 10 Q
+0 X
+0 K
+(6) 98.1 668.33 T
+4 F
+(Tk4.0 Overview and Porting Guide) 359.34 668.33 T
+98.1 660.6 512.1 660.6 2 L
+0.25 H
+0 Z
+N
+98.1 135 512.1 639 R
+7 X
+V
+3 F
+0 X
+-0.27 (This binding will trigger not only when the mouse enters) 152.1 632.33 P
+5 F
+-0.64 (.t) 379.29 632.33 P
+3 F
+-0.27 (, but also when it enters either) 391.28 632.33 P
+5 F
+(.t.b1) 152.1 620.33 T
+3 F
+( or) 182.08 620.33 T
+5 F
+(.t.b2) 195.41 620.33 T
+3 F
+(. This is because the binding tags for a window include its nearest) 225.39 620.33 T
+(ancestor toplevel by default. The toplevel is present in the binding tags to make it easy to) 152.1 608.33 T
+(set up accelerator keys that apply in all the windows of a panel. For example,) 152.1 596.33 T
+5 9 Q
+(bind .t <Control-a> {controlAProc %W}) 179.1 582 T
+3 10 Q
+(will cause) 152.1 568.33 T
+5 F
+(controlAProc) 194.85 568.33 T
+3 F
+( to be invoked whenever) 266.81 568.33 T
+5 F
+(Control-a) 367.56 568.33 T
+3 F
+( is typed in any of the) 421.53 568.33 T
+-0.12 (windows in) 152.1 556.33 P
+5 F
+-0.29 (.t) 200.72 556.33 P
+3 F
+-0.12 (. The procedure will receive the name of the focus window as its ar) 212.71 556.33 P
+-0.12 (gument.) 479.62 556.33 P
+(Unfortunately) 170.1 544.33 T
+(, if you have created bindings on toplevel windows in your Tk 3.6) 225.52 544.33 T
+-0.16 (scripts, they probably expect to trigger only for events in the toplevel, so the bindings will) 152.1 532.33 P
+(misbehave under Tk 4.0. Fortunately you can reproduce the behavior of Tk 3.6 by using) 152.1 520.33 T
+(the) 152.1 508.33 T
+5 F
+(%W) 166.81 508.33 T
+3 F
+( substitution in the binding script. For example, to ensure that) 178.8 508.33 T
+5 F
+(action) 427.28 508.33 T
+3 F
+( is invoked) 463.26 508.33 T
+(only for) 152.1 496.33 T
+5 F
+(Enter) 186.52 496.33 T
+3 F
+( events in a toplevel window itself, create the following binding in place) 216.51 496.33 T
+(of the one above:) 152.1 484.33 T
+5 9 Q
+(bind .t <Enter> {) 179.1 470 T
+(if {"%W" == ".t"} {) 200.63 460 T
+(action) 222.23 450 T
+(}) 200.63 440 T
+(}) 179.1 430 T
+3 10 Q
+-0.01 (When an) 152.1 416.33 P
+5 F
+-0.03 (Enter) 190.38 416.33 P
+3 F
+-0.01 ( event occurs in a descendant of) 220.36 416.33 P
+5 F
+-0.03 (.t) 350.45 416.33 P
+3 F
+-0.01 ( such as) 362.45 416.33 P
+5 F
+-0.03 (.t.x) 396.56 416.33 P
+3 F
+-0.01 (, a binding for) 420.54 416.33 P
+5 F
+-0.03 (Enter) 479.63 416.33 P
+3 F
+(in) 152.1 404.33 T
+5 F
+(.t.x) 162.37 404.33 T
+3 F
+( will trigger \336rst, if there is one. Then the above binding will trigger) 186.36 404.33 T
+(. Since) 457.58 404.33 T
+5 F
+(%W) 487.29 404.33 T
+3 F
+(will be substituted with) 152.1 392.33 T
+5 F
+(.t.x) 248.17 392.33 T
+3 F
+(, the) 272.15 392.33 T
+5 F
+(if) 291.86 392.33 T
+3 F
+( condition will not be satis\336ed and the binding will) 303.86 392.33 T
+(not do anything.) 152.1 380.33 T
+-0.14 ( An alternative solution is to remove the toplevel window from the binding tags of all) 170.1 368.33 P
+-0.12 (its internal windows. However) 152.1 356.33 P
+-0.12 (, this means that you won\325) 274.03 356.33 P
+-0.12 (t be able to take advantage of the) 378.73 356.33 P
+(tag to create key bindings that apply everywhere within the toplevel.) 152.1 344.33 T
+0 F
+(1.6) 127.41 314.33 T
+(Internal bindings in canvases and texts) 152.1 314.33 T
+3 F
+(The same changes in con\337ict resolution described in Section 1.2 also apply to bindings) 152.1 298.33 T
+-0.05 (created internally for the items of a canvas or the tags of a text widget. If a canvas item or) 152.1 286.33 P
+-0.29 (character of text has multiple tags, then one binding can trigger for each tag on each event.) 152.1 274.33 P
+-0.32 (The bindings trigger in the priority order of the tags. Similar porting problems are likely to) 152.1 262.33 P
+-0.19 (occur as described in Section 1.4; if a binding for one tag needs to override that of another) 152.1 250.33 P
+(tag, you\325ll need to add a) 152.1 238.33 T
+5 F
+(break) 251.2 238.33 T
+3 F
+( command under Tk 4.0; if a binding for one tag dupli-) 281.18 238.33 T
+-0.28 (cated the code from another tag\325) 152.1 226.33 P
+-0.28 (s binding, so that they will compose in Tk 3.6, you\325ll have) 279.76 226.33 P
+(to remove the duplicated code in Tk 4.0.) 152.1 214.33 T
+FMENDPAGE
+%%EndPage: "6" 7
+%%Page: "7" 7
+612 792 0 FMBEGINPAGE
+4 10 Q
+0 X
+0 K
+(2 Focus management) 98.1 668.33 T
+0 F
+(7) 506.54 668.33 T
+98.1 660.6 512.1 660.6 2 L
+0.25 H
+0 Z
+N
+98.1 135 512.1 639 R
+7 X
+V
+98.1 623.98 512.1 627 C
+152.1 625.2 512.1 625.2 2 L
+0.5 H
+2 Z
+0 X
+0 K
+N
+98.1 625.49 143.1 625.49 2 L
+0 Z
+N
+40.5 63 571.5 729 C
+0 12 Q
+0 X
+0 K
+(2) 134.63 631 T
+(Focus management) 152.1 631 T
+3 10 Q
+(The input focus is another area where Tk 4.0 contains major changes. Fortunately) 152.1 607.31 T
+(, the) 477.87 607.31 T
+-0.09 (focus changes should not require as many modi\336cations to your Tk 3.6 scripts as the bind-) 152.1 595.31 P
+(ing changes.) 152.1 583.31 T
+0 F
+(2.1) 127.41 553.31 T
+(One focus window per toplevel) 152.1 553.31 T
+3 F
+(Tk 3.6 only keeps track of a single focus window for each application, and this results in) 152.1 537.31 T
+(two problems. First, it doesn\325) 152.1 525.31 T
+(t allow an application to use multiple displays since this) 269.64 525.31 T
+-0.16 (could result in multiple simultaneous focus windows, one on each display) 152.1 513.31 P
+-0.16 (. Second, the Tk) 444.99 513.31 P
+(3.6 model doesn\325) 152.1 501.31 T
+(t work very well for applications that have multiple toplevels: when the) 221.04 501.31 T
+(mouse moves from one toplevel to another) 152.1 489.31 T
+(, the focus window should switch to whatever) 322.7 489.31 T
+-0.24 (window had the focus the last time the mouse was in the new toplevel, but Tk 3.6 does not) 152.1 477.31 P
+(remember this information.) 152.1 465.31 T
+(Tk 4.0 corrects both of these problems. It remembers one focus window for each) 170.1 453.31 T
+(toplevel, which can be queried with the) 152.1 441.31 T
+5 F
+(focus -lastfor) 311.98 441.31 T
+3 F
+( command. When the win-) 395.94 441.31 T
+(dow manager gives the focus to a toplevel window \050because the mouse entered the win-) 152.1 429.31 T
+(dow or because you clicked on the window) 152.1 417.31 T
+(, depending on the focus model being used by) 324.38 417.31 T
+(the window manager\051, Tk passes the focus on to the remembered window) 152.1 405.31 T
+(. Several win-) 446.23 405.31 T
+(dows in an application can have the focus at the same time, one on each display the appli-) 152.1 393.31 T
+(cation is using. When asking for the current focus window in the) 152.1 381.31 T
+5 F
+(focus) 413.31 381.31 T
+3 F
+( command, you) 443.29 381.31 T
+(can use the) 152.1 369.31 T
+5 F
+(-displayof) 199 369.31 T
+3 F
+( switch to specify a particular display) 258.97 369.31 T
+(.) 407.66 369.31 T
+(When you set the focus to a window with the) 170.1 357.31 T
+5 F
+(focus) 353.31 357.31 T
+3 F
+( command, Tk remembers that) 383.29 357.31 T
+(window as the most recent focus window for its toplevel. In addition, if the application) 152.1 345.31 T
+(currently has the focus for the window\325) 152.1 333.31 T
+(s display) 309.2 333.31 T
+(, Tk moves the focus to the speci\336ed win-) 343.82 333.31 T
+-0.35 (dow; this can be used, for example to move the focus to a dialog when the dialog is posted,) 152.1 321.31 P
+(or to perform keyboard traversal among the toplevels of an application. If the application) 152.1 309.31 T
+(doesn\325) 152.1 297.31 T
+(t currently have the focus for the display) 178.57 297.31 T
+(, then Tk will not normally take the focus) 339.74 297.31 T
+(from its current owner) 152.1 285.31 T
+(. However) 241.2 285.31 T
+(, you can specify the) 282.43 285.31 T
+5 F
+(-force) 367.36 285.31 T
+3 F
+( ar) 403.34 285.31 T
+(gument to) 413.43 285.31 T
+5 F
+(focus) 456.18 285.31 T
+3 F
+( to) 486.17 285.31 T
+(insist that Tk grab the focus for this application \050in general this is probably not a good) 152.1 273.31 T
+(idea, since it may clash with the window manager) 152.1 261.31 T
+(\325) 352.05 261.31 T
+(s focus policy\051.) 354.83 261.31 T
+0 F
+(2.2) 127.41 231.31 T
+(Keyboard traversal) 152.1 231.31 T
+3 F
+-0.38 (Tk 4.0 has a much more complete implementation of keyboard traversal than Tk 3.6. In Tk) 152.1 215.31 P
+(3.6 there is built-in support only for keyboard traversal of menus. In Tk 4.0 keyboard tra-) 152.1 203.31 T
+(versal is implemented for all widgets. Y) 152.1 191.31 T
+(ou can type) 311.27 191.31 T
+5 F
+(Tab) 359.85 191.31 T
+3 F
+( to move the focus among the) 377.84 191.31 T
+-0.4 (windows within a toplevel and) 152.1 179.31 P
+5 F
+-0.95 (Shift+Tab) 275.31 179.31 P
+3 F
+-0.4 ( to move in the reverse direction. The order of) 329.28 179.31 P
+-0.11 (traversal is de\336ned by the stacking order of widgets, with the lowest widget \336rst in the tra-) 152.1 167.31 P
+(versal order) 152.1 155.31 T
+(. All Tk widgets now provide a) 199 155.31 T
+5 F
+(-takefocus) 326.14 155.31 T
+3 F
+( option, which determines) 386.11 155.31 T
+FMENDPAGE
+%%EndPage: "7" 8
+%%Page: "8" 8
+612 792 0 FMBEGINPAGE
+0 10 Q
+0 X
+0 K
+(8) 98.1 668.33 T
+4 F
+(Tk4.0 Overview and Porting Guide) 359.34 668.33 T
+98.1 660.6 512.1 660.6 2 L
+0.25 H
+0 Z
+N
+98.1 135 512.1 639 R
+7 X
+V
+3 F
+0 X
+(whether the window should accept the focus during traversal or be skipped. This option) 152.1 632.33 T
+(has several features; see the) 152.1 620.33 T
+5 F
+(options.n) 265.61 620.33 T
+3 F
+( manual entry for details.) 319.58 620.33 T
+(All of the Tk widgets provide a traversal highlight ring as required by Motif. The) 170.1 608.33 T
+(highlight ring turns dark when the widget has the input focus. Its size and colors are con-) 152.1 596.33 T
+(trolled by the) 152.1 584.33 T
+5 F
+(-highlightthickness) 207.9 584.33 T
+3 F
+(,) 321.84 584.33 T
+5 F
+(-highlightbackground) 326.83 584.33 T
+3 F
+(, and) 446.77 584.33 T
+5 F
+(-) 152.1 572.33 T
+(highlightcolor) 158.1 572.33 T
+3 F
+( options. Y) 242.05 572.33 T
+(ou may notice that widgets appear to have extra space) 285.2 572.33 T
+(around them in Tk 4.0; this is due to the traversal highlight ring, which is normally the) 152.1 560.33 T
+(same color as the background for widgets.) 152.1 548.33 T
+0 F
+(2.3) 127.41 518.33 T
+(Support for focus-follows-mouse) 152.1 518.33 T
+3 F
+(Both Tk 3.6 and Tk 4.0 use an) 152.1 502.33 T
+2 F
+(explicit focus model) 275.91 502.33 T
+3 F
+( within a toplevel. This means that) 355.86 502.33 T
+(moving the mouse among the windows of a toplevel does not normally move the focus;) 152.1 490.33 T
+-0.06 (you have to click or perform some other action \050such as pressing) 152.1 478.33 P
+5 F
+-0.15 (Tab) 412.26 478.33 P
+3 F
+-0.06 (\051 to move the focus.) 430.25 478.33 P
+(Tk 3.6 has no support for an) 152.1 466.33 T
+2 F
+(implicit focus model) 267.58 466.33 T
+3 F
+( where the window under the mouse) 348.64 466.33 T
+(always has the focus. In Tk 4.0 you can invoke the library procedure) 152.1 454.33 T
+5 F
+(tk_focusFol-) 428.83 454.33 T
+(lowsMouse) 152.1 442.33 T
+3 F
+( to switch to an implicit focus model; in this mode whenever the mouse) 206.07 442.33 T
+(enters a new window the focus will switch to that window) 152.1 430.33 T
+(.) 384.07 430.33 T
+0 F
+(2.4) 127.41 400.33 T
+(No default focus window) 152.1 400.33 T
+(, no \322none\323 focus.) 269.45 400.33 T
+3 F
+-0.16 (Tk 3.6 has the notion of a default focus window) 152.1 384.33 P
+-0.16 (, which receives the focus if the focus win-) 341.56 384.33 P
+(dow is deleted. It is also possible for an application to abandon the input focus by setting) 152.1 372.33 T
+(the focus to) 152.1 360.33 T
+5 F
+(none) 201.23 360.33 T
+3 F
+(. In Tk 4.0 both of these features have been eliminated. There is no) 225.22 360.33 T
+(default focus window) 152.1 348.33 T
+(, and the focus can never be explicitly abandoned. If the focus win-) 238.05 348.33 T
+(dow is destroyed, Tk resets the input focus to the toplevel containing the old focus win-) 152.1 336.33 T
+(dow) 152.1 324.33 T
+(. If the toplevel is destroyed, the window manager will reclaim the focus and move it) 168.66 324.33 T
+(elsewhere.) 152.1 312.33 T
+-0.18 (If you really want to abandon the focus in Tk 4.0 so that keyboard events are ignored,) 170.1 300.33 P
+(you can create a dummy window with no key bindings \050set its binding tags to an empty) 152.1 288.33 T
+(string to be sure\051, make sure that is never mapped, and give it the input focus.) 152.1 276.33 T
+0 F
+(2.5) 127.41 246.33 T
+(Better focus events) 152.1 246.33 T
+3 F
+-0.13 (Tk 3.6 has a quirky event model for) 152.1 230.33 P
+5 F
+-0.32 (FocusIn) 296.77 230.33 P
+3 F
+-0.13 ( and) 338.75 230.33 P
+5 F
+-0.32 (FocusOut) 357.92 230.33 P
+3 F
+-0.13 ( events: when the window) 405.89 230.33 P
+-0.23 (manager gives the focus to a toplevel, Tk generates a) 152.1 218.33 P
+5 F
+-0.55 (FocusIn) 364.36 218.33 P
+3 F
+-0.23 ( event for the toplevel and) 406.33 218.33 P
+(another) 152.1 206.33 T
+5 F
+(FocusIn) 184.57 206.33 T
+3 F
+( event for the focus window) 226.55 206.33 T
+(, but no events for any other windows.) 337.76 206.33 T
+(When the window manager moves the focus somewhere else,) 152.1 194.33 T
+5 F
+(FocusOut) 400.79 194.33 T
+3 F
+( events are gen-) 448.77 194.33 T
+-0 (erated for these same two windows. In Tk 4.0,) 152.1 182.33 P
+5 F
+-0 (FocusIn) 339.73 182.33 P
+3 F
+-0 ( and) 381.71 182.33 P
+5 F
+-0 (FocusOut) 401.13 182.33 P
+3 F
+-0 ( events are gen-) 449.11 182.33 P
+-0.26 (erated in the same way as) 152.1 170.33 P
+5 F
+-0.63 (Enter) 255.43 170.33 P
+3 F
+-0.26 ( and) 285.41 170.33 P
+5 F
+-0.63 (Leave) 304.31 170.33 P
+3 F
+-0.26 ( events: when the focus arrives, a) 334.29 170.33 P
+5 F
+-0.63 (FocusIn) 467.89 170.33 P
+3 F
+-0.05 (event is generated for each window from the toplevel down to the focus window) 152.1 158.33 P
+-0.05 (, with dif-) 472.5 158.33 P
+FMENDPAGE
+%%EndPage: "8" 9
+%%Page: "9" 9
+612 792 0 FMBEGINPAGE
+4 10 Q
+0 X
+0 K
+(3 T) 98.1 668.33 T
+(ext widgets) 111.43 668.33 T
+0 F
+(9) 506.54 668.33 T
+98.1 660.6 512.1 660.6 2 L
+0.25 H
+0 Z
+N
+98.1 135 512.1 639 R
+7 X
+V
+3 F
+0 X
+-0.33 (ferent detail \336elds for dif) 152.1 632.33 P
+-0.33 (ferent windows \050see Xlib documentation for information on these) 250.53 632.33 P
+(values\051. The reverse happens when the focus leaves a window) 152.1 620.33 T
+(.) 399.57 620.33 T
+0 F
+(2.6) 127.41 590.33 T
+(Porting issues) 152.1 590.33 T
+3 F
+(If you didn\325) 152.1 574.33 T
+(t have any special focus-related code in Tk 3.6, then you shouldn\325) 199.66 574.33 T
+(t need to) 462.9 574.33 T
+(make any changes for 4.0; things will just work better) 152.1 562.33 T
+(. If you wrote code in Tk 3.6 to get) 366.96 562.33 T
+(around the weaknesses with its focus mechanism, then you should remove most or all of) 152.1 550.33 T
+(that code. For example, if you implemented keyboard traversal yourself, or if you built) 152.1 538.33 T
+(your own mechanism to remember a separate focus window for each toplevel and give it) 152.1 526.33 T
+(the input focus whenever the toplevel gets the focus, you can simply remove this code,) 152.1 514.33 T
+-0.33 (since Tk 4.0 performs these functions for you. If you wrote code that depends on the weird) 152.1 502.33 P
+-0.03 (event model in Tk 3.6, that code will need to be rewritten for Tk 4.0. The Tk 4.0 model is) 152.1 490.33 P
+(general enough to duplicate any ef) 152.1 478.33 T
+(fects that were possible in Tk 3.6.) 289.86 478.33 T
+98.1 434.98 512.1 438 C
+152.1 436.2 512.1 436.2 2 L
+0.5 H
+2 Z
+0 X
+0 K
+N
+98.1 436.49 143.1 436.49 2 L
+0 Z
+N
+40.5 63 571.5 729 C
+0 12 Q
+0 X
+0 K
+(3) 134.63 442 T
+(T) 152.1 442 T
+(ext widgets) 158.54 442 T
+3 10 Q
+(T) 152.1 418.31 T
+(ext widgets have under) 157.51 418.31 T
+(gone a major overhaul for Tk 4.0 and they have improved in) 249.76 418.31 T
+(many ways. The changes to text widgets are almost entirely upward-compatible from Tk) 152.1 406.31 T
+(3.6.) 152.1 394.31 T
+0 F
+(3.1) 127.41 364.31 T
+(Embedded windows.) 152.1 364.31 T
+3 F
+(Tk 3.6 supported two kinds of annotations in texts: marks and tags. In Tk 4.0 a third kind) 152.1 348.31 T
+-0.04 (of annotation is available: an embedded window) 152.1 336.31 P
+-0.04 (. This allows you to embed other widgets) 344.99 336.31 P
+(inside a text widget, mixed in with the text. The text widget acts as a geometry manager) 152.1 324.31 T
+(for these windows, laying them out and wrapping them just as if each embedded window) 152.1 312.31 T
+(were a single character in the text. Y) 152.1 300.31 T
+(ou can even have texts with nothing in them but) 297.64 300.31 T
+(embedded windows. The) 152.1 288.31 T
+5 F
+(window) 254.8 288.31 T
+3 F
+( widget command for text widgets provides several) 290.78 288.31 T
+(options to manage embedded windows.) 152.1 276.31 T
+0 F
+(3.2) 127.41 246.31 T
+(More options for tags.) 152.1 246.31 T
+3 F
+(In Tk 4.0 tags support many new options providing additional control over how informa-) 152.1 230.31 T
+(tion is displayed. Here is a summary of the new options:) 152.1 218.31 T
+3 12 Q
+(\245) 152.1 203.31 T
+3 10 Q
+(Y) 162.9 203.31 T
+(ou can now specify tab stops with the) 169.12 203.31 T
+5 F
+(-tabs) 321.79 203.31 T
+3 F
+( option. Each tab stop can use left, cen-) 351.78 203.31 T
+(ter) 162.9 191.31 T
+(, right, or numeric justi\336cation. T) 173.04 191.31 T
+(ab stops can also be speci\336ed for the widget as a) 305.6 191.31 T
+(whole.) 162.9 179.31 T
+3 12 Q
+(\245) 152.1 164.31 T
+3 10 Q
+(Y) 162.9 164.31 T
+(ou can specify justi\336cation \050left, center or right\051 with the) 169.12 164.31 T
+5 F
+(-justify) 398.12 164.31 T
+3 F
+( option.) 446.09 164.31 T
+FMENDPAGE
+%%EndPage: "9" 10
+%%Page: "10" 10
+612 792 0 FMBEGINPAGE
+0 10 Q
+0 X
+0 K
+(10) 98.1 668.33 T
+4 F
+(Tk4.0 Overview and Porting Guide) 359.34 668.33 T
+98.1 660.6 512.1 660.6 2 L
+0.25 H
+0 Z
+N
+98.1 135 512.1 639 R
+7 X
+V
+3 12 Q
+0 X
+(\245) 152.1 632.33 T
+3 10 Q
+(Y) 162.9 632.33 T
+(ou can now specify line spacing with three options,) 169.12 632.33 T
+5 F
+(-spacing1) 376.75 632.33 T
+3 F
+(,) 430.72 632.33 T
+5 F
+(-spacing2) 435.72 632.33 T
+3 F
+(, and) 489.69 632.33 T
+5 F
+(-) 162.9 620.2 T
+(spacing3) 168.9 620.2 T
+3 F
+(, which control the spacing above a line, between wrapped lines, and) 216.87 620.2 T
+(below a line.) 162.9 608.06 T
+3 12 Q
+(\245) 152.1 593.06 T
+3 10 Q
+(Y) 162.9 593.06 T
+(ou can now specify mar) 169.12 593.06 T
+(gins with the) 264.41 593.06 T
+5 F
+(-lmargin1) 318.55 593.06 T
+3 F
+(,) 372.52 593.06 T
+5 F
+(-lmargin2) 377.52 593.06 T
+3 F
+(, and) 431.49 593.06 T
+5 F
+(-rmargin) 453.42 593.06 T
+3 F
+(options.) 162.9 580.92 T
+3 12 Q
+(\245) 152.1 565.92 T
+3 10 Q
+-0.25 (Y) 162.9 565.92 P
+-0.25 (ou can now adjust the vertical position of text \050e.g. for superscripts or subscripts\051 with) 169.12 565.92 P
+(the) 162.9 553.79 T
+5 F
+(-offset) 177.61 553.79 T
+3 F
+( option.) 219.59 553.79 T
+3 12 Q
+(\245) 152.1 538.79 T
+3 10 Q
+-0.03 (Y) 162.9 538.79 P
+-0.03 (ou can now specify the wrapping style \050word wrapping, character wrapping, or none\051) 169.12 538.79 P
+(with the) 162.9 526.65 T
+5 F
+(-wrap) 197.88 526.65 T
+3 F
+( option.) 227.86 526.65 T
+3 12 Q
+(\245) 152.1 511.65 T
+3 10 Q
+(Y) 162.9 511.65 T
+(ou can now request overstriking with the) 169.12 511.65 T
+5 F
+(-overstrike) 334.83 511.65 T
+3 F
+( option.) 400.8 511.65 T
+0 F
+(3.3) 127.41 481.65 T
+(Bindings) 152.1 481.65 T
+3 F
+-0.19 (The default bindings for text widgets have been completely rewritten in Tk 4.0. They now) 152.1 465.65 P
+(support almost all of the Motif behavior \050everything except add mode and secondary) 152.1 453.52 T
+-0.36 (selections\051. They also include a substantial subset of the Emacs bindings for cursor motion) 152.1 441.38 P
+(and basic editing. The) 152.1 429.24 T
+5 F
+(tk_strictMotif) 242.87 429.24 T
+3 F
+( variable disables the Emacs bindings.) 326.82 429.24 T
+0 F
+(3.4) 127.41 399.24 T
+(Miscellaneous new features) 152.1 399.24 T
+3 F
+(In addition to the major changes described above, text widgets also include the following) 152.1 383.24 T
+(new features:) 152.1 371.11 T
+1 F
+(Horizontal scr) 162.9 356.11 T
+(olling) 224.07 356.11 T
+3 F
+(. T) 247.95 356.11 T
+(ext widgets can now be scrolled horizontally as well as verti-) 258.36 356.11 T
+(cally) 162.9 343.97 T
+(, using the) 181.68 343.97 T
+5 F
+(-) 225.55 343.97 T
+(xscrollcommand) 231.54 343.97 T
+3 F
+( option and the) 315.5 343.97 T
+5 F
+(xview) 377.68 343.97 T
+3 F
+( widget command.) 407.67 343.97 T
+1 F
+(Sear) 162.9 328.97 T
+(ching) 182.15 328.97 T
+3 F
+(. T) 205.48 328.97 T
+(ext widgets have a new) 215.88 328.97 T
+5 F
+(search) 311.64 328.97 T
+3 F
+( widget command, which provides ef) 347.62 328.97 T
+(\336-) 495.67 328.97 T
+-0.19 (cient searching of text widgets using either exact matching, glob-style matching, or reg-) 162.9 316.83 P
+(ular expressions. Y) 162.9 304.7 T
+(ou can search forwards or backwards.) 238.79 304.7 T
+1 F
+(Mark gravity) 162.9 289.7 T
+3 F
+(. In Tk 3.6 marks always had \322right gravity\323, which means they stick to) 219.71 289.7 T
+(the character on the right side of the mark; if you insert at the position of a mark, the) 162.9 277.56 T
+-0.1 (new character goes before the mark. In Tk 4.0 you can specify whether marks have left) 162.9 265.42 P
+(or right gravity) 162.9 253.29 T
+(.) 222.77 253.29 T
+1 F
+(Scr) 162.9 238.29 T
+(een information) 177.15 238.29 T
+3 F
+(. In Tk 4.0 there are two new widget commands for text widgets) 245.16 238.29 T
+(that return information about the screen layout. The) 162.9 226.15 T
+5 F
+(dlineinfo) 371.92 226.15 T
+3 F
+( widget command) 425.89 226.15 T
+(returns the bounding box of a display line \050all the information displayed on one line of) 162.9 214.02 T
+(the window) 162.9 201.88 T
+(, which may be either a whole line of text or a partial line if wrapping has) 209.16 201.88 T
+(occurred\051. The) 162.9 189.74 T
+5 F
+(bbox) 224.23 189.74 T
+3 F
+( widget command returns the screen area occupied by a single) 248.21 189.74 T
+(character) 162.9 177.61 T
+(.) 198.97 177.61 T
+1 F
+(Extended insert command) 162.9 162.61 T
+3 F
+(. The) 275.06 162.61 T
+5 F
+(insert) 298.1 162.61 T
+3 F
+( widget command now supports an addi-) 334.08 162.61 T
+-0.32 (tional ar) 162.9 150.47 P
+-0.32 (gument giving a list of tags to apply to the new characters. Y) 195.43 150.47 P
+-0.32 (ou can also include) 434 150.47 P
+(several text and tag ar) 162.9 138.33 T
+(guments in a single) 250.42 138.33 T
+5 F
+(insert) 330.38 138.33 T
+3 F
+( command.) 366.36 138.33 T
+FMENDPAGE
+%%EndPage: "10" 11
+%%Page: "11" 11
+612 792 0 FMBEGINPAGE
+4 10 Q
+0 X
+0 K
+(4 Better Motif compliance) 98.1 668.33 T
+0 F
+(1) 501.54 668.33 T
+(1) 506.54 668.33 T
+98.1 660.6 512.1 660.6 2 L
+0.25 H
+0 Z
+N
+98.1 135 512.1 639 R
+7 X
+V
+1 F
+0 X
+(See command) 162.9 632.33 T
+3 F
+(. There is a new) 222.03 632.33 T
+5 F
+(see) 288.08 632.33 T
+3 F
+( widget command, which adjusts the view in the) 306.07 632.33 T
+(widget if needed to ensure that a particular character is visible in the window) 162.9 620.29 T
+(.) 470.07 620.29 T
+0 F
+(3.5) 127.41 590.29 T
+(Porting issues: tag stickiness, change in end) 152.1 590.29 T
+3 F
+(There are two changes in text widgets that may require modi\336cations to Tk 3.6 scripts.) 152.1 574.29 T
+-0.06 (The \336rst change has to do with tag stickiness. In Tk 3.6, tags are sticky to the right: if you) 152.1 562.24 P
+(insert new text just after a tagged range, the new text acquires the tags of the preceding) 152.1 550.19 T
+(character) 152.1 538.14 T
+(. If you insert text before a tagged range in Tk 3.6, the new characters do not) 188.17 538.14 T
+-0.34 (acquire the tags of the range. In Tk 4.0, tags are not sticky on either side: new text acquires) 152.1 526.09 P
+(a tag from surrounding characters only if the tag is present on both sides of the insertion) 152.1 514.05 T
+(position. The sticky behavior in Tk 3.6 was rarely useful and special code was often) 152.1 502 T
+(needed to work around it. Y) 152.1 489.95 T
+(ou should be able to eliminate this code in Tk 4.0.) 263.24 489.95 T
+(The second incompatible change in text widgets is that the index) 170.1 477.95 T
+5 F
+(end) 431.32 477.95 T
+3 F
+( now refers to) 449.31 477.95 T
+-0.14 (the position just after the \336nal newline in the text, whereas in Tk 3.6 it referred to the posi-) 152.1 465.9 P
+-0.1 (tion just before the \336nal newline. This makes it possible to apply tags to the \336nal newline,) 152.1 453.86 P
+(which was not possible in Tk 3.6, but you may need to modify your scripts if you depend) 152.1 441.81 T
+(on the old position of) 152.1 429.76 T
+5 F
+(end) 240.11 429.76 T
+3 F
+(.) 258.1 429.76 T
+98.1 386.4 512.1 389.43 C
+152.1 387.63 512.1 387.63 2 L
+0.5 H
+2 Z
+0 X
+0 K
+N
+98.1 387.92 143.1 387.92 2 L
+0 Z
+N
+40.5 63 571.5 729 C
+0 12 Q
+0 X
+0 K
+(4) 134.63 393.43 T
+(Better Motif compliance) 152.1 393.43 T
+3 10 Q
+(All of the widgets have been modi\336ed in Tk 4.0 to improve their Motif compliance. This) 152.1 369.74 T
+-0.3 (was done by adding features that were missing and reworking the bindings to comply with) 152.1 357.69 P
+(Motif conventions. I believe that the widgets are now completely Motif compliant except) 152.1 345.64 T
+(for the following missing features:) 152.1 333.6 T
+3 12 Q
+(\245) 152.1 318.6 T
+3 10 Q
+(There is no support for secondary selections.) 162.9 318.6 T
+3 12 Q
+(\245) 152.1 303.6 T
+3 10 Q
+(There is no support for \322add mode\323 in widgets such as texts and listboxes.) 162.9 303.6 T
+3 12 Q
+(\245) 152.1 288.6 T
+3 10 Q
+(There is no support for drag and drop.) 162.9 288.6 T
+-0.02 (Please let me know if you \336nd any other discrepancies between the Tk widgets and Motif) 152.1 273.59 P
+(widgets. W) 152.1 261.55 T
+(e plan to eliminate the remaining incompatibilities over the next year or two.) 196.82 261.55 T
+98.1 218.19 512.1 221.21 C
+152.1 219.41 512.1 219.41 2 L
+0.5 H
+2 Z
+0 X
+0 K
+N
+98.1 219.7 143.1 219.7 2 L
+0 Z
+N
+40.5 63 571.5 729 C
+0 12 Q
+0 X
+0 K
+(5) 134.63 225.21 T
+(W) 152.1 225.21 T
+(idget changes) 163.31 225.21 T
+3 10 Q
+-0.07 (All of the Tk 4.0 widgets have been improved over their 3.6 counterparts, mostly in small) 152.1 201.52 P
+-0.23 (and backwards compatible ways. Here is a summary of the widget improvements; see Sec-) 152.1 189.48 P
+(tion 13 for information about incompatible changes.) 152.1 177.43 T
+3 12 Q
+(\245) 152.1 162.43 T
+3 10 Q
+(All widgets now have a) 162.9 162.43 T
+5 F
+(cget) 259.78 162.43 T
+3 F
+( command, which provides an easier way to retrieve the) 283.76 162.43 T
+(value of a con\336guration option. In other situations where con\336guration options are) 162.9 150.38 T
+(used, such as for menu entries or text tags, a) 162.9 138.33 T
+5 F
+(cget) 342.21 138.33 T
+3 F
+( command is also available.) 366.2 138.33 T
+FMENDPAGE
+%%EndPage: "11" 12
+%%Page: "12" 12
+612 792 0 FMBEGINPAGE
+0 10 Q
+0 X
+0 K
+(12) 98.1 668.33 T
+4 F
+(Tk4.0 Overview and Porting Guide) 359.34 668.33 T
+98.1 660.6 512.1 660.6 2 L
+0.25 H
+0 Z
+N
+98.1 135 512.1 639 R
+7 X
+V
+3 12 Q
+0 X
+(\245) 152.1 632.33 T
+3 10 Q
+-0.22 (All widgets now have) 162.9 632.33 P
+5 F
+-0.53 (-highlightthickness) 251.96 632.33 P
+3 F
+-0.22 (,) 365.9 632.33 P
+5 F
+-0.53 (-highlightbackground) 370.68 632.33 P
+3 F
+-0.22 (, and) 490.61 632.33 P
+5 F
+(-) 162.9 620.33 T
+(highlightcolor) 168.9 620.33 T
+3 F
+( options for displaying a highlight ring when the widget \050or one) 252.85 620.33 T
+(of its descendants\051 has the input focus.) 162.9 608.33 T
+3 12 Q
+(\245) 152.1 593.33 T
+3 10 Q
+(Entry widgets now support justi\336cation and provide a) 162.9 593.33 T
+5 F
+(-show) 379.99 593.33 T
+3 F
+( option for \050not\051 display-) 409.97 593.33 T
+(ing passwords. They will autosize to \336t their text if) 162.9 581.33 T
+5 F
+(-width 0) 369.17 581.33 T
+3 F
+( is speci\336ed.) 417.14 581.33 T
+3 12 Q
+(\245) 152.1 566.33 T
+3 10 Q
+-0.16 (The label/button family of widgets now supports multiline text and justi\336cation, includ-) 162.9 566.33 P
+(ing new options) 162.9 554.33 T
+5 F
+(-wraplength) 229.25 554.33 T
+3 F
+( and) 295.22 554.33 T
+5 F
+(-justify) 314.65 554.33 T
+3 F
+(. These features make the message) 361.97 554.33 T
+-0.04 (widget obsolete. There is also a new) 162.9 542.33 P
+5 F
+-0.1 (-underline) 310.27 542.33 P
+3 F
+-0.04 ( option for highlighting a character) 370.23 542.33 P
+(for keyboard traversal.) 162.9 530.33 T
+3 12 Q
+(\245) 152.1 515.33 T
+3 10 Q
+-0.23 (Listboxes now support all of the Motif selection modes, including single selection, mul-) 162.9 515.33 P
+(tiple selection, and multiple disjoint selections, via the) 162.9 503.33 T
+5 F
+(-selectmode) 382.78 503.33 T
+3 F
+( option. They) 448.74 503.33 T
+(will autosize to \336t their contents if) 162.9 491.33 T
+5 F
+(-width 0) 302.54 491.33 T
+3 F
+( or) 350.52 491.33 T
+5 F
+(-height 0) 363.84 491.33 T
+3 F
+( is speci\336ed. There are) 417.81 491.33 T
+(new) 162.9 479.33 T
+5 F
+(see) 182.05 479.33 T
+3 F
+(,) 200.04 479.33 T
+5 F
+(bbox) 205.04 479.33 T
+3 F
+(, and) 229.02 479.33 T
+5 F
+(activate) 250.95 479.33 T
+3 F
+( widget commands.) 298.92 479.33 T
+3 12 Q
+(\245) 152.1 464.33 T
+3 10 Q
+(Canvas polygons now support) 162.9 464.33 T
+5 F
+(-outline) 286.16 464.33 T
+3 F
+( and) 334.14 464.33 T
+5 F
+(-width) 353.57 464.33 T
+3 F
+( options for drawing outlines.) 389.55 464.33 T
+3 12 Q
+(\245) 152.1 449.33 T
+3 10 Q
+-0.03 (Scale widgets now support real values as well as integers \050see the) 162.9 449.33 P
+5 F
+-0.08 (-resolution) 426.77 449.33 P
+3 F
+-0.03 ( and) 492.73 449.33 P
+5 F
+-0.54 (-digits) 162.9 437.33 P
+3 F
+-0.22 ( options\051, and they have a) 204.88 437.33 P
+5 F
+-0.54 (-variable) 308.73 437.33 P
+3 F
+-0.22 ( option to link to a T) 362.7 437.33 P
+-0.22 (cl variable. They) 442.83 437.33 P
+-0.28 (have two new widget commands,) 162.9 425.33 P
+5 F
+-0.67 (coords) 297.52 425.33 P
+3 F
+-0.28 ( and) 333.5 425.33 P
+5 F
+-0.67 (identify) 352.37 425.33 P
+3 F
+-0.28 (, and their bindings are now) 399.69 425.33 P
+(de\336ned in T) 162.9 413.33 T
+(cl rather than being hardwired in C code as in Tk 3.6.) 210.5 413.33 T
+3 12 Q
+(\245) 152.1 398.33 T
+3 10 Q
+(Scrollbar widgets now have a new interface to the controlling widget, which provides) 162.9 398.33 T
+-0.04 (more \337exibility than the old style \050but the old style is still supported for compatibility\051.) 162.9 386.33 P
+(There is a new option) 162.9 374.33 T
+5 F
+(-jump) 252 374.33 T
+3 F
+( to prevent continuous updates while dragging the slider) 281.98 374.33 T
+(,) 505.88 374.33 T
+-0.24 (and a new option) 162.9 362.33 P
+5 F
+-0.59 (-elementborderwidth) 232.98 362.33 P
+3 F
+-0.24 ( to control the border width of the arrows) 346.92 362.33 P
+(and slider separately from the widget\325) 162.9 350.33 T
+(s outer border) 314.18 350.33 T
+(. There are four new widget com-) 369.14 350.33 T
+(mands,) 162.9 338.33 T
+5 F
+(activate) 193.99 338.33 T
+3 F
+(,) 241.97 338.33 T
+5 F
+(delta) 246.96 338.33 T
+3 F
+(,) 276.95 338.33 T
+5 F
+(fraction) 281.95 338.33 T
+3 F
+(, and) 329.92 338.33 T
+5 F
+(identify) 351.85 338.33 T
+3 F
+(, and the default bindings) 399.17 338.33 T
+(are now de\336ned in T) 162.9 326.33 T
+(cl rather than being hardwired in C code as in Tk 3.6.) 244.91 326.33 T
+3 12 Q
+(\245) 152.1 311.33 T
+3 10 Q
+-0.13 (Menu entries now have several new con\336guration options such as) 162.9 311.33 P
+5 F
+-0.31 (-foreground) 426.97 311.33 P
+3 F
+-0.13 ( and) 492.93 311.33 P
+5 F
+-0.41 (-) 162.9 299.33 P
+-0.41 (indicatoron) 168.9 299.33 P
+3 F
+-0.17 (, and tear) 234.86 299.33 P
+-0.17 (-of) 271.23 299.33 P
+-0.17 (f menus have been reimplemented to be more Motif-like.) 282.7 299.33 P
+(New menu entries can be created in the middle of a menu using the) 162.9 287.33 T
+5 F
+(insert) 434.36 287.33 T
+3 F
+( widget) 470.34 287.33 T
+(command, and there is a) 162.9 275.33 T
+5 F
+(type) 262.83 275.33 T
+3 F
+( widget command that returns the type of a menu entry) 286.81 275.33 T
+(.) 505.45 275.33 T
+3 12 Q
+(\245) 152.1 260.33 T
+3 10 Q
+(Menubuttons now have a) 162.9 260.33 T
+5 F
+(-indicatoron) 266.16 260.33 T
+3 F
+( option for displaying an option menu indi-) 338.12 260.33 T
+-0.38 (cator) 162.9 248.33 P
+-0.38 (. There is now support for option menus via the) 182.33 248.33 P
+5 F
+-0.91 (tk_optionMenu) 370.9 248.33 P
+3 F
+-0.38 ( procedure, and) 448.86 248.33 P
+(popups are simpli\336ed with the) 162.9 236.33 T
+5 F
+(tk_popup) 286.44 236.33 T
+3 F
+( procedure.) 334.42 236.33 T
+3 12 Q
+(\245) 152.1 221.33 T
+3 10 Q
+-0.03 (The variable) 162.9 221.33 P
+5 F
+-0.07 (tk_strictMotif) 215.57 221.33 P
+3 F
+-0.03 ( is used in more places to enforce even stricter Motif) 299.53 221.33 P
+(compliance.) 162.9 209.33 T
+FMENDPAGE
+%%EndPage: "12" 13
+%%Page: "13" 13
+612 792 0 FMBEGINPAGE
+4 10 Q
+0 X
+0 K
+(6 Images) 98.1 668.33 T
+0 F
+(13) 500.99 668.33 T
+98.1 660.6 512.1 660.6 2 L
+0.25 H
+0 Z
+N
+98.1 135 512.1 639 R
+7 X
+V
+98.1 623.98 512.1 627 C
+152.1 625.2 512.1 625.2 2 L
+0.5 H
+2 Z
+0 X
+0 K
+N
+98.1 625.49 143.1 625.49 2 L
+0 Z
+N
+40.5 63 571.5 729 C
+0 12 Q
+0 X
+0 K
+(6) 134.63 631 T
+(Images) 152.1 631 T
+3 10 Q
+(Tk 4.0 contains a general-purpose image mechanism for displaying color pictures and) 152.1 607.31 T
+(other complex objects. There is a new command,) 152.1 595.26 T
+5 F
+(image) 350.84 595.26 T
+3 F
+(, which may be used to create) 380.82 595.26 T
+(image objects. For example, the command) 152.1 583.21 T
+5 9 Q
+(image create photo myFace -f) 179.1 568.88 T
+(ile picture.ppm) 330.09 568.88 T
+3 10 Q
+(creates a new image named) 152.1 555.21 T
+5 F
+(myFace) 264.5 555.21 T
+3 F
+(. The image is of type) 300.48 555.21 T
+5 F
+(photo) 390.14 555.21 T
+3 F
+( \050a full-color represen-) 420.12 555.21 T
+(tation that dithers on monochrome or color) 152.1 543.17 T
+(-mapped displays\051 and the source data for the) 323.46 543.17 T
+(image is in the \336le named) 152.1 531.12 T
+5 F
+(picture.ppm) 257.59 531.12 T
+3 F
+(. Once an image has been created, it can be) 323.56 531.12 T
+-0.15 (used in many dif) 152.1 519.07 P
+-0.15 (ferent places by specifying a) 218.37 519.07 P
+5 F
+-0.36 (-image) 334.46 519.07 P
+3 F
+-0.15 ( option. For example, the command) 370.44 519.07 P
+5 9 Q
+(label .l -image myFace) 179.1 504.74 T
+3 10 Q
+(will create a label widget that displays the image, and if) 152.1 491.07 T
+5 F
+(.c) 377.5 491.07 T
+3 F
+( is a canvas widget the com-) 389.49 491.07 T
+(mand) 152.1 479.02 T
+5 9 Q
+(.c create image 400 200 -image myFace) 179.1 464.69 T
+3 10 Q
+(will create an image item in the canvas that displays) 152.1 451.02 T
+5 F
+(myFace) 363.06 451.02 T
+3 F
+(.) 399.04 451.02 T
+(The image mechanism provides a great deal of \337exibility:) 170.1 439.02 T
+3 12 Q
+(\245) 152.1 424.02 T
+3 10 Q
+-0.18 (Once an image has been de\336ned, it can be used in many dif) 162.9 424.02 P
+-0.18 (ferent places, even on dif) 397.84 424.02 P
+-0.18 (fer-) 497.68 424.02 P
+(ent displays.) 162.9 411.98 T
+3 12 Q
+(\245) 152.1 396.98 T
+3 10 Q
+(Images provide image commands, analogous to widget commands, that can be used to) 162.9 396.98 T
+(manipulate the image; any changes in an image are automatically re\337ected in all of its) 162.9 384.93 T
+(instances.) 162.9 372.88 T
+3 12 Q
+(\245) 152.1 357.88 T
+3 10 Q
+-0.21 (There can be many dif) 162.9 357.88 P
+-0.21 (ferent types of images. Tk 4.0 has two built-in types,) 251.78 357.88 P
+5 F
+-0.51 (photo) 463.11 357.88 P
+3 F
+-0.21 ( and) 493.1 357.88 P
+5 F
+(bitmap) 162.9 345.83 T
+3 F
+(. Other image types can be de\336ned in C as extensions \050see the documentation) 198.88 345.83 T
+-0.16 (for the) 162.9 333.79 P
+5 F
+-0.39 (Tk_CreateImageType) 191.44 333.79 P
+3 F
+-0.16 ( library procedure\051. The photo image type was imple-) 299.38 333.79 P
+(mented by Paul Mackerras, based on his earlier photo widget.) 162.9 321.74 T
+3 12 Q
+(\245) 152.1 306.74 T
+3 10 Q
+(W) 162.9 306.74 T
+(ithin the photo image type, there can be many dif) 171.93 306.74 T
+(ferent \336le formats. In Tk 4.0, only) 368.29 306.74 T
+-0.11 (PPM, PGM, and GIF formats are built-in, but other formats can be added as extensions) 162.9 294.69 P
+(\050see the documentation for the) 162.9 282.64 T
+5 F
+(Tk_CreatePhotoImageFormat) 286.97 282.64 T
+3 F
+( library proce-) 436.89 282.64 T
+(dure\051. Readers for XPM, TIFF) 162.9 270.59 T
+(, and others are available from the T) 284.23 270.59 T
+(cl community) 428.41 270.59 T
+(.) 483.01 270.59 T
+98.1 227.24 512.1 230.26 C
+152.1 228.46 512.1 228.46 2 L
+0.5 H
+2 Z
+0 X
+0 K
+N
+98.1 228.75 143.1 228.75 2 L
+0 Z
+N
+40.5 63 571.5 729 C
+0 12 Q
+0 X
+0 K
+(7) 134.63 234.26 T
+(Color management) 152.1 234.26 T
+3 10 Q
+(Tk 3.6 suf) 152.1 210.57 T
+(fers from a relatively weak mechanism for managing colors. It uses only the) 192.73 210.57 T
+(default colormap for a screen, and if all the entries in that colormap \336ll up then Tk) 152.1 198.52 T
+(switches to monochrome mode and \322rounds\323 all future colors to black or white. This) 152.1 186.48 T
+(approach is becoming increasingly unpleasant because of applications such as Frame and) 152.1 174.43 T
+(W) 152.1 162.38 T
+(eb browsers that use up all the entries in the default colormap.) 160.74 162.38 T
+(Tk 4.0 has a much more powerful color management mechanism. If a colormap \336lls) 170.1 150.38 T
+(up, Tk allocates future colors by picking the closest match from the available colors, so) 152.1 138.33 T
+FMENDPAGE
+%%EndPage: "13" 14
+%%Page: "14" 14
+612 792 0 FMBEGINPAGE
+0 10 Q
+0 X
+0 K
+(14) 98.1 668.33 T
+4 F
+(Tk4.0 Overview and Porting Guide) 359.34 668.33 T
+98.1 660.6 512.1 660.6 2 L
+0.25 H
+0 Z
+N
+98.1 135 512.1 639 R
+7 X
+V
+3 F
+0 X
+(that it need not revert to monochrome mode. Tk also manages colors better by delaying) 152.1 632.33 T
+-0.3 (color allocation until colors are actually needed; in many cases, such as 3D borders, colors) 152.1 620.33 P
+(are never needed. When colors are scarce Tk changes the way it displays beveled borders) 152.1 608.33 T
+-0.38 (so that it uses stippling instead of additional colors for the light and dark shadows. Y) 152.1 596.33 P
+-0.38 (ou can) 484.01 596.33 P
+(\336nd out whether a colormap has \336lled up using the new command) 152.1 584.33 T
+5 F
+(winfo colormap-) 418.59 584.33 T
+(full) 152.1 572.33 T
+3 F
+(.) 176.09 572.33 T
+-0.26 (Tk 4.0 also allows you to allocate new colormaps for toplevel and frame widgets with) 170.1 560.33 P
+(the) 152.1 548.33 T
+5 F
+(-colormap) 166.81 548.33 T
+3 F
+( option, and you change the visual type in these widgets \050with the) 220.78 548.33 T
+5 F
+(-) 152.1 536.33 T
+(visual) 158.1 536.33 T
+3 F
+( option\051 to take advantage of visuals other than the default visual for a screen.) 194.08 536.33 T
+(New commands) 152.1 524.33 T
+5 F
+(winfo visualsavailable) 219.27 524.33 T
+3 F
+( and) 351.2 524.33 T
+5 F
+(wm colormapwindows) 370.63 524.33 T
+3 F
+( have) 478.57 524.33 T
+(been added to help manage colormaps and visuals.) 152.1 512.33 T
+(The default color scheme in Tk 4.0 has changed from a tan palette \050\322bisque\323\051 to a) 170.1 500.33 T
+(gray palette, which seems to becoming standard for Motif. There is a new T) 152.1 488.33 T
+(cl procedure) 454.78 488.33 T
+5 F
+-0.36 (tk_setPalette) 152.1 476.33 P
+3 F
+-0.15 ( that changes the palette of an application on the \337y) 230.06 476.33 P
+-0.15 (, and there is also a) 433.89 476.33 P
+(procedure) 152.1 464.33 T
+5 F
+(tk_bisque) 194.56 464.33 T
+3 F
+( to restore the palette to the old bisque colors.) 248.53 464.33 T
+(The Tk 3.6 color model mechanism is no longer necessary so it has been removed in) 170.1 452.33 T
+(Tk 4.0. If you want to \336nd out whether a screen is monochrome or color) 152.1 440.33 T
+(, you cannot use) 440.38 440.33 T
+(the) 152.1 428.33 T
+5 F
+(tk colormodel) 166.81 428.33 T
+3 F
+( command anymore; use) 244.77 428.33 T
+5 F
+(winfo depth) 345.25 428.33 T
+3 F
+( instead.) 411.22 428.33 T
+98.1 384.98 512.1 388 C
+152.1 386.2 512.1 386.2 2 L
+0.5 H
+2 Z
+0 X
+0 K
+N
+98.1 386.49 143.1 386.49 2 L
+0 Z
+N
+40.5 63 571.5 729 C
+0 12 Q
+0 X
+0 K
+(8) 134.63 392 T
+(Event handling: \336leevent and after) 152.1 392 T
+3 10 Q
+(Tk 4.0 contains several improvements in the area of event handling besides those already) 152.1 368.31 T
+(mentioned for bindings:) 152.1 356.31 T
+3 12 Q
+(\245) 152.1 341.31 T
+3 10 Q
+(There is a new command) 162.9 341.31 T
+5 F
+(f) 265.87 341.31 T
+(ileevent) 271.87 341.31 T
+3 F
+( for performing event-driven I/O to and from) 319.84 341.31 T
+-0.12 (\336les. The) 162.9 329.31 P
+5 F
+-0.29 (f) 202.35 329.31 P
+-0.29 (ileevent) 208.35 329.31 P
+3 F
+-0.12 ( command is modelled very closely after Mark Diekhans\325) 256.33 329.31 P
+5 F
+-0.29 (add-) 488.11 329.31 P
+(input) 162.9 317.31 T
+3 F
+( extension, which has been used widely with Tk 3.6.) 192.88 317.31 T
+3 12 Q
+(\245) 152.1 302.31 T
+3 10 Q
+-0.34 (The) 162.9 302.31 P
+5 F
+-0.82 (after) 180.6 302.31 P
+3 F
+-0.34 ( command has two new options,) 210.58 302.31 P
+5 F
+-0.82 (idle) 339.82 302.31 P
+3 F
+-0.34 ( and) 363.81 302.31 P
+5 F
+-0.82 (cancel) 382.55 302.31 P
+3 F
+-0.34 (.) 418.53 302.31 P
+5 F
+-0.82 (After idle) 423.19 302.31 P
+3 F
+-0.34 ( can be) 482.33 302.31 P
+-0.2 (used to schedule a script as an \322idle handler\323, which means it runs the next time that Tk) 162.9 290.31 P
+(enters the event loop and \336nds no work to do.) 162.9 278.31 T
+5 F
+(After cancel) 348.06 278.31 T
+3 F
+( may be used to delete) 420.02 278.31 T
+(a previously-scheduled) 162.9 266.31 T
+5 F
+(after) 257.83 266.31 T
+3 F
+( script, so that it will no longer be invoked.) 287.81 266.31 T
+98.1 222.95 512.1 225.98 C
+152.1 224.18 512.1 224.18 2 L
+0.5 H
+2 Z
+0 X
+0 K
+N
+98.1 224.46 143.1 224.46 2 L
+0 Z
+N
+40.5 63 571.5 729 C
+0 12 Q
+0 X
+0 K
+(9) 134.63 229.98 T
+(Multiple displays) 152.1 229.98 T
+3 10 Q
+(Although Tk has always allowed a single application to open windows on several dis-) 152.1 206.29 T
+(plays, the support for multiple displays is weak in Tk 3.6. For example, many of the bind-) 152.1 194.29 T
+(ings break if users work simultaneously in windows on dif) 152.1 182.29 T
+(ferent displays, and) 385.94 182.29 T
+(mechanisms like the selection and the input focus have insuf) 152.1 170.29 T
+(\336cient support for multiple) 394.26 170.29 T
+(displays.) 152.1 158.29 T
+FMENDPAGE
+%%EndPage: "14" 15
+%%Page: "15" 15
+612 792 0 FMBEGINPAGE
+4 10 Q
+0 X
+0 K
+(10 The send command) 98.1 668.33 T
+0 F
+(15) 500.99 668.33 T
+98.1 660.6 512.1 660.6 2 L
+0.25 H
+0 Z
+N
+98.1 135 512.1 639 R
+7 X
+V
+3 F
+0 X
+-0.33 (Tk 4.0 contains numerous modi\336cations to improve the handling of multiple displays.) 170.1 632.33 P
+-0.18 (Several commands, such as) 152.1 620.24 P
+5 F
+-0.44 (selection) 263.78 620.24 P
+3 F
+-0.18 (,) 317.76 620.24 P
+5 F
+-0.44 (send) 322.57 620.24 P
+3 F
+-0.18 (, and) 346.55 620.24 P
+5 F
+-0.44 (focus) 368.12 620.24 P
+3 F
+-0.18 (, have a new) 398.1 620.24 P
+5 F
+-0.44 (-displayof) 449.82 620.24 P
+3 F
+(ar) 152.1 608.15 T
+(gument so that you can select a particular display) 159.69 608.15 T
+(. In addition, the bindings have been) 356.12 608.15 T
+(reworked to handle interactions occurring simultaneously on dif) 152.1 596.05 T
+(ferent displays. W) 408.13 596.05 T
+(ith Tk) 480.73 596.05 T
+(4.0 it should be possible to create applications that really use multiple displays gracefully) 152.1 583.96 T
+(.) 508.44 583.96 T
+98.1 540.6 512.1 543.63 C
+152.1 541.83 512.1 541.83 2 L
+0.5 H
+2 Z
+0 X
+0 K
+N
+98.1 542.12 143.1 542.12 2 L
+0 Z
+N
+40.5 63 571.5 729 C
+0 12 Q
+0 X
+0 K
+(10) 127.96 547.63 T
+(The send command) 152.1 547.63 T
+3 10 Q
+-0.2 (The) 152.1 523.94 P
+5 F
+-0.48 (send) 169.94 523.94 P
+3 F
+-0.2 ( command has been completely overhauled for Tk 4.0 to eliminate several prob-) 193.93 523.94 P
+(lems in Tk 3.6 and add a number of new features:) 152.1 511.85 T
+3 12 Q
+(\245) 152.1 496.85 T
+3 10 Q
+(Tk 3.6 aborts a) 162.9 496.85 T
+5 F
+(send) 225.36 496.85 T
+3 F
+( command if no response is received within 5 seconds; this made) 249.34 496.85 T
+(it very dif) 162.9 484.75 T
+(\336cult to invoke long-running commands. Tk 4.0 eliminates the timeout and) 202.14 484.75 T
+(uses a dif) 162.9 472.66 T
+(ferent mechanism to tell if the tar) 200.47 472.66 T
+(get application has crashed.) 333.53 472.66 T
+3 12 Q
+(\245) 152.1 457.66 T
+3 10 Q
+-0.36 (The) 162.9 457.66 P
+5 F
+-0.87 (winfo interps) 180.58 457.66 P
+3 F
+-0.36 ( command no longer returns the names of applications that have) 257.66 457.66 P
+(exited or crashed.) 162.9 445.57 T
+3 12 Q
+(\245) 152.1 430.57 T
+3 10 Q
+(Asynchronous sends are possible using the) 162.9 430.57 T
+5 F
+(-async) 336.67 430.57 T
+3 F
+( switch.) 372.65 430.57 T
+3 12 Q
+(\245) 152.1 415.57 T
+3 10 Q
+(Commands can be sent to displays other than that of the root window) 162.9 415.57 T
+(, using the) 439.3 415.57 T
+5 F
+(-) 162.9 403.47 T
+(displayof) 168.9 403.47 T
+3 F
+( switch.) 222.87 403.47 T
+3 12 Q
+(\245) 152.1 388.47 T
+3 10 Q
+(W) 162.9 388.47 T
+(indow server security is now checked on each) 171.93 388.47 T
+5 F
+(send) 357.89 388.47 T
+3 F
+(, so Tk 4.0 deals better with) 381.88 388.47 T
+(changes in the security of the server) 162.9 376.38 T
+(.) 306.12 376.38 T
+3 12 Q
+(\245) 152.1 361.38 T
+3 10 Q
+(More complete error information \050including the) 162.9 361.38 T
+5 F
+(errorCode) 356.09 361.38 T
+3 F
+( and) 410.06 361.38 T
+5 F
+(errorInfo) 429.49 361.38 T
+3 F
+( vari-) 483.46 361.38 T
+(ables\051 is propagated back to the sender after errors.) 162.9 349.29 T
+3 12 Q
+(\245) 152.1 334.29 T
+3 10 Q
+(Y) 162.9 334.29 T
+(ou can query and change the name of an application with the) 169.12 334.29 T
+5 F
+(tk appname) 414.48 334.29 T
+3 F
+( com-) 474.45 334.29 T
+(mand.) 162.9 322.19 T
+(Unfortunately the improvements to the Tk 4.0) 152.1 307.19 T
+5 F
+(send) 338.65 307.19 T
+3 F
+( mechanism required substantial) 362.63 307.19 T
+(changes to the transport protocol for sends; this makes it impossible for Tk 4.0 applica-) 152.1 295.1 T
+(tions to communicate with Tk 3.6 applications via) 152.1 283.01 T
+5 F
+(send) 355.04 283.01 T
+3 F
+(. The new transport protocol is) 379.02 283.01 T
+(more \337exible than the old protocol, so it should be possible to make protocol improve-) 152.1 270.91 T
+(ments in an upward-compatible way) 152.1 258.82 T
+(.) 296.9 258.82 T
+98.1 215.47 512.1 218.49 C
+152.1 216.69 512.1 216.69 2 L
+0.5 H
+2 Z
+0 X
+0 K
+N
+98.1 216.98 143.1 216.98 2 L
+0 Z
+N
+40.5 63 571.5 729 C
+0 12 Q
+0 X
+0 K
+(1) 128.62 222.49 T
+(1) 134.63 222.49 T
+(The selection and clipboard) 152.1 222.49 T
+3 10 Q
+(In Tk 3.6 the selection mechanism can deal only with the display of the root window and) 152.1 198.8 T
+-0.13 (with the primary selection; there is no support for multiple displays, secondary selections,) 152.1 186.71 P
+(or the clipboard. Tk 4.0 eliminates all of these shortcomings. The) 152.1 174.61 T
+5 F
+(-displayof) 415.82 174.61 T
+3 F
+( option) 475.78 174.61 T
+-0.12 (can be used to specify a particular display in the selection command, and there is now full) 152.1 162.52 P
+(access to all of the X selection types. Tk 4.0 also includes a new) 152.1 150.43 T
+5 F
+(clipboard) 411.36 150.43 T
+3 F
+( command) 465.33 150.43 T
+(for manipulating the clipboard.) 152.1 138.33 T
+FMENDPAGE
+%%EndPage: "15" 16
+%%Page: "16" 16
+612 792 0 FMBEGINPAGE
+0 10 Q
+0 X
+0 K
+(16) 98.1 668.33 T
+4 F
+(Tk4.0 Overview and Porting Guide) 359.34 668.33 T
+98.1 660.6 512.1 660.6 2 L
+0.25 H
+0 Z
+N
+98.1 135 512.1 639 R
+7 X
+V
+98.1 623.98 512.1 627 C
+152.1 625.2 512.1 625.2 2 L
+0.5 H
+2 Z
+0 X
+0 K
+N
+98.1 625.49 143.1 625.49 2 L
+0 Z
+N
+40.5 63 571.5 729 C
+0 12 Q
+0 X
+0 K
+(12) 127.96 631 T
+(Miscellaneous changes) 152.1 631 T
+3 10 Q
+(Here is a quick summary of the remaining changes in Tk 4.0:) 152.1 607.31 T
+3 12 Q
+(\245) 152.1 592.31 T
+3 10 Q
+-0.17 (The) 162.9 592.31 P
+5 F
+-0.42 (wish) 180.76 592.31 P
+3 F
+-0.17 ( application has been modi\336ed so that the) 204.75 592.31 P
+5 F
+-0.42 (-f) 371.58 592.31 P
+-0.42 (ile) 383.57 592.31 P
+3 F
+-0.17 ( switch is no longer needed) 401.56 592.31 P
+(or recommended. This makes) 162.9 580.31 T
+5 F
+(wish) 283.64 580.31 T
+3 F
+( just like) 307.63 580.31 T
+5 F
+(tclsh) 344.56 580.31 T
+3 F
+(, where you specify the script \336le) 374.54 580.31 T
+(as the \336rst ar) 162.9 568.31 T
+(gument to the program, e.g.) 214.07 568.31 T
+5 F
+(wish foo.tcl) 327.33 568.31 T
+3 F
+(. The) 399.29 568.31 T
+5 F
+(-f) 422.33 568.31 T
+(ile) 434.32 568.31 T
+3 F
+( switch is still) 452.31 568.31 T
+(permitted for backward compatibility) 162.9 556.31 T
+(, but its use is deprecated.) 311.87 556.31 T
+3 12 Q
+(\245) 152.1 541.31 T
+5 10 Q
+(Wish) 162.9 541.31 T
+3 F
+( now sets the application\325) 186.89 541.31 T
+(s class from the application name \050what appears in the) 288.49 541.31 T
+-0.37 (title bar of the window by default\051, rather than always using) 162.9 529.31 P
+5 F
+-0.88 (Tk) 400.9 529.31 P
+3 F
+-0.37 ( as the class as in Tk 3.6.) 412.89 529.31 P
+(This makes application-speci\336c options easier to use.) 162.9 517.31 T
+3 12 Q
+(\245) 152.1 502.31 T
+3 10 Q
+(T) 162.9 502.31 T
+(oplevel windows are now resizable by default, whereas in Tk 3.6 they were not. Y) 168.31 502.31 T
+(ou) 496.22 502.31 T
+(can use the) 162.9 490.31 T
+5 F
+(wm resizable) 209.8 490.31 T
+3 F
+( command to make windows non-reiszable.) 281.77 490.31 T
+3 12 Q
+(\245) 152.1 475.31 T
+3 10 Q
+(Tk 4.0 patches around an Xlib bug whereby long-running applications tended to reach) 162.9 475.31 T
+(the end of the space of X resource ids, wrap around to 0 again, and then crash. Tk now) 162.9 463.31 T
+(reuses resource identi\336ers so that wrap-around should never occur) 162.9 451.31 T
+(.) 427.14 451.31 T
+3 12 Q
+(\245) 152.1 436.31 T
+3 10 Q
+-0.13 (There is a new) 162.9 436.31 P
+5 F
+-0.31 (winfo manager) 223.43 436.31 P
+3 F
+-0.13 ( command that tells which geometry manager is con-) 301.08 436.31 P
+(trolling a particular widget.) 162.9 424.31 T
+3 12 Q
+(\245) 152.1 409.31 T
+3 10 Q
+(There is a new) 162.9 409.31 T
+5 F
+(bell) 223.96 409.31 T
+3 F
+( command that does what its name suggests.) 247.94 409.31 T
+3 12 Q
+(\245) 152.1 394.31 T
+3 10 Q
+(There are new) 162.9 394.31 T
+5 F
+(winfo pointerx) 222.56 394.31 T
+3 F
+(,) 306.51 394.31 T
+5 F
+(winfo pointery) 311.51 394.31 T
+3 F
+(, and) 394.81 394.31 T
+5 F
+(winfo pointerxy) 416.74 394.31 T
+3 F
+(commands that can be used to query the position of the mouse pointer) 162.9 382.31 T
+(.) 442.17 382.31 T
+98.1 338.95 512.1 341.98 C
+152.1 340.18 512.1 340.18 2 L
+0.5 H
+2 Z
+0 X
+0 K
+N
+98.1 340.46 143.1 340.46 2 L
+0 Z
+N
+40.5 63 571.5 729 C
+0 12 Q
+0 X
+0 K
+(13) 127.96 345.98 T
+(Summary of Incompatibilites) 152.1 345.98 T
+3 10 Q
+-0.24 (This section lists all of the incompatible changes in Tk 4.0 that may require changes in T) 152.1 322.29 P
+-0.24 (cl) 502.62 322.29 P
+-0.22 (scripts written for T) 152.1 310.29 P
+-0.22 (cl 3.6. Each incompatibility is described in terms of the problem it pro-) 230.42 310.29 P
+(duces when you run your Tk 3.6 script under Tk 4.0 and a possible work-around. Only) 152.1 298.29 T
+(T) 152.1 286.29 T
+(cl-level incompatibilities are covered here. For incompatible changes at the C level, see) 157.51 286.29 T
+(the) 152.1 274.29 T
+5 F
+(README) 166.81 274.29 T
+3 F
+( and) 202.79 274.29 T
+5 F
+(changes) 222.22 274.29 T
+3 F
+( \336les in the distribution. The problems and solutions are) 264.2 274.29 T
+(roughly in order of importance, with the most important problems \336rst.) 152.1 262.29 T
+1 F
+(Pr) 152.1 247.29 T
+(oblem #1:) 162.46 247.29 T
+3 F
+(When you change the background color of a widget, a small ring in the) 206.88 247.29 T
+(default background color remains around the edge of the widget.) 152.1 235.29 T
+2 F
+(Solution:) 170.1 223.29 T
+3 F
+(This is the focus traversal highlight, whose color is speci\336ed separately) 209.25 223.29 T
+(from) 170.1 211.29 T
+5 F
+(-background) 192.03 211.29 T
+3 F
+(; use the) 257.99 211.29 T
+5 F
+(-highlightbackground) 293.8 211.29 T
+3 F
+( option to change the) 413.74 211.29 T
+(color of the highlight. Or) 170.1 199.29 T
+(, you can set) 269.92 199.29 T
+5 F
+(-highlightthickness) 322.38 199.29 T
+3 F
+( to 0 to eliminate) 436.31 199.29 T
+(the traversal highlight altogether) 170.1 187.29 T
+(.) 299.74 187.29 T
+1 F
+(Pr) 152.1 172.29 T
+(oblem #2:) 162.46 172.29 T
+3 F
+(Bindings de\336ned for a widget no longer replace the corresponding class) 206.88 172.29 T
+(bindings, so unwanted class bindings get invoked in addition to the widget bindings.) 152.1 160.29 T
+FMENDPAGE
+%%EndPage: "16" 17
+%%Page: "17" 17
+612 792 0 FMBEGINPAGE
+4 10 Q
+0 X
+0 K
+(13 Summary of Incompatibilites) 98.1 668.33 T
+0 F
+(17) 500.99 668.33 T
+98.1 660.6 512.1 660.6 2 L
+0.25 H
+0 Z
+N
+98.1 135 512.1 639 R
+7 X
+V
+2 F
+0 X
+(Solution:) 170.1 632.33 T
+3 F
+(Add a) 209.25 632.33 T
+5 F
+(break) 235.89 632.33 T
+3 F
+( command at the end of the widget binding, or rework the) 265.88 632.33 T
+(widget binding so that it\325) 170.1 620.33 T
+(s OK for the class binding to execute.) 270.05 620.33 T
+1 F
+(Pr) 152.1 605.33 T
+(oblem #3:) 162.46 605.33 T
+3 F
+(Bindings on toplevel windows are invoked when events occur for internal) 206.88 605.33 T
+(windows inside the toplevels.) 152.1 593.33 T
+2 F
+(Solution:) 170.1 581.33 T
+3 F
+(Use the) 209.25 581.33 T
+5 F
+(%W) 242 581.33 T
+3 F
+( substitution to extract the name of the window where the event) 253.99 581.33 T
+(actually occurred, and only execute the rest of the binding script if this matches the) 170.1 569.33 T
+(name of the toplevel.) 170.1 557.33 T
+1 F
+-0.15 (Pr) 152.1 542.33 P
+-0.15 (oblem #4:) 162.46 542.33 P
+3 F
+-0.15 (The) 206.58 542.33 P
+5 F
+-0.37 (-command) 224.46 542.33 P
+3 F
+-0.15 ( option for a cascade menu entry is no longer invoked when) 272.44 542.33 P
+(the submenu is posted.) 152.1 530.33 T
+2 F
+(Solution:) 170.1 518.33 T
+3 F
+(Use the) 209.25 518.33 T
+5 F
+(-postcommand) 242 518.33 T
+3 F
+( option for the submenu instead.) 313.96 518.33 T
+1 F
+(Pr) 152.1 503.33 T
+(oblem #5:) 162.46 503.33 T
+3 F
+(The) 206.88 503.33 T
+5 F
+(-geometry) 224.92 503.33 T
+3 F
+( option is no longer supported by listboxes, frames, and) 278.89 503.33 T
+(toplevels.) 152.1 491.33 T
+2 F
+(Solution:) 170.1 479.33 T
+3 F
+(Use the) 209.25 479.33 T
+5 F
+(-width) 242 479.33 T
+3 F
+( and) 277.98 479.33 T
+5 F
+(-height) 297.41 479.33 T
+3 F
+( options instead.) 339.39 479.33 T
+1 F
+(Pr) 152.1 464.33 T
+(oblem #6:) 162.46 464.33 T
+3 F
+(The procedure) 206.88 464.33 T
+5 F
+(tk_listboxSingleSelect) 267.38 464.33 T
+3 F
+( no longer exists.) 399.3 464.33 T
+2 F
+(Solution:) 170.1 452.33 T
+3 F
+(Use the) 209.25 452.33 T
+5 F
+(-selectmode) 242 452.33 T
+3 F
+( option on the listbox instead.) 307.96 452.33 T
+1 F
+(Pr) 152.1 437.33 T
+(oblem #7:) 162.46 437.33 T
+3 F
+(Canvases no longer have a) 206.88 437.33 T
+5 F
+(-scrollincrement) 315.96 437.33 T
+3 F
+( option.) 411.91 437.33 T
+2 F
+(Solution:) 170.1 425.33 T
+3 F
+(Use the new) 209.25 425.33 T
+5 F
+(-xscrollincrement) 261.15 425.33 T
+3 F
+( and) 363.09 425.33 T
+5 F
+(-yscrollincrement) 382.52 425.33 T
+3 F
+(options instead.) 170.1 413.33 T
+1 F
+(Pr) 152.1 398.33 T
+(oblem #8:) 162.46 398.33 T
+3 F
+(The) 206.88 398.33 T
+5 F
+(tk colormodel) 224.92 398.33 T
+3 F
+( command no longer exists.) 302.88 398.33 T
+2 F
+-0.28 (Solution:) 170.1 386.33 P
+3 F
+-0.28 (T) 208.97 386.33 P
+-0.28 (o \336nd out whether a window is monochrome or color) 214.37 386.33 P
+-0.28 (, use) 424.34 386.33 P
+5 F
+-0.68 (winfo depth) 444.6 386.33 P
+3 F
+(to extract the window\325) 170.1 374.33 T
+(s depth; a depth of 1 means monochrome.) 259.76 374.33 T
+1 F
+-0.08 (Pr) 152.1 359.33 P
+-0.08 (oblem #9:) 162.46 359.33 P
+3 F
+-0.08 (The class of Tk applications is no longer) 206.72 359.33 P
+5 F
+-0.19 (Tk) 370.97 359.33 P
+3 F
+-0.08 (, so options speci\336ed for the) 382.96 359.33 P
+5 F
+-0.19 (Tk) 497.69 359.33 P
+3 F
+(class in your) 152.1 347.33 T
+5 F
+(.Xdefaults) 205.12 347.33 T
+3 F
+( \336le are no longer used.) 265.09 347.33 T
+2 F
+(Solution:) 170.1 335.33 T
+3 F
+(Modify your) 209.25 335.33 T
+5 F
+(.Xdefaults) 262.55 335.33 T
+3 F
+( \336le \050and any T) 322.52 335.33 T
+(cl code that sets options\051 to) 382.88 335.33 T
+(specify the name of the application \050with the \336rst letter capitalized\051 as the class) 170.1 323.33 T
+(instead of) 170.1 311.33 T
+5 F
+(Tk) 211.74 311.33 T
+3 F
+(.) 223.73 311.33 T
+1 F
+-0.15 (Pr) 152.1 296.33 P
+-0.15 (oblem #10:) 162.46 296.33 P
+3 F
+-0.15 (When text is added to a text widget just after a tagged area, the new text no) 211.57 296.33 P
+(longer receives the tag.) 152.1 284.33 T
+2 F
+-0.1 (Solution:) 170.1 272.33 P
+3 F
+-0.1 (Explicitly tag the new text with the desired tags. If you want the tags on the) 209.15 272.33 P
+-0.08 (new text to be the same as those at some other point in the text, you can use the) 170.1 260.33 P
+5 F
+-0.2 (tag) 488.31 260.33 P
+(names) 170.1 248.33 T
+3 F
+( widget command to query existing tags.) 200.08 248.33 T
+1 F
+(Pr) 152.1 233.33 T
+(oblem #1) 162.46 233.33 T
+(1:) 200.5 233.33 T
+3 F
+(W) 211.33 233.33 T
+(idgets appear lar) 220.36 233.33 T
+(ger than they did in Tk 3.6.) 286.24 233.33 T
+2 F
+(Solution:) 170.1 221.33 T
+3 F
+(There are two issues here. The \336rst is that all widgets now have a focus tra-) 209.25 221.33 T
+-0.24 (versal highlight ring that turns dark when the widget has the focus; this is required for) 170.1 209.33 P
+(Motif compliance but you can eliminate it by specifying a 0 value for the) 170.1 197.33 T
+5 F
+( -high-) 462.4 197.33 T
+(lightthickness) 170.1 185.33 T
+3 F
+( option. The second issue is that the default padding for buttons) 254.05 185.33 T
+-0.17 (and menubuttons has been increased to match the sizes of Motif widgets. If you don\325) 170.1 173.33 P
+-0.17 (t) 506.99 173.33 P
+(mind being dif) 170.1 161.33 T
+(ferent from Motif, you can set the) 228.78 161.33 T
+5 F
+(-padx) 366.45 161.33 T
+3 F
+( and) 396.44 161.33 T
+5 F
+(-) 415.86 161.33 T
+(pady) 421.86 161.33 T
+3 F
+( options back to) 445.85 161.33 T
+FMENDPAGE
+%%EndPage: "17" 18
+%%Page: "18" 18
+612 792 0 FMBEGINPAGE
+0 10 Q
+0 X
+0 K
+(18) 98.1 668.33 T
+4 F
+(Tk4.0 Overview and Porting Guide) 359.34 668.33 T
+98.1 660.6 512.1 660.6 2 L
+0.25 H
+0 Z
+N
+98.1 135 512.1 639 R
+7 X
+V
+3 F
+0 X
+(their Tk 3.6 values \050use the) 170.1 632.33 T
+5 F
+(conf) 281.41 632.33 T
+(igure) 305.4 632.33 T
+3 F
+( widget command in Tk 3.6 to see what the) 335.38 632.33 T
+(old values were\051.) 170.1 620.33 T
+1 F
+(Pr) 152.1 605.33 T
+(oblem #12:) 162.46 605.33 T
+3 F
+(Listboxes now return the selection as a string with newlines separating the) 211.88 605.33 T
+(values, rather than a T) 152.1 593.33 T
+(cl, list.) 240.49 593.33 T
+2 F
+(Solution:) 170.1 581.33 T
+3 F
+(Modify your code to handle the new format. Y) 209.25 581.33 T
+(ou can convert the selection) 395.06 581.33 T
+(back into the old list format with a script like the following:) 170.1 569.33 T
+5 9 Q
+(split [selection get] \134n) 179.1 555 T
+1 10 Q
+(Pr) 152.1 541.33 T
+(oblem #13:) 162.46 541.33 T
+3 F
+(Tk 4.0 applications cannot) 211.88 541.33 T
+5 F
+(send) 320.42 541.33 T
+3 F
+( to or be sent from Tk 3.6 applications.) 344.4 541.33 T
+2 F
+(Solution:) 170.1 529.33 T
+3 F
+(The only solution is to upgrade all your applications to Tk 4.0.) 209.25 529.33 T
+1 F
+-0.17 (Pr) 152.1 514.33 P
+-0.17 (oblem #14:) 162.46 514.33 P
+3 F
+-0.17 (In texts,) 211.54 514.33 P
+5 F
+-0.4 (end) 245.91 514.33 P
+3 F
+-0.17 ( now refers to a position just after the \336nal newline, instead of) 263.9 514.33 P
+(the \336nal newline.) 152.1 502.33 T
+2 F
+-0.08 (Solution:) 170.1 490.33 P
+3 F
+-0.08 (If you wish to refer to the \336nal newline, use the index) 209.17 490.33 P
+5 F
+-0.19 (end-1char) 424.98 490.33 P
+3 F
+-0.08 ( instead) 478.95 490.33 P
+(of) 170.1 478.33 T
+5 F
+(end) 180.92 478.33 T
+3 F
+(.) 198.91 478.33 T
+1 F
+(Pr) 152.1 463.33 T
+(oblem #15:) 162.46 463.33 T
+3 F
+(In entry widgets,) 211.88 463.33 T
+5 F
+(sel.last) 281.83 463.33 T
+3 F
+( now refers to the character just after the last) 329.8 463.33 T
+(selected one, rather than the last selected one. The second index for the) 152.1 451.33 T
+5 F
+(delete) 438.81 451.33 T
+3 F
+( widget) 474.79 451.33 T
+(command has changed in the same way) 152.1 439.33 T
+(.) 309.66 439.33 T
+2 F
+(Solution:) 170.1 427.33 T
+3 F
+(Add one to the values used in your scripts.) 209.25 427.33 T
+1 F
+(Pr) 152.1 412.33 T
+(oblem #16:) 162.46 412.33 T
+3 F
+(Because) 211.88 412.33 T
+5 F
+(Any) 247.68 412.33 T
+3 F
+( is implicit in all bindings, bindings trigger when extra modi-) 265.67 412.33 T
+(\336ers are present, whereas they didn\325) 152.1 400.33 T
+(t trigger in Tk 3.6.) 296.24 400.33 T
+2 F
+(Solution:) 170.1 388.33 T
+3 F
+(In most cases it\325) 209.25 388.33 T
+(s probably \336ne to ignore the extra modi\336ers. If you really) 273.93 388.33 T
+-0.12 (don\325) 170.1 376.33 P
+-0.12 (t want any actions to be taken when extra modi\336ers are present, create additional) 188.24 376.33 P
+(bindings for the cases with extra modi\336ers, and specify a single blank character \050or) 170.1 364.33 T
+(any script that does nothing\051 as the script for those bindings. Alternatively) 170.1 352.33 T
+(, you can) 465.93 352.33 T
+(use the) 170.1 340.33 T
+5 F
+(%s) 200.63 340.33 T
+3 F
+( substitution to extract the mouse and modi\336er state in the event binding,) 212.63 340.33 T
+(then you can test this value for modi\336ers you do or don\325) 170.1 328.33 T
+(t want.) 394.5 328.33 T
+1 F
+(Pr) 152.1 313.33 T
+(oblem #17:) 162.46 313.33 T
+3 F
+(In scrollbars there is no longer a) 211.88 313.33 T
+5 F
+(-foreground) 343.17 313.33 T
+3 F
+( or) 409.13 313.33 T
+5 F
+(-activefore-) 422.45 313.33 T
+(ground) 152.1 301.33 T
+3 F
+( option, and) 188.08 301.33 T
+5 F
+(-background) 238.05 301.33 T
+3 F
+( has a dif) 304.02 301.33 T
+(ferent meaning.) 340.2 301.33 T
+2 F
+-0.4 (Solution:) 170.1 289.33 P
+3 F
+-0.4 (Use) 208.85 289.33 P
+5 F
+-0.96 (-troughcolor) 226.49 289.33 P
+3 F
+-0.4 ( everywhere that you used) 298.45 289.33 P
+5 F
+-0.96 (-background) 403.87 289.33 P
+3 F
+-0.4 ( in Tk 3.6,) 469.83 289.33 P
+5 F
+(-background) 170.1 277.33 T
+3 F
+( everywhere you used to use) 236.06 277.33 T
+5 F
+(-foreground) 352.08 277.33 T
+3 F
+(, and) 418.04 277.33 T
+5 F
+(-activeback-) 439.97 277.33 T
+(ground) 170.1 265.33 T
+3 F
+( everywhere you used to use) 206.08 265.33 T
+5 F
+(-activeforeground) 322.1 265.33 T
+3 F
+(.) 424.04 265.33 T
+1 F
+(Pr) 152.1 250.33 T
+(oblem #18:) 162.46 250.33 T
+3 F
+(Options for colors seem to have changed in scale widgets.) 211.88 250.33 T
+2 F
+(Solution:) 170.1 238.33 T
+3 F
+(Use) 209.25 238.33 T
+5 F
+(-background) 227.29 238.33 T
+3 F
+( where you used to use) 293.25 238.33 T
+5 F
+(-sliderforeground) 387.07 238.33 T
+3 F
+(,) 489.02 238.33 T
+5 F
+(-) 170.1 226.33 T
+(troughcolor) 176.1 226.33 T
+3 F
+( where you used to use) 242.06 226.33 T
+5 F
+(-background) 335.88 226.33 T
+3 F
+(, and) 401.84 226.33 T
+5 F
+( -activeback-) 421.27 226.33 T
+(ground) 170.1 214.33 T
+3 F
+( everywhere you used to use) 206.08 214.33 T
+5 F
+(-activeforeground) 322.1 214.33 T
+3 F
+(.) 424.04 214.33 T
+1 F
+(Pr) 152.1 199.33 T
+(oblem #19:) 162.46 199.33 T
+3 F
+(Scale widgets no longer accept hexadecimal or octal numbers in the) 211.88 199.33 T
+5 F
+(set) 485.84 199.33 T
+3 F
+(command or the) 152.1 187.33 T
+5 F
+(-from) 219.55 187.33 T
+3 F
+( and) 249.54 187.33 T
+5 F
+(-to) 268.97 187.33 T
+3 F
+( options.) 286.96 187.33 T
+2 F
+(Solution:) 170.1 175.33 T
+3 F
+(Use) 209.25 175.33 T
+5 F
+(format) 227.29 175.33 T
+3 F
+( or) 263.27 175.33 T
+5 F
+(expr) 276.59 175.33 T
+3 F
+( to convert the values to decimal.) 300.58 175.33 T
+1 F
+(Pr) 152.1 160.33 T
+(oblem #20:) 162.46 160.33 T
+3 F
+(In checkbuttons, radiobuttons, and menu entries, the) 211.88 160.33 T
+5 F
+(-selector) 423.4 160.33 T
+3 F
+( option) 477.37 160.33 T
+(no longer exists.) 152.1 148.33 T
+FMENDPAGE
+%%EndPage: "18" 19
+%%Page: "19" 19
+612 792 0 FMBEGINPAGE
+4 10 Q
+0 X
+0 K
+(13 Summary of Incompatibilites) 98.1 668.33 T
+0 F
+(19) 500.99 668.33 T
+98.1 660.6 512.1 660.6 2 L
+0.25 H
+0 Z
+N
+98.1 135 512.1 639 R
+7 X
+V
+2 F
+0 X
+(Solution:) 170.1 632.33 T
+3 F
+(Use) 209.25 632.33 T
+5 F
+(-selectcolor) 227.29 632.33 T
+3 F
+( instead of) 299.25 632.33 T
+5 F
+(-select) 343.39 632.33 T
+3 F
+(. T) 385.36 632.33 T
+(o specify that no indicator) 395.77 632.33 T
+(should be drawn at all, use the) 170.1 620.33 T
+5 F
+(-indicatoron) 293.9 620.33 T
+3 F
+( option instead of setting) 365.86 620.33 T
+5 F
+(-select) 467.2 620.33 T
+3 F
+(to an empty string.) 170.1 608.33 T
+1 F
+-0.12 (Pr) 152.1 593.33 P
+-0.12 (oblem #21:) 162.46 593.33 P
+3 F
+-0.12 (The indices of menu entries have changed, and operations on menu entry 0) 211.64 593.33 P
+(no longer work.) 152.1 581.33 T
+2 F
+(Solution:) 170.1 569.33 T
+3 F
+(This is because menus now have a tearof) 209.25 569.33 T
+(f entry at the top by default, and) 372.55 569.33 T
+(this occupies entry 0, so your \336rst entry is now entry 1. Y) 170.1 557.33 T
+(ou can either set the) 398.95 557.33 T
+5 F
+(-) 170.1 545.33 T
+(tearoff) 176.1 545.33 T
+3 F
+( option to 0 to eliminate the tearof) 218.07 545.33 T
+(f entry or add 1 to all the indices you) 354.2 545.33 T
+(use in your scripts.) 170.1 533.33 T
+1 F
+-0.22 (Pr) 152.1 518.33 P
+-0.22 (oblem #22:) 162.46 518.33 P
+3 F
+-0.22 (The) 211.44 518.33 P
+5 F
+-0.53 (enable) 229.26 518.33 P
+3 F
+-0.22 ( and) 265.24 518.33 P
+5 F
+-0.53 (disable) 284.23 518.33 P
+3 F
+-0.22 ( widget commands are no longer supported by) 326.21 518.33 P
+(menus.) 152.1 506.33 T
+2 F
+(Solution:) 170.1 494.33 T
+3 F
+(Use the) 209.25 494.33 T
+5 F
+(-state) 242 494.33 T
+3 F
+( con\336guration option instead.) 277.98 494.33 T
+1 F
+(Pr) 152.1 479.33 T
+(oblem #23:) 162.46 479.33 T
+3 F
+(The) 211.88 479.33 T
+5 F
+(activate) 229.92 479.33 T
+3 F
+( and) 277.89 479.33 T
+5 F
+(deactivate) 297.32 479.33 T
+3 F
+( widget commands are no longer sup-) 357.29 479.33 T
+(ported by buttons, checkbuttons, radiobuttons, and menus.) 152.1 467.33 T
+2 F
+(Solution:) 170.1 455.33 T
+3 F
+(Use the) 209.25 455.33 T
+5 F
+(-state) 242 455.33 T
+3 F
+( con\336guration option instead.) 277.98 455.33 T
+1 F
+(Pr) 152.1 440.33 T
+(oblem #24:) 162.46 440.33 T
+3 F
+(Canvas arc items no longer use the) 211.88 440.33 T
+5 F
+(-f) 353.72 440.33 T
+(ill) 365.71 440.33 T
+3 F
+( and) 383.7 440.33 T
+5 F
+(-stipple) 403.13 440.33 T
+3 F
+( options for) 451.11 440.33 T
+(drawing when the) 152.1 428.33 T
+5 F
+(-style) 226.21 428.33 T
+3 F
+( option is) 262.19 428.33 T
+5 F
+(arc) 301.9 428.33 T
+3 F
+(.) 319.89 428.33 T
+2 F
+(Solution:) 170.1 416.33 T
+3 F
+(Use the) 209.25 416.33 T
+5 F
+(-outline) 242 416.33 T
+3 F
+( and) 289.97 416.33 T
+5 F
+(-outlinestipple) 309.4 416.33 T
+3 F
+( options instead.) 399.35 416.33 T
+1 F
+-0.29 (Pr) 152.1 401.33 P
+-0.29 (oblem #25:) 162.46 401.33 P
+3 F
+-0.29 (The variable) 211.29 401.33 P
+5 F
+-0.7 (tkVersion) 263.43 401.33 P
+3 F
+-0.29 ( no longer exists \050it has been obsolete for several) 317.4 401.33 P
+(releases\051.) 152.1 389.33 T
+2 F
+(Solution:) 170.1 377.33 T
+3 F
+(Use) 209.25 377.33 T
+5 F
+(tk_version) 227.29 377.33 T
+3 F
+( instead.) 287.26 377.33 T
+1 F
+(Pr) 152.1 362.33 T
+(oblem #26:) 162.46 362.33 T
+3 F
+(The syntax of the) 211.88 362.33 T
+5 F
+(scan) 284.05 362.33 T
+3 F
+( widget commands for texts has changed.) 308.03 362.33 T
+2 F
+(Solution:) 170.1 350.33 T
+3 F
+(Modify your code to use the new syntax.) 209.25 350.33 T
+1 F
+(Pr) 152.1 335.33 T
+(oblem #27:) 162.46 335.33 T
+5 F
+(wish) 211.88 335.33 T
+3 F
+( no longer recognizes the) 235.86 335.33 T
+5 F
+(-help) 338.84 335.33 T
+3 F
+( option.) 368.82 335.33 T
+2 F
+(Solution:) 170.1 323.33 T
+3 F
+(Implement this option yourself in your) 209.25 323.33 T
+5 F
+(wish) 366.38 323.33 T
+3 F
+( scripts.) 390.37 323.33 T
+1 F
+(Pr) 152.1 308.33 T
+(oblem #28:) 162.46 308.33 T
+3 F
+(Tk 4.0 always prints real numbers such as canvas coordinates with a deci-) 211.88 308.33 T
+(mal point. This can cause syntax errors if you later use them in situations where integers) 152.1 296.33 T
+(are expected.) 152.1 284.33 T
+2 F
+(Solution:) 170.1 272.33 T
+3 F
+(Change your code so that real numbers work OK, or use the) 209.25 272.33 T
+5 F
+(expr) 451.57 272.33 T
+3 F
+( com-) 475.55 272.33 T
+(mand \050with the) 170.1 260.33 T
+5 F
+(round) 233.12 260.33 T
+3 F
+( function\051 to convert the numbers to integers.) 263.1 260.33 T
+1 F
+(Pr) 152.1 245.33 T
+(oblem #29:) 162.46 245.33 T
+3 F
+(The) 211.88 245.33 T
+5 F
+(pack info) 229.92 245.33 T
+3 F
+( command returns dif) 283.89 245.33 T
+(ferent information, and) 369.48 245.33 T
+5 F
+(pack) 464.41 245.33 T
+(newinfo) 152.1 233.33 T
+3 F
+( no longer exists.) 194.08 233.33 T
+2 F
+(Solution:) 170.1 221.33 T
+3 F
+(Use) 209.25 221.33 T
+5 F
+(pack info) 227.29 221.33 T
+3 F
+( where you used to use) 281.26 221.33 T
+5 F
+(pack newinfo) 375.08 221.33 T
+3 F
+(.) 447.04 221.33 T
+5 F
+(Pack info) 452.04 221.33 T
+3 F
+(was obsolete, so it has been eliminated.) 170.1 209.33 T
+1 F
+(Pr) 152.1 194.33 T
+(oblem #30:) 162.46 194.33 T
+3 F
+(The) 211.88 194.33 T
+5 F
+(view) 229.92 194.33 T
+3 F
+( widget command for entries no longer exists, nor does the) 253.9 194.33 T
+5 F
+(-) 152.1 182.33 T
+(scrollcommand) 158.1 182.33 T
+3 F
+( option.) 236.05 182.33 T
+2 F
+-0.29 (Solution:) 170.1 170.33 P
+3 F
+-0.29 (Use) 208.96 170.33 P
+5 F
+-0.69 (xview) 226.71 170.33 P
+3 F
+-0.29 ( where you used to use) 256.7 170.33 P
+5 F
+-0.69 (view) 348.8 170.33 P
+3 F
+-0.29 (; use) 372.78 170.33 P
+5 F
+-0.69 (-xscrollcommand) 393.31 170.33 P
+3 F
+-0.29 ( where) 483.26 170.33 P
+(you used to use) 170.1 158.33 T
+5 F
+(-scrollcommand) 234.51 158.33 T
+3 F
+(.) 318.46 158.33 T
+FMENDPAGE
+%%EndPage: "19" 20
+%%Page: "20" 20
+612 792 0 FMBEGINPAGE
+0 10 Q
+0 X
+0 K
+(20) 98.1 668.33 T
+4 F
+(Tk4.0 Overview and Porting Guide) 359.34 668.33 T
+98.1 660.6 512.1 660.6 2 L
+0.25 H
+0 Z
+N
+98.1 135 512.1 639 R
+7 X
+V
+1 F
+0 X
+(Pr) 152.1 632.33 T
+(oblem #31:) 162.46 632.33 T
+3 F
+(The) 211.88 632.33 T
+5 F
+(-padx) 229.92 632.33 T
+3 F
+( and) 259.9 632.33 T
+5 F
+(-pady) 279.33 632.33 T
+3 F
+( options are ignored for the button family of wid-) 309.31 632.33 T
+(gets if a bitmap or image is being displayed: the padding is always 0.) 152.1 620.02 T
+2 F
+-0.27 (Solution:) 170.1 608.02 P
+3 F
+-0.27 (Pack the button inside a frame, with extra padding in the frame. Or) 208.98 608.02 P
+-0.27 (, redo the) 472.94 608.02 P
+(image or bitmap to incorporate padding into it.) 170.1 595.71 T
+1 F
+(Pr) 152.1 580.71 T
+(oblem #32:) 162.46 580.71 T
+3 F
+(In radiobuttons, the) 211.88 580.71 T
+5 F
+(-value) 292.38 580.71 T
+3 F
+( option no longer defaults to the name of the) 328.36 580.71 T
+(widget; it defaults to an empty string.) 152.1 568.4 T
+2 F
+(Solution:) 170.1 556.4 T
+3 F
+(Specify the widget\325) 209.25 556.4 T
+(s name explicitly as the value of the option.) 286.98 556.4 T
+1 F
+(Pr) 152.1 541.4 T
+(oblem #33:) 162.46 541.4 T
+3 F
+(The) 211.88 541.4 T
+5 F
+(-menu) 229.92 541.4 T
+3 F
+( option for menubuttons and cascade menu entries may refer) 259.9 541.4 T
+(only to a child of the menubutton or menu.) 152.1 529.08 T
+2 F
+(Solution:) 170.1 517.08 T
+3 F
+(Rename menus to meet this requirement.) 209.25 517.08 T
+1 F
+(Pr) 152.1 502.08 T
+(oblem #34:) 162.46 502.08 T
+3 F
+(The interpretation of) 211.88 502.08 T
+5 F
+(@y) 297.09 502.08 T
+3 F
+( in menus has changed: it never returns) 309.08 502.08 T
+5 F
+(none) 467.86 502.08 T
+3 F
+(,) 491.84 502.08 T
+(even if the y-coordinate is outside the menu \050it returns the index of the closest entry\051.) 152.1 489.77 T
+2 F
+(Solution:) 170.1 477.77 T
+3 F
+(If you care about this distinction, check the y-coordinate explicitly to see if) 209.25 477.77 T
+-0.17 (it is less than 0 or greater than or equal to the window\325) 170.1 465.46 P
+-0.17 (s height \050use) 385.7 465.46 P
+5 F
+-0.41 (winfo height) 438.21 465.46 P
+3 F
+(to get the height\051.) 170.1 453.15 T
+1 F
+-0.13 (Pr) 152.1 438.15 P
+-0.13 (oblem #35:) 162.46 438.15 P
+3 F
+-0.13 (The) 211.62 438.15 P
+5 F
+-0.3 (invoke) 229.54 438.15 P
+3 F
+-0.13 ( and) 265.52 438.15 P
+5 F
+-0.3 (activate) 284.7 438.15 P
+3 F
+-0.13 ( widget commands for menus no longer post) 332.67 438.15 P
+(cascaded submenus.) 152.1 425.83 T
+2 F
+(Solution:) 170.1 413.83 T
+3 F
+(Use the) 209.25 413.83 T
+5 F
+(postcascade) 242 413.83 T
+3 F
+( widget command to post submenus.) 307.96 413.83 T
+1 F
+(Pr) 152.1 398.83 T
+(oblem #36:) 162.46 398.83 T
+3 F
+(The selection tar) 211.88 398.83 T
+(gets) 278.31 398.83 T
+5 F
+(APPLICATION) 296.91 398.83 T
+3 F
+( and) 362.87 398.83 T
+5 F
+(WINDOW_NAME) 382.3 398.83 T
+3 F
+( are no longer) 448.27 398.83 T
+(supported.) 152.1 386.52 T
+2 F
+(Solution:) 170.1 374.52 T
+3 F
+(Use tar) 209.25 374.52 T
+(gets) 237.65 374.52 T
+5 F
+(TK_APPLICATION) 256.25 374.52 T
+3 F
+( and) 340.21 374.52 T
+5 F
+(TK_WINDOW) 359.64 374.52 T
+3 F
+( instead.) 413.61 374.52 T
+1 F
+(Pr) 152.1 359.52 T
+(oblem #37:) 162.46 359.52 T
+3 F
+(There is no longer a default focus.) 211.88 359.52 T
+2 F
+(Solution:) 170.1 347.52 T
+3 F
+(None: modify your code not to depend on this feature.) 209.25 347.52 T
+1 F
+(Pr) 152.1 332.52 T
+(oblem #38:) 162.46 332.52 T
+3 F
+(The) 211.88 332.52 T
+5 F
+(focus) 229.92 332.52 T
+3 F
+( command now returns an empty string to indicate that the) 259.9 332.52 T
+(application doesn\325) 152.1 320.21 T
+(t have the input focus, instead of) 225.48 320.21 T
+5 F
+(none) 358.17 320.21 T
+3 F
+(.) 382.15 320.21 T
+2 F
+(Solution:) 170.1 308.21 T
+3 F
+(Modify your code to check for an empty string instead of) 209.25 308.21 T
+5 F
+(none) 440.47 308.21 T
+3 F
+(.) 464.46 308.21 T
+1 F
+(Pr) 152.1 293.21 T
+(oblem #39:) 162.46 293.21 T
+5 F
+(FocusIn) 211.88 293.21 T
+3 F
+( and) 253.85 293.21 T
+5 F
+(FocusOut) 273.28 293.21 T
+3 F
+( events are delivered to more windows than) 321.26 293.21 T
+(they used to be.) 152.1 280.9 T
+2 F
+-0.02 (Solution:) 170.1 268.9 P
+3 F
+-0.02 (Modify your code to use the new set of events. The old event set was some-) 209.23 268.9 P
+(what bizarre, and the new set matches more closely what happens elsewhere, such as) 170.1 256.58 T
+(with) 170.1 244.27 T
+5 F
+(Enter) 190.37 244.27 T
+3 F
+( and) 220.35 244.27 T
+5 F
+(Leave) 239.78 244.27 T
+3 F
+( events.) 269.77 244.27 T
+1 F
+-0.28 (Pr) 152.1 229.27 P
+-0.28 (oblem #40:) 162.46 229.27 P
+5 F
+-0.67 (wm maxsize) 211.32 229.27 P
+3 F
+-0.28 ( and) 270.62 229.27 P
+5 F
+-0.67 (wm minsize) 289.49 229.27 P
+3 F
+-0.28 ( no longer accept empty ar) 348.79 229.27 P
+-0.28 (guments. This) 453.52 229.27 P
+(means that you cannot use these commands to make windows non-resizable.) 152.1 216.96 T
+2 F
+(Solution:) 170.1 204.96 T
+3 F
+(Use the) 209.25 204.96 T
+5 F
+(wm resizable) 242 204.96 T
+3 F
+( command to make windows resizable.) 313.96 204.96 T
+1 F
+(Pr) 152.1 189.96 T
+(oblem #41:) 162.46 189.96 T
+3 F
+(In the placer) 211.88 189.96 T
+(, if you specify both) 261.43 189.96 T
+5 F
+(-x) 344.15 189.96 T
+3 F
+( and) 356.15 189.96 T
+5 F
+(-relx) 375.58 189.96 T
+3 F
+( then they add, instead of) 405.56 189.96 T
+(the most recent speci\336cation replacing the earlier one. Ditto for) 152.1 177.65 T
+5 F
+(-y) 407.74 177.65 T
+3 F
+( and) 419.73 177.65 T
+5 F
+(-rely) 439.16 177.65 T
+3 F
+(,) 468.5 177.65 T
+5 F
+(-width) 473.49 177.65 T
+3 F
+(and) 152.1 165.33 T
+5 F
+(-relwidth) 169.03 165.33 T
+3 F
+(, and) 223 165.33 T
+5 F
+(-height) 244.93 165.33 T
+3 F
+( and) 286.91 165.33 T
+5 F
+(-relheight) 306.33 165.33 T
+3 F
+(.) 366.3 165.33 T
+2 F
+(Solution:) 170.1 153.33 T
+3 F
+(If you no longer want one of these options to be used, set it to 0 explicitly) 209.25 153.33 T
+(.) 503.14 153.33 T
+1 F
+(Pr) 152.1 138.33 T
+(oblem #42:) 162.46 138.33 T
+3 F
+(The command \322) 211.88 138.33 T
+5 F
+(focus none) 276.27 138.33 T
+3 F
+(\323 doesn\325) 336.24 138.33 T
+(t work in Tk 4.0.) 369.64 138.33 T
+FMENDPAGE
+%%EndPage: "20" 21
+%%Page: "21" 21
+612 792 0 FMBEGINPAGE
+4 10 Q
+0 X
+0 K
+(13 Summary of Incompatibilites) 98.1 668.33 T
+0 F
+(21) 500.99 668.33 T
+98.1 660.6 512.1 660.6 2 L
+0.25 H
+0 Z
+N
+98.1 135 512.1 639 R
+7 X
+V
+2 F
+0 X
+(Solution:) 170.1 632.33 T
+3 F
+(Create a dummy widget that is never mapped and set the focus to that wid-) 209.25 632.33 T
+(get.) 170.1 620.33 T
+1 F
+(Pr) 152.1 605.33 T
+(oblem #43:) 162.46 605.33 T
+5 F
+(%D) 211.88 605.33 T
+3 F
+( substitutions are no longer supported in bindings, nor are the event) 223.87 605.33 T
+(types) 152.1 593.33 T
+5 F
+(CirculateRequest) 175.7 593.33 T
+3 F
+(,) 271.64 593.33 T
+5 F
+(Conf) 276.64 593.33 T
+(igureRequest) 300.63 593.33 T
+3 F
+(,) 372.59 593.33 T
+5 F
+(MapRequest) 377.59 593.33 T
+3 F
+(, and) 437.55 593.33 T
+5 F
+(Resiz-) 459.48 593.33 T
+(eRequest) 152.1 581.33 T
+3 F
+(.) 200.07 581.33 T
+2 F
+-0.25 (Solution:) 170.1 569.33 P
+3 F
+-0.25 (Use the name of the display instead of %D to identify a display; you can get) 209 569.33 P
+(the display name with the) 170.1 557.33 T
+5 F
+(winfo screen) 275.31 557.33 T
+3 F
+( command. The desupported event types) 347.27 557.33 T
+(never really worked anyway) 170.1 545.33 T
+(, so there should be no code that depends on them.) 282.96 545.33 T
+1 F
+(Pr) 152.1 530.33 T
+(oblem #44:) 162.46 530.33 T
+5 F
+(%) 211.88 530.33 T
+3 F
+( binding substitutions that return window identi\336ers, such as) 217.87 530.33 T
+5 F
+(%a) 461.63 530.33 T
+3 F
+( and) 473.62 530.33 T
+5 F
+(%S) 493.05 530.33 T
+3 F
+(,) 505.05 530.33 T
+(now produce hexadecimal results instead of decimal.) 152.1 518.33 T
+2 F
+(Solution:) 170.1 506.33 T
+3 F
+(Use the) 209.25 506.33 T
+5 F
+(format) 242 506.33 T
+3 F
+( command to turn them back to decimal.) 277.98 506.33 T
+1 F
+(Pr) 152.1 491.33 T
+(oblem #45:) 162.46 491.33 T
+5 F
+(Enter) 211.88 491.33 T
+3 F
+(,) 241.46 491.33 T
+5 F
+(Leave) 246.46 491.33 T
+3 F
+(,) 276.44 491.33 T
+5 F
+(FocusIn) 281.44 491.33 T
+3 F
+(, and) 323.42 491.33 T
+5 F
+(FocusOut) 345.34 491.33 T
+3 F
+( events with detail) 393.32 491.33 T
+5 F
+(Notify-) 468.83 491.33 T
+(Inferior) 152.1 479.33 T
+3 F
+( are now ignored by the binding mechanism, so they\325re not visible to T) 200.07 479.33 T
+(cl) 483.08 479.33 T
+(scripts.) 152.1 467.33 T
+2 F
+-0.13 (Solution:) 170.1 455.33 P
+3 F
+-0.13 (In most cases, T) 209.12 455.33 P
+-0.13 (cl scripts work better if these bindings are ignored. Y) 273 455.33 P
+-0.13 (ou can) 483.49 455.33 P
+(still use C code to access these events if you really need them. Or) 170.1 443.33 T
+(, create bindings on) 431.18 443.33 T
+-0.33 (the inferior windows and use) 170.1 431.33 P
+5 F
+-0.8 (NotifyAncestor) 286.96 431.33 P
+3 F
+-0.33 ( bindings on the children instead of) 370.91 431.33 P
+5 F
+(NotifyInferior) 170.1 419.33 T
+3 F
+( bindings on the parent.) 254.05 419.33 T
+FMENDPAGE
+%%EndPage: "21" 22
+%%Page: "22" 22
+612 792 0 FMBEGINPAGE
+0 10 Q
+0 X
+0 K
+(22) 98.1 668.33 T
+4 F
+(Tk4.0 Overview and Porting Guide) 359.34 668.33 T
+98.1 660.6 512.1 660.6 2 L
+0.25 H
+0 Z
+N
+98.1 135 512.1 639 R
+7 X
+V
+FMENDPAGE
+%%EndPage: "22" 23
+%%Trailer
+%%BoundingBox: 0 0 612 792
+%%Pages: 22 1
+%%DocumentFonts: Helvetica-Bold
+%%+ Times-Bold
+%%+ Times-Italic
+%%+ Times-Roman
+%%+ Helvetica
+%%+ Courier
+%%+ Courier-Oblique
diff --git a/tk/library/prolog.ps b/tk/library/prolog.ps
new file mode 100644
index 00000000000..378d5031269
--- /dev/null
+++ b/tk/library/prolog.ps
@@ -0,0 +1,284 @@
+%%BeginProlog
+50 dict begin
+
+% This is a standard prolog for Postscript generated by Tk's canvas
+% widget.
+% SCCS: @(#) prolog.ps 1.7 96/07/08 17:52:14
+
+% The definitions below just define all of the variables used in
+% any of the procedures here. This is needed for obscure reasons
+% explained on p. 716 of the Postscript manual (Section H.2.7,
+% "Initializing Variables," in the section on Encapsulated Postscript).
+
+/baseline 0 def
+/stipimage 0 def
+/height 0 def
+/justify 0 def
+/lineLength 0 def
+/spacing 0 def
+/stipple 0 def
+/strings 0 def
+/xoffset 0 def
+/yoffset 0 def
+/tmpstip null def
+
+% Define the array ISOLatin1Encoding (which specifies how characters are
+% encoded for ISO-8859-1 fonts), if it isn't already present (Postscript
+% level 2 is supposed to define it, but level 1 doesn't).
+
+systemdict /ISOLatin1Encoding known not {
+ /ISOLatin1Encoding [
+ /space /space /space /space /space /space /space /space
+ /space /space /space /space /space /space /space /space
+ /space /space /space /space /space /space /space /space
+ /space /space /space /space /space /space /space /space
+ /space /exclam /quotedbl /numbersign /dollar /percent /ampersand
+ /quoteright
+ /parenleft /parenright /asterisk /plus /comma /minus /period /slash
+ /zero /one /two /three /four /five /six /seven
+ /eight /nine /colon /semicolon /less /equal /greater /question
+ /at /A /B /C /D /E /F /G
+ /H /I /J /K /L /M /N /O
+ /P /Q /R /S /T /U /V /W
+ /X /Y /Z /bracketleft /backslash /bracketright /asciicircum /underscore
+ /quoteleft /a /b /c /d /e /f /g
+ /h /i /j /k /l /m /n /o
+ /p /q /r /s /t /u /v /w
+ /x /y /z /braceleft /bar /braceright /asciitilde /space
+ /space /space /space /space /space /space /space /space
+ /space /space /space /space /space /space /space /space
+ /dotlessi /grave /acute /circumflex /tilde /macron /breve /dotaccent
+ /dieresis /space /ring /cedilla /space /hungarumlaut /ogonek /caron
+ /space /exclamdown /cent /sterling /currency /yen /brokenbar /section
+ /dieresis /copyright /ordfeminine /guillemotleft /logicalnot /hyphen
+ /registered /macron
+ /degree /plusminus /twosuperior /threesuperior /acute /mu /paragraph
+ /periodcentered
+ /cedillar /onesuperior /ordmasculine /guillemotright /onequarter
+ /onehalf /threequarters /questiondown
+ /Agrave /Aacute /Acircumflex /Atilde /Adieresis /Aring /AE /Ccedilla
+ /Egrave /Eacute /Ecircumflex /Edieresis /Igrave /Iacute /Icircumflex
+ /Idieresis
+ /Eth /Ntilde /Ograve /Oacute /Ocircumflex /Otilde /Odieresis /multiply
+ /Oslash /Ugrave /Uacute /Ucircumflex /Udieresis /Yacute /Thorn
+ /germandbls
+ /agrave /aacute /acircumflex /atilde /adieresis /aring /ae /ccedilla
+ /egrave /eacute /ecircumflex /edieresis /igrave /iacute /icircumflex
+ /idieresis
+ /eth /ntilde /ograve /oacute /ocircumflex /otilde /odieresis /divide
+ /oslash /ugrave /uacute /ucircumflex /udieresis /yacute /thorn
+ /ydieresis
+ ] def
+} if
+
+% font ISOEncode font
+% This procedure changes the encoding of a font from the default
+% Postscript encoding to ISOLatin1. It's typically invoked just
+% before invoking "setfont". The body of this procedure comes from
+% Section 5.6.1 of the Postscript book.
+
+/ISOEncode {
+ dup length dict begin
+ {1 index /FID ne {def} {pop pop} ifelse} forall
+ /Encoding ISOLatin1Encoding def
+ currentdict
+ end
+
+ % I'm not sure why it's necessary to use "definefont" on this new
+ % font, but it seems to be important; just use the name "Temporary"
+ % for the font.
+
+ /Temporary exch definefont
+} bind def
+
+% StrokeClip
+%
+% This procedure converts the current path into a clip area under
+% the assumption of stroking. It's a bit tricky because some Postscript
+% interpreters get errors during strokepath for dashed lines. If
+% this happens then turn off dashes and try again.
+
+/StrokeClip {
+ {strokepath} stopped {
+ (This Postscript printer gets limitcheck overflows when) =
+ (stippling dashed lines; lines will be printed solid instead.) =
+ [] 0 setdash strokepath} if
+ clip
+} bind def
+
+% desiredSize EvenPixels closestSize
+%
+% The procedure below is used for stippling. Given the optimal size
+% of a dot in a stipple pattern in the current user coordinate system,
+% compute the closest size that is an exact multiple of the device's
+% pixel size. This allows stipple patterns to be displayed without
+% aliasing effects.
+
+/EvenPixels {
+ % Compute exact number of device pixels per stipple dot.
+ dup 0 matrix currentmatrix dtransform
+ dup mul exch dup mul add sqrt
+
+ % Round to an integer, make sure the number is at least 1, and compute
+ % user coord distance corresponding to this.
+ dup round dup 1 lt {pop 1} if
+ exch div mul
+} bind def
+
+% width height string StippleFill --
+%
+% Given a path already set up and a clipping region generated from
+% it, this procedure will fill the clipping region with a stipple
+% pattern. "String" contains a proper image description of the
+% stipple pattern and "width" and "height" give its dimensions. Each
+% stipple dot is assumed to be about one unit across in the current
+% user coordinate system. This procedure trashes the graphics state.
+
+/StippleFill {
+ % The following code is needed to work around a NeWSprint bug.
+
+ /tmpstip 1 index def
+
+ % Change the scaling so that one user unit in user coordinates
+ % corresponds to the size of one stipple dot.
+ 1 EvenPixels dup scale
+
+ % Compute the bounding box occupied by the path (which is now
+ % the clipping region), and round the lower coordinates down
+ % to the nearest starting point for the stipple pattern. Be
+ % careful about negative numbers, since the rounding works
+ % differently on them.
+
+ pathbbox
+ 4 2 roll
+ 5 index div dup 0 lt {1 sub} if cvi 5 index mul 4 1 roll
+ 6 index div dup 0 lt {1 sub} if cvi 6 index mul 3 2 roll
+
+ % Stack now: width height string y1 y2 x1 x2
+ % Below is a doubly-nested for loop to iterate across this area
+ % in units of the stipple pattern size, going up columns then
+ % across rows, blasting out a stipple-pattern-sized rectangle at
+ % each position
+
+ 6 index exch {
+ 2 index 5 index 3 index {
+ % Stack now: width height string y1 y2 x y
+
+ gsave
+ 1 index exch translate
+ 5 index 5 index true matrix tmpstip imagemask
+ grestore
+ } for
+ pop
+ } for
+ pop pop pop pop pop
+} bind def
+
+% -- AdjustColor --
+% Given a color value already set for output by the caller, adjusts
+% that value to a grayscale or mono value if requested by the CL
+% variable.
+
+/AdjustColor {
+ CL 2 lt {
+ currentgray
+ CL 0 eq {
+ .5 lt {0} {1} ifelse
+ } if
+ setgray
+ } if
+} bind def
+
+% x y strings spacing xoffset yoffset justify stipple DrawText --
+% This procedure does all of the real work of drawing text. The
+% color and font must already have been set by the caller, and the
+% following arguments must be on the stack:
+%
+% x, y - Coordinates at which to draw text.
+% strings - An array of strings, one for each line of the text item,
+% in order from top to bottom.
+% spacing - Spacing between lines.
+% xoffset - Horizontal offset for text bbox relative to x and y: 0 for
+% nw/w/sw anchor, -0.5 for n/center/s, and -1.0 for ne/e/se.
+% yoffset - Vertical offset for text bbox relative to x and y: 0 for
+% nw/n/ne anchor, +0.5 for w/center/e, and +1.0 for sw/s/se.
+% justify - 0 for left justification, 0.5 for center, 1 for right justify.
+% stipple - Boolean value indicating whether or not text is to be
+% drawn in stippled fashion. If text is stippled,
+% procedure StippleText must have been defined to call
+% StippleFill in the right way.
+%
+% Also, when this procedure is invoked, the color and font must already
+% have been set for the text.
+
+/DrawText {
+ /stipple exch def
+ /justify exch def
+ /yoffset exch def
+ /xoffset exch def
+ /spacing exch def
+ /strings exch def
+
+ % First scan through all of the text to find the widest line.
+
+ /lineLength 0 def
+ strings {
+ stringwidth pop
+ dup lineLength gt {/lineLength exch def} {pop} ifelse
+ newpath
+ } forall
+
+ % Compute the baseline offset and the actual font height.
+
+ 0 0 moveto (TXygqPZ) false charpath
+ pathbbox dup /baseline exch def
+ exch pop exch sub /height exch def pop
+ newpath
+
+ % Translate coordinates first so that the origin is at the upper-left
+ % corner of the text's bounding box. Remember that x and y for
+ % positioning are still on the stack.
+
+ translate
+ lineLength xoffset mul
+ strings length 1 sub spacing mul height add yoffset mul translate
+
+ % Now use the baseline and justification information to translate so
+ % that the origin is at the baseline and positioning point for the
+ % first line of text.
+
+ justify lineLength mul baseline neg translate
+
+ % Iterate over each of the lines to output it. For each line,
+ % compute its width again so it can be properly justified, then
+ % display it.
+
+ strings {
+ dup stringwidth pop
+ justify neg mul 0 moveto
+ stipple {
+
+ % The text is stippled, so turn it into a path and print
+ % by calling StippledText, which in turn calls StippleFill.
+ % Unfortunately, many Postscript interpreters will get
+ % overflow errors if we try to do the whole string at
+ % once, so do it a character at a time.
+
+ gsave
+ /char (X) def
+ {
+ char 0 3 -1 roll put
+ currentpoint
+ gsave
+ char true charpath clip StippleText
+ grestore
+ char stringwidth translate
+ moveto
+ } forall
+ grestore
+ } {show} ifelse
+ 0 spacing neg translate
+ } forall
+} bind def
+
+%%EndProlog
diff --git a/tk/library/tkfboxTest.tcl b/tk/library/tkfboxTest.tcl
new file mode 100644
index 00000000000..54b90a2307e
--- /dev/null
+++ b/tk/library/tkfboxTest.tcl
@@ -0,0 +1,1666 @@
+# tkfbox.tcl --
+#
+# Implements the "TK" standard file selection dialog box. This
+# dialog box is used on the Unix platforms whenever the tk_strictMotif
+# flag is not set.
+#
+# The "TK" standard file selection dialog box is similar to the
+# file selection dialog box on Win95(TM). The user can navigate
+# the directories by clicking on the folder icons or by
+# selectinf the "Directory" option menu. The user can select
+# files by clicking on the file icons or by entering a filename
+# in the "Filename:" entry.
+#
+# SCCS: @(#) tkfbox.tcl 1.13 97/10/01 14:51:01
+#
+# Copyright (c) 1994-1996 Sun Microsystems, Inc.
+#
+# See the file "license.terms" for information on usage and redistribution
+# of this file, and for a DISCLAIMER OF ALL WARRANTIES.
+#
+
+#----------------------------------------------------------------------
+#
+# I C O N L I S T
+#
+# This is a pseudo-widget that implements the icon list inside the
+# tkFDialog dialog box.
+#
+#----------------------------------------------------------------------
+
+# tkIconList --
+#
+# Creates an IconList widget.
+#
+proc tkIconList {w args} {
+ upvar #0 $w data
+
+ tkIconList_Config $w $args
+ tkIconList_Create $w
+}
+
+# tkIconList_Config --
+#
+# Configure the widget variables of IconList, according to the command
+# line arguments.
+#
+proc tkIconList_Config {w argList} {
+ upvar #0 $w data
+
+ # 1: the configuration specs
+ #
+ set specs {
+ {-browsecmd "" "" ""}
+ {-command "" "" ""}
+ {-multiple "" "" "0"}
+ }
+
+ # 2: parse the arguments
+ #
+ tclParseConfigSpec $w $specs "" $argList
+}
+
+# tkIconList_Create --
+#
+# Creates an IconList widget by assembling a canvas widget and a
+# scrollbar widget. Sets all the bindings necessary for the IconList's
+# operations.
+#
+proc tkIconList_Create {w} {
+ upvar #0 $w data
+
+ frame $w
+ set data(sbar) [scrollbar $w.sbar -orient horizontal \
+ -highlightthickness 0 -takefocus 0]
+ set data(canvas) [canvas $w.canvas -bd 2 -relief sunken \
+ -width 400 -height 120 -takefocus 1]
+ pack $data(sbar) -side bottom -fill x -padx 2
+ pack $data(canvas) -expand yes -fill both
+
+ $data(sbar) config -command "$data(canvas) xview"
+ $data(canvas) config -xscrollcommand "$data(sbar) set"
+
+ # Initializes the max icon/text width and height and other variables
+ #
+ set data(maxIW) 1
+ set data(maxIH) 1
+ set data(maxTW) 1
+ set data(maxTH) 1
+ set data(numItems) 0
+ set data(curItem) {}
+ set data(noScroll) 1
+
+ # Creates the event bindings.
+ #
+ bind $data(canvas) <Configure> "tkIconList_Arrange $w"
+
+ bind $data(canvas) <1> "tkIconList_Btn1 $w %x %y"
+ bind $data(canvas) <B1-Motion> "tkIconList_Motion1 $w %x %y"
+ bind $data(canvas) <Shift-1> "tkIconList_ShiftBtn1 $w %x %y"
+ bind $data(canvas) <Double-1> "tkIconList_Double1 $w %x %y"
+ bind $data(canvas) <ButtonRelease-1> "tkCancelRepeat"
+ bind $data(canvas) <B1-Leave> "tkIconList_Leave1 $w %x %y"
+ bind $data(canvas) <B1-Enter> "tkCancelRepeat"
+
+ bind $data(canvas) <Up> "tkIconList_UpDown $w -1"
+ bind $data(canvas) <Down> "tkIconList_UpDown $w 1"
+ bind $data(canvas) <Left> "tkIconList_LeftRight $w -1"
+ bind $data(canvas) <Right> "tkIconList_LeftRight $w 1"
+ bind $data(canvas) <Return> "tkIconList_ReturnKey $w"
+ bind $data(canvas) <KeyPress> "tkIconList_KeyPress $w %A"
+ bind $data(canvas) <Control-KeyPress> ";"
+ bind $data(canvas) <Alt-KeyPress> ";"
+
+ bind $data(canvas) <FocusIn> "tkIconList_FocusIn $w"
+
+ return $w
+}
+
+# tkIconList_AutoScan --
+#
+# This procedure is invoked when the mouse leaves an entry window
+# with button 1 down. It scrolls the window up, down, left, or
+# right, depending on where the mouse left the window, and reschedules
+# itself as an "after" command so that the window continues to scroll until
+# the mouse moves back into the window or the mouse button is released.
+#
+# Arguments:
+# w - The IconList window.
+#
+proc tkIconList_AutoScan {w} {
+ upvar #0 $w data
+ global tkPriv
+
+ if {![winfo exists $w]} return
+ set x $tkPriv(x)
+ set y $tkPriv(y)
+
+ if {$data(noScroll)} {
+ return
+ }
+ if {$x >= [winfo width $data(canvas)]} {
+ $data(canvas) xview scroll 1 units
+ } elseif {$x < 0} {
+ $data(canvas) xview scroll -1 units
+ } elseif {$y >= [winfo height $data(canvas)]} {
+ # do nothing
+ } elseif {$y < 0} {
+ # do nothing
+ } else {
+ return
+ }
+
+ tkIconList_Motion1 $w $x $y
+ set tkPriv(afterId) [after 50 tkIconList_AutoScan $w]
+}
+
+# Deletes all the items inside the canvas subwidget and reset the IconList's
+# state.
+#
+proc tkIconList_DeleteAll {w} {
+ upvar #0 $w data
+ upvar #0 $w:itemList itemList
+
+ $data(canvas) delete all
+ catch {unset data(selected)}
+ catch {unset data(rect)}
+ catch {unset data(list)}
+ catch {unset itemList}
+ set data(maxIW) 1
+ set data(maxIH) 1
+ set data(maxTW) 1
+ set data(maxTH) 1
+ set data(numItems) 0
+ set data(curItem) {}
+ set data(noScroll) 1
+ $data(sbar) set 0.0 1.0
+ $data(canvas) xview moveto 0
+}
+
+# Adds an icon into the IconList with the designated image and text
+#
+proc tkIconList_Add {w image text} {
+ upvar #0 $w data
+ upvar #0 $w:itemList itemList
+ upvar #0 $w:textList textList
+
+ set iTag [$data(canvas) create image 0 0 -image $image -anchor nw]
+ set tTag [$data(canvas) create text 0 0 -text $text -anchor nw \
+ -font $data(font)]
+ set rTag [$data(canvas) create rect 0 0 0 0 -fill "" -outline ""]
+
+ set b [$data(canvas) bbox $iTag]
+ set iW [expr {[lindex $b 2]-[lindex $b 0]}]
+ set iH [expr {[lindex $b 3]-[lindex $b 1]}]
+ if {$data(maxIW) < $iW} {
+ set data(maxIW) $iW
+ }
+ if {$data(maxIH) < $iH} {
+ set data(maxIH) $iH
+ }
+
+ set b [$data(canvas) bbox $tTag]
+ set tW [expr {[lindex $b 2]-[lindex $b 0]}]
+ set tH [expr {[lindex $b 3]-[lindex $b 1]}]
+ if {$data(maxTW) < $tW} {
+ set data(maxTW) $tW
+ }
+ if {$data(maxTH) < $tH} {
+ set data(maxTH) $tH
+ }
+
+ lappend data(list) [list $iTag $tTag $rTag $iW $iH $tW $tH $data(numItems)]
+ set itemList($rTag) [list $iTag $tTag $text $data(numItems)]
+ set textList($data(numItems)) [string tolower $text]
+ incr data(numItems)
+}
+
+# Places the icons in a column-major arrangement.
+#
+proc tkIconList_Arrange {w} {
+ upvar #0 $w data
+
+ if {![info exists data(list)]} {
+ if {[info exists data(canvas)] && [winfo exists $data(canvas)]} {
+ set data(noScroll) 1
+ $data(sbar) config -command ""
+ }
+ return
+ }
+
+ set W [winfo width $data(canvas)]
+ set H [winfo height $data(canvas)]
+ set pad [expr {[$data(canvas) cget -highlightthickness] + \
+ [$data(canvas) cget -bd]}]
+ if {$pad < 2} {
+ set pad 2
+ }
+
+ incr W -[expr {$pad*2}]
+ incr H -[expr {$pad*2}]
+
+ set dx [expr {$data(maxIW) + $data(maxTW) + 8}]
+ if {$data(maxTH) > $data(maxIH)} {
+ set dy $data(maxTH)
+ } else {
+ set dy $data(maxIH)
+ }
+ incr dy 2
+ set shift [expr {$data(maxIW) + 4}]
+
+ set x [expr {$pad * 2}]
+ set y [expr {$pad * 1}] ; # Why * 1 ?
+ set usedColumn 0
+ foreach sublist $data(list) {
+ set usedColumn 1
+ set iTag [lindex $sublist 0]
+ set tTag [lindex $sublist 1]
+ set rTag [lindex $sublist 2]
+ set iW [lindex $sublist 3]
+ set iH [lindex $sublist 4]
+ set tW [lindex $sublist 5]
+ set tH [lindex $sublist 6]
+
+ set i_dy [expr {($dy - $iH)/2}]
+ set t_dy [expr {($dy - $tH)/2}]
+
+ $data(canvas) coords $iTag $x [expr {$y + $i_dy}]
+ $data(canvas) coords $tTag [expr {$x + $shift}] [expr {$y + $t_dy}]
+ $data(canvas) coords $tTag [expr {$x + $shift}] [expr {$y + $t_dy}]
+ $data(canvas) coords $rTag $x $y [expr {$x+$dx}] [expr {$y+$dy}]
+
+ incr y $dy
+ if {($y + $dy) > $H} {
+ set y [expr {$pad * 1}] ; # *1 ?
+ incr x $dx
+ set usedColumn 0
+ }
+ }
+
+ if {$usedColumn} {
+ set sW [expr {$x + $dx}]
+ } else {
+ set sW $x
+ }
+
+ if {$sW < $W} {
+ $data(canvas) config -scrollregion "$pad $pad $sW $H"
+ $data(sbar) config -command ""
+ $data(canvas) xview moveto 0
+ set data(noScroll) 1
+ } else {
+ $data(canvas) config -scrollregion "$pad $pad $sW $H"
+ $data(sbar) config -command "$data(canvas) xview"
+ set data(noScroll) 0
+ }
+
+ set data(itemsPerColumn) [expr {($H-$pad)/$dy}]
+ if {$data(itemsPerColumn) < 1} {
+ set data(itemsPerColumn) 1
+ }
+
+ if {$data(curItem) != {}} {
+ tkIconList_Select $w [lindex [lindex $data(list) $data(curItem)] 2] 0
+ }
+}
+
+# Gets called when the user invokes the IconList (usually by double-clicking
+# or pressing the Return key).
+#
+proc tkIconList_Invoke {w} {
+ upvar #0 $w data
+
+ if {[string compare $data(-command) ""] && [info exists data(selected)]} {
+ eval $data(-command)
+ }
+}
+
+# tkIconList_See --
+#
+# If the item is not (completely) visible, scroll the canvas so that
+# it becomes visible.
+proc tkIconList_See {w rTag} {
+ upvar #0 $w data
+ upvar #0 $w:itemList itemList
+
+ if {$data(noScroll)} {
+ return
+ }
+ set sRegion [$data(canvas) cget -scrollregion]
+ if {![string compare $sRegion {}]} {
+ return
+ }
+
+ if {![info exists itemList($rTag)]} {
+ return
+ }
+
+
+ set bbox [$data(canvas) bbox $rTag]
+ set pad [expr {[$data(canvas) cget -highlightthickness] + \
+ [$data(canvas) cget -bd]}]
+
+ set x1 [lindex $bbox 0]
+ set x2 [lindex $bbox 2]
+ incr x1 -[expr {$pad * 2}]
+ incr x2 -[expr {$pad * 1}] ; # *1 ?
+
+ set cW [expr {[winfo width $data(canvas)] - $pad*2}]
+
+ set scrollW [expr {[lindex $sRegion 2]-[lindex $sRegion 0]+1}]
+ set dispX [expr {int([lindex [$data(canvas) xview] 0]*$scrollW)}]
+ set oldDispX $dispX
+
+ # check if out of the right edge
+ #
+ if {($x2 - $dispX) >= $cW} {
+ set dispX [expr {$x2 - $cW}]
+ }
+ # check if out of the left edge
+ #
+ if {($x1 - $dispX) < 0} {
+ set dispX $x1
+ }
+
+ if {$oldDispX != $dispX} {
+ set fraction [expr {double($dispX)/double($scrollW)}]
+ $data(canvas) xview moveto $fraction
+ }
+}
+
+proc tkIconList_SelectAtXY {w x y} {
+ upvar #0 $w data
+
+ tkIconList_Select $w [$data(canvas) find closest \
+ [$data(canvas) canvasx $x] [$data(canvas) canvasy $y]]
+}
+
+proc tkIconList_AddSelectAtXY {w x y {no_delete 0}} {
+ upvar #0 $w data
+
+ if {$data(-multiple) && [info exists data(selected)]} {
+ tkIconList_AddSelect $w [$data(canvas) find closest \
+ [$data(canvas) canvasx $x] [$data(canvas) canvasy $y]] \
+ 1 $no_delete
+ return
+ }
+ tkIconList_SelectAtXY $w $x $y
+}
+
+proc tkIconList_Select {w rTag {callBrowse 1}} {
+ upvar #0 $w data
+ upvar #0 $w:itemList itemList
+
+ if {![info exists itemList($rTag)]} {
+ return
+ }
+ set iTag [lindex $itemList($rTag) 0]
+ set tTag [lindex $itemList($rTag) 1]
+ set text [lindex $itemList($rTag) 2]
+ set serial [lindex $itemList($rTag) 3]
+
+ if {$data(-multiple) && [info exists data(rect)]} {
+ foreach r $data(rect) {
+ $data(canvas) delete $r
+ }
+ unset data(rect)
+ }
+ if ![info exists data(rect)] {
+
+ set data(rect) [$data(canvas) create rect 0 0 0 0 \
+ -fill #a0a0ff -outline #a0a0ff]
+ }
+ $data(canvas) lower $data(rect)
+ set bbox [$data(canvas) bbox $tTag]
+ eval $data(canvas) coords $data(rect) $bbox
+
+ set data(curItem) $serial
+
+ #we can't set the text to data(selected) as text, this is bugy,
+ #when the path contains blanks
+ if {$data(-multiple)} {
+ catch {unset data(selected)}
+ lappend data(selected) $text
+ } else {
+ set data(selected) $text
+ }
+
+ if {$callBrowse} {
+ if [string compare $data(-browsecmd) ""] {
+ eval $data(-browsecmd) [list $data(selected)]
+ }
+ }
+}
+
+proc tkIconList_AddSelect {w rTag {callBrowse 1} {no_delete 0}} {
+ upvar #0 $w data
+ upvar #0 $w:itemList itemList
+
+ if ![info exists itemList($rTag)] {
+ return
+ }
+ set iTag [lindex $itemList($rTag) 0]
+ set tTag [lindex $itemList($rTag) 1]
+ set text [lindex $itemList($rTag) 2]
+ set serial [lindex $itemList($rTag) 3]
+
+ if {[lsearch -exact $data(selected) $text] != -1} {
+ if {$no_delete} {
+ return
+ }
+
+ # we've clicked on an existing item, so we need to remove it
+ set i [lsearch -exact $data(selected) $text]
+ set data(selected) [lreplace $data(selected) $i $i]
+
+ # find the appropriate coordinates and remove the
+ # corresponding rectangle.
+ set tmpbbox [$data(canvas) bbox $tTag]
+ for {set i 0} {$i<[llength $data(rect)]} {incr i} {
+ set rectTag [lindex $data(rect) $i]
+ set testbbox [$data(canvas) coords $rectTag]
+ # test first two coordinates; if they're the same the
+ # entire box should match
+ if {[lindex $testbbox 0]==[lindex $tmpbbox 0] && \
+ [lindex $testbbox 1]==[lindex $tmpbbox 1]} {
+ $data(canvas) delete $rectTag
+ set data(rect) [lreplace $data(rect) $i $i]
+ break
+ }
+ }
+
+ if {$callBrowse} {
+ if [string compare $data(-browsecmd) ""] {
+ eval $data(-browsecmd) [list $data(selected)]
+ }
+ }
+ return
+ }
+
+ set tmprect [$data(canvas) create rect 0 0 0 0 \
+ -fill #a0a0ff -outline #a0a0ff]
+ lappend data(rect) $tmprect
+
+ $data(canvas) lower $tmprect
+ set bbox [$data(canvas) bbox $tTag]
+ eval $data(canvas) coords $tmprect $bbox
+
+ set data(curItem) $serial
+ lappend data(selected) $text
+
+ if {$callBrowse} {
+ if [string compare $data(-browsecmd) ""] {
+ eval $data(-browsecmd) [list $data(selected)]
+ }
+ }
+}
+
+proc tkIconList_Unselect {w} {
+ upvar #0 $w data
+
+ if [info exists data(rect)] {
+ foreach r $data(rect) {
+ $data(canvas) delete $r
+ }
+ unset data(rect)
+ }
+ if {[info exists data(selected)]} {
+ unset data(selected)
+ }
+ set data(curItem) {}
+}
+
+# Returns the selected item
+#
+proc tkIconList_Get {w} {
+ upvar #0 $w data
+
+ if {[info exists data(selected)]} {
+ return $data(selected)
+ } else {
+ return ""
+ }
+}
+
+
+proc tkIconList_Btn1 {w x y} {
+ upvar #0 $w data
+
+ focus $data(canvas)
+ tkIconList_SelectAtXY $w $x $y
+}
+
+proc tkIconList_ShiftBtn1 {w x y} {
+ upvar #0 $w data
+
+ focus $data(canvas)
+ tkIconList_AddSelectAtXY $w $x $y
+}
+
+# Gets called on button-1 motions
+#
+proc tkIconList_Motion1 {w x y} {
+ global tkPriv
+ set tkPriv(x) $x
+ set tkPriv(y) $y
+
+ tkIconList_AddSelectAtXY $w $x $y 1
+}
+
+proc tkIconList_Double1 {w x y} {
+ upvar #0 $w data
+
+ if {$data(curItem) != {}} {
+ tkIconList_Invoke $w
+ }
+}
+
+proc tkIconList_ReturnKey {w} {
+ tkIconList_Invoke $w
+}
+
+proc tkIconList_Leave1 {w x y} {
+ global tkPriv
+
+ set tkPriv(x) $x
+ set tkPriv(y) $y
+ tkIconList_AutoScan $w
+}
+
+proc tkIconList_FocusIn {w} {
+ upvar #0 $w data
+
+ if {![info exists data(list)]} {
+ return
+ }
+
+ if {$data(curItem) == {}} {
+ set rTag [lindex [lindex $data(list) 0] 2]
+ tkIconList_Select $w $rTag
+ }
+}
+
+# tkIconList_UpDown --
+#
+# Moves the active element up or down by one element
+#
+# Arguments:
+# w - The IconList widget.
+# amount - +1 to move down one item, -1 to move back one item.
+#
+proc tkIconList_UpDown {w amount} {
+ upvar #0 $w data
+
+ if {![info exists data(list)]} {
+ return
+ }
+
+ if {$data(curItem) == {}} {
+ set rTag [lindex [lindex $data(list) 0] 2]
+ } else {
+ set oldRTag [lindex [lindex $data(list) $data(curItem)] 2]
+ set rTag [lindex [lindex $data(list) [expr {$data(curItem)+$amount}]] 2]
+ if {![string compare $rTag ""]} {
+ set rTag $oldRTag
+ }
+ }
+
+ if {[string compare $rTag ""]} {
+ tkIconList_Select $w $rTag
+ tkIconList_See $w $rTag
+ }
+}
+
+# tkIconList_LeftRight --
+#
+# Moves the active element left or right by one column
+#
+# Arguments:
+# w - The IconList widget.
+# amount - +1 to move right one column, -1 to move left one column.
+#
+proc tkIconList_LeftRight {w amount} {
+ upvar #0 $w data
+
+ if {![info exists data(list)]} {
+ return
+ }
+ if {$data(curItem) == {}} {
+ set rTag [lindex [lindex $data(list) 0] 2]
+ } else {
+ set oldRTag [lindex [lindex $data(list) $data(curItem)] 2]
+ set newItem [expr {$data(curItem)+($amount*$data(itemsPerColumn))}]
+ set rTag [lindex [lindex $data(list) $newItem] 2]
+ if {![string compare $rTag ""]} {
+ set rTag $oldRTag
+ }
+ }
+
+ if {[string compare $rTag ""]} {
+ tkIconList_Select $w $rTag
+ tkIconList_See $w $rTag
+ }
+}
+
+#----------------------------------------------------------------------
+# Accelerator key bindings
+#----------------------------------------------------------------------
+
+# tkIconList_KeyPress --
+#
+# Gets called when user enters an arbitrary key in the listbox.
+#
+proc tkIconList_KeyPress {w key} {
+ global tkPriv
+
+ append tkPriv(ILAccel,$w) $key
+ tkIconList_Goto $w $tkPriv(ILAccel,$w)
+ catch {
+ after cancel $tkPriv(ILAccel,$w,afterId)
+ }
+ set tkPriv(ILAccel,$w,afterId) [after 500 tkIconList_Reset $w]
+}
+
+proc tkIconList_Goto {w text} {
+ upvar #0 $w data
+ upvar #0 $w:textList textList
+ global tkPriv
+
+ if {![info exists data(list)]} {
+ return
+ }
+
+ if {[string length $text] == 0} {
+ return
+ }
+
+ if {$data(curItem) == {} || $data(curItem) == 0} {
+ set start 0
+ } else {
+ set start $data(curItem)
+ }
+
+ set text [string tolower $text]
+ set theIndex -1
+ set less 0
+ set len [string length $text]
+ set len0 [expr {$len-1}]
+ set i $start
+
+ # Search forward until we find a filename whose prefix is an exact match
+ # with $text
+ while 1 {
+ set sub [string range $textList($i) 0 $len0]
+ if {[string compare $text $sub] == 0} {
+ set theIndex $i
+ break
+ }
+ incr i
+ if {$i == $data(numItems)} {
+ set i 0
+ }
+ if {$i == $start} {
+ break
+ }
+ }
+
+ if {$theIndex > -1} {
+ set rTag [lindex [lindex $data(list) $theIndex] 2]
+ tkIconList_Select $w $rTag 0
+ tkIconList_See $w $rTag
+ }
+}
+
+proc tkIconList_Reset {w} {
+ global tkPriv
+
+ catch {unset tkPriv(ILAccel,$w)}
+}
+
+#----------------------------------------------------------------------
+#
+# F I L E D I A L O G
+#
+#----------------------------------------------------------------------
+
+# tkFDialog --
+#
+# Implements the TK file selection dialog. This dialog is used when
+# the tk_strictMotif flag is set to false. This procedure shouldn't
+# be called directly. Call tk_getOpenFile or tk_getSaveFile instead.
+#
+proc tkFDialog {args} {
+ global tkPriv
+ global __old_dialog
+ global __old_multiple
+ set w __tk_filedialog
+ upvar #0 $w data
+
+ if {![string compare [lindex [info level 0] 0] tk_getOpenFile]} {
+ set type open
+ } else {
+ set type save
+ }
+
+ tkFDialog_Config $w $type $args
+
+ if {![string compare $data(-parent) .]} {
+ set w .$w
+ } else {
+ set w $data(-parent).$w
+ }
+
+ #because tk doesn't use window-path dependent array, it is
+ #impossible to use more than one dialog box at the same time,
+ #so we have to recreate the dialog!
+ if {[info exists __old_dialog] \
+ && ($__old_dialog != $w || $__old_multiple != $data(-multiple))} {
+ catch {destroy $w}
+ catch {destroy $__old_dialog}
+ }
+ set __old_dialog $w
+ set __old_multiple $data(-multiple)
+
+ # (re)create the dialog box if necessary
+ #
+ set new_dialog 0
+ if {![winfo exists $w]} {
+ tkFDialog_Create $w
+ set new_dialog 1
+ } elseif {[string compare [winfo class $w] TkFDialog]} {
+ destroy $w
+ tkFDialog_Create $w
+ set new_dialog 1
+ } else {
+ set data(dirMenuBtn) $w.f1.menu
+ set data(dirMenu) $w.f1.menu.menu
+ set data(upBtn) $w.f1.up
+ set data(icons) $w.icons
+ set data(ent) $w.f2.ent
+ set data(typeMenuLab) $w.f3.lab
+ set data(typeMenuBtn) $w.f3.menu
+ set data(typeMenu) $data(typeMenuBtn).m
+ set data(okBtn) $w.f2.ok
+ set data(cancelBtn) $w.f3.cancel
+ }
+ wm transient $w $data(-parent)
+ #trace variable
+ trace variable data(selectPath) w "tkFDialog_SetPath $w"
+
+ # 5. Initialize the file types menu
+ #
+ if {$data(-filetypes) != {}} {
+ $data(typeMenu) delete 0 end
+ foreach type $data(-filetypes) {
+ set title [lindex $type 0]
+ set filter [lindex $type 1]
+ $data(typeMenu) add command -label $title \
+ -command [list tkFDialog_SetFilter $w $type]
+ }
+ tkFDialog_SetFilter $w [lindex $data(-filetypes) 0]
+ $data(typeMenuBtn) config -state normal
+ $data(typeMenuLab) config -state normal
+ } else {
+ set data(filter) "*"
+ $data(typeMenuBtn) config -state disabled -takefocus 0
+ $data(typeMenuLab) config -state disabled
+ }
+
+ tkFDialog_UpdateWhenIdle $w
+
+ # 6. Withdraw the window, then update all the geometry information
+ # so we know how big it wants to be, then center the window in the
+ # display and de-iconify it.
+
+ if {$new_dialog} {
+ #center dialog, when it has been new created
+ 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 [winfo reqwidth $w]x[winfo reqheight $w]+$x+$y
+ }
+ wm title $w $data(-title)
+ wm deiconify $w
+
+ # 7. Set a grab and claim the focus too.
+
+ set oldFocus [focus]
+ set oldGrab [grab current $w]
+ if {$oldGrab != ""} {
+ set grabStatus [grab status $oldGrab]
+ }
+ grab $w
+ focus $data(ent)
+ $data(ent) delete 0 end
+ $data(ent) insert 0 $data(selectFile)
+ $data(ent) select from 0
+ $data(ent) select to end
+ $data(ent) icursor end
+
+ # 8. Wait for the user to respond, then restore the focus and
+ # return the index of the selected button. Restore the focus
+ # before deleting the window, since otherwise the window manager
+ # may take the focus away so we can't redirect it. Finally,
+ # restore any grab that was in effect.
+
+ tkwait variable tkPriv(selectFilePath)
+ catch {focus $oldFocus}
+ grab release $w
+ wm withdraw $w
+ if {$oldGrab != ""} {
+ if {$grabStatus == "global"} {
+ grab -global $oldGrab
+ } else {
+ grab $oldGrab
+ }
+ }
+ #delete the tracer, because this conflicts with multiple
+ #used dialogs
+ trace vdelete data(selectPath) w "tkFDialog_SetPath $w"
+ return $tkPriv(selectFilePath)
+}
+
+# tkFDialog_Config --
+#
+# Configures the TK filedialog according to the argument list
+#
+proc tkFDialog_Config {w type argList} {
+ upvar #0 $w data
+
+ set data(type) $type
+
+ # 1: the configuration specs
+ #
+ set specs {
+ {-defaultextension "" "" ""}
+ {-filetypes "" "" ""}
+ {-initialdir "" "" ""}
+ {-initialfile "" "" ""}
+ {-parent "" "" "."}
+ {-title "" "" ""}
+ }
+ if ![string compare $type open] {
+ # CYGNUS LOCAL: Handle -choosedir.
+ # Note: the -choosedir option is a Cygnus extension. It is not
+ # documented since it only works on Unix -- it is an
+ # implementation detail of the directory-choosing code in
+ # in libgui.
+ lappend specs {-multiple "" "" "0"} {-choosedir "" "" "0"}
+ # END CYGNUS LOCAL
+ }
+
+ # 2: default values depending on the type of the dialog
+ #
+ if {![info exists data(selectPath)]} {
+ # first time the dialog has been popped up
+ set data(selectPath) [pwd]
+ set data(selectFile) ""
+ }
+
+ # 3: parse the arguments
+ #
+ tclParseConfigSpec $w $specs "" $argList
+
+ if {![string compare $data(-title) ""]} {
+ if {![string compare $type "open"]} {
+ set data(-title) "Open"
+ } else {
+ set data(-title) "Save As"
+ }
+ }
+
+ # 4: set the default directory and selection according to the -initial
+ # settings
+ #
+ # Khamis 16-04-98
+ # When the path contains blanks, glob returns an item in a list, but
+ # data(selectPath) must be an item and not a list of items, so we
+ # must extract the item from the returned list.
+ if {[string compare $data(-initialdir) ""]} {
+ if {[file isdirectory $data(-initialdir)]} {
+ #khamis: Join result of glob to an item
+ set data(selectPath) [lindex [glob $data(-initialdir)] 0]
+ } else {
+ set data(selectPath) [pwd]
+ }
+
+ # Convert the initialdir to an absolute path name.
+
+ set old [pwd]
+ cd $data(selectPath)
+ set data(selectPath) [pwd]
+ cd $old
+ }
+ set data(selectFile) $data(-initialfile)
+
+ # 5. Parse the -filetypes option
+ #
+ set data(-filetypes) [tkFDGetFileTypes $data(-filetypes)]
+
+ if {![winfo exists $data(-parent)]} {
+ error "bad window path name \"$data(-parent)\""
+ }
+
+ # Set -multiple to a one or zero value (not other boolean types
+ # like "yes") so we can use it in tests easier.
+ if {![string compare $type save]} {
+ set data(-multiple) 0
+ # CYGNUS LOCAL: choosedir
+ # Handle -choosedir here as well.
+ set data(-choosedir) 0
+ # END CYGNUS LOCAL
+ } else {
+ if {$data(-multiple)} {
+ set data(-multiple) 1
+ }
+ }
+}
+
+proc tkFDialog_Create {w} {
+ set dataName [lindex [split $w .] end]
+ upvar #0 $dataName data
+ global tk_library
+
+ toplevel $w -class TkFDialog
+
+ # f1: the frame with the directory option menu
+ #
+ set f1 [frame $w.f1]
+ label $f1.lab -text "Directory:" -under 0
+ set data(dirMenuBtn) $f1.menu
+ set data(dirMenu) [tk_optionMenu $f1.menu [format %s(selectPath) $dataName] ""]
+ set data(upBtn) [button $f1.up]
+ if {![info exists tkPriv(updirImage)]} {
+ set tkPriv(updirImage) [image create bitmap -data {
+#define updir_width 28
+#define updir_height 16
+static char updir_bits[] = {
+ 0x00, 0x00, 0x00, 0x00, 0x80, 0x1f, 0x00, 0x00, 0x40, 0x20, 0x00, 0x00,
+ 0x20, 0x40, 0x00, 0x00, 0xf0, 0xff, 0xff, 0x01, 0x10, 0x00, 0x00, 0x01,
+ 0x10, 0x02, 0x00, 0x01, 0x10, 0x07, 0x00, 0x01, 0x90, 0x0f, 0x00, 0x01,
+ 0x10, 0x02, 0x00, 0x01, 0x10, 0x02, 0x00, 0x01, 0x10, 0x02, 0x00, 0x01,
+ 0x10, 0xfe, 0x07, 0x01, 0x10, 0x00, 0x00, 0x01, 0x10, 0x00, 0x00, 0x01,
+ 0xf0, 0xff, 0xff, 0x01};}]
+ }
+ $data(upBtn) config -image $tkPriv(updirImage)
+
+ $f1.menu config -takefocus 1 -highlightthickness 2
+
+ pack $data(upBtn) -side right -padx 4 -fill both
+ pack $f1.lab -side left -padx 4 -fill both
+ pack $f1.menu -expand yes -fill both -padx 4
+
+ # data(icons): the IconList that list the files and directories.
+ #
+ set data(icons) [tkIconList $w.icons \
+ -browsecmd "tkFDialog_ListBrowse $w" \
+ -command "tkFDialog_ListInvoke $w" \
+ -multiple "$data(-multiple)"]
+
+ # f2: the frame with the OK button and the "file name" field
+ #
+ set f2 [frame $w.f2 -bd 0]
+ label $f2.lab -text "File name:" -anchor e -width 14 -under 5 -pady 0
+ if {$data(-multiple)} {
+ $f2.lab config -text "File names:"
+ }
+ set data(ent) [entry $f2.ent]
+
+ # The font to use for the icons. The default Canvas font on Unix
+ # is just deviant.
+ global $w.icons
+ set $w.icons(font) [$data(ent) cget -font]
+
+ # f3: the frame with the cancel button and the file types field
+ #
+ set f3 [frame $w.f3 -bd 0]
+
+ # The "File of types:" label needs to be grayed-out when
+ # -filetypes are not specified. The label widget does not support
+ # grayed-out text on monochrome displays. Therefore, we have to
+ # use a button widget to emulate a label widget (by setting its
+ # bindtags)
+
+ set data(typeMenuLab) [button $f3.lab -text "Files of type:" \
+ -anchor e -width 14 -under 9 \
+ -bd [$f2.lab cget -bd] \
+ -highlightthickness [$f2.lab cget -highlightthickness] \
+ -relief [$f2.lab cget -relief] \
+ -padx [$f2.lab cget -padx] \
+ -pady [$f2.lab cget -pady]]
+ bindtags $data(typeMenuLab) [list $data(typeMenuLab) Label \
+ [winfo toplevel $data(typeMenuLab)] all]
+
+ set data(typeMenuBtn) [menubutton $f3.menu -indicatoron 1 -menu $f3.menu.m]
+ set data(typeMenu) [menu $data(typeMenuBtn).m -tearoff 0]
+ $data(typeMenuBtn) config -takefocus 1 -highlightthickness 2 \
+ -relief raised -bd 2 -anchor w
+
+ # the okBtn is created after the typeMenu so that the keyboard traversal
+ # is in the right order
+ set data(okBtn) [button $f2.ok -text OK -under 0 -width 6 \
+ -default active -pady 3]
+ set data(cancelBtn) [button $f3.cancel -text Cancel -under 0 -width 6\
+ -default normal -pady 3]
+
+ # pack the widgets in f2 and f3
+ #
+ pack $data(okBtn) -side right -padx 4 -anchor e
+ pack $f2.lab -side left -padx 4
+ pack $f2.ent -expand yes -fill x -padx 2 -pady 0
+
+ pack $data(cancelBtn) -side right -padx 4 -anchor w
+ pack $data(typeMenuLab) -side left -padx 4
+ pack $data(typeMenuBtn) -expand yes -fill x -side right
+
+ # Pack all the frames together. We are done with widget construction.
+ #
+ pack $f1 -side top -fill x -pady 4
+ pack $f3 -side bottom -fill x
+ pack $f2 -side bottom -fill x
+ pack $data(icons) -expand yes -fill both -padx 4 -pady 1
+
+ # Set up the event handlers
+ #
+ bind $data(ent) <Return> "tkFDialog_ActivateEnt $w"
+
+ $data(upBtn) config -command "tkFDialog_UpDirCmd $w"
+ $data(okBtn) config -command "tkFDialog_OkCmd $w"
+ $data(cancelBtn) config -command "tkFDialog_CancelCmd $w"
+
+ #trace variable data(selectPath) w "tkFDialog_SetPath $w"
+
+ bind $w <Alt-d> "focus $data(dirMenuBtn)"
+ bind $w <Alt-t> [format {
+ if {"[%s cget -state]" == "normal"} {
+ focus %s
+ }
+ } $data(typeMenuBtn) $data(typeMenuBtn)]
+ bind $w <Alt-n> "focus $data(ent)"
+ bind $w <KeyPress-Escape> "tkButtonInvoke $data(cancelBtn)"
+ bind $w <Alt-c> "tkButtonInvoke $data(cancelBtn)"
+ bind $w <Alt-o> "tkFDialog_InvokeBtn $w Open"
+ bind $w <Alt-s> "tkFDialog_InvokeBtn $w Save"
+
+ wm protocol $w WM_DELETE_WINDOW "tkFDialog_CancelCmd $w"
+
+ # Build the focus group for all the entries
+ #
+ tkFocusGroup_Create $w
+ tkFocusGroup_BindIn $w $data(ent) "tkFDialog_EntFocusIn $w"
+ tkFocusGroup_BindOut $w $data(ent) "tkFDialog_EntFocusOut $w"
+}
+
+# tkFDialog_UpdateWhenIdle --
+#
+# Creates an idle event handler which updates the dialog in idle
+# time. This is important because loading the directory may take a long
+# time and we don't want to load the same directory for multiple times
+# due to multiple concurrent events.
+#
+proc tkFDialog_UpdateWhenIdle {w} {
+ upvar #0 [winfo name $w] data
+
+ if {[info exists data(updateId)]} {
+ return
+ } else {
+ set data(updateId) [after idle tkFDialog_Update $w]
+ }
+}
+
+# tkFDialog_Update --
+#
+# Loads the files and directories into the IconList widget. Also
+# sets up the directory option menu for quick access to parent
+# directories.
+#
+proc tkFDialog_Update {w} {
+
+ # This proc may be called within an idle handler. Make sure that the
+ # window has not been destroyed before this proc is called
+ if {![winfo exists $w] || [string compare [winfo class $w] TkFDialog]} {
+ return
+ }
+
+ set dataName [winfo name $w]
+ upvar #0 $dataName data
+ global tk_library tkPriv
+ catch {unset data(updateId)}
+
+ set TRANSPARENT_GIF_COLOR [$w cget -bg]
+ if {![info exists tkPriv(folderImage)]} {
+ set tkPriv(folderImage) [image create photo -data {
+R0lGODlhEAAMAKEAAAD//wAAAPD/gAAAACH5BAEAAAAALAAAAAAQAAwAAAIghINhyycvVFsB
+QtmS3rjaH1Hg141WaT5ouprt2HHcUgAAOw==}]
+ set tkPriv(fileImage) [image create photo -data {
+R0lGODlhDAAMAKEAALLA3AAAAP//8wAAACH5BAEAAAAALAAAAAAMAAwAAAIgRI4Ha+IfWHsO
+rSASvJTGhnhcV3EJlo3kh53ltF5nAhQAOw==}]
+ }
+ set folder $tkPriv(folderImage)
+ set file $tkPriv(fileImage)
+
+ set appPWD [pwd]
+ if {[catch {
+ cd $data(selectPath)
+ }]} {
+ # We cannot change directory to $data(selectPath). $data(selectPath)
+ # should have been checked before tkFDialog_Update is called, so
+ # we normally won't come to here. Anyways, give an error and abort
+ # action.
+ tk_messageBox -type ok -parent $data(-parent) -message \
+ "Cannot change to the directory \"$data(selectPath)\".\nPermission denied."\
+ -icon warning
+ cd $appPWD
+ return
+ }
+
+ # Turn on the busy cursor. BUG?? We haven't disabled X events, though,
+ # so the user may still click and cause havoc ...
+ #
+ set entCursor [$data(ent) cget -cursor]
+ set dlgCursor [$w cget -cursor]
+ $data(ent) config -cursor watch
+ $w config -cursor watch
+ update idletasks
+
+ tkIconList_DeleteAll $data(icons)
+
+ # Make the dir list
+ #
+ foreach f [lsort -dictionary [glob -nocomplain .* *]] {
+ if {![string compare $f .]} {
+ continue
+ }
+ if {![string compare $f ..]} {
+ continue
+ }
+ if {[file isdir ./$f]} {
+ if {![info exists hasDoneDir($f)]} {
+ tkIconList_Add $data(icons) $folder $f
+ set hasDoneDir($f) 1
+ }
+ }
+ }
+ # Make the file list
+ #
+ if {![string compare $data(filter) *]} {
+ set files [lsort -dictionary \
+ [glob -nocomplain .* *]]
+ } else {
+ set files [lsort -dictionary \
+ [eval glob -nocomplain $data(filter)]]
+ }
+
+ set top 0
+ foreach f $files {
+ if {![file isdir ./$f]} {
+ if {![info exists hasDoneFile($f)]} {
+ tkIconList_Add $data(icons) $file $f
+ set hasDoneFile($f) 1
+ }
+ }
+ }
+
+ tkIconList_Arrange $data(icons)
+
+ # Update the Directory: option menu
+ #
+ set list ""
+ set dir ""
+ foreach subdir [file split $data(selectPath)] {
+ set dir [file join $dir $subdir]
+ lappend list $dir
+ }
+
+ $data(dirMenu) delete 0 end
+ set var [format %s(selectPath) $dataName]
+ foreach path $list {
+ $data(dirMenu) add command -label $path -command [list set $var $path]
+ }
+
+ # Restore the PWD to the application's PWD
+ #
+ cd $appPWD
+
+ # turn off the busy cursor.
+ #
+ $data(ent) config -cursor $entCursor
+ $w config -cursor $dlgCursor
+}
+
+# tkFDialog_SetPathSilently --
+#
+# Sets data(selectPath) without invoking the trace procedure
+#
+proc tkFDialog_SetPathSilently {w path} {
+ upvar #0 [winfo name $w] data
+
+ trace vdelete data(selectPath) w "tkFDialog_SetPath $w"
+ set data(selectPath) $path
+ trace variable data(selectPath) w "tkFDialog_SetPath $w"
+}
+
+
+# This proc gets called whenever data(selectPath) is set
+#
+proc tkFDialog_SetPath {w name1 name2 op} {
+ if {[winfo exists $w]} {
+ upvar #0 [winfo name $w] data
+ tkFDialog_UpdateWhenIdle $w
+ }
+}
+
+# This proc gets called whenever data(filter) is set
+#
+proc tkFDialog_SetFilter {w type} {
+ upvar #0 [winfo name $w] data
+ upvar \#0 $data(icons) icons
+
+ set data(filter) [lindex $type 1]
+ $data(typeMenuBtn) config -text [lindex $type 0] -indicatoron 1
+
+ $icons(sbar) set 0.0 0.0
+
+ tkFDialog_UpdateWhenIdle $w
+}
+
+# tkFDialogResolveFile --
+#
+# Interpret the user's text input in a file selection dialog.
+# Performs:
+#
+# (1) ~ substitution
+# (2) resolve all instances of . and ..
+# (3) check for non-existent files/directories
+# (4) check for chdir permissions
+#
+# Arguments:
+# context: the current directory you are in
+# text: the text entered by the user
+# defaultext: the default extension to add to files with no extension
+#
+# Return vaue:
+# [list $flag $directory $file]
+#
+# flag = OK : valid input
+# = PATTERN : valid directory/pattern
+# = PATH : the directory does not exist
+# = FILE : the directory exists by the file doesn't
+# exist
+# = CHDIR : Cannot change to the directory
+# = ERROR : Invalid entry
+#
+# directory : valid only if flag = OK or PATTERN or FILE
+# file : valid only if flag = OK or PATTERN
+#
+# directory may not be the same as context, because text may contain
+# a subdirectory name
+#
+proc tkFDialogResolveFile {context text defaultext} {
+
+ set appPWD [pwd]
+
+ set path [tkFDialog_JoinFile $context $text]
+
+ if {[file ext $path] == ""} {
+ set path "$path$defaultext"
+ }
+
+
+ if {[catch {file exists $path}]} {
+ # This "if" block can be safely removed if the following code
+ # stop generating errors.
+ #
+ # file exists ~nonsuchuser
+ #
+ return [list ERROR $path ""]
+ }
+
+ if {[file exists $path]} {
+ if {[file isdirectory $path]} {
+ if {[catch {
+ cd $path
+ }]} {
+ return [list CHDIR $path ""]
+ }
+ set directory [pwd]
+ set file ""
+ set flag OK
+ cd $appPWD
+ } else {
+ if {[catch {
+ cd [file dirname $path]
+ }]} {
+ return [list CHDIR [file dirname $path] ""]
+ }
+ set directory [pwd]
+ set file [file tail $path]
+ set flag OK
+ cd $appPWD
+ }
+ } else {
+ set dirname [file dirname $path]
+ if {[file exists $dirname]} {
+ if {[catch {
+ cd $dirname
+ }]} {
+ return [list CHDIR $dirname ""]
+ }
+ set directory [pwd]
+ set file [file tail $path]
+ if {[regexp {[*]|[?]} $file]} {
+ set flag PATTERN
+ } else {
+ set flag FILE
+ }
+ cd $appPWD
+ } else {
+ set directory $dirname
+ set file [file tail $path]
+ set flag PATH
+ }
+ }
+
+ return [list $flag $directory $file]
+}
+
+
+# Gets called when the entry box gets keyboard focus. We clear the selection
+# from the icon list . This way the user can be certain that the input in the
+# entry box is the selection.
+#
+proc tkFDialog_EntFocusIn {w} {
+ upvar #0 [winfo name $w] data
+
+ if {[string compare [$data(ent) get] ""]} {
+ $data(ent) selection from 0
+ $data(ent) selection to end
+ $data(ent) icursor end
+ } else {
+ $data(ent) selection clear
+ }
+
+ tkIconList_Unselect $data(icons)
+
+ if {![string compare $data(type) open]} {
+ $data(okBtn) config -text "Open"
+ } else {
+ $data(okBtn) config -text "Save"
+ }
+}
+
+proc tkFDialog_EntFocusOut {w} {
+ upvar #0 [winfo name $w] data
+
+ $data(ent) selection clear
+}
+
+
+# Verification procedure
+proc tkFDialog_VerifyFileName { w fname } {
+ upvar #0 [winfo name $w] data
+
+ set list [tkFDialogResolveFile $data(selectPath) $fname \
+ $data(-defaultextension)]
+ set flag [lindex $list 0]
+ set path [lindex $list 1]
+ set file [lindex $list 2]
+
+ case $flag {
+ OK {
+ if {![string compare $file ""]} {
+ tkFDialog_SetPathSilently $w [file dirname $path]
+ # CYGNUS LOCAL: handle choosedir
+ if {$data(-choosedir)} {
+ if {$data(-multiple)} {
+ lappend data(selectFile) [file tail $path]
+ } else {
+ set data(selectFile) [file tail $path]
+ }
+ tkFDialog_Done $w
+ } else {
+ # user has entered an existing (sub)directory
+ set data(selectPath) $path
+ $data(ent) delete 0 end
+ }
+ } else {
+ tkFDialog_SetPathSilently $w $path
+ if {$data(-multiple)} {
+ lappend data(selectFile) $file
+ } else {
+ set data(selectFile) $file
+ }
+ tkFDialog_Done $w
+ }
+ }
+ PATTERN {
+ set data(selectPath) $path
+ set data(filter) $file
+ }
+ FILE {
+ if {![string compare $data(type) open]} {
+ tk_messageBox -icon warning -type ok -parent $data(-parent) \
+ -message "File \"[file join $path $file]\" does not exist."
+ $data(ent) select from 0
+ $data(ent) select to end
+ $data(ent) icursor end
+ } else {
+ tkFDialog_SetPathSilently $w $path
+ if {$data(-multiple)} {
+ lappend data(selectFile) $file
+ } else {
+ set data(selectFile) $file
+ }
+ tkFDialog_Done $w
+ }
+ }
+ PATH {
+ tk_messageBox -icon warning -type ok -parent $data(-parent) \
+ -message "Directory \"$path\" does not exist."
+ $data(ent) select from 0
+ $data(ent) select to end
+ $data(ent) icursor end
+ }
+ CHDIR {
+ tk_messageBox -type ok -parent $data(-parent) -message \
+ "Cannot change to the directory \"$path\".\nPermission denied."\
+ -icon warning
+ $data(ent) select from 0
+ $data(ent) select to end
+ $data(ent) icursor end
+ }
+ ERROR {
+ tk_messageBox -type ok -parent $data(-parent) -message \
+ "Invalid file name \"$path\"."\
+ -icon warning
+ $data(ent) select from 0
+ $data(ent) select to end
+ $data(ent) icursor end
+ }
+ }
+}
+
+# Gets called when user presses Return in the "File name" entry.
+#
+proc tkFDialog_ActivateEnt {w} {
+ upvar #0 [winfo name $w] data
+
+ #set text [string trim [$data(ent) get]]
+ set text [$data(ent) get]
+ if {$data(-multiple)} {
+ set data(selectFile) ""
+ foreach fname $text {
+ tkFDialog_VerifyFileName $w $fname
+ }
+ } else {
+ tkFDialog_VerifyFileName $w $text
+ }
+}
+
+# Gets called when user presses the Alt-s or Alt-o keys.
+#
+proc tkFDialog_InvokeBtn {w key} {
+ upvar #0 [winfo name $w] data
+
+ if {![string compare [$data(okBtn) cget -text] $key]} {
+ tkButtonInvoke $data(okBtn)
+ }
+}
+
+# Gets called when user presses the "parent directory" button
+#
+proc tkFDialog_UpDirCmd {w} {
+ upvar #0 [winfo name $w] data
+
+ if {[string compare $data(selectPath) "/"]} {
+ set data(selectPath) [file dirname $data(selectPath)]
+ }
+}
+
+# Join a file name to a path name. The "file join" command will break
+# if the filename begins with ~
+#
+proc tkFDialog_JoinFile {path file} {
+ if {[string match {~*} $file] && [file exists $path/$file]} {
+ return [file join $path ./$file]
+ } else {
+ return [file join $path $file]
+ }
+}
+
+
+
+# Gets called when user presses the "OK" button
+#
+proc tkFDialog_OkCmd {w} {
+ upvar #0 [winfo name $w] data
+
+ set text [tkIconList_Get $data(icons)]
+ if {[string compare $text ""]} {
+ if {!$data(-multiple)} {
+ set file [tkFDialog_JoinFile $data(selectPath) $text]
+ # CYGNUS LOCAL: handle choosedir
+ if {!$data(-choosedir) && [file isdirectory $file]} {
+ tkFDialog_ListInvoke $w $text
+ return
+ }
+ }
+ }
+
+ tkFDialog_ActivateEnt $w
+}
+
+# Gets called when user presses the "Cancel" button
+#
+proc tkFDialog_CancelCmd {w} {
+ upvar #0 [winfo name $w] data
+ global tkPriv
+
+ set tkPriv(selectFilePath) ""
+}
+
+# Gets called when user browses the IconList widget (dragging mouse, arrow
+# keys, etc)
+#
+proc tkFDialog_ListBrowse {w text} {
+ upvar #0 [winfo name $w] data
+
+ if {$text == ""} {
+ return
+ }
+
+ set file [tkFDialog_JoinFile $data(selectPath) $text]
+ # CYGNUS LOCAL: handle choosedir
+ if {$data(-choosedir) || ![file isdirectory $file]} {
+ $data(ent) delete 0 end
+ $data(ent) insert 0 $text
+
+ if {![string compare $data(type) open]} {
+ $data(okBtn) config -text "Open"
+ } else {
+ $data(okBtn) config -text "Save"
+ }
+ } else {
+ $data(okBtn) config -text "Open"
+ }
+}
+
+# Gets called when user invokes the IconList widget (double-click,
+# Return key, etc)
+#
+proc tkFDialog_ListInvoke {w text} {
+ upvar #0 [winfo name $w] data
+
+ if {$text == ""} {
+ return
+ }
+
+ if {$data(-multiple)} {
+ set file [tkFDialog_JoinFile $data(selectPath) [lindex $text 0]]
+ } else {
+ set file [tkFDialog_JoinFile $data(selectPath) $text]
+ }
+
+ if {[file isdirectory $file]} {
+ set appPWD [pwd]
+ if {[catch {cd $file}]} {
+ tk_messageBox -type ok -parent $data(-parent) -message \
+ "Cannot change to the directory \"$file\".\nPermission denied."\
+ -icon warning
+ } else {
+ cd $appPWD
+ set data(selectPath) $file
+ }
+ } else {
+ if {$data(-multiple)} {
+ set data(selectFile) [list $file]
+ } else {
+ set data(selectFile) $file
+ }
+ tkFDialog_Done $w
+ }
+}
+
+# tkFDialog_Done --
+#
+# Gets called when user has input a valid filename. Pops up a
+# dialog box to confirm selection when necessary. Sets the
+# tkPriv(selectFilePath) variable, which will break the "tkwait"
+# loop in tkFDialog and return the selected filename to the
+# script that calls tk_getOpenFile or tk_getSaveFile
+#
+proc tkFDialog_Done {w {selectFilePath ""}} {
+ upvar #0 [winfo name $w] data
+ global tkPriv
+
+ if {![string compare $selectFilePath ""]} {
+ if {$data(-multiple)} {
+ set selectFilePath {}
+ foreach f $data(selectFile) {
+ lappend selectFilePath [file join $data(selectPath) $f]
+ }
+ } else {
+ set selectFilePath [tkFDialog_JoinFile $data(selectPath) \
+ $data(selectFile)]
+ }
+ set tkPriv(selectFile) $data(selectFile)
+ set tkPriv(selectPath) $data(selectPath)
+
+ if {[file exists $selectFilePath] &&
+ ![string compare $data(type) save]} {
+
+ set reply [tk_messageBox -icon warning -type yesno\
+ -parent $data(-parent) -message "File\
+ \"$selectFilePath\" already exists.\nDo\
+ you want to overwrite it?"]
+ if {![string compare $reply "no"]} {
+ return
+ }
+ }
+ }
+ set tkPriv(selectFilePath) $selectFilePath
+}
+
diff --git a/tk/mac/tkMacProjects.sit.hqx b/tk/mac/tkMacProjects.sit.hqx
new file mode 100644
index 00000000000..dc1bbb76460
--- /dev/null
+++ b/tk/mac/tkMacProjects.sit.hqx
@@ -0,0 +1,2534 @@
+(This file must be converted with BinHex 4.0)
+:%A4V6@&M8(*[DQ9MG(-ZFfPd!&0*9%46593K!*!$!GZ0!*!%JHC6593K!!%!!GZ
+0FNaKG3)!N!3@!!!J)!edDdeKBe"bEfTPBh4c!*!5LQ3!N!2(!@d#2!-`!*!$"3#
+3$iB!!!)!rj!%!`#Y0PVEX)6[F3#3"3e51`#3"3(E"rrRrr`!N!BRX5!J$80A-6%
+J8(*[DQ9MG(-!N",he`!!!CF!%`--!GB!N!-1!*!$&J!"8'`!N!-@!*!$pJ!!!J$
+rN!3$!,#$[i@`JlqE!*!&"lTJ!*!&!8pfrr$rq!#3"KBU$3d10MKVT90TEA"XC94
+V,VN!N"&jF!#3%BB!!!l-!*!$K[q3"%e08&*$9dP&!3#VEaVfX!1Q)J!!-k-!!!T
+F!!!+,3!!!cP9FlGr!*!'Yj-0`+fI6FbZ0lP4lQD(hb`*TjIAVERC%hD5P6#bT5r
+cmVNVTa*kPK'H%4UH'TlT-8hEq+XQ5Bjl%EBCB4'HEXU2X$VfAFmff8Bf)pcEaii
+FGj0Mj8@1%8SfiB4YXQQEF-)))k`MM($#Sf6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A4V6@&M8(*
+[DQ9MG(-!N"I(!@d#2!-`!*!$!3!"cmJ!N!F@!*!$KJ!!!J$rN!3$!+df@YZ`K1p
+a!*!&$9)l!*!&!GUArqIrr!#3"Ri#KGB!!!:
diff --git a/tk/mac/tkMacProlog.c b/tk/mac/tkMacProlog.c
new file mode 100644
index 00000000000..21cf67c5551
--- /dev/null
+++ b/tk/mac/tkMacProlog.c
@@ -0,0 +1,61 @@
+/*
+ * tkMacProlog.c --
+ *
+ * Implements a method on the Macintosh to get the prolog
+ * from the resource fork of our application (or the shared
+ * library).
+ *
+ * Copyright (c) 1996-1997 Sun Microsystems, Inc.
+ *
+ * See the file "license.terms" for information on usage and redistribution
+ * of this file, and for a DISCLAIMER OF ALL WARRANTIES.
+ *
+ * SCCS: @(#) tkMacProlog.c 1.6 97/05/21 10:01:07
+ */
+
+#include "tkInt.h"
+#include "tclMacInt.h"
+#include <Resources.h>
+
+/*
+ *--------------------------------------------------------------
+ *
+ * TkGetNativeProlog --
+ *
+ * Locate and load the postscript prolog from the resource
+ * fork of the application. If it can't be found then we
+ * will try looking for the file in the system folder.
+ *
+ * Results:
+ * A standard Tcl Result. If everything is OK the prolog
+ * will be located in the result string of the interpreter.
+ *
+ * Side effects:
+ * None.
+ *
+ *--------------------------------------------------------------
+ */
+
+int
+TkGetNativeProlog(
+ Tcl_Interp *interp) /* Places the prolog in the result. */
+{
+ Handle resource;
+ char *stringPtr;
+ int releaseIt;
+
+
+ resource = Tcl_MacFindResource(interp, 'TEXT', "prolog", -1,
+ NULL, &releaseIt);
+
+ if (resource != NULL) {
+ stringPtr = Tcl_MacConvertTextResource(resource);
+ Tcl_SetResult(interp, stringPtr, TCL_DYNAMIC);
+ if (releaseIt) {
+ ReleaseResource(resource);
+ }
+ return TCL_OK;
+ } else {
+ return TkGetProlog(interp);
+ }
+}
diff --git a/tk/tests/all b/tk/tests/all
new file mode 100644
index 00000000000..b5a59332a71
--- /dev/null
+++ b/tk/tests/all
@@ -0,0 +1,73 @@
+# This file contains a top-level script to run all of the Tcl
+# tests. Execute it by invoking "source all" when running tclTest
+# in this directory.
+#
+
+# RCS: @(#) $Id$
+# If the srcdir variable exists, tests are looked for in that
+# directory. Otherwise they are looked for in ".".
+
+if {! [info exists srcdir]} then {
+ set srcdir .
+}
+
+# Always explicitly load `defs', so tests don't have to. This avoids
+# the need for each .test file to know about $srcdir.
+
+source $srcdir/defs
+
+switch $tcl_platform(platform) {
+ "windows" {
+ # Tests that cause tk to crash under windows.
+ set crash {}
+
+ # Tests that fail under windows.
+
+ set fail { grid.test }
+
+ if {! [info exist exclude] } {
+ set exclude [string tolower "$crash $fail"]
+ }
+ }
+ "macintosh" {
+ set x [pwd]
+ cd $tk_library
+ set tk_library [pwd]
+ cd $x
+
+ # Tests that cause tk to crash under mac.
+ set crash {}
+
+ # Tests that fail under mac.
+ set fail {bind.test entry.test send.test textDisp.test}
+
+ set exclude [string tolower "$crash $fail"]
+ }
+ "unix" {
+ set exclude ""
+ }
+}
+
+if {$tcl_platform(os) == "Win32s"} {
+ set tests [lsort [glob $srcdir/*.tes]]
+} else {
+ set tests [lsort [glob $srcdir/*.test]]
+}
+
+foreach i $tests {
+ set tail [file tail $i]
+ if [string match l.*.test $tail] {
+ # This is an SCCS lock file; ignore it.
+ continue
+ }
+ if [lsearch $exclude [string tolower $tail]]>=0 {
+ # Do not source this file; it exercises a known bug at this time.
+ puts stdout "Skipping $tail"
+ continue
+ }
+ puts stdout $tail
+ if [catch {source $i} msg] {
+ puts $msg
+ }
+}
+puts "Tests all done"
diff --git a/tk/tests/defs b/tk/tests/defs
new file mode 100644
index 00000000000..b0387a34352
--- /dev/null
+++ b/tk/tests/defs
@@ -0,0 +1,371 @@
+# This file contains support code for the Tcl test suite. It is
+# normally sourced by the individual files in the test suite before
+# they run their tests. This improved approach to testing was designed
+# and initially implemented by Mary Ann May-Pumphrey of Sun Microsystems.
+#
+# Copyright (c) 1994-1997 Sun Microsystems, Inc.
+#
+# See the file "license.terms" for information on usage and redistribution
+# of this file, and for a DISCLAIMER OF ALL WARRANTIES.
+#
+# RCS: @(#) $Id$
+
+if ![info exists srcdir] {
+ set srcdir .
+}
+
+if ![info exists VERBOSE] {
+ set VERBOSE 0
+}
+if ![info exists TESTS] {
+ set TESTS {}
+}
+
+tk appname tktest
+wm title . tktest
+
+# Check configuration information that will determine which tests
+# to run. To do this, create an array testConfig. Each element
+# has a 0 or 1 value, and the following elements are defined:
+# unixOnly - 1 means this is a UNIX platform, so it's OK
+# to run tests that only work under UNIX.
+# macOnly - 1 means this is a Mac platform, so it's OK
+# to run tests that only work on Macs.
+# pcOnly - 1 means this is a PC platform, so it's OK to
+# run tests that only work on PCs.
+# unixOrPc - 1 means this is a UNIX or PC platform.
+# macOrPc - 1 means this is a Mac or PC platform.
+# macOrUnix - 1 means this is a Mac or UNIX platform.
+# nonPortable - 1 means this the tests are being running in
+# the master Tcl/Tk development environment;
+# Some tests are inherently non-portable because
+# they depend on things like word length, file system
+# configuration, window manager, etc. These tests
+# are only run in the main Tcl development directory
+# where the configuration is well known. The presence
+# of the file "doAllTests" in this directory indicates
+# that it is safe to run non-portable tests.
+# fonts - 1 means that this platform uses fonts with
+# well-know geometries, so it is safe to run
+# tests that depend on particular font sizes.
+
+catch {unset testConfig}
+
+set testConfig(unixOnly) [expr {$tcl_platform(platform) == "unix"}]
+set testConfig(macOnly) [expr {$tcl_platform(platform) == "macintosh"}]
+set testConfig(pcOnly) [expr {$tcl_platform(platform) == "windows"}]
+
+set testConfig(unix) $testConfig(unixOnly)
+set testConfig(mac) $testConfig(macOnly)
+set testConfig(pc) $testConfig(pcOnly)
+
+set testConfig(unixOrPc) [expr $testConfig(unixOnly) || $testConfig(pcOnly)]
+set testConfig(macOrPc) [expr $testConfig(macOnly) || $testConfig(pcOnly)]
+set testConfig(macOrUnix) [expr $testConfig(macOnly) || $testConfig(unixOnly)]
+
+set testConfig(nonPortable) [expr [file exists doAllTests] || [file exists DOALLT~1]]
+
+set testConfig(nt) [expr {$tcl_platform(os) == "Windows NT"}]
+set testConfig(95) [expr {$tcl_platform(os) == "Windows 95"}]
+set testConfig(win32s) [expr {$tcl_platform(os) == "Win32s"}]
+
+# The following config switches are used to mark tests that should work,
+# but have been temporarily disabled on certain platforms because they don't.
+
+set testConfig(tempNotPc) [expr !$testConfig(pc)]
+set testConfig(tempNotMac) [expr !$testConfig(mac)]
+set testConfig(tempNotUnix) [expr !$testConfig(unix)]
+
+# The following config switches are used to mark tests that crash on
+# certain platforms, so that they can be reactivated again when the
+# underlying problem is fixed.
+
+set testConfig(pcCrash) [expr !$testConfig(pc)]
+set testConfig(win32sCrash) [expr !$testConfig(win32s)]
+set testConfig(macCrash) [expr !$testConfig(mac)]
+set testConfig(unixCrash) [expr !$testConfig(unix)]
+
+set testConfig(fonts) 1
+catch {destroy .e}
+entry .e -width 0 -font {Helvetica -12} -bd 1
+.e insert end "a.bcd"
+if {([winfo reqwidth .e] != 37) || ([winfo reqheight .e] != 20)} {
+ set testConfig(fonts) 0
+}
+destroy .e .t
+text .t -width 80 -height 20 -font {Times -14} -bd 1
+pack .t
+.t insert end "This is\na dot."
+update
+set x [list [.t bbox 1.3] [.t bbox 2.5]]
+destroy .t
+if {[string match {{22 3 6 15} {31 18 [34] 15}} $x] == 0} {
+ set testConfig(fonts) 0
+}
+
+if {$testConfig(nonPortable) == 0} {
+ puts "(will skip non-portable tests)"
+}
+if {$testConfig(fonts) == 0} {
+ puts "(will skip font-sensitive tests: this system has unexpected font geometries)"
+}
+
+trace variable testConfig r safeFetch
+
+proc safeFetch {n1 n2 op} {
+ global testConfig
+
+ if {($n2 != {}) && ([info exists testConfig($n2)] == 0)} {
+ set testConfig($n2) 0
+ }
+}
+
+# If there is no "memory" command (because memory debugging isn't
+# enabled), generate a dummy command that does nothing.
+
+if {[info commands memory] == ""} {
+ proc memory args {}
+}
+
+proc print_verbose {name description script code answer} {
+ puts stdout "\n"
+ puts stdout "==== $name $description"
+ puts stdout "==== Contents of test case:"
+ puts stdout "$script"
+ if {$code != 0} {
+ if {$code == 1} {
+ puts stdout "==== Test generated error:"
+ puts stdout $answer
+ } elseif {$code == 2} {
+ puts stdout "==== Test generated return exception; result was:"
+ puts stdout $answer
+ } elseif {$code == 3} {
+ puts stdout "==== Test generated break exception"
+ } elseif {$code == 4} {
+ puts stdout "==== Test generated continue exception"
+ } else {
+ puts stdout "==== Test generated exception $code; message was:"
+ puts stdout $answer
+ }
+ } else {
+ puts stdout "==== Result was:"
+ puts stdout "$answer"
+ }
+}
+
+# test --
+# This procedure runs a test and prints an error message if the
+# test fails. If VERBOSE has been set, it also prints a message
+# even if the test succeeds. The test will be skipped if it
+# doesn't match the TESTS variable, or if one of the elements
+# of "constraints" turns out not to be true.
+#
+# Arguments:
+# name - Name of test, in the form foo-1.2.
+# description - Short textual description of the test, to
+# help humans understand what it does.
+# constraints - A list of one or more keywords, each of
+# which must be the name of an element in
+# the array "testConfig". If any of these
+# elements is zero, the test is skipped.
+# This argument may be omitted.
+# script - Script to run to carry out the test. It must
+# return a result that can be checked for
+# correctness.
+# answer - Expected result from script.
+
+proc test {name description script answer args} {
+ global VERBOSE TESTS testConfig
+ if {[string compare $TESTS ""] != 0} {
+ set ok 0
+ foreach test $TESTS {
+ if {[string match $test $name]} {
+ set ok 1
+ break
+ }
+ }
+ if {!$ok} {
+ return
+ }
+ }
+ set i [llength $args]
+ if {$i == 0} {
+ # Empty body
+ } elseif {$i == 1} {
+ # "constraints" argument exists; shuffle arguments down, then
+ # make sure that the constraints are satisfied.
+
+ set constraints $script
+ set script $answer
+ set answer [lindex $args 0]
+ set doTest 0
+ if {[string match {*[$\[]*} $constraints] != 0} {
+ # full expression, e.g. {$foo > [info tclversion]}
+
+ catch {set doTest [uplevel #0 expr $constraints]}
+ } elseif {[regexp {[^.a-zA-Z0-9 ]+} $constraints] != 0} {
+ # something like {a || b} should be turned into
+ # $testConfig(a) || $testConfig(b).
+
+ regsub -all {[.a-zA-Z0-9]+} $constraints {$testConfig(&)} c
+ catch {set doTest [eval expr $c]}
+ } else {
+ # just simple constraints such as {unixOnly fonts}.
+
+ set doTest 1
+ foreach constraint $constraints {
+ if {![info exists testConfig($constraint)]
+ || !$testConfig($constraint)} {
+ set doTest 0
+ break
+ }
+ }
+ }
+ if {$doTest == 0} {
+ if {$VERBOSE} {
+ puts stdout "++++ $name SKIPPED: $constraints"
+ }
+ return
+ }
+ } else {
+ error "wrong # args: must be \"test name description ?constraints? script answer\""
+ }
+ memory tag $name
+ set code [catch {uplevel $script} result]
+ if {$code != 0} {
+ print_verbose $name $description $script $code $result
+ } elseif {[string compare $result $answer] == 0} {
+ if {$VERBOSE} then {
+ if {$VERBOSE > 0} {
+ print_verbose $name $description $script $code $result
+ }
+ if {$VERBOSE != -2} {
+ puts stdout "++++ $name PASSED"
+ }
+ }
+ } else {
+ print_verbose $name $description $script $code $result
+ puts stdout "---- Result should have been:"
+ puts stdout "$answer"
+ puts stdout "---- $name FAILED"
+ }
+}
+
+proc dotests {file args} {
+ global TESTS
+ set savedTests $TESTS
+ set TESTS $args
+ source $file
+ set TESTS $savedTests
+}
+
+# If the main window isn't already mapped (e.g. because the tests are
+# being run automatically) , specify a precise size for it so that the
+# user won't have to position it manually.
+
+if {![winfo ismapped .]} {
+ wm geometry . +0+0
+ update
+}
+
+# The following code can be used to perform tests involving a second
+# process running in the background.
+
+# Locate tktest executable
+
+set tktest [info nameofexecutable]
+if {$tktest == "{}"} {
+ set tktest {}
+ puts "Unable to find tktest executable, skipping multiple process tests."
+}
+
+# Create background process
+
+proc setupbg {{args ""}} {
+ global tktest fd bgData
+ if {$tktest == ""} {
+ error "you're not running tktest so setupbg should not have been called"
+ }
+ if {[info exists fd] && ($fd != "")} {
+ cleanupbg
+ }
+ set fd [open "|[list $tktest -geometry +0+0 -name tktest] $args" r+]
+ puts $fd "puts foo; flush stdout"
+ flush $fd
+ if {[gets $fd data] < 0} {
+ error "unexpected EOF from \"$tktest\""
+ }
+ if [string compare $data foo] {
+ error "unexpected output from background process \"$data\""
+ }
+ fileevent $fd readable bgReady
+}
+
+# Send a command to the background process, catching errors and
+# flushing I/O channels
+proc dobg {command} {
+ global fd bgData bgDone
+ puts $fd "catch [list $command] msg; update; puts \$msg; puts **DONE**; flush stdout"
+ flush $fd
+ set bgDone 0
+ set bgData {}
+ tkwait variable bgDone
+ set bgData
+}
+
+# Data arrived from background process. Check for special marker
+# indicating end of data for this command, and make data available
+# to dobg procedure.
+proc bgReady {} {
+ global fd bgData bgDone
+ set x [gets $fd]
+ if [eof $fd] {
+ fileevent $fd readable {}
+ set bgDone 1
+ } elseif {$x == "**DONE**"} {
+ set bgDone 1
+ } else {
+ append bgData $x
+ }
+}
+
+# Exit the background process, and close the pipes
+proc cleanupbg {} {
+ global fd
+ catch {
+ puts $fd "exit"
+ close $fd
+ }
+ set fd ""
+}
+
+# Clean up focus after using generate event, which
+# can leave the window manager with the wrong impression
+# about who thinks they have the focus. (BW)
+
+proc fixfocus {} {
+ catch {destroy .focus}
+ toplevel .focus
+ wm geometry .focus +0+0
+ entry .focus.e
+ .focus.e insert 0 "fixfocus"
+ pack .focus.e
+ update
+ focus -force .focus.e
+ destroy .focus
+}
+
+proc makeFile {contents name} {
+ set fd [open $name w]
+ fconfigure $fd -translation lf
+ if {[string index $contents [expr [string length $contents] - 1]] == "\n"} {
+ puts -nonewline $fd $contents
+ } else {
+ puts $fd $contents
+ }
+ close $fd
+}
+
+proc removeFile {name} {
+ file delete -- $name
+}
diff --git a/tk/tests/script b/tk/tests/script
new file mode 100644
index 00000000000..f1e1d9d2766
--- /dev/null
+++ b/tk/tests/script
@@ -0,0 +1,14 @@
+
+ interp create x
+ x eval {set argc 2}
+ x eval {set argv "-geometry 10x10+0+0"}
+ x eval {load {} Tk}
+ x eval {
+ button .b -text hello
+ bind .b <Destroy> foo
+ }
+ x alias foo destroy_x
+ proc destroy_x {} {interp delete x}
+ update
+ exit
+
diff --git a/tk/tests/visual b/tk/tests/visual
new file mode 100644
index 00000000000..b20f02cf5aa
--- /dev/null
+++ b/tk/tests/visual
@@ -0,0 +1,81 @@
+#!/usr/local/bin/wish -f
+#
+# This script displays provides visual tests for many of Tk's features.
+# Each test displays a window with various information in it, along
+# with instructions about how the window should appear. You can look
+# at the window to make sure it appears as expected. Individual tests
+# are kept in separate ".tcl" files in this directory.
+#
+# RCS: @(#) $Id$
+
+set auto_path ". $auto_path"
+wm title . "Visual Tests for Tk"
+
+#-------------------------------------------------------
+# The code below create the main window, consisting of a
+# menu bar and a message explaining the basic operation
+# of the program.
+#-------------------------------------------------------
+
+frame .menu -relief raised -borderwidth 1
+message .msg -font {Times 18} -relief raised -width 4i \
+ -borderwidth 1 -text "This application provides a collection of visual tests for the Tk toolkit. Each menu entry invokes a test, which displays information on the screen. You can then verify visually that the information is being displayed in the correct way. The tests under the \"Postscript\" menu exercise the Postscript-generation capabilities of canvas widgets."
+
+pack .menu -side top -fill x
+pack .msg -side bottom -expand yes -fill both
+
+#-------------------------------------------------------
+# The code below creates all the menus, which invoke procedures
+# to create particular demonstrations of various widgets.
+#-------------------------------------------------------
+
+menubutton .menu.file -text "File" -menu .menu.file.m
+menu .menu.file.m
+.menu.file.m add command -label "Quit" -command exit
+
+menubutton .menu.group1 -text "Group 1" -menu .menu.group1.m
+menu .menu.group1.m
+.menu.group1.m add command -label "Canvas arcs" -command {source arc.tcl}
+.menu.group1.m add command -label "Beveled borders in text widgets" \
+ -command {source bevel.tcl}
+.menu.group1.m add command -label "Colormap management" \
+ -command {source cmap.tcl}
+.menu.group1.m add command -label "Label/button geometry" \
+ -command {source butGeom.tcl}
+.menu.group1.m add command -label "Label/button colors" \
+ -command {source butGeom2.tcl}
+
+menubutton .menu.ps -text "Canvas Postscript" -menu .menu.ps.m
+menu .menu.ps.m
+.menu.ps.m add command -label "Rectangles and other graphics" \
+ -command {source canvPsGrph.tcl}
+.menu.ps.m add command -label "Text" \
+ -command {source canvPsText.tcl}
+.menu.ps.m add command -label "Bitmaps" \
+ -command {source canvPsBmap.tcl}
+.menu.ps.m add command -label "Arcs" \
+ -command {source canvPsArc.tcl}
+
+pack .menu.file .menu.group1 .menu.ps -side left -padx 1m
+
+# Set up for keyboard-based menu traversal
+
+bind . <Any-FocusIn> {
+ if {("%d" == "NotifyVirtual") && ("%m" == "NotifyNormal")} {
+ focus .menu
+ }
+}
+tk_menuBar .menu .menu.file .menu.group1 .menu.ps
+
+# The following procedure is invoked to print the contents of a canvas:
+
+proc lpr c {
+ exec rm -f tmp.ps
+ $c postscript -file tmp.ps
+ exec lpr tmp.ps
+}
+
+# Set up a class binding to allow objects to be deleted from a canvas
+# by clicking with mouse button 1:
+
+bind Canvas <1> {%W delete [%W find closest %x %y]}
diff --git a/tk/unix/porting.notes b/tk/unix/porting.notes
new file mode 100644
index 00000000000..c5332ec413c
--- /dev/null
+++ b/tk/unix/porting.notes
@@ -0,0 +1,86 @@
+This file contains a collection of notes that various people have
+provided about porting Tk to various machines and operating systems.
+I don't have personal access to any of these machines, so I make
+no guarantees that the notes are correct, complete, or up-to-date.
+If you see the word "I" in any explanations, it refers to the person
+who contributed the information, not to me; this means that I
+probably can't answer any questions about any of this stuff. In
+some cases, a person has volunteered to act as a contact point for
+questions about porting Tcl to a particular machine; in these
+cases the person's name and e-mail address are listed. I'm very
+interested in getting new porting information to add to the file;
+please mail updates to "john.ousterhout@eng.sun.com".
+
+This file reflects information provided for Tk 4.0 and later releases.
+If there is no information for your configuration in this file, check
+the file "porting.old" too; it contains information that was
+submitted for Tk 3.6 and earlier releases, and some of that information
+may still be valid.
+
+A new porting database has recently become available on the Web at
+the following URL:
+ http://www.sunlabs.com/cgi-bin/tcl/info.4.0
+This page provides information about the platforms on which Tcl 7.4
+and Tk 4.0 have been compiled and what changes were needed to get Tcl
+and Tk to compile. You can also add new entries to that database
+when you install Tcl and Tk on a new platform. The Web database is
+likely to be more up-to-date than this file.
+
+RCS: @(#) $Id$
+
+--------------------------------------------
+Solaris, various versions
+--------------------------------------------
+
+1. If typing "make test" results in an error message saying that
+there are no "*.test" files, or you get lots of globbing errors,
+it's probably because your system doesn't have cc installed and
+you used gcc. In order for this to work, you have to set your
+CC environment variable to gcc and your CPP environment variable
+to "gcc -E" before running the configure script.
+
+2. Make sure that /usr/ucb is not in your PATH or LD_LIBRARY_PATH
+environment variables; this will cause confusion between the new
+Solaris libraries and older UCB versions (Tk will expect one version
+and get another).
+
+3. On 486 PCs with Solaris 2.4, when compiling with gcc 2.6.0,
+tkMessage.c appears to hang gcc. If the -O switch is removed
+then it compiles fine.
+
+--------------------------------------------
+486 PCs, Solaris 2.4
+--------------------------------------------
+
+When compiling with gcc 2.6.0, tkMessage.c appears to hang gcc.
+If the -O switch is removed then it compiles fine.
+
+--------------------------------------------
+SGI machines, IRIX 5.2, 5.3, IRIX64 6.0.1
+--------------------------------------------
+
+1. Add "-D_BSD_TIME" to CFLAGS in Makefile. This avoids type conflicts
+in the prototype for the gettimeofday procedure.
+
+2. If you're running under Irix 6.x and wish dumps core, try
+removing -O from the CFLAGS in Makefile and recompiling; compiler
+optimizations seem to cause problems on some machines.
+
+--------------------------------------------
+QNX 4.22
+--------------------------------------------
+
+All of the source files built as is. All I had to do was edit the
+Makefile generated by ./configure to specify where the X11 libraries
+were (ie, I added in -L/usr/X11/lib)
+
+--------------------------------------------
+HP-UX
+--------------------------------------------
+
+There are problems compiling Tk gcc (version 2.7.2) and the HP assembler.
+The problem is that if static functions are called using a pointer reference,
+double arguments are not transferred correctly into the function. That can
+be fixed by making all those functions global. This happens with the
+ScaleXxx() and TranslateXxx() functions for all canvas item types.
+The simplest fix is configure gcc to use the GNU assembler.
diff --git a/tk/win/Defines.h b/tk/win/Defines.h
new file mode 100644
index 00000000000..2aa3b6bb6db
--- /dev/null
+++ b/tk/win/Defines.h
@@ -0,0 +1,5175 @@
+/*
+ Defines.h
+
+ Windows32 API definitions
+
+ Copyright (C) 1996, 1997 Free Software Foundation, Inc.
+
+ Author: Scott Christley <scottc@net-community.com>
+
+ This file is part of the Windows32 API Library.
+
+ This library is free software; you can redistribute it and/or
+ modify it under the terms of the GNU Library General Public
+ License as published by the Free Software Foundation; either
+ version 2 of the License, or (at your option) any later version.
+
+ This library is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ Library General Public License for more details.
+
+ If you are interested in a warranty or support for this source code,
+ contact Scott Christley <scottc@net-community.com> for more information.
+
+ You should have received a copy of the GNU Library General Public
+ License along with this library; see the file COPYING.LIB.
+ If not, write to the Free Software Foundation,
+ 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+*/
+/* WARNING: This file is automatically generated. */
+
+#ifndef _GNU_H_WINDOWS32_DEFINES
+#define _GNU_H_WINDOWS32_DEFINES
+
+#ifdef __cplusplus
+extern "C" {
+#endif /* __cplusplus */
+
+#define MAX_PATH (260)
+#define UNICODE_NULL ((WCHAR)0)
+#define LF_FACESIZE (32)
+#define LF_FULLFACESIZE (64)
+#define ELF_VENDOR_SIZE (4)
+#define SECURITY_STATIC_TRACKING (0)
+#define SECURITY_DYNAMIC_TRACKING (1)
+#define MAX_DEFAULTCHAR (2)
+#define MAX_LEADBYTES (12)
+#define EXCEPTION_MAXIMUM_PARAMETERS (15)
+#define CCHDEVICENAME (32)
+#define CCHFORMNAME (32)
+#define MENU_TEXT_LEN (40)
+#define MAX_LANA (254)
+#define NCBNAMSZ (16)
+#define NETBIOS_NAME_LEN (16)
+#define OFS_MAXPATHNAME (128)
+#define MAX_TAB_STOPS (32)
+#define ANYSIZE_ARRAY (1)
+#define RAS_MaxCallbackNumber (128)
+#define RAS_MaxDeviceName (128)
+#define RAS_MaxDeviceType (16)
+#define RAS_MaxEntryName (256)
+#define RAS_MaxIpAddress (15)
+#define RAS_MaxIpxAddress (21)
+#define RAS_MaxPhoneNumber (128)
+#define UNLEN (256)
+#define PWLEN (256)
+#define CNLEN (15)
+#define DNLEN (15)
+/* Unsigned types max */
+#define MAXDWORD (0xFFFFFFFF)
+#define MAXWORD (0xFFFF)
+#define MAXBYTE (0xFF)
+/* Signed types max/min */
+#define MINCHAR (0x80)
+#define MAXCHAR (0x7F)
+#define MINSHORT (0x8000)
+#define MAXSHORT (0x7FFF)
+#define MINLONG (0x80000000)
+#define MAXLONG (0x7FFFFFFF)
+
+/* _llseek */
+#define FILE_BEGIN (0)
+#define FILE_CURRENT (1)
+#define FILE_END (2)
+
+/* _lopen, LZOpenFile, OpenFile */
+#define OF_READ (0)
+#define OF_READWRITE (2)
+#define OF_WRITE (1)
+#define OF_SHARE_COMPAT (0)
+#define OF_SHARE_DENY_NONE (64)
+#define OF_SHARE_DENY_READ (48)
+#define OF_SHARE_DENY_WRITE (32)
+#define OF_SHARE_EXCLUSIVE (16)
+#define OF_CANCEL (2048)
+#define OF_CREATE (4096)
+#define OF_DELETE (512)
+#define OF_EXIST (16384)
+#define OF_PARSE (256)
+#define OF_PROMPT (8192)
+#define OF_REOPEN (32768)
+#define OF_VERIFY (1024)
+
+/* ActivateKeyboardLayout, LoadKeyboardLayout */
+#define HKL_NEXT (1)
+#define HKL_PREV (0)
+#define KLF_REORDER (8)
+#define KLF_UNLOADPREVIOUS (4)
+#define KLF_ACTIVATE (1)
+#define KLF_NOTELLSHELL (128)
+#define KLF_REPLACELANG (16)
+#define KLF_SUBSTITUTE_OK (2)
+
+/* AppendMenu */
+#define MF_BITMAP (0x4L)
+#define MF_DISABLED (0x2L)
+#define MF_ENABLED (0L)
+#define MF_GRAYED (0x1L)
+#define MF_HELP (0x4000L)
+#define MF_MENUBARBREAK (0x20L)
+#define MF_MENUBREAK (0x40L)
+#define MF_MOUSESELECT (0x8000L)
+#define MF_OWNERDRAW (0x100L)
+#define MF_POPUP (0x10L)
+#define MF_SEPARATOR (0x800L)
+#define MF_STRING (0L)
+#define MF_SYSMENU (0x2000L)
+#define MF_USECHECKBITMAPS (0x200L)
+
+/* Ternary Raster Operations - BitBlt */
+#define BLACKNESS 0x00000042
+#define NOTSRCERASE 0x001100A6
+#define NOTSRCCOPY 0x00330008
+#define SRCERASE 0x00440328
+#define DSTINVERT 0x00550009
+#define PATINVERT 0x005A0049
+#define SRCINVERT 0x00660046
+#define SRCAND 0x008800C6
+#define MERGEPAINT 0x00BB0226
+#define MERGECOPY 0x00C000CA
+#define SRCCOPY 0x00CC0020
+#define SRCPAINT 0x00EE0086
+#define PATCOPY 0x00F00021
+#define PATPAINT 0x00FB0A09
+#define WHITENESS 0x00FF0062
+
+/* Binary Raster Operations */
+#define R2_BLACK (1)
+#define R2_COPYPEN (13)
+#define R2_MASKNOTPEN (3)
+#define R2_MASKPEN (9)
+#define R2_MASKPENNOT (5)
+#define R2_MERGENOTPEN (12)
+#define R2_MERGEPEN (15)
+#define R2_MERGEPENNOT (14)
+#define R2_NOP (11)
+#define R2_NOT (6)
+#define R2_NOTCOPYPEN (4)
+#define R2_NOTMASKPEN (8)
+#define R2_NOTMERGEPEN (2)
+#define R2_NOTXORPEN (10)
+#define R2_WHITE (16)
+#define R2_XORPEN (7)
+
+/* BroadcastSystemMessage */
+#define BSF_FLUSHDISK (4)
+#define BSF_FORCEIFHUNG (32)
+#define BSF_IGNORECURRENTTASK (2)
+#define BSF_NOHANG (8)
+#define BSF_POSTMESSAGE (16)
+#define BSF_QUERY (1)
+#define BSM_ALLCOMPONENTS (0)
+#define BSM_APPLICATIONS (8)
+#define BSM_INSTALLABLEDRIVERS (4)
+#define BSM_NETDRIVER (2)
+#define BSM_VXDS (1)
+#define BROADCAST_QUERY_DENY (1112363332)
+
+/* BrowseCallbackProc */
+
+/* CallNamedPipe */
+#define NMPWAIT_NOWAIT (1)
+#define NMPWAIT_WAIT_FOREVER (-1)
+#define NMPWAIT_USE_DEFAULT_WAIT (0)
+
+/* CascadeWindows, TileWindows */
+#define MDITILE_SKIPDISABLED (2)
+#define MDITILE_HORIZONTAL (1)
+#define MDITILE_VERTICAL (0)
+
+/* CBTProc */
+#define HCBT_ACTIVATE (5)
+#define HCBT_CLICKSKIPPED (6)
+#define HCBT_CREATEWND (3)
+#define HCBT_DESTROYWND (4)
+#define HCBT_KEYSKIPPED (7)
+#define HCBT_MINMAX (1)
+#define HCBT_MOVESIZE (0)
+#define HCBT_QS (2)
+#define HCBT_SETFOCUS (9)
+#define HCBT_SYSCOMMAND (8)
+
+/* ChangeDisplaySettings */
+#define DM_BITSPERPEL (0x40000L)
+#define DM_PELSWIDTH (0x80000L)
+#define DM_PELSHEIGHT (0x100000L)
+#define DM_DISPLAYFLAGS (0x200000L)
+#define DM_DISPLAYFREQUENCY (0x400000L)
+#define CDS_UPDATEREGISTRY (1)
+#define CDS_TEST (2)
+#define DISP_CHANGE_SUCCESSFUL (0)
+#define DISP_CHANGE_RESTART (1)
+#define DISP_CHANGE_BADFLAGS (-4)
+#define DISP_CHANGE_FAILED (-1)
+#define DISP_CHANGE_BADMODE (-2)
+#define DISP_CHANGE_NOTUPDATED (-3)
+
+/* ChangeServiceConfig */
+#define SERVICE_NO_CHANGE (-1)
+#define SERVICE_WIN32_OWN_PROCESS (16)
+#define SERVICE_WIN32_SHARE_PROCESS (32)
+#define SERVICE_KERNEL_DRIVER (1)
+#define SERVICE_FILE_SYSTEM_DRIVER (2)
+#define SERVICE_INTERACTIVE_PROCESS (256)
+#define SERVICE_BOOT_START (0)
+#define SERVICE_SYSTEM_START (1)
+#define SERVICE_AUTO_START (2)
+#define SERVICE_DEMAND_START (3)
+#define SERVICE_DISABLED (4)
+
+/* SERVICE_STATUS structure */
+#define SERVICE_STOPPED (1)
+#define SERVICE_START_PENDING (2)
+#define SERVICE_STOP_PENDING (3)
+#define SERVICE_RUNNING (4)
+#define SERVICE_CONTINUE_PENDING (5)
+#define SERVICE_PAUSE_PENDING (6)
+#define SERVICE_PAUSED (7)
+#define SERVICE_ACCEPT_STOP (1)
+#define SERVICE_ACCEPT_PAUSE_CONTINUE (2)
+#define SERVICE_ACCEPT_SHUTDOWN (4)
+
+/* CheckDlgButton */
+#define BST_CHECKED (1)
+#define BST_INDETERMINATE (2)
+#define BST_UNCHECKED (0)
+#define BST_FOCUS (8)
+#define BST_PUSHED (4)
+
+/* CheckMenuItem, HiliteMenuItem */
+#define MF_BYCOMMAND (0L)
+#define MF_BYPOSITION (0x400L)
+#define MF_CHECKED (0x8L)
+#define MF_UNCHECKED (0L)
+#define MF_HILITE (0x80L)
+#define MF_UNHILITE (0L)
+
+/* ChildWindowFromPointEx */
+#define CWP_ALL (0)
+#define CWP_SKIPINVISIBLE (1)
+#define CWP_SKIPDISABLED (2)
+#define CWP_SKIPTRANSPARENT (4)
+
+/* ClearCommError */
+#define CE_BREAK (16)
+#define CE_DNS (2048)
+#define CE_FRAME (8)
+#define CE_IOE (1024)
+#define CE_MODE (32768)
+#define CE_OOP (4096)
+#define CE_OVERRUN (2)
+#define CE_PTO (512)
+#define CE_RXOVER (1)
+#define CE_RXPARITY (4)
+#define CE_TXFULL (256)
+
+/* ChooseMatchToTarget */
+
+/* CombineRgn */
+#define RGN_AND (1)
+#define RGN_COPY (5)
+#define RGN_DIFF (4)
+#define RGN_OR (2)
+#define RGN_XOR (3)
+#define NULLREGION (1)
+#define SIMPLEREGION (2)
+#define COMPLEXREGION (3)
+#define ERROR (0)
+
+/* CommonDlgExtendedError */
+#define CDERR_DIALOGFAILURE (0xffff)
+#define CDERR_FINDRESFAILURE (6)
+#define CDERR_INITIALIZATION (2)
+#define CDERR_LOADRESFAILURE (7)
+#define CDERR_LOADSTRFAILURE (5)
+#define CDERR_LOCKRESFAILURE (8)
+#define CDERR_MEMALLOCFAILURE (9)
+#define CDERR_MEMLOCKFAILURE (10)
+#define CDERR_NOHINSTANCE (4)
+#define CDERR_NOHOOK (11)
+#define CDERR_NOTEMPLATE (3)
+#define CDERR_REGISTERMSGFAIL (12)
+#define CDERR_STRUCTSIZE (1)
+#define PDERR_CREATEICFAILURE (0x1000 + 10)
+#define PDERR_DEFAULTDIFFERENT (0x1000 + 12)
+#define PDERR_DNDMMISMATCH (0x1000 + 9)
+#define PDERR_GETDEVMODEFAIL (0x1000 + 5)
+#define PDERR_INITFAILURE (0x1000 + 6)
+#define PDERR_LOADDRVFAILURE (0x1000 + 4)
+#define PDERR_NODEFAULTPRN (0x1000 + 8)
+#define PDERR_NODEVICES (0x1000 + 7)
+#define PDERR_PARSEFAILURE (0x1000 + 2)
+#define PDERR_PRINTERNOTFOUND (0x1000 + 11)
+#define PDERR_RETDEFFAILURE (0x1000 + 3)
+#define PDERR_SETUPFAILURE (0x1000 + 1)
+#define CFERR_MAXLESSTHANMIN (0x2000 + 2)
+#define CFERR_NOFONTS (0x2000 + 1)
+#define FNERR_BUFFERTOOSMALL (0x3000 + 3)
+#define FNERR_INVALIDFILENAME (0x3000 + 2)
+#define FNERR_SUBCLASSFAILURE (0x3000 + 1)
+#define FRERR_BUFFERLENGTHZERO (0x4000 + 1)
+
+/* CompareString, LCMapString */
+#define LOCALE_SYSTEM_DEFAULT (0x800L)
+#define LOCALE_USER_DEFAULT (0x400L)
+#define NORM_IGNORECASE (1)
+#define NORM_IGNOREKANATYPE (65536)
+#define NORM_IGNORENONSPACE (2)
+#define NORM_IGNORESYMBOLS (4)
+#define NORM_IGNOREWIDTH (131072)
+#define SORT_STRINGSORT (4096)
+#define LCMAP_BYTEREV (2048)
+#define LCMAP_FULLWIDTH (8388608)
+#define LCMAP_HALFWIDTH (4194304)
+#define LCMAP_HIRAGANA (1048576)
+#define LCMAP_KATAKANA (2097152)
+#define LCMAP_LOWERCASE (256)
+#define LCMAP_SORTKEY (1024)
+#define LCMAP_UPPERCASE (512)
+
+/* ContinueDebugEvent */
+#define DBG_CONTINUE (0x10002L)
+#define DBG_CONTROL_BREAK (0x40010008L)
+#define DBG_CONTROL_C (0x40010005L)
+#define DBG_EXCEPTION_NOT_HANDLED (0x80010001L)
+#define DBG_TERMINATE_THREAD (0x40010003L)
+#define DBG_TERMINATE_PROCESS (0x40010004L)
+
+/* ControlService */
+#define SERVICE_CONTROL_STOP (1)
+#define SERVICE_CONTROL_PAUSE (2)
+#define SERVICE_CONTROL_CONTINUE (3)
+#define SERVICE_CONTROL_INTERROGATE (4)
+#define SERVICE_CONTROL_SHUTDOWN (5)
+
+/* CopyImage, LoadImage */
+#define IMAGE_BITMAP (0)
+#define IMAGE_CURSOR (2)
+#define IMAGE_ENHMETAFILE (1)
+#define IMAGE_ICON (1)
+#define LR_COPYDELETEORG (8)
+#define LR_COPYRETURNORG (4)
+#define LR_MONOCHROME (1)
+#define LR_CREATEDIBSECTION (8192)
+#define LR_DEFAULTSIZE (64)
+
+/* CreateDesktop */
+#define DF_ALLOWOTHERACCOUNTHOOK (0x1L)
+#define DESKTOP_CREATEMENU (0x4L)
+#define DESKTOP_CREATEWINDOW (0x2L)
+#define DESKTOP_ENUMERATE (0x40L)
+#define DESKTOP_HOOKCONTROL (0x8L)
+#define DESKTOP_JOURNALPLAYBACK (0x20L)
+#define DESKTOP_JOURNALRECORD (0x10L)
+#define DESKTOP_READOBJECTS (0x1L)
+#define DESKTOP_SWITCHDESKTOP (0x100L)
+#define DESKTOP_WRITEOBJECTS (0x80L)
+#define WSF_VISIBLE (0x1L)
+
+/* CreateDIBitmap */
+#define CBM_INIT (0x4L)
+#define DIB_PAL_COLORS (1)
+#define DIB_RGB_COLORS (0)
+
+/* CreateFile, GetFileAttributes, SetFileAttributes */
+#define GENERIC_READ (0x80000000L)
+#define GENERIC_WRITE (0x40000000L)
+#define FILE_READ_DATA ( 0x0001 ) /* file & pipe */
+#define FILE_LIST_DIRECTORY ( 0x0001 ) /* directory */
+
+#define FILE_WRITE_DATA ( 0x0002 ) /* file & pipe */
+#define FILE_ADD_FILE ( 0x0002 ) /* directory */
+
+#define FILE_APPEND_DATA ( 0x0004 ) /* file */
+#define FILE_ADD_SUBDIRECTORY ( 0x0004 ) /* directory */
+#define FILE_CREATE_PIPE_INSTANCE ( 0x0004 ) /* named pipe */
+
+#define FILE_READ_EA ( 0x0008 ) /* file & directory */
+#define FILE_READ_PROPERTIES FILE_READ_EA
+
+#define FILE_WRITE_EA ( 0x0010 ) /* file & directory */
+#define FILE_WRITE_PROPERTIES FILE_WRITE_EA
+
+#define FILE_EXECUTE ( 0x0020 ) /* file */
+#define FILE_TRAVERSE ( 0x0020 ) /* directory */
+
+#define FILE_DELETE_CHILD ( 0x0040 ) /* directory */
+
+#define FILE_READ_ATTRIBUTES ( 0x0080 ) /* all */
+
+#define FILE_WRITE_ATTRIBUTES ( 0x0100 ) /* all */
+
+#define FILE_ALL_ACCESS (STANDARD_RIGHTS_REQUIRED | SYNCHRONIZE | 0x1FF)
+
+#define FILE_GENERIC_READ (STANDARD_RIGHTS_READ |\
+ FILE_READ_DATA |\
+ FILE_READ_ATTRIBUTES |\
+ FILE_READ_EA |\
+ SYNCHRONIZE)
+
+
+#define FILE_GENERIC_WRITE (STANDARD_RIGHTS_WRITE |\
+ FILE_WRITE_DATA |\
+ FILE_WRITE_ATTRIBUTES |\
+ FILE_WRITE_EA |\
+ FILE_APPEND_DATA |\
+ SYNCHRONIZE)
+
+
+#define FILE_GENERIC_EXECUTE (STANDARD_RIGHTS_EXECUTE |\
+ FILE_READ_ATTRIBUTES |\
+ FILE_EXECUTE |\
+ SYNCHRONIZE)
+
+#define FILE_SHARE_DELETE (4)
+#define FILE_SHARE_READ (1)
+#define FILE_SHARE_WRITE (2)
+#define CONSOLE_TEXTMODE_BUFFER (1)
+#define CREATE_NEW (1)
+#define CREATE_ALWAYS (2)
+#define OPEN_EXISTING (3)
+#define OPEN_ALWAYS (4)
+#define TRUNCATE_EXISTING (5)
+#define FILE_ATTRIBUTE_ARCHIVE (32)
+#define FILE_ATTRIBUTE_COMPRESSED (2048)
+#define FILE_ATTRIBUTE_NORMAL (128)
+#define FILE_ATTRIBUTE_DIRECTORY (16)
+#define FILE_ATTRIBUTE_HIDDEN (2)
+#define FILE_ATTRIBUTE_READONLY (1)
+#define FILE_ATTRIBUTE_SYSTEM (4)
+#define FILE_ATTRIBUTE_TEMPORARY (256)
+#define FILE_FLAG_WRITE_THROUGH (2147483648)
+#define FILE_FLAG_OVERLAPPED (1073741824)
+#define FILE_FLAG_NO_BUFFERING (536870912)
+#define FILE_FLAG_RANDOM_ACCESS (268435456)
+#define FILE_FLAG_SEQUENTIAL_SCAN (134217728)
+#define FILE_FLAG_DELETE_ON_CLOSE (67108864)
+#define FILE_FLAG_BACKUP_SEMANTICS (33554432)
+#define FILE_FLAG_POSIX_SEMANTICS (16777216)
+#define SECURITY_ANONYMOUS (0)
+#define SECURITY_IDENTIFICATION (65536)
+#define SECURITY_IMPERSONATION (131072)
+#define SECURITY_DELEGATION (196608)
+#define SECURITY_CONTEXT_TRACKING (262144)
+#define SECURITY_EFFECTIVE_ONLY (524288)
+#define SECURITY_SQOS_PRESENT (1048576)
+
+/* CreateFileMapping, VirtualAlloc, VirtualFree, VirtualProtect */
+#define SEC_COMMIT (134217728)
+#define SEC_IMAGE (16777216)
+#define SEC_NOCACHE (268435456)
+#define SEC_RESERVE (67108864)
+#define PAGE_READONLY (2)
+#define PAGE_READWRITE (4)
+#define PAGE_WRITECOPY (8)
+#define PAGE_EXECUTE (16)
+#define PAGE_EXECUTE_READ (32)
+#define PAGE_EXECUTE_READWRITE (64)
+#define PAGE_EXECUTE_WRITECOPY (128)
+#define PAGE_GUARD (256)
+#define PAGE_NOACCESS (1)
+#define PAGE_NOCACHE (512)
+#define MEM_COMMIT (4096)
+#define MEM_FREE (65536)
+#define MEM_RESERVE (8192)
+#define MEM_IMAGE (16777216)
+#define MEM_MAPPED (262144)
+#define MEM_PRIVATE (131072)
+#define MEM_DECOMMIT (16384)
+#define MEM_RELEASE (32768)
+#define MEM_TOP_DOWN (1048576)
+#define EXCEPTION_GUARD_PAGE (0x80000001L)
+#define SECTION_EXTEND_SIZE (0x10)
+#define SECTION_MAP_READ (0x4)
+#define SECTION_MAP_WRITE (0x2)
+#define SECTION_QUERY (0x1)
+#define SECTION_ALL_ACCESS (0xf001fL)
+
+/* CreateFont */
+#define FW_DONTCARE (0)
+#define FW_THIN (100)
+#define FW_EXTRALIGHT (200)
+#define FW_LIGHT (300)
+#define FW_NORMAL (400)
+#define FW_REGULAR FW_NORMAL
+#define FW_MEDIUM (500)
+#define FW_SEMIBOLD (600)
+#define FW_BOLD (700)
+#define FW_EXTRABOLD (800)
+#define FW_HEAVY (900)
+#define ANSI_CHARSET (0)
+#define DEFAULT_CHARSET (1)
+#define SYMBOL_CHARSET (2)
+#define SHIFTJIS_CHARSET (128)
+#define HANGEUL_CHARSET (129)
+#define GB2312_CHARSET (134)
+#define CHINESEBIG5_CHARSET (136)
+#define GREEK_CHARSET (161)
+#define TURKISH_CHARSET (162)
+#define HEBREW_CHARSET (177)
+#define ARABIC_CHARSET (178)
+#define BALTIC_CHARSET (186)
+#define RUSSIAN_CHARSET (204)
+#define THAI_CHARSET (222)
+#define EASTEUROPE_CHARSET (238)
+#define OEM_CHARSET (255)
+#define OUT_DEFAULT_PRECIS (0)
+#define OUT_STRING_PRECIS (1)
+#define OUT_CHARACTER_PRECIS (2)
+#define OUT_STROKE_PRECIS (3)
+#define OUT_TT_PRECIS (4)
+#define OUT_DEVICE_PRECIS (5)
+#define OUT_RASTER_PRECIS (6)
+#define OUT_TT_ONLY_PRECIS (7)
+#define OUT_OUTLINE_PRECIS (8)
+#define CLIP_DEFAULT_PRECIS (0)
+#define CLIP_CHARACTER_PRECIS (1)
+#define CLIP_STROKE_PRECIS (2)
+#define CLIP_MASK (15)
+#define CLIP_LH_ANGLES (16)
+#define CLIP_TT_ALWAYS (32)
+#define CLIP_EMBEDDED (128)
+#define DEFAULT_QUALITY (0)
+#define DRAFT_QUALITY (1)
+#define PROOF_QUALITY (2)
+#define DEFAULT_PITCH (0)
+#define FIXED_PITCH (1)
+#define VARIABLE_PITCH (2)
+#define FF_DECORATIVE (80)
+#define FF_DONTCARE (0)
+#define FF_MODERN (48)
+#define FF_ROMAN (16)
+#define FF_SCRIPT (64)
+#define FF_SWISS (32)
+
+/* CreateHatchBrush */
+#define HS_BDIAGONAL (3)
+#define HS_CROSS (4)
+#define HS_DIAGCROSS (5)
+#define HS_FDIAGONAL (2)
+#define HS_HORIZONTAL (0)
+#define HS_VERTICAL (1)
+
+/* CreateIconFromResourceEx */
+#define LR_DEFAULTCOLOR (0)
+#define LR_LOADREALSIZE (128)
+#define LR_MONOCHROME (1)
+
+/* CreateMailslot, GetMailslotInfo */
+#define MAILSLOT_WAIT_FOREVER (0xffffffffL)
+#define MAILSLOT_NO_MESSAGE (0xffffffffL)
+
+/* CreateMappedBitmap */
+#define CMB_MASKED (2)
+
+/* CreateNamedPipe */
+#define PIPE_ACCESS_DUPLEX (3)
+#define PIPE_ACCESS_INBOUND (1)
+#define PIPE_ACCESS_OUTBOUND (2)
+#define WRITE_DAC (0x40000L)
+#define WRITE_OWNER (0x80000L)
+#define ACCESS_SYSTEM_SECURITY (0x1000000L)
+#define PIPE_TYPE_BYTE (0)
+#define PIPE_TYPE_MESSAGE (4)
+#define PIPE_READMODE_BYTE (0)
+#define PIPE_READMODE_MESSAGE (2)
+#define PIPE_WAIT (0)
+#define PIPE_NOWAIT (1)
+
+/* CreatePen, ExtCreatePen */
+#define PS_GEOMETRIC (65536)
+#define PS_COSMETIC (0)
+#define PS_ALTERNATE (8)
+#define PS_SOLID (0)
+#define PS_DASH (1)
+#define PS_DOT (2)
+#define PS_DASHDOT (3)
+#define PS_DASHDOTDOT (4)
+#define PS_NULL (5)
+#define PS_USERSTYLE (7)
+#define PS_INSIDEFRAME (6)
+#define PS_ENDCAP_ROUND (0)
+#define PS_ENDCAP_SQUARE (256)
+#define PS_ENDCAP_FLAT (512)
+#define PS_JOIN_BEVEL (4096)
+#define PS_JOIN_MITER (8192)
+#define PS_JOIN_ROUND (0)
+#define PS_STYLE_MASK (15)
+#define PS_ENDCAP_MASK (3840)
+#define PS_TYPE_MASK (983040)
+
+/* CreatePolygonRgn */
+#define ALTERNATE (1)
+#define WINDING (2)
+
+/* CreateProcess */
+#define CREATE_DEFAULT_ERROR_MODE (67108864)
+#define CREATE_NEW_CONSOLE (16)
+#define CREATE_NEW_PROCESS_GROUP (512)
+#define CREATE_SEPARATE_WOW_VDM (2048)
+#define CREATE_SUSPENDED (4)
+#define CREATE_UNICODE_ENVIRONMENT (1024)
+#define DEBUG_PROCESS (1)
+#define DEBUG_ONLY_THIS_PROCESS (2)
+#define DETACHED_PROCESS (8)
+#define HIGH_PRIORITY_CLASS (128)
+#define IDLE_PRIORITY_CLASS (64)
+#define NORMAL_PRIORITY_CLASS (32)
+#define REALTIME_PRIORITY_CLASS (256)
+
+/* CreateService */
+#define SERVICE_ALL_ACCESS (0xf01ffL)
+#define SERVICE_CHANGE_CONFIG (2)
+#define SERVICE_ENUMERATE_DEPENDENTS (8)
+#define SERVICE_INTERROGATE (128)
+#define SERVICE_PAUSE_CONTINUE (64)
+#define SERVICE_QUERY_CONFIG (1)
+#define SERVICE_QUERY_STATUS (4)
+#define SERVICE_START (16)
+#define SERVICE_STOP (32)
+#define SERVICE_USER_DEFINED_CONTROL (256)
+#define DELETE (0x10000L)
+#define READ_CONTROL (0x20000L)
+#define GENERIC_EXECUTE (0x20000000L)
+#define SERVICE_WIN32_OWN_PROCESS (16)
+#define SERVICE_WIN32_SHARE_PROCESS (32)
+#define SERVICE_KERNEL_DRIVER (1)
+#define SERVICE_FILE_SYSTEM_DRIVER (2)
+#define SERVICE_INTERACTIVE_PROCESS (256)
+#define SERVICE_BOOT_START (0)
+#define SERVICE_SYSTEM_START (1)
+#define SERVICE_AUTO_START (2)
+#define SERVICE_DEMAND_START (3)
+#define SERVICE_DISABLED (4)
+#define SERVICE_ERROR_IGNORE (0)
+#define SERVICE_ERROR_NORMAL (1)
+#define SERVICE_ERROR_SEVERE (2)
+#define SERVICE_ERROR_CRITICAL (3)
+
+/* CreateTapePartition, WriteTapemark */
+#define TAPE_FIXED_PARTITIONS (0L)
+#define TAPE_INITIATOR_PARTITIONS (0x2L)
+#define TAPE_SELECT_PARTITIONS (0x1L)
+#define TAPE_FILEMARKS (0x1L)
+#define TAPE_LONG_FILEMARKS (0x3L)
+#define TAPE_SETMARKS (0L)
+#define TAPE_SHORT_FILEMARKS (0x2L)
+
+/* CreateWindow */
+#define CW_USEDEFAULT (0x80000000)
+#define WS_BORDER (0x800000L)
+#define WS_CAPTION (0xc00000L)
+#define WS_CHILD (0x40000000L)
+#define WS_CHILDWINDOW (0x40000000L)
+#define WS_CLIPCHILDREN (0x2000000L)
+#define WS_CLIPSIBLINGS (0x4000000L)
+#define WS_DISABLED (0x8000000L)
+#define WS_DLGFRAME (0x400000L)
+#define WS_GROUP (0x20000L)
+#define WS_HSCROLL (0x100000L)
+#define WS_ICONIC (0x20000000L)
+#define WS_MAXIMIZE (0x1000000L)
+#define WS_MAXIMIZEBOX (0x10000L)
+#define WS_MINIMIZE (0x20000000L)
+#define WS_MINIMIZEBOX (0x20000L)
+#define WS_OVERLAPPED (0L)
+#define WS_OVERLAPPEDWINDOW (0xcf0000L)
+#define WS_POPUP (0x80000000L)
+#define WS_POPUPWINDOW (0x80880000L)
+#define WS_SIZEBOX (0x40000L)
+#define WS_SYSMENU (0x80000L)
+#define WS_TABSTOP (0x10000L)
+#define WS_THICKFRAME (0x40000L)
+#define WS_TILED (0L)
+#define WS_TILEDWINDOW (0xcf0000L)
+#define WS_VISIBLE (0x10000000L)
+#define WS_VSCROLL (0x200000L)
+#define MDIS_ALLCHILDSTYLES (0x1)
+#define BS_3STATE (0x5L)
+#define BS_AUTO3STATE (0x6L)
+#define BS_AUTOCHECKBOX (0x3L)
+#define BS_AUTORADIOBUTTON (0x9L)
+#define BS_BITMAP (0x80L)
+#define BS_BOTTOM (0x800L)
+#define BS_CENTER (0x300L)
+#define BS_CHECKBOX (0x2L)
+#define BS_DEFPUSHBUTTON (0x1L)
+#define BS_GROUPBOX (0x7L)
+#define BS_ICON (0x40L)
+#define BS_LEFT (0x100L)
+#define BS_LEFTTEXT (0x20L)
+#define BS_MULTILINE (0x2000L)
+#define BS_NOTIFY (0x4000L)
+#define BS_OWNERDRAW (0xbL)
+#define BS_PUSHBUTTON (0L)
+#define BS_PUSHLIKE (0x1000L)
+#define BS_RADIOBUTTON (0x4L)
+#define BS_RIGHT (0x200L)
+#define BS_RIGHTBUTTON (0x20L)
+#define BS_TEXT (0L)
+#define BS_TOP (0x400L)
+#define BS_USERBUTTON (0x8L)
+#define BS_VCENTER (0xc00L)
+#define CBS_AUTOHSCROLL (0x40L)
+#define CBS_DISABLENOSCROLL (0x800L)
+#define CBS_DROPDOWN (0x2L)
+#define CBS_DROPDOWNLIST (0x3L)
+#define CBS_HASSTRINGS (0x200L)
+#define CBS_LOWERCASE (0x4000L)
+#define CBS_NOINTEGRALHEIGHT (0x400L)
+#define CBS_OEMCONVERT (0x80L)
+#define CBS_OWNERDRAWFIXED (0x10L)
+#define CBS_OWNERDRAWVARIABLE (0x20L)
+#define CBS_SIMPLE (0x1L)
+#define CBS_SORT (0x100L)
+#define CBS_UPPERCASE (0x2000L)
+#define ES_AUTOHSCROLL (0x80L)
+#define ES_AUTOVSCROLL (0x40L)
+#define ES_CENTER (0x1L)
+#define ES_LEFT (0L)
+#define ES_LOWERCASE (0x10L)
+#define ES_MULTILINE (0x4L)
+#define ES_NOHIDESEL (0x100L)
+#define ES_NUMBER (0x2000L)
+#define ES_OEMCONVERT (0x400L)
+#define ES_PASSWORD (0x20L)
+#define ES_READONLY (0x800L)
+#define ES_RIGHT (0x2L)
+#define ES_UPPERCASE (0x8L)
+#define ES_WANTRETURN (0x1000L)
+#define LBS_DISABLENOSCROLL (0x1000L)
+#define LBS_EXTENDEDSEL (0x800L)
+#define LBS_HASSTRINGS (0x40L)
+#define LBS_MULTICOLUMN (0x200L)
+#define LBS_MULTIPLESEL (0x8L)
+#define LBS_NODATA (0x2000L)
+#define LBS_NOINTEGRALHEIGHT (0x100L)
+#define LBS_NOREDRAW (0x4L)
+#define LBS_NOSEL (0x4000L)
+#define LBS_NOTIFY (0x1L)
+#define LBS_OWNERDRAWFIXED (0x10L)
+#define LBS_OWNERDRAWVARIABLE (0x20L)
+#define LBS_SORT (0x2L)
+#define LBS_STANDARD (0xa00003L)
+#define LBS_USETABSTOPS (0x80L)
+#define LBS_WANTKEYBOARDINPUT (0x400L)
+#define SBS_BOTTOMALIGN (0x4L)
+#define SBS_HORZ (0L)
+#define SBS_LEFTALIGN (0x2L)
+#define SBS_RIGHTALIGN (0x4L)
+#define SBS_SIZEBOX (0x8L)
+#define SBS_SIZEBOXBOTTOMRIGHTALIGN (0x4L)
+#define SBS_SIZEBOXTOPLEFTALIGN (0x2L)
+#define SBS_SIZEGRIP (0x10L)
+#define SBS_TOPALIGN (0x2L)
+#define SBS_VERT (0x1L)
+#define SS_BITMAP (0xeL)
+#define SS_BLACKFRAME (0x7L)
+#define SS_BLACKRECT (0x4L)
+#define SS_CENTER (0x1L)
+#define SS_CENTERIMAGE (0x200L)
+#define SS_ENHMETAFILE (0xfL)
+#define SS_ETCHEDFRAME (0x12L)
+#define SS_ETCHEDHORZ (0x10L)
+#define SS_ETCHEDVERT (0x11L)
+#define SS_GRAYFRAME (0x8L)
+#define SS_GRAYRECT (0x5L)
+#define SS_ICON (0x3L)
+#define SS_LEFT (0L)
+#define SS_LEFTNOWORDWRAP (0xcL)
+#define SS_NOPREFIX (0x80L)
+#define SS_NOTIFY (0x100L)
+#define SS_OWNERDRAW (0xdL)
+#define SS_REALSIZEIMAGE (0x800L)
+#define SS_RIGHT (0x2L)
+#define SS_RIGHTJUST (0x400L)
+#define SS_SIMPLE (0xbL)
+#define SS_SUNKEN (0x1000L)
+#define SS_USERITEM (0xaL)
+#define SS_WHITEFRAME (0x9L)
+#define SS_WHITERECT (0x6L)
+#define DS_3DLOOK (0x4L)
+#define DS_ABSALIGN (0x1L)
+#define DS_CENTER (0x800L)
+#define DS_CENTERMOUSE (0x1000L)
+#define DS_CONTEXTHELP (0x2000L)
+#define DS_CONTROL (0x400L)
+#define DS_FIXEDSYS (0x8L)
+#define DS_LOCALEDIT (0x20L)
+#define DS_MODALFRAME (0x80L)
+#define DS_NOFAILCREATE (0x10L)
+#define DS_NOIDLEMSG (0x100L)
+#define DS_SETFONT (0x40L)
+#define DS_SETFOREGROUND (0x200L)
+#define DS_SYSMODAL (0x2L)
+
+/* CreateWindowEx */
+#define WS_EX_ACCEPTFILES (0x10L)
+#define WS_EX_APPWINDOW (0x40000L)
+#define WS_EX_CLIENTEDGE (0x200L)
+#define WS_EX_CONTEXTHELP (0x400L)
+#define WS_EX_CONTROLPARENT (0x10000L)
+#define WS_EX_DLGMODALFRAME (0x1L)
+#define WS_EX_LEFT (0L)
+#define WS_EX_LEFTSCROLLBAR (0x4000L)
+#define WS_EX_LTRREADING (0L)
+#define WS_EX_MDICHILD (0x40L)
+#define WS_EX_NOPARENTNOTIFY (0x4L)
+#define WS_EX_OVERLAPPEDWINDOW (0x300L)
+#define WS_EX_PALETTEWINDOW (0x188L)
+#define WS_EX_RIGHT (0x1000L)
+#define WS_EX_RIGHTSCROLLBAR (0L)
+#define WS_EX_RTLREADING (0x2000L)
+#define WS_EX_STATICEDGE (0x20000L)
+#define WS_EX_TOOLWINDOW (0x80L)
+#define WS_EX_TOPMOST (0x8L)
+#define WS_EX_TRANSPARENT (0x20L)
+#define WS_EX_WINDOWEDGE (0x100L)
+
+/* CreateWindowStation */
+#define WINSTA_ACCESSCLIPBOARD (0x4L)
+#define WINSTA_ACCESSGLOBALATOMS (0x20L)
+#define WINSTA_CREATEDESKTOP (0x8L)
+#define WINSTA_ENUMDESKTOPS (0x1L)
+#define WINSTA_ENUMERATE (0x100L)
+#define WINSTA_EXITWINDOWS (0x40L)
+#define WINSTA_READATTRIBUTES (0x2L)
+#define WINSTA_READSCREEN (0x200L)
+#define WINSTA_WRITEATTRIBUTES (0x10L)
+
+/* DdeCallback */
+
+/* DdeClientTransaction */
+
+/* DdeEnableCallback */
+
+/* DdeGetLastError */
+
+/* DdeInitialize */
+
+/* DdeNameService */
+
+/* DebugProc */
+#define WH_CALLWNDPROC (4)
+#define WH_CALLWNDPROCRET (12)
+#define WH_CBT (5)
+#define WH_DEBUG (9)
+#define WH_GETMESSAGE (3)
+#define WH_JOURNALPLAYBACK (1)
+#define WH_JOURNALRECORD (0)
+#define WH_KEYBOARD (2)
+#define WH_MOUSE (7)
+#define WH_MSGFILTER (-1)
+#define WH_SHELL (10)
+#define WH_SYSMSGFILTER (6)
+#define WH_MSGFILTER (-1)
+#define WH_FOREGROUNDIDLE (11)
+
+/* DefineDosDevice */
+#define DDD_RAW_TARGET_PATH (1)
+#define DDD_REMOVE_DEFINITION (2)
+#define DDD_EXACT_MATCH_ON_REMOVE (4)
+
+/* DeviceCapbilities */
+#define DC_BINNAMES (12)
+#define DC_BINS (6)
+#define DC_COPIES (18)
+#define DC_DRIVER (11)
+#define DC_DATATYPE_PRODUCED (21)
+#define DC_DUPLEX (7)
+#define DC_EMF_COMPLIANT (20)
+#define DC_ENUMRESOLUTIONS (13)
+#define DC_EXTRA (9)
+#define DC_FIELDS (1)
+#define DC_FILEDEPENDENCIES (14)
+#define DC_MAXEXTENT (5)
+#define DC_MINEXTENT (4)
+#define DC_ORIENTATION (17)
+#define DC_PAPERNAMES (16)
+#define DC_PAPERS (2)
+#define DC_PAPERSIZE (3)
+#define DC_SIZE (8)
+#define DC_TRUETYPE (15)
+#define DCTT_BITMAP (0x1L)
+#define DCTT_DOWNLOAD (0x2L)
+#define DCTT_SUBDEV (0x4L)
+#define DC_VERSION (10)
+#define DC_BINADJUST (19)
+#define DC_DATATYPE_PRODUCED (21)
+
+/* DeviceIoControl */
+
+/* DlgDirList */
+#define DDL_ARCHIVE (32)
+#define DDL_DIRECTORY (16)
+#define DDL_DRIVES (16384)
+#define DDL_EXCLUSIVE (32768)
+#define DDL_HIDDEN (2)
+#define DDL_READONLY (1)
+#define DDL_READWRITE (0)
+#define DDL_SYSTEM (4)
+#define DDL_POSTMSGS (8192)
+
+/* DllEntryPoint */
+#define DLL_PROCESS_ATTACH (1)
+#define DLL_THREAD_ATTACH (2)
+#define DLL_PROCESS_DETACH (0)
+#define DLL_THREAD_DETACH (3)
+
+/* DocumentProperties */
+#define DM_IN_BUFFER (8)
+#define DM_MODIFY (8)
+#define DM_IN_PROMPT (4)
+#define DM_PROMPT (4)
+#define DM_OUT_BUFFER (2)
+#define DM_COPY (2)
+#define DM_UPDATE (1)
+
+/* DrawAnimatedRects */
+#define IDANI_OPEN (1)
+#define IDANI_CLOSE (2)
+
+/* DrawCaption */
+#define DC_ACTIVE (1)
+#define DC_SMALLCAP (2)
+
+/* DrawEdge */
+#define BDR_RAISEDINNER (4)
+#define BDR_SUNKENINNER (8)
+#define BDR_RAISEDOUTER (1)
+#define BDR_SUNKENOUTER (1)
+#define EDGE_BUMP (9)
+#define EDGE_ETCHED (6)
+#define EDGE_RAISED (5)
+#define EDGE_SUNKEN (10)
+#define BF_ADJUST (8192)
+#define BF_BOTTOM (8)
+#define BF_BOTTOMLEFT (9)
+#define BF_BOTTOMRIGHT (12)
+#define BF_DIAGONAL (16)
+#define BF_DIAGONAL_ENDBOTTOMLEFT (25)
+#define BF_DIAGONAL_ENDBOTTOMRIGHT (28)
+#define BF_DIAGONAL_ENDTOPLEFT (19)
+#define BF_DIAGONAL_ENDTOPRIGHT (22)
+#define BF_FLAT (16384)
+#define BF_LEFT (1)
+#define BF_MIDDLE (2048)
+#define BF_MONO (32768)
+#define BF_RECT (15)
+#define BF_RIGHT (4)
+#define BF_SOFT (4096)
+#define BF_TOP (2)
+#define BF_TOPLEFT (3)
+#define BF_TOPRIGHT (6)
+
+/* DrawFrameControl */
+#define DFC_BUTTON (4)
+#define DFC_CAPTION (1)
+#define DFC_MENU (2)
+#define DFC_SCROLL (3)
+#define DFCS_BUTTON3STATE (8)
+#define DFCS_BUTTONCHECK (0)
+#define DFCS_BUTTONPUSH (16)
+#define DFCS_BUTTONRADIO (4)
+#define DFCS_BUTTONRADIOIMAGE (1)
+#define DFCS_BUTTONRADIOMASK (2)
+#define DFCS_CAPTIONCLOSE (0)
+#define DFCS_CAPTIONHELP (4)
+#define DFCS_CAPTIONMAX (2)
+#define DFCS_CAPTIONMIN (1)
+#define DFCS_CAPTIONRESTORE (3)
+#define DFCS_MENUARROW (0)
+#define DFCS_MENUBULLET (2)
+#define DFCS_MENUCHECK (1)
+#define DFCS_SCROLLCOMBOBOX (5)
+#define DFCS_SCROLLDOWN (1)
+#define DFCS_SCROLLLEFT (2)
+#define DFCS_SCROLLRIGHT (3)
+#define DFCS_SCROLLSIZEGRIP (8)
+#define DFCS_SCROLLUP (0)
+#define DFCS_ADJUSTRECT (8192)
+#define DFCS_CHECKED (1024)
+#define DFCS_FLAT (16384)
+#define DFCS_INACTIVE (256)
+#define DFCS_MONO (32768)
+#define DFCS_PUSHED (512)
+
+/* DrawIconEx */
+#define DI_COMPAT (4)
+#define DI_DEFAULTSIZE (8)
+#define DI_IMAGE (2)
+#define DI_MASK (1)
+#define DI_NORMAL (3)
+
+/* DrawState */
+#define DST_BITMAP (4)
+#define DST_COMPLEX (0)
+#define DST_ICON (3)
+#define DST_PREFIXTEXT (2)
+#define DST_TEXT (1)
+#define DSS_NORMAL (0)
+#define DSS_UNION (16)
+#define DSS_DISABLED (32)
+#define DSS_MONO (128)
+
+/* DrawStatusText */
+#define SBT_NOBORDERS (256)
+#define SBT_OWNERDRAW (4096)
+#define SBT_POPOUT (512)
+#define SBT_RTLREADING (1024)
+
+/* DrawText, DrawTextEx */
+#define DT_BOTTOM (8)
+#define DT_CALCRECT (1024)
+#define DT_CENTER (1)
+#define DT_EDITCONTROL (8192)
+#define DT_END_ELLIPSIS (32768)
+#define DT_PATH_ELLIPSIS (16384)
+#define DT_EXPANDTABS (64)
+#define DT_EXTERNALLEADING (512)
+#define DT_LEFT (0)
+#define DT_MODIFYSTRING (65536)
+#define DT_NOCLIP (256)
+#define DT_NOPREFIX (2048)
+#define DT_RIGHT (2)
+#define DT_RTLREADING (131072)
+#define DT_SINGLELINE (32)
+#define DT_TABSTOP (128)
+#define DT_TOP (0)
+#define DT_VCENTER (4)
+#define DT_WORDBREAK (16)
+#define DT_INTERNAL (4096)
+
+/* DuplicateHandle, MapViewOfFile */
+#define DUPLICATE_CLOSE_SOURCE (1)
+#define DUPLICATE_SAME_ACCESS (2)
+#define FILE_MAP_ALL_ACCESS (0xf001fL)
+#define FILE_MAP_READ (4)
+#define FILE_MAP_WRITE (2)
+#define FILE_MAP_COPY (1)
+#define MUTEX_ALL_ACCESS (0x1f0001L)
+#define MUTEX_MODIFY_STATE (1)
+#define SYNCHRONIZE (0x100000L)
+#define SEMAPHORE_ALL_ACCESS (0x1f0003L)
+#define SEMAPHORE_MODIFY_STATE (2)
+#define EVENT_ALL_ACCESS (0x1f0003L)
+#define EVENT_MODIFY_STATE (2)
+#define KEY_ALL_ACCESS (0xf003fL)
+#define KEY_CREATE_LINK (32)
+#define KEY_CREATE_SUB_KEY (4)
+#define KEY_ENUMERATE_SUB_KEYS (8)
+#define KEY_EXECUTE (0x20019L)
+#define KEY_NOTIFY (16)
+#define KEY_QUERY_VALUE (1)
+#define KEY_READ (0x20019L)
+#define KEY_SET_VALUE (2)
+#define KEY_WRITE (0x20006L)
+#define PROCESS_ALL_ACCESS (0x1f0fffL)
+#define PROCESS_CREATE_PROCESS (128)
+#define PROCESS_CREATE_THREAD (2)
+#define PROCESS_DUP_HANDLE (64)
+#define PROCESS_QUERY_INFORMATION (1024)
+#define PROCESS_SET_INFORMATION (512)
+#define PROCESS_TERMINATE (1)
+#define PROCESS_VM_OPERATION (8)
+#define PROCESS_VM_READ (16)
+#define PROCESS_VM_WRITE (32)
+#define THREAD_ALL_ACCESS (0x1f03ffL)
+#define THREAD_DIRECT_IMPERSONATION (512)
+#define THREAD_GET_CONTEXT (8)
+#define THREAD_IMPERSONATE (256)
+#define THREAD_QUERY_INFORMATION (64)
+#define THREAD_SET_CONTEXT (16)
+#define THREAD_SET_INFORMATION (32)
+#define THREAD_SET_THREAD_TOKEN (128)
+#define THREAD_SUSPEND_RESUME (2)
+#define THREAD_TERMINATE (1)
+
+/* EditWordBreakProc */
+#define WB_ISDELIMITER (2)
+#define WB_LEFT (0)
+#define WB_RIGHT (1)
+
+/* EnableScrollBar */
+#define SB_BOTH (3)
+#define SB_CTL (2)
+#define SB_HORZ (0)
+#define SB_VERT (1)
+#define ESB_DISABLE_BOTH (3)
+#define ESB_DISABLE_DOWN (2)
+#define ESB_DISABLE_LEFT (1)
+#define ESB_DISABLE_LTUP (1)
+#define ESB_DISABLE_RIGHT (2)
+#define ESB_DISABLE_RTDN (2)
+#define ESB_DISABLE_UP (1)
+#define ESB_ENABLE_BOTH (0)
+
+/* Scroll Bar notifications*/
+#define SB_LINEUP (0)
+#define SB_LINEDOWN (1)
+#define SB_LINELEFT (0)
+#define SB_LINERIGHT (1)
+#define SB_PAGEUP (2)
+#define SB_PAGEDOWN (3)
+#define SB_PAGELEFT (2)
+#define SB_PAGERIGHT (3)
+#define SB_THUMBPOSITION (4)
+#define SB_THUMBTRACK (5)
+#define SB_ENDSCROLL (8)
+#define SB_LEFT (6)
+#define SB_RIGHT (7)
+#define SB_BOTTOM (7)
+#define SB_TOP (6)
+
+/* EnumCalendarInfo */
+#define ENUM_ALL_CALENDARS (-1)
+
+/* EnumDateFormats */
+#define DATE_SHORTDATE (1)
+#define DATE_LONGDATE (2)
+
+/* EnumDependentServices */
+#define SERVICE_ACTIVE (1)
+#define SERVICE_INACTIVE (2)
+
+/* EnumFontFamExProc */
+#define DEVICE_FONTTYPE (2)
+#define RASTER_FONTTYPE (1)
+#define TRUETYPE_FONTTYPE (4)
+
+/* EnumObjects, GetCurrentObject, GetObjectType */
+#define OBJ_BRUSH (2)
+#define OBJ_PEN (1)
+#define OBJ_PAL (5)
+#define OBJ_FONT (6)
+#define OBJ_BITMAP (7)
+#define OBJ_EXTPEN (11)
+#define OBJ_REGION (8)
+#define OBJ_DC (3)
+#define OBJ_MEMDC (10)
+#define OBJ_METAFILE (9)
+#define OBJ_METADC (4)
+#define OBJ_ENHMETAFILE (13)
+#define OBJ_ENHMETADC (12)
+
+/* EnumPrinters */
+
+/* EnumProtocols */
+
+/* EnumResLangProc */
+#define RT_ACCELERATOR (MAKEINTRESOURCE(9))
+#define RT_BITMAP (MAKEINTRESOURCE(2))
+#define RT_DIALOG (MAKEINTRESOURCE(5))
+#define RT_FONT (MAKEINTRESOURCE(8))
+#define RT_FONTDIR (MAKEINTRESOURCE(7))
+#define RT_MENU (MAKEINTRESOURCE(4))
+#define RT_RCDATA (MAKEINTRESOURCE(10))
+#define RT_STRING (MAKEINTRESOURCE(6))
+#define RT_MESSAGETABLE (MAKEINTRESOURCE(11))
+#define RT_CURSOR (MAKEINTRESOURCE(1))
+#define RT_GROUP_CURSOR (MAKEINTRESOURCE(12))
+#define RT_ICON (MAKEINTRESOURCE(3))
+#define RT_GROUP_ICON (MAKEINTRESOURCE(13))
+#define RT_VERSION (MAKEINTRESOURCE(16))
+
+/* EnumServicesStatus */
+#define SERVICE_WIN32 (48)
+#define SERVICE_DRIVER (11)
+
+/* EnumSystemCodePages */
+#define CP_INSTALLED (1)
+#define CP_SUPPORTED (2)
+
+/* EnumSystemLocales */
+#define LCID_INSTALLED (1)
+#define LCID_SUPPORTED (2)
+
+/* EraseTape */
+#define TAPE_ERASE_LONG (0x1L)
+#define TAPE_ERASE_SHORT (0L)
+
+/* Escape */
+#define SP_ERROR (-1)
+#define SP_OUTOFDISK (-4)
+#define SP_OUTOFMEMORY (-5)
+#define SP_USERABORT (-3)
+#define PHYSICALWIDTH (110)
+#define PHYSICALHEIGHT (111)
+#define PHYSICALOFFSETX (112)
+#define PHYSICALOFFSETY (113)
+#define SCALINGFACTORX (114)
+#define SCALINGFACTORY (115)
+#define QUERYESCSUPPORT (8)
+#define ABORTDOC (2)
+#define ENDDOC (11)
+#define GETPHYSPAGESIZE (12)
+#define GETPRINTINGOFFSET (13)
+#define GETSCALINGFACTOR (14)
+#define NEWFRAME (1)
+#define NEXTBAND (3)
+#define PASSTHROUGH (19)
+#define SETABORTPROC (9)
+#define STARTDOC (10)
+
+/* EscapeCommFunction */
+#define CLRDTR (6)
+#define CLRRTS (4)
+#define SETDTR (5)
+#define SETRTS (3)
+#define SETXOFF (1)
+#define SETXON (2)
+#define SETBREAK (8)
+#define CLRBREAK (9)
+
+/* ExitWindowsEx */
+#define EWX_FORCE (4)
+#define EWX_LOGOFF (0)
+#define EWX_POWEROFF (8)
+#define EWX_REBOOT (2)
+#define EWX_SHUTDOWN (1)
+
+/* ExtFloodFill */
+#define FLOODFILLBORDER (0)
+#define FLOODFILLSURFACE (1)
+
+/* ExtTextOut */
+#define ETO_CLIPPED (4)
+#define ETO_GLYPH_INDEX (16)
+#define ETO_OPAQUE (2)
+#define ETO_RTLREADING (128)
+
+/* FillConsoleOutputAttribute */
+#define FOREGROUND_BLUE (1)
+#define FOREGROUND_GREEN (2)
+#define FOREGROUND_RED (4)
+#define FOREGROUND_INTENSITY (8)
+#define BACKGROUND_BLUE (16)
+#define BACKGROUND_GREEN (32)
+#define BACKGROUND_RED (64)
+#define BACKGROUND_INTENSITY (128)
+
+/* FindFirstChangeNotification */
+#define FILE_NOTIFY_CHANGE_FILE_NAME (1)
+#define FILE_NOTIFY_CHANGE_DIR_NAME (2)
+#define FILE_NOTIFY_CHANGE_ATTRIBUTES (4)
+#define FILE_NOTIFY_CHANGE_SIZE (8)
+#define FILE_NOTIFY_CHANGE_LAST_WRITE (16)
+#define FILE_NOTIFY_CHANGE_SECURITY (256)
+
+/* FindFirstPrinterChangeNotification */
+
+/* FindNextPrinterNotification */
+
+/* FMExtensionProc */
+
+/* FoldString */
+#define MAP_FOLDCZONE (16)
+#define MAP_FOLDDIGITS (128)
+#define MAP_PRECOMPOSED (32)
+#define MAP_COMPOSITE (64)
+
+/* ForegroundIdleProc */
+#define HC_ACTION (0)
+
+/* FormatMessage */
+#define FORMAT_MESSAGE_ALLOCATE_BUFFER (256)
+#define FORMAT_MESSAGE_IGNORE_INSERTS (512)
+#define FORMAT_MESSAGE_FROM_STRING (1024)
+#define FORMAT_MESSAGE_FROM_HMODULE (2048)
+#define FORMAT_MESSAGE_FROM_SYSTEM (4096)
+#define FORMAT_MESSAGE_ARGUMENT_ARRAY (8192)
+#define FORMAT_MESSAGE_MAX_WIDTH_MASK (255)
+
+/* GdiComment */
+#define GDICOMMENT_WINDOWS_METAFILE (-2147483647)
+#define GDICOMMENT_BEGINGROUP (2)
+#define GDICOMMENT_ENDGROUP (3)
+#define GDICOMMENT_MULTIFORMATS (1073741828)
+#define GDICOMMENT_IDENTIFIER (1128875079)
+
+/* GenerateConsoleCtrlEvent, HandlerRoutine */
+#define CTRL_C_EVENT (0)
+#define CTRL_BREAK_EVENT (1)
+#define CTRL_CLOSE_EVENT (2)
+#define CTRL_LOGOFF_EVENT (5)
+#define CTRL_SHUTDOWN_EVENT (6)
+
+/* GetAddressByName */
+
+/* GetArcDirection */
+#define AD_COUNTERCLOCKWISE (1)
+#define AD_CLOCKWISE (2)
+
+/* GetBinaryTypes */
+#define SCS_32BIT_BINARY (0)
+#define SCS_DOS_BINARY (1)
+#define SCS_OS216_BINARY (5)
+#define SCS_PIF_BINARY (3)
+#define SCS_POSIX_BINARY (4)
+#define SCS_WOW_BINARY (2)
+
+/* GetBoundsRect, SetBoundsRect */
+#define DCB_DISABLE (8)
+#define DCB_ENABLE (4)
+#define DCB_RESET (1)
+#define DCB_SET (3)
+#define DCB_ACCUMULATE (2)
+
+/* GetCharacterPlacement, GetFontLanguageInfo */
+#define GCP_DBCS (1)
+#define GCP_ERROR (0x8000)
+#define GCP_CLASSIN (0x80000L)
+#define GCP_DIACRITIC (256)
+#define GCP_DISPLAYZWG (0x400000L)
+#define GCP_GLYPHSHAPE (16)
+#define GCP_JUSTIFY (0x10000L)
+#define GCP_JUSTIFYIN (0x200000L)
+#define GCP_KASHIDA (1024)
+#define GCP_LIGATE (32)
+#define GCP_MAXEXTENT (0x100000L)
+#define GCP_NEUTRALOVERRIDE (0x2000000L)
+#define GCP_NUMERICOVERRIDE (0x1000000L)
+#define GCP_NUMERICSLATIN (0x4000000L)
+#define GCP_NUMERICSLOCAL (0x8000000L)
+#define GCP_REORDER (2)
+#define GCP_SYMSWAPOFF (0x800000L)
+#define GCP_USEKERNING (8)
+#define FLI_GLYPHS (0x40000L)
+#define FLI_MASK (0x103b)
+
+/* GetClassLong, GetClassWord */
+#define GCW_ATOM (-32)
+#define GCL_CBCLSEXTRA (-20)
+#define GCL_CBWNDEXTRA (-18)
+#define GCL_HBRBACKGROUND (-10)
+#define GCL_HCURSOR (-12)
+#define GCL_HICON (-14)
+#define GCL_HICONSM (-34)
+#define GCL_HMODULE (-16)
+#define GCL_MENUNAME (-8)
+#define GCL_STYLE (-26)
+#define GCL_WNDPROC (-24)
+
+/* GetClipboardFormat, SetClipboardData */
+#define CF_BITMAP (2)
+#define CF_DIB (8)
+#define CF_PALETTE (9)
+#define CF_ENHMETAFILE (14)
+#define CF_METAFILEPICT (3)
+#define CF_OEMTEXT (7)
+#define CF_TEXT (1)
+#define CF_UNICODETEXT (13)
+#define CF_DIF (5)
+#define CF_DSPBITMAP (130)
+#define CF_DSPENHMETAFILE (142)
+#define CF_DSPMETAFILEPICT (131)
+#define CF_DSPTEXT (129)
+#define CF_GDIOBJFIRST (768)
+#define CF_GDIOBJLAST (1023)
+#define CF_HDROP (15)
+#define CF_LOCALE (16)
+#define CF_OWNERDISPLAY (128)
+#define CF_PENDATA (10)
+#define CF_PRIVATEFIRST (512)
+#define CF_PRIVATELAST (767)
+#define CF_RIFF (11)
+#define CF_SYLK (4)
+#define CF_WAVE (12)
+#define CF_TIFF (6)
+
+/* GetCommMask */
+#define EV_BREAK (64)
+#define EV_CTS (8)
+#define EV_DSR (16)
+#define EV_ERR (128)
+#define EV_EVENT1 (2048)
+#define EV_EVENT2 (4096)
+#define EV_PERR (512)
+#define EV_RING (256)
+#define EV_RLSD (32)
+#define EV_RX80FULL (1024)
+#define EV_RXCHAR (1)
+#define EV_RXFLAG (2)
+#define EV_TXEMPTY (4)
+
+/* GetCommModemStatus */
+#define MS_CTS_ON (0x10L)
+#define MS_DSR_ON (0x20L)
+#define MS_RING_ON (0x40L)
+#define MS_RLSD_ON (0x80L)
+
+/* GetComputerName */
+#define MAX_COMPUTERNAME_LENGTH (15)
+
+/* GetConsoleMode */
+#define ENABLE_LINE_INPUT (2)
+#define ENABLE_ECHO_INPUT (4)
+#define ENABLE_PROCESSED_INPUT (1)
+#define ENABLE_WINDOW_INPUT (8)
+#define ENABLE_MOUSE_INPUT (16)
+#define ENABLE_PROCESSED_OUTPUT (1)
+#define ENABLE_WRAP_AT_EOL_OUTPUT (2)
+
+/* GetCPInfo */
+#define CP_ACP (0)
+#define CP_MACCP (2)
+#define CP_OEMCP (1)
+
+/* GetDateFormat */
+#define DATE_SHORTDATE (1)
+#define DATE_LONGDATE (2)
+#define DATE_USE_ALT_CALENDAR (4)
+
+/* GetDCEx */
+#define DCX_WINDOW (0x1L)
+#define DCX_CACHE (0x2L)
+#define DCX_PARENTCLIP (0x20L)
+#define DCX_CLIPSIBLINGS (0x10L)
+#define DCX_CLIPCHILDREN (0x8L)
+#define DCX_NORESETATTRS (0x4L)
+#define DCX_LOCKWINDOWUPDATE (0x400L)
+#define DCX_EXCLUDERGN (0x40L)
+#define DCX_INTERSECTRGN (0x80L)
+#define DCX_VALIDATE (0x200000L)
+
+/* GetDeviceCaps */
+#define DRIVERVERSION (0)
+#define TECHNOLOGY (2)
+#define DT_PLOTTER (0)
+#define DT_RASDISPLAY (1)
+#define DT_RASPRINTER (2)
+#define DT_RASCAMERA (3)
+#define DT_CHARSTREAM (4)
+#define DT_METAFILE (5)
+#define DT_DISPFILE (6)
+#define HORZSIZE (4)
+#define VERTSIZE (6)
+#define HORZRES (8)
+#define VERTRES (10)
+#define LOGPIXELSX (88)
+#define LOGPIXELSY (90)
+#define BITSPIXEL (12)
+#define PLANES (14)
+#define NUMBRUSHES (16)
+#define NUMPENS (18)
+#define NUMFONTS (22)
+#define NUMCOLORS (24)
+#define ASPECTX (40)
+#define ASPECTY (42)
+#define ASPECTXY (44)
+#define PDEVICESIZE (26)
+#define CLIPCAPS (36)
+#define SIZEPALETTE (104)
+#define NUMRESERVED (106)
+#define COLORRES (108)
+#define PHYSICALWIDTH (110)
+#define PHYSICALHEIGHT (111)
+#define PHYSICALOFFSETX (112)
+#define PHYSICALOFFSETY (113)
+#define SCALINGFACTORX (114)
+#define SCALINGFACTORY (115)
+#define VREFRESH (116)
+#define DESKTOPHORZRES (118)
+#define DESKTOPVERTRES (117)
+#define BLTALIGNMENT (119)
+#define RASTERCAPS (38)
+#define RC_BANDING (2)
+#define RC_BITBLT (1)
+#define RC_BITMAP64 (8)
+#define RC_DI_BITMAP (128)
+#define RC_DIBTODEV (512)
+#define RC_FLOODFILL (4096)
+#define RC_GDI20_OUTPUT (16)
+#define RC_PALETTE (256)
+#define RC_SCALING (4)
+#define RC_STRETCHBLT (2048)
+#define RC_STRETCHDIB (8192)
+#define CURVECAPS (28)
+#define CC_NONE (0)
+#define CC_CIRCLES (1)
+#define CC_PIE (2)
+#define CC_CHORD (4)
+#define CC_ELLIPSES (8)
+#define CC_WIDE (16)
+#define CC_STYLED (32)
+#define CC_WIDESTYLED (64)
+#define CC_INTERIORS (128)
+#define CC_ROUNDRECT (256)
+#define LINECAPS (30)
+#define LC_NONE (0)
+#define LC_POLYLINE (2)
+#define LC_MARKER (4)
+#define LC_POLYMARKER (8)
+#define LC_WIDE (16)
+#define LC_STYLED (32)
+#define LC_WIDESTYLED (64)
+#define LC_INTERIORS (128)
+#define POLYGONALCAPS (32)
+#define PC_NONE (0)
+#define PC_POLYGON (1)
+#define PC_RECTANGLE (2)
+#define PC_WINDPOLYGON (4)
+#define PC_SCANLINE (8)
+#define PC_WIDE (16)
+#define PC_STYLED (32)
+#define PC_WIDESTYLED (64)
+#define PC_INTERIORS (128)
+#define TEXTCAPS (34)
+#define TC_OP_CHARACTER (1)
+#define TC_OP_STROKE (2)
+#define TC_CP_STROKE (4)
+#define TC_CR_90 (8)
+#define TC_CR_ANY (16)
+#define TC_SF_X_YINDEP (32)
+#define TC_SA_DOUBLE (64)
+#define TC_SA_INTEGER (128)
+#define TC_SA_CONTIN (256)
+#define TC_EA_DOUBLE (512)
+#define TC_IA_ABLE (1024)
+#define TC_UA_ABLE (2048)
+#define TC_SO_ABLE (4096)
+#define TC_RA_ABLE (8192)
+#define TC_VA_ABLE (16384)
+#define TC_RESERVED (32768)
+#define TC_SCROLLBLT (65536)
+#define PC_PATHS (512)
+
+/* GetDriveType */
+#define DRIVE_REMOVABLE (2)
+#define DRIVE_FIXED (3)
+#define DRIVE_REMOTE (4)
+#define DRIVE_CDROM (5)
+#define DRIVE_RAMDISK (6)
+#define DRIVE_UNKNOWN (0)
+#define DRIVE_NO_ROOT_DIR (1)
+
+/* GetExceptionCode */
+#define EXCEPTION_ACCESS_VIOLATION (0xc0000005L)
+#define EXCEPTION_BREAKPOINT (0x80000003L)
+#define EXCEPTION_DATATYPE_MISALIGNMENT (0x80000002L)
+#define EXCEPTION_SINGLE_STEP (0x80000004L)
+#define EXCEPTION_ARRAY_BOUNDS_EXCEEDED (0xc000008cL)
+#define EXCEPTION_FLT_DENORMAL_OPERAND (0xc000008dL)
+#define EXCEPTION_FLT_DIVIDE_BY_ZERO (0xc000008eL)
+#define EXCEPTION_FLT_INEXACT_RESULT (0xc000008fL)
+#define EXCEPTION_FLT_INVALID_OPERATION (0xc0000090L)
+#define EXCEPTION_FLT_OVERFLOW (0xc0000091L)
+#define EXCEPTION_FLT_STACK_CHECK (0xc0000092L)
+#define EXCEPTION_FLT_UNDERFLOW (0xc0000093L)
+#define EXCEPTION_INT_DIVIDE_BY_ZERO (0xc0000094L)
+#define EXCEPTION_INT_OVERFLOW (0xc0000095L)
+#define EXCEPTION_INVALID_HANDLE (0xc0000008L)
+#define EXCEPTION_PRIV_INSTRUCTION (0xc0000096L)
+#define EXCEPTION_NONCONTINUABLE_EXCEPTION (0xc0000025L)
+#define EXCEPTION_NONCONTINUABLE (0x1)
+#define EXCEPTION_STACK_OVERFLOW (0xc00000fdL)
+#define EXCEPTION_INVALID_DISPOSITION (0xc0000026L)
+
+/* GetFileType */
+#define FILE_TYPE_UNKNOWN (0)
+#define FILE_TYPE_DISK (1)
+#define FILE_TYPE_CHAR (2)
+#define FILE_TYPE_PIPE (3)
+
+/* GetGlyphOutline */
+#define GGO_BITMAP (1)
+#define GGO_NATIVE (2)
+#define GGO_METRICS (0)
+#define GGO_GRAY2_BITMAP (4)
+#define GGO_GRAY4_BITMAP (5)
+#define GGO_GRAY8_BITMAP (6)
+#define GDI_ERROR (0xffffffffL)
+
+/* GetGraphicsMode */
+#define GM_COMPATIBLE (1)
+#define GM_ADVANCED (2)
+
+/* GetHandleInformation */
+#define HANDLE_FLAG_INHERIT (1)
+#define HANDLE_FLAG_PROTECT_FROM_CLOSE (2)
+
+/* GetIconInfo */
+#define IDC_ARROW (MAKEINTRESOURCE(32512))
+#define IDC_IBEAM (MAKEINTRESOURCE(32513))
+#define IDC_WAIT (MAKEINTRESOURCE(32514))
+#define IDC_CROSS (MAKEINTRESOURCE(32515))
+#define IDC_UPARROW (MAKEINTRESOURCE(32516))
+#define IDC_SIZENWSE (MAKEINTRESOURCE(32642))
+#define IDC_SIZENESW (MAKEINTRESOURCE(32643))
+#define IDC_SIZEWE (MAKEINTRESOURCE(32644))
+#define IDC_SIZENS (MAKEINTRESOURCE(32645))
+#define IDC_SIZEALL (MAKEINTRESOURCE(32646))
+#define IDC_NO (MAKEINTRESOURCE(32648))
+#define IDC_APPSTARTING (MAKEINTRESOURCE(32650))
+#define IDC_HELP (MAKEINTRESOURCE(32651))
+#define IDI_APPLICATION (MAKEINTRESOURCE(32512))
+#define IDI_HAND (MAKEINTRESOURCE(32513))
+#define IDI_QUESTION (MAKEINTRESOURCE(32514))
+#define IDI_EXCLAMATION (MAKEINTRESOURCE(32515))
+#define IDI_ASTERISK (MAKEINTRESOURCE(32516))
+#define IDI_WINLOGO (MAKEINTRESOURCE(32517))
+#define IDC_SIZE (MAKEINTRESOURCE(32640))
+#define IDC_ICON (MAKEINTRESOURCE(32641))
+
+/* GetMapMode */
+#define MM_ANISOTROPIC (8)
+#define MM_HIENGLISH (5)
+#define MM_HIMETRIC (3)
+#define MM_ISOTROPIC (7)
+#define MM_LOENGLISH (4)
+#define MM_LOMETRIC (2)
+#define MM_TEXT (1)
+#define MM_TWIPS (6)
+
+/* GetMenuDefaultItem */
+#define GMDI_GOINTOPOPUPS (0x2L)
+#define GMDI_USEDISABLED (0x1L)
+
+/* PeekMessage */
+#define PM_NOREMOVE (0)
+#define PM_REMOVE (1)
+#define PM_NOYIELD (2)
+
+/* GetNamedPipeHandleState */
+#define PIPE_NOWAIT (1)
+#define PIPE_READMODE_MESSAGE (2)
+
+/* GetNamedPipeInfo */
+#define PIPE_CLIENT_END (0)
+#define PIPE_SERVER_END (1)
+#define PIPE_TYPE_MESSAGE (4)
+
+/* GetNextWindow, GetWindow */
+#define GW_HWNDNEXT (2)
+#define GW_HWNDPREV (3)
+#define GW_CHILD (5)
+#define GW_HWNDFIRST (0)
+#define GW_HWNDLAST (1)
+#define GW_OWNER (4)
+
+/* GetPath */
+#define PT_MOVETO (6)
+#define PT_LINETO (2)
+#define PT_BEZIERTO (4)
+#define PT_CLOSEFIGURE (1)
+
+/* GetProcessShutdownParameters */
+#define SHUTDOWN_NORETRY (1)
+
+/* GetQueueStatus */
+#define QS_ALLEVENTS (191)
+#define QS_ALLINPUT (255)
+#define QS_HOTKEY (128)
+#define QS_INPUT (7)
+#define QS_KEY (1)
+#define QS_MOUSE (6)
+#define QS_MOUSEBUTTON (4)
+#define QS_MOUSEMOVE (2)
+#define QS_PAINT (32)
+#define QS_POSTMESSAGE (8)
+#define QS_SENDMESSAGE (64)
+#define QS_TIMER (16)
+
+/* GetScrollInfo, SetScrollInfo */
+#define SIF_ALL (23)
+#define SIF_PAGE (2)
+#define SIF_POS (4)
+#define SIF_RANGE (1)
+#define SIF_DISABLENOSCROLL (8)
+
+/* GetStdHandle */
+#define STD_INPUT_HANDLE (DWORD)(-10)
+#define STD_OUTPUT_HANDLE (DWORD)(-11)
+#define STD_ERROR_HANDLE (DWORD)(-12)
+#define INVALID_HANDLE_VALUE ((HANDLE)-1)
+
+/* GetStockObject */
+#define BLACK_BRUSH (4)
+#define DKGRAY_BRUSH (3)
+#define GRAY_BRUSH (2)
+#define HOLLOW_BRUSH (5)
+#define LTGRAY_BRUSH (1)
+#define NULL_BRUSH (5)
+#define WHITE_BRUSH (0)
+#define BLACK_PEN (7)
+#define NULL_PEN (8)
+#define WHITE_PEN (6)
+#define ANSI_FIXED_FONT (11)
+#define ANSI_VAR_FONT (12)
+#define DEVICE_DEFAULT_FONT (14)
+#define DEFAULT_GUI_FONT (17)
+#define OEM_FIXED_FONT (10)
+#define SYSTEM_FONT (13)
+#define SYSTEM_FIXED_FONT (16)
+#define DEFAULT_PALETTE (15)
+
+/* GetStringTypeA */
+#define CT_CTYPE1 (1)
+#define CT_CTYPE2 (2)
+#define CT_CTYPE3 (4)
+#define C1_UPPER (1)
+#define C1_LOWER (2)
+#define C1_DIGIT (4)
+#define C1_SPACE (8)
+#define C1_PUNCT (16)
+#define C1_CNTRL (32)
+#define C1_BLANK (64)
+#define C1_XDIGIT (128)
+#define C1_ALPHA (256)
+#define C2_LEFTTORIGHT (1)
+#define C2_RIGHTTOLEFT (2)
+#define C2_EUROPENUMBER (3)
+#define C2_EUROPESEPARATOR (4)
+#define C2_EUROPETERMINATOR (5)
+#define C2_ARABICNUMBER (6)
+#define C2_COMMONSEPARATOR (7)
+#define C2_BLOCKSEPARATOR (8)
+#define C2_SEGMENTSEPARATOR (9)
+#define C2_WHITESPACE (10)
+#define C2_OTHERNEUTRAL (11)
+#define C2_NOTAPPLICABLE (0)
+#define C3_NONSPACING (1)
+#define C3_DIACRITIC (2)
+#define C3_VOWELMARK (4)
+#define C3_SYMBOL (8)
+#define C3_KATAKANA (16)
+#define C3_HIRAGANA (32)
+#define C3_HALFWIDTH (64)
+#define C3_FULLWIDTH (128)
+#define C3_IDEOGRAPH (256)
+#define C3_KASHIDA (512)
+#define C3_ALPHA (32768)
+#define C3_NOTAPPLICABLE (0)
+
+/* GetSysColor */
+#define COLOR_3DDKSHADOW (21)
+#define COLOR_3DFACE (15)
+#define COLOR_3DHILIGHT (20)
+#define COLOR_3DLIGHT (22)
+#define COLOR_BTNHILIGHT (20)
+#define COLOR_3DSHADOW (16)
+#define COLOR_ACTIVEBORDER (10)
+#define COLOR_ACTIVECAPTION (2)
+#define COLOR_APPWORKSPACE (12)
+#define COLOR_BACKGROUND (1)
+#define COLOR_DESKTOP (1)
+#define COLOR_BTNFACE (15)
+#define COLOR_BTNHIGHLIGHT (20)
+#define COLOR_BTNSHADOW (16)
+#define COLOR_BTNTEXT (18)
+#define COLOR_CAPTIONTEXT (9)
+#define COLOR_GRAYTEXT (17)
+#define COLOR_HIGHLIGHT (13)
+#define COLOR_HIGHLIGHTTEXT (14)
+#define COLOR_INACTIVEBORDER (11)
+#define COLOR_INACTIVECAPTION (3)
+#define COLOR_INACTIVECAPTIONTEXT (19)
+#define COLOR_INFOBK (24)
+#define COLOR_INFOTEXT (23)
+#define COLOR_MENU (4)
+#define COLOR_MENUTEXT (7)
+#define COLOR_SCROLLBAR (0)
+#define COLOR_WINDOW (5)
+#define COLOR_WINDOWFRAME (6)
+#define COLOR_WINDOWTEXT (8)
+
+/* GetSystemMetrics */
+#define SM_CYMIN (29)
+#define SM_CXMIN (28)
+#define SM_ARRANGE (56)
+#define SM_CLEANBOOT (67)
+/* The right value for SM_CEMETRICS for NT 3.5 is 75. For Windows 95
+ and NT 4.0, it is 76. The meaning is undocumented, anyhow. */
+#define SM_CMETRICS (76)
+#define SM_CMOUSEBUTTONS (43)
+#define SM_CXBORDER (5)
+#define SM_CYBORDER (6)
+#define SM_CXCURSOR (13)
+#define SM_CYCURSOR (14)
+#define SM_CXDLGFRAME (7)
+#define SM_CYDLGFRAME (8)
+#define SM_CXDOUBLECLK (36)
+#define SM_CYDOUBLECLK (37)
+#define SM_CXDRAG (68)
+#define SM_CYDRAG (69)
+#define SM_CXEDGE (45)
+#define SM_CYEDGE (46)
+#define SM_CXFIXEDFRAME (7)
+#define SM_CYFIXEDFRAME (8)
+#define SM_CXFRAME (32)
+#define SM_CYFRAME (33)
+#define SM_CXFULLSCREEN (16)
+#define SM_CYFULLSCREEN (17)
+#define SM_CXHSCROLL (21)
+#define SM_CYHSCROLL (3)
+#define SM_CXHTHUMB (10)
+#define SM_CXICON (11)
+#define SM_CYICON (12)
+#define SM_CXICONSPACING (38)
+#define SM_CYICONSPACING (39)
+#define SM_CXMAXIMIZED (61)
+#define SM_CYMAXIMIZED (62)
+#define SM_CXMAXTRACK (59)
+#define SM_CYMAXTRACK (60)
+#define SM_CXMENUCHECK (71)
+#define SM_CYMENUCHECK (72)
+#define SM_CXMENUSIZE (54)
+#define SM_CYMENUSIZE (55)
+#define SM_CXMINIMIZED (57)
+#define SM_CYMINIMIZED (58)
+#define SM_CXMINSPACING (47)
+#define SM_CYMINSPACING (48)
+#define SM_CXMINTRACK (34)
+#define SM_CYMINTRACK (35)
+#define SM_CXSCREEN (0)
+#define SM_CYSCREEN (1)
+#define SM_CXSIZE (30)
+#define SM_CYSIZE (31)
+#define SM_CXSIZEFRAME (32)
+#define SM_CYSIZEFRAME (33)
+#define SM_CXSMICON (49)
+#define SM_CYSMICON (50)
+#define SM_CXSMSIZE (52)
+#define SM_CYSMSIZE (53)
+#define SM_CXVSCROLL (2)
+#define SM_CYHSCROLL (3)
+#define SM_CXHSCROLL (21)
+#define SM_CYVSCROLL (20)
+#define SM_CYVTHUMB (9)
+#define SM_CYCAPTION (4)
+#define SM_CYKANJIWINDOW (18)
+#define SM_CYMENU (15)
+#define SM_CYSMCAPTION (51)
+#define SM_DBCSENABLED (42)
+#define SM_DEBUG (22)
+#define SM_MENUDROPALIGNMENT (40)
+#define SM_MIDEASTENABLED (74)
+#define SM_MOUSEPRESENT (19)
+#define SM_MOUSEWHEELPRESENT (75)
+#define SM_NETWORK (63)
+#define SM_PENWINDOWS (41)
+#define SM_SECURE (44)
+#define SM_SHOWSOUNDS (70)
+#define SM_SLOWMACHINE (73)
+#define SM_SWAPBUTTON (23)
+#define ARW_BOTTOMLEFT (0L)
+#define ARW_BOTTOMRIGHT (0x1L)
+#define ARW_HIDE (0x8L)
+#define ARW_TOPLEFT (0x2L)
+#define ARW_TOPRIGHT (0x3L)
+#define ARW_DOWN (0x4L)
+#define ARW_LEFT (0L)
+#define ARW_RIGHT (0L)
+#define ARW_UP (0x4L)
+
+/* GetSystemPaletteUse */
+#define SYSPAL_NOSTATIC (2)
+#define SYSPAL_STATIC (1)
+#define SYSPAL_ERROR (0)
+
+/* GetTapeParameters, SetTapeParameters */
+#define GET_TAPE_MEDIA_INFORMATION (0)
+#define GET_TAPE_DRIVE_INFORMATION (1)
+#define SET_TAPE_MEDIA_INFORMATION (0)
+#define SET_TAPE_DRIVE_INFORMATION (1)
+
+/* GetTapePosition */
+#define TAPE_ABSOLUTE_POSITION (0L)
+#define TAPE_LOGICAL_POSITION (0x1L)
+
+/* GetTextAlign */
+#define TA_BASELINE (24)
+#define TA_BOTTOM (8)
+#define TA_TOP (0)
+#define TA_CENTER (6)
+#define TA_LEFT (0)
+#define TA_RIGHT (2)
+#define TA_RTLREADING (256)
+#define TA_NOUPDATECP (0)
+#define TA_UPDATECP (1)
+#define VTA_BASELINE (24)
+#define VTA_CENTER (6)
+
+/* GetThreadPriority */
+#define THREAD_PRIORITY_ABOVE_NORMAL (1)
+#define THREAD_PRIORITY_BELOW_NORMAL (-1)
+#define THREAD_PRIORITY_HIGHEST (2)
+#define THREAD_PRIORITY_IDLE (-15)
+#define THREAD_PRIORITY_LOWEST (-2)
+#define THREAD_PRIORITY_NORMAL (0)
+#define THREAD_PRIORITY_TIME_CRITICAL (15)
+#define THREAD_PRIORITY_ERROR_RETURN (2147483647)
+#define TLS_MINIMUM_AVAILABLE (64)
+
+/* GetTimeFormat */
+#define TIME_NOMINUTESORSECONDS (1)
+#define TIME_NOSECONDS (2)
+#define TIME_NOTIMEMARKER (4)
+#define TIME_FORCE24HOURFORMAT (8)
+
+/* GetTimeZoneInformation */
+#define TIME_ZONE_ID_INVALID ((DWORD) -1)
+#define TIME_ZONE_ID_UNKNOWN (0)
+#define TIME_ZONE_ID_STANDARD (1)
+#define TIME_ZONE_ID_DAYLIGHT (2)
+
+/* GetUserObjectInformation */
+#define UOI_FLAGS (1)
+#define UOI_NAME (2)
+#define UOI_TYPE (3)
+
+/* GetVolumeInformation */
+#define FS_CASE_IS_PRESERVED (2)
+#define FS_CASE_SENSITIVE (1)
+#define FS_UNICODE_STORED_ON_DISK (4)
+#define FS_PERSISTENT_ACLS (8)
+#define FS_FILE_COMPRESSION (16)
+#define FS_VOL_IS_COMPRESSED (32768)
+
+/* GetWindowLong */
+#define GWL_EXSTYLE (-20)
+#define GWL_STYLE (-16)
+#define GWL_WNDPROC (-4)
+#define GWL_HINSTANCE (-6)
+#define GWL_HWNDPARENT (-8)
+#define GWL_ID (-12)
+#define GWL_USERDATA (-21)
+#define DWL_DLGPROC (4)
+#define DWL_MSGRESULT (0)
+#define DWL_USER (8)
+
+/* GlobalAlloc, GlobalFlags */
+#define GMEM_FIXED (0)
+#define GMEM_MOVEABLE (2)
+#define GPTR (64)
+#define GHND (66)
+#define GMEM_DDESHARE (8192)
+#define GMEM_DISCARDABLE (256)
+#define GMEM_LOWER (4096)
+#define GMEM_NOCOMPACT (16)
+#define GMEM_NODISCARD (32)
+#define GMEM_NOT_BANKED (4096)
+#define GMEM_NOTIFY (16384)
+#define GMEM_SHARE (8192)
+#define GMEM_ZEROINIT (64)
+#define GMEM_DISCARDED (16384)
+#define GMEM_INVALID_HANDLE (32768)
+#define GMEM_LOCKCOUNT (255)
+
+/* HeapAlloc, HeapReAlloc */
+#define HEAP_GENERATE_EXCEPTIONS (4)
+#define HEAP_NO_SERIALIZE (1)
+#define HEAP_ZERO_MEMORY (8)
+#define STATUS_NO_MEMORY (0xc0000017L)
+#define STATUS_ACCESS_VIOLATION (0xc0000005L)
+#define HEAP_REALLOC_IN_PLACE_ONLY (16)
+
+/* ImageList_Create */
+#define ILC_COLOR (0)
+#define ILC_COLOR4 (4)
+#define ILC_COLOR8 (8)
+#define ILC_COLOR16 (16)
+#define ILC_COLOR24 (24)
+#define ILC_COLOR32 (32)
+#define ILC_COLORDDB (254)
+#define ILC_MASK (1)
+#define ILC_PALETTE (2048)
+
+/* ImageList_Draw, ImageList_DrawEx */
+#define ILD_BLEND25 (2)
+#define ILD_BLEND50 (4)
+#define ILD_SELECTED (4)
+#define ILD_BLEND (4)
+#define ILD_FOCUS (2)
+#define ILD_MASK (16)
+#define ILD_NORMAL (0)
+#define ILD_TRANSPARENT (1)
+#define CLR_NONE (0xffffffffL)
+#define CLR_DEFAULT (0xff000000L)
+
+/* ImageList_LoadImage */
+#define LR_DEFAULTCOLOR (0)
+#define LR_LOADFROMFILE (16)
+#define LR_LOADMAP3DCOLORS (4096)
+#define LR_LOADTRANSPARENT (32)
+#define LR_MONOCHROME (1)
+
+/* ImmConfigureIME */
+#define IME_CONFIG_GENERAL (1)
+#define IME_CONFIG_REGISTERWORD (2)
+#define IME_CONFIG_SELECTDICTIONARY (3)
+
+/* ImmGetConversionList */
+#define GCL_CONVERSION (1)
+#define GCL_REVERSECONVERSION (2)
+#define GCL_REVERSE_LENGTH (3)
+
+/* ImmGetGuideLine */
+#define GGL_LEVEL (1)
+#define GGL_INDEX (2)
+#define GGL_STRING (3)
+#define GGL_PRIVATE (4)
+#define GL_LEVEL_ERROR (2)
+#define GL_LEVEL_FATAL (1)
+#define GL_LEVEL_INFORMATION (4)
+#define GL_LEVEL_NOGUIDELINE (0)
+#define GL_LEVEL_WARNING (3)
+#define GL_ID_CANNOTSAVE (17)
+#define GL_ID_NOCONVERT (32)
+#define GL_ID_NODICTIONARY (16)
+#define GL_ID_NOMODULE (1)
+#define GL_ID_READINGCONFLICT (35)
+#define GL_ID_TOOMANYSTROKE (34)
+#define GL_ID_TYPINGERROR (33)
+#define GL_ID_UNKNOWN (0)
+#define GL_ID_INPUTREADING (36)
+#define GL_ID_INPUTRADICAL (37)
+#define GL_ID_INPUTCODE (38)
+#define GL_ID_CHOOSECANDIDATE (40)
+#define GL_ID_REVERSECONVERSION (41)
+
+/* ImmGetProperty */
+#define IGP_PROPERTY (4)
+#define IGP_CONVERSION (8)
+#define IGP_SENTENCE (12)
+#define IGP_UI (16)
+#define IGP_SETCOMPSTR (20)
+#define IGP_SELECT (24)
+#define IME_PROP_AT_CARET (65536)
+#define IME_PROP_SPECIAL_UI (131072)
+#define IME_PROP_CANDLIST_START_FROM_1 (262144)
+#define IME_PROP_UNICODE (524288)
+#define UI_CAP_2700 (1)
+#define UI_CAP_ROT90 (2)
+#define UI_CAP_ROTANY (4)
+#define SCS_CAP_COMPSTR (1)
+#define SCS_CAP_MAKEREAD (2)
+#define SELECT_CAP_CONVERSION (1)
+#define SELECT_CAP_SENTENCE (2)
+
+/* ImmNotifyIME */
+#define NI_CHANGECANDIDATELIST (19)
+#define NI_CLOSECANDIDATE (17)
+#define NI_COMPOSITIONSTR (21)
+#define NI_OPENCANDIDATE (16)
+#define NI_SELECTCANDIDATESTR (18)
+#define NI_SETCANDIDATE_PAGESIZE (23)
+#define NI_SETCANDIDATE_PAGESTART (22)
+#define CPS_CANCEL (4)
+#define CPS_COMPLETE (1)
+#define CPS_CONVERT (2)
+#define CPS_REVERT (3)
+
+/* ImmSetCompositionString */
+#define SCS_SETSTR (9)
+#define SCS_CHANGEATTR (18)
+#define SCS_CHANGECLAUSE (36)
+
+/* ImmUnregisterWord */
+#define IME_REGWORD_STYLE_EUDC (1)
+#define IME_REGWORD_STYLE_USER_FIRST 0x80000000
+#define IME_REGWORD_STYLE_USER_LAST (-1)
+
+/* InitializeSecurityDescriptor */
+#define SECURITY_DESCRIPTOR_REVISION (1)
+
+/* IsTextUnicode */
+#define IS_TEXT_UNICODE_ASCII16 (1)
+#define IS_TEXT_UNICODE_REVERSE_ASCII16 (16)
+#define IS_TEXT_UNICODE_STATISTICS (2)
+#define IS_TEXT_UNICODE_REVERSE_STATISTICS (32)
+#define IS_TEXT_UNICODE_CONTROLS (4)
+#define IS_TEXT_UNICODE_REVERSE_CONTROLS (64)
+#define IS_TEXT_UNICODE_SIGNATURE (8)
+#define IS_TEXT_UNICODE_REVERSE_SIGNATURE (128)
+#define IS_TEXT_UNICODE_ILLEGAL_CHARS (256)
+#define IS_TEXT_UNICODE_ODD_LENGTH (512)
+#define IS_TEXT_UNICODE_NULL_BYTES (4096)
+#define IS_TEXT_UNICODE_UNICODE_MASK (15)
+#define IS_TEXT_UNICODE_REVERSE_MASK (240)
+#define IS_TEXT_UNICODE_NOT_UNICODE_MASK (3840)
+#define IS_TEXT_UNICODE_NOT_ASCII_MASK (61440)
+
+/* JournalPlaybackProc, KeyboardProc */
+#define HC_GETNEXT (1)
+#define HC_SKIP (2)
+#define HC_SYSMODALOFF (5)
+#define HC_SYSMODALON (4)
+#define HC_NOREMOVE (3)
+
+/* keybd_event */
+#define KEYEVENTF_EXTENDEDKEY (1)
+#define KEYEVENTF_KEYUP (2)
+
+/* LoadBitmap */
+#define OBM_BTNCORNERS (32758)
+#define OBM_BTSIZE (32761)
+#define OBM_CHECK (32760)
+#define OBM_CHECKBOXES (32759)
+#define OBM_CLOSE (32754)
+#define OBM_COMBO (32738)
+#define OBM_DNARROW (32752)
+#define OBM_DNARROWD (32742)
+#define OBM_DNARROWI (32736)
+#define OBM_LFARROW (32750)
+#define OBM_LFARROWI (32734)
+#define OBM_LFARROWD (32740)
+#define OBM_MNARROW (32739)
+#define OBM_OLD_CLOSE (32767)
+#define OBM_OLD_DNARROW (32764)
+#define OBM_OLD_LFARROW (32762)
+#define OBM_OLD_REDUCE (32757)
+#define OBM_OLD_RESTORE (32755)
+#define OBM_OLD_RGARROW (32763)
+#define OBM_OLD_UPARROW (32765)
+#define OBM_OLD_ZOOM (32756)
+#define OBM_REDUCE (32749)
+#define OBM_REDUCED (32746)
+#define OBM_RESTORE (32747)
+#define OBM_RESTORED (32744)
+#define OBM_RGARROW (32751)
+#define OBM_RGARROWD (32741)
+#define OBM_RGARROWI (32735)
+#define OBM_SIZE (32766)
+#define OBM_UPARROW (32753)
+#define OBM_UPARROWD (32743)
+#define OBM_UPARROWI (32737)
+#define OBM_ZOOM (32748)
+#define OBM_ZOOMD (32745)
+
+/* LoadLibraryEx */
+#define DONT_RESOLVE_DLL_REFERENCES (1)
+#define LOAD_LIBRARY_AS_DATAFILE (2)
+#define LOAD_WITH_ALTERED_SEARCH_PATH (8)
+
+/* LocalAlloc, LocalFlags */
+#define LPTR (64)
+#define LHND (66)
+#define NONZEROLHND (2)
+#define NONZEROLPTR (0)
+#define LMEM_NONZEROLHND (2)
+#define LMEM_NONZEROLPTR (0)
+#define LMEM_FIXED (0)
+#define LMEM_MOVEABLE (2)
+#define LMEM_NOCOMPACT (16)
+#define LMEM_NODISCARD (32)
+#define LMEM_ZEROINIT (64)
+#define LMEM_MODIFY (128)
+#define LMEM_LOCKCOUNT (255)
+#define LMEM_DISCARDABLE (3840)
+#define LMEM_DISCARDED (16384)
+#define LMEM_INVALID_HANDLE (32768)
+
+/* LockFileEx */
+#define LOCKFILE_FAIL_IMMEDIATELY (1)
+#define LOCKFILE_EXCLUSIVE_LOCK (2)
+
+/* LogonUser */
+
+/* LZCopy, LZInit, LZRead */
+
+/* MessageBeep, MessageBox */
+#define MB_USERICON (0x80L)
+#define MB_ICONASTERISK (0x40L)
+#define MB_ICONEXCLAMATION (0x30L)
+#define MB_ICONWARNING (0x30L)
+#define MB_ICONERROR (0x10L)
+#define MB_ICONHAND (0x10L)
+#define MB_ICONQUESTION (0x20L)
+#define MB_OK (0L)
+#define MB_ABORTRETRYIGNORE (0x2L)
+#define MB_APPLMODAL (0L)
+#define MB_DEFAULT_DESKTOP_ONLY (0x20000L)
+#define MB_HELP (0x4000L)
+#define MB_RIGHT (0x80000L)
+#define MB_RTLREADING (0x100000L)
+#define MB_TOPMOST (0x40000L)
+#define MB_DEFBUTTON1 (0L)
+#define MB_DEFBUTTON2 (0x100L)
+#define MB_DEFBUTTON3 (0x200L)
+#define MB_DEFBUTTON4 (0x300L)
+#define MB_ICONINFORMATION (0x40L)
+#define MB_ICONSTOP (0x10L)
+#define MB_OKCANCEL (0x1L)
+#define MB_RETRYCANCEL (0x5L)
+#define MB_SERVICE_NOTIFICATION (0x40000L)
+#define MB_SETFOREGROUND (0x10000L)
+#define MB_SYSTEMMODAL (0x1000L)
+#define MB_TASKMODAL (0x2000L)
+#define MB_YESNO (0x4L)
+#define MB_YESNOCANCEL (0x3L)
+#define IDABORT (3)
+#define IDCANCEL (2)
+#define IDCLOSE (8)
+#define IDHELP (9)
+#define IDIGNORE (5)
+#define IDNO (7)
+#define IDOK (1)
+#define IDRETRY (4)
+#define IDYES (6)
+
+/* MessageProc */
+#define MSGF_DIALOGBOX (0)
+#define MSGF_MENU (2)
+#define MSGF_NEXTWINDOW (6)
+#define MSGF_SCROLLBAR (5)
+#define MSGF_MAINLOOP (8)
+#define MSGF_USER (4096)
+
+/* ModifyWorldTransform */
+#define MWT_IDENTITY (1)
+#define MWT_LEFTMULTIPLY (2)
+#define MWT_RIGHTMULTIPLY (3)
+
+/* mouse_event */
+#define MOUSEEVENTF_ABSOLUTE (32768)
+#define MOUSEEVENTF_MOVE (1)
+#define MOUSEEVENTF_LEFTDOWN (2)
+#define MOUSEEVENTF_LEFTUP (4)
+#define MOUSEEVENTF_RIGHTDOWN (8)
+#define MOUSEEVENTF_RIGHTUP (16)
+#define MOUSEEVENTF_MIDDLEDOWN (32)
+#define MOUSEEVENTF_MIDDLEUP (64)
+
+/* MoveFileEx */
+#define MOVEFILE_REPLACE_EXISTING (1)
+#define MOVEFILE_COPY_ALLOWED (2)
+#define MOVEFILE_DELAY_UNTIL_REBOOT (4)
+
+/* MsgWaitForMultipleObjects, WaitForMultipleObjectsEx */
+#define WAIT_OBJECT_0 (0L)
+#define WAIT_ABANDONED_0 (0x80L)
+#define WAIT_TIMEOUT (0x102L)
+#define WAIT_IO_COMPLETION (0xc0L)
+#define WAIT_ABANDONED (0x80L)
+#define WAIT_FAILED (0xffffffffL)
+#define MAXIMUM_WAIT_OBJECTS (0x40)
+#define MAXIMUM_SUSPEND_COUNT (0x7f)
+
+/* MultiByteToWideChar */
+#define MB_PRECOMPOSED (1)
+#define MB_COMPOSITE (2)
+#define MB_ERR_INVALID_CHARS (8)
+#define MB_USEGLYPHCHARS (4)
+
+/* NDdeSetTrustedShare */
+
+/* NetAccessCheck */
+
+/* NetServerEnum */
+
+/* NetServiceControl */
+
+/* NetUserEnum */
+
+/* OpenProcessToken */
+#define TOKEN_ADJUST_DEFAULT (128)
+#define TOKEN_ADJUST_GROUPS (64)
+#define TOKEN_ADJUST_PRIVILEGES (32)
+#define TOKEN_ALL_ACCESS (0xf00ffL)
+#define TOKEN_ASSIGN_PRIMARY (1)
+#define TOKEN_DUPLICATE (2)
+#define TOKEN_EXECUTE (0x20000L)
+#define TOKEN_IMPERSONATE (4)
+#define TOKEN_QUERY (8)
+#define TOKEN_QUERY_SOURCE (16)
+#define TOKEN_READ (0x20008L)
+#define TOKEN_WRITE (0x200e0L)
+
+/* OpenSCManager */
+#define SC_MANAGER_ALL_ACCESS (0xf003fL)
+#define SC_MANAGER_CONNECT (1)
+#define SC_MANAGER_CREATE_SERVICE (2)
+#define SC_MANAGER_ENUMERATE_SERVICE (4)
+#define SC_MANAGER_LOCK (8)
+#define SC_MANAGER_QUERY_LOCK_STATUS (16)
+#define SC_MANAGER_MODIFY_BOOT_CONFIG (32)
+
+/* PostMessage */
+#define HWND_BROADCAST ((HWND)0xFFFF)
+
+/* PrepareTape */
+#define TAPE_FORMAT (0x5L)
+#define TAPE_LOAD (0L)
+#define TAPE_LOCK (0x3L)
+#define TAPE_TENSION (0x2L)
+#define TAPE_UNLOAD (0x1L)
+#define TAPE_UNLOCK (0x4L)
+
+/* PropertySheet */
+#define IS_PSREBOOTSYSTEM (3)
+#define IS_PSRESTARTWINDOWS (2)
+
+/* PropSheetPageProc */
+#define PSPCB_CREATE (2)
+#define PSPCB_RELEASE (1)
+
+/* PurgeComm */
+#define PURGE_TXABORT (1)
+#define PURGE_RXABORT (2)
+#define PURGE_TXCLEAR (4)
+#define PURGE_RXCLEAR (8)
+
+/* QueryServiceObjectSecurity */
+#define OWNER_SECURITY_INFORMATION (0x1L)
+#define GROUP_SECURITY_INFORMATION (0x2L)
+#define DACL_SECURITY_INFORMATION (0x4L)
+#define SACL_SECURITY_INFORMATION (0x8L)
+
+/* ReadEventLog, ReportEvent */
+#define EVENTLOG_FORWARDS_READ (4)
+#define EVENTLOG_BACKWARDS_READ (8)
+#define EVENTLOG_SEEK_READ (2)
+#define EVENTLOG_SEQUENTIAL_READ (1)
+#define EVENTLOG_ERROR_TYPE (1)
+#define EVENTLOG_WARNING_TYPE (2)
+#define EVENTLOG_INFORMATION_TYPE (4)
+#define EVENTLOG_AUDIT_SUCCESS (8)
+#define EVENTLOG_AUDIT_FAILURE (16)
+
+/* RedrawWindow */
+#define RDW_ERASE (4)
+#define RDW_FRAME (1024)
+#define RDW_INTERNALPAINT (2)
+#define RDW_INVALIDATE (1)
+#define RDW_NOERASE (32)
+#define RDW_NOFRAME (2048)
+#define RDW_NOINTERNALPAINT (16)
+#define RDW_VALIDATE (8)
+#define RDW_ERASENOW (512)
+#define RDW_UPDATENOW (256)
+#define RDW_ALLCHILDREN (128)
+#define RDW_NOCHILDREN (64)
+
+/* RegCreateKey */
+#define HKEY_CLASSES_ROOT ((HKEY)0x80000000)
+#define HKEY_CURRENT_USER ((HKEY)0x80000001)
+#define HKEY_LOCAL_MACHINE ((HKEY)0x80000002)
+#define HKEY_USERS ((HKEY)0x80000003)
+#define HKEY_PERFORMANCE_DATA ((HKEY)0x80000004)
+#define HKEY_CURRENT_CONFIG ((HKEY)0x80000005)
+#define HKEY_DYN_DATA ((HKEY)0x00000006)
+
+/* RegCreateKeyEx */
+#define REG_OPTION_VOLATILE (0x1L)
+#define REG_OPTION_NON_VOLATILE (0L)
+#define REG_CREATED_NEW_KEY (0x1L)
+#define REG_OPENED_EXISTING_KEY (0x2L)
+
+/* RegEnumValue */
+#define REG_BINARY (3)
+#define REG_DWORD (4)
+#define REG_DWORD_LITTLE_ENDIAN (4)
+#define REG_DWORD_BIG_ENDIAN (5)
+#define REG_EXPAND_SZ (2)
+#define REG_FULL_RESOURCE_DESCRIPTOR (9)
+#define REG_LINK (6)
+#define REG_MULTI_SZ (7)
+#define REG_NONE (0)
+#define REG_RESOURCE_LIST (8)
+#define REG_RESOURCE_REQUIREMENTS_LIST (10)
+#define REG_SZ (1)
+
+/* RegisterHotKey */
+#define MOD_ALT (1)
+#define MOD_CONTROL (2)
+#define MOD_SHIFT (4)
+#define MOD_WIN (8)
+#define IDHOT_SNAPDESKTOP (-2)
+#define IDHOT_SNAPWINDOW (-1)
+
+/* RegNotifyChangeKeyValue */
+#define REG_NOTIFY_CHANGE_NAME (0x1L)
+#define REG_NOTIFY_CHANGE_ATTRIBUTES (0x2L)
+#define REG_NOTIFY_CHANGE_LAST_SET (0x4L)
+#define REG_NOTIFY_CHANGE_SECURITY (0x8L)
+
+/* ScrollWindowEx */
+#define SW_ERASE (4)
+#define SW_INVALIDATE (2)
+#define SW_SCROLLCHILDREN (1)
+
+/* SendMessageTimeout */
+#define SMTO_ABORTIFHUNG (2)
+#define SMTO_BLOCK (1)
+#define SMTO_NORMAL (0)
+
+/* SetBkMode */
+#define OPAQUE (2)
+#define TRANSPARENT (1)
+
+/* SetDebugErrorLevel */
+#define SLE_ERROR (1)
+#define SLE_MINORERROR (2)
+#define SLE_WARNING (3)
+
+/* SetErrorMode */
+#define SEM_FAILCRITICALERRORS (1)
+#define SEM_NOALIGNMENTFAULTEXCEPT (4)
+#define SEM_NOGPFAULTERRORBOX (2)
+#define SEM_NOOPENFILEERRORBOX (32768)
+
+/* SetICMMode */
+#define ICM_ON (2)
+#define ICM_OFF (1)
+#define ICM_QUERY (3)
+
+/* SetJob */
+
+/* Locale Information */
+#define LOCALE_ILANGUAGE (1)
+#define LOCALE_SLANGUAGE (2)
+#define LOCALE_SENGLANGUAGE (4097)
+#define LOCALE_SABBREVLANGNAME (3)
+#define LOCALE_SNATIVELANGNAME (4)
+#define LOCALE_ICOUNTRY (5)
+#define LOCALE_SCOUNTRY (6)
+#define LOCALE_SENGCOUNTRY (4098)
+#define LOCALE_SABBREVCTRYNAME (7)
+#define LOCALE_SNATIVECTRYNAME (8)
+#define LOCALE_IDEFAULTLANGUAGE (9)
+#define LOCALE_IDEFAULTCOUNTRY (10)
+#define LOCALE_IDEFAULTANSICODEPAGE (4100)
+#define LOCALE_IDEFAULTCODEPAGE (11)
+#define LOCALE_SLIST (12)
+#define LOCALE_IMEASURE (13)
+#define LOCALE_SDECIMAL (14)
+#define LOCALE_STHOUSAND (15)
+#define LOCALE_SGROUPING (16)
+#define LOCALE_IDIGITS (17)
+#define LOCALE_ILZERO (18)
+#define LOCALE_INEGNUMBER (4112)
+#define LOCALE_SCURRENCY (20)
+#define LOCALE_SMONDECIMALSEP (22)
+#define LOCALE_SMONTHOUSANDSEP (23)
+#define LOCALE_SMONGROUPING (24)
+#define LOCALE_ICURRDIGITS (25)
+#define LOCALE_ICURRENCY (27)
+#define LOCALE_INEGCURR (28)
+#define LOCALE_SDATE (29)
+#define LOCALE_STIME (30)
+#define LOCALE_STIMEFORMAT (4099)
+#define LOCALE_SSHORTDATE (31)
+#define LOCALE_SLONGDATE (32)
+#define LOCALE_IDATE (33)
+#define LOCALE_ILDATE (34)
+#define LOCALE_ITIME (35)
+#define LOCALE_ITLZERO (37)
+#define LOCALE_IDAYLZERO (38)
+#define LOCALE_IMONLZERO (39)
+#define LOCALE_S1159 (40)
+#define LOCALE_S2359 (41)
+#define LOCALE_ICALENDARTYPE (4105)
+#define LOCALE_IOPTIONALCALENDAR (4107)
+#define LOCALE_IFIRSTDAYOFWEEK (4108)
+#define LOCALE_IFIRSTWEEKOFYEAR (4109)
+#define LOCALE_SDAYNAME1 (42)
+#define LOCALE_SDAYNAME2 (43)
+#define LOCALE_SDAYNAME3 (44)
+#define LOCALE_SDAYNAME4 (45)
+#define LOCALE_SDAYNAME5 (46)
+#define LOCALE_SDAYNAME6 (47)
+#define LOCALE_SDAYNAME7 (48)
+#define LOCALE_SABBREVDAYNAME1 (49)
+#define LOCALE_SABBREVDAYNAME2 (50)
+#define LOCALE_SABBREVDAYNAME3 (51)
+#define LOCALE_SABBREVDAYNAME4 (52)
+#define LOCALE_SABBREVDAYNAME5 (53)
+#define LOCALE_SABBREVDAYNAME6 (54)
+#define LOCALE_SABBREVDAYNAME7 (55)
+#define LOCALE_SMONTHNAME1 (56)
+#define LOCALE_SMONTHNAME2 (57)
+#define LOCALE_SMONTHNAME3 (58)
+#define LOCALE_SMONTHNAME4 (59)
+#define LOCALE_SMONTHNAME5 (60)
+#define LOCALE_SMONTHNAME6 (61)
+#define LOCALE_SMONTHNAME7 (62)
+#define LOCALE_SMONTHNAME8 (63)
+#define LOCALE_SMONTHNAME9 (64)
+#define LOCALE_SMONTHNAME10 (65)
+#define LOCALE_SMONTHNAME11 (66)
+#define LOCALE_SMONTHNAME12 (67)
+#define LOCALE_SMONTHNAME13 (4110)
+#define LOCALE_SABBREVMONTHNAME1 (68)
+#define LOCALE_SABBREVMONTHNAME2 (69)
+#define LOCALE_SABBREVMONTHNAME3 (70)
+#define LOCALE_SABBREVMONTHNAME4 (71)
+#define LOCALE_SABBREVMONTHNAME5 (72)
+#define LOCALE_SABBREVMONTHNAME6 (73)
+#define LOCALE_SABBREVMONTHNAME7 (74)
+#define LOCALE_SABBREVMONTHNAME8 (75)
+#define LOCALE_SABBREVMONTHNAME9 (76)
+#define LOCALE_SABBREVMONTHNAME10 (77)
+#define LOCALE_SABBREVMONTHNAME11 (78)
+#define LOCALE_SABBREVMONTHNAME12 (79)
+#define LOCALE_SABBREVMONTHNAME13 (4111)
+#define LOCALE_SPOSITIVESIGN (80)
+#define LOCALE_SNEGATIVESIGN (81)
+#define LOCALE_IPOSSIGNPOSN (82)
+#define LOCALE_INEGSIGNPOSN (83)
+#define LOCALE_IPOSSYMPRECEDES (84)
+#define LOCALE_IPOSSEPBYSPACE (85)
+#define LOCALE_INEGSYMPRECEDES (86)
+#define LOCALE_INEGSEPBYSPACE (87)
+#define LOCALE_NOUSEROVERRIDE (0x80000000)
+
+/* Calendar Type Information */
+#define CAL_ICALINTVALUE (1)
+#define CAL_IYEAROFFSETRANGE (3)
+#define CAL_SABBREVDAYNAME1 (14)
+#define CAL_SABBREVDAYNAME2 (15)
+#define CAL_SABBREVDAYNAME3 (16)
+#define CAL_SABBREVDAYNAME4 (17)
+#define CAL_SABBREVDAYNAME5 (18)
+#define CAL_SABBREVDAYNAME6 (19)
+#define CAL_SABBREVDAYNAME7 (20)
+#define CAL_SABBREVMONTHNAME1 (34)
+#define CAL_SABBREVMONTHNAME2 (35)
+#define CAL_SABBREVMONTHNAME3 (36)
+#define CAL_SABBREVMONTHNAME4 (37)
+#define CAL_SABBREVMONTHNAME5 (38)
+#define CAL_SABBREVMONTHNAME6 (39)
+#define CAL_SABBREVMONTHNAME7 (40)
+#define CAL_SABBREVMONTHNAME8 (41)
+#define CAL_SABBREVMONTHNAME9 (42)
+#define CAL_SABBREVMONTHNAME10 (43)
+#define CAL_SABBREVMONTHNAME11 (44)
+#define CAL_SABBREVMONTHNAME12 (45)
+#define CAL_SABBREVMONTHNAME13 (46)
+#define CAL_SCALNAME (2)
+#define CAL_SDAYNAME1 (7)
+#define CAL_SDAYNAME2 (8)
+#define CAL_SDAYNAME3 (9)
+#define CAL_SDAYNAME4 (10)
+#define CAL_SDAYNAME5 (11)
+#define CAL_SDAYNAME6 (12)
+#define CAL_SDAYNAME7 (13)
+#define CAL_SERASTRING (4)
+#define CAL_SLONGDATE (6)
+#define CAL_SMONTHNAME1 (21)
+#define CAL_SMONTHNAME2 (22)
+#define CAL_SMONTHNAME3 (23)
+#define CAL_SMONTHNAME4 (24)
+#define CAL_SMONTHNAME5 (25)
+#define CAL_SMONTHNAME6 (26)
+#define CAL_SMONTHNAME7 (27)
+#define CAL_SMONTHNAME8 (28)
+#define CAL_SMONTHNAME9 (29)
+#define CAL_SMONTHNAME10 (30)
+#define CAL_SMONTHNAME11 (31)
+#define CAL_SMONTHNAME12 (32)
+#define CAL_SMONTHNAME13 (33)
+#define CAL_SSHORTDATE (5)
+
+/* SetProcessWorkingSetSize */
+#define PROCESS_SET_QUOTA (256)
+
+/* SetPrinter */
+
+/* SetService */
+
+/* SetStretchBltMode */
+#define BLACKONWHITE (1)
+#define COLORONCOLOR (3)
+#define HALFTONE (4)
+#define STRETCH_ANDSCANS (1)
+#define STRETCH_DELETESCANS (3)
+#define STRETCH_HALFTONE (4)
+#define STRETCH_ORSCANS (2)
+#define WHITEONBLACK (2)
+
+/* SetSystemCursor */
+#define OCR_NORMAL (32512)
+#define OCR_IBEAM (32513)
+#define OCR_WAIT (32514)
+#define OCR_CROSS (32515)
+#define OCR_UP (32516)
+#define OCR_SIZE (32640)
+#define OCR_ICON (32641)
+#define OCR_SIZENWSE (32642)
+#define OCR_SIZENESW (32643)
+#define OCR_SIZEWE (32644)
+#define OCR_SIZENS (32645)
+#define OCR_SIZEALL (32646)
+#define OCR_NO (32648)
+#define OCR_APPSTARTING (32650)
+
+/* SetTapePosition */
+#define TAPE_ABSOLUTE_BLOCK (0x1L)
+#define TAPE_LOGICAL_BLOCK (0x2L)
+#define TAPE_REWIND (0L)
+#define TAPE_SPACE_END_OF_DATA (0x4L)
+#define TAPE_SPACE_FILEMARKS (0x6L)
+#define TAPE_SPACE_RELATIVE_BLOCKS (0x5L)
+#define TAPE_SPACE_SEQUENTIAL_FMKS (0x7L)
+#define TAPE_SPACE_SEQUENTIAL_SMKS (0x9L)
+#define TAPE_SPACE_SETMARKS (0x8L)
+
+/* SetUnhandledExceptionFilter */
+#define EXCEPTION_EXECUTE_HANDLER (1)
+#define EXCEPTION_CONTINUE_EXECUTION (-1)
+#define EXCEPTION_CONTINUE_SEARCH (0)
+
+/* SetWindowPos, DeferWindowPos */
+#define HWND_BOTTOM ((HWND)1)
+#define HWND_NOTOPMOST ((HWND)-2)
+#define HWND_TOP ((HWND)0)
+#define HWND_TOPMOST ((HWND)-1)
+#define SWP_DRAWFRAME (32)
+#define SWP_FRAMECHANGED (32)
+#define SWP_HIDEWINDOW (128)
+#define SWP_NOACTIVATE (16)
+#define SWP_NOCOPYBITS (256)
+#define SWP_NOMOVE (2)
+#define SWP_NOSIZE (1)
+#define SWP_NOREDRAW (8)
+#define SWP_NOZORDER (4)
+#define SWP_SHOWWINDOW (64)
+#define SWP_NOOWNERZORDER (512)
+#define SWP_NOREPOSITION (512)
+#define SWP_NOSENDCHANGING (1024)
+
+/* SHAddToRecentDocs */
+
+/* SHAppBarMessage */
+
+/* SHChangeNotify */
+
+/* ShellProc */
+#define HSHELL_ACTIVATESHELLWINDOW (3)
+#define HSHELL_GETMINRECT (5)
+#define HSHELL_LANGUAGE (8)
+#define HSHELL_REDRAW (6)
+#define HSHELL_TASKMAN (7)
+#define HSHELL_WINDOWACTIVATED (4)
+#define HSHELL_WINDOWCREATED (1)
+#define HSHELL_WINDOWDESTROYED (2)
+
+/* SHGetFileInfo */
+
+/* SHGetSpecialFolderLocation */
+
+/* ShowWindow */
+#define SW_HIDE (0)
+#define SW_MAXIMIZE (3)
+#define SW_MINIMIZE (6)
+#define SW_NORMAL (1)
+#define SW_RESTORE (9)
+#define SW_SHOW (5)
+#define SW_SHOWDEFAULT (10)
+#define SW_SHOWMAXIMIZED (3)
+#define SW_SHOWMINIMIZED (2)
+#define SW_SHOWMINNOACTIVE (7)
+#define SW_SHOWNA (8)
+#define SW_SHOWNOACTIVATE (4)
+#define SW_SHOWNORMAL (1)
+#define WPF_RESTORETOMAXIMIZED (2)
+#define WPF_SETMINPOSITION (1)
+
+/* Sleep */
+#define INFINITE 0xFFFFFFFF
+
+/* SystemParametersInfo */
+#define SPI_GETACCESSTIMEOUT (60)
+#define SPI_GETANIMATION (72)
+#define SPI_GETBEEP (1)
+#define SPI_GETBORDER (5)
+#define SPI_GETDEFAULTINPUTLANG (89)
+#define SPI_GETDRAGFULLWINDOWS (38)
+#define SPI_GETFASTTASKSWITCH (35)
+#define SPI_GETFILTERKEYS (50)
+#define SPI_GETFONTSMOOTHING (74)
+#define SPI_GETGRIDGRANULARITY (18)
+#define SPI_GETHIGHCONTRAST (66)
+#define SPI_GETICONMETRICS (45)
+#define SPI_GETICONTITLELOGFONT (31)
+#define SPI_GETICONTITLEWRAP (25)
+#define SPI_GETKEYBOARDDELAY (22)
+#define SPI_GETKEYBOARDPREF (68)
+#define SPI_GETKEYBOARDSPEED (10)
+#define SPI_GETLOWPOWERACTIVE (83)
+#define SPI_GETLOWPOWERTIMEOUT (79)
+#define SPI_GETMENUDROPALIGNMENT (27)
+#define SPI_GETMINIMIZEDMETRICS (43)
+#define SPI_GETMOUSE (3)
+#define SPI_GETMOUSEKEYS (54)
+#define SPI_GETMOUSETRAILS (94)
+#define SPI_GETNONCLIENTMETRICS (41)
+#define SPI_GETPOWEROFFACTIVE (84)
+#define SPI_GETPOWEROFFTIMEOUT (80)
+#define SPI_GETSCREENREADER (70)
+#define SPI_GETSCREENSAVEACTIVE (16)
+#define SPI_GETSCREENSAVETIMEOUT (14)
+#define SPI_GETSERIALKEYS (62)
+#define SPI_GETSHOWSOUNDS (56)
+#define SPI_GETSOUNDSENTRY (64)
+#define SPI_GETSTICKYKEYS (58)
+#define SPI_GETTOGGLEKEYS (52)
+#define SPI_GETWINDOWSEXTENSION (92)
+#define SPI_GETWORKAREA (48)
+#define SPI_ICONHORIZONTALSPACING (13)
+#define SPI_ICONVERTICALSPACING (24)
+#define SPI_LANGDRIVER (12)
+#define SPI_SCREENSAVERRUNNING (97)
+#define SPI_SETACCESSTIMEOUT (61)
+#define SPI_SETANIMATION (73)
+#define SPI_SETBEEP (2)
+#define SPI_SETBORDER (6)
+#define SPI_SETDEFAULTINPUTLANG (90)
+#define SPI_SETDESKPATTERN (21)
+#define SPI_SETDESKWALLPAPER (20)
+#define SPI_SETDOUBLECLICKTIME (32)
+#define SPI_SETDOUBLECLKHEIGHT (30)
+#define SPI_SETDOUBLECLKWIDTH (29)
+#define SPI_SETDRAGFULLWINDOWS (37)
+#define SPI_SETDRAGHEIGHT (77)
+#define SPI_SETDRAGWIDTH (76)
+#define SPI_SETFASTTASKSWITCH (36)
+#define SPI_SETFILTERKEYS (51)
+#define SPI_SETFONTSMOOTHING (75)
+#define SPI_SETGRIDGRANULARITY (19)
+#define SPI_SETHANDHELD (78)
+#define SPI_SETHIGHCONTRAST (67)
+#define SPI_SETICONMETRICS (46)
+#define SPI_SETICONTITLELOGFONT (34)
+#define SPI_SETICONTITLEWRAP (26)
+#define SPI_SETKEYBOARDDELAY (23)
+#define SPI_SETKEYBOARDPREF (69)
+#define SPI_SETKEYBOARDSPEED (11)
+#define SPI_SETLANGTOGGLE (91)
+#define SPI_SETLOWPOWERACTIVE (85)
+#define SPI_SETLOWPOWERTIMEOUT (81)
+#define SPI_SETMENUDROPALIGNMENT (28)
+#define SPI_SETMINIMIZEDMETRICS (44)
+#define SPI_SETMOUSE (4)
+#define SPI_SETMOUSEBUTTONSWAP (33)
+#define SPI_SETMOUSEKEYS (55)
+#define SPI_SETMOUSETRAILS (93)
+#define SPI_SETNONCLIENTMETRICS (42)
+#define SPI_SETPENWINDOWS (49)
+#define SPI_SETPOWEROFFACTIVE (86)
+#define SPI_SETPOWEROFFTIMEOUT (82)
+#define SPI_SETSCREENREADER (71)
+#define SPI_SETSCREENSAVEACTIVE (17)
+#define SPI_SETSCREENSAVETIMEOUT (15)
+#define SPI_SETSERIALKEYS (63)
+#define SPI_SETSHOWSOUNDS (57)
+#define SPI_SETSOUNDSENTRY (65)
+#define SPI_SETSTICKYKEYS (59)
+#define SPI_SETTOGGLEKEYS (53)
+#define SPI_SETWORKAREA (47)
+#define SPIF_UPDATEINIFILE (1)
+#define SPIF_SENDWININICHANGE (2)
+#define SPIF_SENDCHANGE (2)
+
+/* TrackPopupMenu, TrackPopMenuEx */
+#define TPM_CENTERALIGN (0x4L)
+#define TPM_LEFTALIGN (0L)
+#define TPM_RIGHTALIGN (0x8L)
+#define TPM_LEFTBUTTON (0L)
+#define TPM_RIGHTBUTTON (0x2L)
+#define TPM_HORIZONTAL (0L)
+#define TPM_VERTICAL (0x40L)
+
+/* TranslateCharsetInfo */
+#define TCI_SRCCHARSET (1)
+#define TCI_SRCCODEPAGE (2)
+#define TCI_SRCFONTSIG (3)
+
+/* VerFindFile */
+#define VFFF_ISSHAREDFILE (1)
+#define VFF_CURNEDEST (1)
+#define VFF_FILEINUSE (2)
+#define VFF_BUFFTOOSMALL (4)
+
+/* VerInstallFile */
+#define VIFF_FORCEINSTALL (1)
+#define VIFF_DONTDELETEOLD (2)
+#define VIF_TEMPFILE (0x1L)
+#define VIF_MISMATCH (0x2L)
+#define VIF_SRCOLD (0x4L)
+#define VIF_DIFFLANG (0x8L)
+#define VIF_DIFFCODEPG (0x10L)
+#define VIF_DIFFTYPE (0x20L)
+#define VIF_WRITEPROT (0x40L)
+#define VIF_FILEINUSE (0x80L)
+#define VIF_OUTOFSPACE (0x100L)
+#define VIF_ACCESSVIOLATION (0x200L)
+#define VIF_SHARINGVIOLATION (0x400L)
+#define VIF_CANNOTCREATE (0x800L)
+#define VIF_CANNOTDELETE (0x1000L)
+#define VIF_CANNOTDELETECUR (0x4000L)
+#define VIF_CANNOTRENAME (0x2000L)
+#define VIF_OUTOFMEMORY (0x8000L)
+#define VIF_CANNOTREADSRC (0x10000L)
+#define VIF_CANNOTREADDST (0x20000L)
+#define VIF_BUFFTOOSMALL (0x40000L)
+
+/* WideCharToMultiByte */
+#define WC_COMPOSITECHECK (512)
+#define WC_DISCARDNS (16)
+#define WC_SEPCHARS (32)
+#define WC_DEFAULTCHAR (64)
+
+/* WinHelp */
+#define HELP_COMMAND (0x102L)
+#define HELP_CONTENTS (0x3L)
+#define HELP_CONTEXT (0x1L)
+#define HELP_CONTEXTPOPUP (0x8L)
+#define HELP_FORCEFILE (0x9L)
+#define HELP_HELPONHELP (0x4L)
+#define HELP_INDEX (0x3L)
+#define HELP_KEY (0x101L)
+#define HELP_MULTIKEY (0x201L)
+#define HELP_PARTIALKEY (0x105L)
+#define HELP_QUIT (0x2L)
+#define HELP_SETCONTENTS (0x5L)
+#define HELP_SETINDEX (0x5L)
+#define HELP_CONTEXTMENU (0xa)
+#define HELP_FINDER (0xb)
+#define HELP_WM_HELP (0xc)
+#define HELP_TCARD (0x8000)
+#define HELP_TCARD_DATA (0x10)
+#define HELP_TCARD_OTHER_CALLER (0x11)
+
+/* WNetAddConnectino2 */
+#define CONNECT_UPDATE_PROFILE (1)
+
+/* WNetConnectionDialog, WNetDisconnectDialog, WNetOpenEnum */
+#define RESOURCETYPE_DISK (1)
+#define RESOURCETYPE_PRINT (2)
+#define RESOURCETYPE_ANY (0)
+#define RESOURCE_CONNECTED (1)
+#define RESOURCE_GLOBALNET (2)
+#define RESOURCE_REMEMBERED (3)
+#define RESOURCEUSAGE_CONNECTABLE (1)
+#define RESOURCEUSAGE_CONTAINER (2)
+
+/* WNetGetResourceInformation, WNetGetResourceParent */
+#define WN_BAD_NETNAME (0x43L)
+#define WN_EXTENDED_ERROR (0x4b8L)
+#define WN_MORE_DATA (0xeaL)
+#define WN_NO_NETWORK (0x4c6L)
+#define WN_SUCCESS (0L)
+#define WN_ACCESS_DENIED (0x5L)
+#define WN_BAD_PROVIDER (0x4b4L)
+#define WN_NOT_AUTHENTICATED (0x4dcL)
+
+/* WNetGetUniversalName */
+#define UNIVERSAL_NAME_INFO_LEVEL (1)
+#define REMOTE_NAME_INFO_LEVEL (2)
+
+/* GetExitCodeThread */
+#define STILL_ACTIVE (0x103L)
+
+/* COMMPROP structure */
+#define SP_SERIALCOMM (0x1L)
+#define BAUD_075 (0x1L)
+#define BAUD_110 (0x2L)
+#define BAUD_134_5 (0x4L)
+#define BAUD_150 (0x8L)
+#define BAUD_300 (0x10L)
+#define BAUD_600 (0x20L)
+#define BAUD_1200 (0x40L)
+#define BAUD_1800 (0x80L)
+#define BAUD_2400 (0x100L)
+#define BAUD_4800 (0x200L)
+#define BAUD_7200 (0x400L)
+#define BAUD_9600 (0x800L)
+#define BAUD_14400 (0x1000L)
+#define BAUD_19200 (0x2000L)
+#define BAUD_38400 (0x4000L)
+#define BAUD_56K (0x8000L)
+#define BAUD_57600 (0x40000L)
+#define BAUD_115200 (0x20000L)
+#define BAUD_128K (0x10000L)
+#define BAUD_USER (0x10000000L)
+#define PST_FAX (0x21L)
+#define PST_LAT (0x101L)
+#define PST_MODEM (0x6L)
+#define PST_NETWORK_BRIDGE (0x100L)
+#define PST_PARALLELPORT (0x2L)
+#define PST_RS232 (0x1L)
+#define PST_RS422 (0x3L)
+#define PST_RS423 (0x4L)
+#define PST_RS449 (0x5L)
+#define PST_SCANNER (0x22L)
+#define PST_TCPIP_TELNET (0x102L)
+#define PST_UNSPECIFIED (0L)
+#define PST_X25 (0x103L)
+#define PCF_16BITMODE (0x200L)
+#define PCF_DTRDSR (0x1L)
+#define PCF_INTTIMEOUTS (0x80L)
+#define PCF_PARITY_CHECK (0x8L)
+#define PCF_RLSD (0x4L)
+#define PCF_RTSCTS (0x2L)
+#define PCF_SETXCHAR (0x20L)
+#define PCF_SPECIALCHARS (0x100L)
+#define PCF_TOTALTIMEOUTS (0x40L)
+#define PCF_XONXOFF (0x10L)
+#define SP_BAUD (0x2L)
+#define SP_DATABITS (0x4L)
+#define SP_HANDSHAKING (0x10L)
+#define SP_PARITY (0x1L)
+#define SP_PARITY_CHECK (0x20L)
+#define SP_RLSD (0x40L)
+#define SP_STOPBITS (0x8L)
+#define DATABITS_5 (1)
+#define DATABITS_6 (2)
+#define DATABITS_7 (4)
+#define DATABITS_8 (8)
+#define DATABITS_16 (16)
+#define DATABITS_16X (32)
+#define STOPBITS_10 (1)
+#define STOPBITS_15 (2)
+#define STOPBITS_20 (4)
+#define PARITY_NONE (256)
+#define PARITY_ODD (512)
+#define PARITY_EVEN (1024)
+#define PARITY_MARK (2048)
+#define PARITY_SPACE (4096)
+#define COMMPROP_INITIALIZED (0xe73cf52eL)
+
+/* DCB structure */
+#define CBR_110 (110)
+#define CBR_300 (300)
+#define CBR_600 (600)
+#define CBR_1200 (1200)
+#define CBR_2400 (2400)
+#define CBR_4800 (4800)
+#define CBR_9600 (9600)
+#define CBR_14400 (14400)
+#define CBR_19200 (19200)
+#define CBR_38400 (38400)
+#define CBR_56000 (56000)
+#define CBR_57600 (57600)
+#define CBR_115200 (115200)
+#define CBR_128000 (128000)
+#define CBR_256000 (256000)
+#define DTR_CONTROL_DISABLE (0)
+#define DTR_CONTROL_ENABLE (1)
+#define DTR_CONTROL_HANDSHAKE (2)
+#define RTS_CONTROL_DISABLE (0)
+#define RTS_CONTROL_ENABLE (1)
+#define RTS_CONTROL_HANDSHAKE (2)
+#define RTS_CONTROL_TOGGLE (3)
+#define EVENPARITY (2)
+#define MARKPARITY (3)
+#define NOPARITY (0)
+#define ODDPARITY (1)
+#define SPACEPARITY (4)
+#define ONESTOPBIT (0)
+#define ONE5STOPBITS (1)
+#define TWOSTOPBITS (2)
+
+/* Debugging events */
+#define CREATE_PROCESS_DEBUG_EVENT (3)
+#define CREATE_THREAD_DEBUG_EVENT (2)
+#define EXCEPTION_DEBUG_EVENT (1)
+#define EXIT_PROCESS_DEBUG_EVENT (5)
+#define EXIT_THREAD_DEBUG_EVENT (4)
+#define LOAD_DLL_DEBUG_EVENT (6)
+#define OUTPUT_DEBUG_STRING_EVENT (8)
+#define UNLOAD_DLL_DEBUG_EVENT (7)
+#define RIP_EVENT (9)
+
+/* PROCESS_HEAP_ENTRY structure */
+#define PROCESS_HEAP_REGION (1)
+#define PROCESS_HEAP_UNCOMMITTED_RANGE (2)
+#define PROCESS_HEAP_ENTRY_BUSY (4)
+#define PROCESS_HEAP_ENTRY_MOVEABLE (16)
+#define PROCESS_HEAP_ENTRY_DDESHARE (32)
+
+/* Win32s */
+#define HINSTANCE_ERROR (32)
+
+/* WIN32_STREAM_ID structure */
+#define BACKUP_DATA (1)
+#define BACKUP_EA_DATA (2)
+#define BACKUP_SECURITY_DATA (3)
+#define BACKUP_ALTERNATE_DATA (4)
+#define BACKUP_LINK (5)
+#define STREAM_MODIFIED_WHEN_READ (1)
+#define STREAM_CONTAINS_SECURITY (2)
+
+/* STARTUPINFO structure */
+#define STARTF_USESHOWWINDOW (1)
+#define STARTF_USEPOSITION (4)
+#define STARTF_USESIZE (2)
+#define STARTF_USECOUNTCHARS (8)
+#define STARTF_USEFILLATTRIBUTE (16)
+#define STARTF_RUNFULLSCREEN (32)
+#define STARTF_FORCEONFEEDBACK (64)
+#define STARTF_FORCEOFFFEEDBACK (128)
+#define STARTF_USESTDHANDLES (256)
+#define STARTF_USEHOTKEY (512)
+
+/* OSVERSIONINFO structure */
+#define VER_PLATFORM_WIN32s (0)
+#define VER_PLATFORM_WIN32_WINDOWS (1)
+#define VER_PLATFORM_WIN32_NT (2)
+
+/* PROPSHEETPAGE structure */
+#define MAXPROPPAGES (100)
+#define PSP_DEFAULT (0)
+#define PSP_DLGINDIRECT (1)
+#define PSP_HASHELP (32)
+#define PSP_USECALLBACK (128)
+#define PSP_USEHICON (2)
+#define PSP_USEICONID (4)
+#define PSP_USEREFPARENT (64)
+#define PSP_USETITLE (8)
+#define PSP_RTLREADING (16)
+
+/* PROPSHEETHEADER structure */
+#define PSH_DEFAULT (0)
+#define PSH_HASHELP (512)
+#define PSH_MODELESS (1024)
+#define PSH_NOAPPLYNOW (128)
+#define PSH_PROPSHEETPAGE (8)
+#define PSH_PROPTITLE (1)
+#define PSH_USECALLBACK (256)
+#define PSH_USEHICON (2)
+#define PSH_USEICONID (4)
+#define PSH_USEPSTARTPAGE (64)
+#define PSH_WIZARD (32)
+#define PSH_RTLREADING (2048)
+#define PSCB_INITIALIZED (1)
+#define PSCB_PRECREATE (2)
+
+/* PSN_APPLY message */
+#define PSNRET_NOERROR (0)
+#define PSNRET_INVALID_NOCHANGEPAGE (2)
+
+/* Property Sheet */
+#define PSBTN_APPLYNOW (4)
+#define PSBTN_BACK (0)
+#define PSBTN_CANCEL (5)
+#define PSBTN_FINISH (2)
+#define PSBTN_HELP (6)
+#define PSBTN_NEXT (1)
+#define PSBTN_OK (3)
+#define PSWIZB_BACK (1)
+#define PSWIZB_NEXT (2)
+#define PSWIZB_FINISH (4)
+#define PSWIZB_DISABLEDFINISH (8)
+#define ID_PSREBOOTSYSTEM (3)
+#define ID_PSRESTARTWINDOWS (2)
+#define WIZ_BODYCX (184)
+#define WIZ_BODYX (92)
+#define WIZ_CXBMP (80)
+#define WIZ_CXDLG (276)
+#define WIZ_CYDLG (140)
+
+/* VX_FIXEDFILEINFO structure */
+#define VS_FILE_INFO (MAKEINTRESOURCE(16))
+#define VS_VERSION_INFO (1)
+#define VS_FF_DEBUG (0x1L)
+#define VS_FF_INFOINFERRED (0x10L)
+#define VS_FF_PATCHED (0x4L)
+#define VS_FF_PRERELEASE (0x2L)
+#define VS_FF_PRIVATEBUILD (0x8L)
+#define VS_FF_SPECIALBUILD (0x20L)
+#define VOS_UNKNOWN (0L)
+#define VOS_DOS (0x10000L)
+#define VOS_OS216 (0x20000L)
+#define VOS_OS232 (0x30000L)
+#define VOS_NT (0x40000L)
+#define VOS_DOS_WINDOWS16 (0x10001L)
+#define VOS_DOS_WINDOWS32 (0x10004L)
+#define VOS_OS216_PM16 (0x20002L)
+#define VOS_OS232_PM32 (0x30003L)
+#define VOS_NT_WINDOWS32 (0x40004L)
+#define VFT_UNKNOWN (0L)
+#define VFT_APP (0x1L)
+#define VFT_DLL (0x2L)
+#define VFT_DRV (0x3L)
+#define VFT_FONT (0x4L)
+#define VFT_VXD (0x5L)
+#define VFT_STATIC_LIB (0x7L)
+#define VFT2_UNKNOWN (0L)
+#define VFT2_DRV_PRINTER (0x1L)
+#define VFT2_DRV_KEYBOARD (0x2L)
+#define VFT2_DRV_LANGUAGE (0x3L)
+#define VFT2_DRV_DISPLAY (0x4L)
+#define VFT2_DRV_MOUSE (0x5L)
+#define VFT2_DRV_NETWORK (0x6L)
+#define VFT2_DRV_SYSTEM (0x7L)
+#define VFT2_DRV_INSTALLABLE (0x8L)
+#define VFT2_DRV_SOUND (0x9L)
+#define VFT2_FONT_RASTER (0x1L)
+#define VFT2_FONT_VECTOR (0x2L)
+#define VFT2_FONT_TRUETYPE (0x3L)
+
+/* PANOSE structure */
+#define PAN_ANY (0)
+#define PAN_NO_FIT (1)
+#define PAN_FAMILY_TEXT_DISPLAY (2)
+#define PAN_FAMILY_SCRIPT (3)
+#define PAN_FAMILY_DECORATIVE (4)
+#define PAN_FAMILY_PICTORIAL (5)
+#define PAN_SERIF_COVE (2)
+#define PAN_SERIF_OBTUSE_COVE (3)
+#define PAN_SERIF_SQUARE_COVE (4)
+#define PAN_SERIF_OBTUSE_SQUARE_COVE (5)
+#define PAN_SERIF_SQUARE (6)
+#define PAN_SERIF_THIN (7)
+#define PAN_SERIF_BONE (8)
+#define PAN_SERIF_EXAGGERATED (9)
+#define PAN_SERIF_TRIANGLE (10)
+#define PAN_SERIF_NORMAL_SANS (11)
+#define PAN_SERIF_OBTUSE_SANS (12)
+#define PAN_SERIF_PERP_SANS (13)
+#define PAN_SERIF_FLARED (14)
+#define PAN_SERIF_ROUNDED (15)
+#define PAN_WEIGHT_VERY_LIGHT (2)
+#define PAN_WEIGHT_LIGHT (3)
+#define PAN_WEIGHT_THIN (4)
+#define PAN_WEIGHT_BOOK (5)
+#define PAN_WEIGHT_MEDIUM (6)
+#define PAN_WEIGHT_DEMI (7)
+#define PAN_WEIGHT_BOLD (8)
+#define PAN_WEIGHT_HEAVY (9)
+#define PAN_WEIGHT_BLACK (10)
+#define PAN_WEIGHT_NORD (11)
+#define PAN_PROP_OLD_STYLE (2)
+#define PAN_PROP_MODERN (3)
+#define PAN_PROP_EVEN_WIDTH (4)
+#define PAN_PROP_EXPANDED (5)
+#define PAN_PROP_CONDENSED (6)
+#define PAN_PROP_VERY_EXPANDED (7)
+#define PAN_PROP_VERY_CONDENSED (8)
+#define PAN_PROP_MONOSPACED (9)
+#define PAN_CONTRAST_NONE (2)
+#define PAN_CONTRAST_VERY_LOW (3)
+#define PAN_CONTRAST_LOW (4)
+#define PAN_CONTRAST_MEDIUM_LOW (5)
+#define PAN_CONTRAST_MEDIUM (6)
+#define PAN_CONTRAST_MEDIUM_HIGH (7)
+#define PAN_CONTRAST_HIGH (8)
+#define PAN_CONTRAST_VERY_HIGH (9)
+#define PAN_STROKE_GRADUAL_DIAG (2)
+#define PAN_STROKE_GRADUAL_TRAN (3)
+#define PAN_STROKE_GRADUAL_VERT (4)
+#define PAN_STROKE_GRADUAL_HORZ (5)
+#define PAN_STROKE_RAPID_VERT (6)
+#define PAN_STROKE_RAPID_HORZ (7)
+#define PAN_STROKE_INSTANT_VERT (8)
+#define PAN_STRAIGHT_ARMS_HORZ (2)
+#define PAN_STRAIGHT_ARMS_WEDGE (3)
+#define PAN_STRAIGHT_ARMS_VERT (4)
+#define PAN_STRAIGHT_ARMS_SINGLE_SERIF (5)
+#define PAN_STRAIGHT_ARMS_DOUBLE_SERIF (6)
+#define PAN_BENT_ARMS_HORZ (7)
+#define PAN_BENT_ARMS_VERT (9)
+#define PAN_BENT_ARMS_WEDGE (8)
+#define PAN_BENT_ARMS_SINGLE_SERIF (10)
+#define PAN_BENT_ARMS_DOUBLE_SERIF (11)
+#define PAN_LETT_NORMAL_CONTACT (2)
+#define PAN_LETT_NORMAL_WEIGHTED (3)
+#define PAN_LETT_NORMAL_BOXED (4)
+#define PAN_LETT_NORMAL_FLATTENED (5)
+#define PAN_LETT_NORMAL_ROUNDED (6)
+#define PAN_LETT_NORMAL_OFF_CENTER (7)
+#define PAN_LETT_NORMAL_SQUARE (8)
+#define PAN_LETT_OBLIQUE_CONTACT (9)
+#define PAN_LETT_OBLIQUE_WEIGHTED (10)
+#define PAN_LETT_OBLIQUE_BOXED (11)
+#define PAN_LETT_OBLIQUE_FLATTENED (12)
+#define PAN_LETT_OBLIQUE_ROUNDED (13)
+#define PAN_LETT_OBLIQUE_OFF_CENTER (14)
+#define PAN_LETT_OBLIQUE_SQUARE (15)
+#define PAN_MIDLINE_STANDARD_TRIMMED (2)
+#define PAN_MIDLINE_STANDARD_POINTED (3)
+#define PAN_MIDLINE_STANDARD_SERIFED (4)
+#define PAN_MIDLINE_HIGH_TRIMMED (5)
+#define PAN_MIDLINE_HIGH_POINTED (6)
+#define PAN_MIDLINE_HIGH_SERIFED (7)
+#define PAN_MIDLINE_CONSTANT_TRIMMED (8)
+#define PAN_MIDLINE_CONSTANT_POINTED (9)
+#define PAN_MIDLINE_CONSTANT_SERIFED (10)
+#define PAN_MIDLINE_LOW_TRIMMED (11)
+#define PAN_MIDLINE_LOW_POINTED (12)
+#define PAN_MIDLINE_LOW_SERIFED (13)
+#define PAN_XHEIGHT_CONSTANT_SMALL (2)
+#define PAN_XHEIGHT_CONSTANT_STD (3)
+#define PAN_XHEIGHT_CONSTANT_LARGE (4)
+#define PAN_XHEIGHT_DUCKING_SMALL (5)
+#define PAN_XHEIGHT_DUCKING_STD (6)
+#define PAN_XHEIGHT_DUCKING_LARGE (7)
+
+/* PALETTENTRY structure */
+#define PC_EXPLICIT (2)
+#define PC_NOCOLLAPSE (4)
+#define PC_RESERVED (1)
+
+/* LOGBRUSH structure */
+#define BS_DIBPATTERN (5)
+#define BS_DIBPATTERN8X8 (8)
+#define BS_DIBPATTERNPT (6)
+#define BS_HATCHED (2)
+#define BS_HOLLOW (1)
+#define BS_NULL (1)
+#define BS_PATTERN (3)
+#define BS_PATTERN8X8 (7)
+#define BS_SOLID (0)
+
+/* DEVMODE structure */
+#define DM_ORIENTATION (0x1L)
+#define DM_PAPERSIZE (0x2L)
+#define DM_PAPERLENGTH (0x4L)
+#define DM_PAPERWIDTH (0x8L)
+#define DM_SCALE (0x10L)
+#define DM_COPIES (0x100L)
+#define DM_DEFAULTSOURCE (0x200L)
+#define DM_PRINTQUALITY (0x400L)
+#define DM_COLOR (0x800L)
+#define DM_DUPLEX (0x1000L)
+#define DM_YRESOLUTION (0x2000L)
+#define DM_TTOPTION (0x4000L)
+#define DM_COLLATE (0x8000L)
+#define DM_FORMNAME (0x10000L)
+#define DM_LOGPIXELS (0x20000L)
+#define DM_BITSPERPEL (0x40000L)
+#define DM_PELSWIDTH (0x80000L)
+#define DM_PELSHEIGHT (0x100000L)
+#define DM_DISPLAYFLAGS (0x200000L)
+#define DM_DISPLAYFREQUENCY (0x400000L)
+#define DM_ICMMETHOD (0x800000L)
+#define DM_ICMINTENT (0x1000000L)
+#define DM_MEDIATYPE (0x2000000L)
+#define DM_DITHERTYPE (0x4000000L)
+#define DMORIENT_LANDSCAPE (2)
+#define DMORIENT_PORTRAIT (1)
+#define DMPAPER_LETTER (1)
+#define DMPAPER_LEGAL (5)
+#define DMPAPER_A4 (9)
+#define DMPAPER_CSHEET (24)
+#define DMPAPER_DSHEET (25)
+#define DMPAPER_ESHEET (26)
+#define DMPAPER_LETTERSMALL (2)
+#define DMPAPER_TABLOID (3)
+#define DMPAPER_LEDGER (4)
+#define DMPAPER_STATEMENT (6)
+#define DMPAPER_EXECUTIVE (7)
+#define DMPAPER_A3 (8)
+#define DMPAPER_A4SMALL (10)
+#define DMPAPER_A5 (11)
+#define DMPAPER_B4 (12)
+#define DMPAPER_B5 (13)
+#define DMPAPER_FOLIO (14)
+#define DMPAPER_QUARTO (15)
+#define DMPAPER_10X14 (16)
+#define DMPAPER_11X17 (17)
+#define DMPAPER_NOTE (18)
+#define DMPAPER_ENV_9 (19)
+#define DMPAPER_ENV_10 (20)
+#define DMPAPER_ENV_11 (21)
+#define DMPAPER_ENV_12 (22)
+#define DMPAPER_ENV_14 (23)
+#define DMPAPER_ENV_DL (27)
+#define DMPAPER_ENV_C5 (28)
+#define DMPAPER_ENV_C3 (29)
+#define DMPAPER_ENV_C4 (30)
+#define DMPAPER_ENV_C6 (31)
+#define DMPAPER_ENV_C65 (32)
+#define DMPAPER_ENV_B4 (33)
+#define DMPAPER_ENV_B5 (34)
+#define DMPAPER_ENV_B6 (35)
+#define DMPAPER_ENV_ITALY (36)
+#define DMPAPER_ENV_MONARCH (37)
+#define DMPAPER_ENV_PERSONAL (38)
+#define DMPAPER_FANFOLD_US (39)
+#define DMPAPER_FANFOLD_STD_GERMAN (40)
+#define DMPAPER_FANFOLD_LGL_GERMAN (41)
+#define DMRES_HIGH (-4)
+#define DMRES_MEDIUM (-3)
+#define DMRES_LOW (-2)
+#define DMRES_DRAFT (-1)
+#define DMCOLOR_COLOR (2)
+#define DMCOLOR_MONOCHROME (1)
+#define DMDUP_SIMPLEX (1)
+#define DMDUP_HORIZONTAL (3)
+#define DMDUP_VERTICAL (2)
+#define DMTT_BITMAP (1)
+#define DMTT_DOWNLOAD (2)
+#define DMTT_SUBDEV (3)
+#define DMCOLLATE_TRUE (1)
+#define DMCOLLATE_FALSE (0)
+#define DM_GRAYSCALE (1)
+#define DM_INTERLACED (2)
+#define DMICMMETHOD_NONE (1)
+#define DMICMMETHOD_SYSTEM (2)
+#define DMICMMETHOD_DRIVER (3)
+#define DMICMMETHOD_DEVICE (4)
+#define DMICMMETHOD_USER (256)
+#define DMICM_SATURATE (1)
+#define DMICM_CONTRAST (2)
+#define DMICM_COLORMETRIC (3)
+#define DMICM_USER (256)
+#define DMMEDIA_STANDARD (1)
+#define DMMEDIA_GLOSSY (3)
+#define DMMEDIA_TRANSPARENCY (2)
+#define DMMEDIA_USER (256)
+#define DMDITHER_NONE (1)
+#define DMDITHER_COARSE (2)
+#define DMDITHER_FINE (3)
+#define DMDITHER_LINEART (4)
+#define DMDITHER_GRAYSCALE (10)
+#define DMDITHER_USER (256)
+
+/* RGNDATAHEADER structure */
+#define RDH_RECTANGLES (1)
+
+/* TTPOLYGONHEADER structure */
+#define TT_POLYGON_TYPE (24)
+
+/* TTPOLYCURVE structure */
+#define TT_PRIM_LINE (1)
+#define TT_PRIM_QSPLINE (2)
+
+/* GCP_RESULTS structure */
+#define GCPCLASS_ARABIC (2)
+#define GCPCLASS_HEBREW (2)
+#define GCPCLASS_LATIN (1)
+#define GCPCLASS_LATINNUMBER (5)
+#define GCPCLASS_LOCALNUMBER (4)
+#define GCPCLASS_LATINNUMERICSEPARATOR (7)
+#define GCPCLASS_LATINNUMERICTERMINATOR (6)
+#define GCPCLASS_NEUTRAL (3)
+#define GCPCLASS_NUMERICSEPARATOR (8)
+#define GCPCLASS_PREBOUNDLTR (128)
+#define GCPCLASS_PREBOUNDRTL (64)
+#define GCPCLASS_POSTBOUNDLTR (32)
+#define GCPCLASS_POSTBOUNDRTL (16)
+#define GCPGLYPH_LINKBEFORE (32768)
+#define GCPGLYPH_LINKAFTER (16384)
+
+/* RASTERIZER_STATUS structure */
+#define TT_AVAILABLE (1)
+#define TT_ENABLED (2)
+
+/* COLORADJUSTMENT structure */
+#define CA_NEGATIVE (1)
+#define CA_LOG_FILTER (2)
+#define ILLUMINANT_DEVICE_DEFAULT (0)
+#define ILLUMINANT_A (1)
+#define ILLUMINANT_B (2)
+#define ILLUMINANT_C (3)
+#define ILLUMINANT_D50 (4)
+#define ILLUMINANT_D55 (5)
+#define ILLUMINANT_D65 (6)
+#define ILLUMINANT_D75 (7)
+#define ILLUMINANT_F2 (8)
+#define ILLUMINANT_TUNGSTEN (1)
+#define ILLUMINANT_DAYLIGHT (3)
+#define ILLUMINANT_FLUORESCENT (8)
+#define ILLUMINANT_NTSC (3)
+
+/* DOCINFO structure */
+#define DI_APPBANDING (1)
+
+/* EMRMETAHEADER structure */
+#define EMR_HEADER (1)
+#define ENHMETA_SIGNATURE (1179469088)
+
+/* RTF event masks */
+#define ENM_CHANGE (1)
+#define ENM_CORRECTTEXT (4194304)
+#define ENM_DROPFILES (1048576)
+#define ENM_KEYEVENTS (65536)
+#define ENM_MOUSEEVENTS (131072)
+#define ENM_PROTECTED (2097152)
+#define ENM_REQUESTRESIZE (262144)
+#define ENM_SCROLL (4)
+#define ENM_SELCHANGE (524288)
+#define ENM_UPDATE (2)
+#define ENM_NONE (0)
+
+/* RTF styles */
+#define ES_DISABLENOSCROLL (8192)
+#define ES_EX_NOCALLOLEINIT (16777216)
+#define ES_NOIME (524288)
+#define ES_SAVESEL (32768)
+#define ES_SELFIME (262144)
+#define ES_SUNKEN (16384)
+#define ES_VERTICAL (4194304)
+#define ES_SELECTIONBAR (16777216)
+
+/* EM_SETOPTIONS message */
+#define ECOOP_SET (1)
+#define ECOOP_OR (2)
+#define ECOOP_AND (3)
+#define ECOOP_XOR (4)
+#define ECO_AUTOWORDSELECTION (1)
+#define ECO_AUTOVSCROLL (64)
+#define ECO_AUTOHSCROLL (128)
+#define ECO_NOHIDESEL (256)
+#define ECO_READONLY (2048)
+#define ECO_WANTRETURN (4096)
+#define ECO_SAVESEL (32768)
+#define ECO_SELECTIONBAR (16777216)
+#define ECO_VERTICAL (4194304)
+
+/* EM_SETCHARFORMAT message */
+#define SCF_WORD (2)
+#define SCF_SELECTION (1)
+
+/* EM_STREAMOUT message */
+#define SF_TEXT (1)
+#define SF_RTF (2)
+#define SF_RTFNOOBJS (3)
+#define SF_TEXTIZED (4)
+#define SFF_SELECTION (32768)
+#define SFF_PLAINRTF (16384)
+
+/* EM_FINDWORDBREAK message */
+#define WB_CLASSIFY (3)
+#define WB_ISDELIMITER (2)
+#define WB_LEFT (0)
+#define WB_LEFTBREAK (6)
+#define WB_PREVBREAK (6)
+#define WB_MOVEWORDLEFT (4)
+#define WB_MOVEWORDPREV (4)
+#define WB_MOVEWORDRIGHT (5)
+#define WB_MOVEWORDNEXT (5)
+#define WB_RIGHT (1)
+#define WB_RIGHTBREAK (7)
+#define WB_NEXTBREAK (7)
+
+/* EM_GETPUNCTUATION message */
+#define PC_LEADING (2)
+#define PC_FOLLOWING (1)
+#define PC_DELIMITER (4)
+#define PC_OVERFLOW (3)
+
+/* EM_SETWORDWRAPMODE message */
+#define WBF_WORDWRAP (16)
+#define WBF_WORDBREAK (32)
+#define WBF_OVERFLOW (64)
+#define WBF_LEVEL1 (128)
+#define WBF_LEVEL2 (256)
+#define WBF_CUSTOM (512)
+#define WBF_BREAKAFTER (64)
+#define WBF_BREAKLINE (32)
+#define WBF_ISWHITE (16)
+
+/* CHARFORMAT structure */
+#define CFM_BOLD (1)
+#define CFM_COLOR (1073741824)
+#define CFM_FACE (536870912)
+#define CFM_ITALIC (2)
+#define CFM_OFFSET (268435456)
+#define CFM_PROTECTED (16)
+#define CFM_SIZE (0x80000000)
+#define CFM_STRIKEOUT (8)
+#define CFM_UNDERLINE (4)
+#define CFE_AUTOCOLOR (1073741824)
+#define CFE_BOLD (1)
+#define CFE_ITALIC (2)
+#define CFE_STRIKEOUT (8)
+#define CFE_UNDERLINE (4)
+#define CFE_PROTECTED (16)
+
+/* PARAFORMAT structure */
+#define PFM_ALIGNMENT (8)
+#define PFM_NUMBERING (32)
+#define PFM_OFFSET (4)
+#define PFM_OFFSETINDENT (0x80000000)
+#define PFM_RIGHTINDENT (2)
+#define PFM_STARTINDENT (1)
+#define PFM_TABSTOPS (16)
+#define PFN_BULLET (1)
+#define PFA_LEFT (1)
+#define PFA_RIGHT (2)
+#define PFA_CENTER (3)
+
+/* SELCHANGE structure */
+#define SEL_EMPTY (0)
+#define SEL_TEXT (1)
+#define SEL_OBJECT (2)
+#define SEL_MULTICHAR (4)
+#define SEL_MULTIOBJECT (8)
+
+/* RTF clipboard formats */
+#define CF_RTF "Rich Text Format"
+#define CF_RETEXTOBJ "RichEdit Text and Objects"
+
+/* DRAWITEMSTRUCT structure */
+#define ODT_BUTTON (4)
+#define ODT_COMBOBOX (3)
+#define ODT_LISTBOX (2)
+#define ODT_LISTVIEW (102)
+#define ODT_MENU (1)
+#define ODT_STATIC (5)
+#define ODT_TAB (101)
+#define ODT_HEADER (100)
+#define ODA_DRAWENTIRE (1)
+#define ODA_FOCUS (4)
+#define ODA_SELECT (2)
+#define ODS_CHECKED (8)
+#define ODS_COMBOBOXEDIT (4096)
+#define ODS_DEFAULT (32)
+#define ODS_DISABLED (4)
+#define ODS_FOCUS (16)
+#define ODS_GRAYED (2)
+#define ODS_SELECTED (1)
+
+/* Common control window classes */
+#define ANIMATE_CLASSW L"SysAnimate32"
+#define HOTKEY_CLASSW L"msctls_hotkey32"
+#define PROGRESS_CLASSW L"msctls_progress32"
+#define STATUSCLASSNAMEW L"msctls_statusbar32"
+#define TOOLBARCLASSNAMEW L"ToolbarWindow32"
+#define TOOLTIPS_CLASSW L"tooltips_class32"
+#define TRACKBAR_CLASSW L"msctls_trackbar32"
+#define UPDOWN_CLASSW L"msctls_updown32"
+#define WC_HEADERW L"SysHeader32"
+#define WC_LISTVIEWW L"SysListView32"
+#define WC_TABCONTROLW L"SysTabControl32"
+#define WC_TREEVIEWW L"SysTreeView32"
+
+/* Common control styles */
+#define CCS_ADJUSTABLE (0x20L)
+#define CCS_BOTTOM (0x3L)
+#define CCS_NODIVIDER (0x40L)
+#define CCS_NOMOVEY (0x2L)
+#define CCS_NOPARENTALIGN (0x8L)
+#define CCS_NORESIZE (0x4L)
+#define CCS_TOP (0x1L)
+#define ANIMATE_CLASSA "SysAnimate32"
+#define HOTKEY_CLASSA "msctls_hotkey32"
+#define PROGRESS_CLASSA "msctls_progress32"
+#define STATUSCLASSNAMEA "msctls_statusbar32"
+#define TOOLBARCLASSNAMEA "ToolbarWindow32"
+#define TOOLTIPS_CLASSA "tooltips_class32"
+#define TRACKBAR_CLASSA "msctls_trackbar32"
+#define UPDOWN_CLASSA "msctls_updown32"
+#define WC_HEADERA "SysHeader32"
+#define WC_LISTVIEWA "SysListView32"
+#define WC_TABCONTROLA "SysTabControl32"
+#define WC_TREEVIEWA "SysTreeView32"
+#ifdef UNICODE
+#define ANIMATE_CLASS ANIMATE_CLASSW
+#define HOTKEY_CLASS HOTKEY_CLASSW
+#define PROGRESS_CLASS PROGRESS_CLASSW
+#define STATUSCLASSNAME STATUSCLASSNAMEW
+#define TOOLBARCLASSNAME TOOLBARCLASSNAMEW
+#define TOOLTIPS_CLASS TOOLTIPS_CLASSW
+#define TRACKBAR_CLASS TRACKBAR_CLASSW
+#define UPDOWN_CLASS UPDOWN_CLASSW
+#define WC_HEADER WC_HEADERW
+#define WC_LISTVIEW WC_LISTVIEWW
+#define WC_TABCONTROL WC_TABCONTROLW
+#define WC_TREEVIEW WC_TREEVIEWW
+#else
+#define ANIMATE_CLASS ANIMATE_CLASSA
+#define HOTKEY_CLASS HOTKEY_CLASSA
+#define PROGRESS_CLASS PROGRESS_CLASSA
+#define STATUSCLASSNAME STATUSCLASSNAMEA
+#define TOOLBARCLASSNAME TOOLBARCLASSNAMEA
+#define TOOLTIPS_CLASS TOOLTIPS_CLASSA
+#define TRACKBAR_CLASS TRACKBAR_CLASSA
+#define UPDOWN_CLASS UPDOWN_CLASSA
+#define WC_HEADER WC_HEADERA
+#define WC_LISTVIEW WC_LISTVIEWA
+#define WC_TABCONTROL WC_TABCONTROLA
+#define WC_TREEVIEW WC_TREEVIEWA
+#endif /* UNICODE */
+
+/* Header control styles */
+#define HDS_BUTTONS (2)
+#define HDS_HIDDEN (8)
+#define HDS_HORZ (0)
+
+/* HD_ITEM structure */
+#define HDI_BITMAP (16)
+#define HDI_FORMAT (4)
+#define HDI_HEIGHT (1)
+#define HDI_LPARAM (8)
+#define HDI_TEXT (2)
+#define HDI_WIDTH (1)
+#define HDF_CENTER (2)
+#define HDF_LEFT (0)
+#define HDF_RIGHT (1)
+#define HDF_RTLREADING (4)
+#define HDF_BITMAP (8192)
+#define HDF_OWNERDRAW (32768)
+#define HDF_STRING (16384)
+#define HDF_JUSTIFYMASK (3)
+
+/* HD_HITTESTINFO structure */
+#define HHT_NOWHERE (1)
+#define HHT_ONDIVIDER (4)
+#define HHT_ONDIVOPEN (8)
+#define HHT_ONHEADER (2)
+#define HHT_TOLEFT (2048)
+#define HHT_TORIGHT (1024)
+
+/* TBADDBITMAP structure */
+#define HINST_COMMCTRL ((HINSTANCE)-1)
+#define IDB_STD_LARGE_COLOR (1)
+#define IDB_STD_SMALL_COLOR (0)
+#define IDB_VIEW_LARGE_COLOR (5)
+#define IDB_VIEW_SMALL_COLOR (4)
+#define STD_COPY (1)
+#define STD_CUT (0)
+#define STD_DELETE (5)
+#define STD_FILENEW (6)
+#define STD_FILEOPEN (7)
+#define STD_FILESAVE (8)
+#define STD_FIND (12)
+#define STD_HELP (11)
+#define STD_PASTE (2)
+#define STD_PRINT (14)
+#define STD_PRINTPRE (9)
+#define STD_PROPERTIES (10)
+#define STD_REDOW (4)
+#define STD_REPLACE (13)
+#define STD_UNDO (3)
+#define VIEW_LARGEICONS (0)
+#define VIEW_SMALLICONS (1)
+#define VIEW_LIST (2)
+#define VIEW_DETAILS (3)
+#define VIEW_SORTNAME (4)
+#define VIEW_SORTSIZE (5)
+#define VIEW_SORTDATE (6)
+#define VIEW_SORTTYPE (7)
+
+/* Toolbar styles */
+#define TBSTYLE_ALTDRAG (1024)
+#define TBSTYLE_TOOLTIPS (256)
+#define TBSTYLE_WRAPABLE (512)
+#define TBSTYLE_BUTTON (0)
+#define TBSTYLE_CHECK (2)
+#define TBSTYLE_CHECKGROUP (6)
+#define TBSTYLE_GROUP (4)
+#define TBSTYLE_SEP (1)
+
+/* Toolbar states */
+#define TBSTATE_CHECKED (1)
+#define TBSTATE_ENABLED (4)
+#define TBSTATE_HIDDEN (8)
+#define TBSTATE_INDETERMINATE (16)
+#define TBSTATE_PRESSED (2)
+#define TBSTATE_WRAP (32)
+
+/* Tooltip styles */
+#define TTS_ALWAYSTIP (1)
+#define TTS_NOPREFIX (2)
+
+/* TOOLINFO structure */
+#define TTF_IDISHWND (1)
+#define TTF_CENTERTIP (2)
+#define TTF_RTLREADING (4)
+#define TTF_SUBCLASS (16)
+
+/* TTM_SETDELAYTIME message */
+#define TTDT_AUTOMATIC (0)
+#define TTDT_AUTOPOP (2)
+#define TTDT_INITIAL (3)
+#define TTDT_RESHOW (1)
+
+/* Status window */
+#define SBARS_SIZEGRIP (256)
+#define SBARS_SIZEGRIP (256)
+
+/* DL_DRAGGING message */
+#define DL_MOVECURSOR (3)
+#define DL_COPYCURSOR (2)
+#define DL_STOPCURSOR (1)
+
+/* Up-down control styles */
+#define UDS_ALIGNLEFT (8)
+#define UDS_ALIGNRIGHT (4)
+#define UDS_ARROWKEYS (32)
+#define UDS_AUTOBUDDY (16)
+#define UDS_HORZ (64)
+#define UDS_NOTHOUSANDS (128)
+#define UDS_SETBUDDYINT (2)
+#define UDS_WRAP (1)
+
+/* UDM_SETRANGE message */
+#define UD_MAXVAL (32767)
+#define UD_MINVAL (-32767)
+
+/* HKM_GETHOTKEY message */
+#define HOTKEYF_ALT (4)
+#define HOTKEYF_CONTROL (2)
+#define HOTKEYF_EXT (8)
+#define HOTKEYF_SHIFT (1)
+
+/* HKM_SETRULES message */
+#define HKCOMB_A (8)
+#define HKCOMB_C (4)
+#define HKCOMB_CA (64)
+#define HKCOMB_NONE (1)
+#define HKCOMB_S (2)
+#define HKCOMB_SA (32)
+#define HKCOMB_SC (16)
+#define HKCOMB_SCA (128)
+
+/* Trackbar styles */
+#define TBS_HORZ (0)
+#define TBS_VERT (2)
+#define TBS_AUTOTICKS (1)
+#define TBS_NOTICKS (16)
+#define TBS_TOP (4)
+#define TBS_BOTTOM (0)
+#define TBS_LEFT (4)
+#define TBS_RIGHT (0)
+#define TBS_BOTH (8)
+#define TBS_ENABLESELRANGE (32)
+#define TBS_FIXEDLENGTH (64)
+#define TBS_NOTHUMB (128)
+#define TB_BOTTOM (7)
+#define TB_ENDTRACK (8)
+#define TB_LINEDOWN (1)
+#define TB_LINEUP (0)
+#define TB_PAGEDOWN (3)
+#define TB_PAGEUP (2)
+#define TB_THUMBPOSITION (4)
+#define TB_THUMBTRACK (5)
+#define TB_TOP (6)
+
+/* List view styles */
+#define LVS_ALIGNLEFT (2048)
+#define LVS_ALIGNTOP (0)
+#define LVS_AUTOARRANGE (256)
+#define LVS_EDITLABELS (512)
+#define LVS_ICON (0)
+#define LVS_LIST (3)
+#define LVS_NOCOLUMNHEADER (16384)
+#define LVS_NOLABELWRAP (128)
+#define LVS_NOSCROLL (8192)
+#define LVS_NOSORTHEADER (32768)
+#define LVS_OWNERDRAWFIXED (1024)
+#define LVS_REPORT (1)
+#define LVS_SHAREIMAGELISTS (64)
+#define LVS_SHOWSELALWAYS (8)
+#define LVS_SINGLESEL (4)
+#define LVS_SMALLICON (2)
+#define LVS_SORTASCENDING (16)
+#define LVS_SORTDESCENDING (32)
+#define LVS_TYPESTYLEMASK (64512)
+#define LVSIL_NORMAL (0)
+#define LVSIL_SMALL (1)
+#define LVSIL_STATE (2)
+#define LVIS_CUT (4)
+#define LVIS_DROPHILITED (8)
+#define LVIS_FOCUSED (1)
+#define LVIS_SELECTED (2)
+#define LVIS_OVERLAYMASK (3840)
+#define LVIS_STATEIMAGEMASK (61440)
+#define LPSTR_TEXTCALLBACKW ((LPWSTR)-1L)
+#define LPSTR_TEXTCALLBACKA ((LPSTR)-1L)
+#ifdef UNICODE
+#define LPSTR_TEXTCALLBACK LPSTR_TEXTCALLBACKW
+#else
+#define LPSTR_TEXTCALLBACK LPSTR_TEXTCALLBACKA
+#endif /* UNICODE */
+
+/* LV_ITEM structure */
+#define LVIF_TEXT (1)
+#define LVIF_IMAGE (2)
+#define LVIF_PARAM (4)
+#define LVIF_STATE (8)
+#define LVIF_DI_SETITEM (4096)
+
+/* LVM_GETNEXTITEM structure */
+#define LVNI_ABOVE (256)
+#define LVNI_ALL (0)
+#define LVNI_BELOW (512)
+#define LVNI_TOLEFT (1024)
+#define LVNI_TORIGHT (2048)
+#define LVNI_CUT (4)
+#define LVNI_DROPHILITED (8)
+#define LVNI_FOCUSED (1)
+#define LVNI_SELECTED (2)
+
+/* LV_FINDINFO structure */
+#define LVFI_PARAM (1)
+#define LVFI_PARTIAL (8)
+#define LVFI_STRING (2)
+#define LVFI_WRAP (32)
+#define LVFI_NEARESTXY (64)
+
+/* LV_HITTESTINFO structure */
+#define LVHT_ABOVE (8)
+#define LVHT_BELOW (16)
+#define LVHT_NOWHERE (1)
+#define LVHT_ONITEMICON (2)
+#define LVHT_ONITEMLABEL (4)
+#define LVHT_ONITEMSTATEICON (8)
+#define LVHT_TOLEFT (64)
+#define LVHT_TORIGHT (32)
+
+/* LV_COLUMN structure */
+#define LVCF_FMT (1)
+#define LVCF_SUBITEM (8)
+#define LVCF_TEXT (4)
+#define LVCF_WIDTH (2)
+#define LVCFMT_CENTER (2)
+#define LVCFMT_LEFT (0)
+#define LVCFMT_RIGHT (1)
+
+/* ListView_GetItemRect */
+#define LVIR_BOUNDS (0)
+#define LVIR_ICON (1)
+#define LVIR_LABEL (2)
+#define LVIR_SELECTBOUNDS (3)
+
+/* LVM_ARRANGE message */
+#define LVA_ALIGNLEFT (1)
+#define LVA_ALIGNTOP (2)
+#define LVA_DEFAULT (0)
+#define LVA_SNAPTOGRID (5)
+
+/* LVM_SETCOLUMNWIDTH message */
+#define LVSCW_AUTOSIZE (-1)
+#define LVSCW_AUTOSIZE_USEHEADER (-2)
+
+/* Tree View styles */
+#define TVS_DISABLEDRAGDROP (16)
+#define TVS_EDITLABELS (8)
+#define TVS_HASBUTTONS (1)
+#define TVS_HASLINES (2)
+#define TVS_LINESATROOT (4)
+#define TVS_SHOWSELALWAYS (32)
+
+/* Tree View states */
+#define TVIS_BOLD (16)
+#define TVIS_CUT (4)
+#define TVIS_DROPHILITED (8)
+#define TVIS_EXPANDED (32)
+#define TVIS_EXPANDEDONCE (64)
+#define TVIS_FOCUSED (1)
+#define TVIS_OVERLAYMASK (3840)
+#define TVIS_SELECTED (2)
+#define TVIS_STATEIMAGEMASK (61440)
+#define TVIS_USERMASK (61440)
+
+/* TV_ITEM structure */
+#define TVIF_CHILDREN (64)
+#define TVIF_HANDLE (16)
+#define TVIF_IMAGE (2)
+#define TVIF_PARAM (4)
+#define TVIF_SELECTEDIMAGE (32)
+#define TVIF_STATE (8)
+#define TVIF_TEXT (1)
+#define I_CHILDRENCALLBACK (-1)
+#define I_IMAGECALLBACK (-1)
+
+/* TV_INSERTSTRUCT structure */
+#define TVI_ROOT ((HTREEITEM)0xFFFF0000)
+#define TVI_FIRST ((HTREEITEM)0xFFFF0001)
+#define TVI_LAST ((HTREEITEM)0xFFFF0002)
+#define TVI_SORT ((HTREEITEM)0xFFFF0003)
+
+/* TV_HITTESTINFO structure */
+#define TVHT_ABOVE (256)
+#define TVHT_BELOW (512)
+#define TVHT_NOWHERE (1)
+#define TVHT_ONITEM (70)
+#define TVHT_ONITEMBUTTON (16)
+#define TVHT_ONITEMICON (2)
+#define TVHT_ONITEMINDENT (8)
+#define TVHT_ONITEMLABEL (4)
+#define TVHT_ONITEMRIGHT (32)
+#define TVHT_ONITEMSTATEICON (64)
+#define TVHT_TOLEFT (2048)
+#define TVHT_TORIGHT (1024)
+
+/* TVM_EXPAND message */
+#define TVE_COLLAPSE (1)
+#define TVE_COLLAPSERESET (32768)
+#define TVE_EXPAND (2)
+#define TVE_TOGGLE (3)
+
+/* TVM_GETIMAGELIST message */
+#define TVSIL_NORMAL (0)
+#define TVSIL_STATE (2)
+
+/* TVM_GETNEXTITEM message */
+#define TVGN_CARET (9)
+#define TVGN_CHILD (4)
+#define TVGN_DROPHILITE (8)
+#define TVGN_FIRSTVISIBLE (5)
+#define TVGN_NEXT (1)
+#define TVGN_NEXTVISIBLE (6)
+#define TVGN_PARENT (3)
+#define TVGN_PREVIOUS (2)
+#define TVGN_PREVIOUSVISIBLE (7)
+#define TVGN_ROOT (0)
+
+/* TVN_SELCHANGED message */
+#define TVC_BYKEYBOARD (2)
+#define TVC_BYMOUSE (1)
+#define TVC_UNKNOWN (0)
+
+/* Tab control styles */
+#define TCS_BUTTONS (256)
+#define TCS_FIXEDWIDTH (1024)
+#define TCS_FOCUSNEVER (32768)
+#define TCS_FOCUSONBUTTONDOWN (4096)
+#define TCS_FORCEICONLEFT (16)
+#define TCS_FORCELABELLEFT (32)
+#define TCS_MULTILINE (512)
+#define TCS_OWNERDRAWFIXED (8192)
+#define TCS_RAGGEDRIGHT (2048)
+#define TCS_RIGHTJUSTIFY (0)
+#define TCS_SINGLELINE (0)
+#define TCS_TABS (0)
+#define TCS_TOOLTIPS (16384)
+
+/* TC_ITEM structure */
+#define TCIF_TEXT (1)
+#define TCIF_IMAGE (2)
+#define TCIF_PARAM (8)
+#define TCIF_RTLREADING (4)
+
+/* TC_HITTESTINFO structure */
+#define TCHT_NOWHERE (1)
+#define TCHT_ONITEM (6)
+#define TCHT_ONITEMICON (2)
+#define TCHT_ONITEMLABEL (4)
+
+/* Animation control styles */
+#define ACS_AUTOPLAY (4)
+#define ACS_CENTER (1)
+#define ACS_TRANSPARENT (2)
+
+/* MODEMDEVCAPS structure */
+#define DIALOPTION_BILLING (64)
+#define DIALOPTION_QUIET (128)
+#define DIALOPTION_DIALTONE (256)
+#define MDMVOLFLAG_LOW (1)
+#define MDMVOLFLAG_MEDIUM (2)
+#define MDMVOLFLAG_HIGH (4)
+#define MDMVOL_LOW (0)
+#define MDMVOL_MEDIUM (1)
+#define MDMVOL_HIGH (2)
+#define MDMSPKRFLAG_OFF (1)
+#define MDMSPKRFLAG_DIAL (2)
+#define MDMSPKRFLAG_ON (4)
+#define MDMSPKRFLAG_CALLSETUP (8)
+#define MDMSPKR_OFF (0)
+#define MDMSPKR_DIAL (1)
+#define MDMSPKR_ON (2)
+#define MDMSPKR_CALLSETUP (3)
+#define MDM_BLIND_DIAL (512)
+#define MDM_CCITT_OVERRIDE (64)
+#define MDM_CELLULAR (8)
+#define MDM_COMPRESSION (1)
+#define MDM_ERROR_CONTROL (2)
+#define MDM_FLOWCONTROL_HARD (16)
+#define MDM_FLOWCONTROL_SOFT (32)
+#define MDM_FORCED_EC (4)
+#define MDM_SPEED_ADJUST (128)
+#define MDM_TONE_DIAL (256)
+#define MDM_V23_OVERRIDE (1024)
+
+/* Languages */
+#define LANG_BULGARIAN (2)
+#define LANG_CHINESE (4)
+#define LANG_CROATIAN (26)
+#define LANG_CZECH (5)
+#define LANG_DANISH (6)
+#define LANG_DUTCH (19)
+#define LANG_ENGLISH (9)
+#define LANG_FINNISH (11)
+#define LANG_FRENCH (12)
+#define LANG_GERMAN (7)
+#define LANG_GREEK (8)
+#define LANG_HUNGARIAN (14)
+#define LANG_ICELANDIC (15)
+#define LANG_ITALIAN (16)
+#define LANG_JAPANESE (17)
+#define LANG_KOREAN (18)
+#define LANG_NEUTRAL (0)
+#define LANG_NORWEGIAN (20)
+#define LANG_POLISH (21)
+#define LANG_PORTUGUESE (22)
+#define LANG_ROMANIAN (24)
+#define LANG_RUSSIAN (25)
+#define LANG_SLOVAK (27)
+#define LANG_SLOVENIAN (36)
+#define LANG_SPANISH (10)
+#define LANG_SWEDISH (29)
+#define LANG_TURKISH (31)
+#define SUBLANG_CHINESE_SIMPLIFIED (2)
+#define SUBLANG_CHINESE_TRADITIONAL (1)
+#define SUBLANG_CHINESE_HONGKONG (3)
+#define SUBLANG_CHINESE_SINGAPORE (4)
+#define SUBLANG_DEFAULT (1)
+#define SUBLANG_DUTCH (1)
+#define SUBLANG_DUTCH_BELGIAN (2)
+#define SUBLANG_ENGLISH_AUS (3)
+#define SUBLANG_ENGLISH_CAN (4)
+#define SUBLANG_ENGLISH_EIRE (6)
+#define SUBLANG_ENGLISH_NZ (5)
+#define SUBLANG_ENGLISH_UK (2)
+#define SUBLANG_ENGLISH_US (1)
+#define SUBLANG_FRENCH (1)
+#define SUBLANG_FRENCH_BELGIAN (2)
+#define SUBLANG_FRENCH_CANADIAN (3)
+#define SUBLANG_FRENCH_SWISS (4)
+#define SUBLANG_GERMAN (1)
+#define SUBLANG_GERMAN_AUSTRIAN (3)
+#define SUBLANG_GERMAN_SWISS (2)
+#define SUBLANG_ITALIAN (1)
+#define SUBLANG_ITALIAN_SWISS (2)
+#define SUBLANG_NEUTRAL (0)
+#define SUBLANG_NORWEGIAN_BOKMAL (1)
+#define SUBLANG_NORWEGIAN_NYNORSK (2)
+#define SUBLANG_PORTUGUESE (2)
+#define SUBLANG_PORTUGUESE_BRAZILIAN (1)
+#define SUBLANG_SPANISH (1)
+#define SUBLANG_SPANISH_MEXICAN (2)
+#define SUBLANG_SPANISH_MODERN (3)
+#define SUBLANG_SYS_DEFAULT (2)
+#define NLS_VALID_LOCALE_MASK (1048575)
+#define SORT_DEFAULT (0)
+#define SORT_JAPANESE_XJIS (0)
+#define SORT_JAPANESE_UNICODE (1)
+#define SORT_CHINESE_BIG5 (0)
+#define SORT_CHINESE_UNICODE (1)
+#define SORT_KOREAN_KSC (0)
+#define SORT_KOREAN_UNICODE (1)
+
+/* SYSTEM_INFO structure */
+#define PROCESSOR_INTEL_386 (386)
+#define PROCESSOR_INTEL_486 (486)
+#define PROCESSOR_INTEL_PENTIUM (586)
+#define PROCESSOR_MIPS_R4000 (4000)
+#define PROCESSOR_ALPHA_21064 (21064)
+
+/* FSCTL_SET_COMPRESSION */
+#define COMPRESSION_FORMAT_NONE (0)
+#define COMPRESSION_FORMAT_DEFAULT (1)
+#define COMPRESSION_FORMAT_LZNT1 (2)
+
+/* TAPE_GET_DRIVE_PARAMETERS structure */
+#define TAPE_DRIVE_COMPRESSION (131072)
+#define TAPE_DRIVE_ECC (65536)
+#define TAPE_DRIVE_ERASE_BOP_ONLY (64)
+#define TAPE_DRIVE_ERASE_LONG (32)
+#define TAPE_DRIVE_ERASE_IMMEDIATE (128)
+#define TAPE_DRIVE_ERASE_SHORT (16)
+#define TAPE_DRIVE_FIXED (1)
+#define TAPE_DRIVE_FIXED_BLOCK (1024)
+#define TAPE_DRIVE_INITIATOR (4)
+#define TAPE_DRIVE_PADDING (262144)
+#define TAPE_DRIVE_GET_ABSOLUTE_BLK (1048576)
+#define TAPE_DRIVE_GET_LOGICAL_BLK (2097152)
+#define TAPE_DRIVE_REPORT_SMKS (524288)
+#define TAPE_DRIVE_SELECT (2)
+#define TAPE_DRIVE_SET_EOT_WZ_SIZE (4194304)
+#define TAPE_DRIVE_TAPE_CAPACITY (256)
+#define TAPE_DRIVE_TAPE_REMAINING (512)
+#define TAPE_DRIVE_VARIABLE_BLOCK (2048)
+#define TAPE_DRIVE_WRITE_PROTECT (4096)
+#define TAPE_DRIVE_ABS_BLK_IMMED (-2147475456)
+#define TAPE_DRIVE_ABSOLUTE_BLK (-2147479552)
+#define TAPE_DRIVE_END_OF_DATA (-2147418112)
+#define TAPE_DRIVE_FILEMARKS (-2147221504)
+#define TAPE_DRIVE_LOAD_UNLOAD (-2147483647)
+#define TAPE_DRIVE_LOAD_UNLD_IMMED (-2147483616)
+#define TAPE_DRIVE_LOCK_UNLOCK (-2147483644)
+#define TAPE_DRIVE_LOCK_UNLK_IMMED (-2147483520)
+#define TAPE_DRIVE_LOG_BLK_IMMED (-2147450880)
+#define TAPE_DRIVE_LOGICAL_BLK (-2147467264)
+#define TAPE_DRIVE_RELATIVE_BLKS (-2147352576)
+#define TAPE_DRIVE_REVERSE_POSITION (-2143289344)
+#define TAPE_DRIVE_REWIND_IMMEDIATE (-2147483640)
+#define TAPE_DRIVE_SEQUENTIAL_FMKS (-2146959360)
+#define TAPE_DRIVE_SEQUENTIAL_SMKS (-2145386496)
+#define TAPE_DRIVE_SET_BLOCK_SIZE (-2147483632)
+#define TAPE_DRIVE_SET_COMPRESSION (-2147483136)
+#define TAPE_DRIVE_SET_ECC (-2147483392)
+#define TAPE_DRIVE_SET_PADDING (-2147482624)
+#define TAPE_DRIVE_SET_REPORT_SMKS (-2147481600)
+#define TAPE_DRIVE_SETMARKS (-2146435072)
+#define TAPE_DRIVE_SPACE_IMMEDIATE (-2139095040)
+#define TAPE_DRIVE_TENSION (-2147483646)
+#define TAPE_DRIVE_TENSION_IMMED (-2147483584)
+#define TAPE_DRIVE_WRITE_FILEMARKS (-2113929216)
+#define TAPE_DRIVE_WRITE_LONG_FMKS (-2013265920)
+#define TAPE_DRIVE_WRITE_MARK_IMMED (-1879048192)
+#define TAPE_DRIVE_WRITE_SETMARKS (-2130706432)
+#define TAPE_DRIVE_WRITE_SHORT_FMKS (-2080374784)
+
+/* Standard rights */
+#define STANDARD_RIGHTS_REQUIRED (0xf0000L)
+#define STANDARD_RIGHTS_WRITE (0x20000L)
+#define STANDARD_RIGHTS_READ (0x20000L)
+#define STANDARD_RIGHTS_EXECUTE (0x20000L)
+#define STANDARD_RIGHTS_ALL (0x1f0000L)
+#define SPECIFIC_RIGHTS_ALL (0xffffL)
+
+/* ACCESS_MASK */
+#define MAXIMUM_ALLOWED (0x2000000L)
+#define GENERIC_ALL (0x10000000L)
+
+/* SID */
+#define SECURITY_NULL_RID (0L)
+#define SECURITY_WORLD_RID (0L)
+#define SECURITY_LOCAL_RID (0L)
+#define SECURITY_CREATOR_OWNER_RID (0L)
+#define SECURITY_CREATOR_GROUP_RID (0x1L)
+#define SECURITY_DIALUP_RID (0x1L)
+#define SECURITY_NETWORK_RID (0x2L)
+#define SECURITY_BATCH_RID (0x3L)
+#define SECURITY_INTERACTIVE_RID (0x4L)
+#define SECURITY_LOGON_IDS_RID (0x5L)
+#define SECURITY_LOGON_IDS_RID_COUNT (0x3L)
+#define SECURITY_SERVICE_RID (0x6L)
+#define SECURITY_LOCAL_SYSTEM_RID (0x12L)
+#define SECURITY_BUILTIN_DOMAIN_RID (0x20L)
+#define DOMAIN_USER_RID_ADMIN (0x1f4L)
+#define DOMAIN_USER_RID_GUEST (0x1f5L)
+#define DOMAIN_GROUP_RID_ADMINS (0x200L)
+#define DOMAIN_GROUP_RID_USERS (0x201L)
+#define DOMAIN_ALIAS_RID_ADMINS (0x220L)
+#define DOMAIN_ALIAS_RID_USERS (0x221L)
+#define DOMAIN_ALIAS_RID_GUESTS (0x222L)
+#define DOMAIN_ALIAS_RID_POWER_USERS (0x223L)
+#define DOMAIN_ALIAS_RID_ACCOUNT_OPS (0x224L)
+#define DOMAIN_ALIAS_RID_SYSTEM_OPS (0x225L)
+#define DOMAIN_ALIAS_RID_PRINT_OPS (0x226L)
+#define DOMAIN_ALIAS_RID_BACKUP_OPS (0x227L)
+#define DOMAIN_ALIAS_RID_REPLICATOR (0x228L)
+
+/* TOKEN_GROUPS structure */
+#define SE_GROUP_MANDATORY (0x1L)
+#define SE_GROUP_ENABLED_BY_DEFAULT (0x2L)
+#define SE_GROUP_ENABLED (0x4L)
+#define SE_GROUP_OWNER (0x8L)
+#define SE_GROUP_LOGON_ID (0xc0000000L)
+
+/* ACL Defines */
+#define ACL_REVISION (2)
+
+/* ACE_HEADER structure */
+#define ACCESS_ALLOWED_ACE_TYPE (0x0)
+#define ACCESS_DENIED_ACE_TYPE (0x1)
+#define SYSTEM_AUDIT_ACE_TYPE (0x2)
+#define SYSTEM_ALARM_ACE_TYPE (0x3)
+
+/* ACE flags in the ACE_HEADER structure */
+#define OBJECT_INHERIT_ACE (0x1)
+#define CONTAINER_INHERIT_ACE (0x2)
+#define NO_PROPAGATE_INHERIT_ACE (0x4)
+#define INHERIT_ONLY_ACE (0x8)
+#define SUCCESSFUL_ACCESS_ACE_FLAG (0x40)
+#define FAILED_ACCESS_ACE_FLAG (0x80)
+
+/* SECURITY_DESCRIPTOR_CONTROL */
+#define SECURITY_DESCRIPTOR_REVISION (1)
+#define SECURITY_DESCRIPTOR_MIN_LENGTH (20)
+#define SE_OWNER_DEFAULTED (1)
+#define SE_GROUP_DEFAULTED (2)
+#define SE_DACL_PRESENT (4)
+#define SE_DACL_DEFAULTED (8)
+#define SE_SACL_PRESENT (16)
+#define SE_SACL_DEFAULTED (32)
+#define SE_SELF_RELATIVE (32768)
+
+/* PRIVILEGE_SET */
+#define SE_PRIVILEGE_ENABLED_BY_DEFAULT (0x1L)
+#define SE_PRIVILEGE_ENABLED (0x2L)
+#define SE_PRIVILEGE_USED_FOR_ACCESS (0x80000000L)
+#define PRIVILEGE_SET_ALL_NECESSARY (0x1)
+
+/* OPENFILENAME structure */
+#define OFN_ALLOWMULTISELECT (0x200)
+#define OFN_CREATEPROMPT (0x2000)
+#define OFN_ENABLEHOOK (0x20)
+#define OFN_ENABLETEMPLATE (0x40)
+#define OFN_ENABLETEMPLATEHANDLE (0x80)
+#define OFN_EXPLORER (0x80000)
+#define OFN_EXTENSIONDIFFERENT (0x400)
+#define OFN_FILEMUSTEXIST (0x1000)
+#define OFN_HIDEREADONLY (0x4)
+#define OFN_LONGNAMES (0x200000)
+#define OFN_NOCHANGEDIR (0x8)
+#define OFN_NODEREFERENCELINKS (0x100000)
+#define OFN_NOLONGNAMES (0x40000)
+#define OFN_NONETWORKBUTTON (0x20000)
+#define OFN_NOREADONLYRETURN (0x8000)
+#define OFN_NOTESTFILECREATE (0x10000)
+#define OFN_NOVALIDATE (0x100)
+#define OFN_OVERWRITEPROMPT (0x2)
+#define OFN_PATHMUSTEXIST (0x800)
+#define OFN_READONLY (0x1)
+#define OFN_SHAREAWARE (0x4000)
+#define OFN_SHOWHELP (0x10)
+
+/* SHAREVISTRING message */
+#define OFN_SHAREFALLTHROUGH (0x2)
+#define OFN_SHARENOWARN (0x1)
+#define OFN_SHAREWARN (0)
+
+/* Open/Save notifications */
+#define CDN_INITDONE (0xfffffda7)
+#define CDN_SELCHANGE (0xfffffda6)
+#define CDN_FOLDERCHANGE (0xfffffda5)
+#define CDN_SHAREVIOLATION (0xfffffda4)
+#define CDN_HELP (0xfffffda3)
+#define CDN_FILEOK (0xfffffda2)
+#define CDN_TYPECHANGE (0xfffffda1)
+
+/* Open/Save messages */
+#define CDM_GETFILEPATH (0x465)
+#define CDM_GETFOLDERIDLIST (0x467)
+#define CDM_GETFOLDERPATH (0x466)
+#define CDM_GETSPEC (0x464)
+#define CDM_HIDECONTROL (0x469)
+#define CDM_SETCONTROLTEXT (0x468)
+#define CDM_SETDEFEXT (0x46a)
+
+/* CHOOSECOLOR structure */
+#define CC_ENABLEHOOK (0x10)
+#define CC_ENABLETEMPLATE (0x20)
+#define CC_ENABLETEMPLATEHANDLE (0x40)
+#define CC_FULLOPEN (0x2)
+#define CC_PREVENTFULLOPEN (0x4)
+#define CC_RGBINIT (0x1)
+#define CC_SHOWHELP (0x8)
+#define CC_SOLIDCOLOR (0x80)
+
+/* FINDREPLACE structure */
+#define FR_DIALOGTERM (0x40)
+#define FR_DOWN (0x1)
+#define FR_ENABLEHOOK (0x100)
+#define FR_ENABLETEMPLATE (0x200)
+#define FR_ENABLETEMPLATEHANDLE (0x2000)
+#define FR_FINDNEXT (0x8)
+#define FR_HIDEUPDOWN (0x4000)
+#define FR_HIDEMATCHCASE (0x8000)
+#define FR_HIDEWHOLEWORD (0x10000)
+#define FR_MATCHCASE (0x4)
+#define FR_NOMATCHCASE (0x800)
+#define FR_NOUPDOWN (0x400)
+#define FR_NOWHOLEWORD (0x1000)
+#define FR_REPLACE (0x10)
+#define FR_REPLACEALL (0x20)
+#define FR_SHOWHELP (0x80)
+#define FR_WHOLEWORD (0x2)
+
+/* CHOOSEFONT structure */
+#define CF_APPLY (0x200L)
+#define CF_ANSIONLY (0x400L)
+#define CF_BOTH (0x3)
+#define CF_TTONLY (0x40000L)
+#define CF_EFFECTS (0x100L)
+#define CF_ENABLEHOOK (0x8L)
+#define CF_ENABLETEMPLATE (0x10L)
+#define CF_ENABLETEMPLATEHANDLE (0x20L)
+#define CF_FIXEDPITCHONLY (0x4000L)
+#define CF_FORCEFONTEXIST (0x10000L)
+#define CF_INITTOLOGFONTSTRUCT (0x40L)
+#define CF_LIMITSIZE (0x2000L)
+#define CF_NOOEMFONTS (0x800L)
+#define CF_NOFACESEL (0x80000L)
+#define CF_NOSCRIPTSEL (0x800000L)
+#define CF_NOSTYLESEL (0x100000L)
+#define CF_NOSIZESEL (0x200000L)
+#define CF_NOSIMULATIONS (0x1000L)
+#define CF_NOVECTORFONTS (0x800L)
+#define CF_NOVERTFONTS (0x1000000L)
+#define CF_PRINTERFONTS (0x2)
+#define CF_SCALABLEONLY (0x20000L)
+#define CF_SCREENFONTS (0x1)
+#define CF_SCRIPTSONLY (0x400L)
+#define CF_SELECTSCRIPT (0x400000L)
+#define CF_SHOWHELP (0x4L)
+#define CF_USESTYLE (0x80L)
+#define CF_WYSIWYG (0x8000L)
+#define BOLD_FONTTYPE (0x100)
+#define ITALIC_FONTTYPE (0x200)
+#define PRINTER_FONTTYPE (0x4000)
+#define REGULAR_FONTTYPE (0x400)
+#define SCREEN_FONTTYPE (0x2000)
+#define SIMULATED_FONTTYPE (0x8000)
+
+/* Common dialog messages */
+#define COLOROKSTRINGW L"commdlg_ColorOK"
+#define FILEOKSTRINGW L"commdlg_FileNameOK"
+#define FINDMSGSTRINGW L"commdlg_FindReplace"
+#define HELPMSGSTRINGW L"commdlg_help"
+#define LBSELCHSTRINGW L"commdlg_LBSelChangedNotify"
+#define SETRGBSTRINGW L"commdlg_SetRGBColor"
+#define SHAREVISTRINGW L"commdlg_ShareViolation"
+#define COLOROKSTRINGA "commdlg_ColorOK"
+#define FILEOKSTRINGA "commdlg_FileNameOK"
+#define FINDMSGSTRINGA "commdlg_FindReplace"
+#define HELPMSGSTRINGA "commdlg_help"
+#define LBSELCHSTRINGA "commdlg_LBSelChangedNotify"
+#define SETRGBSTRINGA "commdlg_SetRGBColor"
+#define SHAREVISTRINGA "commdlg_ShareViolation"
+#ifdef UNICODE
+#define COLOROKSTRING COLOROKSTRINGW
+#define FILEOKSTRING FILEOKSTRINGW
+#define FINDMSGSTRING FINDMSGSTRINGW
+#define HELPMSGSTRING HELPMSGSTRINGW
+#define LBSELCHSTRING LBSELCHSTRINGW
+#define SETRGBSTRING SETRGBSTRINGW
+#define SHAREVISTRING SHAREVISTRINGW
+#else
+#define COLOROKSTRING COLOROKSTRINGA
+#define FILEOKSTRING FILEOKSTRINGA
+#define FINDMSGSTRING FINDMSGSTRINGA
+#define HELPMSGSTRING HELPMSGSTRINGA
+#define LBSELCHSTRING LBSELCHSTRINGA
+#define SETRGBSTRING SETRGBSTRINGA
+#define SHAREVISTRING SHAREVISTRINGA
+#endif
+
+/* LBSELCHSTRING message */
+#define CD_LBSELCHANGE (0)
+#define CD_LBSELADD (2)
+#define CD_LBSELSUB (1)
+#define CD_LBSELNOITEMS (-1)
+
+/* DEVNAMES structure */
+#define DN_DEFAULTPRN (1)
+
+/* PRINTDLG structure */
+#define PD_ALLPAGES (0)
+#define PD_COLLATE (16)
+#define PD_DISABLEPRINTTOFILE (524288)
+#define PD_ENABLEPRINTHOOK (4096)
+#define PD_ENABLEPRINTTEMPLATE (16384)
+#define PD_ENABLEPRINTTEMPLATEHANDLE (65536)
+#define PD_ENABLESETUPHOOK (8192)
+#define PD_ENABLESETUPTEMPLATE (32768)
+#define PD_ENABLESETUPTEMPLATEHANDLE (131072)
+#define PD_HIDEPRINTTOFILE (1048576)
+#define PD_NOPAGENUMS (8)
+#define PD_NOSELECTION (4)
+#define PD_NOWARNING (128)
+#define PD_PAGENUMS (2)
+#define PD_PRINTSETUP (64)
+#define PD_PRINTTOFILE (32)
+#define PD_RETURNDC (256)
+#define PD_RETURNDEFAULT (1024)
+#define PD_RETURNIC (512)
+#define PD_SELECTION (1)
+#define PD_SHOWHELP (2048)
+#define PD_USEDEVMODECOPIES (262144)
+#define PD_USEDEVMODECOPIESANDCOLLATE (262144)
+
+/* PAGESETUPDLG structure */
+#define PSD_DEFAULTMINMARGINS (0)
+#define PSD_DISABLEMARGINS (16)
+#define PSD_DISABLEORIENTATION (256)
+#define PSD_DISABLEPAGEPAINTING (524288)
+#define PSD_DISABLEPAPER (512)
+#define PSD_DISABLEPRINTER (32)
+#define PSD_ENABLEPAGEPAINTHOOK (262144)
+#define PSD_ENABLEPAGESETUPHOOK (8192)
+#define PSD_ENABLEPAGESETUPTEMPLATE (32768)
+#define PSD_ENABLEPAGESETUPTEMPLATEHANDLE (131072)
+#define PSD_INHUNDREDTHSOFMILLIMETERS (8)
+#define PSD_INTHOUSANDTHSOFINCHES (4)
+#define PSD_INWININIINTLMEASURE (0)
+#define PSD_MARGINS (2)
+#define PSD_MINMARGINS (1)
+#define PSD_NOWARNING (128)
+#define PSD_RETURNDEFAULT (1024)
+#define PSD_SHOWHELP (2048)
+
+/* WM_SHOWWINDOW message */
+#define SW_OTHERUNZOOM (4)
+#define SW_OTHERZOOM (2)
+#define SW_PARENTCLOSING (1)
+#define SW_PARENTOPENING (3)
+
+/* Virtual Key codes */
+#define VK_LBUTTON (1)
+#define VK_RBUTTON (2)
+#define VK_CANCEL (3)
+#define VK_MBUTTON (4)
+#define VK_BACK (8)
+#define VK_TAB (9)
+#define VK_CLEAR (12)
+#define VK_RETURN (13)
+#define VK_SHIFT (16)
+#define VK_CONTROL (17)
+#define VK_MENU (18)
+#define VK_PAUSE (19)
+#define VK_CAPITAL (20)
+#define VK_ESCAPE (27)
+#define VK_SPACE (32)
+#define VK_PRIOR (33)
+#define VK_NEXT (34)
+#define VK_END (35)
+#define VK_HOME (36)
+#define VK_LEFT (37)
+#define VK_UP (38)
+#define VK_RIGHT (39)
+#define VK_DOWN (40)
+#define VK_SELECT (41)
+#define VK_PRINT (42)
+#define VK_EXECUTE (43)
+#define VK_SNAPSHOT (44)
+#define VK_INSERT (45)
+#define VK_DELETE (46)
+#define VK_HELP (47)
+#define VK_0 (48)
+#define VK_1 (49)
+#define VK_2 (50)
+#define VK_3 (51)
+#define VK_4 (52)
+#define VK_5 (53)
+#define VK_6 (54)
+#define VK_7 (55)
+#define VK_8 (56)
+#define VK_9 (57)
+#define VK_A (65)
+#define VK_B (66)
+#define VK_C (67)
+#define VK_D (68)
+#define VK_E (69)
+#define VK_F (70)
+#define VK_G (71)
+#define VK_H (72)
+#define VK_I (73)
+#define VK_J (74)
+#define VK_K (75)
+#define VK_L (76)
+#define VK_M (77)
+#define VK_N (78)
+#define VK_O (79)
+#define VK_P (80)
+#define VK_Q (81)
+#define VK_R (82)
+#define VK_S (83)
+#define VK_T (84)
+#define VK_U (85)
+#define VK_V (86)
+#define VK_W (87)
+#define VK_X (88)
+#define VK_Y (89)
+#define VK_Z (90)
+#define VK_LWIN (91)
+#define VK_RWIN (92)
+#define VK_APPS (93)
+#define VK_NUMPAD0 (96)
+#define VK_NUMPAD1 (97)
+#define VK_NUMPAD2 (98)
+#define VK_NUMPAD3 (99)
+#define VK_NUMPAD4 (100)
+#define VK_NUMPAD5 (101)
+#define VK_NUMPAD6 (102)
+#define VK_NUMPAD7 (103)
+#define VK_NUMPAD8 (104)
+#define VK_NUMPAD9 (105)
+#define VK_MULTIPLY (106)
+#define VK_ADD (107)
+#define VK_SEPARATOR (108)
+#define VK_SUBTRACT (109)
+#define VK_DECIMAL (110)
+#define VK_DIVIDE (111)
+#define VK_F1 (112)
+#define VK_F2 (113)
+#define VK_F3 (114)
+#define VK_F4 (115)
+#define VK_F5 (116)
+#define VK_F6 (117)
+#define VK_F7 (118)
+#define VK_F8 (119)
+#define VK_F9 (120)
+#define VK_F10 (121)
+#define VK_F11 (122)
+#define VK_F12 (123)
+#define VK_F13 (124)
+#define VK_F14 (125)
+#define VK_F15 (126)
+#define VK_F16 (127)
+#define VK_F17 (128)
+#define VK_F18 (129)
+#define VK_F19 (130)
+#define VK_F20 (131)
+#define VK_F21 (132)
+#define VK_F22 (133)
+#define VK_F23 (134)
+#define VK_F24 (135)
+
+/* GetAsyncKeyState */
+#define VK_NUMLOCK (144)
+#define VK_SCROLL (145)
+#define VK_LSHIFT (160)
+#define VK_LCONTROL (162)
+#define VK_LMENU (164)
+#define VK_RSHIFT (161)
+#define VK_RCONTROL (163)
+#define VK_RMENU (165)
+
+/* ImmGetVirtualKey */
+#define VK_PROCESSKEY (229)
+
+/* Keystroke Message Flags */
+#define KF_ALTDOWN (8192)
+#define KF_DLGMODE (2048)
+#define KF_EXTENDED (256)
+#define KF_MENUMODE (4096)
+#define KF_REPEAT (16384)
+#define KF_UP (32768)
+
+/* GetKeyboardLayoutName */
+#define KL_NAMELENGTH (9)
+
+/* WM_ACTIVATE message */
+#define WA_ACTIVE (1)
+#define WA_CLICKACTIVE (2)
+#define WA_INACTIVE (0)
+
+/* WM_ACTIVATE message */
+#define PWR_CRITICALRESUME (3)
+#define PWR_SUSPENDREQUEST (1)
+#define PWR_SUSPENDRESUME (2)
+#define PWR_FAIL (-1)
+#define PWR_OK (1)
+
+/* WM_NOTIFYFORMAT message */
+#define NF_QUERY (3)
+#define NF_REQUERY (4)
+#define NFR_ANSI (1)
+#define NFR_UNICODE (2)
+
+/* WM_SIZING message */
+#define WMSZ_BOTTOM (6)
+#define WMSZ_BOTTOMLEFT (7)
+#define WMSZ_BOTTOMRIGHT (8)
+#define WMSZ_LEFT (1)
+#define WMSZ_RIGHT (2)
+#define WMSZ_TOP (3)
+#define WMSZ_TOPLEFT (4)
+#define WMSZ_TOPRIGHT (5)
+
+/* WM_MOUSEACTIVATE message */
+#define MA_ACTIVATE (1)
+#define MA_ACTIVATEANDEAT (2)
+#define MA_NOACTIVATE (3)
+#define MA_NOACTIVATEANDEAT (4)
+
+/* WM_SIZE message */
+#define SIZE_MAXHIDE (4)
+#define SIZE_MAXIMIZED (2)
+#define SIZE_MAXSHOW (3)
+#define SIZE_MINIMIZED (1)
+#define SIZE_RESTORED (0)
+
+/* WM_NCCALCSIZE message */
+#define WVR_ALIGNTOP (16)
+#define WVR_ALIGNLEFT (32)
+#define WVR_ALIGNBOTTOM (64)
+#define WVR_ALIGNRIGHT (128)
+#define WVR_HREDRAW (256)
+#define WVR_VREDRAW (512)
+#define WVR_REDRAW (768)
+#define WVR_VALIDRECTS (1024)
+
+/* WM_NCHITTEST message */
+#define HTBOTTOM (15)
+#define HTBOTTOMLEFT (16)
+#define HTBOTTOMRIGHT (17)
+#define HTCAPTION (2)
+#define HTCLIENT (1)
+#define HTERROR (-2)
+#define HTGROWBOX (4)
+#define HTHSCROLL (6)
+#define HTLEFT (10)
+#define HTMENU (5)
+#define HTNOWHERE (0)
+#define HTREDUCE (8)
+#define HTRIGHT (11)
+#define HTSIZE (4)
+#define HTSYSMENU (3)
+#define HTTOP (12)
+#define HTTOPLEFT (13)
+#define HTTOPRIGHT (14)
+#define HTTRANSPARENT (-1)
+#define HTVSCROLL (7)
+#define HTZOOM (9)
+
+/* Mouse messages */
+#define MK_CONTROL (8)
+#define MK_LBUTTON (1)
+#define MK_MBUTTON (16)
+#define MK_RBUTTON (2)
+#define MK_SHIFT (4)
+
+/* WNDCLASS structure */
+#define CS_BYTEALIGNCLIENT (4096)
+#define CS_BYTEALIGNWINDOW (8192)
+#define CS_CLASSDC (64)
+#define CS_DBLCLKS (8)
+#define CS_GLOBALCLASS (16384)
+#define CS_HREDRAW (2)
+#define CS_KEYCVTWINDOW (4)
+#define CS_NOCLOSE (512)
+#define CS_NOKEYCVT (256)
+#define CS_OWNDC (32)
+#define CS_PARENTDC (128)
+#define CS_SAVEBITS (2048)
+#define CS_VREDRAW (1)
+#define DLGWINDOWEXTRA (30)
+
+/* ACCEL structure */
+#define FALT (16)
+#define FCONTROL (8)
+#define FNOINVERT (2)
+#define FSHIFT (4)
+#define FVIRTKEY (1)
+
+/* MENUITEMINFO structure */
+#define MIIM_CHECKMARKS (8)
+#define MIIM_DATA (32)
+#define MIIM_ID (2)
+#define MIIM_STATE (1)
+#define MIIM_SUBMENU (4)
+#define MIIM_TYPE (16)
+#define MFT_BITMAP (0x4L)
+#define MFT_MENUBARBREAK (0x20L)
+#define MFT_MENUBREAK (0x40L)
+#define MFT_OWNERDRAW (0x100L)
+#define MFT_RADIOCHECK (0x200L)
+#define MFT_RIGHTJUSTIFY (0x4000L)
+#define MFT_SEPARATOR (0x800L)
+#define MFT_STRING (0L)
+#define MFS_CHECKED (0x8L)
+#define MFS_DEFAULT (0x1000L)
+#define MFS_DISABLED (0x3L)
+#define MFS_ENABLED (0L)
+#define MFS_GRAYED (0x3L)
+#define MFS_HILITE (0x80L)
+#define MFS_UNCHECKED (0L)
+#define MFS_UNHILITE (0L)
+
+/* SERIALKEYS structure */
+#define SERKF_AVAILABLE (2)
+#define SERKF_INDICATOR (4)
+#define SERKF_SERIALKEYSON (1)
+
+/* FILTERKEYS structure */
+#define FKF_AVAILABLE (2)
+#define FKF_CLICKON (64)
+#define FKF_FILTERKEYSON (1)
+#define FKF_HOTKEYACTIVE (4)
+#define FKF_HOTKEYSOUND (16)
+#define FKF_CONFIRMHOTKEY (8)
+#define FKF_INDICATOR (32)
+
+/* HELPINFO structure */
+#define HELPINFO_MENUITEM (2)
+#define HELPINFO_WINDOW (1)
+
+/* WM_PRINT message */
+#define PRF_CHECKVISIBLE (0x1L)
+#define PRF_CHILDREN (0x10L)
+#define PRF_CLIENT (0x4L)
+#define PRF_ERASEBKGND (0x8L)
+#define PRF_NONCLIENT (0x2L)
+#define PRF_OWNED (0x20L)
+
+/* MapWindowPoints */
+#define HWND_DESKTOP ((HWND)0)
+
+/* WM_SYSCOMMAND message */
+#define SC_CLOSE (61536)
+#define SC_CONTEXTHELP (61824)
+#define SC_DEFAULT (61792)
+#define SC_HOTKEY (61776)
+#define SC_HSCROLL (61568)
+#define SC_KEYMENU (61696)
+#define SC_MAXIMIZE (61488)
+#define SC_ZOOM (61488)
+#define SC_MINIMIZE (61472)
+#define SC_ICON (61472)
+#define SC_MONITORPOWER (61808)
+#define SC_MOUSEMENU (61584)
+#define SC_MOVE (61456)
+#define SC_NEXTWINDOW (61504)
+#define SC_PREVWINDOW (61520)
+#define SC_RESTORE (61728)
+#define SC_SCREENSAVE (61760)
+#define SC_SIZE (61440)
+#define SC_TASKLIST (61744)
+#define SC_VSCROLL (61552)
+
+/* DM_GETDEFID message */
+#define DC_HASDEFID (21323)
+
+/* WM_GETDLGCODE message */
+#define DLGC_BUTTON (8192)
+#define DLGC_DEFPUSHBUTTON (16)
+#define DLGC_HASSETSEL (8)
+#define DLGC_RADIOBUTTON (64)
+#define DLGC_STATIC (256)
+#define DLGC_UNDEFPUSHBUTTON (32)
+#define DLGC_WANTALLKEYS (4)
+#define DLGC_WANTARROWS (1)
+#define DLGC_WANTCHARS (128)
+#define DLGC_WANTMESSAGE (4)
+#define DLGC_WANTTAB (2)
+
+/* EM_SETMARGINS message */
+#define EC_LEFTMARGIN (1)
+#define EC_RIGHTMARGIN (2)
+#define EC_USEFONTINFO (65535)
+
+/* LB_SETCOUNT message */
+#define LB_ERR (-1)
+#define LB_ERRSPACE (-2)
+#define LB_OKAY (0)
+
+/* CB_DIR message */
+#define CB_ERR (-1)
+#define CB_ERRSPACE (-2)
+
+/* WM_IME_CONTROL message */
+#define IMC_GETCANDIDATEPOS (7)
+#define IMC_GETCOMPOSITIONFONT (9)
+#define IMC_GETCOMPOSITIONWINDOW (11)
+#define IMC_GETSTATUSWINDOWPOS (15)
+#define IMC_CLOSESTATUSWINDOW (33)
+#define IMC_OPENSTATUSWINDOW (34)
+#define IMC_SETCANDIDATEPOS (8)
+#define IMC_SETCOMPOSITIONFONT (10)
+#define IMC_SETCOMPOSITIONWINDOW (12)
+#define IMC_SETSTATUSWINDOWPOS (16)
+
+/* WM_IME_CONTROL message */
+#define IMN_CHANGECANDIDATE (3)
+#define IMN_CLOSECANDIDATE (4)
+#define IMN_CLOSESTATUSWINDOW (1)
+#define IMN_GUIDELINE (13)
+#define IMN_OPENCANDIDATE (5)
+#define IMN_OPENSTATUSWINDOW (2)
+#define IMN_SETCANDIDATEPOS (9)
+#define IMN_SETCOMPOSITIONFONT (10)
+#define IMN_SETCOMPOSITIONWINDOW (11)
+#define IMN_SETCONVERSIONMODE (6)
+#define IMN_SETOPENSTATUS (8)
+#define IMN_SETSENTENCEMODE (7)
+#define IMN_SETSTATUSWINDOWPOS (12)
+#define IMN_PRIVATE (14)
+
+/* STICKYKEYS structure */
+#define SKF_AUDIBLEFEEDBACK (64)
+#define SKF_AVAILABLE (2)
+#define SKF_CONFIRMHOTKEY (8)
+#define SKF_HOTKEYACTIVE (4)
+#define SKF_HOTKEYSOUND (16)
+#define SKF_INDICATOR (32)
+#define SKF_STICKYKEYSON (1)
+#define SKF_TRISTATE (128)
+#define SKF_TWOKEYSOFF (256)
+
+/* MOUSEKEYS structure */
+#define MKF_AVAILABLE (2)
+#define MKF_CONFIRMHOTKEY (8)
+#define MKF_HOTKEYACTIVE (4)
+#define MKF_HOTKEYSOUND (16)
+#define MKF_INDICATOR (32)
+#define MKF_MOUSEKEYSON (1)
+#define MKF_MODIFIERS (64)
+#define MKF_REPLACENUMBERS (128)
+
+/* SOUNDSENTRY structure */
+#define SSF_AVAILABLE (2)
+#define SSF_SOUNDSENTRYON (1)
+#define SSTF_BORDER (2)
+#define SSTF_CHARS (1)
+#define SSTF_DISPLAY (3)
+#define SSTF_NONE (0)
+#define SSGF_DISPLAY (3)
+#define SSGF_NONE (0)
+#define SSWF_CUSTOM (4)
+#define SSWF_DISPLAY (3)
+#define SSWF_NONE (0)
+#define SSWF_TITLE (1)
+#define SSWF_WINDOW (2)
+
+/* ACCESSTIMEOUT structure */
+#define ATF_ONOFFFEEDBACK (2)
+#define ATF_TIMEOUTON (1)
+
+/* HIGHCONTRAST structure */
+#define HCF_AVAILABLE (2)
+#define HCF_CONFIRMHOTKEY (8)
+#define HCF_HIGHCONTRASTON (1)
+#define HCF_HOTKEYACTIVE (4)
+#define HCF_HOTKEYAVAILABLE (64)
+#define HCF_HOTKEYSOUND (16)
+#define HCF_INDICATOR (32)
+
+/* TOGGLEKEYS structure */
+#define TKF_AVAILABLE (2)
+#define TKF_CONFIRMHOTKEY (8)
+#define TKF_HOTKEYACTIVE (4)
+#define TKF_HOTKEYSOUND (16)
+#define TKF_TOGGLEKEYSON (1)
+
+/* Installable Policy */
+#define PP_DISPLAYERRORS (1)
+
+/* SERVICE_INFO structure */
+#define RESOURCEDISPLAYTYPE_DOMAIN (1)
+#define RESOURCEDISPLAYTYPE_FILE (4)
+#define RESOURCEDISPLAYTYPE_GENERIC (0)
+#define RESOURCEDISPLAYTYPE_GROUP (5)
+#define RESOURCEDISPLAYTYPE_SERVER (2)
+#define RESOURCEDISPLAYTYPE_SHARE (3)
+
+/* KEY_EVENT_RECORD structure */
+#define CAPSLOCK_ON (128)
+#define ENHANCED_KEY (256)
+#define LEFT_ALT_PRESSED (2)
+#define LEFT_CTRL_PRESSED (8)
+#define NUMLOCK_ON (32)
+#define RIGHT_ALT_PRESSED (1)
+#define RIGHT_CTRL_PRESSED (4)
+#define SCROLLLOCK_ON (64)
+#define SHIFT_PRESSED (16)
+
+/* MOUSE_EVENT_RECORD structure */
+#define FROM_LEFT_1ST_BUTTON_PRESSED (1)
+#define RIGHTMOST_BUTTON_PRESSED (2)
+#define FROM_LEFT_2ND_BUTTON_PRESSED (4)
+#define FROM_LEFT_3RD_BUTTON_PRESSED (8)
+#define FROM_LEFT_4TH_BUTTON_PRESSED (16)
+#define DOUBLE_CLICK (2)
+#define MOUSE_MOVED (1)
+
+/* INPUT_RECORD structure */
+#define KEY_EVENT (1)
+#define MOUSE_EVENT (2)
+#define WINDOW_BUFFER_SIZE_EVENT (4)
+#define MENU_EVENT (8)
+#define FOCUS_EVENT (16)
+
+/* BITMAPINFOHEADER structure */
+#define BI_RGB (0L)
+#define BI_RLE8 (1L)
+#define BI_RLE4 (2L)
+#define BI_BITFIELDS (3L)
+
+/* Extensions to OpenGL */
+
+/* ChoosePixelFormat */
+#define PFD_DRAW_TO_WINDOW (0x4)
+#define PFD_DRAW_TO_BITMAP (0x8)
+#define PFD_SUPPORT_GDI (0x10)
+#define PFD_SUPPORT_OPENGL (0x20)
+#define PFD_DOUBLEBUFFER (0x1)
+#define PFD_STEREO (0x2)
+#define PFD_DOUBLEBUFFER_DONTCARE (0x40000000)
+#define PFD_STEREO_DONTCARE (0x80000000)
+#define PFD_TYPE_RGBA (0)
+#define PFD_TYPE_COLORINDEX (1)
+#define PFD_MAIN_PLANE (0)
+#define PFD_OVERLAY_PLANE (1)
+#define PFD_UNDERLAY_PLANE (-1)
+
+/* wglUseFontOutlines */
+#define WGL_FONT_LINES (0)
+#define WGL_FONT_POLYGONS (1)
+
+/* LAYERPLANEDESCRIPTOR structure */
+
+/* PIXELFORMATDESCRIPTOR structure */
+#define PFD_GENERIC_FORMAT (0x40)
+#define PFD_NEED_PALETTE (0x80)
+#define PFD_NEED_SYSTEM_PALETTE (0x100)
+#define PFD_SWAP_COPY (0x400)
+#define PFD_SWAP_EXCHANGE (0x200)
+
+/* TEXTMETRIC structure */
+#define TMPF_FIXED_PITCH (0x1)
+#define TMPF_VECTOR (0x2)
+#define TMPF_TRUETYPE (0x4)
+#define TMPF_DEVICE (0x8)
+
+/* --------------------- old stuff, need to organize! --------------- */
+
+#define MNC_IGNORE 0
+#define MNC_CLOSE 1
+#define MNC_EXECUTE 2
+#define MNC_SELECT 3
+
+/* BEGINNING of windowsx.h stuff from old headers: */
+#define __CRACK_VOID_F(fn,args) (void)(fn args)
+#define __CRACK_BOOL_F(fn,args) (BOOL)(fn args)
+#define __CRACK_HMENU_F(fn,args) (HMENU)(fn args)
+#define __CRACK_HWND_F(fn,args) (HWND)(fn args)
+#define __CRACK_LONG_F(fn, args) (LRESULT)(fn args)
+#define __CRACK_ZERO_F(fn, args) (fn args,0)
+#define GetFirstChild(h) GetTopWindow(h)
+#define GetNextSibling(h) GetWindow(h, GW_HWNDNEXT)
+#define GetWindowID(h) GetDlgCtrlID(h)
+#define SubclassWindow(h, p) (SetWindowLong(h, GWL_WNDPROC, p))
+
+#define GET_WM_COMMAND_CMD(w, l) HIWORD(w)
+#define GET_WM_COMMAND_ID(w, l) LOWORD(w)
+#define GET_WM_CTLCOLOR_HDC(w, l, msg) (HDC)(w)
+#define GET_WM_CTLCOLOR_HWND(w, l, msg) (HWND)(l)
+#define GET_WM_HSCROLL_CODE(w, l) LOWORD(w)
+#define GET_WM_HSCROLL_HWND(w, l) (HWND)(l)
+#define GET_WM_HSCROLL_POS(w, l) HIWORD(w)
+#define GET_WM_MDIACTIVATE_FACTIVATE(h, a, b) (b == (LONG)h)
+#define GET_WM_MDIACTIVATE_HWNDACTIVATE(a, b) (HWND)(b)
+#define GET_WM_MDIACTIVATE_HWNDDEACT(a, b) (HWND)(a)
+#define GET_WM_VSCROLL_CODE(w, l) LOWORD(w)
+#define GET_WM_VSCROLL_HWND(w, l) (HWND)(l)
+#define GET_WM_VSCROLL_POS(w, l) HIWORD(w)
+
+#define FORWARD_WM_CLOSE(h, fn) __CRACK_VOID_F(fn,(h, WM_CLOSE, 0, 0))
+#define FORWARD_WM_COMMAND(h, id, c, n, fn) __CRACK_VOID_F(fn,(h, WM_COMMAND, MAKEWPARAM(id,n), (LPARAM)c))
+#define FORWARD_WM_CREATE(h, p, fn) __CRACK_BOOL_F(fn,(h, WM_CREATE, 0, (LPARAM)p))
+#define FORWARD_WM_DESTROY(h, fn) __CRACK_VOID_F(fn,(h, WM_DESTROY, 0, 0))
+#define FORWARD_WM_ENABLE(h, e, fn) __CRACK_VOID_F(fn,(h, WM_ENABLE, (WPARAM)e, 0))
+#define FORWARD_WM_INITDIALOG(h, c, l, fn) __CRACK_BOOL_F(fn,(h, WM_INITDIALOG, (WPARAM)c, l))
+#define FORWARD_WM_MDICASCADE(h, c, fn) __CRACK_BOOL_F(fn,(h, WM_MDICASCADE, (WPARAM)c, 0))
+#define FORWARD_WM_MDIDESTROY(h, d, fn) __CRACK_VOID_F(fn,(h, WM_MDIDESTROY, (WPARAM)d, 0))
+#define FORWARD_WM_MDIGETACTIVE(h, fn) __CRACK_HWND_F(fn,(h, WM_MDIGETACTIVE, 0, 0))
+#define FORWARD_WM_MDIICONARRANGE(h, fn) __CRACK_VOID_F(fn,(h, WM_MDIICONARRANGE, 0, 0))
+#define FORWARD_WM_MDISETMENU(h, fr, hf, hw, fn) __CRACK_HMENU_F(fn,(h, WM_MDISETMENU, (WPARAM)((fr) ? (hf) : 0), (LPARAM)(hw)))
+#define FORWARD_WM_MDITILE(h, c, fn) __CRACK_BOOL_F(fn,(h, WM_MDITILE, (WPARAM)(c), 0))
+#define FORWARD_WM_PAINT(h, fn) __CRACK_VOID_F(fn,(h, WM_PAINT, 0, 0))
+#define FORWARD_WM_QUERYENDSESSION(h, fn) __CRACK_BOOL_F(fn,(h, WM_QUERYENDSESSION, 0, 0))
+#define FORWARD_WM_SIZE(h, state, cx, cy, fn) __CRACK_VOID_F(fn,(h, WM_SIZE, (WPARAM)state, MAKELPARAM(cx, cy)))
+#define FORWARD_WM_SYSCOMMAND(h, c, x, y, fn) __CRACK_VOID_F(fn,(h, WM_SYSCOMMAND, (WPARAM)c, MAKELPARAM(x, y)))
+
+#define HANDLE_WM_CLOSE(h, w, l, fn) __CRACK_ZERO_F(fn,(h));
+#define HANDLE_WM_COMMAND(h, w, l, fn) __CRACK_ZERO_F(fn,(h, SEXT_LOWORD(w), (HWND)l, HIWORD(w)))
+#define HANDLE_WM_CREATE(h, w, l, fn) (LRESULT)((fn(h, (CREATESTRUCT *)l)) ? 0 : -1)
+#define HANDLE_WM_DESTROY(h, w, l, fn) __CRACK_ZERO_F(fn,(h))
+#define HANDLE_WM_ENABLE(h, w, l, fn) __CRACK_ZERO_F(fn,(h, (BOOL)w))
+#define HANDLE_WM_INITDIALOG(h, w, l, fn) __CRACK_LONG_F(fn,(h, (HWND)w, l))
+#define HANDLE_WM_MDICASCADE(h, w, l, fn) __CRACK_LONG_F(fn, (h, (UINT)w)
+#define HANDLE_WM_MDIDESTROY(h, w, l, fn) __CRACK_ZERO_F(fn,(h, (HWND)w))
+#define HANDLE_WM_MDIGETACTIVE(h, w, l, fn) __CRACK_LONG_F(fn,(h))
+#define HANDLE_WM_MDIICONARRANGE(h, w, l, fn) __CRACK_ZERO_F(fn,(h))
+#define HANDLE_WM_MDISETMENU(h, w, l, fn) __CRACK_LONG_F(fn,(h, (BOOL)w, (HMENU)w, (HMENU)l)
+#define HANDLE_WM_MDITILE(h, w, l, fn) __CRACK_LONG_F(fn,(h, (UINT)w))
+#define HANDLE_WM_PAINT(h, w, l, fn) __CRACK_ZERO_F(fn,(h))
+#define HANDLE_WM_QUERYENDSESSION(h, w, l, fn) MAKELRESULT(fn(h), 0)
+#define HANDLE_WM_SIZE(h, w, l, fn) __CRACK_ZERO_F(fn,(h, (UINT)w, SEXT_LOWORD(l), SEXT_HIWORD(l)))
+#define HANDLE_WM_SYSCOMMAND(h, w, l, fn) __CRACK_ZERO_F(fn,(h, (UINT)w, SEXT_LOWORD(l), SEXT_HIWORD(l)))
+
+/* Totally disgusting! get wParam and lParam from the environment ! */
+#define HANDLE_MSG(h, message, fn) case message: return HANDLE_##message(h, wParam, lParam, fn)
+
+/* END OF windowsx.h stuff from old headers */
+/* ------------------------------------------------------------------ */
+/* BEGINNING of shellapi.h stuff from old headers */
+
+#define SE_ERR_SHARE 26
+#define SE_ERR_ASSOCINCOMPLETE 27
+#define SE_ERR_DDETIMEOUT 28
+#define SE_ERR_DDEFAIL 29
+#define SE_ERR_DDEBUSY 30
+#define SE_ERR_NOASSOC 31
+
+/* END OF shellapi.h stuff from old headers */
+/* ------------------------------------------------------------------ */
+/* From ddeml.h in old Cygnus headers */
+
+#define XCLASS_BOOL 0x1000
+#define XCLASS_DATA 0x2000
+#define XCLASS_FLAGS 0x4000
+#define XCLASS_MASK 0xfc00
+#define XCLASS_NOTIFICATION 0x8000
+#define XTYPF_NOBLOCK 0x0002
+#define XTYP_ADVDATA 0x4010
+#define XTYP_ADVREQ 0x2022
+#define XTYP_ADVSTART 0x1030
+#define XTYP_ADVSTOP 0x8040
+#define XTYP_CONNECT 0x1062
+#define XTYP_CONNECT_CONFIRM 0x8072
+#define XTYP_DISCONNECT 0x80c2
+#define XTYP_EXECUTE 0x4050
+#define XTYP_POKE 0x4090
+#define XTYP_REQUEST 0x20b0
+#define XTYP_WILDCONNECT 0x20E2
+#define XTYP_REGISTER 0x80A2
+#define XTYP_ERROR 0x8002
+#define XTYP_XACT_COMPLETE 0x8080
+#define XTYP_UNREGISTER 0x80D2
+
+#define DMLERR_DLL_USAGE 0x4004
+#define DMLERR_INVALIDPARAMETER 0x4006
+#define DMLERR_NOTPROCESSED 0x4009
+#define DMLERR_POSTMSG_FAILED 0x400c
+#define DMLERR_SERVER_DIED 0x400e
+#define DMLERR_SYS_ERROR 0x400f
+#define DMLERR_BUSY 0x4001
+#define DMLERR_DATAACKTIMEOUT 0x4002
+#define DMLERR_ADVACKTIMEOUT 0x4000
+#define DMLERR_DLL_NOT_INITIALIZED 0x4003
+#define DMLERR_LOW_MEMORY 0x4007
+#define DMLERR_MEMORY_ERROR 0x4008
+#define DMLERR_POKEACKTIMEOUT 0x400b
+#define DMLERR_NO_CONV_ESTABLISHED 0x400a
+#define DMLERR_REENTRANCY 0x400d
+#define DMLERR_UNFOUND_QUEUE_ID 0x4011
+#define DMLERR_UNADVACKTIMEOUT 0x4010
+#define DMLERR_EXECACKTIMEOUT 0x4005
+#define DDE_FACK 0x8000
+#define DDE_FNOTPROCESSED 0x0000
+
+#define DNS_REGISTER 0x0001
+#define DNS_UNREGISTER 0x0002
+#define CP_WINANSI 1004
+#define CP_WINUNICODE 1200
+#define EXPENTRY CALLBACK
+#define APPCLASS_STANDARD 0x00000000
+
+/* End of stuff from ddeml.h in old Cygnus headers */
+/* ----------------------------------------------- */
+
+#define BKMODE_LAST (2)
+
+#define CTLCOLOR_MSGBOX (0)
+#define CTLCOLOR_EDIT (1)
+#define CTLCOLOR_LISTBOX (2)
+#define CTLCOLOR_BTN (3)
+#define CTLCOLOR_DLG (4)
+#define CTLCOLOR_SCROLLBAR (5)
+#define CTLCOLOR_STATIC (6)
+#define CTLCOLOR_MAX (7)
+
+#define META_SETMAPMODE (0x0103L)
+#define META_SETWINDOWORG (0x020BL)
+#define META_SETWINDOWEXT (0x020CL)
+
+#define POLYFILL_LAST (2)
+
+#define STATUS_WAIT_0 (0x00000000L)
+#define STATUS_ABANDONED_WAIT_0 (0x00000080L)
+#define STATUS_USER_APC (0x000000C0L)
+#define STATUS_TIMEOUT (0x00000102L)
+#define STATUS_PENDING (0x00000103L)
+#define STATUS_GUARD_PAGE_VIOLATION (0x80000001L)
+#define STATUS_DATATYPE_MISALIGNMENT (0x80000002L)
+#define STATUS_BREAKPOINT (0x80000003L)
+#define STATUS_SINGLE_STEP (0x80000004L)
+#define STATUS_IN_PAGE_ERROR (0xC0000006L)
+#define STATUS_INVALID_HANDLE (0xC0000008L)
+#define STATUS_ILLEGAL_INSTRUCTION (0xC000001DL)
+#define STATUS_NONCONTINUABLE_EXCEPTION (0xC0000025L)
+#define STATUS_INVALID_DISPOSITION (0xC0000026L)
+#define STATUS_ARRAY_BOUNDS_EXCEEDED (0xC000008CL)
+#define STATUS_FLOAT_DENORMAL_OPERAND (0xC000008DL)
+#define STATUS_FLOAT_DIVIDE_BY_ZERO (0xC000008EL)
+#define STATUS_FLOAT_INEXACT_RESULT (0xC000008FL)
+#define STATUS_FLOAT_INVALID_OPERATION (0xC0000090L)
+#define STATUS_FLOAT_OVERFLOW (0xC0000091L)
+#define STATUS_FLOAT_STACK_CHECK (0xC0000092L)
+#define STATUS_FLOAT_UNDERFLOW (0xC0000093L)
+#define STATUS_INTEGER_DIVIDE_BY_ZERO (0xC0000094L)
+#define STATUS_INTEGER_OVERFLOW (0xC0000095L)
+#define STATUS_PRIVILEGED_INSTRUCTION (0xC0000096L)
+#define STATUS_STACK_OVERFLOW (0xC00000FDL)
+#define STATUS_CONTROL_C_EXIT (0xC000013AL)
+
+#define EXCEPTION_CTRL_C
+
+#define PROCESSOR_ARCHITECTURE_INTEL 0
+#define PROCESSOR_ARCHITECTURE_MIPS 1
+#define PROCESSOR_ARCHITECTURE_ALPHA 2
+#define PROCESSOR_ARCHITECTURE_PPC 3
+
+#define FreeModule(h) FreeLibrary(h)
+#define MakeProcInstance(p,i) (p)
+#define FreeProcInstance(p) (p)
+
+#define _fmemcpy memcpy
+
+/* Used by wxwindows. */
+#define SIZEFULLSCREEN SIZE_MAXIMIZED
+#define SIZENORMAL SIZE_RESTORED
+#define SIZEICONIC SIZE_MINIMIZED
+#define NPLOGPALETTE PLOGPALETTE
+
+/* In the old winnt.h */
+#if 0
+#ifdef __ANAL__
+#define DECLARE_HANDLE(h) struct h##__ { int dummy; }; typedef struct h##__ *h
+#else
+#define DECLARE_HANDLE(h) typedef void *h
+#endif
+DECLARE_HANDLE(HANDLE);
+#endif
+
+#ifdef __PPC__
+#define CONTEXT_CONTROL 1L
+#define CONTEXT_FLOATING_POINT 2L
+#define CONTEXT_INTEGER 4L
+#define CONTEXT_DEBUG_REGISTERS 8L
+
+#define CONTEXT_FULL (CONTEXT_CONTROL | CONTEXT_FLOATING_POINT | CONTEXT_INTEGER)
+#define CONTEXT_DEBUGGER (CONTEXT_FULL)
+
+#else /* x86 */
+/* The doc refered me to winnt.h, so I had to look... */
+#define SIZE_OF_80387_REGISTERS 80
+
+/* Values for contextflags */
+#define CONTEXT_i386 0x10000
+#define CONTEXT_CONTROL (CONTEXT_i386 | 1)
+#define CONTEXT_INTEGER (CONTEXT_i386 | 2)
+#define CONTEXT_SEGMENTS (CONTEXT_i386 | 4)
+#define CONTEXT_FLOATING_POINT (CONTEXT_i386 | 8)
+#define CONTEXT_DEBUG_REGISTERS (CONTEXT_i386 | 0x10)
+#define CONTEXT_FULL (CONTEXT_CONTROL | CONTEXT_INTEGER | CONTEXT_SEGMENTS)
+
+/* our own invention */
+#define FLAG_TRACE_BIT 0x100
+#define CONTEXT_DEBUGGER (CONTEXT_FULL | CONTEXT_FLOATING_POINT)
+
+#endif
+
+#define ASCIICHAR AsciiChar
+#define FAR
+#define PACKED __attribute__((packed))
+
+#define FILTER_TEMP_DUPLICATE_ACCOUNT (0x0001)
+#define FILTER_NORMAL_ACCOUNT (0x0002)
+#define FILTER_INTERDOMAIN_TRUST_ACCOUNT (0x0008)
+#define FILTER_WORKSTATION_TRUST_ACCOUNT (0x0010)
+#define FILTER_SERVER_TRUST_ACCOUNT (0x0020)
+
+#define LOGON32_LOGON_INTERACTIVE (0x02)
+#define LOGON32_LOGON_BATCH (0x04)
+#define LOGON32_LOGON_SERVICE (0x05)
+#define LOGON32_PROVIDER_DEFAULT (0x00)
+#define LOGON32_PROVIDER_WINNT35 (0x01)
+
+#define QID_SYNC 0xFFFFFFFF
+
+/* Magic numbers in PE executable header. */
+
+#define IMAGE_DOS_SIGNATURE (0x5a4d) /* e_magic field */
+#define IMAGE_NT_SIGNATURE (0x4550) /* nt_signature field */
+
+#ifdef __cplusplus
+}
+#endif /* __cplusplus */
+
+#endif /* _GNU_H_WINDOWS32_DEFINES */