7

I tried to open a new window at the same position as another window.

My Code:

window2.set_position(window1.get_position())

But it doesn't work.

Jake1164
  • 12,291
  • 6
  • 47
  • 64
MarcoQu
  • 73
  • 1
  • 3

1 Answers1

8

set_position just sets a general hint (e.g. center the window). You need the move method:

window2.move(pos_x, pos_y)

see here: http://faq.pygtk.org/index.py?req=show&file=faq10.003.htp

l4mpi
  • 5,103
  • 3
  • 34
  • 54