spostati i file di configurazione, da fare la gestione finestra di
output per scegliere la lingua
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
{
|
||||
"italiano": {
|
||||
"Italiano": {
|
||||
"dateWords": [
|
||||
"Gennaio",
|
||||
"Febbraio",
|
||||
@@ -36,7 +36,7 @@
|
||||
"JOURNAL-CODE:"
|
||||
]
|
||||
},
|
||||
"english": {
|
||||
"English": {
|
||||
"dateWords": [
|
||||
"January",
|
||||
"February",
|
||||
@@ -1,7 +1,7 @@
|
||||
{
|
||||
"version": "v1.1a",
|
||||
"paths": {
|
||||
"lastUsed": "D:/Emanuele/Documenti/workspace/bananaSPLIT/bananaSPLIT/libbananasplit/presettone.json",
|
||||
"lastUsed": "presettone.json",
|
||||
"configurationPath": "D:\\Emanuele\\Documenti\\workspace\\bananaSPLIT\\",
|
||||
"INworkPath": "D:/Emanuele/Desktop",
|
||||
"OUTworkPath": "D:/Emanuele/Desktop"
|
||||
@@ -12,7 +12,7 @@
|
||||
"dateFormat": "{month} {day:d}, {year:d}{}",
|
||||
"outPrefix": "123",
|
||||
"outSuffix": "456",
|
||||
"outDateType": "usa",
|
||||
"outDateType": "jpn",
|
||||
"outNameFormat": "",
|
||||
"outDate": true,
|
||||
"outNumber": true,
|
||||
@@ -27,11 +27,12 @@ class bananaMain(PyQt5.QtWidgets.QMainWindow):
|
||||
def __init__(self):
|
||||
PyQt5.QtWidgets.QMainWindow.__init__(self)
|
||||
try:
|
||||
self.logger = fancyLogger(filepath=r"./libbananasplit/loggerconf.json",fileLog=False)
|
||||
self.conf = bananaCONF(workdir=r"./libbananasplit", logger=self.logger)
|
||||
self.logger = fancyLogger(filepath=r"./conf/loggerconf.json",fileLog=False)
|
||||
self.conf = bananaCONF(workdir=r"./conf", logger=self.logger)
|
||||
self.conf.open()
|
||||
self.conf.use("defaults.json")
|
||||
self.conf.use(self.conf.getParam('paths', 'lastUsed'))
|
||||
print(self.conf.inUse)
|
||||
except:
|
||||
sys.exit()
|
||||
|
||||
@@ -119,7 +120,7 @@ class bananaMain(PyQt5.QtWidgets.QMainWindow):
|
||||
sf.setAcceptMode(PyQt5.QtWidgets.QFileDialog.AcceptSave)
|
||||
sf.setNameFilter("bananaCONF (*.json)")
|
||||
if sf.exec():
|
||||
rv=str(sf.selectedFiles()[0])
|
||||
rv=str(sf.selectedFiles()[0].split('/')[-1])
|
||||
self.conf.setParam(('paths','lastUsed'),rv)
|
||||
self.logger.debug("Scrivi il File: {}".format(rv))
|
||||
self.conf.save(fName=rv)
|
||||
|
||||
Reference in New Issue
Block a user