【发布时间】:2014-11-13 02:37:29
【问题描述】:
我正在一个带有视网膜显示屏的 macbook pro 上构建一个 pyside 应用程序,这是我的设置文件:
import sys
from cx_Freeze import setup, Executable
# Dependencies are automatically detected, but it might need fine tuning.
build_exe_options = {"packages": ["os", "sys", "PySide", "datetime", "subprocess"], "excludes": ["tkinter"]}
# GUI applications require a different base on Windows (the default is for a
# console application).
base = None
if sys.platform == "win32":
base = "Win32GUI"
options = {
'build_exe': {
'includes': 'atexit'
}
}
executables = [
Executable('countdown.py', base=base)
]
setup( name = "Countdown",
version = "0.1",
description = "Countdown timer",
options = options,
executables = executables)
然后我构建了我的应用程序:
python3.3 setup.py bdist_mac
countdown_0.1.app 运行正常,只是 gui 有点模糊:
与直接执行 countdown.py 相比:
我想知道为什么它们看起来如此不同?
【问题讨论】:
-
这很奇怪。应用程序包中必须有一些元数据来控制它。
标签: python macos qt pyside cx-freeze