<html><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><div><div>On Apr 21, 2008, at 12:42 PM, Randy Heiland wrote:</div><br class="Apple-interchange-newline"><blockquote type="cite"><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; ">I was wondering if there's a dialog in the gui code that has built-in <span class="Apple-converted-space"> </span></div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; ">sliders?<span class="Apple-converted-space"> </span>E.g., currently our extension module subclasses <span class="Apple-converted-space"> </span></div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; ">ModelessDialog; however, our input panel has so many values that it <span class="Apple-converted-space"> </span></div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; ">would be convenient if it was embedded in a widget such that sliders <span class="Apple-converted-space"> </span></div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; ">appeared when it was resized smaller.</div></blockquote><br></div><div>Hi Randy,</div><div><span class="Apple-tab-span" style="white-space:pre"> </span>Not directly. One possibility is to use Pmw.ScrolledFrame (<a href="http://pmw.sourceforge.net/doc/ScrolledFrame.html">http://pmw.sourceforge.net/doc/ScrolledFrame.html</a>) as the parent widget for the contents of your dialog. Take the frame you get as an arg to the fillInUI() method and immediately create a Pmw.ScrolledFrame with that frame as the parent. Then fill your dialog in from the frame you get from Pmw.ScrolledFrame.interior(). You can do this almost painlessly like so:</div><div><br></div><div><span class="Apple-tab-span" style="white-space:pre"> </span>def fillInUI(self, parent):<br></div><div><span class="Apple-tab-span" style="white-space:pre"> </span>sf = Pmw.ScrolledFrame(parent)<br></div><div><span class="Apple-tab-span" style="white-space:pre"> </span>sf.grid(sticky="nsew")<br></div><div><span class="Apple-tab-span" style="white-space:pre"> </span>origParent, parent = parent, sf.interior()<br></div><div><span class="Apple-tab-span" style="white-space:pre"> </span># remainder of fillInUI() remains the same...<br></div><div><br></div><div><span class="Apple-tab-span" style="white-space:pre"> </span>Another possibility is to use the Feature_Buttons_Panel widget from Chimera's CGLtk.Hybrid module. This is what Volume Viewer uses to hide/show sections of its interface. You'd have to look at the Volume Viewer code to see how it's called since I haven't used it myself.<br></div><div><br></div><div>--Eric</div><div><br></div><div><div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "><font face="Helvetica" size="5" style="font: normal normal normal 16px/normal Helvetica; "> Eric Pettersen</font></div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "><font face="Helvetica" size="5" style="font: normal normal normal 16px/normal Helvetica; "> UCSF Computer Graphics Lab</font></div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "><font face="Helvetica" size="5" style="font: normal normal normal 16px/normal Helvetica; "> <a href="http://www.cgl.ucsf.edu">http://www.cgl.ucsf.edu</a></font></div></div><br><div></div></div></body></html>