From 323f465209897f186bf460656a639b93b639f7ee Mon Sep 17 00:00:00 2001 From: Martin Hunt Date: Tue, 21 Jan 2003 21:58:34 +0000 Subject: 2003-01-21 Martin M. Hunt * library/main.tcl: Don't require iwidgets 3.0. * library/console.itb (Console::_build_win): Rename tkTextClosestGap to tk::TextClosestGap. Rename tkCancelRepeat to tk::CancelRepeat. Rename tkPriv to tk::Priv. Needed for tk 8.4.1. * library/bpwin.itb (BpWin::build_win): Don't create sizebox. * library/locals.tcl (build_win): Ditto. * library/regwin.itb (RegWin::_build_win): Ditto. * library/srcwin.itb (SrcWin::constructor): Ditto. * library/stackwin.itb (StackWin::build_win): Ditto. * library/watch.tcl (build_win): Ditto. --- gdb/gdbtk/library/bpwin.itb | 14 +++----------- gdb/gdbtk/library/console.itb | 16 ++++++++-------- gdb/gdbtk/library/locals.tcl | 6 +++--- gdb/gdbtk/library/main.tcl | 2 +- gdb/gdbtk/library/regwin.itb | 12 ++++++------ gdb/gdbtk/library/srcwin.itb | 4 ++-- gdb/gdbtk/library/stackwin.itb | 6 +++--- gdb/gdbtk/library/watch.tcl | 8 ++++---- 8 files changed, 30 insertions(+), 38 deletions(-) (limited to 'gdb/gdbtk/library') diff --git a/gdb/gdbtk/library/bpwin.itb b/gdb/gdbtk/library/bpwin.itb index b8ec482296e..3d54f0dda3b 100644 --- a/gdb/gdbtk/library/bpwin.itb +++ b/gdb/gdbtk/library/bpwin.itb @@ -1,5 +1,5 @@ # Breakpoint window for Insight. -# Copyright 1997, 1998, 1999, 2001, 2002 Red Hat, Inc. +# Copyright 1997, 1998, 1999, 2001, 2002, 2003 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 @@ -47,16 +47,8 @@ itcl::body BpWin::build_win {} { global _bp_en _bp_disp tcl_platform set bg1 $::Colors(bg) - if {$tcl_platform(platform) == "windows"} { - # Add a sizebox and set scroll modes to static - ide_sizebox $itk_interior.sbox - place $itk_interior.sbox -relx 1.0 -rely 1.0 -anchor se - set hsmode static - set vsmode static - } else { - set hsmode dynamic - set vsmode dynamic - } + set hsmode dynamic + set vsmode dynamic # FIXME: The iwidgets scrolled frame is pretty useless. # When we get BLT, use its hiertable to do this. diff --git a/gdb/gdbtk/library/console.itb b/gdb/gdbtk/library/console.itb index 3a51a3fc572..6a1a58cc9b9 100644 --- a/gdb/gdbtk/library/console.itb +++ b/gdb/gdbtk/library/console.itb @@ -1,5 +1,5 @@ # Console window for Insight -# Copyright 1998, 1999, 2000, 2001, 2002 Red Hat, Inc. +# Copyright 1998, 1999, 2000, 2001, 2002, 2003 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 @@ -147,7 +147,7 @@ itcl::body Console::_build_win {} { # the saved insertion point. set pretag pre-$_twin bind $_twin <1> [format { - if {[%%W compare [tkTextClosestGap %%W %%x %%y] <= cmdmark]} { + if {[%%W compare [tk::TextClosestGap %%W %%x %%y] <= cmdmark]} { %s _insertion [%%W index insert] } else { %s _insertion {} @@ -160,7 +160,7 @@ itcl::body Console::_build_win {} { } $this $this $this] # FIXME: has inside information. bind $_twin [format { - tkCancelRepeat + tk::CancelRepeat if {[%s _insertion] != ""} { %%W mark set insert [%s _insertion] } @@ -174,18 +174,18 @@ itcl::body Console::_build_win {} { # drags a little "fuzzy". bind $_twin { if {!$tk_strictMotif} { - if {($tkPriv(x) - 2 < %x < $tkPriv(x) + 2) \ - || ($tkPriv(y) - 2 < %y < $tkPriv(y) + 2)} { - set tkPriv(mouseMoved) 1 + 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(mouseMoved)} { + if {$tk::Priv(mouseMoved)} { %W scan dragto %x %y } } break } bind $_twin [format { - if {!$tkPriv(mouseMoved) || $tk_strictMotif} { + if {!$tk::Priv(mouseMoved) || $tk_strictMotif} { %s break } diff --git a/gdb/gdbtk/library/locals.tcl b/gdb/gdbtk/library/locals.tcl index aabd5f5ba23..390154d6460 100644 --- a/gdb/gdbtk/library/locals.tcl +++ b/gdb/gdbtk/library/locals.tcl @@ -1,5 +1,5 @@ # Local Variable Window for Insight. -# Copyright 2002 Red Hat +# Copyright 2002, 2003 Red Hat # # 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 @@ -83,8 +83,8 @@ itcl::class LocalsWin { pack $f.tree -expand yes -fill both pack $f -expand yes -fill both if {$::tcl_platform(platform) == "windows"} { - ide_sizebox [namespace tail $this].sizebox - place [namespace tail $this].sizebox -relx 1 -rely 1 -anchor se +# ide_sizebox [namespace tail $this].sizebox +# place [namespace tail $this].sizebox -relx 1 -rely 1 -anchor se } window_name "Local Variables" diff --git a/gdb/gdbtk/library/main.tcl b/gdb/gdbtk/library/main.tcl index 76638be2347..2dac8a3bfa7 100644 --- a/gdb/gdbtk/library/main.tcl +++ b/gdb/gdbtk/library/main.tcl @@ -78,7 +78,7 @@ namespace import debug::* if {[info exists IWIDGETS_LIBRARY]} { lappend auto_path $IWIDGETS_LIBRARY } -if {[catch {package require Iwidgets 3.0} msg]} { +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" diff --git a/gdb/gdbtk/library/regwin.itb b/gdb/gdbtk/library/regwin.itb index d68fd4eb0b9..594b9f5f9f8 100644 --- a/gdb/gdbtk/library/regwin.itb +++ b/gdb/gdbtk/library/regwin.itb @@ -1,5 +1,5 @@ # Register display window for Insight. -# Copyright 1998, 1999, 2001, 2002 Red Hat, Inc. +# Copyright 1998, 1999, 2001, 2002, 2003 Red Hat, Inc. # # Written by Keith Seitz (keiths@redhat.com) # and Martin Hunt (hunt@redhat.com) @@ -241,11 +241,11 @@ itcl::body RegWin::_build_win {} { grid rowconfigure $itk_interior 0 -weight 0 grid rowconfigure $itk_interior 1 -weight 1 - # Add sizebox for windows - if {[string compare $::tcl_platform(platform) "windows"] == 0} { - ide_sizebox $itk_interior.sbox - place $itk_interior.sbox -relx 1.0 -rely 1.0 -anchor se - } +# Add sizebox for windows +# if {[string compare $::tcl_platform(platform) "windows"] == 0} { +# ide_sizebox $itk_interior.sbox +# place $itk_interior.sbox -relx 1.0 -rely 1.0 -anchor se +# } # Add popup menu - we populate it in the event handler itk_component add popup { diff --git a/gdb/gdbtk/library/srcwin.itb b/gdb/gdbtk/library/srcwin.itb index d4ab32d0846..141dec118a2 100644 --- a/gdb/gdbtk/library/srcwin.itb +++ b/gdb/gdbtk/library/srcwin.itb @@ -1,5 +1,5 @@ # Source window for Insight. -# Copyright 1997, 1998, 1999, 2000, 2001, 2002 Red Hat, Inc. +# Copyright 1997, 1998, 1999, 2000, 2001, 2002, 2003 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 @@ -24,7 +24,7 @@ itcl::body SrcWin::constructor {args} { # On Windows, create a sizebox. if {$::tcl_platform(platform) == "windows"} { - ide_sizebox $itk_interior.sizebox +# ide_sizebox $itk_interior.sizebox } set Tracing [pref get gdb/mode] diff --git a/gdb/gdbtk/library/stackwin.itb b/gdb/gdbtk/library/stackwin.itb index 971f6727f9a..8cea5f1bfde 100644 --- a/gdb/gdbtk/library/stackwin.itb +++ b/gdb/gdbtk/library/stackwin.itb @@ -1,5 +1,5 @@ # Stack window for Insight. -# Copyright 1997, 1998, 1999, 2002 Red Hat +# Copyright 1997, 1998, 1999, 2002, 2003 Red Hat # # 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 @@ -48,8 +48,8 @@ itcl::body StackWin::build_win {} { # Add sizebox for windows if {[string compare $tcl_platform(platform) "windows"] == 0} { - ide_sizebox $itk_interior.sbox - place $itk_interior.sbox -relx 1.0 -rely 1.0 -anchor se +# ide_sizebox $itk_interior.sbox +# place $itk_interior.sbox -relx 1.0 -rely 1.0 -anchor se } update dummy diff --git a/gdb/gdbtk/library/watch.tcl b/gdb/gdbtk/library/watch.tcl index d2fc3223b25..bd90b387bfa 100644 --- a/gdb/gdbtk/library/watch.tcl +++ b/gdb/gdbtk/library/watch.tcl @@ -1,5 +1,5 @@ # Watch window for Insight. -# Copyright 2002 Red Hat +# Copyright 2002, 2003 Red Hat # # 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 @@ -92,9 +92,9 @@ itcl::class WatchWin { 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 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 -- cgit v1.2.1