Skip to content

Commit

Permalink
fix: acons
Browse files Browse the repository at this point in the history
  • Loading branch information
jgirardet committed Aug 30, 2020
1 parent b647197 commit 0fee577
Show file tree
Hide file tree
Showing 12 changed files with 12 additions and 5 deletions.
7 changes: 4 additions & 3 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,16 +1,17 @@
[tool.briefcase]
project_name = "MyCartable"
bundle = "coding.cacahuete"
version = "0.9.2"
version = "0.9.3"
url = "https://github.com/jgirardet/MyCartable"
license = "GNU General Public License v3 (GPLv3)"
author = 'Jimmy Girardet'
author_email = "[email protected]"

[tool.briefcase.app.mycartable]
formal_name = "MyCartable"
description = "My first application"
#icon = "src/mycartable/resources/mycartable"
description = "L'école sur ordinateur, tout un un !!!"
icon = "src/data/icons/mycartable"
installer_icon = "src/data/icons/mycartable"
sources = ['src/mycartable']
requires = ['pyside2==5.15.0',
'pony>=0.7.11,<0.8',
Expand Down
Binary file removed src/data/icons/Icon.ico
Binary file not shown.
Binary file added src/data/icons/mycartable-128.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added src/data/icons/mycartable-16.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added src/data/icons/mycartable-256.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added src/data/icons/mycartable-32.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
File renamed without changes
Binary file added src/data/icons/mycartable-64.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
File renamed without changes.
Binary file added src/data/icons/mycartable.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
8 changes: 6 additions & 2 deletions src/mycartable/main.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import sys
from pathlib import Path

from PySide2.QtGui import QFont, QFontDatabase
from PySide2.QtGui import QFont, QFontDatabase, QIcon, QPixmap
from package import get_prod
from package.constantes import APPNAME, ORGNAME, BASE_FONT
from PySide2.QtCore import (
Expand All @@ -10,6 +10,7 @@
QSettings,
QCoreApplication,
QLocale,
QFile,
)

# from fbs_runtime.application_context.PySide2 import ApplicationContext
Expand Down Expand Up @@ -154,9 +155,12 @@ def main(filename=None):
# import qrc

engine = setup_qml(databaseObject, ui_manager)

# Manifestement l'acces au qrc n'est pas immediat apres creation de l'app
# donc on met tout ça un peu plus "loin"
app.setWindowIcon(QIcon(":/icons/mycartable.png"))
QFontDatabase.addApplicationFont(":/fonts/Verdana.ttf")
font = QFont(BASE_FONT, 12, QFont.Normal)
# font = QFont('Verdana', 12, QFont.Normal)
app.setFont(font)

# run the app
Expand Down
2 changes: 2 additions & 0 deletions src/qml.qrc
Original file line number Diff line number Diff line change
Expand Up @@ -97,6 +97,8 @@
</qresource>

<qresource prefix="/icons">
<file alias="mycartable.png">data/icons/mycartable.png</file>
<file alias="mycartable.ico">data/icons/mycartable.ico</file>
<file alias="ellipse">data/icons/base/pack/png/sphere.png</file>
<file alias="fillrect">data/icons/base/pack/png/fillrect.png</file>
<file alias="newTextSection">data/icons/base/divers/png/003-edit.png</file>
Expand Down

0 comments on commit 0fee577

Please sign in to comment.