4

Is there any other way to change window position without using:

from kivy.config import Config
Config.set('graphics', 'position', 'custom')
Config.set('graphics', 'left', 100)
Config.set('graphics', 'top',  100)

I don't want to use this because when i change the last parameter (100) with my property it doesn't work.

user
  • 5,370
  • 8
  • 47
  • 75
João Neto
  • 85
  • 1
  • 7

1 Answers1

8

It's possible with the current master branch that has this change.

Update: It's possible with the current Kivy stable version → 1.10.0.

With that you can access the Window.top and Window.left properties and change Window position at runtime as well as get the actual position of the Window. Without that change (e.g. version 1.9.1), there's no way how to do that.

Also, Config is basically for a single change before the application actually runs e.g. set the position to [0, 0] and the Window will display at that position after App().run(). Nothing more really.

Peter Badida
  • 11,310
  • 10
  • 44
  • 90