fbpx

CS-Lab Support Forum for CNC Community

Help to run this brand-new forum and stay with us.
Ask your questions, we are here to help! 

 

Please or Register to create posts and topics.

3.5 beta 4 issue with Py msg object

Hi everyone,

Since I upgraded to 3.5 beta 4, messages set with msg object from Py are placed behind the simCNC main window. At first I thought my scripts were failing, but found the message box hiding... Screenshot attached.

Running on W10 22H2 built 19045.2965

Thanks for checking!

André

PS: Do you have any ticketing portal for reporting bugs in a more structured way?

Uploaded files:
  • 2023-06-06-16_35_00-simCNC™-Python-Script-Editor.png

We are aware of this issue and it is already reported as the ticket number #510.
The reporting system functions but as an internal one due to the fact that the reports must be sorted into true and false before being registered.

andre has reacted to this post.
andre

Interestingly, the issue got solved for python msg but now tkinter shows a weird behavior.

Tkinter will open 2 windows, one blank and one with the actual UI called. Both are behind the simCNC window. See screenshot for reference.

Regards,
André

Code:

import tkinter as tk
from tkinter.simpledialog import askinteger
root = tk.Tk()
toolID = askinteger("Tool number", f"T#")
toolID = int(toolID)
d.executeGCode( f"M6 T{toolID}" )
root.mainloop()

System:

  • simCNC 3.500 beta 6 build 2023-06-23 15:19:17
  • W10 22H2 built 19045.2965
Uploaded files:
  • 2023-07-08-12_40_20-simCNC™.png

PS:
root.attributes("-topmost", True) works, but still gives a 2nd window which is on top of my UI (screenshot).

If I add root.withdraw() on root it is removing the 2nd window but then the UI again is set behind the simCNC window.

Uploaded files:
  • 2023-07-08-12_46_02-simCNC™.png
CS-Lab Support has reacted to this post.
CS-Lab Support

I have a great example for you that uses:
- "window.attributes('-topmost', True)" which makes the window always on top
- "lambda" which allows you to use the popup as a regular feature

DOWNLOAD:

input-box.zip

Edited:

I forgot to add that this macro sets machine parameter to 100.

Thank you very much, works perfectly fine with the most current v3.5

Best regards,
André

 

PS: My parents tought me not to take code from strangers 😉  Will always check what the code does before executing it.

PARTNERS:

 

USA

Germany

Slovenia / Bosnia

Spain

South Africa

UNI-CAM

The Netherlands

Portugal

Greece

  Distrib milionis logo

Hungary

Distrib logot

Bulgaria

Master

Kenya

Proteq Automation

Egypt

Germanelectronix

China

Jun Ma

Serbia

ALCO

Italy

LVL tech r

Denmark

Varntoft Dania

Finland

×

Hello!

Click one of our contacts below to chat on WhatsApp

× How can I help you?