©2003 Kåre Sjölander and Jonas Beskow
Introduction Download Documentation Links Forum
WaveSurfer user forum

FAQ  FAQ
Search  Search
Memberlist  Memberlist
Register  Register
Profile  Profile
Login  Login

Moving the wavebar to the top of the Wsurf widget

 
Post new topic   Reply to topic    www.speech.kth.se/wavesurfer Forum Index -> WaveSurfer
View previous topic :: View next topic  
Author Message
mickel



Joined: 17 Dec 2002
Posts: 28
Location: Espoo, Finland

PostPosted: Fri Aug 29, 2003 10:29 am    Post subject: Moving the wavebar to the top of the Wsurf widget Reply with quote

When playing around with different configurations to Wsurf, it seems the wavebar is not a configurable item. At first I wanted to remove it altoghether, but now I have another question:

How do I get the wavebar to be in the very top of the Wsurf widget? I was browsing around the wavebar.tcl code, but as I'm not really a TCL coder, I couldn't figure out what to do. Basically, I would not want to change the TCL code, but rather configure the widget later on in such a way that the wavebar moves from the bottom of the widget to the top. Any ideas?

I'm using the Wsurf widget from Python (which should not matter in this case).

Cheers,

/Mickel
Back to top
View users profile Send private message Visit posters website
Guest






PostPosted: Tue Sep 02, 2003 3:58 pm    Post subject: Reply with quote

Tricky one! As you noticed, the wavebar placement is not part of the standard configuration options, we always assumed bottom of widget...

However, here is an ugly proc that does what you want to an already created widget...

proc moveWavebarToTop {widget} {
set wavebar $widget.workspace.wavebar
set firstpane [lindex [$widget _getPanes] 0]
pack forget $wavebar
destroy ${wavebar}_handle
destroy ${wavebar}.bar
pack $wavebar -before $firstpane \
-expand 0 -fill both
pack propagate $wavebar 0
resizer::addResizer $wavebar \
-type divider -height 4 \
-minheight 10 -maxheight 300
}

# Then, in your main script or in a conf-file:

moveWavebarToTop$widget

-jonas
Back to top
Display posts from previous:   
Post new topic   Reply to topic    www.speech.kth.se/wavesurfer Forum Index -> WaveSurfer All times are GMT + 1 Hour
Page 1 of 1

 
Jump to:  
You can post new topics in this forum
You can reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB 2.0.1 © 2001, 2002 phpBB Group