Skip to content
This repository has been archived by the owner on Sep 6, 2024. It is now read-only.

Commit

Permalink
Fancy splash screen
Browse files Browse the repository at this point in the history
  • Loading branch information
LP-CDF committed Jun 16, 2020
1 parent b70e4b6 commit 6457dcd
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 7 deletions.
21 changes: 15 additions & 6 deletions AMi_Image_Analysis.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
from PyQt5.QtGui import QPixmap, QFont, QColor, QKeySequence
QtWidgets.QApplication.setAttribute(QtCore.Qt.AA_EnableHighDpiScaling, True) #enable highdpi scaling
QtWidgets.QApplication.setAttribute(QtCore.Qt.AA_UseHighDpiPixmaps, True) #use highdpi icons
from PyQt5.QtWidgets import (QLabel, QTableWidgetItem, QFileDialog,
from PyQt5.QtWidgets import (QLabel, QTableWidgetItem, QFileDialog, QSplashScreen,
QMessageBox, QGridLayout,QStyleFactory, QProgressDialog, QInputDialog, QLineEdit)

from utils import ensure_directory
Expand All @@ -29,12 +29,11 @@
import Merge_Zstack
import ReadScreen
import preferences as pref
import cv2


__version__ = "1.2.2"
__author__ = "Ludovic Pecqueur (ludovic.pecqueur \at college-de-france.fr)"
__date__ = "25-05-2020"
__date__ = "16-06-2020"
__license__ = "New BSD http://www.opensource.org/licenses/bsd-license.php"


Expand Down Expand Up @@ -66,8 +65,9 @@ def Citation():
class ViewerModule(QtWidgets.QMainWindow, Ui_MainWindow):
def __init__(self, parent=None):
super(ViewerModule, self).__init__(parent)
# self.app_path=os.path.abspath(os.path.dirname(sys.argv[0]))
self.app_path=os.path.abspath(os.path.dirname(sys.argv[0]))
# print("self.app_path ", self.app_path)
self.SplashScreen(2500)
self.ui=Ui_MainWindow()
self.setupUi(self)
self.setWindowTitle("LCPB AMi Image Analysis version %s"%__version__)
Expand Down Expand Up @@ -114,6 +114,14 @@ def __init__(self, parent=None):

self.initUI()

def SplashScreen(self, ms):
'''ms is the time in ms to show splash screen'''
_image=Path(self.app_path).joinpath("SplashScreen.png")
self.splash=QSplashScreen(QPixmap(str(_image)))
self.splash.show()
QtCore.QTimer.singleShot(ms, self.splash.close)


def initUI(self):

self.MaxCol=6
Expand Down Expand Up @@ -476,9 +484,10 @@ def ShowShortcuts(self):

def ShowAbout(self):
about=QMessageBox()
text='''
text=f'''
AMi Image Analysis version {__version__}
Program written For Python 3 and PyQt5
written by:
by:
Ludovic Pecqueur
Chimie des Processus Biologiques
College de France
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ Images in Timeline can be clicked to load corresponding image in main viewing fr
autoMARCO windows can all be displayed at the same time (previously only a single window could be loaded)

2020/03/03
Merging Z-stacks can be done within AMI_Image_Analysis or command line using the script Merge_Zstack.py. It is done in python and is much faster than using Hugin.
Merging Z-stacks can be done within AMI_Image_Analysis or command line using the script Merge_Zstack.py. It is done in python using openCV and is much faster than using Hugin.

2020/05/20
Improved navigation with shortcuts: Now only visible wells through "Filter" option are selected.
Expand Down
Binary file added SplashScreen.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 6457dcd

Please sign in to comment.