Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixed OS language issue in setlocale function #511

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

ErtungaYusuf
Copy link

@ErtungaYusuf ErtungaYusuf commented Dec 4, 2023

Hey,

I couldnt manage the use module and after some research I saw a bug that occurs in people with different os languages. I also found that there is an open issue about this (#505)
After a bit working I fixed the issue by getting os language with ctypes module and placing it.

@mmebsout
Copy link

This doesn't work on OSX

Traceback (most recent call last):
  File "/test.py", line 11, in <module>
    import ttkbootstrap as tb
  File "venv/lib/python3.10/site-packages/ttkbootstrap/__init__.py", line 3, in <module>
    from ttkbootstrap.widgets import *
  File "venv/lib/python3.10/site-packages/ttkbootstrap/widgets.py", line 14, in <module>
    from ttkbootstrap.dialogs import Querybox
  File "/venv/lib/python3.10/site-packages/ttkbootstrap/dialogs/__init__.py", line 1, in <module>
    from ttkbootstrap.dialogs.dialogs import *
  File "venv/lib/python3.10/site-packages/ttkbootstrap/dialogs/dialogs.py", line 536, in <module>
    class DatePickerDialog:
  File "=venv/lib/python3.10/site-packages/ttkbootstrap/dialogs/dialogs.py", line 566, in DatePickerDialog
    windll = ctypes.windll.kernel32
AttributeError: module 'ctypes' has no attribute 'windll'

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants