Skip to content

Commit

Permalink
EXE and ico
Browse files Browse the repository at this point in the history
  • Loading branch information
fabfab1 committed Mar 7, 2024
1 parent 053b857 commit cbeb78e
Show file tree
Hide file tree
Showing 9 changed files with 5,630 additions and 5,608 deletions.
16 changes: 13 additions & 3 deletions Irfanview_DPI_list.py
Original file line number Diff line number Diff line change
Expand Up @@ -527,14 +527,23 @@ def choose_fig_directories():
root = tk.Tk()
root.title("Irfanview DPI Spreadsheet")
root.geometry("600x250")
root.iconbitmap('icon\IrfanXcel.ico')

# Icon
if getattr(sys, 'frozen', False):
script_dir = sys._MEIPASS
else:
script_dir = os.path.dirname(os.path.realpath(__file__))
icon_path = os.path.join(script_dir, 'icon', 'IrfanXcel.ico')
root.iconbitmap(icon_path)

# Styles
style = ttk.Style()
style.configure("BW.TLabel", foreground="#164194", font=("Arial", 25, "bold"))

style = ttk.Style()
style.configure("BW.TButton", font=("default", 14))

# Widgets
label = ttk.Label(root, text="Irfanview DPI Spreadsheet", style="BW.TLabel")
label.pack(pady=10)

Expand All @@ -551,5 +560,6 @@ def choose_fig_directories():

root.mainloop()

# TODO note for me on how to use pyinstaller. From terminal:
# pyinstaller --onefile --clean --noconsole --icon=icon\IrfanXcel.ico Irfanview_DPI_list.py
# note for me on how to use pyinstaller. From terminal:
# pyinstaller --onefile --clean --noconsole Irfanview_DPI_list.py
# pyinstaller --onefile --clean --noconsole --icon=icon/IrfanXcel.ico --add-data "icon/IrfanXcel.ico;icon/" Irfanview_DPI_list.py
3 changes: 2 additions & 1 deletion Irfanview_DPI_list.spec
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ a = Analysis(
['Irfanview_DPI_list.py'],
pathex=[],
binaries=[],
datas=[],
datas=[('icon/IrfanXcel.ico', 'icon/')],
hiddenimports=[],
hookspath=[],
hooksconfig={},
Expand Down Expand Up @@ -34,4 +34,5 @@ exe = EXE(
target_arch=None,
codesign_identity=None,
entitlements_file=None,
icon=['icon\\IrfanXcel.ico'],
)
3,743 changes: 1,874 additions & 1,869 deletions build/Irfanview_DPI_list/Analysis-00.toc

Large diffs are not rendered by default.

3,731 changes: 1,867 additions & 1,864 deletions build/Irfanview_DPI_list/EXE-00.toc

Large diffs are not rendered by default.

Binary file modified build/Irfanview_DPI_list/Irfanview_DPI_list.pkg
Binary file not shown.
3,727 changes: 1,865 additions & 1,862 deletions build/Irfanview_DPI_list/PKG-00.toc

Large diffs are not rendered by default.

6 changes: 3 additions & 3 deletions build/Irfanview_DPI_list/warn-Irfanview_DPI_list.txt
Original file line number Diff line number Diff line change
Expand Up @@ -15,12 +15,12 @@ IMPORTANT: Do NOT post this list to the issue-tracker. Use it as a basis for
tracking down the missing module yourself. Thanks!

missing module named pyimod02_importers - imported by C:\Users\fAB\PycharmProjects\Irfanview_DPI_list\venv\Lib\site-packages\PyInstaller\hooks\rthooks\pyi_rth_pkgutil.py (delayed), C:\Users\fAB\PycharmProjects\Irfanview_DPI_list\venv\Lib\site-packages\PyInstaller\hooks\rthooks\pyi_rth_pkgres.py (delayed)
missing module named 'org.python' - imported by copy (optional), xml.sax (delayed, conditional)
missing module named org - imported by pickle (optional)
missing module named org - imported by copy (optional)
missing module named 'org.python' - imported by pickle (optional), xml.sax (delayed, conditional)
missing module named typing_extensions - imported by urllib3._collections (conditional), setuptools.config._validate_pyproject.formats (conditional), setuptools.command.build (conditional), packaging.metadata (conditional, optional)
missing module named pwd - imported by posixpath (delayed, conditional, optional), shutil (delayed, optional), tarfile (optional), pathlib (delayed, optional), subprocess (delayed, conditional, optional), netrc (delayed, conditional), getpass (delayed), distutils.util (delayed, conditional, optional), distutils.archive_util (optional), http.server (delayed, optional), webbrowser (delayed), setuptools._distutils.util (delayed, conditional, optional), setuptools._distutils.archive_util (optional)
missing module named grp - imported by shutil (delayed, optional), tarfile (optional), pathlib (delayed, optional), subprocess (delayed, conditional, optional), distutils.archive_util (optional), setuptools._distutils.archive_util (optional)
missing module named posix - imported by posixpath (optional), shutil (conditional), importlib._bootstrap_external (conditional), os (conditional, optional)
missing module named posix - imported by os (conditional, optional), shutil (conditional), importlib._bootstrap_external (conditional), posixpath (optional)
missing module named resource - imported by posix (top-level)
missing module named _manylinux - imported by packaging._manylinux (delayed, optional), setuptools._vendor.packaging._manylinux (delayed, optional), pkg_resources._vendor.packaging._manylinux (delayed, optional)
missing module named jnius - imported by pkg_resources._vendor.platformdirs.android (delayed, optional)
Expand Down
12 changes: 6 additions & 6 deletions build/Irfanview_DPI_list/xref-Irfanview_DPI_list.html
Original file line number Diff line number Diff line change
Expand Up @@ -395,7 +395,7 @@ <h1>modulegraph cross reference for Irfanview_DPI_list.py, pyi_rth__tkinter.py,
<a target="code" href="" type="text/plain"><tt>'org.python'</tt></a>
<span class="moduletype">MissingModule</span> <div class="import">
imported by:
<a href="#copy">copy</a>
<a href="#pickle">pickle</a>
&#8226; <a href="#xml.sax">xml.sax</a>

</div>
Expand Down Expand Up @@ -3815,8 +3815,8 @@ <h1>modulegraph cross reference for Irfanview_DPI_list.py, pyi_rth__tkinter.py,
<a target="code" href="///C:/Program%20Files/Python/Lib/copy.py" type="text/plain"><tt>copy</tt></a>
<span class="moduletype">SourceModule</span> <div class="import">
imports:
<a href="#'org.python'">'org.python'</a>
&#8226; <a href="#copyreg">copyreg</a>
<a href="#copyreg">copyreg</a>
&#8226; <a href="#org">org</a>
&#8226; <a href="#types">types</a>
&#8226; <a href="#weakref">weakref</a>

Expand Down Expand Up @@ -15901,7 +15901,7 @@ <h1>modulegraph cross reference for Irfanview_DPI_list.py, pyi_rth__tkinter.py,
<a target="code" href="" type="text/plain"><tt>org</tt></a>
<span class="moduletype">MissingModule</span> <div class="import">
imported by:
<a href="#pickle">pickle</a>
<a href="#copy">copy</a>

</div>

Expand Down Expand Up @@ -16562,14 +16562,14 @@ <h1>modulegraph cross reference for Irfanview_DPI_list.py, pyi_rth__tkinter.py,
<a target="code" href="///C:/Program%20Files/Python/Lib/pickle.py" type="text/plain"><tt>pickle</tt></a>
<span class="moduletype">SourceModule</span> <div class="import">
imports:
<a href="#_compat_pickle">_compat_pickle</a>
<a href="#'org.python'">'org.python'</a>
&#8226; <a href="#_compat_pickle">_compat_pickle</a>
&#8226; <a href="#_pickle">_pickle</a>
&#8226; <a href="#codecs">codecs</a>
&#8226; <a href="#copyreg">copyreg</a>
&#8226; <a href="#functools">functools</a>
&#8226; <a href="#io">io</a>
&#8226; <a href="#itertools">itertools</a>
&#8226; <a href="#org">org</a>
&#8226; <a href="#pprint">pprint</a>
&#8226; <a href="#re">re</a>
&#8226; <a href="#struct">struct</a>
Expand Down
Binary file modified dist/Irfanview_DPI_list.exe
Binary file not shown.

0 comments on commit cbeb78e

Please sign in to comment.