fantastic idea with the callback - works great!

many thanks
JRAB

On 09/10/2013 04:27 AM, Ben Dickson wrote:
I'm pretty sure I've had this happen on OS X too, but only when the node's properties was a floating window (i.e the Properties Bin was closed).. Will try to extract the code that caused this into a simple test-case

As for reopening the panel, that looks like another bug worth reporting.. Here is a workaround, which hides the panel and re-opens it in an updateUI callback:

thisNode = nuke.thisNode()
k = nuke.Text_Knob('foo', 'foo')
thisNode.addKnob(k)
thisNode.removeKnob(k)

n.hideControlPanel()
def showPanel():
    n.showControlPanel()
    nuke.callbacks.removeUpdateUI(showPanel)

nuke.callbacks.addUpdateUI(showPanel)


On 07/09/13 04:14, John RA Benson wrote:
thanks!

seems to be a linux thing. I just tried my test node on osx and it works fine.

calling node.showControlPanel() from within the node is something different, but if it worked to re-open the panel, at least I'd have a workaround. It does the same in osx and linux - nothing.

thoughts?
JRAB


On Sep 6, 2013, at 7:28 PM, Nathan Rusch<[email protected]> wrote:

Ha. I actually just reported this issue the other day. From what I can tell, it has to do with knobs being reorganized or reordered without giving Nuke a chance to redraw their widgets. As you say, it's pretty much harmless, as all the widgets are still connected to the same back-end knob, but annoying nonetheless.

I'll follow up on here when I have a bug ID.

-Nathan


-----Original Message----- From: John RA Benson
Sent: Friday, September 06, 2013 10:15 AM
To: Nuke Python discussion
Subject: [Nuke-python] multiple panels inside a panel problem

Does anyone have a fix for this problem:

set cut_paste_input [stack 0]
version 7.0 v8
push $cut_paste_input
NoOp {
name NoOp25
selected true
xpos -497
ypos -19511
addUserKnob {20 tests}
addUserKnob {22 reload T "thisNode = nuke.thisNode()\nk =
nuke.Text_Knob('foo',
'foo')\nthisNode.addKnob(k)\nthisNode.removeKnob(k)\n" +STARTLINE}
addUserKnob {22 reloadCloseAndReopen l "reload, Close and Reopen" T
"thisNode = nuke.thisNode()\nk = nuke.Text_Knob('foo',
'foo')\nthisNode.addKnob(k)\nthisNode.removeKnob(k)\n\nthisNode.hideControlPanel()\nthisNode.showControlPanel()"
+STARTLINE}
}

Press the 'reload' button in the noop. I'm just adding a knob, and then
removing it.
Basically, if you have a knob that you want to remove and do so, the
properties panel adds to itself. Each time you run it, it stacks up.
Doesn't appear to be a problem, but it's really annoying, since you have
to close the panel and re-open it to normalize it again.

Speaking of opening and closing, is it normal to not be able to open the
panel with node.showControlPanel() from within a script called by the
node? Do I need to do some context thing to get it to open?

thanks
JRAB
_______________________________________________
Nuke-python mailing list
[email protected], http://forums.thefoundry.co.uk/
http://support.thefoundry.co.uk/cgi-bin/mailman/listinfo/nuke-python
_______________________________________________
Nuke-python mailing list
[email protected], http://forums.thefoundry.co.uk/
http://support.thefoundry.co.uk/cgi-bin/mailman/listinfo/nuke-python

_______________________________________________
Nuke-python mailing list
[email protected], http://forums.thefoundry.co.uk/
http://support.thefoundry.co.uk/cgi-bin/mailman/listinfo/nuke-python


_______________________________________________
Nuke-python mailing list
[email protected], http://forums.thefoundry.co.uk/
http://support.thefoundry.co.uk/cgi-bin/mailman/listinfo/nuke-python

Reply via email to