Comments (7)
It has nothing to do with pyglet.
I have the same problem without using pyglet. Try just using tkinter, os and customtkinter and the problem is still there
This happened after I updated my customtkinter to latest version.
from customtkinter.
What OS are you using and how are you creating the askdirectory? I will look into this tomorrow...
from customtkinter.
I'm on Windows 10 Home
this is a cleaned up version of my code
from tkinter.constants import CENTER, LEFT
import tkinter
import tkinter.messagebox
from tkinter import filedialog as fd
import customtkinter # <- import the CustomTkinter module
import os
class App(customtkinter.CTk):
customtkinter.set_appearance_mode("dark")
APP_NAME = "Bulk Barcode Generator"
WIDTH = 600
HEIGHT = 450
MAIN_COLOR = "#5ea886"
MAIN_COLOR_DARK = "#2D5862"
MAIN_HOVER = "#05f4b7"
def __init__(self, *args, **kwargs):
super().__init__(*args, **kwargs)
self.title(App.APP_NAME)
self.geometry(str(App.WIDTH) + "x" + str(App.HEIGHT))
self.minsize(App.WIDTH, App.HEIGHT)
self.protocol("WM_DELETE_WINDOW", self.on_closing)
# ============ create two CTkFrames ============
#1
self.frame_left = customtkinter.CTkFrame(master=self,
width=220,
height=App.HEIGHT-40,
corner_radius=5)
self.frame_left.place(relx=0.38, rely=0.5, anchor=tkinter.E)
#2
self.frame_right = customtkinter.CTkFrame(master=self,
width=350,
height=App.HEIGHT-40,
corner_radius=5)
self.frame_right.place(relx=0.40, rely=0.5, anchor=tkinter.W)
# # ============ frame_right ============
self.button_output = customtkinter.CTkButton(master=self.frame_right, border_color=App.MAIN_COLOR,
fg_color=None, hover_color=App.MAIN_HOVER,
height=28, text="Output Folder", command=self.button_outputFunc,
border_width=3, corner_radius=10, text_font=('Calibri',16))
self.button_output.place(relx=0.05, rely=0.06, anchor=tkinter.NW)
self.entry_output = customtkinter.CTkEntry(master=self.frame_right, width=320, height=38, corner_radius=5)
self.entry_output.place(relx=0.05, rely=0.18, anchor=tkinter.NW)
def button_outputFunc(self):
self.entry_output.delete(0, 'end')
filename = fd.askdirectory()
self.entry_output.insert(0,str(filename))
pass
def on_closing(self, event=0):
self.destroy()
def start(self):
self.mainloop()
if __name__ == "__main__":
app = App()
app.start()
edit: no idea how to add code block
from customtkinter.
@h4xw4r I am not actually using pyglet, I said that because customtkinter itself is using it.
I am on Windows 10 Home also.
from customtkinter.
@ertucode My bad, you are right İ come realize that later.
from customtkinter.
I don't know what exactly is causing the problem, but now I removed pyglet from CustomTkinter and the dialogs should work fine. I uploaded version 3.9 to pip, maybe you can report if it's now working for you, or if there are any errors. Because now I load the necessary fonts with a custom function, which was done by pyglet before. And I only tested it on two Windows machines (Windows 10, 11).
from customtkinter.
Thanks a lot, works just fine now.
from customtkinter.
Related Issues (20)
- Button Not Appearing HOT 1
- Unable to run examples: segmentation fault
- Bind "Enter Key" to button does not work HOT 4
- Switch does not go to the required position HOT 1
- ctk.CTk().state("zoomed") doesn't work HOT 1
- Invoking .geometry(), .winfo_height() or .winfo_width() on a window always returns 200 HOT 7
- Transparent Window HOT 2
- How to allow windows to overlap though it is topmost window like widgets? HOT 6
- focus_set() does not work HOT 1
- install CustomTkinter with conda HOT 1
- Image Button Transparent Borders HOT 10
- ctk.CTkComboBox changing states takes longer for every time state has been changed
- Label is not getting added inside ScrollableFrame! HOT 9
- How to init my class for using _set_appearence_mode? HOT 1
- doesnt properly show unicode icons HOT 2
- CTkComboBox & CTkOptionMenu second click to close the dropdown HOT 1
- iconphoto is not working HOT 3
- Vertical scroll bar does not work at all HOT 1
- Adjustable Frames HOT 2
- Line numbers for CTkTextBox HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from customtkinter.