Python Forum
[Tkinter] Combobox dropbox appear top left screen corner
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
[Tkinter] Combobox dropbox appear top left screen corner
#11
This was a misunderstanding.
from your first post, should have looked at the image, (As a rule I skip over links, as they can be malicious, post inline to avoid this, as it's OK to post images that are not code). My understanding was completely different from what you were asking.
What I provided was code that will allow your python 'window' to move anywhere on the screen. Moving part of a tkinter widget wasn't even in my thoughts. Using GUI terms will help in future posts.
That is bizarre behaviour, and I think may be related to MS operating system (which I don't use)
Reply
#12
how are you running the script? try and run in it from the command prompt or terminal.
python3 your_script.py or python your_script.py . Your script is so short you could also run it in the terminal interactive prompt-I'm using linux but it's the same on MS
Python 3.7.3 (default, Apr  3 2019, 05:39:12) 
[GCC 8.2.0] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> from tkinter import Tk
>>> from tkinter import ttk
>>> root= Tk()
>>> combo= ttk.Combobox(root)
>>> combo['values']= (1,2,3,4,5)
>>> combo.current(2)
''
>>> combo.grid(column=0,row=0)
>>> 
drag the window, report back
Reply
#13
Hi joe_momma,
When i run the script normaly i only run python my_script.py. Remember this is the simpless script i created to reproduce the issue, but normally this is a complete debug tool for our internal debug in our design departement. And all the dropdown list behave the same.

This time I run the script from the python shell ad here is the output.
Python 3.7.7 (tags/v3.7.7:d7c567b08f, Mar 10 2020, 10:41:24) [MSC v.1900 64 bit (AMD64)] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>> from tkinter import *
>>> from tkinter.ttk import *
>>>
>>> window = Tk()
>>> window.title("ComboBox list down test")
''
>>> window.geometry('350x200')
''
>>> combo = Combobox(window)
>>> combo['values']= (1, 2, 3, 4, 5, "Text")
>>> combo.current(1) #set the selected item
''
>>> combo.grid(column=0, row=0)
>>>
There is no error or message....
Reply
#14
I google around the same issue without tkinter and it can be releated to WPF (.net framework) in windows where a dropdown list appear at 0,0 position, this is what append to me on certain computer and not on other into our departement.

I put a link to stack overflow that look the same issue.
https://stackoverflow.com/questions/3012...the-screen
Reply
#15
Please don't use acronyms. Many on the Forum haven't touched a MS windows OS machine in years therefore not familiar with WPF or any other self proclaimed world solution.
Reply
#16
So no OOP or GUI? It is not like WPF is obscure.
Reply
#17
in reference to deanhystad
Quote:So no OOP or GUI? It is not like WPF is obscure.
OK, I should have qualified my statement.
OOP and GUI are not as obscure. They have same meaning across any OS.
WPF refers specifically to MS platform (as stated).
Please read: https://python-forum.io/misc.php?action=help&hid=21
Quote:Text Talk/Acroynms. Leave out the text talk. atm (at the moment), IIRC (if i recall correctly). Stop assuming everyone knows what it means. You are on a forum, not texting your girlfriend. Dont type things like "can u plz". It looks like you do not give us the time to type properly. why should we give you our time?
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  [PyQt] How can I sync Combobox index to other combobox index? nickzsche 2 2,333 Jan-03-2022, 12:29 PM
Last Post: Axel_Erfurt

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020