public inbox for insight@sourceware.org
 help / color / mirror / Atom feed
* [patch] Remove CygScrolledListbox
@ 2002-11-07 21:27 Martin M. Hunt
  0 siblings, 0 replies; only message in thread
From: Martin M. Hunt @ 2002-11-07 21:27 UTC (permalink / raw)
  To: insight

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

Remove an old scrolledlistbox function. Add some minor improvements.

2002-11-07  Martin M. Hunt  <hunt@redhat.com>

	* library/util.tcl (CygScrolledListbox): Delete.

	* library/srctextwin.itb: Change from CygScrolledListbox
	to iwidgets::scrolledlistbox. Set foreground and background.
	Center popup over source window.






[-- Attachment #2: p --]
[-- Type: text/x-patch, Size: 2549 bytes --]

Index: srctextwin.itb
===================================================================
RCS file: /cvs/src/src/gdb/gdbtk/library/srctextwin.itb,v
retrieving revision 1.38
diff -p -r1.38 srctextwin.itb
*** srctextwin.itb	15 Oct 2002 21:19:51 -0000	1.38
--- srctextwin.itb	8 Nov 2002 05:22:10 -0000
*************** itcl::body SrcTextWin::ask_thread_bp {} 
*** 2822,2829 ****
    
    set a [toplevel .[gensym]]
    wm title $a "Thread Selection"
!   CygScrolledListbox $a.slb -selectmode multiple -height $num_threads
!   
    set i [expr $num_threads - 1]
    set width 0
    foreach line $threads {
--- 2822,2832 ----
    
    set a [toplevel .[gensym]]
    wm title $a "Thread Selection"
! 
!   iwidgets::scrolledlistbox $a.slb \
!     -vscrollmode dynamic -hscrollmode dynamic \
!     -selectmode multiple -textfont global/fixed
! 
    set i [expr $num_threads - 1]
    set width 0
    foreach line $threads {
*************** itcl::body SrcTextWin::ask_thread_bp {} 
*** 2837,2855 ****
        if {[string length $line] > $width} {
  	set width [string length $line]
        }
!       $a.slb.list insert 0 $line 
        incr i -1
      }
    }
!   $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.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
    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
--- 2840,2860 ----
        if {[string length $line] > $width} {
  	set width [string length $line]
        }
!       $a.slb 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)
  
    frame $a.b
    button $a.b.ok -text OK -underline 0 -width 7 \
!     -command "$this do_thread_bp $a.slb"
    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

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2002-11-08  5:27 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-11-07 21:27 [patch] Remove CygScrolledListbox Martin M. Hunt

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).