From da31187aa3b56e48671020703b51c2a5f7ee38f7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Du=C5=A1an=20Poizl?= Date: Sun, 9 Jun 2024 17:15:53 +0200 Subject: [PATCH] Fix small typo in help --- about/help_en | 11 +++++++++-- about/help_fr | 2 +- about/help_sk | 9 +++++++++ batchprocessing.cpp | 1 - 4 files changed, 19 insertions(+), 4 deletions(-) diff --git a/about/help_en b/about/help_en index ff09ffc..d825e0f 100644 --- a/about/help_en +++ b/about/help_en @@ -122,7 +122,7 @@ This example filters for files where: "Bias" is in the file name, the OBJECT pro This module allow to write scripts in JavaScript that process image files. Batch Processing window consist from three main parts. On top is list of input files and directories. You can add directories or individual files to this list. Directories are scanned recursively to find all files even non image files. This list of files is then passed to script in array named files. In script you can then iterate through files like this. -
for(file in files)
+
for(file of files)
 {
     if(file.suffix() == "fits")
     {
@@ -131,6 +131,13 @@ In script you can then iterate through files like this.
     }
 }
 
+

Bellow this list is output directory. All relative paths passed as arguments into methods like copy(), move() or convert() will be relative to this output directory. If you pass absolute path to methods then +this output directory is ignored.

+ +

Bellow that is list of scripts. These scripts are located in application data directory. Select script which you want to run by clicking on it. Clicking on Open scripts will open directory with these scripts where you create new and edit them. +Location of this directory is on Windows: "C:/Users//AppData/Roaming/nou/Tenmon" Linux: "~/.local/share/nou/Tenmon/scripts" MacOS: "~/Library/Application Support/nou/Tenmon/scripts"

+ +

Next is Log windows that contain any messages that come from scripts. Mainly calls to core.log() At bottom there buttons that can start or stop execution of selected scripts.

core

There is global object called core that have these methods. @@ -188,7 +195,7 @@ file.convert("converted_file.jpg", "png");
core.sync(); to ensure that conversion is done and destination file exists.
let compression = {"compressionType": "zstd+sh"};
 let convertedFiles = [];
-for(file of files)
+for(file in files)
 {
     if(file.suffix() == "fits")
         convertedFiles.push(file.convertAsync("xisf/" + file.fileName(), "XISF", compression));
diff --git a/about/help_fr b/about/help_fr
index 8913b39..6da2fe8 100644
--- a/about/help_fr
+++ b/about/help_fr
@@ -107,7 +107,7 @@ Cet exemple filtre les fichiers où : "Bias" figure dans le nom de fichier, la p
 Ce module permet d'écrire des scripts en JavaScript qui traitent des fichiers images. La fenêtre de traitement par lots se compose de trois parties principales. En haut se trouve la liste des fichiers et répertoires d'entrée.
 Vous pouvez ajouter des répertoires ou des fichiers individuels à cette liste. Les répertoires sont analysés de manière récursive pour trouver tous les fichiers, même les fichiers non image. Cette liste de fichiers est ensuite transmise au script dans un tableau nommé  files.
 Dans le script, vous pouvez ensuite parcourir les fichiers comme ici.
-
for(file in files)
+
for(file of files)
 {
     if(file.suffix() == "fits")
     {
diff --git a/about/help_sk b/about/help_sk
index 889a2e2..3251590 100644
--- a/about/help_sk
+++ b/about/help_sk
@@ -78,6 +78,15 @@ Pre indexovanie nových súborov je treba znova pustiť indexáciu.

kde sú jednotlivé stĺpcoch zobrazené vybrané vlastnosti. V spodnej časti panelu je tlačidlo ktoré zobrazí dialóg na výber zobrazovaných sĺpcov. Nasledujú tri výberové a textové polia. Tieto slúžia na vyhľadávanie v databáze. Výberové pole určuje stĺpec v ktorom sa má vyhľadávať a do textového poľa sa zadáva hodnota na vyhľadanie. + +

Zastupné znaky: +

    +
  • % (percent) je zastupný znak reprezentujúci žiadný alebo hocikoľko znakov.
  • +
  • _ (underscore) je zastupný znak nahrádzajúci presne jeden znak. +
  • Bez zástupných znako sa hľadá presná zhoda.
  • +
+

+

V nasledovnom príklade sa vyhľadajú súbory ktoré majú v mene súboru "Bias", OBJECT je M_42 a DATE začína reťazcom 2022. Znak % sa berie ako zástupný znak za hocijaký reťazec znakov aj žiadny. Znak _ je tiež zástupný znak zastupujúci práve jeden znak. diff --git a/batchprocessing.cpp b/batchprocessing.cpp index e67125c..7e2cdd7 100644 --- a/batchprocessing.cpp +++ b/batchprocessing.cpp @@ -100,7 +100,6 @@ BatchProcessing::BatchProcessing(QWidget *parent) : QDialog(parent) QSettings settings; _ui->outputPath->setText(settings.value("batchprocessing/outputpath", QStandardPaths::standardLocations(QStandardPaths::PicturesLocation).first()).toString()); - _ui->pathsList->addItem("/home/nou/Obrázky/astro/2019-12-03"); } BatchProcessing::~BatchProcessing()