![]() |
QtLingo 1
QtLingo is an Application to make Qt Computer Translations easier
|
Main Window Constructor. /class MainWindow. More...
#include <MainWindow.h>
Public Types | |
| enum | MainTabs { TabSettings = 0 , TabSql = 1 , TabTranslations = 2 , TabProject = 3 , TabTabHelp = 4 , TabAll = 9 } |
| Tabs must be forced to be int 0 based indexes that match the actual ui for widgetTab, this enforces compile-time checks. More... | |
| enum | TranslationsErrors { NoError = 100 , HostNotFound = 101 , ErrorTransferring = 102 } |
| Translations Errors. More... | |
| enum | MyMessageTypes { Information = 100 , Warning = 101 , Critical = 102 , Debug = 103 } |
| Message Types. More... | |
| enum | ActionStatesManager { Translations = 100 , TranslationHelp = 101 , TranslationReadMe = 102 } |
| Action States Manager. More... | |
Public Slots | |
| void | onHelp () |
| on Help More... | |
| void | onAbout () |
| on About More... | |
| void | onClipboard () |
| on Clipboard More... | |
| void | onCompile () |
| on Compile More... | |
| void | onAuthor () |
| on Author More... | |
| void | onSave () |
| on Save More... | |
| void | onInternetProgress () |
| on Internet Progress More... | |
| void | onTranslateHelp () |
| translate Help Files More... | |
| void | onTranslateReadMe () |
| Translate ReadMe. More... | |
Public Member Functions | |
| MainWindow (QWidget *parent=nullptr) | |
| MainWindow Constructor. MainWindow. More... | |
| ~MainWindow () | |
| MainWindow Deconstructor. ~MainWindow. More... | |
| void | onRunFirstOnStartup () |
| on Run First On Startup More... | |
| void | loadQtProjectCombo () |
| set Qt Project Combo More... | |
| void | readAllSettings () |
| read Settings More... | |
| void | readStatesChanges () |
| read States Changes More... | |
| void | readSqlDatabaseInfo () |
| read SQL Database Info More... | |
| void | writeAllSettings () |
| write Settings More... | |
| void | writeStateChanges () |
| write State Changes More... | |
| void | writeSqlDatabaseInfo () |
| write SQL Database Info More... | |
| void | setSqlBrowseButton () |
| set SQL Browse Button More... | |
| bool | fillForms (const QString &thisProjectID) |
| fill Forms More... | |
| void | clearForms (int tabNumber) |
| clear Forms More... | |
| void | clearTabSettings () |
| clear Tab Settings More... | |
| void | clearTabHelp () |
| clear Tab Help More... | |
| void | clearTabTranslations () |
| clear Tab Translations More... | |
| void | clearTabProject () |
| clear Tab Project More... | |
| void | checkLanguage (const QString &thisName, const QString &thisLanguage, bool thisChecked) |
| check Language More... | |
| QString | languageChecked () |
| language Checked More... | |
| void | setProjectClass (int tabNumber) |
| set Project Class More... | |
| void | createTranslationJob (const QString &thisTranslate, const QString &thisLangCode, const QString &thisSourceLanguage, bool thisChecked) |
| get Translation String More... | |
| void | setPrograms () |
| set Programs More... | |
| void | setDebugMessage (bool thisState) |
| set Debug Message More... | |
| bool | getDebugMessage () |
| get Debug Message More... | |
| void | retranslate () |
| retranslate none designer components More... | |
| void | loadLanguageComboBox () |
| load Language ComboBox More... | |
| void | loadLanguageComboBoxSource () |
| load Language ComboBox Source More... | |
| void | readSettingsFirst () |
| read Settings First More... | |
| void | setMessagingStates (bool thisMessageState) |
| set Messaging States More... | |
| void | setTabSettings () |
| set Tab Settings More... | |
| void | setTabTranslations () |
| set Tab Translations More... | |
| void | setTabAll () |
| set Tab All More... | |
| QString | translateWithReturn (const QString &text, QOnlineTranslator::Engine engine, QOnlineTranslator::Language translationLang, QOnlineTranslator::Language sourceLang, QOnlineTranslator::Language uiLang) |
| translate With Return, note this is blocking More... | |
| QString | checkTranslationErrors (const QString &thisTranslations, const QString &thisText, QOnlineTranslator::Engine thisEngine, QOnlineTranslator::Language thisTranslationLang, QOnlineTranslator::Language thisSourceLang, QOnlineTranslator::Language thisUiLang) |
| check Translation Errors More... | |
| void | setTranslationErrorType (const QString &thisTranslations) |
| set Translation Error Type More... | |
| void | createHelpTranslationJob (const QString &thisLanguageName, const QString &thisLangCode, bool thisChecked) |
| create Help Translation Job More... | |
| void | setLanguageCode () |
| set Language Code Lable in UI More... | |
| void | acceptTranslations () |
| accept Translations More... | |
| void | createReadMeTranslationJob (const QString &thisLanguageName, const QString &thisLangCode, bool thisChecked) |
| create ReadMe Translation Job More... | |
| void | closeTransHelp () |
| close Trans Help More... | |
| void | setMessage (const QString &thisMessage, MainWindow::MyMessageTypes thisMessageType) |
| set Message More... | |
| void | setActionsDisabled (ActionStatesManager thisAction, bool thisState) |
| set Actions Disabled More... | |
| void | setMainLoaded (bool thisState) |
| set Main Loaded More... | |
| void | setCheckMarksTranslation (const QString &thisDbValve) |
| set Check Marks Translation More... | |
| QString | getComboBoxProjectsID (int thisIndex) |
| get ComboBox Projects ID More... | |
| void | loadLanguage (const QString &thisLanguage) |
| loadLanguage More... | |
| void | setLastLanguageName (const QString &thisLastLanguageName) |
| setLastLanguageName More... | |
| QString | getLastLanguageName () |
| getLastLanguageName More... | |
| void | setDatabaseModel () |
| setDatabaseModel More... | |
| void | setLanguageModel (MyLanguageModel *thisLanguageModel) |
| set Language Model More... | |
| bool | getMainLoaded () |
| get Main Loaded Set to prevent triggers. getMainLoaded More... | |
| void | removeArgs (const QString &thisString, const QString &thisTransFile) |
| remove Args like "String %1" list. removeArgs More... | |
| void | fileRemoveArgs () |
| file Remove Args "String %1". fileRemoveArgs More... | |
| void | fixTranslationFile (const QString &thisFile) |
| fix Translation File; mostly Arabic gets the value before the ID on some fields. fixTranslationFile More... | |
Public Attributes | |
| MyConstants * | myConstants |
myConstants More... | |
Protected Slots | |
| virtual void | changeEvent (QEvent *event) override |
| change Event More... | |
Protected Member Functions | |
| void | closeEvent (QCloseEvent *event) override |
| close Event More... | |
Main Window Constructor. /class MainWindow.
Definition at line 76 of file MainWindow.h.
Action States Manager.
| Enumerator | |
|---|---|
| Translations |
Translations On Compile. |
| TranslationHelp |
Translation Help |
| TranslationReadMe |
Translation ReadMe. |
Definition at line 125 of file MainWindow.h.
| enum MainWindow::MainTabs |
Tabs must be forced to be int 0 based indexes that match the actual ui for widgetTab, this enforces compile-time checks.
Definition at line 87 of file MainWindow.h.
Message Types.
| Enumerator | |
|---|---|
| Information |
Information |
| Warning |
Warning |
| Critical |
Critical |
| Debug |
Debug |
Definition at line 112 of file MainWindow.h.
Translations Errors.
Definition at line 101 of file MainWindow.h.
|
explicit |
MainWindow Constructor. MainWindow.
Definition at line 20 of file MainWindow.cpp.
| MainWindow::~MainWindow | ( | ) |
MainWindow Deconstructor. ~MainWindow.
Definition at line 72 of file MainWindow.cpp.
| void MainWindow::acceptTranslations | ( | ) |
accept Translations
accept Translations. acceptTranslations
Definition at line 2472 of file MainWindow.cpp.
|
overrideprotectedvirtualslot |
change Event
change Event. changeEvent
Definition at line 94 of file MainWindow.cpp.
| void MainWindow::checkLanguage | ( | const QString & | thisName, |
| const QString & | thisLanguage, | ||
| bool | thisChecked | ||
| ) |
| QString MainWindow::checkTranslationErrors | ( | const QString & | thisTranslations, |
| const QString & | thisText, | ||
| QOnlineTranslator::Engine | thisEngine, | ||
| QOnlineTranslator::Language | thisTranslationLang, | ||
| QOnlineTranslator::Language | thisSourceLang, | ||
| QOnlineTranslator::Language | thisUiLang | ||
| ) |
check Translation Errors
check Translation Errors. checkTranslationErrors
Definition at line 2446 of file MainWindow.cpp.
| void MainWindow::clearForms | ( | int | tabNumber | ) |
clear Forms
clear Forms clearForms(TabAll). clearForms
Definition at line 2022 of file MainWindow.cpp.
| void MainWindow::clearTabHelp | ( | ) |
| void MainWindow::clearTabProject | ( | ) |
clear Tab Project
clear Tab Project. clearTabProject
Definition at line 2004 of file MainWindow.cpp.
| void MainWindow::clearTabSettings | ( | ) |
clear Tab Settings
clear Tab Settings. clearTabSettings
Definition at line 1705 of file MainWindow.cpp.
| void MainWindow::clearTabTranslations | ( | ) |
clear Tab Translations
clear Tab Translations. clearTabTranslations
Definition at line 1717 of file MainWindow.cpp.
|
overrideprotected |
| void MainWindow::closeTransHelp | ( | ) |
close Trans Help
translate ReadMe. onTranslateReadMe
Definition at line 2723 of file MainWindow.cpp.
| void MainWindow::createHelpTranslationJob | ( | const QString & | thisLanguageName, |
| const QString & | thisLangCode, | ||
| bool | thisChecked | ||
| ) |
create Help Translation Job
translate With Return Added by Light-Wizzard. translateWithReturn
Definition at line 2980 of file MainWindow.cpp.
| void MainWindow::createReadMeTranslationJob | ( | const QString & | thisLanguageName, |
| const QString & | thisLangCode, | ||
| bool | thisChecked | ||
| ) |
create ReadMe Translation Job
translate With Return Added by Light-Wizzard. translateWithReturn
Definition at line 3019 of file MainWindow.cpp.
| void MainWindow::createTranslationJob | ( | const QString & | thisTranslate, |
| const QString & | thisLangCode, | ||
| const QString & | thisSourceLanguage, | ||
| bool | thisChecked | ||
| ) |
get Translation String
create Translation Job, I pass in the Name of the Language, and the language ID, I do not use the Name, but find it nice to have the info with it. createTranslationJob
Definition at line 2951 of file MainWindow.cpp.
| void MainWindow::fileRemoveArgs | ( | ) |
file Remove Args "String %1". fileRemoveArgs
Definition at line 3268 of file MainWindow.cpp.
| bool MainWindow::fillForms | ( | const QString & | thisProjectID | ) |
fill Forms
fill Forms. fillForms
Definition at line 1642 of file MainWindow.cpp.
| void MainWindow::fixTranslationFile | ( | const QString & | thisFile | ) |
fix Translation File; mostly Arabic gets the value before the ID on some fields. fixTranslationFile
Definition at line 3282 of file MainWindow.cpp.
| QString MainWindow::getComboBoxProjectsID | ( | int | thisIndex | ) |
get ComboBox Projects ID
get ComboBox Projects ID. getComboBoxProjectsID
Definition at line 743 of file MainWindow.cpp.
| bool MainWindow::getDebugMessage | ( | ) |
get Debug Message
get Debug Message. getDebugMessage
Definition at line 3198 of file MainWindow.cpp.
| QString MainWindow::getLastLanguageName | ( | ) |
getLastLanguageName
get Last Language Name. getLastLanguageName
Definition at line 163 of file MainWindow.cpp.
| bool MainWindow::getMainLoaded | ( | ) |
get Main Loaded Set to prevent triggers. getMainLoaded
Definition at line 356 of file MainWindow.cpp.
| QString MainWindow::languageChecked | ( | ) |
language Checked
language Checked. languageChecked
Definition at line 918 of file MainWindow.cpp.
| void MainWindow::loadLanguage | ( | const QString & | thisLanguage | ) |
loadLanguage
load Language. loadLanguage
Definition at line 143 of file MainWindow.cpp.
| void MainWindow::loadLanguageComboBox | ( | ) |
load Language ComboBox
load Language ComboBox. loadLanguageComboBox
Definition at line 256 of file MainWindow.cpp.
| void MainWindow::loadLanguageComboBoxSource | ( | ) |
load Language ComboBox Source
load Language ComboBox Source. loadLanguageComboBoxSource
Definition at line 199 of file MainWindow.cpp.
| void MainWindow::loadQtProjectCombo | ( | ) |
set Qt Project Combo
load Qt Project Combo. loadQtProjectCombo
Definition at line 312 of file MainWindow.cpp.
|
slot |
on About
Main Window Destructor. onAbout.
Definition at line 570 of file MainWindow.cpp.
|
slot |
on Author
on Author. onAuthor
Definition at line 555 of file MainWindow.cpp.
|
slot |
|
slot |
on Compile
on Compile. onCompile
Definition at line 2115 of file MainWindow.cpp.
|
slot |
on Help
Help. onHelp.
Definition at line 585 of file MainWindow.cpp.
|
slot |
on Internet Progress
on Internet Progress. onInternetProgress
Definition at line 171 of file MainWindow.cpp.
| void MainWindow::onRunFirstOnStartup | ( | ) |
on Run First On Startup
on Run First On Startup. onRunFirstOnStartup
Definition at line 364 of file MainWindow.cpp.
|
slot |
|
slot |
translate Help Files
translate Help files. translateHelp
Definition at line 2489 of file MainWindow.cpp.
|
slot |
Translate ReadMe.
translate ReadMe. onTranslateReadMe
Definition at line 2733 of file MainWindow.cpp.
| void MainWindow::readAllSettings | ( | ) |
read Settings
read Settings. readAllSettings
Definition at line 423 of file MainWindow.cpp.
| void MainWindow::readSettingsFirst | ( | ) |
read Settings First
read Settings First. readSettingsFirst
Definition at line 403 of file MainWindow.cpp.
| void MainWindow::readSqlDatabaseInfo | ( | ) |
read SQL Database Info
read SQL Database Info Uses SimpleCrypt to encrypt and decrypt Password. readSqlDatabaseInfo
Definition at line 530 of file MainWindow.cpp.
| void MainWindow::readStatesChanges | ( | ) |
read States Changes
read SQL Database States. readSqlDatabaseStates
Definition at line 457 of file MainWindow.cpp.
| void MainWindow::removeArgs | ( | const QString & | thisString, |
| const QString & | thisTransFile | ||
| ) |
remove Args like "String %1" list. removeArgs
Definition at line 3259 of file MainWindow.cpp.
| void MainWindow::retranslate | ( | ) |
retranslate none designer components
retranslate. retranslate
Definition at line 179 of file MainWindow.cpp.
| void MainWindow::setActionsDisabled | ( | ActionStatesManager | thisAction, |
| bool | thisState | ||
| ) |
| void MainWindow::setCheckMarksTranslation | ( | const QString & | thisDbValve | ) |
set Check Marks Translation
set Check Marks Translation. setCheckMarksTranslation
Definition at line 1102 of file MainWindow.cpp.
| void MainWindow::setDatabaseModel | ( | ) |
setDatabaseModel
set Database Model is called from main.c. setDatabaseModel
Definition at line 121 of file MainWindow.cpp.
| void MainWindow::setDebugMessage | ( | bool | thisState | ) |
set Debug Message
set Debug Message. setDebugMessage
Definition at line 3189 of file MainWindow.cpp.
| void MainWindow::setLanguageCode | ( | ) |
set Language Code Lable in UI
set Language Code. setLanguageCode
Definition at line 248 of file MainWindow.cpp.
| void MainWindow::setLanguageModel | ( | MyLanguageModel * | thisLanguageModel | ) |
set Language Model
set Language Model. setLanguageModel
Definition at line 111 of file MainWindow.cpp.
| void MainWindow::setLastLanguageName | ( | const QString & | thisLastLanguageName | ) |
setLastLanguageName
set Last Language Name. setLastLanguageName
Definition at line 155 of file MainWindow.cpp.
| void MainWindow::setMainLoaded | ( | bool | thisState | ) |
| void MainWindow::setMessage | ( | const QString & | thisMessage, |
| MainWindow::MyMessageTypes | thisMessageType | ||
| ) |
set Message
set Message. setMessage
Definition at line 3165 of file MainWindow.cpp.
| void MainWindow::setMessagingStates | ( | bool | thisMessageState | ) |
set Messaging States
set Messaging States. setMessagingStates
Definition at line 3111 of file MainWindow.cpp.
| void MainWindow::setPrograms | ( | ) |
| void MainWindow::setProjectClass | ( | int | tabNumber | ) |
set Project Class
set Project Class. setProjectClass
Definition at line 2088 of file MainWindow.cpp.
| void MainWindow::setSqlBrowseButton | ( | ) |
set SQL Browse Button
set SQL Browse Button. setSqlBrowseButton
Definition at line 897 of file MainWindow.cpp.
| void MainWindow::setTabAll | ( | ) |
| void MainWindow::setTabSettings | ( | ) |
set Tab Settings
set Tab Settings. setTabSettings
Definition at line 2044 of file MainWindow.cpp.
| void MainWindow::setTabTranslations | ( | ) |
set Tab Translations
set Tab Translations. setTabTranslations
Definition at line 2062 of file MainWindow.cpp.
| void MainWindow::setTranslationErrorType | ( | const QString & | thisTranslations | ) |
set Translation Error Type
check Translation Errors. checkTranslationErrors
Definition at line 2407 of file MainWindow.cpp.
| QString MainWindow::translateWithReturn | ( | const QString & | text, |
| QOnlineTranslator::Engine | engine, | ||
| QOnlineTranslator::Language | translationLang, | ||
| QOnlineTranslator::Language | sourceLang, | ||
| QOnlineTranslator::Language | uiLang | ||
| ) |
translate With Return, note this is blocking
translate With Return Added by Light-Wizzard. translateWithReturn
Definition at line 3051 of file MainWindow.cpp.
| void MainWindow::writeAllSettings | ( | ) |
write Settings
Write All Settings. writeAllSettings.
Definition at line 440 of file MainWindow.cpp.
| void MainWindow::writeSqlDatabaseInfo | ( | ) |
write SQL Database Info
write SQL Database Info Uses SimpleCrypt to encrypt and decrypt Password. writeSqlDatabaseInfo
Definition at line 509 of file MainWindow.cpp.
| void MainWindow::writeStateChanges | ( | ) |
write State Changes
write States Changes. writeStateChanges
Definition at line 484 of file MainWindow.cpp.
| MyConstants* MainWindow::myConstants |