From 8883b2207f6d7fc0d7e9a8c7c14f1f31d09085dd Mon Sep 17 00:00:00 2001 From: George Ember Date: Wed, 21 Sep 2016 17:12:02 +0300 Subject: Translated to Greek MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Finished. Not 100% sure about Trigger meaning Trigger Terminal Εμφάνιση/Απόκρυψη Γραμμής Εντολών --- .../desktop-utils/lumina-terminal/i18n/l-terminal_el.ts | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/desktop-utils/lumina-terminal/i18n/l-terminal_el.ts b/src-qt5/desktop-utils/lumina-terminal/i18n/l-terminal_el.ts index fe7211a7..2d9b7119 100644 --- a/src-qt5/desktop-utils/lumina-terminal/i18n/l-terminal_el.ts +++ b/src-qt5/desktop-utils/lumina-terminal/i18n/l-terminal_el.ts @@ -6,12 +6,12 @@ Copy Selection - + Αντιγραφή Επιλογής Paste - + Επικόλληση @@ -19,27 +19,27 @@ Trigger Terminal - + Εμφάνιση/Απόκρυψη Γραμμής Εντολών Top of Screen - + Επάνω Μέρος της Οθόνης Close Terminal - + Κλείσιμο Γραμμής Εντολών Move To Monitor - + Μετακίνηση στην Οθόνη Monitor %1 - + Οθόνη %1 -- cgit From d4e90780226e6e910561654cc3a574623ddfa5cc Mon Sep 17 00:00:00 2001 From: Ken Moore Date: Wed, 21 Sep 2016 12:07:45 -0400 Subject: Commit a small cleanup for the auto-loading of the apps list on the system. Going to check if this fixes the memory leak issue on some systems (have one I can test on now). --- src-qt5/core/libLumina/LuminaXDG.cpp | 12 +++++++----- src-qt5/core/libLumina/LuminaXDG.h | 1 + 2 files changed, 8 insertions(+), 5 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/core/libLumina/LuminaXDG.cpp b/src-qt5/core/libLumina/LuminaXDG.cpp index 48185a38..64f21743 100644 --- a/src-qt5/core/libLumina/LuminaXDG.cpp +++ b/src-qt5/core/libLumina/LuminaXDG.cpp @@ -20,6 +20,7 @@ XDGDesktopList::XDGDesktopList(QObject *parent, bool watchdirs) : QObject(parent synctimer = new QTimer(this); synctimer->setInterval(60000); //1 minute intervals. since the polling/update only takes a few ms, this is completely reasonable connect(synctimer, SIGNAL(timeout()), this, SLOT(updateList()) ); + keepsynced = watchdirs; if(watchdirs){ watcher = new QFileSystemWatcher(this); connect(watcher, SIGNAL(fileChanged(const QString&)), this, SLOT(watcherChanged()) ); @@ -79,12 +80,13 @@ void XDGDesktopList::updateList(){ } //If this class is automatically managing the lists, update the watched files/dirs and send out notifications if(watcher!=0){ - //qDebug() << "App List Updated:" << lastCheck << appschanged << newfiles << oldkeys; + qDebug() << "Auto App List Update:" << lastCheck << "Changes:" << appschanged;// << newfiles << oldkeys; watcher->removePaths(QStringList() << watcher->files() << watcher->directories()); watcher->addPaths(appDirs); if(appschanged){ emit appsUpdated(); } + synctimer->start(); } - synctimer->start(); + } QList XDGDesktopList::apps(bool showAll, bool showHidden){ @@ -511,15 +513,15 @@ QStringList LXDG::systemApplicationDirs(){ } XDGDesktopList* LXDG::systemAppsList(){ - static XDGDesktopList *sysapps = new XDGDesktopList(0,true); //set this to automatically update as needed + static XDGDesktopList *sysapps = 0; + if(sysapps == 0){ qDebug() << "Generating new apps list"; sysapps = new XDGDesktopList(0,true); }//set this to automatically update as needed if(sysapps->lastCheck.isNull()){ sysapps->updateList(); } //catch the first time the class was used, and prompt for an update right now return sysapps; } QList LXDG::systemDesktopFiles(bool showAll, bool showHidden){ //Quick overload for backwards compatibility which uses the static/global class for managing app entries - XDGDesktopList list(0, false); - return list.apps(showAll, showHidden); + return systemAppsList()->apps(showAll, showHidden); } QHash > LXDG::sortDesktopCats(QList apps){ diff --git a/src-qt5/core/libLumina/LuminaXDG.h b/src-qt5/core/libLumina/LuminaXDG.h index 996e5a20..0397ce71 100644 --- a/src-qt5/core/libLumina/LuminaXDG.h +++ b/src-qt5/core/libLumina/LuminaXDG.h @@ -93,6 +93,7 @@ public slots: private: QFileSystemWatcher *watcher; QTimer *synctimer; + bool keepsynced; private slots: void watcherChanged(); -- cgit From 16e6d9d7ad7f342a747bef3ffcbe007ee3132ba6 Mon Sep 17 00:00:00 2001 From: Ken Moore Date: Wed, 21 Sep 2016 12:19:58 -0400 Subject: Another quick fix to try and track down where Lumina is leaking memory within teh app list search routine. --- src-qt5/core/libLumina/LuminaXDG.cpp | 1 + 1 file changed, 1 insertion(+) (limited to 'src-qt5') diff --git a/src-qt5/core/libLumina/LuminaXDG.cpp b/src-qt5/core/libLumina/LuminaXDG.cpp index 64f21743..a32273c0 100644 --- a/src-qt5/core/libLumina/LuminaXDG.cpp +++ b/src-qt5/core/libLumina/LuminaXDG.cpp @@ -65,6 +65,7 @@ void XDGDesktopList::updateList(){ } if(ok && !found.contains(dFile.name)){ if(!oldkeys.contains(path)){ newfiles << path; } //brand new file (not an update to a previously-read file) + else{ files.remove(path); } //just to ensure that we don't get duplicates within the Hash files.insert(path, dFile); found << dFile.name; oldkeys.removeAll(path); //make sure this key does not get cleaned up later -- cgit From 194547d321a327d6bea549a2aed047169973883b Mon Sep 17 00:00:00 2001 From: Ken Moore Date: Wed, 21 Sep 2016 13:35:25 -0400 Subject: Another small fix to try and correct the memory leak. --- src-qt5/core/libLumina/LuminaXDG.cpp | 24 +++++++++++++----------- 1 file changed, 13 insertions(+), 11 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/core/libLumina/LuminaXDG.cpp b/src-qt5/core/libLumina/LuminaXDG.cpp index a32273c0..b57738c1 100644 --- a/src-qt5/core/libLumina/LuminaXDG.cpp +++ b/src-qt5/core/libLumina/LuminaXDG.cpp @@ -56,32 +56,34 @@ void XDGDesktopList::updateList(){ path = dir.absoluteFilePath(apps[a]); if(files.contains(path) && (files.value(path).lastRead>QFileInfo(path).lastModified()) ){ //Re-use previous data for this file (nothing changed) - dFile = files[path]; + found << files[path].name; //keep track of which files were already found ok=true; }else{ ok=false; + if(files.contains(path)){ files.remove(path); } dFile = LXDG::loadDesktopFile(path,ok); //will change the "ok" variable as needed appschanged = true; //flag that something changed - needed to load a file + if(ok && !found.contains(dFile.name)){ + if(!oldkeys.contains(path)){ newfiles << path; } //brand new file (not an update to a previously-read file) + files.insert(path, dFile); + found << dFile.name; + } } - if(ok && !found.contains(dFile.name)){ - if(!oldkeys.contains(path)){ newfiles << path; } //brand new file (not an update to a previously-read file) - else{ files.remove(path); } //just to ensure that we don't get duplicates within the Hash - files.insert(path, dFile); - found << dFile.name; - oldkeys.removeAll(path); //make sure this key does not get cleaned up later - } + oldkeys.removeAll(path); //make sure this key does not get cleaned up later } //end loop over apps } //end loop over appDirs //Save the extra info to the internal lists - if(!firstrun){ removedApps = oldkeys; }//files which were removed - if(!firstrun){ newApps = newfiles; }//files which were added + if(!firstrun){ + removedApps = oldkeys;//files which were removed + newApps = newfiles; //files which were added + } //Now go through and cleanup any old keys where the associated file does not exist anymore for(int i=0; iremovePaths(QStringList() << watcher->files() << watcher->directories()); watcher->addPaths(appDirs); if(appschanged){ emit appsUpdated(); } -- cgit From 6610dc38cfd9527038716821b5292d13d5f13ea7 Mon Sep 17 00:00:00 2001 From: Ken Moore Date: Wed, 21 Sep 2016 13:57:18 -0400 Subject: Have the internal QHash run "squeeze" after every update run - just to ensure it uses as little memory as possible. --- src-qt5/core/libLumina/LuminaXDG.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src-qt5') diff --git a/src-qt5/core/libLumina/LuminaXDG.cpp b/src-qt5/core/libLumina/LuminaXDG.cpp index b57738c1..e500ab7e 100644 --- a/src-qt5/core/libLumina/LuminaXDG.cpp +++ b/src-qt5/core/libLumina/LuminaXDG.cpp @@ -89,7 +89,7 @@ void XDGDesktopList::updateList(){ if(appschanged){ emit appsUpdated(); } synctimer->start(); } - + files.squeeze(); //make sure this class uses as little memory as possible (should not be needed - but just in case...) } QList XDGDesktopList::apps(bool showAll, bool showHidden){ -- cgit From de4b5c26801cc19956d0eb1e1d109b7024c8e368 Mon Sep 17 00:00:00 2001 From: Ken Moore Date: Wed, 21 Sep 2016 14:20:15 -0400 Subject: Add an "==" operator to the XDGDesktop class. Found a note in the QHash docs that any class type need this defined. --- src-qt5/core/libLumina/LuminaXDG.h | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'src-qt5') diff --git a/src-qt5/core/libLumina/LuminaXDG.h b/src-qt5/core/libLumina/LuminaXDG.h index 0397ce71..1720ebc5 100644 --- a/src-qt5/core/libLumina/LuminaXDG.h +++ b/src-qt5/core/libLumina/LuminaXDG.h @@ -68,6 +68,10 @@ public: //Constructor/destructor XDGDesktop(){} ~XDGDesktop(){} + + friend bool operator==(const XDGDesktop lhs, const XDGDesktop rhs){ + return lhs.filePath == rhs.filePath && lhs.lastRead == rhs.lastRead; + } }; // ======================== -- cgit From e24b7b3f822a55aa8210ed21d50349147426f7a3 Mon Sep 17 00:00:00 2001 From: Ken Moore Date: Wed, 21 Sep 2016 17:08:34 -0400 Subject: Fix the memory usage issue with Lumina and the application list on the system. It no longer grows with time that I can tell, but I am sure there is some additional cleanup and optimizations which can still be done later. --- src-qt5/core/libLumina/LuminaXDG.cpp | 27 +++++++++------------------ src-qt5/core/libLumina/LuminaXDG.h | 22 ++++++++++++---------- 2 files changed, 21 insertions(+), 28 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/core/libLumina/LuminaXDG.cpp b/src-qt5/core/libLumina/LuminaXDG.cpp index e500ab7e..36b05676 100644 --- a/src-qt5/core/libLumina/LuminaXDG.cpp +++ b/src-qt5/core/libLumina/LuminaXDG.cpp @@ -48,7 +48,7 @@ void XDGDesktopList::updateList(){ bool firstrun = lastCheck.isNull() || oldkeys.isEmpty(); lastCheck = QDateTime::currentDateTime(); //Variables for internal loop use only (to prevent re-initializing variable on every iteration) - bool ok; QString path; QDir dir; QStringList apps; XDGDesktop dFile; + bool ok; QString path; QDir dir; QStringList apps; for(int i=0; istart(); } - files.squeeze(); //make sure this class uses as little memory as possible (should not be needed - but just in case...) } QList XDGDesktopList::apps(bool showAll, bool showHidden){ @@ -97,8 +97,8 @@ QList XDGDesktopList::apps(bool showAll, bool showHidden){ QStringList keys = files.keys(); QList out; for(int i=0; i actions; //Type 2 (LINK) variables QString url; - + //Constructor/destructor XDGDesktop(){} - ~XDGDesktop(){} - - friend bool operator==(const XDGDesktop lhs, const XDGDesktop rhs){ - return lhs.filePath == rhs.filePath && lhs.lastRead == rhs.lastRead; - } + ~XDGDesktop(){ + actions.clear(); + showInList.clear(); notShowInList.clear(); actionList.clear(); mimeList.clear(); catList.clear(); keyList.clear(); + name.clear(); genericName.clear(); comment.clear(); icon.clear(); + exec.clear(); tryexec.clear(); path.clear(); startupWM.clear(); url.clear(); + } }; // ======================== -- cgit From 3dbe8c9901459c5b7150aee0cf1cd7081ace6a81 Mon Sep 17 00:00:00 2001 From: Koljasha Date: Thu, 22 Sep 2016 06:06:20 +0000 Subject: Translated using Weblate (l_FILEINFO@ru (generated)) Currently translated at 95.3% (41 of 43 strings) --- .../lumina-fileinfo/i18n/l-fileinfo_ru.ts | 102 ++++++++++----------- 1 file changed, 51 insertions(+), 51 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/desktop-utils/lumina-fileinfo/i18n/l-fileinfo_ru.ts b/src-qt5/desktop-utils/lumina-fileinfo/i18n/l-fileinfo_ru.ts index 5a0a33e4..81793dfc 100644 --- a/src-qt5/desktop-utils/lumina-fileinfo/i18n/l-fileinfo_ru.ts +++ b/src-qt5/desktop-utils/lumina-fileinfo/i18n/l-fileinfo_ru.ts @@ -1,225 +1,225 @@ - + MainUI - - - + + + File Information Информация о Файле - + Owner: Владелец: - + Group: Группа: - + Permissions: Разрешения: - + Created: Созданный: - + Note: The time a file was created might be more recent than the time modified if the file permissions were changed recently. Примечание: время создания файла может быть более позднее, чем время изменения, если права на файл были недавно изменены. - + Last Modified: Последнее изменение: - + Type: Тип: - + MimeType: MIME-тип: - + File Size: Размер файла: - - + + Edit Shortcut Изменить ссылку - + Working Dir: Рабочий каталог: - + Use startup notification Уведомление - + Icon: Иконка: - + Command: Команда: - + Comment: Комментарий: - + Run in terminal Запуск в терминале - + Name: Имя: - + Options Опции - + No Icon Нет иконки - + Save Сохранить - + Close Закрыть - + ---Calculating--- ---Вычисление--- - + Read/Write Чтение/Запись - + Read Only Только чтение - + Write Only Только запись - + No Access Нет доступа - + XDG Shortcut XDG ссылка - + Directory Папка - + Binary Бинарный - + Hidden %1 Скрытый %1 - + URL: URL: - + Save Application File - + Сохранить файл приложения - + Application Registrations (*.desktop) - + Регистрация приложения (* .desktop) - + Select a binary Выбрать бинарный - + Error Ошибка - + Invalid selection: Not a valid executable Неверный выбор: Не является выполняемым - + Select a directory Выбрать каталог - + Select an icon Выбрать иконку - + Images (%1);; All Files (*) Изображений (%1);; Все файлы (*) - - + + Folders: Папки: - - + + Files: Файлы: - + Calculating... Вычисление... -- cgit From 1213e0bf433a4dcf7f586be83689ced072cac411 Mon Sep 17 00:00:00 2001 From: Koljasha Date: Thu, 22 Sep 2016 06:10:06 +0000 Subject: Translated using Weblate (l_TERMINAL@ru (generated)) Currently translated at 0.0% (0 of 7 strings) --- .../lumina-terminal/i18n/l-terminal_ru.ts | 30 +++++++++++----------- 1 file changed, 15 insertions(+), 15 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/desktop-utils/lumina-terminal/i18n/l-terminal_ru.ts b/src-qt5/desktop-utils/lumina-terminal/i18n/l-terminal_ru.ts index 72ca44df..6fa3012b 100644 --- a/src-qt5/desktop-utils/lumina-terminal/i18n/l-terminal_ru.ts +++ b/src-qt5/desktop-utils/lumina-terminal/i18n/l-terminal_ru.ts @@ -1,45 +1,45 @@ - + TerminalWidget - + Copy Selection - + Копировать выбранное - + Paste - + Вставить TrayIcon - + Trigger Terminal - + Запуск терминала - + Top of Screen - + Всегда наверху - + Close Terminal - + Закрыть терминал - + Move To Monitor - + Переместить на экран - + Monitor %1 - + Экран: %1 -- cgit From 4c0ae961a91268f671c4af6edd1a805d51726104 Mon Sep 17 00:00:00 2001 From: Koljasha Date: Thu, 22 Sep 2016 06:13:34 +0000 Subject: Translated using Weblate (l_TE@ru (generated)) Currently translated at 92.5% (50 of 54 strings) --- .../desktop-utils/lumina-textedit/i18n/l-te_ru.ts | 138 +++++++++++---------- 1 file changed, 72 insertions(+), 66 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/desktop-utils/lumina-textedit/i18n/l-te_ru.ts b/src-qt5/desktop-utils/lumina-textedit/i18n/l-te_ru.ts index a8c8e491..04aab764 100644 --- a/src-qt5/desktop-utils/lumina-textedit/i18n/l-te_ru.ts +++ b/src-qt5/desktop-utils/lumina-textedit/i18n/l-te_ru.ts @@ -1,41 +1,41 @@ - + ColorDialog - + Customize Colors Настройка цвета - + Item Type Тип элемента - + Color Цвет - + Sample Пример - - + + Select Color Выбор цвета - + Cancel Отмена - + Apply Применить @@ -43,252 +43,258 @@ MainUI - + MainWindow Главное окно - + Tab 1 Вкладка 1 - + Find the previous match Найти предыдущее совпадение - - - - - + + + + + ... ... - + Find: Найти: - + Find the next match Найти следующее совпадение - + Replace: Заменить: - + Match case Учитывать регистр - + Replace next match Заменить следующее совпадение - + Replace all matches (to end of document) Заменить все совпадения (до конца документа) - + Hide the find/replace options Скрыть опции поиска/замены - + File Файл - + View Просмотр - + Syntax Highlighting Подсветка синтаксиса - + Edit Правка - + toolBar Панель инструментов - + Show Line Numbers Показать номера строк - + None Ничего - - + + New File Новый файл - + Ctrl+N Ctrl+N - + Open File Открыть файл - + Ctrl+O Ctrl+O - + Save File Сохранить файл - + Ctrl+S Ctrl+S - + Save File As Сохранить файл как - + Close Закрыть - + Ctrl+Q Ctrl+Q - + Close File Закрыть файл - + Ctrl+W Ctrl+W - + Customize Colors Настройка цвета - + Wrap Lines Переносить строки - + Find Найти - + Ctrl+F Ctrl+F - + Replace Заменить - + Ctrl+R Ctrl+R - + Text Editor Текстовый редактор - + Open File(s) Открыть файл(ы) - + Text Files (*) Текстовые файлы (*) - - + + Lose Unsaved Changes? - + Потерять несохраненные изменения? - + This file has unsaved changes. Do you want to close it anyway? %1 - + Этот файл содержит несохраненные изменения. +Вы все равно хотите его закрыть? + +%1 - + There are unsaved changes. Do you want to close the editor anyway? %1 - + Есть несохраненные изменения. +Вы все равно хотите закрыть редактор? + +%1 PlainTextEditor - + Save File Сохранить файл - + Text File (*) Текстовые файлы (*) - + Row Number: %1, Column Number: %2 - + Номер строки: %1, Номер колонки: %2 - + The following file has been changed by some other utility. Do you want to re-load it? Следующий файл был изменен с помощью какой-либо другой утилиты. Вы хотите, повторно загрузить его? - + (Note: You will lose all currently-unsaved changes) (Примечание: Вы потеряете все несохраненные изменения) - + File Modified Файл изменен -- cgit From 8cff3a504bb9625bb4bd1114bf5d70ae9f5d563f Mon Sep 17 00:00:00 2001 From: Koljasha Date: Thu, 22 Sep 2016 06:15:53 +0000 Subject: Translated using Weblate (lumina_WM@ru (generated)) Currently translated at 57.1% (4 of 7 strings) --- src-qt5/core/lumina-wm-INCOMPLETE/i18n/lumina-wm_ru.ts | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/core/lumina-wm-INCOMPLETE/i18n/lumina-wm_ru.ts b/src-qt5/core/lumina-wm-INCOMPLETE/i18n/lumina-wm_ru.ts index 0f3d9759..99de4b6a 100644 --- a/src-qt5/core/lumina-wm-INCOMPLETE/i18n/lumina-wm_ru.ts +++ b/src-qt5/core/lumina-wm-INCOMPLETE/i18n/lumina-wm_ru.ts @@ -9,34 +9,34 @@ Экран блокировки - + Password Пароль - + Unlock Session Разблокировать сессию - + Locked by: %1 Заблокировано: %1 - + Too Many Failures - + Слишком много неудач - + Wait %1 Minutes - + Подождите %1 минут(ы) - + Failed Attempts: %1 - + Неудачные попытки: %1 -- cgit From 220b7f6f2835544b8a0699901948a7caa8210447 Mon Sep 17 00:00:00 2001 From: Koljasha Date: Thu, 22 Sep 2016 05:59:40 +0000 Subject: Translated using Weblate (lumina_OPEN@ru (generated)) Currently translated at 100.0% (39 of 39 strings) --- src-qt5/core/lumina-open/i18n/lumina-open_ru.ts | 86 ++++++++++++------------- 1 file changed, 43 insertions(+), 43 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/core/lumina-open/i18n/lumina-open_ru.ts b/src-qt5/core/lumina-open/i18n/lumina-open_ru.ts index 1a1f9f18..f27df3a4 100644 --- a/src-qt5/core/lumina-open/i18n/lumina-open_ru.ts +++ b/src-qt5/core/lumina-open/i18n/lumina-open_ru.ts @@ -4,132 +4,132 @@ LFileDialog - + Open With... Открыть с помощью... - + Preferred Предпочтительный - + Available Доступно - + Custom Пользовательские - + Binary Location Расположение Бинарного Приложения - + Find Найти - + Set this application as the default Использовать это приложение по умолчанию - + OK OK - + Cancel Отмена - + (Email Link) (Email адрес) - + (Internet URL - %1) (Интернет URL - %1) - + Audio Звук - + Video Видео - + Multimedia Мультимедиа - + Development Разработка - + Education Образование - + Game Игры - + Graphics Графика - + Network Сети - + Office Офис - + Science Наука - + Settings Настройки - + System Система - + Utilities Инструменты - + Other Разное - + Find Application Binary Найти Бинарное Приложение @@ -137,69 +137,69 @@ QObject - + File Error Ошибка Файла - - + + Audio Volume %1% Громкость %1% - - + + Screen Brightness %1% Яркость Экрана %1% - + Invalid file or URL: %1 Неверный файл или URL-адрес: %1 - + File could not be opened: %1 Файл не может быть открыт: %1 - + Application shortcut is missing the launching information (malformed shortcut): %1 В ярлыке приложения отсутствует информация для запуска (неверный формат ярлыка): %1 - + URL shortcut is missing the URL: %1 В ярлыке отсутствует URL-адрес: %1 - + Directory shortcut is missing the path to the directory: %1 В ярлыке отсутствует путь к папке: %1 - + Unknown type of shortcut : %1 Неизвестный тип ярлыка: %1 - + Binary Missing Приложение отсутствует - - Could not find "%1". Please ensure it is installed first. - Не найден "%1". Пожалуйста, убедитесь, что он установлен в первую очередь. + + Could not find "%1". Please ensure it is installed first. + Не найден "%1". Пожалуйста, убедитесь, что он установлен в первую очередь. - + Application Error Ошибка Приложения - + The following application experienced an error and needed to close: Следующее приложение вызвало ошибку и должно быть закрыто: -- cgit From 82ebebfb8a5867b400c1df726a478bdcb9d7c005 Mon Sep 17 00:00:00 2001 From: Ken Moore Date: Thu, 22 Sep 2016 16:41:42 -0400 Subject: Large update to how XDGDesktop files are created/used. This impacts almost all tools/utilities within Lumina - please test (passed internal tests so far). This cleans up a lot of the backend XDG compliance class, moving lots of functionality into child functions of the XDGDesktop class and ensuring that they get cleaned up more regularly/properly. This *seems* to make the desktop startup a lot faster, even if the overall memory savings are slight (so far). --- src-qt5/core-utils/lumina-config/AppDialog.h | 20 +- src-qt5/core-utils/lumina-config/PanelWidget.cpp | 24 +- src-qt5/core-utils/lumina-config/PanelWidget.h | 2 +- src-qt5/core-utils/lumina-config/globals.h | 6 + src-qt5/core-utils/lumina-config/main.cpp | 3 + src-qt5/core-utils/lumina-config/mainWindow.cpp | 2 + .../lumina-config/pages/page_autostart.cpp | 43 +- .../lumina-config/pages/page_autostart.h | 2 +- .../lumina-config/pages/page_defaultapps.cpp | 196 ++----- .../lumina-config/pages/page_defaultapps.h | 4 +- .../lumina-config/pages/page_interface_desktop.cpp | 28 +- .../lumina-config/pages/page_interface_desktop.h | 2 +- .../lumina-config/pages/page_interface_menu.cpp | 20 +- .../lumina-config/pages/page_interface_menu.h | 2 +- src-qt5/core-utils/lumina-search/MainUI.cpp | 4 +- src-qt5/core-utils/lumina-search/Worker.cpp | 8 +- src-qt5/core/libLumina/LuminaUtils.cpp | 5 +- src-qt5/core/libLumina/LuminaXDG.cpp | 647 +++++++++++++++++---- src-qt5/core/libLumina/LuminaXDG.h | 55 +- src-qt5/core/lumina-desktop/AppMenu.cpp | 54 +- src-qt5/core/lumina-desktop/AppMenu.h | 5 +- src-qt5/core/lumina-desktop/LDesktop.cpp | 5 +- src-qt5/core/lumina-desktop/SettingsMenu.cpp | 5 +- .../applauncher/AppLauncherPlugin.cpp | 11 +- .../desktopview/DesktopViewPlugin.cpp | 5 +- .../panel-plugins/applauncher/AppLaunchButton.cpp | 12 +- .../panel-plugins/appmenu/LAppMenuPlugin.cpp | 43 +- .../panel-plugins/desktopbar/LDeskBar.cpp | 6 +- .../panel-plugins/systemstart/ItemWidget.cpp | 41 +- .../panel-plugins/systemstart/ItemWidget.h | 4 +- .../panel-plugins/systemstart/StartMenu.cpp | 55 +- .../panel-plugins/systemstart/StartMenu.h | 2 +- .../panel-plugins/userbutton/UserItemWidget.cpp | 36 +- .../panel-plugins/userbutton/UserItemWidget.h | 4 +- .../panel-plugins/userbutton/UserWidget.cpp | 10 +- .../panel-plugins/userbutton/UserWidget.h | 2 +- src-qt5/core/lumina-open/LFileDialog.cpp | 35 +- src-qt5/core/lumina-open/main.cpp | 22 +- src-qt5/desktop-utils/lumina-fileinfo/MainUI.cpp | 32 +- src-qt5/desktop-utils/lumina-fileinfo/MainUI.h | 6 +- .../desktop-utils/lumina-fm/widgets/DirWidget.cpp | 2 +- 41 files changed, 900 insertions(+), 570 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/core-utils/lumina-config/AppDialog.h b/src-qt5/core-utils/lumina-config/AppDialog.h index 392dbe4d..ea7615e2 100644 --- a/src-qt5/core-utils/lumina-config/AppDialog.h +++ b/src-qt5/core-utils/lumina-config/AppDialog.h @@ -9,13 +9,7 @@ #ifndef _LUMINA_FILE_MANAGER_APP_SELECT_DIALOG_H #define _LUMINA_FILE_MANAGER_APP_SELECT_DIALOG_H -#include -#include -#include -#include -#include -#include -#include +#include "globals.h" #include "ui_AppDialog.h" @@ -27,16 +21,15 @@ class AppDialog : public QDialog{ Q_OBJECT private: Ui::AppDialog *ui; - QList APPS; public: - AppDialog(QWidget *parent = 0, QList applist = QList()) : QDialog(parent), ui(new Ui::AppDialog){ + AppDialog(QWidget *parent = 0) : QDialog(parent), ui(new Ui::AppDialog){ ui->setupUi(this); //load the designer file - APPS = applist; //save this for later appreset = false; ui->comboBox->clear(); + QList APPS = LXDG::sortDesktopNames(APPSLIST->apps(false,false)); //Don't show all/hidden for(int i=0; icomboBox->addItem( LXDG::findIcon(APPS[i].icon,"application-x-executable"), APPS[i].name ); + ui->comboBox->addItem( LXDG::findIcon(APPS[i]->icon,"application-x-executable"), APPS[i]->name, APPS[i]->filePath); } this->setWindowIcon( LXDG::findIcon("system-search","") ); if(parent!=0){ @@ -56,13 +49,14 @@ public: ui->buttonBox->setStandardButtons(QDialogButtonBox::Ok | QDialogButtonBox::Cancel); } } - XDGDesktop appselected; //selected application (empty template for cancelled/reset) + + QString appselected; //selected application bool appreset; //Did the user select to reset to defaults? private slots: void on_buttonBox_accepted(){ - appselected = APPS[ ui->comboBox->currentIndex() ]; + appselected = ui->comboBox->currentData().toString(); this->close(); } void on_buttonBox_rejected(){ diff --git a/src-qt5/core-utils/lumina-config/PanelWidget.cpp b/src-qt5/core-utils/lumina-config/PanelWidget.cpp index 7132dcf8..8b38f407 100644 --- a/src-qt5/core-utils/lumina-config/PanelWidget.cpp +++ b/src-qt5/core-utils/lumina-config/PanelWidget.cpp @@ -59,9 +59,8 @@ void PanelWidget::LoadSettings(QSettings *settings, int Dnum, int Pnum){ for(int i=0; isetWhatsThis(plugs[i]); //make sure to preserve the entire plugin ID (is the unique version) ui->list_plugins->addItem(it); @@ -121,17 +120,15 @@ void PanelWidget::reloadColorSample(){ ui->label_color_sample->setStyleSheet("background: "+ui->label_color_sample->whatsThis()); } -XDGDesktop PanelWidget::getSysApp(bool allowreset){ - AppDialog dlg(this, LXDG::sortDesktopNames( LXDG::systemDesktopFiles() ) ); +QString PanelWidget::getSysApp(bool allowreset){ + AppDialog dlg(this); dlg.allowReset(allowreset); dlg.exec(); - XDGDesktop desk; if(dlg.appreset && allowreset){ - desk.filePath = "reset"; //special internal flag + return "reset"; }else{ - desk = dlg.appselected; + return dlg.appselected; } - return desk; } QString PanelWidget::getColorStyle(QString current, bool allowTransparency){ @@ -183,10 +180,11 @@ void PanelWidget::on_tool_addplugin_clicked(){ QString pan = dlg.plugID; //getNewPanelPlugin(); if(pan == "applauncher"){ //Prompt for the application to add - XDGDesktop app =getSysApp(); - if(app.filePath.isEmpty()){ return; } //cancelled - pan.append("::"+app.filePath); - QListWidgetItem *it = new QListWidgetItem( LXDG::findIcon(app.icon,""), app.name); + QString app =getSysApp(); + if(app.isEmpty()){ return; } //cancelled + pan.append("::"+app); + XDGDesktop desk(app); + QListWidgetItem *it = new QListWidgetItem( LXDG::findIcon(desk.icon,""), desk.name); it->setWhatsThis(pan); ui->list_plugins->addItem(it); ui->list_plugins->setCurrentItem(it); diff --git a/src-qt5/core-utils/lumina-config/PanelWidget.h b/src-qt5/core-utils/lumina-config/PanelWidget.h index 3f3cb360..f4e67c2d 100644 --- a/src-qt5/core-utils/lumina-config/PanelWidget.h +++ b/src-qt5/core-utils/lumina-config/PanelWidget.h @@ -39,7 +39,7 @@ private: int dnum, pnum; void reloadColorSample(); - XDGDesktop getSysApp(bool allowreset = false); + QString getSysApp(bool allowreset = false); QString getColorStyle(QString current, bool allowTransparency = true); private slots: void on_tool_rm_clicked(); diff --git a/src-qt5/core-utils/lumina-config/globals.h b/src-qt5/core-utils/lumina-config/globals.h index c96aaaa3..2a863bda 100644 --- a/src-qt5/core-utils/lumina-config/globals.h +++ b/src-qt5/core-utils/lumina-config/globals.h @@ -22,6 +22,9 @@ #include #include #include +#include +#include +#include //Now the Lumina Library classes #include @@ -31,3 +34,6 @@ #include #endif + +//Now the global class for available system applications +extern XDGDesktopList *APPSLIST; diff --git a/src-qt5/core-utils/lumina-config/main.cpp b/src-qt5/core-utils/lumina-config/main.cpp index 856570c0..8df7db48 100644 --- a/src-qt5/core-utils/lumina-config/main.cpp +++ b/src-qt5/core-utils/lumina-config/main.cpp @@ -10,6 +10,9 @@ #include #include #include +#include + +XDGDesktopList *APPSLIST = 0; int main(int argc, char ** argv) { diff --git a/src-qt5/core-utils/lumina-config/mainWindow.cpp b/src-qt5/core-utils/lumina-config/mainWindow.cpp index 5f465199..d6ada8f5 100644 --- a/src-qt5/core-utils/lumina-config/mainWindow.cpp +++ b/src-qt5/core-utils/lumina-config/mainWindow.cpp @@ -15,6 +15,8 @@ //============= mainWindow::mainWindow() : QMainWindow(), ui(new Ui::mainWindow()){ ui->setupUi(this); + APPSLIST = new XDGDesktopList(this, true); //keep this up to date while the app is open + QTimer::singleShot(100, APPSLIST, SLOT(updateList())); //don't let this hold up the initial application loading cpage = "somerandomjunktostartwith"; //Need to insert a spacer action in the toolbar QWidget *tmp = new QWidget(this); diff --git a/src-qt5/core-utils/lumina-config/pages/page_autostart.cpp b/src-qt5/core-utils/lumina-config/pages/page_autostart.cpp index b7c52fb7..371791e9 100644 --- a/src-qt5/core-utils/lumina-config/pages/page_autostart.cpp +++ b/src-qt5/core-utils/lumina-config/pages/page_autostart.cpp @@ -32,19 +32,19 @@ page_autostart::~page_autostart(){ // PUBLIC SLOTS //================ void page_autostart::SaveSettings(){ - QList STARTAPPS = LXDG::findAutoStartFiles(true); //also want invalid/disabled items + QList STARTAPPS = LXDG::findAutoStartFiles(true); //also want invalid/disabled items //bool newstartapps = false; for(int i=0; ilist_session_start->count(); i++){ QString file = ui->list_session_start->item(i)->whatsThis(); bool enabled = ui->list_session_start->item(i)->checkState()==Qt::Checked; bool found = false; for(int i=0; ifilePath==file){ found = true; - if(enabled != !STARTAPPS[i].isHidden){ + if(enabled != !STARTAPPS[i]->isHidden){ //value is different - qDebug() << "Setting Autostart:" << enabled << STARTAPPS[i].filePath; - LXDG::setAutoStarted(enabled, STARTAPPS[i]); + qDebug() << "Setting Autostart:" << enabled << STARTAPPS[i]->filePath; + STARTAPPS[i]->setAutoStarted(enabled); } break; } @@ -55,25 +55,29 @@ void page_autostart::SaveSettings(){ LXDG::setAutoStarted(enabled, file); //newstartapps = true; } - } + } //end loop over GUI items + //Now cleanup all the STARTAPPS data + for(int i=0; STARTAPPS.length(); i++){ STARTAPPS[i]->deleteLater(); } } void page_autostart::LoadSettings(int){ emit HasPendingChanges(false); emit ChangePageTitle( tr("Startup Services") ); - QList STARTAPPS = LXDG::findAutoStartFiles(true); //also want invalid/disabled items + QList STARTAPPS = LXDG::findAutoStartFiles(true); //also want invalid/disabled items //qDebug() << "StartApps:"; ui->list_session_start->clear(); for(int i=0; i " +STARTAPPS[i].name << STARTAPPS[i].isHidden; - if( !LXDG::checkValidity(STARTAPPS[i],false) || !QFile::exists(STARTAPPS[i].filePath) ){ continue; } - QListWidgetItem *it = new QListWidgetItem( LXDG::findIcon(STARTAPPS[i].icon,"application-x-executable"), STARTAPPS[i].name ); - it->setWhatsThis(STARTAPPS[i].filePath); //keep the file location - it->setToolTip(STARTAPPS[i].comment); - if(STARTAPPS[i].isHidden){ it->setCheckState( Qt::Unchecked); } + if( !STARTAPPS[i]->isValid() || !QFile::exists(STARTAPPS[i]->filePath) ){ continue; } + QListWidgetItem *it = new QListWidgetItem( LXDG::findIcon(STARTAPPS[i]->icon,"application-x-executable"), STARTAPPS[i]->name ); + it->setWhatsThis(STARTAPPS[i]->filePath); //keep the file location + it->setToolTip(STARTAPPS[i]->comment); + if(STARTAPPS[i]->isHidden){ it->setCheckState( Qt::Unchecked); } else{it->setCheckState( Qt::Checked); } ui->list_session_start->addItem(it); } + //Now cleanup all the STARTAPPS data + for(int i=0; STARTAPPS.length(); i++){ STARTAPPS[i]->deleteLater(); } } void page_autostart::updateIcons(){ @@ -85,17 +89,15 @@ void page_autostart::updateIcons(){ //================= // PRIVATE //================= -XDGDesktop page_autostart::getSysApp(bool allowreset){ - AppDialog dlg(this, LXDG::sortDesktopNames( LXDG::systemDesktopFiles() ) ); +QString page_autostart::getSysApp(bool allowreset){ + AppDialog dlg(this); dlg.allowReset(allowreset); dlg.exec(); - XDGDesktop desk; if(dlg.appreset && allowreset){ - desk.filePath = "reset"; //special internal flag + return "reset"; }else{ - desk = dlg.appselected; + return dlg.appselected; } - return desk; } //================= @@ -109,8 +111,9 @@ void page_autostart::rmsessionstartitem(){ void page_autostart::addsessionstartapp(){ //Prompt for the application to start - XDGDesktop desk = getSysApp(false); //no reset - if(desk.filePath.isEmpty()){ return; } //cancelled + QString app = getSysApp(false); //no reset + if(app.isEmpty()){ return; } //cancelled + XDGDesktop desk(app); QListWidgetItem *it = new QListWidgetItem( LXDG::findIcon(desk.icon,""), desk.name ); it->setWhatsThis(desk.filePath); it->setToolTip(desk.comment); diff --git a/src-qt5/core-utils/lumina-config/pages/page_autostart.h b/src-qt5/core-utils/lumina-config/pages/page_autostart.h index 88f1ef94..60868598 100644 --- a/src-qt5/core-utils/lumina-config/pages/page_autostart.h +++ b/src-qt5/core-utils/lumina-config/pages/page_autostart.h @@ -27,7 +27,7 @@ public slots: private: Ui::page_autostart *ui; - XDGDesktop getSysApp(bool allowreset); + QString getSysApp(bool allowreset); private slots: void rmsessionstartitem(); diff --git a/src-qt5/core-utils/lumina-config/pages/page_defaultapps.cpp b/src-qt5/core-utils/lumina-config/pages/page_defaultapps.cpp index e55beba6..b2a0896c 100644 --- a/src-qt5/core-utils/lumina-config/pages/page_defaultapps.cpp +++ b/src-qt5/core-utils/lumina-config/pages/page_defaultapps.cpp @@ -48,9 +48,8 @@ void page_defaultapps::LoadSettings(int){ if(tmp.isEmpty()){ tmp = "lumina-fm"; } if( !QFile::exists(tmp) && !LUtils::isValidBinary(tmp) ){ qDebug() << "Invalid Settings:" << tmp; tmp.clear(); } //invalid settings if(tmp.endsWith(".desktop")){ - bool ok = false; - XDGDesktop file = LXDG::loadDesktopFile(tmp, ok); - if(!ok || file.filePath.isEmpty()){ + XDGDesktop file(tmp); + if(file.type == XDGDesktop::BAD){ //Might be a binary - just print out the raw "path" ui->tool_default_filemanager->setText(tmp.section("/",-1)); ui->tool_default_filemanager->setIcon( LXDG::findIcon("application-x-executable","") ); @@ -70,9 +69,8 @@ void page_defaultapps::LoadSettings(int){ tmp =LXDG::findDefaultAppForMime("application/terminal"); //sessionsettings->value("default-terminal", "xterm").toString(); if( !QFile::exists(tmp) && !LUtils::isValidBinary(tmp) ){ qDebug() << "Invalid Settings:" << tmp; tmp.clear(); } //invalid settings if(tmp.endsWith(".desktop")){ - bool ok = false; - XDGDesktop file = LXDG::loadDesktopFile(tmp, ok); - if(!ok || file.filePath.isEmpty()){ + XDGDesktop file(tmp); + if(file.type == XDGDesktop::BAD){ //Might be a binary - just print out the raw "path" ui->tool_default_terminal->setText(tmp.section("/",-1)); ui->tool_default_terminal->setIcon( LXDG::findIcon("application-x-executable","") ); @@ -92,9 +90,8 @@ void page_defaultapps::LoadSettings(int){ tmp = LXDG::findDefaultAppForMime("x-scheme-handler/http"); //appsettings->value("default/webbrowser", "").toString(); if( !QFile::exists(tmp) && !LUtils::isValidBinary(tmp) ){ qDebug() << "Invalid Settings:" << tmp; tmp.clear(); } //invalid settings if(tmp.endsWith(".desktop")){ - bool ok = false; - XDGDesktop file = LXDG::loadDesktopFile(tmp, ok); - if(!ok || file.filePath.isEmpty()){ + XDGDesktop file(tmp); + if(file.type == XDGDesktop::BAD){ //Might be a binary - just print out the raw "path" ui->tool_default_webbrowser->setText(tmp.section("/",-1)); ui->tool_default_webbrowser->setIcon( LXDG::findIcon("application-x-executable","") ); @@ -114,9 +111,8 @@ void page_defaultapps::LoadSettings(int){ tmp = LXDG::findDefaultAppForMime("application/email"); //appsettings->value("default/email", "").toString(); if( !QFile::exists(tmp) && !LUtils::isValidBinary(tmp) ){ qDebug() << "Invalid Settings:" << tmp; tmp.clear(); } //invalid settings if(tmp.endsWith(".desktop")){ - bool ok = false; - XDGDesktop file = LXDG::loadDesktopFile(tmp, ok); - if(!ok || file.filePath.isEmpty()){ + XDGDesktop file(tmp); + if(file.type == XDGDesktop::BAD){ //Might be a binary - just print out the raw "path" ui->tool_default_email->setText(tmp.section("/",-1)); ui->tool_default_email->setIcon( LXDG::findIcon("application-x-executable","") ); @@ -165,9 +161,8 @@ void page_defaultapps::LoadSettings(int){ //Now load the default (if there is one) it->setWhatsThis(1,def); //save for later if(def.endsWith(".desktop")){ - bool ok = false; - XDGDesktop file = LXDG::loadDesktopFile(def, ok); - if(!ok || file.filePath.isEmpty()){ + XDGDesktop file(def); + if(file.type == XDGDesktop::BAD){ //Might be a binary - just print out the raw "path" it->setText(1,def.section("/",-1)); it->setIcon(1, LXDG::findIcon("application-x-executable","") ); @@ -199,150 +194,80 @@ void page_defaultapps::updateIcons(){ //================= // PRIVATE //================= -XDGDesktop page_defaultapps::getSysApp(bool allowreset){ - AppDialog dlg(this, LXDG::sortDesktopNames( LXDG::systemDesktopFiles() ) ); +QString page_defaultapps::getSysApp(bool allowreset){ + AppDialog dlg(this); dlg.allowReset(allowreset); dlg.exec(); - XDGDesktop desk; if(dlg.appreset && allowreset){ - desk.filePath = "reset"; //special internal flag + return "reset"; }else{ - desk = dlg.appselected; + return dlg.appselected; } - return desk; } -//================= -// PRIVATE SLOTS -//================= -void page_defaultapps::changeDefaultBrowser(){ - //Prompt for the new app - XDGDesktop desk = getSysApp(true); - if(desk.filePath.isEmpty()){ return; }//nothing selected - if(desk.filePath=="reset"){ - desk.filePath=""; - } - //save the new app setting and adjust the button appearance - //appsettings->setValue("default/webbrowser", desk.filePath); - LXDG::setDefaultAppForMime("x-scheme-handler/http", desk.filePath.section("/",-1)); - LXDG::setDefaultAppForMime("x-scheme-handler/https", desk.filePath.section("/",-1)); - QString tmp = desk.filePath; - if(tmp.endsWith(".desktop")){ - bool ok = false; - XDGDesktop file = LXDG::loadDesktopFile(tmp, ok); - if(!ok || file.filePath.isEmpty()){ +void page_defaultapps::updateDefaultButton(QToolButton *button, QString app){ + if(app.endsWith(".desktop")){ + XDGDesktop file(app); + if(file.type == XDGDesktop::BAD){ //Might be a binary - just print out the raw "path" - ui->tool_default_webbrowser->setText(tmp.section("/",-1)); - ui->tool_default_webbrowser->setIcon( LXDG::findIcon("application-x-executable","") ); + button->setText(app.section("/",-1)); + button->setIcon( LXDG::findIcon("application-x-executable","") ); }else{ - ui->tool_default_webbrowser->setText(desk.name); - ui->tool_default_webbrowser->setIcon(LXDG::findIcon(desk.icon,"") ); + button->setText(file.name); + button->setIcon(LXDG::findIcon(file.icon,"") ); } - }else if(tmp.isEmpty()){ - ui->tool_default_webbrowser->setText(tr("Click to Set")); - ui->tool_default_webbrowser->setIcon( LXDG::findIcon("system-help","") ); + }else if(app.isEmpty()){ + button->setText(tr("Click to Set")); + button->setIcon( LXDG::findIcon("system-help","") ); }else{ //Might be a binary - just print out the raw "path" - ui->tool_default_webbrowser->setText(tmp.section("/",-1)); - ui->tool_default_webbrowser->setIcon( LXDG::findIcon("application-x-executable","") ); + button->setText(app.section("/",-1)); + button->setIcon( LXDG::findIcon("application-x-executable","") ); } } +//================= +// PRIVATE SLOTS +//================= +void page_defaultapps::changeDefaultBrowser(){ + //Prompt for the new app + QString app = getSysApp(true); + if(app.isEmpty()){ return; }//nothing selected + if(app=="reset"){ app.clear(); } + //save the new app setting and adjust the button appearance + LXDG::setDefaultAppForMime("x-scheme-handler/http", app.section("/",-1)); + LXDG::setDefaultAppForMime("x-scheme-handler/https", app.section("/",-1)); + updateDefaultButton(ui->tool_default_webbrowser, app); +} + void page_defaultapps::changeDefaultEmail(){ //Prompt for the new app - XDGDesktop desk = getSysApp(true); //allow reset to default - if(desk.filePath.isEmpty()){ return; }//nothing selected - if(desk.filePath=="reset"){ - desk.filePath=""; - } + QString app = getSysApp(true); + if(app.isEmpty()){ return; }//nothing selected + if(app=="reset"){ app.clear(); } //save the new app setting and adjust the button appearance - LXDG::setDefaultAppForMime("application/email",desk.filePath); - // appsettings->setValue("default/email", desk.filePath); - QString tmp = desk.filePath; - if(tmp.endsWith(".desktop")){ - bool ok = false; - XDGDesktop file = LXDG::loadDesktopFile(tmp, ok); - if(!ok || file.filePath.isEmpty()){ - //Might be a binary - just print out the raw "path" - ui->tool_default_email->setText(tmp.section("/",-1)); - ui->tool_default_email->setIcon( LXDG::findIcon("application-x-executable","") ); - }else{ - ui->tool_default_email->setText(file.name); - ui->tool_default_email->setIcon(LXDG::findIcon(file.icon,"") ); - } - }else if(tmp.isEmpty()){ - ui->tool_default_email->setText(tr("Click to Set")); - ui->tool_default_email->setIcon( LXDG::findIcon("system-help","") ); - }else{ - //Might be a binary - just print out the raw "path" - ui->tool_default_email->setText(tmp.section("/",-1)); - ui->tool_default_email->setIcon( LXDG::findIcon("application-x-executable","") ); - } + LXDG::setDefaultAppForMime("application/email",app.section("/",-1)); + updateDefaultButton(ui->tool_default_email, app); } void page_defaultapps::changeDefaultFileManager(){ //Prompt for the new app - XDGDesktop desk = getSysApp(true); - if(desk.filePath.isEmpty()){ return; }//nothing selected - if(desk.filePath=="reset"){ - desk.filePath="lumina-fm"; - } + QString app = getSysApp(true); + if(app.isEmpty()){ return; }//nothing selected + if(app=="reset"){ app = "lumina-fm"; } //save the new app setting and adjust the button appearance - //appsettings->setValue("default/directory", desk.filePath); - //sessionsettings->setValue("default-filemanager", desk.filePath); - LXDG::setDefaultAppForMime("inode/directory", desk.filePath.section("/",-1)); - QString tmp = desk.filePath; - if(tmp.endsWith(".desktop")){ - bool ok = false; - XDGDesktop file = LXDG::loadDesktopFile(tmp, ok); - if(!ok || file.filePath.isEmpty()){ - //Might be a binary - just print out the raw "path" - ui->tool_default_filemanager->setText(tmp.section("/",-1)); - ui->tool_default_filemanager->setIcon( LXDG::findIcon("application-x-executable","") ); - }else{ - ui->tool_default_filemanager->setText(file.name); - ui->tool_default_filemanager->setIcon(LXDG::findIcon(file.icon,"") ); - } - }else if(tmp.isEmpty()){ - ui->tool_default_filemanager->setText(tr("Click to Set")); - ui->tool_default_filemanager->setIcon( LXDG::findIcon("system-help","") ); - }else{ - //Might be a binary - just print out the raw "path" - ui->tool_default_filemanager->setText(tmp.section("/",-1)); - ui->tool_default_filemanager->setIcon( LXDG::findIcon("application-x-executable","") ); - } + LXDG::setDefaultAppForMime("inode/directory", app.section("/",-1)); + updateDefaultButton(ui->tool_default_filemanager, app); } void page_defaultapps::changeDefaultTerminal(){ //Prompt for the new app - XDGDesktop desk = getSysApp(true); - if(desk.filePath.isEmpty()){ return; }//nothing selected - if(desk.filePath=="reset"){ - desk.filePath="xterm"; - } + QString app = getSysApp(true); + if(app.isEmpty()){ return; }//nothing selected + if(app=="reset"){ app = "xterm"; } //save the new app setting and adjust the button appearance - LXDG::setDefaultAppForMime("application/terminal",desk.filePath); - //sessionsettings->setValue("default-terminal", desk.filePath); - QString tmp = desk.filePath; - if(tmp.endsWith(".desktop")){ - bool ok = false; - XDGDesktop file = LXDG::loadDesktopFile(tmp, ok); - if(!ok || file.filePath.isEmpty()){ - //Might be a binary - just print out the raw "path" - ui->tool_default_terminal->setText(tmp.section("/",-1)); - ui->tool_default_terminal->setIcon( LXDG::findIcon("application-x-executable","") ); - }else{ - ui->tool_default_terminal->setText(file.name); - ui->tool_default_terminal->setIcon(LXDG::findIcon(file.icon,"") ); - } - }else if(tmp.isEmpty()){ - ui->tool_default_terminal->setText(tr("Click to Set")); - ui->tool_default_terminal->setIcon( LXDG::findIcon("system-help","") ); - }else{ - //Might be a binary - just print out the raw "path" - ui->tool_default_terminal->setText(tmp.section("/",-1)); - ui->tool_default_terminal->setIcon( LXDG::findIcon("application-x-executable","") ); - } + LXDG::setDefaultAppForMime("application/terminal", app.section("/",-1) ); + updateDefaultButton(ui->tool_default_terminal, app); } void page_defaultapps::cleardefaultitem(){ @@ -374,14 +299,15 @@ void page_defaultapps::setdefaultitem(){ } if(list.isEmpty()){ list << it; } //just do the current item //Prompt for which application to use - XDGDesktop desk = getSysApp(false); //no "reset" option - if(desk.filePath.isEmpty()){ return; }//nothing selected + QString app = getSysApp(false); //no "reset" option + if(app.isEmpty()){ return; }//nothing selected //Now set the items for(int i=0; iwhatsThis(0), desk.filePath); + LXDG::setDefaultAppForMime(list[i]->whatsThis(0), app.section("/",-1)); //Set it in the UI - list[i]->setWhatsThis(1,desk.filePath); //app path + XDGDesktop desk(app); + list[i]->setWhatsThis(1,app); //app path list[i]->setIcon(1,LXDG::findIcon(desk.icon,"")); //reset the icon list[i]->setText(1,desk.name); //reset the name } diff --git a/src-qt5/core-utils/lumina-config/pages/page_defaultapps.h b/src-qt5/core-utils/lumina-config/pages/page_defaultapps.h index afe99d4b..f80ea1ab 100644 --- a/src-qt5/core-utils/lumina-config/pages/page_defaultapps.h +++ b/src-qt5/core-utils/lumina-config/pages/page_defaultapps.h @@ -27,7 +27,9 @@ public slots: private: Ui::page_defaultapps *ui; - XDGDesktop getSysApp(bool allowreset); + QString getSysApp(bool allowreset); + + void updateDefaultButton(QToolButton *button, QString app); private slots: //Simple defaults tab diff --git a/src-qt5/core-utils/lumina-config/pages/page_interface_desktop.cpp b/src-qt5/core-utils/lumina-config/pages/page_interface_desktop.cpp index 7a52959a..fdcde804 100644 --- a/src-qt5/core-utils/lumina-config/pages/page_interface_desktop.cpp +++ b/src-qt5/core-utils/lumina-config/pages/page_interface_desktop.cpp @@ -69,9 +69,8 @@ void page_interface_desktop::LoadSettings(int screennum){ dplugs[i] = dplugs[i].section("---",0,0); } if(dplugs[i].startsWith("applauncher::")){ - bool ok = false; - XDGDesktop app = LXDG::loadDesktopFile(dplugs[i].section("::",1,50), ok); - if(!ok){ continue; } //invalid for some reason + XDGDesktop app(dplugs[i].section("::",1,50)); + if(app.type == XDGDesktop::BAD){ continue; } //invalid for some reason //Now fill the item with the necessary info it->setText(app.name); it->setIcon(LXDG::findIcon(app.icon,"") ); @@ -97,17 +96,15 @@ void page_interface_desktop::updateIcons(){ //================= // PRIVATE //================= -XDGDesktop page_interface_desktop::getSysApp(bool allowreset){ - AppDialog dlg(this, LXDG::sortDesktopNames( LXDG::systemDesktopFiles() ) ); +QString page_interface_desktop::getSysApp(bool allowreset){ + AppDialog dlg(this); dlg.allowReset(allowreset); dlg.exec(); - XDGDesktop desk; if(dlg.appreset && allowreset){ - desk.filePath = "reset"; //special internal flag + return "reset"; }else{ - desk = dlg.appselected; + return dlg.appselected; } - return desk; } //================= @@ -122,14 +119,15 @@ void page_interface_desktop::deskplugadded(){ QListWidgetItem *it = new QListWidgetItem(); if(newplug=="applauncher"){ //Prompt for the application to add - XDGDesktop app = getSysApp(); - if(app.filePath.isEmpty()){ return; } //cancelled - newplug.append("::"+app.filePath); + QString app = getSysApp(); + if(app.isEmpty()){ return; } //cancelled + newplug.append("::"+app); + XDGDesktop desk(app); //Now fill the item with the necessary info it->setWhatsThis(newplug); - it->setText(app.name); - it->setIcon(LXDG::findIcon(app.icon,"") ); - it->setToolTip(app.comment); + it->setText(desk.name); + it->setIcon(LXDG::findIcon(desk.icon,"") ); + it->setToolTip(desk.comment); }else{ //Load the info for this plugin LPI info = PINFO->desktopPluginInfo(newplug); diff --git a/src-qt5/core-utils/lumina-config/pages/page_interface_desktop.h b/src-qt5/core-utils/lumina-config/pages/page_interface_desktop.h index e212182a..cfeb7f8c 100644 --- a/src-qt5/core-utils/lumina-config/pages/page_interface_desktop.h +++ b/src-qt5/core-utils/lumina-config/pages/page_interface_desktop.h @@ -33,7 +33,7 @@ private: LPlugins *PINFO; //Get an application on the system - XDGDesktop getSysApp(bool allowreset = false); + QString getSysApp(bool allowreset = false); private slots: void deskplugadded(); diff --git a/src-qt5/core-utils/lumina-config/pages/page_interface_menu.cpp b/src-qt5/core-utils/lumina-config/pages/page_interface_menu.cpp index d211d380..370980d2 100644 --- a/src-qt5/core-utils/lumina-config/pages/page_interface_menu.cpp +++ b/src-qt5/core-utils/lumina-config/pages/page_interface_menu.cpp @@ -53,9 +53,8 @@ QStringList items = settings.value("menu/itemlist", QStringList() ).toStringList ui->list_menu->clear(); for(int i=0; isetWhatsThis( items[i] ); item->setIcon( LXDG::findIcon(desk.icon) ); @@ -99,17 +98,15 @@ void page_interface_menu::updateIcons(){ //================= // PRIVATE //================= -XDGDesktop page_interface_menu::getSysApp(bool allowreset){ - AppDialog dlg(this, LXDG::sortDesktopNames( LXDG::systemDesktopFiles() ) ); +QString page_interface_menu::getSysApp(bool allowreset){ + AppDialog dlg(this); dlg.allowReset(allowreset); dlg.exec(); - XDGDesktop desk; if(dlg.appreset && allowreset){ - desk.filePath = "reset"; //special internal flag + return "reset"; }else{ - desk = dlg.appselected; + return dlg.appselected; } - return desk; } //================= @@ -127,9 +124,10 @@ void page_interface_menu::addmenuplugin(){ if(info.ID=="app"){ //Need to prompt for the exact application to add to the menu // Note: whatsThis() format: "app::::< *.desktop file path >" - XDGDesktop desk = getSysApp(); - if(desk.filePath.isEmpty()){ return; }//nothing selected + QString app = getSysApp(); + if(app.isEmpty()){ return; }//nothing selected //Create the item for the list + XDGDesktop desk(app); it = new QListWidgetItem(LXDG::findIcon(desk.icon,""), desk.name ); it->setWhatsThis(info.ID+"::::"+desk.filePath); it->setToolTip( desk.comment ); diff --git a/src-qt5/core-utils/lumina-config/pages/page_interface_menu.h b/src-qt5/core-utils/lumina-config/pages/page_interface_menu.h index f2a53007..16f80385 100644 --- a/src-qt5/core-utils/lumina-config/pages/page_interface_menu.h +++ b/src-qt5/core-utils/lumina-config/pages/page_interface_menu.h @@ -29,7 +29,7 @@ private: Ui::page_interface_menu *ui; LPlugins *PINFO; //Get an application on the system - XDGDesktop getSysApp(bool allowreset = false); + QString getSysApp(bool allowreset = false); private slots: void addmenuplugin(); diff --git a/src-qt5/core-utils/lumina-search/MainUI.cpp b/src-qt5/core-utils/lumina-search/MainUI.cpp index 99b04b2b..93ee7411 100644 --- a/src-qt5/core-utils/lumina-search/MainUI.cpp +++ b/src-qt5/core-utils/lumina-search/MainUI.cpp @@ -169,8 +169,8 @@ void MainUI::foundSearchItem(QString path){ //Now setup the visuals if(path.simplified().endsWith(".desktop")){ bool ok = false; - XDGDesktop desk = LXDG::loadDesktopFile(path,ok); - if( !ok || !LXDG::checkValidity(desk) ){delete it; return; } //invalid file + XDGDesktop desk(path); + if( !desk.isValid() ){delete it; return; } //invalid file it->setText(desk.name); it->setIcon( LXDG::findIcon(desk.icon, "application-x-desktop") ); }else{ diff --git a/src-qt5/core-utils/lumina-search/Worker.cpp b/src-qt5/core-utils/lumina-search/Worker.cpp index b414a72f..025bcc1e 100644 --- a/src-qt5/core-utils/lumina-search/Worker.cpp +++ b/src-qt5/core-utils/lumina-search/Worker.cpp @@ -6,11 +6,13 @@ Worker::Worker(QObject *parent) : QObject(parent){ //Get the list of all applications and save them in an easily-searchable form - QList apps = LXDG::systemDesktopFiles(); + QList apps = LXDG::systemDesktopFiles(); for(int i=0; iname+":::2:::"+apps[i]->genericName+":::3:::"+apps[i]->comment+":::4:::"+apps[i]->filePath; } stopsearch = false; + //Clean up all the apps structures + for(int i=0; ideleteLater(); } } Worker::~Worker(){ @@ -108,4 +110,4 @@ void Worker::beginsearch(){ } emit SearchUpdate( tr("Search Finished") ); emit SearchDone(); -} \ No newline at end of file +} diff --git a/src-qt5/core/libLumina/LuminaUtils.cpp b/src-qt5/core/libLumina/LuminaUtils.cpp index 1ab3faac..dd4c75c4 100644 --- a/src-qt5/core/libLumina/LuminaUtils.cpp +++ b/src-qt5/core/libLumina/LuminaUtils.cpp @@ -159,9 +159,8 @@ QString LUtils::GenerateOpenTerminalExec(QString term, QString dirpath){ //if(!LUtils::isValidBinary(term)){ if(term.endsWith(".desktop")){ //Pull the binary name out of the shortcut - bool ok = false; - XDGDesktop DF = LXDG::loadDesktopFile(term,ok); - if(!ok){ term = "xterm"; } + XDGDesktop DF(term); + if(DF.type == XDGDesktop::BAD){ term = "xterm"; } else{ term= DF.exec.section(" ",0,0); } //only take the binary name - not any other flags }else{ term = "xterm"; //fallback diff --git a/src-qt5/core/libLumina/LuminaXDG.cpp b/src-qt5/core/libLumina/LuminaXDG.cpp index 36b05676..0e33f254 100644 --- a/src-qt5/core/libLumina/LuminaXDG.cpp +++ b/src-qt5/core/libLumina/LuminaXDG.cpp @@ -15,10 +15,396 @@ static QStringList mimeglobs; static qint64 mimechecktime; +//============================= +// XDGDesktop CLASS +//============================= +XDGDesktop::XDGDesktop(QString file, QObject *parent) : QObject(parent){ + isHidden=false; + useTerminal=false; + startupNotify=false; + type = XDGDesktop::BAD; + filePath = file; + exec = tryexec = ""; // just to make sure this is initialized + if(!filePath.isEmpty()){ sync(); } //if an input file is given - go ahead and sync now +} + +void XDGDesktop::sync(){ + //Reset internal vars + isHidden=false; + useTerminal=false; + startupNotify=false; + type = XDGDesktop::BAD; + exec = tryexec = ""; + //Read in the File + if(!filePath.endsWith(".desktop")){ return; } + lastRead = QDateTime::currentDateTime(); + QStringList file = LUtils::readFile(filePath); + if(file.isEmpty()){ return; } //done with init right here - nothing to load + //Get the current localization code + type = XDGDesktop::APP; //assume this initially if we read the file properly + QString lang = QLocale::system().name(); //lang code + QString slang = lang.section("_",0,0); //short lang code + //Now start looping over the information + XDGDesktopAction CDA; //current desktop action + bool insection=false; + bool inaction=false; + for(int i=0; i - DirWidget - - - Form - Formulário - - - - - Open item - Abrir item - - - - - Open item (select application) - Abrir item (selecionar aplicativo) - - - - - Add item to personal favorites - Adicionar item aos favoritos pessoais - - - - - Rename item - Renomear item - - - - Cut items - Recortar itens - + BrowserWidget - - Cut items (add to the clipboard) - Recortar itens (adicionar na área de transferência) - - - - Copy items - Copiar itens + + Name + Nome - - Copy items to the clipboard - Copiar itens para a área de transferência + + Size + Tamanho - - - Paste items from clipboard - Colar itens da área de transferência + + Type + Tipo - - - Delete Items - Excluir itens + + Date Modified + Modificado em - - Stop loading the directory - Parar o carregamento do diretório + + Date Created + Criado em - - Add selected images to slideshow - Adiciona as imagens selecionadas na apresentação de slides + + Capacity: %1 + Capacidade: %1 - - Create a new directory - Criar um novo diretório + + Files: %1 (%2) + Arquivos: %1 (%2) - - New Dir - Nova pasta + + Files: %1 + - - Create a new file - Criar um novo arquivo + + Dirs: %1 + Pastas: %1 - - New File - Novo arquivo + + No Directory Contents + + + + DirWidget - - Slideshow - Apresentação de slides + + Form + Formulário - - Enqueue selection in multimedia player - Adicionar seleção para uma lista no reprodutor de multimídia + + Increase Icon Sizes + - - Play - Reproduzir + + Decrease Icon Sizes + - + Back Voltar - - + + Go back to previous directory Voltar para a pasta anterior - + Up Acima - - + + Go to parent directory Ir para pasta-pai - + Home Inicio - - + + Go to home directory Ir para a pasta inicial - - - Close this browser - Fechar este navegador + + Menu + - - Name - Nome + + Select Action + - - Size - Tamanho + + SingleColumn + - - Type - Tipo + + Single column view + - - Date Modified - Modificado em + + Dual Column + - - Date Created - Criado em + + Dual Column View + - - + (Limited Access) (Acesso limitado) - - Capacity: %1 - Capacidade: %1 - - - - Files: %1 (%2) - Arquivos: %1 (%2) - - - - Dirs: %1 - Pastas: %1 - - - + + New Document Novo Documento - - + + + Name: Nome: - + Error Creating Document Erro ao Criar Documento - + The document could not be created. Please ensure that you have the proper permissions. O documento não pode ser criado. Por favor, certifique-se que possuí permissão necessária. - + New Directory Novo Diretório - + + + Invalid Name Nome Inválido - + + File Operations + + + + + Directory Operations + + + + + Loading... + + + + + + A file or directory with that name already exists! Please pick a different name. Já existe um arquivo ou pasta com este nome. Por favor, use um nome diferente. - + Error Creating Directory Erro ao Criar Pasta - + The directory could not be created. Please ensure that you have the proper permissions to modify the current directory. A pasta não pode ser criada. Por favor, verifique suas permissões. - + Current Atual - + + Create... + + + + + File + Arquivo + + + + Directory + + + + + Application Launcher + + + + + Launch... + + + + + Terminal + + + + + SlideShow + + + + + Multimedia Player + + + + + Modify Files... + + + + + View Files... + + + + + Checksums + + + + + Properties + + + + File Checksums: Arquivo checksum: - + Missing Utility Utilitário faltando - + The "lumina-fileinfo" utility could not be found on the system. Please install it first. O "lumina-fileinfo" não pode ser encontrado no sistema. Por favor, instale-o... - + Open Abrir - + Open With... Abrir com... - + Rename... Renomear... - - View Checksums... - Ver Checksums... - - - - File Properties... - Propriedades do arquivo... - - - + Cut Selection Cortar seleção - + Copy Selection Copiar seleção - + Paste Colar - + Delete Selection Excluir seleção - - - Open Terminal here - Abrir terminal aqui - FODialog @@ -582,12 +593,12 @@ Nova Localização: %2 Insight - + Shift+Left Shift+Esquerdo - + Shift+Right Shift+Direito @@ -607,363 +618,342 @@ Nova Localização: %2 Modo de Visualização - - Group Mode - Modo de grupo - - - + Bookmarks Marcadores - + External Devices Dispositivos externos - - Edit - Editar + + Git + - - Git + + New Tab - - + New Browser Novo Navegador - + Search Directory... Pesquisar Pasta... - + Increase Icon Size Aumentar tamanho do Ícone - + Decrease Icon Size Diminuir tamanho da ícone - + Larger Icons Ícones maiores - + Ctrl++ Ctrl++ - + Smaller Icons Ícones pequenos - + Ctrl+- Ctrl+- - + New Window Nova janela - + Ctrl+N Ctrl+N - + Add Bookmark Adicionar Marcador - + Ctrl+D Ctrl+D - + Delete Selection Excluir seleção - + Del Del - + Refresh Atualizar - - Close Browser - Fechar Navegador + + Close Tab + - + Repo Status - + Clone Repository - + Ctrl+T Ctrl+T - + Exit Sair - + Ctrl+Q Ctrl+Q - + &Preferences &Preferências - + Show Hidden Files Mostrar arquivos ocultos - + Scan for Devices Procurar por dispositivos - + Manage Bookmarks Gerenciar marcadores - + Show Action Buttons Exibir botões de ação - + Load Thumbnails Carregar miniaturas - + Ctrl+F Ctrl+F - + Detailed List Lista detalhada - + Basic List Lista básica - + Ctrl+W Ctrl+W - - Prefer Tabs - Prefer. abas - - - - Prefer Columns - Preferência das Colunas - - - + F5 F5 - + Ctrl+C Ctrl+C - + Rename... Renomear... - + F2 F2 - + Cut Selection Recortar seleção - + Copy Selection Copiar seleção - + Paste Colar - + Ctrl+V Ctrl+V - + Ctrl+X Ctrl+X - + Invalid Directories Diretórios inválidos - + The following directories are invalid and could not be opened: Os seguintes diretórios são inválidos e não podem ser abertos: - + Root Root - + %1 (Type: %2) %1 (Tipo: %2) - + Filesystem: %1 Sistema de arquivos: %1 - - Browser - Navegador - - - + New Bookmark Novo Marcador - + Name: Nome: - + Invalid Name Nome inválido - + This bookmark name already exists. Please choose another. Este nome de marcador já existe. Por favor, escolha outro. - + Git Repository Status - + Multimedia Multimídia - + Slideshow Apresentação de slides - + Items to be removed: Itens para ser removidos: - + Verify Quit Confirmar saída - + Ctrl+H Ctrl+H - + Ctrl+L - + You have multiple tabs open. Are you sure you want to quit? Você possui várias abas abertas. Deseja realmente sair? - + Verify Removal Confirmar remoção - + WARNING: This will permanently delete the file(s) from the system! ATENÇÃO: Isto irá remover permanentemente o(s) arquivo(s) do sistema! - + Are you sure you want to continue? Você tem certeza de que deseja continuar? - + Rename File Renomear arquivo - + New Name: Novo nome: - + Overwrite File? Substituir arquivo? - + An existing file with the same name will be replaced. Are you sure you want to proceed? Um arquivo existente com o mesmo nome será substituído. Tem certeza de que deseja continuar? @@ -1006,6 +996,50 @@ Nova Localização: %2 Concluído + + OPWidget + + + Form + Formulário + + + + + ... + ... + + + + Evaluating... + + + + + Move + + + + + Copy + + + + + Remove + + + + + %1 Finished + + + + + Errors Occured + + + SlideshowWidget @@ -1109,4 +1143,22 @@ Nova Localização: %2 Você tem certeza de que deseja continuar? + + TrayUI + + + Finished + Concluído + + + + Errors during operation. Click to view details + + + + + No Errors + + + diff --git a/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_ro.ts b/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_ro.ts index 20550897..629ab157 100644 --- a/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_ro.ts +++ b/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_ro.ts @@ -55,314 +55,325 @@ - DirWidget + BrowserWidget - - Form + + Name - - - Open item + + Size - - - Open item (select application) + + Type - - - Add item to personal favorites + + Date Modified - - - Rename item + + Date Created - - Cut items + + Capacity: %1 - - Cut items (add to the clipboard) + + Files: %1 (%2) - - Copy items + + Files: %1 - - Copy items to the clipboard + + Dirs: %1 - - - Paste items from clipboard + + No Directory Contents + + + DirWidget - - - Delete Items + + Form - - Stop loading the directory + + Increase Icon Sizes - - Add selected images to slideshow + + Decrease Icon Sizes - - Create a new directory + + Back - - New Dir + + + Go back to previous directory - - Create a new file + + Up - - New File + + + Go to parent directory - - Slideshow + + Home - - Enqueue selection in multimedia player + + + Go to home directory - - Play + + Menu - - Back + + Select Action - - - Go back to previous directory + + SingleColumn - - Up + + Single column view - - - Go to parent directory + + Dual Column - - Home + + Dual Column View - - - Go to home directory + + (Limited Access) - - - Close this browser + + + New Document - - Name + + + + Name: - - Size + + Error Creating Document - - Type + + The document could not be created. Please ensure that you have the proper permissions. - - Date Modified + + New Directory - - Date Created + + + + Invalid Name - - - (Limited Access) + + File Operations - - Capacity: %1 + + Directory Operations - - Files: %1 (%2) + + Loading... - - Dirs: %1 + + + + A file or directory with that name already exists! Please pick a different name. - - New Document + + Error Creating Directory - - - Name: + + The directory could not be created. Please ensure that you have the proper permissions to modify the current directory. - - Error Creating Document + + Current - - The document could not be created. Please ensure that you have the proper permissions. + + Create... - - New Directory + + File - - Invalid Name + + Directory - - A file or directory with that name already exists! Please pick a different name. + + Application Launcher - - Error Creating Directory + + Launch... - - The directory could not be created. Please ensure that you have the proper permissions to modify the current directory. + + Terminal - - Current + + SlideShow - - File Checksums: + + Multimedia Player - - Missing Utility + + Modify Files... - - The "lumina-fileinfo" utility could not be found on the system. Please install it first. + + View Files... - - Open + + Checksums - - Open With... + + Properties - - Rename... + + File Checksums: + + + + + Missing Utility + + + + + The "lumina-fileinfo" utility could not be found on the system. Please install it first. + + + + + Open - - View Checksums... + + Open With... - - File Properties... + + Rename... - + Cut Selection - + Copy Selection - + Paste - + Delete Selection - - - Open Terminal here - - FODialog @@ -579,12 +590,12 @@ New Location: %2 - + Shift+Left - + Shift+Right @@ -604,363 +615,342 @@ New Location: %2 - - Group Mode - - - - + Bookmarks - + External Devices - - Edit + + Git - - Git + + New Tab - - + New Browser - + Search Directory... - + Increase Icon Size - + Decrease Icon Size - + Larger Icons - + Ctrl++ - + Smaller Icons - + Ctrl+- - + New Window - + Ctrl+N - + Add Bookmark - + Ctrl+D - + Delete Selection - + Del - + Refresh - - Close Browser + + Close Tab - + Repo Status - + Clone Repository - + Ctrl+T - + Exit - + Ctrl+Q - + &Preferences - + Show Hidden Files - + Scan for Devices - + Manage Bookmarks - + Show Action Buttons - + Load Thumbnails - + Ctrl+F - + Detailed List - + Basic List - + Ctrl+W - - Prefer Tabs - - - - - Prefer Columns - - - - + F5 - + Ctrl+C - + Rename... - + F2 - + Cut Selection - + Copy Selection - + Paste - + Ctrl+V - + Ctrl+X - + Invalid Directories - + The following directories are invalid and could not be opened: - + Root - + %1 (Type: %2) - + Filesystem: %1 - - Browser - - - - + New Bookmark - + Name: - + Invalid Name - + This bookmark name already exists. Please choose another. - + Git Repository Status - + Multimedia - + Slideshow - + Items to be removed: - + Verify Quit - + Ctrl+H - + Ctrl+L - + You have multiple tabs open. Are you sure you want to quit? - + Verify Removal - + WARNING: This will permanently delete the file(s) from the system! - + Are you sure you want to continue? - + Rename File - + New Name: - + Overwrite File? - + An existing file with the same name will be replaced. Are you sure you want to proceed? @@ -1003,6 +993,50 @@ New Location: %2 + + OPWidget + + + Form + + + + + + ... + + + + + Evaluating... + + + + + Move + + + + + Copy + + + + + Remove + + + + + %1 Finished + + + + + Errors Occured + + + SlideshowWidget @@ -1106,4 +1140,22 @@ New Location: %2 + + TrayUI + + + Finished + + + + + Errors during operation. Click to view details + + + + + No Errors + + + diff --git a/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_ru.ts b/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_ru.ts index 17afc32e..93e318f4 100644 --- a/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_ru.ts +++ b/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_ru.ts @@ -55,314 +55,325 @@ - DirWidget - - - Form - Дириктории - - - - - Open item - Открыть элемент - - - - - Open item (select application) - Открыть элемент (выбрать приложение) - - - - - Add item to personal favorites - Добавить элемент в Избранное - - - - - Rename item - Переименовать элемент - - - - Cut items - Вырезать элементы - + BrowserWidget - - Cut items (add to the clipboard) - Вырезать элементы (добавить в буфер обмена) - - - - Copy items - Скопировать элементы + + Name + Имя - - Copy items to the clipboard - Скопировать элементы в буфер обмена + + Size + Размер - - - Paste items from clipboard - Вставить из буфера обмена + + Type + Тип - - - Delete Items - Удалить элементы + + Date Modified + Дата изменения - - Stop loading the directory - Остановить загрузку каталога + + Date Created + Дата создания - - Add selected images to slideshow - Добавить выбранные изображения в слайдшоу + + Capacity: %1 + Емкость: %1 - - Create a new directory - Создать новый каталог + + Files: %1 (%2) + Файлы: %1 (%2) - - New Dir - Новый каталог + + Files: %1 + - - Create a new file - Создать новый файл + + Dirs: %1 + Папки: %1 - - New File - Новый файл + + No Directory Contents + + + + DirWidget - - Slideshow - Слайдшоу + + Form + Дириктории - - Enqueue selection in multimedia player - Добавить выбранное в проигрыватель мультимедиа + + Increase Icon Sizes + - - Play - Играть + + Decrease Icon Sizes + - + Back Назад - - + + Go back to previous directory Вернуться к предыдущему каталогу - + Up Вверх - - + + Go to parent directory Перейти в родительский каталог - + Home Домашний каталог - - + + Go to home directory Перейти в домашний каталог - - - Close this browser - Закрыть браузер + + Menu + - - Name - Имя + + Select Action + - - Size - Размер + + SingleColumn + - - Type - Тип + + Single column view + - - Date Modified - Дата изменения + + Dual Column + - - Date Created - Дата создания + + Dual Column View + - - + (Limited Access) (Ограниченный доступ) - - Capacity: %1 - Емкость: %1 - - - - Files: %1 (%2) - Файлы: %1 (%2) - - - - Dirs: %1 - Папки: %1 - - - + + New Document Новый документ - - + + + Name: Имя: - + Error Creating Document Ошибка создания документа - + The document could not be created. Please ensure that you have the proper permissions. Документ не может быть создан. Пожалуйста, убедитесь, что у вас есть соответствующие права. - + New Directory Новый каталог - + + + Invalid Name Недопустимое имя - + + File Operations + + + + + Directory Operations + + + + + Loading... + + + + + + A file or directory with that name already exists! Please pick a different name. Файл или каталог с таким именем уже существует! Пожалуйста, выберите другое имя. - + Error Creating Directory Ошибка создания каталога - + The directory could not be created. Please ensure that you have the proper permissions to modify the current directory. Каталог не может быть создан. Пожалуйста, убедитесь, что у вас есть соответствующие права, чтобы изменить текущий каталог. - + Current Текущий - + + Create... + + + + + File + Файл + + + + Directory + + + + + Application Launcher + + + + + Launch... + + + + + Terminal + + + + + SlideShow + + + + + Multimedia Player + + + + + Modify Files... + + + + + View Files... + + + + + Checksums + + + + + Properties + + + + File Checksums: Контрольные суммы файла: - + Missing Utility Утилита не найдена - + The "lumina-fileinfo" utility could not be found on the system. Please install it first. Утилита "Lumina-FileInfo" не может быть найдена в системе. Пожалуйста, установите ее в первую очередь. - + Open Открыть - + Open With... Открыть в ... - + Rename... Переименовать... - - View Checksums... - Посмотреть Контрольные суммы... - - - - File Properties... - Свойства файла... - - - + Cut Selection Вырезать выделенное - + Copy Selection Копировать выделенное - + Paste Вставить - + Delete Selection Удалить выделенное - - - Open Terminal here - Открыть здесь Терминал - FODialog @@ -581,12 +592,12 @@ New Location: %2 Insight - + Shift+Left Shift+Влево - + Shift+Right Shift+Вправо @@ -606,363 +617,342 @@ New Location: %2 Режим просмотра - - Group Mode - Групповой режим - - - + Bookmarks Закладки - + External Devices Внешние устройства - - Edit - Редактировать + + Git + - - Git + + New Tab - - + New Browser Новый браузер - + Search Directory... Поиск в каталоге... - + Increase Icon Size Увеличить размер иконки - + Decrease Icon Size Уменьшить размер иконки - + Larger Icons Большие иконки - + Ctrl++ Ctrl++ - + Smaller Icons Маленькие иконки - + Ctrl+- Ctrl+- - + New Window Новое окно - + Ctrl+N Ctrl+N - + Add Bookmark Добавить закладку - + Ctrl+D Ctrl+D - + Delete Selection Удалить выделенное - + Del Del - + Refresh Обновление - - Close Browser - Закрыть Браузер + + Close Tab + - + Repo Status - + Clone Repository - + Ctrl+T Ctrl+T - + Exit Выход - + Ctrl+Q Ctrl+Q - + &Preferences Настройка &P - + Show Hidden Files Показать скрытые файлы - + Scan for Devices Поиск устройств - + Manage Bookmarks Управление закладками - + Show Action Buttons Показывать кнопки - + Load Thumbnails Загрузить миниатюры - + Ctrl+F Ctrl+F - + Detailed List Подробный список - + Basic List Список - + Ctrl+W Ctrl+W - - Prefer Tabs - Предпочтительные вкладки - - - - Prefer Columns - Предпочтительные колонки - - - + F5 F5 - + Ctrl+C Ctrl+C - + Rename... Переименовать... - + F2 F2 - + Cut Selection Вырезать выделенное - + Copy Selection Копировать выделенное - + Paste Вставить - + Ctrl+V Ctrl+V - + Ctrl+X Ctrl+X - + Invalid Directories Недопустимая папка - + The following directories are invalid and could not be opened: Следующие папки недопустимы и не могут быть открыты: - + Root Root - + %1 (Type: %2) %1 (тип: %2) - + Filesystem: %1 Файловая система: %1 - - Browser - Браузер - - - + New Bookmark Новая закладка - + Name: Имя: - + Invalid Name Недопустимое имя - + This bookmark name already exists. Please choose another. Закладка с таким именем уже есть. Задайте другое имя. - + Git Repository Status - + Multimedia Мультимедиа - + Slideshow Слайдшоу - + Items to be removed: Объекты будут удалены: - + Verify Quit Проверка Выхода - + Ctrl+H Ctrl+H - + Ctrl+L Ctrl+L - + You have multiple tabs open. Are you sure you want to quit? У вас открыто несколько вкладок. Вы уверены, что хотите выйти? - + Verify Removal Проверка Удаления - + WARNING: This will permanently delete the file(s) from the system! Внимание: Это навсегда удалит файл(ы) из системы! - + Are you sure you want to continue? Вы уверены, что хотите продолжить? - + Rename File Переименовать файл - + New Name: Новое Имя: - + Overwrite File? Перезаписать файл? - + An existing file with the same name will be replaced. Are you sure you want to proceed? Существующий файл с таким именем будет заменен. Вы уверены, что хотите продолжить? @@ -1005,6 +995,50 @@ New Location: %2 Конец + + OPWidget + + + Form + + + + + + ... + ... + + + + Evaluating... + + + + + Move + + + + + Copy + + + + + Remove + + + + + %1 Finished + + + + + Errors Occured + + + SlideshowWidget @@ -1108,4 +1142,22 @@ New Location: %2 Вы уверены, что хотите продолжить? + + TrayUI + + + Finished + + + + + Errors during operation. Click to view details + + + + + No Errors + + + diff --git a/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_sk.ts b/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_sk.ts index f313a80d..b8db9e71 100644 --- a/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_sk.ts +++ b/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_sk.ts @@ -55,314 +55,325 @@ - DirWidget - - - Form - Formulár - - - - - Open item - Otvoriť položku - - - - - Open item (select application) - Otvorenie položky (Výber aplikácie) - - - - - Add item to personal favorites - Pridanie položky k obľúbeným - - - - - Rename item - Premenovať položku - - - - Cut items - Vystrihnúť položku - + BrowserWidget - - Cut items (add to the clipboard) - Vystrihnúť položky (pridať do schránky) - - - - Copy items - Kopírovať položky + + Name + Meno - - Copy items to the clipboard - Skopírujte položky do schránky + + Size + Veľkosť - - - Paste items from clipboard - Vložiť položky zo schránky + + Type + Typ - - - Delete Items - Odstrániť položky + + Date Modified + Dátum zmeny - - Stop loading the directory - Ukončiť načítavanie priečinka + + Date Created + Dátum vytvorenia - - Add selected images to slideshow - Pridať vybrané obrázky do prezentácie + + Capacity: %1 + Kapacita: %1 - - Create a new directory - Vytvoriť nový adresár + + Files: %1 (%2) + Súbory : %1 (%2) - - New Dir - Nový adresár + + Files: %1 + - - Create a new file - Vytvoriť nový súbor + + Dirs: %1 + Adresáre: %1 - - New File - Nový súbor + + No Directory Contents + + + + DirWidget - - Slideshow - Prezentácia + + Form + Formulár - - Enqueue selection in multimedia player - Pridať do zoznamu v prehrávači pre média + + Increase Icon Sizes + - - Play - Prehrať + + Decrease Icon Sizes + - + Back Späť - - + + Go back to previous directory Vráťte sa do predchádzajúceho adresára - + Up Hore - - + + Go to parent directory Prejdite do nadriadeného adresára - + Home Domovská zložka - - + + Go to home directory Choďte do domovského adresára - - - Close this browser - Zatvorte tento prehliadač + + Menu + - - Name - Meno + + Select Action + - - Size - Veľkosť + + SingleColumn + - - Type - Typ + + Single column view + - - Date Modified - Dátum zmeny + + Dual Column + - - Date Created - Dátum vytvorenia + + Dual Column View + - - + (Limited Access) (Limitovaný prístup) - - Capacity: %1 - Kapacita: %1 - - - - Files: %1 (%2) - Súbory : %1 (%2) - - - - Dirs: %1 - Adresáre: %1 - - - + + New Document Nový dokument - - + + + Name: Meno: - + Error Creating Document Chyba pri vytvorení dokumentu - + The document could not be created. Please ensure that you have the proper permissions. Dokument nie je možné vytvoriť. Uistite sa, či máté dostatočné práva. - + New Directory Nový priečinok - + + + Invalid Name Neplatné meno - + + File Operations + + + + + Directory Operations + + + + + Loading... + + + + + + A file or directory with that name already exists! Please pick a different name. Súbor alebo adresár s takým istým názvom už existuje. Prosím, použite iný názov. - + Error Creating Directory Chyba pri vytváraní adresára - + The directory could not be created. Please ensure that you have the proper permissions to modify the current directory. Priečinok nemôže byť vytvorený. Prosím uistite sa, či máte dostatočné práva na úpravu aktuálneho adresára. - + Current Aktuálny - + + Create... + + + + + File + Súbor + + + + Directory + + + + + Application Launcher + + + + + Launch... + + + + + Terminal + + + + + SlideShow + + + + + Multimedia Player + + + + + Modify Files... + + + + + View Files... + + + + + Checksums + + + + + Properties + + + + File Checksums: Kontrolný súčet súboru - + Missing Utility Chýbajú utility - + The "lumina-fileinfo" utility could not be found on the system. Please install it first. "lumina-fileinfo" utility nie je možné nájsť v systéme. Prosím najprv ju nainštalujte. - + Open Otvoriť - + Open With... Otvoriť s... - + Rename... - - View Checksums... - - - - - File Properties... - - - - + Cut Selection Vystrihnúť výber - + Copy Selection Kopírovať označené - + Paste Vložiť - + Delete Selection Zmazať výber - - - Open Terminal here - Tu otvoriť terminál - FODialog @@ -582,12 +593,12 @@ New Location: %2 Náhľad - + Shift+Left Shift+Šípka vľavo - + Shift+Right Shift+šípka vpravo @@ -607,363 +618,342 @@ New Location: %2 Režim zobrazenia - - Group Mode - Skupinový režim - - - + Bookmarks Záložky - + External Devices Externé rozhranie - - Edit + + Git - - Git + + New Tab - - + New Browser Nový prehliadač - + Search Directory... - + Increase Icon Size Zväčšiť veľkosť ikony - + Decrease Icon Size Zmenšiť veľkosť ikony - + Larger Icons Veľké ikony - + Ctrl++ - + Smaller Icons Menšie ikony - + Ctrl+- - + New Window Nové okno - + Ctrl+N Ctrl+N - + Add Bookmark Pridať záložku - + Ctrl+D Ctrl+D - + Delete Selection Zmazať výber - + Del - + Refresh - - Close Browser + + Close Tab - + Repo Status - + Clone Repository - + Ctrl+T Ctrl+T - + Exit Ukončiť - + Ctrl+Q Ctrl+Q - + &Preferences &Predvoľby - + Show Hidden Files Zobraziť skryté súbory - + Scan for Devices Hľadať zariadenia - + Manage Bookmarks Správa záložiek - + Show Action Buttons Zobraziť akčné tlačidlá - + Load Thumbnails Načítať miniatury - + Ctrl+F Ctrl+F - + Detailed List Podrobný zoznam - + Basic List Jednoduchý zoznam - + Ctrl+W Ctrl+W - - Prefer Tabs - Uprednostniť karty - - - - Prefer Columns - Prednosť majú stĺpce - - - + F5 F5 - + Ctrl+C Ctrl+C - + Rename... - + F2 F2 - + Cut Selection Vystrihnúť výber - + Copy Selection Kopírovať označené - + Paste Vložiť - + Ctrl+V Ctrl+V - + Ctrl+X Ctrl+X - + Invalid Directories Neplatné priečinky - + The following directories are invalid and could not be opened: Nasledujúce adresáre sú chybné a nedajú sa otvoriť: - + Root Správca - + %1 (Type: %2) %1 (Typ: %2) - + Filesystem: %1 Súborový systém: %1 - - Browser - Prehliadač - - - + New Bookmark Nová záložka - + Name: Meno: - + Invalid Name Neplatné meno - + This bookmark name already exists. Please choose another. Názov záložky už existuje. Prosím vyberte iný. - + Git Repository Status - + Multimedia Multimédiá - + Slideshow Prezentácia - + Items to be removed: Položky na odstránenie: - + Verify Quit Overte ukončenie - + Ctrl+H - + Ctrl+L - + You have multiple tabs open. Are you sure you want to quit? Máte otvorené viaceré karty. Naozaj ich chcete zatvoriť? - + Verify Removal Overte odstránenie - + WARNING: This will permanently delete the file(s) from the system! Výstraha: Budú natrvalo odstránené súbor/y zo systému! - + Are you sure you want to continue? Naozaj chcete pokračovať? - + Rename File Premenovať súbor - + New Name: Nový názov: - + Overwrite File? Prepísať súbor? - + An existing file with the same name will be replaced. Are you sure you want to proceed? Súbor s rovnakým názvom bude predpísaný. Naozaj chcete pokračovať? @@ -1006,6 +996,50 @@ New Location: %2 Dokončené + + OPWidget + + + Form + + + + + + ... + ... + + + + Evaluating... + + + + + Move + + + + + Copy + + + + + Remove + + + + + %1 Finished + + + + + Errors Occured + + + SlideshowWidget @@ -1109,4 +1143,22 @@ New Location: %2 Ste si istý, že chcete pokračovať? + + TrayUI + + + Finished + + + + + Errors during operation. Click to view details + + + + + No Errors + + + diff --git a/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_sl.ts b/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_sl.ts index 20550897..629ab157 100644 --- a/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_sl.ts +++ b/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_sl.ts @@ -55,314 +55,325 @@ - DirWidget + BrowserWidget - - Form + + Name - - - Open item + + Size - - - Open item (select application) + + Type - - - Add item to personal favorites + + Date Modified - - - Rename item + + Date Created - - Cut items + + Capacity: %1 - - Cut items (add to the clipboard) + + Files: %1 (%2) - - Copy items + + Files: %1 - - Copy items to the clipboard + + Dirs: %1 - - - Paste items from clipboard + + No Directory Contents + + + DirWidget - - - Delete Items + + Form - - Stop loading the directory + + Increase Icon Sizes - - Add selected images to slideshow + + Decrease Icon Sizes - - Create a new directory + + Back - - New Dir + + + Go back to previous directory - - Create a new file + + Up - - New File + + + Go to parent directory - - Slideshow + + Home - - Enqueue selection in multimedia player + + + Go to home directory - - Play + + Menu - - Back + + Select Action - - - Go back to previous directory + + SingleColumn - - Up + + Single column view - - - Go to parent directory + + Dual Column - - Home + + Dual Column View - - - Go to home directory + + (Limited Access) - - - Close this browser + + + New Document - - Name + + + + Name: - - Size + + Error Creating Document - - Type + + The document could not be created. Please ensure that you have the proper permissions. - - Date Modified + + New Directory - - Date Created + + + + Invalid Name - - - (Limited Access) + + File Operations - - Capacity: %1 + + Directory Operations - - Files: %1 (%2) + + Loading... - - Dirs: %1 + + + + A file or directory with that name already exists! Please pick a different name. - - New Document + + Error Creating Directory - - - Name: + + The directory could not be created. Please ensure that you have the proper permissions to modify the current directory. - - Error Creating Document + + Current - - The document could not be created. Please ensure that you have the proper permissions. + + Create... - - New Directory + + File - - Invalid Name + + Directory - - A file or directory with that name already exists! Please pick a different name. + + Application Launcher - - Error Creating Directory + + Launch... - - The directory could not be created. Please ensure that you have the proper permissions to modify the current directory. + + Terminal - - Current + + SlideShow - - File Checksums: + + Multimedia Player - - Missing Utility + + Modify Files... - - The "lumina-fileinfo" utility could not be found on the system. Please install it first. + + View Files... - - Open + + Checksums - - Open With... + + Properties - - Rename... + + File Checksums: + + + + + Missing Utility + + + + + The "lumina-fileinfo" utility could not be found on the system. Please install it first. + + + + + Open - - View Checksums... + + Open With... - - File Properties... + + Rename... - + Cut Selection - + Copy Selection - + Paste - + Delete Selection - - - Open Terminal here - - FODialog @@ -579,12 +590,12 @@ New Location: %2 - + Shift+Left - + Shift+Right @@ -604,363 +615,342 @@ New Location: %2 - - Group Mode - - - - + Bookmarks - + External Devices - - Edit + + Git - - Git + + New Tab - - + New Browser - + Search Directory... - + Increase Icon Size - + Decrease Icon Size - + Larger Icons - + Ctrl++ - + Smaller Icons - + Ctrl+- - + New Window - + Ctrl+N - + Add Bookmark - + Ctrl+D - + Delete Selection - + Del - + Refresh - - Close Browser + + Close Tab - + Repo Status - + Clone Repository - + Ctrl+T - + Exit - + Ctrl+Q - + &Preferences - + Show Hidden Files - + Scan for Devices - + Manage Bookmarks - + Show Action Buttons - + Load Thumbnails - + Ctrl+F - + Detailed List - + Basic List - + Ctrl+W - - Prefer Tabs - - - - - Prefer Columns - - - - + F5 - + Ctrl+C - + Rename... - + F2 - + Cut Selection - + Copy Selection - + Paste - + Ctrl+V - + Ctrl+X - + Invalid Directories - + The following directories are invalid and could not be opened: - + Root - + %1 (Type: %2) - + Filesystem: %1 - - Browser - - - - + New Bookmark - + Name: - + Invalid Name - + This bookmark name already exists. Please choose another. - + Git Repository Status - + Multimedia - + Slideshow - + Items to be removed: - + Verify Quit - + Ctrl+H - + Ctrl+L - + You have multiple tabs open. Are you sure you want to quit? - + Verify Removal - + WARNING: This will permanently delete the file(s) from the system! - + Are you sure you want to continue? - + Rename File - + New Name: - + Overwrite File? - + An existing file with the same name will be replaced. Are you sure you want to proceed? @@ -1003,6 +993,50 @@ New Location: %2 + + OPWidget + + + Form + + + + + + ... + + + + + Evaluating... + + + + + Move + + + + + Copy + + + + + Remove + + + + + %1 Finished + + + + + Errors Occured + + + SlideshowWidget @@ -1106,4 +1140,22 @@ New Location: %2 + + TrayUI + + + Finished + + + + + Errors during operation. Click to view details + + + + + No Errors + + + diff --git a/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_sr.ts b/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_sr.ts index 20550897..629ab157 100644 --- a/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_sr.ts +++ b/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_sr.ts @@ -55,314 +55,325 @@ - DirWidget + BrowserWidget - - Form + + Name - - - Open item + + Size - - - Open item (select application) + + Type - - - Add item to personal favorites + + Date Modified - - - Rename item + + Date Created - - Cut items + + Capacity: %1 - - Cut items (add to the clipboard) + + Files: %1 (%2) - - Copy items + + Files: %1 - - Copy items to the clipboard + + Dirs: %1 - - - Paste items from clipboard + + No Directory Contents + + + DirWidget - - - Delete Items + + Form - - Stop loading the directory + + Increase Icon Sizes - - Add selected images to slideshow + + Decrease Icon Sizes - - Create a new directory + + Back - - New Dir + + + Go back to previous directory - - Create a new file + + Up - - New File + + + Go to parent directory - - Slideshow + + Home - - Enqueue selection in multimedia player + + + Go to home directory - - Play + + Menu - - Back + + Select Action - - - Go back to previous directory + + SingleColumn - - Up + + Single column view - - - Go to parent directory + + Dual Column - - Home + + Dual Column View - - - Go to home directory + + (Limited Access) - - - Close this browser + + + New Document - - Name + + + + Name: - - Size + + Error Creating Document - - Type + + The document could not be created. Please ensure that you have the proper permissions. - - Date Modified + + New Directory - - Date Created + + + + Invalid Name - - - (Limited Access) + + File Operations - - Capacity: %1 + + Directory Operations - - Files: %1 (%2) + + Loading... - - Dirs: %1 + + + + A file or directory with that name already exists! Please pick a different name. - - New Document + + Error Creating Directory - - - Name: + + The directory could not be created. Please ensure that you have the proper permissions to modify the current directory. - - Error Creating Document + + Current - - The document could not be created. Please ensure that you have the proper permissions. + + Create... - - New Directory + + File - - Invalid Name + + Directory - - A file or directory with that name already exists! Please pick a different name. + + Application Launcher - - Error Creating Directory + + Launch... - - The directory could not be created. Please ensure that you have the proper permissions to modify the current directory. + + Terminal - - Current + + SlideShow - - File Checksums: + + Multimedia Player - - Missing Utility + + Modify Files... - - The "lumina-fileinfo" utility could not be found on the system. Please install it first. + + View Files... - - Open + + Checksums - - Open With... + + Properties - - Rename... + + File Checksums: + + + + + Missing Utility + + + + + The "lumina-fileinfo" utility could not be found on the system. Please install it first. + + + + + Open - - View Checksums... + + Open With... - - File Properties... + + Rename... - + Cut Selection - + Copy Selection - + Paste - + Delete Selection - - - Open Terminal here - - FODialog @@ -579,12 +590,12 @@ New Location: %2 - + Shift+Left - + Shift+Right @@ -604,363 +615,342 @@ New Location: %2 - - Group Mode - - - - + Bookmarks - + External Devices - - Edit + + Git - - Git + + New Tab - - + New Browser - + Search Directory... - + Increase Icon Size - + Decrease Icon Size - + Larger Icons - + Ctrl++ - + Smaller Icons - + Ctrl+- - + New Window - + Ctrl+N - + Add Bookmark - + Ctrl+D - + Delete Selection - + Del - + Refresh - - Close Browser + + Close Tab - + Repo Status - + Clone Repository - + Ctrl+T - + Exit - + Ctrl+Q - + &Preferences - + Show Hidden Files - + Scan for Devices - + Manage Bookmarks - + Show Action Buttons - + Load Thumbnails - + Ctrl+F - + Detailed List - + Basic List - + Ctrl+W - - Prefer Tabs - - - - - Prefer Columns - - - - + F5 - + Ctrl+C - + Rename... - + F2 - + Cut Selection - + Copy Selection - + Paste - + Ctrl+V - + Ctrl+X - + Invalid Directories - + The following directories are invalid and could not be opened: - + Root - + %1 (Type: %2) - + Filesystem: %1 - - Browser - - - - + New Bookmark - + Name: - + Invalid Name - + This bookmark name already exists. Please choose another. - + Git Repository Status - + Multimedia - + Slideshow - + Items to be removed: - + Verify Quit - + Ctrl+H - + Ctrl+L - + You have multiple tabs open. Are you sure you want to quit? - + Verify Removal - + WARNING: This will permanently delete the file(s) from the system! - + Are you sure you want to continue? - + Rename File - + New Name: - + Overwrite File? - + An existing file with the same name will be replaced. Are you sure you want to proceed? @@ -1003,6 +993,50 @@ New Location: %2 + + OPWidget + + + Form + + + + + + ... + + + + + Evaluating... + + + + + Move + + + + + Copy + + + + + Remove + + + + + %1 Finished + + + + + Errors Occured + + + SlideshowWidget @@ -1106,4 +1140,22 @@ New Location: %2 + + TrayUI + + + Finished + + + + + Errors during operation. Click to view details + + + + + No Errors + + + diff --git a/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_sv.ts b/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_sv.ts index 27f29a13..c368cdf3 100644 --- a/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_sv.ts +++ b/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_sv.ts @@ -1,448 +1,459 @@ - + BMMDialog - + Manage Bookmarks Hantera bokmärken - + Name Namn - + Path Sökväg - + Remove Bookmark Ta bort bokmärke - + Rename BookMark Byt namn på bokmärke - + Finished Färdig - + Rename Bookmark Byt namn på bokmärke - + Name: Namn: - + Invalid Name Ogiltigt namn - + This bookmark name already exists. Please choose another. Det här bokmärks namnet finns redan. Välj ett annat namn. - DirWidget - - - Form - Formulär - - - - - Open item - Öppna objekt - - - - - Open item (select application) - Öppna objekt (välj ett program) - - - - - Add item to personal favorites - Lägg till fil till dina personliga favoriter - - - - - Rename item - Byt namn på objekt - - - - Cut items - Klipp ut objekt - + BrowserWidget - - Cut items (add to the clipboard) - Klipp ut objekt (lägg till i Urklipp) - - - - Copy items - Kopiera objekt + + Name + Namn - - Copy items to the clipboard - Kopiera objekt till Urklipp + + Size + Storlek - - - Paste items from clipboard - Klistra in objekt från urklipp + + Type + Typ - - - Delete Items - Ta bort objekt + + Date Modified + Ändringsdatum - - Stop loading the directory - Sluta laddandet av katalogen + + Date Created + Datum skapad - - Add selected images to slideshow - Lägg till valda bilder till bildspelet + + Capacity: %1 + Kapacitet: %1 - - Create a new directory - Skapa en ny katalog + + Files: %1 (%2) + Filer: %1 (%2) - - New Dir - Ny Katalog + + Files: %1 + - - Create a new file - Skapa en ny fil + + Dirs: %1 + Kataloger: %1 - - New File - Ny fil + + No Directory Contents + + + + DirWidget - - Slideshow - Bildspel + + Form + Formulär - - Enqueue selection in multimedia player - Köa urval i multimediaspelaren + + Increase Icon Sizes + - - Play - Spela + + Decrease Icon Sizes + - + Back Bakåt - - + + Go back to previous directory Gå tillbaka till förra katalogen - + Up Upp - - + + Go to parent directory Gå till föräldrakatalog - + Home Hem - - + + Go to home directory Gå till hemkatalog - - - Close this browser - Stäng denna webbläsaren + + Menu + - - Name - Namn + + Select Action + - - Size - Storlek + + SingleColumn + - - Type - Typ + + Single column view + - - Date Modified - Ändringsdatum + + Dual Column + - - Date Created - Datum skapad + + Dual Column View + - - + (Limited Access) (Begränsad tillgång) - - Capacity: %1 - Kapacitet: %1 - - - - Files: %1 (%2) - Filer: %1 (%2) - - - - Dirs: %1 - Kataloger: %1 - - - + + New Document Nytt dokument - - + + + Name: Namn: - + Error Creating Document Fel när dokument skulle skapas - + The document could not be created. Please ensure that you have the proper permissions. Detta dokument kunde inte skapas. Se till att du har rätt behörigheter. - + New Directory Ny katalog - + + + Invalid Name Ogiltigt namn - + + File Operations + + + + + Directory Operations + + + + + Loading... + + + + + + A file or directory with that name already exists! Please pick a different name. En fil med samma namn finns redan. Använd ett annat namn. - + Error Creating Directory Fel vid skapande av katalog - + The directory could not be created. Please ensure that you have the proper permissions to modify the current directory. Denna katalogen kunde inte skapas. Se till att du har rätt behörigheter att modifera den aktuella katalogen. - + Current Aktuell - + + Create... + + + + + File + Fil + + + + Directory + + + + + Application Launcher + + + + + Launch... + + + + + Terminal + + + + + SlideShow + + + + + Multimedia Player + + + + + Modify Files... + + + + + View Files... + + + + + Checksums + + + + + Properties + + + + File Checksums: Filkontrollsummor: - + Missing Utility Saknar Verktyg - - The "lumina-fileinfo" utility could not be found on the system. Please install it first. - "lumina-Fileinfo" verktyget kunde inte hittas på systemet. Installera det först. + + The "lumina-fileinfo" utility could not be found on the system. Please install it first. + "lumina-Fileinfo" verktyget kunde inte hittas på systemet. Installera det först. - + Open Öppna - + Open With... Öppna med... - + Rename... Byt namn... - - View Checksums... - Visa checksumma... - - - - File Properties... - Fil Egenskaper... - - - + Cut Selection Klipp markering - + Copy Selection Kopiera markering - + Paste Klistra in - + Delete Selection Ta bort markering - - - Open Terminal here - Öppna terminal här - FODialog - + Performing File Operations Utför Filoperationer - + %v/%m %v/%m - + Stop Stoppa - + Calculating Beräknar - + Overwrite Files? Skriv över filer? - + Do you want to overwrite the existing files? Vill du skriva över dessa filer? - + Note: It will just add a number to the filename otherwise. Obs: Det kommer bara lägga till ett nummer till filnamnet annars. - + Removing: %1 Tar bort: %1 - + Copying: %1 to %2 Kopierar %1 to %2 - + Restoring: %1 as %2 Återställer %1 som %2 - + Moving: %1 to %2 Flyttar %1 till %2 - + Could not remove these files: Kunde inte ta bort de här filerna: - + Could not copy these files: Kunde inte kopiera dessa filer: - + Could not restore these files: Kinte inte återställa dessa filer: - + Could not move these files: Kunde inte flytta dessa filer: - + File Errors Filfel @@ -450,12 +461,12 @@ FOWorker - + Invalid Move Ogiltigt drag - + It is not possible to move a directory into itself. Please make a copy of the directory instead. Old Location: %1 @@ -469,107 +480,107 @@ Ny Plats: %2 GitWizard - + Clone a Git Repository - + Welcome! Välkommen! - + This wizard will guide you through the process of downloading a GIT repository from the internet. - + GitHub Repository Settings - + Organization/User Organisation/Användare - + Repository Name - + Is Private Repository - + Type of Access Typ av Åtkomst - + Use my SSH Key Använd min SSH nyckel - + Login to server - + Username Användarnamn - + Password Lösenord - + Anonymous (public repositories only) - + Optional SSH Password Frivilligt SSH lösenord - + Advanced Options Avancerade Inställningar - + Custom Depth - + Single Branch - + branch name branch namn - - Click "Next" to start downloading the repository + + Click "Next" to start downloading the repository - + Stop Download? - + Kill the current download? @@ -577,393 +588,372 @@ Ny Plats: %2 MainUI - + Insight Insight - + Shift+Left Shift+Vänster - + Shift+Right Shift+Höger - + File Fil - + View Visa - + View Mode Visningsläge - - Group Mode - Gruppläge - - - + Bookmarks Bokmärken - + External Devices Externa enheter - - Edit - Redigera - - - + Git Git - - + + New Tab + + + + New Browser Ny flik - + Search Directory... Sök Katalog... - + Increase Icon Size Öka ikonstorlek - + Decrease Icon Size Minska ikonstorlek - + Larger Icons Stora ikoner - + Ctrl++ Ctrl++ - + Smaller Icons Små ikoner - + Ctrl+- Ctrl+- - + New Window Nytt fönster - + Ctrl+N Ctrl+N - + Add Bookmark Lägg till bokmärke - + Ctrl+D Ctrl+D - + Delete Selection Ta bort markering - + Del Del - + Refresh Uppdatera - - Close Browser - Stäng ett filbläddrar fönster + + Close Tab + - + Repo Status - + Clone Repository - + Ctrl+T Ctrl+T - + Exit Avsluta - + Ctrl+Q Ctrl+Q - + &Preferences &Inställningar - + Show Hidden Files Visa dolda filer - + Scan for Devices Sök efter enheter - + Manage Bookmarks Hantera bokmärken - + Show Action Buttons Visa aktiva knappar - + Load Thumbnails Ladda Miniatyrbilder - + Ctrl+F Ctrl+F - + Detailed List Detaljerad lista - + Basic List Grundläggande Lista - + Ctrl+W Ctrl+W - - Prefer Tabs - Föredra flikar - - - - Prefer Columns - Föredra kolumner - - - + F5 F5 - + Ctrl+C Ctrl+C - + Rename... Byt namn... - + F2 F2 - + Cut Selection Klipp ut markering - + Copy Selection Kopiera markering - + Paste Klistra in - + Ctrl+V Ctrl+V - + Ctrl+X Ctrl+X - + Invalid Directories Ogiltiga kataloger - + The following directories are invalid and could not be opened: Följande kataloger är ogiltiga och kunde inte öppnas: - + Root Root - + %1 (Type: %2) %1 (Typ: %2) - + Filesystem: %1 Filsystem: %1 - - Browser - Webbläsare - - - + New Bookmark Nytt bokmärke - + Name: Namn: - + Invalid Name Ogiltigt namn - + This bookmark name already exists. Please choose another. Det här bokmärks namnet finns redan. Välj ett annat namn. - + Git Repository Status - + Multimedia Multimedia - + Slideshow Bildspel - + Items to be removed: Filer som ska bli borttagna: - + Verify Quit Verifera Avslut - + Ctrl+H Ctrl+H - + Ctrl+L Ctrl+L - + You have multiple tabs open. Are you sure you want to quit? Du har flera flikar öppna. Är du säker på att du vill avsluta? - + Verify Removal Verifiera Borttagande - + WARNING: This will permanently delete the file(s) from the system! VARNING: Detta kommer att permanent ta bort filerna från systemet! - + Are you sure you want to continue? Är du säker på att du vill fortsätta? - + Rename File Byt namn på fil - + New Name: Nytt namn: - + Overwrite File? Skriv över fil? - + An existing file with the same name will be replaced. Are you sure you want to proceed? En befintlig fil med samma namn kommer att ersättas. Är du säker på att du vill fortsätta? @@ -971,142 +961,204 @@ Ny Plats: %2 MultimediaWidget - + Form Formulär - + Go To Next Gå till nästa - + (No Running Video) (Ingen körande Video) - + Playing: Spelar: - + Stopped Stoppad - + Error Playing File: %1 Fel när filen: %1 skulle spelas - + Finished Färdigställd + + OPWidget + + + Form + Formulär + + + + + ... + ... + + + + Evaluating... + + + + + Move + + + + + Copy + + + + + Remove + + + + + %1 Finished + + + + + Errors Occured + + + SlideshowWidget - + Form Formulär - + Delete this image file Ta bort denna bild fil - + Rotate this image file counter-clockwise Rotera den här bildfilen moturs - + Rotate this image file clockwise Rotera den här bildfilen medurs - - + + Zoom in Zooma in - - + + Zoom out Zooma ut - + Go to Beginning Gå till början - - - - + + + + ... ... - + Shift+Left Shift+Vänster - + Go to Previous Gå till föregående - + Left Vänster - + File Name Filnamn - + Go to Next Gå till nästa - + Right Höger - + Go to End Gå till slutet - + Shift+Right Shift+Höger - + Verify Removal Verifiera Borttagande - + WARNING: This will permanently delete the file from the system! VARNING: Detta kommer permanent ta bort filen från ditt system! - + Are you sure you want to continue? Är du säker på att du vill fortsätta? + + TrayUI + + + Finished + + + + + Errors during operation. Click to view details + + + + + No Errors + + + diff --git a/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_sw.ts b/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_sw.ts index 20550897..629ab157 100644 --- a/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_sw.ts +++ b/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_sw.ts @@ -55,314 +55,325 @@ - DirWidget + BrowserWidget - - Form + + Name - - - Open item + + Size - - - Open item (select application) + + Type - - - Add item to personal favorites + + Date Modified - - - Rename item + + Date Created - - Cut items + + Capacity: %1 - - Cut items (add to the clipboard) + + Files: %1 (%2) - - Copy items + + Files: %1 - - Copy items to the clipboard + + Dirs: %1 - - - Paste items from clipboard + + No Directory Contents + + + DirWidget - - - Delete Items + + Form - - Stop loading the directory + + Increase Icon Sizes - - Add selected images to slideshow + + Decrease Icon Sizes - - Create a new directory + + Back - - New Dir + + + Go back to previous directory - - Create a new file + + Up - - New File + + + Go to parent directory - - Slideshow + + Home - - Enqueue selection in multimedia player + + + Go to home directory - - Play + + Menu - - Back + + Select Action - - - Go back to previous directory + + SingleColumn - - Up + + Single column view - - - Go to parent directory + + Dual Column - - Home + + Dual Column View - - - Go to home directory + + (Limited Access) - - - Close this browser + + + New Document - - Name + + + + Name: - - Size + + Error Creating Document - - Type + + The document could not be created. Please ensure that you have the proper permissions. - - Date Modified + + New Directory - - Date Created + + + + Invalid Name - - - (Limited Access) + + File Operations - - Capacity: %1 + + Directory Operations - - Files: %1 (%2) + + Loading... - - Dirs: %1 + + + + A file or directory with that name already exists! Please pick a different name. - - New Document + + Error Creating Directory - - - Name: + + The directory could not be created. Please ensure that you have the proper permissions to modify the current directory. - - Error Creating Document + + Current - - The document could not be created. Please ensure that you have the proper permissions. + + Create... - - New Directory + + File - - Invalid Name + + Directory - - A file or directory with that name already exists! Please pick a different name. + + Application Launcher - - Error Creating Directory + + Launch... - - The directory could not be created. Please ensure that you have the proper permissions to modify the current directory. + + Terminal - - Current + + SlideShow - - File Checksums: + + Multimedia Player - - Missing Utility + + Modify Files... - - The "lumina-fileinfo" utility could not be found on the system. Please install it first. + + View Files... - - Open + + Checksums - - Open With... + + Properties - - Rename... + + File Checksums: + + + + + Missing Utility + + + + + The "lumina-fileinfo" utility could not be found on the system. Please install it first. + + + + + Open - - View Checksums... + + Open With... - - File Properties... + + Rename... - + Cut Selection - + Copy Selection - + Paste - + Delete Selection - - - Open Terminal here - - FODialog @@ -579,12 +590,12 @@ New Location: %2 - + Shift+Left - + Shift+Right @@ -604,363 +615,342 @@ New Location: %2 - - Group Mode - - - - + Bookmarks - + External Devices - - Edit + + Git - - Git + + New Tab - - + New Browser - + Search Directory... - + Increase Icon Size - + Decrease Icon Size - + Larger Icons - + Ctrl++ - + Smaller Icons - + Ctrl+- - + New Window - + Ctrl+N - + Add Bookmark - + Ctrl+D - + Delete Selection - + Del - + Refresh - - Close Browser + + Close Tab - + Repo Status - + Clone Repository - + Ctrl+T - + Exit - + Ctrl+Q - + &Preferences - + Show Hidden Files - + Scan for Devices - + Manage Bookmarks - + Show Action Buttons - + Load Thumbnails - + Ctrl+F - + Detailed List - + Basic List - + Ctrl+W - - Prefer Tabs - - - - - Prefer Columns - - - - + F5 - + Ctrl+C - + Rename... - + F2 - + Cut Selection - + Copy Selection - + Paste - + Ctrl+V - + Ctrl+X - + Invalid Directories - + The following directories are invalid and could not be opened: - + Root - + %1 (Type: %2) - + Filesystem: %1 - - Browser - - - - + New Bookmark - + Name: - + Invalid Name - + This bookmark name already exists. Please choose another. - + Git Repository Status - + Multimedia - + Slideshow - + Items to be removed: - + Verify Quit - + Ctrl+H - + Ctrl+L - + You have multiple tabs open. Are you sure you want to quit? - + Verify Removal - + WARNING: This will permanently delete the file(s) from the system! - + Are you sure you want to continue? - + Rename File - + New Name: - + Overwrite File? - + An existing file with the same name will be replaced. Are you sure you want to proceed? @@ -1003,6 +993,50 @@ New Location: %2 + + OPWidget + + + Form + + + + + + ... + + + + + Evaluating... + + + + + Move + + + + + Copy + + + + + Remove + + + + + %1 Finished + + + + + Errors Occured + + + SlideshowWidget @@ -1106,4 +1140,22 @@ New Location: %2 + + TrayUI + + + Finished + + + + + Errors during operation. Click to view details + + + + + No Errors + + + diff --git a/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_ta.ts b/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_ta.ts index 20550897..629ab157 100644 --- a/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_ta.ts +++ b/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_ta.ts @@ -55,314 +55,325 @@ - DirWidget + BrowserWidget - - Form + + Name - - - Open item + + Size - - - Open item (select application) + + Type - - - Add item to personal favorites + + Date Modified - - - Rename item + + Date Created - - Cut items + + Capacity: %1 - - Cut items (add to the clipboard) + + Files: %1 (%2) - - Copy items + + Files: %1 - - Copy items to the clipboard + + Dirs: %1 - - - Paste items from clipboard + + No Directory Contents + + + DirWidget - - - Delete Items + + Form - - Stop loading the directory + + Increase Icon Sizes - - Add selected images to slideshow + + Decrease Icon Sizes - - Create a new directory + + Back - - New Dir + + + Go back to previous directory - - Create a new file + + Up - - New File + + + Go to parent directory - - Slideshow + + Home - - Enqueue selection in multimedia player + + + Go to home directory - - Play + + Menu - - Back + + Select Action - - - Go back to previous directory + + SingleColumn - - Up + + Single column view - - - Go to parent directory + + Dual Column - - Home + + Dual Column View - - - Go to home directory + + (Limited Access) - - - Close this browser + + + New Document - - Name + + + + Name: - - Size + + Error Creating Document - - Type + + The document could not be created. Please ensure that you have the proper permissions. - - Date Modified + + New Directory - - Date Created + + + + Invalid Name - - - (Limited Access) + + File Operations - - Capacity: %1 + + Directory Operations - - Files: %1 (%2) + + Loading... - - Dirs: %1 + + + + A file or directory with that name already exists! Please pick a different name. - - New Document + + Error Creating Directory - - - Name: + + The directory could not be created. Please ensure that you have the proper permissions to modify the current directory. - - Error Creating Document + + Current - - The document could not be created. Please ensure that you have the proper permissions. + + Create... - - New Directory + + File - - Invalid Name + + Directory - - A file or directory with that name already exists! Please pick a different name. + + Application Launcher - - Error Creating Directory + + Launch... - - The directory could not be created. Please ensure that you have the proper permissions to modify the current directory. + + Terminal - - Current + + SlideShow - - File Checksums: + + Multimedia Player - - Missing Utility + + Modify Files... - - The "lumina-fileinfo" utility could not be found on the system. Please install it first. + + View Files... - - Open + + Checksums - - Open With... + + Properties - - Rename... + + File Checksums: + + + + + Missing Utility + + + + + The "lumina-fileinfo" utility could not be found on the system. Please install it first. + + + + + Open - - View Checksums... + + Open With... - - File Properties... + + Rename... - + Cut Selection - + Copy Selection - + Paste - + Delete Selection - - - Open Terminal here - - FODialog @@ -579,12 +590,12 @@ New Location: %2 - + Shift+Left - + Shift+Right @@ -604,363 +615,342 @@ New Location: %2 - - Group Mode - - - - + Bookmarks - + External Devices - - Edit + + Git - - Git + + New Tab - - + New Browser - + Search Directory... - + Increase Icon Size - + Decrease Icon Size - + Larger Icons - + Ctrl++ - + Smaller Icons - + Ctrl+- - + New Window - + Ctrl+N - + Add Bookmark - + Ctrl+D - + Delete Selection - + Del - + Refresh - - Close Browser + + Close Tab - + Repo Status - + Clone Repository - + Ctrl+T - + Exit - + Ctrl+Q - + &Preferences - + Show Hidden Files - + Scan for Devices - + Manage Bookmarks - + Show Action Buttons - + Load Thumbnails - + Ctrl+F - + Detailed List - + Basic List - + Ctrl+W - - Prefer Tabs - - - - - Prefer Columns - - - - + F5 - + Ctrl+C - + Rename... - + F2 - + Cut Selection - + Copy Selection - + Paste - + Ctrl+V - + Ctrl+X - + Invalid Directories - + The following directories are invalid and could not be opened: - + Root - + %1 (Type: %2) - + Filesystem: %1 - - Browser - - - - + New Bookmark - + Name: - + Invalid Name - + This bookmark name already exists. Please choose another. - + Git Repository Status - + Multimedia - + Slideshow - + Items to be removed: - + Verify Quit - + Ctrl+H - + Ctrl+L - + You have multiple tabs open. Are you sure you want to quit? - + Verify Removal - + WARNING: This will permanently delete the file(s) from the system! - + Are you sure you want to continue? - + Rename File - + New Name: - + Overwrite File? - + An existing file with the same name will be replaced. Are you sure you want to proceed? @@ -1003,6 +993,50 @@ New Location: %2 + + OPWidget + + + Form + + + + + + ... + + + + + Evaluating... + + + + + Move + + + + + Copy + + + + + Remove + + + + + %1 Finished + + + + + Errors Occured + + + SlideshowWidget @@ -1106,4 +1140,22 @@ New Location: %2 + + TrayUI + + + Finished + + + + + Errors during operation. Click to view details + + + + + No Errors + + + diff --git a/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_tg.ts b/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_tg.ts index 20550897..629ab157 100644 --- a/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_tg.ts +++ b/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_tg.ts @@ -55,314 +55,325 @@ - DirWidget + BrowserWidget - - Form + + Name - - - Open item + + Size - - - Open item (select application) + + Type - - - Add item to personal favorites + + Date Modified - - - Rename item + + Date Created - - Cut items + + Capacity: %1 - - Cut items (add to the clipboard) + + Files: %1 (%2) - - Copy items + + Files: %1 - - Copy items to the clipboard + + Dirs: %1 - - - Paste items from clipboard + + No Directory Contents + + + DirWidget - - - Delete Items + + Form - - Stop loading the directory + + Increase Icon Sizes - - Add selected images to slideshow + + Decrease Icon Sizes - - Create a new directory + + Back - - New Dir + + + Go back to previous directory - - Create a new file + + Up - - New File + + + Go to parent directory - - Slideshow + + Home - - Enqueue selection in multimedia player + + + Go to home directory - - Play + + Menu - - Back + + Select Action - - - Go back to previous directory + + SingleColumn - - Up + + Single column view - - - Go to parent directory + + Dual Column - - Home + + Dual Column View - - - Go to home directory + + (Limited Access) - - - Close this browser + + + New Document - - Name + + + + Name: - - Size + + Error Creating Document - - Type + + The document could not be created. Please ensure that you have the proper permissions. - - Date Modified + + New Directory - - Date Created + + + + Invalid Name - - - (Limited Access) + + File Operations - - Capacity: %1 + + Directory Operations - - Files: %1 (%2) + + Loading... - - Dirs: %1 + + + + A file or directory with that name already exists! Please pick a different name. - - New Document + + Error Creating Directory - - - Name: + + The directory could not be created. Please ensure that you have the proper permissions to modify the current directory. - - Error Creating Document + + Current - - The document could not be created. Please ensure that you have the proper permissions. + + Create... - - New Directory + + File - - Invalid Name + + Directory - - A file or directory with that name already exists! Please pick a different name. + + Application Launcher - - Error Creating Directory + + Launch... - - The directory could not be created. Please ensure that you have the proper permissions to modify the current directory. + + Terminal - - Current + + SlideShow - - File Checksums: + + Multimedia Player - - Missing Utility + + Modify Files... - - The "lumina-fileinfo" utility could not be found on the system. Please install it first. + + View Files... - - Open + + Checksums - - Open With... + + Properties - - Rename... + + File Checksums: + + + + + Missing Utility + + + + + The "lumina-fileinfo" utility could not be found on the system. Please install it first. + + + + + Open - - View Checksums... + + Open With... - - File Properties... + + Rename... - + Cut Selection - + Copy Selection - + Paste - + Delete Selection - - - Open Terminal here - - FODialog @@ -579,12 +590,12 @@ New Location: %2 - + Shift+Left - + Shift+Right @@ -604,363 +615,342 @@ New Location: %2 - - Group Mode - - - - + Bookmarks - + External Devices - - Edit + + Git - - Git + + New Tab - - + New Browser - + Search Directory... - + Increase Icon Size - + Decrease Icon Size - + Larger Icons - + Ctrl++ - + Smaller Icons - + Ctrl+- - + New Window - + Ctrl+N - + Add Bookmark - + Ctrl+D - + Delete Selection - + Del - + Refresh - - Close Browser + + Close Tab - + Repo Status - + Clone Repository - + Ctrl+T - + Exit - + Ctrl+Q - + &Preferences - + Show Hidden Files - + Scan for Devices - + Manage Bookmarks - + Show Action Buttons - + Load Thumbnails - + Ctrl+F - + Detailed List - + Basic List - + Ctrl+W - - Prefer Tabs - - - - - Prefer Columns - - - - + F5 - + Ctrl+C - + Rename... - + F2 - + Cut Selection - + Copy Selection - + Paste - + Ctrl+V - + Ctrl+X - + Invalid Directories - + The following directories are invalid and could not be opened: - + Root - + %1 (Type: %2) - + Filesystem: %1 - - Browser - - - - + New Bookmark - + Name: - + Invalid Name - + This bookmark name already exists. Please choose another. - + Git Repository Status - + Multimedia - + Slideshow - + Items to be removed: - + Verify Quit - + Ctrl+H - + Ctrl+L - + You have multiple tabs open. Are you sure you want to quit? - + Verify Removal - + WARNING: This will permanently delete the file(s) from the system! - + Are you sure you want to continue? - + Rename File - + New Name: - + Overwrite File? - + An existing file with the same name will be replaced. Are you sure you want to proceed? @@ -1003,6 +993,50 @@ New Location: %2 + + OPWidget + + + Form + + + + + + ... + + + + + Evaluating... + + + + + Move + + + + + Copy + + + + + Remove + + + + + %1 Finished + + + + + Errors Occured + + + SlideshowWidget @@ -1106,4 +1140,22 @@ New Location: %2 + + TrayUI + + + Finished + + + + + Errors during operation. Click to view details + + + + + No Errors + + + diff --git a/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_th.ts b/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_th.ts index 20550897..629ab157 100644 --- a/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_th.ts +++ b/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_th.ts @@ -55,314 +55,325 @@ - DirWidget + BrowserWidget - - Form + + Name - - - Open item + + Size - - - Open item (select application) + + Type - - - Add item to personal favorites + + Date Modified - - - Rename item + + Date Created - - Cut items + + Capacity: %1 - - Cut items (add to the clipboard) + + Files: %1 (%2) - - Copy items + + Files: %1 - - Copy items to the clipboard + + Dirs: %1 - - - Paste items from clipboard + + No Directory Contents + + + DirWidget - - - Delete Items + + Form - - Stop loading the directory + + Increase Icon Sizes - - Add selected images to slideshow + + Decrease Icon Sizes - - Create a new directory + + Back - - New Dir + + + Go back to previous directory - - Create a new file + + Up - - New File + + + Go to parent directory - - Slideshow + + Home - - Enqueue selection in multimedia player + + + Go to home directory - - Play + + Menu - - Back + + Select Action - - - Go back to previous directory + + SingleColumn - - Up + + Single column view - - - Go to parent directory + + Dual Column - - Home + + Dual Column View - - - Go to home directory + + (Limited Access) - - - Close this browser + + + New Document - - Name + + + + Name: - - Size + + Error Creating Document - - Type + + The document could not be created. Please ensure that you have the proper permissions. - - Date Modified + + New Directory - - Date Created + + + + Invalid Name - - - (Limited Access) + + File Operations - - Capacity: %1 + + Directory Operations - - Files: %1 (%2) + + Loading... - - Dirs: %1 + + + + A file or directory with that name already exists! Please pick a different name. - - New Document + + Error Creating Directory - - - Name: + + The directory could not be created. Please ensure that you have the proper permissions to modify the current directory. - - Error Creating Document + + Current - - The document could not be created. Please ensure that you have the proper permissions. + + Create... - - New Directory + + File - - Invalid Name + + Directory - - A file or directory with that name already exists! Please pick a different name. + + Application Launcher - - Error Creating Directory + + Launch... - - The directory could not be created. Please ensure that you have the proper permissions to modify the current directory. + + Terminal - - Current + + SlideShow - - File Checksums: + + Multimedia Player - - Missing Utility + + Modify Files... - - The "lumina-fileinfo" utility could not be found on the system. Please install it first. + + View Files... - - Open + + Checksums - - Open With... + + Properties - - Rename... + + File Checksums: + + + + + Missing Utility + + + + + The "lumina-fileinfo" utility could not be found on the system. Please install it first. + + + + + Open - - View Checksums... + + Open With... - - File Properties... + + Rename... - + Cut Selection - + Copy Selection - + Paste - + Delete Selection - - - Open Terminal here - - FODialog @@ -579,12 +590,12 @@ New Location: %2 - + Shift+Left - + Shift+Right @@ -604,363 +615,342 @@ New Location: %2 - - Group Mode - - - - + Bookmarks - + External Devices - - Edit + + Git - - Git + + New Tab - - + New Browser - + Search Directory... - + Increase Icon Size - + Decrease Icon Size - + Larger Icons - + Ctrl++ - + Smaller Icons - + Ctrl+- - + New Window - + Ctrl+N - + Add Bookmark - + Ctrl+D - + Delete Selection - + Del - + Refresh - - Close Browser + + Close Tab - + Repo Status - + Clone Repository - + Ctrl+T - + Exit - + Ctrl+Q - + &Preferences - + Show Hidden Files - + Scan for Devices - + Manage Bookmarks - + Show Action Buttons - + Load Thumbnails - + Ctrl+F - + Detailed List - + Basic List - + Ctrl+W - - Prefer Tabs - - - - - Prefer Columns - - - - + F5 - + Ctrl+C - + Rename... - + F2 - + Cut Selection - + Copy Selection - + Paste - + Ctrl+V - + Ctrl+X - + Invalid Directories - + The following directories are invalid and could not be opened: - + Root - + %1 (Type: %2) - + Filesystem: %1 - - Browser - - - - + New Bookmark - + Name: - + Invalid Name - + This bookmark name already exists. Please choose another. - + Git Repository Status - + Multimedia - + Slideshow - + Items to be removed: - + Verify Quit - + Ctrl+H - + Ctrl+L - + You have multiple tabs open. Are you sure you want to quit? - + Verify Removal - + WARNING: This will permanently delete the file(s) from the system! - + Are you sure you want to continue? - + Rename File - + New Name: - + Overwrite File? - + An existing file with the same name will be replaced. Are you sure you want to proceed? @@ -1003,6 +993,50 @@ New Location: %2 + + OPWidget + + + Form + + + + + + ... + + + + + Evaluating... + + + + + Move + + + + + Copy + + + + + Remove + + + + + %1 Finished + + + + + Errors Occured + + + SlideshowWidget @@ -1106,4 +1140,22 @@ New Location: %2 + + TrayUI + + + Finished + + + + + Errors during operation. Click to view details + + + + + No Errors + + + diff --git a/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_tr.ts b/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_tr.ts index 8e1f41a0..d47e69a2 100644 --- a/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_tr.ts +++ b/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_tr.ts @@ -55,314 +55,325 @@ - DirWidget - - - Form - Form - - - - - Open item - Öğeyi aç - - - - - Open item (select application) - Öğeyi aç (uygulama seç) - - - - - Add item to personal favorites - Öğeyi kişisel sık kullanılanlara ekle - - - - - Rename item - Öğeyi yeniden adlandır - - - - Cut items - Öğeleri kes - + BrowserWidget - - Cut items (add to the clipboard) - Öğeleri kes (panoya ekle) - - - - Copy items - Öğeleri kopyala + + Name + Ad - - Copy items to the clipboard - Öğeleri panoya kopyala + + Size + Boyut - - - Paste items from clipboard - Panodan öğeleri yapıştır + + Type + Tür - - - Delete Items - Öğeleri Sil + + Date Modified + Değiştirilme Tarihi - - Stop loading the directory - Dizini yüklemeyi durdur + + Date Created + Oluşturulma Tarihi - - Add selected images to slideshow - Seçili resimleri slayt gösterisine ekle + + Capacity: %1 + Kapasite: %1 - - Create a new directory - Yeni bir dizin oluştur + + Files: %1 (%2) + Dosyalar: %1 (%2) - - New Dir - Yeni Dizin + + Files: %1 + - - Create a new file - Yeni bir dosya oluştur + + Dirs: %1 + Dizinler: %1 - - New File - Yeni Dosya + + No Directory Contents + + + + DirWidget - - Slideshow - Slayt gösterisi + + Form + Form - - Enqueue selection in multimedia player - Seçimi multimedya oynatıcıda sıraya al + + Increase Icon Sizes + - - Play - Oynat + + Decrease Icon Sizes + - + Back Geri - - + + Go back to previous directory Önceki dizine geri git - + Up Yukarı - - + + Go to parent directory Üst dizine git - + Home Ev - - + + Go to home directory Ev dizinine git - - - Close this browser - Bu tarayıcıyı kapat + + Menu + - - Name - Ad + + Select Action + - - Size - Boyut + + SingleColumn + - - Type - Tür + + Single column view + - - Date Modified - Değiştirilme Tarihi + + Dual Column + - - Date Created - Oluşturulma Tarihi + + Dual Column View + - - + (Limited Access) (Sınırlı Erişim) - - Capacity: %1 - Kapasite: %1 - - - - Files: %1 (%2) - Dosyalar: %1 (%2) - - - - Dirs: %1 - Dizinler: %1 - - - + + New Document Yeni Belge - - + + + Name: Ad: - + Error Creating Document Belge Oluşturmada Hata - + The document could not be created. Please ensure that you have the proper permissions. Belge oluşturulamadı. Lütfen uygun izinlere sahip olduğunuza emin olun. - + New Directory Yeni Dizin - + + + Invalid Name Geçersiz Ad - + + File Operations + + + + + Directory Operations + + + + + Loading... + + + + + + A file or directory with that name already exists! Please pick a different name. Aynı adda bir dosya ya da dizin zaten mevcut! Lütfen farklı bir ad seçin. - + Error Creating Directory Dizin Oluşturmada Hata - + The directory could not be created. Please ensure that you have the proper permissions to modify the current directory. Dizin oluşturulamadı. Lütfen geçerli dizinde değişiklik yapmak için uygun izinlere sahip olduğunuza emin olun. - + Current Geçerli - + + Create... + + + + + File + Dosya + + + + Directory + + + + + Application Launcher + + + + + Launch... + + + + + Terminal + + + + + SlideShow + + + + + Multimedia Player + + + + + Modify Files... + + + + + View Files... + + + + + Checksums + + + + + Properties + + + + File Checksums: Dosya Sağlama Toplamları: - + Missing Utility Eksik Gereç - + The "lumina-fileinfo" utility could not be found on the system. Please install it first. Sistemde "lumina-fileinfo" gereci bulunamadı. Lütfen önce gereci yükleyin. - + Open - + Open With... Birlikte Aç... - + Rename... Yeniden adlandır... - - View Checksums... - Sağlama Toplamlarını Görüntüle... - - - - File Properties... - Dosya Özellikleri... - - - + Cut Selection Seçimi Kes - + Copy Selection Seçimi Kopyala - + Paste Yapıştır - + Delete Selection Seçimi Sil - - - Open Terminal here - Uçbirimi burada aç - FODialog @@ -582,12 +593,12 @@ Yeni Konum: %2 Görü - + Shift+Left Shift+Sol - + Shift+Right Shift+Sağ @@ -607,363 +618,342 @@ Yeni Konum: %2 Görünüm Modu - - Group Mode - Grup Modu - - - + Bookmarks Yer imleri - + External Devices Harici Agıtlar - - Edit - Düzenle + + Git + - - Git + + New Tab - - + New Browser Yeni Gözatıcı - + Search Directory... Dizinde Ara... - + Increase Icon Size Simge Boyutunu Arttır - + Decrease Icon Size Simge Boyutunu Azalt - + Larger Icons Daha Büyük Simgeler - + Ctrl++ Ctrl++ - + Smaller Icons Daha Küçük Simgeler - + Ctrl+- Ctrl+- - + New Window Yeni Pencere - + Ctrl+N Ctrl+N - + Add Bookmark Yer İmi Ekle - + Ctrl+D Ctrl+D - + Delete Selection Seçimi Sil - + Del Sil - + Refresh Yenile - - Close Browser - Gözatıcıyı Kapat + + Close Tab + - + Repo Status - + Clone Repository - + Ctrl+T Ctrl+T - + Exit Çık - + Ctrl+Q Ctrl+Q - + &Preferences &Tercihler - + Show Hidden Files Gizli Dosyaları Göster - + Scan for Devices Aygıtlar için Tara - + Manage Bookmarks Yer İmlerini Yönet - + Show Action Buttons Eylem Düğmelerini Göster - + Load Thumbnails Küçük Resimleri Yükle - + Ctrl+F Ctrl+F - + Detailed List Ayrıntılı Liste - + Basic List Temel Liste - + Ctrl+W Ctrl+W - - Prefer Tabs - Sekmeler Tercih Et - - - - Prefer Columns - Sütunlar Tercih Et - - - + F5 F5 - + Ctrl+C Ctrl+C - + Rename... Yeniden adlandır... - + F2 F2 - + Cut Selection Seçimi Kes - + Copy Selection Seçimi Kopyala - + Paste Yapıştır - + Ctrl+V Ctrl+V - + Ctrl+X Ctrl+X - + Invalid Directories Geçersiz Dizinler - + The following directories are invalid and could not be opened: İzleyen dizinler geçersiz ve açılamadı: - + Root Kök - + %1 (Type: %2) %1 (Tür: %2) - + Filesystem: %1 Dosya sistemi: %1 - - Browser - Tarayıcı - - - + New Bookmark Yeni Yer İmi - + Name: Ad: - + Invalid Name Geçersiz Ad - + This bookmark name already exists. Please choose another. Bu yer imi adı zaten mevcut. Lütfen başka bir ad seçin. - + Git Repository Status - + Multimedia Multimedya - + Slideshow Slayt gösterisi - + Items to be removed: Kaldırılacak öğeler: - + Verify Quit Çıkışı Doğrula - + Ctrl+H Ctrl+H - + Ctrl+L - + You have multiple tabs open. Are you sure you want to quit? Açık birden çok sekmeniz mevcut. Çıkmak istediğinize emin misiniz? - + Verify Removal Kaldırmayı Doğrula - + WARNING: This will permanently delete the file(s) from the system! UYARI: Bu işlemle dosya(lar) sistemden kalıcı olarak silinecek! - + Are you sure you want to continue? Devam etmek istediğinize emin misiniz? - + Rename File Dosyayı Yeniden Adlandır - + New Name: Yeni Ad: - + Overwrite File? Dosyanın Üzerine Yazılsın Mı? - + An existing file with the same name will be replaced. Are you sure you want to proceed? Aynı ada sahip mevcut bir dosya yenisiyle değiştirilecek. İlerlemek istediğinize emin misiniz? @@ -1006,6 +996,50 @@ Yeni Konum: %2 Tamamlandı + + OPWidget + + + Form + Form + + + + + ... + ... + + + + Evaluating... + + + + + Move + + + + + Copy + + + + + Remove + + + + + %1 Finished + + + + + Errors Occured + + + SlideshowWidget @@ -1109,4 +1143,22 @@ Yeni Konum: %2 Devam etmek istediğinize emin misiniz? + + TrayUI + + + Finished + + + + + Errors during operation. Click to view details + + + + + No Errors + + + diff --git a/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_uk.ts b/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_uk.ts index 9c6c59be..f77032df 100644 --- a/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_uk.ts +++ b/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_uk.ts @@ -55,314 +55,325 @@ - DirWidget - - - Form - Форма - - - - - Open item - Відкрити елемент - - - - - Open item (select application) - Відкрити елемент (вибрати програму) - - - - - Add item to personal favorites - Додати елемент в Улюблене. - - - - - Rename item - Перейменування елементу - - - - Cut items - Вирізати елементи - + BrowserWidget - - Cut items (add to the clipboard) - Вирізати елементи (додати в буфер обміну) - - - - Copy items - Копіювати запис + + Name + Ім'я - - Copy items to the clipboard - Скопіювати адреси до буфера + + Size + Розмір - - - Paste items from clipboard - Вставити дані з буфера обміну + + Type + Тип - - - Delete Items - Вилучення елементів + + Date Modified + Дата зміни - - Stop loading the directory - Призупинити завантаження каталогу + + Date Created + Дата створення - - Add selected images to slideshow - Додати вибрані зображення в слайдшоу + + Capacity: %1 + Місткість: %1 - - Create a new directory - Створити новий каталог + + Files: %1 (%2) + Файли: %1 (%2) - - New Dir - Новий каталог + + Files: %1 + - - Create a new file - Створити новий файл + + Dirs: %1 + Dirs: %1 - - New File - Новий файл + + No Directory Contents + + + + DirWidget - - Slideshow - Слайдшоу + + Form + Форма - - Enqueue selection in multimedia player - Додати вибране в програвач мультимедіа + + Increase Icon Sizes + - - Play - Відтворити + + Decrease Icon Sizes + - + Back Назад - - + + Go back to previous directory Повернутися до попереднього каталогу - + Up Верх - - + + Go to parent directory В батьківську теку - + Home Домівка - - + + Go to home directory В домашню теку - - - Close this browser - Закрити цей браузер + + Menu + - - Name - Ім'я + + Select Action + - - Size - Розмір + + SingleColumn + - - Type - Тип + + Single column view + - - Date Modified - Дата зміни + + Dual Column + - - Date Created - Дата створення + + Dual Column View + - - + (Limited Access) (Обмежений доступ) - - Capacity: %1 - Місткість: %1 - - - - Files: %1 (%2) - Файли: %1 (%2) - - - - Dirs: %1 - Dirs: %1 - - - + + New Document Новий документ - - + + + Name: Ім'я: - + Error Creating Document Помилка створення документа - + The document could not be created. Please ensure that you have the proper permissions. Цей документ не може бути створений. Будь ласка, впевніться, що у вас є відповідні права. - + New Directory Новий каталог - + + + Invalid Name Некоректна назва - + + File Operations + + + + + Directory Operations + + + + + Loading... + + + + + + A file or directory with that name already exists! Please pick a different name. Файл або каталог з таким іменем вже існує! Будь ласка, виберіть інше ім'я. - + Error Creating Directory Помилка створення каталогу - + The directory could not be created. Please ensure that you have the proper permissions to modify the current directory. Каталог не може бути створений. Будь ласка, впевніться, що у вас є відповідні права, щоб змінити поточний каталог. - + Current Поточний - + + Create... + + + + + File + Файл + + + + Directory + + + + + Application Launcher + + + + + Launch... + + + + + Terminal + + + + + SlideShow + + + + + Multimedia Player + + + + + Modify Files... + + + + + View Files... + + + + + Checksums + + + + + Properties + + + + File Checksums: Контрольні суми файлів: - + Missing Utility Утиліта не знайдена - + The "lumina-fileinfo" utility could not be found on the system. Please install it first. Утиліта "Lumina-FileInfo" не може бути знайдена в системі. Будь ласка, встановіть її в першу чергу. - + Open Відкрити - + Open With... Відкрити за допомогою… - + Rename... Перейменувати... - - View Checksums... - Переглянути контрольні суми... - - - - File Properties... - Властивості файлу... - - - + Cut Selection Вирізати обране - + Copy Selection Копіювати виділене - + Paste Вставити - + Delete Selection Видалити виділене - - - Open Terminal here - Відкрити Термінал тут - FODialog @@ -582,12 +593,12 @@ New Location: %2 Insight - + Shift+Left Shift+ліворуч - + Shift+Right Shift+праворуч @@ -607,363 +618,342 @@ New Location: %2 Режим перегляду - - Group Mode - Груповий режим - - - + Bookmarks Закладки - + External Devices Зовнішні пристрої - - Edit - Редагувати + + Git + - - Git + + New Tab - - + New Browser Новий браузер - + Search Directory... Пошук у каталозі... - + Increase Icon Size Збільшити розмір піктограми - + Decrease Icon Size Зменшити розмір піктограми - + Larger Icons Великі піктограми - + Ctrl++ Ctrl++ - + Smaller Icons Малі піктограми - + Ctrl+- Ctrl+- - + New Window Нове вікно - + Ctrl+N Ctrl+N - + Add Bookmark Додати закладку - + Ctrl+D Ctrl+D - + Delete Selection Видалити виділене - + Del Del - + Refresh Оновити - - Close Browser - Закрити браузер + + Close Tab + - + Repo Status - + Clone Repository - + Ctrl+T Ctrl+T - + Exit Вихід - + Ctrl+Q Ctrl+Q - + &Preferences &Налаштування - + Show Hidden Files Показати приховані файли - + Scan for Devices Пошук пристроїв - + Manage Bookmarks Керування закладками - + Show Action Buttons Показати дійові кнопки - + Load Thumbnails Завантажити мініатюри - + Ctrl+F Ctrl+F - + Detailed List Детальний список - + Basic List Список - + Ctrl+W Ctrl+W - - Prefer Tabs - Переважаючі вкладки - - - - Prefer Columns - Переважаючі стовпчики - - - + F5 F5 - + Ctrl+C Ctrl+C - + Rename... Перейменувати... - + F2 F2 - + Cut Selection Вирізати обране - + Copy Selection Копіювати виділене - + Paste Вставити - + Ctrl+V Ctrl+V - + Ctrl+X Ctrl+X - + Invalid Directories Невірний каталог - + The following directories are invalid and could not be opened: Наступні папки недопустимі та не можуть бути відкриті: - + Root Root - + %1 (Type: %2) %1 (Тип: %2) - + Filesystem: %1 Файлова система: %1 - - Browser - Браузер - - - + New Bookmark Нова закладка - + Name: Ім'я: - + Invalid Name Некоректна назва - + This bookmark name already exists. Please choose another. Закладка з таким іменем вже існує. Виберіть іншу назву. - + Git Repository Status - + Multimedia Мультимедіа - + Slideshow Слайдшоу - + Items to be removed: Об'єкти будуть видалені: - + Verify Quit Перевірка виходу - + Ctrl+H - + Ctrl+L - + You have multiple tabs open. Are you sure you want to quit? У вас відкрито декілька вкладок, ви дійсно хочете його закрити? - + Verify Removal Перевірити Видалення - + WARNING: This will permanently delete the file(s) from the system! УВАГА: Це назавжди видалить файл(и) з системи! - + Are you sure you want to continue? Ви справді бажаєте продовжити? - + Rename File Перейменувати файл - + New Name: Нова назва: - + Overwrite File? Перезаписати файл? - + An existing file with the same name will be replaced. Are you sure you want to proceed? Існуючий файл з таким іменем буде замінений. Ви впевнені, що хочете продовжити? @@ -1006,6 +996,50 @@ New Location: %2 Завершено + + OPWidget + + + Form + Форма + + + + + ... + ... + + + + Evaluating... + + + + + Move + + + + + Copy + + + + + Remove + + + + + %1 Finished + + + + + Errors Occured + + + SlideshowWidget @@ -1109,4 +1143,22 @@ New Location: %2 Ви впевнені, що хочете продовжити? + + TrayUI + + + Finished + Завершено + + + + Errors during operation. Click to view details + + + + + No Errors + + + diff --git a/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_uz.ts b/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_uz.ts index 20550897..629ab157 100644 --- a/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_uz.ts +++ b/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_uz.ts @@ -55,314 +55,325 @@ - DirWidget + BrowserWidget - - Form + + Name - - - Open item + + Size - - - Open item (select application) + + Type - - - Add item to personal favorites + + Date Modified - - - Rename item + + Date Created - - Cut items + + Capacity: %1 - - Cut items (add to the clipboard) + + Files: %1 (%2) - - Copy items + + Files: %1 - - Copy items to the clipboard + + Dirs: %1 - - - Paste items from clipboard + + No Directory Contents + + + DirWidget - - - Delete Items + + Form - - Stop loading the directory + + Increase Icon Sizes - - Add selected images to slideshow + + Decrease Icon Sizes - - Create a new directory + + Back - - New Dir + + + Go back to previous directory - - Create a new file + + Up - - New File + + + Go to parent directory - - Slideshow + + Home - - Enqueue selection in multimedia player + + + Go to home directory - - Play + + Menu - - Back + + Select Action - - - Go back to previous directory + + SingleColumn - - Up + + Single column view - - - Go to parent directory + + Dual Column - - Home + + Dual Column View - - - Go to home directory + + (Limited Access) - - - Close this browser + + + New Document - - Name + + + + Name: - - Size + + Error Creating Document - - Type + + The document could not be created. Please ensure that you have the proper permissions. - - Date Modified + + New Directory - - Date Created + + + + Invalid Name - - - (Limited Access) + + File Operations - - Capacity: %1 + + Directory Operations - - Files: %1 (%2) + + Loading... - - Dirs: %1 + + + + A file or directory with that name already exists! Please pick a different name. - - New Document + + Error Creating Directory - - - Name: + + The directory could not be created. Please ensure that you have the proper permissions to modify the current directory. - - Error Creating Document + + Current - - The document could not be created. Please ensure that you have the proper permissions. + + Create... - - New Directory + + File - - Invalid Name + + Directory - - A file or directory with that name already exists! Please pick a different name. + + Application Launcher - - Error Creating Directory + + Launch... - - The directory could not be created. Please ensure that you have the proper permissions to modify the current directory. + + Terminal - - Current + + SlideShow - - File Checksums: + + Multimedia Player - - Missing Utility + + Modify Files... - - The "lumina-fileinfo" utility could not be found on the system. Please install it first. + + View Files... - - Open + + Checksums - - Open With... + + Properties - - Rename... + + File Checksums: + + + + + Missing Utility + + + + + The "lumina-fileinfo" utility could not be found on the system. Please install it first. + + + + + Open - - View Checksums... + + Open With... - - File Properties... + + Rename... - + Cut Selection - + Copy Selection - + Paste - + Delete Selection - - - Open Terminal here - - FODialog @@ -579,12 +590,12 @@ New Location: %2 - + Shift+Left - + Shift+Right @@ -604,363 +615,342 @@ New Location: %2 - - Group Mode - - - - + Bookmarks - + External Devices - - Edit + + Git - - Git + + New Tab - - + New Browser - + Search Directory... - + Increase Icon Size - + Decrease Icon Size - + Larger Icons - + Ctrl++ - + Smaller Icons - + Ctrl+- - + New Window - + Ctrl+N - + Add Bookmark - + Ctrl+D - + Delete Selection - + Del - + Refresh - - Close Browser + + Close Tab - + Repo Status - + Clone Repository - + Ctrl+T - + Exit - + Ctrl+Q - + &Preferences - + Show Hidden Files - + Scan for Devices - + Manage Bookmarks - + Show Action Buttons - + Load Thumbnails - + Ctrl+F - + Detailed List - + Basic List - + Ctrl+W - - Prefer Tabs - - - - - Prefer Columns - - - - + F5 - + Ctrl+C - + Rename... - + F2 - + Cut Selection - + Copy Selection - + Paste - + Ctrl+V - + Ctrl+X - + Invalid Directories - + The following directories are invalid and could not be opened: - + Root - + %1 (Type: %2) - + Filesystem: %1 - - Browser - - - - + New Bookmark - + Name: - + Invalid Name - + This bookmark name already exists. Please choose another. - + Git Repository Status - + Multimedia - + Slideshow - + Items to be removed: - + Verify Quit - + Ctrl+H - + Ctrl+L - + You have multiple tabs open. Are you sure you want to quit? - + Verify Removal - + WARNING: This will permanently delete the file(s) from the system! - + Are you sure you want to continue? - + Rename File - + New Name: - + Overwrite File? - + An existing file with the same name will be replaced. Are you sure you want to proceed? @@ -1003,6 +993,50 @@ New Location: %2 + + OPWidget + + + Form + + + + + + ... + + + + + Evaluating... + + + + + Move + + + + + Copy + + + + + Remove + + + + + %1 Finished + + + + + Errors Occured + + + SlideshowWidget @@ -1106,4 +1140,22 @@ New Location: %2 + + TrayUI + + + Finished + + + + + Errors during operation. Click to view details + + + + + No Errors + + + diff --git a/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_vi.ts b/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_vi.ts index 20550897..629ab157 100644 --- a/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_vi.ts +++ b/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_vi.ts @@ -55,314 +55,325 @@ - DirWidget + BrowserWidget - - Form + + Name - - - Open item + + Size - - - Open item (select application) + + Type - - - Add item to personal favorites + + Date Modified - - - Rename item + + Date Created - - Cut items + + Capacity: %1 - - Cut items (add to the clipboard) + + Files: %1 (%2) - - Copy items + + Files: %1 - - Copy items to the clipboard + + Dirs: %1 - - - Paste items from clipboard + + No Directory Contents + + + DirWidget - - - Delete Items + + Form - - Stop loading the directory + + Increase Icon Sizes - - Add selected images to slideshow + + Decrease Icon Sizes - - Create a new directory + + Back - - New Dir + + + Go back to previous directory - - Create a new file + + Up - - New File + + + Go to parent directory - - Slideshow + + Home - - Enqueue selection in multimedia player + + + Go to home directory - - Play + + Menu - - Back + + Select Action - - - Go back to previous directory + + SingleColumn - - Up + + Single column view - - - Go to parent directory + + Dual Column - - Home + + Dual Column View - - - Go to home directory + + (Limited Access) - - - Close this browser + + + New Document - - Name + + + + Name: - - Size + + Error Creating Document - - Type + + The document could not be created. Please ensure that you have the proper permissions. - - Date Modified + + New Directory - - Date Created + + + + Invalid Name - - - (Limited Access) + + File Operations - - Capacity: %1 + + Directory Operations - - Files: %1 (%2) + + Loading... - - Dirs: %1 + + + + A file or directory with that name already exists! Please pick a different name. - - New Document + + Error Creating Directory - - - Name: + + The directory could not be created. Please ensure that you have the proper permissions to modify the current directory. - - Error Creating Document + + Current - - The document could not be created. Please ensure that you have the proper permissions. + + Create... - - New Directory + + File - - Invalid Name + + Directory - - A file or directory with that name already exists! Please pick a different name. + + Application Launcher - - Error Creating Directory + + Launch... - - The directory could not be created. Please ensure that you have the proper permissions to modify the current directory. + + Terminal - - Current + + SlideShow - - File Checksums: + + Multimedia Player - - Missing Utility + + Modify Files... - - The "lumina-fileinfo" utility could not be found on the system. Please install it first. + + View Files... - - Open + + Checksums - - Open With... + + Properties - - Rename... + + File Checksums: + + + + + Missing Utility + + + + + The "lumina-fileinfo" utility could not be found on the system. Please install it first. + + + + + Open - - View Checksums... + + Open With... - - File Properties... + + Rename... - + Cut Selection - + Copy Selection - + Paste - + Delete Selection - - - Open Terminal here - - FODialog @@ -579,12 +590,12 @@ New Location: %2 - + Shift+Left - + Shift+Right @@ -604,363 +615,342 @@ New Location: %2 - - Group Mode - - - - + Bookmarks - + External Devices - - Edit + + Git - - Git + + New Tab - - + New Browser - + Search Directory... - + Increase Icon Size - + Decrease Icon Size - + Larger Icons - + Ctrl++ - + Smaller Icons - + Ctrl+- - + New Window - + Ctrl+N - + Add Bookmark - + Ctrl+D - + Delete Selection - + Del - + Refresh - - Close Browser + + Close Tab - + Repo Status - + Clone Repository - + Ctrl+T - + Exit - + Ctrl+Q - + &Preferences - + Show Hidden Files - + Scan for Devices - + Manage Bookmarks - + Show Action Buttons - + Load Thumbnails - + Ctrl+F - + Detailed List - + Basic List - + Ctrl+W - - Prefer Tabs - - - - - Prefer Columns - - - - + F5 - + Ctrl+C - + Rename... - + F2 - + Cut Selection - + Copy Selection - + Paste - + Ctrl+V - + Ctrl+X - + Invalid Directories - + The following directories are invalid and could not be opened: - + Root - + %1 (Type: %2) - + Filesystem: %1 - - Browser - - - - + New Bookmark - + Name: - + Invalid Name - + This bookmark name already exists. Please choose another. - + Git Repository Status - + Multimedia - + Slideshow - + Items to be removed: - + Verify Quit - + Ctrl+H - + Ctrl+L - + You have multiple tabs open. Are you sure you want to quit? - + Verify Removal - + WARNING: This will permanently delete the file(s) from the system! - + Are you sure you want to continue? - + Rename File - + New Name: - + Overwrite File? - + An existing file with the same name will be replaced. Are you sure you want to proceed? @@ -1003,6 +993,50 @@ New Location: %2 + + OPWidget + + + Form + + + + + + ... + + + + + Evaluating... + + + + + Move + + + + + Copy + + + + + Remove + + + + + %1 Finished + + + + + Errors Occured + + + SlideshowWidget @@ -1106,4 +1140,22 @@ New Location: %2 + + TrayUI + + + Finished + + + + + Errors during operation. Click to view details + + + + + No Errors + + + diff --git a/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_zh_CN.ts b/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_zh_CN.ts index 0b92617f..1570de97 100644 --- a/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_zh_CN.ts +++ b/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_zh_CN.ts @@ -57,314 +57,325 @@ - DirWidget - - - Form - 表单 - - - - - Open item - 打开项目 - - - - - Open item (select application) - 打开项目 (选择应用程序) - + BrowserWidget - - - Add item to personal favorites - 添加项目到个人收藏 - - - - - Rename item - 重命名项目 - - - - Cut items - 剪切项目 - - - - Cut items (add to the clipboard) - 剪切项目 (添加到剪贴板) - - - - Copy items - 复制项目 + + Name + 名称 - - Copy items to the clipboard - 复制项目到剪贴板 + + Size + 大小 - - - Paste items from clipboard - 从剪贴板中粘贴项目 + + Type + 类型 - - - Delete Items - 删除项目 + + Date Modified + 修改日期 - - Stop loading the directory - 停止载入目录 + + Date Created + 建立日期 - - Add selected images to slideshow - 将选中图片添加到幻灯片浏览 + + Capacity: %1 + 容量: %1 - - Create a new directory - 建立新目录 + + Files: %1 (%2) + 文件: %1 (%2) - - New Dir - 新建目录 + + Files: %1 + - - Create a new file - 新建文件 + + Dirs: %1 + 目录: %1 - - New File - 新建文件 + + No Directory Contents + + + + DirWidget - - Slideshow - 幻灯片浏览 + + Form + 表单 - - Enqueue selection in multimedia player - 将选中项加入媒体播放器 + + Increase Icon Sizes + - - Play - 播放 + + Decrease Icon Sizes + - + Back 返回 - - + + Go back to previous directory 返回上一个目录 - + Up 向上 - - + + Go to parent directory 前往上层目录 - + Home 用户目录 - - + + Go to home directory 回到用户目录 - - - Close this browser - 关闭浏览器 + + Menu + - - Name - 名称 + + Select Action + - - Size - 大小 + + SingleColumn + - - Type - 类型 + + Single column view + - - Date Modified - 修改日期 + + Dual Column + - - Date Created - 建立日期 + + Dual Column View + - - + (Limited Access) (有限访问) - - Capacity: %1 - 容量: %1 - - - - Files: %1 (%2) - 文件: %1 (%2) - - - - Dirs: %1 - 目录: %1 - - - + + New Document 新文档 - - + + + Name: 名称: - + Error Creating Document 建立文档出错 - + The document could not be created. Please ensure that you have the proper permissions. 无法建立文档。请确定您有适当的权限。 - + New Directory 新目录 - + + + Invalid Name 无效的名称 - + + File Operations + + + + + Directory Operations + + + + + Loading... + + + + + + A file or directory with that name already exists! Please pick a different name. 已有相同名字的文件或目录存在!请选择一个不同的名字。 - + Error Creating Directory 创建目录错误 - + The directory could not be created. Please ensure that you have the proper permissions to modify the current directory. 目录无法被建立。请检查您有更改当前目录的适当权限。 - + Current 当前 - + + Create... + + + + + File + 文件 + + + + Directory + + + + + Application Launcher + + + + + Launch... + + + + + Terminal + + + + + SlideShow + + + + + Multimedia Player + + + + + Modify Files... + + + + + View Files... + + + + + Checksums + + + + + Properties + + + + File Checksums: 文件校验值: - + Missing Utility 缺少的工具 - + The "lumina-fileinfo" utility could not be found on the system. Please install it first. 无法在您的系统里找到 "lumina-fileinfo" 工具。请先安装它。 - + Open 打开 - + Open With... 打开方式... - + Rename... 重命名... - - View Checksums... - 查看校验和... - - - - File Properties... - 文件属性... - - - + Cut Selection 剪切选中部分 - + Copy Selection 复制选中部分 - + Paste 粘贴 - + Delete Selection 删除选中部分 - - - Open Terminal here - 在此处打开终端 - FODialog @@ -587,12 +598,12 @@ New Location: %2 启示 - + Shift+Left Shift+Left - + Shift+Right Shift+Right @@ -612,367 +623,346 @@ New Location: %2 视图模式 - - Group Mode - 分组模式 - - - + Bookmarks 书签 - + External Devices 外部设备 - - Edit - 编辑 + + Git + - - Git + + New Tab - - + New Browser 新浏览器 - + Search Directory... 搜索目录... - + Increase Icon Size 增加图标大小 - + Decrease Icon Size 减少图标大小 - + Larger Icons 更大的图标 - + Ctrl++ Ctrl++ - + Smaller Icons 更小的图标 - + Ctrl+- Ctrl+- - + New Window 新窗口 - + Ctrl+N Ctrl+N - + Add Bookmark 添加书签 - + Ctrl+D Ctrl+D - + Delete Selection 删除选择 - + Del Del - + Refresh 刷新 - - Close Browser - 关闭浏览器 + + Close Tab + - + Repo Status - + Clone Repository - + Ctrl+T Ctrl+T - + Exit 退出 - + Ctrl+Q Ctrl+Q - + &Preferences 首选项(&P) - + Show Hidden Files 显示隐藏文件 - + Scan for Devices 扫描设备 - + Manage Bookmarks 管理书签 - + Show Action Buttons 显示动作按钮 - + Load Thumbnails 载入缩略图 - + Ctrl+F Ctrl+F - + Detailed List 详细列表 - + Basic List 基本清单 - + Ctrl+W Ctrl+W - - Prefer Tabs - 偏好分页 - - - - Prefer Columns - 偏好分栏 - - - + F5 F5 - + Ctrl+C Ctrl+C - + Rename... 重命名... - + F2 F2 - + Cut Selection 剪切选中部分 - + Copy Selection 复制选择部分 - + Paste 粘贴 - + Ctrl+V Ctrl+V - + Ctrl+X Ctrl+X - + Invalid Directories 无效的目录 - + The following directories are invalid and could not be opened: 以下目录无效,无法打开: - + Root - + %1 (Type: %2) %1 (类型:%2) %1 (类型:%2) - + Filesystem: %1 文件系统:%1 - - Browser - 浏览器 - - - + New Bookmark 新书签 - + Name: 名称: - + Invalid Name 无效的名称 - + This bookmark name already exists. Please choose another. 已经存在这个书签名。请输入另一个名字。 - + Git Repository Status - + Multimedia 多媒体 - + Slideshow 幻灯片 - + Items to be removed: 将要删除的项目: - + Verify Quit 快速退出 快速退出 - + Ctrl+H Ctrl+H - + Ctrl+L - + You have multiple tabs open. Are you sure you want to quit? 你有多个标签打开。你确定要退出吗? 你有多个标签打开。你确定要退出吗? - + Verify Removal 快速移除 快速移除 - + WARNING: This will permanently delete the file(s) from the system! 警告:这将永久删除系统中的文件! - + Are you sure you want to continue? 您确定要继续吗? - + Rename File 重命名文件 - + New Name: 新名称: - + Overwrite File? 覆盖文件吗? - + An existing file with the same name will be replaced. Are you sure you want to proceed? 将替换同名的现有文件。你确定要继续吗? 将替换同名的现有文件。你确定要继续吗? @@ -1016,6 +1006,50 @@ New Location: %2 已完成 + + OPWidget + + + Form + 表单 + + + + + ... + ... + + + + Evaluating... + + + + + Move + + + + + Copy + + + + + Remove + + + + + %1 Finished + + + + + Errors Occured + + + SlideshowWidget @@ -1119,4 +1153,22 @@ New Location: %2 您确定要继续吗? + + TrayUI + + + Finished + + + + + Errors during operation. Click to view details + + + + + No Errors + + + diff --git a/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_zh_HK.ts b/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_zh_HK.ts index 20550897..629ab157 100644 --- a/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_zh_HK.ts +++ b/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_zh_HK.ts @@ -55,314 +55,325 @@ - DirWidget + BrowserWidget - - Form + + Name - - - Open item + + Size - - - Open item (select application) + + Type - - - Add item to personal favorites + + Date Modified - - - Rename item + + Date Created - - Cut items + + Capacity: %1 - - Cut items (add to the clipboard) + + Files: %1 (%2) - - Copy items + + Files: %1 - - Copy items to the clipboard + + Dirs: %1 - - - Paste items from clipboard + + No Directory Contents + + + DirWidget - - - Delete Items + + Form - - Stop loading the directory + + Increase Icon Sizes - - Add selected images to slideshow + + Decrease Icon Sizes - - Create a new directory + + Back - - New Dir + + + Go back to previous directory - - Create a new file + + Up - - New File + + + Go to parent directory - - Slideshow + + Home - - Enqueue selection in multimedia player + + + Go to home directory - - Play + + Menu - - Back + + Select Action - - - Go back to previous directory + + SingleColumn - - Up + + Single column view - - - Go to parent directory + + Dual Column - - Home + + Dual Column View - - - Go to home directory + + (Limited Access) - - - Close this browser + + + New Document - - Name + + + + Name: - - Size + + Error Creating Document - - Type + + The document could not be created. Please ensure that you have the proper permissions. - - Date Modified + + New Directory - - Date Created + + + + Invalid Name - - - (Limited Access) + + File Operations - - Capacity: %1 + + Directory Operations - - Files: %1 (%2) + + Loading... - - Dirs: %1 + + + + A file or directory with that name already exists! Please pick a different name. - - New Document + + Error Creating Directory - - - Name: + + The directory could not be created. Please ensure that you have the proper permissions to modify the current directory. - - Error Creating Document + + Current - - The document could not be created. Please ensure that you have the proper permissions. + + Create... - - New Directory + + File - - Invalid Name + + Directory - - A file or directory with that name already exists! Please pick a different name. + + Application Launcher - - Error Creating Directory + + Launch... - - The directory could not be created. Please ensure that you have the proper permissions to modify the current directory. + + Terminal - - Current + + SlideShow - - File Checksums: + + Multimedia Player - - Missing Utility + + Modify Files... - - The "lumina-fileinfo" utility could not be found on the system. Please install it first. + + View Files... - - Open + + Checksums - - Open With... + + Properties - - Rename... + + File Checksums: + + + + + Missing Utility + + + + + The "lumina-fileinfo" utility could not be found on the system. Please install it first. + + + + + Open - - View Checksums... + + Open With... - - File Properties... + + Rename... - + Cut Selection - + Copy Selection - + Paste - + Delete Selection - - - Open Terminal here - - FODialog @@ -579,12 +590,12 @@ New Location: %2 - + Shift+Left - + Shift+Right @@ -604,363 +615,342 @@ New Location: %2 - - Group Mode - - - - + Bookmarks - + External Devices - - Edit + + Git - - Git + + New Tab - - + New Browser - + Search Directory... - + Increase Icon Size - + Decrease Icon Size - + Larger Icons - + Ctrl++ - + Smaller Icons - + Ctrl+- - + New Window - + Ctrl+N - + Add Bookmark - + Ctrl+D - + Delete Selection - + Del - + Refresh - - Close Browser + + Close Tab - + Repo Status - + Clone Repository - + Ctrl+T - + Exit - + Ctrl+Q - + &Preferences - + Show Hidden Files - + Scan for Devices - + Manage Bookmarks - + Show Action Buttons - + Load Thumbnails - + Ctrl+F - + Detailed List - + Basic List - + Ctrl+W - - Prefer Tabs - - - - - Prefer Columns - - - - + F5 - + Ctrl+C - + Rename... - + F2 - + Cut Selection - + Copy Selection - + Paste - + Ctrl+V - + Ctrl+X - + Invalid Directories - + The following directories are invalid and could not be opened: - + Root - + %1 (Type: %2) - + Filesystem: %1 - - Browser - - - - + New Bookmark - + Name: - + Invalid Name - + This bookmark name already exists. Please choose another. - + Git Repository Status - + Multimedia - + Slideshow - + Items to be removed: - + Verify Quit - + Ctrl+H - + Ctrl+L - + You have multiple tabs open. Are you sure you want to quit? - + Verify Removal - + WARNING: This will permanently delete the file(s) from the system! - + Are you sure you want to continue? - + Rename File - + New Name: - + Overwrite File? - + An existing file with the same name will be replaced. Are you sure you want to proceed? @@ -1003,6 +993,50 @@ New Location: %2 + + OPWidget + + + Form + + + + + + ... + + + + + Evaluating... + + + + + Move + + + + + Copy + + + + + Remove + + + + + %1 Finished + + + + + Errors Occured + + + SlideshowWidget @@ -1106,4 +1140,22 @@ New Location: %2 + + TrayUI + + + Finished + + + + + Errors during operation. Click to view details + + + + + No Errors + + + diff --git a/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_zh_TW.ts b/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_zh_TW.ts index 20550897..629ab157 100644 --- a/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_zh_TW.ts +++ b/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_zh_TW.ts @@ -55,314 +55,325 @@ - DirWidget + BrowserWidget - - Form + + Name - - - Open item + + Size - - - Open item (select application) + + Type - - - Add item to personal favorites + + Date Modified - - - Rename item + + Date Created - - Cut items + + Capacity: %1 - - Cut items (add to the clipboard) + + Files: %1 (%2) - - Copy items + + Files: %1 - - Copy items to the clipboard + + Dirs: %1 - - - Paste items from clipboard + + No Directory Contents + + + DirWidget - - - Delete Items + + Form - - Stop loading the directory + + Increase Icon Sizes - - Add selected images to slideshow + + Decrease Icon Sizes - - Create a new directory + + Back - - New Dir + + + Go back to previous directory - - Create a new file + + Up - - New File + + + Go to parent directory - - Slideshow + + Home - - Enqueue selection in multimedia player + + + Go to home directory - - Play + + Menu - - Back + + Select Action - - - Go back to previous directory + + SingleColumn - - Up + + Single column view - - - Go to parent directory + + Dual Column - - Home + + Dual Column View - - - Go to home directory + + (Limited Access) - - - Close this browser + + + New Document - - Name + + + + Name: - - Size + + Error Creating Document - - Type + + The document could not be created. Please ensure that you have the proper permissions. - - Date Modified + + New Directory - - Date Created + + + + Invalid Name - - - (Limited Access) + + File Operations - - Capacity: %1 + + Directory Operations - - Files: %1 (%2) + + Loading... - - Dirs: %1 + + + + A file or directory with that name already exists! Please pick a different name. - - New Document + + Error Creating Directory - - - Name: + + The directory could not be created. Please ensure that you have the proper permissions to modify the current directory. - - Error Creating Document + + Current - - The document could not be created. Please ensure that you have the proper permissions. + + Create... - - New Directory + + File - - Invalid Name + + Directory - - A file or directory with that name already exists! Please pick a different name. + + Application Launcher - - Error Creating Directory + + Launch... - - The directory could not be created. Please ensure that you have the proper permissions to modify the current directory. + + Terminal - - Current + + SlideShow - - File Checksums: + + Multimedia Player - - Missing Utility + + Modify Files... - - The "lumina-fileinfo" utility could not be found on the system. Please install it first. + + View Files... - - Open + + Checksums - - Open With... + + Properties - - Rename... + + File Checksums: + + + + + Missing Utility + + + + + The "lumina-fileinfo" utility could not be found on the system. Please install it first. + + + + + Open - - View Checksums... + + Open With... - - File Properties... + + Rename... - + Cut Selection - + Copy Selection - + Paste - + Delete Selection - - - Open Terminal here - - FODialog @@ -579,12 +590,12 @@ New Location: %2 - + Shift+Left - + Shift+Right @@ -604,363 +615,342 @@ New Location: %2 - - Group Mode - - - - + Bookmarks - + External Devices - - Edit + + Git - - Git + + New Tab - - + New Browser - + Search Directory... - + Increase Icon Size - + Decrease Icon Size - + Larger Icons - + Ctrl++ - + Smaller Icons - + Ctrl+- - + New Window - + Ctrl+N - + Add Bookmark - + Ctrl+D - + Delete Selection - + Del - + Refresh - - Close Browser + + Close Tab - + Repo Status - + Clone Repository - + Ctrl+T - + Exit - + Ctrl+Q - + &Preferences - + Show Hidden Files - + Scan for Devices - + Manage Bookmarks - + Show Action Buttons - + Load Thumbnails - + Ctrl+F - + Detailed List - + Basic List - + Ctrl+W - - Prefer Tabs - - - - - Prefer Columns - - - - + F5 - + Ctrl+C - + Rename... - + F2 - + Cut Selection - + Copy Selection - + Paste - + Ctrl+V - + Ctrl+X - + Invalid Directories - + The following directories are invalid and could not be opened: - + Root - + %1 (Type: %2) - + Filesystem: %1 - - Browser - - - - + New Bookmark - + Name: - + Invalid Name - + This bookmark name already exists. Please choose another. - + Git Repository Status - + Multimedia - + Slideshow - + Items to be removed: - + Verify Quit - + Ctrl+H - + Ctrl+L - + You have multiple tabs open. Are you sure you want to quit? - + Verify Removal - + WARNING: This will permanently delete the file(s) from the system! - + Are you sure you want to continue? - + Rename File - + New Name: - + Overwrite File? - + An existing file with the same name will be replaced. Are you sure you want to proceed? @@ -1003,6 +993,50 @@ New Location: %2 + + OPWidget + + + Form + + + + + + ... + + + + + Evaluating... + + + + + Move + + + + + Copy + + + + + Remove + + + + + %1 Finished + + + + + Errors Occured + + + SlideshowWidget @@ -1106,4 +1140,22 @@ New Location: %2 + + TrayUI + + + Finished + + + + + Errors during operation. Click to view details + + + + + No Errors + + + diff --git a/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_zu.ts b/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_zu.ts index 20550897..629ab157 100644 --- a/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_zu.ts +++ b/src-qt5/desktop-utils/lumina-fm/i18n/lumina-fm_zu.ts @@ -55,314 +55,325 @@ - DirWidget + BrowserWidget - - Form + + Name - - - Open item + + Size - - - Open item (select application) + + Type - - - Add item to personal favorites + + Date Modified - - - Rename item + + Date Created - - Cut items + + Capacity: %1 - - Cut items (add to the clipboard) + + Files: %1 (%2) - - Copy items + + Files: %1 - - Copy items to the clipboard + + Dirs: %1 - - - Paste items from clipboard + + No Directory Contents + + + DirWidget - - - Delete Items + + Form - - Stop loading the directory + + Increase Icon Sizes - - Add selected images to slideshow + + Decrease Icon Sizes - - Create a new directory + + Back - - New Dir + + + Go back to previous directory - - Create a new file + + Up - - New File + + + Go to parent directory - - Slideshow + + Home - - Enqueue selection in multimedia player + + + Go to home directory - - Play + + Menu - - Back + + Select Action - - - Go back to previous directory + + SingleColumn - - Up + + Single column view - - - Go to parent directory + + Dual Column - - Home + + Dual Column View - - - Go to home directory + + (Limited Access) - - - Close this browser + + + New Document - - Name + + + + Name: - - Size + + Error Creating Document - - Type + + The document could not be created. Please ensure that you have the proper permissions. - - Date Modified + + New Directory - - Date Created + + + + Invalid Name - - - (Limited Access) + + File Operations - - Capacity: %1 + + Directory Operations - - Files: %1 (%2) + + Loading... - - Dirs: %1 + + + + A file or directory with that name already exists! Please pick a different name. - - New Document + + Error Creating Directory - - - Name: + + The directory could not be created. Please ensure that you have the proper permissions to modify the current directory. - - Error Creating Document + + Current - - The document could not be created. Please ensure that you have the proper permissions. + + Create... - - New Directory + + File - - Invalid Name + + Directory - - A file or directory with that name already exists! Please pick a different name. + + Application Launcher - - Error Creating Directory + + Launch... - - The directory could not be created. Please ensure that you have the proper permissions to modify the current directory. + + Terminal - - Current + + SlideShow - - File Checksums: + + Multimedia Player - - Missing Utility + + Modify Files... - - The "lumina-fileinfo" utility could not be found on the system. Please install it first. + + View Files... - - Open + + Checksums - - Open With... + + Properties - - Rename... + + File Checksums: + + + + + Missing Utility + + + + + The "lumina-fileinfo" utility could not be found on the system. Please install it first. + + + + + Open - - View Checksums... + + Open With... - - File Properties... + + Rename... - + Cut Selection - + Copy Selection - + Paste - + Delete Selection - - - Open Terminal here - - FODialog @@ -579,12 +590,12 @@ New Location: %2 - + Shift+Left - + Shift+Right @@ -604,363 +615,342 @@ New Location: %2 - - Group Mode - - - - + Bookmarks - + External Devices - - Edit + + Git - - Git + + New Tab - - + New Browser - + Search Directory... - + Increase Icon Size - + Decrease Icon Size - + Larger Icons - + Ctrl++ - + Smaller Icons - + Ctrl+- - + New Window - + Ctrl+N - + Add Bookmark - + Ctrl+D - + Delete Selection - + Del - + Refresh - - Close Browser + + Close Tab - + Repo Status - + Clone Repository - + Ctrl+T - + Exit - + Ctrl+Q - + &Preferences - + Show Hidden Files - + Scan for Devices - + Manage Bookmarks - + Show Action Buttons - + Load Thumbnails - + Ctrl+F - + Detailed List - + Basic List - + Ctrl+W - - Prefer Tabs - - - - - Prefer Columns - - - - + F5 - + Ctrl+C - + Rename... - + F2 - + Cut Selection - + Copy Selection - + Paste - + Ctrl+V - + Ctrl+X - + Invalid Directories - + The following directories are invalid and could not be opened: - + Root - + %1 (Type: %2) - + Filesystem: %1 - - Browser - - - - + New Bookmark - + Name: - + Invalid Name - + This bookmark name already exists. Please choose another. - + Git Repository Status - + Multimedia - + Slideshow - + Items to be removed: - + Verify Quit - + Ctrl+H - + Ctrl+L - + You have multiple tabs open. Are you sure you want to quit? - + Verify Removal - + WARNING: This will permanently delete the file(s) from the system! - + Are you sure you want to continue? - + Rename File - + New Name: - + Overwrite File? - + An existing file with the same name will be replaced. Are you sure you want to proceed? @@ -1003,6 +993,50 @@ New Location: %2 + + OPWidget + + + Form + + + + + + ... + + + + + Evaluating... + + + + + Move + + + + + Copy + + + + + Remove + + + + + %1 Finished + + + + + Errors Occured + + + SlideshowWidget @@ -1106,4 +1140,22 @@ New Location: %2 + + TrayUI + + + Finished + + + + + Errors during operation. Click to view details + + + + + No Errors + + + diff --git a/src-qt5/desktop-utils/lumina-screenshot/i18n/l-screenshot_de.ts b/src-qt5/desktop-utils/lumina-screenshot/i18n/l-screenshot_de.ts index 13a8096e..83fe5eaf 100644 --- a/src-qt5/desktop-utils/lumina-screenshot/i18n/l-screenshot_de.ts +++ b/src-qt5/desktop-utils/lumina-screenshot/i18n/l-screenshot_de.ts @@ -1,15 +1,15 @@ - + ImageEditor - + Zoom In Vergrößern - + Zoom Out Verkleinern @@ -17,115 +17,115 @@ MainUI - - - + + + Take Screenshot Bildschirmfoto erstellen - + New Screenshot Neues Bildschirmfoto - + Settings Einstellungen - + Include Borders Rahmen inkludieren - + Seconds Sekunden - + Delay Verzögerung - + View/Edit Ansicht/Bearbeiten - - + + Save As Speichern unter - + Launch Editor Editor starten - + Crop Zuschneiden - + Resize Größe ändern - + File Datei - + Ctrl+N Strg+N - + Close Schließen - + Esc Esc - + Entire Session Vollständige Sitzung - + Single Window Einzelnes Fenster - + Single Screen Einzelner Bildschirm - + Save Screenshot Bildschirmfoto speichern - + Ctrl+S Strg+S - + Quick Save Schnellspeichern - + PNG Files (*.png);;AllFiles (*) PNG-Dateien (*.png);;Alle Dateien (*) diff --git a/src-qt5/desktop-utils/lumina-screenshot/i18n/l-screenshot_el.ts b/src-qt5/desktop-utils/lumina-screenshot/i18n/l-screenshot_el.ts index dc049e22..7bbc8d1e 100644 --- a/src-qt5/desktop-utils/lumina-screenshot/i18n/l-screenshot_el.ts +++ b/src-qt5/desktop-utils/lumina-screenshot/i18n/l-screenshot_el.ts @@ -1,15 +1,15 @@ - + ImageEditor - + Zoom In Μεγένθυση - + Zoom Out Σμίκρυνση @@ -17,115 +17,115 @@ MainUI - - - + + + Take Screenshot Πάρτε στιγμιότυπο οθόνης - + New Screenshot Νέο Στιγμιότυπο οθόνης - + Settings Ρυθμίσεις - + Include Borders Συμπερίληψη περιθωρίων - + Seconds Δευτερόλεπτα - + Delay Καθυστέρηση - + View/Edit Προβολή/Επεξεργασία - - + + Save As Αποθήκευση Ως - + Launch Editor Εκκίνηση Επεξεργαστή - + Crop Περικοπή - + Resize Αλλαγή μεγέθους - + File Αρχείο - + Ctrl+N Ctrl+N - + Close Κλείσιμο - + Esc Esc - + Entire Session Ολόκληρη την Συνεδρία - + Single Window Μόνο αυτό το παράθυρο - + Single Screen Μόνο αυτή την οθόνη - + Save Screenshot Αποθήκευση Στιγμιοτύπου Οθόνης - + Ctrl+S Ctrl+S - + Quick Save Γρήγορη Αποθήκευση - + PNG Files (*.png);;AllFiles (*) Αρχεία PNG (*.png);;ΌλαΤαΑρχεία (*) diff --git a/src-qt5/desktop-utils/lumina-screenshot/i18n/l-screenshot_it.ts b/src-qt5/desktop-utils/lumina-screenshot/i18n/l-screenshot_it.ts index 615c77b4..3ed38c74 100644 --- a/src-qt5/desktop-utils/lumina-screenshot/i18n/l-screenshot_it.ts +++ b/src-qt5/desktop-utils/lumina-screenshot/i18n/l-screenshot_it.ts @@ -1,15 +1,15 @@ - + ImageEditor - + Zoom In Zuma in - + Zoom Out Zuma Fuori @@ -17,115 +17,115 @@ MainUI - - - + + + Take Screenshot Cattura schermata - + New Screenshot Nuova Schermata - + Settings Impostazioni - + Include Borders Includi il bordo - + Seconds Secondi - + Delay Ritardo - + View/Edit Visualizza/Edita - - + + Save As Salva Come - + Launch Editor - Avvia l'Editor + Avvia l'Editor - + Crop Ritaglia - + Resize Ridimensiona - + File File - + Ctrl+N Ctrl+N - + Close Chiudi - + Esc Esc - + Entire Session Sessione Intera - + Single Window Finestra Singola - + Single Screen Singola Finestra - + Save Screenshot Salva schermata - + Ctrl+S Ctrl+S - + Quick Save Salvataggio Rapido - + PNG Files (*.png);;AllFiles (*) File PNG (*.png);;AllFiles (*) diff --git a/src-qt5/desktop-utils/lumina-terminal/i18n/l-terminal_ca.ts b/src-qt5/desktop-utils/lumina-terminal/i18n/l-terminal_ca.ts index b25e0898..b8abea0c 100644 --- a/src-qt5/desktop-utils/lumina-terminal/i18n/l-terminal_ca.ts +++ b/src-qt5/desktop-utils/lumina-terminal/i18n/l-terminal_ca.ts @@ -1,15 +1,15 @@ - + TerminalWidget - + Copy Selection Copia la selecció - + Paste Enganxa @@ -17,27 +17,27 @@ TrayIcon - + Trigger Terminal Activa el terminal - + Top of Screen A dalt de tot de la pantalla - + Close Terminal Tanca el terminal - + Move To Monitor Desplaça al monitor - + Monitor %1 Monitor %1 diff --git a/src-qt5/desktop-utils/lumina-terminal/i18n/l-terminal_cs.ts b/src-qt5/desktop-utils/lumina-terminal/i18n/l-terminal_cs.ts index 639d51a0..df929b63 100644 --- a/src-qt5/desktop-utils/lumina-terminal/i18n/l-terminal_cs.ts +++ b/src-qt5/desktop-utils/lumina-terminal/i18n/l-terminal_cs.ts @@ -1,15 +1,15 @@ - + TerminalWidget - + Copy Selection Kopírovat výběr - + Paste Vložit @@ -17,27 +17,27 @@ TrayIcon - + Trigger Terminal - + Top of Screen - + Close Terminal Zavřít terminál - + Move To Monitor - + Monitor %1 Obrazovka %1 diff --git a/src-qt5/desktop-utils/lumina-terminal/i18n/l-terminal_hu.ts b/src-qt5/desktop-utils/lumina-terminal/i18n/l-terminal_hu.ts index 3af80820..3eaa9ae1 100644 --- a/src-qt5/desktop-utils/lumina-terminal/i18n/l-terminal_hu.ts +++ b/src-qt5/desktop-utils/lumina-terminal/i18n/l-terminal_hu.ts @@ -1,15 +1,15 @@ - + TerminalWidget - + Copy Selection Kijelöltek Másolása - + Paste Beilleszt @@ -17,27 +17,27 @@ TrayIcon - + Trigger Terminal Terminál Kiszögezése - + Top of Screen Képernyő teteje - + Close Terminal Terminál Bezárása - + Move To Monitor Monitorra mozgatás - + Monitor %1 %1. ik Montior diff --git a/src-qt5/desktop-utils/lumina-terminal/i18n/l-terminal_it.ts b/src-qt5/desktop-utils/lumina-terminal/i18n/l-terminal_it.ts index b9236d74..46e1a7b1 100644 --- a/src-qt5/desktop-utils/lumina-terminal/i18n/l-terminal_it.ts +++ b/src-qt5/desktop-utils/lumina-terminal/i18n/l-terminal_it.ts @@ -1,15 +1,15 @@ - + TerminalWidget - + Copy Selection - + Paste Incolla @@ -17,27 +17,27 @@ TrayIcon - + Trigger Terminal - + Top of Screen - + Close Terminal Chiudi terminale - + Move To Monitor - + Monitor %1 diff --git a/src-qt5/desktop-utils/lumina-terminal/i18n/l-terminal_ja.ts b/src-qt5/desktop-utils/lumina-terminal/i18n/l-terminal_ja.ts index a59009bc..1a6f4668 100644 --- a/src-qt5/desktop-utils/lumina-terminal/i18n/l-terminal_ja.ts +++ b/src-qt5/desktop-utils/lumina-terminal/i18n/l-terminal_ja.ts @@ -1,15 +1,15 @@ - + TerminalWidget - + Copy Selection 選択された範囲をコピー - + Paste 貼り付け @@ -17,27 +17,27 @@ TrayIcon - + Trigger Terminal - + Top of Screen - + Close Terminal 端末を閉じる - + Move To Monitor - + Monitor %1 モニター %1 diff --git a/src-qt5/desktop-utils/lumina-terminal/i18n/l-terminal_lt.ts b/src-qt5/desktop-utils/lumina-terminal/i18n/l-terminal_lt.ts index 9f67c4d1..21184b81 100644 --- a/src-qt5/desktop-utils/lumina-terminal/i18n/l-terminal_lt.ts +++ b/src-qt5/desktop-utils/lumina-terminal/i18n/l-terminal_lt.ts @@ -1,15 +1,15 @@ - + TerminalWidget - + Copy Selection Kopijuoti žymėjimą - + Paste Įdėti @@ -17,27 +17,27 @@ TrayIcon - + Trigger Terminal Perjungti terminalą - + Top of Screen Ekrano viršuje - + Close Terminal Užverti terminalą - + Move To Monitor Perkelti į monitorių - + Monitor %1 Monitorius %1 diff --git a/src-qt5/desktop-utils/lumina-terminal/i18n/l-terminal_ru.ts b/src-qt5/desktop-utils/lumina-terminal/i18n/l-terminal_ru.ts index 6fa3012b..47c8f8c6 100644 --- a/src-qt5/desktop-utils/lumina-terminal/i18n/l-terminal_ru.ts +++ b/src-qt5/desktop-utils/lumina-terminal/i18n/l-terminal_ru.ts @@ -1,15 +1,15 @@ - + TerminalWidget - + Copy Selection Копировать выбранное - + Paste Вставить @@ -17,27 +17,27 @@ TrayIcon - + Trigger Terminal Запуск терминала - + Top of Screen Всегда наверху - + Close Terminal Закрыть терминал - + Move To Monitor Переместить на экран - + Monitor %1 Экран: %1 diff --git a/src-qt5/desktop-utils/lumina-terminal/i18n/l-terminal_sv.ts b/src-qt5/desktop-utils/lumina-terminal/i18n/l-terminal_sv.ts index 5e9949e8..486a361b 100644 --- a/src-qt5/desktop-utils/lumina-terminal/i18n/l-terminal_sv.ts +++ b/src-qt5/desktop-utils/lumina-terminal/i18n/l-terminal_sv.ts @@ -1,15 +1,15 @@ - + TerminalWidget - + Copy Selection Kopiera markering - + Paste Klistra in @@ -17,27 +17,27 @@ TrayIcon - + Trigger Terminal - + Top of Screen - + Close Terminal Stäng terminal - + Move To Monitor Flytta till skärm - + Monitor %1 Skärm %1 diff --git a/src-qt5/desktop-utils/lumina-textedit/i18n/l-te_ca.ts b/src-qt5/desktop-utils/lumina-textedit/i18n/l-te_ca.ts index cf1aaf99..9f8b0e80 100644 --- a/src-qt5/desktop-utils/lumina-textedit/i18n/l-te_ca.ts +++ b/src-qt5/desktop-utils/lumina-textedit/i18n/l-te_ca.ts @@ -1,41 +1,41 @@ - + ColorDialog - + Customize Colors Personalització dels colors - + Item Type - Tipus d'ítem + Tipus d'ítem - + Color Color - + Sample Exemple - - + + Select Color Seleccioneu un color - + Cancel Cancel·la - + Apply Aplica @@ -43,208 +43,208 @@ MainUI - + MainWindow Finestra principal - + Tab 1 Pestanya 1 - + Find the previous match Cerca la coincidència anterior - - - - - + + + + + ... ... - + Find: Cerca: - + Find the next match Cerca la coincidència següent - + Replace: Reemplaça: - + Match case Coincidència de majúscules i minúscules - + Replace next match Reemplaça la coincidència següent - + Replace all matches (to end of document) Reemplaça totes les coincidències (fins al final del document) - + Hide the find/replace options Amaga les opcions de cerca / reemplaça - + File Fitxer - + View Vista - + Syntax Highlighting Realçament de la sintaxi - + Edit Edita - + toolBar - Barra d'eines + Barra d'eines - + Show Line Numbers Mostra els números de les línies - + None Cap - - + + New File Fitxer nou - + Ctrl+N Ctrl+N - + Open File Obre el fitxer - + Ctrl+O Ctrl+O - + Save File Desa el fitxer - + Ctrl+S Ctrl+S - + Save File As Desa el fitxer com a... - + Close Tanca - + Ctrl+Q Ctrl+Q - + Close File Tanca el fitxer - + Ctrl+W Ctrl+W - + Customize Colors Personalització dels colors - + Wrap Lines Ajusta les línies - + Find Cerca - + Ctrl+F Ctrl+F - + Replace Reemplaça - + Ctrl+R Ctrl+R - + Text Editor Editor de text - + Open File(s) Obre fitxers - + Text Files (*) Fitxers de text (*) - - + + Lose Unsaved Changes? Es perden els canvis no desats? - + This file has unsaved changes. Do you want to close it anyway? @@ -255,13 +255,13 @@ El voleu tancar tanmateix? %1 - + There are unsaved changes. Do you want to close the editor anyway? %1 Hi ha canvis no desats. -Voleu tancar l'editor tanmateix? +Voleu tancar l'editor tanmateix? %1 @@ -269,32 +269,32 @@ Voleu tancar l'editor tanmateix? PlainTextEditor - + Save File Desa el fitxer - + Text File (*) Fitxer de text (*) - + Row Number: %1, Column Number: %2 Número de fila: %1. Número de columna: %2 - + The following file has been changed by some other utility. Do you want to re-load it? El fitxer següent ha estat canviat per alguna altra utilitat. El voleu tornar a carregar? - + (Note: You will lose all currently-unsaved changes) (Nota: perdreu tots els canvis que no estiguin desats ara mateix.) - + File Modified Fitxer modificat diff --git a/src-qt5/desktop-utils/lumina-textedit/i18n/l-te_el.ts b/src-qt5/desktop-utils/lumina-textedit/i18n/l-te_el.ts index 0418afb4..2ce72464 100644 --- a/src-qt5/desktop-utils/lumina-textedit/i18n/l-te_el.ts +++ b/src-qt5/desktop-utils/lumina-textedit/i18n/l-te_el.ts @@ -1,41 +1,41 @@ - + ColorDialog - + Customize Colors Προσαρμόστε τα Χρώματα - + Item Type Τύπος Αντικειμένου - + Color Χρώμα - + Sample Δείγμα - - + + Select Color Επιλογή Χρώματος - + Cancel Ακύρωση - + Apply Εφαρμογή @@ -43,208 +43,208 @@ MainUI - + MainWindow ΚύριοΠαράθυρο - + Tab 1 Καρτέλα 1 - + Find the previous match Βρείτε την προηγούμενη τάυτιση - - - - - + + + + + ... ... - + Find: Βρείτε: - + Find the next match Βρείτε την επόμενη τάυτιση - + Replace: Αντικαταστήστε: - + Match case Περίπτωση τάυτισης - + Replace next match Αντικατάσταση επόμενης τάυτισης - + Replace all matches (to end of document) Αντικαταστήστε όλες τις ταυτίσεις (στο τέλος του εγγράφου) - + Hide the find/replace options Αποκρύψτε τις επιλογές έυρεσης/αντικατάστασης - + File Αρχείο - + View Προβολή - + Syntax Highlighting Επισήμανση Σύνταξης - + Edit Επεξεργασία - + toolBar Μπάρα Εργαλείων - + Show Line Numbers Εμφανίστε Αριθμούς Γραμμών - + None Κανένας - - + + New File Νέο Αρχείο - + Ctrl+N Ctrl+N - + Open File Άνοιγμα Αρχείου - + Ctrl+O Ctrl+O - + Save File Αποθήκευση Αρχείου - + Ctrl+S Ctrl+S - + Save File As Αποθήκευση Αρχείου Ως - + Close Κλείσιμο - + Ctrl+Q Ctrl+Q - + Close File Κλείσιμο Αρχείου - + Ctrl+W Ctrl+W - + Customize Colors Προσαρμογή Χρωμάτων - + Wrap Lines - + Find Βρείτε - + Ctrl+F Ctrl+F - + Replace Αντικατάσταση - + Ctrl+R Ctrl+R - + Text Editor Επεξεργαστής Κειμένου - + Open File(s) Άνοιγμα Αρχείου(ων) - + Text Files (*) Αρχεία Κειμένου (*) - - + + Lose Unsaved Changes? Επιθυμείτε να χάσετε τις μη αποθηκευμένες αλλαγές; - + This file has unsaved changes. Do you want to close it anyway? @@ -255,7 +255,7 @@ Do you want to close it anyway? % 1 - + There are unsaved changes. Do you want to close the editor anyway? @@ -269,32 +269,32 @@ Do you want to close the editor anyway? PlainTextEditor - + Save File Αποθήκευση Αρχείου - + Text File (*) Αρχείο Κειμένου (*) - + Row Number: %1, Column Number: %2 Αριθμός σειράς: % 1, Αριθμός Στήλης: % 2 - + The following file has been changed by some other utility. Do you want to re-load it? Το ακόλουθο αρχείο έχει τροποποιηθεί από κάποιο άλλο βοηθητικό πρόγραμμα. Θέλετε να το ξανά-φορτώσετε; - + (Note: You will lose all currently-unsaved changes) (Σημείωση: Θα χάσετε όλες τις επί του παρόντος - μη αποθηκευμένες αλλαγές) - + File Modified Το Αρχείο Τροποποιήθηκε diff --git a/src-qt5/desktop-utils/lumina-textedit/i18n/l-te_hu.ts b/src-qt5/desktop-utils/lumina-textedit/i18n/l-te_hu.ts index 2408c7ac..7b2967ce 100644 --- a/src-qt5/desktop-utils/lumina-textedit/i18n/l-te_hu.ts +++ b/src-qt5/desktop-utils/lumina-textedit/i18n/l-te_hu.ts @@ -1,41 +1,41 @@ - + ColorDialog - + Customize Colors Színek testreszabása - + Item Type Elem típusa - + Color Szín - + Sample Minta - - + + Select Color Szín kiválasztása - + Cancel Mégse - + Apply Alkalmaz @@ -43,208 +43,208 @@ MainUI - + MainWindow Főablak - + Tab 1 1. lap - + Find the previous match Előző találat keresése - - - - - + + + + + ... ... - + Find: Keresés: - + Find the next match Következő találat keresése - + Replace: Csere: - + Match case Kis- és nagybetű különbözik - + Replace next match A következő találat cseréje - + Replace all matches (to end of document) Minden egyezés cseréje (a dokumentum végéig) - + Hide the find/replace options Rejtsd el a keresés/csere opciót - + File Fájl - + View Nézet - + Syntax Highlighting Szintaxiskiemelés - + Edit Szerkesztés - + toolBar Eszköztár - + Show Line Numbers Sorszámozás megjelenítése - + None Nincs - - + + New File Új fájl - + Ctrl+N Ctrl+N - + Open File Fájl megnyitása - + Ctrl+O Ctrl+O - + Save File Fájl mentése - + Ctrl+S Ctrl+S - + Save File As Fájl mentése másként - + Close Bezárás - + Ctrl+Q Ctrl+Q - + Close File Fájl bezárása - + Ctrl+W Ctrl+W - + Customize Colors Színek testreszabása - + Wrap Lines Sorok tördelése - + Find Keresés - + Ctrl+F Ctrl+F - + Replace Csere - + Ctrl+R Ctrl+R - + Text Editor Szövegszerkesztő - + Open File(s) Fájl(ok) megnyitása - + Text Files (*) Szövegfájlok - - + + Lose Unsaved Changes? Odaveszted a mentetlen változásokat ? - + This file has unsaved changes. Do you want to close it anyway? @@ -255,7 +255,7 @@ Mindenképpen bezárod ? %1 - + There are unsaved changes. Do you want to close the editor anyway? @@ -269,32 +269,32 @@ Mindenképp bezárod ? PlainTextEditor - + Save File Fájl mentése - + Text File (*) Szövegfájl (*) - + Row Number: %1, Column Number: %2 Sor száma: %1, Oszlop száma: %2 - + The following file has been changed by some other utility. Do you want to re-load it? A látható fájl egy másik program által megváltozott. Újratöltöd ? - + (Note: You will lose all currently-unsaved changes) (Megjegyzés: Minden mentetlen változás odalesz!) - + File Modified Fájl Módosítva diff --git a/src-qt5/desktop-utils/lumina-textedit/i18n/l-te_ja.ts b/src-qt5/desktop-utils/lumina-textedit/i18n/l-te_ja.ts index 34fc21ec..323b0500 100644 --- a/src-qt5/desktop-utils/lumina-textedit/i18n/l-te_ja.ts +++ b/src-qt5/desktop-utils/lumina-textedit/i18n/l-te_ja.ts @@ -1,41 +1,41 @@ - + ColorDialog - + Customize Colors 色付けの変更 - + Item Type アイテムの種類 - + Color - + Sample サンプル - - + + Select Color 色を選択 - + Cancel キャンセル - + Apply 適用 @@ -43,210 +43,210 @@ MainUI - + MainWindow メインウィンドウ - + Tab 1 タブ 1 - + Find the previous match 前を検索 - - - - - + + + + + ... ... - + Find: 検索: - + Find the next match 次を検索 - + Replace: 置換: - + Match case 大文字と小文字を区別する - + Replace next match 次に一致した文字列を置換する - + Replace all matches (to end of document) すべて置換(ドキュメントの末尾まで) - + Hide the find/replace options 検索/置換オプションを隠す - + File ファイル - + View 表示 - + Syntax Highlighting 構文強調表示 - + Edit 編集 - + toolBar ツールバー - + Show Line Numbers 行番号を表示する - + None なし - - + + New File これ、メニューだけじゃなくて、新しいファイル作ったときのタブ名にもなる。 新しいファイル - + Ctrl+N Ctrl+N - + Open File ファイルを開く - + Ctrl+O Ctrl+O - + Save File ファイルを保存 - + Ctrl+S Ctrl+S - + Save File As - ダイアログが必ず開かれるため、"..."を追加。 + ダイアログが必ず開かれるため、"..."を追加。 名前を付けて保存... - + Close 閉じる - + Ctrl+Q Ctrl+Q - + Close File ファイルを閉じる - + Ctrl+W Ctrl+W - + Customize Colors 色付けの変更 - + Wrap Lines 行を折り返す - + Find 検索 - + Ctrl+F Ctrl+F - + Replace 置換 - + Ctrl+R Ctrl+R - + Text Editor テキストエディター - + Open File(s) ファイルを開く - + Text Files (*) テキストファイル (*) - - + + Lose Unsaved Changes? 保存されていない変更を削除しますか? - + This file has unsaved changes. Do you want to close it anyway? @@ -257,7 +257,7 @@ Do you want to close it anyway? %1 - + There are unsaved changes. Do you want to close the editor anyway? @@ -271,32 +271,32 @@ Do you want to close the editor anyway? PlainTextEditor - + Save File ファイルを保存 - + Text File (*) テキストファイル (*) - + Row Number: %1, Column Number: %2 %1 行目、%2 文字目 - + The following file has been changed by some other utility. Do you want to re-load it? 以下のファイルは他のユーティリティーで変更されています。再度読み込みますか? - + (Note: You will lose all currently-unsaved changes) (注意: 保存されていない変更は失われます) - + File Modified ファイルが変更されています diff --git a/src-qt5/desktop-utils/lumina-textedit/i18n/l-te_lt.ts b/src-qt5/desktop-utils/lumina-textedit/i18n/l-te_lt.ts index 5a5bab85..c8925e55 100644 --- a/src-qt5/desktop-utils/lumina-textedit/i18n/l-te_lt.ts +++ b/src-qt5/desktop-utils/lumina-textedit/i18n/l-te_lt.ts @@ -1,41 +1,41 @@ - + ColorDialog - + Customize Colors Tinkinti spalvas - + Item Type Elemento tipas - + Color Spalva - + Sample Pavyzdys - - + + Select Color Pasirinkti spalvą - + Cancel Atsisakyti - + Apply Taikyti @@ -43,208 +43,208 @@ MainUI - + MainWindow Pagrindinis langas - + Tab 1 Kortelė 1 - + Find the previous match Rasti ankstesnį atitikmenį - - - - - + + + + + ... ... - + Find: Rasti: - + Find the next match Rasti kitą atitikmenį - + Replace: Pakeisti: - + Match case Skirti raidžių dydį - + Replace next match Pakeisti kitą atitikmenį - + Replace all matches (to end of document) Pakeisti visus atitikmenis (iki dokumento pabaigos) - + Hide the find/replace options Slėpti radimo/pakeitimo parinktis - + File Failas - + View Rodinys - + Syntax Highlighting Sintaksės paryškinimas - + Edit Taisa - + toolBar įrankių juosta - + Show Line Numbers Rodyti eilučių numerius - + None Nėra - - + + New File Naujas failas - + Ctrl+N Ctrl(Vald)+N - + Open File Atverti failą - + Ctrl+O Ctrl(Vald)+O - + Save File Įrašyti failą - + Ctrl+S Ctrl(Vald)+S - + Save File As Įrašyti failą kaip - + Close Užverti - + Ctrl+Q Ctrl(Vald)+Q - + Close File Užverti failą - + Ctrl+W Ctrl(Vald)+W - + Customize Colors Tinkinti spalvas - + Wrap Lines Skaidyti eilutes - + Find Rasti - + Ctrl+F Ctrl(Vald)+F - + Replace Pakeisti - + Ctrl+R Ctrl(Vald)+R - + Text Editor Tekstų redaktorius - + Open File(s) Atverti failą(-us) - + Text Files (*) Tekstiniai failai (*) - - + + Lose Unsaved Changes? Prarasti neįrašytus pakeitimus? - + This file has unsaved changes. Do you want to close it anyway? @@ -255,7 +255,7 @@ Ar vis tiek norite jį užverti? %1 - + There are unsaved changes. Do you want to close the editor anyway? @@ -269,32 +269,32 @@ Ar vis tiek norite užverti redaktorių? PlainTextEditor - + Save File Įrašyti failą - + Text File (*) Tekstinis failas (*) - + Row Number: %1, Column Number: %2 Eilutės numeris: %1, Stulpelio numeris: %2 - + The following file has been changed by some other utility. Do you want to re-load it? Šis failas buvo pakeistas kitos paslaugų programos. Ar norite įkelti jį iš naujo? - + (Note: You will lose all currently-unsaved changes) (Pastaba: Jūs prarasite visus šiuo metu neįrašytus pakeitimus) - + File Modified Failas keistas diff --git a/src-qt5/desktop-utils/lumina-textedit/i18n/l-te_ru.ts b/src-qt5/desktop-utils/lumina-textedit/i18n/l-te_ru.ts index 04aab764..807561b4 100644 --- a/src-qt5/desktop-utils/lumina-textedit/i18n/l-te_ru.ts +++ b/src-qt5/desktop-utils/lumina-textedit/i18n/l-te_ru.ts @@ -1,41 +1,41 @@ - + ColorDialog - + Customize Colors Настройка цвета - + Item Type Тип элемента - + Color Цвет - + Sample Пример - - + + Select Color Выбор цвета - + Cancel Отмена - + Apply Применить @@ -43,208 +43,208 @@ MainUI - + MainWindow Главное окно - + Tab 1 Вкладка 1 - + Find the previous match Найти предыдущее совпадение - - - - - + + + + + ... ... - + Find: Найти: - + Find the next match Найти следующее совпадение - + Replace: Заменить: - + Match case Учитывать регистр - + Replace next match Заменить следующее совпадение - + Replace all matches (to end of document) Заменить все совпадения (до конца документа) - + Hide the find/replace options Скрыть опции поиска/замены - + File Файл - + View Просмотр - + Syntax Highlighting Подсветка синтаксиса - + Edit Правка - + toolBar Панель инструментов - + Show Line Numbers Показать номера строк - + None Ничего - - + + New File Новый файл - + Ctrl+N Ctrl+N - + Open File Открыть файл - + Ctrl+O Ctrl+O - + Save File Сохранить файл - + Ctrl+S Ctrl+S - + Save File As Сохранить файл как - + Close Закрыть - + Ctrl+Q Ctrl+Q - + Close File Закрыть файл - + Ctrl+W Ctrl+W - + Customize Colors Настройка цвета - + Wrap Lines Переносить строки - + Find Найти - + Ctrl+F Ctrl+F - + Replace Заменить - + Ctrl+R Ctrl+R - + Text Editor Текстовый редактор - + Open File(s) Открыть файл(ы) - + Text Files (*) Текстовые файлы (*) - - + + Lose Unsaved Changes? Потерять несохраненные изменения? - + This file has unsaved changes. Do you want to close it anyway? @@ -255,7 +255,7 @@ Do you want to close it anyway? %1 - + There are unsaved changes. Do you want to close the editor anyway? @@ -269,32 +269,32 @@ Do you want to close the editor anyway? PlainTextEditor - + Save File Сохранить файл - + Text File (*) Текстовые файлы (*) - + Row Number: %1, Column Number: %2 Номер строки: %1, Номер колонки: %2 - + The following file has been changed by some other utility. Do you want to re-load it? Следующий файл был изменен с помощью какой-либо другой утилиты. Вы хотите, повторно загрузить его? - + (Note: You will lose all currently-unsaved changes) (Примечание: Вы потеряете все несохраненные изменения) - + File Modified Файл изменен diff --git a/src-qt5/desktop-utils/lumina-textedit/i18n/l-te_sv.ts b/src-qt5/desktop-utils/lumina-textedit/i18n/l-te_sv.ts index 2f428080..b7ad9ba5 100644 --- a/src-qt5/desktop-utils/lumina-textedit/i18n/l-te_sv.ts +++ b/src-qt5/desktop-utils/lumina-textedit/i18n/l-te_sv.ts @@ -1,41 +1,41 @@ - + ColorDialog - + Customize Colors Anpassa Färger - + Item Type Objekttyp - + Color Färg - + Sample Exempel - - + + Select Color Välj färg - + Cancel Avbryt - + Apply Verkställ @@ -43,208 +43,208 @@ MainUI - + MainWindow Huvudfönster - + Tab 1 Flik 1 - + Find the previous match Hitta föregående träff - - - - - + + + + + ... ... - + Find: Hitta: - + Find the next match Hitta nästa träff - + Replace: Ersätt: - + Match case Matcha skiftläge - + Replace next match Ersätt nästa träff - + Replace all matches (to end of document) Ersätt alla träffar (till slut av dokument) - + Hide the find/replace options - + File Fil - + View Visa - + Syntax Highlighting Syntaxmarkering - + Edit Redigera - + toolBar Verktygsrad - + Show Line Numbers Visa radnummer - + None Inget - - + + New File Ny fil - + Ctrl+N Ctrl+N - + Open File Öppna fil - + Ctrl+O Ctrl+O - + Save File Spara fil - + Ctrl+S Ctrl+S - + Save File As Spara fil som - + Close Stäng - + Ctrl+Q Ctrl+Q - + Close File Stäng fil - + Ctrl+W Ctrl+W - + Customize Colors Anpassa färger - + Wrap Lines Radbryt linjer - + Find Sök - + Ctrl+F Ctrl+F - + Replace Ersätt - + Ctrl+R Ctrl+R - + Text Editor Textredigerare - + Open File(s) Öppna filer - + Text Files (*) Text filer (*) - - + + Lose Unsaved Changes? - + This file has unsaved changes. Do you want to close it anyway? @@ -255,7 +255,7 @@ Vill du stänga den ändå ? %1 - + There are unsaved changes. Do you want to close the editor anyway? @@ -269,32 +269,32 @@ Vill du stänga editorn ändå? PlainTextEditor - + Save File Spara fil - + Text File (*) Text fil (*) - + Row Number: %1, Column Number: %2 Rad nummer: %1, Kolumn nummer: %2 - + The following file has been changed by some other utility. Do you want to re-load it? - + (Note: You will lose all currently-unsaved changes) (Notera: Du kommer förlora alla osparade ändringar) - + File Modified Fil modifierad -- cgit From 36df3d58e25beb06f16fdf821f18fe8a4bcce2ae Mon Sep 17 00:00:00 2001 From: Ken Moore Date: Thu, 20 Oct 2016 12:05:22 -0400 Subject: Finish up the last couple buttons/actions related to the new Tray UI. 1) If closing the main window while an operation is running, hide it instead until the file operation is finished - then close. 2) Fix the icon on the show errors button 3) Hook up the show errors button to show a scroll dialog with the errors. --- src-qt5/desktop-utils/lumina-fm/MainUI.cpp | 25 +++++++++++++++++++++++-- src-qt5/desktop-utils/lumina-fm/MainUI.h | 9 +++++++-- src-qt5/desktop-utils/lumina-fm/OPWidget.cpp | 13 +++++++++++-- src-qt5/desktop-utils/lumina-fm/OPWidget.h | 2 ++ src-qt5/desktop-utils/lumina-fm/TrayUI.cpp | 7 ++++++- src-qt5/desktop-utils/lumina-fm/TrayUI.h | 3 ++- 6 files changed, 51 insertions(+), 8 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/desktop-utils/lumina-fm/MainUI.cpp b/src-qt5/desktop-utils/lumina-fm/MainUI.cpp index 02533271..128c4cd5 100644 --- a/src-qt5/desktop-utils/lumina-fm/MainUI.cpp +++ b/src-qt5/desktop-utils/lumina-fm/MainUI.cpp @@ -20,7 +20,7 @@ MainUI::MainUI() : QMainWindow(), ui(new Ui::MainUI){ //just to silence/fix some Qt connect warnings in QtConcurrent //qRegisterMetaType< QVector >("QVector"); //qRegisterMetaType< QList >("QList"); - + waitingToClose = false; ui->setupUi(this); ui->menuGit->setVisible( GIT::isAvailable() ); @@ -106,6 +106,7 @@ QSize orig = settings->value("preferences/MainWindowSize", QSize()).toSize(); RebuildDeviceMenu(); //Make sure we start on the browser page TRAY = new TrayUI(this); + connect(TRAY, SIGNAL(JobsFinished()), this, SLOT(TrayJobsFinished()) ); if(DEBUG){ qDebug() << " - Done with init"; } } @@ -187,7 +188,7 @@ void MainUI::OpenDirs(QStringList dirs){ //Double check that there is at least 1 dir loaded //qDebug() << "OpenDirs:" << DWLIST.length() << dirs << invalid << tabBar->currentIndex(); if(DWLIST.isEmpty()){ OpenDirs(QStringList()); } - + waitingToClose = false; } void MainUI::setupIcons(){ @@ -944,3 +945,23 @@ void MainUI::TabNameChanged(QString id, QString name){ } } } + +void MainUI::TrayJobsFinished(){ + if(waitingToClose){ this->close(); } +} + +//============= +// PROTECTED +//============= +void MainUI::closeEvent(QCloseEvent *ev){ + //See if the tray is active or not first + if(TRAY!=0){ + if(TRAY->isVisible() && !waitingToClose){ + this->hide(); + ev->ignore(); + waitingToClose = true; + return; + } + } + QMainWindow::closeEvent(ev); //continue normal close routine +} diff --git a/src-qt5/desktop-utils/lumina-fm/MainUI.h b/src-qt5/desktop-utils/lumina-fm/MainUI.h index 0ed9c44b..2b4c0d7b 100644 --- a/src-qt5/desktop-utils/lumina-fm/MainUI.h +++ b/src-qt5/desktop-utils/lumina-fm/MainUI.h @@ -88,9 +88,10 @@ private: MultimediaWidget *MW; SlideshowWidget *SW; TrayUI *TRAY; + bool waitingToClose; - QSettings *settings; - QShortcut *nextTabLShort, *nextTabRShort, *togglehiddenfilesShort, *focusDirWidgetShort; + QSettings *settings; + QShortcut *nextTabLShort, *nextTabRShort, *togglehiddenfilesShort, *focusDirWidgetShort; //QCompleter *dirCompleter; //Simplification Functions @@ -169,6 +170,8 @@ private slots: //file info in status bar void DisplayStatusBar(QString); + void TrayJobsFinished(); + signals: void Si_AdaptStatusBar(QFileInfoList fileList, QString path, QString messageFolders, QString messageFiles); @@ -179,6 +182,8 @@ protected: QMainWindow::resizeEvent(ev); //just in case the window needs to see the event too } + void closeEvent(QCloseEvent *ev); + }; #endif diff --git a/src-qt5/desktop-utils/lumina-fm/OPWidget.cpp b/src-qt5/desktop-utils/lumina-fm/OPWidget.cpp index 3e842b90..3638e2a8 100644 --- a/src-qt5/desktop-utils/lumina-fm/OPWidget.cpp +++ b/src-qt5/desktop-utils/lumina-fm/OPWidget.cpp @@ -7,16 +7,19 @@ #include "OPWidget.h" #include "ui_OPWidget.h" +#include "ScrollDialog.h" + OPWidget::OPWidget(QWidget *parent) : QWidget(parent), ui(new Ui::OPWidget()){ starttime = endtime = -1; WA = new QWidgetAction(0); WA->setDefaultWidget(this); worker = 0; workthread = 0; + dlg = 0; //Now create the widget ui->setupUi(this); ui->tool_close->setIcon( LXDG::findIcon("dialog-close","view-close") ); - ui->tool_showerrors->setIcon(LXDG::findIcon("view-search","")); + ui->tool_showerrors->setIcon(LXDG::findIcon("dialog-warning","")); //connect the widget buttons connect(ui->tool_close, SIGNAL(clicked()), this, SLOT(closeWidget()) ); connect(ui->tool_showerrors, SIGNAL(clicked()), this, SLOT(showErrors()) ); @@ -26,6 +29,7 @@ OPWidget::~OPWidget(){ if(worker!=0){ worker->stopped = true; worker->deleteLater(); } if(workthread!=0){ workthread->quit(); workthread->wait(); delete workthread; } WA->deleteLater(); + if(dlg!=0){ dlg->deleteLater(); } } QWidgetAction* OPWidget::widgetAction(){ @@ -87,7 +91,12 @@ void OPWidget::closeWidget(){ void OPWidget::showErrors(){ qDebug() << "Errors:" << Errors; - //TODO + if(dlg==0){ + dlg = new ScrollDialog(); //need this to persist outside this function + dlg->setWindowTitle(tr("File Operation Errors")); + dlg->setText( Errors.join("\n") ); + } + dlg->showNormal(); } void OPWidget::opFinished(QStringList errors){ diff --git a/src-qt5/desktop-utils/lumina-fm/OPWidget.h b/src-qt5/desktop-utils/lumina-fm/OPWidget.h index 600df4b7..13fb3cb3 100644 --- a/src-qt5/desktop-utils/lumina-fm/OPWidget.h +++ b/src-qt5/desktop-utils/lumina-fm/OPWidget.h @@ -10,6 +10,7 @@ #define _LUMINA_FILE_MANAGER_FILE_OP_OPWIDGET_H #include "FODialog.h" +#include "ScrollDialog.h" namespace Ui{ class OPWidget; }; @@ -36,6 +37,7 @@ public slots: private: Ui::OPWidget *ui; + ScrollDialog *dlg; //Main Objects QWidgetAction *WA; FOWorker *worker; diff --git a/src-qt5/desktop-utils/lumina-fm/TrayUI.cpp b/src-qt5/desktop-utils/lumina-fm/TrayUI.cpp index 8e796c68..f7034d54 100644 --- a/src-qt5/desktop-utils/lumina-fm/TrayUI.cpp +++ b/src-qt5/desktop-utils/lumina-fm/TrayUI.cpp @@ -12,6 +12,7 @@ TrayUI::TrayUI(QObject *parent) : QSystemTrayIcon(parent){ this->setContextMenu( new QMenu() ); this->setIcon(LXDG::findIcon("Insight-FileManager","")); + connect(this, SIGNAL(activated(QSystemTrayIcon::ActivationReason)), this, SLOT(TrayActivated())); } TrayUI::~TrayUI(){ @@ -38,6 +39,10 @@ void TrayUI::createOP( FILEOP type, QStringList oldF, QStringList newF){ QTimer::singleShot(0, OP, SLOT(startOperation()) ); } +void TrayUI::TrayActivated(){ + this->contextMenu()->popup( this->geometry().center() ); +} + //Operation Widget Responses void TrayUI::OperationClosed(QString ID){ for(int i=0; iduration(); //Assemble the notification (if more than 1 second to perform operation) if(OPS[i]->duration()>1){ - this->showMessage( tr("Finished"), err ? tr("Errors during operation. Click to view details") : tr("No Errors"), err ? QSystemTrayIcon::Warning : QSystemTrayIcon::Information); + this->showMessage( tr("Finished"), err ? tr("Errors during operation. Click to view details") : "", err ? QSystemTrayIcon::Warning : QSystemTrayIcon::Information); } //Close the widget if no errors if(!err){ OperationClosed(ID); } diff --git a/src-qt5/desktop-utils/lumina-fm/TrayUI.h b/src-qt5/desktop-utils/lumina-fm/TrayUI.h index 38a99f7a..4210784a 100644 --- a/src-qt5/desktop-utils/lumina-fm/TrayUI.h +++ b/src-qt5/desktop-utils/lumina-fm/TrayUI.h @@ -31,7 +31,8 @@ private: void createOP( FILEOP, QStringList oldF, QStringList newF); private slots: - + void TrayActivated(); + //Operation Widget Responses void OperationClosed(QString ID); void OperationStarted(QString ID); -- cgit From 0b1d2985423a5ce2a6eedd9e7872eac7e94a2cd9 Mon Sep 17 00:00:00 2001 From: Ken Moore Date: Thu, 20 Oct 2016 12:59:30 -0400 Subject: Add the app registration for lumina-calculator. --- .../desktop-utils/lumina-calculator/lumina-calculator.desktop | 9 +++++++++ src-qt5/desktop-utils/lumina-calculator/lumina-calculator.pro | 4 ++-- 2 files changed, 11 insertions(+), 2 deletions(-) create mode 100644 src-qt5/desktop-utils/lumina-calculator/lumina-calculator.desktop (limited to 'src-qt5') diff --git a/src-qt5/desktop-utils/lumina-calculator/lumina-calculator.desktop b/src-qt5/desktop-utils/lumina-calculator/lumina-calculator.desktop new file mode 100644 index 00000000..cabc3de1 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-calculator/lumina-calculator.desktop @@ -0,0 +1,9 @@ +[Desktop Entry] +Exec=lumina-calculator +Icon=accessories-calculator +Terminal=false +Type=Application +StartupNotify=true +Categories=Utility; +Name=Calculator +Comment=Perform mathematical calculations diff --git a/src-qt5/desktop-utils/lumina-calculator/lumina-calculator.pro b/src-qt5/desktop-utils/lumina-calculator/lumina-calculator.pro index 8c36c516..0d797d70 100644 --- a/src-qt5/desktop-utils/lumina-calculator/lumina-calculator.pro +++ b/src-qt5/desktop-utils/lumina-calculator/lumina-calculator.pro @@ -82,8 +82,8 @@ TRANSLATIONS = i18n/l-calc_af.ts \ dotrans.path=$${L_SHAREDIR}/lumina-desktop/i18n/ dotrans.extra=cd i18n && $${LRELEASE} -nounfinished *.ts && cp *.qm $(INSTALL_ROOT)$${L_SHAREDIR}/lumina-desktop/i18n/ -#desktop.files=lumina-calculator.desktop -#desktop.path=$${L_SHAREDIR}/applications/ +desktop.files=lumina-calculator.desktop +desktop.path=$${L_SHAREDIR}/applications/ INSTALLS += target -- cgit From b7ee5390b1dc9cdc3135e0468ffe200b7c436a2b Mon Sep 17 00:00:00 2001 From: Ken Moore Date: Thu, 20 Oct 2016 13:10:27 -0400 Subject: Hook up the Lumina theme engine into lumina-calculator for icon changes, as well as the translation loading mechanisms. --- src-qt5/desktop-utils/lumina-calculator/main.cpp | 9 ++- src-qt5/desktop-utils/lumina-calculator/mainUI.cpp | 8 ++- src-qt5/desktop-utils/lumina-calculator/mainUI.h | 35 +++++----- src-qt5/desktop-utils/lumina-calculator/mainUI.ui | 79 ++++++++++++++++------ 4 files changed, 91 insertions(+), 40 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/desktop-utils/lumina-calculator/main.cpp b/src-qt5/desktop-utils/lumina-calculator/main.cpp index af252cb3..ea1ae60c 100644 --- a/src-qt5/desktop-utils/lumina-calculator/main.cpp +++ b/src-qt5/desktop-utils/lumina-calculator/main.cpp @@ -7,13 +7,20 @@ #include #include +#include +#include + #include "mainUI.h" int main(int argc, char *argv[]) { + LTHEME::LoadCustomEnvSettings(); QApplication a(argc, argv); - + LUtils::LoadTranslation(&a, "l-calc"); + //Now go ahead and setup the app + LuminaThemeEngine theme(&a); //Now start the window mainUI W; + QObject::connect(&theme, SIGNAL(updateIcons()), &W, SLOT(updateIcons()) ); W.show(); return a.exec(); } diff --git a/src-qt5/desktop-utils/lumina-calculator/mainUI.cpp b/src-qt5/desktop-utils/lumina-calculator/mainUI.cpp index 539fbb8e..3db2e028 100644 --- a/src-qt5/desktop-utils/lumina-calculator/mainUI.cpp +++ b/src-qt5/desktop-utils/lumina-calculator/mainUI.cpp @@ -37,18 +37,22 @@ mainUI::mainUI() : QMainWindow(), ui(new Ui::mainUI()){ connect(ui->button_Equal, SIGNAL (clicked()), this, SLOT (start_calc())); this->setWindowTitle(tr("Calculator")); - this->setWindowIcon( LXDG::findIcon("accessories-calculator","") ); + updateIcons(); ui->line_eq->setFocus(); } mainUI::~mainUI(){ } +void mainUI::updateIcons(){ + this->setWindowIcon( LXDG::findIcon("accessories-calculator","") ); +} + void mainUI::start_calc(){ if(ui->line_eq->text().isEmpty()){ return; } //nothing to do double result = strToNumber(ui->line_eq->text()); if(result!=result){ return; } //bad calculation - NaN's values are special in that they don't equal itself - QString res = "%1 \t(%2)"; + QString res = "%1 \t= [ %2 ]"; ui->list_results->addItem(res.arg(QString::number(result), ui->line_eq->text())); ui->list_results->scrollToItem( ui->list_results->item( ui->list_results->count()-1) ); ui->line_eq->clear(); diff --git a/src-qt5/desktop-utils/lumina-calculator/mainUI.h b/src-qt5/desktop-utils/lumina-calculator/mainUI.h index 0d99c83a..5bab1ffc 100644 --- a/src-qt5/desktop-utils/lumina-calculator/mainUI.h +++ b/src-qt5/desktop-utils/lumina-calculator/mainUI.h @@ -21,25 +21,28 @@ public: mainUI(); ~mainUI(); +public slots: + void updateIcons(); + private slots: void start_calc(); - void clear_calc(); - void captureButton1(); - void captureButton2(); - void captureButton3(); - void captureButton4(); - void captureButton5(); - void captureButton6(); - void captureButton7(); - void captureButton8(); - void captureButton9(); - void captureButton0(); - void captureButtonSubtract(); - void captureButtonAdd(); - void captureButtonDivide(); - void captureButtonMultiply(); + void clear_calc(); + void captureButton1(); + void captureButton2(); + void captureButton3(); + void captureButton4(); + void captureButton5(); + void captureButton6(); + void captureButton7(); + void captureButton8(); + void captureButton9(); + void captureButton0(); + void captureButtonSubtract(); + void captureButtonAdd(); + void captureButtonDivide(); + void captureButtonMultiply(); // void captureButtonEqual(); - void captureButtonDecimal(); + void captureButtonDecimal(); private: diff --git a/src-qt5/desktop-utils/lumina-calculator/mainUI.ui b/src-qt5/desktop-utils/lumina-calculator/mainUI.ui index 2ca316ed..0bdc4001 100644 --- a/src-qt5/desktop-utils/lumina-calculator/mainUI.ui +++ b/src-qt5/desktop-utils/lumina-calculator/mainUI.ui @@ -26,10 +26,14 @@ Qt::Vertical - + - + + + Qt::NoFocus + + @@ -38,6 +42,9 @@ + + Qt::NoFocus + C @@ -50,10 +57,13 @@ - + + + Qt::NoFocus + 7 @@ -61,6 +71,9 @@ + + Qt::NoFocus + 8 @@ -68,6 +81,9 @@ + + Qt::NoFocus + 9 @@ -75,6 +91,9 @@ + + Qt::NoFocus + / @@ -82,6 +101,9 @@ + + Qt::NoFocus + 4 @@ -89,6 +111,9 @@ + + Qt::NoFocus + 5 @@ -96,6 +121,9 @@ + + Qt::NoFocus + 6 @@ -103,6 +131,9 @@ + + Qt::NoFocus + * @@ -110,6 +141,9 @@ + + Qt::NoFocus + 1 @@ -117,6 +151,9 @@ + + Qt::NoFocus + 2 @@ -124,6 +161,9 @@ + + Qt::NoFocus + 3 @@ -131,6 +171,9 @@ + + Qt::NoFocus + - @@ -138,6 +181,9 @@ + + Qt::NoFocus + 0 @@ -145,6 +191,9 @@ + + Qt::NoFocus + . @@ -152,6 +201,9 @@ + + Qt::NoFocus + = @@ -159,6 +211,9 @@ + + Qt::NoFocus + + @@ -167,24 +222,6 @@ - list_results - button_7 - button_8 - button_9 - button_Divide - button_4 - button_5 - button_6 - button_Multiply - button_1 - button_2 - button_3 - button_Subtract - button_0 - button_Decimal - button_Equal - button_Add - line_eq -- cgit From 79cfa16f8e6923762221e70180518636d73f5018 Mon Sep 17 00:00:00 2001 From: Ken Moore Date: Thu, 20 Oct 2016 13:35:45 -0400 Subject: Fix up the parsing/usage of scientific notation within the equation (1e1 or 1E1 = 10) Similarly, skip any +/- at the beginning of a number/section with no context for operation purposes (is a modifier for the number, not an actual operation) --- src-qt5/desktop-utils/lumina-calculator/mainUI.cpp | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/desktop-utils/lumina-calculator/mainUI.cpp b/src-qt5/desktop-utils/lumina-calculator/mainUI.cpp index 3db2e028..baaa0a27 100644 --- a/src-qt5/desktop-utils/lumina-calculator/mainUI.cpp +++ b/src-qt5/desktop-utils/lumina-calculator/mainUI.cpp @@ -81,6 +81,7 @@ void mainUI::captureButtonMultiply(){ ui->line_eq->setText(ui->line_eq->text() + void mainUI::captureButtonDecimal(){ ui->line_eq->setText(ui->line_eq->text() += ui->button_Decimal->text()); } double mainUI::performOperation(double LHS, double RHS, QChar symbol){ + qDebug() << "Perform Operation:" << LHS << symbol << RHS; if(symbol== '+'){ return (LHS+RHS); } else if(symbol== '-'){ return (LHS-RHS); } else if(symbol== '*' || symbol=='x'){ return (LHS*RHS); } @@ -92,7 +93,7 @@ double mainUI::performOperation(double LHS, double RHS, QChar symbol){ double mainUI::strToNumber(QString str){ //Look for perentheses first - //qDebug() << "String to Number: " << str; + qDebug() << "String to Number: " << str; if(str.indexOf("(")>=0){ //qDebug() << "Found Parenthesis"; int start = str.indexOf("("); @@ -116,9 +117,14 @@ double mainUI::strToNumber(QString str){ //Now look for add/subtract int sym = -1; QStringList symbols; symbols << "+" << "-"; + qDebug() << "Get operator:" << str; for(int i=0; i0 && str[tmp-1].toLower()=='e') ){ tmp = str.indexOf(symbols[i], tmp+1); } //catch scientific notation + if(sym < tmp){ + //qDebug() << " - found:" << tmp << sym; + sym = tmp; + } } if(sym>0){ return performOperation( strToNumber(str.left(sym)), strToNumber(str.right(str.length()-sym-1)), str[sym]); } if(sym==0){ return BADVALUE; } @@ -132,6 +138,6 @@ double mainUI::strToNumber(QString str){ if(sym==0){ return BADVALUE; } //Could not find any operations - must be a raw number - //qDebug() << "Found Number:" << str.toDouble(); + qDebug() << " - Found Number:" << str << str.toDouble(); return str.toDouble(); } -- cgit From a2ff9e5e69c2a4a9dca23961635a2311d424af1a Mon Sep 17 00:00:00 2001 From: Ken Moore Date: Thu, 20 Oct 2016 13:46:11 -0400 Subject: Add the ability to acknowledge the "power" symbol (^) within an equation --- src-qt5/desktop-utils/lumina-calculator/mainUI.cpp | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/desktop-utils/lumina-calculator/mainUI.cpp b/src-qt5/desktop-utils/lumina-calculator/mainUI.cpp index baaa0a27..78d071a0 100644 --- a/src-qt5/desktop-utils/lumina-calculator/mainUI.cpp +++ b/src-qt5/desktop-utils/lumina-calculator/mainUI.cpp @@ -81,11 +81,12 @@ void mainUI::captureButtonMultiply(){ ui->line_eq->setText(ui->line_eq->text() + void mainUI::captureButtonDecimal(){ ui->line_eq->setText(ui->line_eq->text() += ui->button_Decimal->text()); } double mainUI::performOperation(double LHS, double RHS, QChar symbol){ - qDebug() << "Perform Operation:" << LHS << symbol << RHS; + //qDebug() << "Perform Operation:" << LHS << symbol << RHS; if(symbol== '+'){ return (LHS+RHS); } else if(symbol== '-'){ return (LHS-RHS); } else if(symbol== '*' || symbol=='x'){ return (LHS*RHS); } else if(symbol== '/'){ return (LHS/RHS); } + else if(symbol== '^'){ return ::pow(LHS, RHS); } //else if(symbol== '%'){ return (LHS%RHS); } qDebug() << "Invalid Symbol:" << symbol; return BADVALUE; @@ -93,7 +94,7 @@ double mainUI::performOperation(double LHS, double RHS, QChar symbol){ double mainUI::strToNumber(QString str){ //Look for perentheses first - qDebug() << "String to Number: " << str; + //qDebug() << "String to Number: " << str; if(str.indexOf("(")>=0){ //qDebug() << "Found Parenthesis"; int start = str.indexOf("("); @@ -107,7 +108,9 @@ double mainUI::strToNumber(QString str){ } if(end0 && str[tmp-1].toLower()=='e') ){ tmp = str.indexOf(symbols[i], tmp+1); } //catch scientific notation @@ -129,7 +132,7 @@ double mainUI::strToNumber(QString str){ if(sym>0){ return performOperation( strToNumber(str.left(sym)), strToNumber(str.right(str.length()-sym-1)), str[sym]); } if(sym==0){ return BADVALUE; } //Now look for multiply/divide - symbols.clear(); symbols << "x" << "*" << "/"; + symbols.clear(); symbols << "x" << "*" << "/" << "^" ; for(int i=0; i Date: Thu, 20 Oct 2016 14:36:40 -0400 Subject: Finish cleaning up some of the calculator: 1) Add an input validator to the line edit to ensure only valid characters get added 2) Add the ability to click a history item to copy that equation into the line edit. 3) Turn off some debugging messages. --- .../desktop-utils/lumina-calculator/EqValidator.h | 39 ++++++++++++++++++ .../lumina-calculator/lumina-calculator.pro | 3 +- src-qt5/desktop-utils/lumina-calculator/mainUI.cpp | 47 +++++++++++++--------- src-qt5/desktop-utils/lumina-calculator/mainUI.h | 2 + src-qt5/desktop-utils/lumina-calculator/mainUI.ui | 37 +++++++++-------- 5 files changed, 91 insertions(+), 37 deletions(-) create mode 100644 src-qt5/desktop-utils/lumina-calculator/EqValidator.h (limited to 'src-qt5') diff --git a/src-qt5/desktop-utils/lumina-calculator/EqValidator.h b/src-qt5/desktop-utils/lumina-calculator/EqValidator.h new file mode 100644 index 00000000..462a330d --- /dev/null +++ b/src-qt5/desktop-utils/lumina-calculator/EqValidator.h @@ -0,0 +1,39 @@ +//=========================================== +// Lumina Desktop source code +// Copyright (c) 2016, Ken Moore +// Available under the 3-clause BSD license +// See the LICENSE file for full details +//=========================================== +#ifndef _LUMINA_CALCULATOR_VALIDATOR_H +#define _LUMINA_CALCULATOR_VALIDATOR_H + +#define VALIDCHARS QString("x*+-/^eE().0123456789") +#define NOSTARTCHARS QString("x*/^)eE.") +#define NOENDCHARS QString("x*/^(eE.") +#define NOCHANGE QString("().") + +#include +#include +#include + +class EqValidator : public QValidator{ + Q_OBJECT +public: + EqValidator(QObject *parent = 0) : QValidator(parent){} + ~EqValidator(){} + + virtual void fixup(QString &input) const{ + if(input.isEmpty()){ return; } + if( NOSTARTCHARS.contains(input.left(1)) && !NOCHANGE.contains(input.left(1)) ){ input.prepend("1"); } + if( NOENDCHARS.contains(input.right(1)) && !NOCHANGE.contains(input.right(1)) ){ input.append("1"); } + } + + virtual QValidator::State validate(QString &input, int&pos) const { + //qDebug() << "Got validate:" << input << pos; + if(pos>0 && !VALIDCHARS.contains(input[pos-1])){ return QValidator::Invalid; } + if(!input.isEmpty() && NOSTARTCHARS.contains(input.left(1))){ return QValidator::Intermediate; } + if(!input.isEmpty() && NOENDCHARS.contains(input.right(1))){ return QValidator::Intermediate; } + return QValidator::Acceptable; + } +}; +#endif diff --git a/src-qt5/desktop-utils/lumina-calculator/lumina-calculator.pro b/src-qt5/desktop-utils/lumina-calculator/lumina-calculator.pro index 0d797d70..15578f4e 100644 --- a/src-qt5/desktop-utils/lumina-calculator/lumina-calculator.pro +++ b/src-qt5/desktop-utils/lumina-calculator/lumina-calculator.pro @@ -5,7 +5,8 @@ QT += core gui widgets TARGET = lumina-calculator target.path = $${L_BINDIR} -HEADERS += mainUI.h +HEADERS += mainUI.h \ + EqValidator.h SOURCES += main.cpp \ mainUI.cpp diff --git a/src-qt5/desktop-utils/lumina-calculator/mainUI.cpp b/src-qt5/desktop-utils/lumina-calculator/mainUI.cpp index 78d071a0..cdb33414 100644 --- a/src-qt5/desktop-utils/lumina-calculator/mainUI.cpp +++ b/src-qt5/desktop-utils/lumina-calculator/mainUI.cpp @@ -9,8 +9,7 @@ #include #include - -//#define VALIDSYMBOLS QString("+-*x/.") +#include "EqValidator.h" #include #define BADVALUE NAN @@ -35,10 +34,11 @@ mainUI::mainUI() : QMainWindow(), ui(new Ui::mainUI()){ connect(ui->button_Multiply, SIGNAL (clicked()), this, SLOT (captureButtonMultiply())); connect(ui->button_Decimal, SIGNAL (clicked()), this, SLOT (captureButtonDecimal())); connect(ui->button_Equal, SIGNAL (clicked()), this, SLOT (start_calc())); - + connect(ui->list_results, SIGNAL(itemClicked(QListWidgetItem*)), this, SLOT(insert_history(QListWidgetItem*)) ); this->setWindowTitle(tr("Calculator")); updateIcons(); ui->line_eq->setFocus(); + ui->line_eq->setValidator(new EqValidator(this) ); } mainUI::~mainUI(){ @@ -46,6 +46,7 @@ mainUI::~mainUI(){ void mainUI::updateIcons(){ this->setWindowIcon( LXDG::findIcon("accessories-calculator","") ); + ui->tool_clear->setIcon( LXDG::findIcon("edit-clear-locationbar-rtl","dialog-cancel") ); } void mainUI::start_calc(){ @@ -63,23 +64,31 @@ void mainUI::clear_calc(){ ui->line_eq->setFocus(); } -void mainUI::captureButton1(){ ui->line_eq->setText(ui->line_eq->text() += ui->button_1->text()); } -void mainUI::captureButton2(){ ui->line_eq->setText(ui->line_eq->text() += ui->button_2->text()); } -void mainUI::captureButton3(){ ui->line_eq->setText(ui->line_eq->text() += ui->button_3->text()); } -void mainUI::captureButton4(){ ui->line_eq->setText(ui->line_eq->text() += ui->button_4->text()); } -void mainUI::captureButton5(){ ui->line_eq->setText(ui->line_eq->text() += ui->button_5->text()); } -void mainUI::captureButton6(){ ui->line_eq->setText(ui->line_eq->text() += ui->button_6->text()); } -void mainUI::captureButton7(){ ui->line_eq->setText(ui->line_eq->text() += ui->button_7->text()); } -void mainUI::captureButton8(){ ui->line_eq->setText(ui->line_eq->text() += ui->button_8->text()); } -void mainUI::captureButton9(){ ui->line_eq->setText(ui->line_eq->text() += ui->button_9->text()); } -void mainUI::captureButton0(){ ui->line_eq->setText(ui->line_eq->text() += ui->button_0->text()); } -void mainUI::captureButtonSubtract(){ ui->line_eq->setText(ui->line_eq->text() += ui->button_Subtract->text()); } -void mainUI::captureButtonAdd(){ ui->line_eq->setText(ui->line_eq->text() += ui->button_Add->text()); } -void mainUI::captureButtonDivide(){ ui->line_eq->setText(ui->line_eq->text() += ui->button_Divide->text()); } -void mainUI::captureButtonMultiply(){ ui->line_eq->setText(ui->line_eq->text() += ui->button_Multiply->text()); } +void mainUI::captureButton1(){ ui->line_eq->insert(ui->button_1->text()); } +void mainUI::captureButton2(){ ui->line_eq->insert(ui->button_2->text()); } +void mainUI::captureButton3(){ ui->line_eq->insert(ui->button_3->text()); } +void mainUI::captureButton4(){ui->line_eq->insert(ui->button_4->text()); } +void mainUI::captureButton5(){ ui->line_eq->insert(ui->button_5->text()); } +void mainUI::captureButton6(){ ui->line_eq->insert(ui->button_6->text()); } +void mainUI::captureButton7(){ ui->line_eq->insert(ui->button_7->text()); } +void mainUI::captureButton8(){ ui->line_eq->insert(ui->button_8->text()); } +void mainUI::captureButton9(){ ui->line_eq->insert(ui->button_9->text()); } +void mainUI::captureButton0(){ ui->line_eq->insert(ui->button_0->text()); } +void mainUI::captureButtonSubtract(){ ui->line_eq->insert(ui->button_Subtract->text()); } +void mainUI::captureButtonAdd(){ ui->line_eq->insert(ui->button_Add->text()); } +void mainUI::captureButtonDivide(){ ui->line_eq->insert(ui->button_Divide->text()); } +void mainUI::captureButtonMultiply(){ ui->line_eq->insert(ui->button_Multiply->text()); } //void mainUI::captureButtonEqual(){ ui->line_eq->setText(ui->line_eq->text() += ui->button_Equal->text()); } -void mainUI::captureButtonDecimal(){ ui->line_eq->setText(ui->line_eq->text() += ui->button_Decimal->text()); } +void mainUI::captureButtonDecimal(){ ui->line_eq->insert(ui->button_Decimal->text()); } + +void mainUI::insert_history(QListWidgetItem *it){ + QString txt = it->text().section("[",1,-1).section("]",0,0).simplified(); + ui->line_eq->insert("("+txt+")"); +} +// ===================== +// PRIVATE FUNCTIONS +// ===================== double mainUI::performOperation(double LHS, double RHS, QChar symbol){ //qDebug() << "Perform Operation:" << LHS << symbol << RHS; if(symbol== '+'){ return (LHS+RHS); } @@ -131,7 +140,7 @@ double mainUI::strToNumber(QString str){ } if(sym>0){ return performOperation( strToNumber(str.left(sym)), strToNumber(str.right(str.length()-sym-1)), str[sym]); } if(sym==0){ return BADVALUE; } - //Now look for multiply/divide + //Now look for multiply/divide/power symbols.clear(); symbols << "x" << "*" << "/" << "^" ; for(int i=0; i #include #include +#include namespace Ui{ class mainUI; @@ -44,6 +45,7 @@ private slots: // void captureButtonEqual(); void captureButtonDecimal(); + void insert_history(QListWidgetItem *it); private: Ui::mainUI *ui; diff --git a/src-qt5/desktop-utils/lumina-calculator/mainUI.ui b/src-qt5/desktop-utils/lumina-calculator/mainUI.ui index 0bdc4001..27d84ac0 100644 --- a/src-qt5/desktop-utils/lumina-calculator/mainUI.ui +++ b/src-qt5/desktop-utils/lumina-calculator/mainUI.ui @@ -33,6 +33,9 @@ Qt::NoFocus + + QAbstractItemView::NoSelection + @@ -46,7 +49,7 @@ Qt::NoFocus - C + C false @@ -65,7 +68,7 @@ Qt::NoFocus - 7 + 7 @@ -75,7 +78,7 @@ Qt::NoFocus - 8 + 8 @@ -85,7 +88,7 @@ Qt::NoFocus - 9 + 9 @@ -95,7 +98,7 @@ Qt::NoFocus - / + / @@ -105,7 +108,7 @@ Qt::NoFocus - 4 + 4 @@ -115,7 +118,7 @@ Qt::NoFocus - 5 + 5 @@ -125,7 +128,7 @@ Qt::NoFocus - 6 + 6 @@ -135,7 +138,7 @@ Qt::NoFocus - * + * @@ -145,7 +148,7 @@ Qt::NoFocus - 1 + 1 @@ -155,7 +158,7 @@ Qt::NoFocus - 2 + 2 @@ -165,7 +168,7 @@ Qt::NoFocus - 3 + 3 @@ -175,7 +178,7 @@ Qt::NoFocus - - + - @@ -185,7 +188,7 @@ Qt::NoFocus - 0 + 0 @@ -195,7 +198,7 @@ Qt::NoFocus - . + . @@ -205,7 +208,7 @@ Qt::NoFocus - = + = @@ -215,7 +218,7 @@ Qt::NoFocus - + + + -- cgit From 563776ab60c28f259545d5f0b40210785be82ccf Mon Sep 17 00:00:00 2001 From: Ken Moore Date: Thu, 20 Oct 2016 14:48:25 -0400 Subject: Add all the translation files for lumina-calculator. --- src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_af.ts | 13 +++++++++++++ src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_ar.ts | 13 +++++++++++++ src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_az.ts | 13 +++++++++++++ src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_bg.ts | 13 +++++++++++++ src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_bn.ts | 13 +++++++++++++ src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_bs.ts | 13 +++++++++++++ src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_ca.ts | 13 +++++++++++++ src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_cs.ts | 13 +++++++++++++ src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_cy.ts | 13 +++++++++++++ src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_da.ts | 13 +++++++++++++ src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_de.ts | 13 +++++++++++++ src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_el.ts | 13 +++++++++++++ .../desktop-utils/lumina-calculator/i18n/l-calc_en_GB.ts | 13 +++++++++++++ .../desktop-utils/lumina-calculator/i18n/l-calc_en_ZA.ts | 13 +++++++++++++ src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_es.ts | 13 +++++++++++++ src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_et.ts | 13 +++++++++++++ src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_eu.ts | 13 +++++++++++++ src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_fa.ts | 13 +++++++++++++ src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_fi.ts | 13 +++++++++++++ src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_fr.ts | 13 +++++++++++++ .../desktop-utils/lumina-calculator/i18n/l-calc_fr_CA.ts | 13 +++++++++++++ src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_gl.ts | 13 +++++++++++++ src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_he.ts | 13 +++++++++++++ src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_hi.ts | 13 +++++++++++++ src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_hr.ts | 13 +++++++++++++ src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_hu.ts | 13 +++++++++++++ src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_id.ts | 13 +++++++++++++ src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_is.ts | 13 +++++++++++++ src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_it.ts | 13 +++++++++++++ src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_ja.ts | 13 +++++++++++++ src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_ka.ts | 13 +++++++++++++ src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_ko.ts | 13 +++++++++++++ src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_lt.ts | 13 +++++++++++++ src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_lv.ts | 13 +++++++++++++ src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_mk.ts | 13 +++++++++++++ src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_mn.ts | 13 +++++++++++++ src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_ms.ts | 13 +++++++++++++ src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_mt.ts | 13 +++++++++++++ src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_nb.ts | 13 +++++++++++++ src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_nl.ts | 13 +++++++++++++ src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_pa.ts | 13 +++++++++++++ src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_pl.ts | 13 +++++++++++++ src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_pt.ts | 13 +++++++++++++ .../desktop-utils/lumina-calculator/i18n/l-calc_pt_BR.ts | 13 +++++++++++++ src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_ro.ts | 13 +++++++++++++ src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_ru.ts | 13 +++++++++++++ src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_sk.ts | 13 +++++++++++++ src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_sl.ts | 13 +++++++++++++ src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_sr.ts | 13 +++++++++++++ src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_sv.ts | 13 +++++++++++++ src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_sw.ts | 13 +++++++++++++ src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_ta.ts | 13 +++++++++++++ src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_tg.ts | 13 +++++++++++++ src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_th.ts | 13 +++++++++++++ src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_tr.ts | 13 +++++++++++++ src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_uk.ts | 13 +++++++++++++ src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_uz.ts | 13 +++++++++++++ src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_vi.ts | 13 +++++++++++++ .../desktop-utils/lumina-calculator/i18n/l-calc_zh_CN.ts | 13 +++++++++++++ .../desktop-utils/lumina-calculator/i18n/l-calc_zh_HK.ts | 13 +++++++++++++ .../desktop-utils/lumina-calculator/i18n/l-calc_zh_TW.ts | 13 +++++++++++++ src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_zu.ts | 13 +++++++++++++ 62 files changed, 806 insertions(+) create mode 100644 src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_af.ts create mode 100644 src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_ar.ts create mode 100644 src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_az.ts create mode 100644 src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_bg.ts create mode 100644 src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_bn.ts create mode 100644 src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_bs.ts create mode 100644 src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_ca.ts create mode 100644 src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_cs.ts create mode 100644 src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_cy.ts create mode 100644 src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_da.ts create mode 100644 src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_de.ts create mode 100644 src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_el.ts create mode 100644 src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_en_GB.ts create mode 100644 src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_en_ZA.ts create mode 100644 src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_es.ts create mode 100644 src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_et.ts create mode 100644 src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_eu.ts create mode 100644 src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_fa.ts create mode 100644 src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_fi.ts create mode 100644 src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_fr.ts create mode 100644 src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_fr_CA.ts create mode 100644 src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_gl.ts create mode 100644 src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_he.ts create mode 100644 src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_hi.ts create mode 100644 src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_hr.ts create mode 100644 src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_hu.ts create mode 100644 src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_id.ts create mode 100644 src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_is.ts create mode 100644 src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_it.ts create mode 100644 src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_ja.ts create mode 100644 src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_ka.ts create mode 100644 src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_ko.ts create mode 100644 src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_lt.ts create mode 100644 src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_lv.ts create mode 100644 src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_mk.ts create mode 100644 src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_mn.ts create mode 100644 src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_ms.ts create mode 100644 src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_mt.ts create mode 100644 src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_nb.ts create mode 100644 src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_nl.ts create mode 100644 src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_pa.ts create mode 100644 src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_pl.ts create mode 100644 src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_pt.ts create mode 100644 src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_pt_BR.ts create mode 100644 src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_ro.ts create mode 100644 src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_ru.ts create mode 100644 src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_sk.ts create mode 100644 src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_sl.ts create mode 100644 src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_sr.ts create mode 100644 src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_sv.ts create mode 100644 src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_sw.ts create mode 100644 src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_ta.ts create mode 100644 src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_tg.ts create mode 100644 src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_th.ts create mode 100644 src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_tr.ts create mode 100644 src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_uk.ts create mode 100644 src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_uz.ts create mode 100644 src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_vi.ts create mode 100644 src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_zh_CN.ts create mode 100644 src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_zh_HK.ts create mode 100644 src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_zh_TW.ts create mode 100644 src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_zu.ts (limited to 'src-qt5') diff --git a/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_af.ts b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_af.ts new file mode 100644 index 00000000..54ad3351 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_af.ts @@ -0,0 +1,13 @@ + + + + + mainUI + + + + Calculator + + + + diff --git a/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_ar.ts b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_ar.ts new file mode 100644 index 00000000..5dc7d76b --- /dev/null +++ b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_ar.ts @@ -0,0 +1,13 @@ + + + + + mainUI + + + + Calculator + + + + diff --git a/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_az.ts b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_az.ts new file mode 100644 index 00000000..41f9070c --- /dev/null +++ b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_az.ts @@ -0,0 +1,13 @@ + + + + + mainUI + + + + Calculator + + + + diff --git a/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_bg.ts b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_bg.ts new file mode 100644 index 00000000..ab1c6569 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_bg.ts @@ -0,0 +1,13 @@ + + + + + mainUI + + + + Calculator + + + + diff --git a/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_bn.ts b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_bn.ts new file mode 100644 index 00000000..99e0144c --- /dev/null +++ b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_bn.ts @@ -0,0 +1,13 @@ + + + + + mainUI + + + + Calculator + + + + diff --git a/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_bs.ts b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_bs.ts new file mode 100644 index 00000000..aa8362ff --- /dev/null +++ b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_bs.ts @@ -0,0 +1,13 @@ + + + + + mainUI + + + + Calculator + + + + diff --git a/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_ca.ts b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_ca.ts new file mode 100644 index 00000000..47d2670e --- /dev/null +++ b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_ca.ts @@ -0,0 +1,13 @@ + + + + + mainUI + + + + Calculator + + + + diff --git a/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_cs.ts b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_cs.ts new file mode 100644 index 00000000..dd36fb16 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_cs.ts @@ -0,0 +1,13 @@ + + + + + mainUI + + + + Calculator + + + + diff --git a/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_cy.ts b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_cy.ts new file mode 100644 index 00000000..80119d58 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_cy.ts @@ -0,0 +1,13 @@ + + + + + mainUI + + + + Calculator + + + + diff --git a/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_da.ts b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_da.ts new file mode 100644 index 00000000..6dc55f8d --- /dev/null +++ b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_da.ts @@ -0,0 +1,13 @@ + + + + + mainUI + + + + Calculator + + + + diff --git a/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_de.ts b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_de.ts new file mode 100644 index 00000000..6cb82dc3 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_de.ts @@ -0,0 +1,13 @@ + + + + + mainUI + + + + Calculator + + + + diff --git a/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_el.ts b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_el.ts new file mode 100644 index 00000000..5d62322d --- /dev/null +++ b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_el.ts @@ -0,0 +1,13 @@ + + + + + mainUI + + + + Calculator + + + + diff --git a/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_en_GB.ts b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_en_GB.ts new file mode 100644 index 00000000..54347b9d --- /dev/null +++ b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_en_GB.ts @@ -0,0 +1,13 @@ + + + + + mainUI + + + + Calculator + + + + diff --git a/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_en_ZA.ts b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_en_ZA.ts new file mode 100644 index 00000000..79dea1ae --- /dev/null +++ b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_en_ZA.ts @@ -0,0 +1,13 @@ + + + + + mainUI + + + + Calculator + + + + diff --git a/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_es.ts b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_es.ts new file mode 100644 index 00000000..7cf1d5aa --- /dev/null +++ b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_es.ts @@ -0,0 +1,13 @@ + + + + + mainUI + + + + Calculator + + + + diff --git a/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_et.ts b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_et.ts new file mode 100644 index 00000000..13cdfc55 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_et.ts @@ -0,0 +1,13 @@ + + + + + mainUI + + + + Calculator + + + + diff --git a/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_eu.ts b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_eu.ts new file mode 100644 index 00000000..9c77d59c --- /dev/null +++ b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_eu.ts @@ -0,0 +1,13 @@ + + + + + mainUI + + + + Calculator + + + + diff --git a/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_fa.ts b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_fa.ts new file mode 100644 index 00000000..60773570 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_fa.ts @@ -0,0 +1,13 @@ + + + + + mainUI + + + + Calculator + + + + diff --git a/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_fi.ts b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_fi.ts new file mode 100644 index 00000000..4e1e8d2e --- /dev/null +++ b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_fi.ts @@ -0,0 +1,13 @@ + + + + + mainUI + + + + Calculator + + + + diff --git a/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_fr.ts b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_fr.ts new file mode 100644 index 00000000..cda0a564 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_fr.ts @@ -0,0 +1,13 @@ + + + + + mainUI + + + + Calculator + + + + diff --git a/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_fr_CA.ts b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_fr_CA.ts new file mode 100644 index 00000000..5b35a26f --- /dev/null +++ b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_fr_CA.ts @@ -0,0 +1,13 @@ + + + + + mainUI + + + + Calculator + + + + diff --git a/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_gl.ts b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_gl.ts new file mode 100644 index 00000000..2b09f479 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_gl.ts @@ -0,0 +1,13 @@ + + + + + mainUI + + + + Calculator + + + + diff --git a/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_he.ts b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_he.ts new file mode 100644 index 00000000..376dfcd0 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_he.ts @@ -0,0 +1,13 @@ + + + + + mainUI + + + + Calculator + + + + diff --git a/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_hi.ts b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_hi.ts new file mode 100644 index 00000000..2ab13f9e --- /dev/null +++ b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_hi.ts @@ -0,0 +1,13 @@ + + + + + mainUI + + + + Calculator + + + + diff --git a/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_hr.ts b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_hr.ts new file mode 100644 index 00000000..d3123f5d --- /dev/null +++ b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_hr.ts @@ -0,0 +1,13 @@ + + + + + mainUI + + + + Calculator + + + + diff --git a/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_hu.ts b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_hu.ts new file mode 100644 index 00000000..d7d5c557 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_hu.ts @@ -0,0 +1,13 @@ + + + + + mainUI + + + + Calculator + + + + diff --git a/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_id.ts b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_id.ts new file mode 100644 index 00000000..4700f930 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_id.ts @@ -0,0 +1,13 @@ + + + + + mainUI + + + + Calculator + + + + diff --git a/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_is.ts b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_is.ts new file mode 100644 index 00000000..bf773bf3 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_is.ts @@ -0,0 +1,13 @@ + + + + + mainUI + + + + Calculator + + + + diff --git a/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_it.ts b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_it.ts new file mode 100644 index 00000000..a3f606be --- /dev/null +++ b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_it.ts @@ -0,0 +1,13 @@ + + + + + mainUI + + + + Calculator + + + + diff --git a/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_ja.ts b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_ja.ts new file mode 100644 index 00000000..7b367b3a --- /dev/null +++ b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_ja.ts @@ -0,0 +1,13 @@ + + + + + mainUI + + + + Calculator + + + + diff --git a/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_ka.ts b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_ka.ts new file mode 100644 index 00000000..71f6d604 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_ka.ts @@ -0,0 +1,13 @@ + + + + + mainUI + + + + Calculator + + + + diff --git a/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_ko.ts b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_ko.ts new file mode 100644 index 00000000..0fc1b363 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_ko.ts @@ -0,0 +1,13 @@ + + + + + mainUI + + + + Calculator + + + + diff --git a/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_lt.ts b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_lt.ts new file mode 100644 index 00000000..22cfc2cb --- /dev/null +++ b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_lt.ts @@ -0,0 +1,13 @@ + + + + + mainUI + + + + Calculator + + + + diff --git a/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_lv.ts b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_lv.ts new file mode 100644 index 00000000..9ba30a3e --- /dev/null +++ b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_lv.ts @@ -0,0 +1,13 @@ + + + + + mainUI + + + + Calculator + + + + diff --git a/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_mk.ts b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_mk.ts new file mode 100644 index 00000000..b275b485 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_mk.ts @@ -0,0 +1,13 @@ + + + + + mainUI + + + + Calculator + + + + diff --git a/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_mn.ts b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_mn.ts new file mode 100644 index 00000000..1018590c --- /dev/null +++ b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_mn.ts @@ -0,0 +1,13 @@ + + + + + mainUI + + + + Calculator + + + + diff --git a/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_ms.ts b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_ms.ts new file mode 100644 index 00000000..d9250e01 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_ms.ts @@ -0,0 +1,13 @@ + + + + + mainUI + + + + Calculator + + + + diff --git a/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_mt.ts b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_mt.ts new file mode 100644 index 00000000..030a2be0 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_mt.ts @@ -0,0 +1,13 @@ + + + + + mainUI + + + + Calculator + + + + diff --git a/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_nb.ts b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_nb.ts new file mode 100644 index 00000000..95884832 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_nb.ts @@ -0,0 +1,13 @@ + + + + + mainUI + + + + Calculator + + + + diff --git a/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_nl.ts b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_nl.ts new file mode 100644 index 00000000..8c0c7356 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_nl.ts @@ -0,0 +1,13 @@ + + + + + mainUI + + + + Calculator + + + + diff --git a/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_pa.ts b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_pa.ts new file mode 100644 index 00000000..f80e33eb --- /dev/null +++ b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_pa.ts @@ -0,0 +1,13 @@ + + + + + mainUI + + + + Calculator + + + + diff --git a/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_pl.ts b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_pl.ts new file mode 100644 index 00000000..d531246b --- /dev/null +++ b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_pl.ts @@ -0,0 +1,13 @@ + + + + + mainUI + + + + Calculator + + + + diff --git a/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_pt.ts b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_pt.ts new file mode 100644 index 00000000..3c54632b --- /dev/null +++ b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_pt.ts @@ -0,0 +1,13 @@ + + + + + mainUI + + + + Calculator + + + + diff --git a/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_pt_BR.ts b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_pt_BR.ts new file mode 100644 index 00000000..3c54632b --- /dev/null +++ b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_pt_BR.ts @@ -0,0 +1,13 @@ + + + + + mainUI + + + + Calculator + + + + diff --git a/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_ro.ts b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_ro.ts new file mode 100644 index 00000000..e5eb59ba --- /dev/null +++ b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_ro.ts @@ -0,0 +1,13 @@ + + + + + mainUI + + + + Calculator + + + + diff --git a/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_ru.ts b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_ru.ts new file mode 100644 index 00000000..32c8cf09 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_ru.ts @@ -0,0 +1,13 @@ + + + + + mainUI + + + + Calculator + + + + diff --git a/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_sk.ts b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_sk.ts new file mode 100644 index 00000000..417de3c2 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_sk.ts @@ -0,0 +1,13 @@ + + + + + mainUI + + + + Calculator + + + + diff --git a/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_sl.ts b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_sl.ts new file mode 100644 index 00000000..5610607f --- /dev/null +++ b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_sl.ts @@ -0,0 +1,13 @@ + + + + + mainUI + + + + Calculator + + + + diff --git a/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_sr.ts b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_sr.ts new file mode 100644 index 00000000..42f515da --- /dev/null +++ b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_sr.ts @@ -0,0 +1,13 @@ + + + + + mainUI + + + + Calculator + + + + diff --git a/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_sv.ts b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_sv.ts new file mode 100644 index 00000000..4f3c7637 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_sv.ts @@ -0,0 +1,13 @@ + + + + + mainUI + + + + Calculator + + + + diff --git a/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_sw.ts b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_sw.ts new file mode 100644 index 00000000..c4996e3d --- /dev/null +++ b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_sw.ts @@ -0,0 +1,13 @@ + + + + + mainUI + + + + Calculator + + + + diff --git a/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_ta.ts b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_ta.ts new file mode 100644 index 00000000..486563b7 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_ta.ts @@ -0,0 +1,13 @@ + + + + + mainUI + + + + Calculator + + + + diff --git a/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_tg.ts b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_tg.ts new file mode 100644 index 00000000..dacc95bd --- /dev/null +++ b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_tg.ts @@ -0,0 +1,13 @@ + + + + + mainUI + + + + Calculator + + + + diff --git a/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_th.ts b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_th.ts new file mode 100644 index 00000000..a134fa3e --- /dev/null +++ b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_th.ts @@ -0,0 +1,13 @@ + + + + + mainUI + + + + Calculator + + + + diff --git a/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_tr.ts b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_tr.ts new file mode 100644 index 00000000..d760ab23 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_tr.ts @@ -0,0 +1,13 @@ + + + + + mainUI + + + + Calculator + + + + diff --git a/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_uk.ts b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_uk.ts new file mode 100644 index 00000000..09f55b07 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_uk.ts @@ -0,0 +1,13 @@ + + + + + mainUI + + + + Calculator + + + + diff --git a/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_uz.ts b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_uz.ts new file mode 100644 index 00000000..a09644b2 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_uz.ts @@ -0,0 +1,13 @@ + + + + + mainUI + + + + Calculator + + + + diff --git a/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_vi.ts b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_vi.ts new file mode 100644 index 00000000..31a14cb7 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_vi.ts @@ -0,0 +1,13 @@ + + + + + mainUI + + + + Calculator + + + + diff --git a/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_zh_CN.ts b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_zh_CN.ts new file mode 100644 index 00000000..2e7e7c71 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_zh_CN.ts @@ -0,0 +1,13 @@ + + + + + mainUI + + + + Calculator + + + + diff --git a/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_zh_HK.ts b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_zh_HK.ts new file mode 100644 index 00000000..1b4e535b --- /dev/null +++ b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_zh_HK.ts @@ -0,0 +1,13 @@ + + + + + mainUI + + + + Calculator + + + + diff --git a/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_zh_TW.ts b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_zh_TW.ts new file mode 100644 index 00000000..33079ddc --- /dev/null +++ b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_zh_TW.ts @@ -0,0 +1,13 @@ + + + + + mainUI + + + + Calculator + + + + diff --git a/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_zu.ts b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_zu.ts new file mode 100644 index 00000000..fc2bf156 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-calculator/i18n/l-calc_zu.ts @@ -0,0 +1,13 @@ + + + + + mainUI + + + + Calculator + + + + -- cgit From 92ad3665da6644c076563d21903249ad05f29361 Mon Sep 17 00:00:00 2001 From: Ken Moore Date: Thu, 20 Oct 2016 14:49:30 -0400 Subject: Add lumina-calculator to the overall desktop-utils build. --- src-qt5/desktop-utils/desktop-utils.pro | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/desktop-utils/desktop-utils.pro b/src-qt5/desktop-utils/desktop-utils.pro index 414579e8..ddb0f6fd 100644 --- a/src-qt5/desktop-utils/desktop-utils.pro +++ b/src-qt5/desktop-utils/desktop-utils.pro @@ -5,7 +5,8 @@ TEMPLATE = subdirs CONFIG += recursive SUBDIRS+= lumina-fm \ - lumina-screenshot \ - lumina-fileinfo \ - lumina-textedit + lumina-screenshot \ + lumina-fileinfo \ + lumina-textedit \ + lumina-calculator # lumina-terminal -- cgit From c79f2df77758fa520bbdc3209d417ef77ca329a1 Mon Sep 17 00:00:00 2001 From: Ken Moore Date: Thu, 20 Oct 2016 15:02:46 -0400 Subject: Fix the resizability of the lumina-calculator window. --- src-qt5/desktop-utils/lumina-calculator/mainUI.ui | 497 +++++++++++++--------- 1 file changed, 296 insertions(+), 201 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/desktop-utils/lumina-calculator/mainUI.ui b/src-qt5/desktop-utils/lumina-calculator/mainUI.ui index 27d84ac0..8586bc8e 100644 --- a/src-qt5/desktop-utils/lumina-calculator/mainUI.ui +++ b/src-qt5/desktop-utils/lumina-calculator/mainUI.ui @@ -6,225 +6,320 @@ 0 0 - 255 - 376 + 271 + 393 Calculator - - - - 9 - 9 - 241 - 361 - - - - Qt::Vertical - - - - - - - Qt::NoFocus - - - QAbstractItemView::NoSelection - - - - - + + + + + Qt::Vertical + + + true + + + - + + + Qt::NoFocus + + + QAbstractItemView::NoSelection + + - + + + + + + + + Qt::NoFocus + + + C + + + false + + + + + + + + + + + + + + 0 + 0 + + + + Qt::NoFocus + + + 7 + + + + + + + + 0 + 0 + + + + Qt::NoFocus + + + 8 + + + + + + + + 0 + 0 + + + + Qt::NoFocus + + + 9 + + + + + + + + 0 + 0 + + + + Qt::NoFocus + + + / + + + + + + + + 0 + 0 + + + + Qt::NoFocus + + + 4 + + + + + + + + 0 + 0 + + + + Qt::NoFocus + + + 5 + + + + + + + + 0 + 0 + + + + Qt::NoFocus + + + 6 + + + + + + + + 0 + 0 + + Qt::NoFocus - C + * - - false + + + + + + + 0 + 0 + + + + Qt::NoFocus + + + 1 + + + + + + + + 0 + 0 + + + + Qt::NoFocus + + + 2 + + + + + + + + 0 + 0 + + + + Qt::NoFocus + + + 3 + + + + + + + + 0 + 0 + + + + Qt::NoFocus + + + - + + + + + + + + 0 + 0 + + + + Qt::NoFocus + + + 0 + + + + + + + + 0 + 0 + + + + Qt::NoFocus + + + . + + + + + + + + 0 + 0 + + + + Qt::NoFocus + + + = + + + + + + + + 0 + 0 + + + + Qt::NoFocus + + + + - - - - - - - - - Qt::NoFocus - - - 7 - - - - - - - Qt::NoFocus - - - 8 - - - - - - - Qt::NoFocus - - - 9 - - - - - - - Qt::NoFocus - - - / - - - - - - - Qt::NoFocus - - - 4 - - - - - - - Qt::NoFocus - - - 5 - - - - - - - Qt::NoFocus - - - 6 - - - - - - - Qt::NoFocus - - - * - - - - - - - Qt::NoFocus - - - 1 - - - - - - - Qt::NoFocus - - - 2 - - - - - - - Qt::NoFocus - - - 3 - - - - - - - Qt::NoFocus - - - - - - - - - - - Qt::NoFocus - - - 0 - - - - - - - Qt::NoFocus - - - . - - - - - - - Qt::NoFocus - - - = - - - - - - - Qt::NoFocus - - - + - - - - - - + + + + -- cgit From 4aea9f05c63447e5f05c15fbc8cb6bcc9382d19d Mon Sep 17 00:00:00 2001 From: Ken Moore Date: Thu, 20 Oct 2016 15:12:45 -0400 Subject: Oops, make sure the .desktop file actually gets installed. --- src-qt5/desktop-utils/lumina-calculator/lumina-calculator.desktop | 1 + src-qt5/desktop-utils/lumina-calculator/lumina-calculator.pro | 2 +- src-qt5/desktop-utils/lumina-calculator/mainUI.cpp | 7 +++++++ src-qt5/desktop-utils/lumina-calculator/mainUI.h | 1 + 4 files changed, 10 insertions(+), 1 deletion(-) (limited to 'src-qt5') diff --git a/src-qt5/desktop-utils/lumina-calculator/lumina-calculator.desktop b/src-qt5/desktop-utils/lumina-calculator/lumina-calculator.desktop index cabc3de1..8732425a 100644 --- a/src-qt5/desktop-utils/lumina-calculator/lumina-calculator.desktop +++ b/src-qt5/desktop-utils/lumina-calculator/lumina-calculator.desktop @@ -6,4 +6,5 @@ Type=Application StartupNotify=true Categories=Utility; Name=Calculator +GenericName=Scientific Calculator for Lumina Comment=Perform mathematical calculations diff --git a/src-qt5/desktop-utils/lumina-calculator/lumina-calculator.pro b/src-qt5/desktop-utils/lumina-calculator/lumina-calculator.pro index 15578f4e..38e22b37 100644 --- a/src-qt5/desktop-utils/lumina-calculator/lumina-calculator.pro +++ b/src-qt5/desktop-utils/lumina-calculator/lumina-calculator.pro @@ -86,7 +86,7 @@ dotrans.extra=cd i18n && $${LRELEASE} -nounfinished *.ts && cp *.qm $(INSTALL_RO desktop.files=lumina-calculator.desktop desktop.path=$${L_SHAREDIR}/applications/ -INSTALLS += target +INSTALLS += target desktop WITH_I18N{ INSTALLS += dotrans diff --git a/src-qt5/desktop-utils/lumina-calculator/mainUI.cpp b/src-qt5/desktop-utils/lumina-calculator/mainUI.cpp index cdb33414..49449586 100644 --- a/src-qt5/desktop-utils/lumina-calculator/mainUI.cpp +++ b/src-qt5/desktop-utils/lumina-calculator/mainUI.cpp @@ -8,6 +8,8 @@ #include "ui_mainUI.h" #include +#include + #include #include "EqValidator.h" @@ -35,6 +37,7 @@ mainUI::mainUI() : QMainWindow(), ui(new Ui::mainUI()){ connect(ui->button_Decimal, SIGNAL (clicked()), this, SLOT (captureButtonDecimal())); connect(ui->button_Equal, SIGNAL (clicked()), this, SLOT (start_calc())); connect(ui->list_results, SIGNAL(itemClicked(QListWidgetItem*)), this, SLOT(insert_history(QListWidgetItem*)) ); + //connect(ui->list_results, SIGNAL(itemRightClicked(QListWidgetItem*)), this, SLOT(copt_to_clipboard(QListWidgetItem*)) ); this->setWindowTitle(tr("Calculator")); updateIcons(); ui->line_eq->setFocus(); @@ -86,6 +89,10 @@ void mainUI::insert_history(QListWidgetItem *it){ ui->line_eq->insert("("+txt+")"); } +void mainUI::copy_to_clipboard(QListWidgetItem *it){ + QString txt = it->text(); + QApplication::clipboard()->setText(txt); +} // ===================== // PRIVATE FUNCTIONS // ===================== diff --git a/src-qt5/desktop-utils/lumina-calculator/mainUI.h b/src-qt5/desktop-utils/lumina-calculator/mainUI.h index 4192b250..50762677 100644 --- a/src-qt5/desktop-utils/lumina-calculator/mainUI.h +++ b/src-qt5/desktop-utils/lumina-calculator/mainUI.h @@ -46,6 +46,7 @@ private slots: void captureButtonDecimal(); void insert_history(QListWidgetItem *it); + void copy_to_clipboard(QListWidgetItem *it); private: Ui::mainUI *ui; -- cgit From 0107662030f5ebf25a65fca39d203e821cfeb544 Mon Sep 17 00:00:00 2001 From: Ken Moore Date: Thu, 20 Oct 2016 15:43:54 -0400 Subject: Setup the calculator to automatically load the last result if the first char is an operator. --- src-qt5/desktop-utils/lumina-calculator/mainUI.cpp | 13 +++++++++++++ src-qt5/desktop-utils/lumina-calculator/mainUI.h | 1 + 2 files changed, 14 insertions(+) (limited to 'src-qt5') diff --git a/src-qt5/desktop-utils/lumina-calculator/mainUI.cpp b/src-qt5/desktop-utils/lumina-calculator/mainUI.cpp index 49449586..a85bcf42 100644 --- a/src-qt5/desktop-utils/lumina-calculator/mainUI.cpp +++ b/src-qt5/desktop-utils/lumina-calculator/mainUI.cpp @@ -16,10 +16,13 @@ #include #define BADVALUE NAN +#define OPS QString("+-*/x^") + mainUI::mainUI() : QMainWindow(), ui(new Ui::mainUI()){ ui->setupUi(this); connect(ui->tool_clear, SIGNAL(clicked()), this, SLOT(clear_calc()) ); connect(ui->line_eq, SIGNAL(returnPressed()), this, SLOT(start_calc()) ); + connect(ui->line_eq, SIGNAL(textEdited(const QString&)), this, SLOT(checkInput(const QString&)) ); connect(ui->button_1, SIGNAL (clicked()), this, SLOT (captureButton1())); connect(ui->button_2, SIGNAL (clicked()), this, SLOT (captureButton2())); connect(ui->button_3, SIGNAL (clicked()), this, SLOT (captureButton3())); @@ -93,6 +96,16 @@ void mainUI::copy_to_clipboard(QListWidgetItem *it){ QString txt = it->text(); QApplication::clipboard()->setText(txt); } + +void mainUI::checkInput(const QString &str){ + if(str.length()==1 && ui->list_results->count()>0){ + if(OPS.contains(str)){ + QString lastresult = ui->list_results->item( ui->list_results->count()-1)->text().section("=",0,0).simplified(); + ui->line_eq->setText( lastresult+str); + } + } +} + // ===================== // PRIVATE FUNCTIONS // ===================== diff --git a/src-qt5/desktop-utils/lumina-calculator/mainUI.h b/src-qt5/desktop-utils/lumina-calculator/mainUI.h index 50762677..b4636126 100644 --- a/src-qt5/desktop-utils/lumina-calculator/mainUI.h +++ b/src-qt5/desktop-utils/lumina-calculator/mainUI.h @@ -47,6 +47,7 @@ private slots: void insert_history(QListWidgetItem *it); void copy_to_clipboard(QListWidgetItem *it); + void checkInput(const QString&); private: Ui::mainUI *ui; -- cgit From ed774582b0c66a7c86c8f8efad84f3248331c4f3 Mon Sep 17 00:00:00 2001 From: Ken Moore Date: Fri, 21 Oct 2016 08:46:04 -0400 Subject: Add directory context to the lumina-textedit in a couple ways: 1) The window title now shows 1 directory deep in stead of just the filename 2) Each tab has a tooltip which will show the full path for that file. --- src-qt5/desktop-utils/lumina-textedit/MainUI.cpp | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/desktop-utils/lumina-textedit/MainUI.cpp b/src-qt5/desktop-utils/lumina-textedit/MainUI.cpp index 613fad04..c4f4eaca 100644 --- a/src-qt5/desktop-utils/lumina-textedit/MainUI.cpp +++ b/src-qt5/desktop-utils/lumina-textedit/MainUI.cpp @@ -89,7 +89,8 @@ MainUI::~MainUI(){ void MainUI::LoadArguments(QStringList args){ //CLI arguments for(int i=0; iline_find->setFocus(); + if(ui->groupReplace->isVisible()){ ui->line_find->setFocus(); } + else{ currentEditor()->setFocus(); } } } @@ -261,8 +262,9 @@ void MainUI::updateTab(QString file){ bool changes = cur->hasChange(); //qDebug() << "Update Tab:" << file << cur << changes; ui->tabWidget->setTabText(index,(changes ? "*" : "") + file.section("/",-1)); + ui->tabWidget->setTabToolTip(index, file); ui->actionSave_File->setEnabled(changes); - this->setWindowTitle( ui->tabWidget->tabText( ui->tabWidget->currentIndex() ) ); + this->setWindowTitle( (changes ? "*" : "") + file.section("/",-2) ); } void MainUI::tabChanged(){ @@ -271,7 +273,8 @@ void MainUI::tabChanged(){ if(cur==0){ return; } //should never happen though bool changes = cur->hasChange(); ui->actionSave_File->setEnabled(changes); - this->setWindowTitle( ui->tabWidget->tabText( ui->tabWidget->currentIndex() ) ); + //this->setWindowTitle( ui->tabWidget->tabText( ui->tabWidget->currentIndex() ) ); + this->setWindowTitle( (changes ? "*" : "") + ui->tabWidget->tabToolTip( ui->tabWidget->currentIndex() ).section("/",-2) ); if(!ui->line_find->hasFocus() && !ui->line_replace->hasFocus()){ ui->tabWidget->currentWidget()->setFocus(); } } -- cgit From 91f80ba710f08a41a559182b32b793a31a239180 Mon Sep 17 00:00:00 2001 From: Ken Moore Date: Fri, 21 Oct 2016 09:28:16 -0400 Subject: Update lumina-calculator a bit: 1) Re-arrange the buttons a tiny bit to match what a numpad looks like (based on user feedback) 2) To fill the empty spot in the corner, add a "percent" button and add handling for that within the solver. 3) Adjust all the button properties so that the window can be resized down to a much smaller footprint as desired. --- .../desktop-utils/lumina-calculator/EqValidator.h | 4 +- src-qt5/desktop-utils/lumina-calculator/mainUI.cpp | 8 +- src-qt5/desktop-utils/lumina-calculator/mainUI.h | 1 + src-qt5/desktop-utils/lumina-calculator/mainUI.ui | 437 +++++++++++++++++---- 4 files changed, 380 insertions(+), 70 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/desktop-utils/lumina-calculator/EqValidator.h b/src-qt5/desktop-utils/lumina-calculator/EqValidator.h index 462a330d..8218efdf 100644 --- a/src-qt5/desktop-utils/lumina-calculator/EqValidator.h +++ b/src-qt5/desktop-utils/lumina-calculator/EqValidator.h @@ -7,8 +7,8 @@ #ifndef _LUMINA_CALCULATOR_VALIDATOR_H #define _LUMINA_CALCULATOR_VALIDATOR_H -#define VALIDCHARS QString("x*+-/^eE().0123456789") -#define NOSTARTCHARS QString("x*/^)eE.") +#define VALIDCHARS QString("x*+-/^%eE().0123456789") +#define NOSTARTCHARS QString("x*/^%)eE.") #define NOENDCHARS QString("x*/^(eE.") #define NOCHANGE QString("().") diff --git a/src-qt5/desktop-utils/lumina-calculator/mainUI.cpp b/src-qt5/desktop-utils/lumina-calculator/mainUI.cpp index a85bcf42..1ea925cd 100644 --- a/src-qt5/desktop-utils/lumina-calculator/mainUI.cpp +++ b/src-qt5/desktop-utils/lumina-calculator/mainUI.cpp @@ -16,7 +16,7 @@ #include #define BADVALUE NAN -#define OPS QString("+-*/x^") +#define OPS QString("+-*/x^%") mainUI::mainUI() : QMainWindow(), ui(new Ui::mainUI()){ ui->setupUi(this); @@ -38,6 +38,7 @@ mainUI::mainUI() : QMainWindow(), ui(new Ui::mainUI()){ connect(ui->button_Divide, SIGNAL (clicked()), this, SLOT (captureButtonDivide())); connect(ui->button_Multiply, SIGNAL (clicked()), this, SLOT (captureButtonMultiply())); connect(ui->button_Decimal, SIGNAL (clicked()), this, SLOT (captureButtonDecimal())); + connect(ui->button_Percent, SIGNAL(clicked()), this, SLOT(captureButtonPercent()) ); connect(ui->button_Equal, SIGNAL (clicked()), this, SLOT (start_calc())); connect(ui->list_results, SIGNAL(itemClicked(QListWidgetItem*)), this, SLOT(insert_history(QListWidgetItem*)) ); //connect(ui->list_results, SIGNAL(itemRightClicked(QListWidgetItem*)), this, SLOT(copt_to_clipboard(QListWidgetItem*)) ); @@ -57,7 +58,9 @@ void mainUI::updateIcons(){ void mainUI::start_calc(){ if(ui->line_eq->text().isEmpty()){ return; } //nothing to do - double result = strToNumber(ui->line_eq->text()); + QString eq = ui->line_eq->text(); + eq.replace("%","/(100)"); + double result = strToNumber(eq); if(result!=result){ return; } //bad calculation - NaN's values are special in that they don't equal itself QString res = "%1 \t= [ %2 ]"; ui->list_results->addItem(res.arg(QString::number(result), ui->line_eq->text())); @@ -86,6 +89,7 @@ void mainUI::captureButtonDivide(){ ui->line_eq->insert(ui->button_Divide->text( void mainUI::captureButtonMultiply(){ ui->line_eq->insert(ui->button_Multiply->text()); } //void mainUI::captureButtonEqual(){ ui->line_eq->setText(ui->line_eq->text() += ui->button_Equal->text()); } void mainUI::captureButtonDecimal(){ ui->line_eq->insert(ui->button_Decimal->text()); } +void mainUI::captureButtonPercent(){ ui->line_eq->insert(ui->button_Percent->text()); } void mainUI::insert_history(QListWidgetItem *it){ QString txt = it->text().section("[",1,-1).section("]",0,0).simplified(); diff --git a/src-qt5/desktop-utils/lumina-calculator/mainUI.h b/src-qt5/desktop-utils/lumina-calculator/mainUI.h index b4636126..cf09801e 100644 --- a/src-qt5/desktop-utils/lumina-calculator/mainUI.h +++ b/src-qt5/desktop-utils/lumina-calculator/mainUI.h @@ -44,6 +44,7 @@ private slots: void captureButtonMultiply(); // void captureButtonEqual(); void captureButtonDecimal(); + void captureButtonPercent(); void insert_history(QListWidgetItem *it); void copy_to_clipboard(QListWidgetItem *it); diff --git a/src-qt5/desktop-utils/lumina-calculator/mainUI.ui b/src-qt5/desktop-utils/lumina-calculator/mainUI.ui index 8586bc8e..699915f2 100644 --- a/src-qt5/desktop-utils/lumina-calculator/mainUI.ui +++ b/src-qt5/desktop-utils/lumina-calculator/mainUI.ui @@ -6,20 +6,44 @@ 0 0 - 271 - 393 + 171 + 258 Calculator + + false + + + + 0 + 0 + + + + 4 + + + 4 + + + 4 + + + 4 + Qt::Vertical + + 10 + true @@ -38,10 +62,23 @@ - + + + + 0 + 0 + + + + + + 0 + 0 + + Qt::NoFocus @@ -58,260 +95,528 @@ + + + 0 + 0 + + - - + + - + 0 0 + + + 20 + 20 + + + + + 5 + 5 + + + + + 30 + 30 + + + + + 11 + 75 + false + true + false + + Qt::NoFocus - 7 + = - - + + - + 0 0 + + + 20 + 20 + + + + + 5 + 5 + + + + + 75 + true + + Qt::NoFocus - 8 + * - - + + - + 0 0 + + + 20 + 20 + + + + + 5 + 5 + + + + + 75 + true + + Qt::NoFocus - 9 + + - - + + - + 0 0 + + + 20 + 20 + + + + + 5 + 5 + + Qt::NoFocus - / + . - - + + - + 0 0 + + + 20 + 20 + + + + + 5 + 5 + + Qt::NoFocus - 4 + 0 - - + + - + 0 0 + + + 20 + 20 + + + + + 5 + 5 + + + + + 75 + true + + Qt::NoFocus - 5 + - - - + + - + 0 0 + + + 20 + 20 + + + + + 5 + 5 + + + + + 75 + true + + Qt::NoFocus - 6 + / - - + + - + 0 0 + + + 20 + 20 + + + + + 5 + 5 + + Qt::NoFocus - * + 7 - - + + - + 0 0 + + + 20 + 20 + + + + + 5 + 5 + + Qt::NoFocus - 1 + 8 - - + + - + 0 0 + + + 20 + 20 + + + + + 5 + 5 + + Qt::NoFocus - 2 + 9 - - + + - + 0 0 + + + 20 + 20 + + + + + 5 + 5 + + Qt::NoFocus - 3 + 4 - - + + - + 0 0 + + + 20 + 20 + + + + + 5 + 5 + + Qt::NoFocus - - + 5 + + + + + + + + 0 + 0 + + + + + 20 + 20 + + + + + 5 + 5 + + + + Qt::NoFocus + + + 6 - + - + 0 0 + + + 20 + 20 + + + + + 5 + 5 + + Qt::NoFocus - 0 + 1 - + - + 0 0 + + + 20 + 20 + + + + + 5 + 5 + + Qt::NoFocus - . + 2 - + - + 0 0 + + + 20 + 20 + + + + + 5 + 5 + + Qt::NoFocus - = + 3 - - + + - + 0 0 - - Qt::NoFocus + + + 20 + 20 + + + + + 5 + 5 + + + + + 75 + true + - + + % -- cgit From ec467b53d969067cc91aa3ddb08defcd5d592cca Mon Sep 17 00:00:00 2001 From: Ken Moore Date: Fri, 21 Oct 2016 10:17:43 -0400 Subject: Turn off keyboard focus for the new % button. --- src-qt5/desktop-utils/lumina-calculator/mainUI.ui | 3 +++ 1 file changed, 3 insertions(+) (limited to 'src-qt5') diff --git a/src-qt5/desktop-utils/lumina-calculator/mainUI.ui b/src-qt5/desktop-utils/lumina-calculator/mainUI.ui index 699915f2..7a0ccfed 100644 --- a/src-qt5/desktop-utils/lumina-calculator/mainUI.ui +++ b/src-qt5/desktop-utils/lumina-calculator/mainUI.ui @@ -615,6 +615,9 @@ true + + Qt::NoFocus + % -- cgit From 85353ba9941d7971d19698dca54bdc946b4ec9e9 Mon Sep 17 00:00:00 2001 From: Ken Moore Date: Fri, 21 Oct 2016 10:48:55 -0400 Subject: Tag version 1.1.0 in the source tree --- src-qt5/core/libLumina/LuminaUtils.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src-qt5') diff --git a/src-qt5/core/libLumina/LuminaUtils.cpp b/src-qt5/core/libLumina/LuminaUtils.cpp index 9fc4e6b0..d74ca864 100644 --- a/src-qt5/core/libLumina/LuminaUtils.cpp +++ b/src-qt5/core/libLumina/LuminaUtils.cpp @@ -54,7 +54,7 @@ inline QStringList ProcessRun(QString cmd, QStringList args){ // LUtils Functions //============= QString LUtils::LuminaDesktopVersion(){ - QString ver = "1.0.1"; + QString ver = "1.1.0"; #ifdef GIT_VERSION ver.append( QString(" (Git Revision: %1)").arg(GIT_VERSION) ); #endif -- cgit From 2119280e7c6c851131764c1287b23653f7a3d4ee Mon Sep 17 00:00:00 2001 From: Ken Moore Date: Fri, 21 Oct 2016 10:50:33 -0400 Subject: Tag version 1.1.1 within the master branch. --- src-qt5/core/libLumina/LuminaUtils.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src-qt5') diff --git a/src-qt5/core/libLumina/LuminaUtils.cpp b/src-qt5/core/libLumina/LuminaUtils.cpp index d74ca864..0fb44ff1 100644 --- a/src-qt5/core/libLumina/LuminaUtils.cpp +++ b/src-qt5/core/libLumina/LuminaUtils.cpp @@ -54,7 +54,7 @@ inline QStringList ProcessRun(QString cmd, QStringList args){ // LUtils Functions //============= QString LUtils::LuminaDesktopVersion(){ - QString ver = "1.1.0"; + QString ver = "1.1.1"; #ifdef GIT_VERSION ver.append( QString(" (Git Revision: %1)").arg(GIT_VERSION) ); #endif -- cgit From ef338ceb9dc6826746a58d903f86200a4da81acb Mon Sep 17 00:00:00 2001 From: Ken Moore Date: Fri, 21 Oct 2016 14:20:15 -0400 Subject: If a .desktop file is given to launch, be more specific with the error when the file is invalid. --- src-qt5/core/lumina-open/main.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src-qt5') diff --git a/src-qt5/core/lumina-open/main.cpp b/src-qt5/core/lumina-open/main.cpp index 68d2575b..b411394c 100644 --- a/src-qt5/core/lumina-open/main.cpp +++ b/src-qt5/core/lumina-open/main.cpp @@ -261,7 +261,7 @@ void getCMD(int argc, char ** argv, QString& binary, QString& args, QString& pat if(extension=="desktop" && !showDLG){ XDGDesktop DF(inFile); if(!DF.isValid()){ - ShowErrorDialog( argc, argv, QString(QObject::tr("File could not be opened: %1")).arg(inFile) ); + ShowErrorDialog( argc, argv, QString(QObject::tr("Application entry is invalid: %1")).arg(inFile) ); } switch(DF.type){ case XDGDesktop::APP: -- cgit From 262e9ff5395e41abc567644530278123f357eee8 Mon Sep 17 00:00:00 2001 From: Ken Moore Date: Fri, 21 Oct 2016 14:29:15 -0400 Subject: For desktop icons, only check if there is a name to decide when to show it. Let the launcher find any problems with it and alert the user at that time. --- .../lumina-desktop/desktop-plugins/applauncher/AppLauncherPlugin.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src-qt5') diff --git a/src-qt5/core/lumina-desktop/desktop-plugins/applauncher/AppLauncherPlugin.cpp b/src-qt5/core/lumina-desktop/desktop-plugins/applauncher/AppLauncherPlugin.cpp index e9ef78cb..708355cd 100644 --- a/src-qt5/core/lumina-desktop/desktop-plugins/applauncher/AppLauncherPlugin.cpp +++ b/src-qt5/core/lumina-desktop/desktop-plugins/applauncher/AppLauncherPlugin.cpp @@ -40,7 +40,7 @@ void AppLauncherPlugin::loadButton(){ QString txt; if(path.endsWith(".desktop") && ok){ XDGDesktop file(path); - ok = file.isValid(); + ok = !file.name.isEmpty(); if(!ok){ button->setWhatsThis(""); button->setIcon( QIcon(LXDG::findIcon("quickopen-file","").pixmap(QSize(icosize,icosize)).scaledToHeight(icosize, Qt::SmoothTransformation) ) ); -- cgit From 0032544d7d9607ad544dd427ea1bd012291ff962 Mon Sep 17 00:00:00 2001 From: Ken Moore Date: Mon, 24 Oct 2016 10:55:08 -0400 Subject: Fix the "sticky" status on the wallpaper widgets. --- src-qt5/core/lumina-desktop/LDesktop.cpp | 1 + src-qt5/core/lumina-desktop/LDesktopPluginSpace.cpp | 1 + 2 files changed, 2 insertions(+) (limited to 'src-qt5') diff --git a/src-qt5/core/lumina-desktop/LDesktop.cpp b/src-qt5/core/lumina-desktop/LDesktop.cpp index 8b1bd825..1a11899d 100644 --- a/src-qt5/core/lumina-desktop/LDesktop.cpp +++ b/src-qt5/core/lumina-desktop/LDesktop.cpp @@ -230,6 +230,7 @@ void LDesktop::InitDesktop(){ else if(grid<0){ grid = 100; } bgDesktop->SetIconSize( grid ); bgDesktop->setContextMenuPolicy(Qt::CustomContextMenu); + //LSession::handle()->XCB->SetAsDesktop(bgDesktop->winId()); connect(bgDesktop, SIGNAL(PluginRemovedByUser(QString)), this, SLOT(RemoveDeskPlugin(QString)) ); connect(bgDesktop, SIGNAL(IncreaseIcons()), this, SLOT(IncreaseDesktopPluginIcons()) ); connect(bgDesktop, SIGNAL(DecreaseIcons()), this, SLOT(DecreaseDesktopPluginIcons()) ); diff --git a/src-qt5/core/lumina-desktop/LDesktopPluginSpace.cpp b/src-qt5/core/lumina-desktop/LDesktopPluginSpace.cpp index 592f3481..18126dfa 100644 --- a/src-qt5/core/lumina-desktop/LDesktopPluginSpace.cpp +++ b/src-qt5/core/lumina-desktop/LDesktopPluginSpace.cpp @@ -29,6 +29,7 @@ LDesktopPluginSpace::LDesktopPluginSpace() : QWidget(){ TopToBottom = true; GRIDSIZE = 100.0; //default value if not set plugsettings = LSession::handle()->DesktopPluginSettings(); + LSession::handle()->XCB->SetAsDesktop(this->winId()); //this->setWindowOpacity(0.0); } -- cgit From 52b42cfa1021edba7a71f47a7c537f24790b9ff5 Mon Sep 17 00:00:00 2001 From: Ken Moore Date: Tue, 25 Oct 2016 08:50:14 -0400 Subject: Fix up the double-precision calculation of equations within parentheses. Now (3*(1/3)) properly equals 1 instead of 0.9999999 --- src-qt5/desktop-utils/lumina-calculator/mainUI.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src-qt5') diff --git a/src-qt5/desktop-utils/lumina-calculator/mainUI.cpp b/src-qt5/desktop-utils/lumina-calculator/mainUI.cpp index 1ea925cd..b26acb73 100644 --- a/src-qt5/desktop-utils/lumina-calculator/mainUI.cpp +++ b/src-qt5/desktop-utils/lumina-calculator/mainUI.cpp @@ -143,7 +143,7 @@ double mainUI::strToNumber(QString str){ //qDebug() << "Replace value:" << str << start << end << str.mid(start+1,end-start); double tmp = strToNumber( str.mid(start+1, end-start-1)); if(tmp!=tmp){ return BADVALUE; } //not a number - str.replace(start, end-start+1, QString::number( tmp ) ); + str.replace(start, end-start+1, QString::number( tmp, 'e', 16) ); //need as high precision as possible here - internal only, never seen //qDebug() << "Replaced:" << str; } // ------------------------------------- -- cgit From 64572549b46acde9ef30565303f59d629cf0eb60 Mon Sep 17 00:00:00 2001 From: Ken Moore Date: Tue, 25 Oct 2016 09:05:19 -0400 Subject: Fix the creation of new files/directories within the right-column of a split view. --- src-qt5/desktop-utils/lumina-fm/widgets/DirWidget2.cpp | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/desktop-utils/lumina-fm/widgets/DirWidget2.cpp b/src-qt5/desktop-utils/lumina-fm/widgets/DirWidget2.cpp index 49799f28..161225e4 100644 --- a/src-qt5/desktop-utils/lumina-fm/widgets/DirWidget2.cpp +++ b/src-qt5/desktop-utils/lumina-fm/widgets/DirWidget2.cpp @@ -100,7 +100,7 @@ QString DirWidget::id(){ } QString DirWidget::currentDir(){ - return currentBrowser()->currentDirectory(); + return currentBrowser()->currentDirectory(); } void DirWidget::setShowDetails(bool show){ @@ -527,6 +527,7 @@ void DirWidget::dirStatusChanged(QString stat){ } void DirWidget::setCurrentBrowser(QString id){ + //qDebug() << "Set Current Browser:" << id; if(id==cBID){ return; } //no change cBID = id; currentDirectoryChanged(true); //update all the averarching widget elements (widget only) @@ -547,7 +548,7 @@ void DirWidget::createNewFile(){ &ok, 0, Qt::ImhFormattedNumbersOnly | Qt::ImhUppercaseOnly | Qt::ImhLowercaseOnly); if(!ok || newdocument.isEmpty()){ return; } //Create the empty file - QString full = BW->currentDirectory(); + QString full = currentBrowser()->currentDirectory(); if(!full.endsWith("/")){ full.append("/"); } //verify the new file does not already exist if(QFile::exists(full+newdocument)){ @@ -572,7 +573,7 @@ void DirWidget::createNewDir(){ &ok, 0, Qt::ImhFormattedNumbersOnly | Qt::ImhUppercaseOnly | Qt::ImhLowercaseOnly); if(!ok || newdir.isEmpty()){ return; } //Now create the new dir - QString full = BW->currentDirectory(); + QString full = currentBrowser()->currentDirectory(); if(!full.endsWith("/")){ full.append("/"); } QDir dir(full); //open the current dir full.append(newdir); //append the new name to the current dir @@ -596,7 +597,7 @@ void DirWidget::createNewXDGEntry(){ if(!ok || newdocument.isEmpty()){ return; } if(!newdocument.endsWith(".desktop")){ newdocument.append(".desktop"); } //Create the empty file - QString full = BW->currentDirectory(); + QString full = currentBrowser()->currentDirectory(); if(!full.endsWith("/")){ full.append("/"); } //Verify the file does not already exist if(QFile::exists(full+newdocument)){ -- cgit From af6ce6ea4f6b62d0b09b0b9ae2f8d640e828802a Mon Sep 17 00:00:00 2001 From: Ken Moore Date: Tue, 25 Oct 2016 11:54:57 -0400 Subject: Add PulseAudio support into the FreeBSD backend if a PICO session is detected. --- src-qt5/core/libLumina/LuminaOS-FreeBSD.cpp | 77 ++++++++++++++++++----------- src-qt5/core/libLumina/LuminaXDG.cpp | 1 + src-qt5/core/libLumina/LuminaXDG.h | 3 ++ 3 files changed, 51 insertions(+), 30 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/core/libLumina/LuminaOS-FreeBSD.cpp b/src-qt5/core/libLumina/LuminaOS-FreeBSD.cpp index 2bffb5a1..b9346565 100644 --- a/src-qt5/core/libLumina/LuminaOS-FreeBSD.cpp +++ b/src-qt5/core/libLumina/LuminaOS-FreeBSD.cpp @@ -97,13 +97,14 @@ void LOS::setScreenBrightness(int percent){ //Run the command(s) bool success = false; // - try hardware setting first (TrueOS || or intel_backlight) - if( LUtils::isValidBinary("pc-sysconfig") ){ + bool remoteSession = !QString(getenv("PICO_CLIENT_LOGIN")).isEmpty(); + if( LUtils::isValidBinary("pc-sysconfig") && !remoteSession){ //Use TrueOS tool (direct sysctl control) QString ret = LUtils::getCmdOutput("pc-sysconfig", QStringList() <<"setscreenbrightness "+QString::number(percent)).join(""); success = ret.toLower().contains("success"); qDebug() << "Set hardware brightness:" << percent << success; } - if( !success && LUtils::isValidBinary("intel_backlight")){ + if( !success && LUtils::isValidBinary("intel_backlight") && !remoteSession){ //Use the intel_backlight utility (only for Intel mobo/hardware?) if(0== LUtils::runCmd("intel_backlight", QStringList() <100){percent=100;} - QString info = LUtils::getCmdOutput("mixer -S vol").join(":").simplified(); //ignores any other lines - if(!info.isEmpty()){ - int L = info.section(":",1,1).toInt(); - int R = info.section(":",2,2).toInt(); - int diff = L-R; - if((percent == L) && (L==R)){ return; } //already set to that volume - if(diff<0){ R=percent; L=percent+diff; } //R Greater - else{ L=percent; R=percent-diff; } //L Greater or equal - //Check bounds - if(L<0){L=0;}else if(L>100){L=100;} - if(R<0){R=0;}else if(R>100){R=100;} - //Run Command - audiovolume = percent; //save for checking later - LUtils::runCmd("mixer vol "+QString::number(L)+":"+QString::number(R)); - LUtils::writeFile(QString(getenv("XDG_CONFIG_HOME"))+"/lumina-desktop/.currentvolume", QStringList() << QString::number(percent), true); - } + bool remoteSession = !QString(getenv("PICO_CLIENT_LOGIN")).isEmpty(); + if(remoteSession){ + LUtils::runCmd(QString("pactl set-sink-volume @DEFAULT_SINK@ ")+QString::number(percent)+"%"); + }else{ + QString info = LUtils::getCmdOutput("mixer -S vol").join(":").simplified(); //ignores any other lines + if(!info.isEmpty()){ + int L = info.section(":",1,1).toInt(); + int R = info.section(":",2,2).toInt(); + int diff = L-R; + if((percent == L) && (L==R)){ return; } //already set to that volume + if(diff<0){ R=percent; L=percent+diff; } //R Greater + else{ L=percent; R=percent-diff; } //L Greater or equal + //Check bounds + if(L<0){L=0;}else if(L>100){L=100;} + if(R<0){R=0;}else if(R>100){R=100;} + //Run Command + LUtils::runCmd("mixer vol "+QString::number(L)+":"+QString::number(R)); + } + } + audiovolume = percent; //save for checking later + LUtils::writeFile(QString(getenv("XDG_CONFIG_HOME"))+"/lumina-desktop/.currentvolume", QStringList() << QString::number(percent), true); } //Change the current volume a set amount (+ or -) void LOS::changeAudioVolume(int percentdiff){ - QString info = LUtils::getCmdOutput("mixer -S vol").join(":").simplified(); //ignores any other lines - if(!info.isEmpty()){ - int L = info.section(":",1,1).toInt() + percentdiff; - int R = info.section(":",2,2).toInt() + percentdiff; - //Check bounds - if(L<0){L=0;}else if(L>100){L=100;} - if(R<0){R=0;}else if(R>100){R=100;} - //Run Command - LUtils::runCmd("mixer vol "+QString::number(L)+":"+QString::number(R)); + bool remoteSession = !QString(getenv("PICO_CLIENT_LOGIN")).isEmpty(); + if(remoteSession){ + LUtils::runCmd(QString("pactl set-sink-volume @DEFAULT_SINK@ ")+((percentdiff>0)?"+" : "") + QString::number(percentdiff)+"%"); + }else{ + QString info = LUtils::getCmdOutput("mixer -S vol").join(":").simplified(); //ignores any other lines + if(!info.isEmpty()){ + int L = info.section(":",1,1).toInt() + percentdiff; + int R = info.section(":",2,2).toInt() + percentdiff; + //Check bounds + if(L<0){L=0;}else if(L>100){L=100;} + if(R<0){R=0;}else if(R>100){R=100;} + //Run Command + LUtils::runCmd("mixer vol "+QString::number(L)+":"+QString::number(R)); + } } } diff --git a/src-qt5/core/libLumina/LuminaXDG.cpp b/src-qt5/core/libLumina/LuminaXDG.cpp index 8ae77ea6..b0d2edd9 100644 --- a/src-qt5/core/libLumina/LuminaXDG.cpp +++ b/src-qt5/core/libLumina/LuminaXDG.cpp @@ -22,6 +22,7 @@ XDGDesktop::XDGDesktop(QString file, QObject *parent) : QObject(parent){ isHidden=false; useTerminal=false; startupNotify=false; + useVGL = false; type = XDGDesktop::BAD; filePath = file; exec = tryexec = ""; // just to make sure this is initialized diff --git a/src-qt5/core/libLumina/LuminaXDG.h b/src-qt5/core/libLumina/LuminaXDG.h index acb688ff..1c86cedb 100644 --- a/src-qt5/core/libLumina/LuminaXDG.h +++ b/src-qt5/core/libLumina/LuminaXDG.h @@ -64,6 +64,9 @@ public: QStringList actionList, mimeList, catList, keyList; bool useTerminal, startupNotify; QList actions; + //Type 1 Extensions for Lumina (Optional) + bool useVGL; //X-VGL + //Type 2 (LINK) variables QString url; -- cgit From f29b8dadbf51ed7eac584f524f3bf05a6a66de16 Mon Sep 17 00:00:00 2001 From: Ken Moore Date: Thu, 27 Oct 2016 08:26:22 -0400 Subject: Add the beginnings of the new RandR xcb backend to Lumina --- src-qt5/core/libLumina/LuminaRandR.cpp | 1 + src-qt5/core/libLumina/LuminaRandR.h | 35 ++++++++++++++++++++++++++++++++++ 2 files changed, 36 insertions(+) create mode 100644 src-qt5/core/libLumina/LuminaRandR.cpp create mode 100644 src-qt5/core/libLumina/LuminaRandR.h (limited to 'src-qt5') diff --git a/src-qt5/core/libLumina/LuminaRandR.cpp b/src-qt5/core/libLumina/LuminaRandR.cpp new file mode 100644 index 00000000..eefc5aa8 --- /dev/null +++ b/src-qt5/core/libLumina/LuminaRandR.cpp @@ -0,0 +1 @@ +#include "LuminaRandR.h" diff --git a/src-qt5/core/libLumina/LuminaRandR.h b/src-qt5/core/libLumina/LuminaRandR.h new file mode 100644 index 00000000..3cdff651 --- /dev/null +++ b/src-qt5/core/libLumina/LuminaRandR.h @@ -0,0 +1,35 @@ +//=========================================== +// Lumina-DE source code +// Copyright (c) 2016, Ken Moore +// Available under the 3-clause BSD license +// See the LICENSE file for full details +//=========================================== +// This class governs all the xcb/randr interactions +// and provides simpler Qt-based functions for use elsewhere +//=========================================== + +//Qt includes +#include + +#include "xcb/randr.h" + +class outputDevice{ +public: + QString id; //output ID + bool enabled; + //Monitor Geometry + QPoint geom; //geometry of monitor within session + //Monitor Resolution + QSize cRes; //current resolution of the monitor (could be different from geom.size() if panning is enabled) + QList availRes; //available resolutions supported by the monitor + //Refresh Rate + int cHz; //current refresh rate + QList availHz; //available refresh rates + //Expand this later to include: + // panning (current/possible) + // rotation (current/possible) + + //FUNCTIONS + + //Modification +}; -- cgit From 029fa4386475732a05f89dd91e7592e65aaf1206 Mon Sep 17 00:00:00 2001 From: Ken Moore Date: Mon, 31 Oct 2016 12:25:58 -0400 Subject: Re-work the main page of the lumina-config tool Now the categories are auto-expanded, two columns of pages are used, page names are shortened, and keyboard usage has been cleaned up. --- src-qt5/core-utils/lumina-config/pages/getPage.h | 29 +++++--- .../core-utils/lumina-config/pages/page_main.cpp | 80 ++++++++++++++++------ src-qt5/core-utils/lumina-config/pages/page_main.h | 5 +- .../core-utils/lumina-config/pages/page_main.ui | 11 ++- 4 files changed, 91 insertions(+), 34 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/core-utils/lumina-config/pages/getPage.h b/src-qt5/core-utils/lumina-config/pages/getPage.h index f77a72c8..fba3998b 100644 --- a/src-qt5/core-utils/lumina-config/pages/getPage.h +++ b/src-qt5/core-utils/lumina-config/pages/getPage.h @@ -26,19 +26,30 @@ static QList KnownPages(){ // Valid Groups: ["appearance", "interface", "session", "user"] QList list; //Reminder: , , , <icon>, <comment>, <category>, <server subsytem list>, <search tags> - list << PageInfo("wallpaper", QObject::tr("Change Wallpaper"), QObject::tr("Wallpaper Settings"), "preferences-desktop-wallpaper",QObject::tr("Change background image(s)"), "appearance", QStringList(), QStringList() << "background" << "wallpaper" << "color" << "image"); - list << PageInfo("theme", QObject::tr("Change Desktop Theme"), QObject::tr("Theme Settings"), "preferences-desktop-theme",QObject::tr("Change interface fonts and colors"), "appearance", QStringList(), QStringList() << "background" << "interface" << "color" << "theme" << "plugins"); + list << PageInfo("wallpaper", QObject::tr("Wallpaper"), QObject::tr("Wallpaper Settings"), "preferences-desktop-wallpaper",QObject::tr("Change background image(s)"), "appearance", QStringList(), QStringList() << "background" << "wallpaper" << "color" << "image"); + list << PageInfo("theme", QObject::tr("Theme"), QObject::tr("Theme Settings"), "preferences-desktop-theme",QObject::tr("Change interface fonts and colors"), "appearance", QStringList(), QStringList() << "background" << "interface" << "color" << "theme" << "plugins"); list << PageInfo("compton", QObject::tr("Window Effects"), QObject::tr("Window Effects"), "window-duplicate",QObject::tr("Adjust transparency levels and window effects"), "appearance", QStringList(), QStringList() << "background" << "interface" << "color" << "transparency" << "windows" << "compositing"); - list << PageInfo("autostart", QObject::tr("Startup Services and Applications"), QObject::tr("Startup Settings"), "preferences-system-session-services",QObject::tr("Automatically start applications or services"), "session", QStringList(), QStringList() << "apps" << "autostart" << "services" << "xdg" << "startup" << "session"); - list << PageInfo("defaultapps", QObject::tr("Default Applications for File Type"), QObject::tr("Mimetype Settings"), "preferences-desktop-default-applications",QObject::tr("Change default applications"), "session", QStringList(), QStringList() << "apps" << "default" << "services" << "xdg" << "session"); + list << PageInfo("autostart", QObject::tr("Autostart"), QObject::tr("Startup Settings"), "preferences-system-session-services",QObject::tr("Automatically start applications or services"), "session", QStringList(), QStringList() << "apps" << "autostart" << "services" << "xdg" << "startup" << "session"); + list << PageInfo("defaultapps", QObject::tr("Applications"), QObject::tr("Mimetype Settings"), "preferences-desktop-default-applications",QObject::tr("Change default applications"), "session", QStringList(), QStringList() << "apps" << "default" << "services" << "xdg" << "session"); list << PageInfo("fluxbox-keys", QObject::tr("Keyboard Shortcuts"), QObject::tr("Keyboard Shortcuts"), "preferences-desktop-keyboard",QObject::tr("Change keyboard shortcuts"), "session", QStringList(), QStringList() << "apps" << "fluxbox" << "keys" << "keyboard" << "session" << "launch"); list << PageInfo("fluxbox-settings", QObject::tr("Window Manager"), QObject::tr("Window Settings"), "preferences-system-windows-actions",QObject::tr("Change window settings and appearances"), "appearance", QStringList(), QStringList() << "window" << "frame" << "border" << "workspace" << "theme" << "fluxbox" << "session"); - list << PageInfo("interface-desktop", QObject::tr("Desktop Icons and Plugins"), QObject::tr("Desktop Plugins"), "preferences-desktop-icons",QObject::tr("Change what icons or tools are embedded on the desktop"), "interface", QStringList(), QStringList() << "desktop" << "plugins" << "embed" << "icons" << "utilities"); - list << PageInfo("interface-panel", QObject::tr("Floating Panels and Plugins"), QObject::tr("Panels and Plugins"), "configure-toolbars",QObject::tr("Change any floating panels and what they show"), "interface", QStringList(), QStringList() << "desktop" << "toolbar" << "panel" << "floating" << "plugins"); - list << PageInfo("interface-menu", QObject::tr("Context Menu and Plugins"), QObject::tr("Menu Plugins"), "preferences-plugin",QObject::tr("Change what options are shown on the desktop context menu"), "interface", QStringList(), QStringList() << "desktop" << "menu" << "plugins" << "shortcuts"); - list << PageInfo("session-locale", QObject::tr("Localization Options"), QObject::tr("Locale Settings"), "preferences-desktop-locale",QObject::tr("Change the default locale settings for this user"), "user", QStringList(), QStringList() << "user"<<"locale"<<"language"<<"translations"); + list << PageInfo("interface-desktop", QObject::tr("Desktop"), QObject::tr("Desktop Plugins"), "preferences-desktop-icons",QObject::tr("Change what icons or tools are embedded on the desktop"), "interface", QStringList(), QStringList() << "desktop" << "plugins" << "embed" << "icons" << "utilities"); + list << PageInfo("interface-panel", QObject::tr("Panels"), QObject::tr("Panels and Plugins"), "configure-toolbars",QObject::tr("Change any floating panels and what they show"), "interface", QStringList(), QStringList() << "desktop" << "toolbar" << "panel" << "floating" << "plugins"); + list << PageInfo("interface-menu", QObject::tr("Menu"), QObject::tr("Menu Plugins"), "preferences-plugin",QObject::tr("Change what options are shown on the desktop context menu"), "interface", QStringList(), QStringList() << "desktop" << "menu" << "plugins" << "shortcuts"); + list << PageInfo("session-locale", QObject::tr("Localization"), QObject::tr("Locale Settings"), "preferences-desktop-locale",QObject::tr("Change the default locale settings for this user"), "user", QStringList(), QStringList() << "user"<<"locale"<<"language"<<"translations"); list << PageInfo("session-options", QObject::tr("General Options"), QObject::tr("User Settings"), "configure",QObject::tr("Change basic user settings such as time/date formats"), "user", QStringList(), QStringList() << "user"<<"settings"<<"time"<<"date"<<"icon"<<"reset"<<"numlock"<<"clock"); - return list; + + //Now sort the items according to the translated name + QStringList names; + for(int i=0; i<list.length(); i++){ names << list[i].name; } + names.sort(Qt::CaseInsensitive); + QList<PAGEINFO> sorted; + for(int i=0; i<names.length(); i++){ + for(int j=0; j<list.length(); j++){ + if(list[j].name==names[i]){ sorted << list.takeAt(j); break; } + } + } + return sorted; } //Add any sub-pages here diff --git a/src-qt5/core-utils/lumina-config/pages/page_main.cpp b/src-qt5/core-utils/lumina-config/pages/page_main.cpp index 1bdd3107..69b32c09 100644 --- a/src-qt5/core-utils/lumina-config/pages/page_main.cpp +++ b/src-qt5/core-utils/lumina-config/pages/page_main.cpp @@ -13,10 +13,12 @@ //========== page_main::page_main(QWidget *parent) : PageWidget(parent), ui(new Ui::page_main()){ ui->setupUi(this); + findShort = new QShortcut(QKeySequence(Qt::CTRL + Qt::Key_F), this, SLOT(showFind())); ui->treeWidget->setMouseTracking(true); ui->treeWidget->setSortingEnabled(false); //the QTreeView sort flag always puts them in backwards (reverse-alphabetical) - connect(ui->treeWidget, SIGNAL(itemActivated(QTreeWidgetItem*,int)), this, SLOT(itemTriggered(QTreeWidgetItem*)) ); - connect(ui->treeWidget, SIGNAL(itemClicked(QTreeWidgetItem*,int)), this, SLOT(itemTriggered(QTreeWidgetItem*)) ); + connect(ui->treeWidget, SIGNAL(itemActivated(QTreeWidgetItem*,int)), this, SLOT(itemTriggered(QTreeWidgetItem*, int)) ); + connect(ui->treeWidget, SIGNAL(itemPressed(QTreeWidgetItem*,int)), this, SLOT(itemTriggered(QTreeWidgetItem*, int)) ); + connect(ui->lineEdit, SIGNAL(textChanged(QString)), this, SLOT(searchChanged(QString)) ); } @@ -25,10 +27,15 @@ page_main::~page_main(){ } void page_main::setPreviousPage(QString id){ + if(id.isEmpty()){ return; } for(int i=0; i<ui->treeWidget->topLevelItemCount(); i++){ for(int j=0; j<ui->treeWidget->topLevelItem(i)->childCount(); j++){ if(ui->treeWidget->topLevelItem(i)->child(j)->whatsThis(0)==id){ - ui->treeWidget->setCurrentItem(ui->treeWidget->topLevelItem(i)->child(j)); + ui->treeWidget->setCurrentItem(ui->treeWidget->topLevelItem(i)->child(j), 0); + ui->treeWidget->scrollToItem(ui->treeWidget->topLevelItem(i)->child(j)); + return; //found item - done + }else if(ui->treeWidget->topLevelItem(i)->child(j)->whatsThis(1)==id){ + ui->treeWidget->setCurrentItem(ui->treeWidget->topLevelItem(i)->child(j), 1); ui->treeWidget->scrollToItem(ui->treeWidget->topLevelItem(i)->child(j)); return; //found item - done } @@ -39,19 +46,24 @@ void page_main::setPreviousPage(QString id){ void page_main::UpdateItems(QString search){ ui->treeWidget->clear(); + ui->treeWidget->setColumnCount(2); //First create the categories QTreeWidgetItem *interface = new QTreeWidgetItem(); interface->setIcon(0, LXDG::findIcon("preferences-desktop","")); interface->setText(0, tr("Interface Configuration")); + interface->setFirstColumnSpanned(true); QTreeWidgetItem *appearance = new QTreeWidgetItem(); appearance->setIcon(0, LXDG::findIcon("preferences-desktop-color","")); appearance->setText(0, tr("Appearance")); + appearance->setFirstColumnSpanned(true); QTreeWidgetItem *session = new QTreeWidgetItem(); session->setIcon(0, LXDG::findIcon("preferences-system-session-services","")); - session->setText(0, tr("Desktop Session Options")); + session->setText(0, tr("Desktop Defaults")); + session->setFirstColumnSpanned(true); QTreeWidgetItem *user = new QTreeWidgetItem(); user->setIcon(0, LXDG::findIcon("preferences-desktop-user","")); user->setText(0, tr("User Settings")); + user->setFirstColumnSpanned(true); //Now go through and add in the known pages for each category QStringList SL = search.split(" "); //search list for(int i=0; i<INFO.length(); i++){ @@ -66,24 +78,40 @@ void page_main::UpdateItems(QString search){ if(!ok){ continue; } //no duplicates between search terms and available info } //qDebug() << "Item Found:" << INFO[i].id << INFO[i].title; - QTreeWidgetItem *it = new QTreeWidgetItem(); - it->setIcon(0, LXDG::findIcon(INFO[i].icon,"") ); - it->setText(0, INFO[i].name); - it->setStatusTip(0, INFO[i].comment); - it->setToolTip(0, INFO[i].comment); - it->setWhatsThis(0, INFO[i].id); - if(INFO[i].category=="interface"){ interface->addChild(it); } - else if(INFO[i].category=="appearance"){ appearance->addChild(it); } - else if(INFO[i].category=="session"){ session->addChild(it); } - else if(INFO[i].category=="user"){ user->addChild(it); } - else{ ui->treeWidget->addTopLevelItem(it); } + int col = 0; + QTreeWidgetItem *lastIt = 0; + if(INFO[i].category=="interface" && interface->childCount()>0 ){ + if( interface->child( interface->childCount()-1)->text(1).isEmpty() ){ lastIt = interface->child(interface->childCount()-1); } + }else if(INFO[i].category=="appearance" && appearance->childCount()>0 ){ + if( appearance->child(appearance->childCount()-1)->text(1).isEmpty() ){ lastIt = appearance->child(appearance->childCount()-1); } + }else if(INFO[i].category=="session" && session->childCount()>0 ){ + if( session->child( session->childCount()-1)->text(1).isEmpty() ){ lastIt = session->child(session->childCount()-1); } + }else if(INFO[i].category=="user" && user->childCount()>0 ){ + if( user->child( user->childCount()-1)->text(1).isEmpty() ){ lastIt = user->child(user->childCount()-1); } + } + if(lastIt==0){ lastIt = new QTreeWidgetItem(); col = 0;} + else{ col = 1; } + lastIt->setIcon(col, LXDG::findIcon(INFO[i].icon,"") ); + lastIt->setText(col, INFO[i].name); + lastIt->setStatusTip(col, INFO[i].comment); + lastIt->setToolTip(col, INFO[i].comment); + lastIt->setWhatsThis(col, INFO[i].id); + if(col==0){ + if(INFO[i].category=="interface"){ interface->addChild(lastIt); } + else if(INFO[i].category=="appearance"){ appearance->addChild(lastIt); } + else if(INFO[i].category=="session"){ session->addChild(lastIt); } + else if(INFO[i].category=="user"){ user->addChild(lastIt); } + else{ ui->treeWidget->addTopLevelItem(lastIt); } + } } //Now add the categories to the tree widget if they are non-empty - if(interface->childCount()>0){ ui->treeWidget->addTopLevelItem(interface); interface->setExpanded(!search.isEmpty()); } - if(appearance->childCount()>0){ ui->treeWidget->addTopLevelItem(appearance); appearance->setExpanded(!search.isEmpty()); } - if(session->childCount()>0){ ui->treeWidget->addTopLevelItem(session); session->setExpanded(!search.isEmpty()); } - if(user->childCount()>0){ ui->treeWidget->addTopLevelItem(user); user->setExpanded(!search.isEmpty()); } + if(interface->childCount()>0){ ui->treeWidget->addTopLevelItem(interface); interface->setExpanded(true); } + if(appearance->childCount()>0){ ui->treeWidget->addTopLevelItem(appearance); appearance->setExpanded(true); } + if(session->childCount()>0){ ui->treeWidget->addTopLevelItem(session); session->setExpanded(true); } + if(user->childCount()>0){ ui->treeWidget->addTopLevelItem(user); user->setExpanded(true); } ui->treeWidget->sortItems(0, Qt::AscendingOrder); + ui->treeWidget->resizeColumnToContents(0); + ui->treeWidget->resizeColumnToContents(1); } //================ @@ -109,11 +137,19 @@ void page_main::updateIcons(){ //================= // PRIVATE SLOTS //================= -void page_main::itemTriggered(QTreeWidgetItem *it){ +void page_main::showFind(){ + ui->lineEdit->setFocus(); + ui->treeWidget->setCurrentItem(0); +} + +void page_main::itemTriggered(QTreeWidgetItem *it, int col){ if(it->childCount()>0){ it->setExpanded( !it->isExpanded() ); - }else if(!it->whatsThis(0).isEmpty()){ - emit ChangePage(it->whatsThis(0)); + it->setSelected(false); + }else if(!it->whatsThis(col).isEmpty()){ + emit ChangePage(it->whatsThis(col)); + }else{ + it->setSelected(false); } } diff --git a/src-qt5/core-utils/lumina-config/pages/page_main.h b/src-qt5/core-utils/lumina-config/pages/page_main.h index 7c7539a3..e4bfeafd 100644 --- a/src-qt5/core-utils/lumina-config/pages/page_main.h +++ b/src-qt5/core-utils/lumina-config/pages/page_main.h @@ -29,11 +29,12 @@ public slots: private: Ui::page_main *ui; QList<PAGEINFO> INFO; - + QShortcut *findShort; void UpdateItems(QString search); private slots: - void itemTriggered(QTreeWidgetItem*); + void showFind(); + void itemTriggered(QTreeWidgetItem*, int); void searchChanged(QString); }; #endif diff --git a/src-qt5/core-utils/lumina-config/pages/page_main.ui b/src-qt5/core-utils/lumina-config/pages/page_main.ui index 2331152b..34033d39 100644 --- a/src-qt5/core-utils/lumina-config/pages/page_main.ui +++ b/src-qt5/core-utils/lumina-config/pages/page_main.ui @@ -36,7 +36,7 @@ <item> <widget class="QTreeWidget" name="treeWidget"> <property name="focusPolicy"> - <enum>Qt::NoFocus</enum> + <enum>Qt::TabFocus</enum> </property> <property name="styleSheet"> <string notr="true">QTreeWidget{background: transparent; }</string> @@ -44,6 +44,15 @@ <property name="editTriggers"> <set>QAbstractItemView::DoubleClicked|QAbstractItemView::EditKeyPressed|QAbstractItemView::SelectedClicked</set> </property> + <property name="tabKeyNavigation"> + <bool>true</bool> + </property> + <property name="showDropIndicator" stdset="0"> + <bool>false</bool> + </property> + <property name="selectionBehavior"> + <enum>QAbstractItemView::SelectItems</enum> + </property> <property name="iconSize"> <size> <width>32</width> -- cgit From efbf100822f8a50abdcfb061b7b1bf1be06b868c Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Tue, 1 Nov 2016 08:22:38 -0400 Subject: Another update to the calculator: 1) Add buttons to clear/save the history (saves as plaintext to a file) 2) Tag each result with a number (#1), and allow the usage of #<number> to recall a history item 3) When recalling history, see if the result looks like it was rounded using the double->text routine for display. If so, substitute the equation, otherwise just use the result (tries to ensure no rounding error-continuity by using previous results). --- .../desktop-utils/lumina-calculator/EqValidator.h | 6 +-- src-qt5/desktop-utils/lumina-calculator/mainUI.cpp | 55 ++++++++++++++++++++-- src-qt5/desktop-utils/lumina-calculator/mainUI.h | 3 ++ src-qt5/desktop-utils/lumina-calculator/mainUI.ui | 55 ++++++++++++++++++---- 4 files changed, 102 insertions(+), 17 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/desktop-utils/lumina-calculator/EqValidator.h b/src-qt5/desktop-utils/lumina-calculator/EqValidator.h index 8218efdf..ab9bcc22 100644 --- a/src-qt5/desktop-utils/lumina-calculator/EqValidator.h +++ b/src-qt5/desktop-utils/lumina-calculator/EqValidator.h @@ -7,10 +7,10 @@ #ifndef _LUMINA_CALCULATOR_VALIDATOR_H #define _LUMINA_CALCULATOR_VALIDATOR_H -#define VALIDCHARS QString("x*+-/^%eE().0123456789") +#define VALIDCHARS QString("x*+-/^%eE().0123456789#") #define NOSTARTCHARS QString("x*/^%)eE.") -#define NOENDCHARS QString("x*/^(eE.") -#define NOCHANGE QString("().") +#define NOENDCHARS QString("x*/^(eE.#") +#define NOCHANGE QString("().#") #include <QValidator> #include <QString> diff --git a/src-qt5/desktop-utils/lumina-calculator/mainUI.cpp b/src-qt5/desktop-utils/lumina-calculator/mainUI.cpp index b26acb73..2f38abae 100644 --- a/src-qt5/desktop-utils/lumina-calculator/mainUI.cpp +++ b/src-qt5/desktop-utils/lumina-calculator/mainUI.cpp @@ -9,7 +9,9 @@ #include <QDebug> #include <QClipboard> +#include <QFileDialog> +#include <LuminaUtils.h> #include <LuminaXDG.h> #include "EqValidator.h" @@ -41,6 +43,8 @@ mainUI::mainUI() : QMainWindow(), ui(new Ui::mainUI()){ connect(ui->button_Percent, SIGNAL(clicked()), this, SLOT(captureButtonPercent()) ); connect(ui->button_Equal, SIGNAL (clicked()), this, SLOT (start_calc())); connect(ui->list_results, SIGNAL(itemClicked(QListWidgetItem*)), this, SLOT(insert_history(QListWidgetItem*)) ); + connect(ui->tool_history_clear, SIGNAL(clicked()), ui->list_results, SLOT(clear()) ); + connect(ui->tool_history_save, SIGNAL(clicked()), this, SLOT(saveHistory()) ); //connect(ui->list_results, SIGNAL(itemRightClicked(QListWidgetItem*)), this, SLOT(copt_to_clipboard(QListWidgetItem*)) ); this->setWindowTitle(tr("Calculator")); updateIcons(); @@ -54,6 +58,8 @@ mainUI::~mainUI(){ void mainUI::updateIcons(){ this->setWindowIcon( LXDG::findIcon("accessories-calculator","") ); ui->tool_clear->setIcon( LXDG::findIcon("edit-clear-locationbar-rtl","dialog-cancel") ); + ui->tool_history_clear->setIcon( LXDG::findIcon("document-close","edit-clear-list") ); + ui->tool_history_save->setIcon( LXDG::findIcon("document-save-as","edit-copy") ); } void mainUI::start_calc(){ @@ -62,8 +68,8 @@ void mainUI::start_calc(){ eq.replace("%","/(100)"); double result = strToNumber(eq); if(result!=result){ return; } //bad calculation - NaN's values are special in that they don't equal itself - QString res = "%1 \t= [ %2 ]"; - ui->list_results->addItem(res.arg(QString::number(result), ui->line_eq->text())); + QString res = "[#%1] %2 \t= [ %3 ]"; + ui->list_results->addItem(res.arg(QString::number(ui->list_results->count()+1), QString::number(result), ui->line_eq->text())); ui->list_results->scrollToItem( ui->list_results->item( ui->list_results->count()-1) ); ui->line_eq->clear(); } @@ -92,7 +98,7 @@ void mainUI::captureButtonDecimal(){ ui->line_eq->insert(ui->button_Decimal->tex void mainUI::captureButtonPercent(){ ui->line_eq->insert(ui->button_Percent->text()); } void mainUI::insert_history(QListWidgetItem *it){ - QString txt = it->text().section("[",1,-1).section("]",0,0).simplified(); + QString txt = it->text().section("[",-1).section("]",0,0).simplified(); ui->line_eq->insert("("+txt+")"); } @@ -104,12 +110,20 @@ void mainUI::copy_to_clipboard(QListWidgetItem *it){ void mainUI::checkInput(const QString &str){ if(str.length()==1 && ui->list_results->count()>0){ if(OPS.contains(str)){ - QString lastresult = ui->list_results->item( ui->list_results->count()-1)->text().section("=",0,0).simplified(); + QString lastresult = ui->list_results->item( ui->list_results->count()-1)->text().section("]",0,0).section("[",-1).simplified(); ui->line_eq->setText( lastresult+str); } } } +void mainUI::saveHistory(){ + QStringList history; + for(int i=0; i<ui->list_results->count(); i++){ history << ui->list_results->item(i)->text(); } + QString file = QFileDialog::getSaveFileName(this, tr("Save Calculator History"), QDir::homePath() ); + if(file.section(".",-1).isEmpty()){ file.append(".txt"); } + LUtils::writeFile(file, history, true); +} + // ===================== // PRIVATE FUNCTIONS // ===================== @@ -126,6 +140,23 @@ double mainUI::performOperation(double LHS, double RHS, QChar symbol){ } double mainUI::strToNumber(QString str){ + //Look for history replacements first + while(str.contains("#")){ + int index = str.indexOf("#"); + int num = -1; //history number + for(int i=index+1; i<str.length(); i++){ + if(!str[i].isNumber() || i==(str.length()-1) ){ + if(!str[i].isNumber()){ i--; } //go back to the last valid char + //qDebug() << "Replace History:" << str << index << i << str.mid(index+1, i-index); + num = str.mid(index+1, i-index).toInt(); + //qDebug() << " H number:" << num; + str.replace(index, i-index+1, getHistory(num)); + //qDebug() << " After Replace:" << str; + break; //finished with this history item + } + } + if(num<1){ return BADVALUE; } //could not perform substitution + } //Look for perentheses first //qDebug() << "String to Number: " << str; if(str.indexOf("(")>=0){ @@ -177,3 +208,19 @@ double mainUI::strToNumber(QString str){ //qDebug() << " - Found Number:" << str << str.toDouble(); return str.toDouble(); } + +QString mainUI::getHistory(int number){ + if(number <1 || number > ui->list_results->count()){ + //use the last history item + number = ui->list_results->count(); + } + QString ans = ui->list_results->item(number-1)->text().section("=",0,0).section("]",-1).simplified(); + QString eq = ui->list_results->item(number-1)->text().section("[",-1).section("]",0,0).simplified(); + //See if the text answer is accurate enough (does not look rounded) + if(ans.length()<7){ + return ("("+ans+")"); //short enough answer that it was probably not rounded + }else{ + //need to re-calculate the last equation instead for exact result + return ("("+eq+")"); + } +} diff --git a/src-qt5/desktop-utils/lumina-calculator/mainUI.h b/src-qt5/desktop-utils/lumina-calculator/mainUI.h index cf09801e..9dc28f3c 100644 --- a/src-qt5/desktop-utils/lumina-calculator/mainUI.h +++ b/src-qt5/desktop-utils/lumina-calculator/mainUI.h @@ -50,9 +50,12 @@ private slots: void copy_to_clipboard(QListWidgetItem *it); void checkInput(const QString&); + void saveHistory(); + private: Ui::mainUI *ui; double performOperation(double LHS, double RHS, QChar symbol); double strToNumber(QString str); //this is highly-recursive + QString getHistory(int number = -1); }; #endif diff --git a/src-qt5/desktop-utils/lumina-calculator/mainUI.ui b/src-qt5/desktop-utils/lumina-calculator/mainUI.ui index 7a0ccfed..4ff5c421 100644 --- a/src-qt5/desktop-utils/lumina-calculator/mainUI.ui +++ b/src-qt5/desktop-utils/lumina-calculator/mainUI.ui @@ -6,8 +6,8 @@ <rect> <x>0</x> <y>0</y> - <width>171</width> - <height>258</height> + <width>204</width> + <height>260</height> </rect> </property> <property name="windowTitle"> @@ -50,14 +50,49 @@ <widget class="QWidget" name="layoutWidget"> <layout class="QVBoxLayout" name="verticalLayout"> <item> - <widget class="QListWidget" name="list_results"> - <property name="focusPolicy"> - <enum>Qt::NoFocus</enum> - </property> - <property name="selectionMode"> - <enum>QAbstractItemView::NoSelection</enum> - </property> - </widget> + <layout class="QHBoxLayout" name="horizontalLayout_2"> + <item> + <widget class="QListWidget" name="list_results"> + <property name="focusPolicy"> + <enum>Qt::NoFocus</enum> + </property> + <property name="selectionMode"> + <enum>QAbstractItemView::NoSelection</enum> + </property> + </widget> + </item> + <item> + <layout class="QVBoxLayout" name="verticalLayout_3"> + <item> + <widget class="QToolButton" name="tool_history_clear"> + <property name="text"> + <string notr="true"/> + </property> + </widget> + </item> + <item> + <widget class="QToolButton" name="tool_history_save"> + <property name="text"> + <string notr="true"/> + </property> + </widget> + </item> + <item> + <spacer name="verticalSpacer"> + <property name="orientation"> + <enum>Qt::Vertical</enum> + </property> + <property name="sizeHint" stdset="0"> + <size> + <width>20</width> + <height>40</height> + </size> + </property> + </spacer> + </item> + </layout> + </item> + </layout> </item> <item> <layout class="QHBoxLayout" name="horizontalLayout"> -- cgit From e5ef2110e9d73a119732a6f6545e328432c842e5 Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Tue, 1 Nov 2016 12:26:17 -0400 Subject: Add in a ton of scientific mathematical functions to the calculator. --- .../desktop-utils/lumina-calculator/EqValidator.h | 2 +- src-qt5/desktop-utils/lumina-calculator/mainUI.cpp | 124 +++++++++++++++++++-- src-qt5/desktop-utils/lumina-calculator/mainUI.h | 8 +- src-qt5/desktop-utils/lumina-calculator/mainUI.ui | 12 +- 4 files changed, 133 insertions(+), 13 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/desktop-utils/lumina-calculator/EqValidator.h b/src-qt5/desktop-utils/lumina-calculator/EqValidator.h index ab9bcc22..8bceb240 100644 --- a/src-qt5/desktop-utils/lumina-calculator/EqValidator.h +++ b/src-qt5/desktop-utils/lumina-calculator/EqValidator.h @@ -7,7 +7,7 @@ #ifndef _LUMINA_CALCULATOR_VALIDATOR_H #define _LUMINA_CALCULATOR_VALIDATOR_H -#define VALIDCHARS QString("x*+-/^%eE().0123456789#") +#define VALIDCHARS QString("x*+-/^%eE().0123456789#acosinthqrlog\u03C0") #define NOSTARTCHARS QString("x*/^%)eE.") #define NOENDCHARS QString("x*/^(eE.#") #define NOCHANGE QString("().#") diff --git a/src-qt5/desktop-utils/lumina-calculator/mainUI.cpp b/src-qt5/desktop-utils/lumina-calculator/mainUI.cpp index 2f38abae..3da9ba6d 100644 --- a/src-qt5/desktop-utils/lumina-calculator/mainUI.cpp +++ b/src-qt5/desktop-utils/lumina-calculator/mainUI.cpp @@ -20,8 +20,12 @@ #define OPS QString("+-*/x^%") + +const double PI = (::acos(1.0)+::acos(-1.0)); + mainUI::mainUI() : QMainWindow(), ui(new Ui::mainUI()){ ui->setupUi(this); + advMenu = 0; connect(ui->tool_clear, SIGNAL(clicked()), this, SLOT(clear_calc()) ); connect(ui->line_eq, SIGNAL(returnPressed()), this, SLOT(start_calc()) ); connect(ui->line_eq, SIGNAL(textEdited(const QString&)), this, SLOT(checkInput(const QString&)) ); @@ -40,7 +44,6 @@ mainUI::mainUI() : QMainWindow(), ui(new Ui::mainUI()){ connect(ui->button_Divide, SIGNAL (clicked()), this, SLOT (captureButtonDivide())); connect(ui->button_Multiply, SIGNAL (clicked()), this, SLOT (captureButtonMultiply())); connect(ui->button_Decimal, SIGNAL (clicked()), this, SLOT (captureButtonDecimal())); - connect(ui->button_Percent, SIGNAL(clicked()), this, SLOT(captureButtonPercent()) ); connect(ui->button_Equal, SIGNAL (clicked()), this, SLOT (start_calc())); connect(ui->list_results, SIGNAL(itemClicked(QListWidgetItem*)), this, SLOT(insert_history(QListWidgetItem*)) ); connect(ui->tool_history_clear, SIGNAL(clicked()), ui->list_results, SLOT(clear()) ); @@ -48,6 +51,7 @@ mainUI::mainUI() : QMainWindow(), ui(new Ui::mainUI()){ //connect(ui->list_results, SIGNAL(itemRightClicked(QListWidgetItem*)), this, SLOT(copt_to_clipboard(QListWidgetItem*)) ); this->setWindowTitle(tr("Calculator")); updateIcons(); + updateMenus(); ui->line_eq->setFocus(); ui->line_eq->setValidator(new EqValidator(this) ); } @@ -60,6 +64,53 @@ void mainUI::updateIcons(){ ui->tool_clear->setIcon( LXDG::findIcon("edit-clear-locationbar-rtl","dialog-cancel") ); ui->tool_history_clear->setIcon( LXDG::findIcon("document-close","edit-clear-list") ); ui->tool_history_save->setIcon( LXDG::findIcon("document-save-as","edit-copy") ); + ui->tool_adv->setIcon( LXDG::findIcon("formula","") ); +} + +void mainUI::updateMenus(){ + if(advMenu==0){ + advMenu = new QMenu(this); + ui->tool_adv->setMenu(advMenu); + connect(advMenu, SIGNAL(triggered(QAction*)), this, SLOT(advMenuTriggered(QAction*)) ); + } + QAction *tmp = advMenu->addAction( QString(tr("Percentage %1")).arg("\t%") ); + tmp->setWhatsThis("%"); + tmp = advMenu->addAction( QString(tr("Power %1")).arg("\t^") ); + tmp->setWhatsThis("^"); + tmp = advMenu->addAction( QString(tr("Base-10 Exponential %1")).arg("\tE") ); + tmp->setWhatsThis("E"); + tmp = advMenu->addAction( QString(tr("Exponential %1")).arg("\te") ); + tmp->setWhatsThis("e"); + tmp = advMenu->addAction( QString(tr("Constant Pi %1")).arg("\t\u03C0") ); + tmp->setWhatsThis("\u03C0"); + advMenu->addSeparator(); + tmp = advMenu->addAction( QString(tr("Square Root %1")).arg("\tsqrt(") ); + tmp->setWhatsThis("sqrt("); + tmp = advMenu->addAction( QString(tr("Logarithm %1")).arg("\tlog(") ); + tmp->setWhatsThis("log("); + tmp = advMenu->addAction( QString(tr("Natural Log %1")).arg("\tln(") ); + tmp->setWhatsThis("ln("); + advMenu->addSeparator(); + tmp = advMenu->addAction( QString(tr("Sine %1")).arg("\tsin(") ); + tmp->setWhatsThis("sin("); + tmp = advMenu->addAction( QString(tr("Cosine %1")).arg("\tcos(") ); + tmp->setWhatsThis("cos("); + tmp = advMenu->addAction( QString(tr("Tangent %1")).arg("\ttan(") ); + tmp->setWhatsThis("tan("); + advMenu->addSeparator(); + tmp = advMenu->addAction( QString(tr("Arc Sine %1")).arg("\tasin(") ); + tmp->setWhatsThis("asin("); + tmp = advMenu->addAction( QString(tr("Arc Cosine %1")).arg("\tacos(") ); + tmp->setWhatsThis("acos("); + tmp = advMenu->addAction( QString(tr("Arc Tangent %1")).arg("\tatan(") ); + tmp->setWhatsThis("atan("); + advMenu->addSeparator(); + tmp = advMenu->addAction( QString(tr("Hyperbolic Sine %1")).arg("\tsinh(") ); + tmp->setWhatsThis("sinh("); + tmp = advMenu->addAction( QString(tr("Hyperbolic Cosine %1")).arg("\tcosh(") ); + tmp->setWhatsThis("cosh("); + tmp = advMenu->addAction( QString(tr("Hyperbolic Tangent %1")).arg("\ttanh(") ); + tmp->setWhatsThis("tanh("); } void mainUI::start_calc(){ @@ -69,7 +120,7 @@ void mainUI::start_calc(){ double result = strToNumber(eq); if(result!=result){ return; } //bad calculation - NaN's values are special in that they don't equal itself QString res = "[#%1] %2 \t= [ %3 ]"; - ui->list_results->addItem(res.arg(QString::number(ui->list_results->count()+1), QString::number(result), ui->line_eq->text())); + ui->list_results->addItem(res.arg(QString::number(ui->list_results->count()+1), QString::number(result, 'G'), ui->line_eq->text())); ui->list_results->scrollToItem( ui->list_results->item( ui->list_results->count()-1) ); ui->line_eq->clear(); } @@ -93,10 +144,12 @@ void mainUI::captureButtonSubtract(){ ui->line_eq->insert(ui->button_Subtract->t void mainUI::captureButtonAdd(){ ui->line_eq->insert(ui->button_Add->text()); } void mainUI::captureButtonDivide(){ ui->line_eq->insert(ui->button_Divide->text()); } void mainUI::captureButtonMultiply(){ ui->line_eq->insert(ui->button_Multiply->text()); } -//void mainUI::captureButtonEqual(){ ui->line_eq->setText(ui->line_eq->text() += ui->button_Equal->text()); } void mainUI::captureButtonDecimal(){ ui->line_eq->insert(ui->button_Decimal->text()); } -void mainUI::captureButtonPercent(){ ui->line_eq->insert(ui->button_Percent->text()); } +void mainUI::advMenuTriggered(QAction *act){ + if(act->whatsThis().isEmpty()){ return; } + ui->line_eq->insert(act->whatsThis()); +} void mainUI::insert_history(QListWidgetItem *it){ QString txt = it->text().section("[",-1).section("]",0,0).simplified(); ui->line_eq->insert("("+txt+")"); @@ -134,12 +187,42 @@ double mainUI::performOperation(double LHS, double RHS, QChar symbol){ else if(symbol== '*' || symbol=='x'){ return (LHS*RHS); } else if(symbol== '/'){ return (LHS/RHS); } else if(symbol== '^'){ return ::pow(LHS, RHS); } + else if(symbol=='e'){ return (LHS * ::exp(RHS) ); } //else if(symbol== '%'){ return (LHS%RHS); } qDebug() << "Invalid Symbol:" << symbol; return BADVALUE; } +double mainUI::performSciOperation(QString func, double arg){ + //This function is for performing calculations of scientific functions "<function>(<arg>)" + //qDebug() << "Perform Sci Op:" << func << arg; + double res; + if(func=="ln"){ return ::log(arg); } + else if(func=="log"){ return ::log10(arg); } + else if(func=="sqrt"){ return ::sqrt(arg); } + else if(func=="sin"){ res = ::sin(arg); } //needs rounding check + else if(func=="cos"){ res = ::cos(arg); } //needs rounding check + else if(func=="tan"){ return ::tan(arg); } + else if(func=="asin"){ return ::asin(arg); } + else if(func=="acos"){ return ::acos(arg); } + else if(func=="atan"){ return ::atan(arg); } + else if(func=="sinh"){ return ::sinh(arg); } + else if(func=="cosh"){ return ::cosh(arg); } + else if(func=="tanh"){ return ::tanh(arg); } + else{ + qDebug() << "Unknown Scientific Function:" << func; + return BADVALUE; + } + //Special cases: + // Check for whether "PI" was input as an argument (in some form) and round off the answer as needed + // since PI is itself a rounded number + if(res < 0.000000000000001){ return 0; } + return res; +} + + double mainUI::strToNumber(QString str){ + //qDebug() << "String To Number:" << str; //Look for history replacements first while(str.contains("#")){ int index = str.indexOf("#"); @@ -174,7 +257,19 @@ double mainUI::strToNumber(QString str){ //qDebug() << "Replace value:" << str << start << end << str.mid(start+1,end-start); double tmp = strToNumber( str.mid(start+1, end-start-1)); if(tmp!=tmp){ return BADVALUE; } //not a number - str.replace(start, end-start+1, QString::number( tmp, 'e', 16) ); //need as high precision as possible here - internal only, never seen + //Now check really quick if this was an argument to a scientific operation + for(int i=start-1; i>=0; i-- ){ + if( !str[i].isLower() || i==0 ){ + if(!str[i].isLower()){ i++; }//don't need the invalid character + if(start-i<2){ continue; } //not long enough - 2+ chars for sci functions + //Got a scientific operation - run it through the routine + tmp = performSciOperation( str.mid(i, start-i), tmp); + if(tmp!=tmp){ return BADVALUE; } //got a bad value + start = i; //new start point for the replacement + break; + } + } + str.replace(start, end-start+1, QString::number( tmp, 'E', 16) ); //need as high precision as possible here - internal only, never seen //qDebug() << "Replaced:" << str; } // ------------------------------------- @@ -196,7 +291,7 @@ double mainUI::strToNumber(QString str){ if(sym>0){ return performOperation( strToNumber(str.left(sym)), strToNumber(str.right(str.length()-sym-1)), str[sym]); } if(sym==0){ return BADVALUE; } //Now look for multiply/divide/power - symbols.clear(); symbols << "x" << "*" << "/" << "^" ; + symbols.clear(); symbols << "x" << "*" << "/" << "^" << "e"; for(int i=0; i<symbols.length(); i++){ int tmp = str.indexOf(symbols[i]); if(sym < tmp){ sym = tmp; } @@ -205,7 +300,22 @@ double mainUI::strToNumber(QString str){ if(sym==0){ return BADVALUE; } //Could not find any operations - must be a raw number - //qDebug() << " - Found Number:" << str << str.toDouble(); + //qDebug() << " - Found Number:" << str;// << str.toDouble(); + if(str=="\u03C0"){ return PI; } + //else if(str.endsWith("\u03C0")){ + //return performOperation( strToNumber(str.section("\u03C0",0,-2)), PI, '*'); + else if(str.contains("\u03C0")){ + qDebug() << " Has Pi:" << str.count("\u03C0"); + //Pi is mixed into the number - need to multiply it all out + double res = 1; + QStringList vals = str.split("\u03C0", QString::SkipEmptyParts); + for(int i=0; i<vals.length(); i++){ res = res * strToNumber(vals[i]); } + //Now multiply in the PI's + for(int i=0; i<str.count("\u03C0"); i++){ + res = res * PI; + } + return res; + } return str.toDouble(); } diff --git a/src-qt5/desktop-utils/lumina-calculator/mainUI.h b/src-qt5/desktop-utils/lumina-calculator/mainUI.h index 9dc28f3c..f05365f3 100644 --- a/src-qt5/desktop-utils/lumina-calculator/mainUI.h +++ b/src-qt5/desktop-utils/lumina-calculator/mainUI.h @@ -24,6 +24,7 @@ public: public slots: void updateIcons(); + void updateMenus(); private slots: void start_calc(); @@ -42,9 +43,9 @@ private slots: void captureButtonAdd(); void captureButtonDivide(); void captureButtonMultiply(); -// void captureButtonEqual(); void captureButtonDecimal(); - void captureButtonPercent(); + + void advMenuTriggered(QAction *act); void insert_history(QListWidgetItem *it); void copy_to_clipboard(QListWidgetItem *it); @@ -54,7 +55,10 @@ private slots: private: Ui::mainUI *ui; + QMenu *advMenu; + double performOperation(double LHS, double RHS, QChar symbol); + double performSciOperation(QString func, double arg); double strToNumber(QString str); //this is highly-recursive QString getHistory(int number = -1); }; diff --git a/src-qt5/desktop-utils/lumina-calculator/mainUI.ui b/src-qt5/desktop-utils/lumina-calculator/mainUI.ui index 4ff5c421..a5369f64 100644 --- a/src-qt5/desktop-utils/lumina-calculator/mainUI.ui +++ b/src-qt5/desktop-utils/lumina-calculator/mainUI.ui @@ -6,7 +6,7 @@ <rect> <x>0</x> <y>0</y> - <width>204</width> + <width>255</width> <height>260</height> </rect> </property> @@ -625,7 +625,7 @@ </widget> </item> <item row="0" column="0"> - <widget class="QPushButton" name="button_Percent"> + <widget class="QToolButton" name="tool_adv"> <property name="sizePolicy"> <sizepolicy hsizetype="Preferred" vsizetype="Preferred"> <horstretch>0</horstretch> @@ -653,8 +653,14 @@ <property name="focusPolicy"> <enum>Qt::NoFocus</enum> </property> + <property name="toolTip"> + <string>Advanced Operations</string> + </property> <property name="text"> - <string>%</string> + <string notr="true">Adv</string> + </property> + <property name="popupMode"> + <enum>QToolButton::InstantPopup</enum> </property> </widget> </item> -- cgit From b486021b3dab405161082dbbd0b862a7da0e4c0c Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Wed, 2 Nov 2016 09:41:07 -0400 Subject: Add a new sessionsettings flag: Qt5_theme_engine=<some theme engine> This will allow the user to set some global Qt5 theme engine (such as qt5ct), and activate it for the entire session. --- src-qt5/core/lumina-desktop/LSession.cpp | 29 +++++++++++++++++++++-------- 1 file changed, 21 insertions(+), 8 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/core/lumina-desktop/LSession.cpp b/src-qt5/core/lumina-desktop/LSession.cpp index 8c8562d4..87f270ea 100644 --- a/src-qt5/core/lumina-desktop/LSession.cpp +++ b/src-qt5/core/lumina-desktop/LSession.cpp @@ -150,13 +150,17 @@ void LSession::setupSession(){ if(DEBUG){ qDebug() << " - Init QFileSystemWatcher:" << timer->elapsed();} watcher = new QFileSystemWatcher(this); QString confdir = sessionsettings->fileName().section("/",0,-2); - watcher->addPath( sessionsettings->fileName() ); - watcher->addPath( confdir+"/desktopsettings.conf" ); - watcher->addPath( confdir+"/fluxbox-init" ); - watcher->addPath( confdir+"/fluxbox-keys" ); + watcherChange(sessionsettings->fileName() ); + watcherChange( confdir+"/desktopsettings.conf" ); + watcherChange( confdir+"/fluxbox-init" ); + watcherChange( confdir+"/fluxbox-keys" ); + //watcher->addPath( sessionsettings->fileName() ); + //watcher->addPath( confdir+"/desktopsettings.conf" ); + //watcher->addPath( confdir+"/fluxbox-init" ); + //watcher->addPath( confdir+"/fluxbox-keys" ); //Try to watch the localized desktop folder too - if(QFile::exists(QDir::homePath()+"/"+tr("Desktop"))){ watcher->addPath( QDir::homePath()+"/"+tr("Desktop") ); } - watcher->addPath( QDir::homePath()+"/Desktop" ); + if(QFile::exists(QDir::homePath()+"/"+tr("Desktop"))){ watcherChange( QDir::homePath()+"/"+tr("Desktop") ); } + watcherChange( QDir::homePath()+"/Desktop" ); //connect internal signals/slots //connect(this->desktop(), SIGNAL(screenCountChanged(int)), this, SLOT(screensChanged()) ); @@ -321,8 +325,17 @@ void LSession::reloadIconTheme(){ void LSession::watcherChange(QString changed){ if(DEBUG){ qDebug() << "Session Watcher Change:" << changed; } //if(changed.endsWith("fluxbox-init") || changed.endsWith("fluxbox-keys")){ refreshWindowManager(); } - if(changed.endsWith("sessionsettings.conf") ){ sessionsettings->sync(); emit SessionConfigChanged(); } - else if(changed.endsWith("desktopsettings.conf") ){ emit DesktopConfigChanged(); } + if(changed.endsWith("sessionsettings.conf") ){ + sessionsettings->sync(); + //qDebug() << "Session Settings Changed"; + if(sessionsettings->contains("Qt5_theme_engine")){ + QString engine = sessionsettings->value("Qt5_theme_engine","").toString(); + //qDebug() << "Set Qt5 theme engine: " << engine; + if(engine.isEmpty()){ unsetenv("QT_QPA_PLATFORMTHEME"); } + else{ setenv("QT_QPA_PLATFORMTHEME", engine.toUtf8().data(),1); } + } + emit SessionConfigChanged(); + }else if(changed.endsWith("desktopsettings.conf") ){ emit DesktopConfigChanged(); } else if(changed == QDir::homePath()+"/Desktop" || changed == QDir::homePath()+"/"+tr("Desktop") ){ desktopFiles = QDir(changed).entryInfoList(QDir::NoDotAndDotDot | QDir::Files | QDir::Dirs ,QDir::Name | QDir::IgnoreCase | QDir::DirsFirst); if(DEBUG){ qDebug() << "New Desktop Files:" << desktopFiles.length(); } -- cgit From 6fc4e0d28202a1d7b51ab64ccd4438508440ec6d Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Wed, 2 Nov 2016 11:01:16 -0400 Subject: Add the new Qt5 theme engine setting to lumina-config. --- .../core-utils/lumina-config/pages/page_theme.cpp | 48 ++- .../core-utils/lumina-config/pages/page_theme.h | 3 + .../core-utils/lumina-config/pages/page_theme.ui | 334 ++++++++++++--------- 3 files changed, 236 insertions(+), 149 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/core-utils/lumina-config/pages/page_theme.cpp b/src-qt5/core-utils/lumina-config/pages/page_theme.cpp index 123812a1..0d946e81 100644 --- a/src-qt5/core-utils/lumina-config/pages/page_theme.cpp +++ b/src-qt5/core-utils/lumina-config/pages/page_theme.cpp @@ -14,6 +14,7 @@ //========== page_theme::page_theme(QWidget *parent) : PageWidget(parent), ui(new Ui::page_theme()){ ui->setupUi(this); + findQt5Themes(); loading = false; PINFO = new LPlugins(); //load the info class connect(ui->spin_session_fontsize, SIGNAL(valueChanged(int)), this, SLOT(settingsChanged()) ); @@ -24,7 +25,7 @@ page_theme::page_theme(QWidget *parent) : PageWidget(parent), ui(new Ui::page_th connect(ui->tool_session_newcolor, SIGNAL(clicked()), this, SLOT(sessionEditColor()) ); connect(ui->tool_session_newtheme, SIGNAL(clicked()), this, SLOT(sessionEditTheme()) ); connect(ui->combo_session_cursortheme, SIGNAL(currentIndexChanged(int)), this, SLOT(settingsChanged()) ); - + connect(ui->combo_qt5_theme, SIGNAL(currentIndexChanged(int)), this, SLOT(checkQt5Theme()) ); updateIcons(); } @@ -41,6 +42,11 @@ void page_theme::SaveSettings(){ QString iconset = ui->combo_session_icontheme->currentText(); QString font = ui->font_session_theme->currentFont().family(); QString fontsize = QString::number(ui->spin_session_fontsize->value())+"pt"; + QString qt5theme = ui->combo_qt5_theme->currentData().toString(); + if(qt5theme=="internal_custom"){ qt5theme = ui->line_qt5_custom_theme->text(); } + QSettings sessionsettings("lumina-desktop","sessionsettings"); + sessionsettings.setValue("Qt5_theme_engine", qt5theme); + //qDebug() << "Saving theme options:" << themefile << colorfile << iconset << font << fontsize; LTHEME::setCurrentSettings( themefile, colorfile, iconset, font, fontsize); LTHEME::setCursorTheme(ui->combo_session_cursortheme->currentText()); @@ -103,6 +109,15 @@ ui->combo_session_themefile->clear(); int cur = ui->combo_session_cursortheme->findText( LTHEME::currentCursor() ); if(cur>=0){ ui->combo_session_cursortheme->setCurrentIndex(cur); } + QSettings sessionsettings("lumina-desktop","sessionsettings"); + QString qt5theme = sessionsettings.value("Qt5_theme_engine", "").toString(); + int index = ui->combo_qt5_theme->findData(qt5theme); + if(index <0){ + ui->line_qt5_custom_theme->setText(qt5theme); + index = ui->combo_qt5_theme->findData("internal_custom"); + } + if(index>=0){ ui->combo_qt5_theme->setCurrentIndex(index); } + QApplication::processEvents(); loading = false; } @@ -110,8 +125,34 @@ ui->combo_session_themefile->clear(); void page_theme::updateIcons(){ ui->tool_session_newtheme->setIcon( LXDG::findIcon("preferences-desktop-theme","") ); ui->tool_session_newcolor->setIcon( LXDG::findIcon("preferences-desktop-color","") ); + ui->tabWidget->setTabIcon(0, LXDG::findIcon("user-desktop","desktop") ); + ui->tabWidget->setTabIcon(1, LXDG::findIcon("preferences-system-windows","") ); } +//================= +// PRIVATE +//================= +void page_theme::findQt5Themes(){ + ui->combo_qt5_theme->clear(); + ui->combo_qt5_theme->addItem( tr("None"), ""); + ui->combo_qt5_theme->addItem( tr("Manual Setting"), "internal_custom"); + //Now probe the system and list any themes that are found + QStringList paths = QCoreApplication::libraryPaths(); + qDebug() << "Known Library Paths:" << paths; + QStringList engines; + for(int i=0; i<paths.length(); i++){ + if(QFile::exists(paths[i]+"/platformthemes")){ + QDir dir(paths[i]+"/platformthemes"); + QStringList libs = dir.entryList(QStringList("lib*.so*"), QDir::Files, QDir::NoSort) ; + for(int j=0; j<libs.length(); j++){ engines << libs[j].section("lib",1,-1).section(".",0,-2).simplified(); } + } + } + engines.sort(); + for(int i=0; i<engines.length(); i++){ + if(i==0){ ui->combo_qt5_theme->insertSeparator(2); } + ui->combo_qt5_theme->addItem( engines[i], engines[i] ); + } +} //================= // PRIVATE SLOTS //================= @@ -167,3 +208,8 @@ void page_theme::sessionEditTheme(){ } emit HasPendingChanges(true); } + +void page_theme::checkQt5Theme(){ + ui->line_qt5_custom_theme->setVisible( ui->combo_qt5_theme->currentData().toString()=="internal_custom"); + settingsChanged(); +} diff --git a/src-qt5/core-utils/lumina-config/pages/page_theme.h b/src-qt5/core-utils/lumina-config/pages/page_theme.h index a56fba7b..3257af9b 100644 --- a/src-qt5/core-utils/lumina-config/pages/page_theme.h +++ b/src-qt5/core-utils/lumina-config/pages/page_theme.h @@ -31,6 +31,8 @@ private: LPlugins *PINFO; bool loading; + void findQt5Themes(); + private slots: void settingsChanged(){ //qDebug() << "Setting Changed:" << !loading; @@ -38,5 +40,6 @@ private slots: } void sessionEditColor(); void sessionEditTheme(); + void checkQt5Theme(); }; #endif diff --git a/src-qt5/core-utils/lumina-config/pages/page_theme.ui b/src-qt5/core-utils/lumina-config/pages/page_theme.ui index decd543f..ecc209ed 100644 --- a/src-qt5/core-utils/lumina-config/pages/page_theme.ui +++ b/src-qt5/core-utils/lumina-config/pages/page_theme.ui @@ -6,14 +6,14 @@ <rect> <x>0</x> <y>0</y> - <width>400</width> + <width>428</width> <height>300</height> </rect> </property> <property name="windowTitle"> <string>Form</string> </property> - <layout class="QFormLayout" name="formLayout"> + <layout class="QVBoxLayout" name="verticalLayout"> <property name="leftMargin"> <number>9</number> </property> @@ -26,155 +26,193 @@ <property name="bottomMargin"> <number>9</number> </property> - <item row="0" column="0"> - <widget class="QLabel" name="label_12"> - <property name="text"> - <string>Font:</string> + <item> + <widget class="QTabWidget" name="tabWidget"> + <property name="currentIndex"> + <number>0</number> </property> + <widget class="QWidget" name="tab_desktop"> + <attribute name="title"> + <string>Desktop Theme</string> + </attribute> + <layout class="QFormLayout" name="formLayout_2"> + <item row="0" column="0"> + <widget class="QLabel" name="label_12"> + <property name="text"> + <string>Font:</string> + </property> + </widget> + </item> + <item row="0" column="1"> + <widget class="QFontComboBox" name="font_session_theme"> + <property name="editable"> + <bool>false</bool> + </property> + </widget> + </item> + <item row="1" column="0"> + <widget class="QLabel" name="label_14"> + <property name="text"> + <string>Font Size:</string> + </property> + </widget> + </item> + <item row="1" column="1"> + <widget class="QSpinBox" name="spin_session_fontsize"> + <property name="suffix"> + <string> point</string> + </property> + </widget> + </item> + <item row="2" column="0"> + <widget class="QLabel" name="label_16"> + <property name="text"> + <string>Theme Template:</string> + </property> + </widget> + </item> + <item row="2" column="1"> + <layout class="QHBoxLayout" name="horizontalLayout_12"> + <item> + <widget class="QComboBox" name="combo_session_themefile"> + <property name="sizeAdjustPolicy"> + <enum>QComboBox::AdjustToContents</enum> + </property> + </widget> + </item> + <item> + <widget class="QToolButton" name="tool_session_newtheme"> + <property name="toolTip"> + <string>Create/Edit a theme template (Advanced)</string> + </property> + <property name="statusTip"> + <string/> + </property> + <property name="text"> + <string>Edit</string> + </property> + <property name="toolButtonStyle"> + <enum>Qt::ToolButtonTextBesideIcon</enum> + </property> + </widget> + </item> + </layout> + </item> + <item row="3" column="0"> + <widget class="QLabel" name="label_17"> + <property name="text"> + <string>Color Scheme:</string> + </property> + </widget> + </item> + <item row="3" column="1"> + <layout class="QHBoxLayout" name="horizontalLayout_19"> + <item> + <widget class="QComboBox" name="combo_session_colorfile"> + <property name="sizeAdjustPolicy"> + <enum>QComboBox::AdjustToContents</enum> + </property> + </widget> + </item> + <item> + <widget class="QToolButton" name="tool_session_newcolor"> + <property name="toolTip"> + <string>Create/Edit a color scheme</string> + </property> + <property name="statusTip"> + <string/> + </property> + <property name="text"> + <string>Edit</string> + </property> + <property name="toolButtonStyle"> + <enum>Qt::ToolButtonTextBesideIcon</enum> + </property> + </widget> + </item> + </layout> + </item> + <item row="4" column="0"> + <widget class="QLabel" name="label_18"> + <property name="text"> + <string>Icon Pack:</string> + </property> + </widget> + </item> + <item row="4" column="1"> + <widget class="QComboBox" name="combo_session_icontheme"/> + </item> + <item row="5" column="0"> + <widget class="QLabel" name="label_31"> + <property name="text"> + <string>Mouse Cursors:</string> + </property> + </widget> + </item> + <item row="5" column="1"> + <layout class="QHBoxLayout" name="horizontalLayout_2"> + <item> + <widget class="QComboBox" name="combo_session_cursortheme"> + <property name="sizePolicy"> + <sizepolicy hsizetype="MinimumExpanding" vsizetype="Fixed"> + <horstretch>0</horstretch> + <verstretch>0</verstretch> + </sizepolicy> + </property> + </widget> + </item> + <item> + <widget class="QLabel" name="label_cursor_sample"> + <property name="sizePolicy"> + <sizepolicy hsizetype="Preferred" vsizetype="Preferred"> + <horstretch>0</horstretch> + <verstretch>0</verstretch> + </sizepolicy> + </property> + <property name="toolTip"> + <string notr="true"/> + </property> + <property name="text"> + <string notr="true"/> + </property> + <property name="scaledContents"> + <bool>true</bool> + </property> + <property name="alignment"> + <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set> + </property> + </widget> + </item> + </layout> + </item> + </layout> + </widget> + <widget class="QWidget" name="tab_apps"> + <attribute name="title"> + <string>Application Themes</string> + </attribute> + <layout class="QFormLayout" name="formLayout"> + <item row="0" column="0"> + <widget class="QLabel" name="label"> + <property name="text"> + <string>Qt5 Theme Engine</string> + </property> + </widget> + </item> + <item row="0" column="1"> + <layout class="QVBoxLayout" name="verticalLayout_2"> + <item> + <widget class="QComboBox" name="combo_qt5_theme"/> + </item> + <item> + <widget class="QLineEdit" name="line_qt5_custom_theme"/> + </item> + </layout> + </item> + </layout> + </widget> </widget> </item> - <item row="0" column="1"> - <widget class="QFontComboBox" name="font_session_theme"> - <property name="editable"> - <bool>false</bool> - </property> - </widget> - </item> - <item row="1" column="0"> - <widget class="QLabel" name="label_14"> - <property name="text"> - <string>Font Size:</string> - </property> - </widget> - </item> - <item row="1" column="1"> - <widget class="QSpinBox" name="spin_session_fontsize"> - <property name="suffix"> - <string> point</string> - </property> - </widget> - </item> - <item row="2" column="0"> - <widget class="QLabel" name="label_16"> - <property name="text"> - <string>Theme Template:</string> - </property> - </widget> - </item> - <item row="2" column="1"> - <layout class="QHBoxLayout" name="horizontalLayout_12"> - <item> - <widget class="QComboBox" name="combo_session_themefile"> - <property name="sizeAdjustPolicy"> - <enum>QComboBox::AdjustToContents</enum> - </property> - </widget> - </item> - <item> - <widget class="QToolButton" name="tool_session_newtheme"> - <property name="toolTip"> - <string>Create/Edit a theme template (Advanced)</string> - </property> - <property name="statusTip"> - <string/> - </property> - <property name="text"> - <string>Edit</string> - </property> - <property name="toolButtonStyle"> - <enum>Qt::ToolButtonTextBesideIcon</enum> - </property> - </widget> - </item> - </layout> - </item> - <item row="3" column="0"> - <widget class="QLabel" name="label_17"> - <property name="text"> - <string>Color Scheme:</string> - </property> - </widget> - </item> - <item row="3" column="1"> - <layout class="QHBoxLayout" name="horizontalLayout_19"> - <item> - <widget class="QComboBox" name="combo_session_colorfile"> - <property name="sizeAdjustPolicy"> - <enum>QComboBox::AdjustToContents</enum> - </property> - </widget> - </item> - <item> - <widget class="QToolButton" name="tool_session_newcolor"> - <property name="toolTip"> - <string>Create/Edit a color scheme</string> - </property> - <property name="statusTip"> - <string/> - </property> - <property name="text"> - <string>Edit</string> - </property> - <property name="toolButtonStyle"> - <enum>Qt::ToolButtonTextBesideIcon</enum> - </property> - </widget> - </item> - </layout> - </item> - <item row="4" column="0"> - <widget class="QLabel" name="label_18"> - <property name="text"> - <string>Icon Pack:</string> - </property> - </widget> - </item> - <item row="4" column="1"> - <widget class="QComboBox" name="combo_session_icontheme"/> - </item> - <item row="5" column="0"> - <widget class="QLabel" name="label_31"> - <property name="text"> - <string>Mouse Cursors:</string> - </property> - </widget> - </item> - <item row="5" column="1"> - <layout class="QHBoxLayout" name="horizontalLayout_2"> - <item> - <widget class="QComboBox" name="combo_session_cursortheme"> - <property name="sizePolicy"> - <sizepolicy hsizetype="MinimumExpanding" vsizetype="Fixed"> - <horstretch>0</horstretch> - <verstretch>0</verstretch> - </sizepolicy> - </property> - </widget> - </item> - <item> - <widget class="QLabel" name="label_cursor_sample"> - <property name="sizePolicy"> - <sizepolicy hsizetype="Preferred" vsizetype="Preferred"> - <horstretch>0</horstretch> - <verstretch>0</verstretch> - </sizepolicy> - </property> - <property name="toolTip"> - <string notr="true"/> - </property> - <property name="text"> - <string notr="true"/> - </property> - <property name="scaledContents"> - <bool>true</bool> - </property> - <property name="alignment"> - <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set> - </property> - </widget> - </item> - </layout> - </item> </layout> </widget> <resources/> -- cgit From 43358bcfd3f815d6f124c70d330a3128aeff9c08 Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Thu, 3 Nov 2016 13:55:36 -0400 Subject: Convert the ResizeMenu class into it's own files: 1) Add a new .pri for loading just that class (works stand-alone) 2) Setup the lumina-desktop to use the new build framework for including that class. --- src-qt5/core/libLumina/LuminaUtils.cpp | 4 +- src-qt5/core/libLumina/LuminaUtils.h | 4 +- src-qt5/core/libLumina/ResizeMenu.cpp | 106 +++++++++++++++++++++ src-qt5/core/libLumina/ResizeMenu.h | 51 ++++++++++ src-qt5/core/libLumina/ResizeMenu.pri | 6 ++ src-qt5/core/lumina-desktop/lumina-desktop.pro | 3 + .../panel-plugins/systemstart/LStartButton.h | 1 + 7 files changed, 171 insertions(+), 4 deletions(-) create mode 100644 src-qt5/core/libLumina/ResizeMenu.cpp create mode 100644 src-qt5/core/libLumina/ResizeMenu.h create mode 100644 src-qt5/core/libLumina/ResizeMenu.pri (limited to 'src-qt5') diff --git a/src-qt5/core/libLumina/LuminaUtils.cpp b/src-qt5/core/libLumina/LuminaUtils.cpp index 0fb44ff1..0d808d1d 100644 --- a/src-qt5/core/libLumina/LuminaUtils.cpp +++ b/src-qt5/core/libLumina/LuminaUtils.cpp @@ -966,7 +966,7 @@ int LUtils::VersionStringToNumber(QString version){ // ======================= // RESIZEMENU CLASS // ======================= -ResizeMenu::ResizeMenu(QWidget *parent) : QMenu(parent){ +/*ResizeMenu::ResizeMenu(QWidget *parent) : QMenu(parent){ this->setContentsMargins(1,1,1,1); this->setMouseTracking(true); resizeSide = NONE; @@ -1060,4 +1060,4 @@ void ResizeMenu::mouseReleaseEvent(QMouseEvent *ev){ }else{ QMenu::mouseReleaseEvent(ev); //do normal processing } -} +}*/ diff --git a/src-qt5/core/libLumina/LuminaUtils.h b/src-qt5/core/libLumina/LuminaUtils.h index e07363ca..4a0a19af 100644 --- a/src-qt5/core/libLumina/LuminaUtils.h +++ b/src-qt5/core/libLumina/LuminaUtils.h @@ -99,7 +99,7 @@ public: //Special subclass for a menu which the user can grab the edges and resize as necessary // Note: Make sure that you don't set 0pixel contents margins on this menu // - it needs at least 1 pixel margins for the user to be able to grab it -class ResizeMenu : public QMenu{ +/*class ResizeMenu : public QMenu{ Q_OBJECT public: ResizeMenu(QWidget *parent = 0); @@ -126,6 +126,6 @@ protected: signals: void MenuResized(QSize); //Emitted when the menu is manually resized by the user -}; +};*/ #endif diff --git a/src-qt5/core/libLumina/ResizeMenu.cpp b/src-qt5/core/libLumina/ResizeMenu.cpp new file mode 100644 index 00000000..9f291134 --- /dev/null +++ b/src-qt5/core/libLumina/ResizeMenu.cpp @@ -0,0 +1,106 @@ +//=========================================== +// Lumina-DE source code +// Copyright (c) 2013-2016, Ken Moore +// Available under the 3-clause BSD license +// See the LICENSE file for full details +//=========================================== +#include "ResizeMenu.h" + +// ======================= +// RESIZEMENU CLASS +// ======================= +ResizeMenu::ResizeMenu(QWidget *parent) : QMenu(parent){ + this->setContentsMargins(1,1,1,1); + this->setMouseTracking(true); + resizeSide = NONE; + cAct = new QWidgetAction(this); + contents = 0; + connect(this, SIGNAL(aboutToShow()), this, SLOT(clearFlags()) ); + connect(this, SIGNAL(aboutToHide()), this, SLOT(clearFlags()) ); + connect(cAct, SIGNAL(hovered()), this, SLOT(clearFlags()) ); +} + +ResizeMenu::~ResizeMenu(){ + +} + +void ResizeMenu::setContents(QWidget *con){ + this->clear(); + cAct->setDefaultWidget(con); + this->addAction(cAct); + contents = con; //save for later + contents->setCursor(Qt::ArrowCursor); +} + +void ResizeMenu::mouseMoveEvent(QMouseEvent *ev){ + QRect geom = this->geometry(); + //Note: The exact position does not matter as much as the size + // since the window will be moved again the next time it is shown + // The "-2" in the sizing below accounts for the menu margins + QPoint gpos = this->mapToGlobal(ev->pos()); + bool handled = false; + switch(resizeSide){ + case TOP: + if(gpos.y() >= geom.bottom()-1){ break; } + geom.setTop(gpos.y()); + this->setGeometry(geom); + if(contents!=0){ contents->setFixedSize(QSize(geom.width()-2, geom.height()-2));} + handled = true; + break; + case BOTTOM: + if(gpos.y() <= geom.top()+1){ break; } + geom.setBottom( gpos.y()); + this->setGeometry(geom); + if(contents!=0){ contents->setFixedSize(QSize(geom.width()-2, geom.height()-2));} + handled = true; + break; + case LEFT: + if(gpos.x() >= geom.right()-1){ break; } + geom.setLeft(gpos.x()); + this->setGeometry(geom); + if(contents!=0){ contents->setFixedSize(QSize(geom.width()-2, geom.height()-2));} + handled = true; + break; + case RIGHT: + if(gpos.x() <= geom.left()+1){ break; } + geom.setRight(gpos.x()); + this->setGeometry(geom); + if(contents!=0){ contents->setFixedSize(QSize(geom.width()-2, geom.height()-2));} + handled = true; + break; + default: //NONE + //qDebug() << " - Mouse At:" << ev->pos(); + //Just adjust the mouse cursor which is shown + if(ev->pos().x()<=1 && ev->pos().x() >= -1){ this->setCursor(Qt::SizeHorCursor); } + else if(ev->pos().x() >= this->width()-1 && ev->pos().x() <= this->width()+1){ this->setCursor(Qt::SizeHorCursor); } + else if(ev->pos().y()<=1 && ev->pos().y() >= -1){ this->setCursor(Qt::SizeVerCursor); } + else if(ev->pos().y() >= this->height()-1 && ev->pos().y() <= this->height()+1){ this->setCursor(Qt::SizeVerCursor); } + else{ this->setCursor(Qt::ArrowCursor); } + } + if(!handled){ QMenu::mouseMoveEvent(ev); } //do normal processing as well +} + +void ResizeMenu::mousePressEvent(QMouseEvent *ev){ + bool used = false; + if(ev->buttons().testFlag(Qt::LeftButton) && resizeSide==NONE){ + //qDebug() << "Mouse Press Event:" << ev->pos() << resizeSide; + if(ev->pos().x()<=1 && ev->pos().x() >= -1){resizeSide = LEFT; used = true;} + else if(ev->pos().x() >= this->width()-1 && ev->pos().x() <= this->width()+1){ resizeSide = RIGHT; used = true;} + else if(ev->pos().y()<=1 && ev->pos().y() >= -1){ resizeSide = TOP; used = true; } + else if(ev->pos().y() >= this->height()-1 && ev->pos().y() <= this->height()+1){ resizeSide = BOTTOM; used = true; } + } + if(used){ ev->accept(); this->grabMouse(); } + else{ QMenu::mousePressEvent(ev); } //do normal processing +} + +void ResizeMenu::mouseReleaseEvent(QMouseEvent *ev){ + this->releaseMouse(); + if(ev->button() == Qt::LeftButton && resizeSide!=NONE ){ + //qDebug() << "Mouse Release Event:" << ev->pos() << resizeSide; + resizeSide = NONE; + emit MenuResized(contents->size()); + ev->accept(); + }else{ + QMenu::mouseReleaseEvent(ev); //do normal processing + } +} diff --git a/src-qt5/core/libLumina/ResizeMenu.h b/src-qt5/core/libLumina/ResizeMenu.h new file mode 100644 index 00000000..ed909da3 --- /dev/null +++ b/src-qt5/core/libLumina/ResizeMenu.h @@ -0,0 +1,51 @@ +//=========================================== +// Lumina-DE source code +// Copyright (c) 2012-2016, Ken Moore +// Available under the 3-clause BSD license +// See the LICENSE file for full details +//=========================================== +#ifndef _LUMINA_LIBRARY_RESIZE_MENU_H +#define _LUMINA_LIBRARY_RESIZE_MENU_H + +#include <QMenu> +#include <QWidget> +#include <QMouseEvent> +#include <QAction> +#include <QWidgetAction> +#include <QRect> +#include <QCursor> +#include <QPoint> + +//Special subclass for a menu which the user can grab the edges and resize as necessary +// Note: Make sure that you don't set 0pixel contents margins on this menu +// - it needs at least 1 pixel margins for the user to be able to grab it +class ResizeMenu : public QMenu{ + Q_OBJECT +public: + ResizeMenu(QWidget *parent = 0); + virtual ~ResizeMenu(); + + void setContents(QWidget *con); + +private: + enum SideFlag{NONE, TOP, BOTTOM, LEFT, RIGHT}; + SideFlag resizeSide; + QWidget *contents; + QWidgetAction *cAct; + +private slots: + void clearFlags(){ + resizeSide=NONE; + } + +protected: + virtual void mouseMoveEvent(QMouseEvent *ev); + virtual void mousePressEvent(QMouseEvent *ev); + virtual void mouseReleaseEvent(QMouseEvent *ev); + +signals: + void MenuResized(QSize); //Emitted when the menu is manually resized by the user + +}; + +#endif diff --git a/src-qt5/core/libLumina/ResizeMenu.pri b/src-qt5/core/libLumina/ResizeMenu.pri new file mode 100644 index 00000000..2b055841 --- /dev/null +++ b/src-qt5/core/libLumina/ResizeMenu.pri @@ -0,0 +1,6 @@ +#Subproject file for bundling the ResizeMenu class into an application +SOURCES += $${PWD}/ResizeMenu.cpp +HEADERS += $${PWD}/ResizeMenu.h +#Add this dir to the include path +# This allows the application to simply use "#include <ResizeMenu.h>" to use it +INCLUDEPATH *= $${PWD} diff --git a/src-qt5/core/lumina-desktop/lumina-desktop.pro b/src-qt5/core/lumina-desktop/lumina-desktop.pro index 814725cc..effa0508 100644 --- a/src-qt5/core/lumina-desktop/lumina-desktop.pro +++ b/src-qt5/core/lumina-desktop/lumina-desktop.pro @@ -53,6 +53,9 @@ HEADERS += Globals.h \ FORMS += SystemWindow.ui \ BootSplash.ui +#include all the special classes from the Lumina tree +include(../libLumina/ResizeMenu.pri) + #Now include all the files for the various plugins include(panel-plugins/panel-plugins.pri) include(desktop-plugins/desktop-plugins.pri) diff --git a/src-qt5/core/lumina-desktop/panel-plugins/systemstart/LStartButton.h b/src-qt5/core/lumina-desktop/panel-plugins/systemstart/LStartButton.h index 1a17b75b..22742bc5 100644 --- a/src-qt5/core/lumina-desktop/panel-plugins/systemstart/LStartButton.h +++ b/src-qt5/core/lumina-desktop/panel-plugins/systemstart/LStartButton.h @@ -25,6 +25,7 @@ // libLumina includes #include <LuminaXDG.h> #include <LuminaUtils.h> +#include <ResizeMenu.h> #include "StartMenu.h" -- cgit From ecae524c77a84b5855fa6390b7e0166c17349c18 Mon Sep 17 00:00:00 2001 From: Thomas Klausner <wiz@NetBSD.org> Date: Mon, 7 Nov 2016 10:07:05 +0100 Subject: Fix unportable test(1) operator. Only bash supports "==", the standard is "=". --- src-qt5/core/menu-scripts/ls.json.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src-qt5') diff --git a/src-qt5/core/menu-scripts/ls.json.sh b/src-qt5/core/menu-scripts/ls.json.sh index 43b0ead6..754a10d4 100755 --- a/src-qt5/core/menu-scripts/ls.json.sh +++ b/src-qt5/core/menu-scripts/ls.json.sh @@ -1,6 +1,6 @@ #!/bin/sh DIR=${1} -if [ "$1" == "" ] ; then +if [ "$1" = "" ] ; then DIR=`pwd` fi -- cgit From 7ab900e41f5f15adccd573d459a80fe60cf6a044 Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Mon, 7 Nov 2016 13:52:20 -0500 Subject: LARGE UPDATE: 1) Dismantle the Lumina library completely. 2) Setup lots of small subproject files (.pri) for the individual classes within the old library. 3) Move all the Lumina binaries to use the new subproject files 4) Split up the LuminaUtils class/files into LUtils and LDesktopUtils (generic utilities, and desktop-specific utilities) --- src-qt5/core-utils/lumina-config/ColorDialog.cpp | 2 +- src-qt5/core-utils/lumina-config/LPlugins.cpp | 2 +- src-qt5/core-utils/lumina-config/ThemeDialog.cpp | 2 +- src-qt5/core-utils/lumina-config/globals.h | 4 +- src-qt5/core-utils/lumina-config/lumina-config.pro | 13 +- src-qt5/core-utils/lumina-config/main.cpp | 2 +- .../lumina-config/pages/page_session_options.cpp | 4 +- src-qt5/core-utils/lumina-search/Worker.cpp | 2 +- src-qt5/core-utils/lumina-search/lumina-search.pro | 10 +- src-qt5/core-utils/lumina-search/main.cpp | 2 +- src-qt5/core-utils/lumina-xconfig/MainUI.cpp | 2 +- .../core-utils/lumina-xconfig/ScreenSettings.cpp | 2 +- .../core-utils/lumina-xconfig/lumina-xconfig.pro | 12 +- src-qt5/core-utils/lumina-xconfig/main.cpp | 2 +- src-qt5/core/colors/Black.qss.colors | 13 + src-qt5/core/colors/Blue-Light.qss.colors | 13 + src-qt5/core/colors/Grey-Dark.qss.colors | 13 + src-qt5/core/colors/Lumina-Glass.qss.colors | 13 + src-qt5/core/colors/Lumina-Gold.qss.colors | 13 + src-qt5/core/colors/Lumina-Green.qss.colors | 13 + src-qt5/core/colors/Lumina-Purple.qss.colors | 13 + src-qt5/core/colors/Lumina-Red.qss.colors | 13 + src-qt5/core/colors/PCBSD10-Default.qss.colors | 13 + src-qt5/core/colors/Solarized-Dark.qss.colors | 16 + src-qt5/core/colors/Solarized-Light.qss.colors | 16 + src-qt5/core/core.pro | 28 +- src-qt5/core/libLumina/LDesktopUtils.cpp | 550 ++++++++++ src-qt5/core/libLumina/LDesktopUtils.h | 49 + src-qt5/core/libLumina/LDesktopUtils.pri | 7 + src-qt5/core/libLumina/LUtils.cpp | 436 ++++++++ src-qt5/core/libLumina/LUtils.h | 78 ++ src-qt5/core/libLumina/LUtils.pri | 34 + src-qt5/core/libLumina/LuminaOS.h | 4 +- src-qt5/core/libLumina/LuminaSingleApplication.h | 2 +- src-qt5/core/libLumina/LuminaSingleApplication.pri | 12 + src-qt5/core/libLumina/LuminaThemes.cpp | 2 +- src-qt5/core/libLumina/LuminaThemes.pri | 10 + src-qt5/core/libLumina/LuminaUtils.cpp | 1063 -------------------- src-qt5/core/libLumina/LuminaUtils.h | 131 --- src-qt5/core/libLumina/LuminaX11.pri | 13 + src-qt5/core/libLumina/LuminaXDG.cpp | 2 +- src-qt5/core/libLumina/LuminaXDG.pri | 10 + src-qt5/core/libLumina/colors/Black.qss.colors | 13 - .../core/libLumina/colors/Blue-Light.qss.colors | 13 - src-qt5/core/libLumina/colors/Grey-Dark.qss.colors | 13 - .../core/libLumina/colors/Lumina-Glass.qss.colors | 13 - .../core/libLumina/colors/Lumina-Gold.qss.colors | 13 - .../core/libLumina/colors/Lumina-Green.qss.colors | 13 - .../core/libLumina/colors/Lumina-Purple.qss.colors | 13 - .../core/libLumina/colors/Lumina-Red.qss.colors | 13 - .../libLumina/colors/PCBSD10-Default.qss.colors | 13 - .../libLumina/colors/Solarized-Dark.qss.colors | 16 - .../libLumina/colors/Solarized-Light.qss.colors | 16 - src-qt5/core/libLumina/libLumina.pro | 86 +- .../core/libLumina/quickplugins/quick-sample.qml | 12 - src-qt5/core/libLumina/themes/Glass.qss.template | 539 ---------- .../libLumina/themes/Lumina-default.qss.template | 494 --------- src-qt5/core/libLumina/themes/None.qss.template | 118 --- src-qt5/core/libLumina/xtrafiles/globs2 | 991 ------------------ src-qt5/core/lumina-desktop/Globals.h | 3 +- src-qt5/core/lumina-desktop/JsonMenu.h | 2 +- src-qt5/core/lumina-desktop/LSession.cpp | 6 +- .../desktop-plugins/notepad/NotepadPlugin.cpp | 2 +- .../desktop-plugins/quickcontainer/QuickDPlugin.h | 2 +- .../desktop-plugins/rssreader/RSSFeedPlugin.cpp | 2 +- src-qt5/core/lumina-desktop/lumina-desktop.pro | 15 +- src-qt5/core/lumina-desktop/main.cpp | 5 +- .../panel-plugins/battery/LBattery.h | 2 +- .../lumina-desktop/panel-plugins/battery/NOTES | 2 +- .../panel-plugins/desktopbar/LDeskBar.cpp | 2 +- .../desktopswitcher/LDesktopSwitcher.h | 2 +- .../panel-plugins/quickcontainer/QuickPPlugin.h | 2 +- .../panel-plugins/systemstart/ItemWidget.cpp | 12 +- .../panel-plugins/systemstart/LStartButton.cpp | 2 +- .../panel-plugins/systemstart/LStartButton.h | 2 +- .../panel-plugins/systemstart/StartMenu.cpp | 2 +- .../panel-plugins/userbutton/UserItemWidget.cpp | 11 +- .../panel-plugins/userbutton/UserWidget.cpp | 2 +- src-qt5/core/lumina-info/MainUI.cpp | 5 +- src-qt5/core/lumina-info/lumina-info.pro | 10 +- src-qt5/core/lumina-info/main.cpp | 2 +- src-qt5/core/lumina-open/LFileDialog.h | 2 +- src-qt5/core/lumina-open/lumina-open.pro | 7 +- src-qt5/core/lumina-open/main.cpp | 2 +- src-qt5/core/lumina-session/lumina-session.pro | 6 +- src-qt5/core/lumina-session/main.cpp | 5 +- src-qt5/core/lumina-session/session.cpp | 2 +- src-qt5/core/quickplugins/quick-sample.qml | 12 + src-qt5/core/themes/Glass.qss.template | 539 ++++++++++ src-qt5/core/themes/Lumina-default.qss.template | 494 +++++++++ src-qt5/core/themes/None.qss.template | 118 +++ src-qt5/core/xtrafiles/globs2 | 991 ++++++++++++++++++ .../lumina-calculator/lumina-calculator.pro | 10 +- src-qt5/desktop-utils/lumina-calculator/main.cpp | 2 +- src-qt5/desktop-utils/lumina-calculator/mainUI.cpp | 3 +- src-qt5/desktop-utils/lumina-fileinfo/MainUI.cpp | 2 +- .../lumina-fileinfo/lumina-fileinfo.pro | 12 +- src-qt5/desktop-utils/lumina-fileinfo/main.cpp | 2 +- src-qt5/desktop-utils/lumina-fm/Browser.cpp | 2 +- src-qt5/desktop-utils/lumina-fm/BrowserWidget.cpp | 2 +- src-qt5/desktop-utils/lumina-fm/DirData.h | 2 +- src-qt5/desktop-utils/lumina-fm/FODialog.h | 2 +- src-qt5/desktop-utils/lumina-fm/MainUI.cpp | 5 +- src-qt5/desktop-utils/lumina-fm/OPWidget.h | 3 + src-qt5/desktop-utils/lumina-fm/gitCompat.h | 2 +- src-qt5/desktop-utils/lumina-fm/gitWizard.h | 1 + src-qt5/desktop-utils/lumina-fm/lumina-fm.pro | 7 +- src-qt5/desktop-utils/lumina-fm/main.cpp | 2 +- .../lumina-fm/widgets/DDListWidgets.h | 2 +- .../desktop-utils/lumina-fm/widgets/DirWidget2.cpp | 2 +- src-qt5/desktop-utils/lumina-screenshot/MainUI.h | 2 +- .../lumina-screenshot/lumina-screenshot.pro | 11 +- src-qt5/desktop-utils/lumina-screenshot/main.cpp | 2 +- src-qt5/desktop-utils/lumina-terminal/TrayIcon.cpp | 4 +- .../lumina-terminal/lumina-terminal.pro | 10 +- src-qt5/desktop-utils/lumina-textedit/MainUI.cpp | 2 +- .../lumina-textedit/PlainTextEditor.cpp | 2 +- .../lumina-textedit/lumina-textedit.pro | 10 +- src-qt5/desktop-utils/lumina-textedit/main.cpp | 2 +- 119 files changed, 3733 insertions(+), 3678 deletions(-) create mode 100644 src-qt5/core/colors/Black.qss.colors create mode 100644 src-qt5/core/colors/Blue-Light.qss.colors create mode 100644 src-qt5/core/colors/Grey-Dark.qss.colors create mode 100644 src-qt5/core/colors/Lumina-Glass.qss.colors create mode 100644 src-qt5/core/colors/Lumina-Gold.qss.colors create mode 100644 src-qt5/core/colors/Lumina-Green.qss.colors create mode 100644 src-qt5/core/colors/Lumina-Purple.qss.colors create mode 100644 src-qt5/core/colors/Lumina-Red.qss.colors create mode 100644 src-qt5/core/colors/PCBSD10-Default.qss.colors create mode 100644 src-qt5/core/colors/Solarized-Dark.qss.colors create mode 100644 src-qt5/core/colors/Solarized-Light.qss.colors create mode 100644 src-qt5/core/libLumina/LDesktopUtils.cpp create mode 100644 src-qt5/core/libLumina/LDesktopUtils.h create mode 100644 src-qt5/core/libLumina/LDesktopUtils.pri create mode 100644 src-qt5/core/libLumina/LUtils.cpp create mode 100644 src-qt5/core/libLumina/LUtils.h create mode 100644 src-qt5/core/libLumina/LUtils.pri create mode 100644 src-qt5/core/libLumina/LuminaSingleApplication.pri create mode 100644 src-qt5/core/libLumina/LuminaThemes.pri delete mode 100644 src-qt5/core/libLumina/LuminaUtils.cpp delete mode 100644 src-qt5/core/libLumina/LuminaUtils.h create mode 100644 src-qt5/core/libLumina/LuminaX11.pri create mode 100644 src-qt5/core/libLumina/LuminaXDG.pri delete mode 100644 src-qt5/core/libLumina/colors/Black.qss.colors delete mode 100644 src-qt5/core/libLumina/colors/Blue-Light.qss.colors delete mode 100644 src-qt5/core/libLumina/colors/Grey-Dark.qss.colors delete mode 100644 src-qt5/core/libLumina/colors/Lumina-Glass.qss.colors delete mode 100644 src-qt5/core/libLumina/colors/Lumina-Gold.qss.colors delete mode 100644 src-qt5/core/libLumina/colors/Lumina-Green.qss.colors delete mode 100644 src-qt5/core/libLumina/colors/Lumina-Purple.qss.colors delete mode 100644 src-qt5/core/libLumina/colors/Lumina-Red.qss.colors delete mode 100644 src-qt5/core/libLumina/colors/PCBSD10-Default.qss.colors delete mode 100644 src-qt5/core/libLumina/colors/Solarized-Dark.qss.colors delete mode 100644 src-qt5/core/libLumina/colors/Solarized-Light.qss.colors delete mode 100644 src-qt5/core/libLumina/quickplugins/quick-sample.qml delete mode 100644 src-qt5/core/libLumina/themes/Glass.qss.template delete mode 100644 src-qt5/core/libLumina/themes/Lumina-default.qss.template delete mode 100644 src-qt5/core/libLumina/themes/None.qss.template delete mode 100644 src-qt5/core/libLumina/xtrafiles/globs2 create mode 100644 src-qt5/core/quickplugins/quick-sample.qml create mode 100644 src-qt5/core/themes/Glass.qss.template create mode 100644 src-qt5/core/themes/Lumina-default.qss.template create mode 100644 src-qt5/core/themes/None.qss.template create mode 100644 src-qt5/core/xtrafiles/globs2 (limited to 'src-qt5') diff --git a/src-qt5/core-utils/lumina-config/ColorDialog.cpp b/src-qt5/core-utils/lumina-config/ColorDialog.cpp index 860f6069..9dfcc641 100644 --- a/src-qt5/core-utils/lumina-config/ColorDialog.cpp +++ b/src-qt5/core-utils/lumina-config/ColorDialog.cpp @@ -1,7 +1,7 @@ #include "ColorDialog.h" #include "ui_ColorDialog.h" -#include <LuminaUtils.h> +#include <LUtils.h> ColorDialog::ColorDialog(QWidget *parent, LPlugins *plugs, QString colorFilePath) : QDialog(parent), ui(new Ui::ColorDialog){ ui->setupUi(this); //load the designer file diff --git a/src-qt5/core-utils/lumina-config/LPlugins.cpp b/src-qt5/core-utils/lumina-config/LPlugins.cpp index cc19f8e8..e48910c7 100644 --- a/src-qt5/core-utils/lumina-config/LPlugins.cpp +++ b/src-qt5/core-utils/lumina-config/LPlugins.cpp @@ -6,7 +6,7 @@ //=========================================== #include "LPlugins.h" -#include <LuminaUtils.h> +#include <LUtils.h> LPlugins::LPlugins(){ LoadPanelPlugins(); diff --git a/src-qt5/core-utils/lumina-config/ThemeDialog.cpp b/src-qt5/core-utils/lumina-config/ThemeDialog.cpp index de17a3d8..75645448 100644 --- a/src-qt5/core-utils/lumina-config/ThemeDialog.cpp +++ b/src-qt5/core-utils/lumina-config/ThemeDialog.cpp @@ -1,7 +1,7 @@ #include "ThemeDialog.h" #include "ui_ThemeDialog.h" -#include <LuminaUtils.h> +#include <LUtils.h> ThemeDialog::ThemeDialog(QWidget *parent, LPlugins *plugs, QString themeFilePath) : QDialog(parent), ui(new Ui::ThemeDialog){ ui->setupUi(this); //load the designer file diff --git a/src-qt5/core-utils/lumina-config/globals.h b/src-qt5/core-utils/lumina-config/globals.h index 2a863bda..0f94785c 100644 --- a/src-qt5/core-utils/lumina-config/globals.h +++ b/src-qt5/core-utils/lumina-config/globals.h @@ -25,10 +25,12 @@ #include <QDialog> #include <QPoint> #include <QCursor> +#include <QMenu> //Now the Lumina Library classes #include <LuminaXDG.h> -#include <LuminaUtils.h> +#include <LUtils.h> +#include <LDesktopUtils.h> #include <LuminaX11.h> #include <LuminaOS.h> #include <LuminaThemes.h> diff --git a/src-qt5/core-utils/lumina-config/lumina-config.pro b/src-qt5/core-utils/lumina-config/lumina-config.pro index 5d6e8db9..fe5494de 100644 --- a/src-qt5/core-utils/lumina-config/lumina-config.pro +++ b/src-qt5/core-utils/lumina-config/lumina-config.pro @@ -10,6 +10,12 @@ target.path = $${L_BINDIR} TEMPLATE = app +#include all the special classes from the Lumina tree +include(../../core/libLumina/LDesktopUtils.pri) #includes LUtils +include(../../core/libLumina/LuminaXDG.pri) +include(../../core/libLumina/LuminaSingleApplication.pri) +include(../../core/libLumina/LuminaThemes.pri) + SOURCES += main.cpp \ mainWindow.cpp \ LPlugins.cpp \ @@ -38,13 +44,6 @@ FORMS += mainWindow.ui \ include("pages/pages.pri") -# RESOURCES+= lumina-config.qrc - -LIBS += -lLuminaUtils - - -DEPENDPATH += ../../core/libLumina - TRANSLATIONS = i18n/lumina-config_af.ts \ i18n/lumina-config_ar.ts \ i18n/lumina-config_az.ts \ diff --git a/src-qt5/core-utils/lumina-config/main.cpp b/src-qt5/core-utils/lumina-config/main.cpp index 8df7db48..b958c10e 100644 --- a/src-qt5/core-utils/lumina-config/main.cpp +++ b/src-qt5/core-utils/lumina-config/main.cpp @@ -7,7 +7,7 @@ #include "mainWindow.h" #include <LuminaOS.h> -#include <LuminaUtils.h> +#include <LUtils.h> #include <LuminaThemes.h> #include <LuminaSingleApplication.h> #include <LuminaXDG.h> diff --git a/src-qt5/core-utils/lumina-config/pages/page_session_options.cpp b/src-qt5/core-utils/lumina-config/pages/page_session_options.cpp index 91f3a0d0..333f9da8 100644 --- a/src-qt5/core-utils/lumina-config/pages/page_session_options.cpp +++ b/src-qt5/core-utils/lumina-config/pages/page_session_options.cpp @@ -122,12 +122,12 @@ void page_session_options::sessionChangeUserIcon(){ } void page_session_options::sessionResetSys(){ - LUtils::LoadSystemDefaults(); + LDesktopUtils::LoadSystemDefaults(); QTimer::singleShot(500,this, SLOT(LoadSettings()) ); } void page_session_options::sessionResetLumina(){ - LUtils::LoadSystemDefaults(true); //skip OS customizations + LDesktopUtils::LoadSystemDefaults(true); //skip OS customizations QTimer::singleShot(500,this, SLOT(LoadSettings()) ); } diff --git a/src-qt5/core-utils/lumina-search/Worker.cpp b/src-qt5/core-utils/lumina-search/Worker.cpp index 0d50d4b8..677d2b4b 100644 --- a/src-qt5/core-utils/lumina-search/Worker.cpp +++ b/src-qt5/core-utils/lumina-search/Worker.cpp @@ -2,7 +2,7 @@ #include <QTimer> #include <LuminaXDG.h> -#include <LuminaUtils.h> +#include <LUtils.h> Worker::Worker(QObject *parent) : QObject(parent){ //Get the list of all applications and save them in an easily-searchable form diff --git a/src-qt5/core-utils/lumina-search/lumina-search.pro b/src-qt5/core-utils/lumina-search/lumina-search.pro index e42142c6..c0186ce4 100644 --- a/src-qt5/core-utils/lumina-search/lumina-search.pro +++ b/src-qt5/core-utils/lumina-search/lumina-search.pro @@ -10,6 +10,12 @@ target.path = $${L_BINDIR} TEMPLATE = app +#include all the special classes from the Lumina tree +include(../../core/libLumina/LUtils.pri) #includes LUtils +include(../../core/libLumina/LuminaXDG.pri) +include(../../core/libLumina/LuminaSingleApplication.pri) +include(../../core/libLumina/LuminaThemes.pri) + SOURCES += main.cpp \ MainUI.cpp \ Worker.cpp \ @@ -22,10 +28,6 @@ HEADERS += MainUI.h \ FORMS += MainUI.ui \ ConfigUI.ui -LIBS += -lLuminaUtils - -DEPENDPATH += ../libLumina - TRANSLATIONS = i18n/lumina-search_af.ts \ i18n/lumina-search_ar.ts \ i18n/lumina-search_az.ts \ diff --git a/src-qt5/core-utils/lumina-search/main.cpp b/src-qt5/core-utils/lumina-search/main.cpp index 5b2b0479..5eee7c32 100644 --- a/src-qt5/core-utils/lumina-search/main.cpp +++ b/src-qt5/core-utils/lumina-search/main.cpp @@ -6,7 +6,7 @@ #include "MainUI.h" #include <LuminaOS.h> #include <LuminaThemes.h> -#include <LuminaUtils.h> +#include <LUtils.h> //==== INPUT FORMAT ==== // lumina-search [-no-excludes] [-dir [directory]] [-search <term>] diff --git a/src-qt5/core-utils/lumina-xconfig/MainUI.cpp b/src-qt5/core-utils/lumina-xconfig/MainUI.cpp index 2aed4d30..169302ca 100644 --- a/src-qt5/core-utils/lumina-xconfig/MainUI.cpp +++ b/src-qt5/core-utils/lumina-xconfig/MainUI.cpp @@ -8,7 +8,7 @@ #include "ui_MainUI.h" #include <LuminaXDG.h> -#include <LuminaUtils.h> +#include <LUtils.h> #include <QTimer> diff --git a/src-qt5/core-utils/lumina-xconfig/ScreenSettings.cpp b/src-qt5/core-utils/lumina-xconfig/ScreenSettings.cpp index 43584a1c..91e1f498 100644 --- a/src-qt5/core-utils/lumina-xconfig/ScreenSettings.cpp +++ b/src-qt5/core-utils/lumina-xconfig/ScreenSettings.cpp @@ -5,7 +5,7 @@ // See the LICENSE file for full details //=========================================== #include "ScreenSettings.h" -#include <LuminaUtils.h> +#include <LUtils.h> #include <QDebug> #include <QSettings> diff --git a/src-qt5/core-utils/lumina-xconfig/lumina-xconfig.pro b/src-qt5/core-utils/lumina-xconfig/lumina-xconfig.pro index a7a34fe9..2fb792d6 100644 --- a/src-qt5/core-utils/lumina-xconfig/lumina-xconfig.pro +++ b/src-qt5/core-utils/lumina-xconfig/lumina-xconfig.pro @@ -8,6 +8,12 @@ target.path = $${L_BINDIR} TEMPLATE = app +#include all the special classes from the Lumina tree +include(../../core/libLumina/LUtils.pri) #includes LUtils +include(../../core/libLumina/LuminaXDG.pri) +include(../../core/libLumina/LuminaSingleApplication.pri) +include(../../core/libLumina/LuminaThemes.pri) + SOURCES += main.cpp \ mainUI.cpp \ ScreenSettings.cpp @@ -17,12 +23,6 @@ HEADERS += mainUI.h \ FORMS += mainUI.ui -# RESOURCES+= lumina-config.qrc - - -LIBS += -lLuminaUtils - -DEPENDPATH += ../libLumina TRANSLATIONS = i18n/lumina-xconfig_af.ts \ i18n/lumina-xconfig_ar.ts \ diff --git a/src-qt5/core-utils/lumina-xconfig/main.cpp b/src-qt5/core-utils/lumina-xconfig/main.cpp index f30486f4..2596bf7a 100644 --- a/src-qt5/core-utils/lumina-xconfig/main.cpp +++ b/src-qt5/core-utils/lumina-xconfig/main.cpp @@ -6,7 +6,7 @@ #include "MainUI.h" #include <LuminaOS.h> #include <LuminaThemes.h> -#include <LuminaUtils.h> +#include <LUtils.h> #include <LuminaSingleApplication.h> #include "ScreenSettings.h" diff --git a/src-qt5/core/colors/Black.qss.colors b/src-qt5/core/colors/Black.qss.colors new file mode 100644 index 00000000..b6269188 --- /dev/null +++ b/src-qt5/core/colors/Black.qss.colors @@ -0,0 +1,13 @@ +ACCENTCOLOR=rgba(204,204,204,200) +ACCENTDISABLECOLOR=rgba(204,204,204,100) +ALTBASECOLOR=rgb(37,37,37) +BASECOLOR=rgb(36,36,36) +HIGHLIGHTCOLOR=rgba(218,222,226,170) +HIGHLIGHTDISABLECOLOR=rgba(218,222,226,160) +PRIMARYCOLOR=rgba(0,0,4,250) +PRIMARYDISABLECOLOR=rgba(0,0,0,180) +SECONDARYCOLOR=rgba(192,192,192,200) +SECONDARYDISABLECOLOR=rgba(192,192,192,100) +TEXTCOLOR=white +TEXTDISABLECOLOR=darkgrey +TEXTHIGHLIGHTCOLOR=black diff --git a/src-qt5/core/colors/Blue-Light.qss.colors b/src-qt5/core/colors/Blue-Light.qss.colors new file mode 100644 index 00000000..5bcb85f6 --- /dev/null +++ b/src-qt5/core/colors/Blue-Light.qss.colors @@ -0,0 +1,13 @@ +ACCENTCOLOR=rgba(157,161,165,200) +ACCENTDISABLECOLOR=rgba(156,156,157,200) +ALTBASECOLOR=rgb(239,247,255) +BASECOLOR=rgb(165,210,255) +HIGHLIGHTCOLOR=rgb(110,158,208) +HIGHLIGHTDISABLECOLOR=rgba(110,158,208,150) +PRIMARYCOLOR=rgba(181,212,238,200) +PRIMARYDISABLECOLOR=rgba(234,237,238,100) +SECONDARYCOLOR=rgba(200,222,243,200) +SECONDARYDISABLECOLOR=rgba(200,222,243,100) +TEXTCOLOR=black +TEXTDISABLECOLOR=grey +TEXTHIGHLIGHTCOLOR=black diff --git a/src-qt5/core/colors/Grey-Dark.qss.colors b/src-qt5/core/colors/Grey-Dark.qss.colors new file mode 100644 index 00000000..207edd04 --- /dev/null +++ b/src-qt5/core/colors/Grey-Dark.qss.colors @@ -0,0 +1,13 @@ +ACCENTCOLOR=rgba(43,43,45,200) +ACCENTDISABLECOLOR=rgba(43,43,45,100) +ALTBASECOLOR=rgb(63,61,61) +BASECOLOR=rgb(93,92,92) +HIGHLIGHTCOLOR=rgba(218,222,226,170) +HIGHLIGHTDISABLECOLOR=rgba(218,222,226,160) +PRIMARYCOLOR=rgba(75,77,80,240) +PRIMARYDISABLECOLOR=rgba(75,77,80,180) +SECONDARYCOLOR=rgba(144,140,142,200) +SECONDARYDISABLECOLOR=rgba(144,140,142,100) +TEXTCOLOR=white +TEXTDISABLECOLOR=darkgrey +TEXTHIGHLIGHTCOLOR=black diff --git a/src-qt5/core/colors/Lumina-Glass.qss.colors b/src-qt5/core/colors/Lumina-Glass.qss.colors new file mode 100644 index 00000000..89534aaa --- /dev/null +++ b/src-qt5/core/colors/Lumina-Glass.qss.colors @@ -0,0 +1,13 @@ +ACCENTCOLOR=rgba(255,252,234,100) +ACCENTDISABLECOLOR=rgba(0,0,0,100) +ALTBASECOLOR=rgba(255,255,255,125) +BASECOLOR=rgb(247,246,244) +HIGHLIGHTCOLOR=rgba(212,212,212,170) +HIGHLIGHTDISABLECOLOR=rgba(184,184,184,100) +PRIMARYCOLOR=rgba(235,242,242,200) +PRIMARYDISABLECOLOR=rgba(214,220,220,200) +SECONDARYCOLOR=rgba(100,100,100,200) +SECONDARYDISABLECOLOR=rgba(100,100,100,100) +TEXTCOLOR=black +TEXTDISABLECOLOR=grey +TEXTHIGHLIGHTCOLOR=black diff --git a/src-qt5/core/colors/Lumina-Gold.qss.colors b/src-qt5/core/colors/Lumina-Gold.qss.colors new file mode 100644 index 00000000..cfad7069 --- /dev/null +++ b/src-qt5/core/colors/Lumina-Gold.qss.colors @@ -0,0 +1,13 @@ +ACCENTCOLOR=rgba(149,144,122,200) +ACCENTDISABLECOLOR=rgba(74,71,60,200) +ALTBASECOLOR=rgb(230,227,204) +BASECOLOR=rgb(247,247,240) +HIGHLIGHTCOLOR=rgba(252,237,149,170) +HIGHLIGHTDISABLECOLOR=rgba(252,237,149,100) +PRIMARYCOLOR=rgba(238,234,226,200) +PRIMARYDISABLECOLOR=rgba(238,235,224,100) +SECONDARYCOLOR=rgba(247,209,112,200) +SECONDARYDISABLECOLOR=rgba(234,198,106,150) +TEXTCOLOR=black +TEXTDISABLECOLOR=grey +TEXTHIGHLIGHTCOLOR=black \ No newline at end of file diff --git a/src-qt5/core/colors/Lumina-Green.qss.colors b/src-qt5/core/colors/Lumina-Green.qss.colors new file mode 100644 index 00000000..99f16acb --- /dev/null +++ b/src-qt5/core/colors/Lumina-Green.qss.colors @@ -0,0 +1,13 @@ +ACCENTCOLOR=rgba(149,144,122,200) +ACCENTDISABLECOLOR=rgba(74,71,60,200) +ALTBASECOLOR=rgb(230,230,230) +BASECOLOR=rgb(247,246,244) +HIGHLIGHTCOLOR=rgba(66,153,76,170) +HIGHLIGHTDISABLECOLOR=rgba(66,153,76,100) +PRIMARYCOLOR=rgba(229,231,238,200) +PRIMARYDISABLECOLOR=rgba(229,231,238,100) +SECONDARYCOLOR=rgba(76,197,84,200) +SECONDARYDISABLECOLOR=rgba(76,197,84,150) +TEXTCOLOR=black +TEXTDISABLECOLOR=grey +TEXTHIGHLIGHTCOLOR=black diff --git a/src-qt5/core/colors/Lumina-Purple.qss.colors b/src-qt5/core/colors/Lumina-Purple.qss.colors new file mode 100644 index 00000000..f2ba7e05 --- /dev/null +++ b/src-qt5/core/colors/Lumina-Purple.qss.colors @@ -0,0 +1,13 @@ +ACCENTCOLOR=rgba(247,231,255,200) +ACCENTDISABLECOLOR=rgba(167,166,166,200) +ALTBASECOLOR=rgb(63,61,61) +BASECOLOR=rgb(93,92,92) +HIGHLIGHTCOLOR=rgba(76,38,171,170) +HIGHLIGHTDISABLECOLOR=rgba(57,19,139,170) +PRIMARYCOLOR=rgba(65,67,80,240) +PRIMARYDISABLECOLOR=rgba(65,67,80,180) +SECONDARYCOLOR=rgba(74,65,120,200) +SECONDARYDISABLECOLOR=rgba(71,65,120,100) +TEXTCOLOR=white +TEXTDISABLECOLOR=darkgrey +TEXTHIGHLIGHTCOLOR=white \ No newline at end of file diff --git a/src-qt5/core/colors/Lumina-Red.qss.colors b/src-qt5/core/colors/Lumina-Red.qss.colors new file mode 100644 index 00000000..f73bdb75 --- /dev/null +++ b/src-qt5/core/colors/Lumina-Red.qss.colors @@ -0,0 +1,13 @@ +ACCENTCOLOR=rgba(255,244,245,200) +ACCENTDISABLECOLOR=rgba(167,166,166,200) +ALTBASECOLOR=rgb(63,61,61) +BASECOLOR=rgb(93,92,92) +HIGHLIGHTCOLOR=rgba(175,9,9,170) +HIGHLIGHTDISABLECOLOR=rgba(154,20,20,170) +PRIMARYCOLOR=rgba(80,66,66,240) +PRIMARYDISABLECOLOR=rgba(80,66,66,180) +SECONDARYCOLOR=rgba(120,22,23,200) +SECONDARYDISABLECOLOR=rgba(120,22,23,100) +TEXTCOLOR=white +TEXTDISABLECOLOR=darkgrey +TEXTHIGHLIGHTCOLOR=white \ No newline at end of file diff --git a/src-qt5/core/colors/PCBSD10-Default.qss.colors b/src-qt5/core/colors/PCBSD10-Default.qss.colors new file mode 100644 index 00000000..efcea51d --- /dev/null +++ b/src-qt5/core/colors/PCBSD10-Default.qss.colors @@ -0,0 +1,13 @@ +ACCENTCOLOR=rgba(182,186,191,200) +ACCENTDISABLECOLOR=rgba(190,190,191,200) +ALTBASECOLOR=rgb(241,241,241) +BASECOLOR=rgb(247,246,244) +HIGHLIGHTCOLOR=rgb(129,184,243) +HIGHLIGHTDISABLECOLOR=rgba(129,184,243,150) +PRIMARYCOLOR=rgba(224,236,238,200) +PRIMARYDISABLECOLOR=rgba(234,237,238,100) +SECONDARYCOLOR=rgba(200,222,243,200) +SECONDARYDISABLECOLOR=rgba(200,222,243,100) +TEXTCOLOR=black +TEXTDISABLECOLOR=grey +TEXTHIGHLIGHTCOLOR=black diff --git a/src-qt5/core/colors/Solarized-Dark.qss.colors b/src-qt5/core/colors/Solarized-Dark.qss.colors new file mode 100644 index 00000000..d4f0f1c9 --- /dev/null +++ b/src-qt5/core/colors/Solarized-Dark.qss.colors @@ -0,0 +1,16 @@ +# Solarized is a theme created by Ethan Schoonover +# See the project site at http://ethanschoonover.com/solarized +# Or see the source at https://github.com/altercation/solarized +ACCENTCOLOR=rgb(181,137,0) +ACCENTDISABLECOLOR=rgb(181,137,0) +ALTBASECOLOR=rgb(0,43,54) +BASECOLOR=rgb(0,43,54) +HIGHLIGHTCOLOR=rgb(7,54,66) +HIGHLIGHTDISABLECOLOR=rgb(7,53,66) +PRIMARYCOLOR=rgb(0,43,54) +PRIMARYDISABLECOLOR=rgb(7,54,66) +SECONDARYCOLOR=rgb(0,43,54) +SECONDARYDISABLECOLOR=rgb(7,54,66) +TEXTCOLOR=rgb(131,148,150) +TEXTDISABLECOLOR=rgb(88,110,117) +TEXTHIGHLIGHTCOLOR=rgb(147,161,161) diff --git a/src-qt5/core/colors/Solarized-Light.qss.colors b/src-qt5/core/colors/Solarized-Light.qss.colors new file mode 100644 index 00000000..fead1915 --- /dev/null +++ b/src-qt5/core/colors/Solarized-Light.qss.colors @@ -0,0 +1,16 @@ +# Solarized is a theme created by Ethan Schoonover +# See the project site at http://ethanschoonover.com/solarized +# Or see the source at https://github.com/altercation/solarized +ACCENTCOLOR=rgb(38,139,210) +ACCENTDISABLECOLOR=rgb(38,139,210) +ALTBASECOLOR=rgb(253,246,227) +BASECOLOR=rgb(253,246,227) +HIGHLIGHTCOLOR=rgb(238,232,213) +HIGHLIGHTDISABLECOLOR=rgb(238,232,213) +PRIMARYCOLOR=rgb(253,246,227) +PRIMARYDISABLECOLOR=rgb(238,232,213) +SECONDARYCOLOR=rgb(253,246,227) +SECONDARYDISABLECOLOR=rgb(238,232,213) +TEXTCOLOR=rgb(131,148,150) +TEXTDISABLECOLOR=rgb(147,161,161) +TEXTHIGHLIGHTCOLOR=rgb(88,110,117) diff --git a/src-qt5/core/core.pro b/src-qt5/core/core.pro index a0d0db3e..27aff3a2 100644 --- a/src-qt5/core/core.pro +++ b/src-qt5/core/core.pro @@ -4,23 +4,31 @@ include("../OS-detect.pri") TEMPLATE = subdirs CONFIG += recursive -SUBDIRS+= libLumina \ - lumina-desktop \ +SUBDIRS+= lumina-desktop \ lumina-session \ lumina-open \ lumina-info # lumina-wm-INCOMPLETE \ # lumina-checkpass - -#Make sure to list libLumina as a requirement for the others (for parallellized builds) -lumina-desktop.depends = libLumina -lumina-session.depends = libLumina -lumina-open.depends = libLumina -lumina-info.depends = libLumina - #Also install any special menu scripts scripts.path = $${L_SHAREDIR}/lumina-desktop/menu-scripts scripts.files = menu-scripts/* -INSTALLS+=scripts +#Color themes +colors.path=$${L_SHAREDIR}/lumina-desktop/colors +colors.files=colors/*.qss.colors + +#Theme templates +themes.path=$${L_SHAREDIR}/lumina-desktop/themes/ +themes.files=themes/*.qss.template + +#QtQuick plugins +#quickplugins.path=$${L_SHAREDIR}/lumina-desktop/quickplugins/ +#quickplugins.files=quickplugins/* + +#Mimetype globs +globs.path=$${L_SHAREDIR}/lumina-desktop +globs.files=xtrafiles/globs2 + +INSTALLS+=scripts colors themes globs diff --git a/src-qt5/core/libLumina/LDesktopUtils.cpp b/src-qt5/core/libLumina/LDesktopUtils.cpp new file mode 100644 index 00000000..4f8d94ef --- /dev/null +++ b/src-qt5/core/libLumina/LDesktopUtils.cpp @@ -0,0 +1,550 @@ +//=========================================== +// Lumina-DE source code +// Copyright (c) 2012-2016, Ken Moore +// Available under the 3-clause BSD license +// See the LICENSE file for full details +//=========================================== +#include "LDesktopUtils.h" + +#include <QDesktopWidget> +#include <QApplication> +#include <QScreen> + +#include "LuminaThemes.h" + +static QStringList fav; + +QString LDesktopUtils::LuminaDesktopVersion(){ + QString ver = "1.1.1"; + #ifdef GIT_VERSION + ver.append( QString(" (Git Revision: %1)").arg(GIT_VERSION) ); + #endif + return ver; +} + +QString LDesktopUtils::LuminaDesktopBuildDate(){ + #ifdef BUILD_DATE + return BUILD_DATE; + #endif + return ""; +} + +//Various function for finding valid QtQuick plugins on the system +bool LDesktopUtils::validQuickPlugin(QString ID){ + return ( !LDesktopUtils::findQuickPluginFile(ID).isEmpty() ); +} + +QString LDesktopUtils::findQuickPluginFile(QString ID){ + if(ID.startsWith("quick-")){ ID = ID.section("-",1,50); } //just in case + //Give preference to any user-supplied plugins (overwrites for system plugins) + QString path = QString(getenv("XDG_CONFIG_HOME"))+"/lumina-desktop/quickplugins/quick-"+ID+".qml"; + if( QFile::exists(path) ){return path; } + path = LOS::LuminaShare()+"quickplugins/quick-"+ID+".qml"; + if( QFile::exists(path) ){return path; } + return ""; //could not be found +} + +QStringList LDesktopUtils::listQuickPlugins(){ + QDir dir(QString(getenv("XDG_CONFIG_HOME"))+"/lumina-desktop/quickplugins"); + QStringList files = dir.entryList(QStringList() << "quick-*.qml", QDir::Files | QDir::NoDotAndDotDot, QDir::Name); + dir.cd(LOS::LuminaShare()+"quickplugins"); + files << dir.entryList(QStringList() << "quick-*.qml", QDir::Files | QDir::NoDotAndDotDot, QDir::Name); + for(int i=0; i<files.length(); i++){ + files[i] = files[i].section("quick-",1,100).section(".qml",0,0); //just grab the ID out of the middle of the filename + } + files.removeDuplicates(); + //qDebug() << "Found Quick Plugins:" << files; + return files; +} + +QStringList LDesktopUtils::infoQuickPlugin(QString ID){ //Returns: [Name, Description, Icon] + //qDebug() << "Find Quick Info:" << ID; + QString path = findQuickPluginFile(ID); + //qDebug() << " - path:" << path; + if(path.isEmpty()){ return QStringList(); } //invalid ID + QStringList contents = LUtils::readFile(path); + if(contents.isEmpty()){ return QStringList(); } //invalid file (unreadable) + contents = contents.filter("//").filter("=").filter("Plugin"); //now just grab the comments + //qDebug() << " - Filtered Contents:" << contents; + QStringList info; info << "" << "" << ""; + for(int i=0; i<contents.length(); i++){ + if(contents[i].contains("Plugin-Name=")){ info[0] = contents[i].section("Plugin-Name=",1,1).simplified(); } + else if(contents[i].contains("Plugin-Description=")){ info[1] = contents[i].section("Plugin-Description=",1,1).simplified(); } + else if(contents[i].contains("Plugin-Icon=")){ info[2] = contents[i].section("Plugin-Icon=",1,1).simplified(); } + } + if(info[0].isEmpty()){ info[0]=ID; } + if(info[2].isEmpty()){ info[2]="preferences-plugin"; } + //qDebug() << " - info:" << info; + return info; +} + +QStringList LDesktopUtils::listFavorites(){ + static QDateTime lastRead; + QDateTime cur = QDateTime::currentDateTime(); + if(lastRead.isNull() || lastRead<QFileInfo( QString(getenv("XDG_CONFIG_HOME"))+"/lumina-desktop/favorites.list").lastModified()){ + fav = LUtils::readFile(QString(getenv("XDG_CONFIG_HOME"))+"/lumina-desktop/favorites.list"); + fav.removeAll(""); //remove any empty lines + fav.removeDuplicates(); + lastRead = cur; + } + + return fav; +} + +bool LDesktopUtils::saveFavorites(QStringList list){ + list.removeDuplicates(); + bool ok = LUtils::writeFile(QString(getenv("XDG_CONFIG_HOME"))+"/lumina-desktop/favorites.list", list, true); + if(ok){ fav = list; } //also save internally in case of rapid write/read of the file + return ok; +} + +bool LDesktopUtils::isFavorite(QString path){ + QStringList fav = LDesktopUtils::listFavorites(); + for(int i=0; i<fav.length(); i++){ + if(fav[i].endsWith("::::"+path)){ return true; } + } + return false; +} + +bool LDesktopUtils::addFavorite(QString path, QString name){ + //Generate the type of favorite this is + QFileInfo info(path); + QString type; + if(info.isDir()){ type="dir"; } + else if(info.suffix()=="desktop"){ type="app"; } + else{ type = LXDG::findAppMimeForFile(path); } + //Assign a name if none given + if(name.isEmpty()){ name = info.fileName(); } + //Now add it to the list + QStringList favs = LDesktopUtils::listFavorites(); + bool found = false; + for(int i=0; i<favs.length(); i++){ + if(favs[i].endsWith("::::"+path)){ favs[i] = name+"::::"+type+"::::"+path; } + } + if(!found){ favs << name+"::::"+type+"::::"+path; } + return LDesktopUtils::saveFavorites(favs); +} + +void LDesktopUtils::removeFavorite(QString path){ + QStringList fav = LDesktopUtils::listFavorites(); + bool changed = false; + for(int i=0; i<fav.length(); i++){ + if(fav[i].endsWith("::::"+path)){ fav.removeAt(i); i--; changed=true;} + } + if(changed){ LDesktopUtils::saveFavorites(fav); } +} + +void LDesktopUtils::upgradeFavorites(int fromoldversionnumber){ + /*if(fromoldversionnumber <= 8004){ // < pre-0.8.4>, sym-links in the ~/.lumina/favorites dir} + //Include 0.8.4-devel versions in this upgrade (need to distinguish b/w devel and release versions later somehow) + QDir favdir(QDir::homePath()+"/.lumina/favorites"); + QFileInfoList symlinks = favdir.entryInfoList(QDir::Files | QDir::Dirs | QDir::System | QDir::NoDotAndDotDot); + QStringList favfile = LDesktopUtils::listFavorites(); //just in case some already exist + bool newentry = false; + for(int i=0; i<symlinks.length(); i++){ + if(!symlinks[i].isSymLink()){ continue; } //not a symlink + QString path = symlinks[i].symLinkTarget(); + QString name = symlinks[i].fileName(); //just use the name of the symlink from the old system + QString type; + if(symlinks[i].isDir()){ type = "dir"; } + else if(name.endsWith(".desktop")){ type = "app"; } + else{ type = LXDG::findAppMimeForFile(path); } + //Put the line into the file + favfile << name+"::::"+type+"::::"+path; + //Now remove the symlink - obsolete format + QFile::remove(symlinks[i].absoluteFilePath()); + newentry = true; + } + if(newentry){ + LDesktopUtils::saveFavorites(favfile); + } + }*/ //end check for version <= 0.8.4 + +} + +void LDesktopUtils::LoadSystemDefaults(bool skipOS){ + //Will create the Lumina configuration files based on the current system template (if any) + qDebug() << "Loading System Defaults"; + QStringList sysDefaults; + if(!skipOS){ sysDefaults = LUtils::readFile(LOS::AppPrefix()+"etc/luminaDesktop.conf"); } + if(sysDefaults.isEmpty() && !skipOS){ sysDefaults = LUtils::readFile(LOS::AppPrefix()+"etc/luminaDesktop.conf.dist"); } + if(sysDefaults.isEmpty() && !skipOS) { sysDefaults = LUtils::readFile(LOS::SysPrefix()+"etc/luminaDesktop.conf"); } + if(sysDefaults.isEmpty() && !skipOS){ sysDefaults = LUtils::readFile(LOS::SysPrefix()+"etc/luminaDesktop.conf.dist"); } + if(sysDefaults.isEmpty() && !skipOS) { sysDefaults = LUtils::readFile(L_ETCDIR+"/luminaDesktop.conf"); } + if(sysDefaults.isEmpty() && !skipOS){ sysDefaults = LUtils::readFile(L_ETCDIR+"/luminaDesktop.conf.dist"); } + if(sysDefaults.isEmpty()){ sysDefaults = LUtils::readFile(LOS::LuminaShare()+"luminaDesktop.conf"); } + //Find the number of the left-most desktop screen + QString screen = "0"; + QDesktopWidget *desk =QApplication::desktop(); + QRect screenGeom; + for(int i=0; i<desk->screenCount(); i++){ + if(desk->screenGeometry(i).x()==0){ + screen = QString::number(i); + screenGeom = desk->screenGeometry(i); + break; + } + } + //Now setup the default "desktopsettings.conf" and "sessionsettings.conf" files + QStringList deskset, sesset;//, lopenset; + + // -- SESSION SETTINGS -- + QStringList tmp = sysDefaults.filter("session_"); + if(tmp.isEmpty()){ tmp = sysDefaults.filter("session."); }//for backwards compat + sesset << "[General]"; //everything is in this section + sesset << "DesktopVersion="+LDesktopUtils::LuminaDesktopVersion(); + for(int i=0; i<tmp.length(); i++){ + if(tmp[i].startsWith("#") || !tmp[i].contains("=") ){ continue; } + QString var = tmp[i].section("=",0,0).toLower().simplified(); + QString val = tmp[i].section("=",1,1).section("#",0,0).simplified(); + if(val.isEmpty()){ continue; } + QString istrue = (val.toLower()=="true") ? "true": "false"; + //Change in 0.8.5 - use "_" instead of "." within variables names - need backwards compat for a little while + if(var.contains(".")){ var.replace(".","_"); } + //Now parse the variable and put the value in the proper file + + if(var.contains("_default_")){ val = LUtils::AppToAbsolute(val); } //got an application/binary + //Special handling for values which need to exist first + if(var.endsWith("_ifexists") ){ + var = var.remove("_ifexists"); //remove this flag from the variable + //Check if the value exists (absolute path only) + if(!QFile::exists(val)){ continue; } //skip this line - value/file does not exist + } + + //Parse/save the value + QString sset; //temporary strings + if(var=="session_enablenumlock"){ sset = "EnableNumlock="+ istrue; } + else if(var=="session_playloginaudio"){ sset = "PlayStartupAudio="+istrue; } + else if(var=="session_playlogoutaudio"){ sset = "PlayLogoutAudio="+istrue; } + else if(var=="session_default_terminal"){ + LXDG::setDefaultAppForMime("application/terminal", val); + //sset = "default-terminal="+val; + }else if(var=="session_default_filemanager"){ + LXDG::setDefaultAppForMime("inode/directory", val); + //sset = "default-filemanager="+val; + //loset = "directory="+val; + }else if(var=="session_default_webbrowser"){ + //loset = "webbrowser="+val; + LXDG::setDefaultAppForMime("x-scheme-handler/http", val); + LXDG::setDefaultAppForMime("x-scheme-handler/https", val); + }else if(var=="session_default_email"){ + LXDG::setDefaultAppForMime("application/email",val); + //loset = "email="+val; + } + //Put the line into the file (overwriting any previous assignment as necessary) + /*if(!loset.isEmpty()){ + int index = lopenset.indexOf(QRegExp(loset.section("=",0,0)+"=*", Qt::CaseSensitive, QRegExp::Wildcard)); + qDebug() << "loset line:" << loset << index << lopenset; + if(index<0){ lopenset << loset; } //new line + else{ lopenset[index] = loset; } //overwrite the other line + }*/ + if(!sset.isEmpty()){ + int index = sesset.indexOf(QRegExp(sset.section("=",0,0)+"=*", Qt::CaseSensitive, QRegExp::Wildcard)); + if(index<0){ sesset << sset; } //new line + else{ sesset[index] = sset; } //overwrite the other line + } + } + //if(!lopenset.isEmpty()){ lopenset.prepend("[default]"); } //the session options exist within this set + + // -- MIMETYPE DEFAULTS -- + tmp = sysDefaults.filter("mime_default_"); + for(int i=0; i<tmp.length(); i++){ + if(tmp[i].startsWith("#") || !tmp[i].contains("=") ){ continue; } + QString var = tmp[i].section("=",0,0).toLower().simplified(); + QString val = tmp[i].section("=",1,1).section("#",0,0).simplified(); + if(val.isEmpty()){ continue; } + QString istrue = (val.toLower()=="true") ? "true": "false"; + //Change in 0.8.5 - use "_" instead of "." within variables names - need backwards compat for a little while + if(var.contains(".")){ var.replace(".","_"); } + //Now parse the variable and put the value in the proper file + val = LUtils::AppToAbsolute(val); + //Special handling for values which need to exist first + if(var.endsWith("_ifexists") ){ + var = var.remove("_ifexists"); //remove this flag from the variable + //Check if the value exists (absolute path only) + if(!QFile::exists(val)){ continue; } //skip this line - value/file does not exist + } + //Now turn this variable into the mimetype only + var = var.section("_default_",1,-1); + LXDG::setDefaultAppForMime(var, val); + } + + // -- DESKTOP SETTINGS -- + //(only works for the primary desktop at the moment) + tmp = sysDefaults.filter("desktop_"); + if(tmp.isEmpty()){ tmp = sysDefaults.filter("desktop."); }//for backwards compat + if(!tmp.isEmpty()){deskset << "[desktop-"+screen+"]"; } + for(int i=0; i<tmp.length(); i++){ + if(tmp[i].startsWith("#") || !tmp[i].contains("=") ){ continue; } + QString var = tmp[i].section("=",0,0).toLower().simplified(); + QString val = tmp[i].section("=",1,1).section("#",0,0).simplified(); + if(val.isEmpty()){ continue; } + QString istrue = (val.toLower()=="true") ? "true": "false"; + //Change in 0.8.5 - use "_" instead of "." within variables names - need backwards compat for a little while + if(var.contains(".")){ var.replace(".","_"); } + //Now parse the variable and put the value in the proper file + if(var=="desktop_visiblepanels"){ deskset << "panels="+val; } + else if(var=="desktop_backgroundfiles"){ deskset << "background\\filelist="+val; } + else if(var=="desktop_backgroundrotateminutes"){ deskset << "background\\minutesToChange="+val; } + else if(var=="desktop_plugins"){ deskset << "pluginlist="+val; } + else if(var=="desktop_generate_icons"){ deskset << "generateDesktopIcons="+istrue; } + } + if(!tmp.isEmpty()){ deskset << ""; } //space between sections + + // -- PANEL SETTINGS -- + //(only works for the primary desktop at the moment) + for(int i=1; i<11; i++){ + QString panvar = "panel"+QString::number(i); + tmp = sysDefaults.filter(panvar); + if(!tmp.isEmpty()){deskset << "[panel"+screen+"."+QString::number(i-1)+"]"; } + for(int i=0; i<tmp.length(); i++){ + if(tmp[i].startsWith("#") || !tmp[i].contains("=") ){ continue; } + QString var = tmp[i].section("=",0,0).toLower().simplified(); + QString val = tmp[i].section("=",1,1).section("#",0,0).simplified(); + if(val.isEmpty()){ continue; } + QString istrue = (val.toLower()=="true") ? "true": "false"; + //Change in 0.8.5 - use "_" instead of "." within variables names - need backwards compat for a little while + if(var.contains(".")){ var.replace(".","_"); } + //Now parse the variable and put the value in the proper file + if(var==(panvar+"_pixelsize")){ + //qDebug() << "Panel Size:" << val; + if(val.contains("%")){ + QString last = val.section("%",1,1).toLower(); //last character + val = val.section("%",0,0); + if(last=="h"){ val = QString::number( qRound(screenGeom.height()*val.toDouble())/100 ); }//adjust value to a percentage of the height of the screen + else if(last=="w"){ val = QString::number( qRound(screenGeom.width()*val.toDouble())/100 ); }//adjust value to a percentage of the width of the screen + } + //qDebug() << " -- Adjusted:" << val; + deskset << "height="+val; + } + else if(var==(panvar+"_autohide")){ deskset << "hidepanel="+istrue; } + else if(var==(panvar+"_location")){ deskset << "location="+val.toLower(); } + else if(var==(panvar+"_plugins")){ deskset << "pluginlist="+val; } + else if(var==(panvar+"_pinlocation")){ deskset << "pinLocation="+val.toLower(); } + else if(var==(panvar+"_edgepercent")){ deskset << "lengthPercent="+val; } + } + if(!tmp.isEmpty()){ deskset << ""; } //space between sections + } + + // -- MENU settings -- + tmp = sysDefaults.filter("menu_"); + if(tmp.isEmpty()){ tmp = sysDefaults.filter("menu."); } //backwards compat + if(!tmp.isEmpty()){deskset << "[menu]"; } + for(int i=0; i<tmp.length(); i++){ + if(tmp[i].startsWith("#") || !tmp[i].contains("=") ){ continue; } + QString var = tmp[i].section("=",0,0).simplified(); + QString val = tmp[i].section("=",1,1).section("#",0,0).toLower().simplified(); + if(val.isEmpty()){ continue; } + //Change in 0.8.5 - use "_" instead of "." within variables names - need backwards compat for a little while + if(var.contains(".")){ var.replace(".","_"); } + //Now parse the variable and put the value in the proper file + if(var=="menu_plugins"){ deskset << "itemlist="+val; } + } + if(!tmp.isEmpty()){ deskset << ""; } //space between sections + + // -- FAVORITES -- + tmp = sysDefaults.filter("favorites_"); + if(tmp.isEmpty()){ tmp = sysDefaults.filter("favorites."); } + for(int i=0; i<tmp.length(); i++){ + if(tmp[i].startsWith("#") || !tmp[i].contains("=") ){ continue; } + QString var = tmp[i].section("=",0,0).toLower().simplified(); + QString val = tmp[i].section("=",1,1).section("#",0,0).simplified(); + //Change in 0.8.5 - use "_" instead of "." within variables names - need backwards compat for a little while + if(var.contains(".")){ var.replace(".","_"); } + //Now parse the variable and put the value in the proper file + qDebug() << "Favorite entry:" << var << val; + val = LUtils::AppToAbsolute(val); //turn any relative files into absolute + if(var=="favorites_add_ifexists" && QFile::exists(val)){ qDebug() << " - Exists/Adding:"; LDesktopUtils::addFavorite(val); } + else if(var=="favorites_add"){ qDebug() << " - Adding:"; LDesktopUtils::addFavorite(val); } + else if(var=="favorites_remove"){ qDebug() << " - Removing:"; LDesktopUtils::removeFavorite(val); } + } + + // -- QUICKLAUNCH -- + tmp = sysDefaults.filter("quicklaunch_"); + if(tmp.isEmpty()){ tmp = sysDefaults.filter("quicklaunch."); } + QStringList quickL; + for(int i=0; i<tmp.length(); i++){ + if(tmp[i].startsWith("#") || !tmp[i].contains("=") ){ continue; } + QString var = tmp[i].section("=",0,0).toLower().simplified(); + QString val = tmp[i].section("=",1,1).section("#",0,0).simplified(); + //Change in 0.8.5 - use "_" instead of "." within variables names - need backwards compat for a little while + if(var.contains(".")){ var.replace(".","_"); } + //Now parse the variable and put the value in the proper file + val = LUtils::AppToAbsolute(val); //turn any relative files into absolute + if(var=="quicklaunch_add_ifexists" && QFile::exists(val)){ quickL << val; } + else if(var=="quicklaunch_add"){ quickL << val; } + } + if(!quickL.isEmpty()){ + if(sesset.isEmpty()){ sesset << "[General]"; } //everything is in this section + sesset << "QuicklaunchApps="+quickL.join(", "); + } + + //Now do any theme settings + QStringList themesettings = LTHEME::currentSettings(); + //List: [theme path, colorspath, iconsname, font, fontsize] + //qDebug() << "Current Theme Color:" << themesettings[1]; + tmp = sysDefaults.filter("theme_"); + if(tmp.isEmpty()){ tmp = sysDefaults.filter("theme."); } + bool setTheme = !tmp.isEmpty(); + for(int i=0; i<tmp.length(); i++){ + if(tmp[i].startsWith("#") || !tmp[i].contains("=") ){ continue; } + QString var = tmp[i].section("=",0,0).toLower().simplified(); + QString val = tmp[i].section("=",1,1).section("#",0,0).simplified(); + if(val.isEmpty()){ continue; } + //Change in 0.8.5 - use "_" instead of "." within variables names - need backwards compat for a little while + if(var.contains(".")){ var.replace(".","_"); } + //Now parse the variable and put the value in the proper file + if(var=="theme_themefile"){ themesettings[0] = val; } + else if(var=="theme_colorfile"){ themesettings[1] = val; } + else if(var=="theme_iconset"){ themesettings[2] = val; } + else if(var=="theme_font"){ themesettings[3] = val; } + else if(var=="theme_fontsize"){ + if(val.endsWith("%")){ val = QString::number( (screenGeom.height()*val.section("%",0,0).toDouble())/100 )+"px"; } + themesettings[4] = val; + } + } + //qDebug() << " - Now Color:" << themesettings[1] << setTheme; + + //Now double check that the custom theme/color files exist and reset it will the full path as necessary + if(setTheme){ + QStringList systhemes = LTHEME::availableSystemThemes(); + QStringList syscolors = LTHEME::availableSystemColors(); + //theme file + //qDebug() << "Detected Themes/colors:" << systhemes << syscolors; + if( !themesettings[0].startsWith("/") || !QFile::exists(themesettings[0]) || !themesettings[0].endsWith(".qss.template")){ + themesettings[0] = themesettings[0].section(".qss",0,0).simplified(); + for(int i=0; i<systhemes.length(); i++){ + if(systhemes[i].startsWith(themesettings[0]+"::::",Qt::CaseInsensitive)){ + themesettings[0] = systhemes[i].section("::::",1,1); //Replace with the full path + break; + } + } + } + //color file + if( !themesettings[1].startsWith("/") || !QFile::exists(themesettings[1]) || !themesettings[1].endsWith(".qss.colors") ){ + //Remove any extra/invalid extension + themesettings[1] = themesettings[1].section(".qss",0,0).simplified(); + for(int i=0; i<syscolors.length(); i++){ + if(syscolors[i].startsWith(themesettings[1]+"::::",Qt::CaseInsensitive)){ + themesettings[1] = syscolors[i].section("::::",1,1); //Replace with the full path + break; + } + } + } + } + //qDebug() << " - Final Theme Color:" << themesettings[1]; + + //Ensure that the settings directory exists + QString setdir = QString(getenv("XDG_CONFIG_HOME"))+"/lumina-desktop"; + if(!QFile::exists(setdir)){ + QDir dir; + dir.mkpath(setdir); + } + //Now save the settings files + if(setTheme){ LTHEME::setCurrentSettings( themesettings[0], themesettings[1], themesettings[2], themesettings[3], themesettings[4]); } + LUtils::writeFile(setdir+"/sessionsettings.conf", sesset, true); + LUtils::writeFile(setdir+"/desktopsettings.conf", deskset, true); + + //Now run any extra config scripts or utilities as needed + tmp = sysDefaults.filter("usersetup_run"); + if(tmp.isEmpty()){ tmp = sysDefaults.filter("usersetup.run"); } + for(int i=0; i<tmp.length(); i++){ + if(tmp[i].startsWith("#") || !tmp[i].contains("=") ){ continue; } + QString var = tmp[i].section("=",0,0).toLower().simplified(); + QString val = tmp[i].section("=",1,1).section("#",0,0).simplified(); + //Change in 0.8.5 - use "_" instead of "." within variables names - need backwards compat for a little while + if(var.contains(".")){ var.replace(".","_"); } + //Now parse the variable and put the value in the proper file + if(var=="usersetup_run"){ + qDebug() << "Running user setup command:" << val; + QProcess::execute(val); + } + } + +} + +bool LDesktopUtils::checkUserFiles(QString lastversion){ + //internal version conversion examples: + // [1.0.0 -> 1000000], [1.2.3 -> 1002003], [0.6.1 -> 6001] + //returns true if something changed + int oldversion = LDesktopUtils::VersionStringToNumber(lastversion); + int nversion = LDesktopUtils::VersionStringToNumber(QApplication::applicationVersion()); + bool newversion = ( oldversion < nversion ); //increasing version number + bool newrelease = ( lastversion.contains("-devel", Qt::CaseInsensitive) && QApplication::applicationVersion().contains("-release", Qt::CaseInsensitive) ); //Moving from devel to release + + QString confdir = QString(getenv("XDG_CONFIG_HOME"))+"/lumina-desktop/"; + //Check for the desktop settings file + QString dset = confdir+"desktopsettings.conf"; + bool firstrun = false; + if(!QFile::exists(dset) || oldversion < 5000){ + if( oldversion < 100000 && nversion>=100000 ){ system("rm -rf ~/.lumina"); qDebug() << "Current desktop settings obsolete: Re-implementing defaults"; } + else{ firstrun = true; } + LDesktopUtils::LoadSystemDefaults(); + } + //Convert the favorites framework as necessary (change occured with 0.8.4) + if(newversion || newrelease){ + LDesktopUtils::upgradeFavorites(oldversion); + } + //Convert from the old desktop numbering system to the new one (change occured with 1.0.1) + if(oldversion<=1000001){ + QStringList DS = LUtils::readFile(dset); + QList<QScreen*> screens = QApplication::screens(); + for(int i=0; i<DS.length(); i++){ + if(!DS[i].startsWith("[")){ continue; } + if(DS[i].startsWith("[desktop-")){ + bool ok = false; + int num = DS[i].section("desktop-",-1).section("]",0,0).toInt(&ok); + if(num>=0 && ok && num< screens.length()){ + //This one needs to be converted + DS[i] = "[desktop-"+screens[num]->name()+"]"; + } + }else if(DS[i].startsWith("[panel")){ + bool ok = false; + int num = DS[i].section("panel",-1).section(".",0,0).toInt(&ok); + if(num>=0 && ok && num< screens.length()){ + //This one needs to be converted + QString rest = DS[i].section(".",1,-1); //everything after the desktop number in the current setting + DS[i] = "[panel_"+screens[num]->name()+"."+rest; + } + } + } + LUtils::writeFile(dset, DS, true); + } + + //Check the fluxbox configuration files + dset = QString(getenv("XDG_CONFIG_HOME"))+"/lumina-desktop/"; + if(!QFile::exists(dset+"fluxbox-init")){ + firstrun = true; + } + bool fluxcopy = false; + if(!QFile::exists(dset+"fluxbox-init")){ fluxcopy=true; } + else if(!QFile::exists(dset+"fluxbox-keys")){fluxcopy=true; } + else if(oldversion < 60){ fluxcopy=true; qDebug() << "Current fluxbox settings obsolete: Re-implementing defaults"; } + if(fluxcopy){ + qDebug() << "Copying default fluxbox configuration files"; + if(QFile::exists(dset+"fluxbox-init")){ QFile::remove(dset+"fluxbox-init"); } + if(QFile::exists(dset+"fluxbox-keys")){ QFile::remove(dset+"fluxbox-keys"); } + QString finit = LUtils::readFile(LOS::LuminaShare()+"fluxbox-init-rc").join("\n"); + finit.replace("${XDG_CONFIG_HOME}", QString(getenv("XDG_CONFIG_HOME"))); + LUtils::writeFile(dset+"fluxbox-init", finit.split("\n")); + QFile::copy(LOS::LuminaShare()+"fluxbox-keys", dset+"fluxbox-keys"); + QFile::setPermissions(dset+"fluxbox-init", QFile::ReadOwner | QFile::WriteOwner | QFile::ReadUser | QFile::ReadOther | QFile::ReadGroup); + QFile::setPermissions(dset+"fluxbox-keys", QFile::ReadOwner | QFile::WriteOwner | QFile::ReadUser | QFile::ReadOther | QFile::ReadGroup); + } + + if(firstrun){ qDebug() << "First time using Lumina!!"; } + return (firstrun || newversion || newrelease); +} + +int LDesktopUtils::VersionStringToNumber(QString version){ + version = version.section("-",0,0); //trim any extra labels off the end + int maj, mid, min; //major/middle/minor version numbers (<Major>.<Middle>.<Minor>) + maj = mid = min = 0; + bool ok = true; + maj = version.section(".",0,0).toInt(&ok); + if(ok){ mid = version.section(".",1,1).toInt(&ok); }else{ maj = 0; } + if(ok){ min = version.section(".",2,2).toInt(&ok); }else{ mid = 0; } + if(!ok){ min = 0; } + //Now assemble the number + //NOTE: This format allows numbers to be anywhere from 0->999 without conflict + return (maj*1000000 + mid*1000 + min); +} diff --git a/src-qt5/core/libLumina/LDesktopUtils.h b/src-qt5/core/libLumina/LDesktopUtils.h new file mode 100644 index 00000000..dbad8757 --- /dev/null +++ b/src-qt5/core/libLumina/LDesktopUtils.h @@ -0,0 +1,49 @@ +//=========================================== +// Lumina-DE source code +// Copyright (c) 2012-2016, Ken Moore +// Available under the 3-clause BSD license +// See the LICENSE file for full details +//=========================================== +#ifndef _LUMINA_LIBRARY_DESKTOP_UTILS_H +#define _LUMINA_LIBRARY_DESKTOP_UTILS_H + +#include <QString> +#include <QStringList> +#include <QFile> +#include <QDir> +#include <QDateTime> + +//Other classes needed +#include <LUtils.h> +#include <LuminaXDG.h> +#include <LuminaOS.h> + +class LDesktopUtils{ +public: + //Get the current version/build of the Lumina desktop + static QString LuminaDesktopVersion(); + static QString LuminaDesktopBuildDate(); + + //Various function for finding valid QtQuick plugins on the system + static bool validQuickPlugin(QString ID); + static QString findQuickPluginFile(QString ID); + static QStringList listQuickPlugins(); //List of valid ID's + static QStringList infoQuickPlugin(QString ID); //Returns: [Name, Description, Icon] + + //Various functions for the favorites sub-system + // Formatting Note: "<name>::::[dir/app/<mimetype>]::::<path>" + // the <name> field might not be used for "app" flagged entries + static QStringList listFavorites(); + static bool saveFavorites(QStringList); + static bool isFavorite(QString path); + static bool addFavorite(QString path, QString name = ""); + static void removeFavorite(QString path); + static void upgradeFavorites(int fromoldversionnumber); + + //Load the default setup for the system + static void LoadSystemDefaults(bool skipOS = false); + static bool checkUserFiles(QString lastversion); //returns true if something changed + static int VersionStringToNumber(QString version); //convert the lumina version string to a number for comparisons +}; + +#endif diff --git a/src-qt5/core/libLumina/LDesktopUtils.pri b/src-qt5/core/libLumina/LDesktopUtils.pri new file mode 100644 index 00000000..80bbcfa8 --- /dev/null +++ b/src-qt5/core/libLumina/LDesktopUtils.pri @@ -0,0 +1,7 @@ +SOURCES *= $${PWD}/LDesktopUtils.cpp +HEADERS *= $${PWD}/LDesktopUtils.h + +INCLUDEPATH *= ${PWD} + +#Now the other dependendies of it +include(LUtils.pri) diff --git a/src-qt5/core/libLumina/LUtils.cpp b/src-qt5/core/libLumina/LUtils.cpp new file mode 100644 index 00000000..78831231 --- /dev/null +++ b/src-qt5/core/libLumina/LUtils.cpp @@ -0,0 +1,436 @@ +//=========================================== +// Lumina-DE source code +// Copyright (c) 2013-2016, Ken Moore +// Available under the 3-clause BSD license +// See the LICENSE file for full details +//=========================================== +#include "LUtils.h" + +#include "LuminaOS.h" +#include "LuminaXDG.h" + +#include <QApplication> +#include <QtConcurrent> + +inline QStringList ProcessRun(QString cmd, QStringList args){ + //Assemble outputs + QStringList out; out << "1" << ""; //error code, string output + QProcess proc; + QProcessEnvironment env = QProcessEnvironment::systemEnvironment(); + env.insert("LANG", "C"); + env.insert("LC_MESSAGES", "C"); + proc.setProcessEnvironment(env); + proc.setProcessChannelMode(QProcess::MergedChannels); + if(args.isEmpty()){ + proc.start(cmd, QIODevice::ReadOnly); + }else{ + proc.start(cmd,args ,QIODevice::ReadOnly); + } + QString info; + while(!proc.waitForFinished(1000)){ + if(proc.state() == QProcess::NotRunning){ break; } //somehow missed the finished signal + QString tmp = proc.readAllStandardOutput(); + if(tmp.isEmpty()){ proc.terminate(); } + else{ info.append(tmp); } + } + out[0] = QString::number(proc.exitCode()); + out[1] = info+QString(proc.readAllStandardOutput()); + return out; +} +//============= +// LUtils Functions +//============= +int LUtils::runCmd(QString cmd, QStringList args){ + /*QProcess proc; + proc.setProcessChannelMode(QProcess::MergedChannels); + if(args.isEmpty()){ + proc.start(cmd); + }else{ + proc.start(cmd, args); + } + //if(!proc.waitForStarted(30000)){ return 1; } //process never started - max wait of 30 seconds + while(!proc.waitForFinished(300)){ + if(proc.state() == QProcess::NotRunning){ break; } //somehow missed the finished signal + QCoreApplication::processEvents(); + } + int ret = proc.exitCode(); + return ret;*/ + QFuture<QStringList> future = QtConcurrent::run(ProcessRun, cmd, args); + return future.result()[0].toInt(); //turn it back into an integer return code + +} + +QStringList LUtils::getCmdOutput(QString cmd, QStringList args){ + /*QProcess proc; + QProcessEnvironment env = QProcessEnvironment::systemEnvironment(); + env.insert("LANG", "C"); + env.insert("LC_MESSAGES", "C"); + proc.setProcessEnvironment(env); + proc.setProcessChannelMode(QProcess::MergedChannels); + if(args.isEmpty()){ + proc.start(cmd); + }else{ + proc.start(cmd,args); + } + //if(!proc.waitForStarted(30000)){ return QStringList(); } //process never started - max wait of 30 seconds + while(!proc.waitForFinished(300)){ + if(proc.state() == QProcess::NotRunning){ break; } //somehow missed the finished signal + QCoreApplication::processEvents(); + } + QStringList out = QString(proc.readAllStandardOutput()).split("\n"); + return out;*/ + QFuture<QStringList> future = QtConcurrent::run(ProcessRun, cmd, args); + return future.result()[1].split("\n"); //Split the return message into lines +} + +QStringList LUtils::readFile(QString filepath){ + QStringList out; + QFile file(filepath); + if(file.open(QIODevice::Text | QIODevice::ReadOnly)){ + QTextStream in(&file); + while(!in.atEnd()){ + out << in.readLine(); + } + file.close(); + } + return out; +} + +bool LUtils::writeFile(QString filepath, QStringList contents, bool overwrite){ + QFile file(filepath); + if(file.exists() && !overwrite){ return false; } + bool ok = false; + if(contents.isEmpty()){ contents << "\n"; } + if( file.open(QIODevice::WriteOnly | QIODevice::Truncate) ){ + QTextStream out(&file); + out << contents.join("\n"); + if(!contents.last().isEmpty()){ out << "\n"; } //always end with a new line + file.close(); + ok = true; + } + return ok; +} + +bool LUtils::isValidBinary(QString& bin){ + if(!bin.startsWith("/")){ + //Relative path: search for it on the current "PATH" settings + QStringList paths = QString(qgetenv("PATH")).split(":"); + for(int i=0; i<paths.length(); i++){ + if(QFile::exists(paths[i]+"/"+bin)){ bin = paths[i]+"/"+bin; break;} + } + } + //bin should be the full path by now + if(!bin.startsWith("/")){ return false; } + QFileInfo info(bin); + bool good = (info.exists() && info.isExecutable()); + if(good){ bin = info.absoluteFilePath(); } + return good; +} + +QStringList LUtils::systemApplicationDirs(){ + //Returns a list of all the directories where *.desktop files can be found + QStringList appDirs = QString(getenv("XDG_DATA_HOME")).split(":"); + appDirs << QString(getenv("XDG_DATA_DIRS")).split(":"); + if(appDirs.isEmpty()){ appDirs << "/usr/local/share" << "/usr/share" << LOS::AppPrefix()+"/share" << LOS::SysPrefix()+"/share" << L_SHAREDIR; } + appDirs.removeDuplicates(); + //Now create a valid list + QStringList out; + for(int i=0; i<appDirs.length(); i++){ + if( QFile::exists(appDirs[i]+"/applications") ){ + out << appDirs[i]+"/applications"; + //Also check any subdirs within this directory + // (looking at you KDE - stick to the standards!!) + out << LUtils::listSubDirectories(appDirs[i]+"/applications"); + } + } + //qDebug() << "System Application Dirs:" << out; + return out; +} + +QString LUtils::GenerateOpenTerminalExec(QString term, QString dirpath){ + //Check the input terminal application (default/fallback - determined by calling application) + //if(!LUtils::isValidBinary(term)){ + if(term.endsWith(".desktop")){ + //Pull the binary name out of the shortcut + XDGDesktop DF(term); + if(DF.type == XDGDesktop::BAD){ term = "xterm"; } + else{ term= DF.exec.section(" ",0,0); } //only take the binary name - not any other flags + }else{ + term = "xterm"; //fallback + } + //} + //Now create the calling command for the designated terminal + // NOTE: While the "-e" routine is supposed to be universal, many terminals do not properly use it + // so add some special/known terminals here as necessary + QString exec; + qWarning() << " - Reached terminal initialization" << term; + if(term=="mate-terminal" || term=="lxterminal" || term=="gnome-terminal"){ + exec = term+" --working-directory=\""+dirpath+"\""; + }else if(term=="xfce4-terminal"){ + exec = term+" --default-working-directory=\""+dirpath+"\""; + }else if(term=="konsole" || term == "qterminal"){ + exec = term+" --workdir \""+dirpath+"\""; + }else{ + //-e is the parameter for most of the terminal appliction to execute an external command. + //In this case we start a shell in the selected directory + //Need the user's shell first + QString shell = QString(getenv("SHELL")); + if(!LUtils::isValidBinary(shell)){ shell = "/bin/sh"; } //universal fallback for a shell + exec = term + " -e \"cd " + dirpath + " && " + shell + " \" "; + } + qDebug() << exec; + return exec; +} + +QStringList LUtils::listSubDirectories(QString dir, bool recursive){ + //This is a recursive method for returning the full paths of all subdirectories (if recursive flag is enabled) + QDir maindir(dir); + QStringList out; + QStringList subs = maindir.entryList(QDir::NoDotAndDotDot | QDir::Dirs, QDir::Name); + for(int i=0; i<subs.length(); i++){ + out << maindir.absoluteFilePath(subs[i]); + if(recursive){ + out << LUtils::listSubDirectories(maindir.absoluteFilePath(subs[i]), recursive); + } + } + return out; +} + +QString LUtils::PathToAbsolute(QString path){ + //Convert an input path to an absolute path (this does not check existance ot anything) + if(path.startsWith("/")){ return path; } //already an absolute path + if(path.startsWith("~")){ path.replace(0,1,QDir::homePath()); } + if(!path.startsWith("/")){ + //Must be a relative path + if(path.startsWith("./")){ path = path.remove(2); } + path.prepend( QDir::currentPath()+"/"); + } + return path; +} + +QString LUtils::AppToAbsolute(QString path){ + if(path.startsWith("~/")){ path = path.replace("~/", QDir::homePath()+"/" ); } + if(path.startsWith("/") || QFile::exists(path)){ return path; } + if(path.endsWith(".desktop")){ + //Look in the XDG dirs + QStringList dirs = systemApplicationDirs(); + for(int i=0; i<dirs.length(); i++){ + if(QFile::exists(dirs[i]+"/"+path)){ return (dirs[i]+"/"+path); } + } + }else{ + //Look on $PATH for the binary + QStringList paths = QString(getenv("PATH")).split(":"); + for(int i=0; i<paths.length(); i++){ + if(QFile::exists(paths[i]+"/"+path)){ return (paths[i]+"/"+path); } + } + } + return path; +} + +QStringList LUtils::imageExtensions(bool wildcards){ + //Note that all the image extensions are lowercase!! + static QStringList imgExtensions; + if(imgExtensions.isEmpty()){ + QList<QByteArray> fmt = QImageReader::supportedImageFormats(); + for(int i=0; i<fmt.length(); i++){ + if(wildcards){ imgExtensions << "*."+QString::fromLocal8Bit(fmt[i]); } + else{ imgExtensions << QString::fromLocal8Bit(fmt[i]); } + } + } + return imgExtensions; +} + + QTranslator* LUtils::LoadTranslation(QApplication *app, QString appname, QString locale, QTranslator *cTrans){ + //Get the current localization + QString langEnc = "UTF-8"; //default value + QString langCode = locale; //provided locale + if(langCode.isEmpty()){ langCode = getenv("LC_ALL"); } + if(langCode.isEmpty()){ langCode = getenv("LANG"); } + if(langCode.isEmpty()){ langCode = "en_US.UTF-8"; } //default to US english + //See if the encoding is included and strip it out as necessary + if(langCode.contains(".")){ + langEnc = langCode.section(".",-1); + langCode = langCode.section(".",0,0); + } + //Now verify the encoding for the locale + if(langCode =="C" || langCode=="POSIX" || langCode.isEmpty()){ + langEnc = "System"; //use the Qt system encoding + } + if(app !=0){ + qDebug() << "Loading Locale:" << appname << langCode << langEnc; + //If an existing translator was provided, remove it first (will be replaced) + if(cTrans!=0){ app->removeTranslator(cTrans); } + //Setup the translator + cTrans = new QTranslator(); + //Use the shortened locale code if specific code does not have a corresponding file + if(!QFile::exists(LOS::LuminaShare()+"i18n/"+appname+"_" + langCode + ".qm") && langCode!="en_US" ){ + langCode.truncate( langCode.indexOf("_") ); + } + QString filename = appname+"_"+langCode+".qm"; + //qDebug() << "FileName:" << filename << "Dir:" << LOS::LuminaShare()+"i18n/"; + if( cTrans->load( filename, LOS::LuminaShare()+"i18n/" ) ){ + app->installTranslator( cTrans ); + }else{ + //Translator could not be loaded for some reason + cTrans = 0; + if(langCode!="en_US"){ + qWarning() << " - Could not load Locale:" << langCode; + } + } + }else{ + //Only going to set the encoding since no application given + qDebug() << "Loading System Encoding:" << langEnc; + } + //Load current encoding for this locale + QTextCodec::setCodecForLocale( QTextCodec::codecForName(langEnc.toUtf8()) ); + return cTrans; +} + +QStringList LUtils::knownLocales(){ + QDir i18n = QDir(LOS::LuminaShare()+"i18n"); + if( !i18n.exists() ){ return QStringList(); } + QStringList files = i18n.entryList(QStringList() << "lumina-desktop_*.qm", QDir::Files, QDir::Name); + if(files.isEmpty()){ return QStringList(); } + //Now strip off the filename and just leave the locale tag + for(int i=0; i<files.length(); i++){ + files[i].chop(3); //remove the ".qm" on the end + files[i] = files[i].section("_",1,50).simplified(); + } + files << "en_US"; //default locale + files.sort(); + return files; +} + +void LUtils::setLocaleEnv(QString lang, QString msg, QString time, QString num,QString money,QString collate, QString ctype){ + //Adjust the current locale environment variables + bool all = false; + if(msg.isEmpty() && time.isEmpty() && num.isEmpty() && money.isEmpty() && collate.isEmpty() && ctype.isEmpty() ){ + if(lang.isEmpty()){ return; } //nothing to do - no changes requested + all = true; //set everything to the "lang" value + } + //If no lang given, but others are given, then use the current setting + if(lang.isEmpty()){ lang = getenv("LC_ALL"); } + if(lang.isEmpty()){ lang = getenv("LANG"); } + if(lang.isEmpty()){ lang = "en_US"; } + //Now go through and set/unset the environment variables + // - LANG & LC_ALL + if(!lang.contains(".")){ lang.append(".UTF-8"); } + setenv("LANG",lang.toUtf8() ,1); //overwrite setting (this is always required as the fallback) + if(all){ setenv("LC_ALL",lang.toUtf8() ,1); } + else{ unsetenv("LC_ALL"); } //make sure the custom settings are used + // - LC_MESSAGES + if(msg.isEmpty()){ unsetenv("LC_MESSAGES"); } + else{ + if(!msg.contains(".")){ msg.append(".UTF-8"); } + setenv("LC_MESSAGES",msg.toUtf8(),1); + } + // - LC_TIME + if(time.isEmpty()){ unsetenv("LC_TIME"); } + else{ + if(!time.contains(".")){ time.append(".UTF-8"); } + setenv("LC_TIME",time.toUtf8(),1); + } + // - LC_NUMERIC + if(num.isEmpty()){ unsetenv("LC_NUMERIC"); } + else{ + if(!num.contains(".")){ num.append(".UTF-8"); } + setenv("LC_NUMERIC",num.toUtf8(),1); + } + // - LC_MONETARY + if(money.isEmpty()){ unsetenv("LC_MONETARY"); } + else{ + if(!money.contains(".")){ money.append(".UTF-8"); } + setenv("LC_MONETARY",money.toUtf8(),1); + } + // - LC_COLLATE + if(collate.isEmpty()){ unsetenv("LC_COLLATE"); } + else{ + if(!collate.contains(".")){ collate.append(".UTF-8"); } + setenv("LC_COLLATE",collate.toUtf8(),1); + } + // - LC_CTYPE + if(ctype.isEmpty()){ unsetenv("LC_CTYPE"); } + else{ + if(!ctype.contains(".")){ ctype.append(".UTF-8"); } + setenv("LC_CTYPE",ctype.toUtf8(),1); + } +} + +QString LUtils::currentLocale(){ + QString curr = getenv("LC_ALL");// = QLocale::system(); + if(curr.isEmpty()){ curr = getenv("LANG"); } + if(curr.isEmpty()){ curr = "en_US"; } + curr = curr.section(".",0,0); //remove any encodings off the end + return curr; +} + +double LUtils::DisplaySizeToBytes(QString num){ + //qDebug() << "Convert Num to Bytes:" << num; + num = num.toLower().simplified(); + num = num.remove(" "); + if(num.isEmpty()){ return 0.0; } + if(num.endsWith("b")){ num.chop(1); } //remove the "bytes" marker (if there is one) + QString lab = "b"; + if(!num[num.size()-1].isNumber()){ + lab = num.right(1); num.chop(1); + } + double N = num.toDouble(); + QStringList labs; labs <<"b"<<"k"<<"m"<<"g"<<"t"<<"p"; //go up to petabytes for now + for(int i=0; i<labs.length(); i++){ + if(lab==labs[i]){ break; }//already at the right units - break out + N = N*1024.0; //Move to the next unit of measurement + } + //qDebug() << " - Done:" << QString::number(N) << lab << num; + return N; +} + +QString LUtils::BytesToDisplaySize(qint64 ibytes){ + static QStringList labs = QStringList(); + if(labs.isEmpty()){ labs << "B" << "K" << "M" << "G" << "T" << "P"; } + //Now get the dominant unit + int c=0; + double bytes = ibytes; //need to keep decimel places for calculations + while(bytes>=1000 && c<labs.length() ){ + bytes = bytes/1024; + c++; + } //labs[c] is the unit + //Bytes are now + //Now format the number (up to 3 digits, not including decimel places) + QString num; + if(bytes>=100){ + //No decimel places + num = QString::number(qRound(bytes)); + }else if(bytes>=10){ + //need 1 decimel place + num = QString::number( (qRound(bytes*10)/10.0) ); + }else if(bytes>=1){ + //need 2 decimel places + num = QString::number( (qRound(bytes*100)/100.0) ); + }else{ + //Fully decimel (3 places) + num = "0."+QString::number(qRound(bytes*1000)); + } + //qDebug() << "Bytes to Human-readable:" << bytes << c << num << labs[c]; + return (num+labs[c]); +} + +QString LUtils::SecondsToDisplay(int secs){ + if(secs < 0){ return "??"; } + QString rem; //remaining + if(secs > 3600){ + int hours = secs/3600; + rem.append( QString::number(hours)+"h "); + secs = secs - (hours*3600); + } + if(secs > 60){ + int min = secs/60; + rem.append( QString::number(min)+"m "); + secs = secs - (min*60); + } + if(secs > 0){ + rem.append( QString::number(secs)+"s"); + }else{ + rem.append( "0s" ); + } + return rem; +} diff --git a/src-qt5/core/libLumina/LUtils.h b/src-qt5/core/libLumina/LUtils.h new file mode 100644 index 00000000..459fca60 --- /dev/null +++ b/src-qt5/core/libLumina/LUtils.h @@ -0,0 +1,78 @@ +//=========================================== +// Lumina-DE source code +// Copyright (c) 2012-2016, Ken Moore +// Available under the 3-clause BSD license +// See the LICENSE file for full details +//=========================================== +#ifndef _LUMINA_LIBRARY_UTILS_H +#define _LUMINA_LIBRARY_UTILS_H + +#include <QCoreApplication> +#include <QProcess> +#include <QTextStream> +#include <QTextCodec> +#include <QFile> +#include <QDir> +#include <QString> +#include <QStringList> +#include <QFile> +#include <QFileInfo> +#include <QObject> +#include <QTranslator> +#include <QDebug> +#include <QDesktopWidget> +#include <QImageReader> +#include <QRegExp> +#include <QFuture> +#include <QScreen> + +class LUtils{ +public: + + //Run an external command and return the exit code + static int runCmd(QString cmd, QStringList args = QStringList()); + //Run an external command and return any text output (one line per entry) + static QStringList getCmdOutput(QString cmd, QStringList args = QStringList()); + + //Read a text file + static QStringList readFile(QString filepath); + //Write a text file + static bool writeFile(QString filepath, QStringList contents, bool overwrite=false); + + //Check whether a file/path is a valid binary + static bool isValidBinary(QString& bin); //full path or name only + static bool isValidBinary(const char *bin){ + QString bins(bin); + return isValidBinary(bins); //overload for a "junk" binary variable input + } + + //Return all the dirs on the system which contain .desktop files + static QStringList systemApplicationDirs(); + + //Create the exec string to open a terminal in a particular directory + static QString GenerateOpenTerminalExec(QString term, QString dirpath); + + //List all the sub-directories of a parent dir (recursive) + static QStringList listSubDirectories(QString dir, bool recursive = true); + + //Convert an input file/dir path to an absolute file path + static QString PathToAbsolute(QString path); //This is primarily for CLI usage (relative paths) + static QString AppToAbsolute(QString path); //This is for looking up a binary/ *.desktop path + + //Get the list of all file extensions which Qt can read (lowercase) + static QStringList imageExtensions(bool wildcards = false); + + //Load a translation file for a Lumina Project + static QTranslator* LoadTranslation(QApplication *app, QString appname, QString locale = "", QTranslator *cTrans = 0); + //Other localization shortcuts + static QStringList knownLocales(); //Note: This only lists locales known to Lumina (so the i18n files need to be installed) + static void setLocaleEnv(QString lang, QString msg="", QString time="", QString num="" ,QString money="",QString collate="", QString ctype=""); + static QString currentLocale(); + + //Number format conversions + static double DisplaySizeToBytes(QString num); //Turn a display size (like 50M or 50KB) into a double for calculations (bytes) + static QString BytesToDisplaySize(qint64 bytes); //convert into a readable size (like 50M or 50KB) + + static QString SecondsToDisplay(int secs); //convert into a readable time +}; +#endif diff --git a/src-qt5/core/libLumina/LUtils.pri b/src-qt5/core/libLumina/LUtils.pri new file mode 100644 index 00000000..d5941a41 --- /dev/null +++ b/src-qt5/core/libLumina/LUtils.pri @@ -0,0 +1,34 @@ +#since this is the most common of the include files - make sure it only gets added once +!contains( HEADERS, $${PWD}/LUtils.h ){ + +include("$${PWD}/../../OS-detect.pri") + +QT *= concurrent + +#Setup any special defines (qmake -> C++) +GIT_VERSION=$$system(git describe --always) +!isEmpty(GIT_VERSION){ + DEFINES += GIT_VERSION='"\\\"$${GIT_VERSION}\\\""' +} +#Note: Saving the build date will break reproducible builds (time stamp always different) +# Disable this by default, but leave it possible to re-enable this as needed by user +#DEFINES += BUILD_DATE='"\\\"$$system(date)\\\""' + +#LuminaOS files +HEADERS *= $${PWD}/LuminaOS.h +# LuminaOS support functions (or fall back to generic one) +exists($${PWD}/LuminaOS-$${LINUX_DISTRO}.cpp){ + SOURCES *= $${PWD}/LuminaOS-$${LINUX_DISTRO}.cpp +}else:exists($${PWD}/LuminaOS-$${OS}.cpp){ + SOURCES *= $${PWD}/LuminaOS-$${OS}.cpp +}else{ + SOURCES *= $${PWD}/LuminaOS-template.cpp +} + +#LUtils Files +SOURCES *= $${PWD}/LUtils.cpp +HEADERS *= $${PWD}/LUtils.h + +INCLUDEPATH *= ${PWD} + +} diff --git a/src-qt5/core/libLumina/LuminaOS.h b/src-qt5/core/libLumina/LuminaOS.h index 50d6baec..96a587a8 100644 --- a/src-qt5/core/libLumina/LuminaOS.h +++ b/src-qt5/core/libLumina/LuminaOS.h @@ -1,6 +1,6 @@ //=========================================== // Lumina-DE source code -// Copyright (c) 2014-15, Ken Moore +// Copyright (c) 2014-16, Ken Moore // Available under the 3-clause BSD license // See the LICENSE file for full details //=========================================== @@ -18,7 +18,7 @@ #include <QDir> #include <QObject> -#include "LuminaUtils.h" +#include "LUtils.h" class LOS{ public: diff --git a/src-qt5/core/libLumina/LuminaSingleApplication.h b/src-qt5/core/libLumina/LuminaSingleApplication.h index 725d8e40..bacf5640 100644 --- a/src-qt5/core/libLumina/LuminaSingleApplication.h +++ b/src-qt5/core/libLumina/LuminaSingleApplication.h @@ -25,7 +25,7 @@ #include <QLockFile> #include <QApplication> -#include <LuminaUtils.h> +#include <LUtils.h> //NOTE: This application type will automatically load the proper translation file(s) // if the application name is set properly diff --git a/src-qt5/core/libLumina/LuminaSingleApplication.pri b/src-qt5/core/libLumina/LuminaSingleApplication.pri new file mode 100644 index 00000000..88ab7726 --- /dev/null +++ b/src-qt5/core/libLumina/LuminaSingleApplication.pri @@ -0,0 +1,12 @@ +include("$${PWD}/../../OS-detect.pri") + +QT *= network x11extras + +#LUtils Files +SOURCES *= $${PWD}/LuminaSingleApplication.cpp +HEADERS *= $${PWD}/LuminaSingleApplication.h + +INCLUDEPATH *= ${PWD} + +#include LUtils and LuminaOS +include(LUtils.pri) diff --git a/src-qt5/core/libLumina/LuminaThemes.cpp b/src-qt5/core/libLumina/LuminaThemes.cpp index 03dfb771..70cd221d 100644 --- a/src-qt5/core/libLumina/LuminaThemes.cpp +++ b/src-qt5/core/libLumina/LuminaThemes.cpp @@ -6,7 +6,7 @@ //=========================================== #include "LuminaThemes.h" -#include "LuminaUtils.h" +#include "LUtils.h" #include "LuminaOS.h" #include <QIcon> #include <QFont> diff --git a/src-qt5/core/libLumina/LuminaThemes.pri b/src-qt5/core/libLumina/LuminaThemes.pri new file mode 100644 index 00000000..0fe35b79 --- /dev/null +++ b/src-qt5/core/libLumina/LuminaThemes.pri @@ -0,0 +1,10 @@ +include("$${PWD}/../../OS-detect.pri") + +#LUtils Files +SOURCES *= $${PWD}/LuminaThemes.cpp +HEADERS *= $${PWD}/LuminaThemes.h + +INCLUDEPATH *= ${PWD} + +#include LUtils and LuminaOS +include(LUtils.pri) diff --git a/src-qt5/core/libLumina/LuminaUtils.cpp b/src-qt5/core/libLumina/LuminaUtils.cpp deleted file mode 100644 index 0d808d1d..00000000 --- a/src-qt5/core/libLumina/LuminaUtils.cpp +++ /dev/null @@ -1,1063 +0,0 @@ -//=========================================== -// Lumina-DE source code -// Copyright (c) 2013-2015, Ken Moore -// Available under the 3-clause BSD license -// See the LICENSE file for full details -//=========================================== -#include "LuminaUtils.h" - -#include <QString> -#include <QFile> -#include <QStringList> -#include <QObject> -#include <QTextCodec> -#include <QDebug> -#include <QDesktopWidget> -#include <QImageReader> -#include <QRegExp> -#include <QFuture> -#include <QtConcurrent> -#include <QScreen> - -#include <LuminaOS.h> -#include <LuminaThemes.h> -#include <LuminaXDG.h> - -static QStringList fav; - -inline QStringList ProcessRun(QString cmd, QStringList args){ - //Assemble outputs - QStringList out; out << "1" << ""; //error code, string output - QProcess proc; - QProcessEnvironment env = QProcessEnvironment::systemEnvironment(); - env.insert("LANG", "C"); - env.insert("LC_MESSAGES", "C"); - proc.setProcessEnvironment(env); - proc.setProcessChannelMode(QProcess::MergedChannels); - if(args.isEmpty()){ - proc.start(cmd, QIODevice::ReadOnly); - }else{ - proc.start(cmd,args ,QIODevice::ReadOnly); - } - QString info; - while(!proc.waitForFinished(1000)){ - if(proc.state() == QProcess::NotRunning){ break; } //somehow missed the finished signal - QString tmp = proc.readAllStandardOutput(); - if(tmp.isEmpty()){ proc.terminate(); } - else{ info.append(tmp); } - } - out[0] = QString::number(proc.exitCode()); - out[1] = info+QString(proc.readAllStandardOutput()); - return out; -} -//============= -// LUtils Functions -//============= -QString LUtils::LuminaDesktopVersion(){ - QString ver = "1.1.1"; - #ifdef GIT_VERSION - ver.append( QString(" (Git Revision: %1)").arg(GIT_VERSION) ); - #endif - return ver; -} - -QString LUtils::LuminaDesktopBuildDate(){ - #ifdef BUILD_DATE - return BUILD_DATE; - #endif - return ""; -} - -int LUtils::runCmd(QString cmd, QStringList args){ - /*QProcess proc; - proc.setProcessChannelMode(QProcess::MergedChannels); - if(args.isEmpty()){ - proc.start(cmd); - }else{ - proc.start(cmd, args); - } - //if(!proc.waitForStarted(30000)){ return 1; } //process never started - max wait of 30 seconds - while(!proc.waitForFinished(300)){ - if(proc.state() == QProcess::NotRunning){ break; } //somehow missed the finished signal - QCoreApplication::processEvents(); - } - int ret = proc.exitCode(); - return ret;*/ - QFuture<QStringList> future = QtConcurrent::run(ProcessRun, cmd, args); - return future.result()[0].toInt(); //turn it back into an integer return code - -} - -QStringList LUtils::getCmdOutput(QString cmd, QStringList args){ - /*QProcess proc; - QProcessEnvironment env = QProcessEnvironment::systemEnvironment(); - env.insert("LANG", "C"); - env.insert("LC_MESSAGES", "C"); - proc.setProcessEnvironment(env); - proc.setProcessChannelMode(QProcess::MergedChannels); - if(args.isEmpty()){ - proc.start(cmd); - }else{ - proc.start(cmd,args); - } - //if(!proc.waitForStarted(30000)){ return QStringList(); } //process never started - max wait of 30 seconds - while(!proc.waitForFinished(300)){ - if(proc.state() == QProcess::NotRunning){ break; } //somehow missed the finished signal - QCoreApplication::processEvents(); - } - QStringList out = QString(proc.readAllStandardOutput()).split("\n"); - return out;*/ - QFuture<QStringList> future = QtConcurrent::run(ProcessRun, cmd, args); - return future.result()[1].split("\n"); //Split the return message into lines -} - -QStringList LUtils::readFile(QString filepath){ - QStringList out; - QFile file(filepath); - if(file.open(QIODevice::Text | QIODevice::ReadOnly)){ - QTextStream in(&file); - while(!in.atEnd()){ - out << in.readLine(); - } - file.close(); - } - return out; -} - -bool LUtils::writeFile(QString filepath, QStringList contents, bool overwrite){ - QFile file(filepath); - if(file.exists() && !overwrite){ return false; } - bool ok = false; - if(contents.isEmpty()){ contents << "\n"; } - if( file.open(QIODevice::WriteOnly | QIODevice::Truncate) ){ - QTextStream out(&file); - out << contents.join("\n"); - if(!contents.last().isEmpty()){ out << "\n"; } //always end with a new line - file.close(); - ok = true; - } - return ok; -} - -bool LUtils::isValidBinary(QString& bin){ - if(!bin.startsWith("/")){ - //Relative path: search for it on the current "PATH" settings - QStringList paths = QString(qgetenv("PATH")).split(":"); - for(int i=0; i<paths.length(); i++){ - if(QFile::exists(paths[i]+"/"+bin)){ bin = paths[i]+"/"+bin; break;} - } - } - //bin should be the full path by now - if(!bin.startsWith("/")){ return false; } - QFileInfo info(bin); - bool good = (info.exists() && info.isExecutable()); - if(good){ bin = info.absoluteFilePath(); } - return good; -} - -QString LUtils::GenerateOpenTerminalExec(QString term, QString dirpath){ - //Check the input terminal application (default/fallback - determined by calling application) - //if(!LUtils::isValidBinary(term)){ - if(term.endsWith(".desktop")){ - //Pull the binary name out of the shortcut - XDGDesktop DF(term); - if(DF.type == XDGDesktop::BAD){ term = "xterm"; } - else{ term= DF.exec.section(" ",0,0); } //only take the binary name - not any other flags - }else{ - term = "xterm"; //fallback - } - //} - //Now create the calling command for the designated terminal - // NOTE: While the "-e" routine is supposed to be universal, many terminals do not properly use it - // so add some special/known terminals here as necessary - QString exec; - qWarning() << " - Reached terminal initialization" << term; - if(term=="mate-terminal" || term=="lxterminal" || term=="gnome-terminal"){ - exec = term+" --working-directory=\""+dirpath+"\""; - }else if(term=="xfce4-terminal"){ - exec = term+" --default-working-directory=\""+dirpath+"\""; - }else if(term=="konsole" || term == "qterminal"){ - exec = term+" --workdir \""+dirpath+"\""; - }else{ - //-e is the parameter for most of the terminal appliction to execute an external command. - //In this case we start a shell in the selected directory - //Need the user's shell first - QString shell = QString(getenv("SHELL")); - if(!LUtils::isValidBinary(shell)){ shell = "/bin/sh"; } //universal fallback for a shell - exec = term + " -e \"cd " + dirpath + " && " + shell + " \" "; - } - qDebug() << exec; - return exec; -} - -QStringList LUtils::listSubDirectories(QString dir, bool recursive){ - //This is a recursive method for returning the full paths of all subdirectories (if recursive flag is enabled) - QDir maindir(dir); - QStringList out; - QStringList subs = maindir.entryList(QDir::NoDotAndDotDot | QDir::Dirs, QDir::Name); - for(int i=0; i<subs.length(); i++){ - out << maindir.absoluteFilePath(subs[i]); - if(recursive){ - out << LUtils::listSubDirectories(maindir.absoluteFilePath(subs[i]), recursive); - } - } - return out; -} - -QString LUtils::PathToAbsolute(QString path){ - //Convert an input path to an absolute path (this does not check existance ot anything) - if(path.startsWith("/")){ return path; } //already an absolute path - if(path.startsWith("~")){ path.replace(0,1,QDir::homePath()); } - if(!path.startsWith("/")){ - //Must be a relative path - if(path.startsWith("./")){ path = path.remove(2); } - path.prepend( QDir::currentPath()+"/"); - } - return path; -} - -QString LUtils::AppToAbsolute(QString path){ - if(path.startsWith("~/")){ path = path.replace("~/", QDir::homePath()+"/" ); } - if(path.startsWith("/") || QFile::exists(path)){ return path; } - if(path.endsWith(".desktop")){ - //Look in the XDG dirs - QStringList dirs = LXDG::systemApplicationDirs(); - for(int i=0; i<dirs.length(); i++){ - if(QFile::exists(dirs[i]+"/"+path)){ return (dirs[i]+"/"+path); } - } - }else{ - //Look on $PATH for the binary - QStringList paths = QString(getenv("PATH")).split(":"); - for(int i=0; i<paths.length(); i++){ - if(QFile::exists(paths[i]+"/"+path)){ return (paths[i]+"/"+path); } - } - } - return path; -} - -QStringList LUtils::imageExtensions(bool wildcards){ - //Note that all the image extensions are lowercase!! - static QStringList imgExtensions; - if(imgExtensions.isEmpty()){ - QList<QByteArray> fmt = QImageReader::supportedImageFormats(); - for(int i=0; i<fmt.length(); i++){ - if(wildcards){ imgExtensions << "*."+QString::fromLocal8Bit(fmt[i]); } - else{ imgExtensions << QString::fromLocal8Bit(fmt[i]); } - } - } - return imgExtensions; -} - - QTranslator* LUtils::LoadTranslation(QApplication *app, QString appname, QString locale, QTranslator *cTrans){ - //Get the current localization - QString langEnc = "UTF-8"; //default value - QString langCode = locale; //provided locale - if(langCode.isEmpty()){ langCode = getenv("LC_ALL"); } - if(langCode.isEmpty()){ langCode = getenv("LANG"); } - if(langCode.isEmpty()){ langCode = "en_US.UTF-8"; } //default to US english - //See if the encoding is included and strip it out as necessary - if(langCode.contains(".")){ - langEnc = langCode.section(".",-1); - langCode = langCode.section(".",0,0); - } - //Now verify the encoding for the locale - if(langCode =="C" || langCode=="POSIX" || langCode.isEmpty()){ - langEnc = "System"; //use the Qt system encoding - } - if(app !=0){ - qDebug() << "Loading Locale:" << appname << langCode << langEnc; - //If an existing translator was provided, remove it first (will be replaced) - if(cTrans!=0){ app->removeTranslator(cTrans); } - //Setup the translator - cTrans = new QTranslator(); - //Use the shortened locale code if specific code does not have a corresponding file - if(!QFile::exists(LOS::LuminaShare()+"i18n/"+appname+"_" + langCode + ".qm") && langCode!="en_US" ){ - langCode.truncate( langCode.indexOf("_") ); - } - QString filename = appname+"_"+langCode+".qm"; - //qDebug() << "FileName:" << filename << "Dir:" << LOS::LuminaShare()+"i18n/"; - if( cTrans->load( filename, LOS::LuminaShare()+"i18n/" ) ){ - app->installTranslator( cTrans ); - }else{ - //Translator could not be loaded for some reason - cTrans = 0; - if(langCode!="en_US"){ - qWarning() << " - Could not load Locale:" << langCode; - } - } - }else{ - //Only going to set the encoding since no application given - qDebug() << "Loading System Encoding:" << langEnc; - } - //Load current encoding for this locale - QTextCodec::setCodecForLocale( QTextCodec::codecForName(langEnc.toUtf8()) ); - return cTrans; -} - -QStringList LUtils::knownLocales(){ - QDir i18n = QDir(LOS::LuminaShare()+"i18n"); - if( !i18n.exists() ){ return QStringList(); } - QStringList files = i18n.entryList(QStringList() << "lumina-desktop_*.qm", QDir::Files, QDir::Name); - if(files.isEmpty()){ return QStringList(); } - //Now strip off the filename and just leave the locale tag - for(int i=0; i<files.length(); i++){ - files[i].chop(3); //remove the ".qm" on the end - files[i] = files[i].section("_",1,50).simplified(); - } - files << "en_US"; //default locale - files.sort(); - return files; -} - -void LUtils::setLocaleEnv(QString lang, QString msg, QString time, QString num,QString money,QString collate, QString ctype){ - //Adjust the current locale environment variables - bool all = false; - if(msg.isEmpty() && time.isEmpty() && num.isEmpty() && money.isEmpty() && collate.isEmpty() && ctype.isEmpty() ){ - if(lang.isEmpty()){ return; } //nothing to do - no changes requested - all = true; //set everything to the "lang" value - } - //If no lang given, but others are given, then use the current setting - if(lang.isEmpty()){ lang = getenv("LC_ALL"); } - if(lang.isEmpty()){ lang = getenv("LANG"); } - if(lang.isEmpty()){ lang = "en_US"; } - //Now go through and set/unset the environment variables - // - LANG & LC_ALL - if(!lang.contains(".")){ lang.append(".UTF-8"); } - setenv("LANG",lang.toUtf8() ,1); //overwrite setting (this is always required as the fallback) - if(all){ setenv("LC_ALL",lang.toUtf8() ,1); } - else{ unsetenv("LC_ALL"); } //make sure the custom settings are used - // - LC_MESSAGES - if(msg.isEmpty()){ unsetenv("LC_MESSAGES"); } - else{ - if(!msg.contains(".")){ msg.append(".UTF-8"); } - setenv("LC_MESSAGES",msg.toUtf8(),1); - } - // - LC_TIME - if(time.isEmpty()){ unsetenv("LC_TIME"); } - else{ - if(!time.contains(".")){ time.append(".UTF-8"); } - setenv("LC_TIME",time.toUtf8(),1); - } - // - LC_NUMERIC - if(num.isEmpty()){ unsetenv("LC_NUMERIC"); } - else{ - if(!num.contains(".")){ num.append(".UTF-8"); } - setenv("LC_NUMERIC",num.toUtf8(),1); - } - // - LC_MONETARY - if(money.isEmpty()){ unsetenv("LC_MONETARY"); } - else{ - if(!money.contains(".")){ money.append(".UTF-8"); } - setenv("LC_MONETARY",money.toUtf8(),1); - } - // - LC_COLLATE - if(collate.isEmpty()){ unsetenv("LC_COLLATE"); } - else{ - if(!collate.contains(".")){ collate.append(".UTF-8"); } - setenv("LC_COLLATE",collate.toUtf8(),1); - } - // - LC_CTYPE - if(ctype.isEmpty()){ unsetenv("LC_CTYPE"); } - else{ - if(!ctype.contains(".")){ ctype.append(".UTF-8"); } - setenv("LC_CTYPE",ctype.toUtf8(),1); - } -} - -QString LUtils::currentLocale(){ - QString curr = getenv("LC_ALL");// = QLocale::system(); - if(curr.isEmpty()){ curr = getenv("LANG"); } - if(curr.isEmpty()){ curr = "en_US"; } - curr = curr.section(".",0,0); //remove any encodings off the end - return curr; -} - -double LUtils::DisplaySizeToBytes(QString num){ - //qDebug() << "Convert Num to Bytes:" << num; - num = num.toLower().simplified(); - num = num.remove(" "); - if(num.isEmpty()){ return 0.0; } - if(num.endsWith("b")){ num.chop(1); } //remove the "bytes" marker (if there is one) - QString lab = "b"; - if(!num[num.size()-1].isNumber()){ - lab = num.right(1); num.chop(1); - } - double N = num.toDouble(); - QStringList labs; labs <<"b"<<"k"<<"m"<<"g"<<"t"<<"p"; //go up to petabytes for now - for(int i=0; i<labs.length(); i++){ - if(lab==labs[i]){ break; }//already at the right units - break out - N = N*1024.0; //Move to the next unit of measurement - } - //qDebug() << " - Done:" << QString::number(N) << lab << num; - return N; -} - -QString LUtils::BytesToDisplaySize(qint64 ibytes){ - static QStringList labs = QStringList(); - if(labs.isEmpty()){ labs << "B" << "K" << "M" << "G" << "T" << "P"; } - //Now get the dominant unit - int c=0; - double bytes = ibytes; //need to keep decimel places for calculations - while(bytes>=1000 && c<labs.length() ){ - bytes = bytes/1024; - c++; - } //labs[c] is the unit - //Bytes are now - //Now format the number (up to 3 digits, not including decimel places) - QString num; - if(bytes>=100){ - //No decimel places - num = QString::number(qRound(bytes)); - }else if(bytes>=10){ - //need 1 decimel place - num = QString::number( (qRound(bytes*10)/10.0) ); - }else if(bytes>=1){ - //need 2 decimel places - num = QString::number( (qRound(bytes*100)/100.0) ); - }else{ - //Fully decimel (3 places) - num = "0."+QString::number(qRound(bytes*1000)); - } - //qDebug() << "Bytes to Human-readable:" << bytes << c << num << labs[c]; - return (num+labs[c]); -} - -QString LUtils::SecondsToDisplay(int secs){ - if(secs < 0){ return "??"; } - QString rem; //remaining - if(secs > 3600){ - int hours = secs/3600; - rem.append( QString::number(hours)+"h "); - secs = secs - (hours*3600); - } - if(secs > 60){ - int min = secs/60; - rem.append( QString::number(min)+"m "); - secs = secs - (min*60); - } - if(secs > 0){ - rem.append( QString::number(secs)+"s"); - }else{ - rem.append( "0s" ); - } - return rem; -} - -//Various function for finding valid QtQuick plugins on the system -bool LUtils::validQuickPlugin(QString ID){ - return ( !LUtils::findQuickPluginFile(ID).isEmpty() ); -} - -QString LUtils::findQuickPluginFile(QString ID){ - if(ID.startsWith("quick-")){ ID = ID.section("-",1,50); } //just in case - //Give preference to any user-supplied plugins (overwrites for system plugins) - QString path = QString(getenv("XDG_CONFIG_HOME"))+"/lumina-desktop/quickplugins/quick-"+ID+".qml"; - if( QFile::exists(path) ){return path; } - path = LOS::LuminaShare()+"quickplugins/quick-"+ID+".qml"; - if( QFile::exists(path) ){return path; } - return ""; //could not be found -} - -QStringList LUtils::listQuickPlugins(){ - QDir dir(QString(getenv("XDG_CONFIG_HOME"))+"/lumina-desktop/quickplugins"); - QStringList files = dir.entryList(QStringList() << "quick-*.qml", QDir::Files | QDir::NoDotAndDotDot, QDir::Name); - dir.cd(LOS::LuminaShare()+"quickplugins"); - files << dir.entryList(QStringList() << "quick-*.qml", QDir::Files | QDir::NoDotAndDotDot, QDir::Name); - for(int i=0; i<files.length(); i++){ - files[i] = files[i].section("quick-",1,100).section(".qml",0,0); //just grab the ID out of the middle of the filename - } - files.removeDuplicates(); - //qDebug() << "Found Quick Plugins:" << files; - return files; -} - -QStringList LUtils::infoQuickPlugin(QString ID){ //Returns: [Name, Description, Icon] - //qDebug() << "Find Quick Info:" << ID; - QString path = findQuickPluginFile(ID); - //qDebug() << " - path:" << path; - if(path.isEmpty()){ return QStringList(); } //invalid ID - QStringList contents = LUtils::readFile(path); - if(contents.isEmpty()){ return QStringList(); } //invalid file (unreadable) - contents = contents.filter("//").filter("=").filter("Plugin"); //now just grab the comments - //qDebug() << " - Filtered Contents:" << contents; - QStringList info; info << "" << "" << ""; - for(int i=0; i<contents.length(); i++){ - if(contents[i].contains("Plugin-Name=")){ info[0] = contents[i].section("Plugin-Name=",1,1).simplified(); } - else if(contents[i].contains("Plugin-Description=")){ info[1] = contents[i].section("Plugin-Description=",1,1).simplified(); } - else if(contents[i].contains("Plugin-Icon=")){ info[2] = contents[i].section("Plugin-Icon=",1,1).simplified(); } - } - if(info[0].isEmpty()){ info[0]=ID; } - if(info[2].isEmpty()){ info[2]="preferences-plugin"; } - //qDebug() << " - info:" << info; - return info; -} - -QStringList LUtils::listFavorites(){ - static QDateTime lastRead; - QDateTime cur = QDateTime::currentDateTime(); - if(lastRead.isNull() || lastRead<QFileInfo( QString(getenv("XDG_CONFIG_HOME"))+"/lumina-desktop/favorites.list").lastModified()){ - fav = LUtils::readFile(QString(getenv("XDG_CONFIG_HOME"))+"/lumina-desktop/favorites.list"); - fav.removeAll(""); //remove any empty lines - fav.removeDuplicates(); - lastRead = cur; - } - - return fav; -} - -bool LUtils::saveFavorites(QStringList list){ - list.removeDuplicates(); - bool ok = LUtils::writeFile(QString(getenv("XDG_CONFIG_HOME"))+"/lumina-desktop/favorites.list", list, true); - if(ok){ fav = list; } //also save internally in case of rapid write/read of the file - return ok; -} - -bool LUtils::isFavorite(QString path){ - QStringList fav = LUtils::listFavorites(); - for(int i=0; i<fav.length(); i++){ - if(fav[i].endsWith("::::"+path)){ return true; } - } - return false; -} - -bool LUtils::addFavorite(QString path, QString name){ - //Generate the type of favorite this is - QFileInfo info(path); - QString type; - if(info.isDir()){ type="dir"; } - else if(info.suffix()=="desktop"){ type="app"; } - else{ type = LXDG::findAppMimeForFile(path); } - //Assign a name if none given - if(name.isEmpty()){ name = info.fileName(); } - //Now add it to the list - QStringList favs = LUtils::listFavorites(); - bool found = false; - for(int i=0; i<favs.length(); i++){ - if(favs[i].endsWith("::::"+path)){ favs[i] = name+"::::"+type+"::::"+path; } - } - if(!found){ favs << name+"::::"+type+"::::"+path; } - return LUtils::saveFavorites(favs); -} - -void LUtils::removeFavorite(QString path){ - QStringList fav = LUtils::listFavorites(); - bool changed = false; - for(int i=0; i<fav.length(); i++){ - if(fav[i].endsWith("::::"+path)){ fav.removeAt(i); i--; changed=true;} - } - if(changed){ LUtils::saveFavorites(fav); } -} - -void LUtils::upgradeFavorites(int fromoldversionnumber){ - /*if(fromoldversionnumber <= 8004){ // < pre-0.8.4>, sym-links in the ~/.lumina/favorites dir} - //Include 0.8.4-devel versions in this upgrade (need to distinguish b/w devel and release versions later somehow) - QDir favdir(QDir::homePath()+"/.lumina/favorites"); - QFileInfoList symlinks = favdir.entryInfoList(QDir::Files | QDir::Dirs | QDir::System | QDir::NoDotAndDotDot); - QStringList favfile = LUtils::listFavorites(); //just in case some already exist - bool newentry = false; - for(int i=0; i<symlinks.length(); i++){ - if(!symlinks[i].isSymLink()){ continue; } //not a symlink - QString path = symlinks[i].symLinkTarget(); - QString name = symlinks[i].fileName(); //just use the name of the symlink from the old system - QString type; - if(symlinks[i].isDir()){ type = "dir"; } - else if(name.endsWith(".desktop")){ type = "app"; } - else{ type = LXDG::findAppMimeForFile(path); } - //Put the line into the file - favfile << name+"::::"+type+"::::"+path; - //Now remove the symlink - obsolete format - QFile::remove(symlinks[i].absoluteFilePath()); - newentry = true; - } - if(newentry){ - LUtils::saveFavorites(favfile); - } - }*/ //end check for version <= 0.8.4 - -} - -void LUtils::LoadSystemDefaults(bool skipOS){ - //Will create the Lumina configuration files based on the current system template (if any) - qDebug() << "Loading System Defaults"; - QStringList sysDefaults; - if(!skipOS){ sysDefaults = LUtils::readFile(LOS::AppPrefix()+"etc/luminaDesktop.conf"); } - if(sysDefaults.isEmpty() && !skipOS){ sysDefaults = LUtils::readFile(LOS::AppPrefix()+"etc/luminaDesktop.conf.dist"); } - if(sysDefaults.isEmpty() && !skipOS) { sysDefaults = LUtils::readFile(LOS::SysPrefix()+"etc/luminaDesktop.conf"); } - if(sysDefaults.isEmpty() && !skipOS){ sysDefaults = LUtils::readFile(LOS::SysPrefix()+"etc/luminaDesktop.conf.dist"); } - if(sysDefaults.isEmpty() && !skipOS) { sysDefaults = LUtils::readFile(L_ETCDIR+"/luminaDesktop.conf"); } - if(sysDefaults.isEmpty() && !skipOS){ sysDefaults = LUtils::readFile(L_ETCDIR+"/luminaDesktop.conf.dist"); } - if(sysDefaults.isEmpty()){ sysDefaults = LUtils::readFile(LOS::LuminaShare()+"luminaDesktop.conf"); } - //Find the number of the left-most desktop screen - QString screen = "0"; - QDesktopWidget *desk =QApplication::desktop(); - QRect screenGeom; - for(int i=0; i<desk->screenCount(); i++){ - if(desk->screenGeometry(i).x()==0){ - screen = QString::number(i); - screenGeom = desk->screenGeometry(i); - break; - } - } - //Now setup the default "desktopsettings.conf" and "sessionsettings.conf" files - QStringList deskset, sesset;//, lopenset; - - // -- SESSION SETTINGS -- - QStringList tmp = sysDefaults.filter("session_"); - if(tmp.isEmpty()){ tmp = sysDefaults.filter("session."); }//for backwards compat - sesset << "[General]"; //everything is in this section - sesset << "DesktopVersion="+LUtils::LuminaDesktopVersion(); - for(int i=0; i<tmp.length(); i++){ - if(tmp[i].startsWith("#") || !tmp[i].contains("=") ){ continue; } - QString var = tmp[i].section("=",0,0).toLower().simplified(); - QString val = tmp[i].section("=",1,1).section("#",0,0).simplified(); - if(val.isEmpty()){ continue; } - QString istrue = (val.toLower()=="true") ? "true": "false"; - //Change in 0.8.5 - use "_" instead of "." within variables names - need backwards compat for a little while - if(var.contains(".")){ var.replace(".","_"); } - //Now parse the variable and put the value in the proper file - - if(var.contains("_default_")){ val = AppToAbsolute(val); } //got an application/binary - //Special handling for values which need to exist first - if(var.endsWith("_ifexists") ){ - var = var.remove("_ifexists"); //remove this flag from the variable - //Check if the value exists (absolute path only) - if(!QFile::exists(val)){ continue; } //skip this line - value/file does not exist - } - - //Parse/save the value - QString sset; //temporary strings - if(var=="session_enablenumlock"){ sset = "EnableNumlock="+ istrue; } - else if(var=="session_playloginaudio"){ sset = "PlayStartupAudio="+istrue; } - else if(var=="session_playlogoutaudio"){ sset = "PlayLogoutAudio="+istrue; } - else if(var=="session_default_terminal"){ - LXDG::setDefaultAppForMime("application/terminal", val); - //sset = "default-terminal="+val; - }else if(var=="session_default_filemanager"){ - LXDG::setDefaultAppForMime("inode/directory", val); - //sset = "default-filemanager="+val; - //loset = "directory="+val; - }else if(var=="session_default_webbrowser"){ - //loset = "webbrowser="+val; - LXDG::setDefaultAppForMime("x-scheme-handler/http", val); - LXDG::setDefaultAppForMime("x-scheme-handler/https", val); - }else if(var=="session_default_email"){ - LXDG::setDefaultAppForMime("application/email",val); - //loset = "email="+val; - } - //Put the line into the file (overwriting any previous assignment as necessary) - /*if(!loset.isEmpty()){ - int index = lopenset.indexOf(QRegExp(loset.section("=",0,0)+"=*", Qt::CaseSensitive, QRegExp::Wildcard)); - qDebug() << "loset line:" << loset << index << lopenset; - if(index<0){ lopenset << loset; } //new line - else{ lopenset[index] = loset; } //overwrite the other line - }*/ - if(!sset.isEmpty()){ - int index = sesset.indexOf(QRegExp(sset.section("=",0,0)+"=*", Qt::CaseSensitive, QRegExp::Wildcard)); - if(index<0){ sesset << sset; } //new line - else{ sesset[index] = sset; } //overwrite the other line - } - } - //if(!lopenset.isEmpty()){ lopenset.prepend("[default]"); } //the session options exist within this set - - // -- MIMETYPE DEFAULTS -- - tmp = sysDefaults.filter("mime_default_"); - for(int i=0; i<tmp.length(); i++){ - if(tmp[i].startsWith("#") || !tmp[i].contains("=") ){ continue; } - QString var = tmp[i].section("=",0,0).toLower().simplified(); - QString val = tmp[i].section("=",1,1).section("#",0,0).simplified(); - if(val.isEmpty()){ continue; } - QString istrue = (val.toLower()=="true") ? "true": "false"; - //Change in 0.8.5 - use "_" instead of "." within variables names - need backwards compat for a little while - if(var.contains(".")){ var.replace(".","_"); } - //Now parse the variable and put the value in the proper file - val = AppToAbsolute(val); - //Special handling for values which need to exist first - if(var.endsWith("_ifexists") ){ - var = var.remove("_ifexists"); //remove this flag from the variable - //Check if the value exists (absolute path only) - if(!QFile::exists(val)){ continue; } //skip this line - value/file does not exist - } - //Now turn this variable into the mimetype only - var = var.section("_default_",1,-1); - LXDG::setDefaultAppForMime(var, val); - } - - // -- DESKTOP SETTINGS -- - //(only works for the primary desktop at the moment) - tmp = sysDefaults.filter("desktop_"); - if(tmp.isEmpty()){ tmp = sysDefaults.filter("desktop."); }//for backwards compat - if(!tmp.isEmpty()){deskset << "[desktop-"+screen+"]"; } - for(int i=0; i<tmp.length(); i++){ - if(tmp[i].startsWith("#") || !tmp[i].contains("=") ){ continue; } - QString var = tmp[i].section("=",0,0).toLower().simplified(); - QString val = tmp[i].section("=",1,1).section("#",0,0).simplified(); - if(val.isEmpty()){ continue; } - QString istrue = (val.toLower()=="true") ? "true": "false"; - //Change in 0.8.5 - use "_" instead of "." within variables names - need backwards compat for a little while - if(var.contains(".")){ var.replace(".","_"); } - //Now parse the variable and put the value in the proper file - if(var=="desktop_visiblepanels"){ deskset << "panels="+val; } - else if(var=="desktop_backgroundfiles"){ deskset << "background\\filelist="+val; } - else if(var=="desktop_backgroundrotateminutes"){ deskset << "background\\minutesToChange="+val; } - else if(var=="desktop_plugins"){ deskset << "pluginlist="+val; } - else if(var=="desktop_generate_icons"){ deskset << "generateDesktopIcons="+istrue; } - } - if(!tmp.isEmpty()){ deskset << ""; } //space between sections - - // -- PANEL SETTINGS -- - //(only works for the primary desktop at the moment) - for(int i=1; i<11; i++){ - QString panvar = "panel"+QString::number(i); - tmp = sysDefaults.filter(panvar); - if(!tmp.isEmpty()){deskset << "[panel"+screen+"."+QString::number(i-1)+"]"; } - for(int i=0; i<tmp.length(); i++){ - if(tmp[i].startsWith("#") || !tmp[i].contains("=") ){ continue; } - QString var = tmp[i].section("=",0,0).toLower().simplified(); - QString val = tmp[i].section("=",1,1).section("#",0,0).simplified(); - if(val.isEmpty()){ continue; } - QString istrue = (val.toLower()=="true") ? "true": "false"; - //Change in 0.8.5 - use "_" instead of "." within variables names - need backwards compat for a little while - if(var.contains(".")){ var.replace(".","_"); } - //Now parse the variable and put the value in the proper file - if(var==(panvar+"_pixelsize")){ - //qDebug() << "Panel Size:" << val; - if(val.contains("%")){ - QString last = val.section("%",1,1).toLower(); //last character - val = val.section("%",0,0); - if(last=="h"){ val = QString::number( qRound(screenGeom.height()*val.toDouble())/100 ); }//adjust value to a percentage of the height of the screen - else if(last=="w"){ val = QString::number( qRound(screenGeom.width()*val.toDouble())/100 ); }//adjust value to a percentage of the width of the screen - } - //qDebug() << " -- Adjusted:" << val; - deskset << "height="+val; - } - else if(var==(panvar+"_autohide")){ deskset << "hidepanel="+istrue; } - else if(var==(panvar+"_location")){ deskset << "location="+val.toLower(); } - else if(var==(panvar+"_plugins")){ deskset << "pluginlist="+val; } - else if(var==(panvar+"_pinlocation")){ deskset << "pinLocation="+val.toLower(); } - else if(var==(panvar+"_edgepercent")){ deskset << "lengthPercent="+val; } - } - if(!tmp.isEmpty()){ deskset << ""; } //space between sections - } - - // -- MENU settings -- - tmp = sysDefaults.filter("menu_"); - if(tmp.isEmpty()){ tmp = sysDefaults.filter("menu."); } //backwards compat - if(!tmp.isEmpty()){deskset << "[menu]"; } - for(int i=0; i<tmp.length(); i++){ - if(tmp[i].startsWith("#") || !tmp[i].contains("=") ){ continue; } - QString var = tmp[i].section("=",0,0).simplified(); - QString val = tmp[i].section("=",1,1).section("#",0,0).toLower().simplified(); - if(val.isEmpty()){ continue; } - //Change in 0.8.5 - use "_" instead of "." within variables names - need backwards compat for a little while - if(var.contains(".")){ var.replace(".","_"); } - //Now parse the variable and put the value in the proper file - if(var=="menu_plugins"){ deskset << "itemlist="+val; } - } - if(!tmp.isEmpty()){ deskset << ""; } //space between sections - - // -- FAVORITES -- - tmp = sysDefaults.filter("favorites_"); - if(tmp.isEmpty()){ tmp = sysDefaults.filter("favorites."); } - for(int i=0; i<tmp.length(); i++){ - if(tmp[i].startsWith("#") || !tmp[i].contains("=") ){ continue; } - QString var = tmp[i].section("=",0,0).toLower().simplified(); - QString val = tmp[i].section("=",1,1).section("#",0,0).simplified(); - //Change in 0.8.5 - use "_" instead of "." within variables names - need backwards compat for a little while - if(var.contains(".")){ var.replace(".","_"); } - //Now parse the variable and put the value in the proper file - qDebug() << "Favorite entry:" << var << val; - val = AppToAbsolute(val); //turn any relative files into absolute - if(var=="favorites_add_ifexists" && QFile::exists(val)){ qDebug() << " - Exists/Adding:"; LUtils::addFavorite(val); } - else if(var=="favorites_add"){ qDebug() << " - Adding:"; LUtils::addFavorite(val); } - else if(var=="favorites_remove"){ qDebug() << " - Removing:"; LUtils::removeFavorite(val); } - } - - // -- QUICKLAUNCH -- - tmp = sysDefaults.filter("quicklaunch_"); - if(tmp.isEmpty()){ tmp = sysDefaults.filter("quicklaunch."); } - QStringList quickL; - for(int i=0; i<tmp.length(); i++){ - if(tmp[i].startsWith("#") || !tmp[i].contains("=") ){ continue; } - QString var = tmp[i].section("=",0,0).toLower().simplified(); - QString val = tmp[i].section("=",1,1).section("#",0,0).simplified(); - //Change in 0.8.5 - use "_" instead of "." within variables names - need backwards compat for a little while - if(var.contains(".")){ var.replace(".","_"); } - //Now parse the variable and put the value in the proper file - val = AppToAbsolute(val); //turn any relative files into absolute - if(var=="quicklaunch_add_ifexists" && QFile::exists(val)){ quickL << val; } - else if(var=="quicklaunch_add"){ quickL << val; } - } - if(!quickL.isEmpty()){ - if(sesset.isEmpty()){ sesset << "[General]"; } //everything is in this section - sesset << "QuicklaunchApps="+quickL.join(", "); - } - - //Now do any theme settings - QStringList themesettings = LTHEME::currentSettings(); - //List: [theme path, colorspath, iconsname, font, fontsize] - //qDebug() << "Current Theme Color:" << themesettings[1]; - tmp = sysDefaults.filter("theme_"); - if(tmp.isEmpty()){ tmp = sysDefaults.filter("theme."); } - bool setTheme = !tmp.isEmpty(); - for(int i=0; i<tmp.length(); i++){ - if(tmp[i].startsWith("#") || !tmp[i].contains("=") ){ continue; } - QString var = tmp[i].section("=",0,0).toLower().simplified(); - QString val = tmp[i].section("=",1,1).section("#",0,0).simplified(); - if(val.isEmpty()){ continue; } - //Change in 0.8.5 - use "_" instead of "." within variables names - need backwards compat for a little while - if(var.contains(".")){ var.replace(".","_"); } - //Now parse the variable and put the value in the proper file - if(var=="theme_themefile"){ themesettings[0] = val; } - else if(var=="theme_colorfile"){ themesettings[1] = val; } - else if(var=="theme_iconset"){ themesettings[2] = val; } - else if(var=="theme_font"){ themesettings[3] = val; } - else if(var=="theme_fontsize"){ - if(val.endsWith("%")){ val = QString::number( (screenGeom.height()*val.section("%",0,0).toDouble())/100 )+"px"; } - themesettings[4] = val; - } - } - //qDebug() << " - Now Color:" << themesettings[1] << setTheme; - - //Now double check that the custom theme/color files exist and reset it will the full path as necessary - if(setTheme){ - QStringList systhemes = LTHEME::availableSystemThemes(); - QStringList syscolors = LTHEME::availableSystemColors(); - //theme file - //qDebug() << "Detected Themes/colors:" << systhemes << syscolors; - if( !themesettings[0].startsWith("/") || !QFile::exists(themesettings[0]) || !themesettings[0].endsWith(".qss.template")){ - themesettings[0] = themesettings[0].section(".qss",0,0).simplified(); - for(int i=0; i<systhemes.length(); i++){ - if(systhemes[i].startsWith(themesettings[0]+"::::",Qt::CaseInsensitive)){ - themesettings[0] = systhemes[i].section("::::",1,1); //Replace with the full path - break; - } - } - } - //color file - if( !themesettings[1].startsWith("/") || !QFile::exists(themesettings[1]) || !themesettings[1].endsWith(".qss.colors") ){ - //Remove any extra/invalid extension - themesettings[1] = themesettings[1].section(".qss",0,0).simplified(); - for(int i=0; i<syscolors.length(); i++){ - if(syscolors[i].startsWith(themesettings[1]+"::::",Qt::CaseInsensitive)){ - themesettings[1] = syscolors[i].section("::::",1,1); //Replace with the full path - break; - } - } - } - } - //qDebug() << " - Final Theme Color:" << themesettings[1]; - - //Ensure that the settings directory exists - QString setdir = QString(getenv("XDG_CONFIG_HOME"))+"/lumina-desktop"; - if(!QFile::exists(setdir)){ - QDir dir; - dir.mkpath(setdir); - } - //Now save the settings files - if(setTheme){ LTHEME::setCurrentSettings( themesettings[0], themesettings[1], themesettings[2], themesettings[3], themesettings[4]); } - LUtils::writeFile(setdir+"/sessionsettings.conf", sesset, true); - LUtils::writeFile(setdir+"/desktopsettings.conf", deskset, true); - - //Now run any extra config scripts or utilities as needed - tmp = sysDefaults.filter("usersetup_run"); - if(tmp.isEmpty()){ tmp = sysDefaults.filter("usersetup.run"); } - for(int i=0; i<tmp.length(); i++){ - if(tmp[i].startsWith("#") || !tmp[i].contains("=") ){ continue; } - QString var = tmp[i].section("=",0,0).toLower().simplified(); - QString val = tmp[i].section("=",1,1).section("#",0,0).simplified(); - //Change in 0.8.5 - use "_" instead of "." within variables names - need backwards compat for a little while - if(var.contains(".")){ var.replace(".","_"); } - //Now parse the variable and put the value in the proper file - if(var=="usersetup_run"){ - qDebug() << "Running user setup command:" << val; - QProcess::execute(val); - } - } - -} - -bool LUtils::checkUserFiles(QString lastversion){ - //internal version conversion examples: - // [1.0.0 -> 1000000], [1.2.3 -> 1002003], [0.6.1 -> 6001] - //returns true if something changed - int oldversion = LUtils::VersionStringToNumber(lastversion); - int nversion = LUtils::VersionStringToNumber(QApplication::applicationVersion()); - bool newversion = ( oldversion < nversion ); //increasing version number - bool newrelease = ( lastversion.contains("-devel", Qt::CaseInsensitive) && QApplication::applicationVersion().contains("-release", Qt::CaseInsensitive) ); //Moving from devel to release - - QString confdir = QString(getenv("XDG_CONFIG_HOME"))+"/lumina-desktop/"; - //Check for the desktop settings file - QString dset = confdir+"desktopsettings.conf"; - bool firstrun = false; - if(!QFile::exists(dset) || oldversion < 5000){ - if( oldversion < 100000 && nversion>=100000 ){ system("rm -rf ~/.lumina"); qDebug() << "Current desktop settings obsolete: Re-implementing defaults"; } - else{ firstrun = true; } - LUtils::LoadSystemDefaults(); - } - //Convert the favorites framework as necessary (change occured with 0.8.4) - if(newversion || newrelease){ - LUtils::upgradeFavorites(oldversion); - } - //Convert from the old desktop numbering system to the new one (change occured with 1.0.1) - if(oldversion<=1000001){ - QStringList DS = LUtils::readFile(dset); - QList<QScreen*> screens = QApplication::screens(); - for(int i=0; i<DS.length(); i++){ - if(!DS[i].startsWith("[")){ continue; } - if(DS[i].startsWith("[desktop-")){ - bool ok = false; - int num = DS[i].section("desktop-",-1).section("]",0,0).toInt(&ok); - if(num>=0 && ok && num< screens.length()){ - //This one needs to be converted - DS[i] = "[desktop-"+screens[num]->name()+"]"; - } - }else if(DS[i].startsWith("[panel")){ - bool ok = false; - int num = DS[i].section("panel",-1).section(".",0,0).toInt(&ok); - if(num>=0 && ok && num< screens.length()){ - //This one needs to be converted - QString rest = DS[i].section(".",1,-1); //everything after the desktop number in the current setting - DS[i] = "[panel_"+screens[num]->name()+"."+rest; - } - } - } - LUtils::writeFile(dset, DS, true); - } - - //Check the fluxbox configuration files - dset = QString(getenv("XDG_CONFIG_HOME"))+"/lumina-desktop/"; - if(!QFile::exists(dset+"fluxbox-init")){ - firstrun = true; - } - bool fluxcopy = false; - if(!QFile::exists(dset+"fluxbox-init")){ fluxcopy=true; } - else if(!QFile::exists(dset+"fluxbox-keys")){fluxcopy=true; } - else if(oldversion < 60){ fluxcopy=true; qDebug() << "Current fluxbox settings obsolete: Re-implementing defaults"; } - if(fluxcopy){ - qDebug() << "Copying default fluxbox configuration files"; - if(QFile::exists(dset+"fluxbox-init")){ QFile::remove(dset+"fluxbox-init"); } - if(QFile::exists(dset+"fluxbox-keys")){ QFile::remove(dset+"fluxbox-keys"); } - QString finit = LUtils::readFile(LOS::LuminaShare()+"fluxbox-init-rc").join("\n"); - finit.replace("${XDG_CONFIG_HOME}", QString(getenv("XDG_CONFIG_HOME"))); - LUtils::writeFile(dset+"fluxbox-init", finit.split("\n")); - QFile::copy(LOS::LuminaShare()+"fluxbox-keys", dset+"fluxbox-keys"); - QFile::setPermissions(dset+"fluxbox-init", QFile::ReadOwner | QFile::WriteOwner | QFile::ReadUser | QFile::ReadOther | QFile::ReadGroup); - QFile::setPermissions(dset+"fluxbox-keys", QFile::ReadOwner | QFile::WriteOwner | QFile::ReadUser | QFile::ReadOther | QFile::ReadGroup); - } - - if(firstrun){ qDebug() << "First time using Lumina!!"; } - return (firstrun || newversion || newrelease); -} - -int LUtils::VersionStringToNumber(QString version){ - version = version.section("-",0,0); //trim any extra labels off the end - int maj, mid, min; //major/middle/minor version numbers (<Major>.<Middle>.<Minor>) - maj = mid = min = 0; - bool ok = true; - maj = version.section(".",0,0).toInt(&ok); - if(ok){ mid = version.section(".",1,1).toInt(&ok); }else{ maj = 0; } - if(ok){ min = version.section(".",2,2).toInt(&ok); }else{ mid = 0; } - if(!ok){ min = 0; } - //Now assemble the number - //NOTE: This format allows numbers to be anywhere from 0->999 without conflict - return (maj*1000000 + mid*1000 + min); -} - -// ======================= -// RESIZEMENU CLASS -// ======================= -/*ResizeMenu::ResizeMenu(QWidget *parent) : QMenu(parent){ - this->setContentsMargins(1,1,1,1); - this->setMouseTracking(true); - resizeSide = NONE; - cAct = new QWidgetAction(this); - contents = 0; - connect(this, SIGNAL(aboutToShow()), this, SLOT(clearFlags()) ); - connect(this, SIGNAL(aboutToHide()), this, SLOT(clearFlags()) ); - connect(cAct, SIGNAL(hovered()), this, SLOT(clearFlags()) ); -} - -ResizeMenu::~ResizeMenu(){ - -} - -void ResizeMenu::setContents(QWidget *con){ - this->clear(); - cAct->setDefaultWidget(con); - this->addAction(cAct); - contents = con; //save for later - contents->setCursor(Qt::ArrowCursor); -} - -void ResizeMenu::mouseMoveEvent(QMouseEvent *ev){ - QRect geom = this->geometry(); - //Note: The exact position does not matter as much as the size - // since the window will be moved again the next time it is shown - // The "-2" in the sizing below accounts for the menu margins - QPoint gpos = this->mapToGlobal(ev->pos()); - bool handled = false; - switch(resizeSide){ - case TOP: - if(gpos.y() >= geom.bottom()-1){ break; } - geom.setTop(gpos.y()); - this->setGeometry(geom); - if(contents!=0){ contents->setFixedSize(QSize(geom.width()-2, geom.height()-2));} - handled = true; - break; - case BOTTOM: - if(gpos.y() <= geom.top()+1){ break; } - geom.setBottom( gpos.y()); - this->setGeometry(geom); - if(contents!=0){ contents->setFixedSize(QSize(geom.width()-2, geom.height()-2));} - handled = true; - break; - case LEFT: - if(gpos.x() >= geom.right()-1){ break; } - geom.setLeft(gpos.x()); - this->setGeometry(geom); - if(contents!=0){ contents->setFixedSize(QSize(geom.width()-2, geom.height()-2));} - handled = true; - break; - case RIGHT: - if(gpos.x() <= geom.left()+1){ break; } - geom.setRight(gpos.x()); - this->setGeometry(geom); - if(contents!=0){ contents->setFixedSize(QSize(geom.width()-2, geom.height()-2));} - handled = true; - break; - default: //NONE - //qDebug() << " - Mouse At:" << ev->pos(); - //Just adjust the mouse cursor which is shown - if(ev->pos().x()<=1 && ev->pos().x() >= -1){ this->setCursor(Qt::SizeHorCursor); } - else if(ev->pos().x() >= this->width()-1 && ev->pos().x() <= this->width()+1){ this->setCursor(Qt::SizeHorCursor); } - else if(ev->pos().y()<=1 && ev->pos().y() >= -1){ this->setCursor(Qt::SizeVerCursor); } - else if(ev->pos().y() >= this->height()-1 && ev->pos().y() <= this->height()+1){ this->setCursor(Qt::SizeVerCursor); } - else{ this->setCursor(Qt::ArrowCursor); } - } - if(!handled){ QMenu::mouseMoveEvent(ev); } //do normal processing as well -} - -void ResizeMenu::mousePressEvent(QMouseEvent *ev){ - bool used = false; - if(ev->buttons().testFlag(Qt::LeftButton) && resizeSide==NONE){ - //qDebug() << "Mouse Press Event:" << ev->pos() << resizeSide; - if(ev->pos().x()<=1 && ev->pos().x() >= -1){resizeSide = LEFT; used = true;} - else if(ev->pos().x() >= this->width()-1 && ev->pos().x() <= this->width()+1){ resizeSide = RIGHT; used = true;} - else if(ev->pos().y()<=1 && ev->pos().y() >= -1){ resizeSide = TOP; used = true; } - else if(ev->pos().y() >= this->height()-1 && ev->pos().y() <= this->height()+1){ resizeSide = BOTTOM; used = true; } - } - if(used){ ev->accept(); this->grabMouse(); } - else{ QMenu::mousePressEvent(ev); } //do normal processing -} - -void ResizeMenu::mouseReleaseEvent(QMouseEvent *ev){ - this->releaseMouse(); - if(ev->button() == Qt::LeftButton && resizeSide!=NONE ){ - //qDebug() << "Mouse Release Event:" << ev->pos() << resizeSide; - resizeSide = NONE; - emit MenuResized(contents->size()); - ev->accept(); - }else{ - QMenu::mouseReleaseEvent(ev); //do normal processing - } -}*/ diff --git a/src-qt5/core/libLumina/LuminaUtils.h b/src-qt5/core/libLumina/LuminaUtils.h deleted file mode 100644 index 4a0a19af..00000000 --- a/src-qt5/core/libLumina/LuminaUtils.h +++ /dev/null @@ -1,131 +0,0 @@ -//=========================================== -// Lumina-DE source code -// Copyright (c) 2012-2015, Ken Moore -// Available under the 3-clause BSD license -// See the LICENSE file for full details -//=========================================== -#ifndef _LUMINA_LIBRARY_UTILS_H -#define _LUMINA_LIBRARY_UTILS_H - -#include <QCoreApplication> -#include <QProcess> -#include <QTextStream> -#include <QFile> -#include <QDir> -#include <QString> -#include <QStringList> -#include <QFile> -#include <QFileInfo> -#include <QObject> -#include <QTranslator> -//#include <QApplication> -#include <QMenu> -#include <QMouseEvent> -#include <QSize> -#include <QWidgetAction> - -class LUtils{ -public: - //Get the current version/build of the Lumina desktop - static QString LuminaDesktopVersion(); - static QString LuminaDesktopBuildDate(); - - //Run an external command and return the exit code - static int runCmd(QString cmd, QStringList args = QStringList()); - //Run an external command and return any text output (one line per entry) - static QStringList getCmdOutput(QString cmd, QStringList args = QStringList()); - - //Read a text file - static QStringList readFile(QString filepath); - //Write a text file - static bool writeFile(QString filepath, QStringList contents, bool overwrite=false); - - //Check whether a file/path is a valid binary - static bool isValidBinary(QString& bin); //full path or name only - static bool isValidBinary(const char *bin){ - QString bins(bin); - return isValidBinary(bins); //overload for a "junk" binary variable input - } - - //Create the exec string to open a terminal in a particular directory - static QString GenerateOpenTerminalExec(QString term, QString dirpath); - - //List all the sub-directories of a parent dir (recursive) - static QStringList listSubDirectories(QString dir, bool recursive = true); - - //Convert an input file/dir path to an absolute file path - static QString PathToAbsolute(QString path); //This is primarily for CLI usage (relative paths) - static QString AppToAbsolute(QString path); //This is for looking up a binary/ *.desktop path - - //Get the list of all file extensions which Qt can read (lowercase) - static QStringList imageExtensions(bool wildcards = false); - - //Load a translation file for a Lumina Project - static QTranslator* LoadTranslation(QApplication *app, QString appname, QString locale = "", QTranslator *cTrans = 0); - //Other localization shortcuts - static QStringList knownLocales(); //Note: This only lists locales known to Lumina (so the i18n files need to be installed) - static void setLocaleEnv(QString lang, QString msg="", QString time="", QString num="" ,QString money="",QString collate="", QString ctype=""); - static QString currentLocale(); - - //Number format conversions - static double DisplaySizeToBytes(QString num); //Turn a display size (like 50M or 50KB) into a double for calculations (bytes) - static QString BytesToDisplaySize(qint64 bytes); //convert into a readable size (like 50M or 50KB) - - static QString SecondsToDisplay(int secs); //convert into a readable time - - //Various function for finding valid QtQuick plugins on the system - static bool validQuickPlugin(QString ID); - static QString findQuickPluginFile(QString ID); - static QStringList listQuickPlugins(); //List of valid ID's - static QStringList infoQuickPlugin(QString ID); //Returns: [Name, Description, Icon] - - //Various functions for the favorites sub-system - // Formatting Note: "<name>::::[dir/app/<mimetype>]::::<path>" - // the <name> field might not be used for "app" flagged entries - static QStringList listFavorites(); - static bool saveFavorites(QStringList); - static bool isFavorite(QString path); - static bool addFavorite(QString path, QString name = ""); - static void removeFavorite(QString path); - static void upgradeFavorites(int fromoldversionnumber); - - //Load the default setup for the system - static void LoadSystemDefaults(bool skipOS = false); - static bool checkUserFiles(QString lastversion); //returns true if something changed - static int VersionStringToNumber(QString version); //convert the lumina version string to a number for comparisons - -}; - -//Special subclass for a menu which the user can grab the edges and resize as necessary -// Note: Make sure that you don't set 0pixel contents margins on this menu -// - it needs at least 1 pixel margins for the user to be able to grab it -/*class ResizeMenu : public QMenu{ - Q_OBJECT -public: - ResizeMenu(QWidget *parent = 0); - virtual ~ResizeMenu(); - - void setContents(QWidget *con); - -private: - enum SideFlag{NONE, TOP, BOTTOM, LEFT, RIGHT}; - SideFlag resizeSide; - QWidget *contents; - QWidgetAction *cAct; - -private slots: - void clearFlags(){ - resizeSide=NONE; - } - -protected: - virtual void mouseMoveEvent(QMouseEvent *ev); - virtual void mousePressEvent(QMouseEvent *ev); - virtual void mouseReleaseEvent(QMouseEvent *ev); - -signals: - void MenuResized(QSize); //Emitted when the menu is manually resized by the user - -};*/ - -#endif diff --git a/src-qt5/core/libLumina/LuminaX11.pri b/src-qt5/core/libLumina/LuminaX11.pri new file mode 100644 index 00000000..0e472dd4 --- /dev/null +++ b/src-qt5/core/libLumina/LuminaX11.pri @@ -0,0 +1,13 @@ + +QT *= x11extras + +LIBS *= -lc -lxcb -lxcb-ewmh -lxcb-icccm -lxcb-image -lxcb-composite -lxcb-damage -lxcb-util -lXdamage + +#LUtils Files +SOURCES *= $${PWD}/LuminaX11.cpp +HEADERS *= $${PWD}/LuminaX11.h + +INCLUDEPATH *= ${PWD} + +#include LUtils and LuminaOS +include(LUtils.pri) diff --git a/src-qt5/core/libLumina/LuminaXDG.cpp b/src-qt5/core/libLumina/LuminaXDG.cpp index b0d2edd9..d6342269 100644 --- a/src-qt5/core/libLumina/LuminaXDG.cpp +++ b/src-qt5/core/libLumina/LuminaXDG.cpp @@ -6,7 +6,7 @@ //=========================================== #include "LuminaXDG.h" #include "LuminaOS.h" -#include "LuminaUtils.h" +#include "LUtils.h" #include <QObject> #include <QTimer> #include <QMediaPlayer> diff --git a/src-qt5/core/libLumina/LuminaXDG.pri b/src-qt5/core/libLumina/LuminaXDG.pri new file mode 100644 index 00000000..6f3a2b7c --- /dev/null +++ b/src-qt5/core/libLumina/LuminaXDG.pri @@ -0,0 +1,10 @@ +QT *= multimedia svg + +#LUtils Files +SOURCES *= $${PWD}/LuminaXDG.cpp +HEADERS *= $${PWD}/LuminaXDG.h + +INCLUDEPATH *= ${PWD} + +#include LUtils and LuminaOS +include(LUtils.pri) diff --git a/src-qt5/core/libLumina/colors/Black.qss.colors b/src-qt5/core/libLumina/colors/Black.qss.colors deleted file mode 100644 index b6269188..00000000 --- a/src-qt5/core/libLumina/colors/Black.qss.colors +++ /dev/null @@ -1,13 +0,0 @@ -ACCENTCOLOR=rgba(204,204,204,200) -ACCENTDISABLECOLOR=rgba(204,204,204,100) -ALTBASECOLOR=rgb(37,37,37) -BASECOLOR=rgb(36,36,36) -HIGHLIGHTCOLOR=rgba(218,222,226,170) -HIGHLIGHTDISABLECOLOR=rgba(218,222,226,160) -PRIMARYCOLOR=rgba(0,0,4,250) -PRIMARYDISABLECOLOR=rgba(0,0,0,180) -SECONDARYCOLOR=rgba(192,192,192,200) -SECONDARYDISABLECOLOR=rgba(192,192,192,100) -TEXTCOLOR=white -TEXTDISABLECOLOR=darkgrey -TEXTHIGHLIGHTCOLOR=black diff --git a/src-qt5/core/libLumina/colors/Blue-Light.qss.colors b/src-qt5/core/libLumina/colors/Blue-Light.qss.colors deleted file mode 100644 index 5bcb85f6..00000000 --- a/src-qt5/core/libLumina/colors/Blue-Light.qss.colors +++ /dev/null @@ -1,13 +0,0 @@ -ACCENTCOLOR=rgba(157,161,165,200) -ACCENTDISABLECOLOR=rgba(156,156,157,200) -ALTBASECOLOR=rgb(239,247,255) -BASECOLOR=rgb(165,210,255) -HIGHLIGHTCOLOR=rgb(110,158,208) -HIGHLIGHTDISABLECOLOR=rgba(110,158,208,150) -PRIMARYCOLOR=rgba(181,212,238,200) -PRIMARYDISABLECOLOR=rgba(234,237,238,100) -SECONDARYCOLOR=rgba(200,222,243,200) -SECONDARYDISABLECOLOR=rgba(200,222,243,100) -TEXTCOLOR=black -TEXTDISABLECOLOR=grey -TEXTHIGHLIGHTCOLOR=black diff --git a/src-qt5/core/libLumina/colors/Grey-Dark.qss.colors b/src-qt5/core/libLumina/colors/Grey-Dark.qss.colors deleted file mode 100644 index 207edd04..00000000 --- a/src-qt5/core/libLumina/colors/Grey-Dark.qss.colors +++ /dev/null @@ -1,13 +0,0 @@ -ACCENTCOLOR=rgba(43,43,45,200) -ACCENTDISABLECOLOR=rgba(43,43,45,100) -ALTBASECOLOR=rgb(63,61,61) -BASECOLOR=rgb(93,92,92) -HIGHLIGHTCOLOR=rgba(218,222,226,170) -HIGHLIGHTDISABLECOLOR=rgba(218,222,226,160) -PRIMARYCOLOR=rgba(75,77,80,240) -PRIMARYDISABLECOLOR=rgba(75,77,80,180) -SECONDARYCOLOR=rgba(144,140,142,200) -SECONDARYDISABLECOLOR=rgba(144,140,142,100) -TEXTCOLOR=white -TEXTDISABLECOLOR=darkgrey -TEXTHIGHLIGHTCOLOR=black diff --git a/src-qt5/core/libLumina/colors/Lumina-Glass.qss.colors b/src-qt5/core/libLumina/colors/Lumina-Glass.qss.colors deleted file mode 100644 index 89534aaa..00000000 --- a/src-qt5/core/libLumina/colors/Lumina-Glass.qss.colors +++ /dev/null @@ -1,13 +0,0 @@ -ACCENTCOLOR=rgba(255,252,234,100) -ACCENTDISABLECOLOR=rgba(0,0,0,100) -ALTBASECOLOR=rgba(255,255,255,125) -BASECOLOR=rgb(247,246,244) -HIGHLIGHTCOLOR=rgba(212,212,212,170) -HIGHLIGHTDISABLECOLOR=rgba(184,184,184,100) -PRIMARYCOLOR=rgba(235,242,242,200) -PRIMARYDISABLECOLOR=rgba(214,220,220,200) -SECONDARYCOLOR=rgba(100,100,100,200) -SECONDARYDISABLECOLOR=rgba(100,100,100,100) -TEXTCOLOR=black -TEXTDISABLECOLOR=grey -TEXTHIGHLIGHTCOLOR=black diff --git a/src-qt5/core/libLumina/colors/Lumina-Gold.qss.colors b/src-qt5/core/libLumina/colors/Lumina-Gold.qss.colors deleted file mode 100644 index cfad7069..00000000 --- a/src-qt5/core/libLumina/colors/Lumina-Gold.qss.colors +++ /dev/null @@ -1,13 +0,0 @@ -ACCENTCOLOR=rgba(149,144,122,200) -ACCENTDISABLECOLOR=rgba(74,71,60,200) -ALTBASECOLOR=rgb(230,227,204) -BASECOLOR=rgb(247,247,240) -HIGHLIGHTCOLOR=rgba(252,237,149,170) -HIGHLIGHTDISABLECOLOR=rgba(252,237,149,100) -PRIMARYCOLOR=rgba(238,234,226,200) -PRIMARYDISABLECOLOR=rgba(238,235,224,100) -SECONDARYCOLOR=rgba(247,209,112,200) -SECONDARYDISABLECOLOR=rgba(234,198,106,150) -TEXTCOLOR=black -TEXTDISABLECOLOR=grey -TEXTHIGHLIGHTCOLOR=black \ No newline at end of file diff --git a/src-qt5/core/libLumina/colors/Lumina-Green.qss.colors b/src-qt5/core/libLumina/colors/Lumina-Green.qss.colors deleted file mode 100644 index 99f16acb..00000000 --- a/src-qt5/core/libLumina/colors/Lumina-Green.qss.colors +++ /dev/null @@ -1,13 +0,0 @@ -ACCENTCOLOR=rgba(149,144,122,200) -ACCENTDISABLECOLOR=rgba(74,71,60,200) -ALTBASECOLOR=rgb(230,230,230) -BASECOLOR=rgb(247,246,244) -HIGHLIGHTCOLOR=rgba(66,153,76,170) -HIGHLIGHTDISABLECOLOR=rgba(66,153,76,100) -PRIMARYCOLOR=rgba(229,231,238,200) -PRIMARYDISABLECOLOR=rgba(229,231,238,100) -SECONDARYCOLOR=rgba(76,197,84,200) -SECONDARYDISABLECOLOR=rgba(76,197,84,150) -TEXTCOLOR=black -TEXTDISABLECOLOR=grey -TEXTHIGHLIGHTCOLOR=black diff --git a/src-qt5/core/libLumina/colors/Lumina-Purple.qss.colors b/src-qt5/core/libLumina/colors/Lumina-Purple.qss.colors deleted file mode 100644 index f2ba7e05..00000000 --- a/src-qt5/core/libLumina/colors/Lumina-Purple.qss.colors +++ /dev/null @@ -1,13 +0,0 @@ -ACCENTCOLOR=rgba(247,231,255,200) -ACCENTDISABLECOLOR=rgba(167,166,166,200) -ALTBASECOLOR=rgb(63,61,61) -BASECOLOR=rgb(93,92,92) -HIGHLIGHTCOLOR=rgba(76,38,171,170) -HIGHLIGHTDISABLECOLOR=rgba(57,19,139,170) -PRIMARYCOLOR=rgba(65,67,80,240) -PRIMARYDISABLECOLOR=rgba(65,67,80,180) -SECONDARYCOLOR=rgba(74,65,120,200) -SECONDARYDISABLECOLOR=rgba(71,65,120,100) -TEXTCOLOR=white -TEXTDISABLECOLOR=darkgrey -TEXTHIGHLIGHTCOLOR=white \ No newline at end of file diff --git a/src-qt5/core/libLumina/colors/Lumina-Red.qss.colors b/src-qt5/core/libLumina/colors/Lumina-Red.qss.colors deleted file mode 100644 index f73bdb75..00000000 --- a/src-qt5/core/libLumina/colors/Lumina-Red.qss.colors +++ /dev/null @@ -1,13 +0,0 @@ -ACCENTCOLOR=rgba(255,244,245,200) -ACCENTDISABLECOLOR=rgba(167,166,166,200) -ALTBASECOLOR=rgb(63,61,61) -BASECOLOR=rgb(93,92,92) -HIGHLIGHTCOLOR=rgba(175,9,9,170) -HIGHLIGHTDISABLECOLOR=rgba(154,20,20,170) -PRIMARYCOLOR=rgba(80,66,66,240) -PRIMARYDISABLECOLOR=rgba(80,66,66,180) -SECONDARYCOLOR=rgba(120,22,23,200) -SECONDARYDISABLECOLOR=rgba(120,22,23,100) -TEXTCOLOR=white -TEXTDISABLECOLOR=darkgrey -TEXTHIGHLIGHTCOLOR=white \ No newline at end of file diff --git a/src-qt5/core/libLumina/colors/PCBSD10-Default.qss.colors b/src-qt5/core/libLumina/colors/PCBSD10-Default.qss.colors deleted file mode 100644 index efcea51d..00000000 --- a/src-qt5/core/libLumina/colors/PCBSD10-Default.qss.colors +++ /dev/null @@ -1,13 +0,0 @@ -ACCENTCOLOR=rgba(182,186,191,200) -ACCENTDISABLECOLOR=rgba(190,190,191,200) -ALTBASECOLOR=rgb(241,241,241) -BASECOLOR=rgb(247,246,244) -HIGHLIGHTCOLOR=rgb(129,184,243) -HIGHLIGHTDISABLECOLOR=rgba(129,184,243,150) -PRIMARYCOLOR=rgba(224,236,238,200) -PRIMARYDISABLECOLOR=rgba(234,237,238,100) -SECONDARYCOLOR=rgba(200,222,243,200) -SECONDARYDISABLECOLOR=rgba(200,222,243,100) -TEXTCOLOR=black -TEXTDISABLECOLOR=grey -TEXTHIGHLIGHTCOLOR=black diff --git a/src-qt5/core/libLumina/colors/Solarized-Dark.qss.colors b/src-qt5/core/libLumina/colors/Solarized-Dark.qss.colors deleted file mode 100644 index d4f0f1c9..00000000 --- a/src-qt5/core/libLumina/colors/Solarized-Dark.qss.colors +++ /dev/null @@ -1,16 +0,0 @@ -# Solarized is a theme created by Ethan Schoonover -# See the project site at http://ethanschoonover.com/solarized -# Or see the source at https://github.com/altercation/solarized -ACCENTCOLOR=rgb(181,137,0) -ACCENTDISABLECOLOR=rgb(181,137,0) -ALTBASECOLOR=rgb(0,43,54) -BASECOLOR=rgb(0,43,54) -HIGHLIGHTCOLOR=rgb(7,54,66) -HIGHLIGHTDISABLECOLOR=rgb(7,53,66) -PRIMARYCOLOR=rgb(0,43,54) -PRIMARYDISABLECOLOR=rgb(7,54,66) -SECONDARYCOLOR=rgb(0,43,54) -SECONDARYDISABLECOLOR=rgb(7,54,66) -TEXTCOLOR=rgb(131,148,150) -TEXTDISABLECOLOR=rgb(88,110,117) -TEXTHIGHLIGHTCOLOR=rgb(147,161,161) diff --git a/src-qt5/core/libLumina/colors/Solarized-Light.qss.colors b/src-qt5/core/libLumina/colors/Solarized-Light.qss.colors deleted file mode 100644 index fead1915..00000000 --- a/src-qt5/core/libLumina/colors/Solarized-Light.qss.colors +++ /dev/null @@ -1,16 +0,0 @@ -# Solarized is a theme created by Ethan Schoonover -# See the project site at http://ethanschoonover.com/solarized -# Or see the source at https://github.com/altercation/solarized -ACCENTCOLOR=rgb(38,139,210) -ACCENTDISABLECOLOR=rgb(38,139,210) -ALTBASECOLOR=rgb(253,246,227) -BASECOLOR=rgb(253,246,227) -HIGHLIGHTCOLOR=rgb(238,232,213) -HIGHLIGHTDISABLECOLOR=rgb(238,232,213) -PRIMARYCOLOR=rgb(253,246,227) -PRIMARYDISABLECOLOR=rgb(238,232,213) -SECONDARYCOLOR=rgb(253,246,227) -SECONDARYDISABLECOLOR=rgb(238,232,213) -TEXTCOLOR=rgb(131,148,150) -TEXTDISABLECOLOR=rgb(147,161,161) -TEXTHIGHLIGHTCOLOR=rgb(88,110,117) diff --git a/src-qt5/core/libLumina/libLumina.pro b/src-qt5/core/libLumina/libLumina.pro index 2786b875..a7dc160a 100644 --- a/src-qt5/core/libLumina/libLumina.pro +++ b/src-qt5/core/libLumina/libLumina.pro @@ -1,57 +1,57 @@ -include("$${PWD}/../../OS-detect.pri") +#include("$${PWD}/../../OS-detect.pri") -QT += core network widgets x11extras multimedia concurrent svg +#QT += core network widgets x11extras multimedia concurrent svg -define +#define #Setup any special defines (qmake -> C++) -GIT_VERSION=$$system(git describe --always) -!isEmpty(GIT_VERSION){ - DEFINES += GIT_VERSION='"\\\"$${GIT_VERSION}\\\""' -} -DEFINES += BUILD_DATE='"\\\"$$system(date)\\\""' +#GIT_VERSION=$$system(git describe --always) +#!isEmpty(GIT_VERSION){ +# DEFINES += GIT_VERSION='"\\\"$${GIT_VERSION}\\\""' +#} +#DEFINES += BUILD_DATE='"\\\"$$system(date)\\\""' -TARGET=LuminaUtils +#TARGET=LuminaUtils -target.path = $${L_LIBDIR} +#target.path = $${L_LIBDIR} -DESTDIR= $$_PRO_FILE_PWD_/ +#DESTDIR= $$_PRO_FILE_PWD_/ -TEMPLATE = lib -LANGUAGE = C++ -VERSION = 1 +#TEMPLATE = lib +#LANGUAGE = C++ +#VERSION = 1 -HEADERS += LuminaXDG.h \ - LuminaUtils.h \ - LuminaX11.h \ - LuminaThemes.h \ - LuminaOS.h \ - LuminaSingleApplication.h +#HEADERS += LuminaXDG.h \ +# LuminaUtils.h \ +# LuminaX11.h \ +# LuminaThemes.h \ +# LuminaOS.h \ +# LuminaSingleApplication.h -SOURCES += LuminaXDG.cpp \ - LuminaUtils.cpp \ - LuminaX11.cpp \ - LuminaThemes.cpp \ - LuminaSingleApplication.cpp +#SOURCES += LuminaXDG.cpp \ +# LuminaUtils.cpp \ +# LuminaX11.cpp \ +# LuminaThemes.cpp \ +# LuminaSingleApplication.cpp # Also load the OS template as available for # LuminaOS support functions (or fall back to generic one) -exists($${PWD}/LuminaOS-$${LINUX_DISTRO}.cpp){ - SOURCES += LuminaOS-$${LINUX_DISTRO}.cpp -}else:exists($${PWD}/LuminaOS-$${OS}.cpp){ - SOURCES += LuminaOS-$${OS}.cpp -}else{ - SOURCES += LuminaOS-template.cpp -} - -LIBS += -lc -lxcb -lxcb-ewmh -lxcb-icccm -lxcb-image -lxcb-composite -lxcb-damage -lxcb-util -lXdamage - -include.path=$${L_INCLUDEDIR} -include.files=LuminaXDG.h \ - LuminaUtils.h \ - LuminaX11.h \ - LuminaThemes.h \ - LuminaOS.h \ - LuminaSingleApplication.h +#exists($${PWD}/LuminaOS-$${LINUX_DISTRO}.cpp){ +# SOURCES += LuminaOS-$${LINUX_DISTRO}.cpp +#}else:exists($${PWD}/LuminaOS-$${OS}.cpp){ +# SOURCES += LuminaOS-$${OS}.cpp +#}else{ +# SOURCES += LuminaOS-template.cpp +#} + +#LIBS += -lc -lxcb -lxcb-ewmh -lxcb-icccm -lxcb-image -lxcb-composite -lxcb-damage -lxcb-util -lXdamage + +#include.path=$${L_INCLUDEDIR} +#include.files=LuminaXDG.h \ +# LuminaUtils.h \ +# LuminaX11.h \ +# LuminaThemes.h \ +# LuminaOS.h \ +# LuminaSingleApplication.h colors.path=$${L_SHAREDIR}/lumina-desktop/colors colors.files=colors/*.qss.colors @@ -65,4 +65,4 @@ themes.files=themes/*.qss.template globs.path=$${L_SHAREDIR}/lumina-desktop globs.files=xtrafiles/globs2 -INSTALLS += target include colors themes globs +INSTALLS += colors themes globs diff --git a/src-qt5/core/libLumina/quickplugins/quick-sample.qml b/src-qt5/core/libLumina/quickplugins/quick-sample.qml deleted file mode 100644 index 18b10d77..00000000 --- a/src-qt5/core/libLumina/quickplugins/quick-sample.qml +++ /dev/null @@ -1,12 +0,0 @@ -// Plugin-Name=Sample -// Plugin-Description=A simple example for QtQuick/QML plugins -// Plugin-Icon=preferences-plugin -// Created: Ken Moore (ken@pcbsd.org) May 2015 - -import QtQuick.Controls 1.3 - -Label { - text: "Sample" - color: "blue" - font.bold: true -} \ No newline at end of file diff --git a/src-qt5/core/libLumina/themes/Glass.qss.template b/src-qt5/core/libLumina/themes/Glass.qss.template deleted file mode 100644 index d594d25e..00000000 --- a/src-qt5/core/libLumina/themes/Glass.qss.template +++ /dev/null @@ -1,539 +0,0 @@ -/* ALL THE TEMPLATE WIDGETS */ -INHERITS=None - -/* ALL THE WIDGETS WITH THE BASE COLOR */ -QMainWindow, QMenu, QDialog, QMessageBox{ - background: qradialgradient(spread:reflect, cx:0.113757, cy:0.875, radius:0.7, fx:0.045, fy:0.954545, stop:0 %%BASECOLOR%%, stop:1 %%ALTBASECOLOR%%); - color: %%TEXTCOLOR%%; - border: 1px solid %%ACCENTDISABLECOLOR%%; - border-radius: 3px; -} - -/* ALL THE WIDGETS WITH AN ALTERNATE BASE COLOR */ -QLineEdit, QTextEdit, QTextBrowser, QPlainTextEdit, QSpinBox, QDateEdit, QDateTimeEdit, QTimeEdit, QDoubleSpinBox{ - background: %%ALTBASECOLOR%%; - color: %%TEXTCOLOR%%; - border-color: %%ACCENTDISABLECOLOR%%; - selection-background-color: %%HIGHLIGHTCOLOR%%; - selection-color: %%TEXTHIGHLIGHTCOLOR%%; -} - -/* PAGES OF CONTAINER WIDGETS */ -QStackedWidget .QWidget{ - background: transparent; - color: %%TEXTCOLOR%%; - border: none; -} - -QToolBox::tab{ - color: %%TEXTCOLOR%%; -} - -/* MENU WIDGETS */ -QMenuBar, QMenuBar::item,QToolBar{ - background: transparent; - border: none; - color: %%TEXTCOLOR%%; -} - -QStatusBar{ - background: QLinearGradient(x1: 0, y1: 0, x2: 0, y2: 1, stop: 0 transparent, stop: 0.5 %%SECONDARYCOLOR%%); - border: none; - color: %%TEXTCOLOR%%; -} -QToolBar:top{ - border-bottom: 1px solid %%ACCENTCOLOR%%; -} -QToolBar:bottom{ - border-top: 1px solid %%ACCENTCOLOR%%; -} -QToolBar:left{ - border-right: 1px solid %%ACCENTCOLOR%%; -} -QToolBar:right{ - border-left: 1px solid %%ACCENTCOLOR%%; -} - -QMenuBar::item{ - background: transparent; /*Use the menu bar color*/ - padding-left: 4px; - padding-right: 2px; -} - -QMenuBar::item:selected, QMenuBar::item:pressed, QMenu::item:selected{ -background: QLinearGradient(x1: 0, y1: 0, x2: 1, y2: 1, stop: 0 %%HIGHLIGHTDISABLECOLOR%%, stop: 1 %%HIGHLIGHTCOLOR%%); -color: %%TEXTHIGHLIGHTCOLOR%%; -border: 1px solid %%ACCENTCOLOR%%; -} -QMenuBar::item:disabled{ - color: %%TEXTDISABLECOLOR%%; -} - -/*QMenu::item{ - border: 2px solid #808080; -}*/ - -QMenu::item{ - background: transparent; - border: 1px solid transparent; - color: %%TEXTCOLOR%%; - padding: 4px 30px 4px 20px; - margin-left: 3px; - margin-right: 3px; -} - -/* TAB WIDGETS */ -/*QTabBar{ - Custom Font settings need to be here and NOT in the ::tab fields, - otherwise it will break auto-scaling of the tab sizes to fit the text -}*/ -/* Transparency does not work on main pages within tabwidgets*/ -QTabWidget QStackedWidget .QWidget{ - background: rgb(230,230,230); - border-bottom-left-radius: 4px; - border-bottom-right-radius: 4px; -} -QTabWidget{ - color: black; - border: none; -} -QTabWidget QLabel{ - color: black; -} -QTabBar::tab { - background: QLinearGradient(x1: 0, y1: 0, x2: 1, y2: 1, stop: 0 %%SECONDARYDISABLECOLOR%%, stop: 1 %%ALTBASECOLOR%%); - border: 1px solid %%ACCENTCOLOR%%; - padding: 2px; - color: %%TEXTCOLOR%%; -} -QTabBar::tab:top{ - border-top-left-radius: 4px; - border-top-right-radius: 4px; - max-width: 100em; - min-width: 0em; -} -QTabBar::tab:bottom{ - border-bottom-left-radius: 4px; - border-bottom-right-radius: 4px; - max-width: 100em; - min-width: 0em; -} -/* left/right tab indicators appear to be reversed in Qt*/ -QTabBar::tab:right{ - border-top-left-radius: 4px; - border-bottom-left-radius: 4px; - max-height: 100em; - min-height: 0em; -} -QTabBar::tab:left{ - border-top-right-radius: 4px; - border-bottom-right-radius: 4px; - max-height: 100em; - min-height: 0em; -} -QTabBar::tab:selected{ - background: QLinearGradient(x1: 0, y1: 0, x2: 0, y2: 1, stop: 0 %%HIGHLIGHTDISABLECOLOR%%, stop: 1 rgb(230,230,230)); - border-bottom: none; -} -QTabBar::tab:hover { - background: %%HIGHLIGHTCOLOR%%; - border: 1px solid %%ACCENTDISABLECOLOR%%; - } - -QTabBar::tab:!selected:top { - margin-top: 4px; -} -QTabBar::tab:!selected:bottom{ - margin-bottom: 4px; -} -QTabBar::tab:!selected:right{ - margin-left: 4px; -} -QTabBar::tab:!selected:left{ - margin-right: 4px; -} - -/* FRAME WIDGETS */ -QToolTip{ - background: QLinearGradient(x1: 0, y1: 0, x2: 1, y2: 1, stop: 0 %%BASECOLOR%%, stop: 1 %%ALTBASECOLOR%%); - border-radius: 3px; - border: 1px solid %%ACCENTCOLOR%%; - padding: 1px; - color: %%TEXTCOLOR%%; -} - -QLabel{ - background: transparent; - border: none; - color: %%TEXTCOLOR%%; -} -QAbstractButton::disabled{ - color: %%TEXTDISABLECOLOR%%; -} - -/* GROUP BOX */ -QGroupBox{ - background-color: transparent; - border-color: %%ACCENTCOLOR%%; - border-radius: 5px; - margin-top: 2ex; - font-weight: bold; -} -QGroupBox::title{ - subcontrol-origin: margin; - subcontrol-position: top center; - padding: 0 3px; - background: transparent; - /*border: none;*/ - color: %%TEXTCOLOR%%; -} - -/* COMBO BOX */ -QComboBox{ - /*border: 1px solid %%ACCENTCOLOR%%; - border-radius: 3px; - padding: 1px 18px 1px 3px;*/ - color: %%TEXTCOLOR%%; - background: %%ALTBASECOLOR%%; - selection-background-color: %%HIGHLIGHTCOLOR%%; - } - - -/* VIEW WIDGETS */ -QTreeView, QListView{ - background: %%ALTBASECOLOR%%; - alternate-background-color: %%BASECOLOR%%; - /*selection-background-color: %%SECONDARYCOLOR%%;*/ - border: 1px solid %%ACCENTCOLOR%%; - border-radius: 3px; - /*show-decoration-selected: 1;*/ - color: %%TEXTCOLOR%%; - selection-color: %%TEXTCOLOR%%; -} - -QTreeView:focus, QListView:focus{ - border: 1px solid %%HIGHLIGHTDISABLECOLOR%%; -} - -/* -QTreeView::item and QListView::item unneccessary: -Already set though parentage and causes usage errors if set manually -*/ - -/*QTreeView::item:selected, QListView::item:selected{ - background: %%SECONDARYDISABLECOLOR%%; - border-color: %%ACCENTCOLOR%%; - color: %%TEXTCOLOR%%; -}*/ - -QTreeView::item:hover, QListView::item:hover{ - background: %%HIGHLIGHTDISABLECOLOR%%; -} -QTreeView::item:selected:hover, QListView::item:selected:hover{ - background: %%HIGHLIGHTDISABLECOLOR%%; -} -QTreeView::item:selected, QListView::item:selected{ - background: %%SECONDARYDISABLECOLOR%%; -} -QTreeView::item:selected:focus, QListView::item:selected:focus{ - background: %%SECONDARYCOLOR%%; -} -QHeaderView{ - background: %%HIGHLIGHTDISABLECOLOR%%; - color: %%TEXTHIGHLIGHTCOLOR%%; - border: none; - border-top-left-radius: 3px; /*match the list/tree view widgets*/ - border-top-right-radius: 3px; /*match the list/tree view widgets*/ -} -QHeaderView::section{ - background: %%HIGHLIGHTDISABLECOLOR%%; /*QLinearGradient(x1: 0, y1: 0, x2: 1, y2: 1, stop: 0 %%PRIMARYDISABLECOLOR%%, stop: 1 %%PRIMARYCOLOR%%);*/ - color: %%TEXTHIGHLIGHTCOLOR%%; - border-color: %%ACCENTCOLOR%%; - padding: 1px; - padding-left: 4px; -} -QHeaderView::section:hover{ - background: %%PRIMARYCOLOR%%; - border-color: %%ACCENTDISABLECOLOR%%; - color: %%TEXTCOLOR%%; -} - -/* SCROLLBARS (NOTE: Changing 1 subcontrol means you have to change all of them)*/ -QScrollBar{ - background:%%ALTBASECOLOR%%; -} -QScrollBar:horizontal{ - margin: 0px 0px 0px 0px; -} -QScrollBar:vertical{ - margin: 0px 0px 0px 0px; -} -QScrollBar::handle{ - background: %%SECONDARYCOLOR%%; - border: 1px solid transparent; - border-radius: 7px; -} -QScrollBar::handle:hover, QScrollBar::add-line:hover, QScrollBar::sub-line:hover{ - background: %%SECONDARYDISABLECOLOR%%; -} -QScrollBar::add-line{ -subcontrol-origin: none; -} -QScrollBar::add-line:vertical, QScrollBar::sub-line:vertical{ -height: 0px; -} -QScrollBar::add-line:horizontal, QScrollBar::sub-line:horizontal{ -width: 0px; -} -QScrollBar::sub-line{ -subcontrol-origin: none; -} - -/* SLIDERS */ -QSlider::groove:horizontal { -border: 1px solid %%ACCENTCOLOR%%; -background: %%ALTBASECOLOR%%; -height: 10px; -border-radius: 3px; -} -QSlider::groove:vertical { -border: 1px solid %%ACCENTCOLOR%%; -background: %%ALTBASECOLOR%%; -width: 10px; -border-radius: 3px; -} -QSlider::sub-page:horizontal { -background: qlineargradient(x1: 0, y1: 0, x2: 1, y2: 1, - stop: 0 %%HIGHLIGHTCOLOR%%, stop: 1 %%HIGHLIGHTDISABLECOLOR%%); -border: 1px solid %%ACCENTCOLOR%%; -height: 10px; -border-radius: 3px; -} -QSlider::sub-page:vertical { -background: qlineargradient(x1: 0, y1: 0, x2: 1, y2: 1, - stop: 0 %%HIGHLIGHTCOLOR%%, stop: 1 %%HIGHLIGHTDISABLECOLOR%%); -border: 1px solid %%ACCENTCOLOR%%; -width: 10px; -border-radius: 3px; -} -QSlider::add-page:horizontal{ -background: %%ALTBASECOLOR%%; -border: 1px solid %%ACCENTCOLOR%%; -height: 10px; -border-radius: 3px; -} -QSlider::add-page:vertical{ -background: %%ALTBASECOLOR%%; -border: 1px solid %%ACCENTCOLOR%%; -width: 10px; -border-radius: 3px; -} -QSlider::handle:horizontal{ -background: %%ALTBASECOLOR%%; -border: 1px solid %%ACCENTCOLOR%%; -width: 13px; -border-radius: 4px; -} -QSlider::handle:vertical{ -background: %%ALTBASECOLOR%%; -border: 1px solid %%ACCENTCOLOR%%; -height: 13px; -border-radius: 4px; -} -QSlider::handle:horizontal:hover, QSlider::handle:vertical:hover{ -border: 1px solid %%ACCENTDISABLECOLOR%%; -/*background: %%HIGHLIGHTCOLOR%%;*/ -} - -QSlider::sub-page:horizontal:disabled { -background: %%ACCENTDISABLECOLOR%%; -border-color: %%ACCENTCOLOR%%; -} - -QSlider::add-page:horizontal:disabled { -background: %%ACCENTDISABLECOLOR%%; -border-color: %%ACCENTCOLOR%%; -} - -QSlider::handle:horizontal:disabled { -background: %%ALTBASECOLOR%%; -border: 1px solid %%ACCENTCOLOR%%; -} - -/* BUTTONS */ -QPushButton{ - border: 1px solid %%ACCENTCOLOR%%; - border-radius: 3px; - background-color: QLinearGradient(x1: 0, y1: 0, x2: 1, y2: 1, stop: 0 %%SECONDARYDISABLECOLOR%%, stop: 1 %%SECONDARYCOLOR%%); - padding: 2px; - padding-right: 4px; - color: %%TEXTCOLOR%%; - } - -QToolButton{ /* Assume a flat button for every toolbutton by default*/ - color: %%TEXTCOLOR%%; - border: 1px solid transparent; - border-radius: 3px; - background-color: transparent; - padding: 1px; -} - - QPushButton:pressed, QPushButton:open, QPushButton:selected, QPushButton:checked, QPushButton:on, QToolButton:pressed, QToolButton:open, QToolButton:selected, QToolButton:checked, QToolButton:on{ - background-color: QLinearGradient(x1: 0, y1: 0, x2: 1, y2: 1, stop: 0 %%HIGHLIGHTDISABLECOLOR%%, stop: 1 %%HIGHLIGHTCOLOR%%); - margin-top: 2px; - } - -QPushButton:flat, QToolButton:flat{ - background-color: transparent; - border: 1px solid transparent; /* no border for a flat button */ -} - -QPushButton:hover, QToolButton:hover{ - border: 1px solid %%ACCENTCOLOR%%; - background-color: QLinearGradient(x1: 0, y1: 0, x2: 1, y2: 1, stop: 0 %%HIGHLIGHTDISABLECOLOR%%, stop: 1 %%HIGHLIGHTCOLOR%%); - color: %%TEXTHIGHLIGHTCOLOR%%; -} -QRadioButton, QCheckBox{ - padding: 2px; - border: 1px solid transparent; - border-radius: 3px; - color: %%TEXTCOLOR%%; -} -QRadioButton::hover, QCheckBox:hover{ - background: QLinearGradient(x1: 0, y1: 0, x2: 1, y2: 1, stop: 0 %%HIGHLIGHTDISABLECOLOR%%, stop: 1 %%HIGHLIGHTCOLOR%%); - border: 1px solid %%ACCENTCOLOR%%; - color: %%TEXTHIGHLIGHTCOLOR%%; -} -QRadioButton::indicator, QCheckBox::indicator, QGroupBox::indicator{ - border: 1px solid %%TEXTCOLOR%%; -} -QRadioButton::indicator{ - border-radius: 7px; -} -QRadioButton::indicator:checked{ - background: qradialgradient(spread:pad, cx:0.5, cy:0.5, radius:1, fx:0.5, fy:0.5, stop:0 %%TEXTCOLOR%%, stop:0.25 %%TEXTCOLOR%%, stop:0.25001 transparent); -} -QCheckBox::indicator:checked, QGroupBox::indicator:checked{ - padding: 1px; - background-origin: content; - background-clip: content; - background: %%TEXTCOLOR%%; -} -QCheckBox::indicator:indeterminate, QGroupBox::indicator:indeterminate{ - padding: 1px; - background-origin: content; - background-clip: content; - background: QLinearGradient(x1: 0, y1: 0, x2: 1, y2: 1, stop: 0.49 transparent, stop: 0.5 %%TEXTCOLOR%%); -} - -/* PROGRESSBAR */ -QProgressBar{ - background-color: %%ALTBASECOLOR%%; - border: 1px solid %%ACCENTCOLOR%%; - border-radius: 5px; - color: %%TEXTCOLOR%%; - text-align: center; - padding: 1px; -} - QProgressBar::chunk { - background-color: QLinearGradient(x1: 0, y1: 0, x2: 1, y2: 1, stop: 0 %%HIGHLIGHTCOLOR%%, stop: 1 %%HIGHLIGHTDISABLECOLOR%%); - /*border: 1px solid %%ACCENTDISABLECOLOR%%;*/ - border-radius: 5px; - } -QProgressBar::chunk:vertical{ - margin-left: 2px; - margin-right: 2px; -} -QProgressBar::chunk:horizontal{ - margin-top: 2px; - margin-bottom: 2px; -} - -QWidget#LuminaBootSplash{ - background: qradialgradient(spread:reflect, cx:0.113757, cy:0.875, radius:0.7, fx:0.045, fy:0.954545, stop:0 rgba(234, 236, 243, 30), stop:1 rgba(229, 229, 229, 70)); - border-radius: 5px; -} - -LDPlugin#applauncher{ - background-color: transparent; - border: none; -} -LDPlugin#applauncher QToolButton, LDPlugin, LDPlugin#desktopview QListWidget::item{ - background-color: qradialgradient(spread:reflect, cx:0.113757, cy:0.875, radius:0.7, fx:0.045, fy:0.954545, stop:0 rgba(234, 236, 243, 30), stop:1 rgba(229, 229, 229, 70)); - border-width: 3px; - border-style: solid; - border-radius: 5px; - border-top-color: qradialgradient(spread:pad, cx:0.5, cy:1, radius:0.5, fx:0.5, fy:1, stop:0 rgba(255, 255, 255, 30), stop:0.724868 rgba(255, 255, 255, 60), stop:1 rgba(255, 255, 255, 10)); - border-bottom-color: qradialgradient(spread:pad, cx:0.5, cy:0, radius:0.5, fx:0.5, fy:0, stop:0 rgba(255, 255, 255, 30), stop:0.724868 rgba(255, 255, 255, 60), stop:1 rgba(255, 255, 255, 10)); - border-left-color: qradialgradient(spread:pad, cx:1, cy:0.5, radius:0.5, fx:1, fy:0.5, stop:0 rgba(255, 255, 255, 30), stop:0.724868 rgba(255, 255, 255, 60), stop:1 rgba(255, 255, 255, 10)); - border-right-color: qradialgradient(spread:pad, cx:0, cy:0.5, radius:0.5, fx:1, fy:0.5, stop:0 rgba(255, 255, 255, 30), stop:0.724868 rgba(255, 255, 255, 60), stop:1 rgba(255, 255, 255, 10)); - color: white; -} - -LDPlugin#applauncher QToolButton:hover, LDPlugin#desktopview QListWidget::item:hover{ - background-color: qradialgradient(spread:reflect, cx:0.113757, cy:0.875, radius:0.7, fx:0.045, fy:0.954545, stop:0 rgba(234, 236, 243, 100), stop:1 rgba(229, 229, 229, 150)); - border-width: 3px; - border-style: solid; - border-radius: 5px; - border-top-color: qradialgradient(spread:pad, cx:0.5, cy:1, radius:0.5, fx:0.5, fy:1, stop:0 rgba(255, 255, 255, 30), stop:0.724868 rgba(255, 255, 255, 60), stop:1 rgba(255, 255, 255, 10)); - border-bottom-color: qradialgradient(spread:pad, cx:0.5, cy:0, radius:0.5, fx:0.5, fy:0, stop:0 rgba(255, 255, 255, 30), stop:0.724868 rgba(255, 255, 255, 60), stop:1 rgba(255, 255, 255, 10)); - border-left-color: qradialgradient(spread:pad, cx:1, cy:0.5, radius:0.5, fx:1, fy:0.5, stop:0 rgba(255, 255, 255, 30), stop:0.724868 rgba(255, 255, 255, 60), stop:1 rgba(255, 255, 255, 10)); - border-right-color: qradialgradient(spread:pad, cx:0, cy:0.5, radius:0.5, fx:1, fy:0.5, stop:0 rgba(255, 255, 255, 30), stop:0.724868 rgba(255, 255, 255, 60), stop:1 rgba(255, 255, 255, 10)); - color: %%TEXTHIGHLIGHTCOLOR%%; -} -QWidget#LuminaPanelColor{ - background: qradialgradient(spread:reflect, cx:0.113757, cy:0.875, radius:0.7, fx:0.045, fy:0.954545, stop:0 rgba(234, 236, 243, 60), stop:1 rgba(229, 229, 229, 110)); - border-radius: 3px; -} -/*Special taskmanager window buttons: based on window state*/ -LTBWidget{ - border: 1px solid transparent; - border-radius: 3px; -} -LTBWidget::menu-indicator{ image: none; } /*disable the menu arrow*/ -LTBWidget#WindowVisible{ - background: QLinearGradient(x1: 0, y1: 0, x2: 1, y2: 1.1, stop: 0.1 %%PRIMARYCOLOR%%, stop: 1 transparent); -} -LTBWidget#WindowInvisible{ - background: transparent; -} -LTBWidget#WindowActive{ - background: QLinearGradient(x1: 0, y1: 0, x2: 1, y2: 1.1, stop: 0.1 %%HIGHLIGHTDISABLECOLOR%%, stop: 1 transparent); -} -LTBWidget#WindowAttention{ - background: QLinearGradient(x1: 0, y1: 0, x2: 1, y2: 1.1, stop: 0.1 %%HIGHLIGHTCOLOR%%, stop: 1 transparent); -} -LTBWidget:hover, LTBWidget#WindowVisible:hover, LTBWidget#WindowInvisible:hover, LTBWidget#WindowActive:hover, LTBWidget#WindowAttention:hover, QToolButton:hover{ - background: QLinearGradient(x1: 0, y1: 0, x2: 1, y2: 1.1, stop: 0.1 %%HIGHLIGHTCOLOR%%, stop: 1 transparent); - color: %%TEXTHIGHLIGHTCOLOR%%; - border-width: 1px; - border-style: solid; - border-top-color: qradialgradient(spread:pad, cx:0.5, cy:1, radius:0.5, fx:0.5, fy:1, stop:0 rgba(255, 255, 255, 30), stop:0.724868 rgba(255, 255, 255, 60), stop:1 rgba(255, 255, 255, 10)); - border-bottom-color: qradialgradient(spread:pad, cx:0.5, cy:0, radius:0.5, fx:0.5, fy:0, stop:0 rgba(255, 255, 255, 30), stop:0.724868 rgba(255, 255, 255, 60), stop:1 rgba(255, 255, 255, 10)); - border-left-color: qradialgradient(spread:pad, cx:1, cy:0.5, radius:0.5, fx:1, fy:0.5, stop:0 rgba(255, 255, 255, 30), stop:0.724868 rgba(255, 255, 255, 60), stop:1 rgba(255, 255, 255, 10)); - border-right-color: qradialgradient(spread:pad, cx:0, cy:0.5, radius:0.5, fx:1, fy:0.5, stop:0 rgba(255, 255, 255, 30), stop:0.724868 rgba(255, 255, 255, 60), stop:1 rgba(255, 255, 255, 10)); -} -/* CALENDER WIDGET */ - /* (This is a special hack since there is no official support for stylesheets for this widget) */ - QCalendarWidget QWidget#qt_calendar_navigationbar{ - background-color: %%ALTBASECOLOR%%; - } -QCalendarWidget QWidget{ - background-color: %%BASECOLOR%%; - alternate-background-color: rgba(255, 255, 255, 50); - color: %%TEXTCOLOR%%; -} -QCalendarWidget QAbstractButton{ - background-color: transparent; -} -QCalendarWidget QAbstractButton::menu-indicator{ - image: none; -} -QCalendarWidget QAbstractItemView{ - selection-background-color: qradialgradient(spread:reflect, cx:0.113757, cy:0.875, radius:0.7, fx:0.045, fy:0.954545, stop:0 rgba(234, 236, 243, 20), stop:1 rgba(229, 229, 229, 100)); - selection-color: %%TEXTHIGHLIGHTCOLOR%%; -} -QCalendarWidget QWidget#qt_calendar_calendarview{ - background-color: rgb(220,220,220); - border: none; -} diff --git a/src-qt5/core/libLumina/themes/Lumina-default.qss.template b/src-qt5/core/libLumina/themes/Lumina-default.qss.template deleted file mode 100644 index 9f03d4ae..00000000 --- a/src-qt5/core/libLumina/themes/Lumina-default.qss.template +++ /dev/null @@ -1,494 +0,0 @@ -/* ALL THE TEMPLATE WIDGETS */ -INHERITS=None - -/* ALL THE WIDGETS WITH THE BASE COLOR */ -QMainWindow, QMenu, QDialog, QMessageBox{ - background: %%BASECOLOR%%; - color: %%TEXTCOLOR%%; -} - -/* ALL THE WIDGETS WITH AN ALTERNATE BASE COLOR */ -QLineEdit, QTextEdit, QTextBrowser, QPlainTextEdit, QSpinBox, QDateEdit, QDateTimeEdit, QTimeEdit, QDoubleSpinBox{ - background: %%ALTBASECOLOR%%; - color: %%TEXTCOLOR%%; - border-color: %%ACCENTDISABLECOLOR%%; - selection-background-color: %%HIGHLIGHTCOLOR%%; - selection-color: %%TEXTHIGHLIGHTCOLOR%%; - -} - -/* PAGES OF CONTAINER WIDGETS */ -QStackedWidget .QWidget, QTabWidget .QWidget{ - background: %%ALTBASECOLOR%%; - color: %%TEXTCOLOR%%; - border: none; -} -QToolBox::tab{ - color: %%TEXTCOLOR%%; -} - -/* MENU WIDGETS */ -QMenuBar, QMenuBar::item,QToolBar{ - background: %%SECONDARYCOLOR%%; - border: none; - color: %%TEXTCOLOR%%; -} - -QStatusBar{ - background: QLinearGradient(x1: 0, y1: 0, x2: 0, y2: 1, stop: 0 transparent, stop: 0.5 %%SECONDARYCOLOR%%); - border: none; - color: %%TEXTCOLOR%%; -} -QToolBar:top{ - border-bottom: 1px solid %%ACCENTCOLOR%%; -} -QToolBar:bottom{ - border-top: 1px solid %%ACCENTCOLOR%%; -} -QToolBar:left{ - border-right: 1px solid %%ACCENTCOLOR%%; -} -QToolBar:right{ - border-left: 1px solid %%ACCENTCOLOR%%; -} - -QMenuBar::item{ - background: transparent; /*Use the menu bar color*/ - padding-left: 4px; - padding-right: 2px; -} - -QMenuBar::item:selected, QMenuBar::item:pressed, QMenu::item:selected{ -background: QLinearGradient(x1: 0, y1: 0, x2: 1, y2: 1, stop: 0 %%HIGHLIGHTDISABLECOLOR%%, stop: 1 %%HIGHLIGHTCOLOR%%); -color: %%TEXTHIGHLIGHTCOLOR%%; -border: 1px solid %%ACCENTCOLOR%%; -} -QMenuBar::item:disabled{ - color: %%TEXTDISABLECOLOR%%; -} - -QMenu::item{ - border: 2px solid #808080; -} - -QMenu::item{ - background: transparent; - border: 1px solid transparent; - color: %%TEXTCOLOR%%; - padding: 4px 30px 4px 20px; - margin-left: 3px; - margin-right: 3px; -} - -/* TAB WIDGETS */ -/*QTabBar{ - Custom Font settings need to be here and NOT in the ::tab fields, - otherwise it will break auto-scaling of the tab sizes to fit the text -}*/ -QTabBar::tab { - background: QLinearGradient(x1: 0, y1: 0, x2: 1, y2: 1, stop: 0 %%SECONDARYDISABLECOLOR%%, stop: 1 %%SECONDARYCOLOR%%); - border: 1px solid %%ACCENTCOLOR%%; - padding: 2px; - color: %%TEXTCOLOR%%; -} -QTabBar::tab:top{ - border-top-left-radius: 4px; - border-top-right-radius: 4px; - max-width: 100em; - min-width: 0em; -} -QTabBar::tab:bottom{ - border-bottom-left-radius: 4px; - border-bottom-right-radius: 4px; - max-width: 100em; - min-width: 0em; -} -/* left/right tab indicators appear to be reversed in Qt*/ -QTabBar::tab:right{ - border-top-left-radius: 4px; - border-bottom-left-radius: 4px; - max-height: 100em; - min-height: 0em; -} -QTabBar::tab:left{ - border-top-right-radius: 4px; - border-bottom-right-radius: 4px; - max-height: 100em; - min-height: 0em; -} -QTabBar::tab:selected{ - background: %%HIGHLIGHTDISABLECOLOR%%; -} -QTabBar::tab:hover { - background: %%HIGHLIGHTCOLOR%%; - border: 1px solid %%ACCENTDISABLECOLOR%%; - } - -QTabBar::tab:!selected:top { - margin-top: 4px; -} -QTabBar::tab:!selected:bottom{ - margin-bottom: 4px; -} -QTabBar::tab:!selected:right{ - margin-left: 4px; -} -QTabBar::tab:!selected:left{ - margin-right: 4px; -} - -/* FRAME WIDGETS */ -QToolTip{ - background: QLinearGradient(x1: 0, y1: 0, x2: 1, y2: 1, stop: 0 %%BASECOLOR%%, stop: 1 %%ALTBASECOLOR%%); - border-radius: 3px; - border: 1px solid %%ACCENTCOLOR%%; - padding: 1px; - color: %%TEXTCOLOR%%; -} - -QLabel{ - background: transparent; - border: none; - color: %%TEXTCOLOR%%; -} -QAbstractButton::disabled{ - color: %%TEXTDISABLECOLOR%%; -} - -/* GROUP BOX */ -QGroupBox{ - background-color: transparent; - border-color: %%ACCENTCOLOR%%; - border-radius: 5px; - margin-top: 2ex; - font-weight: bold; -} -QGroupBox::title{ - subcontrol-origin: margin; - subcontrol-position: top center; - padding: 0 3px; - background: transparent; - /*border: none;*/ - color: %%TEXTCOLOR%%; -} - -/* COMBO BOX */ -QComboBox{ - /*border: 1px solid %%ACCENTCOLOR%%; - border-radius: 3px; - padding: 1px 18px 1px 3px;*/ - color: %%TEXTCOLOR%%; - background: %%ALTBASECOLOR%%; - selection-background-color: %%HIGHLIGHTCOLOR%%; - } - - -/* VIEW WIDGETS */ -QTreeView, QListView{ - background: %%ALTBASECOLOR%%; - alternate-background-color: %%BASECOLOR%%; - /*selection-background-color: %%SECONDARYCOLOR%%;*/ - border: 1px solid %%ACCENTCOLOR%%; - border-radius: 3px; - /*show-decoration-selected: 1;*/ - color: %%TEXTCOLOR%%; - selection-color: %%TEXTCOLOR%%; -} - -QTreeView:focus, QListView:focus{ - border: 1px solid %%HIGHLIGHTDISABLECOLOR%%; -} - -/* -QTreeView::item and QListView::item unneccessary: -Already set though parentage and causes usage errors if set manually -*/ - -/*QTreeView::item:selected, QListView::item:selected{ - background: %%SECONDARYDISABLECOLOR%%; - border-color: %%ACCENTCOLOR%%; - color: %%TEXTCOLOR%%; -}*/ - -QTreeView::item:hover, QListView::item:hover{ - background: %%HIGHLIGHTDISABLECOLOR%%; -} -QTreeView::item:selected:hover, QListView::item:selected:hover{ - background: %%HIGHLIGHTDISABLECOLOR%%; -} -QTreeView::item:selected, QListView::item:selected{ - background: %%SECONDARYDISABLECOLOR%%; -} -QTreeView::item:selected:focus, QListView::item:selected:focus{ - background: %%SECONDARYCOLOR%%; -} -QHeaderView{ - background: %%HIGHLIGHTDISABLECOLOR%%; - color: %%TEXTHIGHLIGHTCOLOR%%; - border: none; - border-top-left-radius: 3px; /*match the list/tree view widgets*/ - border-top-right-radius: 3px; /*match the list/tree view widgets*/ -} -QHeaderView::section{ - background: %%HIGHLIGHTDISABLECOLOR%%; /*QLinearGradient(x1: 0, y1: 0, x2: 1, y2: 1, stop: 0 %%PRIMARYDISABLECOLOR%%, stop: 1 %%PRIMARYCOLOR%%);*/ - color: %%TEXTHIGHLIGHTCOLOR%%; - border-color: %%ACCENTCOLOR%%; - padding: 1px; - padding-left: 4px; -} -QHeaderView::section:hover{ - background: %%PRIMARYCOLOR%%; - border-color: %%ACCENTDISABLECOLOR%%; - color: %%TEXTCOLOR%%; -} - -/* SCROLLBARS (NOTE: Changing 1 subcontrol means you have to change all of them)*/ -QScrollBar{ - background: QLinearGradient(x1: 0, y1: 0, x2: 0, y2: 1, stop: 0 %%SECONDARYCOLOR%%, stop: 1 %%SECONDARYDISABLECOLOR%%); - /*border: 1px solid %%ACCENTCOLOR%%;*/ -} -QScrollBar:horizontal{ - margin: 0px 20px 0px 20px; -} -QScrollBar:vertical{ - margin: 20px 0px 20px 0px; -} -QScrollBar::sub-page, QScrollBar::add-page{ - background: %%BASECOLOR%%; - border: 1px solid %%ACCENTCOLOR%%; -} -QScrollBar::sub-page:vertical{ - border-bottom: none; -} -QScrollBar::add-page:vertical{ - border-top: none; -} -QScrollBar::sub-page:horizontal{ - border-right: none; -} -QScrollBar::add-page:horizontal{ - border-left: none; -} -QScrollBar::handle{ - background: QLinearGradient(x1: 0, y1: -0.3, x2: 0, y2: 1.3, stop: 0 %%BASECOLOR%%, stop: 0.5 %%SECONDARYCOLOR%%, stop: 1 %%BASECOLOR%%); - border: 1px solid %%ACCENTCOLOR%%; -} -QScrollBar::handle:hover, QScrollBar::add-line:hover, QScrollBar::sub-line:hover{ - background: %%HIGHLIGHTCOLOR%%; -} -QScrollBar::add-line{ - background: QLinearGradient(x1: 0, y1: 0, x2: 0, y2: 1, stop: 0 %%SECONDARYDISABLECOLOR%%, stop: 1 %%SECONDARYCOLOR%%); - border: 1px solid %%ACCENTCOLOR%%; - border-radius: 3px; -subcontrol-position: bottom right; -subcontrol-origin: margin; -} -QScrollBar::add-line:vertical, QScrollBar::sub-line:vertical{ -height: 20px; -} -QScrollBar::add-line:horizontal, QScrollBar::sub-line:horizontal{ -width: 20px; -} -QScrollBar::sub-line{ - background: QLinearGradient(x1: 0, y1: 0, x2: 0, y2: 1, stop: 0 %%SECONDARYCOLOR%%, stop: 1 %%SECONDARYDISABLECOLOR%%); - border: 1px solid %%ACCENTCOLOR%%; - border-radius: 3px; -subcontrol-position: top left; -subcontrol-origin: margin; -height: 20px; -} -/* SLIDERS */ -QSlider::groove:horizontal { -border: 1px solid %%ACCENTCOLOR%%; -background: %%ALTBASECOLOR%%; -height: 10px; -border-radius: 3px; -} -QSlider::groove:vertical { -border: 1px solid %%ACCENTCOLOR%%; -background: %%ALTBASECOLOR%%; -width: 10px; -border-radius: 3px; -} -QSlider::sub-page:horizontal { -background: qlineargradient(x1: 0, y1: 0, x2: 1, y2: 1, - stop: 0 %%HIGHLIGHTCOLOR%%, stop: 1 %%HIGHLIGHTDISABLECOLOR%%); -border: 1px solid %%ACCENTCOLOR%%; -height: 10px; -border-radius: 3px; -} -QSlider::sub-page:vertical { -background: qlineargradient(x1: 0, y1: 0, x2: 1, y2: 1, - stop: 0 %%HIGHLIGHTCOLOR%%, stop: 1 %%HIGHLIGHTDISABLECOLOR%%); -border: 1px solid %%ACCENTCOLOR%%; -width: 10px; -border-radius: 3px; -} -QSlider::add-page:horizontal{ -background: %%ALTBASECOLOR%%; -border: 1px solid %%ACCENTCOLOR%%; -height: 10px; -border-radius: 3px; -} -QSlider::add-page:vertical{ -background: %%ALTBASECOLOR%%; -border: 1px solid %%ACCENTCOLOR%%; -width: 10px; -border-radius: 3px; -} -QSlider::handle:horizontal{ -background: %%ALTBASECOLOR%%; -border: 1px solid %%ACCENTCOLOR%%; -width: 13px; -border-radius: 4px; -} -QSlider::handle:vertical{ -background: %%ALTBASECOLOR%%; -border: 1px solid %%ACCENTCOLOR%%; -height: 13px; -border-radius: 4px; -} -QSlider::handle:horizontal:hover, QSlider::handle:vertical:hover{ -border: 1px solid %%ACCENTDISABLECOLOR%%; -/*background: %%HIGHLIGHTCOLOR%%;*/ -} - -QSlider::sub-page:horizontal:disabled { -background: %%ACCENTDISABLECOLOR%%; -border-color: %%ACCENTCOLOR%%; -} - -QSlider::add-page:horizontal:disabled { -background: %%ACCENTDISABLECOLOR%%; -border-color: %%ACCENTCOLOR%%; -} - -QSlider::handle:horizontal:disabled { -background: %%ALTBASECOLOR%%; -border: 1px solid %%ACCENTCOLOR%%; -} - -/* BUTTONS */ -QPushButton{ - border: 1px solid %%ACCENTCOLOR%%; - border-radius: 3px; - background-color: QLinearGradient(x1: 0, y1: 0, x2: 1, y2: 1, stop: 0 %%SECONDARYDISABLECOLOR%%, stop: 1 %%SECONDARYCOLOR%%); - padding: 2px; - padding-right: 4px; - color: %%TEXTCOLOR%%; - } - -QToolButton{ /* Assume a flat button for every toolbutton by default*/ - color: %%TEXTCOLOR%%; - border: 1px solid transparent; - border-radius: 3px; - background-color: transparent; - padding: 1px; -} - - QPushButton:pressed, QPushButton:open, QPushButton:selected, QPushButton:checked, QPushButton:on, QToolButton:pressed, QToolButton:open, QToolButton:selected, QToolButton:checked, QToolButton:on{ - background-color: QLinearGradient(x1: 0, y1: 0, x2: 1, y2: 1, stop: 0 %%HIGHLIGHTDISABLECOLOR%%, stop: 1 %%HIGHLIGHTCOLOR%%); - margin-top: 2px; - } - -QPushButton:flat, QToolButton:flat{ - background-color: transparent; - border: 1px solid transparent; /* no border for a flat button */ -} - -QPushButton:hover, QToolButton:hover{ - border: 1px solid %%ACCENTCOLOR%%; - background-color: QLinearGradient(x1: 0, y1: 0, x2: 1, y2: 1, stop: 0 %%HIGHLIGHTDISABLECOLOR%%, stop: 1 %%HIGHLIGHTCOLOR%%); - color: %%TEXTHIGHLIGHTCOLOR%%; -} -QRadioButton, QCheckBox{ - padding: 2px; - border: 1px solid transparent; - border-radius: 3px; - color: %%TEXTCOLOR%%; -} -QRadioButton::hover, QCheckBox:hover{ - background: QLinearGradient(x1: 0, y1: 0, x2: 1, y2: 1, stop: 0 %%HIGHLIGHTDISABLECOLOR%%, stop: 1 %%HIGHLIGHTCOLOR%%); - border: 1px solid %%ACCENTCOLOR%%; - color: %%TEXTHIGHLIGHTCOLOR%%; -} -QRadioButton::indicator, QCheckBox::indicator, QGroupBox::indicator{ - border: 1px solid %%TEXTCOLOR%%; -} -QRadioButton::indicator{ - border-radius: 7px; -} -QRadioButton::indicator:checked{ - background: qradialgradient(spread:pad, cx:0.5, cy:0.5, radius:1, fx:0.5, fy:0.5, stop:0 %%TEXTCOLOR%%, stop:0.25 %%TEXTCOLOR%%, stop:0.25001 transparent); -} -QCheckBox::indicator:checked, QGroupBox::indicator:checked{ - padding: 1px; - background-origin: content; - background-clip: content; - background: %%TEXTCOLOR%%; -} -QCheckBox::indicator:indeterminate, QGroupBox::indicator:indeterminate{ - padding: 1px; - background-origin: content; - background-clip: content; - background: QLinearGradient(x1: 0, y1: 0, x2: 1, y2: 1, stop: 0.49 transparent, stop: 0.5 %%TEXTCOLOR%%); -} - -/* PROGRESSBAR */ -QProgressBar{ - background-color: %%ALTBASECOLOR%%; - border: 1px solid %%ACCENTCOLOR%%; - border-radius: 5px; - color: %%TEXTCOLOR%%; - text-align: center; - padding: 1px; -} - QProgressBar::chunk { - background-color: QLinearGradient(x1: 0, y1: 0, x2: 1, y2: 1, stop: 0 %%HIGHLIGHTCOLOR%%, stop: 1 %%HIGHLIGHTDISABLECOLOR%%); - /*border: 1px solid %%ACCENTDISABLECOLOR%%;*/ - border-radius: 5px; - } -QProgressBar::chunk:vertical{ - margin-left: 2px; - margin-right: 2px; -} -QProgressBar::chunk:horizontal{ - margin-top: 2px; - margin-bottom: 2px; -} - - /* SPINBOX */ -/*QAbstractSpinBox{ - background-color: %%ALTBASECOLOR%%; - border: 1px solid %%ACCENTCOLOR%%; - border-radius: 3px; -} -QAbstractSpinBox:disabled{ - color: %%ACCENTDISABLECOLOR%%; -}*/ -/*QAbstractSpinBox::down-button{ - subcontrol-origin: border; - subcontrol-position: left; - width: 16px; - border-width: 1px; -} -QAbstractSpinBox::up-button{ - subcontrol-origin: border; - subcontrol-position: right; - width: 16px; - border-width: 1px; -}*/ -/* -QAbstractSpinBox::down-arrow{ - border-image: url(":/trolltech/styles/commonstyle/images/left-16.png"); - width: 16px; - height: 16px; -} -QAbstractSpinBox::down-arrow:disabled, QAbstractSpinBox::up-arrow:disabled, QAbstractSpinBox::down-arrow:off, QAbstractSpinBox::up-arrow:off{ - border-image: url(:/none); -} -QAbstractSpinBox::up-arrow{ - border-image: url(":/trolltech/styles/commonstyle/images/right-16.png"); - width: 16px; - height: 16px; -}*/ diff --git a/src-qt5/core/libLumina/themes/None.qss.template b/src-qt5/core/libLumina/themes/None.qss.template deleted file mode 100644 index 7d923b1e..00000000 --- a/src-qt5/core/libLumina/themes/None.qss.template +++ /dev/null @@ -1,118 +0,0 @@ -/* This is a blank stylesheet to disable the Lumina Themes almost entirely*/ -QWidget{ - font-family: %%FONT%%; - font-size: %%FONTSIZE%%; -} -/* Set the panel appearance for this theme (unless manually customized) */ -QWidget#LuminaPanelColor{ - background: QLinearGradient(x1: 0, y1: 0, x2: 1, y2: 1, stop: 0 %%PRIMARYCOLOR%%, stop: 1 %%PRIMARYDISABLECOLOR%%); - border-radius: 5px; -} -QWidget#LuminaBootSplash{ - background: %%BASECOLOR%%; - border-radius: 5px; -} - -/* Set the default canvas appearance for Lumina desktop plugins*/ -/* Default to a non-transparent background for all desktop plugins*/ -LDPlugin{ - background: %%BASECOLOR%%; - border-radius: 5px; -} -/* Now specify which plugins should have a transparent background */ -LDPlugin#applauncher, LDPlugin#desktopview{ - background: transparent; - border-radius: 5px; -} - -LDPlugin#applauncher QToolButton{ -background: transparent; - border: none; - border-radius: 5px; - color: white; -} -LDPlugin#applauncher QToolButton:hover{ - background: %%PRIMARYDISABLECOLOR%%; - border: none; - border-radius: 5px; - color: %%TEXTHIGHLIGHTCOLOR%%; -} - -LDPlugin#desktopview QListWidget{ - background: transparent; - border: 1px solid transparent; -} -LDPlugin#desktopview QListWidget::item{ - background: qlineargradient(x1: 0, y1: 0, x2: 0, y2: 1, - stop: 0 transparent, - stop: 0.7 transparent, - stop: 1.0 %%PRIMARYDISABLECOLOR%%); - border-radius: 5px; - color: %%TEXTCOLOR%%; -} - -LDPlugin#desktopview QListWidget::item:hover{ - background: %%PRIMARYDISABLECOLOR%%; - border-radius: 5px; - color: %%TEXTHIGHLIGHTCOLOR%%; -} -/*For the special widgets on the user button*/ -UserItemWidget, ItemWidget{ - background: transparent; - border-radius: 3px; -} -UserItemWidget:hover, ItemWidget:hover{ - background: %%HIGHLIGHTCOLOR%%; - color: %%TEXTHIGHLIGHTCOLOR%%; -} - -/*Special taskmanager window buttons: based on window state*/ -LTBWidget{ - border: 1px solid transparent; - border-radius: 3px; -} -LTBWidget::menu-indicator{ image: none; } /*disable the menu arrow*/ -LTBWidget#WindowVisible{ - background: QLinearGradient(x1: 0, y1: 0, x2: 1, y2: 1.1, stop: 0.3 %%SECONDARYCOLOR%%, stop: 1 transparent); -} -LTBWidget#WindowInvisible{ - /* Primary color is used for the panel appearance, so use that to make it disappear*/ - background: transparent; -} -LTBWidget#WindowActive{ - background: QLinearGradient(x1: 0, y1: 0, x2: 1, y2: 1.1, stop: 0.3 %%HIGHLIGHTDISABLECOLOR%%, stop: 1 transparent); -} -LTBWidget#WindowAttention{ - background: QLinearGradient(x1: 0, y1: 0, x2: 1, y2: 1.1, stop: 0.3 %%HIGHLIGHTCOLOR%%, stop: 1 transparent); -} -LTBWidget:hover, LTBWidget#WindowVisible:hover, LTBWidget#WindowInvisible:hover, LTBWidget#WindowActive:hover, LTBWidget#WindowAttention:hover{ - background: %%HIGHLIGHTCOLOR%%; - color: %%TEXTHIGHLIGHTCOLOR%%; - border: 1px solid %%ACCENTCOLOR%%; -} - -/* CALENDER WIDGET */ - /* (This is a special hack since there is no official support for stylesheets for this widget) */ - QCalendarWidget QWidget#qt_calendar_navigationbar{ - background-color: %%ALTBASECOLOR%%; - } -QCalendarWidget QWidget{ - background-color: %%BASECOLOR%%; - alternate-background-color: %%HIGHLIGHTDISABLECOLOR%%; - color: %%TEXTCOLOR%%; -} -QCalendarWidget QAbstractButton{ - background-color: transparent; -} -QCalendarWidget QAbstractButton::menu-indicator{ - image: none; -} -QCalendarWidget QAbstractItemView{ - background-color: %%SECONDARYCOLOR%%; - selection-background-color: QLinearGradient(x1: 0, y1: 0, x2: 0, y2: 1, stop: 0 %%HIGHLIGHTDISABLECOLOR%%, stop: 1 %%HIGHLIGHTCOLOR%%);; - selection-color: %%TEXTHIGHLIGHTCOLOR%%; -} -QCalendarWidget QWidget#qt_calendar_calendarview{ - background-color: %%ALTBASECOLOR%%; - border: none; -} \ No newline at end of file diff --git a/src-qt5/core/libLumina/xtrafiles/globs2 b/src-qt5/core/libLumina/xtrafiles/globs2 deleted file mode 100644 index 0a783316..00000000 --- a/src-qt5/core/libLumina/xtrafiles/globs2 +++ /dev/null @@ -1,991 +0,0 @@ -# Fallback "globs2" file from the FreeDesktop mimetype database (9/23/16) -# This is only used if the official database cannot be found on the system -80:application/x-cd-image:*.iso -80:application/x-doom-wad:*.wad -50:text/x-vala:*.vala -50:application/x-nes-rom:*.nez -50:audio/ac3:*.ac3 -50:application/x-mswrite:*.wri -50:application/smil+xml:*.smil -50:text/x-verilog:*.v -50:application/x-qpress:*.qp -50:image/x-exr:*.exr -50:application/x-compress:*.z -50:image/x-jng:*.jng -50:application/oda:*.oda -50:application/vnd.oasis.opendocument.database:*.odb -50:application/vnd.sun.xml.base:*.odb -50:application/vnd.oasis.opendocument.chart:*.odc -50:text/vtt:*.vtt -50:application/x-xz-compressed-tar:*.txz -50:application/vnd.oasis.opendocument.formula:*.odf -50:application/vnd.oasis.opendocument.formula:*.odf -50:application/vnd.oasis.opendocument.graphics:*.odg -50:application/vnd.oasis.opendocument.graphics:*.odg -50:text/x-ldif:*.ldif -50:application/vnd.oasis.opendocument.image:*.odi -50:image/jp2:*.jp2 -50:application/x-oleo:*.oleo -50:application/oxps:*.xps -50:application/vnd.oasis.opendocument.text-master:*.odm -50:application/vnd.oasis.opendocument.text-master:*.odm -50:application/x-ruby:*.rb -50:audio/vnd.rn-realaudio:*.ra -50:application/x-mimearchive:*.mht -50:application/vnd.oasis.opendocument.presentation:*.odp -50:application/vnd.oasis.opendocument.presentation:*.odp -50:application/x-raw-disk-image-xz-compressed:*.raw-disk-image.xz -50:application/vnd.oasis.opendocument.spreadsheet:*.ods -50:application/vnd.oasis.opendocument.spreadsheet:*.ods -50:application/vnd.oasis.opendocument.text:*.odt -50:application/vnd.oasis.opendocument.text:*.odt -50:image/x-portable-bitmap:*.pbm -50:application/x-egon:*.egon -50:application/x-font-pcf:*.pcf.z -50:application/x-xliff:*.xliff -50:application/vnd.rn-realmedia:*.rm -50:application/x-abiword:*.abw -50:image/vnd.rn-realpix:*.rp -50:image/x-sigma-x3f:*.x3f -50:video/webm:*.webm -50:text/rust:*.rs -50:text/vnd.rn-realtext:*.rt -50:image/webp:*.webp -50:application/x-cpio:*.cpio -50:audio/midi:*.mid -50:application/x-mif:*.mif -50:video/vnd.rn-realvideo:*.rv -50:application/vnd.google-earth.kml+xml:*.kml -50:image/x-3ds:*.3ds -50:image/x-photo-cd:*.pcd -50:application/x-pc-engine-rom:*.pce -50:application/x-font-pcf:*.pcf -50:application/x-cisco-vpn-settings:*.pcf -50:model/vrml:*.wrl -50:text/x-fortran:*.f95 -50:text/plain:*.txt -50:image/x-xpixmap:*.xpm -50:application/vnd.hp-pcl:*.pcl -50:application/x-trash:*.bak -50:application/vnd.openxmlformats-officedocument.presentationml.template:*.potx -50:application/vnd.openxmlformats-officedocument.presentationml.template:*.potx -50:application/x-sms-rom:*.sg -50:application/x-shellscript:*.sh -50:model/vrml:*.vrml -50:text/vcard:*.vcard -50:image/x-skencil:*.sk -50:image/x-pict:*.pct -50:video/3gpp2:*.3g2 -50:text/x-vala:*.vapi -50:application/x-sharedlib:*.so -50:application/x-tzo:*.tzo -50:video/x-javafx:*.fxm -50:image/jpeg:*.jpe -50:audio/x-aifc:*.aifc -50:application/x-lzma-compressed-tar:*.tar.lzma -50:x-epoc/x-sisx-app:*.sisx -50:audio/x-aiff:*.aiff -50:audio/x-aifc:*.aiffc -50:image/jp2:*.jpf -50:application/x-hdf:*.hdf4 -50:application/x-hdf:*.hdf5 -50:application/x-aportisdoc:*.pdb -50:application/vnd.palm:*.pdb -50:application/x-aportisdoc:*.pdc -50:application/x-profile:gmon.out -50:application/x-jbuilder-project:*.jpr -50:application/pdf:*.pdf -50:application/x-bzpdf:*.pdf.bz2 -50:application/x-theme:*.theme -50:image/jpeg:*.jpg -50:application/x-raw-disk-image-xz-compressed:*.img.xz -50:application/x-jbuilder-project:*.jpx -50:image/jp2:*.jpx -50:text/x-svsrc:*.sv -50:image/x-quicktime:*.qtif -50:image/x-kodak-k25:*.k25 -50:text/x-scheme:*.ss -50:application/vnd.openxmlformats-officedocument.presentationml.presentation:*.pptx -50:application/vnd.openxmlformats-officedocument.presentationml.presentation:*.pptx -50:application/x-ace:*.ace -50:image/vnd.zbrush.pcx:*.pcx -50:text/x-adasrc:*.ads -50:text/x-tcl:*.tk -50:text/x-changelog:changelog -50:audio/flac:*.flac -50:text/x-adasrc:*.adb -50:text/html:*.htm -50:text/x-google-video-pointer:*.gvp -50:text/troff:*.tr -50:audio/x-matroska:*.mka -50:text/vnd.trolltech.linguist:*.ts -50:video/mp2t:*.ts -50:application/x-cb7:*.cb7 -50:text/x-vhdl:*.vhdl -50:audio/ogg:*.oga -50:audio/x-vorbis+ogg:*.oga -50:audio/x-flac+ogg:*.oga -50:audio/x-speex+ogg:*.oga -50:application/xslt+xml:*.xsl -50:application/x-saturn-rom:*.iso -50:application/x-wii-rom:*.iso -50:application/x-gamecube-rom:*.iso -50:application/atom+xml:*.atom -50:video/3gpp:*.3ga -50:application/x-kontour:*.kon -50:audio/ogg:*.ogg -50:video/ogg:*.ogg -50:audio/x-vorbis+ogg:*.ogg -50:audio/x-flac+ogg:*.ogg -50:audio/x-speex+ogg:*.ogg -50:video/x-theora+ogg:*.ogg -50:image/x-pentax-pef:*.pef -50:application/vnd.ms-cab-compressed:*.cab -50:text/markdown:*.mkd -50:application/rdf+xml:*.rdfs -50:application/x-zoo:*.zoo -50:video/x-ogm+ogg:*.ogm -50:text/x-rpm-spec:*.spec -50:application/x-x509-ca-cert:*.pem -50:video/3gpp2:*.3gp2 -50:application/x-xpinstall:*.xpi -50:video/x-matroska:*.mkv -50:application/ram:*.ram -50:application/x-designer:*.ui -50:application/x-gtk-builder:*.ui -50:audio/x-wavpack-correction:*.wvc -50:video/ogg:*.ogv -50:application/vnd.tcpdump.pcap:*.cap -50:application/ogg:*.ogx -50:application/x-rar:*.rar -50:application/x-xbel:*.xbel -50:application/jrd+json:*.jrd -50:application/vnd.ms-tnef:*.tnef -50:image/x-panasonic-raw:*.raw -50:video/3gpp:*.3gp -50:audio/vnd.rn-realaudio:*.rax -50:text/x-python:*.wsgi -50:application/x-7z-compressed:*.7z -50:audio/x-wavpack:*.wvp -50:image/x-cmu-raster:*.ras -50:application/x-font-type1:*.pfa -50:application/x-font-type1:*.pfb -50:application/x-kpovmodeler:*.kpm -50:text/x-ocaml:*.mli -50:image/x-fuji-raf:*.raf -50:application/ld+json:*.jsonld -50:audio/x-ms-asx:*.wvx -50:application/x-kpresenter:*.kpr -50:application/x-font-bdf:*.bdf -50:application/x-cd-image:*.iso9660 -50:application/x-kpresenter:*.kpt -50:text/x-eiffel:*.e -50:application/x-font-afm:*.afm -50:text/x-nfo:*.nfo -50:image/x-compressed-xcf:*.xcf.bz2 -50:text/x-cobol:*.cbl -50:video/mp2t:*.bdm -50:video/quicktime:*.moov -50:text/x-texinfo:*.texi -50:application/x-wwf:*.wwf -50:application/x-cbr:*.cbr -50:application/pkcs12:*.pfx -50:application/metalink+xml:*.metalink -50:application/x-cbt:*.cbt -50:video/mpeg:[0-9][0-9][0-9].vdr -50:application/x-perl:*.perl -50:application/vnd.mozilla.xul+xml:*.xul -50:application/x-cbz:*.cbz -50:text/x-log:*.log -50:application/x-smaf:*.mmf -50:application/javascript:*.jsm -50:text/x-meson:meson_options.txt -50:application/x-gba-rom:*.agb -50:application/x-hwt:*.hwt -50:text/x-iptables:*.iptables -50:application/mathml+xml:*.mml -50:application/oxps:*.oxps -50:video/mp2t:*.bdmv -50:video/3gpp:*.3gpp -50:application/x-docbook+xml:*.docbook -50:audio/x-mod:*.m15 -50:application/x-chess-pgn:*.pgn -50:audio/x-mo3:*.mo3 -50:application/x-bcpio:*.bcpio -50:application/pgp-encrypted:*.pgp -50:application/pgp-keys:*.pgp -50:application/pgp-signature:*.pgp -50:application/x-bzip-compressed-tar:*.tar.bz -50:application/x-amipro:*.sam -50:application/vnd.google-earth.kmz:*.kmz -50:video/quicktime:*.qt -50:image/x-portable-graymap:*.pgm -50:application/x-krita:*.kra -50:application/x-dar:*.dar -50:application/vnd.wordperfect:*.wp -50:image/vnd.wap.wbmp:*.wbmp -50:application/x-spss-sav:*.sav -50:text/x-scons:sconstruct -50:video/x-msvideo:*.divx -50:audio/x-wavpack:*.wv -50:application/xhtml+xml:*.xhtml -50:video/x-mng:*.mng -50:text/x-uuencode:*.uue -50:image/x-pict:*.pict1 -50:image/x-pict:*.pict2 -50:image/x-bzeps:*.eps.bz2 -50:application/x-n64-rom:*.z64 -50:audio/x-musepack:*.mp+ -50:text/x-c++hdr:*.hxx -50:application/rdf+xml:*.rdf -50:application/x-netcdf:*.cdf -50:application/vnd.rn-realmedia:*.rmvb -50:application/x-dbf:*.dbf -50:audio/mp2:*.mp2 -50:video/mpeg:*.mp2 -50:application/vnd.lotus-1-2-3:*.123 -50:application/x-php:*.php -50:application/x-font-pcf:*.pcf.gz -50:audio/mpeg:*.mp3 -50:video/mp4:*.mp4 -50:text/x-python:*.py -50:audio/x-minipsf:*.minipsf -50:audio/x-xm:*.xm -50:application/vnd.corel-draw:*.cdr -50:audio/x-xi:*.xi -50:image/x-xwindowdump:*.xwd -50:application/x-desktop:*.desktop -50:application/x-bzip-compressed-tar:*.tb2 -50:text/x-tex:*.latex -50:text/x-moc:*.moc -50:audio/x-mod:*.mod -50:application/vnd.openxmlformats-officedocument.presentationml.slideshow:*.ppsx -50:application/x-docbook+xml:*.dbk -50:text/x-mof:*.mof -50:application/x-xz:*.xz -50:application/vnd.ms-excel.sheet.binary.macroEnabled.12:*.xlsb -50:application/vnd.ms-excel.sheet.binary.macroenabled.12:*.xlsb -50:application/x-kspread:*.ksp -50:audio/x-aiff:*.aif -50:text/markdown:*.markdown -50:text/vcard:*.gcrd -50:application/x-php:*.php3 -50:application/x-php:*.php4 -50:application/x-php:*.php5 -50:text/x-reject:*.rej -50:application/vnd.ms-excel.sheet.macroEnabled.12:*.xlsm -50:application/vnd.ms-excel.sheet.macroenabled.12:*.xlsm -50:video/mp2t:*.m2ts -50:text/x-ms-regedit:*.reg -50:application/vnd.openxmlformats-officedocument.wordprocessingml.document:*.docx -50:application/vnd.openxmlformats-officedocument.wordprocessingml.document:*.docx -50:text/x-dcl:*.dcl -50:application/dicom:*.dcm -50:video/vnd.mpegurl:*.m1u -50:text/x-scheme:*.scm -50:application/x-qtiplot:*.qti.gz -50:application/pkix-cert:*.cer -50:image/x-kodak-dcr:*.dcr -50:application/x-tar:*.tar -50:text/x-patch:*.patch -50:text/x-scala:*.scala -50:image/vnd.djvu:*.djvu -50:audio/x-musepack:*.mpc -50:video/quicktime:*.mov -50:video/mpeg:*.mpe -50:application/x-tarz:*.taz -50:application/x-trash:*.old -50:video/mpeg:*.mpg -50:video/mp2t:*.mpl -50:application/vnd.stardivision.draw:*.sda -50:application/vnd.stardivision.calc:*.sdc -50:text/x-mrml:*.mrml -50:application/vnd.stardivision.impress:*.sdd -50:audio/x-musepack:*.mpp -50:application/vnd.ms-excel.template.macroEnabled.12:*.xltm -50:application/vnd.ms-excel.template.macroenabled.12:*.xltm -50:video/mp4:*.lrv -50:video/mp2t:*.m2t -50:image/x-gzeps:*.epsf.gz -50:application/x-lrzip:*.lrz -50:video/3gpp2:*.3gpp2 -50:image/jpeg:*.jpeg -50:application/mbox:*.mbox -50:application/vnd.stardivision.impress:*.sdp -50:application/sdp:*.sdp -50:audio/x-mpegurl:*.m3u8 -50:application/vnd.apple.mpegurl:*.m3u8 -50:application/vnd.stardivision.chart:*.sds -50:image/x-dds:*.dds -50:application/x-kugar:*.kud -50:application/vnd.openxmlformats-officedocument.spreadsheetml.sheet:*.xlsx -50:application/vnd.openxmlformats-officedocument.spreadsheetml.sheet:*.xlsx -50:application/vnd.stardivision.writer:*.sdw -50:application/x-fictionbook+xml:*.fb2 -50:application/x-xzpdf:*.pdf.xz -50:text/x-copying:copying -50:application/x-bzip-compressed-tar:*.tbz -50:application/zlib:*.zz -50:application/x-lrzip-compressed-tar:*.tar.lrz -50:text/x-bibtex:*.bib -50:image/x-rgb:*.rgb -50:application/x-gzpostscript:*.ps.gz -50:application/x-gameboy-rom:*.cgb -50:application/x-php:*.phps -50:application/vnd.debian.binary-package:*.deb -50:application/x-qw:*.qif -50:image/x-quicktime:*.qif -50:audio/x-mpegurl:*.m3u -50:application/vnd.apple.mpegurl:*.m3u -50:application/vnd.openxmlformats-officedocument.spreadsheetml.template:*.xltx -50:application/vnd.openxmlformats-officedocument.spreadsheetml.template:*.xltx -50:text/x-c++src:*.c++ -50:application/x-ccmx:*.ccmx -50:application/vnd.coffeescript:*.coffee -50:application/octet-stream:*.bin -50:application/x-saturn-rom:*.bin -50:application/smil+xml:*.kino -50:application/pgp-keys:*.pkr -50:application/vnd.ms-visio.stencil.macroEnabled.main+xml:*.vssm -50:image/cgm:*.cgm -50:text/x-mup:*.not -50:text/x-tcl:*.tcl -50:audio/mp4:*.m4a -50:application/x-x509-ca-cert:*.der -50:audio/x-m4b:*.m4b -50:application/x-pagemaker:*.pm6 -50:text/x-meson:meson.build -50:application/x-sami:*.sami -50:application/vnd.ms-visio.stencil.main+xml:*.vssx -50:audio/x-iriver-pla:*.pla -50:text/x-mrml:*.mrl -50:application/vnd.nintendo.snes.rom:*.sfc -50:application/xml:*.xsd -50:video/mp4:*.m4v -50:video/mp2t:*.mpls -50:application/x-planperfect:*.pln -50:text/x-tex:*.ltx -50:image/x-minolta-mrw:*.mrw -50:application/metalink4+xml:*.meta4 -50:application/vnd.ms-powerpoint.addin.macroEnabled.12:*.ppam -50:application/vnd.ms-visio.template.macroEnabled.main+xml:*.vstm -50:application/x-compressed-tar:*.tar.gz -50:audio/x-scpls:*.pls -50:application/vnd.ms-htmlhelp:*.chm -50:application/x-hwp:*.hwp -50:application/x-abiword:*.abw.gz -50:application/x-alz:*.alz -50:application/x-kword:*.kwd -50:text/x-lua:*.lua -50:application/vnd.ms-visio.template.main+xml:*.vstx -50:video/vnd.mpegurl:*.m4u -50:text/x-ooc:*.ooc -50:application/x-msi:*.msi -50:application/x-kexiproject-sqlite2:*.kexi -50:application/x-kexiproject-sqlite3:*.kexi -50:video/x-anim:*.anim[1-9j] -50:application/x-pagemaker:*.pmd -50:application/x-abiword:*.zabw -50:application/x-gameboy-rom:*.sgb -50:application/x-kword:*.kwt -50:application/x-go-sgf:*.sgf -50:application/pkcs10:*.p10 -50:image/x-sgi:*.sgi -50:application/pkcs12:*.p12 -50:application/x-blender:*.blender -50:application/vnd.stardivision.writer:*.sgl -50:application/x-msx-rom:*.msx -50:application/x-dia-shape:*.shape -50:application/x-blender:*.blend -50:application/x-blender:*.blend -50:application/x-mimearchive:*.mhtml -50:audio/midi:*.midi -50:application/x-java-jnlp-file:*.jnlp -50:text/x-cmake:cmakelists.txt -50:audio/x-amzxml:*.amz -50:image/x-tga:*.tpic -50:audio/AMR:*.amr -50:text/x-makefile:makefile -50:text/x-scons:sconscript.* -50:text/x-tex:*.tex -50:application/vnd.oasis.opendocument.graphics-flat-xml:*.fodg -50:application/vnd.oasis.opendocument.graphics-flat-xml:*.fodg -50:text/sgml:*.sgm -50:application/x-amiga-disk-format:*.adf -50:image/x-msod:*.msod -50:audio/x-mod:*.mtm -50:image/png:*.png -50:application/vnd.oasis.opendocument.presentation-flat-xml:*.fodp -50:application/vnd.oasis.opendocument.presentation-flat-xml:*.fodp -50:application/x-navi-animation:*.ani -50:application/vnd.oasis.opendocument.spreadsheet-flat-xml:*.fods -50:application/vnd.oasis.opendocument.spreadsheet-flat-xml:*.fods -50:application/vnd.oasis.opendocument.text-flat-xml:*.fodt -50:application/vnd.oasis.opendocument.text-flat-xml:*.fodt -50:application/x-n64-rom:*.n64 -50:application/x-ustar:*.ustar -50:application/x-gameboy-rom:*.gbc -50:application/x-gba-rom:*.gba -50:application/x-java-pack200:*.pack -50:application/dicom:dicomdir -50:application/x-shar:*.shar -50:application/x-shorten:*.shn -50:application/x-genesis-rom:*.32x -50:image/x-portable-anymap:*.pnm -50:application/x-gzdvi:*.dvi.gz -50:application/annodex:*.anx -50:text/html:*.html -50:video/mp2t:*.mts -50:text/x-authors:authors -50:text/x-install:install -50:application/x-quattropro:*.wb1 -50:application/x-quattropro:*.wb2 -50:application/x-quattropro:*.wb3 -50:application/x-gnucash:*.gnucash -50:application/x-perl:*.pod -50:application/x-source-rpm:*.src.rpm -50:image/x-lwo:*.lwo -50:application/x-dia-diagram:*.dia -50:application/vnd.lotus-wordpro:*.lwp -50:application/x-lrzip-compressed-tar:*.tlrz -50:application/x-partial-download:*.wkdownload -50:application/x-glade:*.glade -50:application/pgp-signature:*.sig -50:text/x-qml:*.qml -50:image/x-tga:*.tga -50:audio/prs.sid:*.sid -50:application/x-trash:*.sik -50:application/x-spss-por:*.por -50:application/x-wii-wad:*.wad -50:application/vnd.ms-powerpoint:*.pot -50:text/x-gettext-translation-template:*.pot -50:image/x-lws:*.lws -50:application/x-zip-compressed-fb2:*.fb2.zip -50:text/vcard:*.vcf -50:application/vnd.symbian.install:*.sis -50:application/x-stuffit:*.sit -50:application/x-e-theme:*.etheme -50:application/sieve:*.siv -50:image/bmp:*.bmp -50:application/x-nes-rom:*.unif -50:image/x-skencil:*.sk1 -50:image/openraster:*.ora -50:text/vcard:*.vct -50:application/x-compressed-tar:*.tgz -50:application/x-netshow-channel:*.nsc -50:audio/x-wav:*.wav -50:image/x-olympus-orf:*.orf -50:audio/x-ms-asx:*.wax -50:audio/x-ape:*.ape -50:image/x-lwo:*.lwob -50:text/calendar:*.vcs -50:image/rle:*.rle -50:application/x-siag:*.siag -50:application/vnd.android.package-archive:*.apk -50:image/x-portable-pixmap:*.ppm -50:application/x-lz4:*.lz4 -50:image/x-applix-graphics:*.ag -50:application/illustrator:*.ai -50:application/vnd.ms-powerpoint:*.pps -50:application/vnd.ms-powerpoint:*.ppt -50:application/vnd.ms-powerpoint:*.ppt -50:video/x-nsv:*.nsv -50:application/x-perl:*.al -50:image/x-tga:*.vda -50:text/x-tex:*.cls -50:application/x-archive:*.ar -50:application/vnd.ms-powerpoint:*.ppz -50:application/x-applix-spreadsheet:*.as -50:application/vnd.tcpdump.pcap:*.pcap -50:audio/basic:*.au -50:application/x-applix-word:*.aw -50:image/vnd.djvu:*.djv -50:application/vnd.palm:*.pqa -50:application/xslt+xml:*.xslt -50:application/x-bittorrent:*.torrent -50:image/x-bzeps:*.epsi.bz2 -50:video/quicktime:*.qtvr -50:text/x-mup:*.mup -50:application/x-t602:*.602 -50:application/vnd.rn-realmedia:*.rmj -50:image/tiff:*.tif -50:application/x-lyx:*.lyx -50:application/x-gedcom:*.ged -50:application/vnd.rn-realmedia:*.rmm -50:application/x-gnucash:*.xac -50:text/x-eiffel:*.eif -50:application/x-sv4cpio:*.sv4cpio -50:application/vnd.rn-realmedia:*.rms -50:application/pgp-keys:*.skr -50:application/x-tar:*.gem -50:application/x-genesis-rom:*.gen -50:application/vnd.ms-works:*.wcm -50:application/x-yaml:*.yaml -50:application/vnd.ms-word.template.macroEnabled.12:*.dotm -50:application/vnd.ms-word.template.macroenabled.12:*.dotm -50:application/x-lha:*.lzh -50:application/mxf:*.mxf -50:application/vnd.oasis.opendocument.chart-template:*.otc -50:application/x-mobipocket-ebook:*.prc -50:application/vnd.palm:*.prc -50:application/vnd.oasis.opendocument.formula-template:*.otf -50:application/x-font-otf:*.otf -50:application/vnd.oasis.opendocument.graphics-template:*.otg -50:application/vnd.oasis.opendocument.graphics-template:*.otg -50:application/vnd.oasis.opendocument.text-web:*.oth -50:application/vnd.oasis.opendocument.text-web:*.oth -50:application/relax-ng-compact-syntax:*.rnc -50:application/x-lzop:*.lzo -50:text/x-makefile:gnumakefile -50:application/x-bzip:*.bz -50:application/x-arj:*.arj -50:application/x-spss-sav:*.zsav -50:text/x-c++src:*.cc -50:application/vnd.oasis.opendocument.presentation-template:*.otp -50:application/vnd.oasis.opendocument.presentation-template:*.otp -50:image/fits:*.fits -50:application/vnd.ms-works:*.wdb -50:application/vnd.oasis.opendocument.spreadsheet-template:*.ots -50:application/vnd.oasis.opendocument.spreadsheet-template:*.ots -50:application/vnd.oasis.opendocument.text-template:*.ott -50:application/vnd.oasis.opendocument.text-template:*.ott -50:application/x-partial-download:*.crdownload -50:application/x-tzo:*.tar.lzo -50:application/x-hdf:*.hdf -50:application/x-tarz:*.tar.z -50:application/vnd.rn-realmedia:*.rmx -50:image/x-sony-arw:*.arw -50:image/svg+xml-compressed:*.svgz -50:text/x-csharp:*.cs -50:text/spreadsheet:*.slk -50:image/x-icns:*.icns -50:image/x-xbitmap:*.xbm -50:video/vnd.mpegurl:*.mxu -50:application/xml:*.xbl -50:application/xml:*.rng -50:application/x-pagemaker:*.p65 -50:text/x-opml+xml:*.opml -50:text/plain:*.asc -50:image/vnd.adobe.photoshop:*.psd -50:application/x-font-linux-psf:*.psf -50:audio/x-psf:*.psf -50:text/x-cobol:*.cob -50:application/vnd.ms-asf:*.asf -50:application/vnd.nintendo.snes.rom:*.smc -50:application/vnd.stardivision.mail:*.smd -50:application/x-genesis-rom:*.smd -50:application/x-dc-rom:*.dc -50:application/vnd.stardivision.math:*.smf -50:application/x-apple-diskimage:*.dmg -50:application/smil+xml:*.smi -50:application/x-sami:*.smi -50:text/x-dsrc:*.di -50:application/x-asp:*.asp -50:application/x-gedcom:*.gedcom -50:application/smil+xml:*.sml -50:text/x-ssa:*.ass -50:image/x-xfig:*.fig -50:image/x-tga:*.icb -50:application/vnd.tcpdump.pcap:*.dmp -50:application/x-pocket-word:*.psw -50:application/x-sms-rom:*.sms -50:audio/x-ms-asx:*.asx -50:image/x-xcf:*.xcf -50:text/vnd.sun.j2me.app-descriptor:*.jad -50:video/dv:*.dv -50:application/vnd.openxmlformats-officedocument.wordprocessingml.template:*.dotx -50:application/vnd.openxmlformats-officedocument.wordprocessingml.template:*.dotx -50:image/vnd.microsoft.icon:*.ico -50:application/x-ica:*.ica -50:application/vnd.iccprofile:*.icc -50:text/calendar:*.ics -50:application/x-java-archive:*.jar -50:application/x-gnumeric:*.gnumeric -50:application/vnd.iccprofile:*.icm -50:application/x-sv4crc:*.sv4crc -50:audio/basic:*.snd -50:application/x-lzma:*.lzma -50:application/x-x509-ca-cert:*.cert -50:image/x-adobe-dng:*.dng -50:video/mp2t:*.cpi -50:text/x-vhdl:*.vhd -50:application/x-rpm:*.rpm -50:application/x-bzpostscript:*.ps.bz2 -50:text/x-emacs-lisp:*.el -50:application/xspf+xml:*.xspf -50:text/x-c++src:*.cpp -50:application/vnd.oasis.opendocument.text-master-template:*.otm -50:image/x-canon-cr2:*.cr2 -50:application/x-gnuplot:*.gnuplot -50:application/ecmascript:*.es -50:image/fax-g3:*.g3 -50:text/x-idl:*.idl -50:application/x-pkcs7-certificates:*.p7b -50:application/pkcs7-mime:*.p7c -50:application/andrew-inset:*.ez -50:application/x-desktop:*.kdelnk -50:application/x-lzma-compressed-tar:*.tlz -50:application/vnd.ms-publisher:*.pub -50:text/x-xslfo:*.xslfo -50:application/x-core:core:cs -50:application/x-core:core -50:application/x-trig:*.trig -50:application/pkcs7-mime:*.p7m -50:application/msword:*.doc -50:application/msword:*.doc -50:application/vnd.ms-word:*.doc -50:application/rdf+xml:*.owl -50:text/cache-manifest:*.manifest -50:application/pkcs7-signature:*.p7s -50:image/x-emf:*.emf -50:application/x-fluid:*.fl -50:image/gif:*.gif -50:message/rfc822:*.eml -50:application/owl+xml:*.owx -50:image/ief:*.ief -50:text/x-c++hdr:*.h++ -50:text/x-xslfo:*.fo -50:application/vnd.emusic-emusic_package:*.emp -50:application/msword-template:*.dot -50:text/vnd.graphviz:*.dot -50:application/x-hdf:*.h4 -50:application/x-hdf:*.h5 -50:application/x-nzb:*.nzb -50:text/x-uil:*.uil -50:video/vnd.vivo:*.viv -50:application/vnd.debian.binary-package:*.udeb -50:audio/midi:*.kar -50:video/x-msvideo:*.avf -50:text/csv-schema:*.csvs -50:application/x-pkcs7-certificates:*.spc -50:application/x-font-speedo:*.spd -50:application/x-qtiplot:*.qti -50:application/vnd.ms-excel.addin.macroEnabled.12:*.xlam -50:application/x-tex-gf:*.gf -50:application/vnd.ms-tnef:*.tnf -50:application/x-quicktime-media-link:*.qtl -50:text/x-patch:*.diff -50:application/pkix-crl:*.crl -50:application/vnd.openofficeorg.extension:*.oxt -50:application/vnd.openofficeorg.extension:*.oxt -50:application/x-source-rpm:*.spm -50:application/x-sms-rom:*.gg -50:application/vnd.adobe.flash.movie:*.spl -50:application/x-bzdvi:*.dvi.bz2 -50:application/x-gnuplot:*.gp -50:application/x-gameboy-rom:*.gb -50:application/x-x509-ca-cert:*.crt -50:image/x-sony-sr2:*.sr2 -50:application/x-gz-font-linux-psf:*.psf.gz -50:image/x-canon-crw:*.crw -50:image/x-ilbm:*.iff -50:audio/x-speex:*.spx -50:audio/x-mod:*.ult -50:audio/x-mod:*.669 -50:video/x-flv:*.flv -50:application/x-kivio:*.flw -50:text/vnd.graphviz:*.gv -50:application/gzip:*.gz -50:application/pkix-pkipath:*.pkipath -50:application/vnd.palm:*.oprc -50:audio/AMR-WB:*.awb -50:text/x-genie:*.gs:cs -50:text/x-genie:*.gs -50:video/x-flic:*.flc -50:text/x-go:*.go -50:application/x-cdrdao-toc:*.toc -50:application/x-awk:*.awk -50:application/x-csh:*.csh -50:audio/x-s3m:*.s3m -50:text/x-c++hdr:*.hh -50:application/xml-external-parsed-entity:*.ent -50:application/sql:*.sql -50:image/x-gzeps:*.eps.gz -50:text/x-texinfo:*.texinfo -50:video/x-msvideo:*.avi -50:application/rss+xml:*.rss -50:application/x-ufraw:*.ufraw -50:text/css:*.css -50:text/x-c++hdr:*.hp -50:application/x-ms-wim:*.wim -50:text/csv:*.csv -50:text/x-haskell:*.hs -50:application/x-mobipocket-ebook:*.mobi -50:application/vnd.lotus-1-2-3:*.wk1 -50:audio/annodex:*.axa -50:application/vnd.lotus-1-2-3:*.wk3 -50:application/vnd.lotus-1-2-3:*.wk4 -50:application/x-wais-source:*.src -50:application/rtf:*.rtf -50:image/x-sony-srf:*.srf -50:image/x-ilbm:*.ilbm -50:audio/x-mpegurl:*.vlc -50:application/x-nes-rom:*.unf -50:application/x-smaf:*.smaf -50:audio/x-mod:*.uni -50:video/x-flic:*.fli -50:text/sgml:*.sgml -50:video/annodex:*.axv -50:image/x-kodak-kdc:*.kdc -50:text/x-txt2tags:*.t2t -50:application/x-subrip:*.srt -50:audio/x-it:*.it -50:image/x-eps:*.eps -50:application/x-gzpdf:*.pdf.gz -50:image/x-eps:*.epsf -50:text/richtext:*.rtx -50:image/x-eps:*.epsi -50:application/x-java-jce-keystore:*.jceks -50:application/x-python-bytecode:*.pyc -50:image/x-ilbm:*.lbm -50:video/vnd.vivo:*.vivo -50:text/x-ssa:*.ssa -50:application/x-cue:*.cue -50:audio/vnd.dts.hd:*.dtshd -50:application/x-python-bytecode:*.pyo -50:application/x-windows-themepack:*.themepack -50:video/x-sgi-movie:*.movie -50:text/x-cmake:*.cmake -50:text/x-dsl:*.dsl -50:application/x-trash:*% -50:application/vnd.ms-powerpoint.slide.macroEnabled.12:*.sldm -50:image/x-panasonic-raw2:*.rw2 -50:application/gml+xml:*.gml -50:application/javascript:*.js -50:application/x-markaby:*.mab -50:application/x-gettext-translation:*.gmo -50:image/x-win-bitmap:*.cur -50:text/x-fortran:*.for -50:application/vnd.lotus-1-2-3:*.wks -50:application/vnd.ms-works:*.wks -50:text/x-python:*.pyx -50:application/vnd.openxmlformats-officedocument.presentationml.slide:*.sldx -50:text/x-makefile:*.mak -50:application/x-troff-man:*.man -50:message/x-gnu-rmail:rmail -50:application/vnd.sun.xml.calc.template:*.stc -50:application/vnd.sun.xml.calc.template:*.stc -50:application/vnd.sun.xml.draw.template:*.std -50:application/vnd.sun.xml.draw.template:*.std -50:application/xml-dtd:*.dtd -50:application/x-iwork-keynote-sffkey:*.key -50:application/vnd.sun.xml.impress.template:*.sti -50:application/vnd.sun.xml.impress.template:*.sti -50:application/x-gnucash:*.gnc -50:application/x-abiword:*.abw.crashed -50:application/x-kchart:*.chrt -50:audio/prs.sid:*.psid -50:application/gnunet-directory:*.gnd -50:audio/ogg:*.opus -50:audio/x-opus+ogg:*.opus -50:audio/x-stm:*.stm -50:application/x-bzip:*.bz2 -50:text/x-erlang:*.erl -50:application/epub+zip:*.epub -50:application/x-java-keystore:*.ks -50:video/vnd.rn-realvideo:*.rvx -50:application/x-m4:*.m4 -50:application/vnd.sun.xml.writer.template:*.stw -50:application/vnd.sun.xml.writer.template:*.stw -50:text/x-tex:*.sty -50:audio/vnd.dts:*.dts -50:application/json:*.json -50:text/x-tex:*.dtx -50:application/x-kformula:*.kfo -50:application/json-patch+json:*.json-patch -50:application/x-bzip-compressed-tar:*.tar.bz2 -50:application/x-java:*.class -50:application/x-shared-library-la:*.la -50:text/x-microdvd:*.sub -50:text/x-mpsub:*.sub -50:text/x-subviewer:*.sub -50:application/font-woff:*.woff -50:image/x-macpaint:*.pntg -50:application/winhlp:*.hlp -50:image/tiff:*.tiff -50:audio/x-ms-wma:*.wma -50:text/x-qml:*.qmlproject -50:video/mpeg:*.vob -50:application/vnd.ms-visio.drawing.macroEnabled.main+xml:*.vsdm -50:text/troff:*.roff -50:image/x-sun-raster:*.sun -50:audio/x-voc:*.voc -50:image/x-wmf:*.wmf -50:text/x-scons:sconscript -50:application/x-tar:*.gtar -50:text/vnd.wap.wml:*.wml -50:application/x-par2:*.par2 -50:application/x-par2:*.par2 -50:application/x-cpio-compressed:*.cpio.gz -50:application/vnd.ms-visio.drawing.main+xml:*.vsdx -50:application/vnd.stardivision.writer:*.vor -50:image/x-compressed-xcf:*.xcf.gz -50:text/x-lilypond:*.ly -50:application/x-lzip:*.lz -50:audio/x-psflib:*.psflib -50:video/x-ms-wmv:*.wmv -50:audio/x-ms-asx:*.wmx -50:application/x-it87:*.it87 -50:text/tab-separated-values:*.tsv -50:audio/mp4:*.f4a -50:audio/x-m4b:*.f4b -50:audio/x-tta:*.tta -50:application/x-trash:*~ -50:application/x-font-ttf:*.ttc -50:image/svg+xml:*.svg -50:application/x-kexi-connectiondata:*.kexic -50:application/x-font-ttf:*.ttf -50:application/x-dvi:*.dvi -50:application/vnd.ms-excel:*.xla -50:text/x-java:*.java -50:application/vnd.ms-excel:*.xlc -50:application/vnd.ms-excel:*.xld -50:application/pgp-encrypted:*.gpg -50:application/pgp-keys:*.gpg -50:application/pgp-signature:*.gpg -50:application/x-xliff:*.xlf -50:application/x-gettext-translation:*.mo -50:text/x-modelica:*.mo -50:text/x-svhdr:*.svh -50:application/x-mswinurl:*.url -50:image/x-gzeps:*.epsi.gz -50:application/vnd.ms-access:*.mdb -50:application/vnd.ms-excel:*.xll -50:application/vnd.ms-excel:*.xlm -50:application/vnd.ms-tnef:winmail.dat -50:application/x-kexiproject-shortcut:*.kexis -50:application/x-font-ttx:*.ttx -50:application/x-raw-disk-image:*.raw-disk-image -50:application/vnd.ms-works:*.xlr -50:application/vnd.ms-excel:*.xls -50:application/vnd.ms-excel:*.xls -50:application/vnd.wordperfect:*.wp4 -50:application/vnd.wordperfect:*.wp5 -50:application/vnd.wordperfect:*.wp6 -50:application/vnd.ms-excel:*.xlt -50:application/vnd.ms-excel:*.xlw -50:text/turtle:*.ttl -50:application/mathematica:*.nb -50:application/x-netcdf:*.nc -50:video/mp4:*.f4v -50:application/vnd.adobe.flash.movie:*.swf -50:text/x-makefile:*.mk -50:image/vnd.dwg:*.dwg -50:text/x-setext:*.etx -50:application/x-genesis-rom:*.mdx -50:application/vnd.ms-powerpoint.template.macroEnabled.12:*.potm -50:application/vnd.ms-powerpoint.template.macroenabled.12:*.potm -50:application/x-xz-compressed-tar:*.tar.xz -50:application/x-ms-wim:*.swm -50:video/mpeg:*.mpeg -50:text/x-credits:credits -50:text/x-iMelody:*.ime -50:audio/x-xmf:*.xmf -50:application/x-raw-disk-image:*.img -50:text/x-xmi:*.xmi -50:text/spreadsheet:*.sylk -50:application/x-partial-download:*.part -50:application/xml:*.xml -50:audio/x-mod:*.med -50:text/vnd.wap.wmlscript:*.wmls -50:image/x-bzeps:*.epsf.bz2 -50:application/x-killustrator:*.kil -50:application/pkcs8:*.p8 -50:application/zip:*.zip -50:image/vnd.ms-modi:*.mdi -50:application/x-java-keystore:*.jks -50:text/x-c++src:*.cxx -50:text/x-iMelody:*.imy -50:application/vnd.sun.xml.calc:*.sxc -50:application/vnd.sun.xml.calc:*.sxc -50:application/vnd.sun.xml.draw:*.sxd -50:application/vnd.sun.xml.draw:*.sxd -50:application/x-java-keystore:cacerts -50:application/vnd.sun.xml.writer.global:*.sxg -50:application/vnd.sun.xml.writer.global:*.sxg -50:application/x-graphite:*.gra -50:application/vnd.sun.xml.impress:*.sxi -50:application/vnd.sun.xml.impress:*.sxi -50:video/x-matroska-3d:*.mk3d -50:application/vnd.wordperfect:*.wpd -50:application/vnd.sun.xml.math:*.sxm -50:application/vnd.sun.xml.math:*.sxm -50:application/vnd.ms-powerpoint.slideshow.macroEnabled.12:*.ppsm -50:application/x-wpg:*.wpg -50:application/x-gnuplot:*.gplt -50:image/vnd.dxf:*.dxf -50:application/x-lha:*.lha -50:model/vrml:*.vrm -50:application/vnd.ms-wpl:*.wpl -50:audio/mpeg:*.mpga -50:application/vnd.sun.xml.writer:*.sxw -50:application/vnd.sun.xml.writer:*.sxw -50:application/vnd.wordperfect:*.wpp -50:application/x-n64-rom:*.v64 -50:text/x-c++hdr:*.hpp -50:application/vnd.ms-works:*.wps -50:text/plain:*,v -50:text/markdown:*.md -50:text/x-tex:*.ins -50:text/x-troff-ms:*.ms -50:application/x-tgif:*.obj -50:text/x-c++src:*.C:cs -50:text/x-c++src:*.C -50:text/x-literate-haskell:*.lhs -50:image/x-pict:*.pict -50:text/x-ocaml:*.ml -50:text/x-troff-mm:*.mm -50:application/x-nintendo-ds-rom:*.nds -50:application/x-bzip-compressed-tar:*.tbz2 -50:text/x-qml:*.qmltypes -50:application/x-lhz:*.lhz -50:application/vnd.visio:*.vsd -50:application/x-tex-pk:*.pk -50:application/x-font-type1:*.gsf -50:application/x-perl:*.pl -50:application/x-perl:*.pl -50:application/x-perl:*.pm -50:application/x-pagemaker:*.pm -50:application/vnd.ms-powerpoint.presentation.macroEnabled.12:*.pptm -50:application/vnd.ms-powerpoint.presentation.macroenabled.12:*.pptm -50:text/x-gettext-translation:*.po -50:application/vnd.hp-hpgl:*.hpgl -50:audio/x-gsm:*.gsm -50:application/postscript:*.ps -50:text/x-fortran:*.f90 -50:application/vnd.ms-word.document.macroEnabled.12:*.docm -50:application/vnd.ms-word.document.macroenabled.12:*.docm -50:application/x-yaml:*.yml -50:application/vnd.visio:*.vss -50:application/vnd.visio:*.vst -50:image/x-tga:*.vst -50:application/x-karbon:*.karbon -50:image/x-nikon-nef:*.nef -50:application/vnd.visio:*.vsw -50:application/x-archive:*.a -50:audio/aac:*.aac -50:text/x-csrc:*.c:cs -50:text/x-csrc:*.c -50:application/x-pw:*.pw -50:application/x-magicpoint:*.mgp -50:text/x-ocl:*.ocl -50:application/x-pak:*.pak -50:text/x-chdr:*.h -50:text/x-dsrc:*.d -50:application/x-nes-rom:*.nes -50:application/x-ms-dos-executable:*.exe -50:text/x-objcsrc:*.m -50:text/x-matlab:*.m -50:text/x-troff-me:*.me -50:application/x-object:*.o -50:text/x-fortran:*.f -50:text/x-pascal:*.p -50:text/x-pascal:*.pas -50:video/mp2t:*.clpi -10:application/x-perl:*.t -10:text/troff:*.t -10:text/x-readme:readme* -10:application/pgp-encrypted:*.asc -10:application/pgp-keys:*.asc -10:application/pgp-signature:*.asc -10:text/x-makefile:makefile.* diff --git a/src-qt5/core/lumina-desktop/Globals.h b/src-qt5/core/lumina-desktop/Globals.h index 479fe4ad..14dfd93f 100644 --- a/src-qt5/core/lumina-desktop/Globals.h +++ b/src-qt5/core/lumina-desktop/Globals.h @@ -7,7 +7,8 @@ #ifndef _LUMINA_DESKTOP_GLOBALS_H #define _LUMINA_DESKTOP_GLOBALS_H -#include <LuminaUtils.h> +#include <LUtils.h> +#include <LDesktopUtils.h> //#include "../global.h" #include <unistd.h> diff --git a/src-qt5/core/lumina-desktop/JsonMenu.h b/src-qt5/core/lumina-desktop/JsonMenu.h index 87377a73..5a6b2237 100644 --- a/src-qt5/core/lumina-desktop/JsonMenu.h +++ b/src-qt5/core/lumina-desktop/JsonMenu.h @@ -16,7 +16,7 @@ #include <QJsonObject> #include <QJsonArray> -#include <LuminaUtils.h> +#include <LUtils.h> #include <LuminaXDG.h> #include "LSession.h" diff --git a/src-qt5/core/lumina-desktop/LSession.cpp b/src-qt5/core/lumina-desktop/LSession.cpp index 87f270ea..f383c163 100644 --- a/src-qt5/core/lumina-desktop/LSession.cpp +++ b/src-qt5/core/lumina-desktop/LSession.cpp @@ -15,7 +15,7 @@ //LibLumina X11 class #include <LuminaX11.h> -#include <LuminaUtils.h> +#include <LUtils.h> #include <unistd.h> //for usleep() usage @@ -29,7 +29,7 @@ LSession::LSession(int &argc, char ** argv) : LSingleApplication(argc, argv, "lu if(this->isPrimaryProcess()){ connect(this, SIGNAL(InputsAvailable(QStringList)), this, SLOT(NewCommunication(QStringList)) ); this->setApplicationName("Lumina Desktop Environment"); - this->setApplicationVersion( LUtils::LuminaDesktopVersion() ); + this->setApplicationVersion( LDesktopUtils::LuminaDesktopVersion() ); this->setOrganizationName("LuminaDesktopEnvironment"); this->setQuitOnLastWindowClosed(false); //since the LDesktop's are not necessarily "window"s //Enabled a few of the simple effects by default @@ -372,7 +372,7 @@ void LSession::checkUserFiles(){ //internal version conversion examples: // [1.0.0 -> 1000000], [1.2.3 -> 1002003], [0.6.1 -> 6001] QString OVS = sessionsettings->value("DesktopVersion","0").toString(); //Old Version String - bool changed = LUtils::checkUserFiles(OVS); + bool changed = LDesktopUtils::checkUserFiles(OVS); if(changed){ //Save the current version of the session to the settings file (for next time) sessionsettings->setValue("DesktopVersion", this->applicationVersion()); diff --git a/src-qt5/core/lumina-desktop/desktop-plugins/notepad/NotepadPlugin.cpp b/src-qt5/core/lumina-desktop/desktop-plugins/notepad/NotepadPlugin.cpp index 435a57c2..a2549acf 100644 --- a/src-qt5/core/lumina-desktop/desktop-plugins/notepad/NotepadPlugin.cpp +++ b/src-qt5/core/lumina-desktop/desktop-plugins/notepad/NotepadPlugin.cpp @@ -2,7 +2,7 @@ #include <LuminaXDG.h> #include "LSession.h" -#include <LuminaUtils.h> +#include <LUtils.h> #include <QDir> #include <QFileDialog> #include <QInputDialog> diff --git a/src-qt5/core/lumina-desktop/desktop-plugins/quickcontainer/QuickDPlugin.h b/src-qt5/core/lumina-desktop/desktop-plugins/quickcontainer/QuickDPlugin.h index 4ba74133..d6039ac0 100644 --- a/src-qt5/core/lumina-desktop/desktop-plugins/quickcontainer/QuickDPlugin.h +++ b/src-qt5/core/lumina-desktop/desktop-plugins/quickcontainer/QuickDPlugin.h @@ -13,7 +13,7 @@ #include <QVBoxLayout> #include "../LDPlugin.h" -#include <LuminaUtils.h> +#include <LUtils.h> class QuickDPlugin : public LDPlugin{ Q_OBJECT diff --git a/src-qt5/core/lumina-desktop/desktop-plugins/rssreader/RSSFeedPlugin.cpp b/src-qt5/core/lumina-desktop/desktop-plugins/rssreader/RSSFeedPlugin.cpp index 23c1ca01..8dc58e0a 100644 --- a/src-qt5/core/lumina-desktop/desktop-plugins/rssreader/RSSFeedPlugin.cpp +++ b/src-qt5/core/lumina-desktop/desktop-plugins/rssreader/RSSFeedPlugin.cpp @@ -9,7 +9,7 @@ #include <LuminaXDG.h> #include "LSession.h" -#include <LuminaUtils.h> +#include <LUtils.h> #include <QDir> #include <QFileDialog> #include <QInputDialog> diff --git a/src-qt5/core/lumina-desktop/lumina-desktop.pro b/src-qt5/core/lumina-desktop/lumina-desktop.pro index effa0508..4b725288 100644 --- a/src-qt5/core/lumina-desktop/lumina-desktop.pro +++ b/src-qt5/core/lumina-desktop/lumina-desktop.pro @@ -4,16 +4,23 @@ QT += core gui network greaterThan(QT_MAJOR_VERSION, 4): QT += widgets x11extras multimedia concurrent svg + TARGET = lumina-desktop target.path = $${L_BINDIR} +#include all the special classes from the Lumina tree +include(../libLumina/ResizeMenu.pri) +include(../libLumina/LDesktopUtils.pri) #includes LUtils and LOS +include(../libLumina/LuminaXDG.pri) +include(../libLumina/LuminaX11.pri) +include(../libLumina/LuminaSingleApplication.pri) +include(../libLumina/LuminaThemes.pri) -LIBS += -lLuminaUtils -lxcb -lxcb-damage -DEPENDPATH += ../libLumina +#LIBS += -lLuminaUtils -lxcb -lxcb-damage +#DEPENDPATH += ../libLumina TEMPLATE = app - SOURCES += main.cpp \ WMProcess.cpp \ LXcbEventFilter.cpp \ @@ -53,8 +60,6 @@ HEADERS += Globals.h \ FORMS += SystemWindow.ui \ BootSplash.ui -#include all the special classes from the Lumina tree -include(../libLumina/ResizeMenu.pri) #Now include all the files for the various plugins include(panel-plugins/panel-plugins.pri) diff --git a/src-qt5/core/lumina-desktop/main.cpp b/src-qt5/core/lumina-desktop/main.cpp index 35561073..b42a3816 100644 --- a/src-qt5/core/lumina-desktop/main.cpp +++ b/src-qt5/core/lumina-desktop/main.cpp @@ -22,7 +22,8 @@ #include <LuminaXDG.h> //from libLuminaUtils #include <LuminaThemes.h> #include <LuminaOS.h> -#include <LuminaUtils.h> +#include <LUtils.h> +#include <LDesktopUtils.h> #define DEBUG 0 @@ -58,7 +59,7 @@ int main(int argc, char ** argv) { if (argc > 1) { if (QString(argv[1]) == QString("--version")){ - qDebug() << LUtils::LuminaDesktopVersion(); + qDebug() << LDesktopUtils::LuminaDesktopVersion(); return 0; } } diff --git a/src-qt5/core/lumina-desktop/panel-plugins/battery/LBattery.h b/src-qt5/core/lumina-desktop/panel-plugins/battery/LBattery.h index 3d31faad..29562d5d 100644 --- a/src-qt5/core/lumina-desktop/panel-plugins/battery/LBattery.h +++ b/src-qt5/core/lumina-desktop/panel-plugins/battery/LBattery.h @@ -12,7 +12,7 @@ #include <QString> #include <QLabel> -#include <LuminaUtils.h> +#include <LUtils.h> #include <LuminaXDG.h> #include <LuminaOS.h> diff --git a/src-qt5/core/lumina-desktop/panel-plugins/battery/NOTES b/src-qt5/core/lumina-desktop/panel-plugins/battery/NOTES index 3ea07778..3d93267e 100644 --- a/src-qt5/core/lumina-desktop/panel-plugins/battery/NOTES +++ b/src-qt5/core/lumina-desktop/panel-plugins/battery/NOTES @@ -22,7 +22,7 @@ apm -l apm -t Zeigt die verbleibende Zeit in Sekunden -Aufruf Systemfunktionen: LuminaUtils.h +Aufruf Systemfunktionen: LUtils.h mit der Methode: QStringList LUtils::getCmdOutput(QString cmd, QStringList args) diff --git a/src-qt5/core/lumina-desktop/panel-plugins/desktopbar/LDeskBar.cpp b/src-qt5/core/lumina-desktop/panel-plugins/desktopbar/LDeskBar.cpp index 9903d4fd..90d942de 100644 --- a/src-qt5/core/lumina-desktop/panel-plugins/desktopbar/LDeskBar.cpp +++ b/src-qt5/core/lumina-desktop/panel-plugins/desktopbar/LDeskBar.cpp @@ -102,7 +102,7 @@ void LDeskBarPlugin::filechanged(QString file){ } void LDeskBarPlugin::updateFiles(){ QFileInfoList homefiles = LSession::handle()->DesktopFiles(); - QStringList favitems = LUtils::listFavorites(); + QStringList favitems = LDesktopUtils::listFavorites(); //Remember for format for favorites: <name>::::[app/dir/<mimetype>]::::<full path> for(int i=0; i<homefiles.length(); i++){ if( !favitems.filter(homefiles[i].canonicalFilePath()).isEmpty() ){ continue; } //duplicate entry diff --git a/src-qt5/core/lumina-desktop/panel-plugins/desktopswitcher/LDesktopSwitcher.h b/src-qt5/core/lumina-desktop/panel-plugins/desktopswitcher/LDesktopSwitcher.h index 851d9e35..af9250b7 100644 --- a/src-qt5/core/lumina-desktop/panel-plugins/desktopswitcher/LDesktopSwitcher.h +++ b/src-qt5/core/lumina-desktop/panel-plugins/desktopswitcher/LDesktopSwitcher.h @@ -14,7 +14,7 @@ #include <QMenu> #include <QToolButton> -#include <LuminaUtils.h> +#include <LUtils.h> #include <LuminaXDG.h> #include <LuminaX11.h> diff --git a/src-qt5/core/lumina-desktop/panel-plugins/quickcontainer/QuickPPlugin.h b/src-qt5/core/lumina-desktop/panel-plugins/quickcontainer/QuickPPlugin.h index e160c2b3..6f61c4d5 100644 --- a/src-qt5/core/lumina-desktop/panel-plugins/quickcontainer/QuickPPlugin.h +++ b/src-qt5/core/lumina-desktop/panel-plugins/quickcontainer/QuickPPlugin.h @@ -13,7 +13,7 @@ #include <QVBoxLayout> #include "../LPPlugin.h" -#include <LuminaUtils.h> +#include <LUtils.h> #include <QDebug> class QuickPPlugin : public LPPlugin{ diff --git a/src-qt5/core/lumina-desktop/panel-plugins/systemstart/ItemWidget.cpp b/src-qt5/core/lumina-desktop/panel-plugins/systemstart/ItemWidget.cpp index 15b9c72c..ea074a59 100644 --- a/src-qt5/core/lumina-desktop/panel-plugins/systemstart/ItemWidget.cpp +++ b/src-qt5/core/lumina-desktop/panel-plugins/systemstart/ItemWidget.cpp @@ -5,7 +5,7 @@ // See the LICENSE file for full details //=========================================== #include "ItemWidget.h" -#include <LuminaUtils.h> +#include <LUtils.h> #include <QMenu> #include "../../LSession.h" @@ -73,7 +73,7 @@ ItemWidget::ItemWidget(QWidget *parent, QString itemPath, QString type, bool gob icon->setWhatsThis(itemPath); if(!goback){ this->setWhatsThis(name->text()); } isDirectory = (type=="dir"); //save this for later - if(LUtils::isFavorite(itemPath)){ + if(LDesktopUtils::isFavorite(itemPath)){ linkPath = itemPath; isShortcut=true; }else if( inHome ){//|| itemPath.section("/",0,-2)==QDir::homePath()+"/Desktop" ){ @@ -93,7 +93,7 @@ ItemWidget::ItemWidget(QWidget *parent, XDGDesktop *item) : QFrame(parent){ createWidget(); if(item==0){ gooditem = false; return; } isDirectory = false; - if(LUtils::isFavorite(item->filePath)){ + if(LDesktopUtils::isFavorite(item->filePath)){ linkPath = item->filePath; isShortcut=true; }else if( item->filePath.section("/",0,-2)==QDir::homePath()+"/Desktop" ){ @@ -177,7 +177,7 @@ void ItemWidget::setupContextMenu(){ contextMenu->addAction( LXDG::findIcon("preferences-desktop-icons",""), tr("Pin to Desktop"), this, SLOT(PinToDesktop()) ); } //Favorite Item - if( LUtils::isFavorite(icon->whatsThis()) ){ //Favorite Item - can always remove this + if( LDesktopUtils::isFavorite(icon->whatsThis()) ){ //Favorite Item - can always remove this contextMenu->addAction( LXDG::findIcon("edit-delete",""), tr("Remove from Favorites"), this, SLOT(RemoveFavorite()) ); }else{ //This file does not have a shortcut yet -- allow the user to add it @@ -242,13 +242,13 @@ void ItemWidget::PinToDesktop(){ } void ItemWidget::RemoveFavorite(){ - LUtils::removeFavorite(icon->whatsThis()); + LDesktopUtils::removeFavorite(icon->whatsThis()); linkPath.clear(); emit RemovedShortcut(); } void ItemWidget::AddFavorite(){ - if( LUtils::addFavorite(icon->whatsThis()) ){ + if( LDesktopUtils::addFavorite(icon->whatsThis()) ){ linkPath = icon->whatsThis(); emit NewShortcut(); } diff --git a/src-qt5/core/lumina-desktop/panel-plugins/systemstart/LStartButton.cpp b/src-qt5/core/lumina-desktop/panel-plugins/systemstart/LStartButton.cpp index 0a396464..f44add77 100644 --- a/src-qt5/core/lumina-desktop/panel-plugins/systemstart/LStartButton.cpp +++ b/src-qt5/core/lumina-desktop/panel-plugins/systemstart/LStartButton.cpp @@ -8,7 +8,7 @@ #include "../../LSession.h" #include <LuminaXDG.h> -#include <LuminaUtils.h> //This contains the "ResizeMenu" class +#include <LUtils.h> //This contains the "ResizeMenu" class LStartButtonPlugin::LStartButtonPlugin(QWidget *parent, QString id, bool horizontal) : LPPlugin(parent, id, horizontal){ button = new QToolButton(this); diff --git a/src-qt5/core/lumina-desktop/panel-plugins/systemstart/LStartButton.h b/src-qt5/core/lumina-desktop/panel-plugins/systemstart/LStartButton.h index 22742bc5..d46bb1be 100644 --- a/src-qt5/core/lumina-desktop/panel-plugins/systemstart/LStartButton.h +++ b/src-qt5/core/lumina-desktop/panel-plugins/systemstart/LStartButton.h @@ -24,7 +24,7 @@ // libLumina includes #include <LuminaXDG.h> -#include <LuminaUtils.h> +#include <LUtils.h> #include <ResizeMenu.h> #include "StartMenu.h" diff --git a/src-qt5/core/lumina-desktop/panel-plugins/systemstart/StartMenu.cpp b/src-qt5/core/lumina-desktop/panel-plugins/systemstart/StartMenu.cpp index bfac46c0..260215ec 100644 --- a/src-qt5/core/lumina-desktop/panel-plugins/systemstart/StartMenu.cpp +++ b/src-qt5/core/lumina-desktop/panel-plugins/systemstart/StartMenu.cpp @@ -411,7 +411,7 @@ void StartMenu::UpdateApps(){ void StartMenu::UpdateFavs(){ //SYNTAX NOTE: (per-line) "<name>::::[dir/app/<mimetype>]::::<path>" - QStringList newfavs = LUtils::listFavorites(); + QStringList newfavs = LDesktopUtils::listFavorites(); if(favs == newfavs){ return; } //nothing to do - same as before favs = newfavs; ClearScrollArea(ui->scroll_favs); diff --git a/src-qt5/core/lumina-desktop/panel-plugins/userbutton/UserItemWidget.cpp b/src-qt5/core/lumina-desktop/panel-plugins/userbutton/UserItemWidget.cpp index a1dfe956..8d7dab7a 100644 --- a/src-qt5/core/lumina-desktop/panel-plugins/userbutton/UserItemWidget.cpp +++ b/src-qt5/core/lumina-desktop/panel-plugins/userbutton/UserItemWidget.cpp @@ -5,7 +5,8 @@ // See the LICENSE file for full details //=========================================== #include "UserItemWidget.h" -#include <LuminaUtils.h> +#include <LUtils.h> +#include <LDesktopUtils.h> #include <QMenu> #define TEXTCUTOFF 165 @@ -50,7 +51,7 @@ UserItemWidget::UserItemWidget(QWidget *parent, QString itemPath, QString type, icon->setWhatsThis(itemPath); if(!goback){ this->setWhatsThis(name->text()); } isDirectory = (type=="dir"); //save this for later - if(LUtils::isFavorite(itemPath)){ + if(LDesktopUtils::isFavorite(itemPath)){ linkPath = itemPath; isShortcut=true; }else if( inHome ){//|| itemPath.section("/",0,-2)==QDir::homePath()+"/Desktop" ){ @@ -66,7 +67,7 @@ UserItemWidget::UserItemWidget(QWidget *parent, XDGDesktop *item) : QFrame(paren if(item==0){ return; } createWidget(); isDirectory = false; - if(LUtils::isFavorite(item->filePath)){ + if(LDesktopUtils::isFavorite(item->filePath)){ linkPath = item->filePath; isShortcut=true; }else if( item->filePath.section("/",0,-2)==QDir::homePath()+"/Desktop" ){ @@ -171,7 +172,7 @@ void UserItemWidget::setupActions(XDGDesktop *app){ void UserItemWidget::buttonClicked(){ button->setVisible(false); if(button->whatsThis()=="add"){ - LUtils::addFavorite(icon->whatsThis()); + LDesktopUtils::addFavorite(icon->whatsThis()); //QFile::link(icon->whatsThis(), QDir::homePath()+"/.lumina/favorites/"+icon->whatsThis().section("/",-1) ); emit NewShortcut(); }else if(button->whatsThis()=="remove"){ @@ -184,7 +185,7 @@ void UserItemWidget::buttonClicked(){ } //Don't emit the RemovedShortcut signal here - the automatic ~/Desktop watcher will see the change when finished }else{ - LUtils::removeFavorite(icon->whatsThis()); //This is a favorite + LDesktopUtils::removeFavorite(icon->whatsThis()); //This is a favorite emit RemovedShortcut(); } } diff --git a/src-qt5/core/lumina-desktop/panel-plugins/userbutton/UserWidget.cpp b/src-qt5/core/lumina-desktop/panel-plugins/userbutton/UserWidget.cpp index fb58c7f6..a0ba8996 100644 --- a/src-qt5/core/lumina-desktop/panel-plugins/userbutton/UserWidget.cpp +++ b/src-qt5/core/lumina-desktop/panel-plugins/userbutton/UserWidget.cpp @@ -221,7 +221,7 @@ void UserWidget::updateFavItems(bool newfilter){ if(updatingfavs){ return; } updatingfavs = true; //qDebug() << "Updating User Favorite Items"; - QStringList newfavs = LUtils::listFavorites(); + QStringList newfavs = LDesktopUtils::listFavorites(); //qDebug() << "Favorites:" << newfavs; if(lastHomeUpdate.isNull() || (QFileInfo(QDir::homePath()+"/Desktop").lastModified() > lastHomeUpdate) || newfavs!=favs ){ favs = newfavs; diff --git a/src-qt5/core/lumina-info/MainUI.cpp b/src-qt5/core/lumina-info/MainUI.cpp index 98a4c160..7e6a3630 100644 --- a/src-qt5/core/lumina-info/MainUI.cpp +++ b/src-qt5/core/lumina-info/MainUI.cpp @@ -8,7 +8,8 @@ #include "ui_MainUI.h" #include <LuminaOS.h> -#include <LuminaUtils.h> +#include <LDesktopUtils.h> +#include <LUtils.h> #include <LuminaXDG.h> #include <QPixmap> @@ -38,7 +39,7 @@ void MainUI::updateUI(){ ui->tool_website->setIcon( LXDG::findIcon("go-home","")); connect(ui->push_close, SIGNAL(clicked()), this, SLOT(close()) ); //General Tab - ui->label_version->setText( LUtils::LuminaDesktopVersion() ); + ui->label_version->setText( LDesktopUtils::LuminaDesktopVersion() ); ui->label_OS->setText( LOS::OSName() ); connect(ui->tool_aboutQt, SIGNAL(clicked()), this, SLOT(showQtInfo()) ); //License Tab diff --git a/src-qt5/core/lumina-info/lumina-info.pro b/src-qt5/core/lumina-info/lumina-info.pro index 9ced275b..3ba1f527 100644 --- a/src-qt5/core/lumina-info/lumina-info.pro +++ b/src-qt5/core/lumina-info/lumina-info.pro @@ -8,6 +8,12 @@ target.path = $${L_BINDIR} TEMPLATE = app +#include all the special classes from the Lumina tree +include(../libLumina/LDesktopUtils.pri) #includes LUtils +include(../libLumina/LuminaXDG.pri) +include(../libLumina/LuminaSingleApplication.pri) +include(../libLumina/LuminaThemes.pri) + SOURCES += main.cpp \ MainUI.cpp @@ -17,9 +23,9 @@ FORMS += MainUI.ui RESOURCES+= lumina-info.qrc -LIBS += -lLuminaUtils +#LIBS += -lLuminaUtils -DEPENDPATH += ../libLumina +#DEPENDPATH += ../libLumina TRANSLATIONS = i18n/lumina-info_af.ts \ i18n/lumina-info_ar.ts \ diff --git a/src-qt5/core/lumina-info/main.cpp b/src-qt5/core/lumina-info/main.cpp index 8fe6a183..e30911c5 100644 --- a/src-qt5/core/lumina-info/main.cpp +++ b/src-qt5/core/lumina-info/main.cpp @@ -6,7 +6,7 @@ #include "MainUI.h" #include <LuminaOS.h> #include <LuminaThemes.h> -#include <LuminaUtils.h> +#include <LUtils.h> #include <LuminaSingleApplication.h> int main(int argc, char ** argv) diff --git a/src-qt5/core/lumina-open/LFileDialog.h b/src-qt5/core/lumina-open/LFileDialog.h index 95e117fa..b81cde05 100644 --- a/src-qt5/core/lumina-open/LFileDialog.h +++ b/src-qt5/core/lumina-open/LFileDialog.h @@ -22,7 +22,7 @@ #include <QAction> #include <LuminaXDG.h> //From libLuminaUtils -#include <LuminaUtils.h> +#include <LUtils.h> namespace Ui{ class LFileDialog; diff --git a/src-qt5/core/lumina-open/lumina-open.pro b/src-qt5/core/lumina-open/lumina-open.pro index 3240b2d3..96d879bd 100644 --- a/src-qt5/core/lumina-open/lumina-open.pro +++ b/src-qt5/core/lumina-open/lumina-open.pro @@ -9,6 +9,9 @@ target.path = $${L_BINDIR} TEMPLATE = app +include(../libLumina/LuminaXDG.pri) +include(../libLumina/LuminaThemes.pri) + SOURCES += main.cpp \ LFileDialog.cpp @@ -18,10 +21,6 @@ FORMS += LFileDialog.ui RESOURCES+= lumina-open.qrc -LIBS += -lLuminaUtils - -DEPENDPATH += ../libLumina - TRANSLATIONS = i18n/lumina-open_af.ts \ i18n/lumina-open_ar.ts \ diff --git a/src-qt5/core/lumina-open/main.cpp b/src-qt5/core/lumina-open/main.cpp index b411394c..279f7c1b 100644 --- a/src-qt5/core/lumina-open/main.cpp +++ b/src-qt5/core/lumina-open/main.cpp @@ -25,7 +25,7 @@ #include "LFileDialog.h" #include <LuminaXDG.h> -#include <LuminaUtils.h> +#include <LUtils.h> #include <LuminaOS.h> #include <LuminaThemes.h> diff --git a/src-qt5/core/lumina-session/lumina-session.pro b/src-qt5/core/lumina-session/lumina-session.pro index 91a5f891..dc697a34 100644 --- a/src-qt5/core/lumina-session/lumina-session.pro +++ b/src-qt5/core/lumina-session/lumina-session.pro @@ -6,9 +6,9 @@ QT = core widgets TARGET = start-lumina-desktop target.path = $${L_BINDIR} - -LIBS += -lLuminaUtils -DEPENDPATH += ../libLumina +include(../libLumina/LDesktopUtils.pri) +include(../libLumina/LuminaXDG.pri) +include(../libLumina/LuminaThemes.pri) SOURCES += main.cpp \ session.cpp diff --git a/src-qt5/core/lumina-session/main.cpp b/src-qt5/core/lumina-session/main.cpp index 77e553d4..73af45f9 100644 --- a/src-qt5/core/lumina-session/main.cpp +++ b/src-qt5/core/lumina-session/main.cpp @@ -10,7 +10,8 @@ #include <QString> #include "session.h" -#include <LuminaUtils.h> +#include <LUtils.h> +#include <LDesktopUtils.h> #include <LuminaOS.h> #include <LuminaThemes.h> #include <LuminaXDG.h> @@ -21,7 +22,7 @@ int main(int argc, char ** argv) { if (argc > 1) { if (QString(argv[1]) == QString("--version")){ - qDebug() << LUtils::LuminaDesktopVersion(); + qDebug() << LDesktopUtils::LuminaDesktopVersion(); return 0; } } diff --git a/src-qt5/core/lumina-session/session.cpp b/src-qt5/core/lumina-session/session.cpp index c689c9a3..10953f12 100644 --- a/src-qt5/core/lumina-session/session.cpp +++ b/src-qt5/core/lumina-session/session.cpp @@ -13,7 +13,7 @@ #include <QSettings> #include <QDir> -#include <LuminaUtils.h> +#include <LUtils.h> #include <LuminaOS.h> void LSession::stopall(){ diff --git a/src-qt5/core/quickplugins/quick-sample.qml b/src-qt5/core/quickplugins/quick-sample.qml new file mode 100644 index 00000000..18b10d77 --- /dev/null +++ b/src-qt5/core/quickplugins/quick-sample.qml @@ -0,0 +1,12 @@ +// Plugin-Name=Sample +// Plugin-Description=A simple example for QtQuick/QML plugins +// Plugin-Icon=preferences-plugin +// Created: Ken Moore (ken@pcbsd.org) May 2015 + +import QtQuick.Controls 1.3 + +Label { + text: "Sample" + color: "blue" + font.bold: true +} \ No newline at end of file diff --git a/src-qt5/core/themes/Glass.qss.template b/src-qt5/core/themes/Glass.qss.template new file mode 100644 index 00000000..d594d25e --- /dev/null +++ b/src-qt5/core/themes/Glass.qss.template @@ -0,0 +1,539 @@ +/* ALL THE TEMPLATE WIDGETS */ +INHERITS=None + +/* ALL THE WIDGETS WITH THE BASE COLOR */ +QMainWindow, QMenu, QDialog, QMessageBox{ + background: qradialgradient(spread:reflect, cx:0.113757, cy:0.875, radius:0.7, fx:0.045, fy:0.954545, stop:0 %%BASECOLOR%%, stop:1 %%ALTBASECOLOR%%); + color: %%TEXTCOLOR%%; + border: 1px solid %%ACCENTDISABLECOLOR%%; + border-radius: 3px; +} + +/* ALL THE WIDGETS WITH AN ALTERNATE BASE COLOR */ +QLineEdit, QTextEdit, QTextBrowser, QPlainTextEdit, QSpinBox, QDateEdit, QDateTimeEdit, QTimeEdit, QDoubleSpinBox{ + background: %%ALTBASECOLOR%%; + color: %%TEXTCOLOR%%; + border-color: %%ACCENTDISABLECOLOR%%; + selection-background-color: %%HIGHLIGHTCOLOR%%; + selection-color: %%TEXTHIGHLIGHTCOLOR%%; +} + +/* PAGES OF CONTAINER WIDGETS */ +QStackedWidget .QWidget{ + background: transparent; + color: %%TEXTCOLOR%%; + border: none; +} + +QToolBox::tab{ + color: %%TEXTCOLOR%%; +} + +/* MENU WIDGETS */ +QMenuBar, QMenuBar::item,QToolBar{ + background: transparent; + border: none; + color: %%TEXTCOLOR%%; +} + +QStatusBar{ + background: QLinearGradient(x1: 0, y1: 0, x2: 0, y2: 1, stop: 0 transparent, stop: 0.5 %%SECONDARYCOLOR%%); + border: none; + color: %%TEXTCOLOR%%; +} +QToolBar:top{ + border-bottom: 1px solid %%ACCENTCOLOR%%; +} +QToolBar:bottom{ + border-top: 1px solid %%ACCENTCOLOR%%; +} +QToolBar:left{ + border-right: 1px solid %%ACCENTCOLOR%%; +} +QToolBar:right{ + border-left: 1px solid %%ACCENTCOLOR%%; +} + +QMenuBar::item{ + background: transparent; /*Use the menu bar color*/ + padding-left: 4px; + padding-right: 2px; +} + +QMenuBar::item:selected, QMenuBar::item:pressed, QMenu::item:selected{ +background: QLinearGradient(x1: 0, y1: 0, x2: 1, y2: 1, stop: 0 %%HIGHLIGHTDISABLECOLOR%%, stop: 1 %%HIGHLIGHTCOLOR%%); +color: %%TEXTHIGHLIGHTCOLOR%%; +border: 1px solid %%ACCENTCOLOR%%; +} +QMenuBar::item:disabled{ + color: %%TEXTDISABLECOLOR%%; +} + +/*QMenu::item{ + border: 2px solid #808080; +}*/ + +QMenu::item{ + background: transparent; + border: 1px solid transparent; + color: %%TEXTCOLOR%%; + padding: 4px 30px 4px 20px; + margin-left: 3px; + margin-right: 3px; +} + +/* TAB WIDGETS */ +/*QTabBar{ + Custom Font settings need to be here and NOT in the ::tab fields, + otherwise it will break auto-scaling of the tab sizes to fit the text +}*/ +/* Transparency does not work on main pages within tabwidgets*/ +QTabWidget QStackedWidget .QWidget{ + background: rgb(230,230,230); + border-bottom-left-radius: 4px; + border-bottom-right-radius: 4px; +} +QTabWidget{ + color: black; + border: none; +} +QTabWidget QLabel{ + color: black; +} +QTabBar::tab { + background: QLinearGradient(x1: 0, y1: 0, x2: 1, y2: 1, stop: 0 %%SECONDARYDISABLECOLOR%%, stop: 1 %%ALTBASECOLOR%%); + border: 1px solid %%ACCENTCOLOR%%; + padding: 2px; + color: %%TEXTCOLOR%%; +} +QTabBar::tab:top{ + border-top-left-radius: 4px; + border-top-right-radius: 4px; + max-width: 100em; + min-width: 0em; +} +QTabBar::tab:bottom{ + border-bottom-left-radius: 4px; + border-bottom-right-radius: 4px; + max-width: 100em; + min-width: 0em; +} +/* left/right tab indicators appear to be reversed in Qt*/ +QTabBar::tab:right{ + border-top-left-radius: 4px; + border-bottom-left-radius: 4px; + max-height: 100em; + min-height: 0em; +} +QTabBar::tab:left{ + border-top-right-radius: 4px; + border-bottom-right-radius: 4px; + max-height: 100em; + min-height: 0em; +} +QTabBar::tab:selected{ + background: QLinearGradient(x1: 0, y1: 0, x2: 0, y2: 1, stop: 0 %%HIGHLIGHTDISABLECOLOR%%, stop: 1 rgb(230,230,230)); + border-bottom: none; +} +QTabBar::tab:hover { + background: %%HIGHLIGHTCOLOR%%; + border: 1px solid %%ACCENTDISABLECOLOR%%; + } + +QTabBar::tab:!selected:top { + margin-top: 4px; +} +QTabBar::tab:!selected:bottom{ + margin-bottom: 4px; +} +QTabBar::tab:!selected:right{ + margin-left: 4px; +} +QTabBar::tab:!selected:left{ + margin-right: 4px; +} + +/* FRAME WIDGETS */ +QToolTip{ + background: QLinearGradient(x1: 0, y1: 0, x2: 1, y2: 1, stop: 0 %%BASECOLOR%%, stop: 1 %%ALTBASECOLOR%%); + border-radius: 3px; + border: 1px solid %%ACCENTCOLOR%%; + padding: 1px; + color: %%TEXTCOLOR%%; +} + +QLabel{ + background: transparent; + border: none; + color: %%TEXTCOLOR%%; +} +QAbstractButton::disabled{ + color: %%TEXTDISABLECOLOR%%; +} + +/* GROUP BOX */ +QGroupBox{ + background-color: transparent; + border-color: %%ACCENTCOLOR%%; + border-radius: 5px; + margin-top: 2ex; + font-weight: bold; +} +QGroupBox::title{ + subcontrol-origin: margin; + subcontrol-position: top center; + padding: 0 3px; + background: transparent; + /*border: none;*/ + color: %%TEXTCOLOR%%; +} + +/* COMBO BOX */ +QComboBox{ + /*border: 1px solid %%ACCENTCOLOR%%; + border-radius: 3px; + padding: 1px 18px 1px 3px;*/ + color: %%TEXTCOLOR%%; + background: %%ALTBASECOLOR%%; + selection-background-color: %%HIGHLIGHTCOLOR%%; + } + + +/* VIEW WIDGETS */ +QTreeView, QListView{ + background: %%ALTBASECOLOR%%; + alternate-background-color: %%BASECOLOR%%; + /*selection-background-color: %%SECONDARYCOLOR%%;*/ + border: 1px solid %%ACCENTCOLOR%%; + border-radius: 3px; + /*show-decoration-selected: 1;*/ + color: %%TEXTCOLOR%%; + selection-color: %%TEXTCOLOR%%; +} + +QTreeView:focus, QListView:focus{ + border: 1px solid %%HIGHLIGHTDISABLECOLOR%%; +} + +/* +QTreeView::item and QListView::item unneccessary: +Already set though parentage and causes usage errors if set manually +*/ + +/*QTreeView::item:selected, QListView::item:selected{ + background: %%SECONDARYDISABLECOLOR%%; + border-color: %%ACCENTCOLOR%%; + color: %%TEXTCOLOR%%; +}*/ + +QTreeView::item:hover, QListView::item:hover{ + background: %%HIGHLIGHTDISABLECOLOR%%; +} +QTreeView::item:selected:hover, QListView::item:selected:hover{ + background: %%HIGHLIGHTDISABLECOLOR%%; +} +QTreeView::item:selected, QListView::item:selected{ + background: %%SECONDARYDISABLECOLOR%%; +} +QTreeView::item:selected:focus, QListView::item:selected:focus{ + background: %%SECONDARYCOLOR%%; +} +QHeaderView{ + background: %%HIGHLIGHTDISABLECOLOR%%; + color: %%TEXTHIGHLIGHTCOLOR%%; + border: none; + border-top-left-radius: 3px; /*match the list/tree view widgets*/ + border-top-right-radius: 3px; /*match the list/tree view widgets*/ +} +QHeaderView::section{ + background: %%HIGHLIGHTDISABLECOLOR%%; /*QLinearGradient(x1: 0, y1: 0, x2: 1, y2: 1, stop: 0 %%PRIMARYDISABLECOLOR%%, stop: 1 %%PRIMARYCOLOR%%);*/ + color: %%TEXTHIGHLIGHTCOLOR%%; + border-color: %%ACCENTCOLOR%%; + padding: 1px; + padding-left: 4px; +} +QHeaderView::section:hover{ + background: %%PRIMARYCOLOR%%; + border-color: %%ACCENTDISABLECOLOR%%; + color: %%TEXTCOLOR%%; +} + +/* SCROLLBARS (NOTE: Changing 1 subcontrol means you have to change all of them)*/ +QScrollBar{ + background:%%ALTBASECOLOR%%; +} +QScrollBar:horizontal{ + margin: 0px 0px 0px 0px; +} +QScrollBar:vertical{ + margin: 0px 0px 0px 0px; +} +QScrollBar::handle{ + background: %%SECONDARYCOLOR%%; + border: 1px solid transparent; + border-radius: 7px; +} +QScrollBar::handle:hover, QScrollBar::add-line:hover, QScrollBar::sub-line:hover{ + background: %%SECONDARYDISABLECOLOR%%; +} +QScrollBar::add-line{ +subcontrol-origin: none; +} +QScrollBar::add-line:vertical, QScrollBar::sub-line:vertical{ +height: 0px; +} +QScrollBar::add-line:horizontal, QScrollBar::sub-line:horizontal{ +width: 0px; +} +QScrollBar::sub-line{ +subcontrol-origin: none; +} + +/* SLIDERS */ +QSlider::groove:horizontal { +border: 1px solid %%ACCENTCOLOR%%; +background: %%ALTBASECOLOR%%; +height: 10px; +border-radius: 3px; +} +QSlider::groove:vertical { +border: 1px solid %%ACCENTCOLOR%%; +background: %%ALTBASECOLOR%%; +width: 10px; +border-radius: 3px; +} +QSlider::sub-page:horizontal { +background: qlineargradient(x1: 0, y1: 0, x2: 1, y2: 1, + stop: 0 %%HIGHLIGHTCOLOR%%, stop: 1 %%HIGHLIGHTDISABLECOLOR%%); +border: 1px solid %%ACCENTCOLOR%%; +height: 10px; +border-radius: 3px; +} +QSlider::sub-page:vertical { +background: qlineargradient(x1: 0, y1: 0, x2: 1, y2: 1, + stop: 0 %%HIGHLIGHTCOLOR%%, stop: 1 %%HIGHLIGHTDISABLECOLOR%%); +border: 1px solid %%ACCENTCOLOR%%; +width: 10px; +border-radius: 3px; +} +QSlider::add-page:horizontal{ +background: %%ALTBASECOLOR%%; +border: 1px solid %%ACCENTCOLOR%%; +height: 10px; +border-radius: 3px; +} +QSlider::add-page:vertical{ +background: %%ALTBASECOLOR%%; +border: 1px solid %%ACCENTCOLOR%%; +width: 10px; +border-radius: 3px; +} +QSlider::handle:horizontal{ +background: %%ALTBASECOLOR%%; +border: 1px solid %%ACCENTCOLOR%%; +width: 13px; +border-radius: 4px; +} +QSlider::handle:vertical{ +background: %%ALTBASECOLOR%%; +border: 1px solid %%ACCENTCOLOR%%; +height: 13px; +border-radius: 4px; +} +QSlider::handle:horizontal:hover, QSlider::handle:vertical:hover{ +border: 1px solid %%ACCENTDISABLECOLOR%%; +/*background: %%HIGHLIGHTCOLOR%%;*/ +} + +QSlider::sub-page:horizontal:disabled { +background: %%ACCENTDISABLECOLOR%%; +border-color: %%ACCENTCOLOR%%; +} + +QSlider::add-page:horizontal:disabled { +background: %%ACCENTDISABLECOLOR%%; +border-color: %%ACCENTCOLOR%%; +} + +QSlider::handle:horizontal:disabled { +background: %%ALTBASECOLOR%%; +border: 1px solid %%ACCENTCOLOR%%; +} + +/* BUTTONS */ +QPushButton{ + border: 1px solid %%ACCENTCOLOR%%; + border-radius: 3px; + background-color: QLinearGradient(x1: 0, y1: 0, x2: 1, y2: 1, stop: 0 %%SECONDARYDISABLECOLOR%%, stop: 1 %%SECONDARYCOLOR%%); + padding: 2px; + padding-right: 4px; + color: %%TEXTCOLOR%%; + } + +QToolButton{ /* Assume a flat button for every toolbutton by default*/ + color: %%TEXTCOLOR%%; + border: 1px solid transparent; + border-radius: 3px; + background-color: transparent; + padding: 1px; +} + + QPushButton:pressed, QPushButton:open, QPushButton:selected, QPushButton:checked, QPushButton:on, QToolButton:pressed, QToolButton:open, QToolButton:selected, QToolButton:checked, QToolButton:on{ + background-color: QLinearGradient(x1: 0, y1: 0, x2: 1, y2: 1, stop: 0 %%HIGHLIGHTDISABLECOLOR%%, stop: 1 %%HIGHLIGHTCOLOR%%); + margin-top: 2px; + } + +QPushButton:flat, QToolButton:flat{ + background-color: transparent; + border: 1px solid transparent; /* no border for a flat button */ +} + +QPushButton:hover, QToolButton:hover{ + border: 1px solid %%ACCENTCOLOR%%; + background-color: QLinearGradient(x1: 0, y1: 0, x2: 1, y2: 1, stop: 0 %%HIGHLIGHTDISABLECOLOR%%, stop: 1 %%HIGHLIGHTCOLOR%%); + color: %%TEXTHIGHLIGHTCOLOR%%; +} +QRadioButton, QCheckBox{ + padding: 2px; + border: 1px solid transparent; + border-radius: 3px; + color: %%TEXTCOLOR%%; +} +QRadioButton::hover, QCheckBox:hover{ + background: QLinearGradient(x1: 0, y1: 0, x2: 1, y2: 1, stop: 0 %%HIGHLIGHTDISABLECOLOR%%, stop: 1 %%HIGHLIGHTCOLOR%%); + border: 1px solid %%ACCENTCOLOR%%; + color: %%TEXTHIGHLIGHTCOLOR%%; +} +QRadioButton::indicator, QCheckBox::indicator, QGroupBox::indicator{ + border: 1px solid %%TEXTCOLOR%%; +} +QRadioButton::indicator{ + border-radius: 7px; +} +QRadioButton::indicator:checked{ + background: qradialgradient(spread:pad, cx:0.5, cy:0.5, radius:1, fx:0.5, fy:0.5, stop:0 %%TEXTCOLOR%%, stop:0.25 %%TEXTCOLOR%%, stop:0.25001 transparent); +} +QCheckBox::indicator:checked, QGroupBox::indicator:checked{ + padding: 1px; + background-origin: content; + background-clip: content; + background: %%TEXTCOLOR%%; +} +QCheckBox::indicator:indeterminate, QGroupBox::indicator:indeterminate{ + padding: 1px; + background-origin: content; + background-clip: content; + background: QLinearGradient(x1: 0, y1: 0, x2: 1, y2: 1, stop: 0.49 transparent, stop: 0.5 %%TEXTCOLOR%%); +} + +/* PROGRESSBAR */ +QProgressBar{ + background-color: %%ALTBASECOLOR%%; + border: 1px solid %%ACCENTCOLOR%%; + border-radius: 5px; + color: %%TEXTCOLOR%%; + text-align: center; + padding: 1px; +} + QProgressBar::chunk { + background-color: QLinearGradient(x1: 0, y1: 0, x2: 1, y2: 1, stop: 0 %%HIGHLIGHTCOLOR%%, stop: 1 %%HIGHLIGHTDISABLECOLOR%%); + /*border: 1px solid %%ACCENTDISABLECOLOR%%;*/ + border-radius: 5px; + } +QProgressBar::chunk:vertical{ + margin-left: 2px; + margin-right: 2px; +} +QProgressBar::chunk:horizontal{ + margin-top: 2px; + margin-bottom: 2px; +} + +QWidget#LuminaBootSplash{ + background: qradialgradient(spread:reflect, cx:0.113757, cy:0.875, radius:0.7, fx:0.045, fy:0.954545, stop:0 rgba(234, 236, 243, 30), stop:1 rgba(229, 229, 229, 70)); + border-radius: 5px; +} + +LDPlugin#applauncher{ + background-color: transparent; + border: none; +} +LDPlugin#applauncher QToolButton, LDPlugin, LDPlugin#desktopview QListWidget::item{ + background-color: qradialgradient(spread:reflect, cx:0.113757, cy:0.875, radius:0.7, fx:0.045, fy:0.954545, stop:0 rgba(234, 236, 243, 30), stop:1 rgba(229, 229, 229, 70)); + border-width: 3px; + border-style: solid; + border-radius: 5px; + border-top-color: qradialgradient(spread:pad, cx:0.5, cy:1, radius:0.5, fx:0.5, fy:1, stop:0 rgba(255, 255, 255, 30), stop:0.724868 rgba(255, 255, 255, 60), stop:1 rgba(255, 255, 255, 10)); + border-bottom-color: qradialgradient(spread:pad, cx:0.5, cy:0, radius:0.5, fx:0.5, fy:0, stop:0 rgba(255, 255, 255, 30), stop:0.724868 rgba(255, 255, 255, 60), stop:1 rgba(255, 255, 255, 10)); + border-left-color: qradialgradient(spread:pad, cx:1, cy:0.5, radius:0.5, fx:1, fy:0.5, stop:0 rgba(255, 255, 255, 30), stop:0.724868 rgba(255, 255, 255, 60), stop:1 rgba(255, 255, 255, 10)); + border-right-color: qradialgradient(spread:pad, cx:0, cy:0.5, radius:0.5, fx:1, fy:0.5, stop:0 rgba(255, 255, 255, 30), stop:0.724868 rgba(255, 255, 255, 60), stop:1 rgba(255, 255, 255, 10)); + color: white; +} + +LDPlugin#applauncher QToolButton:hover, LDPlugin#desktopview QListWidget::item:hover{ + background-color: qradialgradient(spread:reflect, cx:0.113757, cy:0.875, radius:0.7, fx:0.045, fy:0.954545, stop:0 rgba(234, 236, 243, 100), stop:1 rgba(229, 229, 229, 150)); + border-width: 3px; + border-style: solid; + border-radius: 5px; + border-top-color: qradialgradient(spread:pad, cx:0.5, cy:1, radius:0.5, fx:0.5, fy:1, stop:0 rgba(255, 255, 255, 30), stop:0.724868 rgba(255, 255, 255, 60), stop:1 rgba(255, 255, 255, 10)); + border-bottom-color: qradialgradient(spread:pad, cx:0.5, cy:0, radius:0.5, fx:0.5, fy:0, stop:0 rgba(255, 255, 255, 30), stop:0.724868 rgba(255, 255, 255, 60), stop:1 rgba(255, 255, 255, 10)); + border-left-color: qradialgradient(spread:pad, cx:1, cy:0.5, radius:0.5, fx:1, fy:0.5, stop:0 rgba(255, 255, 255, 30), stop:0.724868 rgba(255, 255, 255, 60), stop:1 rgba(255, 255, 255, 10)); + border-right-color: qradialgradient(spread:pad, cx:0, cy:0.5, radius:0.5, fx:1, fy:0.5, stop:0 rgba(255, 255, 255, 30), stop:0.724868 rgba(255, 255, 255, 60), stop:1 rgba(255, 255, 255, 10)); + color: %%TEXTHIGHLIGHTCOLOR%%; +} +QWidget#LuminaPanelColor{ + background: qradialgradient(spread:reflect, cx:0.113757, cy:0.875, radius:0.7, fx:0.045, fy:0.954545, stop:0 rgba(234, 236, 243, 60), stop:1 rgba(229, 229, 229, 110)); + border-radius: 3px; +} +/*Special taskmanager window buttons: based on window state*/ +LTBWidget{ + border: 1px solid transparent; + border-radius: 3px; +} +LTBWidget::menu-indicator{ image: none; } /*disable the menu arrow*/ +LTBWidget#WindowVisible{ + background: QLinearGradient(x1: 0, y1: 0, x2: 1, y2: 1.1, stop: 0.1 %%PRIMARYCOLOR%%, stop: 1 transparent); +} +LTBWidget#WindowInvisible{ + background: transparent; +} +LTBWidget#WindowActive{ + background: QLinearGradient(x1: 0, y1: 0, x2: 1, y2: 1.1, stop: 0.1 %%HIGHLIGHTDISABLECOLOR%%, stop: 1 transparent); +} +LTBWidget#WindowAttention{ + background: QLinearGradient(x1: 0, y1: 0, x2: 1, y2: 1.1, stop: 0.1 %%HIGHLIGHTCOLOR%%, stop: 1 transparent); +} +LTBWidget:hover, LTBWidget#WindowVisible:hover, LTBWidget#WindowInvisible:hover, LTBWidget#WindowActive:hover, LTBWidget#WindowAttention:hover, QToolButton:hover{ + background: QLinearGradient(x1: 0, y1: 0, x2: 1, y2: 1.1, stop: 0.1 %%HIGHLIGHTCOLOR%%, stop: 1 transparent); + color: %%TEXTHIGHLIGHTCOLOR%%; + border-width: 1px; + border-style: solid; + border-top-color: qradialgradient(spread:pad, cx:0.5, cy:1, radius:0.5, fx:0.5, fy:1, stop:0 rgba(255, 255, 255, 30), stop:0.724868 rgba(255, 255, 255, 60), stop:1 rgba(255, 255, 255, 10)); + border-bottom-color: qradialgradient(spread:pad, cx:0.5, cy:0, radius:0.5, fx:0.5, fy:0, stop:0 rgba(255, 255, 255, 30), stop:0.724868 rgba(255, 255, 255, 60), stop:1 rgba(255, 255, 255, 10)); + border-left-color: qradialgradient(spread:pad, cx:1, cy:0.5, radius:0.5, fx:1, fy:0.5, stop:0 rgba(255, 255, 255, 30), stop:0.724868 rgba(255, 255, 255, 60), stop:1 rgba(255, 255, 255, 10)); + border-right-color: qradialgradient(spread:pad, cx:0, cy:0.5, radius:0.5, fx:1, fy:0.5, stop:0 rgba(255, 255, 255, 30), stop:0.724868 rgba(255, 255, 255, 60), stop:1 rgba(255, 255, 255, 10)); +} +/* CALENDER WIDGET */ + /* (This is a special hack since there is no official support for stylesheets for this widget) */ + QCalendarWidget QWidget#qt_calendar_navigationbar{ + background-color: %%ALTBASECOLOR%%; + } +QCalendarWidget QWidget{ + background-color: %%BASECOLOR%%; + alternate-background-color: rgba(255, 255, 255, 50); + color: %%TEXTCOLOR%%; +} +QCalendarWidget QAbstractButton{ + background-color: transparent; +} +QCalendarWidget QAbstractButton::menu-indicator{ + image: none; +} +QCalendarWidget QAbstractItemView{ + selection-background-color: qradialgradient(spread:reflect, cx:0.113757, cy:0.875, radius:0.7, fx:0.045, fy:0.954545, stop:0 rgba(234, 236, 243, 20), stop:1 rgba(229, 229, 229, 100)); + selection-color: %%TEXTHIGHLIGHTCOLOR%%; +} +QCalendarWidget QWidget#qt_calendar_calendarview{ + background-color: rgb(220,220,220); + border: none; +} diff --git a/src-qt5/core/themes/Lumina-default.qss.template b/src-qt5/core/themes/Lumina-default.qss.template new file mode 100644 index 00000000..9f03d4ae --- /dev/null +++ b/src-qt5/core/themes/Lumina-default.qss.template @@ -0,0 +1,494 @@ +/* ALL THE TEMPLATE WIDGETS */ +INHERITS=None + +/* ALL THE WIDGETS WITH THE BASE COLOR */ +QMainWindow, QMenu, QDialog, QMessageBox{ + background: %%BASECOLOR%%; + color: %%TEXTCOLOR%%; +} + +/* ALL THE WIDGETS WITH AN ALTERNATE BASE COLOR */ +QLineEdit, QTextEdit, QTextBrowser, QPlainTextEdit, QSpinBox, QDateEdit, QDateTimeEdit, QTimeEdit, QDoubleSpinBox{ + background: %%ALTBASECOLOR%%; + color: %%TEXTCOLOR%%; + border-color: %%ACCENTDISABLECOLOR%%; + selection-background-color: %%HIGHLIGHTCOLOR%%; + selection-color: %%TEXTHIGHLIGHTCOLOR%%; + +} + +/* PAGES OF CONTAINER WIDGETS */ +QStackedWidget .QWidget, QTabWidget .QWidget{ + background: %%ALTBASECOLOR%%; + color: %%TEXTCOLOR%%; + border: none; +} +QToolBox::tab{ + color: %%TEXTCOLOR%%; +} + +/* MENU WIDGETS */ +QMenuBar, QMenuBar::item,QToolBar{ + background: %%SECONDARYCOLOR%%; + border: none; + color: %%TEXTCOLOR%%; +} + +QStatusBar{ + background: QLinearGradient(x1: 0, y1: 0, x2: 0, y2: 1, stop: 0 transparent, stop: 0.5 %%SECONDARYCOLOR%%); + border: none; + color: %%TEXTCOLOR%%; +} +QToolBar:top{ + border-bottom: 1px solid %%ACCENTCOLOR%%; +} +QToolBar:bottom{ + border-top: 1px solid %%ACCENTCOLOR%%; +} +QToolBar:left{ + border-right: 1px solid %%ACCENTCOLOR%%; +} +QToolBar:right{ + border-left: 1px solid %%ACCENTCOLOR%%; +} + +QMenuBar::item{ + background: transparent; /*Use the menu bar color*/ + padding-left: 4px; + padding-right: 2px; +} + +QMenuBar::item:selected, QMenuBar::item:pressed, QMenu::item:selected{ +background: QLinearGradient(x1: 0, y1: 0, x2: 1, y2: 1, stop: 0 %%HIGHLIGHTDISABLECOLOR%%, stop: 1 %%HIGHLIGHTCOLOR%%); +color: %%TEXTHIGHLIGHTCOLOR%%; +border: 1px solid %%ACCENTCOLOR%%; +} +QMenuBar::item:disabled{ + color: %%TEXTDISABLECOLOR%%; +} + +QMenu::item{ + border: 2px solid #808080; +} + +QMenu::item{ + background: transparent; + border: 1px solid transparent; + color: %%TEXTCOLOR%%; + padding: 4px 30px 4px 20px; + margin-left: 3px; + margin-right: 3px; +} + +/* TAB WIDGETS */ +/*QTabBar{ + Custom Font settings need to be here and NOT in the ::tab fields, + otherwise it will break auto-scaling of the tab sizes to fit the text +}*/ +QTabBar::tab { + background: QLinearGradient(x1: 0, y1: 0, x2: 1, y2: 1, stop: 0 %%SECONDARYDISABLECOLOR%%, stop: 1 %%SECONDARYCOLOR%%); + border: 1px solid %%ACCENTCOLOR%%; + padding: 2px; + color: %%TEXTCOLOR%%; +} +QTabBar::tab:top{ + border-top-left-radius: 4px; + border-top-right-radius: 4px; + max-width: 100em; + min-width: 0em; +} +QTabBar::tab:bottom{ + border-bottom-left-radius: 4px; + border-bottom-right-radius: 4px; + max-width: 100em; + min-width: 0em; +} +/* left/right tab indicators appear to be reversed in Qt*/ +QTabBar::tab:right{ + border-top-left-radius: 4px; + border-bottom-left-radius: 4px; + max-height: 100em; + min-height: 0em; +} +QTabBar::tab:left{ + border-top-right-radius: 4px; + border-bottom-right-radius: 4px; + max-height: 100em; + min-height: 0em; +} +QTabBar::tab:selected{ + background: %%HIGHLIGHTDISABLECOLOR%%; +} +QTabBar::tab:hover { + background: %%HIGHLIGHTCOLOR%%; + border: 1px solid %%ACCENTDISABLECOLOR%%; + } + +QTabBar::tab:!selected:top { + margin-top: 4px; +} +QTabBar::tab:!selected:bottom{ + margin-bottom: 4px; +} +QTabBar::tab:!selected:right{ + margin-left: 4px; +} +QTabBar::tab:!selected:left{ + margin-right: 4px; +} + +/* FRAME WIDGETS */ +QToolTip{ + background: QLinearGradient(x1: 0, y1: 0, x2: 1, y2: 1, stop: 0 %%BASECOLOR%%, stop: 1 %%ALTBASECOLOR%%); + border-radius: 3px; + border: 1px solid %%ACCENTCOLOR%%; + padding: 1px; + color: %%TEXTCOLOR%%; +} + +QLabel{ + background: transparent; + border: none; + color: %%TEXTCOLOR%%; +} +QAbstractButton::disabled{ + color: %%TEXTDISABLECOLOR%%; +} + +/* GROUP BOX */ +QGroupBox{ + background-color: transparent; + border-color: %%ACCENTCOLOR%%; + border-radius: 5px; + margin-top: 2ex; + font-weight: bold; +} +QGroupBox::title{ + subcontrol-origin: margin; + subcontrol-position: top center; + padding: 0 3px; + background: transparent; + /*border: none;*/ + color: %%TEXTCOLOR%%; +} + +/* COMBO BOX */ +QComboBox{ + /*border: 1px solid %%ACCENTCOLOR%%; + border-radius: 3px; + padding: 1px 18px 1px 3px;*/ + color: %%TEXTCOLOR%%; + background: %%ALTBASECOLOR%%; + selection-background-color: %%HIGHLIGHTCOLOR%%; + } + + +/* VIEW WIDGETS */ +QTreeView, QListView{ + background: %%ALTBASECOLOR%%; + alternate-background-color: %%BASECOLOR%%; + /*selection-background-color: %%SECONDARYCOLOR%%;*/ + border: 1px solid %%ACCENTCOLOR%%; + border-radius: 3px; + /*show-decoration-selected: 1;*/ + color: %%TEXTCOLOR%%; + selection-color: %%TEXTCOLOR%%; +} + +QTreeView:focus, QListView:focus{ + border: 1px solid %%HIGHLIGHTDISABLECOLOR%%; +} + +/* +QTreeView::item and QListView::item unneccessary: +Already set though parentage and causes usage errors if set manually +*/ + +/*QTreeView::item:selected, QListView::item:selected{ + background: %%SECONDARYDISABLECOLOR%%; + border-color: %%ACCENTCOLOR%%; + color: %%TEXTCOLOR%%; +}*/ + +QTreeView::item:hover, QListView::item:hover{ + background: %%HIGHLIGHTDISABLECOLOR%%; +} +QTreeView::item:selected:hover, QListView::item:selected:hover{ + background: %%HIGHLIGHTDISABLECOLOR%%; +} +QTreeView::item:selected, QListView::item:selected{ + background: %%SECONDARYDISABLECOLOR%%; +} +QTreeView::item:selected:focus, QListView::item:selected:focus{ + background: %%SECONDARYCOLOR%%; +} +QHeaderView{ + background: %%HIGHLIGHTDISABLECOLOR%%; + color: %%TEXTHIGHLIGHTCOLOR%%; + border: none; + border-top-left-radius: 3px; /*match the list/tree view widgets*/ + border-top-right-radius: 3px; /*match the list/tree view widgets*/ +} +QHeaderView::section{ + background: %%HIGHLIGHTDISABLECOLOR%%; /*QLinearGradient(x1: 0, y1: 0, x2: 1, y2: 1, stop: 0 %%PRIMARYDISABLECOLOR%%, stop: 1 %%PRIMARYCOLOR%%);*/ + color: %%TEXTHIGHLIGHTCOLOR%%; + border-color: %%ACCENTCOLOR%%; + padding: 1px; + padding-left: 4px; +} +QHeaderView::section:hover{ + background: %%PRIMARYCOLOR%%; + border-color: %%ACCENTDISABLECOLOR%%; + color: %%TEXTCOLOR%%; +} + +/* SCROLLBARS (NOTE: Changing 1 subcontrol means you have to change all of them)*/ +QScrollBar{ + background: QLinearGradient(x1: 0, y1: 0, x2: 0, y2: 1, stop: 0 %%SECONDARYCOLOR%%, stop: 1 %%SECONDARYDISABLECOLOR%%); + /*border: 1px solid %%ACCENTCOLOR%%;*/ +} +QScrollBar:horizontal{ + margin: 0px 20px 0px 20px; +} +QScrollBar:vertical{ + margin: 20px 0px 20px 0px; +} +QScrollBar::sub-page, QScrollBar::add-page{ + background: %%BASECOLOR%%; + border: 1px solid %%ACCENTCOLOR%%; +} +QScrollBar::sub-page:vertical{ + border-bottom: none; +} +QScrollBar::add-page:vertical{ + border-top: none; +} +QScrollBar::sub-page:horizontal{ + border-right: none; +} +QScrollBar::add-page:horizontal{ + border-left: none; +} +QScrollBar::handle{ + background: QLinearGradient(x1: 0, y1: -0.3, x2: 0, y2: 1.3, stop: 0 %%BASECOLOR%%, stop: 0.5 %%SECONDARYCOLOR%%, stop: 1 %%BASECOLOR%%); + border: 1px solid %%ACCENTCOLOR%%; +} +QScrollBar::handle:hover, QScrollBar::add-line:hover, QScrollBar::sub-line:hover{ + background: %%HIGHLIGHTCOLOR%%; +} +QScrollBar::add-line{ + background: QLinearGradient(x1: 0, y1: 0, x2: 0, y2: 1, stop: 0 %%SECONDARYDISABLECOLOR%%, stop: 1 %%SECONDARYCOLOR%%); + border: 1px solid %%ACCENTCOLOR%%; + border-radius: 3px; +subcontrol-position: bottom right; +subcontrol-origin: margin; +} +QScrollBar::add-line:vertical, QScrollBar::sub-line:vertical{ +height: 20px; +} +QScrollBar::add-line:horizontal, QScrollBar::sub-line:horizontal{ +width: 20px; +} +QScrollBar::sub-line{ + background: QLinearGradient(x1: 0, y1: 0, x2: 0, y2: 1, stop: 0 %%SECONDARYCOLOR%%, stop: 1 %%SECONDARYDISABLECOLOR%%); + border: 1px solid %%ACCENTCOLOR%%; + border-radius: 3px; +subcontrol-position: top left; +subcontrol-origin: margin; +height: 20px; +} +/* SLIDERS */ +QSlider::groove:horizontal { +border: 1px solid %%ACCENTCOLOR%%; +background: %%ALTBASECOLOR%%; +height: 10px; +border-radius: 3px; +} +QSlider::groove:vertical { +border: 1px solid %%ACCENTCOLOR%%; +background: %%ALTBASECOLOR%%; +width: 10px; +border-radius: 3px; +} +QSlider::sub-page:horizontal { +background: qlineargradient(x1: 0, y1: 0, x2: 1, y2: 1, + stop: 0 %%HIGHLIGHTCOLOR%%, stop: 1 %%HIGHLIGHTDISABLECOLOR%%); +border: 1px solid %%ACCENTCOLOR%%; +height: 10px; +border-radius: 3px; +} +QSlider::sub-page:vertical { +background: qlineargradient(x1: 0, y1: 0, x2: 1, y2: 1, + stop: 0 %%HIGHLIGHTCOLOR%%, stop: 1 %%HIGHLIGHTDISABLECOLOR%%); +border: 1px solid %%ACCENTCOLOR%%; +width: 10px; +border-radius: 3px; +} +QSlider::add-page:horizontal{ +background: %%ALTBASECOLOR%%; +border: 1px solid %%ACCENTCOLOR%%; +height: 10px; +border-radius: 3px; +} +QSlider::add-page:vertical{ +background: %%ALTBASECOLOR%%; +border: 1px solid %%ACCENTCOLOR%%; +width: 10px; +border-radius: 3px; +} +QSlider::handle:horizontal{ +background: %%ALTBASECOLOR%%; +border: 1px solid %%ACCENTCOLOR%%; +width: 13px; +border-radius: 4px; +} +QSlider::handle:vertical{ +background: %%ALTBASECOLOR%%; +border: 1px solid %%ACCENTCOLOR%%; +height: 13px; +border-radius: 4px; +} +QSlider::handle:horizontal:hover, QSlider::handle:vertical:hover{ +border: 1px solid %%ACCENTDISABLECOLOR%%; +/*background: %%HIGHLIGHTCOLOR%%;*/ +} + +QSlider::sub-page:horizontal:disabled { +background: %%ACCENTDISABLECOLOR%%; +border-color: %%ACCENTCOLOR%%; +} + +QSlider::add-page:horizontal:disabled { +background: %%ACCENTDISABLECOLOR%%; +border-color: %%ACCENTCOLOR%%; +} + +QSlider::handle:horizontal:disabled { +background: %%ALTBASECOLOR%%; +border: 1px solid %%ACCENTCOLOR%%; +} + +/* BUTTONS */ +QPushButton{ + border: 1px solid %%ACCENTCOLOR%%; + border-radius: 3px; + background-color: QLinearGradient(x1: 0, y1: 0, x2: 1, y2: 1, stop: 0 %%SECONDARYDISABLECOLOR%%, stop: 1 %%SECONDARYCOLOR%%); + padding: 2px; + padding-right: 4px; + color: %%TEXTCOLOR%%; + } + +QToolButton{ /* Assume a flat button for every toolbutton by default*/ + color: %%TEXTCOLOR%%; + border: 1px solid transparent; + border-radius: 3px; + background-color: transparent; + padding: 1px; +} + + QPushButton:pressed, QPushButton:open, QPushButton:selected, QPushButton:checked, QPushButton:on, QToolButton:pressed, QToolButton:open, QToolButton:selected, QToolButton:checked, QToolButton:on{ + background-color: QLinearGradient(x1: 0, y1: 0, x2: 1, y2: 1, stop: 0 %%HIGHLIGHTDISABLECOLOR%%, stop: 1 %%HIGHLIGHTCOLOR%%); + margin-top: 2px; + } + +QPushButton:flat, QToolButton:flat{ + background-color: transparent; + border: 1px solid transparent; /* no border for a flat button */ +} + +QPushButton:hover, QToolButton:hover{ + border: 1px solid %%ACCENTCOLOR%%; + background-color: QLinearGradient(x1: 0, y1: 0, x2: 1, y2: 1, stop: 0 %%HIGHLIGHTDISABLECOLOR%%, stop: 1 %%HIGHLIGHTCOLOR%%); + color: %%TEXTHIGHLIGHTCOLOR%%; +} +QRadioButton, QCheckBox{ + padding: 2px; + border: 1px solid transparent; + border-radius: 3px; + color: %%TEXTCOLOR%%; +} +QRadioButton::hover, QCheckBox:hover{ + background: QLinearGradient(x1: 0, y1: 0, x2: 1, y2: 1, stop: 0 %%HIGHLIGHTDISABLECOLOR%%, stop: 1 %%HIGHLIGHTCOLOR%%); + border: 1px solid %%ACCENTCOLOR%%; + color: %%TEXTHIGHLIGHTCOLOR%%; +} +QRadioButton::indicator, QCheckBox::indicator, QGroupBox::indicator{ + border: 1px solid %%TEXTCOLOR%%; +} +QRadioButton::indicator{ + border-radius: 7px; +} +QRadioButton::indicator:checked{ + background: qradialgradient(spread:pad, cx:0.5, cy:0.5, radius:1, fx:0.5, fy:0.5, stop:0 %%TEXTCOLOR%%, stop:0.25 %%TEXTCOLOR%%, stop:0.25001 transparent); +} +QCheckBox::indicator:checked, QGroupBox::indicator:checked{ + padding: 1px; + background-origin: content; + background-clip: content; + background: %%TEXTCOLOR%%; +} +QCheckBox::indicator:indeterminate, QGroupBox::indicator:indeterminate{ + padding: 1px; + background-origin: content; + background-clip: content; + background: QLinearGradient(x1: 0, y1: 0, x2: 1, y2: 1, stop: 0.49 transparent, stop: 0.5 %%TEXTCOLOR%%); +} + +/* PROGRESSBAR */ +QProgressBar{ + background-color: %%ALTBASECOLOR%%; + border: 1px solid %%ACCENTCOLOR%%; + border-radius: 5px; + color: %%TEXTCOLOR%%; + text-align: center; + padding: 1px; +} + QProgressBar::chunk { + background-color: QLinearGradient(x1: 0, y1: 0, x2: 1, y2: 1, stop: 0 %%HIGHLIGHTCOLOR%%, stop: 1 %%HIGHLIGHTDISABLECOLOR%%); + /*border: 1px solid %%ACCENTDISABLECOLOR%%;*/ + border-radius: 5px; + } +QProgressBar::chunk:vertical{ + margin-left: 2px; + margin-right: 2px; +} +QProgressBar::chunk:horizontal{ + margin-top: 2px; + margin-bottom: 2px; +} + + /* SPINBOX */ +/*QAbstractSpinBox{ + background-color: %%ALTBASECOLOR%%; + border: 1px solid %%ACCENTCOLOR%%; + border-radius: 3px; +} +QAbstractSpinBox:disabled{ + color: %%ACCENTDISABLECOLOR%%; +}*/ +/*QAbstractSpinBox::down-button{ + subcontrol-origin: border; + subcontrol-position: left; + width: 16px; + border-width: 1px; +} +QAbstractSpinBox::up-button{ + subcontrol-origin: border; + subcontrol-position: right; + width: 16px; + border-width: 1px; +}*/ +/* +QAbstractSpinBox::down-arrow{ + border-image: url(":/trolltech/styles/commonstyle/images/left-16.png"); + width: 16px; + height: 16px; +} +QAbstractSpinBox::down-arrow:disabled, QAbstractSpinBox::up-arrow:disabled, QAbstractSpinBox::down-arrow:off, QAbstractSpinBox::up-arrow:off{ + border-image: url(:/none); +} +QAbstractSpinBox::up-arrow{ + border-image: url(":/trolltech/styles/commonstyle/images/right-16.png"); + width: 16px; + height: 16px; +}*/ diff --git a/src-qt5/core/themes/None.qss.template b/src-qt5/core/themes/None.qss.template new file mode 100644 index 00000000..7d923b1e --- /dev/null +++ b/src-qt5/core/themes/None.qss.template @@ -0,0 +1,118 @@ +/* This is a blank stylesheet to disable the Lumina Themes almost entirely*/ +QWidget{ + font-family: %%FONT%%; + font-size: %%FONTSIZE%%; +} +/* Set the panel appearance for this theme (unless manually customized) */ +QWidget#LuminaPanelColor{ + background: QLinearGradient(x1: 0, y1: 0, x2: 1, y2: 1, stop: 0 %%PRIMARYCOLOR%%, stop: 1 %%PRIMARYDISABLECOLOR%%); + border-radius: 5px; +} +QWidget#LuminaBootSplash{ + background: %%BASECOLOR%%; + border-radius: 5px; +} + +/* Set the default canvas appearance for Lumina desktop plugins*/ +/* Default to a non-transparent background for all desktop plugins*/ +LDPlugin{ + background: %%BASECOLOR%%; + border-radius: 5px; +} +/* Now specify which plugins should have a transparent background */ +LDPlugin#applauncher, LDPlugin#desktopview{ + background: transparent; + border-radius: 5px; +} + +LDPlugin#applauncher QToolButton{ +background: transparent; + border: none; + border-radius: 5px; + color: white; +} +LDPlugin#applauncher QToolButton:hover{ + background: %%PRIMARYDISABLECOLOR%%; + border: none; + border-radius: 5px; + color: %%TEXTHIGHLIGHTCOLOR%%; +} + +LDPlugin#desktopview QListWidget{ + background: transparent; + border: 1px solid transparent; +} +LDPlugin#desktopview QListWidget::item{ + background: qlineargradient(x1: 0, y1: 0, x2: 0, y2: 1, + stop: 0 transparent, + stop: 0.7 transparent, + stop: 1.0 %%PRIMARYDISABLECOLOR%%); + border-radius: 5px; + color: %%TEXTCOLOR%%; +} + +LDPlugin#desktopview QListWidget::item:hover{ + background: %%PRIMARYDISABLECOLOR%%; + border-radius: 5px; + color: %%TEXTHIGHLIGHTCOLOR%%; +} +/*For the special widgets on the user button*/ +UserItemWidget, ItemWidget{ + background: transparent; + border-radius: 3px; +} +UserItemWidget:hover, ItemWidget:hover{ + background: %%HIGHLIGHTCOLOR%%; + color: %%TEXTHIGHLIGHTCOLOR%%; +} + +/*Special taskmanager window buttons: based on window state*/ +LTBWidget{ + border: 1px solid transparent; + border-radius: 3px; +} +LTBWidget::menu-indicator{ image: none; } /*disable the menu arrow*/ +LTBWidget#WindowVisible{ + background: QLinearGradient(x1: 0, y1: 0, x2: 1, y2: 1.1, stop: 0.3 %%SECONDARYCOLOR%%, stop: 1 transparent); +} +LTBWidget#WindowInvisible{ + /* Primary color is used for the panel appearance, so use that to make it disappear*/ + background: transparent; +} +LTBWidget#WindowActive{ + background: QLinearGradient(x1: 0, y1: 0, x2: 1, y2: 1.1, stop: 0.3 %%HIGHLIGHTDISABLECOLOR%%, stop: 1 transparent); +} +LTBWidget#WindowAttention{ + background: QLinearGradient(x1: 0, y1: 0, x2: 1, y2: 1.1, stop: 0.3 %%HIGHLIGHTCOLOR%%, stop: 1 transparent); +} +LTBWidget:hover, LTBWidget#WindowVisible:hover, LTBWidget#WindowInvisible:hover, LTBWidget#WindowActive:hover, LTBWidget#WindowAttention:hover{ + background: %%HIGHLIGHTCOLOR%%; + color: %%TEXTHIGHLIGHTCOLOR%%; + border: 1px solid %%ACCENTCOLOR%%; +} + +/* CALENDER WIDGET */ + /* (This is a special hack since there is no official support for stylesheets for this widget) */ + QCalendarWidget QWidget#qt_calendar_navigationbar{ + background-color: %%ALTBASECOLOR%%; + } +QCalendarWidget QWidget{ + background-color: %%BASECOLOR%%; + alternate-background-color: %%HIGHLIGHTDISABLECOLOR%%; + color: %%TEXTCOLOR%%; +} +QCalendarWidget QAbstractButton{ + background-color: transparent; +} +QCalendarWidget QAbstractButton::menu-indicator{ + image: none; +} +QCalendarWidget QAbstractItemView{ + background-color: %%SECONDARYCOLOR%%; + selection-background-color: QLinearGradient(x1: 0, y1: 0, x2: 0, y2: 1, stop: 0 %%HIGHLIGHTDISABLECOLOR%%, stop: 1 %%HIGHLIGHTCOLOR%%);; + selection-color: %%TEXTHIGHLIGHTCOLOR%%; +} +QCalendarWidget QWidget#qt_calendar_calendarview{ + background-color: %%ALTBASECOLOR%%; + border: none; +} \ No newline at end of file diff --git a/src-qt5/core/xtrafiles/globs2 b/src-qt5/core/xtrafiles/globs2 new file mode 100644 index 00000000..0a783316 --- /dev/null +++ b/src-qt5/core/xtrafiles/globs2 @@ -0,0 +1,991 @@ +# Fallback "globs2" file from the FreeDesktop mimetype database (9/23/16) +# This is only used if the official database cannot be found on the system +80:application/x-cd-image:*.iso +80:application/x-doom-wad:*.wad +50:text/x-vala:*.vala +50:application/x-nes-rom:*.nez +50:audio/ac3:*.ac3 +50:application/x-mswrite:*.wri +50:application/smil+xml:*.smil +50:text/x-verilog:*.v +50:application/x-qpress:*.qp +50:image/x-exr:*.exr +50:application/x-compress:*.z +50:image/x-jng:*.jng +50:application/oda:*.oda +50:application/vnd.oasis.opendocument.database:*.odb +50:application/vnd.sun.xml.base:*.odb +50:application/vnd.oasis.opendocument.chart:*.odc +50:text/vtt:*.vtt +50:application/x-xz-compressed-tar:*.txz +50:application/vnd.oasis.opendocument.formula:*.odf +50:application/vnd.oasis.opendocument.formula:*.odf +50:application/vnd.oasis.opendocument.graphics:*.odg +50:application/vnd.oasis.opendocument.graphics:*.odg +50:text/x-ldif:*.ldif +50:application/vnd.oasis.opendocument.image:*.odi +50:image/jp2:*.jp2 +50:application/x-oleo:*.oleo +50:application/oxps:*.xps +50:application/vnd.oasis.opendocument.text-master:*.odm +50:application/vnd.oasis.opendocument.text-master:*.odm +50:application/x-ruby:*.rb +50:audio/vnd.rn-realaudio:*.ra +50:application/x-mimearchive:*.mht +50:application/vnd.oasis.opendocument.presentation:*.odp +50:application/vnd.oasis.opendocument.presentation:*.odp +50:application/x-raw-disk-image-xz-compressed:*.raw-disk-image.xz +50:application/vnd.oasis.opendocument.spreadsheet:*.ods +50:application/vnd.oasis.opendocument.spreadsheet:*.ods +50:application/vnd.oasis.opendocument.text:*.odt +50:application/vnd.oasis.opendocument.text:*.odt +50:image/x-portable-bitmap:*.pbm +50:application/x-egon:*.egon +50:application/x-font-pcf:*.pcf.z +50:application/x-xliff:*.xliff +50:application/vnd.rn-realmedia:*.rm +50:application/x-abiword:*.abw +50:image/vnd.rn-realpix:*.rp +50:image/x-sigma-x3f:*.x3f +50:video/webm:*.webm +50:text/rust:*.rs +50:text/vnd.rn-realtext:*.rt +50:image/webp:*.webp +50:application/x-cpio:*.cpio +50:audio/midi:*.mid +50:application/x-mif:*.mif +50:video/vnd.rn-realvideo:*.rv +50:application/vnd.google-earth.kml+xml:*.kml +50:image/x-3ds:*.3ds +50:image/x-photo-cd:*.pcd +50:application/x-pc-engine-rom:*.pce +50:application/x-font-pcf:*.pcf +50:application/x-cisco-vpn-settings:*.pcf +50:model/vrml:*.wrl +50:text/x-fortran:*.f95 +50:text/plain:*.txt +50:image/x-xpixmap:*.xpm +50:application/vnd.hp-pcl:*.pcl +50:application/x-trash:*.bak +50:application/vnd.openxmlformats-officedocument.presentationml.template:*.potx +50:application/vnd.openxmlformats-officedocument.presentationml.template:*.potx +50:application/x-sms-rom:*.sg +50:application/x-shellscript:*.sh +50:model/vrml:*.vrml +50:text/vcard:*.vcard +50:image/x-skencil:*.sk +50:image/x-pict:*.pct +50:video/3gpp2:*.3g2 +50:text/x-vala:*.vapi +50:application/x-sharedlib:*.so +50:application/x-tzo:*.tzo +50:video/x-javafx:*.fxm +50:image/jpeg:*.jpe +50:audio/x-aifc:*.aifc +50:application/x-lzma-compressed-tar:*.tar.lzma +50:x-epoc/x-sisx-app:*.sisx +50:audio/x-aiff:*.aiff +50:audio/x-aifc:*.aiffc +50:image/jp2:*.jpf +50:application/x-hdf:*.hdf4 +50:application/x-hdf:*.hdf5 +50:application/x-aportisdoc:*.pdb +50:application/vnd.palm:*.pdb +50:application/x-aportisdoc:*.pdc +50:application/x-profile:gmon.out +50:application/x-jbuilder-project:*.jpr +50:application/pdf:*.pdf +50:application/x-bzpdf:*.pdf.bz2 +50:application/x-theme:*.theme +50:image/jpeg:*.jpg +50:application/x-raw-disk-image-xz-compressed:*.img.xz +50:application/x-jbuilder-project:*.jpx +50:image/jp2:*.jpx +50:text/x-svsrc:*.sv +50:image/x-quicktime:*.qtif +50:image/x-kodak-k25:*.k25 +50:text/x-scheme:*.ss +50:application/vnd.openxmlformats-officedocument.presentationml.presentation:*.pptx +50:application/vnd.openxmlformats-officedocument.presentationml.presentation:*.pptx +50:application/x-ace:*.ace +50:image/vnd.zbrush.pcx:*.pcx +50:text/x-adasrc:*.ads +50:text/x-tcl:*.tk +50:text/x-changelog:changelog +50:audio/flac:*.flac +50:text/x-adasrc:*.adb +50:text/html:*.htm +50:text/x-google-video-pointer:*.gvp +50:text/troff:*.tr +50:audio/x-matroska:*.mka +50:text/vnd.trolltech.linguist:*.ts +50:video/mp2t:*.ts +50:application/x-cb7:*.cb7 +50:text/x-vhdl:*.vhdl +50:audio/ogg:*.oga +50:audio/x-vorbis+ogg:*.oga +50:audio/x-flac+ogg:*.oga +50:audio/x-speex+ogg:*.oga +50:application/xslt+xml:*.xsl +50:application/x-saturn-rom:*.iso +50:application/x-wii-rom:*.iso +50:application/x-gamecube-rom:*.iso +50:application/atom+xml:*.atom +50:video/3gpp:*.3ga +50:application/x-kontour:*.kon +50:audio/ogg:*.ogg +50:video/ogg:*.ogg +50:audio/x-vorbis+ogg:*.ogg +50:audio/x-flac+ogg:*.ogg +50:audio/x-speex+ogg:*.ogg +50:video/x-theora+ogg:*.ogg +50:image/x-pentax-pef:*.pef +50:application/vnd.ms-cab-compressed:*.cab +50:text/markdown:*.mkd +50:application/rdf+xml:*.rdfs +50:application/x-zoo:*.zoo +50:video/x-ogm+ogg:*.ogm +50:text/x-rpm-spec:*.spec +50:application/x-x509-ca-cert:*.pem +50:video/3gpp2:*.3gp2 +50:application/x-xpinstall:*.xpi +50:video/x-matroska:*.mkv +50:application/ram:*.ram +50:application/x-designer:*.ui +50:application/x-gtk-builder:*.ui +50:audio/x-wavpack-correction:*.wvc +50:video/ogg:*.ogv +50:application/vnd.tcpdump.pcap:*.cap +50:application/ogg:*.ogx +50:application/x-rar:*.rar +50:application/x-xbel:*.xbel +50:application/jrd+json:*.jrd +50:application/vnd.ms-tnef:*.tnef +50:image/x-panasonic-raw:*.raw +50:video/3gpp:*.3gp +50:audio/vnd.rn-realaudio:*.rax +50:text/x-python:*.wsgi +50:application/x-7z-compressed:*.7z +50:audio/x-wavpack:*.wvp +50:image/x-cmu-raster:*.ras +50:application/x-font-type1:*.pfa +50:application/x-font-type1:*.pfb +50:application/x-kpovmodeler:*.kpm +50:text/x-ocaml:*.mli +50:image/x-fuji-raf:*.raf +50:application/ld+json:*.jsonld +50:audio/x-ms-asx:*.wvx +50:application/x-kpresenter:*.kpr +50:application/x-font-bdf:*.bdf +50:application/x-cd-image:*.iso9660 +50:application/x-kpresenter:*.kpt +50:text/x-eiffel:*.e +50:application/x-font-afm:*.afm +50:text/x-nfo:*.nfo +50:image/x-compressed-xcf:*.xcf.bz2 +50:text/x-cobol:*.cbl +50:video/mp2t:*.bdm +50:video/quicktime:*.moov +50:text/x-texinfo:*.texi +50:application/x-wwf:*.wwf +50:application/x-cbr:*.cbr +50:application/pkcs12:*.pfx +50:application/metalink+xml:*.metalink +50:application/x-cbt:*.cbt +50:video/mpeg:[0-9][0-9][0-9].vdr +50:application/x-perl:*.perl +50:application/vnd.mozilla.xul+xml:*.xul +50:application/x-cbz:*.cbz +50:text/x-log:*.log +50:application/x-smaf:*.mmf +50:application/javascript:*.jsm +50:text/x-meson:meson_options.txt +50:application/x-gba-rom:*.agb +50:application/x-hwt:*.hwt +50:text/x-iptables:*.iptables +50:application/mathml+xml:*.mml +50:application/oxps:*.oxps +50:video/mp2t:*.bdmv +50:video/3gpp:*.3gpp +50:application/x-docbook+xml:*.docbook +50:audio/x-mod:*.m15 +50:application/x-chess-pgn:*.pgn +50:audio/x-mo3:*.mo3 +50:application/x-bcpio:*.bcpio +50:application/pgp-encrypted:*.pgp +50:application/pgp-keys:*.pgp +50:application/pgp-signature:*.pgp +50:application/x-bzip-compressed-tar:*.tar.bz +50:application/x-amipro:*.sam +50:application/vnd.google-earth.kmz:*.kmz +50:video/quicktime:*.qt +50:image/x-portable-graymap:*.pgm +50:application/x-krita:*.kra +50:application/x-dar:*.dar +50:application/vnd.wordperfect:*.wp +50:image/vnd.wap.wbmp:*.wbmp +50:application/x-spss-sav:*.sav +50:text/x-scons:sconstruct +50:video/x-msvideo:*.divx +50:audio/x-wavpack:*.wv +50:application/xhtml+xml:*.xhtml +50:video/x-mng:*.mng +50:text/x-uuencode:*.uue +50:image/x-pict:*.pict1 +50:image/x-pict:*.pict2 +50:image/x-bzeps:*.eps.bz2 +50:application/x-n64-rom:*.z64 +50:audio/x-musepack:*.mp+ +50:text/x-c++hdr:*.hxx +50:application/rdf+xml:*.rdf +50:application/x-netcdf:*.cdf +50:application/vnd.rn-realmedia:*.rmvb +50:application/x-dbf:*.dbf +50:audio/mp2:*.mp2 +50:video/mpeg:*.mp2 +50:application/vnd.lotus-1-2-3:*.123 +50:application/x-php:*.php +50:application/x-font-pcf:*.pcf.gz +50:audio/mpeg:*.mp3 +50:video/mp4:*.mp4 +50:text/x-python:*.py +50:audio/x-minipsf:*.minipsf +50:audio/x-xm:*.xm +50:application/vnd.corel-draw:*.cdr +50:audio/x-xi:*.xi +50:image/x-xwindowdump:*.xwd +50:application/x-desktop:*.desktop +50:application/x-bzip-compressed-tar:*.tb2 +50:text/x-tex:*.latex +50:text/x-moc:*.moc +50:audio/x-mod:*.mod +50:application/vnd.openxmlformats-officedocument.presentationml.slideshow:*.ppsx +50:application/x-docbook+xml:*.dbk +50:text/x-mof:*.mof +50:application/x-xz:*.xz +50:application/vnd.ms-excel.sheet.binary.macroEnabled.12:*.xlsb +50:application/vnd.ms-excel.sheet.binary.macroenabled.12:*.xlsb +50:application/x-kspread:*.ksp +50:audio/x-aiff:*.aif +50:text/markdown:*.markdown +50:text/vcard:*.gcrd +50:application/x-php:*.php3 +50:application/x-php:*.php4 +50:application/x-php:*.php5 +50:text/x-reject:*.rej +50:application/vnd.ms-excel.sheet.macroEnabled.12:*.xlsm +50:application/vnd.ms-excel.sheet.macroenabled.12:*.xlsm +50:video/mp2t:*.m2ts +50:text/x-ms-regedit:*.reg +50:application/vnd.openxmlformats-officedocument.wordprocessingml.document:*.docx +50:application/vnd.openxmlformats-officedocument.wordprocessingml.document:*.docx +50:text/x-dcl:*.dcl +50:application/dicom:*.dcm +50:video/vnd.mpegurl:*.m1u +50:text/x-scheme:*.scm +50:application/x-qtiplot:*.qti.gz +50:application/pkix-cert:*.cer +50:image/x-kodak-dcr:*.dcr +50:application/x-tar:*.tar +50:text/x-patch:*.patch +50:text/x-scala:*.scala +50:image/vnd.djvu:*.djvu +50:audio/x-musepack:*.mpc +50:video/quicktime:*.mov +50:video/mpeg:*.mpe +50:application/x-tarz:*.taz +50:application/x-trash:*.old +50:video/mpeg:*.mpg +50:video/mp2t:*.mpl +50:application/vnd.stardivision.draw:*.sda +50:application/vnd.stardivision.calc:*.sdc +50:text/x-mrml:*.mrml +50:application/vnd.stardivision.impress:*.sdd +50:audio/x-musepack:*.mpp +50:application/vnd.ms-excel.template.macroEnabled.12:*.xltm +50:application/vnd.ms-excel.template.macroenabled.12:*.xltm +50:video/mp4:*.lrv +50:video/mp2t:*.m2t +50:image/x-gzeps:*.epsf.gz +50:application/x-lrzip:*.lrz +50:video/3gpp2:*.3gpp2 +50:image/jpeg:*.jpeg +50:application/mbox:*.mbox +50:application/vnd.stardivision.impress:*.sdp +50:application/sdp:*.sdp +50:audio/x-mpegurl:*.m3u8 +50:application/vnd.apple.mpegurl:*.m3u8 +50:application/vnd.stardivision.chart:*.sds +50:image/x-dds:*.dds +50:application/x-kugar:*.kud +50:application/vnd.openxmlformats-officedocument.spreadsheetml.sheet:*.xlsx +50:application/vnd.openxmlformats-officedocument.spreadsheetml.sheet:*.xlsx +50:application/vnd.stardivision.writer:*.sdw +50:application/x-fictionbook+xml:*.fb2 +50:application/x-xzpdf:*.pdf.xz +50:text/x-copying:copying +50:application/x-bzip-compressed-tar:*.tbz +50:application/zlib:*.zz +50:application/x-lrzip-compressed-tar:*.tar.lrz +50:text/x-bibtex:*.bib +50:image/x-rgb:*.rgb +50:application/x-gzpostscript:*.ps.gz +50:application/x-gameboy-rom:*.cgb +50:application/x-php:*.phps +50:application/vnd.debian.binary-package:*.deb +50:application/x-qw:*.qif +50:image/x-quicktime:*.qif +50:audio/x-mpegurl:*.m3u +50:application/vnd.apple.mpegurl:*.m3u +50:application/vnd.openxmlformats-officedocument.spreadsheetml.template:*.xltx +50:application/vnd.openxmlformats-officedocument.spreadsheetml.template:*.xltx +50:text/x-c++src:*.c++ +50:application/x-ccmx:*.ccmx +50:application/vnd.coffeescript:*.coffee +50:application/octet-stream:*.bin +50:application/x-saturn-rom:*.bin +50:application/smil+xml:*.kino +50:application/pgp-keys:*.pkr +50:application/vnd.ms-visio.stencil.macroEnabled.main+xml:*.vssm +50:image/cgm:*.cgm +50:text/x-mup:*.not +50:text/x-tcl:*.tcl +50:audio/mp4:*.m4a +50:application/x-x509-ca-cert:*.der +50:audio/x-m4b:*.m4b +50:application/x-pagemaker:*.pm6 +50:text/x-meson:meson.build +50:application/x-sami:*.sami +50:application/vnd.ms-visio.stencil.main+xml:*.vssx +50:audio/x-iriver-pla:*.pla +50:text/x-mrml:*.mrl +50:application/vnd.nintendo.snes.rom:*.sfc +50:application/xml:*.xsd +50:video/mp4:*.m4v +50:video/mp2t:*.mpls +50:application/x-planperfect:*.pln +50:text/x-tex:*.ltx +50:image/x-minolta-mrw:*.mrw +50:application/metalink4+xml:*.meta4 +50:application/vnd.ms-powerpoint.addin.macroEnabled.12:*.ppam +50:application/vnd.ms-visio.template.macroEnabled.main+xml:*.vstm +50:application/x-compressed-tar:*.tar.gz +50:audio/x-scpls:*.pls +50:application/vnd.ms-htmlhelp:*.chm +50:application/x-hwp:*.hwp +50:application/x-abiword:*.abw.gz +50:application/x-alz:*.alz +50:application/x-kword:*.kwd +50:text/x-lua:*.lua +50:application/vnd.ms-visio.template.main+xml:*.vstx +50:video/vnd.mpegurl:*.m4u +50:text/x-ooc:*.ooc +50:application/x-msi:*.msi +50:application/x-kexiproject-sqlite2:*.kexi +50:application/x-kexiproject-sqlite3:*.kexi +50:video/x-anim:*.anim[1-9j] +50:application/x-pagemaker:*.pmd +50:application/x-abiword:*.zabw +50:application/x-gameboy-rom:*.sgb +50:application/x-kword:*.kwt +50:application/x-go-sgf:*.sgf +50:application/pkcs10:*.p10 +50:image/x-sgi:*.sgi +50:application/pkcs12:*.p12 +50:application/x-blender:*.blender +50:application/vnd.stardivision.writer:*.sgl +50:application/x-msx-rom:*.msx +50:application/x-dia-shape:*.shape +50:application/x-blender:*.blend +50:application/x-blender:*.blend +50:application/x-mimearchive:*.mhtml +50:audio/midi:*.midi +50:application/x-java-jnlp-file:*.jnlp +50:text/x-cmake:cmakelists.txt +50:audio/x-amzxml:*.amz +50:image/x-tga:*.tpic +50:audio/AMR:*.amr +50:text/x-makefile:makefile +50:text/x-scons:sconscript.* +50:text/x-tex:*.tex +50:application/vnd.oasis.opendocument.graphics-flat-xml:*.fodg +50:application/vnd.oasis.opendocument.graphics-flat-xml:*.fodg +50:text/sgml:*.sgm +50:application/x-amiga-disk-format:*.adf +50:image/x-msod:*.msod +50:audio/x-mod:*.mtm +50:image/png:*.png +50:application/vnd.oasis.opendocument.presentation-flat-xml:*.fodp +50:application/vnd.oasis.opendocument.presentation-flat-xml:*.fodp +50:application/x-navi-animation:*.ani +50:application/vnd.oasis.opendocument.spreadsheet-flat-xml:*.fods +50:application/vnd.oasis.opendocument.spreadsheet-flat-xml:*.fods +50:application/vnd.oasis.opendocument.text-flat-xml:*.fodt +50:application/vnd.oasis.opendocument.text-flat-xml:*.fodt +50:application/x-n64-rom:*.n64 +50:application/x-ustar:*.ustar +50:application/x-gameboy-rom:*.gbc +50:application/x-gba-rom:*.gba +50:application/x-java-pack200:*.pack +50:application/dicom:dicomdir +50:application/x-shar:*.shar +50:application/x-shorten:*.shn +50:application/x-genesis-rom:*.32x +50:image/x-portable-anymap:*.pnm +50:application/x-gzdvi:*.dvi.gz +50:application/annodex:*.anx +50:text/html:*.html +50:video/mp2t:*.mts +50:text/x-authors:authors +50:text/x-install:install +50:application/x-quattropro:*.wb1 +50:application/x-quattropro:*.wb2 +50:application/x-quattropro:*.wb3 +50:application/x-gnucash:*.gnucash +50:application/x-perl:*.pod +50:application/x-source-rpm:*.src.rpm +50:image/x-lwo:*.lwo +50:application/x-dia-diagram:*.dia +50:application/vnd.lotus-wordpro:*.lwp +50:application/x-lrzip-compressed-tar:*.tlrz +50:application/x-partial-download:*.wkdownload +50:application/x-glade:*.glade +50:application/pgp-signature:*.sig +50:text/x-qml:*.qml +50:image/x-tga:*.tga +50:audio/prs.sid:*.sid +50:application/x-trash:*.sik +50:application/x-spss-por:*.por +50:application/x-wii-wad:*.wad +50:application/vnd.ms-powerpoint:*.pot +50:text/x-gettext-translation-template:*.pot +50:image/x-lws:*.lws +50:application/x-zip-compressed-fb2:*.fb2.zip +50:text/vcard:*.vcf +50:application/vnd.symbian.install:*.sis +50:application/x-stuffit:*.sit +50:application/x-e-theme:*.etheme +50:application/sieve:*.siv +50:image/bmp:*.bmp +50:application/x-nes-rom:*.unif +50:image/x-skencil:*.sk1 +50:image/openraster:*.ora +50:text/vcard:*.vct +50:application/x-compressed-tar:*.tgz +50:application/x-netshow-channel:*.nsc +50:audio/x-wav:*.wav +50:image/x-olympus-orf:*.orf +50:audio/x-ms-asx:*.wax +50:audio/x-ape:*.ape +50:image/x-lwo:*.lwob +50:text/calendar:*.vcs +50:image/rle:*.rle +50:application/x-siag:*.siag +50:application/vnd.android.package-archive:*.apk +50:image/x-portable-pixmap:*.ppm +50:application/x-lz4:*.lz4 +50:image/x-applix-graphics:*.ag +50:application/illustrator:*.ai +50:application/vnd.ms-powerpoint:*.pps +50:application/vnd.ms-powerpoint:*.ppt +50:application/vnd.ms-powerpoint:*.ppt +50:video/x-nsv:*.nsv +50:application/x-perl:*.al +50:image/x-tga:*.vda +50:text/x-tex:*.cls +50:application/x-archive:*.ar +50:application/vnd.ms-powerpoint:*.ppz +50:application/x-applix-spreadsheet:*.as +50:application/vnd.tcpdump.pcap:*.pcap +50:audio/basic:*.au +50:application/x-applix-word:*.aw +50:image/vnd.djvu:*.djv +50:application/vnd.palm:*.pqa +50:application/xslt+xml:*.xslt +50:application/x-bittorrent:*.torrent +50:image/x-bzeps:*.epsi.bz2 +50:video/quicktime:*.qtvr +50:text/x-mup:*.mup +50:application/x-t602:*.602 +50:application/vnd.rn-realmedia:*.rmj +50:image/tiff:*.tif +50:application/x-lyx:*.lyx +50:application/x-gedcom:*.ged +50:application/vnd.rn-realmedia:*.rmm +50:application/x-gnucash:*.xac +50:text/x-eiffel:*.eif +50:application/x-sv4cpio:*.sv4cpio +50:application/vnd.rn-realmedia:*.rms +50:application/pgp-keys:*.skr +50:application/x-tar:*.gem +50:application/x-genesis-rom:*.gen +50:application/vnd.ms-works:*.wcm +50:application/x-yaml:*.yaml +50:application/vnd.ms-word.template.macroEnabled.12:*.dotm +50:application/vnd.ms-word.template.macroenabled.12:*.dotm +50:application/x-lha:*.lzh +50:application/mxf:*.mxf +50:application/vnd.oasis.opendocument.chart-template:*.otc +50:application/x-mobipocket-ebook:*.prc +50:application/vnd.palm:*.prc +50:application/vnd.oasis.opendocument.formula-template:*.otf +50:application/x-font-otf:*.otf +50:application/vnd.oasis.opendocument.graphics-template:*.otg +50:application/vnd.oasis.opendocument.graphics-template:*.otg +50:application/vnd.oasis.opendocument.text-web:*.oth +50:application/vnd.oasis.opendocument.text-web:*.oth +50:application/relax-ng-compact-syntax:*.rnc +50:application/x-lzop:*.lzo +50:text/x-makefile:gnumakefile +50:application/x-bzip:*.bz +50:application/x-arj:*.arj +50:application/x-spss-sav:*.zsav +50:text/x-c++src:*.cc +50:application/vnd.oasis.opendocument.presentation-template:*.otp +50:application/vnd.oasis.opendocument.presentation-template:*.otp +50:image/fits:*.fits +50:application/vnd.ms-works:*.wdb +50:application/vnd.oasis.opendocument.spreadsheet-template:*.ots +50:application/vnd.oasis.opendocument.spreadsheet-template:*.ots +50:application/vnd.oasis.opendocument.text-template:*.ott +50:application/vnd.oasis.opendocument.text-template:*.ott +50:application/x-partial-download:*.crdownload +50:application/x-tzo:*.tar.lzo +50:application/x-hdf:*.hdf +50:application/x-tarz:*.tar.z +50:application/vnd.rn-realmedia:*.rmx +50:image/x-sony-arw:*.arw +50:image/svg+xml-compressed:*.svgz +50:text/x-csharp:*.cs +50:text/spreadsheet:*.slk +50:image/x-icns:*.icns +50:image/x-xbitmap:*.xbm +50:video/vnd.mpegurl:*.mxu +50:application/xml:*.xbl +50:application/xml:*.rng +50:application/x-pagemaker:*.p65 +50:text/x-opml+xml:*.opml +50:text/plain:*.asc +50:image/vnd.adobe.photoshop:*.psd +50:application/x-font-linux-psf:*.psf +50:audio/x-psf:*.psf +50:text/x-cobol:*.cob +50:application/vnd.ms-asf:*.asf +50:application/vnd.nintendo.snes.rom:*.smc +50:application/vnd.stardivision.mail:*.smd +50:application/x-genesis-rom:*.smd +50:application/x-dc-rom:*.dc +50:application/vnd.stardivision.math:*.smf +50:application/x-apple-diskimage:*.dmg +50:application/smil+xml:*.smi +50:application/x-sami:*.smi +50:text/x-dsrc:*.di +50:application/x-asp:*.asp +50:application/x-gedcom:*.gedcom +50:application/smil+xml:*.sml +50:text/x-ssa:*.ass +50:image/x-xfig:*.fig +50:image/x-tga:*.icb +50:application/vnd.tcpdump.pcap:*.dmp +50:application/x-pocket-word:*.psw +50:application/x-sms-rom:*.sms +50:audio/x-ms-asx:*.asx +50:image/x-xcf:*.xcf +50:text/vnd.sun.j2me.app-descriptor:*.jad +50:video/dv:*.dv +50:application/vnd.openxmlformats-officedocument.wordprocessingml.template:*.dotx +50:application/vnd.openxmlformats-officedocument.wordprocessingml.template:*.dotx +50:image/vnd.microsoft.icon:*.ico +50:application/x-ica:*.ica +50:application/vnd.iccprofile:*.icc +50:text/calendar:*.ics +50:application/x-java-archive:*.jar +50:application/x-gnumeric:*.gnumeric +50:application/vnd.iccprofile:*.icm +50:application/x-sv4crc:*.sv4crc +50:audio/basic:*.snd +50:application/x-lzma:*.lzma +50:application/x-x509-ca-cert:*.cert +50:image/x-adobe-dng:*.dng +50:video/mp2t:*.cpi +50:text/x-vhdl:*.vhd +50:application/x-rpm:*.rpm +50:application/x-bzpostscript:*.ps.bz2 +50:text/x-emacs-lisp:*.el +50:application/xspf+xml:*.xspf +50:text/x-c++src:*.cpp +50:application/vnd.oasis.opendocument.text-master-template:*.otm +50:image/x-canon-cr2:*.cr2 +50:application/x-gnuplot:*.gnuplot +50:application/ecmascript:*.es +50:image/fax-g3:*.g3 +50:text/x-idl:*.idl +50:application/x-pkcs7-certificates:*.p7b +50:application/pkcs7-mime:*.p7c +50:application/andrew-inset:*.ez +50:application/x-desktop:*.kdelnk +50:application/x-lzma-compressed-tar:*.tlz +50:application/vnd.ms-publisher:*.pub +50:text/x-xslfo:*.xslfo +50:application/x-core:core:cs +50:application/x-core:core +50:application/x-trig:*.trig +50:application/pkcs7-mime:*.p7m +50:application/msword:*.doc +50:application/msword:*.doc +50:application/vnd.ms-word:*.doc +50:application/rdf+xml:*.owl +50:text/cache-manifest:*.manifest +50:application/pkcs7-signature:*.p7s +50:image/x-emf:*.emf +50:application/x-fluid:*.fl +50:image/gif:*.gif +50:message/rfc822:*.eml +50:application/owl+xml:*.owx +50:image/ief:*.ief +50:text/x-c++hdr:*.h++ +50:text/x-xslfo:*.fo +50:application/vnd.emusic-emusic_package:*.emp +50:application/msword-template:*.dot +50:text/vnd.graphviz:*.dot +50:application/x-hdf:*.h4 +50:application/x-hdf:*.h5 +50:application/x-nzb:*.nzb +50:text/x-uil:*.uil +50:video/vnd.vivo:*.viv +50:application/vnd.debian.binary-package:*.udeb +50:audio/midi:*.kar +50:video/x-msvideo:*.avf +50:text/csv-schema:*.csvs +50:application/x-pkcs7-certificates:*.spc +50:application/x-font-speedo:*.spd +50:application/x-qtiplot:*.qti +50:application/vnd.ms-excel.addin.macroEnabled.12:*.xlam +50:application/x-tex-gf:*.gf +50:application/vnd.ms-tnef:*.tnf +50:application/x-quicktime-media-link:*.qtl +50:text/x-patch:*.diff +50:application/pkix-crl:*.crl +50:application/vnd.openofficeorg.extension:*.oxt +50:application/vnd.openofficeorg.extension:*.oxt +50:application/x-source-rpm:*.spm +50:application/x-sms-rom:*.gg +50:application/vnd.adobe.flash.movie:*.spl +50:application/x-bzdvi:*.dvi.bz2 +50:application/x-gnuplot:*.gp +50:application/x-gameboy-rom:*.gb +50:application/x-x509-ca-cert:*.crt +50:image/x-sony-sr2:*.sr2 +50:application/x-gz-font-linux-psf:*.psf.gz +50:image/x-canon-crw:*.crw +50:image/x-ilbm:*.iff +50:audio/x-speex:*.spx +50:audio/x-mod:*.ult +50:audio/x-mod:*.669 +50:video/x-flv:*.flv +50:application/x-kivio:*.flw +50:text/vnd.graphviz:*.gv +50:application/gzip:*.gz +50:application/pkix-pkipath:*.pkipath +50:application/vnd.palm:*.oprc +50:audio/AMR-WB:*.awb +50:text/x-genie:*.gs:cs +50:text/x-genie:*.gs +50:video/x-flic:*.flc +50:text/x-go:*.go +50:application/x-cdrdao-toc:*.toc +50:application/x-awk:*.awk +50:application/x-csh:*.csh +50:audio/x-s3m:*.s3m +50:text/x-c++hdr:*.hh +50:application/xml-external-parsed-entity:*.ent +50:application/sql:*.sql +50:image/x-gzeps:*.eps.gz +50:text/x-texinfo:*.texinfo +50:video/x-msvideo:*.avi +50:application/rss+xml:*.rss +50:application/x-ufraw:*.ufraw +50:text/css:*.css +50:text/x-c++hdr:*.hp +50:application/x-ms-wim:*.wim +50:text/csv:*.csv +50:text/x-haskell:*.hs +50:application/x-mobipocket-ebook:*.mobi +50:application/vnd.lotus-1-2-3:*.wk1 +50:audio/annodex:*.axa +50:application/vnd.lotus-1-2-3:*.wk3 +50:application/vnd.lotus-1-2-3:*.wk4 +50:application/x-wais-source:*.src +50:application/rtf:*.rtf +50:image/x-sony-srf:*.srf +50:image/x-ilbm:*.ilbm +50:audio/x-mpegurl:*.vlc +50:application/x-nes-rom:*.unf +50:application/x-smaf:*.smaf +50:audio/x-mod:*.uni +50:video/x-flic:*.fli +50:text/sgml:*.sgml +50:video/annodex:*.axv +50:image/x-kodak-kdc:*.kdc +50:text/x-txt2tags:*.t2t +50:application/x-subrip:*.srt +50:audio/x-it:*.it +50:image/x-eps:*.eps +50:application/x-gzpdf:*.pdf.gz +50:image/x-eps:*.epsf +50:text/richtext:*.rtx +50:image/x-eps:*.epsi +50:application/x-java-jce-keystore:*.jceks +50:application/x-python-bytecode:*.pyc +50:image/x-ilbm:*.lbm +50:video/vnd.vivo:*.vivo +50:text/x-ssa:*.ssa +50:application/x-cue:*.cue +50:audio/vnd.dts.hd:*.dtshd +50:application/x-python-bytecode:*.pyo +50:application/x-windows-themepack:*.themepack +50:video/x-sgi-movie:*.movie +50:text/x-cmake:*.cmake +50:text/x-dsl:*.dsl +50:application/x-trash:*% +50:application/vnd.ms-powerpoint.slide.macroEnabled.12:*.sldm +50:image/x-panasonic-raw2:*.rw2 +50:application/gml+xml:*.gml +50:application/javascript:*.js +50:application/x-markaby:*.mab +50:application/x-gettext-translation:*.gmo +50:image/x-win-bitmap:*.cur +50:text/x-fortran:*.for +50:application/vnd.lotus-1-2-3:*.wks +50:application/vnd.ms-works:*.wks +50:text/x-python:*.pyx +50:application/vnd.openxmlformats-officedocument.presentationml.slide:*.sldx +50:text/x-makefile:*.mak +50:application/x-troff-man:*.man +50:message/x-gnu-rmail:rmail +50:application/vnd.sun.xml.calc.template:*.stc +50:application/vnd.sun.xml.calc.template:*.stc +50:application/vnd.sun.xml.draw.template:*.std +50:application/vnd.sun.xml.draw.template:*.std +50:application/xml-dtd:*.dtd +50:application/x-iwork-keynote-sffkey:*.key +50:application/vnd.sun.xml.impress.template:*.sti +50:application/vnd.sun.xml.impress.template:*.sti +50:application/x-gnucash:*.gnc +50:application/x-abiword:*.abw.crashed +50:application/x-kchart:*.chrt +50:audio/prs.sid:*.psid +50:application/gnunet-directory:*.gnd +50:audio/ogg:*.opus +50:audio/x-opus+ogg:*.opus +50:audio/x-stm:*.stm +50:application/x-bzip:*.bz2 +50:text/x-erlang:*.erl +50:application/epub+zip:*.epub +50:application/x-java-keystore:*.ks +50:video/vnd.rn-realvideo:*.rvx +50:application/x-m4:*.m4 +50:application/vnd.sun.xml.writer.template:*.stw +50:application/vnd.sun.xml.writer.template:*.stw +50:text/x-tex:*.sty +50:audio/vnd.dts:*.dts +50:application/json:*.json +50:text/x-tex:*.dtx +50:application/x-kformula:*.kfo +50:application/json-patch+json:*.json-patch +50:application/x-bzip-compressed-tar:*.tar.bz2 +50:application/x-java:*.class +50:application/x-shared-library-la:*.la +50:text/x-microdvd:*.sub +50:text/x-mpsub:*.sub +50:text/x-subviewer:*.sub +50:application/font-woff:*.woff +50:image/x-macpaint:*.pntg +50:application/winhlp:*.hlp +50:image/tiff:*.tiff +50:audio/x-ms-wma:*.wma +50:text/x-qml:*.qmlproject +50:video/mpeg:*.vob +50:application/vnd.ms-visio.drawing.macroEnabled.main+xml:*.vsdm +50:text/troff:*.roff +50:image/x-sun-raster:*.sun +50:audio/x-voc:*.voc +50:image/x-wmf:*.wmf +50:text/x-scons:sconscript +50:application/x-tar:*.gtar +50:text/vnd.wap.wml:*.wml +50:application/x-par2:*.par2 +50:application/x-par2:*.par2 +50:application/x-cpio-compressed:*.cpio.gz +50:application/vnd.ms-visio.drawing.main+xml:*.vsdx +50:application/vnd.stardivision.writer:*.vor +50:image/x-compressed-xcf:*.xcf.gz +50:text/x-lilypond:*.ly +50:application/x-lzip:*.lz +50:audio/x-psflib:*.psflib +50:video/x-ms-wmv:*.wmv +50:audio/x-ms-asx:*.wmx +50:application/x-it87:*.it87 +50:text/tab-separated-values:*.tsv +50:audio/mp4:*.f4a +50:audio/x-m4b:*.f4b +50:audio/x-tta:*.tta +50:application/x-trash:*~ +50:application/x-font-ttf:*.ttc +50:image/svg+xml:*.svg +50:application/x-kexi-connectiondata:*.kexic +50:application/x-font-ttf:*.ttf +50:application/x-dvi:*.dvi +50:application/vnd.ms-excel:*.xla +50:text/x-java:*.java +50:application/vnd.ms-excel:*.xlc +50:application/vnd.ms-excel:*.xld +50:application/pgp-encrypted:*.gpg +50:application/pgp-keys:*.gpg +50:application/pgp-signature:*.gpg +50:application/x-xliff:*.xlf +50:application/x-gettext-translation:*.mo +50:text/x-modelica:*.mo +50:text/x-svhdr:*.svh +50:application/x-mswinurl:*.url +50:image/x-gzeps:*.epsi.gz +50:application/vnd.ms-access:*.mdb +50:application/vnd.ms-excel:*.xll +50:application/vnd.ms-excel:*.xlm +50:application/vnd.ms-tnef:winmail.dat +50:application/x-kexiproject-shortcut:*.kexis +50:application/x-font-ttx:*.ttx +50:application/x-raw-disk-image:*.raw-disk-image +50:application/vnd.ms-works:*.xlr +50:application/vnd.ms-excel:*.xls +50:application/vnd.ms-excel:*.xls +50:application/vnd.wordperfect:*.wp4 +50:application/vnd.wordperfect:*.wp5 +50:application/vnd.wordperfect:*.wp6 +50:application/vnd.ms-excel:*.xlt +50:application/vnd.ms-excel:*.xlw +50:text/turtle:*.ttl +50:application/mathematica:*.nb +50:application/x-netcdf:*.nc +50:video/mp4:*.f4v +50:application/vnd.adobe.flash.movie:*.swf +50:text/x-makefile:*.mk +50:image/vnd.dwg:*.dwg +50:text/x-setext:*.etx +50:application/x-genesis-rom:*.mdx +50:application/vnd.ms-powerpoint.template.macroEnabled.12:*.potm +50:application/vnd.ms-powerpoint.template.macroenabled.12:*.potm +50:application/x-xz-compressed-tar:*.tar.xz +50:application/x-ms-wim:*.swm +50:video/mpeg:*.mpeg +50:text/x-credits:credits +50:text/x-iMelody:*.ime +50:audio/x-xmf:*.xmf +50:application/x-raw-disk-image:*.img +50:text/x-xmi:*.xmi +50:text/spreadsheet:*.sylk +50:application/x-partial-download:*.part +50:application/xml:*.xml +50:audio/x-mod:*.med +50:text/vnd.wap.wmlscript:*.wmls +50:image/x-bzeps:*.epsf.bz2 +50:application/x-killustrator:*.kil +50:application/pkcs8:*.p8 +50:application/zip:*.zip +50:image/vnd.ms-modi:*.mdi +50:application/x-java-keystore:*.jks +50:text/x-c++src:*.cxx +50:text/x-iMelody:*.imy +50:application/vnd.sun.xml.calc:*.sxc +50:application/vnd.sun.xml.calc:*.sxc +50:application/vnd.sun.xml.draw:*.sxd +50:application/vnd.sun.xml.draw:*.sxd +50:application/x-java-keystore:cacerts +50:application/vnd.sun.xml.writer.global:*.sxg +50:application/vnd.sun.xml.writer.global:*.sxg +50:application/x-graphite:*.gra +50:application/vnd.sun.xml.impress:*.sxi +50:application/vnd.sun.xml.impress:*.sxi +50:video/x-matroska-3d:*.mk3d +50:application/vnd.wordperfect:*.wpd +50:application/vnd.sun.xml.math:*.sxm +50:application/vnd.sun.xml.math:*.sxm +50:application/vnd.ms-powerpoint.slideshow.macroEnabled.12:*.ppsm +50:application/x-wpg:*.wpg +50:application/x-gnuplot:*.gplt +50:image/vnd.dxf:*.dxf +50:application/x-lha:*.lha +50:model/vrml:*.vrm +50:application/vnd.ms-wpl:*.wpl +50:audio/mpeg:*.mpga +50:application/vnd.sun.xml.writer:*.sxw +50:application/vnd.sun.xml.writer:*.sxw +50:application/vnd.wordperfect:*.wpp +50:application/x-n64-rom:*.v64 +50:text/x-c++hdr:*.hpp +50:application/vnd.ms-works:*.wps +50:text/plain:*,v +50:text/markdown:*.md +50:text/x-tex:*.ins +50:text/x-troff-ms:*.ms +50:application/x-tgif:*.obj +50:text/x-c++src:*.C:cs +50:text/x-c++src:*.C +50:text/x-literate-haskell:*.lhs +50:image/x-pict:*.pict +50:text/x-ocaml:*.ml +50:text/x-troff-mm:*.mm +50:application/x-nintendo-ds-rom:*.nds +50:application/x-bzip-compressed-tar:*.tbz2 +50:text/x-qml:*.qmltypes +50:application/x-lhz:*.lhz +50:application/vnd.visio:*.vsd +50:application/x-tex-pk:*.pk +50:application/x-font-type1:*.gsf +50:application/x-perl:*.pl +50:application/x-perl:*.pl +50:application/x-perl:*.pm +50:application/x-pagemaker:*.pm +50:application/vnd.ms-powerpoint.presentation.macroEnabled.12:*.pptm +50:application/vnd.ms-powerpoint.presentation.macroenabled.12:*.pptm +50:text/x-gettext-translation:*.po +50:application/vnd.hp-hpgl:*.hpgl +50:audio/x-gsm:*.gsm +50:application/postscript:*.ps +50:text/x-fortran:*.f90 +50:application/vnd.ms-word.document.macroEnabled.12:*.docm +50:application/vnd.ms-word.document.macroenabled.12:*.docm +50:application/x-yaml:*.yml +50:application/vnd.visio:*.vss +50:application/vnd.visio:*.vst +50:image/x-tga:*.vst +50:application/x-karbon:*.karbon +50:image/x-nikon-nef:*.nef +50:application/vnd.visio:*.vsw +50:application/x-archive:*.a +50:audio/aac:*.aac +50:text/x-csrc:*.c:cs +50:text/x-csrc:*.c +50:application/x-pw:*.pw +50:application/x-magicpoint:*.mgp +50:text/x-ocl:*.ocl +50:application/x-pak:*.pak +50:text/x-chdr:*.h +50:text/x-dsrc:*.d +50:application/x-nes-rom:*.nes +50:application/x-ms-dos-executable:*.exe +50:text/x-objcsrc:*.m +50:text/x-matlab:*.m +50:text/x-troff-me:*.me +50:application/x-object:*.o +50:text/x-fortran:*.f +50:text/x-pascal:*.p +50:text/x-pascal:*.pas +50:video/mp2t:*.clpi +10:application/x-perl:*.t +10:text/troff:*.t +10:text/x-readme:readme* +10:application/pgp-encrypted:*.asc +10:application/pgp-keys:*.asc +10:application/pgp-signature:*.asc +10:text/x-makefile:makefile.* diff --git a/src-qt5/desktop-utils/lumina-calculator/lumina-calculator.pro b/src-qt5/desktop-utils/lumina-calculator/lumina-calculator.pro index 38e22b37..efb9e68c 100644 --- a/src-qt5/desktop-utils/lumina-calculator/lumina-calculator.pro +++ b/src-qt5/desktop-utils/lumina-calculator/lumina-calculator.pro @@ -5,6 +5,12 @@ QT += core gui widgets TARGET = lumina-calculator target.path = $${L_BINDIR} +#include all the special classes from the Lumina tree +include(../../core/libLumina/LUtils.pri) #includes LUtils +include(../../core/libLumina/LuminaXDG.pri) +include(../../core/libLumina/LuminaSingleApplication.pri) +include(../../core/libLumina/LuminaThemes.pri) + HEADERS += mainUI.h \ EqValidator.h @@ -13,10 +19,6 @@ SOURCES += main.cpp \ FORMS += mainUI.ui -LIBS += -lLuminaUtils - -DEPENDPATH += ../../libLumina - TRANSLATIONS = i18n/l-calc_af.ts \ i18n/l-calc_ar.ts \ i18n/l-calc_az.ts \ diff --git a/src-qt5/desktop-utils/lumina-calculator/main.cpp b/src-qt5/desktop-utils/lumina-calculator/main.cpp index ea1ae60c..da57763a 100644 --- a/src-qt5/desktop-utils/lumina-calculator/main.cpp +++ b/src-qt5/desktop-utils/lumina-calculator/main.cpp @@ -8,7 +8,7 @@ #include <QDebug> #include <LuminaThemes.h> -#include <LuminaUtils.h> +#include <LUtils.h> #include "mainUI.h" diff --git a/src-qt5/desktop-utils/lumina-calculator/mainUI.cpp b/src-qt5/desktop-utils/lumina-calculator/mainUI.cpp index 3da9ba6d..fcc39fd2 100644 --- a/src-qt5/desktop-utils/lumina-calculator/mainUI.cpp +++ b/src-qt5/desktop-utils/lumina-calculator/mainUI.cpp @@ -10,8 +10,9 @@ #include <QDebug> #include <QClipboard> #include <QFileDialog> +#include <QMenu> -#include <LuminaUtils.h> +#include <LUtils.h> #include <LuminaXDG.h> #include "EqValidator.h" diff --git a/src-qt5/desktop-utils/lumina-fileinfo/MainUI.cpp b/src-qt5/desktop-utils/lumina-fileinfo/MainUI.cpp index 8a16f03f..3e0150e2 100644 --- a/src-qt5/desktop-utils/lumina-fileinfo/MainUI.cpp +++ b/src-qt5/desktop-utils/lumina-fileinfo/MainUI.cpp @@ -11,7 +11,7 @@ #include <QFileDialog> #include <QMessageBox> -#include <LuminaUtils.h> +#include <LUtils.h> #include <LuminaOS.h> //LFileInfo INFO = LFileInfo(""); diff --git a/src-qt5/desktop-utils/lumina-fileinfo/lumina-fileinfo.pro b/src-qt5/desktop-utils/lumina-fileinfo/lumina-fileinfo.pro index 685b48a6..ee12b420 100644 --- a/src-qt5/desktop-utils/lumina-fileinfo/lumina-fileinfo.pro +++ b/src-qt5/desktop-utils/lumina-fileinfo/lumina-fileinfo.pro @@ -9,6 +9,12 @@ TEMPLATE = app target.path = $${L_BINDIR} +#include all the special classes from the Lumina tree +include(../../core/libLumina/LUtils.pri) #includes LUtils +include(../../core/libLumina/LuminaXDG.pri) +include(../../core/libLumina/LuminaSingleApplication.pri) +include(../../core/libLumina/LuminaThemes.pri) + SOURCES += main.cpp\ MainUI.cpp @@ -16,12 +22,6 @@ HEADERS += MainUI.h FORMS += MainUI.ui -#RESOURCES+= lumina-fileinfo.qrc - -LIBS += -lLuminaUtils - -DEPENDPATH += ../libLumina - TRANSLATIONS = i18n/l-fileinfo_af.ts \ i18n/l-fileinfo_ar.ts \ diff --git a/src-qt5/desktop-utils/lumina-fileinfo/main.cpp b/src-qt5/desktop-utils/lumina-fileinfo/main.cpp index ac3336bf..46f83831 100644 --- a/src-qt5/desktop-utils/lumina-fileinfo/main.cpp +++ b/src-qt5/desktop-utils/lumina-fileinfo/main.cpp @@ -4,7 +4,7 @@ #include <QFile> #include "MainUI.h" -#include <LuminaUtils.h> +#include <LUtils.h> #include <LuminaThemes.h> int main(int argc, char ** argv) diff --git a/src-qt5/desktop-utils/lumina-fm/Browser.cpp b/src-qt5/desktop-utils/lumina-fm/Browser.cpp index 72920757..5b84e2e7 100644 --- a/src-qt5/desktop-utils/lumina-fm/Browser.cpp +++ b/src-qt5/desktop-utils/lumina-fm/Browser.cpp @@ -11,7 +11,7 @@ #include <QtConcurrent> #include <QDebug> -#include <LuminaUtils.h> +#include <LUtils.h> Browser::Browser(QObject *parent) : QObject(parent){ watcher = new QFileSystemWatcher(this); diff --git a/src-qt5/desktop-utils/lumina-fm/BrowserWidget.cpp b/src-qt5/desktop-utils/lumina-fm/BrowserWidget.cpp index da651cca..8db13718 100644 --- a/src-qt5/desktop-utils/lumina-fm/BrowserWidget.cpp +++ b/src-qt5/desktop-utils/lumina-fm/BrowserWidget.cpp @@ -10,7 +10,7 @@ #include <QTimer> #include <QSettings> -#include <LuminaUtils.h> +#include <LUtils.h> #include <LuminaOS.h> BrowserWidget::BrowserWidget(QString objID, QWidget *parent) : QWidget(parent){ diff --git a/src-qt5/desktop-utils/lumina-fm/DirData.h b/src-qt5/desktop-utils/lumina-fm/DirData.h index 546dd6c5..c887ed5c 100644 --- a/src-qt5/desktop-utils/lumina-fm/DirData.h +++ b/src-qt5/desktop-utils/lumina-fm/DirData.h @@ -16,7 +16,7 @@ #include <QDir> #include <LuminaXDG.h> -#include <LuminaUtils.h> +#include <LUtils.h> #define ZSNAPDIR QString("/.zfs/snapshot/") diff --git a/src-qt5/desktop-utils/lumina-fm/FODialog.h b/src-qt5/desktop-utils/lumina-fm/FODialog.h index a595b9f2..9b53a934 100644 --- a/src-qt5/desktop-utils/lumina-fm/FODialog.h +++ b/src-qt5/desktop-utils/lumina-fm/FODialog.h @@ -21,7 +21,7 @@ // libLumina includes #include <LuminaXDG.h> -#include <LuminaUtils.h> +#include <LUtils.h> class FOWorker : public QObject{ Q_OBJECT diff --git a/src-qt5/desktop-utils/lumina-fm/MainUI.cpp b/src-qt5/desktop-utils/lumina-fm/MainUI.cpp index 128c4cd5..0744ac84 100644 --- a/src-qt5/desktop-utils/lumina-fm/MainUI.cpp +++ b/src-qt5/desktop-utils/lumina-fm/MainUI.cpp @@ -7,10 +7,13 @@ #include "MainUI.h" #include "ui_MainUI.h" +#include <QMenu> #include <QFileInfo> #include "gitCompat.h" #include "gitWizard.h" +#include <LDesktopUtils.h> + #define DEBUG 0 MainUI::MainUI() : QMainWindow(), ui(new Ui::MainUI){ @@ -845,7 +848,7 @@ void MainUI::PasteFiles(QString dir, QStringList raw){ void MainUI::FavoriteFiles(QStringList list){ qDebug() << "Favorite Files:" << list; for(int i=0; i<list.length(); i++){ - LUtils::addFavorite(list[i]); + LDesktopUtils::addFavorite(list[i]); } //Might want to make this a "toggle" instead of an add later on... } diff --git a/src-qt5/desktop-utils/lumina-fm/OPWidget.h b/src-qt5/desktop-utils/lumina-fm/OPWidget.h index 13fb3cb3..4fdb7db8 100644 --- a/src-qt5/desktop-utils/lumina-fm/OPWidget.h +++ b/src-qt5/desktop-utils/lumina-fm/OPWidget.h @@ -11,6 +11,9 @@ #include "FODialog.h" #include "ScrollDialog.h" + +#include <QWidgetAction> + namespace Ui{ class OPWidget; }; diff --git a/src-qt5/desktop-utils/lumina-fm/gitCompat.h b/src-qt5/desktop-utils/lumina-fm/gitCompat.h index 3e6cb15e..4e63e780 100644 --- a/src-qt5/desktop-utils/lumina-fm/gitCompat.h +++ b/src-qt5/desktop-utils/lumina-fm/gitCompat.h @@ -14,7 +14,7 @@ #include <QProcessEnvironment> #include <QDebug> #include <QTemporaryFile> -#include <LuminaUtils.h> +#include <LUtils.h> #include <unistd.h> diff --git a/src-qt5/desktop-utils/lumina-fm/gitWizard.h b/src-qt5/desktop-utils/lumina-fm/gitWizard.h index 4a6ec2bc..e49f43aa 100644 --- a/src-qt5/desktop-utils/lumina-fm/gitWizard.h +++ b/src-qt5/desktop-utils/lumina-fm/gitWizard.h @@ -12,6 +12,7 @@ #include <QWizard> #include <QString> #include <QMessageBox> +#include <QCloseEvent> #include "gitCompat.h" diff --git a/src-qt5/desktop-utils/lumina-fm/lumina-fm.pro b/src-qt5/desktop-utils/lumina-fm/lumina-fm.pro index 92042ad7..a98161f0 100644 --- a/src-qt5/desktop-utils/lumina-fm/lumina-fm.pro +++ b/src-qt5/desktop-utils/lumina-fm/lumina-fm.pro @@ -9,6 +9,12 @@ target.path = $${L_BINDIR} TEMPLATE = app +#include all the special classes from the Lumina tree +include(../../core/libLumina/LDesktopUtils.pri) #includes LUtils +include(../../core/libLumina/LuminaXDG.pri) +include(../../core/libLumina/LuminaSingleApplication.pri) +include(../../core/libLumina/LuminaThemes.pri) + SOURCES += main.cpp \ MainUI.cpp \ FODialog.cpp \ @@ -51,7 +57,6 @@ FORMS += MainUI.ui \ icons.files = Insight-FileManager.png icons.path = $${L_SHAREDIR}/pixmaps -LIBS += -lLuminaUtils TRANSLATIONS = i18n/lumina-fm_af.ts \ i18n/lumina-fm_ar.ts \ diff --git a/src-qt5/desktop-utils/lumina-fm/main.cpp b/src-qt5/desktop-utils/lumina-fm/main.cpp index eaaf182c..c72f031e 100644 --- a/src-qt5/desktop-utils/lumina-fm/main.cpp +++ b/src-qt5/desktop-utils/lumina-fm/main.cpp @@ -6,7 +6,7 @@ #include "MainUI.h" #include <LuminaOS.h> #include <LuminaThemes.h> -#include <LuminaUtils.h> +#include <LUtils.h> #include <LuminaSingleApplication.h> #include "BrowserWidget.h" diff --git a/src-qt5/desktop-utils/lumina-fm/widgets/DDListWidgets.h b/src-qt5/desktop-utils/lumina-fm/widgets/DDListWidgets.h index 8049600e..48127efa 100644 --- a/src-qt5/desktop-utils/lumina-fm/widgets/DDListWidgets.h +++ b/src-qt5/desktop-utils/lumina-fm/widgets/DDListWidgets.h @@ -24,7 +24,7 @@ #include <QUrl> #include <QDir> -#include <LuminaUtils.h> +#include <LUtils.h> //============== // LIST WIDGET diff --git a/src-qt5/desktop-utils/lumina-fm/widgets/DirWidget2.cpp b/src-qt5/desktop-utils/lumina-fm/widgets/DirWidget2.cpp index 161225e4..29adf09d 100644 --- a/src-qt5/desktop-utils/lumina-fm/widgets/DirWidget2.cpp +++ b/src-qt5/desktop-utils/lumina-fm/widgets/DirWidget2.cpp @@ -19,7 +19,7 @@ #include <LuminaOS.h> #include <LuminaXDG.h> -#include <LuminaUtils.h> +#include <LUtils.h> #include "../ScrollDialog.h" diff --git a/src-qt5/desktop-utils/lumina-screenshot/MainUI.h b/src-qt5/desktop-utils/lumina-screenshot/MainUI.h index 853fb194..00b3f8ac 100644 --- a/src-qt5/desktop-utils/lumina-screenshot/MainUI.h +++ b/src-qt5/desktop-utils/lumina-screenshot/MainUI.h @@ -20,7 +20,7 @@ #include <QScreen> #include <LuminaXDG.h> -#include <LuminaUtils.h> +#include <LUtils.h> #include <LuminaX11.h> #include "ImageEditor.h" diff --git a/src-qt5/desktop-utils/lumina-screenshot/lumina-screenshot.pro b/src-qt5/desktop-utils/lumina-screenshot/lumina-screenshot.pro index a85b234c..cb2b9713 100644 --- a/src-qt5/desktop-utils/lumina-screenshot/lumina-screenshot.pro +++ b/src-qt5/desktop-utils/lumina-screenshot/lumina-screenshot.pro @@ -9,6 +9,13 @@ target.path = $${L_BINDIR} TEMPLATE = app +#include all the special classes from the Lumina tree +include(../../core/libLumina/LUtils.pri) #includes LUtils +include(../../core/libLumina/LuminaXDG.pri) +include(../../core/libLumina/LuminaSingleApplication.pri) +include(../../core/libLumina/LuminaThemes.pri) +include(../../core/libLumina/LuminaX11.pri) + SOURCES += main.cpp \ MainUI.cpp \ ImageEditor.cpp @@ -18,10 +25,6 @@ HEADERS += MainUI.h \ FORMS += MainUI.ui -LIBS += -lLuminaUtils - -DEPENDPATH += ../libLumina - TRANSLATIONS = i18n/l-screenshot_af.ts \ i18n/l-screenshot_ar.ts \ i18n/l-screenshot_az.ts \ diff --git a/src-qt5/desktop-utils/lumina-screenshot/main.cpp b/src-qt5/desktop-utils/lumina-screenshot/main.cpp index 27e1f2ff..a39d6851 100644 --- a/src-qt5/desktop-utils/lumina-screenshot/main.cpp +++ b/src-qt5/desktop-utils/lumina-screenshot/main.cpp @@ -6,7 +6,7 @@ #include "MainUI.h" #include <LuminaOS.h> #include <LuminaThemes.h> -#include <LuminaUtils.h> +#include <LUtils.h> #include <LuminaSingleApplication.h> int main(int argc, char ** argv) diff --git a/src-qt5/desktop-utils/lumina-terminal/TrayIcon.cpp b/src-qt5/desktop-utils/lumina-terminal/TrayIcon.cpp index ea970df9..52e15314 100644 --- a/src-qt5/desktop-utils/lumina-terminal/TrayIcon.cpp +++ b/src-qt5/desktop-utils/lumina-terminal/TrayIcon.cpp @@ -9,7 +9,7 @@ #include <QDir> #include <QDesktopWidget> -#include <LuminaUtils.h> +#include <LUtils.h> TrayIcon::TrayIcon() : QSystemTrayIcon(){ //Create the child widgets here @@ -169,4 +169,4 @@ void TrayIcon::TermHidden(){ void TrayIcon::TermVisible(){ termVisible = true; -} \ No newline at end of file +} diff --git a/src-qt5/desktop-utils/lumina-terminal/lumina-terminal.pro b/src-qt5/desktop-utils/lumina-terminal/lumina-terminal.pro index ada7110b..4c623087 100644 --- a/src-qt5/desktop-utils/lumina-terminal/lumina-terminal.pro +++ b/src-qt5/desktop-utils/lumina-terminal/lumina-terminal.pro @@ -5,6 +5,12 @@ QT += core gui widgets network TARGET = lumina-terminal target.path = $${L_BINDIR} +#include all the special classes from the Lumina tree +include(../../core/libLumina/LUtils.pri) #includes LUtils +include(../../core/libLumina/LuminaXDG.pri) +include(../../core/libLumina/LuminaSingleApplication.pri) +include(../../core/libLumina/LuminaThemes.pri) + HEADERS += TrayIcon.h \ TermWindow.h \ TerminalWidget.h \ @@ -17,10 +23,8 @@ SOURCES += main.cpp \ TtyProcess.cpp -LIBS += -lLuminaUtils -lncurses - +LIBS += -lncurses -DEPENDPATH += ../../libLumina TRANSLATIONS = i18n/l-terminal_af.ts \ i18n/l-terminal_ar.ts \ diff --git a/src-qt5/desktop-utils/lumina-textedit/MainUI.cpp b/src-qt5/desktop-utils/lumina-textedit/MainUI.cpp index c4f4eaca..4a7fbabf 100644 --- a/src-qt5/desktop-utils/lumina-textedit/MainUI.cpp +++ b/src-qt5/desktop-utils/lumina-textedit/MainUI.cpp @@ -10,7 +10,7 @@ #include "syntaxSupport.h" #include <LuminaXDG.h> -#include <LuminaUtils.h> +#include <LUtils.h> #include <QFileDialog> #include <QDir> diff --git a/src-qt5/desktop-utils/lumina-textedit/PlainTextEditor.cpp b/src-qt5/desktop-utils/lumina-textedit/PlainTextEditor.cpp index 99a0ed75..e8eaa007 100644 --- a/src-qt5/desktop-utils/lumina-textedit/PlainTextEditor.cpp +++ b/src-qt5/desktop-utils/lumina-textedit/PlainTextEditor.cpp @@ -14,7 +14,7 @@ #include <QApplication> #include <QMessageBox> -#include <LuminaUtils.h> +#include <LUtils.h> //============== // PUBLIC diff --git a/src-qt5/desktop-utils/lumina-textedit/lumina-textedit.pro b/src-qt5/desktop-utils/lumina-textedit/lumina-textedit.pro index 8b46f7b2..3da05dbc 100644 --- a/src-qt5/desktop-utils/lumina-textedit/lumina-textedit.pro +++ b/src-qt5/desktop-utils/lumina-textedit/lumina-textedit.pro @@ -5,6 +5,12 @@ QT += core gui widgets TARGET = lumina-textedit target.path = $${L_BINDIR} +#include all the special classes from the Lumina tree +include(../../core/libLumina/LUtils.pri) #includes LUtils +include(../../core/libLumina/LuminaXDG.pri) +include(../../core/libLumina/LuminaSingleApplication.pri) +include(../../core/libLumina/LuminaThemes.pri) + HEADERS += MainUI.h \ PlainTextEditor.h \ syntaxSupport.h \ @@ -18,10 +24,6 @@ SOURCES += main.cpp \ FORMS += MainUI.ui \ ColorDialog.ui -LIBS += -lLuminaUtils - - -DEPENDPATH += ../../libLumina TRANSLATIONS = i18n/l-te_af.ts \ i18n/l-te_ar.ts \ diff --git a/src-qt5/desktop-utils/lumina-textedit/main.cpp b/src-qt5/desktop-utils/lumina-textedit/main.cpp index f4ee02cf..346a6c44 100644 --- a/src-qt5/desktop-utils/lumina-textedit/main.cpp +++ b/src-qt5/desktop-utils/lumina-textedit/main.cpp @@ -8,7 +8,7 @@ #include <QDebug> #include <LuminaThemes.h> -#include <LuminaUtils.h> +#include <LUtils.h> #include "MainUI.h" -- cgit From 340c1b5cd4376e0a4ff2e7acdb4e4536f734006c Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Wed, 9 Nov 2016 17:53:33 -0500 Subject: Fix the wallpaper background when a screen resizes. --- src-qt5/core/lumina-desktop/LDesktop.cpp | 1 + 1 file changed, 1 insertion(+) (limited to 'src-qt5') diff --git a/src-qt5/core/lumina-desktop/LDesktop.cpp b/src-qt5/core/lumina-desktop/LDesktop.cpp index 1a11899d..b08251bd 100644 --- a/src-qt5/core/lumina-desktop/LDesktop.cpp +++ b/src-qt5/core/lumina-desktop/LDesktop.cpp @@ -474,6 +474,7 @@ void LDesktop::UpdateDesktopPluginArea(){ bgDesktop->setGeometry(desktop->screenGeometry(desktopnumber)); bgDesktop->setDesktopArea( rec ); bgDesktop->UpdateGeom(); //just in case the plugin space itself needs to do anything + QTimer::singleShot(10, this, SLOT(UpdateBackground()) ); //Re-paint the panels (just in case a plugin was underneath it and the panel is transparent) //for(int i=0; i<PANELS.length(); i++){ PANELS[i]->update(); } //Make sure to re-disable any WM control flags -- cgit From 8811bc7cdd845ef14eacbc1f4a8bc1512c9fd928 Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Thu, 10 Nov 2016 10:02:20 -0500 Subject: Due to some erratic reports of the wallpaper widget not staying on the bottom of the window stack within virtualBox environments: on focus in events for the desktop, lower the window to the bottom of the stack manually. --- src-qt5/core/lumina-desktop/LDesktopPluginSpace.h | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'src-qt5') diff --git a/src-qt5/core/lumina-desktop/LDesktopPluginSpace.h b/src-qt5/core/lumina-desktop/LDesktopPluginSpace.h index 12382db8..abc34878 100644 --- a/src-qt5/core/lumina-desktop/LDesktopPluginSpace.h +++ b/src-qt5/core/lumina-desktop/LDesktopPluginSpace.h @@ -188,6 +188,10 @@ private slots: } protected: + void focusInEvent(QFocusEvent *ev){ + this->lower(); //make sure we stay on the bottom of the window stack + QWidget::focusInEvent(ev); //do normal handling + } void paintEvent(QPaintEvent*ev); //Need Drag and Drop functionality (internal movement) -- cgit From 135fd7e158e8c4c030beb8f9c64bc24303a07da7 Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Thu, 10 Nov 2016 10:11:28 -0500 Subject: Disable the theme engine from the desktop-utilities. Also start pruning unneeded libLumina classes from the desktop utils. --- src-qt5/desktop-utils/lumina-calculator/lumina-calculator.pro | 2 +- src-qt5/desktop-utils/lumina-calculator/main.cpp | 4 ++-- src-qt5/desktop-utils/lumina-fileinfo/lumina-fileinfo.pro | 2 +- src-qt5/desktop-utils/lumina-fileinfo/main.cpp | 4 ++-- src-qt5/desktop-utils/lumina-fm/main.cpp | 4 ++-- src-qt5/desktop-utils/lumina-screenshot/main.cpp | 5 ++--- src-qt5/desktop-utils/lumina-terminal/main.cpp | 4 ++-- src-qt5/desktop-utils/lumina-textedit/lumina-textedit.pro | 2 +- src-qt5/desktop-utils/lumina-textedit/main.cpp | 4 ++-- 9 files changed, 15 insertions(+), 16 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/desktop-utils/lumina-calculator/lumina-calculator.pro b/src-qt5/desktop-utils/lumina-calculator/lumina-calculator.pro index efb9e68c..347a8dfb 100644 --- a/src-qt5/desktop-utils/lumina-calculator/lumina-calculator.pro +++ b/src-qt5/desktop-utils/lumina-calculator/lumina-calculator.pro @@ -8,7 +8,7 @@ target.path = $${L_BINDIR} #include all the special classes from the Lumina tree include(../../core/libLumina/LUtils.pri) #includes LUtils include(../../core/libLumina/LuminaXDG.pri) -include(../../core/libLumina/LuminaSingleApplication.pri) +#include(../../core/libLumina/LuminaSingleApplication.pri) include(../../core/libLumina/LuminaThemes.pri) HEADERS += mainUI.h \ diff --git a/src-qt5/desktop-utils/lumina-calculator/main.cpp b/src-qt5/desktop-utils/lumina-calculator/main.cpp index da57763a..222ee8b4 100644 --- a/src-qt5/desktop-utils/lumina-calculator/main.cpp +++ b/src-qt5/desktop-utils/lumina-calculator/main.cpp @@ -17,10 +17,10 @@ int main(int argc, char *argv[]) { QApplication a(argc, argv); LUtils::LoadTranslation(&a, "l-calc"); //Now go ahead and setup the app - LuminaThemeEngine theme(&a); + //LuminaThemeEngine theme(&a); //Now start the window mainUI W; - QObject::connect(&theme, SIGNAL(updateIcons()), &W, SLOT(updateIcons()) ); + //QObject::connect(&theme, SIGNAL(updateIcons()), &W, SLOT(updateIcons()) ); W.show(); return a.exec(); } diff --git a/src-qt5/desktop-utils/lumina-fileinfo/lumina-fileinfo.pro b/src-qt5/desktop-utils/lumina-fileinfo/lumina-fileinfo.pro index ee12b420..6f44a512 100644 --- a/src-qt5/desktop-utils/lumina-fileinfo/lumina-fileinfo.pro +++ b/src-qt5/desktop-utils/lumina-fileinfo/lumina-fileinfo.pro @@ -12,7 +12,7 @@ target.path = $${L_BINDIR} #include all the special classes from the Lumina tree include(../../core/libLumina/LUtils.pri) #includes LUtils include(../../core/libLumina/LuminaXDG.pri) -include(../../core/libLumina/LuminaSingleApplication.pri) +#include(../../core/libLumina/LuminaSingleApplication.pri) include(../../core/libLumina/LuminaThemes.pri) SOURCES += main.cpp\ diff --git a/src-qt5/desktop-utils/lumina-fileinfo/main.cpp b/src-qt5/desktop-utils/lumina-fileinfo/main.cpp index 46f83831..4b048487 100644 --- a/src-qt5/desktop-utils/lumina-fileinfo/main.cpp +++ b/src-qt5/desktop-utils/lumina-fileinfo/main.cpp @@ -12,7 +12,7 @@ int main(int argc, char ** argv) LTHEME::LoadCustomEnvSettings(); QApplication a(argc, argv); LUtils::LoadTranslation(&a, "l-fileinfo"); - LuminaThemeEngine theme(&a); + //LuminaThemeEngine theme(&a); //Read the input variables @@ -39,7 +39,7 @@ int main(int argc, char ** argv) } if(!path.isEmpty() || !flag.isEmpty()){ MainUI w; - QObject::connect(&theme, SIGNAL(updateIcons()), &w, SLOT(UpdateIcons()) ); + //QObject::connect(&theme, SIGNAL(updateIcons()), &w, SLOT(UpdateIcons()) ); w.LoadFile(path, flag); w.show(); int retCode = a.exec(); diff --git a/src-qt5/desktop-utils/lumina-fm/main.cpp b/src-qt5/desktop-utils/lumina-fm/main.cpp index c72f031e..61d2dc95 100644 --- a/src-qt5/desktop-utils/lumina-fm/main.cpp +++ b/src-qt5/desktop-utils/lumina-fm/main.cpp @@ -18,7 +18,7 @@ int main(int argc, char ** argv) if( !a.isPrimaryProcess()){ return 0; } qDebug() << "Loaded QApplication"; a.setApplicationName("Insight File Manager"); - LuminaThemeEngine themes(&a); + //LuminaThemeEngine themes(&a); //Get the list of inputs for the initial load QStringList in = a.inputlist; //has fixes for relative paths and such @@ -26,7 +26,7 @@ int main(int argc, char ** argv) //Start the UI MainUI w; QObject::connect(&a, SIGNAL(InputsAvailable(QStringList)), &w, SLOT(slotSingleInstance(QStringList)) ); - QObject::connect(&themes, SIGNAL(updateIcons()), &w, SLOT(setupIcons()) ); + //QObject::connect(&themes, SIGNAL(updateIcons()), &w, SLOT(setupIcons()) ); w.OpenDirs(in); w.show(); diff --git a/src-qt5/desktop-utils/lumina-screenshot/main.cpp b/src-qt5/desktop-utils/lumina-screenshot/main.cpp index a39d6851..7ba9d2d5 100644 --- a/src-qt5/desktop-utils/lumina-screenshot/main.cpp +++ b/src-qt5/desktop-utils/lumina-screenshot/main.cpp @@ -13,12 +13,11 @@ int main(int argc, char ** argv) { LTHEME::LoadCustomEnvSettings(); LSingleApplication a(argc, argv, "l-screenshot"); - LuminaThemeEngine theme(&a); + //LuminaThemeEngine theme(&a); a.setApplicationName("Take Screenshot"); - //LUtils::LoadTranslation(&a, "l-screenshot"); MainUI w; - QObject::connect(&theme,SIGNAL(updateIcons()), &w, SLOT(setupIcons()) ); + //QObject::connect(&theme,SIGNAL(updateIcons()), &w, SLOT(setupIcons()) ); w.show(); return a.exec(); diff --git a/src-qt5/desktop-utils/lumina-terminal/main.cpp b/src-qt5/desktop-utils/lumina-terminal/main.cpp index 7375b074..a316ff35 100644 --- a/src-qt5/desktop-utils/lumina-terminal/main.cpp +++ b/src-qt5/desktop-utils/lumina-terminal/main.cpp @@ -34,13 +34,13 @@ int main(int argc, char *argv[]) { } //Now go ahead and setup the app - LuminaThemeEngine theme(&a); + //LuminaThemeEngine theme(&a); QApplication::setQuitOnLastWindowClosed(false); //Now start the tray icon TrayIcon tray; QObject::connect(&a, SIGNAL(InputsAvailable(QStringList)), &tray, SLOT(slotSingleInstance(QStringList)) ); - QObject::connect(&theme, SIGNAL(updateIcons()), &tray, SLOT(updateIcons()) ); + //QObject::connect(&theme, SIGNAL(updateIcons()), &tray, SLOT(updateIcons()) ); tray.parseInputs(a.inputlist); tray.show(); return a.exec(); diff --git a/src-qt5/desktop-utils/lumina-textedit/lumina-textedit.pro b/src-qt5/desktop-utils/lumina-textedit/lumina-textedit.pro index 3da05dbc..51e099e9 100644 --- a/src-qt5/desktop-utils/lumina-textedit/lumina-textedit.pro +++ b/src-qt5/desktop-utils/lumina-textedit/lumina-textedit.pro @@ -8,7 +8,7 @@ target.path = $${L_BINDIR} #include all the special classes from the Lumina tree include(../../core/libLumina/LUtils.pri) #includes LUtils include(../../core/libLumina/LuminaXDG.pri) -include(../../core/libLumina/LuminaSingleApplication.pri) +#include(../../core/libLumina/LuminaSingleApplication.pri) include(../../core/libLumina/LuminaThemes.pri) HEADERS += MainUI.h \ diff --git a/src-qt5/desktop-utils/lumina-textedit/main.cpp b/src-qt5/desktop-utils/lumina-textedit/main.cpp index 346a6c44..ec4503a0 100644 --- a/src-qt5/desktop-utils/lumina-textedit/main.cpp +++ b/src-qt5/desktop-utils/lumina-textedit/main.cpp @@ -17,14 +17,14 @@ int main(int argc, char *argv[]) { QApplication a(argc, argv); LUtils::LoadTranslation(&a, "l-te"); //Now go ahead and setup the app - LuminaThemeEngine theme(&a); + //LuminaThemeEngine theme(&a); QStringList args; for(int i=1; i<argc; i++){ args << QString(argv[i]); } //Now start the window MainUI W; - QObject::connect(&theme, SIGNAL(updateIcons()), &W, SLOT(updateIcons()) ); + //QObject::connect(&theme, SIGNAL(updateIcons()), &W, SLOT(updateIcons()) ); W.LoadArguments(args); W.show(); return a.exec(); -- cgit From 3ccbe4ab221a88c19d50525e5a73c45381ee0bd4 Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Thu, 10 Nov 2016 10:13:36 -0500 Subject: Tag version 1.1.2 internally (Lumina Library no longer in existence) --- src-qt5/core/libLumina/LDesktopUtils.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src-qt5') diff --git a/src-qt5/core/libLumina/LDesktopUtils.cpp b/src-qt5/core/libLumina/LDesktopUtils.cpp index 4f8d94ef..2797c8ca 100644 --- a/src-qt5/core/libLumina/LDesktopUtils.cpp +++ b/src-qt5/core/libLumina/LDesktopUtils.cpp @@ -15,7 +15,7 @@ static QStringList fav; QString LDesktopUtils::LuminaDesktopVersion(){ - QString ver = "1.1.1"; + QString ver = "1.1.2"; #ifdef GIT_VERSION ver.append( QString(" (Git Revision: %1)").arg(GIT_VERSION) ); #endif -- cgit From 6451f4368ee79501af011c833813f51c9713c5d1 Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Thu, 10 Nov 2016 10:19:47 -0500 Subject: Disable the theme engine from the core-utils. Clean up the libLumina classes needed by the core-utils. --- src-qt5/core-utils/lumina-config/main.cpp | 4 ++-- src-qt5/core-utils/lumina-search/lumina-search.pro | 2 +- src-qt5/core-utils/lumina-search/main.cpp | 4 ++-- src-qt5/core-utils/lumina-xconfig/main.cpp | 4 ++-- 4 files changed, 7 insertions(+), 7 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/core-utils/lumina-config/main.cpp b/src-qt5/core-utils/lumina-config/main.cpp index b958c10e..27493bac 100644 --- a/src-qt5/core-utils/lumina-config/main.cpp +++ b/src-qt5/core-utils/lumina-config/main.cpp @@ -20,11 +20,11 @@ int main(int argc, char ** argv) LSingleApplication a(argc, argv, "lumina-config"); //loads translations inside constructor if(!a.isPrimaryProcess()){ return 0; } - LuminaThemeEngine theme(&a); + //LuminaThemeEngine theme(&a); mainWindow w; QObject::connect(&a, SIGNAL(InputsAvailable(QStringList)), &w, SLOT(slotSingleInstance()) ); - QObject::connect(&theme, SIGNAL(updateIcons()), &w, SLOT(setupIcons()) ); + //QObject::connect(&theme, SIGNAL(updateIcons()), &w, SLOT(setupIcons()) ); w.show(); int retCode = a.exec(); diff --git a/src-qt5/core-utils/lumina-search/lumina-search.pro b/src-qt5/core-utils/lumina-search/lumina-search.pro index c0186ce4..4c0d88ef 100644 --- a/src-qt5/core-utils/lumina-search/lumina-search.pro +++ b/src-qt5/core-utils/lumina-search/lumina-search.pro @@ -13,7 +13,7 @@ TEMPLATE = app #include all the special classes from the Lumina tree include(../../core/libLumina/LUtils.pri) #includes LUtils include(../../core/libLumina/LuminaXDG.pri) -include(../../core/libLumina/LuminaSingleApplication.pri) +#include(../../core/libLumina/LuminaSingleApplication.pri) include(../../core/libLumina/LuminaThemes.pri) SOURCES += main.cpp \ diff --git a/src-qt5/core-utils/lumina-search/main.cpp b/src-qt5/core-utils/lumina-search/main.cpp index 5eee7c32..5e71e99c 100644 --- a/src-qt5/core-utils/lumina-search/main.cpp +++ b/src-qt5/core-utils/lumina-search/main.cpp @@ -20,13 +20,13 @@ int main(int argc, char ** argv) LTHEME::LoadCustomEnvSettings(); QApplication a(argc, argv); //qDebug() << "Init Theme Engine..."; - LuminaThemeEngine theme(&a); + //LuminaThemeEngine theme(&a); //qDebug() << "Load Translations..."; a.setApplicationName("Search for..."); LUtils::LoadTranslation(&a, "lumina-search"); MainUI w; - QObject::connect(&theme,SIGNAL(updateIcons()), &w, SLOT(setupIcons()) ); + //QObject::connect(&theme,SIGNAL(updateIcons()), &w, SLOT(setupIcons()) ); w.show(); if(argc>1){ bool startsearch = false; diff --git a/src-qt5/core-utils/lumina-xconfig/main.cpp b/src-qt5/core-utils/lumina-xconfig/main.cpp index 2596bf7a..a39a9f5d 100644 --- a/src-qt5/core-utils/lumina-xconfig/main.cpp +++ b/src-qt5/core-utils/lumina-xconfig/main.cpp @@ -26,12 +26,12 @@ int main(int argc, char ** argv) if( !a.isPrimaryProcess()){ return 0; } //qDebug() << "Loaded QApplication"; a.setApplicationName("Lumina Screen Configuration"); - LuminaThemeEngine themes(&a); + //LuminaThemeEngine themes(&a); //Start the UI MainUI w; QObject::connect(&a, SIGNAL(InputsAvailable(QStringList)), &w, SLOT(slotSingleInstance()) ); - QObject::connect(&themes, SIGNAL(updateIcons()), &w, SLOT(loadIcons()) ); + //QObject::connect(&themes, SIGNAL(updateIcons()), &w, SLOT(loadIcons()) ); w.show(); int retCode = a.exec(); -- cgit From 634557bad1b1b6781fe693d37b480897cc55376e Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Thu, 10 Nov 2016 12:38:56 -0500 Subject: Add pass-through for context menu requests on many desktop plugins. This should allow the user to click almost anywhere on the plugin to actually see the menu for managing the plugin itself. --- .../core/lumina-desktop/desktop-plugins/audioplayer/PlayerWidget.cpp | 4 +++- src-qt5/core/lumina-desktop/desktop-plugins/notepad/NotepadPlugin.cpp | 1 + .../core/lumina-desktop/desktop-plugins/rssreader/RSSFeedPlugin.cpp | 2 +- 3 files changed, 5 insertions(+), 2 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/core/lumina-desktop/desktop-plugins/audioplayer/PlayerWidget.cpp b/src-qt5/core/lumina-desktop/desktop-plugins/audioplayer/PlayerWidget.cpp index 4d293b39..722a5865 100644 --- a/src-qt5/core/lumina-desktop/desktop-plugins/audioplayer/PlayerWidget.cpp +++ b/src-qt5/core/lumina-desktop/desktop-plugins/audioplayer/PlayerWidget.cpp @@ -30,6 +30,8 @@ PlayerWidget::PlayerWidget(QWidget *parent) : QWidget(parent), ui(new Ui::Player ui->tool_add->setMenu(addMenu); updatinglists = false; //start off as false + + ui->combo_playlist->setContextMenuPolicy(Qt::NoContextMenu); LoadIcons(); playerStateChanged(); //update button visibility @@ -266,4 +268,4 @@ AudioPlayerPlugin::AudioPlayerPlugin(QWidget *parent, QString ID) : LDPlugin(par AudioPlayerPlugin::~AudioPlayerPlugin(){ //qDebug() << "Remove AudioPlayerPlugin"; -} \ No newline at end of file +} diff --git a/src-qt5/core/lumina-desktop/desktop-plugins/notepad/NotepadPlugin.cpp b/src-qt5/core/lumina-desktop/desktop-plugins/notepad/NotepadPlugin.cpp index a2549acf..fe26941e 100644 --- a/src-qt5/core/lumina-desktop/desktop-plugins/notepad/NotepadPlugin.cpp +++ b/src-qt5/core/lumina-desktop/desktop-plugins/notepad/NotepadPlugin.cpp @@ -60,6 +60,7 @@ NotePadPlugin::NotePadPlugin(QWidget* parent, QString ID) : LDPlugin(parent, ID) edit->setReadOnly(false); edit->setSizePolicy(QSizePolicy::Expanding, QSizePolicy::Expanding); vlay->addWidget(edit); + edit->setContextMenuPolicy(Qt::NoContextMenu); //Now load the new file-based system for saving notes //qDebug() << "Saving a new setting"; diff --git a/src-qt5/core/lumina-desktop/desktop-plugins/rssreader/RSSFeedPlugin.cpp b/src-qt5/core/lumina-desktop/desktop-plugins/rssreader/RSSFeedPlugin.cpp index 8dc58e0a..c330d6c0 100644 --- a/src-qt5/core/lumina-desktop/desktop-plugins/rssreader/RSSFeedPlugin.cpp +++ b/src-qt5/core/lumina-desktop/desktop-plugins/rssreader/RSSFeedPlugin.cpp @@ -20,7 +20,7 @@ RSSFeedPlugin::RSSFeedPlugin(QWidget* parent, QString ID) : LDPlugin(parent, ID) //Load the global settings setprefix = "rssreader/"; //this structure/prefix should be used for *all* plugins of this type RSS = new RSSReader(this, setprefix); - + ui->text_feed->setContextMenuPolicy(Qt::NoContextMenu); //Create the options menu optionsMenu = new QMenu(this); ui->tool_options->setMenu(optionsMenu); -- cgit From 9553d3929dc5b32c80c23fc426da09ed80c36ed3 Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Thu, 10 Nov 2016 14:00:16 -0500 Subject: Add a new panel plugin: "audioplayer": This is panel-based implementation of the desktop plugin with the same name. Allows the user to load/play audio files directly from the desktop session without loading any external applications. --- src-qt5/core/lumina-desktop/Globals.h | 15 +++++++++------ src-qt5/core/lumina-desktop/panel-plugins/NewPP.h | 4 ++++ .../core/lumina-desktop/panel-plugins/panel-plugins.pri | 13 +++++++++---- 3 files changed, 22 insertions(+), 10 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/core/lumina-desktop/Globals.h b/src-qt5/core/lumina-desktop/Globals.h index 14dfd93f..3df48741 100644 --- a/src-qt5/core/lumina-desktop/Globals.h +++ b/src-qt5/core/lumina-desktop/Globals.h @@ -8,17 +8,20 @@ #define _LUMINA_DESKTOP_GLOBALS_H #include <LUtils.h> +#include <LuminaXDG.h> +#include <LuminaOS.h> #include <LDesktopUtils.h> -//#include "../global.h" + +#include <QWidgetAction> +#include <QMenu> +#include <QString> +#include <QIcon> +#include <QWidget> +#include <QAction> #include <unistd.h> #include <stdio.h> -/*#ifdef __linux - // Needed for BUFSIZ - #include <stdio.h> -#endif // #ifdef __linux*/ - class Lumina{ public: enum STATES {NONE, VISIBLE, INVISIBLE, ACTIVE, NOTIFICATION, NOSHOW}; diff --git a/src-qt5/core/lumina-desktop/panel-plugins/NewPP.h b/src-qt5/core/lumina-desktop/panel-plugins/NewPP.h index 2641ad79..e811beeb 100644 --- a/src-qt5/core/lumina-desktop/panel-plugins/NewPP.h +++ b/src-qt5/core/lumina-desktop/panel-plugins/NewPP.h @@ -26,9 +26,11 @@ #include "appmenu/LAppMenuPlugin.h" #include "applauncher/AppLaunchButton.h" #include "systemstart/LStartButton.h" +#include "audioplayer/LPAudioPlayer.h" //#include "quickcontainer/QuickPPlugin.h" #include "systemtray/LSysTray.h" //must be last due to X11 compile issues + class NewPP{ public: static LPPlugin* createPlugin(QString plugin, QWidget* parent = 0, bool horizontal = true){ @@ -60,6 +62,8 @@ public: plug = new LAppMenuPlugin(parent, plugin, horizontal); }else if(plugin.startsWith("systemstart---")){ plug = new LStartButtonPlugin(parent, plugin, horizontal); + }else if(plugin.startsWith("audioplayer---")){ + plug = new LPAudioPlayer(parent, plugin, horizontal); }else if(plugin.section("---",0,0).section("::",0,0)=="applauncher"){ plug = new AppLaunchButtonPlugin(parent, plugin, horizontal); //}else if( plugin.section("---",0,0).startsWith("quick-") && LUtils::validQuickPlugin(plugin.section("---",0,0)) ){ diff --git a/src-qt5/core/lumina-desktop/panel-plugins/panel-plugins.pri b/src-qt5/core/lumina-desktop/panel-plugins/panel-plugins.pri index afa7dbe2..284d1700 100644 --- a/src-qt5/core/lumina-desktop/panel-plugins/panel-plugins.pri +++ b/src-qt5/core/lumina-desktop/panel-plugins/panel-plugins.pri @@ -18,7 +18,9 @@ SOURCES += $$PWD/userbutton/LUserButton.cpp \ $$PWD/applauncher/AppLaunchButton.cpp \ $$PWD/systemstart/LStartButton.cpp \ $$PWD/systemstart/StartMenu.cpp \ - $$PWD/systemstart/ItemWidget.cpp + $$PWD/systemstart/ItemWidget.cpp \ + $$PWD/audioplayer/LPAudioPlayer.cpp \ + $$PWD/audioplayer/PPlayerWidget.cpp HEADERS += $$PWD/userbutton/LUserButton.h \ $$PWD/userbutton/UserWidget.h \ @@ -40,10 +42,13 @@ HEADERS += $$PWD/userbutton/LUserButton.h \ $$PWD/applauncher/AppLaunchButton.h \ $$PWD/systemstart/LStartButton.h \ $$PWD/systemstart/StartMenu.h \ - $$PWD/systemstart/ItemWidget.h + $$PWD/systemstart/ItemWidget.h \ + $$PWD/audioplayer/LPAudioPlayer.h \ + $$PWD/audioplayer/PPlayerWidget.h # $$PWD/quickcontainer/QuickPPlugin.h FORMS += $$PWD/userbutton/UserWidget.ui \ $$PWD/systemdashboard/SysMenuQuick.ui \ - $$PWD/systemstart/StartMenu.ui - \ No newline at end of file + $$PWD/systemstart/StartMenu.ui \ + $$PWD/audioplayer/PPlayerWidget.ui + -- cgit From d38116c2f2140f1815aefa847b6644e6d8ef2046 Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Thu, 10 Nov 2016 14:02:35 -0500 Subject: Clean up some more of the library project files. --- src-qt5/core/libLumina/ResizeMenu.pri | 4 +-- src-qt5/core/libLumina/libLumina.pro | 68 ----------------------------------- 2 files changed, 2 insertions(+), 70 deletions(-) delete mode 100644 src-qt5/core/libLumina/libLumina.pro (limited to 'src-qt5') diff --git a/src-qt5/core/libLumina/ResizeMenu.pri b/src-qt5/core/libLumina/ResizeMenu.pri index 2b055841..247427f1 100644 --- a/src-qt5/core/libLumina/ResizeMenu.pri +++ b/src-qt5/core/libLumina/ResizeMenu.pri @@ -1,6 +1,6 @@ #Subproject file for bundling the ResizeMenu class into an application -SOURCES += $${PWD}/ResizeMenu.cpp -HEADERS += $${PWD}/ResizeMenu.h +SOURCES *= $${PWD}/ResizeMenu.cpp +HEADERS *= $${PWD}/ResizeMenu.h #Add this dir to the include path # This allows the application to simply use "#include <ResizeMenu.h>" to use it INCLUDEPATH *= $${PWD} diff --git a/src-qt5/core/libLumina/libLumina.pro b/src-qt5/core/libLumina/libLumina.pro deleted file mode 100644 index a7dc160a..00000000 --- a/src-qt5/core/libLumina/libLumina.pro +++ /dev/null @@ -1,68 +0,0 @@ -#include("$${PWD}/../../OS-detect.pri") - -#QT += core network widgets x11extras multimedia concurrent svg - -#define -#Setup any special defines (qmake -> C++) -#GIT_VERSION=$$system(git describe --always) -#!isEmpty(GIT_VERSION){ -# DEFINES += GIT_VERSION='"\\\"$${GIT_VERSION}\\\""' -#} -#DEFINES += BUILD_DATE='"\\\"$$system(date)\\\""' - -#TARGET=LuminaUtils - -#target.path = $${L_LIBDIR} - -#DESTDIR= $$_PRO_FILE_PWD_/ - -#TEMPLATE = lib -#LANGUAGE = C++ -#VERSION = 1 - -#HEADERS += LuminaXDG.h \ -# LuminaUtils.h \ -# LuminaX11.h \ -# LuminaThemes.h \ -# LuminaOS.h \ -# LuminaSingleApplication.h - -#SOURCES += LuminaXDG.cpp \ -# LuminaUtils.cpp \ -# LuminaX11.cpp \ -# LuminaThemes.cpp \ -# LuminaSingleApplication.cpp - -# Also load the OS template as available for -# LuminaOS support functions (or fall back to generic one) -#exists($${PWD}/LuminaOS-$${LINUX_DISTRO}.cpp){ -# SOURCES += LuminaOS-$${LINUX_DISTRO}.cpp -#}else:exists($${PWD}/LuminaOS-$${OS}.cpp){ -# SOURCES += LuminaOS-$${OS}.cpp -#}else{ -# SOURCES += LuminaOS-template.cpp -#} - -#LIBS += -lc -lxcb -lxcb-ewmh -lxcb-icccm -lxcb-image -lxcb-composite -lxcb-damage -lxcb-util -lXdamage - -#include.path=$${L_INCLUDEDIR} -#include.files=LuminaXDG.h \ -# LuminaUtils.h \ -# LuminaX11.h \ -# LuminaThemes.h \ -# LuminaOS.h \ -# LuminaSingleApplication.h - -colors.path=$${L_SHAREDIR}/lumina-desktop/colors -colors.files=colors/*.qss.colors - -themes.path=$${L_SHAREDIR}/lumina-desktop/themes/ -themes.files=themes/*.qss.template - -#quickplugins.path=$${L_SHAREDIR}/lumina-desktop/quickplugins/ -#quickplugins.files=quickplugins/* - -globs.path=$${L_SHAREDIR}/lumina-desktop -globs.files=xtrafiles/globs2 - -INSTALLS += colors themes globs -- cgit From 48c40ab76e4131d5fba86b772434d1c6f3bc2c0f Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Thu, 10 Nov 2016 14:05:11 -0500 Subject: Make lumina-config aware of the new "audioplayer" panel plugin. --- src-qt5/core-utils/lumina-config/LPlugins.cpp | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'src-qt5') diff --git a/src-qt5/core-utils/lumina-config/LPlugins.cpp b/src-qt5/core-utils/lumina-config/LPlugins.cpp index e48910c7..089a181c 100644 --- a/src-qt5/core-utils/lumina-config/LPlugins.cpp +++ b/src-qt5/core-utils/lumina-config/LPlugins.cpp @@ -166,6 +166,13 @@ void LPlugins::LoadPanelPlugins(){ info.ID = "applauncher"; info.icon = "quickopen"; PANEL.insert(info.ID, info); + //Audio Player Plugin + info = LPI(); //clear it + info.name = QObject::tr("Audio Player"); + info.description = QObject::tr("Play through lists of audio files"); + info.ID = "audioplayer"; + info.icon = "media-playback-start"; + PANEL.insert(info.ID, info); } // DESKTOP PLUGINS -- cgit From 4a84a25874dc0486d7a4514c84b0c63eac6f3873 Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Thu, 10 Nov 2016 15:35:34 -0500 Subject: If lumina-textedit is opened without any arguments, automatically open a blank/new file. --- src-qt5/desktop-utils/lumina-textedit/MainUI.cpp | 3 +++ 1 file changed, 3 insertions(+) (limited to 'src-qt5') diff --git a/src-qt5/desktop-utils/lumina-textedit/MainUI.cpp b/src-qt5/desktop-utils/lumina-textedit/MainUI.cpp index 4a7fbabf..88f7bf00 100644 --- a/src-qt5/desktop-utils/lumina-textedit/MainUI.cpp +++ b/src-qt5/desktop-utils/lumina-textedit/MainUI.cpp @@ -92,6 +92,9 @@ void MainUI::LoadArguments(QStringList args){ //CLI arguments if(ui->groupReplace->isVisible()){ ui->line_find->setFocus(); } else{ currentEditor()->setFocus(); } } + if(ui->tabWidget->count()<1){ + NewFile(); + } } // ================= -- cgit From 4a73dcc40afd2257588cee0656119dfe985efa3e Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Fri, 11 Nov 2016 09:14:40 -0500 Subject: Oops - forgot to add some files to the previous commits. --- src-qt5/core/lumina-desktop/Globals.h | 1 + src-qt5/core/lumina-desktop/panel-plugins/NewPP.h | 3 + .../panel-plugins/audioplayer/LPAudioPlayer.cpp | 30 +++ .../panel-plugins/audioplayer/LPAudioPlayer.h | 49 ++++ .../panel-plugins/audioplayer/PPlayerWidget.cpp | 258 +++++++++++++++++++++ .../panel-plugins/audioplayer/PPlayerWidget.h | 59 +++++ .../panel-plugins/audioplayer/PPlayerWidget.ui | 182 +++++++++++++++ .../panel-plugins/jsonmenu/PPJsonMenu.cpp | 35 +++ .../panel-plugins/jsonmenu/PPJsonMenu.h | 42 ++++ .../lumina-desktop/panel-plugins/panel-plugins.pri | 6 +- 10 files changed, 663 insertions(+), 2 deletions(-) create mode 100644 src-qt5/core/lumina-desktop/panel-plugins/audioplayer/LPAudioPlayer.cpp create mode 100644 src-qt5/core/lumina-desktop/panel-plugins/audioplayer/LPAudioPlayer.h create mode 100644 src-qt5/core/lumina-desktop/panel-plugins/audioplayer/PPlayerWidget.cpp create mode 100644 src-qt5/core/lumina-desktop/panel-plugins/audioplayer/PPlayerWidget.h create mode 100644 src-qt5/core/lumina-desktop/panel-plugins/audioplayer/PPlayerWidget.ui create mode 100644 src-qt5/core/lumina-desktop/panel-plugins/jsonmenu/PPJsonMenu.cpp create mode 100644 src-qt5/core/lumina-desktop/panel-plugins/jsonmenu/PPJsonMenu.h (limited to 'src-qt5') diff --git a/src-qt5/core/lumina-desktop/Globals.h b/src-qt5/core/lumina-desktop/Globals.h index 3df48741..15e7a4b6 100644 --- a/src-qt5/core/lumina-desktop/Globals.h +++ b/src-qt5/core/lumina-desktop/Globals.h @@ -18,6 +18,7 @@ #include <QIcon> #include <QWidget> #include <QAction> +#include <QToolButton> #include <unistd.h> #include <stdio.h> diff --git a/src-qt5/core/lumina-desktop/panel-plugins/NewPP.h b/src-qt5/core/lumina-desktop/panel-plugins/NewPP.h index e811beeb..3a5f6a5b 100644 --- a/src-qt5/core/lumina-desktop/panel-plugins/NewPP.h +++ b/src-qt5/core/lumina-desktop/panel-plugins/NewPP.h @@ -27,6 +27,7 @@ #include "applauncher/AppLaunchButton.h" #include "systemstart/LStartButton.h" #include "audioplayer/LPAudioPlayer.h" +#include "jsonmenu/PPJsonMenu.h" //#include "quickcontainer/QuickPPlugin.h" #include "systemtray/LSysTray.h" //must be last due to X11 compile issues @@ -64,6 +65,8 @@ public: plug = new LStartButtonPlugin(parent, plugin, horizontal); }else if(plugin.startsWith("audioplayer---")){ plug = new LPAudioPlayer(parent, plugin, horizontal); + }else if(plugin.section("::::",0,0)=="jsonmenu" && plugin.split("::::").length()>=3 ){ + plug = new LPJsonMenu(parent, plugin, horizontal); }else if(plugin.section("---",0,0).section("::",0,0)=="applauncher"){ plug = new AppLaunchButtonPlugin(parent, plugin, horizontal); //}else if( plugin.section("---",0,0).startsWith("quick-") && LUtils::validQuickPlugin(plugin.section("---",0,0)) ){ diff --git a/src-qt5/core/lumina-desktop/panel-plugins/audioplayer/LPAudioPlayer.cpp b/src-qt5/core/lumina-desktop/panel-plugins/audioplayer/LPAudioPlayer.cpp new file mode 100644 index 00000000..5669aaf5 --- /dev/null +++ b/src-qt5/core/lumina-desktop/panel-plugins/audioplayer/LPAudioPlayer.cpp @@ -0,0 +1,30 @@ +//=========================================== +// Lumina-DE source code +// Copyright (c) 2014, Susanne Jaeckel +// Available under the 3-clause BSD license +// See the LICENSE file for full details +//=========================================== +#include "LPAudioPlayer.h" +#include "LSession.h" + +LPAudioPlayer::LPAudioPlayer(QWidget *parent, QString id, bool horizontal) : LPPlugin(parent, id, horizontal){ + //Setup the button + button = new QToolButton(this); + button->setAutoRaise(true); + button->setToolButtonStyle(Qt::ToolButtonIconOnly); + button->setPopupMode(QToolButton::InstantPopup); //make sure it runs the update routine first + //connect(button, SIGNAL(clicked()), this, SLOT(openMenu())); + this->layout()->setContentsMargins(0,0,0,0); + this->layout()->addWidget(button); + wact = new QWidgetAction(this); + aplayer = new PPlayerWidget(this); + button ->setMenu(new QMenu(this) ); + wact->setDefaultWidget(aplayer); + button->menu()->addAction(wact); + //Now start up the widgets + button->setIcon( LXDG::findIcon("audio-volume-high","") ); + QTimer::singleShot(0,this,SLOT(OrientationChange()) ); //update the sizing/icon +} + +LPAudioPlayer::~LPAudioPlayer(){ +} diff --git a/src-qt5/core/lumina-desktop/panel-plugins/audioplayer/LPAudioPlayer.h b/src-qt5/core/lumina-desktop/panel-plugins/audioplayer/LPAudioPlayer.h new file mode 100644 index 00000000..e5132b1f --- /dev/null +++ b/src-qt5/core/lumina-desktop/panel-plugins/audioplayer/LPAudioPlayer.h @@ -0,0 +1,49 @@ +//=========================================== +// Lumina-DE source code +// Copyright (c) 2016, Ken Moore +// Available under the 3-clause BSD license +// See the LICENSE file for full details +//=========================================== +#ifndef _LUMINA_PANEL_AUDIO_PLAYER_PLUGIN_H +#define _LUMINA_PANEL_AUDIO_PLAYER_PLUGIN_H + +#include "../../Globals.h" +#include "../LTBWidget.h" +#include "../LPPlugin.h" +#include "PPlayerWidget.h" + +class LPAudioPlayer : public LPPlugin{ + Q_OBJECT +public: + LPAudioPlayer(QWidget *parent = 0, QString id = "audioplayer", bool horizontal=true); + ~LPAudioPlayer(); + +private: + QToolButton *button; + QWidgetAction *wact; + PPlayerWidget *aplayer; + + //int iconOld; + +private slots: + //void updateBattery(bool force = false); + //QString getRemainingTime(); + +public slots: + void LocaleChange(){ + //updateBattery(true); + } + + void OrientationChange(){ + if(this->layout()->direction()==QBoxLayout::LeftToRight){ + this->setSizePolicy(QSizePolicy::Preferred, QSizePolicy::MinimumExpanding); + button->setIconSize( QSize(this->height(), this->height()) ); + }else{ + this->setSizePolicy(QSizePolicy::MinimumExpanding, QSizePolicy::Preferred); + button->setIconSize( QSize(this->width(), this->width()) ); + } + this->layout()->update(); + } +}; + +#endif diff --git a/src-qt5/core/lumina-desktop/panel-plugins/audioplayer/PPlayerWidget.cpp b/src-qt5/core/lumina-desktop/panel-plugins/audioplayer/PPlayerWidget.cpp new file mode 100644 index 00000000..023e20c7 --- /dev/null +++ b/src-qt5/core/lumina-desktop/panel-plugins/audioplayer/PPlayerWidget.cpp @@ -0,0 +1,258 @@ +//=========================================== +// Lumina-DE source code +// Copyright (c) 2015, Ken Moore +// Available under the 3-clause BSD license +// See the LICENSE file for full details +//=========================================== +#include "PPlayerWidget.h" +#include "ui_PPlayerWidget.h" + +#include <QDir> +#include <QUrl> +#include <QInputDialog> +#include <QFileDialog> +#include <LuminaXDG.h> +#include <QDebug> +#include <QDesktopWidget> + +PPlayerWidget::PPlayerWidget(QWidget *parent) : QWidget(parent), ui(new Ui::PPlayerWidget()){ + ui->setupUi(this); //load the designer form + PLAYER = new QMediaPlayer(this); + PLAYER->setVolume(100); + PLAYER->setNotifyInterval(1000); //1 second interval (just needs to be a rough estimate) + PLAYLIST = new QMediaPlaylist(this); + PLAYLIST->setPlaybackMode(QMediaPlaylist::Sequential); + PLAYER->setPlaylist(PLAYLIST); + + configMenu = new QMenu(this); + ui->tool_config->setMenu(configMenu); + addMenu = new QMenu(this); + ui->tool_add->setMenu(addMenu); + + updatinglists = false; //start off as false + + ui->combo_playlist->setContextMenuPolicy(Qt::NoContextMenu); + + LoadIcons(); + playerStateChanged(); //update button visibility + currentSongChanged(); + //Connect all the signals/slots + //connect(infoTimer, SIGNAL(timeout()), this, SLOT(rotateTrackInfo()) ); + connect(PLAYER, SIGNAL(positionChanged(qint64)),this, SLOT(updateProgress(qint64)) ); + connect(PLAYER, SIGNAL(durationChanged(qint64)), this, SLOT(updateMaxProgress(qint64)) ); + connect(PLAYLIST, SIGNAL(mediaChanged(int, int)), this, SLOT(playlistChanged()) ); + connect(PLAYER, SIGNAL(stateChanged(QMediaPlayer::State)), this, SLOT(playerStateChanged()) ); + connect(PLAYLIST, SIGNAL(currentMediaChanged(const QMediaContent&)), this, SLOT(currentSongChanged()) ); + connect(ui->combo_playlist, SIGNAL(currentIndexChanged(int)), this, SLOT(userlistSelectionChanged()) ); + connect(ui->tool_play, SIGNAL(clicked()), this, SLOT(playClicked()) ); + connect(ui->tool_pause, SIGNAL(clicked()), this, SLOT(pauseClicked()) ); + connect(ui->tool_stop, SIGNAL(clicked()), this, SLOT(stopClicked()) ); + connect(ui->tool_next, SIGNAL(clicked()), this, SLOT(nextClicked()) ); + connect(ui->tool_prev, SIGNAL(clicked()), this, SLOT(prevClicked()) ); + +} + +PPlayerWidget::~PPlayerWidget(){ + //qDebug() << "Removing PPlayerWidget"; +} + +void PPlayerWidget::LoadIcons(){ + ui->tool_stop->setIcon( LXDG::findIcon("media-playback-stop","") ); + ui->tool_play->setIcon( LXDG::findIcon("media-playback-start","") ); + ui->tool_pause->setIcon( LXDG::findIcon("media-playback-pause","") ); + ui->tool_next->setIcon( LXDG::findIcon("media-skip-forward","") ); + ui->tool_prev->setIcon( LXDG::findIcon("media-skip-backward","") ); + ui->tool_add->setIcon( LXDG::findIcon("list-add","") ); + ui->tool_config->setIcon( LXDG::findIcon("configure","") ); + //Now re-assemble the menus as well + configMenu->clear(); + configMenu->addAction(LXDG::findIcon("media-eject",""), tr("Clear Playlist"), this, SLOT(ClearPlaylist())); + configMenu->addAction(LXDG::findIcon("roll",""), tr("Shuffle Playlist"), this, SLOT(ShufflePlaylist())); + addMenu->clear(); + addMenu->addAction(LXDG::findIcon("document-new",""), tr("Add Files"), this, SLOT(AddFilesToPlaylist())); + addMenu->addAction(LXDG::findIcon("folder-new",""), tr("Add Directory"), this, SLOT(AddDirToPlaylist())); + addMenu->addAction(LXDG::findIcon("download",""), tr("Add URL"), this, SLOT(AddURLToPlaylist())); +} + +void PPlayerWidget::playClicked(){ + PLAYER->play(); +} + +void PPlayerWidget::pauseClicked(){ + PLAYER->pause(); +} + +void PPlayerWidget::stopClicked(){ + PLAYER->stop(); +} + +void PPlayerWidget::nextClicked(){ + PLAYLIST->next(); +} + +void PPlayerWidget::prevClicked(){ + PLAYLIST->previous(); +} + +void PPlayerWidget::AddFilesToPlaylist(){ + //Prompt the user to select multimedia files + QFileDialog dlg(0, Qt::Dialog | Qt::WindowStaysOnTopHint ); + dlg.setFileMode(QFileDialog::ExistingFiles); + dlg.setAcceptMode(QFileDialog::AcceptOpen); + dlg.setNameFilter( tr("Multimedia Files")+" ("+LXDG::findAVFileExtensions().join(" ")+")"); + dlg.setWindowTitle(tr("Select Multimedia Files")); + dlg.setWindowIcon( LXDG::findIcon("file-open","") ); + dlg.setDirectory(QDir::homePath()); //start in the home directory + //ensure it is centered on the current screen + QPoint center = QApplication::desktop()->screenGeometry(this).center(); + dlg.move( center.x()-(dlg.width()/2), center.y()-(dlg.height()/2) ); + dlg.show(); + while( dlg.isVisible() ){ + QApplication::processEvents(); + } + QList<QUrl> files = dlg.selectedUrls(); + if(files.isEmpty() || dlg.result()!=QDialog::Accepted){ return; } //cancelled + //Make this use show/processEvents later + //QList<QUrl> files = QFileDialog::getOpenFileUrls(0, tr("Select Multimedia Files"), QDir::homePath(), "Multimedia Files ("+LXDG::findAVFileExtensions().join(" ")+")"); + QList<QMediaContent> urls; + for(int i=0; i<files.length(); i++){ + urls << QMediaContent(files[i]); + } + PLAYLIST->addMedia(urls); + playlistChanged(); +} + +void PPlayerWidget::AddDirToPlaylist(){ + QFileDialog dlg(0, Qt::Dialog | Qt::WindowStaysOnTopHint ); + dlg.setFileMode(QFileDialog::Directory); + dlg.setOption(QFileDialog::ShowDirsOnly, true); + dlg.setAcceptMode(QFileDialog::AcceptOpen); + dlg.setWindowTitle(tr("Select Multimedia Directory")); + dlg.setWindowIcon( LXDG::findIcon("folder-open","") ); + dlg.setDirectory(QDir::homePath()); //start in the home directory + //ensure it is centered on the current screen + QPoint center = QApplication::desktop()->screenGeometry(this).center(); + dlg.move( center.x()-(dlg.width()/2), center.y()-(dlg.height()/2) ); + dlg.show(); + while( dlg.isVisible() ){ + QApplication::processEvents(); + } + if(dlg.result() != QDialog::Accepted){ return; } //cancelled + QStringList sel = dlg.selectedFiles(); + if(sel.isEmpty()){ return; } //cancelled + QString dirpath = sel.first(); //QFileDialog::getExistingDirectory(0, tr("Select a Multimedia Directory"), QDir::homePath() ); + if(dirpath.isEmpty()){ return; } //cancelled + QDir dir(dirpath); + QFileInfoList files = dir.entryInfoList(LXDG::findAVFileExtensions(), QDir::Files | QDir::NoDotAndDotDot, QDir::Name); + if(files.isEmpty()){ return; } //nothing in this directory + QList<QMediaContent> urls; + for(int i=0; i<files.length(); i++){ + urls << QMediaContent(QUrl::fromLocalFile(files[i].absoluteFilePath()) ); + } + PLAYLIST->addMedia(urls); + playlistChanged(); +} + +void PPlayerWidget::AddURLToPlaylist(){ + QInputDialog dlg(0, Qt::Dialog | Qt::WindowStaysOnTopHint ); + dlg.setInputMode(QInputDialog::TextInput); + dlg.setLabelText(tr("Enter a valid URL for a multimedia file or stream:")); + dlg.setTextEchoMode(QLineEdit::Normal); + dlg.setWindowTitle(tr("Multimedia URL")); + dlg.setWindowIcon( LXDG::findIcon("download","") ); + //ensure it is centered on the current screen + QPoint center = QApplication::desktop()->screenGeometry(this).center(); + dlg.move( center.x()-(dlg.width()/2), center.y()-(dlg.height()/2) ); + dlg.show(); + while( dlg.isVisible() ){ + QApplication::processEvents(); + } + QString url = dlg.textValue(); + if(url.isEmpty() || dlg.result()!=QDialog::Accepted){ return; } //cancelled + + //QString url = QInputDialog::getText(0, tr("Multimedia URL"), tr("Enter a valid URL for a multimedia file or stream"), QLineEdit::Normal); + //if(url.isEmpty()){ return; } + QUrl newurl(url); + if(!newurl.isValid()){ return; } //invalid URL + PLAYLIST->addMedia(newurl); + playlistChanged(); +} + +void PPlayerWidget::ClearPlaylist(){ + PLAYER->stop(); + PLAYLIST->clear(); + playlistChanged(); +} + +void PPlayerWidget::ShufflePlaylist(){ + PLAYLIST->shuffle(); +} + + +void PPlayerWidget::userlistSelectionChanged(){ //front-end combobox was changed by the user + if(updatinglists){ return; } + PLAYLIST->setCurrentIndex( ui->combo_playlist->currentIndex() ); +} + +void PPlayerWidget::playerStateChanged(){ + switch( PLAYER->state() ){ + case QMediaPlayer::StoppedState: + ui->tool_stop->setVisible(false); + ui->tool_play->setVisible(true); + ui->tool_pause->setVisible(false); + ui->progressBar->setVisible(false); + break; + case QMediaPlayer::PausedState: + ui->tool_stop->setVisible(true); + ui->tool_play->setVisible(true); + ui->tool_pause->setVisible(false); + ui->progressBar->setVisible(true); + break; + case QMediaPlayer::PlayingState: + ui->tool_stop->setVisible(true); + ui->tool_play->setVisible(false); + ui->tool_pause->setVisible(true); + ui->progressBar->setVisible(true); + break; + } + +} + +void PPlayerWidget::playlistChanged(){ + updatinglists = true; + ui->combo_playlist->clear(); + for(int i=0; i<PLAYLIST->mediaCount(); i++){ + QUrl url = PLAYLIST->media(i).canonicalUrl(); + if(url.isLocalFile()){ + ui->combo_playlist->addItem(LXDG::findMimeIcon(url.fileName().section(".",-1)), url.fileName() ); + }else{ + ui->combo_playlist->addItem(LXDG::findIcon("download",""), url.toString() ); + } + } + if(PLAYLIST->currentIndex()<0 && PLAYLIST->mediaCount()>0){ PLAYLIST->setCurrentIndex(0); } + ui->combo_playlist->setCurrentIndex(PLAYLIST->currentIndex()); + + updatinglists = false; +} + +void PPlayerWidget::currentSongChanged(){ + if(PLAYLIST->currentIndex() != ui->combo_playlist->currentIndex()){ + updatinglists = true; + ui->combo_playlist->setCurrentIndex(PLAYLIST->currentIndex()); + updatinglists = false; + } + ui->tool_next->setEnabled( PLAYLIST->nextIndex() >= 0 ); + ui->tool_prev->setEnabled( PLAYLIST->previousIndex() >= 0); + ui->label_num->setText( QString::number( PLAYLIST->currentIndex()+1)+"/"+QString::number(PLAYLIST->mediaCount()) ); + ui->progressBar->setRange(0, PLAYER->duration() ); + ui->progressBar->setValue(0); +} + +void PPlayerWidget::updateProgress(qint64 val){ + //qDebug() << "Update Progress Bar:" << val; + ui->progressBar->setValue(val); +} + +void PPlayerWidget::updateMaxProgress(qint64 val){ + ui->progressBar->setRange(0,val); +} diff --git a/src-qt5/core/lumina-desktop/panel-plugins/audioplayer/PPlayerWidget.h b/src-qt5/core/lumina-desktop/panel-plugins/audioplayer/PPlayerWidget.h new file mode 100644 index 00000000..a551d74f --- /dev/null +++ b/src-qt5/core/lumina-desktop/panel-plugins/audioplayer/PPlayerWidget.h @@ -0,0 +1,59 @@ +//=========================================== +// Lumina-DE source code +// Copyright (c) 2015, Ken Moore +// Available under the 3-clause BSD license +// See the LICENSE file for full details +//=========================================== +// This plugin is a simple audio player on the desktop +//=========================================== +#ifndef _LUMINA_PANEL_PLUGIN_AUDIO_PLAYER_WIDGET_H +#define _LUMINA_PANEL_PLUGIN_AUDIO_PLAYER_WIDGET_H + +#include <QMediaPlaylist> +#include <QMediaPlayer> +#include <QTimer> +#include <QWidget> +#include <QMenu> + + +namespace Ui{ + class PPlayerWidget; +}; + +class PPlayerWidget : public QWidget{ + Q_OBJECT +public: + PPlayerWidget(QWidget *parent = 0); + ~PPlayerWidget(); + +public slots: + void LoadIcons(); + +private: + Ui::PPlayerWidget *ui; + QMediaPlaylist *PLAYLIST; + QMediaPlayer *PLAYER; + QMenu *configMenu, *addMenu; + bool updatinglists; + +private slots: + void playClicked(); + void pauseClicked(); + void stopClicked(); + void nextClicked(); + void prevClicked(); + + void AddFilesToPlaylist(); + void AddDirToPlaylist(); + void AddURLToPlaylist(); + void ClearPlaylist(); + void ShufflePlaylist(); + void userlistSelectionChanged(); //front-end combobox was changed by the user + void playerStateChanged(); + void playlistChanged(); //list of items changed + void currentSongChanged(); + void updateProgress(qint64 val); + void updateMaxProgress(qint64 val); +}; + +#endif diff --git a/src-qt5/core/lumina-desktop/panel-plugins/audioplayer/PPlayerWidget.ui b/src-qt5/core/lumina-desktop/panel-plugins/audioplayer/PPlayerWidget.ui new file mode 100644 index 00000000..2d2450be --- /dev/null +++ b/src-qt5/core/lumina-desktop/panel-plugins/audioplayer/PPlayerWidget.ui @@ -0,0 +1,182 @@ +<?xml version="1.0" encoding="UTF-8"?> +<ui version="4.0"> + <class>PPlayerWidget</class> + <widget class="QWidget" name="PPlayerWidget"> + <property name="geometry"> + <rect> + <x>0</x> + <y>0</y> + <width>346</width> + <height>90</height> + </rect> + </property> + <property name="windowTitle"> + <string>Form</string> + </property> + <property name="styleSheet"> + <string notr="true">QToolButton::menu-indicator{ image: none; }</string> + </property> + <layout class="QVBoxLayout" name="verticalLayout"> + <property name="spacing"> + <number>4</number> + </property> + <property name="leftMargin"> + <number>0</number> + </property> + <property name="topMargin"> + <number>0</number> + </property> + <property name="rightMargin"> + <number>0</number> + </property> + <property name="bottomMargin"> + <number>0</number> + </property> + <item> + <layout class="QHBoxLayout" name="horizontalLayout_2"> + <item> + <widget class="QToolButton" name="tool_config"> + <property name="text"> + <string notr="true">Config</string> + </property> + <property name="popupMode"> + <enum>QToolButton::InstantPopup</enum> + </property> + <property name="autoRaise"> + <bool>true</bool> + </property> + </widget> + </item> + <item> + <widget class="QToolButton" name="tool_add"> + <property name="text"> + <string notr="true">Add</string> + </property> + <property name="popupMode"> + <enum>QToolButton::InstantPopup</enum> + </property> + <property name="autoRaise"> + <bool>true</bool> + </property> + </widget> + </item> + <item> + <spacer name="horizontalSpacer"> + <property name="orientation"> + <enum>Qt::Horizontal</enum> + </property> + <property name="sizeHint" stdset="0"> + <size> + <width>40</width> + <height>20</height> + </size> + </property> + </spacer> + </item> + <item> + <widget class="QToolButton" name="tool_prev"> + <property name="text"> + <string notr="true">prev</string> + </property> + <property name="autoRaise"> + <bool>true</bool> + </property> + </widget> + </item> + <item> + <widget class="QLabel" name="label_num"> + <property name="text"> + <string notr="true">1/10</string> + </property> + </widget> + </item> + <item> + <widget class="QToolButton" name="tool_next"> + <property name="text"> + <string notr="true">next</string> + </property> + <property name="autoRaise"> + <bool>true</bool> + </property> + </widget> + </item> + </layout> + </item> + <item> + <widget class="QComboBox" name="combo_playlist"/> + </item> + <item> + <layout class="QHBoxLayout" name="horizontalLayout"> + <item> + <widget class="QToolButton" name="tool_play"> + <property name="text"> + <string notr="true">Play</string> + </property> + <property name="autoRaise"> + <bool>true</bool> + </property> + </widget> + </item> + <item> + <widget class="QToolButton" name="tool_pause"> + <property name="text"> + <string notr="true">Pause</string> + </property> + <property name="autoRaise"> + <bool>true</bool> + </property> + </widget> + </item> + <item> + <widget class="QToolButton" name="tool_stop"> + <property name="text"> + <string notr="true">Stop</string> + </property> + <property name="autoRaise"> + <bool>true</bool> + </property> + </widget> + </item> + <item> + <spacer name="horizontalSpacer_2"> + <property name="orientation"> + <enum>Qt::Horizontal</enum> + </property> + <property name="sizeHint" stdset="0"> + <size> + <width>40</width> + <height>20</height> + </size> + </property> + </spacer> + </item> + <item> + <widget class="QProgressBar" name="progressBar"> + <property name="value"> + <number>24</number> + </property> + <property name="textVisible"> + <bool>false</bool> + </property> + </widget> + </item> + </layout> + </item> + <item> + <spacer name="verticalSpacer"> + <property name="orientation"> + <enum>Qt::Vertical</enum> + </property> + <property name="sizeHint" stdset="0"> + <size> + <width>20</width> + <height>0</height> + </size> + </property> + </spacer> + </item> + </layout> + </widget> + <resources/> + <connections/> +</ui> diff --git a/src-qt5/core/lumina-desktop/panel-plugins/jsonmenu/PPJsonMenu.cpp b/src-qt5/core/lumina-desktop/panel-plugins/jsonmenu/PPJsonMenu.cpp new file mode 100644 index 00000000..14880f9b --- /dev/null +++ b/src-qt5/core/lumina-desktop/panel-plugins/jsonmenu/PPJsonMenu.cpp @@ -0,0 +1,35 @@ +//=========================================== +// Lumina Desktop source code +// Copyright (c) 2016, Ken Moore +// Available under the 3-clause BSD license +// See the LICENSE file for full details +//=========================================== +#include "PPJsonMenu.h" +#include "../../JsonMenu.h" + +LPJsonMenu::LPJsonMenu(QWidget *parent, QString id, bool horizontal) : LPPlugin(parent, id, horizontal){ + //Setup the button + button = new QToolButton(this); + button->setAutoRaise(true); + button->setToolButtonStyle(Qt::ToolButtonIconOnly); + button->setPopupMode(QToolButton::InstantPopup); //make sure it runs the update routine first + //connect(button, SIGNAL(clicked()), this, SLOT(openMenu())); + this->layout()->setContentsMargins(0,0,0,0); + this->layout()->addWidget(button); + //Parse the id and get the extra information needed for the plugin + QStringList info = id.section("---",0,0).split("::::"); //FORMAT:[ "jsonmenu---<number>",exec,name, icon(optional)] + if(info.length()>=3){ + qDebug() << "Custom JSON Menu Loaded:" << info; + JsonMenu *menu = new JsonMenu(info[1], button); + button->setText(info[2]); + //connect(menu, SIGNAL(triggered(QAction*)), this, SLOT(SystemApplication(QAction*)) ); + if(info.length()>=4){ button->setIcon( LXDG::findIcon(info[3],"run-build") ); } + else{ button->setIcon( LXDG::findIcon("run-build","") ); } + button->setMenu(menu); + } + //Now start up the widgets + QTimer::singleShot(0,this,SLOT(OrientationChange()) ); //update the sizing/icon +} + +LPJsonMenu::~LPJsonMenu(){ +} diff --git a/src-qt5/core/lumina-desktop/panel-plugins/jsonmenu/PPJsonMenu.h b/src-qt5/core/lumina-desktop/panel-plugins/jsonmenu/PPJsonMenu.h new file mode 100644 index 00000000..d0827fd2 --- /dev/null +++ b/src-qt5/core/lumina-desktop/panel-plugins/jsonmenu/PPJsonMenu.h @@ -0,0 +1,42 @@ +//=========================================== +// Lumina-DE source code +// Copyright (c) 2016, Ken Moore +// Available under the 3-clause BSD license +// See the LICENSE file for full details +//=========================================== +#ifndef _LUMINA_PANEL_JSON_PLUGIN_H +#define _LUMINA_PANEL_JSON_PLUGIN_H + +#include "../../Globals.h" +#include "../LPPlugin.h" + + +class LPJsonMenu : public LPPlugin{ + Q_OBJECT +public: + LPJsonMenu(QWidget *parent = 0, QString id = "jsonmenu", bool horizontal=true); + ~LPJsonMenu(); + +private: + QToolButton *button; + +private slots: + //void SystemApplication(QAction*); + +public slots: + void LocaleChange(){ + } + + void OrientationChange(){ + if(this->layout()->direction()==QBoxLayout::LeftToRight){ + this->setSizePolicy(QSizePolicy::Preferred, QSizePolicy::MinimumExpanding); + button->setIconSize( QSize(this->height(), this->height()) ); + }else{ + this->setSizePolicy(QSizePolicy::MinimumExpanding, QSizePolicy::Preferred); + button->setIconSize( QSize(this->width(), this->width()) ); + } + this->layout()->update(); + } +}; + +#endif diff --git a/src-qt5/core/lumina-desktop/panel-plugins/panel-plugins.pri b/src-qt5/core/lumina-desktop/panel-plugins/panel-plugins.pri index 284d1700..9db23968 100644 --- a/src-qt5/core/lumina-desktop/panel-plugins/panel-plugins.pri +++ b/src-qt5/core/lumina-desktop/panel-plugins/panel-plugins.pri @@ -20,7 +20,8 @@ SOURCES += $$PWD/userbutton/LUserButton.cpp \ $$PWD/systemstart/StartMenu.cpp \ $$PWD/systemstart/ItemWidget.cpp \ $$PWD/audioplayer/LPAudioPlayer.cpp \ - $$PWD/audioplayer/PPlayerWidget.cpp + $$PWD/audioplayer/PPlayerWidget.cpp \ + $$PWD/jsonmenu/PPJsonMenu.cpp HEADERS += $$PWD/userbutton/LUserButton.h \ $$PWD/userbutton/UserWidget.h \ @@ -44,7 +45,8 @@ HEADERS += $$PWD/userbutton/LUserButton.h \ $$PWD/systemstart/StartMenu.h \ $$PWD/systemstart/ItemWidget.h \ $$PWD/audioplayer/LPAudioPlayer.h \ - $$PWD/audioplayer/PPlayerWidget.h + $$PWD/audioplayer/PPlayerWidget.h \ + $$PWD/jsonmenu/PPJsonMenu.h # $$PWD/quickcontainer/QuickPPlugin.h FORMS += $$PWD/userbutton/UserWidget.ui \ -- cgit From 522e8444ec27ff825a33d7447a0011cc8b5749c1 Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Fri, 11 Nov 2016 17:31:40 -0500 Subject: Fix up the panel autohide routine so it actually resizes the panels instead of just moving them around. --- src-qt5/core/lumina-desktop/LPanel.cpp | 44 ++++++++++++++++++++++++++-------- src-qt5/core/lumina-desktop/LPanel.h | 4 +++- 2 files changed, 37 insertions(+), 11 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/core/lumina-desktop/LPanel.cpp b/src-qt5/core/lumina-desktop/LPanel.cpp index 933dc778..62534acb 100644 --- a/src-qt5/core/lumina-desktop/LPanel.cpp +++ b/src-qt5/core/lumina-desktop/LPanel.cpp @@ -121,6 +121,7 @@ void LPanel::UpdatePanel(bool geomonly){ layout->setDirection(QBoxLayout::TopToBottom); } int ht = qRound(settings->value(PPREFIX+"height", 30).toDouble()); //this is technically the distance into the screen from the edge + fullwidth = ht; //save this for later if(ht<=1){ ht = 30; } //some kind of error in the saved height - use the default value int hidesize = qRound(ht*0.01); //use 1% of the panel size if(hidesize<2){ hidesize=2; } //minimum of 2 pixels (need space for the mouse to go over it) @@ -151,9 +152,10 @@ void LPanel::UpdatePanel(bool geomonly){ if(!hidden){ LSession::handle()->XCB->ReserveLocation(this->winId(), this->geometry(), "top"); } else{ LSession::handle()->XCB->ReserveLocation(this->winId(), QRect(xloc, yloc, this->width(), hidesize), "top"); - hidepoint = QPoint(xloc, yloc+hidesize-ht); + hidepoint = QPoint(xloc, yloc); showpoint = QPoint(xloc, yloc); - this->move(hidepoint); //Could bleed over onto the screen above + this->move(hidepoint); + this->resize( this->width(), viswidth); } }else if(loc=="bottom"){ //bottom of screen QSize sz = QSize(xwid*panelPercent, ht); @@ -169,6 +171,7 @@ void LPanel::UpdatePanel(bool geomonly){ hidepoint = QPoint(xloc, yloc+xhi-hidesize); showpoint = QPoint(xloc, yloc+xhi-ht); this->move(hidepoint); //Could bleed over onto the screen below + this->resize( this->width(), viswidth); } }else if(loc=="left"){ //left side of screen QSize sz = QSize(ht, xhi*panelPercent); @@ -181,9 +184,10 @@ void LPanel::UpdatePanel(bool geomonly){ if(!hidden){ LSession::handle()->XCB->ReserveLocation(this->winId(), this->geometry(), "left"); } else{ LSession::handle()->XCB->ReserveLocation(this->winId(), QRect(xloc, yloc, hidesize, sz.height()), "left"); - hidepoint = QPoint(xloc-ht+hidesize, yloc); + hidepoint = QPoint(xloc, yloc); showpoint = QPoint(xloc, yloc); this->move(hidepoint); //Could bleed over onto the screen left + this->resize( viswidth, this->height()); } }else{ //right side of screen QSize sz = QSize(ht, xhi*panelPercent); @@ -199,6 +203,7 @@ void LPanel::UpdatePanel(bool geomonly){ hidepoint = QPoint(xloc+xwid-hidesize, yloc); showpoint = QPoint(xloc+xwid-ht, yloc); this->move(hidepoint); //Could bleed over onto the screen right + this->resize( viswidth, this->height()); } } if(DEBUG){ qDebug() << " - Done with panel geometry"; } @@ -265,7 +270,7 @@ void LPanel::UpdatePanel(bool geomonly){ i--; //make sure we don't miss the next item with the re-order } } - LSession::processEvents(); + //LSession::processEvents(); } //Now remove any extra plugins from the end //qDebug() << "plugins:" << plugins; @@ -279,7 +284,7 @@ void LPanel::UpdatePanel(bool geomonly){ } layout->takeAt(i); //remove from the layout PLUGINS.takeAt(i)->deleteLater(); //delete the actual widget - LSession::processEvents(); + //LSession::processEvents(); i--; //need to back up one space to not miss another plugin } this->update(); @@ -289,7 +294,8 @@ void LPanel::UpdatePanel(bool geomonly){ for(int i=0; i<PLUGINS.length(); i++){ QTimer::singleShot(0,PLUGINS[i], SLOT(OrientationChange())); } - LSession::processEvents(); + checkPanelFocus(); + //LSession::processEvents(); } void LPanel::UpdateLocale(){ @@ -310,13 +316,24 @@ void LPanel::UpdateTheme(){ // PRIVATE SLOTS // =================== void LPanel::checkPanelFocus(){ + qDebug() << "Check Panel Focus:" << panelnum << viswidth << fullwidth << this->size(); if( !this->geometry().contains(QCursor::pos()) ){ //Move the panel back to it's "hiding" spot - if(hidden){ this->move(hidepoint); this->update(); } + if(hidden){ + QSize sz(horizontal ? this->width() : viswidth, horizontal ? viswidth : this->height() ); + this->setMinimumSize(sz); + this->setMaximumSize(sz); + this->setGeometry( QRect(hidepoint, sz) ); + } //Re-active the old window if(LSession::handle()->activeWindow()!=0){ LSession::handle()->XCB->ActivateWindow(LSession::handle()->activeWindow()); } + }else if(hidden){ + QSize sz(horizontal ? this->width() : fullwidth, horizontal ? fullwidth : this->height() ); + this->setMinimumSize(sz); + this->setMaximumSize(sz); + this->setGeometry( QRect(showpoint, sz) ); } } @@ -324,10 +341,15 @@ void LPanel::checkPanelFocus(){ //=========== // PROTECTED //=========== +void LPanel::resizeEvent(QResizeEvent *event){ + QWidget::resizeEvent(event); + for(int i=0; i<PLUGINS.length(); i++){ PLUGINS[i]->OrientationChange(); } +} + void LPanel::paintEvent(QPaintEvent *event){ if(!hascompositer){ QPainter *painter = new QPainter(this); - //qDebug() << "Paint Panel:" << PPREFIX; + qDebug() << "Paint Panel:" << PPREFIX; //Make sure the base background of the event rectangle is the associated rectangle from the BGWindow QRect rec = event->rect();//this->geometry(); //start with the global geometry of the panel rec.adjust(-1,-1,2,2); //add 1 more pixel on each side @@ -343,11 +365,13 @@ void LPanel::paintEvent(QPaintEvent *event){ void LPanel::enterEvent(QEvent *event){ //qDebug() << "Panel Enter Event:"; - if(hidden){ + checkPanelFocus(); + /*if(hidden){ //Move the panel out so it is fully available this->move(showpoint); + this->resize( horizontal ? this->width() : fullwidth, horizontal ? fullwidth : this->height() ); this->update(); - } + }*/ //this->activateWindow(); event->accept(); //just to quiet the compile warning } diff --git a/src-qt5/core/lumina-desktop/LPanel.h b/src-qt5/core/lumina-desktop/LPanel.h index b3c9ba60..2828161c 100644 --- a/src-qt5/core/lumina-desktop/LPanel.h +++ b/src-qt5/core/lumina-desktop/LPanel.h @@ -35,11 +35,12 @@ private: QString PPREFIX; //internal prefix for all settings QDesktopWidget *screen; QWidget *bgWindow, *panelArea; + //QRect hidegeom, showgeom; //for hidden panels QPoint hidepoint, showpoint; //for hidden panels: locations when hidden/visible bool defaultpanel, horizontal, hidden, hascompositer; int screennum; int panelnum; - int viswidth; + int viswidth, fullwidth; QList<LPPlugin*> PLUGINS; public: @@ -69,6 +70,7 @@ private slots: void checkPanelFocus(); protected: + void resizeEvent(QResizeEvent *event); void paintEvent(QPaintEvent *event); void enterEvent(QEvent *event); void leaveEvent(QEvent *event); -- cgit From 3464e681e6eebe8022b75750405770e8dfe7db87 Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Sat, 12 Nov 2016 09:19:29 -0500 Subject: Speed up the initial loading of the desktop at start, and delay the auto-started apps by 1/2 second. --- src-qt5/core/lumina-desktop/LPanel.cpp | 4 ++-- src-qt5/core/lumina-desktop/LSession.cpp | 22 +++++----------------- .../applauncher/AppLauncherPlugin.cpp | 3 ++- .../desktop-plugins/notepad/NotepadPlugin.cpp | 2 +- 4 files changed, 10 insertions(+), 21 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/core/lumina-desktop/LPanel.cpp b/src-qt5/core/lumina-desktop/LPanel.cpp index 62534acb..43584ffc 100644 --- a/src-qt5/core/lumina-desktop/LPanel.cpp +++ b/src-qt5/core/lumina-desktop/LPanel.cpp @@ -67,7 +67,7 @@ LPanel::LPanel(QSettings *file, int scr, int num, QWidget *parent) : QWidget(){ //this->setWindowOpacity(0.5); //fully transparent background for the main widget //panelArea->setWindowOpacity(1.0); //fully opaque for the widget on top (apply stylesheet transparencies) } - QTimer::singleShot(1,this, SLOT(UpdatePanel()) ); //start this in a new thread + QTimer::singleShot(1,this, SLOT(UpdatePanel()) ); //connect(screen, SIGNAL(resized(int)), this, SLOT(UpdatePanel()) ); //in case the screen resolution changes } @@ -246,7 +246,7 @@ void LPanel::UpdatePanel(bool geomonly){ //Make sure the plugin layout has the correct orientation if(horizontal){PLUGINS[p]->layout()->setDirection(QBoxLayout::LeftToRight); } else{ PLUGINS[p]->layout()->setDirection(QBoxLayout::TopToBottom); } - QTimer::singleShot(0,PLUGINS[p], SLOT( OrientationChange() ) ); + PLUGINS[p]->OrientationChange(); //Now check the location of the plugin in the panel if(p!=i){ //wrong place in the panel layout->takeAt(p); //remove the item from the current location diff --git a/src-qt5/core/lumina-desktop/LSession.cpp b/src-qt5/core/lumina-desktop/LSession.cpp index f383c163..22439911 100644 --- a/src-qt5/core/lumina-desktop/LSession.cpp +++ b/src-qt5/core/lumina-desktop/LSession.cpp @@ -120,12 +120,6 @@ void LSession::setupSession(){ if(DEBUG){ qDebug() << " - Init System Tray:" << timer->elapsed();} startSystemTray(); - //Launch Fluxbox - //splash.showScreen("wm"); - //if(DEBUG){ qDebug() << " - Init WM:" << timer->elapsed();} - //WM = new WMProcess(); - //WM->startWM(); - //Initialize the global menus qDebug() << " - Initialize system menus"; splash.showScreen("apps"); @@ -143,7 +137,8 @@ void LSession::setupSession(){ if(DEBUG){ qDebug() << " - Init Desktops:" << timer->elapsed();} desktopFiles = QDir(QDir::homePath()+"/Desktop").entryInfoList(QDir::NoDotAndDotDot | QDir::Files | QDir::Dirs, QDir::Name | QDir::IgnoreCase | QDir::DirsFirst); updateDesktops(); - + for(int i=0; i<6; i++){ LSession::processEvents(); } //Run through this a few times so the interface systems get up and running + //Now setup the system watcher for changes splash.showScreen("final"); qDebug() << " - Initialize file system watcher"; @@ -154,25 +149,18 @@ void LSession::setupSession(){ watcherChange( confdir+"/desktopsettings.conf" ); watcherChange( confdir+"/fluxbox-init" ); watcherChange( confdir+"/fluxbox-keys" ); - //watcher->addPath( sessionsettings->fileName() ); - //watcher->addPath( confdir+"/desktopsettings.conf" ); - //watcher->addPath( confdir+"/fluxbox-init" ); - //watcher->addPath( confdir+"/fluxbox-keys" ); //Try to watch the localized desktop folder too if(QFile::exists(QDir::homePath()+"/"+tr("Desktop"))){ watcherChange( QDir::homePath()+"/"+tr("Desktop") ); } watcherChange( QDir::homePath()+"/Desktop" ); //connect internal signals/slots - //connect(this->desktop(), SIGNAL(screenCountChanged(int)), this, SLOT(screensChanged()) ); - //connect(this->desktop(), SIGNAL(resized(int)), this, SLOT(screenResized(int)) ); connect(watcher, SIGNAL(directoryChanged(QString)), this, SLOT(watcherChange(QString)) ); connect(watcher, SIGNAL(fileChanged(QString)), this, SLOT(watcherChange(QString)) ); connect(this, SIGNAL(aboutToQuit()), this, SLOT(SessionEnding()) ); if(DEBUG){ qDebug() << " - Init Finished:" << timer->elapsed(); delete timer;} - QApplication::processEvents(); - launchStartupApps(); - //QTimer::singleShot(500, this, SLOT(launchStartupApps()) ); - //QApplication::processEvents(); + for(int i=0; i<4; i++){ LSession::processEvents(); } //Again, just a few event loops here so thing can settle before we close the splash screen + //launchStartupApps(); + QTimer::singleShot(500, this, SLOT(launchStartupApps()) ); splash.close(); } diff --git a/src-qt5/core/lumina-desktop/desktop-plugins/applauncher/AppLauncherPlugin.cpp b/src-qt5/core/lumina-desktop/desktop-plugins/applauncher/AppLauncherPlugin.cpp index 708355cd..3be19faa 100644 --- a/src-qt5/core/lumina-desktop/desktop-plugins/applauncher/AppLauncherPlugin.cpp +++ b/src-qt5/core/lumina-desktop/desktop-plugins/applauncher/AppLauncherPlugin.cpp @@ -20,7 +20,8 @@ AppLauncherPlugin::AppLauncherPlugin(QWidget* parent, QString ID) : LDPlugin(par connect(watcher, SIGNAL(fileChanged(QString)), this, SLOT( loadButton()) ); connect(this, SIGNAL(PluginActivated()), this, SLOT(buttonClicked()) ); //in case they use the context menu to launch it. - QTimer::singleShot(200,this, SLOT(loadButton()) ); + loadButton(); + //QTimer::singleShot(0,this, SLOT(loadButton()) ); } void AppLauncherPlugin::Cleanup(){ diff --git a/src-qt5/core/lumina-desktop/desktop-plugins/notepad/NotepadPlugin.cpp b/src-qt5/core/lumina-desktop/desktop-plugins/notepad/NotepadPlugin.cpp index fe26941e..6d321305 100644 --- a/src-qt5/core/lumina-desktop/desktop-plugins/notepad/NotepadPlugin.cpp +++ b/src-qt5/core/lumina-desktop/desktop-plugins/notepad/NotepadPlugin.cpp @@ -66,7 +66,7 @@ NotePadPlugin::NotePadPlugin(QWidget* parent, QString ID) : LDPlugin(parent, ID) //qDebug() << "Saving a new setting"; this->saveSetting("customFile",""); //always clear this when the plugin is initialized (only maintained per-session) //qDebug() << "Loading Notes Dir"; - QTimer::singleShot(2000, this, SLOT(notesDirChanged())); + QTimer::singleShot(10, this, SLOT(notesDirChanged())); //qDebug() << "Set Sizing"; //qDebug() << "Connect Signals/slots"; -- cgit From 877625d070f47cddfb8283351f373879deeda98b Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Sat, 12 Nov 2016 14:33:38 -0500 Subject: New Desktop Utility: lumina-archiver This is a pure Qt5 front-end to the "tar" utility for creating, viewing, and editing archives of various formats. ChangeLog=YES --- src-qt5/desktop-utils/desktop-utils.pro | 3 +- .../desktop-utils/lumina-archiver/7ZBackend.cpp | 160 +++++++++++++ src-qt5/desktop-utils/lumina-archiver/7ZBackend.h | 61 +++++ src-qt5/desktop-utils/lumina-archiver/MainUI.cpp | 262 +++++++++++++++++++++ src-qt5/desktop-utils/lumina-archiver/MainUI.h | 58 +++++ src-qt5/desktop-utils/lumina-archiver/MainUI.ui | 189 +++++++++++++++ src-qt5/desktop-utils/lumina-archiver/NOTES | 11 + .../desktop-utils/lumina-archiver/TarBackend.cpp | 202 ++++++++++++++++ src-qt5/desktop-utils/lumina-archiver/TarBackend.h | 62 +++++ .../lumina-archiver/i18n/l-archiver_af.ts | 97 ++++++++ .../lumina-archiver/i18n/l-archiver_ar.ts | 97 ++++++++ .../lumina-archiver/i18n/l-archiver_az.ts | 97 ++++++++ .../lumina-archiver/i18n/l-archiver_bg.ts | 97 ++++++++ .../lumina-archiver/i18n/l-archiver_bn.ts | 97 ++++++++ .../lumina-archiver/i18n/l-archiver_bs.ts | 97 ++++++++ .../lumina-archiver/i18n/l-archiver_ca.ts | 97 ++++++++ .../lumina-archiver/i18n/l-archiver_cs.ts | 97 ++++++++ .../lumina-archiver/i18n/l-archiver_cy.ts | 97 ++++++++ .../lumina-archiver/i18n/l-archiver_da.ts | 97 ++++++++ .../lumina-archiver/i18n/l-archiver_de.ts | 97 ++++++++ .../lumina-archiver/i18n/l-archiver_el.ts | 97 ++++++++ .../lumina-archiver/i18n/l-archiver_en_GB.ts | 97 ++++++++ .../lumina-archiver/i18n/l-archiver_en_ZA.ts | 97 ++++++++ .../lumina-archiver/i18n/l-archiver_es.ts | 97 ++++++++ .../lumina-archiver/i18n/l-archiver_et.ts | 97 ++++++++ .../lumina-archiver/i18n/l-archiver_eu.ts | 97 ++++++++ .../lumina-archiver/i18n/l-archiver_fa.ts | 97 ++++++++ .../lumina-archiver/i18n/l-archiver_fi.ts | 97 ++++++++ .../lumina-archiver/i18n/l-archiver_fr.ts | 97 ++++++++ .../lumina-archiver/i18n/l-archiver_fr_CA.ts | 97 ++++++++ .../lumina-archiver/i18n/l-archiver_gl.ts | 97 ++++++++ .../lumina-archiver/i18n/l-archiver_he.ts | 97 ++++++++ .../lumina-archiver/i18n/l-archiver_hi.ts | 97 ++++++++ .../lumina-archiver/i18n/l-archiver_hr.ts | 97 ++++++++ .../lumina-archiver/i18n/l-archiver_hu.ts | 97 ++++++++ .../lumina-archiver/i18n/l-archiver_id.ts | 97 ++++++++ .../lumina-archiver/i18n/l-archiver_is.ts | 97 ++++++++ .../lumina-archiver/i18n/l-archiver_it.ts | 97 ++++++++ .../lumina-archiver/i18n/l-archiver_ja.ts | 97 ++++++++ .../lumina-archiver/i18n/l-archiver_ka.ts | 97 ++++++++ .../lumina-archiver/i18n/l-archiver_ko.ts | 97 ++++++++ .../lumina-archiver/i18n/l-archiver_lt.ts | 97 ++++++++ .../lumina-archiver/i18n/l-archiver_lv.ts | 97 ++++++++ .../lumina-archiver/i18n/l-archiver_mk.ts | 97 ++++++++ .../lumina-archiver/i18n/l-archiver_mn.ts | 97 ++++++++ .../lumina-archiver/i18n/l-archiver_ms.ts | 97 ++++++++ .../lumina-archiver/i18n/l-archiver_mt.ts | 97 ++++++++ .../lumina-archiver/i18n/l-archiver_nb.ts | 97 ++++++++ .../lumina-archiver/i18n/l-archiver_nl.ts | 97 ++++++++ .../lumina-archiver/i18n/l-archiver_pa.ts | 97 ++++++++ .../lumina-archiver/i18n/l-archiver_pl.ts | 97 ++++++++ .../lumina-archiver/i18n/l-archiver_pt.ts | 97 ++++++++ .../lumina-archiver/i18n/l-archiver_pt_BR.ts | 97 ++++++++ .../lumina-archiver/i18n/l-archiver_ro.ts | 97 ++++++++ .../lumina-archiver/i18n/l-archiver_ru.ts | 97 ++++++++ .../lumina-archiver/i18n/l-archiver_sk.ts | 97 ++++++++ .../lumina-archiver/i18n/l-archiver_sl.ts | 97 ++++++++ .../lumina-archiver/i18n/l-archiver_sr.ts | 97 ++++++++ .../lumina-archiver/i18n/l-archiver_sv.ts | 97 ++++++++ .../lumina-archiver/i18n/l-archiver_sw.ts | 97 ++++++++ .../lumina-archiver/i18n/l-archiver_ta.ts | 97 ++++++++ .../lumina-archiver/i18n/l-archiver_tg.ts | 97 ++++++++ .../lumina-archiver/i18n/l-archiver_th.ts | 97 ++++++++ .../lumina-archiver/i18n/l-archiver_tr.ts | 97 ++++++++ .../lumina-archiver/i18n/l-archiver_uk.ts | 97 ++++++++ .../lumina-archiver/i18n/l-archiver_uz.ts | 97 ++++++++ .../lumina-archiver/i18n/l-archiver_vi.ts | 97 ++++++++ .../lumina-archiver/i18n/l-archiver_zh_CN.ts | 97 ++++++++ .../lumina-archiver/i18n/l-archiver_zh_HK.ts | 97 ++++++++ .../lumina-archiver/i18n/l-archiver_zh_TW.ts | 97 ++++++++ .../lumina-archiver/i18n/l-archiver_zu.ts | 97 ++++++++ .../lumina-archiver/lumina-archiver.desktop | 10 + .../lumina-archiver/lumina-archiver.pro | 98 ++++++++ src-qt5/desktop-utils/lumina-archiver/main.cpp | 29 +++ 74 files changed, 7158 insertions(+), 1 deletion(-) create mode 100644 src-qt5/desktop-utils/lumina-archiver/7ZBackend.cpp create mode 100644 src-qt5/desktop-utils/lumina-archiver/7ZBackend.h create mode 100644 src-qt5/desktop-utils/lumina-archiver/MainUI.cpp create mode 100644 src-qt5/desktop-utils/lumina-archiver/MainUI.h create mode 100644 src-qt5/desktop-utils/lumina-archiver/MainUI.ui create mode 100644 src-qt5/desktop-utils/lumina-archiver/NOTES create mode 100644 src-qt5/desktop-utils/lumina-archiver/TarBackend.cpp create mode 100644 src-qt5/desktop-utils/lumina-archiver/TarBackend.h create mode 100644 src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_af.ts create mode 100644 src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_ar.ts create mode 100644 src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_az.ts create mode 100644 src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_bg.ts create mode 100644 src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_bn.ts create mode 100644 src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_bs.ts create mode 100644 src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_ca.ts create mode 100644 src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_cs.ts create mode 100644 src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_cy.ts create mode 100644 src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_da.ts create mode 100644 src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_de.ts create mode 100644 src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_el.ts create mode 100644 src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_en_GB.ts create mode 100644 src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_en_ZA.ts create mode 100644 src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_es.ts create mode 100644 src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_et.ts create mode 100644 src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_eu.ts create mode 100644 src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_fa.ts create mode 100644 src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_fi.ts create mode 100644 src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_fr.ts create mode 100644 src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_fr_CA.ts create mode 100644 src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_gl.ts create mode 100644 src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_he.ts create mode 100644 src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_hi.ts create mode 100644 src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_hr.ts create mode 100644 src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_hu.ts create mode 100644 src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_id.ts create mode 100644 src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_is.ts create mode 100644 src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_it.ts create mode 100644 src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_ja.ts create mode 100644 src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_ka.ts create mode 100644 src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_ko.ts create mode 100644 src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_lt.ts create mode 100644 src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_lv.ts create mode 100644 src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_mk.ts create mode 100644 src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_mn.ts create mode 100644 src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_ms.ts create mode 100644 src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_mt.ts create mode 100644 src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_nb.ts create mode 100644 src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_nl.ts create mode 100644 src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_pa.ts create mode 100644 src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_pl.ts create mode 100644 src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_pt.ts create mode 100644 src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_pt_BR.ts create mode 100644 src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_ro.ts create mode 100644 src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_ru.ts create mode 100644 src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_sk.ts create mode 100644 src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_sl.ts create mode 100644 src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_sr.ts create mode 100644 src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_sv.ts create mode 100644 src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_sw.ts create mode 100644 src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_ta.ts create mode 100644 src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_tg.ts create mode 100644 src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_th.ts create mode 100644 src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_tr.ts create mode 100644 src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_uk.ts create mode 100644 src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_uz.ts create mode 100644 src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_vi.ts create mode 100644 src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_zh_CN.ts create mode 100644 src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_zh_HK.ts create mode 100644 src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_zh_TW.ts create mode 100644 src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_zu.ts create mode 100644 src-qt5/desktop-utils/lumina-archiver/lumina-archiver.desktop create mode 100644 src-qt5/desktop-utils/lumina-archiver/lumina-archiver.pro create mode 100644 src-qt5/desktop-utils/lumina-archiver/main.cpp (limited to 'src-qt5') diff --git a/src-qt5/desktop-utils/desktop-utils.pro b/src-qt5/desktop-utils/desktop-utils.pro index ddb0f6fd..24f847d1 100644 --- a/src-qt5/desktop-utils/desktop-utils.pro +++ b/src-qt5/desktop-utils/desktop-utils.pro @@ -8,5 +8,6 @@ SUBDIRS+= lumina-fm \ lumina-screenshot \ lumina-fileinfo \ lumina-textedit \ - lumina-calculator + lumina-calculator \ + lumina-archiver # lumina-terminal diff --git a/src-qt5/desktop-utils/lumina-archiver/7ZBackend.cpp b/src-qt5/desktop-utils/lumina-archiver/7ZBackend.cpp new file mode 100644 index 00000000..5d97457f --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/7ZBackend.cpp @@ -0,0 +1,160 @@ +//=========================================== +// Lumina-DE source code +// Copyright (c) 2016, Ken Moore +// Available under the 3-clause BSD license +// See the LICENSE file for full details +//=========================================== +#include "7ZBackend.h" +#include <QFile> +#include <QDebug> + +ZBackend::ZBackend(QObject *parent) : QObject(parent){ + //Setup the backend process + PROC.setProcessChannelMode(QProcess::MergedChannels); + PROC.setProgram("7z"); + connect(&PROC, SIGNAL(finished(int, QProcess::ExitStatus)), this, SLOT(procFinished(int, QProcess::ExitStatus)) ); + connect(&PROC, SIGNAL(readyReadStandardOutput()), this, SLOT(processData()) ); + connect(&PROC, SIGNAL(started()), this, SIGNAL(ProcessStarting()) ); + LIST = STARTING = false; +} + +ZBackend::~ZBackend(){ + +} + +//=============== +// PUBLIC +//=============== +void ZBackend::loadFile(QString path, QString pass){ + filepath = path; + flags.clear(); + //contents.clear(); + //Now determine the flags which are used for this type of file (for later use) + if(!pass.isEmpty()){ flags << "-p"+pass; } //add password entry + //Look for some special file extensions which 7z can't seem to detect itself + QStringList ext = path.section("/",-1).section(".",1,-1).split("."); + if(ext.contains("tar")){ + flags << "-ttar"; + } + flags << filepath; //add the actual archive path + if(QFile::exists(path)){ startList(); } + else{ contents.clear(); emit ProcessFinished(); } +} + +QString ZBackend::currentFile(){ + return filepath; +} + +bool ZBackend::isWorking(){ + return (PROC.state() != QProcess::Running); +} + +//Listing routines +QStringList ZBackend::heirarchy(){ + return contents.keys(); +} + +double ZBackend::size(QString file){ + if(!contents.contains(file)){ return -1; } + return contents.value(file)[1].toDouble(); +} + +double ZBackend::csize(QString file){ + if(!contents.contains(file)){ return -1; } + return contents.value(file)[2].toDouble(); +} + +bool ZBackend::isDir(QString file){ + if(!contents.contains(file)){ return false; } + return contents.value(file)[0].startsWith("D"); +} + +//Modification routines +void ZBackend::startAdd(QStringList paths){ + QStringList args; + args << "a" << flags << paths; + STARTING=true; + PROC.start("7z", args); +} + +void ZBackend::startRemove(QStringList paths){ + QStringList args; + args << "d" << flags << paths; + STARTING=true; + PROC.start("7z", args); +} + +void ZBackend::startExtract(QString path, bool preservepaths){ + QStringList args; + args << (preservepaths ? "x" : "e") << flags << "-o"+path; + STARTING=true; + PROC.start("7z", args); +} + +//=============== +// PUBLIC SLOTS +//=============== + +//=============== +// PRIVATE +//=============== +void ZBackend::parseLines(QStringList lines){ + if(STARTING){ + //Ignore all the p7zip header info + while(STARTING && !lines.isEmpty()){ + if(lines[0]=="--"){ STARTING = false; } //found the end of the headers + lines.removeAt(0); + } + } + for(int i=0; i<lines.length(); i++){ + if(lines[i].simplified().isEmpty() || lines[i].contains(" = ") || lines[i].contains("----") ){ continue; } + if(LIST){ + if(lines[i].contains(" Attr ") || lines[i].contains(", ") ){ continue; } //headers + QStringList info = lines[i].split(" ",QString::SkipEmptyParts); + //Format: [date, time, attr, size, compressed size, name] + if(info.length()<6){ continue; } //invalid line + while(info.length()>6){ info[5] = info[5]+" "+info[6]; info.removeAt(6); } //Filename has spaces in it + contents.insert(info[5], QStringList() << info[2] << info[3] << info[4]); //Save the + } + } +} + +void ZBackend::startList(){ + contents.clear(); + QStringList args; + args << "l"; //list (lowercase L) + LIST = STARTING=true; + PROC.start("7z", QStringList() << args << flags); +} + +//=============== +// PRIVATE SLOTS +//=============== +void ZBackend::procFinished(int retcode, QProcess::ExitStatus){ + processData(); + //qDebug() << "Process Finished:" << PROC.arguments() << retcode; + LIST = STARTING = false; + if(PROC.arguments().contains("l")){ + emit ProcessFinished(); + }else{ + if(retcode==0){ + QStringList args = PROC.arguments(); + for(int i=0; i<args.length(); i++){ + if(args[i].startsWith("-o")){ QProcess::startDetached("xdg-open \""+ args[i].section("-o",1,-1)+"\""); } //just extracted to a dir - open it now + } + } + startList(); + } +} + +void ZBackend::processData(){ + //Read the process + static QString data; + QString read = data+PROC.readAllStandardOutput(); + if(read.endsWith("\n")){ data.clear(); } + else{ data = read.section("\n",-1); read = read.section("\n",0,-2); } + QStringList lines = read.split("\n",QString::SkipEmptyParts); + if(LIST){ parseLines(lines); } + //qDebug() << lines; + emit ProgressUpdate(-1, ""); +} diff --git a/src-qt5/desktop-utils/lumina-archiver/7ZBackend.h b/src-qt5/desktop-utils/lumina-archiver/7ZBackend.h new file mode 100644 index 00000000..7e023c72 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/7ZBackend.h @@ -0,0 +1,61 @@ +//=========================================== +// Lumina-DE source code +// Copyright (c) 2016, Ken Moore +// Available under the 3-clause BSD license +// See the LICENSE file for full details +//=========================================== +#ifndef _LUMINA_ARCHIVER_7ZIP_BACKEND_H +#define _LUMINA_ARCHIVER_7ZIP_BACKEND_H + +#include <QProcess> +#include <QString> +#include <QStringList> + +class ZBackend : public QObject{ + Q_OBJECT +public: + ZBackend(QObject *parent = 0); + ~ZBackend(); + + void loadFile(QString path, QString pass=""); + + //Listing routines + QString currentFile(); + bool isWorking(); //is this currently still making changes? + + //Contents listing + QStringList heirarchy(); //returns all the file paths within the archive + double size(QString file); + double csize(QString file); + bool isDir(QString file); + + //Modification routines + void startAdd(QStringList paths); + void startRemove(QStringList paths); + void startExtract(QString path, bool preservepaths); //path to dir + +public slots: + +private: + QProcess PROC; + + QString filepath; + QStringList flags; + QHash<QString, QStringList> contents; //<filepath, [attributes, size, compressed size] + + bool LIST, STARTING; + void parseLines(QStringList lines); + +private slots: + void startList(); + void procFinished(int retcode, QProcess::ExitStatus); + void processData(); + +signals: + void FileLoaded(); + void ProcessStarting(); + void ProgressUpdate(int, QString); //percentage, text + void ProcessFinished(); +}; + +#endif diff --git a/src-qt5/desktop-utils/lumina-archiver/MainUI.cpp b/src-qt5/desktop-utils/lumina-archiver/MainUI.cpp new file mode 100644 index 00000000..612c7beb --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/MainUI.cpp @@ -0,0 +1,262 @@ +//=========================================== +// Lumina-DE source code +// Copyright (c) 2016, Ken Moore +// Available under the 3-clause BSD license +// See the LICENSE file for full details +//=========================================== +#include "MainUI.h" +#include "ui_MainUI.h" + +#include <QMessageBox> +#include <QFileDialog> +#include <LuminaXDG.h> +#include <LUtils.h> + +#define TAREXT ( +MainUI::MainUI() : QMainWindow(), ui(new Ui::MainUI){ + ui->setupUi(this); + this->setWindowTitle(tr("Archive Manager")); + BACKEND = new Backend(this); + connect(BACKEND, SIGNAL(ProcessStarting()), this, SLOT(ProcStarting()) ); + connect(BACKEND, SIGNAL(ProcessFinished()), this, SLOT(ProcFinished()) ); + connect(BACKEND, SIGNAL(ProgressUpdate(int, QString)), this, SLOT(ProcUpdate(int, QString)) ); + + //Add a spacer between toolbar items + QWidget *spacer = new QWidget(this); + spacer->setSizePolicy(QSizePolicy::Expanding, QSizePolicy::Expanding); + ui->toolBar->insertWidget(ui->actionAdd_File, spacer); + + //Connect the UI signals/slots + connect(ui->action_New, SIGNAL(triggered()), this, SLOT(NewArchive()) ); + connect(ui->action_Open, SIGNAL(triggered()), this, SLOT(OpenArchive()) ); + connect(ui->action_Quit, SIGNAL(triggered()), this, SLOT(close()) ); + connect(ui->actionAdd_File, SIGNAL(triggered()), this, SLOT(addFiles()) ); + connect(ui->actionRemove_File, SIGNAL(triggered()), this, SLOT(remFiles()) ); + connect(ui->actionExtract_All, SIGNAL(triggered()), this, SLOT(extractFiles()) ); + connect(ui->actionAdd_Dirs, SIGNAL(triggered()), this, SLOT(addDirs()) ); + ui->progressBar->setVisible(false); + ui->label_progress->setVisible(false); + ui->actionAdd_File->setEnabled(false); + ui->actionRemove_File->setEnabled(false); + ui->actionExtract_All->setEnabled(false); + ui->actionAdd_Dirs->setEnabled(false); + loadIcons(); + ui->tree_contents->setHeaderLabels( QStringList() << tr("File") << tr("MimeType") << tr("Size") << tr("Compressed")+" " ); +} + +MainUI::~MainUI(){ + +} + +void MainUI::LoadArguments(QStringList args){ + for(int i=0; i<args.length(); i++){ + if(QFile::exists(args[i])){ BACKEND->loadFile(args[i]); break;} + } +} + +void MainUI::loadIcons(){ + this->setWindowIcon( LXDG::findIcon("utilities-file-archiver","") ); + ui->action_New->setIcon( LXDG::findIcon("file-new", "document-new") ); + ui->action_Open->setIcon( LXDG::findIcon("file-open","document-open") ); + ui->action_Quit->setIcon( LXDG::findIcon("application-exit", "dialog-close") ); + ui->actionAdd_File->setIcon( LXDG::findIcon("archive-insert", "") ); + ui->actionAdd_Dirs->setIcon( LXDG::findIcon("archive-insert-directory","") ); + ui->actionRemove_File->setIcon( LXDG::findIcon("archive-remove","") ); + ui->actionExtract_All->setIcon( LXDG::findIcon("archive-extract","") ); +} + +//=================== +// PRIVATE +//=================== +QTreeWidgetItem* MainUI::findItem(QString path, QTreeWidgetItem *start){ + if(start==0){ + for(int i=0; i<ui->tree_contents->topLevelItemCount(); i++){ + QString itpath = ui->tree_contents->topLevelItem(i)->whatsThis(0); + if(itpath == path){ return ui->tree_contents->topLevelItem(i); } + else if(path.startsWith(itpath+"/")){ return findItem(path, ui->tree_contents->topLevelItem(i)); } + } + }else{ + for(int i=0; i<start->childCount(); i++){ + QString itpath = start->child(i)->whatsThis(0); + if(itpath == path){ return start->child(i); } + else if(path.startsWith(itpath+"/")){ return findItem(path, start->child(i)); } + } + } + return 0; //nothing found +} + +void MainUI::cleanItems(QStringList list, QTreeWidgetItem *start){ + if(start==0){ + for(int i=0; i<ui->tree_contents->topLevelItemCount(); i++){ + cleanItems(list, ui->tree_contents->topLevelItem(i)); + if(!list.contains(ui->tree_contents->topLevelItem(i)->whatsThis(0)) ){ + delete ui->tree_contents->topLevelItem(i); + } + } + }else{ + for(int i=0; i<start->childCount(); i++){ + cleanItems(list, start->child(i)); + if(!list.contains(start->child(i)->whatsThis(0)) ){ + delete start->child(i); + } + } + } +} + +//Functions for setting the valid file extensions ("tar" limitations) +QString MainUI::CreateFileTypes(){ + QStringList types; + types << QString(tr("All Types %1")).arg("(*.tar.gz *.tar.xz *.tar.bz *.tar.bz2 *.tar.lzma *.tar *.zip *.tgz *.txz *.tbz *.tbz2 *.tlz *.cpio *.pax *.ar *.shar *.7z)"); + types << tr("Uncompressed Archive (*.tar)"); + types << tr("GZip Compressed Archive (*.tar.gz *.tgz)"); + types << tr("BZip Compressed Archive (*.tar.bz *.tbz)"); + types << tr("BZip2 Compressed Archive (*.tar.bz2 *.tbz2)"); + types << tr("LMZA Compressed Archive (*.tar.lzma *.tlz)"); + types << tr("XZ Compressed Archive (*.tar.xz *.txz)"); + types << tr("CPIO Archive (*.cpio)"); + types << tr("PAX Archive (*.pax)"); + types << tr("AR Archive (*.ar)"); + types << tr("SHAR Archive (*.shar)"); + types << tr("Zip Archive (*.zip)"); + types << tr("7-Zip Archive (*.7z)"); + return types.join(";;"); +} + +QString MainUI::OpenFileTypes(){ + QStringList types; + types << QString(tr("All Types %1")).arg("(*.tar.gz *.tar.xz *.tar.bz *.tar.bz2 *.tar.lzma *.tar *.zip *.tgz *.txz *.tbz *.tbz2 *.tlz *.cpio *.pax *.ar *.shar *.7z *.iso *.xar *.jar *.rpm)"); + types << tr("Uncompressed Archive (*.tar)"); + types << tr("GZip Compressed Archive (*.tar.gz *.tgz)"); + types << tr("BZip Compressed Archive (*.tar.bz *.tbz)"); + types << tr("BZip2 Compressed Archive (*.tar.bz2 *.tbz2)"); + types << tr("XZ Compressed Archive (*.tar.xz *.txz)"); + types << tr("LMZA Compressed Archive (*.tar.lzma *.tlz)"); + types << tr("CPIO Archive (*.cpio)"); + types << tr("PAX Archive (*.pax)"); + types << tr("AR Archive (*.ar)"); + types << tr("SHAR Archive (*.shar)"); + types << tr("Zip Archive (*.zip)"); + types << tr("7-Zip Archive (*.7z)"); + types << tr("READ-ONLY: ISO image (*.iso)"); + types << tr("READ-ONLY: XAR archive (*.xar)"); + types << tr("READ-ONLY: Java archive (*.jar)"); + types << tr("READ-ONLY: RedHat Package (*.rpm)"); + return types.join(";;"); +} + +//=================== +// PRIVATE SLOTS +//=================== +void MainUI::NewArchive(){ + QString file = QFileDialog::getSaveFileName(this, tr("Create Archive"), QDir::homePath(), CreateFileTypes() ); + if(file.isEmpty()){ return; } + if(QFile::exists(file)){ + if( !QFile::remove(file) ){ QMessageBox::warning(this, tr("Error"), QString(tr("Could not overwrite file:"))+"\n"+file); } + } + BACKEND->loadFile(file); +} + +void MainUI::OpenArchive(){ + QString file = QFileDialog::getOpenFileName(this, tr("Open Archive"), QDir::homePath(), OpenFileTypes() ); + if(file.isEmpty()){ return; } + BACKEND->loadFile(file); +} + +void MainUI::addFiles(){ + QStringList files = QFileDialog::getOpenFileNames(this, tr("Add to Archive"), QDir::homePath() ); + if(files.isEmpty()){ return; } + BACKEND->startAdd(files); +} + +void MainUI::addDirs(){ + QString dirs = QFileDialog::getExistingDirectory(this, tr("Add to Archive"), QDir::homePath() ); + if(dirs.isEmpty()){ return; } + BACKEND->startAdd(QStringList() << dirs); +} + +void MainUI::remFiles(){ + QList<QTreeWidgetItem*> sel = ui->tree_contents->selectedItems(); + QStringList items; + for(int i=0; i<sel.length(); i++){ + items << sel[i]->whatsThis(0); + } + items.removeDuplicates(); + BACKEND->startRemove(items); +} + +void MainUI::extractFiles(){ + QString dir = QFileDialog::getExistingDirectory(this, tr("Extract Into Directory"), QDir::homePath() ); + if(dir.isEmpty()){ return; } + BACKEND->startExtract(dir, true); +} + +void MainUI::UpdateTree(){ + ui->tree_contents->setHeaderLabels( QStringList() << tr("File") << tr("MimeType") << tr("Size") << tr("Compressed")+" " ); + QStringList files = BACKEND->heirarchy(); + files.sort(); + //Remove any entries for file no longer in the archive + cleanItems(files); + qDebug() << "Found Files:" << files; + for(int i=0; i<files.length(); i++){ + if(0 != findItem(files[i]) ){ continue; } //already in the tree widget + QString mime = LXDG::findAppMimeForFile(files[i].section("/",-1), false); //first match only + QTreeWidgetItem *it = new QTreeWidgetItem( QStringList() << files[i].section("/",-1) << mime << LUtils::BytesToDisplaySize( BACKEND->size(files[i])) << LUtils::BytesToDisplaySize(BACKEND->csize(files[i])) ); + it->setWhatsThis(0, files[i]); + if(BACKEND->isDir(files[i])){ + it->setIcon(0, LXDG::findIcon("folder","")); + it->setText(1,""); //clear the mimetype + }else{ + it->setIcon(0, LXDG::findMimeIcon(files[i].section("/",-1)) ); + } + //Now find which item to add this too + if(files[i].contains("/")){ + QTreeWidgetItem *parent = findItem(files[i].section("/",0,-2)); + QList<QTreeWidgetItem*> list = ui->tree_contents->findItems(files[i].section("/",-3,-2), Qt::MatchExactly, 0); + if(parent==0){ ui->tree_contents->addTopLevelItem(it); } + else{ parent->addChild(it); } + }else{ + ui->tree_contents->addTopLevelItem(it); + } + } + int wid = 0; + for(int i=3; i>0; i--){ui->tree_contents->resizeColumnToContents(i); wid+= ui->tree_contents->columnWidth(i); } + ui->tree_contents->setColumnWidth(0, ui->tree_contents->viewport()->width()-wid); +} + +//Backend Handling +void MainUI::ProcStarting(){ + ui->progressBar->setRange(0,0); + ui->progressBar->setValue(0); + ui->progressBar->setVisible(true); + ui->label_progress->setVisible(true); + ui->tree_contents->setEnabled(false); + ui->label_archive->setText(BACKEND->currentFile()); +} + +void MainUI::ProcFinished(){ + ui->progressBar->setRange(0,0); + ui->progressBar->setValue(0); + ui->progressBar->setVisible(false); + ui->label_progress->setVisible(false); + ui->tree_contents->setEnabled(true); + if(ui->label_archive->text()!=BACKEND->currentFile()){ + ui->label_archive->setText(BACKEND->currentFile()); + this->setWindowTitle(BACKEND->currentFile().section("/",-1)); + ui->tree_contents->clear(); + } + QFileInfo info(BACKEND->currentFile()); + bool canmodify = info.isWritable(); + if(!info.exists()){ canmodify = QFileInfo(BACKEND->currentFile().section("/",0,-2)).isWritable(); } + canmodify = canmodify && BACKEND->canModify(); //also include the file type limitations + ui->actionAdd_File->setEnabled(canmodify); + ui->actionRemove_File->setEnabled(canmodify && info.exists()); + ui->actionExtract_All->setEnabled(info.exists()); + ui->actionAdd_Dirs->setEnabled(canmodify); + UpdateTree(); +} + +void MainUI::ProcUpdate(int percent, QString txt){ + ui->progressBar->setMaximum( percent<0 ? 0 : 100 ); + ui->progressBar->setValue(percent); + if(!txt.isEmpty()){ ui->label_progress->setText(txt); } +} diff --git a/src-qt5/desktop-utils/lumina-archiver/MainUI.h b/src-qt5/desktop-utils/lumina-archiver/MainUI.h new file mode 100644 index 00000000..802d241b --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/MainUI.h @@ -0,0 +1,58 @@ +//=========================================== +// Lumina-DE source code +// Copyright (c) 2016, Ken Moore +// Available under the 3-clause BSD license +// See the LICENSE file for full details +//=========================================== +#ifndef _LUMINA_ARCHIVER_MAIN_UI_H +#define _LUMINA_ARCHIVER_MAIN_UI_H + +#include <QMainWindow> +#include <QString> +#include <QTreeWidgetItem> + +#include "TarBackend.h" + +namespace Ui{ + class MainUI; +}; + +class MainUI : public QMainWindow{ + Q_OBJECT +public: + MainUI(); + ~MainUI(); + + void LoadArguments(QStringList); + void loadIcons(); + +private: + Ui::MainUI *ui; + Backend *BACKEND; + + QTreeWidgetItem* findItem(QString path, QTreeWidgetItem *start = 0); + void cleanItems(QStringList list, QTreeWidgetItem *start = 0); + + //Functions for setting the valid file extensions ("tar" limitations) + QString CreateFileTypes(); + QString OpenFileTypes(); + +private slots: + void NewArchive(); + void OpenArchive(); + void addFiles(); + void addDirs(); + void remFiles(); + void extractFiles(); + + void UpdateTree(); + + + //Backend Handling + void ProcStarting(); + void ProcFinished(); + void ProcUpdate(int percent, QString txt); + +}; + +#endif diff --git a/src-qt5/desktop-utils/lumina-archiver/MainUI.ui b/src-qt5/desktop-utils/lumina-archiver/MainUI.ui new file mode 100644 index 00000000..8c2b2836 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/MainUI.ui @@ -0,0 +1,189 @@ +<?xml version="1.0" encoding="UTF-8"?> +<ui version="4.0"> + <class>MainUI</class> + <widget class="QMainWindow" name="MainUI"> + <property name="geometry"> + <rect> + <x>0</x> + <y>0</y> + <width>403</width> + <height>294</height> + </rect> + </property> + <property name="windowTitle"> + <string>MainWindow</string> + </property> + <widget class="QWidget" name="centralwidget"> + <layout class="QVBoxLayout" name="verticalLayout"> + <item> + <layout class="QHBoxLayout" name="horizontalLayout"> + <item> + <widget class="QLabel" name="label"> + <property name="font"> + <font> + <weight>75</weight> + <bold>true</bold> + </font> + </property> + <property name="text"> + <string>Archive:</string> + </property> + </widget> + </item> + <item> + <widget class="QLabel" name="label_archive"> + <property name="sizePolicy"> + <sizepolicy hsizetype="Expanding" vsizetype="Preferred"> + <horstretch>0</horstretch> + <verstretch>0</verstretch> + </sizepolicy> + </property> + <property name="text"> + <string notr="true"/> + </property> + </widget> + </item> + </layout> + </item> + <item> + <widget class="QTreeWidget" name="tree_contents"> + <column> + <property name="text"> + <string notr="true">1</string> + </property> + </column> + </widget> + </item> + <item> + <layout class="QHBoxLayout" name="horizontalLayout_2"> + <item> + <widget class="QProgressBar" name="progressBar"> + <property name="value"> + <number>24</number> + </property> + </widget> + </item> + <item> + <widget class="QLabel" name="label_progress"> + <property name="text"> + <string notr="true"/> + </property> + </widget> + </item> + </layout> + </item> + </layout> + </widget> + <widget class="QMenuBar" name="menubar"> + <property name="geometry"> + <rect> + <x>0</x> + <y>0</y> + <width>403</width> + <height>22</height> + </rect> + </property> + <widget class="QMenu" name="menuFile"> + <property name="title"> + <string>File</string> + </property> + <addaction name="action_New"/> + <addaction name="action_Open"/> + <addaction name="separator"/> + <addaction name="action_Quit"/> + </widget> + <widget class="QMenu" name="menuEdit"> + <property name="title"> + <string>Edit</string> + </property> + <addaction name="actionAdd_File"/> + <addaction name="actionAdd_Dirs"/> + <addaction name="actionRemove_File"/> + <addaction name="separator"/> + <addaction name="actionExtract_All"/> + </widget> + <addaction name="menuFile"/> + <addaction name="menuEdit"/> + </widget> + <widget class="QStatusBar" name="statusbar"/> + <widget class="QToolBar" name="toolBar"> + <property name="windowTitle"> + <string>toolBar</string> + </property> + <property name="movable"> + <bool>false</bool> + </property> + <property name="floatable"> + <bool>false</bool> + </property> + <attribute name="toolBarArea"> + <enum>TopToolBarArea</enum> + </attribute> + <attribute name="toolBarBreak"> + <bool>false</bool> + </attribute> + <addaction name="action_New"/> + <addaction name="action_Open"/> + <addaction name="actionAdd_File"/> + <addaction name="actionAdd_Dirs"/> + <addaction name="actionRemove_File"/> + <addaction name="separator"/> + <addaction name="actionExtract_All"/> + </widget> + <action name="action_Open"> + <property name="text"> + <string>&Open Archive</string> + </property> + <property name="statusTip"> + <string>Open archive</string> + </property> + </action> + <action name="action_New"> + <property name="text"> + <string>&New Archive</string> + </property> + <property name="statusTip"> + <string>New archive</string> + </property> + </action> + <action name="action_Quit"> + <property name="text"> + <string>&Quit</string> + </property> + </action> + <action name="actionAdd_File"> + <property name="text"> + <string>Add File(s)</string> + </property> + <property name="statusTip"> + <string>Add files to archive</string> + </property> + </action> + <action name="actionRemove_File"> + <property name="text"> + <string>Remove File(s)</string> + </property> + <property name="statusTip"> + <string>Remove selection from archive</string> + </property> + </action> + <action name="actionExtract_All"> + <property name="text"> + <string>Extract All</string> + </property> + <property name="statusTip"> + <string>Extract archive into a directory</string> + </property> + </action> + <action name="actionAdd_Dirs"> + <property name="text"> + <string>Add Directory</string> + </property> + <property name="statusTip"> + <string>Add directory to archive</string> + </property> + </action> + </widget> + <resources/> + <connections/> +</ui> diff --git a/src-qt5/desktop-utils/lumina-archiver/NOTES b/src-qt5/desktop-utils/lumina-archiver/NOTES new file mode 100644 index 00000000..20de4ac4 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/NOTES @@ -0,0 +1,11 @@ +Notes about "tar" on FreeBSD: + +1) Use "-a" when creating archive with "-c" to automatically determine compression type from the file extension +2) Valid file extensions: +Read-Write: *.zip, *.tar.gz, *.tar.xz, *.tar.bz, *.tar.bz2, *.tar, *.zip, *.tgz, *.txz, *.tbz, *.tbz2, *.cpio, *.pax, *.ar, *.shar, *.7z +Read-Only: *.iso, *.xar, *.jar, *.rpm + +To Extract: use "-x" +To List: use "-t" with "-v" for detailed info (space-delimited: [perms, ?, user, group, size, month, day, time, filename]) +To pass a file on the command line use "-f <file>" +If no compression flag (z, j, J, etc...) are given when reading/extracting, then it will automatically determine the type to use. diff --git a/src-qt5/desktop-utils/lumina-archiver/TarBackend.cpp b/src-qt5/desktop-utils/lumina-archiver/TarBackend.cpp new file mode 100644 index 00000000..f6738855 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/TarBackend.cpp @@ -0,0 +1,202 @@ +//=========================================== +// Lumina-DE source code +// Copyright (c) 2016, Ken Moore +// Available under the 3-clause BSD license +// See the LICENSE file for full details +//=========================================== +#include "TarBackend.h" +#include <QFile> +#include <QDebug> + +Backend::Backend(QObject *parent) : QObject(parent){ + //Setup the backend process + PROC.setProcessChannelMode(QProcess::MergedChannels); + PROC.setProgram("7z"); + connect(&PROC, SIGNAL(finished(int, QProcess::ExitStatus)), this, SLOT(procFinished(int, QProcess::ExitStatus)) ); + connect(&PROC, SIGNAL(readyReadStandardOutput()), this, SLOT(processData()) ); + connect(&PROC, SIGNAL(started()), this, SIGNAL(ProcessStarting()) ); + LIST = STARTING = false; +} + +Backend::~Backend(){ + +} + +//=============== +// PUBLIC +//=============== +void Backend::loadFile(QString path){ + filepath = path; + tmpfilepath = filepath.section("/",0,-2)+"/"+".tmp_larchiver_"+filepath.section("/",-1); + flags.clear(); + flags << "-f" << filepath; //add the actual archive path + if(QFile::exists(path)){ startList(); } + else{ contents.clear(); emit ProcessFinished(); } +} + +bool Backend::canModify(){ + static QStringList validEXT; + if(validEXT.isEmpty()){ + validEXT << ".zip" << ".tar.gz" << ".tgz" << ".tar.xz" << ".txz" << ".tar.bz" << ".tbz" << ".tar.bz2" << ".tbz2" << ".tar" \ + << ".tar.lzma" << ".tlz" << ".cpio" << ".pax" << ".ar" << ".shar" << ".7z"; + } + for(int i=0; i<validEXT.length(); i++){ + if(filepath.endsWith(validEXT[i])){ return true; } + } + return false; +} + +QString Backend::currentFile(){ + return filepath; +} + +bool Backend::isWorking(){ + return (PROC.state() != QProcess::Running); +} + +//Listing routines +QStringList Backend::heirarchy(){ + return contents.keys(); +} + +double Backend::size(QString file){ + if(!contents.contains(file)){ return -1; } + return contents.value(file)[1].toDouble(); +} + +double Backend::csize(QString file){ + if(!contents.contains(file)){ return -1; } + return contents.value(file)[1].toDouble(); +} + +bool Backend::isDir(QString file){ + if(!contents.contains(file)){ return false; } + return contents.value(file)[0].startsWith("d"); +} + +//Modification routines +void Backend::startAdd(QStringList paths){ + //NOTE: All the "paths" have to have the same parent directory + if(paths.contains(filepath)){ paths.removeAll(filepath); } + if(paths.isEmpty()){ return; } + QStringList args; + args << "-c" << "-a"; + args << flags; + //Now setup the parent dir + QString parent = paths[0].section("/",0,-2); + for(int i=0; i<paths.length(); i++){ + paths[i] = paths[i].section(parent,1,-1); + if(paths[i].startsWith("/")){ paths[i].remove(0,1); } + } + args << "-C" << parent; + args << paths; + if(QFile::exists(filepath)){ //append to existing + args.replaceInStrings(filepath, tmpfilepath); + args<< "@"+filepath; + } + STARTING=true; + PROC.start("tar", args); +} + +void Backend::startRemove(QStringList paths){ + if(paths.contains(filepath)){ paths.removeAll(filepath); } + if(contents.isEmpty() || paths.isEmpty() || !QFile::exists(filepath)){ return; } //invalid + QStringList args; + args << "-c" << "-a"; + args << flags; + args.replaceInStrings(filepath, tmpfilepath); + //Add the include rules for all the files we want to keep (no exclude option in "tar") + for(int i=0; i<paths.length(); i++){ + args << "--exclude" << paths[i]; + } + args<< "@"+filepath; + STARTING=true; + PROC.start("tar", args); +} + +void Backend::startExtract(QString path, bool overwrite){ + QStringList args; + args << "-x"; + if(!overwrite){ args << "-k"; } + args << flags << "-C" << path; + STARTING=true; + qDebug() << "Starting command:" << "tar" << args; + PROC.start("tar", args); +} + +//=============== +// PUBLIC SLOTS +//=============== + +//=============== +// PRIVATE +//=============== +void Backend::parseLines(QStringList lines){ + for(int i=0; i<lines.length(); i++){ + QStringList info = lines[i].split(" ",QString::SkipEmptyParts); + //Format: [perms, ?, user, group, size, month, day, time, file] + if(info.startsWith("x ") && filepath.endsWith(".zip")){ + //ZIP archives do not have all the extra information - just filenames + while(info.length()>2){ info[1]=info[1]+" "+info[2]; } + QString file = info[1]; + QString perms = ""; + if(file.endsWith("/")){ perms = "d"; file.chop(1); } + contents.insert(file, QStringList() << perms << "-1" ); //Save the [perms, size ] + } + else if(info.length()<9){ continue; } //invalid line + //TAR Archive parsing + while(info.length()>9){ info[8] = info[8]+" "+info[9]; info.removeAt(9); } //Filename has spaces in it + QString file = info[8]; + if(file.endsWith("/")){ file.chop(1); } + contents.insert(file, QStringList() << info[0] << info[4] ); //Save the [perms, size ] + } +} + +void Backend::startList(){ + contents.clear(); + QStringList args; + args << "-tv"; + LIST = STARTING=true; + PROC.start("tar", QStringList() << args << flags); +} + +//=============== +// PRIVATE SLOTS +//=============== +void Backend::procFinished(int retcode, QProcess::ExitStatus){ + processData(); + qDebug() << "Process Finished:" << PROC.arguments() << retcode; + LIST = STARTING = false; + if(PROC.arguments().contains("-tv")){ + if(retcode!=0){ contents.clear(); } //could not read archive + emit ProcessFinished(); + }else{ + bool needupdate = true; + QStringList args = PROC.arguments(); + if(args.contains("-x") && retcode==0){ + needupdate=false; + QProcess::startDetached("xdg-open \""+ args.last()+"\""); //just extracted to a dir - open it now + }else if(args.contains("-c") && QFile::exists(tmpfilepath)){ + if(retcode==0){ + QFile::remove(filepath); + QFile::rename(tmpfilepath, filepath); + }else{ + QFile::remove(tmpfilepath); + } + } + if(needupdate){ startList(); } + else{ emit ProcessFinished(); } + } +} + +void Backend::processData(){ + //Read the process + static QString data; + QString read = data+PROC.readAllStandardOutput(); + if(read.endsWith("\n")){ data.clear(); } + else{ data = read.section("\n",-1); read = read.section("\n",0,-2); } + QStringList lines = read.split("\n",QString::SkipEmptyParts); + if(LIST){ parseLines(lines); } + //qDebug() << lines; + emit ProgressUpdate(-1, ""); +} diff --git a/src-qt5/desktop-utils/lumina-archiver/TarBackend.h b/src-qt5/desktop-utils/lumina-archiver/TarBackend.h new file mode 100644 index 00000000..11c61319 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/TarBackend.h @@ -0,0 +1,62 @@ +//=========================================== +// Lumina-DE source code +// Copyright (c) 2016, Ken Moore +// Available under the 3-clause BSD license +// See the LICENSE file for full details +//=========================================== +#ifndef _LUMINA_ARCHIVER_TAR_BACKEND_H +#define _LUMINA_ARCHIVER_TAR_BACKEND_H + +#include <QProcess> +#include <QString> +#include <QStringList> + +class Backend : public QObject{ + Q_OBJECT +public: + Backend(QObject *parent = 0); + ~Backend(); + + void loadFile(QString path); + bool canModify(); //run on the current file + + //Listing routines + QString currentFile(); + bool isWorking(); //is this currently still making changes? + + //Contents listing + QStringList heirarchy(); //returns all the file paths within the archive + double size(QString file); + double csize(QString file); + bool isDir(QString file); + + //Modification routines + void startAdd(QStringList paths); + void startRemove(QStringList paths); + void startExtract(QString path, bool overwrite); //path to dir + +public slots: + +private: + QProcess PROC; + + QString filepath, tmpfilepath; + QStringList flags; + QHash<QString, QStringList> contents; //<filepath, [attributes, size, compressed size] + + bool LIST, STARTING; + void parseLines(QStringList lines); + +private slots: + void startList(); + void procFinished(int retcode, QProcess::ExitStatus); + void processData(); + +signals: + void FileLoaded(); + void ProcessStarting(); + void ProgressUpdate(int, QString); //percentage, text + void ProcessFinished(); +}; + +#endif diff --git a/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_af.ts b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_af.ts new file mode 100644 index 00000000..ab581514 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_af.ts @@ -0,0 +1,97 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.1" language="af_ZA"> +<context> + <name>MainUI</name> + <message> + <location filename="../MainUI.ui" line="14"/> + <source>MainWindow</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="29"/> + <source>Archive:</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="88"/> + <source>File</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="97"/> + <source>Edit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="111"/> + <source>toolBar</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="135"/> + <source>&Open Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="138"/> + <source>Open archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="143"/> + <source>&New Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="146"/> + <source>New archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="151"/> + <source>&Quit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="156"/> + <source>Add File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="159"/> + <source>Add files to archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="164"/> + <source>Remove File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="167"/> + <source>Remove selection from archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="172"/> + <source>Extract All</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="175"/> + <source>Extract archive into a directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="180"/> + <source>Add Directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="183"/> + <source>Add directory to archive</source> + <translation type="unfinished"></translation> + </message> +</context> +</TS> diff --git a/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_ar.ts b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_ar.ts new file mode 100644 index 00000000..ac0e0e4b --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_ar.ts @@ -0,0 +1,97 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.1" language="ar_EG"> +<context> + <name>MainUI</name> + <message> + <location filename="../MainUI.ui" line="14"/> + <source>MainWindow</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="29"/> + <source>Archive:</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="88"/> + <source>File</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="97"/> + <source>Edit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="111"/> + <source>toolBar</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="135"/> + <source>&Open Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="138"/> + <source>Open archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="143"/> + <source>&New Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="146"/> + <source>New archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="151"/> + <source>&Quit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="156"/> + <source>Add File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="159"/> + <source>Add files to archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="164"/> + <source>Remove File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="167"/> + <source>Remove selection from archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="172"/> + <source>Extract All</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="175"/> + <source>Extract archive into a directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="180"/> + <source>Add Directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="183"/> + <source>Add directory to archive</source> + <translation type="unfinished"></translation> + </message> +</context> +</TS> diff --git a/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_az.ts b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_az.ts new file mode 100644 index 00000000..8ad730ee --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_az.ts @@ -0,0 +1,97 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.1" language="az_AZ"> +<context> + <name>MainUI</name> + <message> + <location filename="../MainUI.ui" line="14"/> + <source>MainWindow</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="29"/> + <source>Archive:</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="88"/> + <source>File</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="97"/> + <source>Edit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="111"/> + <source>toolBar</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="135"/> + <source>&Open Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="138"/> + <source>Open archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="143"/> + <source>&New Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="146"/> + <source>New archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="151"/> + <source>&Quit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="156"/> + <source>Add File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="159"/> + <source>Add files to archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="164"/> + <source>Remove File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="167"/> + <source>Remove selection from archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="172"/> + <source>Extract All</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="175"/> + <source>Extract archive into a directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="180"/> + <source>Add Directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="183"/> + <source>Add directory to archive</source> + <translation type="unfinished"></translation> + </message> +</context> +</TS> diff --git a/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_bg.ts b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_bg.ts new file mode 100644 index 00000000..026e1632 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_bg.ts @@ -0,0 +1,97 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.1" language="bg_BG"> +<context> + <name>MainUI</name> + <message> + <location filename="../MainUI.ui" line="14"/> + <source>MainWindow</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="29"/> + <source>Archive:</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="88"/> + <source>File</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="97"/> + <source>Edit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="111"/> + <source>toolBar</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="135"/> + <source>&Open Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="138"/> + <source>Open archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="143"/> + <source>&New Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="146"/> + <source>New archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="151"/> + <source>&Quit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="156"/> + <source>Add File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="159"/> + <source>Add files to archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="164"/> + <source>Remove File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="167"/> + <source>Remove selection from archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="172"/> + <source>Extract All</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="175"/> + <source>Extract archive into a directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="180"/> + <source>Add Directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="183"/> + <source>Add directory to archive</source> + <translation type="unfinished"></translation> + </message> +</context> +</TS> diff --git a/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_bn.ts b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_bn.ts new file mode 100644 index 00000000..bc7f9953 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_bn.ts @@ -0,0 +1,97 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.1" language="bn_BD"> +<context> + <name>MainUI</name> + <message> + <location filename="../MainUI.ui" line="14"/> + <source>MainWindow</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="29"/> + <source>Archive:</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="88"/> + <source>File</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="97"/> + <source>Edit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="111"/> + <source>toolBar</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="135"/> + <source>&Open Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="138"/> + <source>Open archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="143"/> + <source>&New Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="146"/> + <source>New archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="151"/> + <source>&Quit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="156"/> + <source>Add File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="159"/> + <source>Add files to archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="164"/> + <source>Remove File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="167"/> + <source>Remove selection from archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="172"/> + <source>Extract All</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="175"/> + <source>Extract archive into a directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="180"/> + <source>Add Directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="183"/> + <source>Add directory to archive</source> + <translation type="unfinished"></translation> + </message> +</context> +</TS> diff --git a/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_bs.ts b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_bs.ts new file mode 100644 index 00000000..3b55fd7f --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_bs.ts @@ -0,0 +1,97 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.1" language="bs_BA"> +<context> + <name>MainUI</name> + <message> + <location filename="../MainUI.ui" line="14"/> + <source>MainWindow</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="29"/> + <source>Archive:</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="88"/> + <source>File</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="97"/> + <source>Edit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="111"/> + <source>toolBar</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="135"/> + <source>&Open Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="138"/> + <source>Open archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="143"/> + <source>&New Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="146"/> + <source>New archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="151"/> + <source>&Quit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="156"/> + <source>Add File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="159"/> + <source>Add files to archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="164"/> + <source>Remove File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="167"/> + <source>Remove selection from archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="172"/> + <source>Extract All</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="175"/> + <source>Extract archive into a directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="180"/> + <source>Add Directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="183"/> + <source>Add directory to archive</source> + <translation type="unfinished"></translation> + </message> +</context> +</TS> diff --git a/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_ca.ts b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_ca.ts new file mode 100644 index 00000000..35c9bc27 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_ca.ts @@ -0,0 +1,97 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.1" language="ca_ES"> +<context> + <name>MainUI</name> + <message> + <location filename="../MainUI.ui" line="14"/> + <source>MainWindow</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="29"/> + <source>Archive:</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="88"/> + <source>File</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="97"/> + <source>Edit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="111"/> + <source>toolBar</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="135"/> + <source>&Open Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="138"/> + <source>Open archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="143"/> + <source>&New Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="146"/> + <source>New archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="151"/> + <source>&Quit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="156"/> + <source>Add File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="159"/> + <source>Add files to archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="164"/> + <source>Remove File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="167"/> + <source>Remove selection from archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="172"/> + <source>Extract All</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="175"/> + <source>Extract archive into a directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="180"/> + <source>Add Directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="183"/> + <source>Add directory to archive</source> + <translation type="unfinished"></translation> + </message> +</context> +</TS> diff --git a/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_cs.ts b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_cs.ts new file mode 100644 index 00000000..a7e6efdc --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_cs.ts @@ -0,0 +1,97 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.1" language="cs_CZ"> +<context> + <name>MainUI</name> + <message> + <location filename="../MainUI.ui" line="14"/> + <source>MainWindow</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="29"/> + <source>Archive:</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="88"/> + <source>File</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="97"/> + <source>Edit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="111"/> + <source>toolBar</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="135"/> + <source>&Open Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="138"/> + <source>Open archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="143"/> + <source>&New Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="146"/> + <source>New archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="151"/> + <source>&Quit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="156"/> + <source>Add File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="159"/> + <source>Add files to archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="164"/> + <source>Remove File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="167"/> + <source>Remove selection from archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="172"/> + <source>Extract All</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="175"/> + <source>Extract archive into a directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="180"/> + <source>Add Directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="183"/> + <source>Add directory to archive</source> + <translation type="unfinished"></translation> + </message> +</context> +</TS> diff --git a/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_cy.ts b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_cy.ts new file mode 100644 index 00000000..76846a06 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_cy.ts @@ -0,0 +1,97 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.1" language="cy_GB"> +<context> + <name>MainUI</name> + <message> + <location filename="../MainUI.ui" line="14"/> + <source>MainWindow</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="29"/> + <source>Archive:</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="88"/> + <source>File</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="97"/> + <source>Edit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="111"/> + <source>toolBar</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="135"/> + <source>&Open Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="138"/> + <source>Open archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="143"/> + <source>&New Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="146"/> + <source>New archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="151"/> + <source>&Quit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="156"/> + <source>Add File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="159"/> + <source>Add files to archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="164"/> + <source>Remove File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="167"/> + <source>Remove selection from archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="172"/> + <source>Extract All</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="175"/> + <source>Extract archive into a directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="180"/> + <source>Add Directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="183"/> + <source>Add directory to archive</source> + <translation type="unfinished"></translation> + </message> +</context> +</TS> diff --git a/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_da.ts b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_da.ts new file mode 100644 index 00000000..827ed758 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_da.ts @@ -0,0 +1,97 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.1" language="da_DK"> +<context> + <name>MainUI</name> + <message> + <location filename="../MainUI.ui" line="14"/> + <source>MainWindow</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="29"/> + <source>Archive:</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="88"/> + <source>File</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="97"/> + <source>Edit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="111"/> + <source>toolBar</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="135"/> + <source>&Open Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="138"/> + <source>Open archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="143"/> + <source>&New Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="146"/> + <source>New archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="151"/> + <source>&Quit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="156"/> + <source>Add File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="159"/> + <source>Add files to archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="164"/> + <source>Remove File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="167"/> + <source>Remove selection from archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="172"/> + <source>Extract All</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="175"/> + <source>Extract archive into a directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="180"/> + <source>Add Directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="183"/> + <source>Add directory to archive</source> + <translation type="unfinished"></translation> + </message> +</context> +</TS> diff --git a/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_de.ts b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_de.ts new file mode 100644 index 00000000..e7d473ca --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_de.ts @@ -0,0 +1,97 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.1" language="de_DE"> +<context> + <name>MainUI</name> + <message> + <location filename="../MainUI.ui" line="14"/> + <source>MainWindow</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="29"/> + <source>Archive:</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="88"/> + <source>File</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="97"/> + <source>Edit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="111"/> + <source>toolBar</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="135"/> + <source>&Open Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="138"/> + <source>Open archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="143"/> + <source>&New Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="146"/> + <source>New archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="151"/> + <source>&Quit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="156"/> + <source>Add File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="159"/> + <source>Add files to archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="164"/> + <source>Remove File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="167"/> + <source>Remove selection from archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="172"/> + <source>Extract All</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="175"/> + <source>Extract archive into a directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="180"/> + <source>Add Directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="183"/> + <source>Add directory to archive</source> + <translation type="unfinished"></translation> + </message> +</context> +</TS> diff --git a/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_el.ts b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_el.ts new file mode 100644 index 00000000..63742497 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_el.ts @@ -0,0 +1,97 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.1" language="el_GR"> +<context> + <name>MainUI</name> + <message> + <location filename="../MainUI.ui" line="14"/> + <source>MainWindow</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="29"/> + <source>Archive:</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="88"/> + <source>File</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="97"/> + <source>Edit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="111"/> + <source>toolBar</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="135"/> + <source>&Open Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="138"/> + <source>Open archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="143"/> + <source>&New Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="146"/> + <source>New archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="151"/> + <source>&Quit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="156"/> + <source>Add File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="159"/> + <source>Add files to archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="164"/> + <source>Remove File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="167"/> + <source>Remove selection from archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="172"/> + <source>Extract All</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="175"/> + <source>Extract archive into a directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="180"/> + <source>Add Directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="183"/> + <source>Add directory to archive</source> + <translation type="unfinished"></translation> + </message> +</context> +</TS> diff --git a/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_en_GB.ts b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_en_GB.ts new file mode 100644 index 00000000..72a6c400 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_en_GB.ts @@ -0,0 +1,97 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.1" language="en_GB"> +<context> + <name>MainUI</name> + <message> + <location filename="../MainUI.ui" line="14"/> + <source>MainWindow</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="29"/> + <source>Archive:</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="88"/> + <source>File</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="97"/> + <source>Edit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="111"/> + <source>toolBar</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="135"/> + <source>&Open Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="138"/> + <source>Open archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="143"/> + <source>&New Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="146"/> + <source>New archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="151"/> + <source>&Quit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="156"/> + <source>Add File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="159"/> + <source>Add files to archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="164"/> + <source>Remove File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="167"/> + <source>Remove selection from archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="172"/> + <source>Extract All</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="175"/> + <source>Extract archive into a directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="180"/> + <source>Add Directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="183"/> + <source>Add directory to archive</source> + <translation type="unfinished"></translation> + </message> +</context> +</TS> diff --git a/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_en_ZA.ts b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_en_ZA.ts new file mode 100644 index 00000000..5dd14258 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_en_ZA.ts @@ -0,0 +1,97 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.1" language="en_ZA"> +<context> + <name>MainUI</name> + <message> + <location filename="../MainUI.ui" line="14"/> + <source>MainWindow</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="29"/> + <source>Archive:</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="88"/> + <source>File</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="97"/> + <source>Edit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="111"/> + <source>toolBar</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="135"/> + <source>&Open Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="138"/> + <source>Open archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="143"/> + <source>&New Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="146"/> + <source>New archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="151"/> + <source>&Quit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="156"/> + <source>Add File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="159"/> + <source>Add files to archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="164"/> + <source>Remove File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="167"/> + <source>Remove selection from archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="172"/> + <source>Extract All</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="175"/> + <source>Extract archive into a directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="180"/> + <source>Add Directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="183"/> + <source>Add directory to archive</source> + <translation type="unfinished"></translation> + </message> +</context> +</TS> diff --git a/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_es.ts b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_es.ts new file mode 100644 index 00000000..61227156 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_es.ts @@ -0,0 +1,97 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.1" language="es_ES"> +<context> + <name>MainUI</name> + <message> + <location filename="../MainUI.ui" line="14"/> + <source>MainWindow</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="29"/> + <source>Archive:</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="88"/> + <source>File</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="97"/> + <source>Edit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="111"/> + <source>toolBar</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="135"/> + <source>&Open Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="138"/> + <source>Open archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="143"/> + <source>&New Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="146"/> + <source>New archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="151"/> + <source>&Quit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="156"/> + <source>Add File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="159"/> + <source>Add files to archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="164"/> + <source>Remove File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="167"/> + <source>Remove selection from archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="172"/> + <source>Extract All</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="175"/> + <source>Extract archive into a directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="180"/> + <source>Add Directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="183"/> + <source>Add directory to archive</source> + <translation type="unfinished"></translation> + </message> +</context> +</TS> diff --git a/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_et.ts b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_et.ts new file mode 100644 index 00000000..9ee54edb --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_et.ts @@ -0,0 +1,97 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.1" language="et_EE"> +<context> + <name>MainUI</name> + <message> + <location filename="../MainUI.ui" line="14"/> + <source>MainWindow</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="29"/> + <source>Archive:</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="88"/> + <source>File</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="97"/> + <source>Edit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="111"/> + <source>toolBar</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="135"/> + <source>&Open Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="138"/> + <source>Open archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="143"/> + <source>&New Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="146"/> + <source>New archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="151"/> + <source>&Quit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="156"/> + <source>Add File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="159"/> + <source>Add files to archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="164"/> + <source>Remove File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="167"/> + <source>Remove selection from archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="172"/> + <source>Extract All</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="175"/> + <source>Extract archive into a directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="180"/> + <source>Add Directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="183"/> + <source>Add directory to archive</source> + <translation type="unfinished"></translation> + </message> +</context> +</TS> diff --git a/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_eu.ts b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_eu.ts new file mode 100644 index 00000000..c2654d9a --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_eu.ts @@ -0,0 +1,97 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.1" language="eu_ES"> +<context> + <name>MainUI</name> + <message> + <location filename="../MainUI.ui" line="14"/> + <source>MainWindow</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="29"/> + <source>Archive:</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="88"/> + <source>File</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="97"/> + <source>Edit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="111"/> + <source>toolBar</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="135"/> + <source>&Open Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="138"/> + <source>Open archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="143"/> + <source>&New Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="146"/> + <source>New archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="151"/> + <source>&Quit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="156"/> + <source>Add File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="159"/> + <source>Add files to archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="164"/> + <source>Remove File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="167"/> + <source>Remove selection from archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="172"/> + <source>Extract All</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="175"/> + <source>Extract archive into a directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="180"/> + <source>Add Directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="183"/> + <source>Add directory to archive</source> + <translation type="unfinished"></translation> + </message> +</context> +</TS> diff --git a/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_fa.ts b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_fa.ts new file mode 100644 index 00000000..f6e3a7df --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_fa.ts @@ -0,0 +1,97 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.1" language="fa_IR"> +<context> + <name>MainUI</name> + <message> + <location filename="../MainUI.ui" line="14"/> + <source>MainWindow</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="29"/> + <source>Archive:</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="88"/> + <source>File</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="97"/> + <source>Edit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="111"/> + <source>toolBar</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="135"/> + <source>&Open Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="138"/> + <source>Open archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="143"/> + <source>&New Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="146"/> + <source>New archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="151"/> + <source>&Quit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="156"/> + <source>Add File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="159"/> + <source>Add files to archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="164"/> + <source>Remove File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="167"/> + <source>Remove selection from archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="172"/> + <source>Extract All</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="175"/> + <source>Extract archive into a directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="180"/> + <source>Add Directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="183"/> + <source>Add directory to archive</source> + <translation type="unfinished"></translation> + </message> +</context> +</TS> diff --git a/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_fi.ts b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_fi.ts new file mode 100644 index 00000000..08245066 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_fi.ts @@ -0,0 +1,97 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.1" language="fi_FI"> +<context> + <name>MainUI</name> + <message> + <location filename="../MainUI.ui" line="14"/> + <source>MainWindow</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="29"/> + <source>Archive:</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="88"/> + <source>File</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="97"/> + <source>Edit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="111"/> + <source>toolBar</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="135"/> + <source>&Open Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="138"/> + <source>Open archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="143"/> + <source>&New Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="146"/> + <source>New archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="151"/> + <source>&Quit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="156"/> + <source>Add File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="159"/> + <source>Add files to archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="164"/> + <source>Remove File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="167"/> + <source>Remove selection from archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="172"/> + <source>Extract All</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="175"/> + <source>Extract archive into a directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="180"/> + <source>Add Directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="183"/> + <source>Add directory to archive</source> + <translation type="unfinished"></translation> + </message> +</context> +</TS> diff --git a/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_fr.ts b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_fr.ts new file mode 100644 index 00000000..260fee63 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_fr.ts @@ -0,0 +1,97 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.1" language="fr_FR"> +<context> + <name>MainUI</name> + <message> + <location filename="../MainUI.ui" line="14"/> + <source>MainWindow</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="29"/> + <source>Archive:</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="88"/> + <source>File</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="97"/> + <source>Edit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="111"/> + <source>toolBar</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="135"/> + <source>&Open Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="138"/> + <source>Open archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="143"/> + <source>&New Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="146"/> + <source>New archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="151"/> + <source>&Quit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="156"/> + <source>Add File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="159"/> + <source>Add files to archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="164"/> + <source>Remove File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="167"/> + <source>Remove selection from archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="172"/> + <source>Extract All</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="175"/> + <source>Extract archive into a directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="180"/> + <source>Add Directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="183"/> + <source>Add directory to archive</source> + <translation type="unfinished"></translation> + </message> +</context> +</TS> diff --git a/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_fr_CA.ts b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_fr_CA.ts new file mode 100644 index 00000000..6e51aa1c --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_fr_CA.ts @@ -0,0 +1,97 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.1" language="fr_CA"> +<context> + <name>MainUI</name> + <message> + <location filename="../MainUI.ui" line="14"/> + <source>MainWindow</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="29"/> + <source>Archive:</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="88"/> + <source>File</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="97"/> + <source>Edit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="111"/> + <source>toolBar</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="135"/> + <source>&Open Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="138"/> + <source>Open archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="143"/> + <source>&New Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="146"/> + <source>New archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="151"/> + <source>&Quit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="156"/> + <source>Add File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="159"/> + <source>Add files to archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="164"/> + <source>Remove File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="167"/> + <source>Remove selection from archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="172"/> + <source>Extract All</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="175"/> + <source>Extract archive into a directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="180"/> + <source>Add Directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="183"/> + <source>Add directory to archive</source> + <translation type="unfinished"></translation> + </message> +</context> +</TS> diff --git a/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_gl.ts b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_gl.ts new file mode 100644 index 00000000..a99012ed --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_gl.ts @@ -0,0 +1,97 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.1" language="gl_ES"> +<context> + <name>MainUI</name> + <message> + <location filename="../MainUI.ui" line="14"/> + <source>MainWindow</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="29"/> + <source>Archive:</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="88"/> + <source>File</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="97"/> + <source>Edit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="111"/> + <source>toolBar</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="135"/> + <source>&Open Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="138"/> + <source>Open archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="143"/> + <source>&New Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="146"/> + <source>New archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="151"/> + <source>&Quit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="156"/> + <source>Add File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="159"/> + <source>Add files to archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="164"/> + <source>Remove File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="167"/> + <source>Remove selection from archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="172"/> + <source>Extract All</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="175"/> + <source>Extract archive into a directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="180"/> + <source>Add Directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="183"/> + <source>Add directory to archive</source> + <translation type="unfinished"></translation> + </message> +</context> +</TS> diff --git a/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_he.ts b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_he.ts new file mode 100644 index 00000000..4d0e9b93 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_he.ts @@ -0,0 +1,97 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.1" language="he_IL"> +<context> + <name>MainUI</name> + <message> + <location filename="../MainUI.ui" line="14"/> + <source>MainWindow</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="29"/> + <source>Archive:</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="88"/> + <source>File</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="97"/> + <source>Edit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="111"/> + <source>toolBar</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="135"/> + <source>&Open Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="138"/> + <source>Open archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="143"/> + <source>&New Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="146"/> + <source>New archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="151"/> + <source>&Quit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="156"/> + <source>Add File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="159"/> + <source>Add files to archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="164"/> + <source>Remove File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="167"/> + <source>Remove selection from archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="172"/> + <source>Extract All</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="175"/> + <source>Extract archive into a directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="180"/> + <source>Add Directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="183"/> + <source>Add directory to archive</source> + <translation type="unfinished"></translation> + </message> +</context> +</TS> diff --git a/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_hi.ts b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_hi.ts new file mode 100644 index 00000000..b656ae44 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_hi.ts @@ -0,0 +1,97 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.1" language="hi_IN"> +<context> + <name>MainUI</name> + <message> + <location filename="../MainUI.ui" line="14"/> + <source>MainWindow</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="29"/> + <source>Archive:</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="88"/> + <source>File</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="97"/> + <source>Edit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="111"/> + <source>toolBar</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="135"/> + <source>&Open Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="138"/> + <source>Open archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="143"/> + <source>&New Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="146"/> + <source>New archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="151"/> + <source>&Quit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="156"/> + <source>Add File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="159"/> + <source>Add files to archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="164"/> + <source>Remove File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="167"/> + <source>Remove selection from archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="172"/> + <source>Extract All</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="175"/> + <source>Extract archive into a directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="180"/> + <source>Add Directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="183"/> + <source>Add directory to archive</source> + <translation type="unfinished"></translation> + </message> +</context> +</TS> diff --git a/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_hr.ts b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_hr.ts new file mode 100644 index 00000000..84851442 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_hr.ts @@ -0,0 +1,97 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.1" language="hr_HR"> +<context> + <name>MainUI</name> + <message> + <location filename="../MainUI.ui" line="14"/> + <source>MainWindow</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="29"/> + <source>Archive:</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="88"/> + <source>File</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="97"/> + <source>Edit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="111"/> + <source>toolBar</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="135"/> + <source>&Open Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="138"/> + <source>Open archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="143"/> + <source>&New Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="146"/> + <source>New archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="151"/> + <source>&Quit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="156"/> + <source>Add File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="159"/> + <source>Add files to archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="164"/> + <source>Remove File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="167"/> + <source>Remove selection from archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="172"/> + <source>Extract All</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="175"/> + <source>Extract archive into a directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="180"/> + <source>Add Directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="183"/> + <source>Add directory to archive</source> + <translation type="unfinished"></translation> + </message> +</context> +</TS> diff --git a/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_hu.ts b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_hu.ts new file mode 100644 index 00000000..0c0af316 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_hu.ts @@ -0,0 +1,97 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.1" language="hu_HU"> +<context> + <name>MainUI</name> + <message> + <location filename="../MainUI.ui" line="14"/> + <source>MainWindow</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="29"/> + <source>Archive:</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="88"/> + <source>File</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="97"/> + <source>Edit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="111"/> + <source>toolBar</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="135"/> + <source>&Open Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="138"/> + <source>Open archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="143"/> + <source>&New Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="146"/> + <source>New archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="151"/> + <source>&Quit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="156"/> + <source>Add File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="159"/> + <source>Add files to archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="164"/> + <source>Remove File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="167"/> + <source>Remove selection from archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="172"/> + <source>Extract All</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="175"/> + <source>Extract archive into a directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="180"/> + <source>Add Directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="183"/> + <source>Add directory to archive</source> + <translation type="unfinished"></translation> + </message> +</context> +</TS> diff --git a/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_id.ts b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_id.ts new file mode 100644 index 00000000..487a8454 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_id.ts @@ -0,0 +1,97 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.1" language="id_ID"> +<context> + <name>MainUI</name> + <message> + <location filename="../MainUI.ui" line="14"/> + <source>MainWindow</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="29"/> + <source>Archive:</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="88"/> + <source>File</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="97"/> + <source>Edit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="111"/> + <source>toolBar</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="135"/> + <source>&Open Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="138"/> + <source>Open archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="143"/> + <source>&New Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="146"/> + <source>New archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="151"/> + <source>&Quit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="156"/> + <source>Add File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="159"/> + <source>Add files to archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="164"/> + <source>Remove File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="167"/> + <source>Remove selection from archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="172"/> + <source>Extract All</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="175"/> + <source>Extract archive into a directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="180"/> + <source>Add Directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="183"/> + <source>Add directory to archive</source> + <translation type="unfinished"></translation> + </message> +</context> +</TS> diff --git a/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_is.ts b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_is.ts new file mode 100644 index 00000000..4471fca4 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_is.ts @@ -0,0 +1,97 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.1" language="is_IS"> +<context> + <name>MainUI</name> + <message> + <location filename="../MainUI.ui" line="14"/> + <source>MainWindow</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="29"/> + <source>Archive:</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="88"/> + <source>File</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="97"/> + <source>Edit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="111"/> + <source>toolBar</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="135"/> + <source>&Open Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="138"/> + <source>Open archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="143"/> + <source>&New Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="146"/> + <source>New archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="151"/> + <source>&Quit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="156"/> + <source>Add File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="159"/> + <source>Add files to archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="164"/> + <source>Remove File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="167"/> + <source>Remove selection from archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="172"/> + <source>Extract All</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="175"/> + <source>Extract archive into a directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="180"/> + <source>Add Directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="183"/> + <source>Add directory to archive</source> + <translation type="unfinished"></translation> + </message> +</context> +</TS> diff --git a/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_it.ts b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_it.ts new file mode 100644 index 00000000..1d73c016 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_it.ts @@ -0,0 +1,97 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.1" language="it_IT"> +<context> + <name>MainUI</name> + <message> + <location filename="../MainUI.ui" line="14"/> + <source>MainWindow</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="29"/> + <source>Archive:</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="88"/> + <source>File</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="97"/> + <source>Edit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="111"/> + <source>toolBar</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="135"/> + <source>&Open Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="138"/> + <source>Open archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="143"/> + <source>&New Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="146"/> + <source>New archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="151"/> + <source>&Quit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="156"/> + <source>Add File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="159"/> + <source>Add files to archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="164"/> + <source>Remove File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="167"/> + <source>Remove selection from archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="172"/> + <source>Extract All</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="175"/> + <source>Extract archive into a directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="180"/> + <source>Add Directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="183"/> + <source>Add directory to archive</source> + <translation type="unfinished"></translation> + </message> +</context> +</TS> diff --git a/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_ja.ts b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_ja.ts new file mode 100644 index 00000000..3e862fee --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_ja.ts @@ -0,0 +1,97 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.1" language="ja_JP"> +<context> + <name>MainUI</name> + <message> + <location filename="../MainUI.ui" line="14"/> + <source>MainWindow</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="29"/> + <source>Archive:</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="88"/> + <source>File</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="97"/> + <source>Edit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="111"/> + <source>toolBar</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="135"/> + <source>&Open Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="138"/> + <source>Open archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="143"/> + <source>&New Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="146"/> + <source>New archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="151"/> + <source>&Quit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="156"/> + <source>Add File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="159"/> + <source>Add files to archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="164"/> + <source>Remove File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="167"/> + <source>Remove selection from archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="172"/> + <source>Extract All</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="175"/> + <source>Extract archive into a directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="180"/> + <source>Add Directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="183"/> + <source>Add directory to archive</source> + <translation type="unfinished"></translation> + </message> +</context> +</TS> diff --git a/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_ka.ts b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_ka.ts new file mode 100644 index 00000000..64c54faa --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_ka.ts @@ -0,0 +1,97 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.1" language="ka_GE"> +<context> + <name>MainUI</name> + <message> + <location filename="../MainUI.ui" line="14"/> + <source>MainWindow</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="29"/> + <source>Archive:</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="88"/> + <source>File</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="97"/> + <source>Edit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="111"/> + <source>toolBar</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="135"/> + <source>&Open Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="138"/> + <source>Open archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="143"/> + <source>&New Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="146"/> + <source>New archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="151"/> + <source>&Quit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="156"/> + <source>Add File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="159"/> + <source>Add files to archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="164"/> + <source>Remove File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="167"/> + <source>Remove selection from archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="172"/> + <source>Extract All</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="175"/> + <source>Extract archive into a directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="180"/> + <source>Add Directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="183"/> + <source>Add directory to archive</source> + <translation type="unfinished"></translation> + </message> +</context> +</TS> diff --git a/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_ko.ts b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_ko.ts new file mode 100644 index 00000000..86c97cd8 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_ko.ts @@ -0,0 +1,97 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.1" language="ko_KR"> +<context> + <name>MainUI</name> + <message> + <location filename="../MainUI.ui" line="14"/> + <source>MainWindow</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="29"/> + <source>Archive:</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="88"/> + <source>File</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="97"/> + <source>Edit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="111"/> + <source>toolBar</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="135"/> + <source>&Open Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="138"/> + <source>Open archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="143"/> + <source>&New Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="146"/> + <source>New archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="151"/> + <source>&Quit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="156"/> + <source>Add File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="159"/> + <source>Add files to archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="164"/> + <source>Remove File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="167"/> + <source>Remove selection from archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="172"/> + <source>Extract All</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="175"/> + <source>Extract archive into a directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="180"/> + <source>Add Directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="183"/> + <source>Add directory to archive</source> + <translation type="unfinished"></translation> + </message> +</context> +</TS> diff --git a/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_lt.ts b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_lt.ts new file mode 100644 index 00000000..4186ab73 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_lt.ts @@ -0,0 +1,97 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.1" language="lt_LT"> +<context> + <name>MainUI</name> + <message> + <location filename="../MainUI.ui" line="14"/> + <source>MainWindow</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="29"/> + <source>Archive:</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="88"/> + <source>File</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="97"/> + <source>Edit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="111"/> + <source>toolBar</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="135"/> + <source>&Open Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="138"/> + <source>Open archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="143"/> + <source>&New Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="146"/> + <source>New archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="151"/> + <source>&Quit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="156"/> + <source>Add File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="159"/> + <source>Add files to archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="164"/> + <source>Remove File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="167"/> + <source>Remove selection from archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="172"/> + <source>Extract All</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="175"/> + <source>Extract archive into a directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="180"/> + <source>Add Directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="183"/> + <source>Add directory to archive</source> + <translation type="unfinished"></translation> + </message> +</context> +</TS> diff --git a/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_lv.ts b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_lv.ts new file mode 100644 index 00000000..7bd2fd6e --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_lv.ts @@ -0,0 +1,97 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.1" language="lv_LV"> +<context> + <name>MainUI</name> + <message> + <location filename="../MainUI.ui" line="14"/> + <source>MainWindow</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="29"/> + <source>Archive:</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="88"/> + <source>File</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="97"/> + <source>Edit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="111"/> + <source>toolBar</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="135"/> + <source>&Open Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="138"/> + <source>Open archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="143"/> + <source>&New Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="146"/> + <source>New archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="151"/> + <source>&Quit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="156"/> + <source>Add File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="159"/> + <source>Add files to archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="164"/> + <source>Remove File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="167"/> + <source>Remove selection from archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="172"/> + <source>Extract All</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="175"/> + <source>Extract archive into a directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="180"/> + <source>Add Directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="183"/> + <source>Add directory to archive</source> + <translation type="unfinished"></translation> + </message> +</context> +</TS> diff --git a/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_mk.ts b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_mk.ts new file mode 100644 index 00000000..f2e36d4e --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_mk.ts @@ -0,0 +1,97 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.1" language="mk_MK"> +<context> + <name>MainUI</name> + <message> + <location filename="../MainUI.ui" line="14"/> + <source>MainWindow</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="29"/> + <source>Archive:</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="88"/> + <source>File</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="97"/> + <source>Edit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="111"/> + <source>toolBar</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="135"/> + <source>&Open Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="138"/> + <source>Open archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="143"/> + <source>&New Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="146"/> + <source>New archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="151"/> + <source>&Quit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="156"/> + <source>Add File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="159"/> + <source>Add files to archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="164"/> + <source>Remove File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="167"/> + <source>Remove selection from archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="172"/> + <source>Extract All</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="175"/> + <source>Extract archive into a directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="180"/> + <source>Add Directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="183"/> + <source>Add directory to archive</source> + <translation type="unfinished"></translation> + </message> +</context> +</TS> diff --git a/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_mn.ts b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_mn.ts new file mode 100644 index 00000000..36509fbe --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_mn.ts @@ -0,0 +1,97 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.1" language="mn_MN"> +<context> + <name>MainUI</name> + <message> + <location filename="../MainUI.ui" line="14"/> + <source>MainWindow</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="29"/> + <source>Archive:</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="88"/> + <source>File</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="97"/> + <source>Edit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="111"/> + <source>toolBar</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="135"/> + <source>&Open Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="138"/> + <source>Open archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="143"/> + <source>&New Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="146"/> + <source>New archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="151"/> + <source>&Quit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="156"/> + <source>Add File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="159"/> + <source>Add files to archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="164"/> + <source>Remove File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="167"/> + <source>Remove selection from archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="172"/> + <source>Extract All</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="175"/> + <source>Extract archive into a directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="180"/> + <source>Add Directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="183"/> + <source>Add directory to archive</source> + <translation type="unfinished"></translation> + </message> +</context> +</TS> diff --git a/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_ms.ts b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_ms.ts new file mode 100644 index 00000000..c25fe143 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_ms.ts @@ -0,0 +1,97 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.1" language="ms_MY"> +<context> + <name>MainUI</name> + <message> + <location filename="../MainUI.ui" line="14"/> + <source>MainWindow</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="29"/> + <source>Archive:</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="88"/> + <source>File</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="97"/> + <source>Edit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="111"/> + <source>toolBar</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="135"/> + <source>&Open Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="138"/> + <source>Open archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="143"/> + <source>&New Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="146"/> + <source>New archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="151"/> + <source>&Quit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="156"/> + <source>Add File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="159"/> + <source>Add files to archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="164"/> + <source>Remove File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="167"/> + <source>Remove selection from archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="172"/> + <source>Extract All</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="175"/> + <source>Extract archive into a directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="180"/> + <source>Add Directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="183"/> + <source>Add directory to archive</source> + <translation type="unfinished"></translation> + </message> +</context> +</TS> diff --git a/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_mt.ts b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_mt.ts new file mode 100644 index 00000000..dca63bbf --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_mt.ts @@ -0,0 +1,97 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.1" language="mt_MT"> +<context> + <name>MainUI</name> + <message> + <location filename="../MainUI.ui" line="14"/> + <source>MainWindow</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="29"/> + <source>Archive:</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="88"/> + <source>File</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="97"/> + <source>Edit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="111"/> + <source>toolBar</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="135"/> + <source>&Open Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="138"/> + <source>Open archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="143"/> + <source>&New Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="146"/> + <source>New archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="151"/> + <source>&Quit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="156"/> + <source>Add File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="159"/> + <source>Add files to archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="164"/> + <source>Remove File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="167"/> + <source>Remove selection from archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="172"/> + <source>Extract All</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="175"/> + <source>Extract archive into a directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="180"/> + <source>Add Directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="183"/> + <source>Add directory to archive</source> + <translation type="unfinished"></translation> + </message> +</context> +</TS> diff --git a/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_nb.ts b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_nb.ts new file mode 100644 index 00000000..286321b1 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_nb.ts @@ -0,0 +1,97 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.1" language="nb_NO"> +<context> + <name>MainUI</name> + <message> + <location filename="../MainUI.ui" line="14"/> + <source>MainWindow</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="29"/> + <source>Archive:</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="88"/> + <source>File</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="97"/> + <source>Edit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="111"/> + <source>toolBar</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="135"/> + <source>&Open Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="138"/> + <source>Open archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="143"/> + <source>&New Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="146"/> + <source>New archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="151"/> + <source>&Quit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="156"/> + <source>Add File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="159"/> + <source>Add files to archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="164"/> + <source>Remove File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="167"/> + <source>Remove selection from archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="172"/> + <source>Extract All</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="175"/> + <source>Extract archive into a directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="180"/> + <source>Add Directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="183"/> + <source>Add directory to archive</source> + <translation type="unfinished"></translation> + </message> +</context> +</TS> diff --git a/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_nl.ts b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_nl.ts new file mode 100644 index 00000000..6d37a34a --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_nl.ts @@ -0,0 +1,97 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.1" language="nl_NL"> +<context> + <name>MainUI</name> + <message> + <location filename="../MainUI.ui" line="14"/> + <source>MainWindow</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="29"/> + <source>Archive:</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="88"/> + <source>File</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="97"/> + <source>Edit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="111"/> + <source>toolBar</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="135"/> + <source>&Open Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="138"/> + <source>Open archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="143"/> + <source>&New Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="146"/> + <source>New archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="151"/> + <source>&Quit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="156"/> + <source>Add File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="159"/> + <source>Add files to archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="164"/> + <source>Remove File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="167"/> + <source>Remove selection from archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="172"/> + <source>Extract All</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="175"/> + <source>Extract archive into a directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="180"/> + <source>Add Directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="183"/> + <source>Add directory to archive</source> + <translation type="unfinished"></translation> + </message> +</context> +</TS> diff --git a/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_pa.ts b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_pa.ts new file mode 100644 index 00000000..db42c2c5 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_pa.ts @@ -0,0 +1,97 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.1" language="pa_IN"> +<context> + <name>MainUI</name> + <message> + <location filename="../MainUI.ui" line="14"/> + <source>MainWindow</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="29"/> + <source>Archive:</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="88"/> + <source>File</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="97"/> + <source>Edit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="111"/> + <source>toolBar</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="135"/> + <source>&Open Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="138"/> + <source>Open archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="143"/> + <source>&New Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="146"/> + <source>New archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="151"/> + <source>&Quit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="156"/> + <source>Add File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="159"/> + <source>Add files to archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="164"/> + <source>Remove File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="167"/> + <source>Remove selection from archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="172"/> + <source>Extract All</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="175"/> + <source>Extract archive into a directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="180"/> + <source>Add Directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="183"/> + <source>Add directory to archive</source> + <translation type="unfinished"></translation> + </message> +</context> +</TS> diff --git a/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_pl.ts b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_pl.ts new file mode 100644 index 00000000..0e23358c --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_pl.ts @@ -0,0 +1,97 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.1" language="pl_PL"> +<context> + <name>MainUI</name> + <message> + <location filename="../MainUI.ui" line="14"/> + <source>MainWindow</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="29"/> + <source>Archive:</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="88"/> + <source>File</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="97"/> + <source>Edit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="111"/> + <source>toolBar</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="135"/> + <source>&Open Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="138"/> + <source>Open archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="143"/> + <source>&New Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="146"/> + <source>New archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="151"/> + <source>&Quit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="156"/> + <source>Add File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="159"/> + <source>Add files to archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="164"/> + <source>Remove File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="167"/> + <source>Remove selection from archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="172"/> + <source>Extract All</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="175"/> + <source>Extract archive into a directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="180"/> + <source>Add Directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="183"/> + <source>Add directory to archive</source> + <translation type="unfinished"></translation> + </message> +</context> +</TS> diff --git a/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_pt.ts b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_pt.ts new file mode 100644 index 00000000..e81e589f --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_pt.ts @@ -0,0 +1,97 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.1" language="pt_BR"> +<context> + <name>MainUI</name> + <message> + <location filename="../MainUI.ui" line="14"/> + <source>MainWindow</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="29"/> + <source>Archive:</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="88"/> + <source>File</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="97"/> + <source>Edit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="111"/> + <source>toolBar</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="135"/> + <source>&Open Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="138"/> + <source>Open archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="143"/> + <source>&New Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="146"/> + <source>New archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="151"/> + <source>&Quit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="156"/> + <source>Add File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="159"/> + <source>Add files to archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="164"/> + <source>Remove File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="167"/> + <source>Remove selection from archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="172"/> + <source>Extract All</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="175"/> + <source>Extract archive into a directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="180"/> + <source>Add Directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="183"/> + <source>Add directory to archive</source> + <translation type="unfinished"></translation> + </message> +</context> +</TS> diff --git a/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_pt_BR.ts b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_pt_BR.ts new file mode 100644 index 00000000..e81e589f --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_pt_BR.ts @@ -0,0 +1,97 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.1" language="pt_BR"> +<context> + <name>MainUI</name> + <message> + <location filename="../MainUI.ui" line="14"/> + <source>MainWindow</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="29"/> + <source>Archive:</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="88"/> + <source>File</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="97"/> + <source>Edit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="111"/> + <source>toolBar</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="135"/> + <source>&Open Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="138"/> + <source>Open archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="143"/> + <source>&New Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="146"/> + <source>New archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="151"/> + <source>&Quit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="156"/> + <source>Add File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="159"/> + <source>Add files to archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="164"/> + <source>Remove File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="167"/> + <source>Remove selection from archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="172"/> + <source>Extract All</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="175"/> + <source>Extract archive into a directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="180"/> + <source>Add Directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="183"/> + <source>Add directory to archive</source> + <translation type="unfinished"></translation> + </message> +</context> +</TS> diff --git a/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_ro.ts b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_ro.ts new file mode 100644 index 00000000..87fe6df6 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_ro.ts @@ -0,0 +1,97 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.1" language="ro_RO"> +<context> + <name>MainUI</name> + <message> + <location filename="../MainUI.ui" line="14"/> + <source>MainWindow</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="29"/> + <source>Archive:</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="88"/> + <source>File</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="97"/> + <source>Edit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="111"/> + <source>toolBar</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="135"/> + <source>&Open Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="138"/> + <source>Open archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="143"/> + <source>&New Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="146"/> + <source>New archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="151"/> + <source>&Quit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="156"/> + <source>Add File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="159"/> + <source>Add files to archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="164"/> + <source>Remove File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="167"/> + <source>Remove selection from archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="172"/> + <source>Extract All</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="175"/> + <source>Extract archive into a directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="180"/> + <source>Add Directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="183"/> + <source>Add directory to archive</source> + <translation type="unfinished"></translation> + </message> +</context> +</TS> diff --git a/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_ru.ts b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_ru.ts new file mode 100644 index 00000000..45605d01 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_ru.ts @@ -0,0 +1,97 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.1" language="ru_RU"> +<context> + <name>MainUI</name> + <message> + <location filename="../MainUI.ui" line="14"/> + <source>MainWindow</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="29"/> + <source>Archive:</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="88"/> + <source>File</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="97"/> + <source>Edit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="111"/> + <source>toolBar</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="135"/> + <source>&Open Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="138"/> + <source>Open archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="143"/> + <source>&New Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="146"/> + <source>New archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="151"/> + <source>&Quit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="156"/> + <source>Add File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="159"/> + <source>Add files to archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="164"/> + <source>Remove File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="167"/> + <source>Remove selection from archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="172"/> + <source>Extract All</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="175"/> + <source>Extract archive into a directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="180"/> + <source>Add Directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="183"/> + <source>Add directory to archive</source> + <translation type="unfinished"></translation> + </message> +</context> +</TS> diff --git a/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_sk.ts b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_sk.ts new file mode 100644 index 00000000..b106eb76 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_sk.ts @@ -0,0 +1,97 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.1" language="sk_SK"> +<context> + <name>MainUI</name> + <message> + <location filename="../MainUI.ui" line="14"/> + <source>MainWindow</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="29"/> + <source>Archive:</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="88"/> + <source>File</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="97"/> + <source>Edit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="111"/> + <source>toolBar</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="135"/> + <source>&Open Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="138"/> + <source>Open archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="143"/> + <source>&New Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="146"/> + <source>New archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="151"/> + <source>&Quit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="156"/> + <source>Add File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="159"/> + <source>Add files to archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="164"/> + <source>Remove File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="167"/> + <source>Remove selection from archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="172"/> + <source>Extract All</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="175"/> + <source>Extract archive into a directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="180"/> + <source>Add Directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="183"/> + <source>Add directory to archive</source> + <translation type="unfinished"></translation> + </message> +</context> +</TS> diff --git a/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_sl.ts b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_sl.ts new file mode 100644 index 00000000..38ae2d5b --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_sl.ts @@ -0,0 +1,97 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.1" language="sl_SI"> +<context> + <name>MainUI</name> + <message> + <location filename="../MainUI.ui" line="14"/> + <source>MainWindow</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="29"/> + <source>Archive:</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="88"/> + <source>File</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="97"/> + <source>Edit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="111"/> + <source>toolBar</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="135"/> + <source>&Open Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="138"/> + <source>Open archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="143"/> + <source>&New Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="146"/> + <source>New archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="151"/> + <source>&Quit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="156"/> + <source>Add File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="159"/> + <source>Add files to archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="164"/> + <source>Remove File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="167"/> + <source>Remove selection from archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="172"/> + <source>Extract All</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="175"/> + <source>Extract archive into a directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="180"/> + <source>Add Directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="183"/> + <source>Add directory to archive</source> + <translation type="unfinished"></translation> + </message> +</context> +</TS> diff --git a/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_sr.ts b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_sr.ts new file mode 100644 index 00000000..d09258be --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_sr.ts @@ -0,0 +1,97 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.1" language="sr_RS"> +<context> + <name>MainUI</name> + <message> + <location filename="../MainUI.ui" line="14"/> + <source>MainWindow</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="29"/> + <source>Archive:</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="88"/> + <source>File</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="97"/> + <source>Edit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="111"/> + <source>toolBar</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="135"/> + <source>&Open Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="138"/> + <source>Open archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="143"/> + <source>&New Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="146"/> + <source>New archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="151"/> + <source>&Quit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="156"/> + <source>Add File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="159"/> + <source>Add files to archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="164"/> + <source>Remove File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="167"/> + <source>Remove selection from archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="172"/> + <source>Extract All</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="175"/> + <source>Extract archive into a directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="180"/> + <source>Add Directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="183"/> + <source>Add directory to archive</source> + <translation type="unfinished"></translation> + </message> +</context> +</TS> diff --git a/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_sv.ts b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_sv.ts new file mode 100644 index 00000000..4d75eec1 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_sv.ts @@ -0,0 +1,97 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.1" language="sv_SE"> +<context> + <name>MainUI</name> + <message> + <location filename="../MainUI.ui" line="14"/> + <source>MainWindow</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="29"/> + <source>Archive:</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="88"/> + <source>File</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="97"/> + <source>Edit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="111"/> + <source>toolBar</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="135"/> + <source>&Open Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="138"/> + <source>Open archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="143"/> + <source>&New Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="146"/> + <source>New archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="151"/> + <source>&Quit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="156"/> + <source>Add File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="159"/> + <source>Add files to archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="164"/> + <source>Remove File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="167"/> + <source>Remove selection from archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="172"/> + <source>Extract All</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="175"/> + <source>Extract archive into a directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="180"/> + <source>Add Directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="183"/> + <source>Add directory to archive</source> + <translation type="unfinished"></translation> + </message> +</context> +</TS> diff --git a/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_sw.ts b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_sw.ts new file mode 100644 index 00000000..86f417f6 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_sw.ts @@ -0,0 +1,97 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.1" language="sw_TZ"> +<context> + <name>MainUI</name> + <message> + <location filename="../MainUI.ui" line="14"/> + <source>MainWindow</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="29"/> + <source>Archive:</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="88"/> + <source>File</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="97"/> + <source>Edit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="111"/> + <source>toolBar</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="135"/> + <source>&Open Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="138"/> + <source>Open archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="143"/> + <source>&New Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="146"/> + <source>New archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="151"/> + <source>&Quit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="156"/> + <source>Add File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="159"/> + <source>Add files to archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="164"/> + <source>Remove File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="167"/> + <source>Remove selection from archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="172"/> + <source>Extract All</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="175"/> + <source>Extract archive into a directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="180"/> + <source>Add Directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="183"/> + <source>Add directory to archive</source> + <translation type="unfinished"></translation> + </message> +</context> +</TS> diff --git a/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_ta.ts b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_ta.ts new file mode 100644 index 00000000..dbb5f1f1 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_ta.ts @@ -0,0 +1,97 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.1" language="ta_IN"> +<context> + <name>MainUI</name> + <message> + <location filename="../MainUI.ui" line="14"/> + <source>MainWindow</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="29"/> + <source>Archive:</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="88"/> + <source>File</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="97"/> + <source>Edit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="111"/> + <source>toolBar</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="135"/> + <source>&Open Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="138"/> + <source>Open archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="143"/> + <source>&New Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="146"/> + <source>New archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="151"/> + <source>&Quit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="156"/> + <source>Add File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="159"/> + <source>Add files to archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="164"/> + <source>Remove File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="167"/> + <source>Remove selection from archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="172"/> + <source>Extract All</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="175"/> + <source>Extract archive into a directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="180"/> + <source>Add Directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="183"/> + <source>Add directory to archive</source> + <translation type="unfinished"></translation> + </message> +</context> +</TS> diff --git a/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_tg.ts b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_tg.ts new file mode 100644 index 00000000..47e310d0 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_tg.ts @@ -0,0 +1,97 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.1" language="tg_TJ"> +<context> + <name>MainUI</name> + <message> + <location filename="../MainUI.ui" line="14"/> + <source>MainWindow</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="29"/> + <source>Archive:</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="88"/> + <source>File</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="97"/> + <source>Edit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="111"/> + <source>toolBar</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="135"/> + <source>&Open Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="138"/> + <source>Open archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="143"/> + <source>&New Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="146"/> + <source>New archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="151"/> + <source>&Quit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="156"/> + <source>Add File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="159"/> + <source>Add files to archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="164"/> + <source>Remove File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="167"/> + <source>Remove selection from archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="172"/> + <source>Extract All</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="175"/> + <source>Extract archive into a directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="180"/> + <source>Add Directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="183"/> + <source>Add directory to archive</source> + <translation type="unfinished"></translation> + </message> +</context> +</TS> diff --git a/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_th.ts b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_th.ts new file mode 100644 index 00000000..f0f80088 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_th.ts @@ -0,0 +1,97 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.1" language="th_TH"> +<context> + <name>MainUI</name> + <message> + <location filename="../MainUI.ui" line="14"/> + <source>MainWindow</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="29"/> + <source>Archive:</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="88"/> + <source>File</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="97"/> + <source>Edit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="111"/> + <source>toolBar</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="135"/> + <source>&Open Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="138"/> + <source>Open archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="143"/> + <source>&New Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="146"/> + <source>New archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="151"/> + <source>&Quit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="156"/> + <source>Add File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="159"/> + <source>Add files to archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="164"/> + <source>Remove File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="167"/> + <source>Remove selection from archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="172"/> + <source>Extract All</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="175"/> + <source>Extract archive into a directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="180"/> + <source>Add Directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="183"/> + <source>Add directory to archive</source> + <translation type="unfinished"></translation> + </message> +</context> +</TS> diff --git a/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_tr.ts b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_tr.ts new file mode 100644 index 00000000..d06385e8 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_tr.ts @@ -0,0 +1,97 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.1" language="tr_TR"> +<context> + <name>MainUI</name> + <message> + <location filename="../MainUI.ui" line="14"/> + <source>MainWindow</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="29"/> + <source>Archive:</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="88"/> + <source>File</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="97"/> + <source>Edit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="111"/> + <source>toolBar</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="135"/> + <source>&Open Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="138"/> + <source>Open archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="143"/> + <source>&New Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="146"/> + <source>New archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="151"/> + <source>&Quit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="156"/> + <source>Add File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="159"/> + <source>Add files to archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="164"/> + <source>Remove File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="167"/> + <source>Remove selection from archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="172"/> + <source>Extract All</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="175"/> + <source>Extract archive into a directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="180"/> + <source>Add Directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="183"/> + <source>Add directory to archive</source> + <translation type="unfinished"></translation> + </message> +</context> +</TS> diff --git a/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_uk.ts b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_uk.ts new file mode 100644 index 00000000..5feffd69 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_uk.ts @@ -0,0 +1,97 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.1" language="uk_UA"> +<context> + <name>MainUI</name> + <message> + <location filename="../MainUI.ui" line="14"/> + <source>MainWindow</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="29"/> + <source>Archive:</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="88"/> + <source>File</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="97"/> + <source>Edit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="111"/> + <source>toolBar</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="135"/> + <source>&Open Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="138"/> + <source>Open archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="143"/> + <source>&New Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="146"/> + <source>New archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="151"/> + <source>&Quit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="156"/> + <source>Add File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="159"/> + <source>Add files to archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="164"/> + <source>Remove File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="167"/> + <source>Remove selection from archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="172"/> + <source>Extract All</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="175"/> + <source>Extract archive into a directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="180"/> + <source>Add Directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="183"/> + <source>Add directory to archive</source> + <translation type="unfinished"></translation> + </message> +</context> +</TS> diff --git a/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_uz.ts b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_uz.ts new file mode 100644 index 00000000..9f46964e --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_uz.ts @@ -0,0 +1,97 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.1" language="uz_UZ"> +<context> + <name>MainUI</name> + <message> + <location filename="../MainUI.ui" line="14"/> + <source>MainWindow</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="29"/> + <source>Archive:</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="88"/> + <source>File</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="97"/> + <source>Edit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="111"/> + <source>toolBar</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="135"/> + <source>&Open Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="138"/> + <source>Open archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="143"/> + <source>&New Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="146"/> + <source>New archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="151"/> + <source>&Quit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="156"/> + <source>Add File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="159"/> + <source>Add files to archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="164"/> + <source>Remove File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="167"/> + <source>Remove selection from archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="172"/> + <source>Extract All</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="175"/> + <source>Extract archive into a directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="180"/> + <source>Add Directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="183"/> + <source>Add directory to archive</source> + <translation type="unfinished"></translation> + </message> +</context> +</TS> diff --git a/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_vi.ts b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_vi.ts new file mode 100644 index 00000000..77dae6d0 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_vi.ts @@ -0,0 +1,97 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.1" language="vi_VN"> +<context> + <name>MainUI</name> + <message> + <location filename="../MainUI.ui" line="14"/> + <source>MainWindow</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="29"/> + <source>Archive:</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="88"/> + <source>File</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="97"/> + <source>Edit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="111"/> + <source>toolBar</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="135"/> + <source>&Open Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="138"/> + <source>Open archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="143"/> + <source>&New Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="146"/> + <source>New archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="151"/> + <source>&Quit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="156"/> + <source>Add File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="159"/> + <source>Add files to archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="164"/> + <source>Remove File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="167"/> + <source>Remove selection from archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="172"/> + <source>Extract All</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="175"/> + <source>Extract archive into a directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="180"/> + <source>Add Directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="183"/> + <source>Add directory to archive</source> + <translation type="unfinished"></translation> + </message> +</context> +</TS> diff --git a/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_zh_CN.ts b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_zh_CN.ts new file mode 100644 index 00000000..ead12601 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_zh_CN.ts @@ -0,0 +1,97 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.1" language="zh_CN"> +<context> + <name>MainUI</name> + <message> + <location filename="../MainUI.ui" line="14"/> + <source>MainWindow</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="29"/> + <source>Archive:</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="88"/> + <source>File</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="97"/> + <source>Edit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="111"/> + <source>toolBar</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="135"/> + <source>&Open Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="138"/> + <source>Open archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="143"/> + <source>&New Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="146"/> + <source>New archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="151"/> + <source>&Quit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="156"/> + <source>Add File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="159"/> + <source>Add files to archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="164"/> + <source>Remove File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="167"/> + <source>Remove selection from archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="172"/> + <source>Extract All</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="175"/> + <source>Extract archive into a directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="180"/> + <source>Add Directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="183"/> + <source>Add directory to archive</source> + <translation type="unfinished"></translation> + </message> +</context> +</TS> diff --git a/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_zh_HK.ts b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_zh_HK.ts new file mode 100644 index 00000000..305f35df --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_zh_HK.ts @@ -0,0 +1,97 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.1" language="zh_HK"> +<context> + <name>MainUI</name> + <message> + <location filename="../MainUI.ui" line="14"/> + <source>MainWindow</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="29"/> + <source>Archive:</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="88"/> + <source>File</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="97"/> + <source>Edit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="111"/> + <source>toolBar</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="135"/> + <source>&Open Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="138"/> + <source>Open archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="143"/> + <source>&New Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="146"/> + <source>New archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="151"/> + <source>&Quit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="156"/> + <source>Add File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="159"/> + <source>Add files to archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="164"/> + <source>Remove File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="167"/> + <source>Remove selection from archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="172"/> + <source>Extract All</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="175"/> + <source>Extract archive into a directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="180"/> + <source>Add Directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="183"/> + <source>Add directory to archive</source> + <translation type="unfinished"></translation> + </message> +</context> +</TS> diff --git a/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_zh_TW.ts b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_zh_TW.ts new file mode 100644 index 00000000..2a37d401 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_zh_TW.ts @@ -0,0 +1,97 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.1" language="zh_TW"> +<context> + <name>MainUI</name> + <message> + <location filename="../MainUI.ui" line="14"/> + <source>MainWindow</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="29"/> + <source>Archive:</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="88"/> + <source>File</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="97"/> + <source>Edit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="111"/> + <source>toolBar</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="135"/> + <source>&Open Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="138"/> + <source>Open archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="143"/> + <source>&New Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="146"/> + <source>New archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="151"/> + <source>&Quit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="156"/> + <source>Add File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="159"/> + <source>Add files to archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="164"/> + <source>Remove File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="167"/> + <source>Remove selection from archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="172"/> + <source>Extract All</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="175"/> + <source>Extract archive into a directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="180"/> + <source>Add Directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="183"/> + <source>Add directory to archive</source> + <translation type="unfinished"></translation> + </message> +</context> +</TS> diff --git a/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_zu.ts b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_zu.ts new file mode 100644 index 00000000..a503faf8 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/i18n/l-archiver_zu.ts @@ -0,0 +1,97 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.1" language="zu_ZA"> +<context> + <name>MainUI</name> + <message> + <location filename="../MainUI.ui" line="14"/> + <source>MainWindow</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="29"/> + <source>Archive:</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="88"/> + <source>File</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="97"/> + <source>Edit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="111"/> + <source>toolBar</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="135"/> + <source>&Open Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="138"/> + <source>Open archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="143"/> + <source>&New Archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="146"/> + <source>New archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="151"/> + <source>&Quit</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="156"/> + <source>Add File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="159"/> + <source>Add files to archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="164"/> + <source>Remove File(s)</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="167"/> + <source>Remove selection from archive</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="172"/> + <source>Extract All</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="175"/> + <source>Extract archive into a directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="180"/> + <source>Add Directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../MainUI.ui" line="183"/> + <source>Add directory to archive</source> + <translation type="unfinished"></translation> + </message> +</context> +</TS> diff --git a/src-qt5/desktop-utils/lumina-archiver/lumina-archiver.desktop b/src-qt5/desktop-utils/lumina-archiver/lumina-archiver.desktop new file mode 100644 index 00000000..f0b6772d --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/lumina-archiver.desktop @@ -0,0 +1,10 @@ +[Desktop Entry] +Exec=lumina-archiver %f +Icon=utilities-file-archiver +Terminal=false +Type=Application +StartupNotify=true +Categories=Utility; +MimeType=application/x-xz-compressed-tar; application/x-lzma-compressed-tar; application/x-bzip-compressed-tar; application/x-tar; application/x-compressed-tar; application/zip; +Name=Lumina Archiver +Comment=Archive creator and viewer diff --git a/src-qt5/desktop-utils/lumina-archiver/lumina-archiver.pro b/src-qt5/desktop-utils/lumina-archiver/lumina-archiver.pro new file mode 100644 index 00000000..5c35af2c --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/lumina-archiver.pro @@ -0,0 +1,98 @@ +include("$${PWD}/../../OS-detect.pri") + +QT += core gui widgets + +TARGET = lumina-archiver +target.path = $${L_BINDIR} + +#include all the special classes from the Lumina tree +include(../../core/libLumina/LUtils.pri) #includes LUtils +include(../../core/libLumina/LuminaXDG.pri) +include(../../core/libLumina/LuminaThemes.pri) + +HEADERS += MainUI.h \ + TarBackend.h + +SOURCES += main.cpp \ + MainUI.cpp \ + TarBackend.cpp + +FORMS += MainUI.ui + +TRANSLATIONS = i18n/l-archiver_af.ts \ + i18n/l-archiver_ar.ts \ + i18n/l-archiver_az.ts \ + i18n/l-archiver_bg.ts \ + i18n/l-archiver_bn.ts \ + i18n/l-archiver_bs.ts \ + i18n/l-archiver_ca.ts \ + i18n/l-archiver_cs.ts \ + i18n/l-archiver_cy.ts \ + i18n/l-archiver_da.ts \ + i18n/l-archiver_de.ts \ + i18n/l-archiver_el.ts \ + i18n/l-archiver_en_GB.ts \ + i18n/l-archiver_en_ZA.ts \ + i18n/l-archiver_es.ts \ + i18n/l-archiver_et.ts \ + i18n/l-archiver_eu.ts \ + i18n/l-archiver_fa.ts \ + i18n/l-archiver_fi.ts \ + i18n/l-archiver_fr.ts \ + i18n/l-archiver_fr_CA.ts \ + i18n/l-archiver_gl.ts \ + i18n/l-archiver_he.ts \ + i18n/l-archiver_hi.ts \ + i18n/l-archiver_hr.ts \ + i18n/l-archiver_hu.ts \ + i18n/l-archiver_id.ts \ + i18n/l-archiver_is.ts \ + i18n/l-archiver_it.ts \ + i18n/l-archiver_ja.ts \ + i18n/l-archiver_ka.ts \ + i18n/l-archiver_ko.ts \ + i18n/l-archiver_lt.ts \ + i18n/l-archiver_lv.ts \ + i18n/l-archiver_mk.ts \ + i18n/l-archiver_mn.ts \ + i18n/l-archiver_ms.ts \ + i18n/l-archiver_mt.ts \ + i18n/l-archiver_nb.ts \ + i18n/l-archiver_nl.ts \ + i18n/l-archiver_pa.ts \ + i18n/l-archiver_pl.ts \ + i18n/l-archiver_pt.ts \ + i18n/l-archiver_pt_BR.ts \ + i18n/l-archiver_ro.ts \ + i18n/l-archiver_ru.ts \ + i18n/l-archiver_sk.ts \ + i18n/l-archiver_sl.ts \ + i18n/l-archiver_sr.ts \ + i18n/l-archiver_sv.ts \ + i18n/l-archiver_sw.ts \ + i18n/l-archiver_ta.ts \ + i18n/l-archiver_tg.ts \ + i18n/l-archiver_th.ts \ + i18n/l-archiver_tr.ts \ + i18n/l-archiver_uk.ts \ + i18n/l-archiver_uz.ts \ + i18n/l-archiver_vi.ts \ + i18n/l-archiver_zh_CN.ts \ + i18n/l-archiver_zh_HK.ts \ + i18n/l-archiver_zh_TW.ts \ + i18n/l-archiver_zu.ts + +dotrans.path=$${L_SHAREDIR}/lumina-desktop/i18n/ +dotrans.extra=cd i18n && $${LRELEASE} -nounfinished *.ts && cp *.qm $(INSTALL_ROOT)$${L_SHAREDIR}/lumina-desktop/i18n/ + +desktop.files=lumina-archiver.desktop +desktop.path=$${L_SHAREDIR}/applications/ + +#link.path=$${L_BINDIR} +#link.extra=ln -sf lumina-archiver $(INSTALL_ROOT)$${L_BINDIR}/lpac + +INSTALLS += target desktop + +WITH_I18N{ + INSTALLS += dotrans +} diff --git a/src-qt5/desktop-utils/lumina-archiver/main.cpp b/src-qt5/desktop-utils/lumina-archiver/main.cpp new file mode 100644 index 00000000..ccd85902 --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/main.cpp @@ -0,0 +1,29 @@ +//=========================================== +// Lumina-DE source code +// Copyright (c) 2016, Ken Moore +// Available under the 3-clause BSD license +// See the LICENSE file for full details +//=========================================== +#include <QApplication> +#include <QDebug> + +#include <LuminaThemes.h> +#include <LUtils.h> + +#include "MainUI.h" + +int main(int argc, char *argv[]) { + LTHEME::LoadCustomEnvSettings(); + QApplication a(argc, argv); + LUtils::LoadTranslation(&a, "l-archiver"); + //Now go ahead and setup the app + QStringList args; + for(int i=1; i<argc; i++){ + args << LUtils::PathToAbsolute( QString(argv[i]) ); + } + //Now start the window + MainUI W; + W.LoadArguments(args); + W.show(); + return a.exec(); +} -- cgit From 966dbb1eb90d820a3385f25ecf474f386e859e6d Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Sat, 12 Nov 2016 15:24:14 -0500 Subject: Add support for extracting a single file from an archive for viewing temporarily. --- src-qt5/desktop-utils/lumina-archiver/MainUI.cpp | 25 ++++++++++++++++------ src-qt5/desktop-utils/lumina-archiver/MainUI.h | 4 ++-- .../desktop-utils/lumina-archiver/TarBackend.cpp | 23 +++++++++++++++++--- src-qt5/desktop-utils/lumina-archiver/TarBackend.h | 2 ++ 4 files changed, 43 insertions(+), 11 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/desktop-utils/lumina-archiver/MainUI.cpp b/src-qt5/desktop-utils/lumina-archiver/MainUI.cpp index 612c7beb..9710045c 100644 --- a/src-qt5/desktop-utils/lumina-archiver/MainUI.cpp +++ b/src-qt5/desktop-utils/lumina-archiver/MainUI.cpp @@ -34,6 +34,7 @@ MainUI::MainUI() : QMainWindow(), ui(new Ui::MainUI){ connect(ui->actionRemove_File, SIGNAL(triggered()), this, SLOT(remFiles()) ); connect(ui->actionExtract_All, SIGNAL(triggered()), this, SLOT(extractFiles()) ); connect(ui->actionAdd_Dirs, SIGNAL(triggered()), this, SLOT(addDirs()) ); + connect(ui->tree_contents, SIGNAL(itemDoubleClicked(QTreeWidgetItem*, int)), this, SLOT(ViewFile(QTreeWidgetItem*)) ); ui->progressBar->setVisible(false); ui->label_progress->setVisible(false); ui->actionAdd_File->setEnabled(false); @@ -85,22 +86,26 @@ QTreeWidgetItem* MainUI::findItem(QString path, QTreeWidgetItem *start){ return 0; //nothing found } -void MainUI::cleanItems(QStringList list, QTreeWidgetItem *start){ +bool MainUI::cleanItems(QStringList list, QTreeWidgetItem *start){ + bool changed = false; if(start==0){ for(int i=0; i<ui->tree_contents->topLevelItemCount(); i++){ - cleanItems(list, ui->tree_contents->topLevelItem(i)); + changed = changed || cleanItems(list, ui->tree_contents->topLevelItem(i)); if(!list.contains(ui->tree_contents->topLevelItem(i)->whatsThis(0)) ){ delete ui->tree_contents->topLevelItem(i); + changed = true; } } }else{ for(int i=0; i<start->childCount(); i++){ - cleanItems(list, start->child(i)); + changed = changed || cleanItems(list, start->child(i)); if(!list.contains(start->child(i)->whatsThis(0)) ){ delete start->child(i); + changed = true; } } } + return changed; } //Functions for setting the valid file extensions ("tar" limitations) @@ -190,12 +195,17 @@ void MainUI::extractFiles(){ BACKEND->startExtract(dir, true); } +void MainUI::ViewFile(QTreeWidgetItem *it){ + if(it->childCount()>0){ return; } //directory - not viewable + BACKEND->startViewFile(it->whatsThis(0)); +} + void MainUI::UpdateTree(){ ui->tree_contents->setHeaderLabels( QStringList() << tr("File") << tr("MimeType") << tr("Size") << tr("Compressed")+" " ); QStringList files = BACKEND->heirarchy(); files.sort(); //Remove any entries for file no longer in the archive - cleanItems(files); + bool changed = cleanItems(files); qDebug() << "Found Files:" << files; for(int i=0; i<files.length(); i++){ if(0 != findItem(files[i]) ){ continue; } //already in the tree widget @@ -217,10 +227,13 @@ void MainUI::UpdateTree(){ }else{ ui->tree_contents->addTopLevelItem(it); } + changed = true; } int wid = 0; - for(int i=3; i>0; i--){ui->tree_contents->resizeColumnToContents(i); wid+= ui->tree_contents->columnWidth(i); } - ui->tree_contents->setColumnWidth(0, ui->tree_contents->viewport()->width()-wid); + if(changed){ + for(int i=3; i>0; i--){ui->tree_contents->resizeColumnToContents(i); wid+= ui->tree_contents->columnWidth(i); } + ui->tree_contents->setColumnWidth(0, ui->tree_contents->viewport()->width()-wid); + } } //Backend Handling diff --git a/src-qt5/desktop-utils/lumina-archiver/MainUI.h b/src-qt5/desktop-utils/lumina-archiver/MainUI.h index 802d241b..09207aa3 100644 --- a/src-qt5/desktop-utils/lumina-archiver/MainUI.h +++ b/src-qt5/desktop-utils/lumina-archiver/MainUI.h @@ -31,7 +31,7 @@ private: Backend *BACKEND; QTreeWidgetItem* findItem(QString path, QTreeWidgetItem *start = 0); - void cleanItems(QStringList list, QTreeWidgetItem *start = 0); + bool cleanItems(QStringList list, QTreeWidgetItem *start = 0); //returns true if anything gets cleaned //Functions for setting the valid file extensions ("tar" limitations) QString CreateFileTypes(); @@ -44,7 +44,7 @@ private slots: void addDirs(); void remFiles(); void extractFiles(); - + void ViewFile(QTreeWidgetItem *it); void UpdateTree(); diff --git a/src-qt5/desktop-utils/lumina-archiver/TarBackend.cpp b/src-qt5/desktop-utils/lumina-archiver/TarBackend.cpp index f6738855..4dee247b 100644 --- a/src-qt5/desktop-utils/lumina-archiver/TarBackend.cpp +++ b/src-qt5/desktop-utils/lumina-archiver/TarBackend.cpp @@ -6,12 +6,13 @@ //=========================================== #include "TarBackend.h" #include <QFile> +#include <QDir> #include <QDebug> Backend::Backend(QObject *parent) : QObject(parent){ //Setup the backend process PROC.setProcessChannelMode(QProcess::MergedChannels); - PROC.setProgram("7z"); + PROC.setProgram("tar"); connect(&PROC, SIGNAL(finished(int, QProcess::ExitStatus)), this, SLOT(procFinished(int, QProcess::ExitStatus)) ); connect(&PROC, SIGNAL(readyReadStandardOutput()), this, SLOT(processData()) ); connect(&PROC, SIGNAL(started()), this, SIGNAL(ProcessStarting()) ); @@ -36,7 +37,7 @@ void Backend::loadFile(QString path){ bool Backend::canModify(){ static QStringList validEXT; - if(validEXT.isEmpty()){ + if( validEXT.isEmpty() ){ validEXT << ".zip" << ".tar.gz" << ".tgz" << ".tar.xz" << ".txz" << ".tar.bz" << ".tbz" << ".tar.bz2" << ".tbz2" << ".tar" \ << ".tar.lzma" << ".tlz" << ".cpio" << ".pax" << ".ar" << ".shar" << ".7z"; } @@ -120,6 +121,15 @@ void Backend::startExtract(QString path, bool overwrite){ if(!overwrite){ args << "-k"; } args << flags << "-C" << path; STARTING=true; + //qDebug() << "Starting command:" << "tar" << args; + PROC.start("tar", args); +} + +void Backend::startViewFile(QString path){ + QStringList args; + args << "-x"; + args << flags <<"--include" << path <<"--strip-components" << QString::number(path.count("/")) << "-C" << QDir::tempPath(); + STARTING=true; qDebug() << "Starting command:" << "tar" << args; PROC.start("tar", args); } @@ -175,7 +185,14 @@ void Backend::procFinished(int retcode, QProcess::ExitStatus){ QStringList args = PROC.arguments(); if(args.contains("-x") && retcode==0){ needupdate=false; - QProcess::startDetached("xdg-open \""+ args.last()+"\""); //just extracted to a dir - open it now + if(args.contains("--include")){ + //Need to find the full path to the extracted file + QString path = args.last() +"/"+ args[ args.indexOf("--include")+1].section("/",-1); + QFile::setPermissions(path, QFileDevice::ReadOwner); + QProcess::startDetached("xdg-open \""+path+"\""); + }else{ + QProcess::startDetached("xdg-open \""+ args.last()+"\""); //just extracted to a dir - open it now + } }else if(args.contains("-c") && QFile::exists(tmpfilepath)){ if(retcode==0){ QFile::remove(filepath); diff --git a/src-qt5/desktop-utils/lumina-archiver/TarBackend.h b/src-qt5/desktop-utils/lumina-archiver/TarBackend.h index 11c61319..f12aae63 100644 --- a/src-qt5/desktop-utils/lumina-archiver/TarBackend.h +++ b/src-qt5/desktop-utils/lumina-archiver/TarBackend.h @@ -35,6 +35,8 @@ public: void startRemove(QStringList paths); void startExtract(QString path, bool overwrite); //path to dir + void startViewFile(QString path); + public slots: private: -- cgit From e3a9c6c5fdb7710c56f526e7d3bbf0e55cd24fd1 Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Tue, 15 Nov 2016 09:05:41 -0500 Subject: Update the default luminaDesktop.conf files to try and associate the archive mimetypes with lumina-archiver by default. --- .../core/lumina-desktop/defaults/luminaDesktop-TrueOS.conf | 7 +++++++ src-qt5/core/lumina-desktop/defaults/luminaDesktop.conf | 14 +++++++------- 2 files changed, 14 insertions(+), 7 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/core/lumina-desktop/defaults/luminaDesktop-TrueOS.conf b/src-qt5/core/lumina-desktop/defaults/luminaDesktop-TrueOS.conf index 9b819e7c..56ff8b84 100644 --- a/src-qt5/core/lumina-desktop/defaults/luminaDesktop-TrueOS.conf +++ b/src-qt5/core/lumina-desktop/defaults/luminaDesktop-TrueOS.conf @@ -42,6 +42,13 @@ mime_default_unknown/*=lumina-textedit.desktop mime_default_application/x-shellscript=lumina-textedit.desktop mime_default_application/pdf_ifexists=pc-pdfviewer.desktop mime_default_application/pdf_ifexists=okular.desktop +mime_default_application/zip_ifexists=lumina-archiver.desktop +mime_default_application/x-compressed-tar_ifexists=lumina-archiver.desktop +mime_default_application/x-bzip-compressed-tar_ifexists=lumina-archiver.desktop +mime_default_application/x-lrzip-compressed-tar_ifexists=lumina-archiver.desktop +mime_default_application/x-lzma-compressed-tar_ifexists=lumina-archiver.desktop +mime_default_application/x-xz-compressed-tar_ifexists=lumina-archiver.desktop +mime_default_application/x-tar_ifexists=lumina-archiver.desktop #THEME SETTINGS theme_themefile=Glass #Name of the theme to use (disable for Lumina-Default) diff --git a/src-qt5/core/lumina-desktop/defaults/luminaDesktop.conf b/src-qt5/core/lumina-desktop/defaults/luminaDesktop.conf index 4950b1a0..46d00053 100644 --- a/src-qt5/core/lumina-desktop/defaults/luminaDesktop.conf +++ b/src-qt5/core/lumina-desktop/defaults/luminaDesktop.conf @@ -36,13 +36,13 @@ session_default_email_ifexists=trojita.desktop mime_default_text/*_ifexists=lumina-textedit.desktop mime_default_audio/*_ifexists=vlc.desktop mime_default_video/*_ifexists=vlc.desktop -mime_default_application/zip_ifexists=peazip.desktop -mime_default_application/x-compressed-tar_ifexists=peazip.desktop -mime_default_application/x-bzip-compressed-tar_ifexists=peazip.desktop -mime_default_application/x-lrzip-compressed-tar_ifexists=peazip.desktop -mime_default_application/x-lzma-compressed-tar_ifexists=peazip.desktop -mime_default_application/x-xz-compressed-tar_ifexists=peazip.desktop -mime_default_application/x-tar_ifexists=peazip.desktop +mime_default_application/zip_ifexists=lumina-archiver.desktop +mime_default_application/x-compressed-tar_ifexists=lumina-archiver.desktop +mime_default_application/x-bzip-compressed-tar_ifexists=lumina-archiver.desktop +mime_default_application/x-lrzip-compressed-tar_ifexists=lumina-archiver.desktop +mime_default_application/x-lzma-compressed-tar_ifexists=lumina-archiver.desktop +mime_default_application/x-xz-compressed-tar_ifexists=lumina-archiver.desktop +mime_default_application/x-tar_ifexists=lumina-archiver.desktop mime_default_unknown/*=lumina-textedit.desktop mime_default_application/x-shellscript=lumina-textedit.desktop -- cgit From d9ba230fbdae3ac7fa31bbaaf625d4fe258d04ab Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Tue, 15 Nov 2016 09:19:23 -0500 Subject: Add knowledge of the new jsonmenu panel plugin to lumina-config. --- src-qt5/core-utils/lumina-config/LPlugins.cpp | 9 +++++- src-qt5/core-utils/lumina-config/PanelWidget.cpp | 36 ++++++++++++++++++++---- 2 files changed, 38 insertions(+), 7 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/core-utils/lumina-config/LPlugins.cpp b/src-qt5/core-utils/lumina-config/LPlugins.cpp index 089a181c..dfd490e6 100644 --- a/src-qt5/core-utils/lumina-config/LPlugins.cpp +++ b/src-qt5/core-utils/lumina-config/LPlugins.cpp @@ -173,6 +173,13 @@ void LPlugins::LoadPanelPlugins(){ info.ID = "audioplayer"; info.icon = "media-playback-start"; PANEL.insert(info.ID, info); + //JSON Menu Scripts + info = LPI(); //clear it + info.name = QObject::tr("Menu Script"); + info.description = QObject::tr("Run an external script to generate a user defined menu"); + info.ID = "jsonmenu"; + info.icon = "text-x-script"; + PANEL.insert(info.ID, info); } // DESKTOP PLUGINS @@ -293,7 +300,7 @@ void LPlugins::LoadMenuPlugins(){ info.ID = "app"; info.icon = "application-x-desktop"; MENU.insert(info.ID, info); - //Custom Apps + //JSON Menu Scripts info = LPI(); //clear it info.name = QObject::tr("Menu Script"); info.description = QObject::tr("Run an external script to generate a user defined menu"); diff --git a/src-qt5/core-utils/lumina-config/PanelWidget.cpp b/src-qt5/core-utils/lumina-config/PanelWidget.cpp index aff7bda3..d5d3d9bd 100644 --- a/src-qt5/core-utils/lumina-config/PanelWidget.cpp +++ b/src-qt5/core-utils/lumina-config/PanelWidget.cpp @@ -9,7 +9,7 @@ #include "GetPluginDialog.h" #include "AppDialog.h" - +#include "ScriptDialog.h" PanelWidget::PanelWidget(QWidget *parent, QWidget *Main, LPlugins *Pinfo) : QWidget(parent), ui(new Ui::PanelWidget){ ui->setupUi(this); @@ -66,6 +66,18 @@ void PanelWidget::LoadSettings(QSettings *settings, int Dnum, int Pnum){ it->setWhatsThis(plugs[i]); //make sure to preserve the entire plugin ID (is the unique version) ui->list_plugins->addItem(it); } + + }else if(pid.startsWith("jsonmenu")){ + LPI info = PINFO->panelPluginInfo( plugs[i].section("::::",0,0) ); + if(info.ID.isEmpty()){ continue; } //invalid plugin type (no longer available?) + QString exec = plugs[i].section("::::",1,1); + QListWidgetItem *item = new QListWidgetItem(); + item->setWhatsThis( plugs[i] ); + item->setIcon( LXDG::findIcon(plugs[i].section("::::",3,3),info.icon) ); + item->setText( plugs[i].section("::::",2,2) +" ("+info.name+")" ); + item->setToolTip( info.description ); + ui->list_plugins->addItem(item); + }else{ LPI info = PINFO->panelPluginInfo(pid); if(!info.ID.isEmpty()){ @@ -180,23 +192,35 @@ void PanelWidget::on_tool_addplugin_clicked(){ dlg.exec(); if(!dlg.selected){ return; } //cancelled QString pan = dlg.plugID; //getNewPanelPlugin(); + QListWidgetItem *it = 0; if(pan == "applauncher"){ //Prompt for the application to add QString app =getSysApp(); if(app.isEmpty()){ return; } //cancelled pan.append("::"+app); XDGDesktop desk(app); - QListWidgetItem *it = new QListWidgetItem( LXDG::findIcon(desk.icon,""), desk.name); + it = new QListWidgetItem( LXDG::findIcon(desk.icon,""), desk.name); it->setWhatsThis(pan); - ui->list_plugins->addItem(it); - ui->list_plugins->setCurrentItem(it); - ui->list_plugins->scrollToItem(it); + + }else if(pan=="jsonmenu"){ + //Need to prompt for the script file, name, and icon to use + //new ID format: "jsonmenu"::::<exec to run>::::<name>::::<icon> + ScriptDialog SD(this); + SD.exec(); + if(!SD.isValid()){ return; } + LPI info = PINFO->panelPluginInfo(pan); + it = new QListWidgetItem( LXDG::findIcon(SD.icon(),"text-x-script"), SD.name()+" ("+info.ID+")" ); + it->setWhatsThis(info.ID+"::::"+SD.command()+"::::"+SD.name()+"::::"+SD.icon()); + it->setToolTip( info.description ); }else{ if(pan.isEmpty()){ return; } //nothing selected //Add the new plugin to the list LPI info = PINFO->panelPluginInfo(pan); - QListWidgetItem *it = new QListWidgetItem( LXDG::findIcon(info.icon,""), info.name); + it = new QListWidgetItem( LXDG::findIcon(info.icon,""), info.name); it->setWhatsThis(info.ID); + } + //Now add the new item to the list + if(it!=0){ ui->list_plugins->addItem(it); ui->list_plugins->setCurrentItem(it); ui->list_plugins->scrollToItem(it); -- cgit From 0afad0dbbae4440ec311e9682f62686889afbcce Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Tue, 15 Nov 2016 10:10:16 -0500 Subject: Add the new option for detection GPU accel to the compositor page. --- src-qt5/core-utils/lumina-config/pages/page_compton.cpp | 3 +++ src-qt5/core-utils/lumina-config/pages/page_compton.ui | 7 +++++++ 2 files changed, 10 insertions(+) (limited to 'src-qt5') diff --git a/src-qt5/core-utils/lumina-config/pages/page_compton.cpp b/src-qt5/core-utils/lumina-config/pages/page_compton.cpp index 0003c9c8..e3bfe1fd 100644 --- a/src-qt5/core-utils/lumina-config/pages/page_compton.cpp +++ b/src-qt5/core-utils/lumina-config/pages/page_compton.cpp @@ -15,6 +15,7 @@ page_compton::page_compton(QWidget *parent) : PageWidget(parent), ui(new Ui::pag ui->setupUi(this); connect(ui->text_file, SIGNAL(textChanged()), this, SLOT(settingChanged()) ); connect(ui->check_disablecompton, SIGNAL(toggled(bool)), this, SLOT(settingChanged()) ); + connect(ui->check_GPUverify, SIGNAL(toggled(bool)), this, SLOT(settingChanged()) ); updateIcons(); } @@ -29,6 +30,7 @@ void page_compton::SaveSettings(){ emit HasPendingChanges(false); QSettings settings("lumina-desktop","sessionsettings"); settings.setValue("enableCompositing", !ui->check_disablecompton->isChecked()); + settings.setValue("compositingWithGpuAccelOnly", ui->check_GPUverify->isChecked()); QString set = QString(getenv("XDG_CONFIG_HOME"))+"/lumina-desktop/compton.conf"; LUtils::writeFile(set, ui->text_file->toPlainText().split("\n"),true); } @@ -38,6 +40,7 @@ void page_compton::LoadSettings(int){ emit ChangePageTitle( tr("Compositor Settings") ); QSettings settings("lumina-desktop","sessionsettings"); ui->check_disablecompton->setChecked( !settings.value("enableCompositing", true).toBool() ); + ui->check_GPUverify->setChecked( settings.value("compositingWithGpuAccelOnly", true).toBool() ); QString set = QString(getenv("XDG_CONFIG_HOME"))+"/lumina-desktop/compton.conf"; qDebug() << "Load Compton settings:" << set; ui->text_file->setPlainText( LUtils::readFile(set).join("\n") ); diff --git a/src-qt5/core-utils/lumina-config/pages/page_compton.ui b/src-qt5/core-utils/lumina-config/pages/page_compton.ui index 9083a2fb..857331d6 100644 --- a/src-qt5/core-utils/lumina-config/pages/page_compton.ui +++ b/src-qt5/core-utils/lumina-config/pages/page_compton.ui @@ -33,6 +33,13 @@ </property> </widget> </item> + <item> + <widget class="QCheckBox" name="check_GPUverify"> + <property name="text"> + <string>Only use compositing with GPU acceleration </string> + </property> + </widget> + </item> <item> <widget class="QPlainTextEdit" name="text_file"/> </item> -- cgit From 9c7a9458572362b968f862e8c29d74aa7cb8a702 Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Tue, 15 Nov 2016 10:34:30 -0500 Subject: Add a general session option for whether to show the application crash notifications. --- .../lumina-config/pages/page_defaultapps.ui | 256 ++++++++++----------- .../lumina-config/pages/page_session_options.cpp | 12 + .../lumina-config/pages/page_session_options.ui | 7 + 3 files changed, 147 insertions(+), 128 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/core-utils/lumina-config/pages/page_defaultapps.ui b/src-qt5/core-utils/lumina-config/pages/page_defaultapps.ui index ef72c4f1..8440e198 100644 --- a/src-qt5/core-utils/lumina-config/pages/page_defaultapps.ui +++ b/src-qt5/core-utils/lumina-config/pages/page_defaultapps.ui @@ -29,11 +29,138 @@ <item> <widget class="QTabWidget" name="tabWidget_apps"> <property name="currentIndex"> - <number>1</number> + <number>0</number> </property> <property name="movable"> <bool>false</bool> </property> + <widget class="QWidget" name="tab_auto"> + <attribute name="title"> + <string>Basic Settings</string> + </attribute> + <layout class="QVBoxLayout" name="verticalLayout_7"> + <item> + <layout class="QGridLayout" name="gridLayout_6"> + <item row="0" column="0"> + <layout class="QFormLayout" name="formLayout_10"> + <property name="fieldGrowthPolicy"> + <enum>QFormLayout::ExpandingFieldsGrow</enum> + </property> + <item row="0" column="0"> + <widget class="QLabel" name="label_37"> + <property name="font"> + <font> + <weight>75</weight> + <bold>true</bold> + </font> + </property> + <property name="text"> + <string>Web Browser:</string> + </property> + </widget> + </item> + <item row="0" column="1"> + <widget class="QToolButton" name="tool_default_webbrowser"> + <property name="text"> + <string notr="true">...</string> + </property> + <property name="toolButtonStyle"> + <enum>Qt::ToolButtonTextBesideIcon</enum> + </property> + </widget> + </item> + <item row="1" column="0"> + <widget class="QLabel" name="label_38"> + <property name="font"> + <font> + <weight>75</weight> + <bold>true</bold> + </font> + </property> + <property name="text"> + <string>E-Mail Client:</string> + </property> + </widget> + </item> + <item row="1" column="1"> + <widget class="QToolButton" name="tool_default_email"> + <property name="text"> + <string notr="true">...</string> + </property> + <property name="toolButtonStyle"> + <enum>Qt::ToolButtonTextBesideIcon</enum> + </property> + </widget> + </item> + </layout> + </item> + <item row="0" column="1"> + <layout class="QFormLayout" name="formLayout_11"> + <item row="0" column="0"> + <widget class="QLabel" name="label_39"> + <property name="font"> + <font> + <weight>75</weight> + <bold>true</bold> + </font> + </property> + <property name="text"> + <string>File Manager:</string> + </property> + </widget> + </item> + <item row="1" column="0"> + <widget class="QLabel" name="label_40"> + <property name="font"> + <font> + <weight>75</weight> + <bold>true</bold> + </font> + </property> + <property name="text"> + <string>Virtual Terminal:</string> + </property> + </widget> + </item> + <item row="0" column="1"> + <widget class="QToolButton" name="tool_default_filemanager"> + <property name="text"> + <string>...</string> + </property> + <property name="toolButtonStyle"> + <enum>Qt::ToolButtonTextBesideIcon</enum> + </property> + </widget> + </item> + <item row="1" column="1"> + <widget class="QToolButton" name="tool_default_terminal"> + <property name="text"> + <string>...</string> + </property> + <property name="toolButtonStyle"> + <enum>Qt::ToolButtonTextBesideIcon</enum> + </property> + </widget> + </item> + </layout> + </item> + </layout> + </item> + <item> + <spacer name="verticalSpacer_4"> + <property name="orientation"> + <enum>Qt::Vertical</enum> + </property> + <property name="sizeHint" stdset="0"> + <size> + <width>20</width> + <height>40</height> + </size> + </property> + </spacer> + </item> + </layout> + </widget> <widget class="QWidget" name="tab_defaults"> <attribute name="title"> <string>Advanced</string> @@ -163,133 +290,6 @@ </item> </layout> </widget> - <widget class="QWidget" name="tab_auto"> - <attribute name="title"> - <string>Basic Settings</string> - </attribute> - <layout class="QVBoxLayout" name="verticalLayout_7"> - <item> - <layout class="QGridLayout" name="gridLayout_6"> - <item row="0" column="0"> - <layout class="QFormLayout" name="formLayout_10"> - <property name="fieldGrowthPolicy"> - <enum>QFormLayout::ExpandingFieldsGrow</enum> - </property> - <item row="0" column="0"> - <widget class="QLabel" name="label_37"> - <property name="font"> - <font> - <weight>75</weight> - <bold>true</bold> - </font> - </property> - <property name="text"> - <string>Web Browser:</string> - </property> - </widget> - </item> - <item row="0" column="1"> - <widget class="QToolButton" name="tool_default_webbrowser"> - <property name="text"> - <string notr="true">...</string> - </property> - <property name="toolButtonStyle"> - <enum>Qt::ToolButtonTextBesideIcon</enum> - </property> - </widget> - </item> - <item row="1" column="0"> - <widget class="QLabel" name="label_38"> - <property name="font"> - <font> - <weight>75</weight> - <bold>true</bold> - </font> - </property> - <property name="text"> - <string>E-Mail Client:</string> - </property> - </widget> - </item> - <item row="1" column="1"> - <widget class="QToolButton" name="tool_default_email"> - <property name="text"> - <string notr="true">...</string> - </property> - <property name="toolButtonStyle"> - <enum>Qt::ToolButtonTextBesideIcon</enum> - </property> - </widget> - </item> - </layout> - </item> - <item row="0" column="1"> - <layout class="QFormLayout" name="formLayout_11"> - <item row="0" column="0"> - <widget class="QLabel" name="label_39"> - <property name="font"> - <font> - <weight>75</weight> - <bold>true</bold> - </font> - </property> - <property name="text"> - <string>File Manager:</string> - </property> - </widget> - </item> - <item row="1" column="0"> - <widget class="QLabel" name="label_40"> - <property name="font"> - <font> - <weight>75</weight> - <bold>true</bold> - </font> - </property> - <property name="text"> - <string>Virtual Terminal:</string> - </property> - </widget> - </item> - <item row="0" column="1"> - <widget class="QToolButton" name="tool_default_filemanager"> - <property name="text"> - <string>...</string> - </property> - <property name="toolButtonStyle"> - <enum>Qt::ToolButtonTextBesideIcon</enum> - </property> - </widget> - </item> - <item row="1" column="1"> - <widget class="QToolButton" name="tool_default_terminal"> - <property name="text"> - <string>...</string> - </property> - <property name="toolButtonStyle"> - <enum>Qt::ToolButtonTextBesideIcon</enum> - </property> - </widget> - </item> - </layout> - </item> - </layout> - </item> - <item> - <spacer name="verticalSpacer_4"> - <property name="orientation"> - <enum>Qt::Vertical</enum> - </property> - <property name="sizeHint" stdset="0"> - <size> - <width>20</width> - <height>40</height> - </size> - </property> - </spacer> - </item> - </layout> - </widget> </widget> </item> </layout> diff --git a/src-qt5/core-utils/lumina-config/pages/page_session_options.cpp b/src-qt5/core-utils/lumina-config/pages/page_session_options.cpp index 333f9da8..1af87cd2 100644 --- a/src-qt5/core-utils/lumina-config/pages/page_session_options.cpp +++ b/src-qt5/core-utils/lumina-config/pages/page_session_options.cpp @@ -33,6 +33,7 @@ page_session_options::page_session_options(QWidget *parent) : PageWidget(parent) connect(ui->check_session_playloginaudio, SIGNAL(toggled(bool)), this, SLOT(settingChanged()) ); connect(ui->check_session_playlogoutaudio, SIGNAL(toggled(bool)), this, SLOT(settingChanged()) ); connect(ui->check_autoapplinks, SIGNAL(toggled(bool)), this, SLOT(settingChanged()) ); + connect(ui->check_watch_app_procs, SIGNAL(toggled(bool)), this, SLOT(settingChanged()) ); updateIcons(); } @@ -53,6 +54,14 @@ void page_session_options::SaveSettings(){ sessionsettings.setValue("TimeFormat", ui->line_session_time->text()); sessionsettings.setValue("DateFormat", ui->line_session_date->text()); sessionsettings.setValue("DateTimeOrder", ui->combo_session_datetimeorder->currentData().toString()); + + QString lopenWatchFile = QString(getenv("XDG_CONFIG_HOME"))+"/lumina-desktop/nowatch"; + if(QFile::exists(lopenWatchFile) && ui->check_watch_app_procs->isChecked()){ + QFile::remove(lopenWatchFile); + }else if(!QFile::exists(lopenWatchFile) && !ui->check_watch_app_procs->isChecked()){ + QFile file(lopenWatchFile); + if(file.open(QIODevice::WriteOnly) ){ file.close(); } //just need to touch it to create the file + } emit HasPendingChanges(false); } @@ -71,6 +80,9 @@ void page_session_options::LoadSettings(int){ int index = ui->combo_session_datetimeorder->findData( sessionsettings.value("DateTimeOrder","timeonly").toString() ); ui->combo_session_datetimeorder->setCurrentIndex(index); + QString lopenWatchFile = QString(getenv("XDG_CONFIG_HOME"))+"/lumina-desktop/nowatch"; + ui->check_watch_app_procs->setChecked( !QFile::exists(lopenWatchFile) ); + sessionLoadTimeSample(); sessionLoadDateSample(); QApplication::processEvents(); //throw away any interaction events from loading diff --git a/src-qt5/core-utils/lumina-config/pages/page_session_options.ui b/src-qt5/core-utils/lumina-config/pages/page_session_options.ui index 55d204ae..255166de 100644 --- a/src-qt5/core-utils/lumina-config/pages/page_session_options.ui +++ b/src-qt5/core-utils/lumina-config/pages/page_session_options.ui @@ -59,6 +59,13 @@ </property> </widget> </item> + <item> + <widget class="QCheckBox" name="check_watch_app_procs"> + <property name="text"> + <string>Show application crash data</string> + </property> + </widget> + </item> <item> <layout class="QHBoxLayout" name="horizontalLayout_14"> <item> -- cgit From 834e242d561f727a33f19f9e62ad0c8f9f903d0d Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Thu, 17 Nov 2016 09:48:24 -0500 Subject: Add a new page for mouse-settings in lumina-config (disabled for the moment) --- src-qt5/core-utils/lumina-config/pages/getPage.h | 4 +- .../core-utils/lumina-config/pages/page_mouse.cpp | 65 ++++++++++++++++++++++ .../core-utils/lumina-config/pages/page_mouse.h | 33 +++++++++++ .../core-utils/lumina-config/pages/page_mouse.ui | 58 +++++++++++++++++++ src-qt5/core-utils/lumina-config/pages/pages.pri | 9 ++- 5 files changed, 165 insertions(+), 4 deletions(-) create mode 100644 src-qt5/core-utils/lumina-config/pages/page_mouse.cpp create mode 100644 src-qt5/core-utils/lumina-config/pages/page_mouse.h create mode 100644 src-qt5/core-utils/lumina-config/pages/page_mouse.ui (limited to 'src-qt5') diff --git a/src-qt5/core-utils/lumina-config/pages/getPage.h b/src-qt5/core-utils/lumina-config/pages/getPage.h index fba3998b..ea0cfb00 100644 --- a/src-qt5/core-utils/lumina-config/pages/getPage.h +++ b/src-qt5/core-utils/lumina-config/pages/getPage.h @@ -38,7 +38,7 @@ static QList<PAGEINFO> KnownPages(){ list << PageInfo("interface-menu", QObject::tr("Menu"), QObject::tr("Menu Plugins"), "preferences-plugin",QObject::tr("Change what options are shown on the desktop context menu"), "interface", QStringList(), QStringList() << "desktop" << "menu" << "plugins" << "shortcuts"); list << PageInfo("session-locale", QObject::tr("Localization"), QObject::tr("Locale Settings"), "preferences-desktop-locale",QObject::tr("Change the default locale settings for this user"), "user", QStringList(), QStringList() << "user"<<"locale"<<"language"<<"translations"); list << PageInfo("session-options", QObject::tr("General Options"), QObject::tr("User Settings"), "configure",QObject::tr("Change basic user settings such as time/date formats"), "user", QStringList(), QStringList() << "user"<<"settings"<<"time"<<"date"<<"icon"<<"reset"<<"numlock"<<"clock"); - + //list << PageInfo("mouse", QObject::tr("Mouse Settings"), QObject::tr("Mouse Settings"), "input-mouse",QObject::tr("Adjust mouse settings"), "user", QStringList(), QStringList() << "user"<<"speed"<<"accel"<<"mouse"); //Now sort the items according to the translated name QStringList names; for(int i=0; i<list.length(); i++){ names << list[i].name; } @@ -66,6 +66,7 @@ static QList<PAGEINFO> KnownPages(){ #include "page_session_locale.h" #include "page_session_options.h" #include "page_compton.h" +#include "page_mouse.h" static PageWidget* GetNewPage(QString id, QWidget *parent){ //Find the page that matches this "id" @@ -82,6 +83,7 @@ static PageWidget* GetNewPage(QString id, QWidget *parent){ else if(id=="session-locale"){ page = new page_session_locale(parent); } else if(id=="session-options"){ page = new page_session_options(parent); } else if(id=="compton"){ page = new page_compton(parent); } + else if(id=="mouse"){ page = new page_mouse(parent); } //Return the main control_panel page as the fallback/default if(page==0){ id.clear(); page = new page_main(parent); } page->setWhatsThis(id); diff --git a/src-qt5/core-utils/lumina-config/pages/page_mouse.cpp b/src-qt5/core-utils/lumina-config/pages/page_mouse.cpp new file mode 100644 index 00000000..675a8b25 --- /dev/null +++ b/src-qt5/core-utils/lumina-config/pages/page_mouse.cpp @@ -0,0 +1,65 @@ +//=========================================== +// Lumina Desktop Source Code +// Copyright (c) 2016, Ken Moore +// Available under the 3-clause BSD license +// See the LICENSE file for full details +//=========================================== +#include "page_mouse.h" +#include "ui_page_mouse.h" +#include "getPage.h" + +//========== +// PUBLIC +//========== +page_mouse::page_mouse(QWidget *parent) : PageWidget(parent), ui(new Ui::page_mouse()){ + ui->setupUi(this); + connect(ui->slider_accel, SIGNAL(valueChanged(int)), this, SLOT(accelChanged(int)) ); + updateIcons(); +} + +page_mouse::~page_mouse(){ + +} + +//================ +// PUBLIC SLOTS +//================ +void page_mouse::SaveSettings(){ + + emit HasPendingChanges(false); +} + +void page_mouse::LoadSettings(int){ + emit HasPendingChanges(false); + emit ChangePageTitle( tr("Desktop Settings") ); + +} + +void page_mouse::updateIcons(){ + +} + +//================= +// PRIVATE +//================= + +//================= +// PRIVATE SLOTS +//================= +void page_mouse::accelChanged(int val){ + if(val<=4){ + val = 4-val; + ui->label_accel->setText( QString("1/%1").arg(QString::number(val)) ); + QProcess::startDetached("xset mouse 1/"+QString::number(val)); + }else{ + val = val-4; + if(val%2==0){ + val = val/2; + ui->label_accel->setText( QString::number(val) ); + QProcess::startDetached("xset mouse "+QString::number(val)); + }else{ + ui->label_accel->setText( QString::number(val)+"/2" ); + QProcess::startDetached("xset mouse "+QString::number(val)+"/2"); + } + } +} diff --git a/src-qt5/core-utils/lumina-config/pages/page_mouse.h b/src-qt5/core-utils/lumina-config/pages/page_mouse.h new file mode 100644 index 00000000..f005760f --- /dev/null +++ b/src-qt5/core-utils/lumina-config/pages/page_mouse.h @@ -0,0 +1,33 @@ +//=========================================== +// Lumina Desktop Source Code +// Copyright (c) 2016, Ken Moore +// Available under the 3-clause BSD license +// See the LICENSE file for full details +//=========================================== +#ifndef _LUMINA_CONFIG_PAGE_MOUSE_H +#define _LUMINA_CONFIG_PAGE_MOUSE_H +#include "../globals.h" +#include "PageWidget.h" + +namespace Ui{ + class page_mouse; +}; + +class page_mouse : public PageWidget{ + Q_OBJECT +public: + page_mouse(QWidget *parent); + ~page_mouse(); + +public slots: + void SaveSettings(); + void LoadSettings(int screennum); + void updateIcons(); + +private: + Ui::page_mouse *ui; + +private slots: + void accelChanged(int val); +}; +#endif diff --git a/src-qt5/core-utils/lumina-config/pages/page_mouse.ui b/src-qt5/core-utils/lumina-config/pages/page_mouse.ui new file mode 100644 index 00000000..619e38dc --- /dev/null +++ b/src-qt5/core-utils/lumina-config/pages/page_mouse.ui @@ -0,0 +1,58 @@ +<?xml version="1.0" encoding="UTF-8"?> +<ui version="4.0"> + <class>page_mouse</class> + <widget class="QWidget" name="page_mouse"> + <property name="geometry"> + <rect> + <x>0</x> + <y>0</y> + <width>400</width> + <height>300</height> + </rect> + </property> + <property name="windowTitle"> + <string>Form</string> + </property> + <layout class="QFormLayout" name="formLayout"> + <item row="0" column="0"> + <widget class="QLabel" name="label"> + <property name="text"> + <string>Mouse Acceleration</string> + </property> + </widget> + </item> + <item row="0" column="1"> + <layout class="QHBoxLayout" name="horizontalLayout"> + <item> + <widget class="QSlider" name="slider_accel"> + <property name="maximum"> + <number>20</number> + </property> + <property name="value"> + <number>4</number> + </property> + <property name="orientation"> + <enum>Qt::Horizontal</enum> + </property> + <property name="tickPosition"> + <enum>QSlider::TicksBelow</enum> + </property> + <property name="tickInterval"> + <number>2</number> + </property> + </widget> + </item> + <item> + <widget class="QLabel" name="label_accel"> + <property name="text"> + <string notr="true"/> + </property> + </widget> + </item> + </layout> + </item> + </layout> + </widget> + <resources/> + <connections/> +</ui> diff --git a/src-qt5/core-utils/lumina-config/pages/pages.pri b/src-qt5/core-utils/lumina-config/pages/pages.pri index b1db2860..b36ca7ba 100644 --- a/src-qt5/core-utils/lumina-config/pages/pages.pri +++ b/src-qt5/core-utils/lumina-config/pages/pages.pri @@ -13,7 +13,8 @@ HEADERS += $${PWD}/getPage.h \ $${PWD}/page_interface_panels.h \ $${PWD}/page_session_locale.h \ $${PWD}/page_session_options.h \ - $${PWD}/page_compton.h + $${PWD}/page_compton.h \ + $${PWD}/page_mouse.h SOURCES += $${PWD}/page_main.cpp \ @@ -28,7 +29,8 @@ SOURCES += $${PWD}/page_main.cpp \ $${PWD}/page_interface_panels.cpp \ $${PWD}/page_session_locale.cpp \ $${PWD}/page_session_options.cpp \ - $${PWD}/page_compton.cpp + $${PWD}/page_compton.cpp \ + $${PWD}/page_mouse.cpp FORMS += $${PWD}/page_main.ui \ @@ -43,4 +45,5 @@ FORMS += $${PWD}/page_main.ui \ $${PWD}/page_interface_panels.ui \ $${PWD}/page_session_locale.ui \ $${PWD}/page_session_options.ui \ - $${PWD}/page_compton.ui + $${PWD}/page_compton.ui \ + $${PWD}/page_mouse.ui -- cgit From e81f5030cba63c6ba8763c688d86d0b1843272e0 Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Thu, 17 Nov 2016 09:56:13 -0500 Subject: Bump the copyright year on the LuminaX11 files. --- src-qt5/core/libLumina/LuminaX11.cpp | 3 ++- src-qt5/core/libLumina/LuminaX11.h | 3 +-- 2 files changed, 3 insertions(+), 3 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/core/libLumina/LuminaX11.cpp b/src-qt5/core/libLumina/LuminaX11.cpp index 3708af6d..a8016460 100644 --- a/src-qt5/core/libLumina/LuminaX11.cpp +++ b/src-qt5/core/libLumina/LuminaX11.cpp @@ -1,6 +1,6 @@ //=========================================== // Lumina-DE source code -// Copyright (c) 2014-2015, Ken Moore +// Copyright (c) 2014-2016, Ken Moore // Available under the 3-clause BSD license // See the LICENSE file for full details //=========================================== @@ -1124,6 +1124,7 @@ void LXCB::closeSystemTray(WId trayID){ xcb_destroy_window(QX11Info::connection(), trayID); } + // === SetScreenWorkArea() === /*void LXCB::SetScreenWorkArea(unsigned int screen, QRect rect){ //This is only useful because Fluxbox does not set the _NET_WORKAREA root atom diff --git a/src-qt5/core/libLumina/LuminaX11.h b/src-qt5/core/libLumina/LuminaX11.h index 7b6cce3c..2c741111 100644 --- a/src-qt5/core/libLumina/LuminaX11.h +++ b/src-qt5/core/libLumina/LuminaX11.h @@ -1,6 +1,6 @@ //=========================================== // Lumina-DE source code -// Copyright (c) 2014-2015, Ken Moore +// Copyright (c) 2014-2016, Ken Moore // Available under the 3-clause BSD license // See the LICENSE file for full details //=========================================== @@ -161,7 +161,6 @@ public: WId startSystemTray(int screen = 0); //Startup the system tray (returns window ID for tray) void closeSystemTray(WId); //Close the system tray - //============ // WM Functions (directly changing/reading properties) // - Using these directly may prevent the WM from seeing the change -- cgit From c8478cd010f7c6056a48e0cca9d4c0359329297a Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Thu, 17 Nov 2016 10:38:53 -0500 Subject: Add in the beginnings of a new backend class for managing input devices (LInputDevice): This uses the xcb-xinput library for interacting with devices on X (could be moved to wayland in the future). --- src-qt5/core/libLumina/LInputDevice.cpp | 88 +++++++++++++++++++++++++++++++++ src-qt5/core/libLumina/LInputDevice.h | 43 ++++++++++++++++ src-qt5/core/libLumina/LInputDevice.pri | 13 +++++ 3 files changed, 144 insertions(+) create mode 100644 src-qt5/core/libLumina/LInputDevice.cpp create mode 100644 src-qt5/core/libLumina/LInputDevice.h create mode 100644 src-qt5/core/libLumina/LInputDevice.pri (limited to 'src-qt5') diff --git a/src-qt5/core/libLumina/LInputDevice.cpp b/src-qt5/core/libLumina/LInputDevice.cpp new file mode 100644 index 00000000..a760d19d --- /dev/null +++ b/src-qt5/core/libLumina/LInputDevice.cpp @@ -0,0 +1,88 @@ +//=========================================== +// Lumina-DE source code +// Copyright (c) 2016, Ken Moore +// Available under the 3-clause BSD license +// See the LICENSE file for full details +//=========================================== +#include "LInputDevice.h" + +//Qt Library includes +#include <QString> +#include <QX11Info> +#include <QDebug> + +//XCB Library includes +#include <xcb/xcb.h> +#include <xcb/xcb_atom.h> +#include <xcb/xinput.h> + +// LInputDevice Class +LInputDevice::LInputDevice(unsigned int id, unsigned int type){ + devID = id; + devType = type; + //devName = name; +} + +LInputDevice::~LInputDevice(){ + +} + +unsigned int LInputDevice::devNumber(){ + return devID; +} + +bool LInputDevice::isPointer(){ + return (devType==XCB_INPUT_DEVICE_USE_IS_X_POINTER \ + || devType==XCB_INPUT_DEVICE_USE_IS_X_EXTENSION_POINTER); +} + +bool LInputDevice::isKeyboard(){ + return (devType==XCB_INPUT_DEVICE_USE_IS_X_KEYBOARD \ + || devType==XCB_INPUT_DEVICE_USE_IS_X_EXTENSION_KEYBOARD); +} + +bool LInputDevice::isExtension(){ + return (devType==XCB_INPUT_DEVICE_USE_IS_X_EXTENSION_DEVICE \ + || devType==XCB_INPUT_DEVICE_USE_IS_X_EXTENSION_KEYBOARD \ + || devType==XCB_INPUT_DEVICE_USE_IS_X_EXTENSION_POINTER); +} + +QStringList LInputDevice::listProperties(){ + xcb_input_list_device_properties_cookie_t cookie = xcb_input_list_device_properties_unchecked(QX11Info::connection(), devID); + xcb_input_list_device_properties_reply_t *reply = xcb_input_list_device_properties_reply(QX11Info::connection(), cookie, NULL); + qDebug() << "Property List:"; + qDebug() << " - response_type:" << reply->response_type; + qDebug() << " - num atoms:" << reply->num_atoms; + qDebug() << " - length:" << reply->length; + qDebug() << " - sequence:" << reply->sequence; + //Done with data structure + ::free(reply); + //Return info + return QStringList(); +} +//====================== +// LInput Static Functions +//====================== +QList<LInputDevice*> LInput::listDevices(){ + QList<LInputDevice*> devices; + xcb_input_list_input_devices_cookie_t cookie = xcb_input_list_input_devices_unchecked(QX11Info::connection()); + xcb_input_list_input_devices_reply_t *reply = xcb_input_list_input_devices_reply(QX11Info::connection(), cookie, NULL); + if(reply==0){ return devices; } //error - nothing returned + //Use the iterator for going through the reply + xcb_input_device_info_iterator_t iter = xcb_input_list_input_devices_devices_iterator(reply); + //xcb_str_iterator_t nameiter = xcb_input_list_input_devices_names_iterator(reply); + + //Now step through the reply + QStringList info; + while(iter.data != 0 ){ + devices << new LInputDevice(iter.data->device_id, iter.data->device_use); + //qDebug() << "Input Device:" << iter.data->device_id; + //qDebug() << " - num_class_info:" << iter.data->num_class_info; + xcb_input_device_info_next(&iter); + //xcb_input_device_name_next(&nameiter); + } + //Free the reply (done with it) + ::free(reply); + //return the information + return devices; +} diff --git a/src-qt5/core/libLumina/LInputDevice.h b/src-qt5/core/libLumina/LInputDevice.h new file mode 100644 index 00000000..efbc41e7 --- /dev/null +++ b/src-qt5/core/libLumina/LInputDevice.h @@ -0,0 +1,43 @@ +//=========================================== +// Lumina-DE source code +// Copyright (c) 2016, Ken Moore +// Available under the 3-clause BSD license +// See the LICENSE file for full details +//=========================================== +// This class governs all the XCB input device interactions +// and provides simpler Qt-based functions for use elsewhere +//=========================================== +#ifndef _LUMINA_XCB_INPUT_DEVICES_H +#define _LUMINA_XCB_INPUT_DEVICES_H + +#include <QList> +#include <QString> +#include <QStringList> + +class LInputDevice{ +public: + LInputDevice(unsigned int id, unsigned int type); //don't use this directly - use the "listDevices()" function instead + ~LInputDevice(); + + //QString name(); //Return the name of this device + unsigned int devNumber(); + bool isPointer(); + bool isKeyboard(); + bool isExtension(); + + //List Properties of device + QStringList listProperties(); + +private: + unsigned int devID; //device ID number - assigned at class creation + unsigned int devType; //device "use" identifier - assigned at class creation + //QString devName; //device name - use this for cross-session management (id #'s can get changed every session) +}; + +//Static functions for overall management +class LInput{ + QList<LInputDevice*> listDevices(); //NOTE: Make sure you "free()" all the LInputDevice objects when finished + +}; + +#endif diff --git a/src-qt5/core/libLumina/LInputDevice.pri b/src-qt5/core/libLumina/LInputDevice.pri new file mode 100644 index 00000000..e90728ce --- /dev/null +++ b/src-qt5/core/libLumina/LInputDevice.pri @@ -0,0 +1,13 @@ + +QT *= x11extras + +LIBS *= -lc -lxcb -lxcb-xinput + +#LUtils Files +SOURCES *= $${PWD}/LInputDevice.cpp +HEADERS *= $${PWD}/LInputDevice.h + +INCLUDEPATH *= ${PWD} + +#include LUtils and LuminaOS +#include(LUtils.pri) -- cgit From f56665661e03a6a988451af0544c5866a6dfd88e Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Thu, 17 Nov 2016 10:42:48 -0500 Subject: Oops - make sure the LInput funcions are public and static --- src-qt5/core/libLumina/LInputDevice.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src-qt5') diff --git a/src-qt5/core/libLumina/LInputDevice.h b/src-qt5/core/libLumina/LInputDevice.h index efbc41e7..1293ea92 100644 --- a/src-qt5/core/libLumina/LInputDevice.h +++ b/src-qt5/core/libLumina/LInputDevice.h @@ -36,7 +36,8 @@ private: //Static functions for overall management class LInput{ - QList<LInputDevice*> listDevices(); //NOTE: Make sure you "free()" all the LInputDevice objects when finished + public: + static QList<LInputDevice*> listDevices(); //NOTE: Make sure you "free()" all the LInputDevice objects when finished }; -- cgit From 7a0a00fde86468ddf5d6877a96a3e23ed123bb0a Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Thu, 17 Nov 2016 11:17:57 -0500 Subject: Get a bit more of the input device class working - using lumina-config for testing on the new "mouse" page (which is still disabled for the moment). --- src-qt5/core-utils/lumina-config/globals.h | 2 ++ src-qt5/core-utils/lumina-config/lumina-config.pro | 1 + src-qt5/core-utils/lumina-config/pages/page_mouse.cpp | 16 ++++++++++++++-- src-qt5/core-utils/lumina-config/pages/page_mouse.h | 3 +++ src-qt5/core/libLumina/LInputDevice.cpp | 8 ++++---- 5 files changed, 24 insertions(+), 6 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/core-utils/lumina-config/globals.h b/src-qt5/core-utils/lumina-config/globals.h index 0f94785c..ed7549aa 100644 --- a/src-qt5/core-utils/lumina-config/globals.h +++ b/src-qt5/core-utils/lumina-config/globals.h @@ -35,6 +35,8 @@ #include <LuminaOS.h> #include <LuminaThemes.h> +#include "pages/PageWidget.h" + #endif //Now the global class for available system applications diff --git a/src-qt5/core-utils/lumina-config/lumina-config.pro b/src-qt5/core-utils/lumina-config/lumina-config.pro index fe5494de..57531e69 100644 --- a/src-qt5/core-utils/lumina-config/lumina-config.pro +++ b/src-qt5/core-utils/lumina-config/lumina-config.pro @@ -15,6 +15,7 @@ include(../../core/libLumina/LDesktopUtils.pri) #includes LUtils include(../../core/libLumina/LuminaXDG.pri) include(../../core/libLumina/LuminaSingleApplication.pri) include(../../core/libLumina/LuminaThemes.pri) +include(../../core/libLumina/LInputDevice.pri) SOURCES += main.cpp \ mainWindow.cpp \ diff --git a/src-qt5/core-utils/lumina-config/pages/page_mouse.cpp b/src-qt5/core-utils/lumina-config/pages/page_mouse.cpp index 675a8b25..0dabdf2d 100644 --- a/src-qt5/core-utils/lumina-config/pages/page_mouse.cpp +++ b/src-qt5/core-utils/lumina-config/pages/page_mouse.cpp @@ -14,11 +14,23 @@ page_mouse::page_mouse(QWidget *parent) : PageWidget(parent), ui(new Ui::page_mouse()){ ui->setupUi(this); connect(ui->slider_accel, SIGNAL(valueChanged(int)), this, SLOT(accelChanged(int)) ); - updateIcons(); + updateIcons(); + qDebug() << "List Devices:"; + QList<LInputDevice*> devices = LInput::listDevices(); + for(int i=0; i<devices.length(); i++){ + if(!devices[i]->isPointer()){ + ::free( devices.takeAt(i)); + i--; + }else{ + qDebug() << "Found Pointer:" << devices[i]->devNumber(); + qDebug() << " - isExtension:" << devices[i]->isExtension(); + devices[i]->listProperties(); + } + } } page_mouse::~page_mouse(){ - + for(int i=0; i<devices.length(); i++){ ::free(devices[i]); } } //================ diff --git a/src-qt5/core-utils/lumina-config/pages/page_mouse.h b/src-qt5/core-utils/lumina-config/pages/page_mouse.h index f005760f..849917c5 100644 --- a/src-qt5/core-utils/lumina-config/pages/page_mouse.h +++ b/src-qt5/core-utils/lumina-config/pages/page_mouse.h @@ -9,6 +9,8 @@ #include "../globals.h" #include "PageWidget.h" +#include <LInputDevice.h> + namespace Ui{ class page_mouse; }; @@ -26,6 +28,7 @@ public slots: private: Ui::page_mouse *ui; + QList<LInputDevice*> devices; private slots: void accelChanged(int val); diff --git a/src-qt5/core/libLumina/LInputDevice.cpp b/src-qt5/core/libLumina/LInputDevice.cpp index a760d19d..79f5c27f 100644 --- a/src-qt5/core/libLumina/LInputDevice.cpp +++ b/src-qt5/core/libLumina/LInputDevice.cpp @@ -69,17 +69,17 @@ QList<LInputDevice*> LInput::listDevices(){ xcb_input_list_input_devices_reply_t *reply = xcb_input_list_input_devices_reply(QX11Info::connection(), cookie, NULL); if(reply==0){ return devices; } //error - nothing returned //Use the iterator for going through the reply + //qDebug() << "Create iterator"; xcb_input_device_info_iterator_t iter = xcb_input_list_input_devices_devices_iterator(reply); //xcb_str_iterator_t nameiter = xcb_input_list_input_devices_names_iterator(reply); //Now step through the reply - QStringList info; while(iter.data != 0 ){ devices << new LInputDevice(iter.data->device_id, iter.data->device_use); - //qDebug() << "Input Device:" << iter.data->device_id; + //qDebug() << "Found Input Device:" << iter.data->device_id; //qDebug() << " - num_class_info:" << iter.data->num_class_info; - xcb_input_device_info_next(&iter); - //xcb_input_device_name_next(&nameiter); + if(iter.rem>0){ xcb_input_device_info_next(&iter); } + else{ break; } } //Free the reply (done with it) ::free(reply); -- cgit From 44c2f396902ee2a9da898fd3965a7c5600d20118 Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Thu, 17 Nov 2016 13:53:55 -0500 Subject: Commit some more work on the new input device framework. Got the properties getting listed now, just need to figure out how to read/set the various properties (no documentation on what the various inputs are for the XCB functions to do that). --- .../core-utils/lumina-config/pages/page_mouse.cpp | 2 +- src-qt5/core/libLumina/LInputDevice.cpp | 40 +++++++++++++++++----- src-qt5/core/libLumina/LInputDevice.h | 11 +++++- 3 files changed, 43 insertions(+), 10 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/core-utils/lumina-config/pages/page_mouse.cpp b/src-qt5/core-utils/lumina-config/pages/page_mouse.cpp index 0dabdf2d..dbe075d7 100644 --- a/src-qt5/core-utils/lumina-config/pages/page_mouse.cpp +++ b/src-qt5/core-utils/lumina-config/pages/page_mouse.cpp @@ -24,7 +24,7 @@ page_mouse::page_mouse(QWidget *parent) : PageWidget(parent), ui(new Ui::page_mo }else{ qDebug() << "Found Pointer:" << devices[i]->devNumber(); qDebug() << " - isExtension:" << devices[i]->isExtension(); - devices[i]->listProperties(); + qDebug() << " - Properties:" << devices[i]->listProperties(); } } } diff --git a/src-qt5/core/libLumina/LInputDevice.cpp b/src-qt5/core/libLumina/LInputDevice.cpp index 79f5c27f..d141e39a 100644 --- a/src-qt5/core/libLumina/LInputDevice.cpp +++ b/src-qt5/core/libLumina/LInputDevice.cpp @@ -15,12 +15,17 @@ #include <xcb/xcb.h> #include <xcb/xcb_atom.h> #include <xcb/xinput.h> +#include <xcb/xproto.h> -// LInputDevice Class +//=================== +// LInputDevice Class +//=================== +// === PUBLIC === LInputDevice::LInputDevice(unsigned int id, unsigned int type){ devID = id; devType = type; //devName = name; + getProperties(); //need to populate the name/atom correlations for properties } LInputDevice::~LInputDevice(){ @@ -47,18 +52,37 @@ bool LInputDevice::isExtension(){ || devType==XCB_INPUT_DEVICE_USE_IS_X_EXTENSION_POINTER); } +// Property Management QStringList LInputDevice::listProperties(){ + return devProps.keys(); +} + +QVariant LInputDevice::propertyValue(QString prop){ + if(!devProps.contains(prop)){ return QVariant(); } + //Now generate the property request + // xcb_input_get_device_property_cookie_t cookie = xcb_input_get_device_property_unchecked( QX11Info::connection(), devProps.value(prop), \ +// XCB_ATOM_ATOM, 0, 1000, devID, NULL); + QVariant result; + return result; +} + +// === PRIVATE === +void LInputDevice::getProperties(){ + devProps.clear(); xcb_input_list_device_properties_cookie_t cookie = xcb_input_list_device_properties_unchecked(QX11Info::connection(), devID); xcb_input_list_device_properties_reply_t *reply = xcb_input_list_device_properties_reply(QX11Info::connection(), cookie, NULL); - qDebug() << "Property List:"; - qDebug() << " - response_type:" << reply->response_type; - qDebug() << " - num atoms:" << reply->num_atoms; - qDebug() << " - length:" << reply->length; - qDebug() << " - sequence:" << reply->sequence; + //Get the atoms + xcb_atom_t *atoms = xcb_input_list_device_properties_atoms(reply); + //qDebug() << "Property Response Type:" << reply->response_type; //Always seems to be "1" + QList<xcb_get_atom_name_cookie_t> cookies; + for(int i=0; i<reply->num_atoms; i++){ cookies << xcb_get_atom_name(QX11Info::connection(), atoms[i]); } + for(int i=0; i<reply->num_atoms; i++){ + xcb_get_atom_name_reply_t *nr = xcb_get_atom_name_reply(QX11Info::connection(), cookies[i], NULL); + devProps.insert(QString::fromUtf8( xcb_get_atom_name_name(nr), xcb_get_atom_name_name_length(nr) ),atoms[i] ); + ::free(nr); + } //Done with data structure ::free(reply); - //Return info - return QStringList(); } //====================== // LInput Static Functions diff --git a/src-qt5/core/libLumina/LInputDevice.h b/src-qt5/core/libLumina/LInputDevice.h index 1293ea92..f7a4713c 100644 --- a/src-qt5/core/libLumina/LInputDevice.h +++ b/src-qt5/core/libLumina/LInputDevice.h @@ -13,24 +13,33 @@ #include <QList> #include <QString> #include <QStringList> +#include <QHash> +#include <QVariant> + +#include <xcb/xproto.h> class LInputDevice{ public: LInputDevice(unsigned int id, unsigned int type); //don't use this directly - use the "listDevices()" function instead ~LInputDevice(); + //Device Information //QString name(); //Return the name of this device unsigned int devNumber(); bool isPointer(); bool isKeyboard(); bool isExtension(); - //List Properties of device + //Property Management QStringList listProperties(); + QVariant propertyValue(QString prop); private: unsigned int devID; //device ID number - assigned at class creation unsigned int devType; //device "use" identifier - assigned at class creation + QHash<QString, xcb_atom_t> devProps; //Known device properties <name, atom> + + void getProperties(); //QString devName; //device name - use this for cross-session management (id #'s can get changed every session) }; -- cgit From eea17de71ca7198bb3e463b730c534090496fc7c Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Fri, 18 Nov 2016 10:36:46 -0500 Subject: Add a couple new features to lumina-archiver: 1) Add the ability to extract only the selected item from an archive 2) Add better status reporting on archive interactions Changelog=yes --- src-qt5/desktop-utils/lumina-archiver/MainUI.cpp | 30 +++++++++++++++++-- src-qt5/desktop-utils/lumina-archiver/MainUI.h | 3 +- src-qt5/desktop-utils/lumina-archiver/MainUI.ui | 34 ++++++++++++++++++++++ .../desktop-utils/lumina-archiver/TarBackend.cpp | 22 +++++++++----- src-qt5/desktop-utils/lumina-archiver/TarBackend.h | 4 +-- 5 files changed, 80 insertions(+), 13 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/desktop-utils/lumina-archiver/MainUI.cpp b/src-qt5/desktop-utils/lumina-archiver/MainUI.cpp index 9710045c..71fb6db1 100644 --- a/src-qt5/desktop-utils/lumina-archiver/MainUI.cpp +++ b/src-qt5/desktop-utils/lumina-archiver/MainUI.cpp @@ -18,7 +18,7 @@ MainUI::MainUI() : QMainWindow(), ui(new Ui::MainUI){ this->setWindowTitle(tr("Archive Manager")); BACKEND = new Backend(this); connect(BACKEND, SIGNAL(ProcessStarting()), this, SLOT(ProcStarting()) ); - connect(BACKEND, SIGNAL(ProcessFinished()), this, SLOT(ProcFinished()) ); + connect(BACKEND, SIGNAL(ProcessFinished(bool, QString)), this, SLOT(ProcFinished(bool, QString)) ); connect(BACKEND, SIGNAL(ProgressUpdate(int, QString)), this, SLOT(ProcUpdate(int, QString)) ); //Add a spacer between toolbar items @@ -33,10 +33,12 @@ MainUI::MainUI() : QMainWindow(), ui(new Ui::MainUI){ connect(ui->actionAdd_File, SIGNAL(triggered()), this, SLOT(addFiles()) ); connect(ui->actionRemove_File, SIGNAL(triggered()), this, SLOT(remFiles()) ); connect(ui->actionExtract_All, SIGNAL(triggered()), this, SLOT(extractFiles()) ); + connect(ui->actionExtract_Sel, SIGNAL(triggered()), this, SLOT(extractSelection()) ); connect(ui->actionAdd_Dirs, SIGNAL(triggered()), this, SLOT(addDirs()) ); connect(ui->tree_contents, SIGNAL(itemDoubleClicked(QTreeWidgetItem*, int)), this, SLOT(ViewFile(QTreeWidgetItem*)) ); ui->progressBar->setVisible(false); ui->label_progress->setVisible(false); + ui->label_progress_icon->setVisible(false); ui->actionAdd_File->setEnabled(false); ui->actionRemove_File->setEnabled(false); ui->actionExtract_All->setEnabled(false); @@ -64,6 +66,7 @@ void MainUI::loadIcons(){ ui->actionAdd_Dirs->setIcon( LXDG::findIcon("archive-insert-directory","") ); ui->actionRemove_File->setIcon( LXDG::findIcon("archive-remove","") ); ui->actionExtract_All->setIcon( LXDG::findIcon("archive-extract","") ); + ui->actionExtract_Sel->setIcon( LXDG::findIcon("archive-extract","") ); } //=================== @@ -158,24 +161,28 @@ void MainUI::NewArchive(){ if(QFile::exists(file)){ if( !QFile::remove(file) ){ QMessageBox::warning(this, tr("Error"), QString(tr("Could not overwrite file:"))+"\n"+file); } } + ui->label_progress->setText(""); //just clear it (this action is instant) BACKEND->loadFile(file); } void MainUI::OpenArchive(){ QString file = QFileDialog::getOpenFileName(this, tr("Open Archive"), QDir::homePath(), OpenFileTypes() ); if(file.isEmpty()){ return; } + ui->label_progress->setText(tr("Opening Archive")); BACKEND->loadFile(file); } void MainUI::addFiles(){ QStringList files = QFileDialog::getOpenFileNames(this, tr("Add to Archive"), QDir::homePath() ); if(files.isEmpty()){ return; } + ui->label_progress->setText(tr("Adding Items")); BACKEND->startAdd(files); } void MainUI::addDirs(){ QString dirs = QFileDialog::getExistingDirectory(this, tr("Add to Archive"), QDir::homePath() ); if(dirs.isEmpty()){ return; } + ui->label_progress->setText(tr("Adding Items")); BACKEND->startAdd(QStringList() << dirs); } @@ -186,17 +193,29 @@ void MainUI::remFiles(){ items << sel[i]->whatsThis(0); } items.removeDuplicates(); + ui->label_progress->setText(tr("Removing Items")); BACKEND->startRemove(items); } void MainUI::extractFiles(){ QString dir = QFileDialog::getExistingDirectory(this, tr("Extract Into Directory"), QDir::homePath() ); if(dir.isEmpty()){ return; } + ui->label_progress->setText(tr("Extracting...")); BACKEND->startExtract(dir, true); } +void MainUI::extractSelection(){ + if(ui->tree_contents->currentItem()==0){ return; } + QString sel = ui->tree_contents->currentItem()->whatsThis(0); + QString dir = QFileDialog::getExistingDirectory(this, tr("Extract Into Directory"), QDir::homePath() ); + if(dir.isEmpty()){ return; } + ui->label_progress->setText(tr("Extracting...")); + BACKEND->startExtract(dir, true, sel); +} + void MainUI::ViewFile(QTreeWidgetItem *it){ if(it->childCount()>0){ return; } //directory - not viewable + ui->label_progress->setText(tr("Extracting...")); BACKEND->startViewFile(it->whatsThis(0)); } @@ -242,16 +261,21 @@ void MainUI::ProcStarting(){ ui->progressBar->setValue(0); ui->progressBar->setVisible(true); ui->label_progress->setVisible(true); + ui->label_progress_icon->setVisible(false); ui->tree_contents->setEnabled(false); ui->label_archive->setText(BACKEND->currentFile()); } -void MainUI::ProcFinished(){ +void MainUI::ProcFinished(bool success, QString msg){ ui->progressBar->setRange(0,0); ui->progressBar->setValue(0); ui->progressBar->setVisible(false); - ui->label_progress->setVisible(false); + ui->label_progress->setText(msg); + ui->label_progress->setVisible(!msg.isEmpty()); ui->tree_contents->setEnabled(true); + ui->label_progress_icon->setVisible(!msg.isEmpty()); + if(success){ ui->label_progress_icon->setPixmap( LXDG::findIcon("task-complete","").pixmap(32,32) );} + else{ ui->label_progress_icon->setPixmap( LXDG::findIcon("task-attention","").pixmap(32,32) );} if(ui->label_archive->text()!=BACKEND->currentFile()){ ui->label_archive->setText(BACKEND->currentFile()); this->setWindowTitle(BACKEND->currentFile().section("/",-1)); diff --git a/src-qt5/desktop-utils/lumina-archiver/MainUI.h b/src-qt5/desktop-utils/lumina-archiver/MainUI.h index 09207aa3..bb462a7d 100644 --- a/src-qt5/desktop-utils/lumina-archiver/MainUI.h +++ b/src-qt5/desktop-utils/lumina-archiver/MainUI.h @@ -44,13 +44,14 @@ private slots: void addDirs(); void remFiles(); void extractFiles(); + void extractSelection(); void ViewFile(QTreeWidgetItem *it); void UpdateTree(); //Backend Handling void ProcStarting(); - void ProcFinished(); + void ProcFinished(bool, QString); void ProcUpdate(int percent, QString txt); }; diff --git a/src-qt5/desktop-utils/lumina-archiver/MainUI.ui b/src-qt5/desktop-utils/lumina-archiver/MainUI.ui index 8c2b2836..1aff2e4f 100644 --- a/src-qt5/desktop-utils/lumina-archiver/MainUI.ui +++ b/src-qt5/desktop-utils/lumina-archiver/MainUI.ui @@ -56,6 +56,31 @@ </item> <item> <layout class="QHBoxLayout" name="horizontalLayout_2"> + <item> + <widget class="QLabel" name="label_progress_icon"> + <property name="sizePolicy"> + <sizepolicy hsizetype="Fixed" vsizetype="Fixed"> + <horstretch>0</horstretch> + <verstretch>0</verstretch> + </sizepolicy> + </property> + <property name="minimumSize"> + <size> + <width>32</width> + <height>32</height> + </size> + </property> + <property name="maximumSize"> + <size> + <width>32</width> + <height>32</height> + </size> + </property> + <property name="text"> + <string notr="true"/> + </property> + </widget> + </item> <item> <widget class="QProgressBar" name="progressBar"> <property name="value"> @@ -68,6 +93,9 @@ <property name="text"> <string notr="true"/> </property> + <property name="alignment"> + <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set> + </property> </widget> </item> </layout> @@ -101,6 +129,7 @@ <addaction name="actionRemove_File"/> <addaction name="separator"/> <addaction name="actionExtract_All"/> + <addaction name="actionExtract_Sel"/> </widget> <addaction name="menuFile"/> <addaction name="menuEdit"/> @@ -183,6 +212,11 @@ <string>Add directory to archive</string> </property> </action> + <action name="actionExtract_Sel"> + <property name="text"> + <string>Extract Selection</string> + </property> + </action> </widget> <resources/> <connections/> diff --git a/src-qt5/desktop-utils/lumina-archiver/TarBackend.cpp b/src-qt5/desktop-utils/lumina-archiver/TarBackend.cpp index 4dee247b..de3ef49b 100644 --- a/src-qt5/desktop-utils/lumina-archiver/TarBackend.cpp +++ b/src-qt5/desktop-utils/lumina-archiver/TarBackend.cpp @@ -32,7 +32,7 @@ void Backend::loadFile(QString path){ flags.clear(); flags << "-f" << filepath; //add the actual archive path if(QFile::exists(path)){ startList(); } - else{ contents.clear(); emit ProcessFinished(); } + else{ contents.clear(); emit ProcessFinished(true, ""); } } bool Backend::canModify(){ @@ -115,11 +115,13 @@ void Backend::startRemove(QStringList paths){ PROC.start("tar", args); } -void Backend::startExtract(QString path, bool overwrite){ +void Backend::startExtract(QString path, bool overwrite, QString file){ QStringList args; args << "-x"; if(!overwrite){ args << "-k"; } - args << flags << "-C" << path; + args << flags; + if(!file.isEmpty()){ args << "--include" << file << "--strip-components" << QString::number(file.count("/")); } + args << "-C" << path; STARTING=true; //qDebug() << "Starting command:" << "tar" << args; PROC.start("tar", args); @@ -174,17 +176,19 @@ void Backend::startList(){ // PRIVATE SLOTS //=============== void Backend::procFinished(int retcode, QProcess::ExitStatus){ + static QString result; processData(); qDebug() << "Process Finished:" << PROC.arguments() << retcode; LIST = STARTING = false; if(PROC.arguments().contains("-tv")){ if(retcode!=0){ contents.clear(); } //could not read archive - emit ProcessFinished(); + emit ProcessFinished(true,result); + result.clear(); }else{ bool needupdate = true; QStringList args = PROC.arguments(); if(args.contains("-x") && retcode==0){ - needupdate=false; + needupdate=false; if(args.contains("--include")){ //Need to find the full path to the extracted file QString path = args.last() +"/"+ args[ args.indexOf("--include")+1].section("/",-1); @@ -201,8 +205,10 @@ void Backend::procFinished(int retcode, QProcess::ExitStatus){ QFile::remove(tmpfilepath); } } + if(args.contains("-x")){ result = tr("Extraction Finished"); } + else if(args.contains("-c")){ result = tr("Modification Finished"); } if(needupdate){ startList(); } - else{ emit ProcessFinished(); } + else{ emit ProcessFinished(retcode==0, result); result.clear(); } } } @@ -213,7 +219,9 @@ void Backend::processData(){ if(read.endsWith("\n")){ data.clear(); } else{ data = read.section("\n",-1); read = read.section("\n",0,-2); } QStringList lines = read.split("\n",QString::SkipEmptyParts); + QString info; if(LIST){ parseLines(lines); } + else if(!lines.isEmpty()){ info = lines.last(); } //qDebug() << lines; - emit ProgressUpdate(-1, ""); + emit ProgressUpdate(-1, info); } diff --git a/src-qt5/desktop-utils/lumina-archiver/TarBackend.h b/src-qt5/desktop-utils/lumina-archiver/TarBackend.h index f12aae63..c1e47454 100644 --- a/src-qt5/desktop-utils/lumina-archiver/TarBackend.h +++ b/src-qt5/desktop-utils/lumina-archiver/TarBackend.h @@ -33,7 +33,7 @@ public: //Modification routines void startAdd(QStringList paths); void startRemove(QStringList paths); - void startExtract(QString path, bool overwrite); //path to dir + void startExtract(QString path, bool overwrite, QString file=""); //path to dir, overwrite, optional file to extract (everything otherwise) void startViewFile(QString path); @@ -58,7 +58,7 @@ signals: void FileLoaded(); void ProcessStarting(); void ProgressUpdate(int, QString); //percentage, text - void ProcessFinished(); + void ProcessFinished(bool, QString); //success, text }; #endif -- cgit From dfcd09c7824548001260bc18dcae711c50f63de3 Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Fri, 18 Nov 2016 12:37:01 -0500 Subject: Fix up the detection of links within an archive - and show them appropriately within the UI --- src-qt5/desktop-utils/lumina-archiver/MainUI.cpp | 61 +++++++++++++++------- .../desktop-utils/lumina-archiver/TarBackend.cpp | 25 +++++++-- src-qt5/desktop-utils/lumina-archiver/TarBackend.h | 3 ++ 3 files changed, 66 insertions(+), 23 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/desktop-utils/lumina-archiver/MainUI.cpp b/src-qt5/desktop-utils/lumina-archiver/MainUI.cpp index 71fb6db1..9d41374c 100644 --- a/src-qt5/desktop-utils/lumina-archiver/MainUI.cpp +++ b/src-qt5/desktop-utils/lumina-archiver/MainUI.cpp @@ -44,7 +44,7 @@ MainUI::MainUI() : QMainWindow(), ui(new Ui::MainUI){ ui->actionExtract_All->setEnabled(false); ui->actionAdd_Dirs->setEnabled(false); loadIcons(); - ui->tree_contents->setHeaderLabels( QStringList() << tr("File") << tr("MimeType") << tr("Size") << tr("Compressed")+" " ); + ui->tree_contents->setHeaderLabels( QStringList() << tr("File") << tr("MimeType") << tr("Size")+" " ); } MainUI::~MainUI(){ @@ -53,7 +53,11 @@ MainUI::~MainUI(){ void MainUI::LoadArguments(QStringList args){ for(int i=0; i<args.length(); i++){ - if(QFile::exists(args[i])){ BACKEND->loadFile(args[i]); break;} + if(QFile::exists(args[i])){ + ui->label_progress->setText(tr("Opening Archive...")); + BACKEND->loadFile(args[i]); + break; + } } } @@ -75,17 +79,16 @@ void MainUI::loadIcons(){ QTreeWidgetItem* MainUI::findItem(QString path, QTreeWidgetItem *start){ if(start==0){ for(int i=0; i<ui->tree_contents->topLevelItemCount(); i++){ - QString itpath = ui->tree_contents->topLevelItem(i)->whatsThis(0); - if(itpath == path){ return ui->tree_contents->topLevelItem(i); } - else if(path.startsWith(itpath+"/")){ return findItem(path, ui->tree_contents->topLevelItem(i)); } + if(ui->tree_contents->topLevelItem(i)->whatsThis(0) == path){ return ui->tree_contents->topLevelItem(i); } + else if(path.startsWith(ui->tree_contents->topLevelItem(i)->whatsThis(0)+"/")){ return findItem(path, ui->tree_contents->topLevelItem(i)); } } }else{ for(int i=0; i<start->childCount(); i++){ - QString itpath = start->child(i)->whatsThis(0); - if(itpath == path){ return start->child(i); } - else if(path.startsWith(itpath+"/")){ return findItem(path, start->child(i)); } + if(start->child(i)->whatsThis(0) == path){ return start->child(i); } + else if(path.startsWith(start->child(i)->whatsThis(0)+"/")){ return findItem(path, start->child(i)); } } } + //qDebug() << "Could not find item:" << path; return 0; //nothing found } @@ -168,21 +171,21 @@ void MainUI::NewArchive(){ void MainUI::OpenArchive(){ QString file = QFileDialog::getOpenFileName(this, tr("Open Archive"), QDir::homePath(), OpenFileTypes() ); if(file.isEmpty()){ return; } - ui->label_progress->setText(tr("Opening Archive")); + ui->label_progress->setText(tr("Opening Archive...")); BACKEND->loadFile(file); } void MainUI::addFiles(){ QStringList files = QFileDialog::getOpenFileNames(this, tr("Add to Archive"), QDir::homePath() ); if(files.isEmpty()){ return; } - ui->label_progress->setText(tr("Adding Items")); + ui->label_progress->setText(tr("Adding Items...")); BACKEND->startAdd(files); } void MainUI::addDirs(){ QString dirs = QFileDialog::getExistingDirectory(this, tr("Add to Archive"), QDir::homePath() ); if(dirs.isEmpty()){ return; } - ui->label_progress->setText(tr("Adding Items")); + ui->label_progress->setText(tr("Adding Items...")); BACKEND->startAdd(QStringList() << dirs); } @@ -193,7 +196,7 @@ void MainUI::remFiles(){ items << sel[i]->whatsThis(0); } items.removeDuplicates(); - ui->label_progress->setText(tr("Removing Items")); + ui->label_progress->setText(tr("Removing Items...")); BACKEND->startRemove(items); } @@ -220,20 +223,30 @@ void MainUI::ViewFile(QTreeWidgetItem *it){ } void MainUI::UpdateTree(){ - ui->tree_contents->setHeaderLabels( QStringList() << tr("File") << tr("MimeType") << tr("Size") << tr("Compressed")+" " ); + this->setEnabled(false); + ui->tree_contents->setHeaderLabels( QStringList() << tr("File") << tr("MimeType") << tr("Size")+" " ); QStringList files = BACKEND->heirarchy(); files.sort(); //Remove any entries for file no longer in the archive bool changed = cleanItems(files); - qDebug() << "Found Files:" << files; + //qDebug() << "Found Files:" << files; for(int i=0; i<files.length(); i++){ if(0 != findItem(files[i]) ){ continue; } //already in the tree widget QString mime = LXDG::findAppMimeForFile(files[i].section("/",-1), false); //first match only - QTreeWidgetItem *it = new QTreeWidgetItem( QStringList() << files[i].section("/",-1) << mime << LUtils::BytesToDisplaySize( BACKEND->size(files[i])) << LUtils::BytesToDisplaySize(BACKEND->csize(files[i])) ); + QTreeWidgetItem *it = new QTreeWidgetItem(); + it->setText(0, files[i].section("/",-1) ); + if(!BACKEND->isLink(files[i])){ + it->setText(1, LXDG::findAppMimeForFile(files[i].section("/",-1), false) ); + it->setText(2, LUtils::BytesToDisplaySize( BACKEND->size(files[i])) ); + }else{ + it->setText(1, QString(tr("Link To: %1")).arg(BACKEND->linkTo(files[i]) ) ); + } it->setWhatsThis(0, files[i]); if(BACKEND->isDir(files[i])){ it->setIcon(0, LXDG::findIcon("folder","")); it->setText(1,""); //clear the mimetype + }else if(BACKEND->isLink(files[i])){ + it->setIcon(0, LXDG::findIcon("emblem-symbolic-link","") ); }else{ it->setIcon(0, LXDG::findMimeIcon(files[i].section("/",-1)) ); } @@ -245,14 +258,23 @@ void MainUI::UpdateTree(){ else{ parent->addChild(it); } }else{ ui->tree_contents->addTopLevelItem(it); + QApplication::processEvents(); } changed = true; } - int wid = 0; + if(changed){ - for(int i=3; i>0; i--){ui->tree_contents->resizeColumnToContents(i); wid+= ui->tree_contents->columnWidth(i); } + int wid = ui->tree_contents->fontMetrics().width("W")*5; + ui->tree_contents->setColumnWidth(2, wid); + for(int i=1; i<2; i++){ui->tree_contents->resizeColumnToContents(i); QApplication::processEvents(); wid+= ui->tree_contents->columnWidth(i); } + //qDebug() << "Set column 0 width:" << wid << ui->tree_contents->viewport()->width(); ui->tree_contents->setColumnWidth(0, ui->tree_contents->viewport()->width()-wid); } + ui->tree_contents->sortItems(0, Qt::AscendingOrder); //sort by name + ui->tree_contents->sortItems(1,Qt::AscendingOrder); //sort by mimetype (put dirs first - still organized by name) + + this->setEnabled(true); + ui->tree_contents->setEnabled(true); } //Backend Handling @@ -260,19 +282,19 @@ void MainUI::ProcStarting(){ ui->progressBar->setRange(0,0); ui->progressBar->setValue(0); ui->progressBar->setVisible(true); - ui->label_progress->setVisible(true); + ui->label_progress->setVisible(!ui->label_progress->text().isEmpty()); ui->label_progress_icon->setVisible(false); ui->tree_contents->setEnabled(false); ui->label_archive->setText(BACKEND->currentFile()); } void MainUI::ProcFinished(bool success, QString msg){ + UpdateTree(); ui->progressBar->setRange(0,0); ui->progressBar->setValue(0); ui->progressBar->setVisible(false); ui->label_progress->setText(msg); ui->label_progress->setVisible(!msg.isEmpty()); - ui->tree_contents->setEnabled(true); ui->label_progress_icon->setVisible(!msg.isEmpty()); if(success){ ui->label_progress_icon->setPixmap( LXDG::findIcon("task-complete","").pixmap(32,32) );} else{ ui->label_progress_icon->setPixmap( LXDG::findIcon("task-attention","").pixmap(32,32) );} @@ -289,7 +311,6 @@ void MainUI::ProcFinished(bool success, QString msg){ ui->actionRemove_File->setEnabled(canmodify && info.exists()); ui->actionExtract_All->setEnabled(info.exists()); ui->actionAdd_Dirs->setEnabled(canmodify); - UpdateTree(); } void MainUI::ProcUpdate(int percent, QString txt){ diff --git a/src-qt5/desktop-utils/lumina-archiver/TarBackend.cpp b/src-qt5/desktop-utils/lumina-archiver/TarBackend.cpp index de3ef49b..919a6813 100644 --- a/src-qt5/desktop-utils/lumina-archiver/TarBackend.cpp +++ b/src-qt5/desktop-utils/lumina-archiver/TarBackend.cpp @@ -75,6 +75,16 @@ bool Backend::isDir(QString file){ return contents.value(file)[0].startsWith("d"); } +bool Backend::isLink(QString file){ + if(!contents.contains(file)){ return false; } + return contents.value(file)[0].startsWith("l"); +} + +QString Backend::linkTo(QString file){ + if(!contents.contains(file)){ return ""; } + return contents.value(file)[2]; +} + //Modification routines void Backend::startAdd(QStringList paths){ //NOTE: All the "paths" have to have the same parent directory @@ -153,14 +163,23 @@ void Backend::parseLines(QStringList lines){ QString file = info[1]; QString perms = ""; if(file.endsWith("/")){ perms = "d"; file.chop(1); } - contents.insert(file, QStringList() << perms << "-1" ); //Save the [perms, size ] + contents.insert(file, QStringList() << perms << "-1" <<""); //Save the [perms, size, linkto ] } else if(info.length()<9){ continue; } //invalid line //TAR Archive parsing while(info.length()>9){ info[8] = info[8]+" "+info[9]; info.removeAt(9); } //Filename has spaces in it QString file = info[8]; if(file.endsWith("/")){ file.chop(1); } - contents.insert(file, QStringList() << info[0] << info[4] ); //Save the [perms, size ] + QString linkto; + //See if this file has the "link to" or "->" notation + if(file.contains(" -> ")){ linkto = file.section(" -> ",1,-1); file = file.section(" -> ",0,0); } + else if(file.contains(" link to ")){ + //Special case - alternate form of a link within a tar archive (not reflected in perms) + linkto = file.section(" link to ",1,-1); + file = file.section(" link to ",0,0); + if(info[0].startsWith("-")){ info[0].replace(0,1,"l"); } + } + contents.insert(file, QStringList() << info[0] << info[4] << linkto); //Save the [perms, size, linkto ] } } @@ -178,7 +197,7 @@ void Backend::startList(){ void Backend::procFinished(int retcode, QProcess::ExitStatus){ static QString result; processData(); - qDebug() << "Process Finished:" << PROC.arguments() << retcode; + //qDebug() << "Process Finished:" << PROC.arguments() << retcode; LIST = STARTING = false; if(PROC.arguments().contains("-tv")){ if(retcode!=0){ contents.clear(); } //could not read archive diff --git a/src-qt5/desktop-utils/lumina-archiver/TarBackend.h b/src-qt5/desktop-utils/lumina-archiver/TarBackend.h index c1e47454..47bc0bb6 100644 --- a/src-qt5/desktop-utils/lumina-archiver/TarBackend.h +++ b/src-qt5/desktop-utils/lumina-archiver/TarBackend.h @@ -29,6 +29,8 @@ public: double size(QString file); double csize(QString file); bool isDir(QString file); + bool isLink(QString file); + QString linkTo(QString file); //Modification routines void startAdd(QStringList paths); @@ -37,6 +39,7 @@ public: void startViewFile(QString path); + //Special process public slots: private: -- cgit From d5a55a057d3fc180a3a07e76362b6830b6d2c5f4 Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Fri, 18 Nov 2016 12:40:50 -0500 Subject: Add a new dialog UI form (not integrated yet) for a front-end to "dd"ing ISO/IMG files to a USB stick. --- src-qt5/desktop-utils/lumina-archiver/isoDialog.ui | 151 +++++++++++++++++++++ 1 file changed, 151 insertions(+) create mode 100644 src-qt5/desktop-utils/lumina-archiver/isoDialog.ui (limited to 'src-qt5') diff --git a/src-qt5/desktop-utils/lumina-archiver/isoDialog.ui b/src-qt5/desktop-utils/lumina-archiver/isoDialog.ui new file mode 100644 index 00000000..99ba31fb --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/isoDialog.ui @@ -0,0 +1,151 @@ +<?xml version="1.0" encoding="UTF-8"?> +<ui version="4.0"> + <class>isoDialog</class> + <widget class="QDialog" name="isoDialog"> + <property name="geometry"> + <rect> + <x>0</x> + <y>0</y> + <width>305</width> + <height>179</height> + </rect> + </property> + <property name="windowTitle"> + <string>Burn ISO/IMG to device</string> + </property> + <layout class="QFormLayout" name="formLayout"> + <item row="0" column="0" colspan="2"> + <widget class="QLabel" name="label_iso"> + <property name="font"> + <font> + <weight>75</weight> + <bold>true</bold> + </font> + </property> + <property name="text"> + <string>TextLabel</string> + </property> + <property name="alignment"> + <set>Qt::AlignCenter</set> + </property> + </widget> + </item> + <item row="1" column="0"> + <widget class="QLabel" name="label"> + <property name="sizePolicy"> + <sizepolicy hsizetype="Expanding" vsizetype="Preferred"> + <horstretch>0</horstretch> + <verstretch>0</verstretch> + </sizepolicy> + </property> + <property name="text"> + <string>Transfer Rate</string> + </property> + </widget> + </item> + <item row="1" column="1"> + <layout class="QHBoxLayout" name="horizontalLayout"> + <item> + <widget class="QSpinBox" name="spin_rate_num"> + <property name="sizePolicy"> + <sizepolicy hsizetype="Preferred" vsizetype="Fixed"> + <horstretch>0</horstretch> + <verstretch>0</verstretch> + </sizepolicy> + </property> + <property name="minimum"> + <number>1</number> + </property> + <property name="maximum"> + <number>1023</number> + </property> + </widget> + </item> + <item> + <widget class="QComboBox" name="combo_rate_units"/> + </item> + </layout> + </item> + <item row="2" column="0"> + <widget class="QLabel" name="label_3"> + <property name="text"> + <string>USB Device</string> + </property> + </widget> + </item> + <item row="3" column="0" colspan="2"> + <widget class="QCheckBox" name="check_sync"> + <property name="text"> + <string>Wipe all extra space on device (conv = sync)</string> + </property> + <property name="checked"> + <bool>true</bool> + </property> + </widget> + </item> + <item row="2" column="1"> + <layout class="QHBoxLayout" name="horizontalLayout_2"> + <item> + <widget class="QComboBox" name="combo_devices"/> + </item> + <item> + <widget class="QToolButton" name="tool_refresh"> + <property name="toolTip"> + <string>Refresh Device List</string> + </property> + <property name="text"> + <string notr="true"/> + </property> + </widget> + </item> + </layout> + </item> + <item row="4" column="0"> + <spacer name="verticalSpacer"> + <property name="orientation"> + <enum>Qt::Vertical</enum> + </property> + <property name="sizeHint" stdset="0"> + <size> + <width>20</width> + <height>40</height> + </size> + </property> + </spacer> + </item> + <item row="5" column="0" colspan="2"> + <layout class="QHBoxLayout" name="horizontalLayout_3"> + <item> + <spacer name="horizontalSpacer"> + <property name="orientation"> + <enum>Qt::Horizontal</enum> + </property> + <property name="sizeHint" stdset="0"> + <size> + <width>40</width> + <height>20</height> + </size> + </property> + </spacer> + </item> + <item> + <widget class="QPushButton" name="push_cancel"> + <property name="text"> + <string>Cancel</string> + </property> + </widget> + </item> + <item> + <widget class="QPushButton" name="push_start"> + <property name="text"> + <string>Start</string> + </property> + </widget> + </item> + </layout> + </item> + </layout> + </widget> + <resources/> + <connections/> +</ui> -- cgit From cb5524f6fd5186414c11339375bebd3b808b4857 Mon Sep 17 00:00:00 2001 From: q5sys <jt@obs-sec.com> Date: Sun, 20 Nov 2016 01:41:14 -0500 Subject: search clear function on ESC press --- src-qt5/core-utils/lumina-config/mainWindow.cpp | 6 +++++- src-qt5/core-utils/lumina-config/pages/PageWidget.h | 2 +- src-qt5/core-utils/lumina-config/pages/page_compton.cpp | 12 ++++++------ src-qt5/core-utils/lumina-config/pages/page_main.cpp | 5 +++++ src-qt5/core-utils/lumina-config/pages/page_main.h | 1 + 5 files changed, 18 insertions(+), 8 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/core-utils/lumina-config/mainWindow.cpp b/src-qt5/core-utils/lumina-config/mainWindow.cpp index d6ada8f5..ecaf2990 100644 --- a/src-qt5/core-utils/lumina-config/mainWindow.cpp +++ b/src-qt5/core-utils/lumina-config/mainWindow.cpp @@ -9,6 +9,7 @@ #include "globals.h" #include "pages/getPage.h" +#include "pages/page_main.h" //============= // PUBLIC @@ -133,7 +134,10 @@ void mainWindow::on_actionSave_triggered(){ } void mainWindow::on_actionBack_triggered(){ - if(cpage.isEmpty()){ this->close(); } //main menu - go ahead and close it + if(cpage.isEmpty()){ page_main::clearlineEdit(); } //since ESC doesnt close any other Lumina Appliction by default, I've +commented this out for +the +time being. else{ page_change(""); } //Use the interactive wrapper (check for save state, etc). } diff --git a/src-qt5/core-utils/lumina-config/pages/PageWidget.h b/src-qt5/core-utils/lumina-config/pages/PageWidget.h index 2d663e71..8cd23db7 100644 --- a/src-qt5/core-utils/lumina-config/pages/PageWidget.h +++ b/src-qt5/core-utils/lumina-config/pages/PageWidget.h @@ -52,7 +52,7 @@ public slots: //Simplification function for widget connections virtual void settingChanged(){ - emit HasPendingChanges(true); + emit HasPendingChanges(true); } }; diff --git a/src-qt5/core-utils/lumina-config/pages/page_compton.cpp b/src-qt5/core-utils/lumina-config/pages/page_compton.cpp index 0003c9c8..5f7cd190 100644 --- a/src-qt5/core-utils/lumina-config/pages/page_compton.cpp +++ b/src-qt5/core-utils/lumina-config/pages/page_compton.cpp @@ -12,10 +12,10 @@ // PUBLIC //========== page_compton::page_compton(QWidget *parent) : PageWidget(parent), ui(new Ui::page_compton()){ - ui->setupUi(this); - connect(ui->text_file, SIGNAL(textChanged()), this, SLOT(settingChanged()) ); - connect(ui->check_disablecompton, SIGNAL(toggled(bool)), this, SLOT(settingChanged()) ); - updateIcons(); + ui->setupUi(this); + connect(ui->text_file, SIGNAL(textChanged()), this, SLOT(settingChanged()) ); + connect(ui->check_disablecompton, SIGNAL(toggled(bool)), this, SLOT(settingChanged()) ); + updateIcons(); } page_compton::~page_compton(){ @@ -34,17 +34,17 @@ void page_compton::SaveSettings(){ } void page_compton::LoadSettings(int){ - emit HasPendingChanges(false); emit ChangePageTitle( tr("Compositor Settings") ); QSettings settings("lumina-desktop","sessionsettings"); ui->check_disablecompton->setChecked( !settings.value("enableCompositing", true).toBool() ); QString set = QString(getenv("XDG_CONFIG_HOME"))+"/lumina-desktop/compton.conf"; qDebug() << "Load Compton settings:" << set; ui->text_file->setPlainText( LUtils::readFile(set).join("\n") ); + emit HasPendingChanges(false); } void page_compton::updateIcons(){ - +emit HasPendingChanges(false); } //================= diff --git a/src-qt5/core-utils/lumina-config/pages/page_main.cpp b/src-qt5/core-utils/lumina-config/pages/page_main.cpp index 69b32c09..e60606f3 100644 --- a/src-qt5/core-utils/lumina-config/pages/page_main.cpp +++ b/src-qt5/core-utils/lumina-config/pages/page_main.cpp @@ -121,6 +121,11 @@ void page_main::SaveSettings(){ } +void page_main::clearlineEdit(){ + ui->lineEdit->clear(); +} + + void page_main::LoadSettings(int){ emit HasPendingChanges(false); emit ChangePageTitle( tr("Desktop Settings") ); diff --git a/src-qt5/core-utils/lumina-config/pages/page_main.h b/src-qt5/core-utils/lumina-config/pages/page_main.h index e4bfeafd..095815e9 100644 --- a/src-qt5/core-utils/lumina-config/pages/page_main.h +++ b/src-qt5/core-utils/lumina-config/pages/page_main.h @@ -20,6 +20,7 @@ public: ~page_main(); virtual void setPreviousPage(QString id); + void clearlineEdit(); public slots: void SaveSettings(); -- cgit From 151062b99e29e18dbc614bf66582f908c864a96a Mon Sep 17 00:00:00 2001 From: q5sys <jt@obs-sec.com> Date: Sun, 20 Nov 2016 01:50:36 -0500 Subject: Revert "search clear function on ESC press" This reverts commit b9840ef585385fece513e24e4cea193d35328dc0, reversing changes made to cb5524f6fd5186414c11339375bebd3b808b4857. --- src-qt5/core-utils/lumina-config/LPlugins.cpp | 9 +- src-qt5/core-utils/lumina-config/PanelWidget.cpp | 36 +-- src-qt5/core-utils/lumina-config/globals.h | 2 - src-qt5/core-utils/lumina-config/lumina-config.pro | 1 - src-qt5/core-utils/lumina-config/pages/getPage.h | 4 +- .../lumina-config/pages/page_compton.cpp | 2 - .../core-utils/lumina-config/pages/page_compton.ui | 7 - .../lumina-config/pages/page_defaultapps.ui | 256 ++++++++++----------- .../core-utils/lumina-config/pages/page_mouse.cpp | 77 ------- .../core-utils/lumina-config/pages/page_mouse.h | 36 --- .../core-utils/lumina-config/pages/page_mouse.ui | 58 ----- .../lumina-config/pages/page_session_options.cpp | 12 - .../lumina-config/pages/page_session_options.ui | 7 - src-qt5/core-utils/lumina-config/pages/pages.pri | 9 +- src-qt5/core/libLumina/LInputDevice.cpp | 112 --------- src-qt5/core/libLumina/LInputDevice.h | 53 ----- src-qt5/core/libLumina/LInputDevice.pri | 13 -- src-qt5/core/libLumina/LuminaX11.cpp | 3 +- src-qt5/core/libLumina/LuminaX11.h | 3 +- .../defaults/luminaDesktop-TrueOS.conf | 7 - .../lumina-desktop/defaults/luminaDesktop.conf | 14 +- src-qt5/desktop-utils/lumina-archiver/MainUI.cpp | 83 ++----- src-qt5/desktop-utils/lumina-archiver/MainUI.h | 3 +- src-qt5/desktop-utils/lumina-archiver/MainUI.ui | 34 --- .../desktop-utils/lumina-archiver/TarBackend.cpp | 47 +--- src-qt5/desktop-utils/lumina-archiver/TarBackend.h | 7 +- src-qt5/desktop-utils/lumina-archiver/isoDialog.ui | 151 ------------ 27 files changed, 181 insertions(+), 865 deletions(-) delete mode 100644 src-qt5/core-utils/lumina-config/pages/page_mouse.cpp delete mode 100644 src-qt5/core-utils/lumina-config/pages/page_mouse.h delete mode 100644 src-qt5/core-utils/lumina-config/pages/page_mouse.ui delete mode 100644 src-qt5/core/libLumina/LInputDevice.cpp delete mode 100644 src-qt5/core/libLumina/LInputDevice.h delete mode 100644 src-qt5/core/libLumina/LInputDevice.pri delete mode 100644 src-qt5/desktop-utils/lumina-archiver/isoDialog.ui (limited to 'src-qt5') diff --git a/src-qt5/core-utils/lumina-config/LPlugins.cpp b/src-qt5/core-utils/lumina-config/LPlugins.cpp index dfd490e6..089a181c 100644 --- a/src-qt5/core-utils/lumina-config/LPlugins.cpp +++ b/src-qt5/core-utils/lumina-config/LPlugins.cpp @@ -173,13 +173,6 @@ void LPlugins::LoadPanelPlugins(){ info.ID = "audioplayer"; info.icon = "media-playback-start"; PANEL.insert(info.ID, info); - //JSON Menu Scripts - info = LPI(); //clear it - info.name = QObject::tr("Menu Script"); - info.description = QObject::tr("Run an external script to generate a user defined menu"); - info.ID = "jsonmenu"; - info.icon = "text-x-script"; - PANEL.insert(info.ID, info); } // DESKTOP PLUGINS @@ -300,7 +293,7 @@ void LPlugins::LoadMenuPlugins(){ info.ID = "app"; info.icon = "application-x-desktop"; MENU.insert(info.ID, info); - //JSON Menu Scripts + //Custom Apps info = LPI(); //clear it info.name = QObject::tr("Menu Script"); info.description = QObject::tr("Run an external script to generate a user defined menu"); diff --git a/src-qt5/core-utils/lumina-config/PanelWidget.cpp b/src-qt5/core-utils/lumina-config/PanelWidget.cpp index d5d3d9bd..aff7bda3 100644 --- a/src-qt5/core-utils/lumina-config/PanelWidget.cpp +++ b/src-qt5/core-utils/lumina-config/PanelWidget.cpp @@ -9,7 +9,7 @@ #include "GetPluginDialog.h" #include "AppDialog.h" -#include "ScriptDialog.h" + PanelWidget::PanelWidget(QWidget *parent, QWidget *Main, LPlugins *Pinfo) : QWidget(parent), ui(new Ui::PanelWidget){ ui->setupUi(this); @@ -66,18 +66,6 @@ void PanelWidget::LoadSettings(QSettings *settings, int Dnum, int Pnum){ it->setWhatsThis(plugs[i]); //make sure to preserve the entire plugin ID (is the unique version) ui->list_plugins->addItem(it); } - - }else if(pid.startsWith("jsonmenu")){ - LPI info = PINFO->panelPluginInfo( plugs[i].section("::::",0,0) ); - if(info.ID.isEmpty()){ continue; } //invalid plugin type (no longer available?) - QString exec = plugs[i].section("::::",1,1); - QListWidgetItem *item = new QListWidgetItem(); - item->setWhatsThis( plugs[i] ); - item->setIcon( LXDG::findIcon(plugs[i].section("::::",3,3),info.icon) ); - item->setText( plugs[i].section("::::",2,2) +" ("+info.name+")" ); - item->setToolTip( info.description ); - ui->list_plugins->addItem(item); - }else{ LPI info = PINFO->panelPluginInfo(pid); if(!info.ID.isEmpty()){ @@ -192,35 +180,23 @@ void PanelWidget::on_tool_addplugin_clicked(){ dlg.exec(); if(!dlg.selected){ return; } //cancelled QString pan = dlg.plugID; //getNewPanelPlugin(); - QListWidgetItem *it = 0; if(pan == "applauncher"){ //Prompt for the application to add QString app =getSysApp(); if(app.isEmpty()){ return; } //cancelled pan.append("::"+app); XDGDesktop desk(app); - it = new QListWidgetItem( LXDG::findIcon(desk.icon,""), desk.name); + QListWidgetItem *it = new QListWidgetItem( LXDG::findIcon(desk.icon,""), desk.name); it->setWhatsThis(pan); - - }else if(pan=="jsonmenu"){ - //Need to prompt for the script file, name, and icon to use - //new ID format: "jsonmenu"::::<exec to run>::::<name>::::<icon> - ScriptDialog SD(this); - SD.exec(); - if(!SD.isValid()){ return; } - LPI info = PINFO->panelPluginInfo(pan); - it = new QListWidgetItem( LXDG::findIcon(SD.icon(),"text-x-script"), SD.name()+" ("+info.ID+")" ); - it->setWhatsThis(info.ID+"::::"+SD.command()+"::::"+SD.name()+"::::"+SD.icon()); - it->setToolTip( info.description ); + ui->list_plugins->addItem(it); + ui->list_plugins->setCurrentItem(it); + ui->list_plugins->scrollToItem(it); }else{ if(pan.isEmpty()){ return; } //nothing selected //Add the new plugin to the list LPI info = PINFO->panelPluginInfo(pan); - it = new QListWidgetItem( LXDG::findIcon(info.icon,""), info.name); + QListWidgetItem *it = new QListWidgetItem( LXDG::findIcon(info.icon,""), info.name); it->setWhatsThis(info.ID); - } - //Now add the new item to the list - if(it!=0){ ui->list_plugins->addItem(it); ui->list_plugins->setCurrentItem(it); ui->list_plugins->scrollToItem(it); diff --git a/src-qt5/core-utils/lumina-config/globals.h b/src-qt5/core-utils/lumina-config/globals.h index ed7549aa..0f94785c 100644 --- a/src-qt5/core-utils/lumina-config/globals.h +++ b/src-qt5/core-utils/lumina-config/globals.h @@ -35,8 +35,6 @@ #include <LuminaOS.h> #include <LuminaThemes.h> -#include "pages/PageWidget.h" - #endif //Now the global class for available system applications diff --git a/src-qt5/core-utils/lumina-config/lumina-config.pro b/src-qt5/core-utils/lumina-config/lumina-config.pro index 57531e69..fe5494de 100644 --- a/src-qt5/core-utils/lumina-config/lumina-config.pro +++ b/src-qt5/core-utils/lumina-config/lumina-config.pro @@ -15,7 +15,6 @@ include(../../core/libLumina/LDesktopUtils.pri) #includes LUtils include(../../core/libLumina/LuminaXDG.pri) include(../../core/libLumina/LuminaSingleApplication.pri) include(../../core/libLumina/LuminaThemes.pri) -include(../../core/libLumina/LInputDevice.pri) SOURCES += main.cpp \ mainWindow.cpp \ diff --git a/src-qt5/core-utils/lumina-config/pages/getPage.h b/src-qt5/core-utils/lumina-config/pages/getPage.h index ea0cfb00..fba3998b 100644 --- a/src-qt5/core-utils/lumina-config/pages/getPage.h +++ b/src-qt5/core-utils/lumina-config/pages/getPage.h @@ -38,7 +38,7 @@ static QList<PAGEINFO> KnownPages(){ list << PageInfo("interface-menu", QObject::tr("Menu"), QObject::tr("Menu Plugins"), "preferences-plugin",QObject::tr("Change what options are shown on the desktop context menu"), "interface", QStringList(), QStringList() << "desktop" << "menu" << "plugins" << "shortcuts"); list << PageInfo("session-locale", QObject::tr("Localization"), QObject::tr("Locale Settings"), "preferences-desktop-locale",QObject::tr("Change the default locale settings for this user"), "user", QStringList(), QStringList() << "user"<<"locale"<<"language"<<"translations"); list << PageInfo("session-options", QObject::tr("General Options"), QObject::tr("User Settings"), "configure",QObject::tr("Change basic user settings such as time/date formats"), "user", QStringList(), QStringList() << "user"<<"settings"<<"time"<<"date"<<"icon"<<"reset"<<"numlock"<<"clock"); - //list << PageInfo("mouse", QObject::tr("Mouse Settings"), QObject::tr("Mouse Settings"), "input-mouse",QObject::tr("Adjust mouse settings"), "user", QStringList(), QStringList() << "user"<<"speed"<<"accel"<<"mouse"); + //Now sort the items according to the translated name QStringList names; for(int i=0; i<list.length(); i++){ names << list[i].name; } @@ -66,7 +66,6 @@ static QList<PAGEINFO> KnownPages(){ #include "page_session_locale.h" #include "page_session_options.h" #include "page_compton.h" -#include "page_mouse.h" static PageWidget* GetNewPage(QString id, QWidget *parent){ //Find the page that matches this "id" @@ -83,7 +82,6 @@ static PageWidget* GetNewPage(QString id, QWidget *parent){ else if(id=="session-locale"){ page = new page_session_locale(parent); } else if(id=="session-options"){ page = new page_session_options(parent); } else if(id=="compton"){ page = new page_compton(parent); } - else if(id=="mouse"){ page = new page_mouse(parent); } //Return the main control_panel page as the fallback/default if(page==0){ id.clear(); page = new page_main(parent); } page->setWhatsThis(id); diff --git a/src-qt5/core-utils/lumina-config/pages/page_compton.cpp b/src-qt5/core-utils/lumina-config/pages/page_compton.cpp index 8cdb2ea7..5f7cd190 100644 --- a/src-qt5/core-utils/lumina-config/pages/page_compton.cpp +++ b/src-qt5/core-utils/lumina-config/pages/page_compton.cpp @@ -29,7 +29,6 @@ void page_compton::SaveSettings(){ emit HasPendingChanges(false); QSettings settings("lumina-desktop","sessionsettings"); settings.setValue("enableCompositing", !ui->check_disablecompton->isChecked()); - settings.setValue("compositingWithGpuAccelOnly", ui->check_GPUverify->isChecked()); QString set = QString(getenv("XDG_CONFIG_HOME"))+"/lumina-desktop/compton.conf"; LUtils::writeFile(set, ui->text_file->toPlainText().split("\n"),true); } @@ -38,7 +37,6 @@ void page_compton::LoadSettings(int){ emit ChangePageTitle( tr("Compositor Settings") ); QSettings settings("lumina-desktop","sessionsettings"); ui->check_disablecompton->setChecked( !settings.value("enableCompositing", true).toBool() ); - ui->check_GPUverify->setChecked( settings.value("compositingWithGpuAccelOnly", true).toBool() ); QString set = QString(getenv("XDG_CONFIG_HOME"))+"/lumina-desktop/compton.conf"; qDebug() << "Load Compton settings:" << set; ui->text_file->setPlainText( LUtils::readFile(set).join("\n") ); diff --git a/src-qt5/core-utils/lumina-config/pages/page_compton.ui b/src-qt5/core-utils/lumina-config/pages/page_compton.ui index 857331d6..9083a2fb 100644 --- a/src-qt5/core-utils/lumina-config/pages/page_compton.ui +++ b/src-qt5/core-utils/lumina-config/pages/page_compton.ui @@ -33,13 +33,6 @@ </property> </widget> </item> - <item> - <widget class="QCheckBox" name="check_GPUverify"> - <property name="text"> - <string>Only use compositing with GPU acceleration </string> - </property> - </widget> - </item> <item> <widget class="QPlainTextEdit" name="text_file"/> </item> diff --git a/src-qt5/core-utils/lumina-config/pages/page_defaultapps.ui b/src-qt5/core-utils/lumina-config/pages/page_defaultapps.ui index 8440e198..ef72c4f1 100644 --- a/src-qt5/core-utils/lumina-config/pages/page_defaultapps.ui +++ b/src-qt5/core-utils/lumina-config/pages/page_defaultapps.ui @@ -29,138 +29,11 @@ <item> <widget class="QTabWidget" name="tabWidget_apps"> <property name="currentIndex"> - <number>0</number> + <number>1</number> </property> <property name="movable"> <bool>false</bool> </property> - <widget class="QWidget" name="tab_auto"> - <attribute name="title"> - <string>Basic Settings</string> - </attribute> - <layout class="QVBoxLayout" name="verticalLayout_7"> - <item> - <layout class="QGridLayout" name="gridLayout_6"> - <item row="0" column="0"> - <layout class="QFormLayout" name="formLayout_10"> - <property name="fieldGrowthPolicy"> - <enum>QFormLayout::ExpandingFieldsGrow</enum> - </property> - <item row="0" column="0"> - <widget class="QLabel" name="label_37"> - <property name="font"> - <font> - <weight>75</weight> - <bold>true</bold> - </font> - </property> - <property name="text"> - <string>Web Browser:</string> - </property> - </widget> - </item> - <item row="0" column="1"> - <widget class="QToolButton" name="tool_default_webbrowser"> - <property name="text"> - <string notr="true">...</string> - </property> - <property name="toolButtonStyle"> - <enum>Qt::ToolButtonTextBesideIcon</enum> - </property> - </widget> - </item> - <item row="1" column="0"> - <widget class="QLabel" name="label_38"> - <property name="font"> - <font> - <weight>75</weight> - <bold>true</bold> - </font> - </property> - <property name="text"> - <string>E-Mail Client:</string> - </property> - </widget> - </item> - <item row="1" column="1"> - <widget class="QToolButton" name="tool_default_email"> - <property name="text"> - <string notr="true">...</string> - </property> - <property name="toolButtonStyle"> - <enum>Qt::ToolButtonTextBesideIcon</enum> - </property> - </widget> - </item> - </layout> - </item> - <item row="0" column="1"> - <layout class="QFormLayout" name="formLayout_11"> - <item row="0" column="0"> - <widget class="QLabel" name="label_39"> - <property name="font"> - <font> - <weight>75</weight> - <bold>true</bold> - </font> - </property> - <property name="text"> - <string>File Manager:</string> - </property> - </widget> - </item> - <item row="1" column="0"> - <widget class="QLabel" name="label_40"> - <property name="font"> - <font> - <weight>75</weight> - <bold>true</bold> - </font> - </property> - <property name="text"> - <string>Virtual Terminal:</string> - </property> - </widget> - </item> - <item row="0" column="1"> - <widget class="QToolButton" name="tool_default_filemanager"> - <property name="text"> - <string>...</string> - </property> - <property name="toolButtonStyle"> - <enum>Qt::ToolButtonTextBesideIcon</enum> - </property> - </widget> - </item> - <item row="1" column="1"> - <widget class="QToolButton" name="tool_default_terminal"> - <property name="text"> - <string>...</string> - </property> - <property name="toolButtonStyle"> - <enum>Qt::ToolButtonTextBesideIcon</enum> - </property> - </widget> - </item> - </layout> - </item> - </layout> - </item> - <item> - <spacer name="verticalSpacer_4"> - <property name="orientation"> - <enum>Qt::Vertical</enum> - </property> - <property name="sizeHint" stdset="0"> - <size> - <width>20</width> - <height>40</height> - </size> - </property> - </spacer> - </item> - </layout> - </widget> <widget class="QWidget" name="tab_defaults"> <attribute name="title"> <string>Advanced</string> @@ -290,6 +163,133 @@ </item> </layout> </widget> + <widget class="QWidget" name="tab_auto"> + <attribute name="title"> + <string>Basic Settings</string> + </attribute> + <layout class="QVBoxLayout" name="verticalLayout_7"> + <item> + <layout class="QGridLayout" name="gridLayout_6"> + <item row="0" column="0"> + <layout class="QFormLayout" name="formLayout_10"> + <property name="fieldGrowthPolicy"> + <enum>QFormLayout::ExpandingFieldsGrow</enum> + </property> + <item row="0" column="0"> + <widget class="QLabel" name="label_37"> + <property name="font"> + <font> + <weight>75</weight> + <bold>true</bold> + </font> + </property> + <property name="text"> + <string>Web Browser:</string> + </property> + </widget> + </item> + <item row="0" column="1"> + <widget class="QToolButton" name="tool_default_webbrowser"> + <property name="text"> + <string notr="true">...</string> + </property> + <property name="toolButtonStyle"> + <enum>Qt::ToolButtonTextBesideIcon</enum> + </property> + </widget> + </item> + <item row="1" column="0"> + <widget class="QLabel" name="label_38"> + <property name="font"> + <font> + <weight>75</weight> + <bold>true</bold> + </font> + </property> + <property name="text"> + <string>E-Mail Client:</string> + </property> + </widget> + </item> + <item row="1" column="1"> + <widget class="QToolButton" name="tool_default_email"> + <property name="text"> + <string notr="true">...</string> + </property> + <property name="toolButtonStyle"> + <enum>Qt::ToolButtonTextBesideIcon</enum> + </property> + </widget> + </item> + </layout> + </item> + <item row="0" column="1"> + <layout class="QFormLayout" name="formLayout_11"> + <item row="0" column="0"> + <widget class="QLabel" name="label_39"> + <property name="font"> + <font> + <weight>75</weight> + <bold>true</bold> + </font> + </property> + <property name="text"> + <string>File Manager:</string> + </property> + </widget> + </item> + <item row="1" column="0"> + <widget class="QLabel" name="label_40"> + <property name="font"> + <font> + <weight>75</weight> + <bold>true</bold> + </font> + </property> + <property name="text"> + <string>Virtual Terminal:</string> + </property> + </widget> + </item> + <item row="0" column="1"> + <widget class="QToolButton" name="tool_default_filemanager"> + <property name="text"> + <string>...</string> + </property> + <property name="toolButtonStyle"> + <enum>Qt::ToolButtonTextBesideIcon</enum> + </property> + </widget> + </item> + <item row="1" column="1"> + <widget class="QToolButton" name="tool_default_terminal"> + <property name="text"> + <string>...</string> + </property> + <property name="toolButtonStyle"> + <enum>Qt::ToolButtonTextBesideIcon</enum> + </property> + </widget> + </item> + </layout> + </item> + </layout> + </item> + <item> + <spacer name="verticalSpacer_4"> + <property name="orientation"> + <enum>Qt::Vertical</enum> + </property> + <property name="sizeHint" stdset="0"> + <size> + <width>20</width> + <height>40</height> + </size> + </property> + </spacer> + </item> + </layout> + </widget> </widget> </item> </layout> diff --git a/src-qt5/core-utils/lumina-config/pages/page_mouse.cpp b/src-qt5/core-utils/lumina-config/pages/page_mouse.cpp deleted file mode 100644 index dbe075d7..00000000 --- a/src-qt5/core-utils/lumina-config/pages/page_mouse.cpp +++ /dev/null @@ -1,77 +0,0 @@ -//=========================================== -// Lumina Desktop Source Code -// Copyright (c) 2016, Ken Moore -// Available under the 3-clause BSD license -// See the LICENSE file for full details -//=========================================== -#include "page_mouse.h" -#include "ui_page_mouse.h" -#include "getPage.h" - -//========== -// PUBLIC -//========== -page_mouse::page_mouse(QWidget *parent) : PageWidget(parent), ui(new Ui::page_mouse()){ - ui->setupUi(this); - connect(ui->slider_accel, SIGNAL(valueChanged(int)), this, SLOT(accelChanged(int)) ); - updateIcons(); - qDebug() << "List Devices:"; - QList<LInputDevice*> devices = LInput::listDevices(); - for(int i=0; i<devices.length(); i++){ - if(!devices[i]->isPointer()){ - ::free( devices.takeAt(i)); - i--; - }else{ - qDebug() << "Found Pointer:" << devices[i]->devNumber(); - qDebug() << " - isExtension:" << devices[i]->isExtension(); - qDebug() << " - Properties:" << devices[i]->listProperties(); - } - } -} - -page_mouse::~page_mouse(){ - for(int i=0; i<devices.length(); i++){ ::free(devices[i]); } -} - -//================ -// PUBLIC SLOTS -//================ -void page_mouse::SaveSettings(){ - - emit HasPendingChanges(false); -} - -void page_mouse::LoadSettings(int){ - emit HasPendingChanges(false); - emit ChangePageTitle( tr("Desktop Settings") ); - -} - -void page_mouse::updateIcons(){ - -} - -//================= -// PRIVATE -//================= - -//================= -// PRIVATE SLOTS -//================= -void page_mouse::accelChanged(int val){ - if(val<=4){ - val = 4-val; - ui->label_accel->setText( QString("1/%1").arg(QString::number(val)) ); - QProcess::startDetached("xset mouse 1/"+QString::number(val)); - }else{ - val = val-4; - if(val%2==0){ - val = val/2; - ui->label_accel->setText( QString::number(val) ); - QProcess::startDetached("xset mouse "+QString::number(val)); - }else{ - ui->label_accel->setText( QString::number(val)+"/2" ); - QProcess::startDetached("xset mouse "+QString::number(val)+"/2"); - } - } -} diff --git a/src-qt5/core-utils/lumina-config/pages/page_mouse.h b/src-qt5/core-utils/lumina-config/pages/page_mouse.h deleted file mode 100644 index 849917c5..00000000 --- a/src-qt5/core-utils/lumina-config/pages/page_mouse.h +++ /dev/null @@ -1,36 +0,0 @@ -//=========================================== -// Lumina Desktop Source Code -// Copyright (c) 2016, Ken Moore -// Available under the 3-clause BSD license -// See the LICENSE file for full details -//=========================================== -#ifndef _LUMINA_CONFIG_PAGE_MOUSE_H -#define _LUMINA_CONFIG_PAGE_MOUSE_H -#include "../globals.h" -#include "PageWidget.h" - -#include <LInputDevice.h> - -namespace Ui{ - class page_mouse; -}; - -class page_mouse : public PageWidget{ - Q_OBJECT -public: - page_mouse(QWidget *parent); - ~page_mouse(); - -public slots: - void SaveSettings(); - void LoadSettings(int screennum); - void updateIcons(); - -private: - Ui::page_mouse *ui; - QList<LInputDevice*> devices; - -private slots: - void accelChanged(int val); -}; -#endif diff --git a/src-qt5/core-utils/lumina-config/pages/page_mouse.ui b/src-qt5/core-utils/lumina-config/pages/page_mouse.ui deleted file mode 100644 index 619e38dc..00000000 --- a/src-qt5/core-utils/lumina-config/pages/page_mouse.ui +++ /dev/null @@ -1,58 +0,0 @@ -<?xml version="1.0" encoding="UTF-8"?> -<ui version="4.0"> - <class>page_mouse</class> - <widget class="QWidget" name="page_mouse"> - <property name="geometry"> - <rect> - <x>0</x> - <y>0</y> - <width>400</width> - <height>300</height> - </rect> - </property> - <property name="windowTitle"> - <string>Form</string> - </property> - <layout class="QFormLayout" name="formLayout"> - <item row="0" column="0"> - <widget class="QLabel" name="label"> - <property name="text"> - <string>Mouse Acceleration</string> - </property> - </widget> - </item> - <item row="0" column="1"> - <layout class="QHBoxLayout" name="horizontalLayout"> - <item> - <widget class="QSlider" name="slider_accel"> - <property name="maximum"> - <number>20</number> - </property> - <property name="value"> - <number>4</number> - </property> - <property name="orientation"> - <enum>Qt::Horizontal</enum> - </property> - <property name="tickPosition"> - <enum>QSlider::TicksBelow</enum> - </property> - <property name="tickInterval"> - <number>2</number> - </property> - </widget> - </item> - <item> - <widget class="QLabel" name="label_accel"> - <property name="text"> - <string notr="true"/> - </property> - </widget> - </item> - </layout> - </item> - </layout> - </widget> - <resources/> - <connections/> -</ui> diff --git a/src-qt5/core-utils/lumina-config/pages/page_session_options.cpp b/src-qt5/core-utils/lumina-config/pages/page_session_options.cpp index 1af87cd2..333f9da8 100644 --- a/src-qt5/core-utils/lumina-config/pages/page_session_options.cpp +++ b/src-qt5/core-utils/lumina-config/pages/page_session_options.cpp @@ -33,7 +33,6 @@ page_session_options::page_session_options(QWidget *parent) : PageWidget(parent) connect(ui->check_session_playloginaudio, SIGNAL(toggled(bool)), this, SLOT(settingChanged()) ); connect(ui->check_session_playlogoutaudio, SIGNAL(toggled(bool)), this, SLOT(settingChanged()) ); connect(ui->check_autoapplinks, SIGNAL(toggled(bool)), this, SLOT(settingChanged()) ); - connect(ui->check_watch_app_procs, SIGNAL(toggled(bool)), this, SLOT(settingChanged()) ); updateIcons(); } @@ -54,14 +53,6 @@ void page_session_options::SaveSettings(){ sessionsettings.setValue("TimeFormat", ui->line_session_time->text()); sessionsettings.setValue("DateFormat", ui->line_session_date->text()); sessionsettings.setValue("DateTimeOrder", ui->combo_session_datetimeorder->currentData().toString()); - - QString lopenWatchFile = QString(getenv("XDG_CONFIG_HOME"))+"/lumina-desktop/nowatch"; - if(QFile::exists(lopenWatchFile) && ui->check_watch_app_procs->isChecked()){ - QFile::remove(lopenWatchFile); - }else if(!QFile::exists(lopenWatchFile) && !ui->check_watch_app_procs->isChecked()){ - QFile file(lopenWatchFile); - if(file.open(QIODevice::WriteOnly) ){ file.close(); } //just need to touch it to create the file - } emit HasPendingChanges(false); } @@ -80,9 +71,6 @@ void page_session_options::LoadSettings(int){ int index = ui->combo_session_datetimeorder->findData( sessionsettings.value("DateTimeOrder","timeonly").toString() ); ui->combo_session_datetimeorder->setCurrentIndex(index); - QString lopenWatchFile = QString(getenv("XDG_CONFIG_HOME"))+"/lumina-desktop/nowatch"; - ui->check_watch_app_procs->setChecked( !QFile::exists(lopenWatchFile) ); - sessionLoadTimeSample(); sessionLoadDateSample(); QApplication::processEvents(); //throw away any interaction events from loading diff --git a/src-qt5/core-utils/lumina-config/pages/page_session_options.ui b/src-qt5/core-utils/lumina-config/pages/page_session_options.ui index 255166de..55d204ae 100644 --- a/src-qt5/core-utils/lumina-config/pages/page_session_options.ui +++ b/src-qt5/core-utils/lumina-config/pages/page_session_options.ui @@ -59,13 +59,6 @@ </property> </widget> </item> - <item> - <widget class="QCheckBox" name="check_watch_app_procs"> - <property name="text"> - <string>Show application crash data</string> - </property> - </widget> - </item> <item> <layout class="QHBoxLayout" name="horizontalLayout_14"> <item> diff --git a/src-qt5/core-utils/lumina-config/pages/pages.pri b/src-qt5/core-utils/lumina-config/pages/pages.pri index b36ca7ba..b1db2860 100644 --- a/src-qt5/core-utils/lumina-config/pages/pages.pri +++ b/src-qt5/core-utils/lumina-config/pages/pages.pri @@ -13,8 +13,7 @@ HEADERS += $${PWD}/getPage.h \ $${PWD}/page_interface_panels.h \ $${PWD}/page_session_locale.h \ $${PWD}/page_session_options.h \ - $${PWD}/page_compton.h \ - $${PWD}/page_mouse.h + $${PWD}/page_compton.h SOURCES += $${PWD}/page_main.cpp \ @@ -29,8 +28,7 @@ SOURCES += $${PWD}/page_main.cpp \ $${PWD}/page_interface_panels.cpp \ $${PWD}/page_session_locale.cpp \ $${PWD}/page_session_options.cpp \ - $${PWD}/page_compton.cpp \ - $${PWD}/page_mouse.cpp + $${PWD}/page_compton.cpp FORMS += $${PWD}/page_main.ui \ @@ -45,5 +43,4 @@ FORMS += $${PWD}/page_main.ui \ $${PWD}/page_interface_panels.ui \ $${PWD}/page_session_locale.ui \ $${PWD}/page_session_options.ui \ - $${PWD}/page_compton.ui \ - $${PWD}/page_mouse.ui + $${PWD}/page_compton.ui diff --git a/src-qt5/core/libLumina/LInputDevice.cpp b/src-qt5/core/libLumina/LInputDevice.cpp deleted file mode 100644 index d141e39a..00000000 --- a/src-qt5/core/libLumina/LInputDevice.cpp +++ /dev/null @@ -1,112 +0,0 @@ -//=========================================== -// Lumina-DE source code -// Copyright (c) 2016, Ken Moore -// Available under the 3-clause BSD license -// See the LICENSE file for full details -//=========================================== -#include "LInputDevice.h" - -//Qt Library includes -#include <QString> -#include <QX11Info> -#include <QDebug> - -//XCB Library includes -#include <xcb/xcb.h> -#include <xcb/xcb_atom.h> -#include <xcb/xinput.h> -#include <xcb/xproto.h> - -//=================== -// LInputDevice Class -//=================== -// === PUBLIC === -LInputDevice::LInputDevice(unsigned int id, unsigned int type){ - devID = id; - devType = type; - //devName = name; - getProperties(); //need to populate the name/atom correlations for properties -} - -LInputDevice::~LInputDevice(){ - -} - -unsigned int LInputDevice::devNumber(){ - return devID; -} - -bool LInputDevice::isPointer(){ - return (devType==XCB_INPUT_DEVICE_USE_IS_X_POINTER \ - || devType==XCB_INPUT_DEVICE_USE_IS_X_EXTENSION_POINTER); -} - -bool LInputDevice::isKeyboard(){ - return (devType==XCB_INPUT_DEVICE_USE_IS_X_KEYBOARD \ - || devType==XCB_INPUT_DEVICE_USE_IS_X_EXTENSION_KEYBOARD); -} - -bool LInputDevice::isExtension(){ - return (devType==XCB_INPUT_DEVICE_USE_IS_X_EXTENSION_DEVICE \ - || devType==XCB_INPUT_DEVICE_USE_IS_X_EXTENSION_KEYBOARD \ - || devType==XCB_INPUT_DEVICE_USE_IS_X_EXTENSION_POINTER); -} - -// Property Management -QStringList LInputDevice::listProperties(){ - return devProps.keys(); -} - -QVariant LInputDevice::propertyValue(QString prop){ - if(!devProps.contains(prop)){ return QVariant(); } - //Now generate the property request - // xcb_input_get_device_property_cookie_t cookie = xcb_input_get_device_property_unchecked( QX11Info::connection(), devProps.value(prop), \ -// XCB_ATOM_ATOM, 0, 1000, devID, NULL); - QVariant result; - return result; -} - -// === PRIVATE === -void LInputDevice::getProperties(){ - devProps.clear(); - xcb_input_list_device_properties_cookie_t cookie = xcb_input_list_device_properties_unchecked(QX11Info::connection(), devID); - xcb_input_list_device_properties_reply_t *reply = xcb_input_list_device_properties_reply(QX11Info::connection(), cookie, NULL); - //Get the atoms - xcb_atom_t *atoms = xcb_input_list_device_properties_atoms(reply); - //qDebug() << "Property Response Type:" << reply->response_type; //Always seems to be "1" - QList<xcb_get_atom_name_cookie_t> cookies; - for(int i=0; i<reply->num_atoms; i++){ cookies << xcb_get_atom_name(QX11Info::connection(), atoms[i]); } - for(int i=0; i<reply->num_atoms; i++){ - xcb_get_atom_name_reply_t *nr = xcb_get_atom_name_reply(QX11Info::connection(), cookies[i], NULL); - devProps.insert(QString::fromUtf8( xcb_get_atom_name_name(nr), xcb_get_atom_name_name_length(nr) ),atoms[i] ); - ::free(nr); - } - //Done with data structure - ::free(reply); -} -//====================== -// LInput Static Functions -//====================== -QList<LInputDevice*> LInput::listDevices(){ - QList<LInputDevice*> devices; - xcb_input_list_input_devices_cookie_t cookie = xcb_input_list_input_devices_unchecked(QX11Info::connection()); - xcb_input_list_input_devices_reply_t *reply = xcb_input_list_input_devices_reply(QX11Info::connection(), cookie, NULL); - if(reply==0){ return devices; } //error - nothing returned - //Use the iterator for going through the reply - //qDebug() << "Create iterator"; - xcb_input_device_info_iterator_t iter = xcb_input_list_input_devices_devices_iterator(reply); - //xcb_str_iterator_t nameiter = xcb_input_list_input_devices_names_iterator(reply); - - //Now step through the reply - while(iter.data != 0 ){ - devices << new LInputDevice(iter.data->device_id, iter.data->device_use); - //qDebug() << "Found Input Device:" << iter.data->device_id; - //qDebug() << " - num_class_info:" << iter.data->num_class_info; - if(iter.rem>0){ xcb_input_device_info_next(&iter); } - else{ break; } - } - //Free the reply (done with it) - ::free(reply); - //return the information - return devices; -} diff --git a/src-qt5/core/libLumina/LInputDevice.h b/src-qt5/core/libLumina/LInputDevice.h deleted file mode 100644 index f7a4713c..00000000 --- a/src-qt5/core/libLumina/LInputDevice.h +++ /dev/null @@ -1,53 +0,0 @@ -//=========================================== -// Lumina-DE source code -// Copyright (c) 2016, Ken Moore -// Available under the 3-clause BSD license -// See the LICENSE file for full details -//=========================================== -// This class governs all the XCB input device interactions -// and provides simpler Qt-based functions for use elsewhere -//=========================================== -#ifndef _LUMINA_XCB_INPUT_DEVICES_H -#define _LUMINA_XCB_INPUT_DEVICES_H - -#include <QList> -#include <QString> -#include <QStringList> -#include <QHash> -#include <QVariant> - -#include <xcb/xproto.h> - -class LInputDevice{ -public: - LInputDevice(unsigned int id, unsigned int type); //don't use this directly - use the "listDevices()" function instead - ~LInputDevice(); - - //Device Information - //QString name(); //Return the name of this device - unsigned int devNumber(); - bool isPointer(); - bool isKeyboard(); - bool isExtension(); - - //Property Management - QStringList listProperties(); - QVariant propertyValue(QString prop); - -private: - unsigned int devID; //device ID number - assigned at class creation - unsigned int devType; //device "use" identifier - assigned at class creation - QHash<QString, xcb_atom_t> devProps; //Known device properties <name, atom> - - void getProperties(); - //QString devName; //device name - use this for cross-session management (id #'s can get changed every session) -}; - -//Static functions for overall management -class LInput{ - public: - static QList<LInputDevice*> listDevices(); //NOTE: Make sure you "free()" all the LInputDevice objects when finished - -}; - -#endif diff --git a/src-qt5/core/libLumina/LInputDevice.pri b/src-qt5/core/libLumina/LInputDevice.pri deleted file mode 100644 index e90728ce..00000000 --- a/src-qt5/core/libLumina/LInputDevice.pri +++ /dev/null @@ -1,13 +0,0 @@ - -QT *= x11extras - -LIBS *= -lc -lxcb -lxcb-xinput - -#LUtils Files -SOURCES *= $${PWD}/LInputDevice.cpp -HEADERS *= $${PWD}/LInputDevice.h - -INCLUDEPATH *= ${PWD} - -#include LUtils and LuminaOS -#include(LUtils.pri) diff --git a/src-qt5/core/libLumina/LuminaX11.cpp b/src-qt5/core/libLumina/LuminaX11.cpp index a8016460..3708af6d 100644 --- a/src-qt5/core/libLumina/LuminaX11.cpp +++ b/src-qt5/core/libLumina/LuminaX11.cpp @@ -1,6 +1,6 @@ //=========================================== // Lumina-DE source code -// Copyright (c) 2014-2016, Ken Moore +// Copyright (c) 2014-2015, Ken Moore // Available under the 3-clause BSD license // See the LICENSE file for full details //=========================================== @@ -1124,7 +1124,6 @@ void LXCB::closeSystemTray(WId trayID){ xcb_destroy_window(QX11Info::connection(), trayID); } - // === SetScreenWorkArea() === /*void LXCB::SetScreenWorkArea(unsigned int screen, QRect rect){ //This is only useful because Fluxbox does not set the _NET_WORKAREA root atom diff --git a/src-qt5/core/libLumina/LuminaX11.h b/src-qt5/core/libLumina/LuminaX11.h index 2c741111..7b6cce3c 100644 --- a/src-qt5/core/libLumina/LuminaX11.h +++ b/src-qt5/core/libLumina/LuminaX11.h @@ -1,6 +1,6 @@ //=========================================== // Lumina-DE source code -// Copyright (c) 2014-2016, Ken Moore +// Copyright (c) 2014-2015, Ken Moore // Available under the 3-clause BSD license // See the LICENSE file for full details //=========================================== @@ -161,6 +161,7 @@ public: WId startSystemTray(int screen = 0); //Startup the system tray (returns window ID for tray) void closeSystemTray(WId); //Close the system tray + //============ // WM Functions (directly changing/reading properties) // - Using these directly may prevent the WM from seeing the change diff --git a/src-qt5/core/lumina-desktop/defaults/luminaDesktop-TrueOS.conf b/src-qt5/core/lumina-desktop/defaults/luminaDesktop-TrueOS.conf index 56ff8b84..9b819e7c 100644 --- a/src-qt5/core/lumina-desktop/defaults/luminaDesktop-TrueOS.conf +++ b/src-qt5/core/lumina-desktop/defaults/luminaDesktop-TrueOS.conf @@ -42,13 +42,6 @@ mime_default_unknown/*=lumina-textedit.desktop mime_default_application/x-shellscript=lumina-textedit.desktop mime_default_application/pdf_ifexists=pc-pdfviewer.desktop mime_default_application/pdf_ifexists=okular.desktop -mime_default_application/zip_ifexists=lumina-archiver.desktop -mime_default_application/x-compressed-tar_ifexists=lumina-archiver.desktop -mime_default_application/x-bzip-compressed-tar_ifexists=lumina-archiver.desktop -mime_default_application/x-lrzip-compressed-tar_ifexists=lumina-archiver.desktop -mime_default_application/x-lzma-compressed-tar_ifexists=lumina-archiver.desktop -mime_default_application/x-xz-compressed-tar_ifexists=lumina-archiver.desktop -mime_default_application/x-tar_ifexists=lumina-archiver.desktop #THEME SETTINGS theme_themefile=Glass #Name of the theme to use (disable for Lumina-Default) diff --git a/src-qt5/core/lumina-desktop/defaults/luminaDesktop.conf b/src-qt5/core/lumina-desktop/defaults/luminaDesktop.conf index 46d00053..4950b1a0 100644 --- a/src-qt5/core/lumina-desktop/defaults/luminaDesktop.conf +++ b/src-qt5/core/lumina-desktop/defaults/luminaDesktop.conf @@ -36,13 +36,13 @@ session_default_email_ifexists=trojita.desktop mime_default_text/*_ifexists=lumina-textedit.desktop mime_default_audio/*_ifexists=vlc.desktop mime_default_video/*_ifexists=vlc.desktop -mime_default_application/zip_ifexists=lumina-archiver.desktop -mime_default_application/x-compressed-tar_ifexists=lumina-archiver.desktop -mime_default_application/x-bzip-compressed-tar_ifexists=lumina-archiver.desktop -mime_default_application/x-lrzip-compressed-tar_ifexists=lumina-archiver.desktop -mime_default_application/x-lzma-compressed-tar_ifexists=lumina-archiver.desktop -mime_default_application/x-xz-compressed-tar_ifexists=lumina-archiver.desktop -mime_default_application/x-tar_ifexists=lumina-archiver.desktop +mime_default_application/zip_ifexists=peazip.desktop +mime_default_application/x-compressed-tar_ifexists=peazip.desktop +mime_default_application/x-bzip-compressed-tar_ifexists=peazip.desktop +mime_default_application/x-lrzip-compressed-tar_ifexists=peazip.desktop +mime_default_application/x-lzma-compressed-tar_ifexists=peazip.desktop +mime_default_application/x-xz-compressed-tar_ifexists=peazip.desktop +mime_default_application/x-tar_ifexists=peazip.desktop mime_default_unknown/*=lumina-textedit.desktop mime_default_application/x-shellscript=lumina-textedit.desktop diff --git a/src-qt5/desktop-utils/lumina-archiver/MainUI.cpp b/src-qt5/desktop-utils/lumina-archiver/MainUI.cpp index 9d41374c..9710045c 100644 --- a/src-qt5/desktop-utils/lumina-archiver/MainUI.cpp +++ b/src-qt5/desktop-utils/lumina-archiver/MainUI.cpp @@ -18,7 +18,7 @@ MainUI::MainUI() : QMainWindow(), ui(new Ui::MainUI){ this->setWindowTitle(tr("Archive Manager")); BACKEND = new Backend(this); connect(BACKEND, SIGNAL(ProcessStarting()), this, SLOT(ProcStarting()) ); - connect(BACKEND, SIGNAL(ProcessFinished(bool, QString)), this, SLOT(ProcFinished(bool, QString)) ); + connect(BACKEND, SIGNAL(ProcessFinished()), this, SLOT(ProcFinished()) ); connect(BACKEND, SIGNAL(ProgressUpdate(int, QString)), this, SLOT(ProcUpdate(int, QString)) ); //Add a spacer between toolbar items @@ -33,18 +33,16 @@ MainUI::MainUI() : QMainWindow(), ui(new Ui::MainUI){ connect(ui->actionAdd_File, SIGNAL(triggered()), this, SLOT(addFiles()) ); connect(ui->actionRemove_File, SIGNAL(triggered()), this, SLOT(remFiles()) ); connect(ui->actionExtract_All, SIGNAL(triggered()), this, SLOT(extractFiles()) ); - connect(ui->actionExtract_Sel, SIGNAL(triggered()), this, SLOT(extractSelection()) ); connect(ui->actionAdd_Dirs, SIGNAL(triggered()), this, SLOT(addDirs()) ); connect(ui->tree_contents, SIGNAL(itemDoubleClicked(QTreeWidgetItem*, int)), this, SLOT(ViewFile(QTreeWidgetItem*)) ); ui->progressBar->setVisible(false); ui->label_progress->setVisible(false); - ui->label_progress_icon->setVisible(false); ui->actionAdd_File->setEnabled(false); ui->actionRemove_File->setEnabled(false); ui->actionExtract_All->setEnabled(false); ui->actionAdd_Dirs->setEnabled(false); loadIcons(); - ui->tree_contents->setHeaderLabels( QStringList() << tr("File") << tr("MimeType") << tr("Size")+" " ); + ui->tree_contents->setHeaderLabels( QStringList() << tr("File") << tr("MimeType") << tr("Size") << tr("Compressed")+" " ); } MainUI::~MainUI(){ @@ -53,11 +51,7 @@ MainUI::~MainUI(){ void MainUI::LoadArguments(QStringList args){ for(int i=0; i<args.length(); i++){ - if(QFile::exists(args[i])){ - ui->label_progress->setText(tr("Opening Archive...")); - BACKEND->loadFile(args[i]); - break; - } + if(QFile::exists(args[i])){ BACKEND->loadFile(args[i]); break;} } } @@ -70,7 +64,6 @@ void MainUI::loadIcons(){ ui->actionAdd_Dirs->setIcon( LXDG::findIcon("archive-insert-directory","") ); ui->actionRemove_File->setIcon( LXDG::findIcon("archive-remove","") ); ui->actionExtract_All->setIcon( LXDG::findIcon("archive-extract","") ); - ui->actionExtract_Sel->setIcon( LXDG::findIcon("archive-extract","") ); } //=================== @@ -79,16 +72,17 @@ void MainUI::loadIcons(){ QTreeWidgetItem* MainUI::findItem(QString path, QTreeWidgetItem *start){ if(start==0){ for(int i=0; i<ui->tree_contents->topLevelItemCount(); i++){ - if(ui->tree_contents->topLevelItem(i)->whatsThis(0) == path){ return ui->tree_contents->topLevelItem(i); } - else if(path.startsWith(ui->tree_contents->topLevelItem(i)->whatsThis(0)+"/")){ return findItem(path, ui->tree_contents->topLevelItem(i)); } + QString itpath = ui->tree_contents->topLevelItem(i)->whatsThis(0); + if(itpath == path){ return ui->tree_contents->topLevelItem(i); } + else if(path.startsWith(itpath+"/")){ return findItem(path, ui->tree_contents->topLevelItem(i)); } } }else{ for(int i=0; i<start->childCount(); i++){ - if(start->child(i)->whatsThis(0) == path){ return start->child(i); } - else if(path.startsWith(start->child(i)->whatsThis(0)+"/")){ return findItem(path, start->child(i)); } + QString itpath = start->child(i)->whatsThis(0); + if(itpath == path){ return start->child(i); } + else if(path.startsWith(itpath+"/")){ return findItem(path, start->child(i)); } } } - //qDebug() << "Could not find item:" << path; return 0; //nothing found } @@ -164,28 +158,24 @@ void MainUI::NewArchive(){ if(QFile::exists(file)){ if( !QFile::remove(file) ){ QMessageBox::warning(this, tr("Error"), QString(tr("Could not overwrite file:"))+"\n"+file); } } - ui->label_progress->setText(""); //just clear it (this action is instant) BACKEND->loadFile(file); } void MainUI::OpenArchive(){ QString file = QFileDialog::getOpenFileName(this, tr("Open Archive"), QDir::homePath(), OpenFileTypes() ); if(file.isEmpty()){ return; } - ui->label_progress->setText(tr("Opening Archive...")); BACKEND->loadFile(file); } void MainUI::addFiles(){ QStringList files = QFileDialog::getOpenFileNames(this, tr("Add to Archive"), QDir::homePath() ); if(files.isEmpty()){ return; } - ui->label_progress->setText(tr("Adding Items...")); BACKEND->startAdd(files); } void MainUI::addDirs(){ QString dirs = QFileDialog::getExistingDirectory(this, tr("Add to Archive"), QDir::homePath() ); if(dirs.isEmpty()){ return; } - ui->label_progress->setText(tr("Adding Items...")); BACKEND->startAdd(QStringList() << dirs); } @@ -196,57 +186,35 @@ void MainUI::remFiles(){ items << sel[i]->whatsThis(0); } items.removeDuplicates(); - ui->label_progress->setText(tr("Removing Items...")); BACKEND->startRemove(items); } void MainUI::extractFiles(){ QString dir = QFileDialog::getExistingDirectory(this, tr("Extract Into Directory"), QDir::homePath() ); if(dir.isEmpty()){ return; } - ui->label_progress->setText(tr("Extracting...")); BACKEND->startExtract(dir, true); } -void MainUI::extractSelection(){ - if(ui->tree_contents->currentItem()==0){ return; } - QString sel = ui->tree_contents->currentItem()->whatsThis(0); - QString dir = QFileDialog::getExistingDirectory(this, tr("Extract Into Directory"), QDir::homePath() ); - if(dir.isEmpty()){ return; } - ui->label_progress->setText(tr("Extracting...")); - BACKEND->startExtract(dir, true, sel); -} - void MainUI::ViewFile(QTreeWidgetItem *it){ if(it->childCount()>0){ return; } //directory - not viewable - ui->label_progress->setText(tr("Extracting...")); BACKEND->startViewFile(it->whatsThis(0)); } void MainUI::UpdateTree(){ - this->setEnabled(false); - ui->tree_contents->setHeaderLabels( QStringList() << tr("File") << tr("MimeType") << tr("Size")+" " ); + ui->tree_contents->setHeaderLabels( QStringList() << tr("File") << tr("MimeType") << tr("Size") << tr("Compressed")+" " ); QStringList files = BACKEND->heirarchy(); files.sort(); //Remove any entries for file no longer in the archive bool changed = cleanItems(files); - //qDebug() << "Found Files:" << files; + qDebug() << "Found Files:" << files; for(int i=0; i<files.length(); i++){ if(0 != findItem(files[i]) ){ continue; } //already in the tree widget QString mime = LXDG::findAppMimeForFile(files[i].section("/",-1), false); //first match only - QTreeWidgetItem *it = new QTreeWidgetItem(); - it->setText(0, files[i].section("/",-1) ); - if(!BACKEND->isLink(files[i])){ - it->setText(1, LXDG::findAppMimeForFile(files[i].section("/",-1), false) ); - it->setText(2, LUtils::BytesToDisplaySize( BACKEND->size(files[i])) ); - }else{ - it->setText(1, QString(tr("Link To: %1")).arg(BACKEND->linkTo(files[i]) ) ); - } + QTreeWidgetItem *it = new QTreeWidgetItem( QStringList() << files[i].section("/",-1) << mime << LUtils::BytesToDisplaySize( BACKEND->size(files[i])) << LUtils::BytesToDisplaySize(BACKEND->csize(files[i])) ); it->setWhatsThis(0, files[i]); if(BACKEND->isDir(files[i])){ it->setIcon(0, LXDG::findIcon("folder","")); it->setText(1,""); //clear the mimetype - }else if(BACKEND->isLink(files[i])){ - it->setIcon(0, LXDG::findIcon("emblem-symbolic-link","") ); }else{ it->setIcon(0, LXDG::findMimeIcon(files[i].section("/",-1)) ); } @@ -258,23 +226,14 @@ void MainUI::UpdateTree(){ else{ parent->addChild(it); } }else{ ui->tree_contents->addTopLevelItem(it); - QApplication::processEvents(); } changed = true; } - + int wid = 0; if(changed){ - int wid = ui->tree_contents->fontMetrics().width("W")*5; - ui->tree_contents->setColumnWidth(2, wid); - for(int i=1; i<2; i++){ui->tree_contents->resizeColumnToContents(i); QApplication::processEvents(); wid+= ui->tree_contents->columnWidth(i); } - //qDebug() << "Set column 0 width:" << wid << ui->tree_contents->viewport()->width(); + for(int i=3; i>0; i--){ui->tree_contents->resizeColumnToContents(i); wid+= ui->tree_contents->columnWidth(i); } ui->tree_contents->setColumnWidth(0, ui->tree_contents->viewport()->width()-wid); } - ui->tree_contents->sortItems(0, Qt::AscendingOrder); //sort by name - ui->tree_contents->sortItems(1,Qt::AscendingOrder); //sort by mimetype (put dirs first - still organized by name) - - this->setEnabled(true); - ui->tree_contents->setEnabled(true); } //Backend Handling @@ -282,22 +241,17 @@ void MainUI::ProcStarting(){ ui->progressBar->setRange(0,0); ui->progressBar->setValue(0); ui->progressBar->setVisible(true); - ui->label_progress->setVisible(!ui->label_progress->text().isEmpty()); - ui->label_progress_icon->setVisible(false); + ui->label_progress->setVisible(true); ui->tree_contents->setEnabled(false); ui->label_archive->setText(BACKEND->currentFile()); } -void MainUI::ProcFinished(bool success, QString msg){ - UpdateTree(); +void MainUI::ProcFinished(){ ui->progressBar->setRange(0,0); ui->progressBar->setValue(0); ui->progressBar->setVisible(false); - ui->label_progress->setText(msg); - ui->label_progress->setVisible(!msg.isEmpty()); - ui->label_progress_icon->setVisible(!msg.isEmpty()); - if(success){ ui->label_progress_icon->setPixmap( LXDG::findIcon("task-complete","").pixmap(32,32) );} - else{ ui->label_progress_icon->setPixmap( LXDG::findIcon("task-attention","").pixmap(32,32) );} + ui->label_progress->setVisible(false); + ui->tree_contents->setEnabled(true); if(ui->label_archive->text()!=BACKEND->currentFile()){ ui->label_archive->setText(BACKEND->currentFile()); this->setWindowTitle(BACKEND->currentFile().section("/",-1)); @@ -311,6 +265,7 @@ void MainUI::ProcFinished(bool success, QString msg){ ui->actionRemove_File->setEnabled(canmodify && info.exists()); ui->actionExtract_All->setEnabled(info.exists()); ui->actionAdd_Dirs->setEnabled(canmodify); + UpdateTree(); } void MainUI::ProcUpdate(int percent, QString txt){ diff --git a/src-qt5/desktop-utils/lumina-archiver/MainUI.h b/src-qt5/desktop-utils/lumina-archiver/MainUI.h index bb462a7d..09207aa3 100644 --- a/src-qt5/desktop-utils/lumina-archiver/MainUI.h +++ b/src-qt5/desktop-utils/lumina-archiver/MainUI.h @@ -44,14 +44,13 @@ private slots: void addDirs(); void remFiles(); void extractFiles(); - void extractSelection(); void ViewFile(QTreeWidgetItem *it); void UpdateTree(); //Backend Handling void ProcStarting(); - void ProcFinished(bool, QString); + void ProcFinished(); void ProcUpdate(int percent, QString txt); }; diff --git a/src-qt5/desktop-utils/lumina-archiver/MainUI.ui b/src-qt5/desktop-utils/lumina-archiver/MainUI.ui index 1aff2e4f..8c2b2836 100644 --- a/src-qt5/desktop-utils/lumina-archiver/MainUI.ui +++ b/src-qt5/desktop-utils/lumina-archiver/MainUI.ui @@ -56,31 +56,6 @@ </item> <item> <layout class="QHBoxLayout" name="horizontalLayout_2"> - <item> - <widget class="QLabel" name="label_progress_icon"> - <property name="sizePolicy"> - <sizepolicy hsizetype="Fixed" vsizetype="Fixed"> - <horstretch>0</horstretch> - <verstretch>0</verstretch> - </sizepolicy> - </property> - <property name="minimumSize"> - <size> - <width>32</width> - <height>32</height> - </size> - </property> - <property name="maximumSize"> - <size> - <width>32</width> - <height>32</height> - </size> - </property> - <property name="text"> - <string notr="true"/> - </property> - </widget> - </item> <item> <widget class="QProgressBar" name="progressBar"> <property name="value"> @@ -93,9 +68,6 @@ <property name="text"> <string notr="true"/> </property> - <property name="alignment"> - <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set> - </property> </widget> </item> </layout> @@ -129,7 +101,6 @@ <addaction name="actionRemove_File"/> <addaction name="separator"/> <addaction name="actionExtract_All"/> - <addaction name="actionExtract_Sel"/> </widget> <addaction name="menuFile"/> <addaction name="menuEdit"/> @@ -212,11 +183,6 @@ <string>Add directory to archive</string> </property> </action> - <action name="actionExtract_Sel"> - <property name="text"> - <string>Extract Selection</string> - </property> - </action> </widget> <resources/> <connections/> diff --git a/src-qt5/desktop-utils/lumina-archiver/TarBackend.cpp b/src-qt5/desktop-utils/lumina-archiver/TarBackend.cpp index 919a6813..4dee247b 100644 --- a/src-qt5/desktop-utils/lumina-archiver/TarBackend.cpp +++ b/src-qt5/desktop-utils/lumina-archiver/TarBackend.cpp @@ -32,7 +32,7 @@ void Backend::loadFile(QString path){ flags.clear(); flags << "-f" << filepath; //add the actual archive path if(QFile::exists(path)){ startList(); } - else{ contents.clear(); emit ProcessFinished(true, ""); } + else{ contents.clear(); emit ProcessFinished(); } } bool Backend::canModify(){ @@ -75,16 +75,6 @@ bool Backend::isDir(QString file){ return contents.value(file)[0].startsWith("d"); } -bool Backend::isLink(QString file){ - if(!contents.contains(file)){ return false; } - return contents.value(file)[0].startsWith("l"); -} - -QString Backend::linkTo(QString file){ - if(!contents.contains(file)){ return ""; } - return contents.value(file)[2]; -} - //Modification routines void Backend::startAdd(QStringList paths){ //NOTE: All the "paths" have to have the same parent directory @@ -125,13 +115,11 @@ void Backend::startRemove(QStringList paths){ PROC.start("tar", args); } -void Backend::startExtract(QString path, bool overwrite, QString file){ +void Backend::startExtract(QString path, bool overwrite){ QStringList args; args << "-x"; if(!overwrite){ args << "-k"; } - args << flags; - if(!file.isEmpty()){ args << "--include" << file << "--strip-components" << QString::number(file.count("/")); } - args << "-C" << path; + args << flags << "-C" << path; STARTING=true; //qDebug() << "Starting command:" << "tar" << args; PROC.start("tar", args); @@ -163,23 +151,14 @@ void Backend::parseLines(QStringList lines){ QString file = info[1]; QString perms = ""; if(file.endsWith("/")){ perms = "d"; file.chop(1); } - contents.insert(file, QStringList() << perms << "-1" <<""); //Save the [perms, size, linkto ] + contents.insert(file, QStringList() << perms << "-1" ); //Save the [perms, size ] } else if(info.length()<9){ continue; } //invalid line //TAR Archive parsing while(info.length()>9){ info[8] = info[8]+" "+info[9]; info.removeAt(9); } //Filename has spaces in it QString file = info[8]; if(file.endsWith("/")){ file.chop(1); } - QString linkto; - //See if this file has the "link to" or "->" notation - if(file.contains(" -> ")){ linkto = file.section(" -> ",1,-1); file = file.section(" -> ",0,0); } - else if(file.contains(" link to ")){ - //Special case - alternate form of a link within a tar archive (not reflected in perms) - linkto = file.section(" link to ",1,-1); - file = file.section(" link to ",0,0); - if(info[0].startsWith("-")){ info[0].replace(0,1,"l"); } - } - contents.insert(file, QStringList() << info[0] << info[4] << linkto); //Save the [perms, size, linkto ] + contents.insert(file, QStringList() << info[0] << info[4] ); //Save the [perms, size ] } } @@ -195,19 +174,17 @@ void Backend::startList(){ // PRIVATE SLOTS //=============== void Backend::procFinished(int retcode, QProcess::ExitStatus){ - static QString result; processData(); - //qDebug() << "Process Finished:" << PROC.arguments() << retcode; + qDebug() << "Process Finished:" << PROC.arguments() << retcode; LIST = STARTING = false; if(PROC.arguments().contains("-tv")){ if(retcode!=0){ contents.clear(); } //could not read archive - emit ProcessFinished(true,result); - result.clear(); + emit ProcessFinished(); }else{ bool needupdate = true; QStringList args = PROC.arguments(); if(args.contains("-x") && retcode==0){ - needupdate=false; + needupdate=false; if(args.contains("--include")){ //Need to find the full path to the extracted file QString path = args.last() +"/"+ args[ args.indexOf("--include")+1].section("/",-1); @@ -224,10 +201,8 @@ void Backend::procFinished(int retcode, QProcess::ExitStatus){ QFile::remove(tmpfilepath); } } - if(args.contains("-x")){ result = tr("Extraction Finished"); } - else if(args.contains("-c")){ result = tr("Modification Finished"); } if(needupdate){ startList(); } - else{ emit ProcessFinished(retcode==0, result); result.clear(); } + else{ emit ProcessFinished(); } } } @@ -238,9 +213,7 @@ void Backend::processData(){ if(read.endsWith("\n")){ data.clear(); } else{ data = read.section("\n",-1); read = read.section("\n",0,-2); } QStringList lines = read.split("\n",QString::SkipEmptyParts); - QString info; if(LIST){ parseLines(lines); } - else if(!lines.isEmpty()){ info = lines.last(); } //qDebug() << lines; - emit ProgressUpdate(-1, info); + emit ProgressUpdate(-1, ""); } diff --git a/src-qt5/desktop-utils/lumina-archiver/TarBackend.h b/src-qt5/desktop-utils/lumina-archiver/TarBackend.h index 47bc0bb6..f12aae63 100644 --- a/src-qt5/desktop-utils/lumina-archiver/TarBackend.h +++ b/src-qt5/desktop-utils/lumina-archiver/TarBackend.h @@ -29,17 +29,14 @@ public: double size(QString file); double csize(QString file); bool isDir(QString file); - bool isLink(QString file); - QString linkTo(QString file); //Modification routines void startAdd(QStringList paths); void startRemove(QStringList paths); - void startExtract(QString path, bool overwrite, QString file=""); //path to dir, overwrite, optional file to extract (everything otherwise) + void startExtract(QString path, bool overwrite); //path to dir void startViewFile(QString path); - //Special process public slots: private: @@ -61,7 +58,7 @@ signals: void FileLoaded(); void ProcessStarting(); void ProgressUpdate(int, QString); //percentage, text - void ProcessFinished(bool, QString); //success, text + void ProcessFinished(); }; #endif diff --git a/src-qt5/desktop-utils/lumina-archiver/isoDialog.ui b/src-qt5/desktop-utils/lumina-archiver/isoDialog.ui deleted file mode 100644 index 99ba31fb..00000000 --- a/src-qt5/desktop-utils/lumina-archiver/isoDialog.ui +++ /dev/null @@ -1,151 +0,0 @@ -<?xml version="1.0" encoding="UTF-8"?> -<ui version="4.0"> - <class>isoDialog</class> - <widget class="QDialog" name="isoDialog"> - <property name="geometry"> - <rect> - <x>0</x> - <y>0</y> - <width>305</width> - <height>179</height> - </rect> - </property> - <property name="windowTitle"> - <string>Burn ISO/IMG to device</string> - </property> - <layout class="QFormLayout" name="formLayout"> - <item row="0" column="0" colspan="2"> - <widget class="QLabel" name="label_iso"> - <property name="font"> - <font> - <weight>75</weight> - <bold>true</bold> - </font> - </property> - <property name="text"> - <string>TextLabel</string> - </property> - <property name="alignment"> - <set>Qt::AlignCenter</set> - </property> - </widget> - </item> - <item row="1" column="0"> - <widget class="QLabel" name="label"> - <property name="sizePolicy"> - <sizepolicy hsizetype="Expanding" vsizetype="Preferred"> - <horstretch>0</horstretch> - <verstretch>0</verstretch> - </sizepolicy> - </property> - <property name="text"> - <string>Transfer Rate</string> - </property> - </widget> - </item> - <item row="1" column="1"> - <layout class="QHBoxLayout" name="horizontalLayout"> - <item> - <widget class="QSpinBox" name="spin_rate_num"> - <property name="sizePolicy"> - <sizepolicy hsizetype="Preferred" vsizetype="Fixed"> - <horstretch>0</horstretch> - <verstretch>0</verstretch> - </sizepolicy> - </property> - <property name="minimum"> - <number>1</number> - </property> - <property name="maximum"> - <number>1023</number> - </property> - </widget> - </item> - <item> - <widget class="QComboBox" name="combo_rate_units"/> - </item> - </layout> - </item> - <item row="2" column="0"> - <widget class="QLabel" name="label_3"> - <property name="text"> - <string>USB Device</string> - </property> - </widget> - </item> - <item row="3" column="0" colspan="2"> - <widget class="QCheckBox" name="check_sync"> - <property name="text"> - <string>Wipe all extra space on device (conv = sync)</string> - </property> - <property name="checked"> - <bool>true</bool> - </property> - </widget> - </item> - <item row="2" column="1"> - <layout class="QHBoxLayout" name="horizontalLayout_2"> - <item> - <widget class="QComboBox" name="combo_devices"/> - </item> - <item> - <widget class="QToolButton" name="tool_refresh"> - <property name="toolTip"> - <string>Refresh Device List</string> - </property> - <property name="text"> - <string notr="true"/> - </property> - </widget> - </item> - </layout> - </item> - <item row="4" column="0"> - <spacer name="verticalSpacer"> - <property name="orientation"> - <enum>Qt::Vertical</enum> - </property> - <property name="sizeHint" stdset="0"> - <size> - <width>20</width> - <height>40</height> - </size> - </property> - </spacer> - </item> - <item row="5" column="0" colspan="2"> - <layout class="QHBoxLayout" name="horizontalLayout_3"> - <item> - <spacer name="horizontalSpacer"> - <property name="orientation"> - <enum>Qt::Horizontal</enum> - </property> - <property name="sizeHint" stdset="0"> - <size> - <width>40</width> - <height>20</height> - </size> - </property> - </spacer> - </item> - <item> - <widget class="QPushButton" name="push_cancel"> - <property name="text"> - <string>Cancel</string> - </property> - </widget> - </item> - <item> - <widget class="QPushButton" name="push_start"> - <property name="text"> - <string>Start</string> - </property> - </widget> - </item> - </layout> - </item> - </layout> - </widget> - <resources/> - <connections/> -</ui> -- cgit From 876173714461d6f9d104636d90e648c9f7009505 Mon Sep 17 00:00:00 2001 From: q5sys <jt@obs-sec.com> Date: Sun, 20 Nov 2016 01:56:04 -0500 Subject: comment out changes made to wrong repo, until method can be fixed --- src-qt5/core-utils/lumina-config/mainWindow.cpp | 6 +----- src-qt5/core-utils/lumina-config/pages/page_main.cpp | 6 +++--- src-qt5/core-utils/lumina-config/pages/page_main.h | 2 +- 3 files changed, 5 insertions(+), 9 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/core-utils/lumina-config/mainWindow.cpp b/src-qt5/core-utils/lumina-config/mainWindow.cpp index ecaf2990..de49f22b 100644 --- a/src-qt5/core-utils/lumina-config/mainWindow.cpp +++ b/src-qt5/core-utils/lumina-config/mainWindow.cpp @@ -9,7 +9,6 @@ #include "globals.h" #include "pages/getPage.h" -#include "pages/page_main.h" //============= // PUBLIC @@ -134,10 +133,7 @@ void mainWindow::on_actionSave_triggered(){ } void mainWindow::on_actionBack_triggered(){ - if(cpage.isEmpty()){ page_main::clearlineEdit(); } //since ESC doesnt close any other Lumina Appliction by default, I've -commented this out for -the -time being. + if(cpage.isEmpty()){ /* page_main::clearlineEdit(); */ } //since ESC doesnt close any other Lumina Appliction by default, I've commented this out for the time being. else{ page_change(""); } //Use the interactive wrapper (check for save state, etc). } diff --git a/src-qt5/core-utils/lumina-config/pages/page_main.cpp b/src-qt5/core-utils/lumina-config/pages/page_main.cpp index e60606f3..22d00d27 100644 --- a/src-qt5/core-utils/lumina-config/pages/page_main.cpp +++ b/src-qt5/core-utils/lumina-config/pages/page_main.cpp @@ -121,9 +121,9 @@ void page_main::SaveSettings(){ } -void page_main::clearlineEdit(){ - ui->lineEdit->clear(); -} +//void page_main::clearlineEdit(){ +// ui->lineEdit->clear(); +//} void page_main::LoadSettings(int){ diff --git a/src-qt5/core-utils/lumina-config/pages/page_main.h b/src-qt5/core-utils/lumina-config/pages/page_main.h index 095815e9..a41f0753 100644 --- a/src-qt5/core-utils/lumina-config/pages/page_main.h +++ b/src-qt5/core-utils/lumina-config/pages/page_main.h @@ -20,7 +20,7 @@ public: ~page_main(); virtual void setPreviousPage(QString id); - void clearlineEdit(); +// void clearlineEdit(); public slots: void SaveSettings(); -- cgit From 0bf0b86dc0a509a6fb432bac0d1d89d838f655a6 Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Sun, 20 Nov 2016 13:21:49 -0500 Subject: Revert "comment out changes made to wrong repo, until method can be fixed" This reverts commit 876173714461d6f9d104636d90e648c9f7009505. --- src-qt5/core-utils/lumina-config/mainWindow.cpp | 6 +++++- src-qt5/core-utils/lumina-config/pages/page_main.cpp | 6 +++--- src-qt5/core-utils/lumina-config/pages/page_main.h | 2 +- 3 files changed, 9 insertions(+), 5 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/core-utils/lumina-config/mainWindow.cpp b/src-qt5/core-utils/lumina-config/mainWindow.cpp index de49f22b..ecaf2990 100644 --- a/src-qt5/core-utils/lumina-config/mainWindow.cpp +++ b/src-qt5/core-utils/lumina-config/mainWindow.cpp @@ -9,6 +9,7 @@ #include "globals.h" #include "pages/getPage.h" +#include "pages/page_main.h" //============= // PUBLIC @@ -133,7 +134,10 @@ void mainWindow::on_actionSave_triggered(){ } void mainWindow::on_actionBack_triggered(){ - if(cpage.isEmpty()){ /* page_main::clearlineEdit(); */ } //since ESC doesnt close any other Lumina Appliction by default, I've commented this out for the time being. + if(cpage.isEmpty()){ page_main::clearlineEdit(); } //since ESC doesnt close any other Lumina Appliction by default, I've +commented this out for +the +time being. else{ page_change(""); } //Use the interactive wrapper (check for save state, etc). } diff --git a/src-qt5/core-utils/lumina-config/pages/page_main.cpp b/src-qt5/core-utils/lumina-config/pages/page_main.cpp index 22d00d27..e60606f3 100644 --- a/src-qt5/core-utils/lumina-config/pages/page_main.cpp +++ b/src-qt5/core-utils/lumina-config/pages/page_main.cpp @@ -121,9 +121,9 @@ void page_main::SaveSettings(){ } -//void page_main::clearlineEdit(){ -// ui->lineEdit->clear(); -//} +void page_main::clearlineEdit(){ + ui->lineEdit->clear(); +} void page_main::LoadSettings(int){ diff --git a/src-qt5/core-utils/lumina-config/pages/page_main.h b/src-qt5/core-utils/lumina-config/pages/page_main.h index a41f0753..095815e9 100644 --- a/src-qt5/core-utils/lumina-config/pages/page_main.h +++ b/src-qt5/core-utils/lumina-config/pages/page_main.h @@ -20,7 +20,7 @@ public: ~page_main(); virtual void setPreviousPage(QString id); -// void clearlineEdit(); + void clearlineEdit(); public slots: void SaveSettings(); -- cgit From c79aa5623796f62aa67b2c37367e28710b0f05d2 Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Sun, 20 Nov 2016 13:22:08 -0500 Subject: Revert "Revert "search clear function on ESC press"" This reverts commit 151062b99e29e18dbc614bf66582f908c864a96a. --- src-qt5/core-utils/lumina-config/LPlugins.cpp | 9 +- src-qt5/core-utils/lumina-config/PanelWidget.cpp | 36 ++- src-qt5/core-utils/lumina-config/globals.h | 2 + src-qt5/core-utils/lumina-config/lumina-config.pro | 1 + src-qt5/core-utils/lumina-config/pages/getPage.h | 4 +- .../lumina-config/pages/page_compton.cpp | 2 + .../core-utils/lumina-config/pages/page_compton.ui | 7 + .../lumina-config/pages/page_defaultapps.ui | 256 ++++++++++----------- .../core-utils/lumina-config/pages/page_mouse.cpp | 77 +++++++ .../core-utils/lumina-config/pages/page_mouse.h | 36 +++ .../core-utils/lumina-config/pages/page_mouse.ui | 58 +++++ .../lumina-config/pages/page_session_options.cpp | 12 + .../lumina-config/pages/page_session_options.ui | 7 + src-qt5/core-utils/lumina-config/pages/pages.pri | 9 +- src-qt5/core/libLumina/LInputDevice.cpp | 112 +++++++++ src-qt5/core/libLumina/LInputDevice.h | 53 +++++ src-qt5/core/libLumina/LInputDevice.pri | 13 ++ src-qt5/core/libLumina/LuminaX11.cpp | 3 +- src-qt5/core/libLumina/LuminaX11.h | 3 +- .../defaults/luminaDesktop-TrueOS.conf | 7 + .../lumina-desktop/defaults/luminaDesktop.conf | 14 +- src-qt5/desktop-utils/lumina-archiver/MainUI.cpp | 83 +++++-- src-qt5/desktop-utils/lumina-archiver/MainUI.h | 3 +- src-qt5/desktop-utils/lumina-archiver/MainUI.ui | 34 +++ .../desktop-utils/lumina-archiver/TarBackend.cpp | 47 +++- src-qt5/desktop-utils/lumina-archiver/TarBackend.h | 7 +- src-qt5/desktop-utils/lumina-archiver/isoDialog.ui | 151 ++++++++++++ 27 files changed, 865 insertions(+), 181 deletions(-) create mode 100644 src-qt5/core-utils/lumina-config/pages/page_mouse.cpp create mode 100644 src-qt5/core-utils/lumina-config/pages/page_mouse.h create mode 100644 src-qt5/core-utils/lumina-config/pages/page_mouse.ui create mode 100644 src-qt5/core/libLumina/LInputDevice.cpp create mode 100644 src-qt5/core/libLumina/LInputDevice.h create mode 100644 src-qt5/core/libLumina/LInputDevice.pri create mode 100644 src-qt5/desktop-utils/lumina-archiver/isoDialog.ui (limited to 'src-qt5') diff --git a/src-qt5/core-utils/lumina-config/LPlugins.cpp b/src-qt5/core-utils/lumina-config/LPlugins.cpp index 089a181c..dfd490e6 100644 --- a/src-qt5/core-utils/lumina-config/LPlugins.cpp +++ b/src-qt5/core-utils/lumina-config/LPlugins.cpp @@ -173,6 +173,13 @@ void LPlugins::LoadPanelPlugins(){ info.ID = "audioplayer"; info.icon = "media-playback-start"; PANEL.insert(info.ID, info); + //JSON Menu Scripts + info = LPI(); //clear it + info.name = QObject::tr("Menu Script"); + info.description = QObject::tr("Run an external script to generate a user defined menu"); + info.ID = "jsonmenu"; + info.icon = "text-x-script"; + PANEL.insert(info.ID, info); } // DESKTOP PLUGINS @@ -293,7 +300,7 @@ void LPlugins::LoadMenuPlugins(){ info.ID = "app"; info.icon = "application-x-desktop"; MENU.insert(info.ID, info); - //Custom Apps + //JSON Menu Scripts info = LPI(); //clear it info.name = QObject::tr("Menu Script"); info.description = QObject::tr("Run an external script to generate a user defined menu"); diff --git a/src-qt5/core-utils/lumina-config/PanelWidget.cpp b/src-qt5/core-utils/lumina-config/PanelWidget.cpp index aff7bda3..d5d3d9bd 100644 --- a/src-qt5/core-utils/lumina-config/PanelWidget.cpp +++ b/src-qt5/core-utils/lumina-config/PanelWidget.cpp @@ -9,7 +9,7 @@ #include "GetPluginDialog.h" #include "AppDialog.h" - +#include "ScriptDialog.h" PanelWidget::PanelWidget(QWidget *parent, QWidget *Main, LPlugins *Pinfo) : QWidget(parent), ui(new Ui::PanelWidget){ ui->setupUi(this); @@ -66,6 +66,18 @@ void PanelWidget::LoadSettings(QSettings *settings, int Dnum, int Pnum){ it->setWhatsThis(plugs[i]); //make sure to preserve the entire plugin ID (is the unique version) ui->list_plugins->addItem(it); } + + }else if(pid.startsWith("jsonmenu")){ + LPI info = PINFO->panelPluginInfo( plugs[i].section("::::",0,0) ); + if(info.ID.isEmpty()){ continue; } //invalid plugin type (no longer available?) + QString exec = plugs[i].section("::::",1,1); + QListWidgetItem *item = new QListWidgetItem(); + item->setWhatsThis( plugs[i] ); + item->setIcon( LXDG::findIcon(plugs[i].section("::::",3,3),info.icon) ); + item->setText( plugs[i].section("::::",2,2) +" ("+info.name+")" ); + item->setToolTip( info.description ); + ui->list_plugins->addItem(item); + }else{ LPI info = PINFO->panelPluginInfo(pid); if(!info.ID.isEmpty()){ @@ -180,23 +192,35 @@ void PanelWidget::on_tool_addplugin_clicked(){ dlg.exec(); if(!dlg.selected){ return; } //cancelled QString pan = dlg.plugID; //getNewPanelPlugin(); + QListWidgetItem *it = 0; if(pan == "applauncher"){ //Prompt for the application to add QString app =getSysApp(); if(app.isEmpty()){ return; } //cancelled pan.append("::"+app); XDGDesktop desk(app); - QListWidgetItem *it = new QListWidgetItem( LXDG::findIcon(desk.icon,""), desk.name); + it = new QListWidgetItem( LXDG::findIcon(desk.icon,""), desk.name); it->setWhatsThis(pan); - ui->list_plugins->addItem(it); - ui->list_plugins->setCurrentItem(it); - ui->list_plugins->scrollToItem(it); + + }else if(pan=="jsonmenu"){ + //Need to prompt for the script file, name, and icon to use + //new ID format: "jsonmenu"::::<exec to run>::::<name>::::<icon> + ScriptDialog SD(this); + SD.exec(); + if(!SD.isValid()){ return; } + LPI info = PINFO->panelPluginInfo(pan); + it = new QListWidgetItem( LXDG::findIcon(SD.icon(),"text-x-script"), SD.name()+" ("+info.ID+")" ); + it->setWhatsThis(info.ID+"::::"+SD.command()+"::::"+SD.name()+"::::"+SD.icon()); + it->setToolTip( info.description ); }else{ if(pan.isEmpty()){ return; } //nothing selected //Add the new plugin to the list LPI info = PINFO->panelPluginInfo(pan); - QListWidgetItem *it = new QListWidgetItem( LXDG::findIcon(info.icon,""), info.name); + it = new QListWidgetItem( LXDG::findIcon(info.icon,""), info.name); it->setWhatsThis(info.ID); + } + //Now add the new item to the list + if(it!=0){ ui->list_plugins->addItem(it); ui->list_plugins->setCurrentItem(it); ui->list_plugins->scrollToItem(it); diff --git a/src-qt5/core-utils/lumina-config/globals.h b/src-qt5/core-utils/lumina-config/globals.h index 0f94785c..ed7549aa 100644 --- a/src-qt5/core-utils/lumina-config/globals.h +++ b/src-qt5/core-utils/lumina-config/globals.h @@ -35,6 +35,8 @@ #include <LuminaOS.h> #include <LuminaThemes.h> +#include "pages/PageWidget.h" + #endif //Now the global class for available system applications diff --git a/src-qt5/core-utils/lumina-config/lumina-config.pro b/src-qt5/core-utils/lumina-config/lumina-config.pro index fe5494de..57531e69 100644 --- a/src-qt5/core-utils/lumina-config/lumina-config.pro +++ b/src-qt5/core-utils/lumina-config/lumina-config.pro @@ -15,6 +15,7 @@ include(../../core/libLumina/LDesktopUtils.pri) #includes LUtils include(../../core/libLumina/LuminaXDG.pri) include(../../core/libLumina/LuminaSingleApplication.pri) include(../../core/libLumina/LuminaThemes.pri) +include(../../core/libLumina/LInputDevice.pri) SOURCES += main.cpp \ mainWindow.cpp \ diff --git a/src-qt5/core-utils/lumina-config/pages/getPage.h b/src-qt5/core-utils/lumina-config/pages/getPage.h index fba3998b..ea0cfb00 100644 --- a/src-qt5/core-utils/lumina-config/pages/getPage.h +++ b/src-qt5/core-utils/lumina-config/pages/getPage.h @@ -38,7 +38,7 @@ static QList<PAGEINFO> KnownPages(){ list << PageInfo("interface-menu", QObject::tr("Menu"), QObject::tr("Menu Plugins"), "preferences-plugin",QObject::tr("Change what options are shown on the desktop context menu"), "interface", QStringList(), QStringList() << "desktop" << "menu" << "plugins" << "shortcuts"); list << PageInfo("session-locale", QObject::tr("Localization"), QObject::tr("Locale Settings"), "preferences-desktop-locale",QObject::tr("Change the default locale settings for this user"), "user", QStringList(), QStringList() << "user"<<"locale"<<"language"<<"translations"); list << PageInfo("session-options", QObject::tr("General Options"), QObject::tr("User Settings"), "configure",QObject::tr("Change basic user settings such as time/date formats"), "user", QStringList(), QStringList() << "user"<<"settings"<<"time"<<"date"<<"icon"<<"reset"<<"numlock"<<"clock"); - + //list << PageInfo("mouse", QObject::tr("Mouse Settings"), QObject::tr("Mouse Settings"), "input-mouse",QObject::tr("Adjust mouse settings"), "user", QStringList(), QStringList() << "user"<<"speed"<<"accel"<<"mouse"); //Now sort the items according to the translated name QStringList names; for(int i=0; i<list.length(); i++){ names << list[i].name; } @@ -66,6 +66,7 @@ static QList<PAGEINFO> KnownPages(){ #include "page_session_locale.h" #include "page_session_options.h" #include "page_compton.h" +#include "page_mouse.h" static PageWidget* GetNewPage(QString id, QWidget *parent){ //Find the page that matches this "id" @@ -82,6 +83,7 @@ static PageWidget* GetNewPage(QString id, QWidget *parent){ else if(id=="session-locale"){ page = new page_session_locale(parent); } else if(id=="session-options"){ page = new page_session_options(parent); } else if(id=="compton"){ page = new page_compton(parent); } + else if(id=="mouse"){ page = new page_mouse(parent); } //Return the main control_panel page as the fallback/default if(page==0){ id.clear(); page = new page_main(parent); } page->setWhatsThis(id); diff --git a/src-qt5/core-utils/lumina-config/pages/page_compton.cpp b/src-qt5/core-utils/lumina-config/pages/page_compton.cpp index 5f7cd190..8cdb2ea7 100644 --- a/src-qt5/core-utils/lumina-config/pages/page_compton.cpp +++ b/src-qt5/core-utils/lumina-config/pages/page_compton.cpp @@ -29,6 +29,7 @@ void page_compton::SaveSettings(){ emit HasPendingChanges(false); QSettings settings("lumina-desktop","sessionsettings"); settings.setValue("enableCompositing", !ui->check_disablecompton->isChecked()); + settings.setValue("compositingWithGpuAccelOnly", ui->check_GPUverify->isChecked()); QString set = QString(getenv("XDG_CONFIG_HOME"))+"/lumina-desktop/compton.conf"; LUtils::writeFile(set, ui->text_file->toPlainText().split("\n"),true); } @@ -37,6 +38,7 @@ void page_compton::LoadSettings(int){ emit ChangePageTitle( tr("Compositor Settings") ); QSettings settings("lumina-desktop","sessionsettings"); ui->check_disablecompton->setChecked( !settings.value("enableCompositing", true).toBool() ); + ui->check_GPUverify->setChecked( settings.value("compositingWithGpuAccelOnly", true).toBool() ); QString set = QString(getenv("XDG_CONFIG_HOME"))+"/lumina-desktop/compton.conf"; qDebug() << "Load Compton settings:" << set; ui->text_file->setPlainText( LUtils::readFile(set).join("\n") ); diff --git a/src-qt5/core-utils/lumina-config/pages/page_compton.ui b/src-qt5/core-utils/lumina-config/pages/page_compton.ui index 9083a2fb..857331d6 100644 --- a/src-qt5/core-utils/lumina-config/pages/page_compton.ui +++ b/src-qt5/core-utils/lumina-config/pages/page_compton.ui @@ -33,6 +33,13 @@ </property> </widget> </item> + <item> + <widget class="QCheckBox" name="check_GPUverify"> + <property name="text"> + <string>Only use compositing with GPU acceleration </string> + </property> + </widget> + </item> <item> <widget class="QPlainTextEdit" name="text_file"/> </item> diff --git a/src-qt5/core-utils/lumina-config/pages/page_defaultapps.ui b/src-qt5/core-utils/lumina-config/pages/page_defaultapps.ui index ef72c4f1..8440e198 100644 --- a/src-qt5/core-utils/lumina-config/pages/page_defaultapps.ui +++ b/src-qt5/core-utils/lumina-config/pages/page_defaultapps.ui @@ -29,11 +29,138 @@ <item> <widget class="QTabWidget" name="tabWidget_apps"> <property name="currentIndex"> - <number>1</number> + <number>0</number> </property> <property name="movable"> <bool>false</bool> </property> + <widget class="QWidget" name="tab_auto"> + <attribute name="title"> + <string>Basic Settings</string> + </attribute> + <layout class="QVBoxLayout" name="verticalLayout_7"> + <item> + <layout class="QGridLayout" name="gridLayout_6"> + <item row="0" column="0"> + <layout class="QFormLayout" name="formLayout_10"> + <property name="fieldGrowthPolicy"> + <enum>QFormLayout::ExpandingFieldsGrow</enum> + </property> + <item row="0" column="0"> + <widget class="QLabel" name="label_37"> + <property name="font"> + <font> + <weight>75</weight> + <bold>true</bold> + </font> + </property> + <property name="text"> + <string>Web Browser:</string> + </property> + </widget> + </item> + <item row="0" column="1"> + <widget class="QToolButton" name="tool_default_webbrowser"> + <property name="text"> + <string notr="true">...</string> + </property> + <property name="toolButtonStyle"> + <enum>Qt::ToolButtonTextBesideIcon</enum> + </property> + </widget> + </item> + <item row="1" column="0"> + <widget class="QLabel" name="label_38"> + <property name="font"> + <font> + <weight>75</weight> + <bold>true</bold> + </font> + </property> + <property name="text"> + <string>E-Mail Client:</string> + </property> + </widget> + </item> + <item row="1" column="1"> + <widget class="QToolButton" name="tool_default_email"> + <property name="text"> + <string notr="true">...</string> + </property> + <property name="toolButtonStyle"> + <enum>Qt::ToolButtonTextBesideIcon</enum> + </property> + </widget> + </item> + </layout> + </item> + <item row="0" column="1"> + <layout class="QFormLayout" name="formLayout_11"> + <item row="0" column="0"> + <widget class="QLabel" name="label_39"> + <property name="font"> + <font> + <weight>75</weight> + <bold>true</bold> + </font> + </property> + <property name="text"> + <string>File Manager:</string> + </property> + </widget> + </item> + <item row="1" column="0"> + <widget class="QLabel" name="label_40"> + <property name="font"> + <font> + <weight>75</weight> + <bold>true</bold> + </font> + </property> + <property name="text"> + <string>Virtual Terminal:</string> + </property> + </widget> + </item> + <item row="0" column="1"> + <widget class="QToolButton" name="tool_default_filemanager"> + <property name="text"> + <string>...</string> + </property> + <property name="toolButtonStyle"> + <enum>Qt::ToolButtonTextBesideIcon</enum> + </property> + </widget> + </item> + <item row="1" column="1"> + <widget class="QToolButton" name="tool_default_terminal"> + <property name="text"> + <string>...</string> + </property> + <property name="toolButtonStyle"> + <enum>Qt::ToolButtonTextBesideIcon</enum> + </property> + </widget> + </item> + </layout> + </item> + </layout> + </item> + <item> + <spacer name="verticalSpacer_4"> + <property name="orientation"> + <enum>Qt::Vertical</enum> + </property> + <property name="sizeHint" stdset="0"> + <size> + <width>20</width> + <height>40</height> + </size> + </property> + </spacer> + </item> + </layout> + </widget> <widget class="QWidget" name="tab_defaults"> <attribute name="title"> <string>Advanced</string> @@ -163,133 +290,6 @@ </item> </layout> </widget> - <widget class="QWidget" name="tab_auto"> - <attribute name="title"> - <string>Basic Settings</string> - </attribute> - <layout class="QVBoxLayout" name="verticalLayout_7"> - <item> - <layout class="QGridLayout" name="gridLayout_6"> - <item row="0" column="0"> - <layout class="QFormLayout" name="formLayout_10"> - <property name="fieldGrowthPolicy"> - <enum>QFormLayout::ExpandingFieldsGrow</enum> - </property> - <item row="0" column="0"> - <widget class="QLabel" name="label_37"> - <property name="font"> - <font> - <weight>75</weight> - <bold>true</bold> - </font> - </property> - <property name="text"> - <string>Web Browser:</string> - </property> - </widget> - </item> - <item row="0" column="1"> - <widget class="QToolButton" name="tool_default_webbrowser"> - <property name="text"> - <string notr="true">...</string> - </property> - <property name="toolButtonStyle"> - <enum>Qt::ToolButtonTextBesideIcon</enum> - </property> - </widget> - </item> - <item row="1" column="0"> - <widget class="QLabel" name="label_38"> - <property name="font"> - <font> - <weight>75</weight> - <bold>true</bold> - </font> - </property> - <property name="text"> - <string>E-Mail Client:</string> - </property> - </widget> - </item> - <item row="1" column="1"> - <widget class="QToolButton" name="tool_default_email"> - <property name="text"> - <string notr="true">...</string> - </property> - <property name="toolButtonStyle"> - <enum>Qt::ToolButtonTextBesideIcon</enum> - </property> - </widget> - </item> - </layout> - </item> - <item row="0" column="1"> - <layout class="QFormLayout" name="formLayout_11"> - <item row="0" column="0"> - <widget class="QLabel" name="label_39"> - <property name="font"> - <font> - <weight>75</weight> - <bold>true</bold> - </font> - </property> - <property name="text"> - <string>File Manager:</string> - </property> - </widget> - </item> - <item row="1" column="0"> - <widget class="QLabel" name="label_40"> - <property name="font"> - <font> - <weight>75</weight> - <bold>true</bold> - </font> - </property> - <property name="text"> - <string>Virtual Terminal:</string> - </property> - </widget> - </item> - <item row="0" column="1"> - <widget class="QToolButton" name="tool_default_filemanager"> - <property name="text"> - <string>...</string> - </property> - <property name="toolButtonStyle"> - <enum>Qt::ToolButtonTextBesideIcon</enum> - </property> - </widget> - </item> - <item row="1" column="1"> - <widget class="QToolButton" name="tool_default_terminal"> - <property name="text"> - <string>...</string> - </property> - <property name="toolButtonStyle"> - <enum>Qt::ToolButtonTextBesideIcon</enum> - </property> - </widget> - </item> - </layout> - </item> - </layout> - </item> - <item> - <spacer name="verticalSpacer_4"> - <property name="orientation"> - <enum>Qt::Vertical</enum> - </property> - <property name="sizeHint" stdset="0"> - <size> - <width>20</width> - <height>40</height> - </size> - </property> - </spacer> - </item> - </layout> - </widget> </widget> </item> </layout> diff --git a/src-qt5/core-utils/lumina-config/pages/page_mouse.cpp b/src-qt5/core-utils/lumina-config/pages/page_mouse.cpp new file mode 100644 index 00000000..dbe075d7 --- /dev/null +++ b/src-qt5/core-utils/lumina-config/pages/page_mouse.cpp @@ -0,0 +1,77 @@ +//=========================================== +// Lumina Desktop Source Code +// Copyright (c) 2016, Ken Moore +// Available under the 3-clause BSD license +// See the LICENSE file for full details +//=========================================== +#include "page_mouse.h" +#include "ui_page_mouse.h" +#include "getPage.h" + +//========== +// PUBLIC +//========== +page_mouse::page_mouse(QWidget *parent) : PageWidget(parent), ui(new Ui::page_mouse()){ + ui->setupUi(this); + connect(ui->slider_accel, SIGNAL(valueChanged(int)), this, SLOT(accelChanged(int)) ); + updateIcons(); + qDebug() << "List Devices:"; + QList<LInputDevice*> devices = LInput::listDevices(); + for(int i=0; i<devices.length(); i++){ + if(!devices[i]->isPointer()){ + ::free( devices.takeAt(i)); + i--; + }else{ + qDebug() << "Found Pointer:" << devices[i]->devNumber(); + qDebug() << " - isExtension:" << devices[i]->isExtension(); + qDebug() << " - Properties:" << devices[i]->listProperties(); + } + } +} + +page_mouse::~page_mouse(){ + for(int i=0; i<devices.length(); i++){ ::free(devices[i]); } +} + +//================ +// PUBLIC SLOTS +//================ +void page_mouse::SaveSettings(){ + + emit HasPendingChanges(false); +} + +void page_mouse::LoadSettings(int){ + emit HasPendingChanges(false); + emit ChangePageTitle( tr("Desktop Settings") ); + +} + +void page_mouse::updateIcons(){ + +} + +//================= +// PRIVATE +//================= + +//================= +// PRIVATE SLOTS +//================= +void page_mouse::accelChanged(int val){ + if(val<=4){ + val = 4-val; + ui->label_accel->setText( QString("1/%1").arg(QString::number(val)) ); + QProcess::startDetached("xset mouse 1/"+QString::number(val)); + }else{ + val = val-4; + if(val%2==0){ + val = val/2; + ui->label_accel->setText( QString::number(val) ); + QProcess::startDetached("xset mouse "+QString::number(val)); + }else{ + ui->label_accel->setText( QString::number(val)+"/2" ); + QProcess::startDetached("xset mouse "+QString::number(val)+"/2"); + } + } +} diff --git a/src-qt5/core-utils/lumina-config/pages/page_mouse.h b/src-qt5/core-utils/lumina-config/pages/page_mouse.h new file mode 100644 index 00000000..849917c5 --- /dev/null +++ b/src-qt5/core-utils/lumina-config/pages/page_mouse.h @@ -0,0 +1,36 @@ +//=========================================== +// Lumina Desktop Source Code +// Copyright (c) 2016, Ken Moore +// Available under the 3-clause BSD license +// See the LICENSE file for full details +//=========================================== +#ifndef _LUMINA_CONFIG_PAGE_MOUSE_H +#define _LUMINA_CONFIG_PAGE_MOUSE_H +#include "../globals.h" +#include "PageWidget.h" + +#include <LInputDevice.h> + +namespace Ui{ + class page_mouse; +}; + +class page_mouse : public PageWidget{ + Q_OBJECT +public: + page_mouse(QWidget *parent); + ~page_mouse(); + +public slots: + void SaveSettings(); + void LoadSettings(int screennum); + void updateIcons(); + +private: + Ui::page_mouse *ui; + QList<LInputDevice*> devices; + +private slots: + void accelChanged(int val); +}; +#endif diff --git a/src-qt5/core-utils/lumina-config/pages/page_mouse.ui b/src-qt5/core-utils/lumina-config/pages/page_mouse.ui new file mode 100644 index 00000000..619e38dc --- /dev/null +++ b/src-qt5/core-utils/lumina-config/pages/page_mouse.ui @@ -0,0 +1,58 @@ +<?xml version="1.0" encoding="UTF-8"?> +<ui version="4.0"> + <class>page_mouse</class> + <widget class="QWidget" name="page_mouse"> + <property name="geometry"> + <rect> + <x>0</x> + <y>0</y> + <width>400</width> + <height>300</height> + </rect> + </property> + <property name="windowTitle"> + <string>Form</string> + </property> + <layout class="QFormLayout" name="formLayout"> + <item row="0" column="0"> + <widget class="QLabel" name="label"> + <property name="text"> + <string>Mouse Acceleration</string> + </property> + </widget> + </item> + <item row="0" column="1"> + <layout class="QHBoxLayout" name="horizontalLayout"> + <item> + <widget class="QSlider" name="slider_accel"> + <property name="maximum"> + <number>20</number> + </property> + <property name="value"> + <number>4</number> + </property> + <property name="orientation"> + <enum>Qt::Horizontal</enum> + </property> + <property name="tickPosition"> + <enum>QSlider::TicksBelow</enum> + </property> + <property name="tickInterval"> + <number>2</number> + </property> + </widget> + </item> + <item> + <widget class="QLabel" name="label_accel"> + <property name="text"> + <string notr="true"/> + </property> + </widget> + </item> + </layout> + </item> + </layout> + </widget> + <resources/> + <connections/> +</ui> diff --git a/src-qt5/core-utils/lumina-config/pages/page_session_options.cpp b/src-qt5/core-utils/lumina-config/pages/page_session_options.cpp index 333f9da8..1af87cd2 100644 --- a/src-qt5/core-utils/lumina-config/pages/page_session_options.cpp +++ b/src-qt5/core-utils/lumina-config/pages/page_session_options.cpp @@ -33,6 +33,7 @@ page_session_options::page_session_options(QWidget *parent) : PageWidget(parent) connect(ui->check_session_playloginaudio, SIGNAL(toggled(bool)), this, SLOT(settingChanged()) ); connect(ui->check_session_playlogoutaudio, SIGNAL(toggled(bool)), this, SLOT(settingChanged()) ); connect(ui->check_autoapplinks, SIGNAL(toggled(bool)), this, SLOT(settingChanged()) ); + connect(ui->check_watch_app_procs, SIGNAL(toggled(bool)), this, SLOT(settingChanged()) ); updateIcons(); } @@ -53,6 +54,14 @@ void page_session_options::SaveSettings(){ sessionsettings.setValue("TimeFormat", ui->line_session_time->text()); sessionsettings.setValue("DateFormat", ui->line_session_date->text()); sessionsettings.setValue("DateTimeOrder", ui->combo_session_datetimeorder->currentData().toString()); + + QString lopenWatchFile = QString(getenv("XDG_CONFIG_HOME"))+"/lumina-desktop/nowatch"; + if(QFile::exists(lopenWatchFile) && ui->check_watch_app_procs->isChecked()){ + QFile::remove(lopenWatchFile); + }else if(!QFile::exists(lopenWatchFile) && !ui->check_watch_app_procs->isChecked()){ + QFile file(lopenWatchFile); + if(file.open(QIODevice::WriteOnly) ){ file.close(); } //just need to touch it to create the file + } emit HasPendingChanges(false); } @@ -71,6 +80,9 @@ void page_session_options::LoadSettings(int){ int index = ui->combo_session_datetimeorder->findData( sessionsettings.value("DateTimeOrder","timeonly").toString() ); ui->combo_session_datetimeorder->setCurrentIndex(index); + QString lopenWatchFile = QString(getenv("XDG_CONFIG_HOME"))+"/lumina-desktop/nowatch"; + ui->check_watch_app_procs->setChecked( !QFile::exists(lopenWatchFile) ); + sessionLoadTimeSample(); sessionLoadDateSample(); QApplication::processEvents(); //throw away any interaction events from loading diff --git a/src-qt5/core-utils/lumina-config/pages/page_session_options.ui b/src-qt5/core-utils/lumina-config/pages/page_session_options.ui index 55d204ae..255166de 100644 --- a/src-qt5/core-utils/lumina-config/pages/page_session_options.ui +++ b/src-qt5/core-utils/lumina-config/pages/page_session_options.ui @@ -59,6 +59,13 @@ </property> </widget> </item> + <item> + <widget class="QCheckBox" name="check_watch_app_procs"> + <property name="text"> + <string>Show application crash data</string> + </property> + </widget> + </item> <item> <layout class="QHBoxLayout" name="horizontalLayout_14"> <item> diff --git a/src-qt5/core-utils/lumina-config/pages/pages.pri b/src-qt5/core-utils/lumina-config/pages/pages.pri index b1db2860..b36ca7ba 100644 --- a/src-qt5/core-utils/lumina-config/pages/pages.pri +++ b/src-qt5/core-utils/lumina-config/pages/pages.pri @@ -13,7 +13,8 @@ HEADERS += $${PWD}/getPage.h \ $${PWD}/page_interface_panels.h \ $${PWD}/page_session_locale.h \ $${PWD}/page_session_options.h \ - $${PWD}/page_compton.h + $${PWD}/page_compton.h \ + $${PWD}/page_mouse.h SOURCES += $${PWD}/page_main.cpp \ @@ -28,7 +29,8 @@ SOURCES += $${PWD}/page_main.cpp \ $${PWD}/page_interface_panels.cpp \ $${PWD}/page_session_locale.cpp \ $${PWD}/page_session_options.cpp \ - $${PWD}/page_compton.cpp + $${PWD}/page_compton.cpp \ + $${PWD}/page_mouse.cpp FORMS += $${PWD}/page_main.ui \ @@ -43,4 +45,5 @@ FORMS += $${PWD}/page_main.ui \ $${PWD}/page_interface_panels.ui \ $${PWD}/page_session_locale.ui \ $${PWD}/page_session_options.ui \ - $${PWD}/page_compton.ui + $${PWD}/page_compton.ui \ + $${PWD}/page_mouse.ui diff --git a/src-qt5/core/libLumina/LInputDevice.cpp b/src-qt5/core/libLumina/LInputDevice.cpp new file mode 100644 index 00000000..d141e39a --- /dev/null +++ b/src-qt5/core/libLumina/LInputDevice.cpp @@ -0,0 +1,112 @@ +//=========================================== +// Lumina-DE source code +// Copyright (c) 2016, Ken Moore +// Available under the 3-clause BSD license +// See the LICENSE file for full details +//=========================================== +#include "LInputDevice.h" + +//Qt Library includes +#include <QString> +#include <QX11Info> +#include <QDebug> + +//XCB Library includes +#include <xcb/xcb.h> +#include <xcb/xcb_atom.h> +#include <xcb/xinput.h> +#include <xcb/xproto.h> + +//=================== +// LInputDevice Class +//=================== +// === PUBLIC === +LInputDevice::LInputDevice(unsigned int id, unsigned int type){ + devID = id; + devType = type; + //devName = name; + getProperties(); //need to populate the name/atom correlations for properties +} + +LInputDevice::~LInputDevice(){ + +} + +unsigned int LInputDevice::devNumber(){ + return devID; +} + +bool LInputDevice::isPointer(){ + return (devType==XCB_INPUT_DEVICE_USE_IS_X_POINTER \ + || devType==XCB_INPUT_DEVICE_USE_IS_X_EXTENSION_POINTER); +} + +bool LInputDevice::isKeyboard(){ + return (devType==XCB_INPUT_DEVICE_USE_IS_X_KEYBOARD \ + || devType==XCB_INPUT_DEVICE_USE_IS_X_EXTENSION_KEYBOARD); +} + +bool LInputDevice::isExtension(){ + return (devType==XCB_INPUT_DEVICE_USE_IS_X_EXTENSION_DEVICE \ + || devType==XCB_INPUT_DEVICE_USE_IS_X_EXTENSION_KEYBOARD \ + || devType==XCB_INPUT_DEVICE_USE_IS_X_EXTENSION_POINTER); +} + +// Property Management +QStringList LInputDevice::listProperties(){ + return devProps.keys(); +} + +QVariant LInputDevice::propertyValue(QString prop){ + if(!devProps.contains(prop)){ return QVariant(); } + //Now generate the property request + // xcb_input_get_device_property_cookie_t cookie = xcb_input_get_device_property_unchecked( QX11Info::connection(), devProps.value(prop), \ +// XCB_ATOM_ATOM, 0, 1000, devID, NULL); + QVariant result; + return result; +} + +// === PRIVATE === +void LInputDevice::getProperties(){ + devProps.clear(); + xcb_input_list_device_properties_cookie_t cookie = xcb_input_list_device_properties_unchecked(QX11Info::connection(), devID); + xcb_input_list_device_properties_reply_t *reply = xcb_input_list_device_properties_reply(QX11Info::connection(), cookie, NULL); + //Get the atoms + xcb_atom_t *atoms = xcb_input_list_device_properties_atoms(reply); + //qDebug() << "Property Response Type:" << reply->response_type; //Always seems to be "1" + QList<xcb_get_atom_name_cookie_t> cookies; + for(int i=0; i<reply->num_atoms; i++){ cookies << xcb_get_atom_name(QX11Info::connection(), atoms[i]); } + for(int i=0; i<reply->num_atoms; i++){ + xcb_get_atom_name_reply_t *nr = xcb_get_atom_name_reply(QX11Info::connection(), cookies[i], NULL); + devProps.insert(QString::fromUtf8( xcb_get_atom_name_name(nr), xcb_get_atom_name_name_length(nr) ),atoms[i] ); + ::free(nr); + } + //Done with data structure + ::free(reply); +} +//====================== +// LInput Static Functions +//====================== +QList<LInputDevice*> LInput::listDevices(){ + QList<LInputDevice*> devices; + xcb_input_list_input_devices_cookie_t cookie = xcb_input_list_input_devices_unchecked(QX11Info::connection()); + xcb_input_list_input_devices_reply_t *reply = xcb_input_list_input_devices_reply(QX11Info::connection(), cookie, NULL); + if(reply==0){ return devices; } //error - nothing returned + //Use the iterator for going through the reply + //qDebug() << "Create iterator"; + xcb_input_device_info_iterator_t iter = xcb_input_list_input_devices_devices_iterator(reply); + //xcb_str_iterator_t nameiter = xcb_input_list_input_devices_names_iterator(reply); + + //Now step through the reply + while(iter.data != 0 ){ + devices << new LInputDevice(iter.data->device_id, iter.data->device_use); + //qDebug() << "Found Input Device:" << iter.data->device_id; + //qDebug() << " - num_class_info:" << iter.data->num_class_info; + if(iter.rem>0){ xcb_input_device_info_next(&iter); } + else{ break; } + } + //Free the reply (done with it) + ::free(reply); + //return the information + return devices; +} diff --git a/src-qt5/core/libLumina/LInputDevice.h b/src-qt5/core/libLumina/LInputDevice.h new file mode 100644 index 00000000..f7a4713c --- /dev/null +++ b/src-qt5/core/libLumina/LInputDevice.h @@ -0,0 +1,53 @@ +//=========================================== +// Lumina-DE source code +// Copyright (c) 2016, Ken Moore +// Available under the 3-clause BSD license +// See the LICENSE file for full details +//=========================================== +// This class governs all the XCB input device interactions +// and provides simpler Qt-based functions for use elsewhere +//=========================================== +#ifndef _LUMINA_XCB_INPUT_DEVICES_H +#define _LUMINA_XCB_INPUT_DEVICES_H + +#include <QList> +#include <QString> +#include <QStringList> +#include <QHash> +#include <QVariant> + +#include <xcb/xproto.h> + +class LInputDevice{ +public: + LInputDevice(unsigned int id, unsigned int type); //don't use this directly - use the "listDevices()" function instead + ~LInputDevice(); + + //Device Information + //QString name(); //Return the name of this device + unsigned int devNumber(); + bool isPointer(); + bool isKeyboard(); + bool isExtension(); + + //Property Management + QStringList listProperties(); + QVariant propertyValue(QString prop); + +private: + unsigned int devID; //device ID number - assigned at class creation + unsigned int devType; //device "use" identifier - assigned at class creation + QHash<QString, xcb_atom_t> devProps; //Known device properties <name, atom> + + void getProperties(); + //QString devName; //device name - use this for cross-session management (id #'s can get changed every session) +}; + +//Static functions for overall management +class LInput{ + public: + static QList<LInputDevice*> listDevices(); //NOTE: Make sure you "free()" all the LInputDevice objects when finished + +}; + +#endif diff --git a/src-qt5/core/libLumina/LInputDevice.pri b/src-qt5/core/libLumina/LInputDevice.pri new file mode 100644 index 00000000..e90728ce --- /dev/null +++ b/src-qt5/core/libLumina/LInputDevice.pri @@ -0,0 +1,13 @@ + +QT *= x11extras + +LIBS *= -lc -lxcb -lxcb-xinput + +#LUtils Files +SOURCES *= $${PWD}/LInputDevice.cpp +HEADERS *= $${PWD}/LInputDevice.h + +INCLUDEPATH *= ${PWD} + +#include LUtils and LuminaOS +#include(LUtils.pri) diff --git a/src-qt5/core/libLumina/LuminaX11.cpp b/src-qt5/core/libLumina/LuminaX11.cpp index 3708af6d..a8016460 100644 --- a/src-qt5/core/libLumina/LuminaX11.cpp +++ b/src-qt5/core/libLumina/LuminaX11.cpp @@ -1,6 +1,6 @@ //=========================================== // Lumina-DE source code -// Copyright (c) 2014-2015, Ken Moore +// Copyright (c) 2014-2016, Ken Moore // Available under the 3-clause BSD license // See the LICENSE file for full details //=========================================== @@ -1124,6 +1124,7 @@ void LXCB::closeSystemTray(WId trayID){ xcb_destroy_window(QX11Info::connection(), trayID); } + // === SetScreenWorkArea() === /*void LXCB::SetScreenWorkArea(unsigned int screen, QRect rect){ //This is only useful because Fluxbox does not set the _NET_WORKAREA root atom diff --git a/src-qt5/core/libLumina/LuminaX11.h b/src-qt5/core/libLumina/LuminaX11.h index 7b6cce3c..2c741111 100644 --- a/src-qt5/core/libLumina/LuminaX11.h +++ b/src-qt5/core/libLumina/LuminaX11.h @@ -1,6 +1,6 @@ //=========================================== // Lumina-DE source code -// Copyright (c) 2014-2015, Ken Moore +// Copyright (c) 2014-2016, Ken Moore // Available under the 3-clause BSD license // See the LICENSE file for full details //=========================================== @@ -161,7 +161,6 @@ public: WId startSystemTray(int screen = 0); //Startup the system tray (returns window ID for tray) void closeSystemTray(WId); //Close the system tray - //============ // WM Functions (directly changing/reading properties) // - Using these directly may prevent the WM from seeing the change diff --git a/src-qt5/core/lumina-desktop/defaults/luminaDesktop-TrueOS.conf b/src-qt5/core/lumina-desktop/defaults/luminaDesktop-TrueOS.conf index 9b819e7c..56ff8b84 100644 --- a/src-qt5/core/lumina-desktop/defaults/luminaDesktop-TrueOS.conf +++ b/src-qt5/core/lumina-desktop/defaults/luminaDesktop-TrueOS.conf @@ -42,6 +42,13 @@ mime_default_unknown/*=lumina-textedit.desktop mime_default_application/x-shellscript=lumina-textedit.desktop mime_default_application/pdf_ifexists=pc-pdfviewer.desktop mime_default_application/pdf_ifexists=okular.desktop +mime_default_application/zip_ifexists=lumina-archiver.desktop +mime_default_application/x-compressed-tar_ifexists=lumina-archiver.desktop +mime_default_application/x-bzip-compressed-tar_ifexists=lumina-archiver.desktop +mime_default_application/x-lrzip-compressed-tar_ifexists=lumina-archiver.desktop +mime_default_application/x-lzma-compressed-tar_ifexists=lumina-archiver.desktop +mime_default_application/x-xz-compressed-tar_ifexists=lumina-archiver.desktop +mime_default_application/x-tar_ifexists=lumina-archiver.desktop #THEME SETTINGS theme_themefile=Glass #Name of the theme to use (disable for Lumina-Default) diff --git a/src-qt5/core/lumina-desktop/defaults/luminaDesktop.conf b/src-qt5/core/lumina-desktop/defaults/luminaDesktop.conf index 4950b1a0..46d00053 100644 --- a/src-qt5/core/lumina-desktop/defaults/luminaDesktop.conf +++ b/src-qt5/core/lumina-desktop/defaults/luminaDesktop.conf @@ -36,13 +36,13 @@ session_default_email_ifexists=trojita.desktop mime_default_text/*_ifexists=lumina-textedit.desktop mime_default_audio/*_ifexists=vlc.desktop mime_default_video/*_ifexists=vlc.desktop -mime_default_application/zip_ifexists=peazip.desktop -mime_default_application/x-compressed-tar_ifexists=peazip.desktop -mime_default_application/x-bzip-compressed-tar_ifexists=peazip.desktop -mime_default_application/x-lrzip-compressed-tar_ifexists=peazip.desktop -mime_default_application/x-lzma-compressed-tar_ifexists=peazip.desktop -mime_default_application/x-xz-compressed-tar_ifexists=peazip.desktop -mime_default_application/x-tar_ifexists=peazip.desktop +mime_default_application/zip_ifexists=lumina-archiver.desktop +mime_default_application/x-compressed-tar_ifexists=lumina-archiver.desktop +mime_default_application/x-bzip-compressed-tar_ifexists=lumina-archiver.desktop +mime_default_application/x-lrzip-compressed-tar_ifexists=lumina-archiver.desktop +mime_default_application/x-lzma-compressed-tar_ifexists=lumina-archiver.desktop +mime_default_application/x-xz-compressed-tar_ifexists=lumina-archiver.desktop +mime_default_application/x-tar_ifexists=lumina-archiver.desktop mime_default_unknown/*=lumina-textedit.desktop mime_default_application/x-shellscript=lumina-textedit.desktop diff --git a/src-qt5/desktop-utils/lumina-archiver/MainUI.cpp b/src-qt5/desktop-utils/lumina-archiver/MainUI.cpp index 9710045c..9d41374c 100644 --- a/src-qt5/desktop-utils/lumina-archiver/MainUI.cpp +++ b/src-qt5/desktop-utils/lumina-archiver/MainUI.cpp @@ -18,7 +18,7 @@ MainUI::MainUI() : QMainWindow(), ui(new Ui::MainUI){ this->setWindowTitle(tr("Archive Manager")); BACKEND = new Backend(this); connect(BACKEND, SIGNAL(ProcessStarting()), this, SLOT(ProcStarting()) ); - connect(BACKEND, SIGNAL(ProcessFinished()), this, SLOT(ProcFinished()) ); + connect(BACKEND, SIGNAL(ProcessFinished(bool, QString)), this, SLOT(ProcFinished(bool, QString)) ); connect(BACKEND, SIGNAL(ProgressUpdate(int, QString)), this, SLOT(ProcUpdate(int, QString)) ); //Add a spacer between toolbar items @@ -33,16 +33,18 @@ MainUI::MainUI() : QMainWindow(), ui(new Ui::MainUI){ connect(ui->actionAdd_File, SIGNAL(triggered()), this, SLOT(addFiles()) ); connect(ui->actionRemove_File, SIGNAL(triggered()), this, SLOT(remFiles()) ); connect(ui->actionExtract_All, SIGNAL(triggered()), this, SLOT(extractFiles()) ); + connect(ui->actionExtract_Sel, SIGNAL(triggered()), this, SLOT(extractSelection()) ); connect(ui->actionAdd_Dirs, SIGNAL(triggered()), this, SLOT(addDirs()) ); connect(ui->tree_contents, SIGNAL(itemDoubleClicked(QTreeWidgetItem*, int)), this, SLOT(ViewFile(QTreeWidgetItem*)) ); ui->progressBar->setVisible(false); ui->label_progress->setVisible(false); + ui->label_progress_icon->setVisible(false); ui->actionAdd_File->setEnabled(false); ui->actionRemove_File->setEnabled(false); ui->actionExtract_All->setEnabled(false); ui->actionAdd_Dirs->setEnabled(false); loadIcons(); - ui->tree_contents->setHeaderLabels( QStringList() << tr("File") << tr("MimeType") << tr("Size") << tr("Compressed")+" " ); + ui->tree_contents->setHeaderLabels( QStringList() << tr("File") << tr("MimeType") << tr("Size")+" " ); } MainUI::~MainUI(){ @@ -51,7 +53,11 @@ MainUI::~MainUI(){ void MainUI::LoadArguments(QStringList args){ for(int i=0; i<args.length(); i++){ - if(QFile::exists(args[i])){ BACKEND->loadFile(args[i]); break;} + if(QFile::exists(args[i])){ + ui->label_progress->setText(tr("Opening Archive...")); + BACKEND->loadFile(args[i]); + break; + } } } @@ -64,6 +70,7 @@ void MainUI::loadIcons(){ ui->actionAdd_Dirs->setIcon( LXDG::findIcon("archive-insert-directory","") ); ui->actionRemove_File->setIcon( LXDG::findIcon("archive-remove","") ); ui->actionExtract_All->setIcon( LXDG::findIcon("archive-extract","") ); + ui->actionExtract_Sel->setIcon( LXDG::findIcon("archive-extract","") ); } //=================== @@ -72,17 +79,16 @@ void MainUI::loadIcons(){ QTreeWidgetItem* MainUI::findItem(QString path, QTreeWidgetItem *start){ if(start==0){ for(int i=0; i<ui->tree_contents->topLevelItemCount(); i++){ - QString itpath = ui->tree_contents->topLevelItem(i)->whatsThis(0); - if(itpath == path){ return ui->tree_contents->topLevelItem(i); } - else if(path.startsWith(itpath+"/")){ return findItem(path, ui->tree_contents->topLevelItem(i)); } + if(ui->tree_contents->topLevelItem(i)->whatsThis(0) == path){ return ui->tree_contents->topLevelItem(i); } + else if(path.startsWith(ui->tree_contents->topLevelItem(i)->whatsThis(0)+"/")){ return findItem(path, ui->tree_contents->topLevelItem(i)); } } }else{ for(int i=0; i<start->childCount(); i++){ - QString itpath = start->child(i)->whatsThis(0); - if(itpath == path){ return start->child(i); } - else if(path.startsWith(itpath+"/")){ return findItem(path, start->child(i)); } + if(start->child(i)->whatsThis(0) == path){ return start->child(i); } + else if(path.startsWith(start->child(i)->whatsThis(0)+"/")){ return findItem(path, start->child(i)); } } } + //qDebug() << "Could not find item:" << path; return 0; //nothing found } @@ -158,24 +164,28 @@ void MainUI::NewArchive(){ if(QFile::exists(file)){ if( !QFile::remove(file) ){ QMessageBox::warning(this, tr("Error"), QString(tr("Could not overwrite file:"))+"\n"+file); } } + ui->label_progress->setText(""); //just clear it (this action is instant) BACKEND->loadFile(file); } void MainUI::OpenArchive(){ QString file = QFileDialog::getOpenFileName(this, tr("Open Archive"), QDir::homePath(), OpenFileTypes() ); if(file.isEmpty()){ return; } + ui->label_progress->setText(tr("Opening Archive...")); BACKEND->loadFile(file); } void MainUI::addFiles(){ QStringList files = QFileDialog::getOpenFileNames(this, tr("Add to Archive"), QDir::homePath() ); if(files.isEmpty()){ return; } + ui->label_progress->setText(tr("Adding Items...")); BACKEND->startAdd(files); } void MainUI::addDirs(){ QString dirs = QFileDialog::getExistingDirectory(this, tr("Add to Archive"), QDir::homePath() ); if(dirs.isEmpty()){ return; } + ui->label_progress->setText(tr("Adding Items...")); BACKEND->startAdd(QStringList() << dirs); } @@ -186,35 +196,57 @@ void MainUI::remFiles(){ items << sel[i]->whatsThis(0); } items.removeDuplicates(); + ui->label_progress->setText(tr("Removing Items...")); BACKEND->startRemove(items); } void MainUI::extractFiles(){ QString dir = QFileDialog::getExistingDirectory(this, tr("Extract Into Directory"), QDir::homePath() ); if(dir.isEmpty()){ return; } + ui->label_progress->setText(tr("Extracting...")); BACKEND->startExtract(dir, true); } +void MainUI::extractSelection(){ + if(ui->tree_contents->currentItem()==0){ return; } + QString sel = ui->tree_contents->currentItem()->whatsThis(0); + QString dir = QFileDialog::getExistingDirectory(this, tr("Extract Into Directory"), QDir::homePath() ); + if(dir.isEmpty()){ return; } + ui->label_progress->setText(tr("Extracting...")); + BACKEND->startExtract(dir, true, sel); +} + void MainUI::ViewFile(QTreeWidgetItem *it){ if(it->childCount()>0){ return; } //directory - not viewable + ui->label_progress->setText(tr("Extracting...")); BACKEND->startViewFile(it->whatsThis(0)); } void MainUI::UpdateTree(){ - ui->tree_contents->setHeaderLabels( QStringList() << tr("File") << tr("MimeType") << tr("Size") << tr("Compressed")+" " ); + this->setEnabled(false); + ui->tree_contents->setHeaderLabels( QStringList() << tr("File") << tr("MimeType") << tr("Size")+" " ); QStringList files = BACKEND->heirarchy(); files.sort(); //Remove any entries for file no longer in the archive bool changed = cleanItems(files); - qDebug() << "Found Files:" << files; + //qDebug() << "Found Files:" << files; for(int i=0; i<files.length(); i++){ if(0 != findItem(files[i]) ){ continue; } //already in the tree widget QString mime = LXDG::findAppMimeForFile(files[i].section("/",-1), false); //first match only - QTreeWidgetItem *it = new QTreeWidgetItem( QStringList() << files[i].section("/",-1) << mime << LUtils::BytesToDisplaySize( BACKEND->size(files[i])) << LUtils::BytesToDisplaySize(BACKEND->csize(files[i])) ); + QTreeWidgetItem *it = new QTreeWidgetItem(); + it->setText(0, files[i].section("/",-1) ); + if(!BACKEND->isLink(files[i])){ + it->setText(1, LXDG::findAppMimeForFile(files[i].section("/",-1), false) ); + it->setText(2, LUtils::BytesToDisplaySize( BACKEND->size(files[i])) ); + }else{ + it->setText(1, QString(tr("Link To: %1")).arg(BACKEND->linkTo(files[i]) ) ); + } it->setWhatsThis(0, files[i]); if(BACKEND->isDir(files[i])){ it->setIcon(0, LXDG::findIcon("folder","")); it->setText(1,""); //clear the mimetype + }else if(BACKEND->isLink(files[i])){ + it->setIcon(0, LXDG::findIcon("emblem-symbolic-link","") ); }else{ it->setIcon(0, LXDG::findMimeIcon(files[i].section("/",-1)) ); } @@ -226,14 +258,23 @@ void MainUI::UpdateTree(){ else{ parent->addChild(it); } }else{ ui->tree_contents->addTopLevelItem(it); + QApplication::processEvents(); } changed = true; } - int wid = 0; + if(changed){ - for(int i=3; i>0; i--){ui->tree_contents->resizeColumnToContents(i); wid+= ui->tree_contents->columnWidth(i); } + int wid = ui->tree_contents->fontMetrics().width("W")*5; + ui->tree_contents->setColumnWidth(2, wid); + for(int i=1; i<2; i++){ui->tree_contents->resizeColumnToContents(i); QApplication::processEvents(); wid+= ui->tree_contents->columnWidth(i); } + //qDebug() << "Set column 0 width:" << wid << ui->tree_contents->viewport()->width(); ui->tree_contents->setColumnWidth(0, ui->tree_contents->viewport()->width()-wid); } + ui->tree_contents->sortItems(0, Qt::AscendingOrder); //sort by name + ui->tree_contents->sortItems(1,Qt::AscendingOrder); //sort by mimetype (put dirs first - still organized by name) + + this->setEnabled(true); + ui->tree_contents->setEnabled(true); } //Backend Handling @@ -241,17 +282,22 @@ void MainUI::ProcStarting(){ ui->progressBar->setRange(0,0); ui->progressBar->setValue(0); ui->progressBar->setVisible(true); - ui->label_progress->setVisible(true); + ui->label_progress->setVisible(!ui->label_progress->text().isEmpty()); + ui->label_progress_icon->setVisible(false); ui->tree_contents->setEnabled(false); ui->label_archive->setText(BACKEND->currentFile()); } -void MainUI::ProcFinished(){ +void MainUI::ProcFinished(bool success, QString msg){ + UpdateTree(); ui->progressBar->setRange(0,0); ui->progressBar->setValue(0); ui->progressBar->setVisible(false); - ui->label_progress->setVisible(false); - ui->tree_contents->setEnabled(true); + ui->label_progress->setText(msg); + ui->label_progress->setVisible(!msg.isEmpty()); + ui->label_progress_icon->setVisible(!msg.isEmpty()); + if(success){ ui->label_progress_icon->setPixmap( LXDG::findIcon("task-complete","").pixmap(32,32) );} + else{ ui->label_progress_icon->setPixmap( LXDG::findIcon("task-attention","").pixmap(32,32) );} if(ui->label_archive->text()!=BACKEND->currentFile()){ ui->label_archive->setText(BACKEND->currentFile()); this->setWindowTitle(BACKEND->currentFile().section("/",-1)); @@ -265,7 +311,6 @@ void MainUI::ProcFinished(){ ui->actionRemove_File->setEnabled(canmodify && info.exists()); ui->actionExtract_All->setEnabled(info.exists()); ui->actionAdd_Dirs->setEnabled(canmodify); - UpdateTree(); } void MainUI::ProcUpdate(int percent, QString txt){ diff --git a/src-qt5/desktop-utils/lumina-archiver/MainUI.h b/src-qt5/desktop-utils/lumina-archiver/MainUI.h index 09207aa3..bb462a7d 100644 --- a/src-qt5/desktop-utils/lumina-archiver/MainUI.h +++ b/src-qt5/desktop-utils/lumina-archiver/MainUI.h @@ -44,13 +44,14 @@ private slots: void addDirs(); void remFiles(); void extractFiles(); + void extractSelection(); void ViewFile(QTreeWidgetItem *it); void UpdateTree(); //Backend Handling void ProcStarting(); - void ProcFinished(); + void ProcFinished(bool, QString); void ProcUpdate(int percent, QString txt); }; diff --git a/src-qt5/desktop-utils/lumina-archiver/MainUI.ui b/src-qt5/desktop-utils/lumina-archiver/MainUI.ui index 8c2b2836..1aff2e4f 100644 --- a/src-qt5/desktop-utils/lumina-archiver/MainUI.ui +++ b/src-qt5/desktop-utils/lumina-archiver/MainUI.ui @@ -56,6 +56,31 @@ </item> <item> <layout class="QHBoxLayout" name="horizontalLayout_2"> + <item> + <widget class="QLabel" name="label_progress_icon"> + <property name="sizePolicy"> + <sizepolicy hsizetype="Fixed" vsizetype="Fixed"> + <horstretch>0</horstretch> + <verstretch>0</verstretch> + </sizepolicy> + </property> + <property name="minimumSize"> + <size> + <width>32</width> + <height>32</height> + </size> + </property> + <property name="maximumSize"> + <size> + <width>32</width> + <height>32</height> + </size> + </property> + <property name="text"> + <string notr="true"/> + </property> + </widget> + </item> <item> <widget class="QProgressBar" name="progressBar"> <property name="value"> @@ -68,6 +93,9 @@ <property name="text"> <string notr="true"/> </property> + <property name="alignment"> + <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set> + </property> </widget> </item> </layout> @@ -101,6 +129,7 @@ <addaction name="actionRemove_File"/> <addaction name="separator"/> <addaction name="actionExtract_All"/> + <addaction name="actionExtract_Sel"/> </widget> <addaction name="menuFile"/> <addaction name="menuEdit"/> @@ -183,6 +212,11 @@ <string>Add directory to archive</string> </property> </action> + <action name="actionExtract_Sel"> + <property name="text"> + <string>Extract Selection</string> + </property> + </action> </widget> <resources/> <connections/> diff --git a/src-qt5/desktop-utils/lumina-archiver/TarBackend.cpp b/src-qt5/desktop-utils/lumina-archiver/TarBackend.cpp index 4dee247b..919a6813 100644 --- a/src-qt5/desktop-utils/lumina-archiver/TarBackend.cpp +++ b/src-qt5/desktop-utils/lumina-archiver/TarBackend.cpp @@ -32,7 +32,7 @@ void Backend::loadFile(QString path){ flags.clear(); flags << "-f" << filepath; //add the actual archive path if(QFile::exists(path)){ startList(); } - else{ contents.clear(); emit ProcessFinished(); } + else{ contents.clear(); emit ProcessFinished(true, ""); } } bool Backend::canModify(){ @@ -75,6 +75,16 @@ bool Backend::isDir(QString file){ return contents.value(file)[0].startsWith("d"); } +bool Backend::isLink(QString file){ + if(!contents.contains(file)){ return false; } + return contents.value(file)[0].startsWith("l"); +} + +QString Backend::linkTo(QString file){ + if(!contents.contains(file)){ return ""; } + return contents.value(file)[2]; +} + //Modification routines void Backend::startAdd(QStringList paths){ //NOTE: All the "paths" have to have the same parent directory @@ -115,11 +125,13 @@ void Backend::startRemove(QStringList paths){ PROC.start("tar", args); } -void Backend::startExtract(QString path, bool overwrite){ +void Backend::startExtract(QString path, bool overwrite, QString file){ QStringList args; args << "-x"; if(!overwrite){ args << "-k"; } - args << flags << "-C" << path; + args << flags; + if(!file.isEmpty()){ args << "--include" << file << "--strip-components" << QString::number(file.count("/")); } + args << "-C" << path; STARTING=true; //qDebug() << "Starting command:" << "tar" << args; PROC.start("tar", args); @@ -151,14 +163,23 @@ void Backend::parseLines(QStringList lines){ QString file = info[1]; QString perms = ""; if(file.endsWith("/")){ perms = "d"; file.chop(1); } - contents.insert(file, QStringList() << perms << "-1" ); //Save the [perms, size ] + contents.insert(file, QStringList() << perms << "-1" <<""); //Save the [perms, size, linkto ] } else if(info.length()<9){ continue; } //invalid line //TAR Archive parsing while(info.length()>9){ info[8] = info[8]+" "+info[9]; info.removeAt(9); } //Filename has spaces in it QString file = info[8]; if(file.endsWith("/")){ file.chop(1); } - contents.insert(file, QStringList() << info[0] << info[4] ); //Save the [perms, size ] + QString linkto; + //See if this file has the "link to" or "->" notation + if(file.contains(" -> ")){ linkto = file.section(" -> ",1,-1); file = file.section(" -> ",0,0); } + else if(file.contains(" link to ")){ + //Special case - alternate form of a link within a tar archive (not reflected in perms) + linkto = file.section(" link to ",1,-1); + file = file.section(" link to ",0,0); + if(info[0].startsWith("-")){ info[0].replace(0,1,"l"); } + } + contents.insert(file, QStringList() << info[0] << info[4] << linkto); //Save the [perms, size, linkto ] } } @@ -174,17 +195,19 @@ void Backend::startList(){ // PRIVATE SLOTS //=============== void Backend::procFinished(int retcode, QProcess::ExitStatus){ + static QString result; processData(); - qDebug() << "Process Finished:" << PROC.arguments() << retcode; + //qDebug() << "Process Finished:" << PROC.arguments() << retcode; LIST = STARTING = false; if(PROC.arguments().contains("-tv")){ if(retcode!=0){ contents.clear(); } //could not read archive - emit ProcessFinished(); + emit ProcessFinished(true,result); + result.clear(); }else{ bool needupdate = true; QStringList args = PROC.arguments(); if(args.contains("-x") && retcode==0){ - needupdate=false; + needupdate=false; if(args.contains("--include")){ //Need to find the full path to the extracted file QString path = args.last() +"/"+ args[ args.indexOf("--include")+1].section("/",-1); @@ -201,8 +224,10 @@ void Backend::procFinished(int retcode, QProcess::ExitStatus){ QFile::remove(tmpfilepath); } } + if(args.contains("-x")){ result = tr("Extraction Finished"); } + else if(args.contains("-c")){ result = tr("Modification Finished"); } if(needupdate){ startList(); } - else{ emit ProcessFinished(); } + else{ emit ProcessFinished(retcode==0, result); result.clear(); } } } @@ -213,7 +238,9 @@ void Backend::processData(){ if(read.endsWith("\n")){ data.clear(); } else{ data = read.section("\n",-1); read = read.section("\n",0,-2); } QStringList lines = read.split("\n",QString::SkipEmptyParts); + QString info; if(LIST){ parseLines(lines); } + else if(!lines.isEmpty()){ info = lines.last(); } //qDebug() << lines; - emit ProgressUpdate(-1, ""); + emit ProgressUpdate(-1, info); } diff --git a/src-qt5/desktop-utils/lumina-archiver/TarBackend.h b/src-qt5/desktop-utils/lumina-archiver/TarBackend.h index f12aae63..47bc0bb6 100644 --- a/src-qt5/desktop-utils/lumina-archiver/TarBackend.h +++ b/src-qt5/desktop-utils/lumina-archiver/TarBackend.h @@ -29,14 +29,17 @@ public: double size(QString file); double csize(QString file); bool isDir(QString file); + bool isLink(QString file); + QString linkTo(QString file); //Modification routines void startAdd(QStringList paths); void startRemove(QStringList paths); - void startExtract(QString path, bool overwrite); //path to dir + void startExtract(QString path, bool overwrite, QString file=""); //path to dir, overwrite, optional file to extract (everything otherwise) void startViewFile(QString path); + //Special process public slots: private: @@ -58,7 +61,7 @@ signals: void FileLoaded(); void ProcessStarting(); void ProgressUpdate(int, QString); //percentage, text - void ProcessFinished(); + void ProcessFinished(bool, QString); //success, text }; #endif diff --git a/src-qt5/desktop-utils/lumina-archiver/isoDialog.ui b/src-qt5/desktop-utils/lumina-archiver/isoDialog.ui new file mode 100644 index 00000000..99ba31fb --- /dev/null +++ b/src-qt5/desktop-utils/lumina-archiver/isoDialog.ui @@ -0,0 +1,151 @@ +<?xml version="1.0" encoding="UTF-8"?> +<ui version="4.0"> + <class>isoDialog</class> + <widget class="QDialog" name="isoDialog"> + <property name="geometry"> + <rect> + <x>0</x> + <y>0</y> + <width>305</width> + <height>179</height> + </rect> + </property> + <property name="windowTitle"> + <string>Burn ISO/IMG to device</string> + </property> + <layout class="QFormLayout" name="formLayout"> + <item row="0" column="0" colspan="2"> + <widget class="QLabel" name="label_iso"> + <property name="font"> + <font> + <weight>75</weight> + <bold>true</bold> + </font> + </property> + <property name="text"> + <string>TextLabel</string> + </property> + <property name="alignment"> + <set>Qt::AlignCenter</set> + </property> + </widget> + </item> + <item row="1" column="0"> + <widget class="QLabel" name="label"> + <property name="sizePolicy"> + <sizepolicy hsizetype="Expanding" vsizetype="Preferred"> + <horstretch>0</horstretch> + <verstretch>0</verstretch> + </sizepolicy> + </property> + <property name="text"> + <string>Transfer Rate</string> + </property> + </widget> + </item> + <item row="1" column="1"> + <layout class="QHBoxLayout" name="horizontalLayout"> + <item> + <widget class="QSpinBox" name="spin_rate_num"> + <property name="sizePolicy"> + <sizepolicy hsizetype="Preferred" vsizetype="Fixed"> + <horstretch>0</horstretch> + <verstretch>0</verstretch> + </sizepolicy> + </property> + <property name="minimum"> + <number>1</number> + </property> + <property name="maximum"> + <number>1023</number> + </property> + </widget> + </item> + <item> + <widget class="QComboBox" name="combo_rate_units"/> + </item> + </layout> + </item> + <item row="2" column="0"> + <widget class="QLabel" name="label_3"> + <property name="text"> + <string>USB Device</string> + </property> + </widget> + </item> + <item row="3" column="0" colspan="2"> + <widget class="QCheckBox" name="check_sync"> + <property name="text"> + <string>Wipe all extra space on device (conv = sync)</string> + </property> + <property name="checked"> + <bool>true</bool> + </property> + </widget> + </item> + <item row="2" column="1"> + <layout class="QHBoxLayout" name="horizontalLayout_2"> + <item> + <widget class="QComboBox" name="combo_devices"/> + </item> + <item> + <widget class="QToolButton" name="tool_refresh"> + <property name="toolTip"> + <string>Refresh Device List</string> + </property> + <property name="text"> + <string notr="true"/> + </property> + </widget> + </item> + </layout> + </item> + <item row="4" column="0"> + <spacer name="verticalSpacer"> + <property name="orientation"> + <enum>Qt::Vertical</enum> + </property> + <property name="sizeHint" stdset="0"> + <size> + <width>20</width> + <height>40</height> + </size> + </property> + </spacer> + </item> + <item row="5" column="0" colspan="2"> + <layout class="QHBoxLayout" name="horizontalLayout_3"> + <item> + <spacer name="horizontalSpacer"> + <property name="orientation"> + <enum>Qt::Horizontal</enum> + </property> + <property name="sizeHint" stdset="0"> + <size> + <width>40</width> + <height>20</height> + </size> + </property> + </spacer> + </item> + <item> + <widget class="QPushButton" name="push_cancel"> + <property name="text"> + <string>Cancel</string> + </property> + </widget> + </item> + <item> + <widget class="QPushButton" name="push_start"> + <property name="text"> + <string>Start</string> + </property> + </widget> + </item> + </layout> + </item> + </layout> + </widget> + <resources/> + <connections/> +</ui> -- cgit From df2209e6fe8f938c7178a076d29e25d71c207877 Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Sun, 20 Nov 2016 13:31:56 -0500 Subject: Fix a reference to an uncommitted function by q5sys. --- src-qt5/core-utils/lumina-config/mainWindow.cpp | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/core-utils/lumina-config/mainWindow.cpp b/src-qt5/core-utils/lumina-config/mainWindow.cpp index ecaf2990..659cb306 100644 --- a/src-qt5/core-utils/lumina-config/mainWindow.cpp +++ b/src-qt5/core-utils/lumina-config/mainWindow.cpp @@ -134,10 +134,7 @@ void mainWindow::on_actionSave_triggered(){ } void mainWindow::on_actionBack_triggered(){ - if(cpage.isEmpty()){ page_main::clearlineEdit(); } //since ESC doesnt close any other Lumina Appliction by default, I've -commented this out for -the -time being. + if(cpage.isEmpty()){ }// page_main::clearlineEdit(); } //since ESC doesnt close any other Lumina Appliction by default, I've commented this out for the time being. else{ page_change(""); } //Use the interactive wrapper (check for save state, etc). } -- cgit From 3f885fb37548a8ba362ac2519717379f250895cb Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Mon, 21 Nov 2016 10:04:28 -0500 Subject: Add a new menu plugin: "lockdesktop". This just adds a shortcut to the context menu for locking the desktop session. --- src-qt5/core-utils/lumina-config/LPlugins.cpp | 7 +++++++ src-qt5/core/lumina-desktop/LDesktop.cpp | 7 ++++++- src-qt5/core/lumina-desktop/LDesktop.h | 1 + 3 files changed, 14 insertions(+), 1 deletion(-) (limited to 'src-qt5') diff --git a/src-qt5/core-utils/lumina-config/LPlugins.cpp b/src-qt5/core-utils/lumina-config/LPlugins.cpp index dfd490e6..aa691df4 100644 --- a/src-qt5/core-utils/lumina-config/LPlugins.cpp +++ b/src-qt5/core-utils/lumina-config/LPlugins.cpp @@ -307,6 +307,13 @@ void LPlugins::LoadMenuPlugins(){ info.ID = "jsonmenu"; info.icon = "text-x-script"; MENU.insert(info.ID, info); + //Lock Screen item + info = LPI(); //clear it + info.name = QObject::tr("Lock Session"); + info.description = QObject::tr("Lock the current desktop session"); + info.ID = "lockdesktop"; + info.icon = "system-lock-screen"; + MENU.insert(info.ID, info); } void LPlugins::LoadColorItems(){ diff --git a/src-qt5/core/lumina-desktop/LDesktop.cpp b/src-qt5/core/lumina-desktop/LDesktop.cpp index b08251bd..5031fb96 100644 --- a/src-qt5/core/lumina-desktop/LDesktop.cpp +++ b/src-qt5/core/lumina-desktop/LDesktop.cpp @@ -96,7 +96,11 @@ void LDesktop::UpdateGeometry(){ //qDebug() << " - Done With Desktop Geom Updates"; QTimer::singleShot(0, this, SLOT(UpdatePanels())); } - + +void LDesktop::SystemLock(){ + QProcess::startDetached("xscreensaver-command -lock"); +} + void LDesktop::SystemLogout(){ LSession::handle()->systemWindow(); } @@ -279,6 +283,7 @@ void LDesktop::UpdateMenu(bool fast){ usewinmenu=false; for(int i=0; i<items.length(); i++){ if(items[i]=="terminal"){ deskMenu->addAction(LXDG::findIcon("utilities-terminal",""), tr("Terminal"), this, SLOT(SystemTerminal()) ); } + else if(items[i]=="lockdesktop"){ deskMenu->addAction(LXDG::findIcon("system-lock-screen",""), tr("Lock Session"), this, SLOT(SystemLock()) ); } else if(items[i]=="filemanager"){ deskMenu->addAction( LXDG::findIcon("user-home",""), tr("Browse Files"), this, SLOT(SystemFileManager()) ); } else if(items[i]=="applications"){ deskMenu->addMenu( LSession::handle()->applicationMenu() ); } else if(items[i]=="line"){ deskMenu->addSeparator(); } diff --git a/src-qt5/core/lumina-desktop/LDesktop.h b/src-qt5/core/lumina-desktop/LDesktop.h index c576a805..378db75b 100644 --- a/src-qt5/core/lumina-desktop/LDesktop.h +++ b/src-qt5/core/lumina-desktop/LDesktop.h @@ -50,6 +50,7 @@ public: void UpdateGeometry(); public slots: + void SystemLock(); void SystemLogout(); void SystemTerminal(); void SystemFileManager(); -- cgit From 2034d424a2054b6b4c31424c0ad89644e8fac5fe Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Mon, 21 Nov 2016 10:06:18 -0500 Subject: Add the "lockdesktop" menu plugin to the TrueOS default settings. --- src-qt5/core/lumina-desktop/defaults/luminaDesktop-TrueOS.conf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src-qt5') diff --git a/src-qt5/core/lumina-desktop/defaults/luminaDesktop-TrueOS.conf b/src-qt5/core/lumina-desktop/defaults/luminaDesktop-TrueOS.conf index 56ff8b84..c1f3a194 100644 --- a/src-qt5/core/lumina-desktop/defaults/luminaDesktop-TrueOS.conf +++ b/src-qt5/core/lumina-desktop/defaults/luminaDesktop-TrueOS.conf @@ -73,7 +73,7 @@ panel1_pinlocation=center #[left/center/right] Note:[left/right] corresponds to panel1_edgepercent=99 #[1->100] percentage of the screen edge to use #MENU SETTINGS (right-click menu) -menu_plugins=terminal, filemanager, applications, line, settings #list of menu plugins to show +menu_plugins=terminal, filemanager, applications, line, settings, line, lockdesktop#list of menu plugins to show #FAVORITES CUSTOMIZATION #favorites_add=<file/dir path> #Create a favorites entry for this file/dir -- cgit From c0024651b0e21c77d34d01328bc406484d45880b Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Mon, 21 Nov 2016 11:00:21 -0500 Subject: Add the ability to specify "--page <page_id>" when running lumina-config to go to a particular page. --- src-qt5/core-utils/lumina-config/main.cpp | 7 ++++--- src-qt5/core-utils/lumina-config/mainWindow.cpp | 11 +++++++++-- src-qt5/core-utils/lumina-config/mainWindow.h | 2 +- 3 files changed, 14 insertions(+), 6 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/core-utils/lumina-config/main.cpp b/src-qt5/core-utils/lumina-config/main.cpp index 27493bac..e2c757a3 100644 --- a/src-qt5/core-utils/lumina-config/main.cpp +++ b/src-qt5/core-utils/lumina-config/main.cpp @@ -21,10 +21,11 @@ int main(int argc, char ** argv) if(!a.isPrimaryProcess()){ return 0; } //LuminaThemeEngine theme(&a); - + QStringList args; + for(int i=1; i<argc; i++){ args << QString(argv[i]); } mainWindow w; - QObject::connect(&a, SIGNAL(InputsAvailable(QStringList)), &w, SLOT(slotSingleInstance()) ); - //QObject::connect(&theme, SIGNAL(updateIcons()), &w, SLOT(setupIcons()) ); + QObject::connect(&a, SIGNAL(InputsAvailable(QStringList)), &w, SLOT(slotSingleInstance(QStringList)) ); + w.slotSingleInstance(args); w.show(); int retCode = a.exec(); diff --git a/src-qt5/core-utils/lumina-config/mainWindow.cpp b/src-qt5/core-utils/lumina-config/mainWindow.cpp index 659cb306..595d69f6 100644 --- a/src-qt5/core-utils/lumina-config/mainWindow.cpp +++ b/src-qt5/core-utils/lumina-config/mainWindow.cpp @@ -27,7 +27,7 @@ mainWindow::mainWindow() : QMainWindow(), ui(new Ui::mainWindow()){ connect(backShortcut, SIGNAL(activated()), this, SLOT(on_actionBack_triggered()) ); setupIcons(); loadMonitors(); - changePage(""); //load the default main page + //changePage(""); //load the default main page } mainWindow::~mainWindow(){ @@ -37,7 +37,14 @@ mainWindow::~mainWindow(){ //============== // PUBLIC SLOTS //============== -void mainWindow::slotSingleInstance(){ +void mainWindow::slotSingleInstance(QStringList args){ + for(int i=0; i<args.length(); i++){ + if(args[i]=="--page" && i<args.length()-1){ + i++; + changePage(args[i]); + } + } + if(cpage == "somerandomjunktostartwith"){ changePage(""); } this->showNormal(); //just in case it is hidden/minimized } diff --git a/src-qt5/core-utils/lumina-config/mainWindow.h b/src-qt5/core-utils/lumina-config/mainWindow.h index 14969473..71fda711 100644 --- a/src-qt5/core-utils/lumina-config/mainWindow.h +++ b/src-qt5/core-utils/lumina-config/mainWindow.h @@ -19,7 +19,7 @@ public: ~mainWindow(); public slots: - void slotSingleInstance(); + void slotSingleInstance(QStringList args); void setupIcons(); void loadMonitors(); -- cgit From a0dd33922d93a6972b1fe81808866c5973c7d563 Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Mon, 21 Nov 2016 11:03:33 -0500 Subject: Add a shortcut for opening the wallpaper settings within the "preferences" menu. --- src-qt5/core/lumina-desktop/SettingsMenu.cpp | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/core/lumina-desktop/SettingsMenu.cpp b/src-qt5/core/lumina-desktop/SettingsMenu.cpp index 80ef3042..58208931 100644 --- a/src-qt5/core/lumina-desktop/SettingsMenu.cpp +++ b/src-qt5/core/lumina-desktop/SettingsMenu.cpp @@ -30,12 +30,16 @@ void SettingsMenu::UpdateMenu(){ QAction *act = new QAction(LXDG::findIcon("preferences-desktop-screensaver",""), tr("Screensaver"), this); act->setWhatsThis("xscreensaver-demo"); this->addAction(act); - act = new QAction( LXDG::findIcon("preferences-desktop",""), tr("Desktop"), this); - act->setWhatsThis("lumina-config"); + act = new QAction( LXDG::findIcon("preferences-desktop-wallpaper",""), tr("Wallpaper"), this); + act->setWhatsThis("lumina-config --page wallpaper"); this->addAction(act); act = new QAction( LXDG::findIcon("preferences-other",""), tr("Display"), this); act->setWhatsThis("lumina-xconfig"); this->addAction(act); + act = new QAction( LXDG::findIcon("preferences-desktop",""), tr("All Desktop Settings"), this); + act->setWhatsThis("lumina-config"); + this->addAction(act); + this->addSeparator(); /*QString qtconfig = LOS::QtConfigShortcut(); if(QFile::exists(qtconfig) && !qtconfig.isEmpty()){ act = new QAction( LXDG::findIcon("preferences-desktop-theme",""), tr("Window Theme"), this); @@ -52,7 +56,6 @@ void SettingsMenu::UpdateMenu(){ this->addAction(act); } } - this->addSeparator(); act = new QAction( LXDG::findIcon("lumina",""), tr("About Lumina"), this); act->setWhatsThis("lumina-info"); this->addAction(act); -- cgit From 1b7f0d30506c1c9ff39acbe8cd6e6403a02ae5f2 Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Tue, 22 Nov 2016 14:08:52 -0500 Subject: Fix up the default settings-setting routine to use the new panel/desktop syntax when setting the default configuration for the primary monitor. --- src-qt5/core/libLumina/LDesktopUtils.cpp | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/core/libLumina/LDesktopUtils.cpp b/src-qt5/core/libLumina/LDesktopUtils.cpp index 2797c8ca..80135ed0 100644 --- a/src-qt5/core/libLumina/LDesktopUtils.cpp +++ b/src-qt5/core/libLumina/LDesktopUtils.cpp @@ -269,10 +269,11 @@ void LDesktopUtils::LoadSystemDefaults(bool skipOS){ } // -- DESKTOP SETTINGS -- + QString deskID = QApplication::primaryScreen()->name(); //(only works for the primary desktop at the moment) - tmp = sysDefaults.filter("desktop_"); - if(tmp.isEmpty()){ tmp = sysDefaults.filter("desktop."); }//for backwards compat - if(!tmp.isEmpty()){deskset << "[desktop-"+screen+"]"; } + tmp = sysDefaults.filter("desktop-"+deskID); + if(tmp.isEmpty()){ tmp = sysDefaults.filter("desktop."+deskID); }//for backwards compat + if(!tmp.isEmpty()){deskset << "[desktop-"+deskID+"]"; } for(int i=0; i<tmp.length(); i++){ if(tmp[i].startsWith("#") || !tmp[i].contains("=") ){ continue; } QString var = tmp[i].section("=",0,0).toLower().simplified(); @@ -293,9 +294,9 @@ void LDesktopUtils::LoadSystemDefaults(bool skipOS){ // -- PANEL SETTINGS -- //(only works for the primary desktop at the moment) for(int i=1; i<11; i++){ - QString panvar = "panel"+QString::number(i); + QString panvar = "panel_"+deskID+"."+QString::number(i-1); tmp = sysDefaults.filter(panvar); - if(!tmp.isEmpty()){deskset << "[panel"+screen+"."+QString::number(i-1)+"]"; } + if(!tmp.isEmpty()){deskset << "["+panvar+"]"; } for(int i=0; i<tmp.length(); i++){ if(tmp[i].startsWith("#") || !tmp[i].contains("=") ){ continue; } QString var = tmp[i].section("=",0,0).toLower().simplified(); -- cgit From 86fc339b032d454469c966066d9b4ca61f844e30 Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Tue, 22 Nov 2016 14:16:14 -0500 Subject: Oops - NOW the desktop/panel settings-reload will work. --- src-qt5/core/libLumina/LDesktopUtils.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/core/libLumina/LDesktopUtils.cpp b/src-qt5/core/libLumina/LDesktopUtils.cpp index 80135ed0..978ce70b 100644 --- a/src-qt5/core/libLumina/LDesktopUtils.cpp +++ b/src-qt5/core/libLumina/LDesktopUtils.cpp @@ -271,8 +271,8 @@ void LDesktopUtils::LoadSystemDefaults(bool skipOS){ // -- DESKTOP SETTINGS -- QString deskID = QApplication::primaryScreen()->name(); //(only works for the primary desktop at the moment) - tmp = sysDefaults.filter("desktop-"+deskID); - if(tmp.isEmpty()){ tmp = sysDefaults.filter("desktop."+deskID); }//for backwards compat + tmp = sysDefaults.filter("desktop_"); + if(tmp.isEmpty()){ tmp = sysDefaults.filter("desktop."); }//for backwards compat if(!tmp.isEmpty()){deskset << "[desktop-"+deskID+"]"; } for(int i=0; i<tmp.length(); i++){ if(tmp[i].startsWith("#") || !tmp[i].contains("=") ){ continue; } @@ -294,9 +294,9 @@ void LDesktopUtils::LoadSystemDefaults(bool skipOS){ // -- PANEL SETTINGS -- //(only works for the primary desktop at the moment) for(int i=1; i<11; i++){ - QString panvar = "panel_"+deskID+"."+QString::number(i-1); + QString panvar = "panel"+QString::number(i); tmp = sysDefaults.filter(panvar); - if(!tmp.isEmpty()){deskset << "["+panvar+"]"; } + if(!tmp.isEmpty()){deskset << "[panel_"+deskID+"."+QString::number(i-1)+"]"; } for(int i=0; i<tmp.length(); i++){ if(tmp[i].startsWith("#") || !tmp[i].contains("=") ){ continue; } QString var = tmp[i].section("=",0,0).toLower().simplified(); -- cgit From 61ec083ea62121a9eba88c4bd46f10be9b367f81 Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Tue, 22 Nov 2016 14:40:13 -0500 Subject: Add better error notifications when saving screenshots. --- src-qt5/desktop-utils/lumina-screenshot/MainUI.cpp | 26 +++++++++++++++++----- src-qt5/desktop-utils/lumina-screenshot/MainUI.h | 3 +++ 2 files changed, 23 insertions(+), 6 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/desktop-utils/lumina-screenshot/MainUI.cpp b/src-qt5/desktop-utils/lumina-screenshot/MainUI.cpp index 83940c93..16e7c77b 100644 --- a/src-qt5/desktop-utils/lumina-screenshot/MainUI.cpp +++ b/src-qt5/desktop-utils/lumina-screenshot/MainUI.cpp @@ -8,6 +8,8 @@ #include "ui_MainUI.h" #include <LuminaX11.h> +#include <QMessageBox> + MainUI::MainUI() : QMainWindow(), ui(new Ui::MainUI){ ui->setupUi(this); //load the designer file @@ -48,6 +50,7 @@ MainUI::MainUI() : QMainWindow(), ui(new Ui::MainUI){ this->show(); IMG->setDefaultSize(ui->scrollArea->maximumViewportSize()); IMG->LoadImage( QApplication::screens().at(0)->grabWindow(QApplication::desktop()->winId()).toImage() ); //initial screenshot + lastScreenShot = QDateTime::currentDateTime(); //ui->label_screenshot->setPixmap( cpic.scaled(ui->label_screenshot->size(), Qt::KeepAspectRatio, Qt::SmoothTransformation) ); } @@ -69,26 +72,36 @@ void MainUI::setupIcons(){ //ui->actionEdit->setIcon( LXDG::findIcon("applications-graphics","") ); } +void MainUI::showSaveError(QString path){ + QMessageBox::warning(this, tr("Could not save screenshot"), tr("The screenshot could not be saved. Please check directory permissions or pick a different directory")+"\n\n"+path); +} //============== // PRIVATE SLOTS //============== void MainUI::saveScreenshot(){ if(mousegrabbed){ return; } - QString filepath = QFileDialog::getSaveFileName(this, tr("Save Screenshot"), ppath, tr("PNG Files (*.png);;AllFiles (*)") ); + QString filepath = QFileDialog::getSaveFileName(this, tr("Save Screenshot"), ppath+"/"+QString( "Screenshot-%1.png" ).arg( lastScreenShot.toString("yyyy-MM-dd-hh-mm-ss")), tr("PNG Files (*.png);;AllFiles (*)") ); if(filepath.isEmpty()){ return; } if(!filepath.endsWith(".png")){ filepath.append(".png"); } - IMG->image().save(filepath, "png"); - ppath = filepath; + if( !IMG->image().save(filepath, "png") ){ + showSaveError(filepath); + }else{ + ppath = filepath.section("/",0,-2); //just the directory + } } + void MainUI::quicksave(){ if(mousegrabbed){ return; } QString savedir = QDir::homePath()+"/"; if(QFile::exists(savedir + "Pictures/")){ savedir.append("Pictures/"); } else if(QFile::exists(savedir + "Images/")){ savedir.append("Images/"); } - QString path = savedir + QString( "Screenshot-%1.png" ).arg( QDateTime::currentDateTime().toString("yyyy-MM-dd-hh-mm-ss") ); - IMG->image().save(path, "png"); - QProcess::startDetached("lumina-open \""+path+"\""); + QString path = savedir + QString( "Screenshot-%1.png" ).arg( lastScreenShot.toString("yyyy-MM-dd-hh-mm-ss") ); + if(IMG->image().save(path, "png") ){ + QProcess::startDetached("lumina-open \""+path+"\""); + }else{ + showSaveError(path); + } } void MainUI::startScreenshot(){ @@ -145,6 +158,7 @@ void MainUI::getPixmap(){ this->show(); this->setGeometry(lastgeom); ui->tabWidget->setCurrentWidget(ui->tab_view); //view it right now + lastScreenShot = QDateTime::currentDateTime(); //Now display the pixmap on the label as well IMG->LoadImage( cpic.toImage() ); } diff --git a/src-qt5/desktop-utils/lumina-screenshot/MainUI.h b/src-qt5/desktop-utils/lumina-screenshot/MainUI.h index 00b3f8ac..69c9bf26 100644 --- a/src-qt5/desktop-utils/lumina-screenshot/MainUI.h +++ b/src-qt5/desktop-utils/lumina-screenshot/MainUI.h @@ -49,6 +49,9 @@ private: //Image Editor widget ImageEditor *IMG; + QDateTime lastScreenShot; + + void showSaveError(QString path); private slots: //Button Slots -- cgit From 5bedc7e5673928ff0424da1b2719f0d75f62a8cf Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Tue, 22 Nov 2016 15:45:14 -0500 Subject: Fix up the scaling options in the UI for lumina-screenshot. --- .../lumina-screenshot/ImageEditor.cpp | 31 ++++++-- .../desktop-utils/lumina-screenshot/ImageEditor.h | 5 +- src-qt5/desktop-utils/lumina-screenshot/MainUI.cpp | 15 +++- src-qt5/desktop-utils/lumina-screenshot/MainUI.h | 2 + src-qt5/desktop-utils/lumina-screenshot/MainUI.ui | 83 +++++++++++++++++----- 5 files changed, 112 insertions(+), 24 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/desktop-utils/lumina-screenshot/ImageEditor.cpp b/src-qt5/desktop-utils/lumina-screenshot/ImageEditor.cpp index 7516f204..fa5a7318 100644 --- a/src-qt5/desktop-utils/lumina-screenshot/ImageEditor.cpp +++ b/src-qt5/desktop-utils/lumina-screenshot/ImageEditor.cpp @@ -27,6 +27,7 @@ void ImageEditor::LoadImage(QImage img){ this->update(); //trigger paint event selRect = QRect(); emit selectionChanged(false); + emit scaleFactorChanged(getScaleFactor()*100); } void ImageEditor::setDefaultSize(QSize sz){ @@ -53,24 +54,37 @@ QImage ImageEditor::image(){ return fullIMG; } +int ImageEditor::getScalingValue(){ + return (getScaleFactor() *100); +} + // === PRIVATE SLOTS === void ImageEditor::showMenu(){ contextMenu->popup(QCursor::pos()); } // === PUBLIC SLOTS === +void ImageEditor::setScaling(int perc){ + qreal sf = ((qreal) perc)/100.0; + if(sf<0.05){ sf = 0.05; } //5% minimum + else if(sf>2){ sf = 2.0; } //200% maximum + rescaleImage(sf); +} + void ImageEditor::scaleUp(int val){ qreal sf = getScaleFactor(); sf+= ((qreal) val)/100.0; if(sf>2){ sf = 2.0; } rescaleImage(sf); + emit scaleFactorChanged(sf*100); } void ImageEditor::scaleDown(int val){ qreal sf = getScaleFactor(); sf-= ((qreal) val)/100.0; - if(sf<0.1){ sf = 0.1; } + if(sf<0.05){ sf = 0.05; } rescaleImage(sf); + emit scaleFactorChanged(sf*100); } void ImageEditor::cropImage(){ @@ -81,6 +95,7 @@ void ImageEditor::cropImage(){ scaledIMG = fullIMG.scaled( defaultSize, Qt::KeepAspectRatio,Qt::SmoothTransformation); selRect = QRect(); emit selectionChanged(false); + emit scaleFactorChanged(getScaleFactor()*100); this->update(); //trigger paint event } @@ -94,28 +109,34 @@ void ImageEditor::resizeImage(){ void ImageEditor::mousePressEvent(QMouseEvent *ev){ selRect = QRect(); //reset it emit selectionChanged(false); - selPoint = ev->pos(); //widget-relative coords + if(scaledIMG.rect().contains(ev->pos())){ + selPoint = ev->pos(); //widget-relative coords + }else{ + selPoint = QPoint(); + } } void ImageEditor::mouseMoveEvent(QMouseEvent *ev){ - if( !this->geometry().contains(ev->pos()) ){ selRect = QRect(); } + if( selPoint.isNull() ){ return; } else if(selPoint.x() < ev->pos().x()){ if(selPoint.y() < ev->pos().y()){ //init point is upper-left corner - selRect = QRect(selPoint, ev->pos()); + selRect = QRect(selPoint, ev->pos()).intersected(scaledIMG.rect()); }else{ //init point is lower-left corner selRect.setBottomLeft(selPoint); selRect.setTopRight(ev->pos()); + selRect = selRect.intersected(scaledIMG.rect()); } }else{ if(selPoint.y() < ev->pos().y()){ //init point is upper-right corner selRect.setBottomLeft(ev->pos()); selRect.setTopRight(selPoint); + selRect = selRect.intersected(scaledIMG.rect()); }else{ //init point is lower-right corner - selRect = QRect(ev->pos(), selPoint); + selRect = QRect(ev->pos(), selPoint).intersected(scaledIMG.rect()); } } this->update(); diff --git a/src-qt5/desktop-utils/lumina-screenshot/ImageEditor.h b/src-qt5/desktop-utils/lumina-screenshot/ImageEditor.h index 58a16e56..869c49fc 100644 --- a/src-qt5/desktop-utils/lumina-screenshot/ImageEditor.h +++ b/src-qt5/desktop-utils/lumina-screenshot/ImageEditor.h @@ -28,6 +28,8 @@ public: bool hasSelection(); QImage image(); + int getScalingValue(); + private: QImage fullIMG, scaledIMG; //Note: the aspect ratio between the two images must be preserved!! QSize defaultSize; //for loading new images @@ -53,6 +55,7 @@ private slots: void showMenu(); public slots: + void setScaling(int perc); //10% <--> 200% range is valid void scaleUp(int val = 10); //10% change by default void scaleDown(int val = 10); //10% change by default @@ -67,6 +70,6 @@ protected: signals: void selectionChanged(bool); //true if there is a selection - + void scaleFactorChanged(int); }; #endif diff --git a/src-qt5/desktop-utils/lumina-screenshot/MainUI.cpp b/src-qt5/desktop-utils/lumina-screenshot/MainUI.cpp index 16e7c77b..9dd6c9d3 100644 --- a/src-qt5/desktop-utils/lumina-screenshot/MainUI.cpp +++ b/src-qt5/desktop-utils/lumina-screenshot/MainUI.cpp @@ -19,7 +19,7 @@ MainUI::MainUI() : QMainWindow(), ui(new Ui::MainUI){ ui->scrollArea->setWidget(IMG); ui->tabWidget->setCurrentWidget(ui->tab_view); ppath = QDir::homePath(); - + ui->label_zoom_percent->setMinimumWidth( ui->label_zoom_percent->fontMetrics().width("200%") ); setupIcons(); ui->spin_monitor->setMaximum(QApplication::desktop()->screenCount()); if(ui->spin_monitor->maximum()<2){ @@ -37,6 +37,8 @@ MainUI::MainUI() : QMainWindow(), ui(new Ui::MainUI){ connect(ui->actionTake_Screenshot, SIGNAL(triggered()), this, SLOT(startScreenshot()) ); connect(ui->tool_crop, SIGNAL(clicked()), IMG, SLOT(cropImage()) ); connect(IMG, SIGNAL(selectionChanged(bool)), this, SLOT(imgselchanged(bool)) ); + connect(IMG, SIGNAL(scaleFactorChanged(int)), this, SLOT(imgScalingChanged(int)) ); + connect(ui->slider_zoom, SIGNAL(valueChanged(int)), this, SLOT(imgScalingChanged()) ); settings = new QSettings("lumina-desktop", "lumina-screenshot",this); if(settings->value("screenshot-target", "window").toString() == "window") { @@ -117,6 +119,17 @@ void MainUI::imgselchanged(bool hassel){ ui->tool_resize->setEnabled(hassel); } +void MainUI::imgScalingChanged(int percent){ + //qDebug() << "Scale Changed:" << percent; + if(percent<0){ + //Changed by user interaction + IMG->setScaling(ui->slider_zoom->value()); + }else{ + ui->slider_zoom->setValue(percent); + } + ui->label_zoom_percent->setText( QString::number(ui->slider_zoom->value())+"%"); +} + bool MainUI::getWindow(){ //Use this function to set cwin cwin = 0; diff --git a/src-qt5/desktop-utils/lumina-screenshot/MainUI.h b/src-qt5/desktop-utils/lumina-screenshot/MainUI.h index 69c9bf26..f7319541 100644 --- a/src-qt5/desktop-utils/lumina-screenshot/MainUI.h +++ b/src-qt5/desktop-utils/lumina-screenshot/MainUI.h @@ -64,6 +64,8 @@ private slots: void startScreenshot(); void imgselchanged(bool hassel); + void imgScalingChanged(int percent = -1); + //Utility functions to perform a screenshot bool getWindow(); //set the "cwin" variable as appropriate void getPixmap(); //set the "cpic" variable to the new screenshot diff --git a/src-qt5/desktop-utils/lumina-screenshot/MainUI.ui b/src-qt5/desktop-utils/lumina-screenshot/MainUI.ui index db1c0cee..22b99b72 100644 --- a/src-qt5/desktop-utils/lumina-screenshot/MainUI.ui +++ b/src-qt5/desktop-utils/lumina-screenshot/MainUI.ui @@ -11,7 +11,7 @@ </rect> </property> <property name="windowTitle"> - <string>Take Screenshot</string> + <string>Lumina Screenshot</string> </property> <widget class="QWidget" name="centralwidget"> <layout class="QVBoxLayout" name="verticalLayout"> @@ -188,21 +188,70 @@ <number>1</number> </property> <item> - <widget class="QScrollArea" name="scrollArea"> - <property name="widgetResizable"> - <bool>true</bool> - </property> - <widget class="QWidget" name="scrollAreaWidgetContents"> - <property name="geometry"> - <rect> - <x>0</x> - <y>0</y> - <width>341</width> - <height>171</height> - </rect> - </property> - </widget> - </widget> + <layout class="QHBoxLayout" name="horizontalLayout_4"> + <item> + <layout class="QVBoxLayout" name="verticalLayout_4"> + <item> + <widget class="QLabel" name="label_zoom_percent"> + <property name="minimumSize"> + <size> + <width>0</width> + <height>0</height> + </size> + </property> + <property name="text"> + <string notr="true"/> + </property> + <property name="alignment"> + <set>Qt::AlignCenter</set> + </property> + </widget> + </item> + <item> + <widget class="QSlider" name="slider_zoom"> + <property name="minimum"> + <number>5</number> + </property> + <property name="maximum"> + <number>200</number> + </property> + <property name="singleStep"> + <number>5</number> + </property> + <property name="value"> + <number>100</number> + </property> + <property name="orientation"> + <enum>Qt::Vertical</enum> + </property> + <property name="tickPosition"> + <enum>QSlider::TicksBothSides</enum> + </property> + <property name="tickInterval"> + <number>20</number> + </property> + </widget> + </item> + </layout> + </item> + <item> + <widget class="QScrollArea" name="scrollArea"> + <property name="widgetResizable"> + <bool>true</bool> + </property> + <widget class="QWidget" name="scrollAreaWidgetContents"> + <property name="geometry"> + <rect> + <x>0</x> + <y>0</y> + <width>306</width> + <height>173</height> + </rect> + </property> + </widget> + </widget> + </item> + </layout> </item> <item> <layout class="QHBoxLayout" name="horizontalLayout_2"> @@ -274,7 +323,7 @@ <x>0</x> <y>0</y> <width>349</width> - <height>23</height> + <height>22</height> </rect> </property> <widget class="QMenu" name="menuFile"> -- cgit From 102f7c729e55ae92b1bb4b0928dde030a2766b79 Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Mon, 28 Nov 2016 08:07:29 -0500 Subject: A few important fixes for lumina-search: 1) Ensure the background search process gets stopped when the app is closed. 2) Add a limit of 100 items to the search results (any more than that and the user should refine their search term) 3) Make sure that any "proc" directory on the system is always excluded from the search. This directory heirarchy is highly recursive in nature and should never really be used for searches anyway. 4) Increase the time delay before starting any live search to 1/2 second (used to be 1/3 second). --- src-qt5/core-utils/lumina-search/MainUI.cpp | 4 +++- src-qt5/core-utils/lumina-search/Worker.cpp | 3 ++- 2 files changed, 5 insertions(+), 2 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/core-utils/lumina-search/MainUI.cpp b/src-qt5/core-utils/lumina-search/MainUI.cpp index 93ee7411..b3e28f8a 100644 --- a/src-qt5/core-utils/lumina-search/MainUI.cpp +++ b/src-qt5/core-utils/lumina-search/MainUI.cpp @@ -17,7 +17,7 @@ MainUI::MainUI() : QMainWindow(), ui(new Ui::MainUI){ ui->tool_configure->setVisible(false); //app search initially set livetime = new QTimer(this); - livetime->setInterval(300); //1/3 second for live searches + livetime->setInterval(500); //1/2 second for live searches livetime->setSingleShot(true); workthread = new QThread(this); @@ -56,6 +56,7 @@ MainUI::MainUI() : QMainWindow(), ui(new Ui::MainUI){ } MainUI::~MainUI(){ + searcher->StopSearch(); workthread->quit(); workthread->wait(); } @@ -189,6 +190,7 @@ void MainUI::foundSearchItem(QString path){ } //Now add it to the widget ui->listWidget->addItem(it); + if(ui->listWidget->count()>100){ searcher->StopSearch(); } //just in case } void MainUI::stopSearch(){ diff --git a/src-qt5/core-utils/lumina-search/Worker.cpp b/src-qt5/core-utils/lumina-search/Worker.cpp index 677d2b4b..df1a0c3c 100644 --- a/src-qt5/core-utils/lumina-search/Worker.cpp +++ b/src-qt5/core-utils/lumina-search/Worker.cpp @@ -52,7 +52,8 @@ bool Worker::searchDir(QString dirpath){ tmp = dir.entryList(QDir::Dirs | QDir::NoDotAndDotDot , QDir::Name); for(int i=0; i<tmp.length(); i++){ if(stopsearch){ return true; } - if( skipDirs.contains(dir.absoluteFilePath(tmp[i])) ){ continue; } //this dir is skipped + if( skipDirs.contains(dir.absoluteFilePath(tmp[i])) || tmp[i]=="proc" ){ continue; } //this dir is skipped + //Special case - skip the "proc" directory heirarchy (highly-recursive layout for *every* process which is running) if( searchDir(dir.absoluteFilePath(tmp[i])) ){ return true; } } return false; -- cgit From 33010dd68c2a80edde7dd9b219a4383453fd132b Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Mon, 28 Nov 2016 08:22:16 -0500 Subject: Fix up the loading of the "show hidden files" option at the start of a browser widget in lumina-fm. --- src-qt5/desktop-utils/lumina-fm/MainUI.cpp | 1 + 1 file changed, 1 insertion(+) (limited to 'src-qt5') diff --git a/src-qt5/desktop-utils/lumina-fm/MainUI.cpp b/src-qt5/desktop-utils/lumina-fm/MainUI.cpp index 0744ac84..b017600b 100644 --- a/src-qt5/desktop-utils/lumina-fm/MainUI.cpp +++ b/src-qt5/desktop-utils/lumina-fm/MainUI.cpp @@ -179,6 +179,7 @@ void MainUI::OpenDirs(QStringList dirs){ //Initialize the widget with the proper settings DW->setShowDetails(radio_view_details->isChecked()); DW->setThumbnailSize(settings->value("iconsize", 32).toInt()); + DW->showHidden( ui->actionView_Hidden_Files->isChecked() ); //Now load the directory DW->ChangeDir(dirs[i]); //kick off loading the directory info } -- cgit From 24d88d1ac4d316da3527b236c6cedb2b4a90bc85 Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Mon, 28 Nov 2016 08:58:10 -0500 Subject: Fix up the regular expression strip of the ZFS snapshot from the full path. --- src-qt5/desktop-utils/lumina-fm/widgets/DirWidget2.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src-qt5') diff --git a/src-qt5/desktop-utils/lumina-fm/widgets/DirWidget2.cpp b/src-qt5/desktop-utils/lumina-fm/widgets/DirWidget2.cpp index 29adf09d..48ad6aa5 100644 --- a/src-qt5/desktop-utils/lumina-fm/widgets/DirWidget2.cpp +++ b/src-qt5/desktop-utils/lumina-fm/widgets/DirWidget2.cpp @@ -513,7 +513,8 @@ void DirWidget::currentDirectoryChanged(bool widgetonly){ qDebug() << "Changed to directory:" << cur; }else{ //Re-assemble the normalbasedir variable (in case moving around within a snapshot) - normalbasedir = cur.replace( QRegExp("/\\.zfs/snapshot/(.)+/"), "/" ); + normalbasedir = cur; + normalbasedir.replace( QRegExp("\\/\\.zfs\\/snapshot/([^/]+)\\/"), "/" ); qDebug() << "Changed to snapshot:" << cur << normalbasedir; } ui->actionBack->setEnabled( currentBrowser()->history().length()>1 ); -- cgit From 1567c8875ea5473a9c7e2c3fbd0537fe944b9778 Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Mon, 28 Nov 2016 15:00:30 -0500 Subject: Add a small 1/5 second delay between the zoom slider changing and the actual update of the zoom level (prevent flickering and seizures from rapidly changing the slider). --- src-qt5/desktop-utils/lumina-screenshot/MainUI.cpp | 11 ++++++++++- src-qt5/desktop-utils/lumina-screenshot/MainUI.h | 2 ++ 2 files changed, 12 insertions(+), 1 deletion(-) (limited to 'src-qt5') diff --git a/src-qt5/desktop-utils/lumina-screenshot/MainUI.cpp b/src-qt5/desktop-utils/lumina-screenshot/MainUI.cpp index 9dd6c9d3..ac17ee3e 100644 --- a/src-qt5/desktop-utils/lumina-screenshot/MainUI.cpp +++ b/src-qt5/desktop-utils/lumina-screenshot/MainUI.cpp @@ -26,6 +26,9 @@ MainUI::MainUI() : QMainWindow(), ui(new Ui::MainUI){ ui->spin_monitor->setEnabled(false); ui->radio_monitor->setEnabled(false); } + scaleTimer = new QTimer(this); + scaleTimer->setSingleShot(true); + scaleTimer->setInterval(200); //~1/5 second //Setup the connections connect(ui->tool_save, SIGNAL(clicked()), this, SLOT(saveScreenshot()) ); @@ -38,7 +41,8 @@ MainUI::MainUI() : QMainWindow(), ui(new Ui::MainUI){ connect(ui->tool_crop, SIGNAL(clicked()), IMG, SLOT(cropImage()) ); connect(IMG, SIGNAL(selectionChanged(bool)), this, SLOT(imgselchanged(bool)) ); connect(IMG, SIGNAL(scaleFactorChanged(int)), this, SLOT(imgScalingChanged(int)) ); - connect(ui->slider_zoom, SIGNAL(valueChanged(int)), this, SLOT(imgScalingChanged()) ); + connect(ui->slider_zoom, SIGNAL(valueChanged(int)), this, SLOT(sliderChanged()) ); + connect(scaleTimer, SIGNAL(timeout()), this, SLOT(imgScalingChanged()) ); settings = new QSettings("lumina-desktop", "lumina-screenshot",this); if(settings->value("screenshot-target", "window").toString() == "window") { @@ -130,6 +134,11 @@ void MainUI::imgScalingChanged(int percent){ ui->label_zoom_percent->setText( QString::number(ui->slider_zoom->value())+"%"); } +void MainUI::sliderChanged(){ + ui->label_zoom_percent->setText( QString::number(ui->slider_zoom->value())+"%"); + scaleTimer->start(); +} + bool MainUI::getWindow(){ //Use this function to set cwin cwin = 0; diff --git a/src-qt5/desktop-utils/lumina-screenshot/MainUI.h b/src-qt5/desktop-utils/lumina-screenshot/MainUI.h index f7319541..bb1b61df 100644 --- a/src-qt5/desktop-utils/lumina-screenshot/MainUI.h +++ b/src-qt5/desktop-utils/lumina-screenshot/MainUI.h @@ -46,6 +46,7 @@ private: WId cwin; //current window to screenshot QSettings *settings; LXCB *XCB; //Library access to window subsystems + QTimer *scaleTimer; //Image Editor widget ImageEditor *IMG; @@ -65,6 +66,7 @@ private slots: void imgselchanged(bool hassel); void imgScalingChanged(int percent = -1); + void sliderChanged(); //Utility functions to perform a screenshot bool getWindow(); //set the "cwin" variable as appropriate -- cgit From 37c099c421884041c9e50837708639a95328e31b Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Tue, 29 Nov 2016 08:32:43 -0500 Subject: Fix a recursive bug in the parenthesis matching/replacing routine within lumina-calculator. --- src-qt5/desktop-utils/lumina-calculator/mainUI.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/desktop-utils/lumina-calculator/mainUI.cpp b/src-qt5/desktop-utils/lumina-calculator/mainUI.cpp index fcc39fd2..057e4ddd 100644 --- a/src-qt5/desktop-utils/lumina-calculator/mainUI.cpp +++ b/src-qt5/desktop-utils/lumina-calculator/mainUI.cpp @@ -255,14 +255,16 @@ double mainUI::strToNumber(QString str){ if(need==0){ end = i; } } if(end<start){ return BADVALUE; } - //qDebug() << "Replace value:" << str << start << end << str.mid(start+1,end-start); + //qDebug() << "Replace value:" << str << start << end << str.mid(start+1,end-start-1); double tmp = strToNumber( str.mid(start+1, end-start-1)); if(tmp!=tmp){ return BADVALUE; } //not a number //Now check really quick if this was an argument to a scientific operation + //qDebug() << "Got Number:" << tmp; for(int i=start-1; i>=0; i-- ){ + //qDebug() << "Check for function:" << start << i << str[i]; if( !str[i].isLower() || i==0 ){ if(!str[i].isLower()){ i++; }//don't need the invalid character - if(start-i<2){ continue; } //not long enough - 2+ chars for sci functions + if(start-i<2){ break; } //not long enough - 2+ chars for sci functions //Got a scientific operation - run it through the routine tmp = performSciOperation( str.mid(i, start-i), tmp); if(tmp!=tmp){ return BADVALUE; } //got a bad value -- cgit From e3d638e4b0e95da0b1cac6a4b0fd136cd533788a Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Wed, 30 Nov 2016 09:45:08 -0500 Subject: Cleanup the bootsplash a bit: 1) Move the loading message/progress to the bottom of the window. 2) Move the loading icon to the top-left side 3) Implement the (optional) usage of the "fortune" utility for a random/short message during the loading process. --- src-qt5/core/lumina-desktop/BootSplash.cpp | 8 +- src-qt5/core/lumina-desktop/BootSplash.ui | 197 +++++++++++++++++++---------- 2 files changed, 139 insertions(+), 66 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/core/lumina-desktop/BootSplash.cpp b/src-qt5/core/lumina-desktop/BootSplash.cpp index e75bca21..e8a2decc 100644 --- a/src-qt5/core/lumina-desktop/BootSplash.cpp +++ b/src-qt5/core/lumina-desktop/BootSplash.cpp @@ -2,6 +2,7 @@ #include "ui_BootSplash.h" #include <LuminaXDG.h> +#include <LUtils.h> BootSplash::BootSplash() : QWidget(0, Qt::SplashScreen | Qt::X11BypassWindowManagerHint | Qt::WindowStaysOnTopHint | Qt::WindowDoesNotAcceptFocus), ui(new Ui::BootSplash){ ui->setupUi(this); @@ -9,6 +10,11 @@ BootSplash::BootSplash() : QWidget(0, Qt::SplashScreen | Qt::X11BypassWindowMana //Center the window on the primary screen QPoint ctr = QApplication::desktop()->screenGeometry().center(); this->move( ctr.x()-(this->width()/2), ctr.y()-(this->height()/2) ); + if(LUtils::isValidBinary("fortune")){ + QString random = LUtils::getCmdOutput("fortune -s").join("\n").simplified(); + if(random.endsWith("\n")){ random.chop(1); } + ui->label_welcome->setText( "\""+random+"\"" ); + } } void BootSplash::showScreen(QString loading){ //update icon, text, and progress @@ -40,7 +46,7 @@ void BootSplash::showScreen(QString loading){ //update icon, text, and progress icon = "preferences-desktop-wallpaper"; }else if(loading=="final"){ txt = tr("Finalizing …"); per = 90; - icon = "pcbsd"; + icon = "start-here-lumina"; }else if(loading.startsWith("app::")){ txt = QString(tr("Starting App: %1")).arg(loading.section("::",1,50)); per = -1; } diff --git a/src-qt5/core/lumina-desktop/BootSplash.ui b/src-qt5/core/lumina-desktop/BootSplash.ui index 867b658c..7b2bebf9 100644 --- a/src-qt5/core/lumina-desktop/BootSplash.ui +++ b/src-qt5/core/lumina-desktop/BootSplash.ui @@ -6,82 +6,149 @@ <rect> <x>0</x> <y>0</y> - <width>280</width> - <height>127</height> + <width>314</width> + <height>194</height> </rect> </property> <property name="windowTitle"> <string>Form</string> </property> - <layout class="QGridLayout" name="gridLayout"> - <item row="0" column="4"> - <spacer name="horizontalSpacer"> - <property name="orientation"> - <enum>Qt::Horizontal</enum> - </property> - <property name="sizeHint" stdset="0"> - <size> - <width>40</width> - <height>20</height> - </size> - </property> - </spacer> + <layout class="QVBoxLayout" name="verticalLayout"> + <property name="spacing"> + <number>1</number> + </property> + <property name="leftMargin"> + <number>1</number> + </property> + <property name="topMargin"> + <number>1</number> + </property> + <property name="rightMargin"> + <number>1</number> + </property> + <property name="bottomMargin"> + <number>1</number> + </property> + <item> + <layout class="QGridLayout" name="gridLayout"> + <item row="2" column="0"> + <spacer name="verticalSpacer"> + <property name="orientation"> + <enum>Qt::Vertical</enum> + </property> + <property name="sizeHint" stdset="0"> + <size> + <width>20</width> + <height>40</height> + </size> + </property> + </spacer> + </item> + <item row="1" column="0"> + <widget class="QLabel" name="label_icon"> + <property name="minimumSize"> + <size> + <width>64</width> + <height>64</height> + </size> + </property> + <property name="maximumSize"> + <size> + <width>64</width> + <height>16777215</height> + </size> + </property> + <property name="text"> + <string notr="true"/> + </property> + <property name="alignment"> + <set>Qt::AlignCenter</set> + </property> + </widget> + </item> + <item row="0" column="0"> + <spacer name="verticalSpacer_2"> + <property name="orientation"> + <enum>Qt::Vertical</enum> + </property> + <property name="sizeHint" stdset="0"> + <size> + <width>20</width> + <height>40</height> + </size> + </property> + </spacer> + </item> + <item row="0" column="1" rowspan="3"> + <widget class="QLabel" name="label_welcome"> + <property name="sizePolicy"> + <sizepolicy hsizetype="Preferred" vsizetype="Expanding"> + <horstretch>0</horstretch> + <verstretch>0</verstretch> + </sizepolicy> + </property> + <property name="text"> + <string>Welcome to the Lumina Desktop Environment!</string> + </property> + <property name="alignment"> + <set>Qt::AlignCenter</set> + </property> + <property name="wordWrap"> + <bool>true</bool> + </property> + </widget> + </item> + </layout> </item> - <item row="0" column="2"> - <widget class="QLabel" name="label_icon"> - <property name="minimumSize"> - <size> - <width>64</width> - <height>64</height> - </size> - </property> - <property name="text"> - <string notr="true"/> - </property> - <property name="alignment"> - <set>Qt::AlignCenter</set> - </property> - </widget> - </item> - <item row="0" column="0" rowspan="2"> - <widget class="QProgressBar" name="progressBar"> - <property name="value"> - <number>0</number> - </property> - <property name="orientation"> - <enum>Qt::Vertical</enum> - </property> - <property name="format"> - <string/> - </property> - </widget> - </item> - <item row="0" column="1"> - <spacer name="horizontalSpacer_2"> + <item> + <widget class="Line" name="line"> <property name="orientation"> <enum>Qt::Horizontal</enum> </property> - <property name="sizeHint" stdset="0"> - <size> - <width>40</width> - <height>20</height> - </size> - </property> - </spacer> - </item> - <item row="1" column="1" colspan="4"> - <widget class="QLabel" name="label_text"> - <property name="text"> - <string notr="true">Some loading message</string> - </property> - <property name="alignment"> - <set>Qt::AlignCenter</set> - </property> - <property name="wordWrap"> - <bool>true</bool> - </property> </widget> </item> + <item> + <layout class="QHBoxLayout" name="horizontalLayout"> + <item> + <widget class="QProgressBar" name="progressBar"> + <property name="sizePolicy"> + <sizepolicy hsizetype="Preferred" vsizetype="Preferred"> + <horstretch>0</horstretch> + <verstretch>0</verstretch> + </sizepolicy> + </property> + <property name="value"> + <number>0</number> + </property> + <property name="orientation"> + <enum>Qt::Horizontal</enum> + </property> + <property name="format"> + <string/> + </property> + </widget> + </item> + <item> + <widget class="QLabel" name="label_text"> + <property name="sizePolicy"> + <sizepolicy hsizetype="Expanding" vsizetype="Preferred"> + <horstretch>0</horstretch> + <verstretch>0</verstretch> + </sizepolicy> + </property> + <property name="text"> + <string notr="true">Some loading message</string> + </property> + <property name="alignment"> + <set>Qt::AlignCenter</set> + </property> + <property name="wordWrap"> + <bool>true</bool> + </property> + </widget> + </item> + </layout> + </item> </layout> </widget> <resources/> -- cgit From d3b332c98f7d7ff105e39b3ae2bbf88ad5fcd9cd Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Wed, 30 Nov 2016 10:04:52 -0500 Subject: A few more tweaks for the boot splash. Font weights and such to better accent the rest of the UI. --- src-qt5/core/lumina-desktop/BootSplash.ui | 60 ++++++++++++++++++++++--------- src-qt5/core/lumina-desktop/LSession.cpp | 3 ++ 2 files changed, 46 insertions(+), 17 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/core/lumina-desktop/BootSplash.ui b/src-qt5/core/lumina-desktop/BootSplash.ui index 7b2bebf9..43070eee 100644 --- a/src-qt5/core/lumina-desktop/BootSplash.ui +++ b/src-qt5/core/lumina-desktop/BootSplash.ui @@ -80,23 +80,49 @@ </spacer> </item> <item row="0" column="1" rowspan="3"> - <widget class="QLabel" name="label_welcome"> - <property name="sizePolicy"> - <sizepolicy hsizetype="Preferred" vsizetype="Expanding"> - <horstretch>0</horstretch> - <verstretch>0</verstretch> - </sizepolicy> - </property> - <property name="text"> - <string>Welcome to the Lumina Desktop Environment!</string> - </property> - <property name="alignment"> - <set>Qt::AlignCenter</set> - </property> - <property name="wordWrap"> - <bool>true</bool> - </property> - </widget> + <layout class="QVBoxLayout" name="verticalLayout_2"> + <item> + <widget class="QLabel" name="label"> + <property name="font"> + <font> + <weight>75</weight> + <bold>true</bold> + <underline>false</underline> + </font> + </property> + <property name="text"> + <string>Starting the Lumina Desktop...</string> + </property> + <property name="alignment"> + <set>Qt::AlignHCenter|Qt::AlignTop</set> + </property> + </widget> + </item> + <item> + <widget class="QLabel" name="label_welcome"> + <property name="sizePolicy"> + <sizepolicy hsizetype="Preferred" vsizetype="Expanding"> + <horstretch>0</horstretch> + <verstretch>0</verstretch> + </sizepolicy> + </property> + <property name="font"> + <font> + <italic>true</italic> + </font> + </property> + <property name="text"> + <string notr="true"/> + </property> + <property name="alignment"> + <set>Qt::AlignCenter</set> + </property> + <property name="wordWrap"> + <bool>true</bool> + </property> + </widget> + </item> + </layout> </item> </layout> </item> diff --git a/src-qt5/core/lumina-desktop/LSession.cpp b/src-qt5/core/lumina-desktop/LSession.cpp index 22439911..289d7ede 100644 --- a/src-qt5/core/lumina-desktop/LSession.cpp +++ b/src-qt5/core/lumina-desktop/LSession.cpp @@ -161,7 +161,10 @@ void LSession::setupSession(){ for(int i=0; i<4; i++){ LSession::processEvents(); } //Again, just a few event loops here so thing can settle before we close the splash screen //launchStartupApps(); QTimer::singleShot(500, this, SLOT(launchStartupApps()) ); + splash.hide(); + LSession::processEvents(); splash.close(); + LSession::processEvents(); } void LSession::CleanupSession(){ -- cgit From 86f47941e8335e24e18093b365a320f89d0dfebc Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Wed, 30 Nov 2016 12:58:12 -0500 Subject: Get rid of the whitespace between mimetype registrations in the lumina-archiver.desktop file. --- src-qt5/desktop-utils/lumina-archiver/lumina-archiver.desktop | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src-qt5') diff --git a/src-qt5/desktop-utils/lumina-archiver/lumina-archiver.desktop b/src-qt5/desktop-utils/lumina-archiver/lumina-archiver.desktop index f0b6772d..4eea58c5 100644 --- a/src-qt5/desktop-utils/lumina-archiver/lumina-archiver.desktop +++ b/src-qt5/desktop-utils/lumina-archiver/lumina-archiver.desktop @@ -5,6 +5,6 @@ Terminal=false Type=Application StartupNotify=true Categories=Utility; -MimeType=application/x-xz-compressed-tar; application/x-lzma-compressed-tar; application/x-bzip-compressed-tar; application/x-tar; application/x-compressed-tar; application/zip; +MimeType=application/x-xz-compressed-tar;application/x-lzma-compressed-tar;application/x-bzip-compressed-tar;application/x-tar;application/x-compressed-tar;application/zip; Name=Lumina Archiver Comment=Archive creator and viewer -- cgit From d4f8bc41d53b85b1d3639fdc129f369e7f1b581e Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Wed, 30 Nov 2016 13:08:30 -0500 Subject: Unify the icons used for battery indications within the start menu and battery plugin. Also, add a green background to the battery plugin when the charge is 100% and still plugged in. --- src-qt5/core/lumina-desktop/panel-plugins/battery/LBattery.cpp | 3 ++- .../core/lumina-desktop/panel-plugins/systemstart/StartMenu.cpp | 9 ++++----- 2 files changed, 6 insertions(+), 6 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/core/lumina-desktop/panel-plugins/battery/LBattery.cpp b/src-qt5/core/lumina-desktop/panel-plugins/battery/LBattery.cpp index af081191..ee379613 100644 --- a/src-qt5/core/lumina-desktop/panel-plugins/battery/LBattery.cpp +++ b/src-qt5/core/lumina-desktop/panel-plugins/battery/LBattery.cpp @@ -1,6 +1,6 @@ //=========================================== // Lumina-DE source code -// Copyright (c) 2014, Susanne Jaeckel +// Copyright (c) 2014, Susanne Jaeckel, 2015-2016 Ken Moore // Available under the 3-clause BSD license // See the LICENSE file for full details //=========================================== @@ -81,6 +81,7 @@ void LBattery::updateBattery(bool force){ LSession::handle()->playAudioFile(LOS::LuminaShare()+"low-battery.ogg"); } if(icon==0){ label->setStyleSheet("QLabel{ background: red;}"); } + else if(icon==14 && charge>98){ label->setStyleSheet("QLabel{ background: green;}"); } else{ label->setStyleSheet("QLabel{ background: transparent;}"); } iconOld = icon; diff --git a/src-qt5/core/lumina-desktop/panel-plugins/systemstart/StartMenu.cpp b/src-qt5/core/lumina-desktop/panel-plugins/systemstart/StartMenu.cpp index 260215ec..a34d09db 100644 --- a/src-qt5/core/lumina-desktop/panel-plugins/systemstart/StartMenu.cpp +++ b/src-qt5/core/lumina-desktop/panel-plugins/systemstart/StartMenu.cpp @@ -488,11 +488,10 @@ void StartMenu::on_stackedWidget_currentChanged(int val){ //Battery available - update the status button int charge = LOS::batteryCharge(); QString TT, ICON; - if(charge < 10){ ICON="-low"; } - else if(charge<20){ ICON="-caution"; } - else if(charge<40){ ICON="-040"; } - else if(charge<60){ ICON="-060"; } - else if(charge<80){ ICON="-080"; } + if(charge<=5){ ICON="-caution"; } + else if(charge<=20){ ICON="-040"; } + else if(charge<=70){ ICON="-060"; } + else if(charge<=90){ ICON="-080"; } else{ ICON="-100"; } if(LOS::batteryIsCharging()){ if(charge>=80){ ICON.clear(); } //for charging, there is no suffix to the icon name over 80% -- cgit From 64840d4a66d791967bec1b2dbc0b18d0d8590d01 Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Wed, 30 Nov 2016 13:43:14 -0500 Subject: Fix up the permissions of extracted files via lumina-archiver. --- src-qt5/desktop-utils/lumina-archiver/TarBackend.cpp | 2 +- src-qt5/desktop-utils/lumina-archiver/lumina-archiver.desktop | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/desktop-utils/lumina-archiver/TarBackend.cpp b/src-qt5/desktop-utils/lumina-archiver/TarBackend.cpp index 919a6813..ddfd9d52 100644 --- a/src-qt5/desktop-utils/lumina-archiver/TarBackend.cpp +++ b/src-qt5/desktop-utils/lumina-archiver/TarBackend.cpp @@ -127,7 +127,7 @@ void Backend::startRemove(QStringList paths){ void Backend::startExtract(QString path, bool overwrite, QString file){ QStringList args; - args << "-x"; + args << "-x" << "--no-same-owner"; if(!overwrite){ args << "-k"; } args << flags; if(!file.isEmpty()){ args << "--include" << file << "--strip-components" << QString::number(file.count("/")); } diff --git a/src-qt5/desktop-utils/lumina-archiver/lumina-archiver.desktop b/src-qt5/desktop-utils/lumina-archiver/lumina-archiver.desktop index 4eea58c5..b0259aed 100644 --- a/src-qt5/desktop-utils/lumina-archiver/lumina-archiver.desktop +++ b/src-qt5/desktop-utils/lumina-archiver/lumina-archiver.desktop @@ -5,6 +5,6 @@ Terminal=false Type=Application StartupNotify=true Categories=Utility; -MimeType=application/x-xz-compressed-tar;application/x-lzma-compressed-tar;application/x-bzip-compressed-tar;application/x-tar;application/x-compressed-tar;application/zip; +MimeType=application/x-xz-compressed-tar;application/x-lzma-compressed-tar;application/x-bzip-compressed-tar;application/x-tar;application/x-compressed-tar;application/zip;application/gzip;application/bzip Name=Lumina Archiver Comment=Archive creator and viewer -- cgit From 6953a388620a15cd2e4d5620b32da5492abff9b9 Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Wed, 30 Nov 2016 14:07:37 -0500 Subject: Allow for multi-selection of items for extractions. --- src-qt5/desktop-utils/lumina-archiver/MainUI.cpp | 10 +++++++--- src-qt5/desktop-utils/lumina-archiver/MainUI.ui | 3 +++ src-qt5/desktop-utils/lumina-archiver/TarBackend.cpp | 8 +++++++- src-qt5/desktop-utils/lumina-archiver/TarBackend.h | 1 + 4 files changed, 18 insertions(+), 4 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/desktop-utils/lumina-archiver/MainUI.cpp b/src-qt5/desktop-utils/lumina-archiver/MainUI.cpp index 9d41374c..52831706 100644 --- a/src-qt5/desktop-utils/lumina-archiver/MainUI.cpp +++ b/src-qt5/desktop-utils/lumina-archiver/MainUI.cpp @@ -208,12 +208,16 @@ void MainUI::extractFiles(){ } void MainUI::extractSelection(){ - if(ui->tree_contents->currentItem()==0){ return; } - QString sel = ui->tree_contents->currentItem()->whatsThis(0); + if(ui->tree_contents->currentItem()==0){ return; } //nothing selected + QList<QTreeWidgetItem*> sel = ui->tree_contents->selectedItems(); + if(sel.isEmpty()){ sel << ui->tree_contents->currentItem(); } + QStringList selList; + for(int i=0; i<sel.length(); i++){ selList << sel[i]->whatsThis(0); } + selList.removeDuplicates(); QString dir = QFileDialog::getExistingDirectory(this, tr("Extract Into Directory"), QDir::homePath() ); if(dir.isEmpty()){ return; } ui->label_progress->setText(tr("Extracting...")); - BACKEND->startExtract(dir, true, sel); + BACKEND->startExtract(dir, true, selList); } void MainUI::ViewFile(QTreeWidgetItem *it){ diff --git a/src-qt5/desktop-utils/lumina-archiver/MainUI.ui b/src-qt5/desktop-utils/lumina-archiver/MainUI.ui index 1aff2e4f..45583ce3 100644 --- a/src-qt5/desktop-utils/lumina-archiver/MainUI.ui +++ b/src-qt5/desktop-utils/lumina-archiver/MainUI.ui @@ -47,6 +47,9 @@ </item> <item> <widget class="QTreeWidget" name="tree_contents"> + <property name="selectionMode"> + <enum>QAbstractItemView::ExtendedSelection</enum> + </property> <column> <property name="text"> <string notr="true">1</string> diff --git a/src-qt5/desktop-utils/lumina-archiver/TarBackend.cpp b/src-qt5/desktop-utils/lumina-archiver/TarBackend.cpp index ddfd9d52..f87506ec 100644 --- a/src-qt5/desktop-utils/lumina-archiver/TarBackend.cpp +++ b/src-qt5/desktop-utils/lumina-archiver/TarBackend.cpp @@ -126,11 +126,17 @@ void Backend::startRemove(QStringList paths){ } void Backend::startExtract(QString path, bool overwrite, QString file){ + startExtract(path, overwrite, QStringList() << file); //overload for multi-file function +} + +void Backend::startExtract(QString path, bool overwrite, QStringList files){ QStringList args; args << "-x" << "--no-same-owner"; if(!overwrite){ args << "-k"; } args << flags; - if(!file.isEmpty()){ args << "--include" << file << "--strip-components" << QString::number(file.count("/")); } + for(int i=0; i<files.length(); i++){ + args << "--include" << files[i] << "--strip-components" << QString::number(files[i].count("/")); + } args << "-C" << path; STARTING=true; //qDebug() << "Starting command:" << "tar" << args; diff --git a/src-qt5/desktop-utils/lumina-archiver/TarBackend.h b/src-qt5/desktop-utils/lumina-archiver/TarBackend.h index 47bc0bb6..ac2cb61f 100644 --- a/src-qt5/desktop-utils/lumina-archiver/TarBackend.h +++ b/src-qt5/desktop-utils/lumina-archiver/TarBackend.h @@ -36,6 +36,7 @@ public: void startAdd(QStringList paths); void startRemove(QStringList paths); void startExtract(QString path, bool overwrite, QString file=""); //path to dir, overwrite, optional file to extract (everything otherwise) + void startExtract(QString path, bool overwrite, QStringList files); void startViewFile(QString path); -- cgit From f9dd55960d1fa93882287b7949042273bda74183 Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Thu, 1 Dec 2016 08:23:27 -0500 Subject: Have lumina-archiver just open the containing folder when extracting multiple files. --- src-qt5/desktop-utils/lumina-archiver/TarBackend.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/desktop-utils/lumina-archiver/TarBackend.cpp b/src-qt5/desktop-utils/lumina-archiver/TarBackend.cpp index f87506ec..9a8cd5b7 100644 --- a/src-qt5/desktop-utils/lumina-archiver/TarBackend.cpp +++ b/src-qt5/desktop-utils/lumina-archiver/TarBackend.cpp @@ -214,12 +214,13 @@ void Backend::procFinished(int retcode, QProcess::ExitStatus){ QStringList args = PROC.arguments(); if(args.contains("-x") && retcode==0){ needupdate=false; - if(args.contains("--include")){ - //Need to find the full path to the extracted file + if(args.count("--include")==1){ + //Need to find the full path to the (single) extracted file QString path = args.last() +"/"+ args[ args.indexOf("--include")+1].section("/",-1); QFile::setPermissions(path, QFileDevice::ReadOwner); QProcess::startDetached("xdg-open \""+path+"\""); }else{ + //Multi-file extract - open the dir instead QProcess::startDetached("xdg-open \""+ args.last()+"\""); //just extracted to a dir - open it now } }else if(args.contains("-c") && QFile::exists(tmpfilepath)){ -- cgit From a3e934d2defa7831204ff2bd2e1bd030dcfae80c Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Thu, 1 Dec 2016 08:24:00 -0500 Subject: Add the Lumina version to the bottom of the boot splash as well. --- src-qt5/core/lumina-desktop/BootSplash.cpp | 2 ++ src-qt5/core/lumina-desktop/BootSplash.ui | 16 ++++++++++++++++ 2 files changed, 18 insertions(+) (limited to 'src-qt5') diff --git a/src-qt5/core/lumina-desktop/BootSplash.cpp b/src-qt5/core/lumina-desktop/BootSplash.cpp index e8a2decc..f7981670 100644 --- a/src-qt5/core/lumina-desktop/BootSplash.cpp +++ b/src-qt5/core/lumina-desktop/BootSplash.cpp @@ -3,6 +3,7 @@ #include <LuminaXDG.h> #include <LUtils.h> +#include <LDesktopUtils.h> BootSplash::BootSplash() : QWidget(0, Qt::SplashScreen | Qt::X11BypassWindowManagerHint | Qt::WindowStaysOnTopHint | Qt::WindowDoesNotAcceptFocus), ui(new Ui::BootSplash){ ui->setupUi(this); @@ -15,6 +16,7 @@ BootSplash::BootSplash() : QWidget(0, Qt::SplashScreen | Qt::X11BypassWindowMana if(random.endsWith("\n")){ random.chop(1); } ui->label_welcome->setText( "\""+random+"\"" ); } + ui->label_version->setText( QString(tr("Version %1")).arg(LDesktopUtils::LuminaDesktopVersion()) ); } void BootSplash::showScreen(QString loading){ //update icon, text, and progress diff --git a/src-qt5/core/lumina-desktop/BootSplash.ui b/src-qt5/core/lumina-desktop/BootSplash.ui index 43070eee..43f4ca67 100644 --- a/src-qt5/core/lumina-desktop/BootSplash.ui +++ b/src-qt5/core/lumina-desktop/BootSplash.ui @@ -122,6 +122,22 @@ </property> </widget> </item> + <item> + <widget class="QLabel" name="label_version"> + <property name="font"> + <font> + <pointsize>7</pointsize> + <italic>true</italic> + </font> + </property> + <property name="text"> + <string notr="true">Version</string> + </property> + <property name="alignment"> + <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set> + </property> + </widget> + </item> </layout> </item> </layout> -- cgit From f7b894621578f5b54b3da9a3291586cee503c2d9 Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Thu, 1 Dec 2016 10:33:19 -0500 Subject: Get rid of the "fortune" usage, and replace it with a built-in system of tips for Lumina itself (avoids strange stuff from fortune, and ensures information which is at least semi-useful for the user). --- src-qt5/core/lumina-desktop/BootSplash.cpp | 28 +++++++++++++++++++++++----- src-qt5/core/lumina-desktop/BootSplash.h | 4 +++- src-qt5/core/lumina-desktop/LSession.cpp | 8 +++++--- 3 files changed, 31 insertions(+), 9 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/core/lumina-desktop/BootSplash.cpp b/src-qt5/core/lumina-desktop/BootSplash.cpp index f7981670..f6c4c5fa 100644 --- a/src-qt5/core/lumina-desktop/BootSplash.cpp +++ b/src-qt5/core/lumina-desktop/BootSplash.cpp @@ -11,14 +11,32 @@ BootSplash::BootSplash() : QWidget(0, Qt::SplashScreen | Qt::X11BypassWindowMana //Center the window on the primary screen QPoint ctr = QApplication::desktop()->screenGeometry().center(); this->move( ctr.x()-(this->width()/2), ctr.y()-(this->height()/2) ); - if(LUtils::isValidBinary("fortune")){ - QString random = LUtils::getCmdOutput("fortune -s").join("\n").simplified(); - if(random.endsWith("\n")){ random.chop(1); } - ui->label_welcome->setText( "\""+random+"\"" ); - } + generateTipOfTheDay(); ui->label_version->setText( QString(tr("Version %1")).arg(LDesktopUtils::LuminaDesktopVersion()) ); } +void BootSplash::generateTipOfTheDay(){ + int index = qrand()%5; //Make sure this number matches the length of the case below (max value +1) + QString tip = "This desktop is generously sponsored by iXsystems\nwww.ixsystems.com"; //fallback message (just in case) + switch(index){ + case 0: + tip = tr("This desktop is powered by coffee, coffee, and more coffee."); break; + case 1: + tip = tr("Keep up with desktop news!")+"\n\nwww.lumina-desktop.org"; break; + case 2: + tip = tr("There is a full handbook of information about the desktop available online.")+"\n\nwww.lumina-desktop.org/handbook"; break; + case 3: + tip = tr("Want to change the interface? Everything is customizable in the desktop configuration!"); break; + case 4: + tip = tr("Lumina can easily reproduce the interface from most other desktop environments."); break; + case 5: + tip = tr(""); break; + case 6: + tip = tr(""); break; + } + ui->label_welcome->setText( "\""+tip+"\"" ); +} + void BootSplash::showScreen(QString loading){ //update icon, text, and progress QString txt, icon; int per = 0; diff --git a/src-qt5/core/lumina-desktop/BootSplash.h b/src-qt5/core/lumina-desktop/BootSplash.h index f5bf97a8..f9812ff4 100644 --- a/src-qt5/core/lumina-desktop/BootSplash.h +++ b/src-qt5/core/lumina-desktop/BootSplash.h @@ -18,6 +18,8 @@ class BootSplash : public QWidget{ private: Ui::BootSplash *ui; + void generateTipOfTheDay(); + public: BootSplash(); ~BootSplash(){} @@ -26,4 +28,4 @@ public: void showText(QString txt); //will only update the text, not the icon/progress }; -#endif \ No newline at end of file +#endif diff --git a/src-qt5/core/lumina-desktop/LSession.cpp b/src-qt5/core/lumina-desktop/LSession.cpp index 289d7ede..27b40aa3 100644 --- a/src-qt5/core/lumina-desktop/LSession.cpp +++ b/src-qt5/core/lumina-desktop/LSession.cpp @@ -81,14 +81,16 @@ LSession::~LSession(){ } void LSession::setupSession(){ + //Seed random number generator (if needed) + qsrand( QTime::currentTime().msec() ); + BootSplash splash; splash.showScreen("init"); qDebug() << "Initializing Session"; if(QFile::exists("/tmp/.luminastopping")){ QFile::remove("/tmp/.luminastopping"); } QTime* timer = 0; - if(DEBUG){ timer = new QTime(); timer->start(); qDebug() << " - Init srand:" << timer->elapsed();} - //Seed random number generator (if needed) - qsrand( QTime::currentTime().msec() ); + //if(DEBUG){ timer = new QTime(); timer->start(); qDebug() << " - Init srand:" << timer->elapsed();} + //Setup the QSettings default paths splash.showScreen("settings"); if(DEBUG){ qDebug() << " - Init QSettings:" << timer->elapsed();} -- cgit From 41cf532756bdf300a9a4db35809ef2b95c91a868 Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Thu, 1 Dec 2016 14:16:16 -0500 Subject: Fix up the non-selection extraction of an archive. (empty "name" field messed it up) --- src-qt5/desktop-utils/lumina-archiver/TarBackend.cpp | 1 + 1 file changed, 1 insertion(+) (limited to 'src-qt5') diff --git a/src-qt5/desktop-utils/lumina-archiver/TarBackend.cpp b/src-qt5/desktop-utils/lumina-archiver/TarBackend.cpp index 9a8cd5b7..78efd51c 100644 --- a/src-qt5/desktop-utils/lumina-archiver/TarBackend.cpp +++ b/src-qt5/desktop-utils/lumina-archiver/TarBackend.cpp @@ -135,6 +135,7 @@ void Backend::startExtract(QString path, bool overwrite, QStringList files){ if(!overwrite){ args << "-k"; } args << flags; for(int i=0; i<files.length(); i++){ + if(files[i].simplified().isEmpty()){ continue; } args << "--include" << files[i] << "--strip-components" << QString::number(files[i].count("/")); } args << "-C" << path; -- cgit From a78098bec6289f4d242bc132205866dbdd73eb24 Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Thu, 1 Dec 2016 15:40:59 -0500 Subject: Adjust the Qt-crash workaround a bit to try and avoid starting a dbus session if possible. --- src-qt5/core/lumina-session/session.cpp | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/core/lumina-session/session.cpp b/src-qt5/core/lumina-session/session.cpp index 10953f12..19acdb1c 100644 --- a/src-qt5/core/lumina-session/session.cpp +++ b/src-qt5/core/lumina-session/session.cpp @@ -61,11 +61,16 @@ void LSession::startProcess(QString ID, QString command, QStringList watchfiles) proc->setStandardOutputFile(logfile); proc->setObjectName(ID); if(ID=="runtime"){ - //Bypass for a hidden dbus requirement for Qt itself (Qt 5.5.1) - QDir tmp = QDir::temp(); - if( tmp.entryList(QStringList() << "dbus-*").isEmpty() && LUtils::isValidBinary("dbus-launch")){ - command.prepend("dbus-launch --exit-with-session "); - } + //Bypass for a hidden dbus file requirement for Qt itself (Qt 5.5.1+?) + if(!QFile::exists("/etc/machine-id") && !QFile::exists("/var/db/dbus/machine-id")){ + if(LUtils::isValidBinary("dbus-uuidgen") && LUtils::runCmd("dbus-uuidgen --ensure") ){ } //good - the UUID was created successfully + else if(LUtils::isValidBinary("dbus-launch")){ command.prepend("dbus-launch --exit-with-session "); } + else{ + //create a simple DBUS UUID and put it in the universal-fallback location (OS-independent) + // TO-DO - root vs user level permissions issue? + qDebug() << "Could not find '/etc/machine-id' or '/var/db/dbus/machine-id': Qt will most likely crash. \nPlease run 'dbus-uuidgen --ensure' with root permissions to generate this file if Lumina does not start properly."; + } + } } proc->start(command, QIODevice::ReadOnly); connect(proc, SIGNAL(finished(int, QProcess::ExitStatus)), this, SLOT(procFinished()) ); -- cgit From 120110d558b58fb0ca530c63a6070dad44d4cd75 Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Fri, 2 Dec 2016 13:47:23 -0500 Subject: Make the start menu open faster by only loading the favorites *when the file/list changes*. --- src-qt5/core/lumina-desktop/LSession.cpp | 7 ++++++- src-qt5/core/lumina-desktop/LSession.h | 1 + .../core/lumina-desktop/panel-plugins/systemstart/StartMenu.cpp | 3 ++- 3 files changed, 9 insertions(+), 2 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/core/lumina-desktop/LSession.cpp b/src-qt5/core/lumina-desktop/LSession.cpp index 27b40aa3..0b5d9409 100644 --- a/src-qt5/core/lumina-desktop/LSession.cpp +++ b/src-qt5/core/lumina-desktop/LSession.cpp @@ -151,6 +151,7 @@ void LSession::setupSession(){ watcherChange( confdir+"/desktopsettings.conf" ); watcherChange( confdir+"/fluxbox-init" ); watcherChange( confdir+"/fluxbox-keys" ); + watcherChange( confdir+"/favorites.list" ); //Try to watch the localized desktop folder too if(QFile::exists(QDir::homePath()+"/"+tr("Desktop"))){ watcherChange( QDir::homePath()+"/"+tr("Desktop") ); } watcherChange( QDir::homePath()+"/Desktop" ); @@ -333,9 +334,13 @@ void LSession::watcherChange(QString changed){ desktopFiles = QDir(changed).entryInfoList(QDir::NoDotAndDotDot | QDir::Files | QDir::Dirs ,QDir::Name | QDir::IgnoreCase | QDir::DirsFirst); if(DEBUG){ qDebug() << "New Desktop Files:" << desktopFiles.length(); } emit DesktopFilesChanged(); - } + }else if(changed.endsWith("favorites.list")){ emit FavoritesChanged(); } //Now ensure this file was not removed from the watcher if(!watcher->files().contains(changed) && !watcher->directories().contains(changed)){ + if(!QFile::exists(changed)){ + //Create the file really quick to ensure it can be watched + //TODO + } watcher->addPath(changed); } } diff --git a/src-qt5/core/lumina-desktop/LSession.h b/src-qt5/core/lumina-desktop/LSession.h index d19cf70c..bd93289a 100644 --- a/src-qt5/core/lumina-desktop/LSession.h +++ b/src-qt5/core/lumina-desktop/LSession.h @@ -184,6 +184,7 @@ signals: void IconThemeChanged(); void DesktopConfigChanged(); void SessionConfigChanged(); + void FavoritesChanged(); void DesktopFilesChanged(); void WorkspaceChanged(); diff --git a/src-qt5/core/lumina-desktop/panel-plugins/systemstart/StartMenu.cpp b/src-qt5/core/lumina-desktop/panel-plugins/systemstart/StartMenu.cpp index a34d09db..d05ba22f 100644 --- a/src-qt5/core/lumina-desktop/panel-plugins/systemstart/StartMenu.cpp +++ b/src-qt5/core/lumina-desktop/panel-plugins/systemstart/StartMenu.cpp @@ -24,6 +24,7 @@ StartMenu::StartMenu(QWidget *parent) : QWidget(parent), ui(new Ui::StartMenu){ searchTimer->setSingleShot(true); connect(searchTimer, SIGNAL(timeout()), this, SLOT(startSearch()) ); connect(LSession::handle()->applicationMenu(), SIGNAL(AppMenuUpdated()), this, SLOT(UpdateApps()) ); + connect(LSession::handle(), SIGNAL(FavoritesChanged()), this, SLOT(UpdateFavs()) ); //Need to load the last used setting of the application list QString state = LSession::handle()->DesktopPluginSettings()->value("panelPlugs/systemstart/showcategories", "partial").toString(); if(state=="partial"){ui->check_apps_showcats->setCheckState(Qt::PartiallyChecked); } @@ -128,7 +129,7 @@ void StartMenu::UpdateMenu(bool forceall){ if(forceall){ UpdateAll(); } //Quick update routine before the menu is made visible //qDebug() << "update favs"; - UpdateFavs(); + //UpdateFavs(); //qDebug() << "check page"; if(ui->stackedWidget->currentWidget() != ui->page_main){ ui->stackedWidget->setCurrentWidget(ui->page_main); //just show the main page -- cgit From 546bba1faf69e1aac06aa13fd0ecd28d23c09a7f Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Mon, 5 Dec 2016 09:31:56 -0500 Subject: Re-enable drag and drop within lumina-fm. --- src-qt5/desktop-utils/lumina-fm/BrowserWidget.cpp | 2 ++ .../lumina-fm/widgets/DDListWidgets.h | 27 +++++++++++++--------- 2 files changed, 18 insertions(+), 11 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/desktop-utils/lumina-fm/BrowserWidget.cpp b/src-qt5/desktop-utils/lumina-fm/BrowserWidget.cpp index 8db13718..0d9c33f8 100644 --- a/src-qt5/desktop-utils/lumina-fm/BrowserWidget.cpp +++ b/src-qt5/desktop-utils/lumina-fm/BrowserWidget.cpp @@ -357,6 +357,8 @@ void BrowserWidget::itemDataAvailable(QIcon ico, LFileInfo info){ void BrowserWidget::itemsLoading(int total){ qDebug() << "Got number of items loading:" << total; + if(listWidget!=0){ listWidget->setWhatsThis( BROWSER->currentDirectory() ); } + if(treeWidget!=0){ treeWidget->setWhatsThis(BROWSER->currentDirectory() ); } numItems = total; //save this for later if(total<1){ emit updateDirectoryStatus( tr("No Directory Contents") ); diff --git a/src-qt5/desktop-utils/lumina-fm/widgets/DDListWidgets.h b/src-qt5/desktop-utils/lumina-fm/widgets/DDListWidgets.h index 48127efa..f7373432 100644 --- a/src-qt5/desktop-utils/lumina-fm/widgets/DDListWidgets.h +++ b/src-qt5/desktop-utils/lumina-fm/widgets/DDListWidgets.h @@ -63,9 +63,10 @@ protected: if(items.length()<1){ return; } QList<QUrl> urilist; for(int i=0; i<items.length(); i++){ - urilist << QUrl::fromLocalFile(items[i]->whatsThis().section("::::",1,100)); + urilist << QUrl::fromLocalFile(items[i]->whatsThis()); } //Create the mime data + //qDebug() << "Start Drag:" << urilist; QMimeData *mime = new QMimeData; mime->setUrls(urilist); //Create the drag structure @@ -91,6 +92,7 @@ protected: if(ev->mimeData()->hasUrls() && !this->whatsThis().isEmpty() ){ //Change the drop type depending on the data/dir QString home = QDir::homePath(); + //qDebug() << "Drag Move:" << home << this->whatsThis(); if( this->whatsThis().startsWith(home) ){ ev->setDropAction(Qt::MoveAction); } else{ ev->setDropAction(Qt::CopyAction); } ev->acceptProposedAction(); //allow this to be dropped here @@ -107,7 +109,8 @@ protected: //See if the item under the drop point is a directory or not QListWidgetItem *it = this->itemAt( ev->pos()); if(it!=0){ - QFileInfo info(it->whatsThis().section("::::",1,100)); + //qDebug() << "Drop Item:" << it->whatsThis(); + QFileInfo info(it->whatsThis()); if(info.isDir() && info.isWritable()){ dirpath = info.absoluteFilePath(); } @@ -118,11 +121,12 @@ protected: foreach(const QUrl &url, ev->mimeData()->urls()){ const QString filepath = url.toLocalFile(); //If the target file is modifiable, assume a move - otherwise copy - if(QFileInfo(filepath).isWritable() && (filepath.startsWith(home) && dirpath.startsWith(home))){ files << "cut::::"+filepath; } - else{ files << "copy::::"+filepath; } + if(QFileInfo(filepath).isWritable() && (filepath.startsWith(home) && dirpath.startsWith(home))){ + if(filepath.section("/",0,-2)!=dirpath){ files << "cut::::"+filepath; } //don't "cut" a file into the same dir + }else{ files << "copy::::"+filepath; } } - //qDebug() << "Drop Event:" << dirpath; - emit DataDropped( dirpath, files ); + //qDebug() << "Drop Event:" << dirpath << files; + if(!files.isEmpty()){ emit DataDropped( dirpath, files ); } } void mouseReleaseEvent(QMouseEvent *ev){ @@ -175,7 +179,7 @@ protected: if(items.length()<1){ return; } QList<QUrl> urilist; for(int i=0; i<items.length(); i++){ - urilist << QUrl::fromLocalFile(items[i]->whatsThis(0).section("::::",1,100)); + urilist << QUrl::fromLocalFile(items[i]->whatsThis(0)); } //Create the mime data QMimeData *mime = new QMimeData; @@ -218,7 +222,7 @@ protected: //See if the item under the drop point is a directory or not QTreeWidgetItem *it = this->itemAt( ev->pos()); if(it!=0){ - QFileInfo info(it->whatsThis(0).section("::::",1,100)); + QFileInfo info(it->whatsThis(0)); if(info.isDir() && info.isWritable()){ dirpath = info.absoluteFilePath(); } @@ -229,9 +233,10 @@ protected: QString home = QDir::homePath(); foreach(const QUrl &url, ev->mimeData()->urls()){ const QString filepath = url.toLocalFile(); - //If the target file is modifiable, assume a move - otherwise copy - if(QFileInfo(filepath).isWritable() && (filepath.startsWith(home) && dirpath.startsWith(home)) ){ files << "cut::::"+filepath; } - else{ files << "copy::::"+filepath; } + //If the target file is modifiable, assume a move - otherwise copy + if(QFileInfo(filepath).isWritable() && (filepath.startsWith(home) && dirpath.startsWith(home))){ + if(filepath.section("/",0,-2)!=dirpath){ files << "cut::::"+filepath; } //don't "cut" a file into the same dir + }else{ files << "copy::::"+filepath; } } //qDebug() << "Drop Event:" << dirpath; emit DataDropped( dirpath, files ); -- cgit From 74cae9e81c4b11df50a419e43d1f3dfab49acdfb Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Mon, 5 Dec 2016 09:38:50 -0500 Subject: Add a bit more debugging to the start-lumina-desktop binary. --- src-qt5/core/lumina-session/main.cpp | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'src-qt5') diff --git a/src-qt5/core/lumina-session/main.cpp b/src-qt5/core/lumina-session/main.cpp index 73af45f9..5fa2bb69 100644 --- a/src-qt5/core/lumina-session/main.cpp +++ b/src-qt5/core/lumina-session/main.cpp @@ -33,6 +33,7 @@ int main(int argc, char ** argv) //Start X11 if needed QString disp = QString(getenv("DISPLAY")).simplified(); if(disp.isEmpty()){ + qDebug() << "No X11 session detected: Lumina will try to start one..."; //No X session found. Go ahead and re-init this binary within an xinit call QString prog = QString(argv[0]).section("/",-1); LUtils::isValidBinary(prog); //will adjust the path to be absolute @@ -40,6 +41,7 @@ int main(int argc, char ** argv) //if(LUtils::isValidBinary("x11vnc")){ args << "--" << "-listen" << "tcp"; } //need to be able to VNC into this session return QProcess::execute("xinit", args); } + qDebug() << "Starting the Lumina desktop on current X11 session:" << disp; //Setup any initialization values LTHEME::LoadCustomEnvSettings(); LXDG::setEnvironmentVars(); @@ -52,8 +54,10 @@ int main(int argc, char ** argv) //Configure X11 monitors if needed if(LUtils::isValidBinary("lumina-xconfig")){ + qDebug() << " - Resetting monitor configuration to last-used settings"; QProcess::execute("lumina-xconfig --reset-monitors"); } + qDebug() << " - Starting the session..."; //Startup the session QCoreApplication a(argc, argv); LSession sess; -- cgit From a66855211362b35033171bdecce13f02fe9aa3d7 Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Mon, 5 Dec 2016 12:29:34 -0500 Subject: Have the "start-lumina-desktop" binary check for an existing lockfile and remove it before launching the desktop. --- src-qt5/core/lumina-session/lumina-session.pro | 2 +- src-qt5/core/lumina-session/main.cpp | 17 +++++++++++++++++ 2 files changed, 18 insertions(+), 1 deletion(-) (limited to 'src-qt5') diff --git a/src-qt5/core/lumina-session/lumina-session.pro b/src-qt5/core/lumina-session/lumina-session.pro index dc697a34..4b06ad60 100644 --- a/src-qt5/core/lumina-session/lumina-session.pro +++ b/src-qt5/core/lumina-session/lumina-session.pro @@ -1,6 +1,6 @@ include($${PWD}/../../OS-detect.pri) -QT = core widgets +QT = core widgets x11extras TARGET = start-lumina-desktop diff --git a/src-qt5/core/lumina-session/main.cpp b/src-qt5/core/lumina-session/main.cpp index 5fa2bb69..0e076ac3 100644 --- a/src-qt5/core/lumina-session/main.cpp +++ b/src-qt5/core/lumina-session/main.cpp @@ -8,6 +8,8 @@ #include <QCoreApplication> #include <QProcess> #include <QString> +#include <QLockFile> +#include <QX11Info> #include "session.h" #include <LUtils.h> @@ -16,6 +18,8 @@ #include <LuminaThemes.h> #include <LuminaXDG.h> +#include <unistd.h> + #define DEBUG 0 int main(int argc, char ** argv) @@ -51,6 +55,19 @@ int main(int argc, char ** argv) //Check for any missing user config files + //Check for any stale desktop lock files and clean them up + QString cfile = QDir::tempPath()+"/.LSingleApp-%1-%2-%3"; + cfile = cfile.arg( QString(getlogin()), "lumina-desktop", QString::number(QX11Info::appScreen()) ); + if(QFile::exists(cfile)){ + qDebug() << "Found Desktop Lock for X session:" << disp; + qDebug() << " - Disabling Lock and starting new desktop session"; + QLockFile lock(cfile+"-lock"); + if(lock.isLocked()){ lock.unlock(); } + QFile::remove(cfile); + } + if(QFile::exists(QDir::tempPath()+"/.luminastopping")){ + QFile::remove(QDir::tempPath()+"/.luminastopping"); + } //Configure X11 monitors if needed if(LUtils::isValidBinary("lumina-xconfig")){ -- cgit From 5e027876c9aea2f7d7aed8e7e26b7f6dfada31c7 Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Mon, 5 Dec 2016 12:30:23 -0500 Subject: Commit a couple tweaks for lumina-fm - trying to get the drag and drop highlighting working. --- src-qt5/desktop-utils/lumina-fm/BrowserWidget.cpp | 9 ++++----- src-qt5/desktop-utils/lumina-fm/widgets/DDListWidgets.h | 11 ++++++++--- 2 files changed, 12 insertions(+), 8 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/desktop-utils/lumina-fm/BrowserWidget.cpp b/src-qt5/desktop-utils/lumina-fm/BrowserWidget.cpp index 0d9c33f8..0486e337 100644 --- a/src-qt5/desktop-utils/lumina-fm/BrowserWidget.cpp +++ b/src-qt5/desktop-utils/lumina-fm/BrowserWidget.cpp @@ -29,7 +29,7 @@ BrowserWidget::BrowserWidget(QString objID, QWidget *parent) : QWidget(parent){ readDateFormat(); freshload = true; //nothing loaded yet numItems = 0; - + this->setMouseTracking(true); } BrowserWidget::~BrowserWidget(){ @@ -137,10 +137,9 @@ QStringList BrowserWidget::history(){ } void BrowserWidget::setShowActive(bool show){ - if(!show){ this->setStyleSheet("QAbstractScrollArea{ background-color: rgba(10,10,10,10); } QHeaderView{ background-color: lightgrey; }"); } - else{ - this->setStyleSheet( ""); - } + QString base = "";//"QListWidget::item,QTreeWidget::item{ border: 1px solid transparent; background-color: red; } QListWidget::item:hover,QTreeWidget::item:hover{ border: 1px solid black; background-color: blue; }"; + if(!show){ base.prepend("QAbstractScrollArea{ background-color: rgba(10,10,10,10); } QHeaderView{ background-color: lightgrey; } "); } + this->setStyleSheet(base); } // This function is only called if user changes sessionsettings. By doing so, operations like sorting by date diff --git a/src-qt5/desktop-utils/lumina-fm/widgets/DDListWidgets.h b/src-qt5/desktop-utils/lumina-fm/widgets/DDListWidgets.h index f7373432..254362fd 100644 --- a/src-qt5/desktop-utils/lumina-fm/widgets/DDListWidgets.h +++ b/src-qt5/desktop-utils/lumina-fm/widgets/DDListWidgets.h @@ -45,6 +45,7 @@ public: this->setWrapping(true); this->setMouseTracking(true); this->setSortingEnabled(true); //This sorts *only* by name - type is not preserved + //this->setStyleSheet("QListWidget::item{ border: 1px solid transparent; border-radius: 5px; background-color: transparent;} QListWidget::item:hover{ border-color: black; } QListWidget::item:focus{ border-color: lightblue; }"); } ~DDListWidget(){} @@ -85,7 +86,7 @@ protected: ev->acceptProposedAction(); //allow this to be dropped here }else{ ev->ignore(); - } + } } void dragMoveEvent(QDragMoveEvent *ev){ @@ -93,12 +94,15 @@ protected: //Change the drop type depending on the data/dir QString home = QDir::homePath(); //qDebug() << "Drag Move:" << home << this->whatsThis(); - if( this->whatsThis().startsWith(home) ){ ev->setDropAction(Qt::MoveAction); } - else{ ev->setDropAction(Qt::CopyAction); } + if( this->whatsThis().startsWith(home) ){ ev->setDropAction(Qt::MoveAction); this->setCursor(Qt::DragMoveCursor); } + else{ ev->setDropAction(Qt::CopyAction); this->setCursor(Qt::DragCopyCursor);} ev->acceptProposedAction(); //allow this to be dropped here + //this->setCursor(Qt::CrossCursor); }else{ + this->setCursor(Qt::ForbiddenCursor); ev->ignore(); } + this->update(); } void dropEvent(QDropEvent *ev){ @@ -127,6 +131,7 @@ protected: } //qDebug() << "Drop Event:" << dirpath << files; if(!files.isEmpty()){ emit DataDropped( dirpath, files ); } + this->setCursor(Qt::ArrowCursor); } void mouseReleaseEvent(QMouseEvent *ev){ -- cgit From c6e0fe646e78a6aff588277445fde9752f886a71 Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Tue, 6 Dec 2016 14:34:27 -0500 Subject: Get the new input device routines almost ready. Still have the page disabled in lumina-config right now, but it is coming along nicely. --- src-qt5/core-utils/lumina-config/pages/getPage.h | 2 +- .../core-utils/lumina-config/pages/page_mouse.cpp | 152 ++++++++++++++--- .../core-utils/lumina-config/pages/page_mouse.h | 7 +- .../core-utils/lumina-config/pages/page_mouse.ui | 43 +---- src-qt5/core/libLumina/LInputDevice.cpp | 181 ++++++++++++++++++++- src-qt5/core/libLumina/LInputDevice.h | 28 +++- src-qt5/core/libLumina/LInputDevice.pri | 2 +- 7 files changed, 338 insertions(+), 77 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/core-utils/lumina-config/pages/getPage.h b/src-qt5/core-utils/lumina-config/pages/getPage.h index ea0cfb00..a0785266 100644 --- a/src-qt5/core-utils/lumina-config/pages/getPage.h +++ b/src-qt5/core-utils/lumina-config/pages/getPage.h @@ -38,7 +38,7 @@ static QList<PAGEINFO> KnownPages(){ list << PageInfo("interface-menu", QObject::tr("Menu"), QObject::tr("Menu Plugins"), "preferences-plugin",QObject::tr("Change what options are shown on the desktop context menu"), "interface", QStringList(), QStringList() << "desktop" << "menu" << "plugins" << "shortcuts"); list << PageInfo("session-locale", QObject::tr("Localization"), QObject::tr("Locale Settings"), "preferences-desktop-locale",QObject::tr("Change the default locale settings for this user"), "user", QStringList(), QStringList() << "user"<<"locale"<<"language"<<"translations"); list << PageInfo("session-options", QObject::tr("General Options"), QObject::tr("User Settings"), "configure",QObject::tr("Change basic user settings such as time/date formats"), "user", QStringList(), QStringList() << "user"<<"settings"<<"time"<<"date"<<"icon"<<"reset"<<"numlock"<<"clock"); - //list << PageInfo("mouse", QObject::tr("Mouse Settings"), QObject::tr("Mouse Settings"), "input-mouse",QObject::tr("Adjust mouse settings"), "user", QStringList(), QStringList() << "user"<<"speed"<<"accel"<<"mouse"); + //list << PageInfo("mouse", QObject::tr("Input Device Settings"), QObject::tr("Input Device Settings"), "preferences-desktop-peripherals",QObject::tr("Adjust keyboard and mouse devices"), "user", QStringList(), QStringList() << "user"<<"speed"<<"accel"<<"mouse" << "keyboard"); //Now sort the items according to the translated name QStringList names; for(int i=0; i<list.length(); i++){ names << list[i].name; } diff --git a/src-qt5/core-utils/lumina-config/pages/page_mouse.cpp b/src-qt5/core-utils/lumina-config/pages/page_mouse.cpp index dbe075d7..1dd41295 100644 --- a/src-qt5/core-utils/lumina-config/pages/page_mouse.cpp +++ b/src-qt5/core-utils/lumina-config/pages/page_mouse.cpp @@ -8,15 +8,17 @@ #include "ui_page_mouse.h" #include "getPage.h" +#include <QSpinBox> +#include <QDoubleSpinBox> + //========== // PUBLIC //========== page_mouse::page_mouse(QWidget *parent) : PageWidget(parent), ui(new Ui::page_mouse()){ ui->setupUi(this); - connect(ui->slider_accel, SIGNAL(valueChanged(int)), this, SLOT(accelChanged(int)) ); - updateIcons(); - qDebug() << "List Devices:"; - QList<LInputDevice*> devices = LInput::listDevices(); + devices = LInput::listDevices(); + //DEBUG Code + /*qDebug() << "List Devices:"; for(int i=0; i<devices.length(); i++){ if(!devices[i]->isPointer()){ ::free( devices.takeAt(i)); @@ -24,9 +26,14 @@ page_mouse::page_mouse(QWidget *parent) : PageWidget(parent), ui(new Ui::page_mo }else{ qDebug() << "Found Pointer:" << devices[i]->devNumber(); qDebug() << " - isExtension:" << devices[i]->isExtension(); - qDebug() << " - Properties:" << devices[i]->listProperties(); + QList<int> props = devices[i]->listProperties(); + qDebug() << " - Properties:"; + for(int j=0; j<props.length(); j++){ + qDebug() << " --" <<devices[i]->propertyName(props[j])+" ("+QString::number(props[j])+")" <<" = " << devices[i]->getPropertyValue(props[j]); + } } - } + }*/ + generateUI(); } page_mouse::~page_mouse(){ @@ -43,35 +50,134 @@ void page_mouse::SaveSettings(){ void page_mouse::LoadSettings(int){ emit HasPendingChanges(false); - emit ChangePageTitle( tr("Desktop Settings") ); + emit ChangePageTitle( tr("Mouse Settings") ); } void page_mouse::updateIcons(){ - + for(int i=0; i<ui->tabWidget->count(); i++){ + ui->tabWidget->setTabIcon( i, LXDG::findIcon( "input-"+ui->tabWidget->tabWhatsThis(i).section(":",0,0), "" ) ); + } } //================= // PRIVATE //================= +void page_mouse::generateUI(){ + ui->tabWidget->clear(); //remove all tabs (just in case) + int mouse = 1; + int keyboard = 1; + qDebug() << "Devices Found:" << devices.length(); + for(int i=0; i<devices.length(); i++){ + QTreeWidget *tree = 0; + if(!devices[i]->isExtension()){ + //Make a new tab for this device + tree = new QTreeWidget(this); + tree->setHeaderHidden(true); + tree->setColumnCount(2); + if(devices[i]->isPointer()){ + int tab = ui->tabWidget->addTab(tree, LXDG::findIcon("input-mouse",""), QString(tr("Mouse #%1")).arg(QString::number(mouse)) ); + ui->tabWidget->setTabWhatsThis(tab, "mouse:"+QString::number(devices[i]->devNumber())); + mouse++; + }else{ + int tab = ui->tabWidget->addTab(tree, LXDG::findIcon("input-keyboard",""), QString(tr("Keyboard #%1")).arg(QString::number(keyboard)) ); + ui->tabWidget->setTabWhatsThis(tab, "keyboard:"+QString::number(devices[i]->devNumber()) ); + keyboard++; + } + }else{ + //Find the associated tab for this extension device + int tab = 0; + QString type = devices[i]->isPointer() ? "mouse" : "keyboard"; + int num = devices[i]->devNumber(); + for(int t=ui->tabWidget->count()-1; t>0; t--){ + if(ui->tabWidget->tabWhatsThis(t).startsWith(type) && ui->tabWidget->tabWhatsThis(t).section(":",-1).toInt() < num ){ tab = t; break; } + } + tree = static_cast<QTreeWidget*>( ui->tabWidget->widget(tab) ); + } + if(tree!=0){ populateDeviceTree(tree, devices[i]); } + } +} + +void page_mouse::populateDeviceTree(QTreeWidget *tree, LInputDevice *device){ + QTreeWidgetItem *top = new QTreeWidgetItem(tree); + if(device->isExtension()){ + top->setText( 0, QString(tr("Extension Device #%1")).arg(QString::number(tree->topLevelItemCount())) ); + }else{ top->setText(0, tr("Master Device")); } + top->setWhatsThis(0, QString(device->isPointer() ? "mouse" : "keyboard")+":"+QString::number(device->devNumber()) ); //save this for later + top->setFirstColumnSpanned(true); + top->setExpanded(true); + tree->addTopLevelItem(top); + //Now add all the child properties to this item + QList<int> props = device->listProperties(); + for(int i=0; i<props.length(); i++){ + QTreeWidgetItem *tmp = new QTreeWidgetItem(top); + tmp->setWhatsThis(0, QString::number(props[i]) ); + tmp->setText(0, device->propertyName(props[i])); + top->addChild(tmp); + populateDeviceItemValue(tree, tmp, device->getPropertyValue(props[i]), QString::number(device->devNumber())+":"+QString::number(props[i]) ); + } + //Clean up the tree widget as needed + top->sortChildren(0, Qt::AscendingOrder); + tree->resizeColumnToContents(0); +} + +void page_mouse::populateDeviceItemValue(QTreeWidget *tree, QTreeWidgetItem *it, QVariant value, QString id){ + if(value.type()==QVariant::Int){ + //Could be a boolian - check the name for known "enable" states + if(it->text(0).toLower().contains("enable") || it->text(0).toLower().contains("emulation") ){ + //Just use a checkable column within the item + bool enabled = (value.toInt()==1); + it->setText(1,""); + it->setCheckState(1, enabled ? Qt::Checked : Qt::Unchecked); + }else{ + //Use a QSpinBox + QSpinBox *box = new QSpinBox(); + box->setRange(0,100); + box->setValue( value.toInt() ); + tree->setItemWidget(it, 1, box); + connect(box, SIGNAL(valueChanged(int)), this, SLOT(valueChanged()) ); + } + }else if(value.canConvert<double>()){ + //Use a QDoubleSpinBox + QDoubleSpinBox *box = new QDoubleSpinBox(); + box->setRange(0,100); + box->setValue( value.toInt() ); + tree->setItemWidget(it, 1, box); + connect(box, SIGNAL(valueChanged(double)), this, SLOT(valueChanged()) ); + }else if(value.canConvert<QList<QVariant>>()){ + //Not Modifiable - just use the label in the item + QList<QVariant> list = value.toList(); + QStringList txtList; + for(int i=0; i<list.length(); i++){ txtList << list[i].toString(); } + it->setText(1, txtList.join(", ") ); + }else if( value.canConvert<QString>() ){ + //Not Modifiable - just use the label in the item + it->setText(1, value.toString()); + } +} //================= // PRIVATE SLOTS //================= -void page_mouse::accelChanged(int val){ - if(val<=4){ - val = 4-val; - ui->label_accel->setText( QString("1/%1").arg(QString::number(val)) ); - QProcess::startDetached("xset mouse 1/"+QString::number(val)); - }else{ - val = val-4; - if(val%2==0){ - val = val/2; - ui->label_accel->setText( QString::number(val) ); - QProcess::startDetached("xset mouse "+QString::number(val)); - }else{ - ui->label_accel->setText( QString::number(val)+"/2" ); - QProcess::startDetached("xset mouse "+QString::number(val)+"/2"); - } +void page_mouse::valueChanged(){ + //WILL NOT WORK - the widgets within the tree item *do not* activate the item when clicked + // - so the current item is NOT guaranteed to be the one which was modified + //Get the current Tab/TreeWidget + QTreeWidget *tree = static_cast<QTreeWidget*>(ui->tabWidget->widget( ui->tabWidget->currentIndex() ) ); + if(tree==0){ return; } + //Now get the current item in the tree + QTreeWidgetItem *it = tree->currentItem(); + if(it==0){ return; } + qDebug() << "Item Value Changed:" << it->text(0); + //Now read the value of the item and save that into the device + QVariant value; + if(tree->itemWidget(it, 1)!=0){ + //Got Item Widget + + }else if(it->text(1)==""){ + //Checkbox + value = QVariant( (it->checkState(1)==Qt::Checked) ? 1 : 0 ); } + + } diff --git a/src-qt5/core-utils/lumina-config/pages/page_mouse.h b/src-qt5/core-utils/lumina-config/pages/page_mouse.h index 849917c5..d16ec214 100644 --- a/src-qt5/core-utils/lumina-config/pages/page_mouse.h +++ b/src-qt5/core-utils/lumina-config/pages/page_mouse.h @@ -30,7 +30,12 @@ private: Ui::page_mouse *ui; QList<LInputDevice*> devices; + void generateUI(); + void populateDeviceTree(QTreeWidget *tree, LInputDevice *device); + void populateDeviceItemValue(QTreeWidget *tree, QTreeWidgetItem *it, QVariant value, QString id); + private slots: - void accelChanged(int val); + void valueChanged(); + }; #endif diff --git a/src-qt5/core-utils/lumina-config/pages/page_mouse.ui b/src-qt5/core-utils/lumina-config/pages/page_mouse.ui index 619e38dc..a6c2e53f 100644 --- a/src-qt5/core-utils/lumina-config/pages/page_mouse.ui +++ b/src-qt5/core-utils/lumina-config/pages/page_mouse.ui @@ -13,44 +13,17 @@ <property name="windowTitle"> <string>Form</string> </property> - <layout class="QFormLayout" name="formLayout"> - <item row="0" column="0"> - <widget class="QLabel" name="label"> - <property name="text"> - <string>Mouse Acceleration</string> + <layout class="QVBoxLayout" name="verticalLayout"> + <item> + <widget class="QTabWidget" name="tabWidget"> + <property name="iconSize"> + <size> + <width>32</width> + <height>32</height> + </size> </property> </widget> </item> - <item row="0" column="1"> - <layout class="QHBoxLayout" name="horizontalLayout"> - <item> - <widget class="QSlider" name="slider_accel"> - <property name="maximum"> - <number>20</number> - </property> - <property name="value"> - <number>4</number> - </property> - <property name="orientation"> - <enum>Qt::Horizontal</enum> - </property> - <property name="tickPosition"> - <enum>QSlider::TicksBelow</enum> - </property> - <property name="tickInterval"> - <number>2</number> - </property> - </widget> - </item> - <item> - <widget class="QLabel" name="label_accel"> - <property name="text"> - <string notr="true"/> - </property> - </widget> - </item> - </layout> - </item> </layout> </widget> <resources/> diff --git a/src-qt5/core/libLumina/LInputDevice.cpp b/src-qt5/core/libLumina/LInputDevice.cpp index d141e39a..a04dd607 100644 --- a/src-qt5/core/libLumina/LInputDevice.cpp +++ b/src-qt5/core/libLumina/LInputDevice.cpp @@ -17,6 +17,8 @@ #include <xcb/xinput.h> #include <xcb/xproto.h> +#include <LUtils.h> + //=================== // LInputDevice Class //=================== @@ -24,8 +26,10 @@ LInputDevice::LInputDevice(unsigned int id, unsigned int type){ devID = id; devType = type; + //ATOM_FLOAT = 0; //init this when needed later //devName = name; getProperties(); //need to populate the name/atom correlations for properties + readProperties(); //populate the hash with the current values of the properties } LInputDevice::~LInputDevice(){ @@ -53,17 +57,46 @@ bool LInputDevice::isExtension(){ } // Property Management -QStringList LInputDevice::listProperties(){ +QList<int> LInputDevice::listProperties(){ return devProps.keys(); } -QVariant LInputDevice::propertyValue(QString prop){ - if(!devProps.contains(prop)){ return QVariant(); } - //Now generate the property request - // xcb_input_get_device_property_cookie_t cookie = xcb_input_get_device_property_unchecked( QX11Info::connection(), devProps.value(prop), \ -// XCB_ATOM_ATOM, 0, 1000, devID, NULL); - QVariant result; - return result; +QString LInputDevice::propertyName(int prop){ + if(devProps.contains(prop)){ return devProps[prop].name; } + else{ return ""; } +} + +QVariant LInputDevice::getPropertyValue(int prop){ + if(devProps.contains(prop)){ return devProps[prop].value; } + else{ return QVariant(); } +} + +bool LInputDevice::setPropertyValue(int prop, QVariant value){ + if(!devProps.contains(prop)){ return false; } + //Need the float atom for some properties - make sure we have that first + /*if(ATOM_FLOAT==0){ + xcb_intern_atom_reply_t *ar = xcb_intern_atom_reply(QX11Info::connection(), \ + xcb_intern_atom(QX11Info::connection(), 0, 1, "FLOAT"), NULL); + if(ar!=0){ + ATOM_FLOAT = ar->atom; + free(ar); + } + }*/ + //Now setup the argument + bool ok = false; + QStringList args; + args << "--set-prop"; + args << QString::number(devID); + args << QString::number(prop); //prop ID + args << variantToString(value); + ok = (0 == LUtils::runCmd("xinput", args) ); + if(ok){ + //Need to update the value in the hash as well + propData dat = devProps[prop]; + dat.value = value; + devProps.insert(prop, dat); + } + return ok; } // === PRIVATE === @@ -78,12 +111,142 @@ void LInputDevice::getProperties(){ for(int i=0; i<reply->num_atoms; i++){ cookies << xcb_get_atom_name(QX11Info::connection(), atoms[i]); } for(int i=0; i<reply->num_atoms; i++){ xcb_get_atom_name_reply_t *nr = xcb_get_atom_name_reply(QX11Info::connection(), cookies[i], NULL); - devProps.insert(QString::fromUtf8( xcb_get_atom_name_name(nr), xcb_get_atom_name_name_length(nr) ),atoms[i] ); + propData DATA; + DATA.name = QString::fromUtf8( xcb_get_atom_name_name(nr), xcb_get_atom_name_name_length(nr) ); + DATA.atom = atoms[i]; + DATA.id = (int)(atoms[i]); + devProps.insert(DATA.id,DATA); ::free(nr); } //Done with data structure ::free(reply); } + +void LInputDevice::readProperties(){ + QList<int> props = devProps.keys(); + //XINPUT UTILITY USAGE (alternative to XCB which actually works right now) + QStringList info = LUtils::getCmdOutput("xinput list-props "+QString::number(devID)); + for(int i=0; i<props.length(); i++){ + propData PROP = devProps[props[i]]; + QStringList filter = info.filter(" ("+QString::number(PROP.id)+"):"); + if(filter.length()==1){ + QString val = filter.first().section("):",1,-1).simplified(); + //Now figure out what type of value this is and save it into the QVariant + QVariant variant; + if(val.split(", ").length()>1){ + //some kind of array + QList<QVariant> list; + QStringList valList = val.split(", "); + for(int j=0; j<valList.length(); j++){ list << valueToVariant(valList[j]); } + variant = QVariant(list); + }else{ + variant = valueToVariant(val); + } + PROP.value = variant; + } + devProps.insert(props[i], PROP); + } + +//XCB Code (non-functional - issue with library itself? 12/6/16 - Ken Moore) + /*QVariant result; + if(!devProps.contains(prop)){qDebug() << "Invalid Property"; return result; } + //Now generate the property request + xcb_input_get_device_property_cookie_t cookie = xcb_input_get_device_property_unchecked( QX11Info::connection(), devProps.value(prop).atom, \ + XCB_ATOM_ATOM, 0, 1000, devID, 0); + xcb_input_get_device_property_reply_t *reply = xcb_input_get_device_property_reply(QX11Info::connection(), cookie, NULL); + if(reply==0){ qDebug() << "Could not get reply!"; return result; } + //Now read off the value of the property + if(ATOM_FLOAT==0){ + xcb_intern_atom_reply_t *ar = xcb_intern_atom_reply(QX11Info::connection(), \ + xcb_intern_atom(QX11Info::connection(), 0, 1, "FLOAT"), NULL); + if(ar!=0){ + ATOM_FLOAT = ar->atom; + free(ar); + } + } + //Turn the reply into the proper items array (depends on format of the return data) + xcb_input_get_device_property_items_t items; + qDebug() <<QByteArray::fromRawData( (char*)(xcb_input_get_device_property_items(reply) ) , reply->num_items); + void *buffer = xcb_input_get_device_property_items(reply); + xcb_input_get_device_property_items_serialize( &buffer, reply->num_items, reply->format, &items); + + //if(reply->num_items > 0){ + //qDebug() << "Format:" << reply->format << "Length:" << length; + //qDebug() << "Response Type:" << reply->response_type << "Pads:" << reply->pad0 << reply->pad1; + switch(reply->type){ + case XCB_ATOM_INTEGER: + //qDebug() << "Got Integer"; + + break; + case XCB_ATOM_CARDINAL: + //qDebug() << "Got Cardinal"; + + break; + case XCB_ATOM_STRING: + qDebug() << "Got String:"; + if(reply->format==8){ + result.setValue( QByteArray::fromRawData( (char*) xcb_input_get_device_property_items_data_8(&items), sizeof(xcb_input_get_device_property_items_data_8(&items))/sizeof(char)) ); + } + break; + case XCB_ATOM_ATOM: + //qDebug() << "Got Atom"; + + break; + default: + qDebug() << "Other Type:" << reply->type; + } + //} + free(reply); //done with this structure + return result;*/ +} + +QVariant LInputDevice::valueToVariant(QString value){ + //Read through the string and see what type of value it is + if(value.count("\"")==2){ + //String value or atom + if(value.endsWith(")")){ + //ATOM (name string +(atomID)) + return QVariant(value); //don't strip off the atom number -- keep that within the parenthesis + }else{ + //String + value = value.section("\"",1,-2); //everything between the quotes + return QVariant(value); + } + }else if(value.contains(".")){ + //float/double number + return QVariant( value.toDouble() ); + }else{ + //integer or boolian (no way to tell right now - assume all int) + bool ok = false; + int intval = value.toInt(&ok); + if(ok){ return QVariant(intval); } + } + return QVariant(); +} + +QString LInputDevice::variantToString(QVariant value){ + if( value.canConvert< QList<QVariant> >() ){ + //List of variants + QStringList out; + QList<QVariant> list = value.toList(); + for(int i=0; i<list.length(); i++){ out << variantToString(list[i]); } + return out.join(", "); + }else{ + //Single value + if(value.canConvert<double>() ){ + return QString::number(value.toDouble()); + }else if(value.canConvert<int>() ){ + return QString::number(value.toInt()); + }else if( value.canConvert<QString>() ){ + //See if this is an atom first + QString val = value.toString(); + if(val.contains("(")){ val = val.section("(",1,-1).section(")",0,0); } + return val; + } + } + return ""; //nothing to return +} + //====================== // LInput Static Functions //====================== diff --git a/src-qt5/core/libLumina/LInputDevice.h b/src-qt5/core/libLumina/LInputDevice.h index f7a4713c..82dee4fd 100644 --- a/src-qt5/core/libLumina/LInputDevice.h +++ b/src-qt5/core/libLumina/LInputDevice.h @@ -18,6 +18,14 @@ #include <xcb/xproto.h> +//Internal data structure for storing the property information +struct propData{ + int id; + QString name; + QVariant value; + xcb_atom_t atom; +}; + class LInputDevice{ public: LInputDevice(unsigned int id, unsigned int type); //don't use this directly - use the "listDevices()" function instead @@ -31,16 +39,22 @@ public: bool isExtension(); //Property Management - QStringList listProperties(); - QVariant propertyValue(QString prop); + QList<int> listProperties(); + QString propertyName(int prop); + QVariant getPropertyValue(int prop); + bool setPropertyValue(int prop, QVariant value); private: - unsigned int devID; //device ID number - assigned at class creation - unsigned int devType; //device "use" identifier - assigned at class creation - QHash<QString, xcb_atom_t> devProps; //Known device properties <name, atom> + unsigned int devID; //device ID number - assigned at class creation + unsigned int devType; //device "use" identifier - assigned at class creation + QHash<int, propData> devProps; //Known device properties <id#, properties struct> + + void getProperties(); + void readProperties(); + QVariant valueToVariant(QString value); //xinput output to QVariant + QString variantToString(QVariant value); //QVariant to xinput input string - void getProperties(); - //QString devName; //device name - use this for cross-session management (id #'s can get changed every session) + //QString devName; //device name - use this for cross-session management (id #'s can get changed every session) }; //Static functions for overall management diff --git a/src-qt5/core/libLumina/LInputDevice.pri b/src-qt5/core/libLumina/LInputDevice.pri index e90728ce..a5f88a05 100644 --- a/src-qt5/core/libLumina/LInputDevice.pri +++ b/src-qt5/core/libLumina/LInputDevice.pri @@ -10,4 +10,4 @@ HEADERS *= $${PWD}/LInputDevice.h INCLUDEPATH *= ${PWD} #include LUtils and LuminaOS -#include(LUtils.pri) +include(LUtils.pri) -- cgit From e39b66bd0dfdcee226adad7d34c5363fbd23bea6 Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Wed, 7 Dec 2016 10:54:28 -0500 Subject: Enable the new input-devices page within lumina-config. This now allows the user to view/change properties on their input devices (mouse/keyboards) for the current session only (save/restore settings between sessions not implemented yet). NOTE: this change adds a dependency on the "xinput" utility to view property values. The XCB library usage to eliminate this dependency is commented out within the source code right now due to unsolved issues with the library calls. --- src-qt5/core-utils/lumina-config/pages/getPage.h | 4 +- .../core-utils/lumina-config/pages/page_mouse.cpp | 73 ++++++++++++++++------ .../core-utils/lumina-config/pages/page_mouse.h | 2 + 3 files changed, 57 insertions(+), 22 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/core-utils/lumina-config/pages/getPage.h b/src-qt5/core-utils/lumina-config/pages/getPage.h index a0785266..b209bb20 100644 --- a/src-qt5/core-utils/lumina-config/pages/getPage.h +++ b/src-qt5/core-utils/lumina-config/pages/getPage.h @@ -38,7 +38,7 @@ static QList<PAGEINFO> KnownPages(){ list << PageInfo("interface-menu", QObject::tr("Menu"), QObject::tr("Menu Plugins"), "preferences-plugin",QObject::tr("Change what options are shown on the desktop context menu"), "interface", QStringList(), QStringList() << "desktop" << "menu" << "plugins" << "shortcuts"); list << PageInfo("session-locale", QObject::tr("Localization"), QObject::tr("Locale Settings"), "preferences-desktop-locale",QObject::tr("Change the default locale settings for this user"), "user", QStringList(), QStringList() << "user"<<"locale"<<"language"<<"translations"); list << PageInfo("session-options", QObject::tr("General Options"), QObject::tr("User Settings"), "configure",QObject::tr("Change basic user settings such as time/date formats"), "user", QStringList(), QStringList() << "user"<<"settings"<<"time"<<"date"<<"icon"<<"reset"<<"numlock"<<"clock"); - //list << PageInfo("mouse", QObject::tr("Input Device Settings"), QObject::tr("Input Device Settings"), "preferences-desktop-peripherals",QObject::tr("Adjust keyboard and mouse devices"), "user", QStringList(), QStringList() << "user"<<"speed"<<"accel"<<"mouse" << "keyboard"); + list << PageInfo("input-devices", QObject::tr("Input Device Settings"), QObject::tr("Input Device Settings"), "preferences-desktop-peripherals",QObject::tr("Adjust keyboard and mouse devices"), "user", QStringList(), QStringList() << "user"<<"speed"<<"accel"<<"mouse" << "keyboard"); //Now sort the items according to the translated name QStringList names; for(int i=0; i<list.length(); i++){ names << list[i].name; } @@ -83,7 +83,7 @@ static PageWidget* GetNewPage(QString id, QWidget *parent){ else if(id=="session-locale"){ page = new page_session_locale(parent); } else if(id=="session-options"){ page = new page_session_options(parent); } else if(id=="compton"){ page = new page_compton(parent); } - else if(id=="mouse"){ page = new page_mouse(parent); } + else if(id=="input-devices"){ page = new page_mouse(parent); } //Return the main control_panel page as the fallback/default if(page==0){ id.clear(); page = new page_main(parent); } page->setWhatsThis(id); diff --git a/src-qt5/core-utils/lumina-config/pages/page_mouse.cpp b/src-qt5/core-utils/lumina-config/pages/page_mouse.cpp index 1dd41295..36ce81dc 100644 --- a/src-qt5/core-utils/lumina-config/pages/page_mouse.cpp +++ b/src-qt5/core-utils/lumina-config/pages/page_mouse.cpp @@ -75,6 +75,7 @@ void page_mouse::generateUI(){ tree = new QTreeWidget(this); tree->setHeaderHidden(true); tree->setColumnCount(2); + connect(tree, SIGNAL(itemClicked(QTreeWidgetItem*, int)), this, SLOT(itemClicked(QTreeWidgetItem*,int)) ); if(devices[i]->isPointer()){ int tab = ui->tabWidget->addTab(tree, LXDG::findIcon("input-mouse",""), QString(tr("Mouse #%1")).arg(QString::number(mouse)) ); ui->tabWidget->setTabWhatsThis(tab, "mouse:"+QString::number(devices[i]->devNumber())); @@ -110,6 +111,7 @@ void page_mouse::populateDeviceTree(QTreeWidget *tree, LInputDevice *device){ //Now add all the child properties to this item QList<int> props = device->listProperties(); for(int i=0; i<props.length(); i++){ + if(device->propertyName(props[i]).toLower().contains("matrix")){ continue; } //skip this one - can not change from UI and most people will never want to anyway QTreeWidgetItem *tmp = new QTreeWidgetItem(top); tmp->setWhatsThis(0, QString::number(props[i]) ); tmp->setText(0, device->propertyName(props[i])); @@ -124,24 +126,27 @@ void page_mouse::populateDeviceTree(QTreeWidget *tree, LInputDevice *device){ void page_mouse::populateDeviceItemValue(QTreeWidget *tree, QTreeWidgetItem *it, QVariant value, QString id){ if(value.type()==QVariant::Int){ //Could be a boolian - check the name for known "enable" states - if(it->text(0).toLower().contains("enable") || it->text(0).toLower().contains("emulation") ){ + if(value.toInt() < 2 && (it->text(0).toLower().contains("enable") || it->text(0).toLower().contains("emulation") || it->text(0)==("XTEST Device") ) ){ //Just use a checkable column within the item bool enabled = (value.toInt()==1); it->setText(1,""); + it->setWhatsThis(1, "bool:"+id); it->setCheckState(1, enabled ? Qt::Checked : Qt::Unchecked); }else{ //Use a QSpinBox QSpinBox *box = new QSpinBox(); box->setRange(0,100); box->setValue( value.toInt() ); + box->setWhatsThis("int:"+id); tree->setItemWidget(it, 1, box); connect(box, SIGNAL(valueChanged(int)), this, SLOT(valueChanged()) ); } - }else if(value.canConvert<double>()){ + }else if(value.type()==QVariant::Double){ //Use a QDoubleSpinBox QDoubleSpinBox *box = new QDoubleSpinBox(); - box->setRange(0,100); + box->setRange(0,1000); box->setValue( value.toInt() ); + box->setWhatsThis("double:"+id); tree->setItemWidget(it, 1, box); connect(box, SIGNAL(valueChanged(double)), this, SLOT(valueChanged()) ); @@ -151,6 +156,7 @@ void page_mouse::populateDeviceItemValue(QTreeWidget *tree, QTreeWidgetItem *it, QStringList txtList; for(int i=0; i<list.length(); i++){ txtList << list[i].toString(); } it->setText(1, txtList.join(", ") ); + it->setToolTip(1, txtList.join(", ")); }else if( value.canConvert<QString>() ){ //Not Modifiable - just use the label in the item it->setText(1, value.toString()); @@ -160,24 +166,51 @@ void page_mouse::populateDeviceItemValue(QTreeWidget *tree, QTreeWidgetItem *it, // PRIVATE SLOTS //================= void page_mouse::valueChanged(){ - //WILL NOT WORK - the widgets within the tree item *do not* activate the item when clicked - // - so the current item is NOT guaranteed to be the one which was modified - //Get the current Tab/TreeWidget - QTreeWidget *tree = static_cast<QTreeWidget*>(ui->tabWidget->widget( ui->tabWidget->currentIndex() ) ); - if(tree==0){ return; } - //Now get the current item in the tree - QTreeWidgetItem *it = tree->currentItem(); - if(it==0){ return; } - qDebug() << "Item Value Changed:" << it->text(0); - //Now read the value of the item and save that into the device + //Now get the currently focused widget + QWidget *foc = this->focusWidget(); + if(foc==0){ return; } + //qDebug() << "Focus Widget:" << foc->whatsThis(); + //Now pull out the value and device/property numbers + unsigned int dev = foc->whatsThis().section(":",1,1).toInt(); + int prop = foc->whatsThis().section(":",2,2).toInt(); QVariant value; - if(tree->itemWidget(it, 1)!=0){ - //Got Item Widget - - }else if(it->text(1)==""){ - //Checkbox - value = QVariant( (it->checkState(1)==Qt::Checked) ? 1 : 0 ); + if(foc->whatsThis().startsWith("int:")){ value.setValue( static_cast<QSpinBox*>(foc)->value() ); } + else if(foc->whatsThis().startsWith("double:")){ value.setValue( static_cast<QDoubleSpinBox*>(foc)->value() ); } + //Now change the property for the device + qDebug() << " - Device:" <<dev << "prop:" << prop << "value:" << value; + for(int i=0; i<devices.length(); i++){ + if(devices[i]->devNumber() == dev){ + bool ok = devices[i]->setPropertyValue(prop, value); + if(ok){ foc->setStyleSheet(""); } + else{ foc->setStyleSheet("background: red"); } + //qDebug() << " - Changed property:" << (ok ? "success" : "failure"); + break; + } } +} - +void page_mouse::itemClicked(QTreeWidgetItem *it, int col){ + if(col!=1){ return; } //only care about value changes + if(it->whatsThis(1).isEmpty()){ return; }//not a checkable item + qDebug() << "item Clicked:" << it->whatsThis(1) << it->text(0); + //Now pull out the value and device/property numbers + unsigned int dev = it->whatsThis(1).section(":",1,1).toInt(); + int prop = it->whatsThis(1).section(":",2,2).toInt(); + QVariant value( (it->checkState(1)==Qt::Checked) ? 1 : 0 ); + //Now change the property for the device + qDebug() << " - Device:" <<dev << "prop:" << prop << "value:" << value; + for(int i=0; i<devices.length(); i++){ + if(devices[i]->devNumber() == dev){ + //Since this "clicked" signal can get sent out even if the value has not changed, go ahead and make sure we have a different value first + QVariant current = devices[i]->getPropertyValue(prop); + //qDebug() << " - Current Value:" << current; + if(value.toInt()!=current.toInt()){ + bool ok = devices[i]->setPropertyValue(prop, value); + //if(ok){ foc->setStyleSheet(""); } + //else{ foc->setStyleSheet("background: red"); } + qDebug() << " - Changed property:" << (ok ? "success" : "failure"); + } + break; + } + } } diff --git a/src-qt5/core-utils/lumina-config/pages/page_mouse.h b/src-qt5/core-utils/lumina-config/pages/page_mouse.h index d16ec214..00487910 100644 --- a/src-qt5/core-utils/lumina-config/pages/page_mouse.h +++ b/src-qt5/core-utils/lumina-config/pages/page_mouse.h @@ -10,6 +10,7 @@ #include "PageWidget.h" #include <LInputDevice.h> +#include <QTreeWidgetItem> namespace Ui{ class page_mouse; @@ -36,6 +37,7 @@ private: private slots: void valueChanged(); + void itemClicked(QTreeWidgetItem*, int); }; #endif -- cgit From 0808bfd0808415b0ea186254ae120029c584939b Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Wed, 7 Dec 2016 11:12:30 -0500 Subject: Add some more filtering for mouse devices: Hide all the trivial/unchangeable pointer devices, and list all the other mouse devices (even extension devices) as distinct mice. --- src-qt5/core-utils/lumina-config/pages/page_mouse.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src-qt5') diff --git a/src-qt5/core-utils/lumina-config/pages/page_mouse.cpp b/src-qt5/core-utils/lumina-config/pages/page_mouse.cpp index 36ce81dc..8f5c0c23 100644 --- a/src-qt5/core-utils/lumina-config/pages/page_mouse.cpp +++ b/src-qt5/core-utils/lumina-config/pages/page_mouse.cpp @@ -70,7 +70,8 @@ void page_mouse::generateUI(){ qDebug() << "Devices Found:" << devices.length(); for(int i=0; i<devices.length(); i++){ QTreeWidget *tree = 0; - if(!devices[i]->isExtension()){ + if(!devices[i]->isExtension() || devices[i]->isPointer()){ + if(devices[i]->isPointer() && devices[i]->listProperties().count() <4){ continue; } //filter out all the trivial/static mouse devices //Make a new tab for this device tree = new QTreeWidget(this); tree->setHeaderHidden(true); -- cgit From e4f0a0c307e7b3eb1ec820777a1d15e38826d8b0 Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Wed, 7 Dec 2016 13:12:27 -0500 Subject: Cleanup some more of the terminal functionality: 1) Auto-hide the window when it loses focus 2) Give the terminal widget focus when it is clicked on 3) When starting the PTY do one interaction with it programmatically to ensure it is *really* ready before the user starts using it. --- src-qt5/desktop-utils/lumina-terminal/TermWindow.cpp | 10 +++++++++- src-qt5/desktop-utils/lumina-terminal/TermWindow.h | 4 +++- .../desktop-utils/lumina-terminal/TerminalWidget.cpp | 1 + src-qt5/desktop-utils/lumina-terminal/TrayIcon.cpp | 1 + src-qt5/desktop-utils/lumina-terminal/TtyProcess.cpp | 19 ++++++++++++++++++- src-qt5/desktop-utils/lumina-terminal/TtyProcess.h | 1 + 6 files changed, 33 insertions(+), 3 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/desktop-utils/lumina-terminal/TermWindow.cpp b/src-qt5/desktop-utils/lumina-terminal/TermWindow.cpp index b400ac6e..783fc482 100644 --- a/src-qt5/desktop-utils/lumina-terminal/TermWindow.cpp +++ b/src-qt5/desktop-utils/lumina-terminal/TermWindow.cpp @@ -57,7 +57,7 @@ TermWindow::TermWindow(QSettings *set) : QWidget(0, Qt::Window | Qt::BypassWindo connect(closeS, SIGNAL(activated()), this, SLOT(CloseWindow()) ); connect(prevTabS, SIGNAL(activated()), this, SLOT(Prev_Tab()) ); connect(nextTabS, SIGNAL(activated()), this, SLOT(Next_Tab()) ); - + connect(QApplication::instance(), SIGNAL(applicationStateChanged(Qt::ApplicationState)), this, SLOT(activeStatusChanged()) ); //Now set the defaults screennum = 0; //default value setTopOfScreen(true); //default value @@ -282,6 +282,14 @@ void TermWindow::AnimFinished(){ animRunning = -1; //done } +void TermWindow::activeStatusChanged(){ + //Note: Qt 5.6.1 returns the opposite value for isActiveWindow() (12/7/16) + //qDebug() << "active status changed:" << this->isActiveWindow() << (this == QApplication::activeWindow()); + if(animRunning>=0){ return; } //ignore this event - already changing + if(!this->isActiveWindow() && !this->isVisible()){ ShowWindow(); } + else if(this->isActiveWindow() && this->isVisible()){ HideWindow(); } +} + // =================== // PROTECTED // =================== diff --git a/src-qt5/desktop-utils/lumina-terminal/TermWindow.h b/src-qt5/desktop-utils/lumina-terminal/TermWindow.h index d68c5457..d21fe502 100644 --- a/src-qt5/desktop-utils/lumina-terminal/TermWindow.h +++ b/src-qt5/desktop-utils/lumina-terminal/TermWindow.h @@ -56,7 +56,9 @@ private slots: void focusOnWidget(); //Animation finishing void AnimFinished(); - + //Window focus/active status changed + void activeStatusChanged(); + protected: void mouseMoveEvent(QMouseEvent*); diff --git a/src-qt5/desktop-utils/lumina-terminal/TerminalWidget.cpp b/src-qt5/desktop-utils/lumina-terminal/TerminalWidget.cpp index d9099452..6342be59 100644 --- a/src-qt5/desktop-utils/lumina-terminal/TerminalWidget.cpp +++ b/src-qt5/desktop-utils/lumina-terminal/TerminalWidget.cpp @@ -471,6 +471,7 @@ void TerminalWidget::keyPressEvent(QKeyEvent *ev){ void TerminalWidget::mousePressEvent(QMouseEvent *ev){ this->setFocus(); + this->activateWindow(); if(ev->button()==Qt::RightButton){ QTextEdit::mousePressEvent(ev); }else if(ev->button()==Qt::MiddleButton){ diff --git a/src-qt5/desktop-utils/lumina-terminal/TrayIcon.cpp b/src-qt5/desktop-utils/lumina-terminal/TrayIcon.cpp index 52e15314..5198146e 100644 --- a/src-qt5/desktop-utils/lumina-terminal/TrayIcon.cpp +++ b/src-qt5/desktop-utils/lumina-terminal/TrayIcon.cpp @@ -145,6 +145,7 @@ void TrayIcon::updateScreenMenu(){ } } ScreenMenu->setVisible(!ScreenMenu->isEmpty()); + ScreenMenu->setEnabled(!ScreenMenu->isEmpty()); } void TrayIcon::TrayActivated(QSystemTrayIcon::ActivationReason reason){ diff --git a/src-qt5/desktop-utils/lumina-terminal/TtyProcess.cpp b/src-qt5/desktop-utils/lumina-terminal/TtyProcess.cpp index 24124348..a1ee0be7 100644 --- a/src-qt5/desktop-utils/lumina-terminal/TtyProcess.cpp +++ b/src-qt5/desktop-utils/lumina-terminal/TtyProcess.cpp @@ -2,11 +2,13 @@ #include <QDir> #include <QProcessEnvironment> +#include <QTimer> TTYProcess::TTYProcess(QObject *parent) : QObject(parent){ childProc = 0; sn = 0; ttyfd = 0; + starting = true; } TTYProcess::~TTYProcess(){ @@ -59,6 +61,12 @@ bool TTYProcess::startTTY(QString prog, QStringList args, QString workdir){ connect(sn, SIGNAL(activated(int)), this, SLOT(checkStatus(int)) ); ttyfd = FD; qDebug() << " - PTY:" << ptsname(FD); + //BUG BYPASS - 12/7/16 + //If the PTY gets input fairly soon after starting, the PTY will re-print the initial line(s) + // So send the "newline" signal now to get things started + starting = true; + //writeTTY("\n"); //newline + //writeTTY(QByteArray("\x1b[2J") ); //clear display return true; } } @@ -97,12 +105,21 @@ QByteArray TTYProcess::readTTY(){ } bool bad = true; BA = CleanANSI(BA, bad); - if(bad){ + if(bad){ //incomplete fragent - read some more first fragBA = BA; return readTTY(); }else{ //qDebug() << "Read Data:" << BA; + if(starting && !BA.contains("\n") ){ + //qDebug() << "Starting phase 1:" << BA; + writeTTY("\n\b"); //newline + backspace + BA.clear(); + }else if(starting){ + //qDebug() << "Starting phase 2:" << BA; + BA.remove(0, BA.indexOf("\n")+1); + starting = false; + } return BA; } } diff --git a/src-qt5/desktop-utils/lumina-terminal/TtyProcess.h b/src-qt5/desktop-utils/lumina-terminal/TtyProcess.h index 9b3873b0..1603fe5e 100644 --- a/src-qt5/desktop-utils/lumina-terminal/TtyProcess.h +++ b/src-qt5/desktop-utils/lumina-terminal/TtyProcess.h @@ -60,6 +60,7 @@ private: int ttyfd; QSocketNotifier *sn; QByteArray fragBA; //fragment ByteArray + bool starting; //==================================== // C Library function for setting up the PTY -- cgit From 0f18a11a64a6a112b5bf9e612c086da882f3c65f Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Wed, 7 Dec 2016 13:27:30 -0500 Subject: Disable the auto-hide on activation event - something weird is going on (probably due to the special flags on the terminal window). --- src-qt5/desktop-utils/lumina-terminal/TermWindow.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/desktop-utils/lumina-terminal/TermWindow.cpp b/src-qt5/desktop-utils/lumina-terminal/TermWindow.cpp index 783fc482..8ff3ecd1 100644 --- a/src-qt5/desktop-utils/lumina-terminal/TermWindow.cpp +++ b/src-qt5/desktop-utils/lumina-terminal/TermWindow.cpp @@ -286,8 +286,9 @@ void TermWindow::activeStatusChanged(){ //Note: Qt 5.6.1 returns the opposite value for isActiveWindow() (12/7/16) //qDebug() << "active status changed:" << this->isActiveWindow() << (this == QApplication::activeWindow()); if(animRunning>=0){ return; } //ignore this event - already changing - if(!this->isActiveWindow() && !this->isVisible()){ ShowWindow(); } - else if(this->isActiveWindow() && this->isVisible()){ HideWindow(); } + //if(!this->isActiveWindow() && !this->isVisible()){ ShowWindow(); } + //else if(this->isActiveWindow() this->isVisible()){ HideWindow(); } + //ReShowWindow(); } // =================== -- cgit From df9192bf18a26083ed7775ef6699f6c46781e476 Mon Sep 17 00:00:00 2001 From: q5sys <jt@obs-sec.com> Date: Thu, 8 Dec 2016 00:51:19 -0500 Subject: testing mouse util --- src-qt5/core-utils/lumina-config/pages/getPage.h | 3 +++ src-qt5/core-utils/lumina-config/pages/page_mouse.h | 8 ++++---- src-qt5/core-utils/lumina-config/pages/pages.pri | 9 ++++++--- 3 files changed, 13 insertions(+), 7 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/core-utils/lumina-config/pages/getPage.h b/src-qt5/core-utils/lumina-config/pages/getPage.h index b209bb20..aeeade43 100644 --- a/src-qt5/core-utils/lumina-config/pages/getPage.h +++ b/src-qt5/core-utils/lumina-config/pages/getPage.h @@ -39,6 +39,7 @@ static QList<PAGEINFO> KnownPages(){ list << PageInfo("session-locale", QObject::tr("Localization"), QObject::tr("Locale Settings"), "preferences-desktop-locale",QObject::tr("Change the default locale settings for this user"), "user", QStringList(), QStringList() << "user"<<"locale"<<"language"<<"translations"); list << PageInfo("session-options", QObject::tr("General Options"), QObject::tr("User Settings"), "configure",QObject::tr("Change basic user settings such as time/date formats"), "user", QStringList(), QStringList() << "user"<<"settings"<<"time"<<"date"<<"icon"<<"reset"<<"numlock"<<"clock"); list << PageInfo("input-devices", QObject::tr("Input Device Settings"), QObject::tr("Input Device Settings"), "preferences-desktop-peripherals",QObject::tr("Adjust keyboard and mouse devices"), "user", QStringList(), QStringList() << "user"<<"speed"<<"accel"<<"mouse" << "keyboard"); + list << PageInfo("mouse-settings", QObject::tr("Mouse Settings"), QObject::tr("Mouse Settings"), "preferences-desktop-mouse",QObject::tr("Adjust mouse devices"), "user", QStringList(), QStringList() << "user"<<"speed"<<"accel"<<"mouse"); //Now sort the items according to the translated name QStringList names; for(int i=0; i<list.length(); i++){ names << list[i].name; } @@ -67,6 +68,7 @@ static QList<PAGEINFO> KnownPages(){ #include "page_session_options.h" #include "page_compton.h" #include "page_mouse.h" +#include "page_mouse_trueos.h" static PageWidget* GetNewPage(QString id, QWidget *parent){ //Find the page that matches this "id" @@ -84,6 +86,7 @@ static PageWidget* GetNewPage(QString id, QWidget *parent){ else if(id=="session-options"){ page = new page_session_options(parent); } else if(id=="compton"){ page = new page_compton(parent); } else if(id=="input-devices"){ page = new page_mouse(parent); } + else if(id=="mouse-settings"){ page = new page_mouse_trueos(parent); } //Return the main control_panel page as the fallback/default if(page==0){ id.clear(); page = new page_main(parent); } page->setWhatsThis(id); diff --git a/src-qt5/core-utils/lumina-config/pages/page_mouse.h b/src-qt5/core-utils/lumina-config/pages/page_mouse.h index 00487910..47b90303 100644 --- a/src-qt5/core-utils/lumina-config/pages/page_mouse.h +++ b/src-qt5/core-utils/lumina-config/pages/page_mouse.h @@ -13,14 +13,14 @@ #include <QTreeWidgetItem> namespace Ui{ - class page_mouse; + class page_mouse; }; class page_mouse : public PageWidget{ Q_OBJECT public: - page_mouse(QWidget *parent); - ~page_mouse(); + page_mouse(QWidget *parent); + ~page_mouse(); public slots: void SaveSettings(); @@ -28,7 +28,7 @@ public slots: void updateIcons(); private: - Ui::page_mouse *ui; + Ui::page_mouse *ui; QList<LInputDevice*> devices; void generateUI(); diff --git a/src-qt5/core-utils/lumina-config/pages/pages.pri b/src-qt5/core-utils/lumina-config/pages/pages.pri index b36ca7ba..4ea13f01 100644 --- a/src-qt5/core-utils/lumina-config/pages/pages.pri +++ b/src-qt5/core-utils/lumina-config/pages/pages.pri @@ -14,7 +14,8 @@ HEADERS += $${PWD}/getPage.h \ $${PWD}/page_session_locale.h \ $${PWD}/page_session_options.h \ $${PWD}/page_compton.h \ - $${PWD}/page_mouse.h + $${PWD}/page_mouse.h \ + $$PWD/page_mouse_trueos.h SOURCES += $${PWD}/page_main.cpp \ @@ -30,7 +31,8 @@ SOURCES += $${PWD}/page_main.cpp \ $${PWD}/page_session_locale.cpp \ $${PWD}/page_session_options.cpp \ $${PWD}/page_compton.cpp \ - $${PWD}/page_mouse.cpp + $${PWD}/page_mouse.cpp \ + $$PWD/page_mouse_trueos.cpp FORMS += $${PWD}/page_main.ui \ @@ -46,4 +48,5 @@ FORMS += $${PWD}/page_main.ui \ $${PWD}/page_session_locale.ui \ $${PWD}/page_session_options.ui \ $${PWD}/page_compton.ui \ - $${PWD}/page_mouse.ui + $${PWD}/page_mouse.ui \ + $$PWD/page_mouse_trueos.ui -- cgit From f5e58ea4eed72f6755b887740a5fa76320eae5ed Mon Sep 17 00:00:00 2001 From: q5sys <jt@obs-sec.com> Date: Thu, 8 Dec 2016 00:53:59 -0500 Subject: it would help if I actually pushed the pages --- .../lumina-config/pages/page_mouse_trueos.cpp | 256 ++++++++++++ .../lumina-config/pages/page_mouse_trueos.h | 63 +++ .../lumina-config/pages/page_mouse_trueos.ui | 427 +++++++++++++++++++++ 3 files changed, 746 insertions(+) create mode 100644 src-qt5/core-utils/lumina-config/pages/page_mouse_trueos.cpp create mode 100644 src-qt5/core-utils/lumina-config/pages/page_mouse_trueos.h create mode 100644 src-qt5/core-utils/lumina-config/pages/page_mouse_trueos.ui (limited to 'src-qt5') diff --git a/src-qt5/core-utils/lumina-config/pages/page_mouse_trueos.cpp b/src-qt5/core-utils/lumina-config/pages/page_mouse_trueos.cpp new file mode 100644 index 00000000..63c0838e --- /dev/null +++ b/src-qt5/core-utils/lumina-config/pages/page_mouse_trueos.cpp @@ -0,0 +1,256 @@ +//=========================================== +// Lumina Desktop Source Code +// Copyright (c) 2016, Ken Moore +// Available under the 3-clause BSD license +// See the LICENSE file for full details +//=========================================== +#include "page_mouse_trueos.h" +#include "ui_page_mouse_trueos.h" +#include "getPage.h" + +#include <QSpinBox> +#include <QDoubleSpinBox> +#include <QDebug> +#include <QProcess> + + +//========== +// PUBLIC +//========== +page_mouse_trueos::page_mouse_trueos(QWidget *parent) : PageWidget(parent), ui(new Ui::page_mouse_trueos()){ + ui->setupUi(this); +// devices = LInput::listDevices(); + //DEBUG Code + /*qDebug() << "List Devices:"; + for(int i=0; i<devices.length(); i++){ + if(!devices[i]->isPointer()){ + ::free( devices.takeAt(i)); + i--; + }else{ + qDebug() << "Found Pointer:" << devices[i]->devNumber(); + qDebug() << " - isExtension:" << devices[i]->isExtension(); + QList<int> props = devices[i]->listProperties(); + qDebug() << " - Properties:"; + for(int j=0; j<props.length(); j++){ + qDebug() << " --" <<devices[i]->propertyName(props[j])+" ("+QString::number(props[j])+")" <<" = " << devices[i]->getPropertyValue(props[j]); + } + } + }*/ + QString program = "/usr/sbin/moused"; + ui->slider_mouseAcceleration->setRange(1,200); + ui->slider_mouseAcceleration->setValue(100); + ui->slider_doubleClickThreshold->setRange(1,1000); + ui->slider_doubleClickThreshold->setValue(500); + + connect( ui->slider_mouseAcceleration, SIGNAL(valueChanged(int)), this, SLOT(setValue(double))); + realAccelValue = ( ui->slider_mouseAcceleration->value() / divisor); + realAccelValueString = QString::number(ui->slider_mouseAcceleration->value() / divisor, 'f', 2); + connect( ui->slider_doubleClickThreshold, SIGNAL(valueChanged(int)), this, SLOT(setValue(double))); + realDoubleClickValue = (ui->slider_doubleClickThreshold->value()); + realDoubleClickValueString = QString::number(ui->slider_doubleClickThreshold->value()); + + connect( ui->button_apply, SIGNAL(clicked()), this, SLOT(updateMoused())); + + connect(ui->checkBoxHandedness, SIGNAL(toggled(bool)), this, SLOT(swapHandedness()) ); + connect(ui->checkBoxTerminateDrift, SIGNAL(toggled(bool)), this, SLOT(terminateDrift()) ); + + ui->combobox_resolutionBox->setCurrentIndex(1); + connect(ui->combobox_resolutionBox, SIGNAL(currentIndexChanged(QString)), this, SLOT(setMouseResolution()) ); + +} + +page_mouse_trueos::~page_mouse_trueos(){ +// for(int i=0; i<devices.length(); i++){ ::free(devices[i]); } +} + +//================ +// PUBLIC SLOTS +//================ +void page_mouse_trueos::SaveSettings(){ + + emit HasPendingChanges(false); +} + +void page_mouse_trueos::LoadSettings(int){ + emit HasPendingChanges(false); + emit ChangePageTitle( tr("Mouse Settings") ); + +} +/* +void page_mouse_trueos::updateIcons(){ + for(int i=0; i<ui->tabWidget->count(); i++){ + ui->tabWidget->setTabIcon( i, LXDG::findIcon( "input-"+ui->tabWidget->tabWhatsThis(i).section(":",0,0), "" ) ); + } +} +*/ + +//================= +// PRIVATE +//================= + +void page_mouse_trueos::swapHandedness(){ + if(ui->checkBoxHandedness->isChecked()){ + handString = "-m 1=3 -m 3=1"; + } + else{ + handString = "-m 1=1 -m 3=3"; + } +} + +void page_mouse_trueos::setMouseResolution(){ + resolutionValue = ui->combobox_resolutionBox->itemText(ui->combobox_resolutionBox->currentIndex()); + resString = "-r " + resolutionValue; +} + +void page_mouse_trueos::setMouseAcceleration(){ + realAccelValue = ( ui->slider_mouseAcceleration->value() / divisor); + realAccelValueString = QString::number( ui->slider_mouseAcceleration->value() / divisor, 'f', 2); + accelString = "-a " + realAccelValueString; +} + +void page_mouse_trueos::setDoubleClickThreshold(){ + realDoubleClickValueString = QString::number( ui->slider_doubleClickThreshold->value()); + dclickString = "-C " + realDoubleClickValueString; +} + +void page_mouse_trueos::terminateDrift(){ + if(ui->checkBoxTerminateDrift->isChecked()){ + driftString = "-T 4[,500[,4000]]"; + } + else{ + driftString = ""; + } +} + +void page_mouse_trueos::updateMoused(){ + setMouseAcceleration(); setDoubleClickThreshold(); + qDebug() << "handString" << handString; + qDebug() << "resString" << resString; + qDebug() << "accelString" << accelString; + qDebug() << "dclickString" << dclickString; + qDebug() << "driftstring" << driftString; + deviceString = "-p /dev/sysmouse"; + mousedargs << deviceString << handString << resString << accelString << dclickString << driftString; + qDebug() << "mousedargs" << mousedargs; + QProcess *moused = new QProcess(this); + moused->start(program, mousedargs); + +} + +/* +void page_mouse_trueos::populateDeviceTree(QTreeWidget *tree, LInputDevice *device){ + QTreeWidgetItem *top = new QTreeWidgetItem(tree); + if(device->isExtension()){ + top->setText( 0, QString(tr("Extension Device #%1")).arg(QString::number(tree->topLevelItemCount())) ); + }else{ top->setText(0, tr("Master Device")); } + top->setWhatsThis(0, QString(device->isPointer() ? "mouse" : "keyboard")+":"+QString::number(device->devNumber()) ); //save this for later + top->setFirstColumnSpanned(true); + top->setExpanded(true); + tree->addTopLevelItem(top); + //Now add all the child properties to this item + QList<int> props = device->listProperties(); + for(int i=0; i<props.length(); i++){ + if(device->propertyName(props[i]).toLower().contains("matrix")){ continue; } //skip this one - can not change from UI and most people will never want to anyway + QTreeWidgetItem *tmp = new QTreeWidgetItem(top); + tmp->setWhatsThis(0, QString::number(props[i]) ); + tmp->setText(0, device->propertyName(props[i])); + top->addChild(tmp); + populateDeviceItemValue(tree, tmp, device->getPropertyValue(props[i]), QString::number(device->devNumber())+":"+QString::number(props[i]) ); + } + //Clean up the tree widget as needed + top->sortChildren(0, Qt::AscendingOrder); + tree->resizeColumnToContents(0); +} + +void page_mouse_trueos::populateDeviceItemValue(QTreeWidget *tree, QTreeWidgetItem *it, QVariant value, QString id){ + if(value.type()==QVariant::Int){ + //Could be a boolian - check the name for known "enable" states + if(value.toInt() < 2 && (it->text(0).toLower().contains("enable") || it->text(0).toLower().contains("emulation") || it->text(0)==("XTEST Device") ) ){ + //Just use a checkable column within the item + bool enabled = (value.toInt()==1); + it->setText(1,""); + it->setWhatsThis(1, "bool:"+id); + it->setCheckState(1, enabled ? Qt::Checked : Qt::Unchecked); + }else{ + //Use a QSpinBox + QSpinBox *box = new QSpinBox(); + box->setRange(0,100); + box->setValue( value.toInt() ); + box->setWhatsThis("int:"+id); + tree->setItemWidget(it, 1, box); + connect(box, SIGNAL(valueChanged(int)), this, SLOT(valueChanged()) ); + } + }else if(value.type()==QVariant::Double){ + //Use a QDoubleSpinBox + QDoubleSpinBox *box = new QDoubleSpinBox(); + box->setRange(0,1000); + box->setValue( value.toInt() ); + box->setWhatsThis("double:"+id); + tree->setItemWidget(it, 1, box); + connect(box, SIGNAL(valueChanged(double)), this, SLOT(valueChanged()) ); + + }else if(value.canConvert<QList<QVariant>>()){ + //Not Modifiable - just use the label in the item + QList<QVariant> list = value.toList(); + QStringList txtList; + for(int i=0; i<list.length(); i++){ txtList << list[i].toString(); } + it->setText(1, txtList.join(", ") ); + it->setToolTip(1, txtList.join(", ")); + }else if( value.canConvert<QString>() ){ + //Not Modifiable - just use the label in the item + it->setText(1, value.toString()); + } +} +//================= +// PRIVATE SLOTS +//================= +void page_mouse_trueos::valueChanged(){ + //Now get the currently focused widget + QWidget *foc = this->focusWidget(); + if(foc==0){ return; } + //qDebug() << "Focus Widget:" << foc->whatsThis(); + //Now pull out the value and device/property numbers + unsigned int dev = foc->whatsThis().section(":",1,1).toInt(); + int prop = foc->whatsThis().section(":",2,2).toInt(); + QVariant value; + if(foc->whatsThis().startsWith("int:")){ value.setValue( static_cast<QSpinBox*>(foc)->value() ); } + else if(foc->whatsThis().startsWith("double:")){ value.setValue( static_cast<QDoubleSpinBox*>(foc)->value() ); } + //Now change the property for the device + qDebug() << " - Device:" <<dev << "prop:" << prop << "value:" << value; + for(int i=0; i<devices.length(); i++){ + if(devices[i]->devNumber() == dev){ + bool ok = devices[i]->setPropertyValue(prop, value); + if(ok){ foc->setStyleSheet(""); } + else{ foc->setStyleSheet("background: red"); } + //qDebug() << " - Changed property:" << (ok ? "success" : "failure"); + break; + } + } +} + +void page_mouse_trueos::itemClicked(QTreeWidgetItem *it, int col){ + if(col!=1){ return; } //only care about value changes + if(it->whatsThis(1).isEmpty()){ return; }//not a checkable item + qDebug() << "item Clicked:" << it->whatsThis(1) << it->text(0); + //Now pull out the value and device/property numbers + unsigned int dev = it->whatsThis(1).section(":",1,1).toInt(); + int prop = it->whatsThis(1).section(":",2,2).toInt(); + QVariant value( (it->checkState(1)==Qt::Checked) ? 1 : 0 ); + //Now change the property for the device + qDebug() << " - Device:" <<dev << "prop:" << prop << "value:" << value; + for(int i=0; i<devices.length(); i++){ + if(devices[i]->devNumber() == dev){ + //Since this "clicked" signal can get sent out even if the value has not changed, go ahead and make sure we have a different value first + QVariant current = devices[i]->getPropertyValue(prop); + //qDebug() << " - Current Value:" << current; + if(value.toInt()!=current.toInt()){ + bool ok = devices[i]->setPropertyValue(prop, value); + //if(ok){ foc->setStyleSheet(""); } + //else{ foc->setStyleSheet("background: red"); } + qDebug() << " - Changed property:" << (ok ? "success" : "failure"); + } + break; + } + } +} +*/ diff --git a/src-qt5/core-utils/lumina-config/pages/page_mouse_trueos.h b/src-qt5/core-utils/lumina-config/pages/page_mouse_trueos.h new file mode 100644 index 00000000..a5db261b --- /dev/null +++ b/src-qt5/core-utils/lumina-config/pages/page_mouse_trueos.h @@ -0,0 +1,63 @@ +//=========================================== +// Lumina Desktop Source Code +// Copyright (c) 2016, Ken Moore +// Available under the 3-clause BSD license +// See the LICENSE file for full details +//=========================================== +#ifndef _LUMINA_CONFIG_PAGE_MOUSE_TRUEOS_H +#define _LUMINA_CONFIG_PAGE_MOUSE_TRUEOS_H +#include "../globals.h" +#include "PageWidget.h" + +#include <LInputDevice.h> +#include <QTreeWidgetItem> + +namespace Ui{ + class page_mouse_trueos; +}; + +class page_mouse_trueos : public PageWidget{ + Q_OBJECT +public: + page_mouse_trueos(QWidget *parent); + ~page_mouse_trueos(); + const double divisor = 100; + double realAccelValue; + QString realAccelValueString; + double realDoubleClickValue; + QString realDoubleClickValueString; + QString resolutionValue; + QString handString; + QString resString; + QString dclickString; + QString driftString; + QString accelString; + QString program; + QStringList mousedargs; + QString deviceString; + + +public slots: + void SaveSettings(); + void LoadSettings(int screennum); +// void updateIcons(); + void swapHandedness(); + void setMouseResolution(); + void setMouseAcceleration(); + void setDoubleClickThreshold(); + void terminateDrift(); + void updateMoused(); + + + + +private: + Ui::page_mouse_trueos *ui; +// QList<LInputDevice*> devices; + + +private slots: + + +}; +#endif diff --git a/src-qt5/core-utils/lumina-config/pages/page_mouse_trueos.ui b/src-qt5/core-utils/lumina-config/pages/page_mouse_trueos.ui new file mode 100644 index 00000000..6a974d4c --- /dev/null +++ b/src-qt5/core-utils/lumina-config/pages/page_mouse_trueos.ui @@ -0,0 +1,427 @@ +<?xml version="1.0" encoding="UTF-8"?> +<ui version="4.0"> + <class>page_mouse_trueos</class> + <widget class="QWidget" name="page_mouse_trueos"> + <property name="geometry"> + <rect> + <x>0</x> + <y>0</y> + <width>427</width> + <height>417</height> + </rect> + </property> + <property name="windowTitle"> + <string>Form</string> + </property> + <layout class="QVBoxLayout" name="verticalLayout_4"> + <item> + <spacer name="verticalSpacer"> + <property name="orientation"> + <enum>Qt::Vertical</enum> + </property> + <property name="sizeHint" stdset="0"> + <size> + <width>20</width> + <height>40</height> + </size> + </property> + </spacer> + </item> + <item> + <layout class="QFormLayout" name="formLayout"> + <item row="0" column="1"> + <layout class="QHBoxLayout" name="horizontalLayout_5"> + <item> + <widget class="QLabel" name="label_7"> + <property name="text"> + <string>Mouse Acceleration</string> + </property> + </widget> + </item> + <item> + <spacer name="horizontalSpacer_2"> + <property name="orientation"> + <enum>Qt::Horizontal</enum> + </property> + <property name="sizeHint" stdset="0"> + <size> + <width>40</width> + <height>20</height> + </size> + </property> + </spacer> + </item> + <item> + <widget class="QLabel" name="label_8"> + <property name="text"> + <string>( default = 1)</string> + </property> + </widget> + </item> + </layout> + </item> + <item row="1" column="1"> + <layout class="QVBoxLayout" name="verticalLayout"> + <item> + <layout class="QHBoxLayout" name="horizontalLayout"> + <item> + <widget class="QLabel" name="label"> + <property name="sizePolicy"> + <sizepolicy hsizetype="Preferred" vsizetype="Minimum"> + <horstretch>0</horstretch> + <verstretch>0</verstretch> + </sizepolicy> + </property> + <property name="text"> + <string>0</string> + </property> + </widget> + </item> + <item> + <spacer name="horizontalSpacer_4"> + <property name="sizePolicy"> + <sizepolicy hsizetype="Expanding" vsizetype="Minimum"> + <horstretch>0</horstretch> + <verstretch>0</verstretch> + </sizepolicy> + </property> + <property name="orientation"> + <enum>Qt::Horizontal</enum> + </property> + <property name="sizeHint" stdset="0"> + <size> + <width>40</width> + <height>20</height> + </size> + </property> + </spacer> + </item> + <item> + <widget class="QLabel" name="label_2"> + <property name="sizePolicy"> + <sizepolicy hsizetype="Preferred" vsizetype="Minimum"> + <horstretch>0</horstretch> + <verstretch>0</verstretch> + </sizepolicy> + </property> + <property name="text"> + <string>1</string> + </property> + </widget> + </item> + <item> + <spacer name="horizontalSpacer_5"> + <property name="sizePolicy"> + <sizepolicy hsizetype="Expanding" vsizetype="Minimum"> + <horstretch>0</horstretch> + <verstretch>0</verstretch> + </sizepolicy> + </property> + <property name="orientation"> + <enum>Qt::Horizontal</enum> + </property> + <property name="sizeHint" stdset="0"> + <size> + <width>40</width> + <height>20</height> + </size> + </property> + </spacer> + </item> + <item> + <widget class="QLabel" name="label_3"> + <property name="sizePolicy"> + <sizepolicy hsizetype="Preferred" vsizetype="Minimum"> + <horstretch>0</horstretch> + <verstretch>0</verstretch> + </sizepolicy> + </property> + <property name="text"> + <string>2</string> + </property> + </widget> + </item> + </layout> + </item> + <item> + <widget class="QSlider" name="slider_mouseAcceleration"> + <property name="sizePolicy"> + <sizepolicy hsizetype="Expanding" vsizetype="Minimum"> + <horstretch>0</horstretch> + <verstretch>0</verstretch> + </sizepolicy> + </property> + <property name="maximum"> + <number>200</number> + </property> + <property name="singleStep"> + <number>20</number> + </property> + <property name="pageStep"> + <number>20</number> + </property> + <property name="value"> + <number>100</number> + </property> + <property name="orientation"> + <enum>Qt::Horizontal</enum> + </property> + <property name="invertedAppearance"> + <bool>false</bool> + </property> + <property name="tickPosition"> + <enum>QSlider::TicksAbove</enum> + </property> + <property name="tickInterval"> + <number>20</number> + </property> + </widget> + </item> + </layout> + </item> + <item row="2" column="1"> + <widget class="Line" name="line"> + <property name="orientation"> + <enum>Qt::Horizontal</enum> + </property> + </widget> + </item> + <item row="3" column="1"> + <layout class="QHBoxLayout" name="horizontalLayout_6"> + <item> + <widget class="QLabel" name="label_9"> + <property name="text"> + <string>Double Click Threshold</string> + </property> + </widget> + </item> + <item> + <spacer name="horizontalSpacer_3"> + <property name="orientation"> + <enum>Qt::Horizontal</enum> + </property> + <property name="sizeHint" stdset="0"> + <size> + <width>40</width> + <height>20</height> + </size> + </property> + </spacer> + </item> + <item> + <widget class="QLabel" name="label_10"> + <property name="text"> + <string>(default = 500)</string> + </property> + </widget> + </item> + </layout> + </item> + <item row="4" column="1"> + <layout class="QVBoxLayout" name="verticalLayout_2"> + <item> + <layout class="QHBoxLayout" name="horizontalLayout_2"> + <item> + <widget class="QLabel" name="label_4"> + <property name="sizePolicy"> + <sizepolicy hsizetype="Preferred" vsizetype="Minimum"> + <horstretch>0</horstretch> + <verstretch>0</verstretch> + </sizepolicy> + </property> + <property name="text"> + <string>1ms</string> + </property> + </widget> + </item> + <item> + <spacer name="horizontalSpacer_6"> + <property name="sizePolicy"> + <sizepolicy hsizetype="Expanding" vsizetype="Minimum"> + <horstretch>0</horstretch> + <verstretch>0</verstretch> + </sizepolicy> + </property> + <property name="orientation"> + <enum>Qt::Horizontal</enum> + </property> + <property name="sizeHint" stdset="0"> + <size> + <width>40</width> + <height>20</height> + </size> + </property> + </spacer> + </item> + <item> + <widget class="QLabel" name="label_5"> + <property name="sizePolicy"> + <sizepolicy hsizetype="Preferred" vsizetype="Minimum"> + <horstretch>0</horstretch> + <verstretch>0</verstretch> + </sizepolicy> + </property> + <property name="text"> + <string>500ms</string> + </property> + </widget> + </item> + <item> + <spacer name="horizontalSpacer_7"> + <property name="orientation"> + <enum>Qt::Horizontal</enum> + </property> + <property name="sizeHint" stdset="0"> + <size> + <width>40</width> + <height>20</height> + </size> + </property> + </spacer> + </item> + <item> + <widget class="QLabel" name="label_6"> + <property name="text"> + <string>1s</string> + </property> + </widget> + </item> + </layout> + </item> + <item> + <widget class="QSlider" name="slider_doubleClickThreshold"> + <property name="sizePolicy"> + <sizepolicy hsizetype="Expanding" vsizetype="Minimum"> + <horstretch>0</horstretch> + <verstretch>0</verstretch> + </sizepolicy> + </property> + <property name="maximum"> + <number>1000</number> + </property> + <property name="singleStep"> + <number>25</number> + </property> + <property name="pageStep"> + <number>25</number> + </property> + <property name="value"> + <number>500</number> + </property> + <property name="orientation"> + <enum>Qt::Horizontal</enum> + </property> + <property name="tickPosition"> + <enum>QSlider::TicksAbove</enum> + </property> + <property name="tickInterval"> + <number>100</number> + </property> + </widget> + </item> + </layout> + </item> + <item row="5" column="1"> + <widget class="Line" name="line_3"> + <property name="orientation"> + <enum>Qt::Horizontal</enum> + </property> + </widget> + </item> + <item row="6" column="1"> + <layout class="QHBoxLayout" name="horizontalLayout_4"> + <item> + <layout class="QVBoxLayout" name="verticalLayout_3"> + <item> + <layout class="QHBoxLayout" name="horizontalLayout_3"> + <item> + <widget class="QLabel" name="label_resolutionBox"> + <property name="text"> + <string>Resolution</string> + </property> + <property name="buddy"> + <cstring>combobox_resolutionBox</cstring> + </property> + </widget> + </item> + <item> + <widget class="QComboBox" name="combobox_resolutionBox"> + <item> + <property name="text"> + <string>low</string> + </property> + </item> + <item> + <property name="text"> + <string>medium-low</string> + </property> + </item> + <item> + <property name="text"> + <string>medium-high</string> + </property> + </item> + <item> + <property name="text"> + <string>high</string> + </property> + </item> + </widget> + </item> + </layout> + </item> + <item> + <widget class="QCheckBox" name="checkBoxTerminateDrift"> + <property name="text"> + <string>Terminate Drift</string> + </property> + </widget> + </item> + <item> + <widget class="QCheckBox" name="checkBoxHandedness"> + <property name="text"> + <string>Switch Handedness</string> + </property> + </widget> + </item> + </layout> + </item> + <item> + <layout class="QHBoxLayout" name="horizontalLayout_7"> + <item> + <spacer name="horizontalSpacer"> + <property name="orientation"> + <enum>Qt::Horizontal</enum> + </property> + <property name="sizeHint" stdset="0"> + <size> + <width>40</width> + <height>20</height> + </size> + </property> + </spacer> + </item> + <item> + <widget class="QPushButton" name="button_apply"> + <property name="sizePolicy"> + <sizepolicy hsizetype="Minimum" vsizetype="MinimumExpanding"> + <horstretch>0</horstretch> + <verstretch>0</verstretch> + </sizepolicy> + </property> + <property name="text"> + <string>Apply</string> + </property> + </widget> + </item> + </layout> + </item> + </layout> + </item> + </layout> + </item> + </layout> + </widget> + <resources/> + <connections/> +</ui> -- cgit From a4d27d5a2ea057ff3dea94a2c1e7803cae3fea8b Mon Sep 17 00:00:00 2001 From: JT Pennington <jt@obs-sec.com> Date: Wed, 7 Dec 2016 21:55:29 -0800 Subject: clean up code --- src-qt5/core-utils/lumina-config/pages/page_mouse_trueos.h | 10 ---------- 1 file changed, 10 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/core-utils/lumina-config/pages/page_mouse_trueos.h b/src-qt5/core-utils/lumina-config/pages/page_mouse_trueos.h index a5db261b..ff643747 100644 --- a/src-qt5/core-utils/lumina-config/pages/page_mouse_trueos.h +++ b/src-qt5/core-utils/lumina-config/pages/page_mouse_trueos.h @@ -36,7 +36,6 @@ public: QStringList mousedargs; QString deviceString; - public slots: void SaveSettings(); void LoadSettings(int screennum); @@ -48,16 +47,7 @@ public slots: void terminateDrift(); void updateMoused(); - - - private: Ui::page_mouse_trueos *ui; -// QList<LInputDevice*> devices; - - -private slots: - - }; #endif -- cgit From 46c42fb0bdd3adee0f5d5901915ab76bc79d7cc4 Mon Sep 17 00:00:00 2001 From: JT Pennington <jt@obs-sec.com> Date: Wed, 7 Dec 2016 21:58:39 -0800 Subject: code cleanup --- .../lumina-config/pages/page_mouse_trueos.cpp | 160 +-------------------- 1 file changed, 7 insertions(+), 153 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/core-utils/lumina-config/pages/page_mouse_trueos.cpp b/src-qt5/core-utils/lumina-config/pages/page_mouse_trueos.cpp index 63c0838e..60bc2872 100644 --- a/src-qt5/core-utils/lumina-config/pages/page_mouse_trueos.cpp +++ b/src-qt5/core-utils/lumina-config/pages/page_mouse_trueos.cpp @@ -8,8 +8,6 @@ #include "ui_page_mouse_trueos.h" #include "getPage.h" -#include <QSpinBox> -#include <QDoubleSpinBox> #include <QDebug> #include <QProcess> @@ -19,48 +17,30 @@ //========== page_mouse_trueos::page_mouse_trueos(QWidget *parent) : PageWidget(parent), ui(new Ui::page_mouse_trueos()){ ui->setupUi(this); -// devices = LInput::listDevices(); - //DEBUG Code - /*qDebug() << "List Devices:"; - for(int i=0; i<devices.length(); i++){ - if(!devices[i]->isPointer()){ - ::free( devices.takeAt(i)); - i--; - }else{ - qDebug() << "Found Pointer:" << devices[i]->devNumber(); - qDebug() << " - isExtension:" << devices[i]->isExtension(); - QList<int> props = devices[i]->listProperties(); - qDebug() << " - Properties:"; - for(int j=0; j<props.length(); j++){ - qDebug() << " --" <<devices[i]->propertyName(props[j])+" ("+QString::number(props[j])+")" <<" = " << devices[i]->getPropertyValue(props[j]); - } - } - }*/ QString program = "/usr/sbin/moused"; + ui->slider_mouseAcceleration->setRange(1,200); ui->slider_mouseAcceleration->setValue(100); - ui->slider_doubleClickThreshold->setRange(1,1000); - ui->slider_doubleClickThreshold->setValue(500); - connect( ui->slider_mouseAcceleration, SIGNAL(valueChanged(int)), this, SLOT(setValue(double))); realAccelValue = ( ui->slider_mouseAcceleration->value() / divisor); realAccelValueString = QString::number(ui->slider_mouseAcceleration->value() / divisor, 'f', 2); + + ui->slider_doubleClickThreshold->setRange(1,1000); + ui->slider_doubleClickThreshold->setValue(500); connect( ui->slider_doubleClickThreshold, SIGNAL(valueChanged(int)), this, SLOT(setValue(double))); realDoubleClickValue = (ui->slider_doubleClickThreshold->value()); realDoubleClickValueString = QString::number(ui->slider_doubleClickThreshold->value()); - connect( ui->button_apply, SIGNAL(clicked()), this, SLOT(updateMoused())); + ui->combobox_resolutionBox->setCurrentIndex(1); + connect(ui->combobox_resolutionBox, SIGNAL(currentIndexChanged(QString)), this, SLOT(setMouseResolution()) ); connect(ui->checkBoxHandedness, SIGNAL(toggled(bool)), this, SLOT(swapHandedness()) ); connect(ui->checkBoxTerminateDrift, SIGNAL(toggled(bool)), this, SLOT(terminateDrift()) ); - ui->combobox_resolutionBox->setCurrentIndex(1); - connect(ui->combobox_resolutionBox, SIGNAL(currentIndexChanged(QString)), this, SLOT(setMouseResolution()) ); - + connect( ui->button_apply, SIGNAL(clicked()), this, SLOT(updateMoused())); } page_mouse_trueos::~page_mouse_trueos(){ -// for(int i=0; i<devices.length(); i++){ ::free(devices[i]); } } //================ @@ -74,15 +54,7 @@ void page_mouse_trueos::SaveSettings(){ void page_mouse_trueos::LoadSettings(int){ emit HasPendingChanges(false); emit ChangePageTitle( tr("Mouse Settings") ); - -} -/* -void page_mouse_trueos::updateIcons(){ - for(int i=0; i<ui->tabWidget->count(); i++){ - ui->tabWidget->setTabIcon( i, LXDG::findIcon( "input-"+ui->tabWidget->tabWhatsThis(i).section(":",0,0), "" ) ); - } } -*/ //================= // PRIVATE @@ -134,123 +106,5 @@ void page_mouse_trueos::updateMoused(){ qDebug() << "mousedargs" << mousedargs; QProcess *moused = new QProcess(this); moused->start(program, mousedargs); - -} - -/* -void page_mouse_trueos::populateDeviceTree(QTreeWidget *tree, LInputDevice *device){ - QTreeWidgetItem *top = new QTreeWidgetItem(tree); - if(device->isExtension()){ - top->setText( 0, QString(tr("Extension Device #%1")).arg(QString::number(tree->topLevelItemCount())) ); - }else{ top->setText(0, tr("Master Device")); } - top->setWhatsThis(0, QString(device->isPointer() ? "mouse" : "keyboard")+":"+QString::number(device->devNumber()) ); //save this for later - top->setFirstColumnSpanned(true); - top->setExpanded(true); - tree->addTopLevelItem(top); - //Now add all the child properties to this item - QList<int> props = device->listProperties(); - for(int i=0; i<props.length(); i++){ - if(device->propertyName(props[i]).toLower().contains("matrix")){ continue; } //skip this one - can not change from UI and most people will never want to anyway - QTreeWidgetItem *tmp = new QTreeWidgetItem(top); - tmp->setWhatsThis(0, QString::number(props[i]) ); - tmp->setText(0, device->propertyName(props[i])); - top->addChild(tmp); - populateDeviceItemValue(tree, tmp, device->getPropertyValue(props[i]), QString::number(device->devNumber())+":"+QString::number(props[i]) ); - } - //Clean up the tree widget as needed - top->sortChildren(0, Qt::AscendingOrder); - tree->resizeColumnToContents(0); } -void page_mouse_trueos::populateDeviceItemValue(QTreeWidget *tree, QTreeWidgetItem *it, QVariant value, QString id){ - if(value.type()==QVariant::Int){ - //Could be a boolian - check the name for known "enable" states - if(value.toInt() < 2 && (it->text(0).toLower().contains("enable") || it->text(0).toLower().contains("emulation") || it->text(0)==("XTEST Device") ) ){ - //Just use a checkable column within the item - bool enabled = (value.toInt()==1); - it->setText(1,""); - it->setWhatsThis(1, "bool:"+id); - it->setCheckState(1, enabled ? Qt::Checked : Qt::Unchecked); - }else{ - //Use a QSpinBox - QSpinBox *box = new QSpinBox(); - box->setRange(0,100); - box->setValue( value.toInt() ); - box->setWhatsThis("int:"+id); - tree->setItemWidget(it, 1, box); - connect(box, SIGNAL(valueChanged(int)), this, SLOT(valueChanged()) ); - } - }else if(value.type()==QVariant::Double){ - //Use a QDoubleSpinBox - QDoubleSpinBox *box = new QDoubleSpinBox(); - box->setRange(0,1000); - box->setValue( value.toInt() ); - box->setWhatsThis("double:"+id); - tree->setItemWidget(it, 1, box); - connect(box, SIGNAL(valueChanged(double)), this, SLOT(valueChanged()) ); - - }else if(value.canConvert<QList<QVariant>>()){ - //Not Modifiable - just use the label in the item - QList<QVariant> list = value.toList(); - QStringList txtList; - for(int i=0; i<list.length(); i++){ txtList << list[i].toString(); } - it->setText(1, txtList.join(", ") ); - it->setToolTip(1, txtList.join(", ")); - }else if( value.canConvert<QString>() ){ - //Not Modifiable - just use the label in the item - it->setText(1, value.toString()); - } -} -//================= -// PRIVATE SLOTS -//================= -void page_mouse_trueos::valueChanged(){ - //Now get the currently focused widget - QWidget *foc = this->focusWidget(); - if(foc==0){ return; } - //qDebug() << "Focus Widget:" << foc->whatsThis(); - //Now pull out the value and device/property numbers - unsigned int dev = foc->whatsThis().section(":",1,1).toInt(); - int prop = foc->whatsThis().section(":",2,2).toInt(); - QVariant value; - if(foc->whatsThis().startsWith("int:")){ value.setValue( static_cast<QSpinBox*>(foc)->value() ); } - else if(foc->whatsThis().startsWith("double:")){ value.setValue( static_cast<QDoubleSpinBox*>(foc)->value() ); } - //Now change the property for the device - qDebug() << " - Device:" <<dev << "prop:" << prop << "value:" << value; - for(int i=0; i<devices.length(); i++){ - if(devices[i]->devNumber() == dev){ - bool ok = devices[i]->setPropertyValue(prop, value); - if(ok){ foc->setStyleSheet(""); } - else{ foc->setStyleSheet("background: red"); } - //qDebug() << " - Changed property:" << (ok ? "success" : "failure"); - break; - } - } -} - -void page_mouse_trueos::itemClicked(QTreeWidgetItem *it, int col){ - if(col!=1){ return; } //only care about value changes - if(it->whatsThis(1).isEmpty()){ return; }//not a checkable item - qDebug() << "item Clicked:" << it->whatsThis(1) << it->text(0); - //Now pull out the value and device/property numbers - unsigned int dev = it->whatsThis(1).section(":",1,1).toInt(); - int prop = it->whatsThis(1).section(":",2,2).toInt(); - QVariant value( (it->checkState(1)==Qt::Checked) ? 1 : 0 ); - //Now change the property for the device - qDebug() << " - Device:" <<dev << "prop:" << prop << "value:" << value; - for(int i=0; i<devices.length(); i++){ - if(devices[i]->devNumber() == dev){ - //Since this "clicked" signal can get sent out even if the value has not changed, go ahead and make sure we have a different value first - QVariant current = devices[i]->getPropertyValue(prop); - //qDebug() << " - Current Value:" << current; - if(value.toInt()!=current.toInt()){ - bool ok = devices[i]->setPropertyValue(prop, value); - //if(ok){ foc->setStyleSheet(""); } - //else{ foc->setStyleSheet("background: red"); } - qDebug() << " - Changed property:" << (ok ? "success" : "failure"); - } - break; - } - } -} -*/ -- cgit From 0d3db8715c8668a0d5297ff8dc695ffd6dc3df62 Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Thu, 8 Dec 2016 09:32:29 -0500 Subject: Fix up the auto-hide functionality within the terminal when the term window loses focus. --- src-qt5/desktop-utils/lumina-terminal/TermWindow.cpp | 13 +++++++------ src-qt5/desktop-utils/lumina-terminal/TermWindow.h | 1 + 2 files changed, 8 insertions(+), 6 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/desktop-utils/lumina-terminal/TermWindow.cpp b/src-qt5/desktop-utils/lumina-terminal/TermWindow.cpp index 8ff3ecd1..15cfe047 100644 --- a/src-qt5/desktop-utils/lumina-terminal/TermWindow.cpp +++ b/src-qt5/desktop-utils/lumina-terminal/TermWindow.cpp @@ -36,6 +36,11 @@ TermWindow::TermWindow(QSettings *set) : QWidget(0, Qt::Window | Qt::BypassWindo ANIM = new QPropertyAnimation(this, "geometry", this); ANIM->setDuration(300); //1/3 second animation connect(ANIM, SIGNAL(finished()), this, SLOT(AnimFinished()) ); + activeTimer = new QTimer(this); + activeTimer->setInterval(50); + activeTimer->setSingleShot(true); + connect(activeTimer, SIGNAL(timeout()), this, SLOT(activeStatusChanged()) ); + connect(QApplication::instance(), SIGNAL(applicationStateChanged(Qt::ApplicationState)), activeTimer, SLOT(start()) ); //Create the keyboard shortcuts //hideS = new QShortcut(QKeySequence(Qt::Key_Escape),this); closeS = new QShortcut(QKeySequence(Qt::CTRL | Qt::Key_Q),this); @@ -57,7 +62,6 @@ TermWindow::TermWindow(QSettings *set) : QWidget(0, Qt::Window | Qt::BypassWindo connect(closeS, SIGNAL(activated()), this, SLOT(CloseWindow()) ); connect(prevTabS, SIGNAL(activated()), this, SLOT(Prev_Tab()) ); connect(nextTabS, SIGNAL(activated()), this, SLOT(Next_Tab()) ); - connect(QApplication::instance(), SIGNAL(applicationStateChanged(Qt::ApplicationState)), this, SLOT(activeStatusChanged()) ); //Now set the defaults screennum = 0; //default value setTopOfScreen(true); //default value @@ -283,12 +287,9 @@ void TermWindow::AnimFinished(){ } void TermWindow::activeStatusChanged(){ - //Note: Qt 5.6.1 returns the opposite value for isActiveWindow() (12/7/16) - //qDebug() << "active status changed:" << this->isActiveWindow() << (this == QApplication::activeWindow()); if(animRunning>=0){ return; } //ignore this event - already changing - //if(!this->isActiveWindow() && !this->isVisible()){ ShowWindow(); } - //else if(this->isActiveWindow() this->isVisible()){ HideWindow(); } - //ReShowWindow(); + QWidget *active = QApplication::activeWindow(); + if(active==0 && this->isVisible()){ HideWindow(); } } // =================== diff --git a/src-qt5/desktop-utils/lumina-terminal/TermWindow.h b/src-qt5/desktop-utils/lumina-terminal/TermWindow.h index d21fe502..5f583126 100644 --- a/src-qt5/desktop-utils/lumina-terminal/TermWindow.h +++ b/src-qt5/desktop-utils/lumina-terminal/TermWindow.h @@ -41,6 +41,7 @@ private: bool onTop, CLOSING; QPropertyAnimation *ANIM; int animRunning; //internal flag for what animation is currently running + QTimer *activeTimer; //Calculate the window geometry necessary based on screen/location void CalculateGeom(); -- cgit From 2fa1f4e1a16e74177b22bcb63d40acabfb8daa75 Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Thu, 8 Dec 2016 12:49:09 -0500 Subject: Commit some more fixes for the terminal. Now the arrow keys work properly with the terminal again. --- .../lumina-terminal/TerminalWidget.cpp | 19 ++++--- .../desktop-utils/lumina-terminal/TtyProcess.cpp | 63 ++++++++++++++++++---- src-qt5/desktop-utils/lumina-terminal/TtyProcess.h | 1 + 3 files changed, 67 insertions(+), 16 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/desktop-utils/lumina-terminal/TerminalWidget.cpp b/src-qt5/desktop-utils/lumina-terminal/TerminalWidget.cpp index 6342be59..6893915b 100644 --- a/src-qt5/desktop-utils/lumina-terminal/TerminalWidget.cpp +++ b/src-qt5/desktop-utils/lumina-terminal/TerminalWidget.cpp @@ -93,10 +93,15 @@ void TerminalWidget::applyData(QByteArray data){ //qDebug() << "Data:" << data; for(int i=0; i<data.size(); i++){ if( data.at(i)=='\b' ){ - //Flush current text buffer to widget - //Simple cursor backward 1 (NOT backspace in this context!! - this widget should be in "insert" mode instead) - InsertText(chars); chars.clear(); - this->moveCursor(QTextCursor::Left, QTextCursor::MoveAnchor); + //Backspace + if(!chars.isEmpty()){ chars.chop(1); } + else{ + QTextCursor cur = this->textCursor(); + cur.movePosition(QTextCursor::Left, QTextCursor::KeepAnchor, 1); + cur.removeSelectedText(); + this->setTextCursor(cur); + } + //}else if( data.at(i)=='\t' ){ //chars.append(" "); }else if( data.at(i)=='\x1B' ){ @@ -116,9 +121,9 @@ void TerminalWidget::applyData(QByteArray data){ }else if( data.at(i) != '\r' ){ //Special Check: if inserting text within a line, clear the rest of this line first - if(i==0 && this->textCursor().position() < this->document()->characterCount()-1){ + /*if(i==0 && this->textCursor().position() < this->document()->characterCount()-1){ applyANSI("[K"); - } + }*/ chars.append(data.at(i)); //Plaintext character - just add it here //qDebug() << "Insert Text:" << data.at(i) << CFMT.foreground().color() << CFMT.background().color(); @@ -462,7 +467,7 @@ void TerminalWidget::keyPressEvent(QKeyEvent *ev){ sendKeyPress(Qt::Key_End); //just in case the cursor is not at the end (TTY will split lines and such - ugly) } QByteArray ba; ba.append(ev->text()); //avoid any byte conversions - //qDebug() << "Forward Input:" << ba; + qDebug() << "Forward Input:" << ba; PROC->writeTTY(ba); } diff --git a/src-qt5/desktop-utils/lumina-terminal/TtyProcess.cpp b/src-qt5/desktop-utils/lumina-terminal/TtyProcess.cpp index a1ee0be7..a92b33f8 100644 --- a/src-qt5/desktop-utils/lumina-terminal/TtyProcess.cpp +++ b/src-qt5/desktop-utils/lumina-terminal/TtyProcess.cpp @@ -9,6 +9,7 @@ TTYProcess::TTYProcess(QObject *parent) : QObject(parent){ sn = 0; ttyfd = 0; starting = true; + fixReply = -1; } TTYProcess::~TTYProcess(){ @@ -20,10 +21,25 @@ bool TTYProcess::startTTY(QString prog, QStringList args, QString workdir){ if(workdir=="~"){ workdir = QDir::homePath(); } QDir::setCurrent(workdir); QProcessEnvironment env = QProcessEnvironment::systemEnvironment(); - setenv("TERM","xterm",1);//"vt100",1); //vt100: VT100 emulation support + setenv("TERM","vt220-color",1);//"vt102-color",1); //vt100: VT100 emulation support (QTerminal sets "xterm" here) unsetenv("TERMCAP"); - /*setenv("TERMCAP","mvterm|vv100|mvterm emulator with ANSI colors:\ - :pa#64:Co#8:AF=\E[3%dm:AB=\E[4%dm:op=\E[100m:tc=vt102:",1); //see /etc/termcap as well*/ + //setenv("TERMCAP","vt102-color",1); + /*setenv("TERMCAP",":do=2\E[B:co#80:li#24:cl=50\E[H\E[J:sf=2*\ED:\ + :le=^H:bs:am:cm=5\E[%i%d;%dH:nd=2\E[C:up=2\E[A:\ + :ce=3\E[K:cd=50\E[J:so=2\E[7m:se=2\E[m:us=2\E[4m:ue=2\E[m:\ + :md=2\E[1m:mr=2\E[7m:mb=2\E[5m:me=2\E[m:\ + :is=\E>\E[?1;3;4;5l\E[?7;8h\E[1;24r\E[24;1H:\ + :if=/usr/share/tabset/vt100:nw=2\EE:ho=\E[H:\ + :as=2\E(0:ae=2\E(B:\ + :ac=``aaffggjjkkllmmnnooppqqrrssttuuvvwwxxyyzz{{||:\ + :rs=\E>\E[?1;3;4;5l\E[?7;8h:ks=\E[?1h\E=:ke=\E[?1l\E>:\ + :ku=\EOA:kd=\EOB:kr=\EOC:kl=\EOD:kb=\177:\ + :k0=\EOy:k1=\EOP:k2=\EOQ:k3=\EOR:k4=\EOS:k5=\EOt:\ + :k6=\EOu:k7=\EOv:k8=\EOl:k9=\EOw:k;=\EOx:@8=\EOM:\ + :K1=\EOq:K2=\EOr:K3=\EOs:K4=\EOp:K5=\EOn:pt:sr=2*\EM:xn:\ + :sc=2\E7:rc=2\E8:cs=5\E[%i%d;%dr:UP=2\E[%dA:DO=2\E[%dB:RI=2\E[%dC:\ + :LE=2\E[%dD:ct=2\E[3g:st=2\EH:ta=^I:ms:bl=^G:cr=^M:eo:it#8:\ + :RA=\E[?7l:SA=\E[?7h:po=\E[5i:pf=\E[4i:",1); //see /etc/termcap as well*/ QStringList filter = env.keys().filter("XTERM"); for(int i=0; i<filter.length(); i++){ unsetenv(filter[i].toLocal8Bit().data()); } //if(env.contains("TERM")){ unsetenv("TERM"); } @@ -61,12 +77,7 @@ bool TTYProcess::startTTY(QString prog, QStringList args, QString workdir){ connect(sn, SIGNAL(activated(int)), this, SLOT(checkStatus(int)) ); ttyfd = FD; qDebug() << " - PTY:" << ptsname(FD); - //BUG BYPASS - 12/7/16 - //If the PTY gets input fairly soon after starting, the PTY will re-print the initial line(s) - // So send the "newline" signal now to get things started starting = true; - //writeTTY("\n"); //newline - //writeTTY(QByteArray("\x1b[2J") ); //clear display return true; } } @@ -86,6 +97,9 @@ void TTYProcess::closeTTY(){ void TTYProcess::writeTTY(QByteArray output){ //qDebug() << "Write:" << output; + static QList<QByteArray> knownFixes; + if(knownFixes.isEmpty()){ knownFixes << "\x1b[C" << "\x1b[D"; } + fixReply = knownFixes.indexOf(output); ::write(ttyfd, output.data(), output.size()); } @@ -110,7 +124,9 @@ QByteArray TTYProcess::readTTY(){ fragBA = BA; return readTTY(); }else{ - //qDebug() << "Read Data:" << BA; + qDebug() << "Read Data:" << BA; + //BUG BYPASS - 12/7/16 + //If the PTY gets input fairly soon after starting, the PTY will re-print the initial line(s) if(starting && !BA.contains("\n") ){ //qDebug() << "Starting phase 1:" << BA; writeTTY("\n\b"); //newline + backspace @@ -120,6 +136,26 @@ QByteArray TTYProcess::readTTY(){ BA.remove(0, BA.indexOf("\n")+1); starting = false; } + //Apply known fixes for replies to particular inputs + if(fixReply >= 0){ + qDebug() << "Fix Reply:" <<fixReply << BA; + switch(fixReply){ + case 0: //Right arrow ("\x1b[C") - PTY reply clears the screen after printing only the first char (not everything) + if(BA.length()>0){ + BA.remove(0,1); + BA.prepend("\x1b[C"); //just move the cursor - don't re-print that 1 character + } + break; + case 1: //Right arrow ("\x1b[D") - PTY reply clears the screen after printing only the first char (not everything) + if(BA.startsWith("\b")){ + BA.remove(0,1); + BA.prepend("\x1b[D"); //just move the cursor - don't send the "back" character (\b) + } + break; + } + fixReply = -1; //done with the fix - resume normal operations + //qDebug() << " - Fixed:" << BA; + } return BA; } } @@ -182,6 +218,15 @@ QByteArray TTYProcess::CleanANSI(QByteArray raw, bool &incomplete){ index = raw.indexOf("\x07"); } + //VT102 Identify request + index = raw.indexOf("\x1b[Z"); + while(index>=0){ + raw = raw.remove(index,1); + index = raw.indexOf("\x1b[Z"); + //Also send the proper reply to this identify request right away + writeTTY("\x1b[/Z"); + } + incomplete = false; return raw; } diff --git a/src-qt5/desktop-utils/lumina-terminal/TtyProcess.h b/src-qt5/desktop-utils/lumina-terminal/TtyProcess.h index 1603fe5e..c2b483a9 100644 --- a/src-qt5/desktop-utils/lumina-terminal/TtyProcess.h +++ b/src-qt5/desktop-utils/lumina-terminal/TtyProcess.h @@ -61,6 +61,7 @@ private: QSocketNotifier *sn; QByteArray fragBA; //fragment ByteArray bool starting; + int fixReply; //flag for detecting particular inputs and "fixing" the reply to it as needed //==================================== // C Library function for setting up the PTY -- cgit From 2dbb9e2b705e22d82e8630a3d237e3562b65465a Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Thu, 8 Dec 2016 13:36:49 -0500 Subject: Apply a cursor fix for backspace *within* the middle of a line. --- src-qt5/desktop-utils/lumina-terminal/TtyProcess.cpp | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/desktop-utils/lumina-terminal/TtyProcess.cpp b/src-qt5/desktop-utils/lumina-terminal/TtyProcess.cpp index a92b33f8..6321699e 100644 --- a/src-qt5/desktop-utils/lumina-terminal/TtyProcess.cpp +++ b/src-qt5/desktop-utils/lumina-terminal/TtyProcess.cpp @@ -98,7 +98,7 @@ void TTYProcess::closeTTY(){ void TTYProcess::writeTTY(QByteArray output){ //qDebug() << "Write:" << output; static QList<QByteArray> knownFixes; - if(knownFixes.isEmpty()){ knownFixes << "\x1b[C" << "\x1b[D"; } + if(knownFixes.isEmpty()){ knownFixes << "\x1b[C" << "\x1b[D" << "\b"; } fixReply = knownFixes.indexOf(output); ::write(ttyfd, output.data(), output.size()); } @@ -136,22 +136,29 @@ QByteArray TTYProcess::readTTY(){ BA.remove(0, BA.indexOf("\n")+1); starting = false; } - //Apply known fixes for replies to particular inputs + //Apply known fixes for replies to particular inputs (mostly related to cursor position *within* the current line if(fixReply >= 0){ qDebug() << "Fix Reply:" <<fixReply << BA; switch(fixReply){ - case 0: //Right arrow ("\x1b[C") - PTY reply clears the screen after printing only the first char (not everything) + case 0: //Right arrow ("\x1b[C") - PTY reply re-prints the next character rather than moving the cursor if(BA.length()>0){ BA.remove(0,1); BA.prepend("\x1b[C"); //just move the cursor - don't re-print that 1 character } break; - case 1: //Right arrow ("\x1b[D") - PTY reply clears the screen after printing only the first char (not everything) + case 1: //Left arrow ("\x1b[D") - PTY erases the previous character instead of moving the cursor if(BA.startsWith("\b")){ BA.remove(0,1); BA.prepend("\x1b[D"); //just move the cursor - don't send the "back" character (\b) } break; + case 2: //Backspace ("\b") - PTY works fine if on the end of the line, but when in the middle of a line it will backpace a number of times after clearing (same as left arrow issue) + if(BA.contains("\x1b[K")){ + while(BA.indexOf("\x1b[K") < BA.lastIndexOf("\b") ){ + BA.replace( BA.lastIndexOf("\b"), 1, "\x1b[D"); //just move the cursor left - don't send the "back" character (\b) + } + } + break; } fixReply = -1; //done with the fix - resume normal operations //qDebug() << " - Fixed:" << BA; -- cgit From adcdd6418b1b8838e56c50077168074938a51459 Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Thu, 8 Dec 2016 14:29:28 -0500 Subject: Clean up a bit more of the Terminal interactions. --- .../lumina-terminal/TerminalWidget.cpp | 10 ++----- .../desktop-utils/lumina-terminal/TtyProcess.cpp | 32 ++++++++++++++-------- 2 files changed, 23 insertions(+), 19 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/desktop-utils/lumina-terminal/TerminalWidget.cpp b/src-qt5/desktop-utils/lumina-terminal/TerminalWidget.cpp index 6893915b..398d80c0 100644 --- a/src-qt5/desktop-utils/lumina-terminal/TerminalWidget.cpp +++ b/src-qt5/desktop-utils/lumina-terminal/TerminalWidget.cpp @@ -120,10 +120,6 @@ void TerminalWidget::applyData(QByteArray data){ i+=end; //move the final loop along - already handled these bytes }else if( data.at(i) != '\r' ){ - //Special Check: if inserting text within a line, clear the rest of this line first - /*if(i==0 && this->textCursor().position() < this->document()->characterCount()-1){ - applyANSI("[K"); - }*/ chars.append(data.at(i)); //Plaintext character - just add it here //qDebug() << "Insert Text:" << data.at(i) << CFMT.foreground().color() << CFMT.background().color(); @@ -136,7 +132,7 @@ void TerminalWidget::applyData(QByteArray data){ void TerminalWidget::applyANSI(QByteArray code){ //Note: the first byte is often the "[" character - qDebug() << "Handle ANSI:" << code; + //qDebug() << "Handle ANSI:" << code; if(code.length()==1){ //KEYPAD MODES if(code.at(0)=='='){ altkeypad = true; } @@ -419,7 +415,7 @@ void TerminalWidget::sendKeyPress(int key){ ba.append("\x1b[F"); break; } - qDebug() << "Forward Input:" << ba; + //qDebug() << "Forward Input:" << ba; if(!ba.isEmpty()){ PROC->writeTTY(ba); } } @@ -467,7 +463,7 @@ void TerminalWidget::keyPressEvent(QKeyEvent *ev){ sendKeyPress(Qt::Key_End); //just in case the cursor is not at the end (TTY will split lines and such - ugly) } QByteArray ba; ba.append(ev->text()); //avoid any byte conversions - qDebug() << "Forward Input:" << ba; + //qDebug() << "Forward Input:" << ba; PROC->writeTTY(ba); } diff --git a/src-qt5/desktop-utils/lumina-terminal/TtyProcess.cpp b/src-qt5/desktop-utils/lumina-terminal/TtyProcess.cpp index 6321699e..e3ec64d8 100644 --- a/src-qt5/desktop-utils/lumina-terminal/TtyProcess.cpp +++ b/src-qt5/desktop-utils/lumina-terminal/TtyProcess.cpp @@ -4,6 +4,8 @@ #include <QProcessEnvironment> #include <QTimer> +#define DEBUG 0 + TTYProcess::TTYProcess(QObject *parent) : QObject(parent){ childProc = 0; sn = 0; @@ -21,9 +23,9 @@ bool TTYProcess::startTTY(QString prog, QStringList args, QString workdir){ if(workdir=="~"){ workdir = QDir::homePath(); } QDir::setCurrent(workdir); QProcessEnvironment env = QProcessEnvironment::systemEnvironment(); - setenv("TERM","vt220-color",1);//"vt102-color",1); //vt100: VT100 emulation support (QTerminal sets "xterm" here) + setenv("TERM","xterm",1); //"vt220-color",1);//"vt102-color",1); //vt100: VT100 emulation support (QTerminal sets "xterm" here) unsetenv("TERMCAP"); - //setenv("TERMCAP","vt102-color",1); + setenv("TERMCAP","vt220-color",1); /*setenv("TERMCAP",":do=2\E[B:co#80:li#24:cl=50\E[H\E[J:sf=2*\ED:\ :le=^H:bs:am:cm=5\E[%i%d;%dH:nd=2\E[C:up=2\E[A:\ :ce=3\E[K:cd=50\E[J:so=2\E[7m:se=2\E[m:us=2\E[4m:ue=2\E[m:\ @@ -60,12 +62,14 @@ bool TTYProcess::startTTY(QString prog, QStringList args, QString workdir){ cargs[i] = NULL; } } - qDebug() << "PTY Start:" << prog; + if(DEBUG){ qDebug() << "PTY Start:" << prog; } //Launch the process attached to a new PTY int FD = 0; pid_t tmp = LaunchProcess(FD, cprog, cargs); - qDebug() << " - PID:" << tmp; - qDebug() << " - FD:" << FD; + if(DEBUG){ + qDebug() << " - PID:" << tmp; + qDebug() << " - FD:" << FD; + } if(tmp<0){ return false; } //error else{ childProc = tmp; @@ -76,7 +80,7 @@ bool TTYProcess::startTTY(QString prog, QStringList args, QString workdir){ sn->setEnabled(true); connect(sn, SIGNAL(activated(int)), this, SLOT(checkStatus(int)) ); ttyfd = FD; - qDebug() << " - PTY:" << ptsname(FD); + if(DEBUG){ qDebug() << " - PTY:" << ptsname(FD); } starting = true; return true; } @@ -98,7 +102,7 @@ void TTYProcess::closeTTY(){ void TTYProcess::writeTTY(QByteArray output){ //qDebug() << "Write:" << output; static QList<QByteArray> knownFixes; - if(knownFixes.isEmpty()){ knownFixes << "\x1b[C" << "\x1b[D" << "\b"; } + if(knownFixes.isEmpty()){ knownFixes << "\x1b[C" << "\x1b[D" << "\b" << "\x7F" << "\x08"; } fixReply = knownFixes.indexOf(output); ::write(ttyfd, output.data(), output.size()); } @@ -124,7 +128,7 @@ QByteArray TTYProcess::readTTY(){ fragBA = BA; return readTTY(); }else{ - qDebug() << "Read Data:" << BA; + if(DEBUG){ qDebug() << "Read Data:" << BA; } //BUG BYPASS - 12/7/16 //If the PTY gets input fairly soon after starting, the PTY will re-print the initial line(s) if(starting && !BA.contains("\n") ){ @@ -136,9 +140,11 @@ QByteArray TTYProcess::readTTY(){ BA.remove(0, BA.indexOf("\n")+1); starting = false; } - //Apply known fixes for replies to particular inputs (mostly related to cursor position *within* the current line + //Apply known fixes for replies to particular inputs (mostly related to cursor position *within* the current line) + // This appears to be primarily from the concept that the cursor position is always at the end of the line (old VT limitation?) + // so almost all these fixes are for cursor positioning within the current line if(fixReply >= 0){ - qDebug() << "Fix Reply:" <<fixReply << BA; + if(DEBUG){ qDebug() << "Fix Reply:" <<fixReply << BA; } switch(fixReply){ case 0: //Right arrow ("\x1b[C") - PTY reply re-prints the next character rather than moving the cursor if(BA.length()>0){ @@ -152,7 +158,9 @@ QByteArray TTYProcess::readTTY(){ BA.prepend("\x1b[D"); //just move the cursor - don't send the "back" character (\b) } break; - case 2: //Backspace ("\b") - PTY works fine if on the end of the line, but when in the middle of a line it will backpace a number of times after clearing (same as left arrow issue) + case 2: //Backspace or delete - PTY works fine if on the end of the line, but when in the middle of a line it will backpace a number of times after clearing (same as left arrow issue) + case 3: + case 4: if(BA.contains("\x1b[K")){ while(BA.indexOf("\x1b[K") < BA.lastIndexOf("\b") ){ BA.replace( BA.lastIndexOf("\b"), 1, "\x1b[D"); //just move the cursor left - don't send the "back" character (\b) @@ -161,7 +169,7 @@ QByteArray TTYProcess::readTTY(){ break; } fixReply = -1; //done with the fix - resume normal operations - //qDebug() << " - Fixed:" << BA; + if(DEBUG){ qDebug() << " - Fixed:" << BA; } } return BA; } -- cgit From fba4fc2ffdb0eaa9e39e6b4e07e8941d6738d4e9 Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Thu, 8 Dec 2016 15:51:56 -0500 Subject: Fix up the selection highlighting *during* the mouse movement. --- .../lumina-terminal/TerminalWidget.cpp | 24 +++++++++++++++------- .../desktop-utils/lumina-terminal/TerminalWidget.h | 1 + .../desktop-utils/lumina-terminal/TtyProcess.cpp | 24 ++++++++++++++++++---- 3 files changed, 38 insertions(+), 11 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/desktop-utils/lumina-terminal/TerminalWidget.cpp b/src-qt5/desktop-utils/lumina-terminal/TerminalWidget.cpp index 398d80c0..83474f04 100644 --- a/src-qt5/desktop-utils/lumina-terminal/TerminalWidget.cpp +++ b/src-qt5/desktop-utils/lumina-terminal/TerminalWidget.cpp @@ -19,7 +19,10 @@ TerminalWidget::TerminalWidget(QWidget *parent, QString dir) : QTextEdit(parent){ //Setup the text widget closing = false; - this->setStyleSheet("QTextEdit{ background: black; color: white; }"); + QPalette P = this->palette(); + P.setColor(QPalette::Base, Qt::black); + P.setColor(QPalette::Text, Qt::white); + this->setPalette(P); this->setLineWrapMode(QTextEdit::WidgetWidth); this->setAcceptRichText(false); this->setOverwriteMode(true); @@ -37,14 +40,15 @@ TerminalWidget::TerminalWidget(QWidget *parent, QString dir) : QTextEdit(parent) QFontDatabase FDB; QStringList fonts = FDB.families(QFontDatabase::Latin); for(int i=0; i<fonts.length(); i++){ - if(FDB.isFixedPitch(fonts[i])){ this->setFont(QFont(fonts[i])); qDebug() << "Using Font:" << fonts[i]; break; } + if(FDB.isFixedPitch(fonts[i]) && FDB.isSmoothlyScalable(fonts[i]) ){ this->setFont(QFont(fonts[i])); qDebug() << "Using Font:" << fonts[i]; break; } + //if(FDB.isSmoothlyScalable(fonts[i]) ){ this->setFont(QFont(fonts[i])); qDebug() << "Using Font:" << fonts[i]; break; } } //Create/open the TTY port PROC = new TTYProcess(this); - qDebug() << "Open new TTY"; + //qDebug() << "Open new TTY"; //int fd; bool ok = PROC->startTTY( QProcessEnvironment::systemEnvironment().value("SHELL","/bin/sh"), QStringList(), dir); - qDebug() << " - opened:" << ok; + //qDebug() << " - opened:" << ok; this->setEnabled(PROC->isOpen()); contextMenu = new QMenu(this); copyA = contextMenu->addAction(LXDG::findIcon("edit-copy"), tr("Copy Selection"), this, SLOT(copySelection()) ); @@ -59,10 +63,14 @@ TerminalWidget::~TerminalWidget(){ aboutToClose(); } +void TerminalWidget::setTerminalFont(QFont font){ + this->setFont(font); +} + void TerminalWidget::aboutToClose(){ closing = true; if(PROC->isOpen()){ PROC->closeTTY(); } //TTY PORT - //delete PROC-> + } // ================== @@ -82,7 +90,7 @@ void TerminalWidget::InsertText(QString txt){ sel.cursor = cur; sels << sel; this->setExtraSelections(sels); - //qDebug() << "New Text. Format:" << CFMT.foreground() << CFMT.font(); + //qDebug() << "New Text Format:"<< txt << CFMT.foreground() << CFMT.font() << CFMT.fontWeight(); } void TerminalWidget::applyData(QByteArray data){ @@ -485,9 +493,11 @@ void TerminalWidget::mousePressEvent(QMouseEvent *ev){ } void TerminalWidget::mouseMoveEvent(QMouseEvent *ev){ - if(ev->button()==Qt::LeftButton){ + //qDebug() << "MouseMove Event" << ev->button() << ev->buttons() << Qt::LeftButton; + if(ev->buttons().testFlag(Qt::LeftButton) ){ selCursor.setPosition(this->cursorForPosition(ev->pos()).position(), QTextCursor::KeepAnchor); if(selCursor.hasSelection()){ this->setTextCursor(selCursor); } + //qDebug() << "Mouse Movement:" << selCursor.hasSelection(); }else{ QTextEdit::mouseMoveEvent(ev); } diff --git a/src-qt5/desktop-utils/lumina-terminal/TerminalWidget.h b/src-qt5/desktop-utils/lumina-terminal/TerminalWidget.h index bdec606b..16509cb4 100644 --- a/src-qt5/desktop-utils/lumina-terminal/TerminalWidget.h +++ b/src-qt5/desktop-utils/lumina-terminal/TerminalWidget.h @@ -23,6 +23,7 @@ public: TerminalWidget(QWidget *parent =0, QString dir=""); ~TerminalWidget(); + void setTerminalFont(QFont); void aboutToClose(); private: diff --git a/src-qt5/desktop-utils/lumina-terminal/TtyProcess.cpp b/src-qt5/desktop-utils/lumina-terminal/TtyProcess.cpp index e3ec64d8..88eeb1ec 100644 --- a/src-qt5/desktop-utils/lumina-terminal/TtyProcess.cpp +++ b/src-qt5/desktop-utils/lumina-terminal/TtyProcess.cpp @@ -23,9 +23,10 @@ bool TTYProcess::startTTY(QString prog, QStringList args, QString workdir){ if(workdir=="~"){ workdir = QDir::homePath(); } QDir::setCurrent(workdir); QProcessEnvironment env = QProcessEnvironment::systemEnvironment(); - setenv("TERM","xterm",1); //"vt220-color",1);//"vt102-color",1); //vt100: VT100 emulation support (QTerminal sets "xterm" here) - unsetenv("TERMCAP"); - setenv("TERMCAP","vt220-color",1); + setenv("TERM","vt220-color",1);//"vt102-color",1); //vt100: VT100 emulation support (QTerminal sets "xterm" here) + //unsetenv("TERM"); + //unsetenv("TERMCAP"); + setenv("TERMCAP","xterm",1); /*setenv("TERMCAP",":do=2\E[B:co#80:li#24:cl=50\E[H\E[J:sf=2*\ED:\ :le=^H:bs:am:cm=5\E[%i%d;%dH:nd=2\E[C:up=2\E[A:\ :ce=3\E[K:cd=50\E[J:so=2\E[7m:se=2\E[m:us=2\E[4m:ue=2\E[m:\ @@ -241,7 +242,22 @@ QByteArray TTYProcess::CleanANSI(QByteArray raw, bool &incomplete){ //Also send the proper reply to this identify request right away writeTTY("\x1b[/Z"); } - +//Terminal Status request + index = raw.indexOf("\x1b[5n"); + while(index>=0){ + raw = raw.remove(index,1); + index = raw.indexOf("\x1b[5n"); + //Also send the proper reply to this identify request right away + writeTTY("\x1b[c"); //everything ok + } +//Terminal Identify request + index = raw.indexOf("\x1b[c"); + while(index>=0){ + raw = raw.remove(index,1); + index = raw.indexOf("\x1b[?1;7c"); + //Also send the proper reply to this identify request right away + writeTTY("\x1b[/Z"); + } incomplete = false; return raw; } -- cgit From 192606e238eb5022975de61e7db6f46eb8172325 Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Thu, 8 Dec 2016 16:00:54 -0500 Subject: Add a couple more options for the tip of the day. --- src-qt5/core/lumina-desktop/BootSplash.cpp | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/core/lumina-desktop/BootSplash.cpp b/src-qt5/core/lumina-desktop/BootSplash.cpp index f6c4c5fa..5674eaff 100644 --- a/src-qt5/core/lumina-desktop/BootSplash.cpp +++ b/src-qt5/core/lumina-desktop/BootSplash.cpp @@ -16,8 +16,8 @@ BootSplash::BootSplash() : QWidget(0, Qt::SplashScreen | Qt::X11BypassWindowMana } void BootSplash::generateTipOfTheDay(){ - int index = qrand()%5; //Make sure this number matches the length of the case below (max value +1) - QString tip = "This desktop is generously sponsored by iXsystems\nwww.ixsystems.com"; //fallback message (just in case) + int index = qrand()%7; //Make sure this number matches the length of the case below (max value +1) + QString tip; switch(index){ case 0: tip = tr("This desktop is powered by coffee, coffee, and more coffee."); break; @@ -30,11 +30,11 @@ void BootSplash::generateTipOfTheDay(){ case 4: tip = tr("Lumina can easily reproduce the interface from most other desktop environments."); break; case 5: - tip = tr(""); break; + tip = tr("This desktop is generously sponsored by iXsystems")+"\n\nwww.ixsystems.com"; break; case 6: - tip = tr(""); break; + tip = "\""+tr("I have never been hurt by what I have not said")+"\"\n\n- Calvin Coolidge -"; break; } - ui->label_welcome->setText( "\""+tip+"\"" ); + ui->label_welcome->setText( tip); } void BootSplash::showScreen(QString loading){ //update icon, text, and progress -- cgit From d1dd25e554cea6f03b9aa840d7a95522fe7c841d Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Fri, 9 Dec 2016 07:11:26 -0500 Subject: Fix up a build error on the cluster (not sure why the cluster had a problem with this - works fine locally). --- src-qt5/core-utils/lumina-config/pages/page_mouse.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src-qt5') diff --git a/src-qt5/core-utils/lumina-config/pages/page_mouse.cpp b/src-qt5/core-utils/lumina-config/pages/page_mouse.cpp index 8f5c0c23..a9f3168a 100644 --- a/src-qt5/core-utils/lumina-config/pages/page_mouse.cpp +++ b/src-qt5/core-utils/lumina-config/pages/page_mouse.cpp @@ -151,7 +151,7 @@ void page_mouse::populateDeviceItemValue(QTreeWidget *tree, QTreeWidgetItem *it, tree->setItemWidget(it, 1, box); connect(box, SIGNAL(valueChanged(double)), this, SLOT(valueChanged()) ); - }else if(value.canConvert<QList<QVariant>>()){ + }else if(value.canConvert< QList<QVariant> >()){ //Not Modifiable - just use the label in the item QList<QVariant> list = value.toList(); QStringList txtList; -- cgit From 9a27567cfd00569a5ec11e18643e68097f7ed04d Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Fri, 9 Dec 2016 09:47:45 -0500 Subject: Add a ton more quotes to the login message generator. Now up to 46, which should be good enough for a while. --- src-qt5/core/lumina-desktop/BootSplash.cpp | 80 +++++++++++++++++++++++++++++- 1 file changed, 79 insertions(+), 1 deletion(-) (limited to 'src-qt5') diff --git a/src-qt5/core/lumina-desktop/BootSplash.cpp b/src-qt5/core/lumina-desktop/BootSplash.cpp index 5674eaff..8903d963 100644 --- a/src-qt5/core/lumina-desktop/BootSplash.cpp +++ b/src-qt5/core/lumina-desktop/BootSplash.cpp @@ -16,7 +16,7 @@ BootSplash::BootSplash() : QWidget(0, Qt::SplashScreen | Qt::X11BypassWindowMana } void BootSplash::generateTipOfTheDay(){ - int index = qrand()%7; //Make sure this number matches the length of the case below (max value +1) + int index = qrand()%46; //Make sure this number matches the length of the case below (max value +1) QString tip; switch(index){ case 0: @@ -33,6 +33,84 @@ void BootSplash::generateTipOfTheDay(){ tip = tr("This desktop is generously sponsored by iXsystems")+"\n\nwww.ixsystems.com"; break; case 6: tip = "\""+tr("I have never been hurt by what I have not said")+"\"\n\n- Calvin Coolidge -"; break; + case 7: + tip = "\""+tr("Gotta have more cowbell!")+"\"\n\n- Christopher Walken (SNL) -"; break; + case 8: + tip = "\""+tr("Everything has its beauty but not everyone sees it.")+"\"\n\n- Confucius -"; break; + case 9: + tip = "\""+tr("Before God we are all equally wise - and equally foolish.")+"\"\n\n- Albert Einstein -"; break; + case 10: + tip = "\""+tr("We cannot do everything at once, but we can do something at once.")+"\"\n\n- Calvin Coolidge -"; break; + case 11: + tip = "\""+tr("One with the law is a majority.")+"\"\n\n- Calvin Coolidge -"; break; + case 12: + tip = "\""+tr("Don't expect to build up the weak by pulling down the strong.")+"\"\n\n- Calvin Coolidge -"; break; + case 13: + tip = "\""+tr("You can't know too much, but you can say too much.")+"\"\n\n- Calvin Coolidge -"; break; + case 14: + tip = "\""+tr("Duty is not collective; it is personal.")+"\"\n\n- Calvin Coolidge -"; break; + case 15: + tip = "\""+tr("Any society that would give up a little liberty to gain a little security will deserve neither and lose both.")+"\"\n\n- Benjamin Franklin -"; break; + case 16: + tip = "\""+tr("Never trust a computer you can’t throw out a window.")+"\"\n\n- Steve Wozniak -"; break; + case 17: + tip = "\""+tr("Study the past if you would define the future.")+"\"\n\n- Confucius -"; break; + case 18: + tip = "\""+tr("The way to get started is to quit talking and begin doing.")+"\"\n\n- Walt Disney -"; break; + case 19: + tip = "\""+tr("Ask and it will be given to you; search, and you will find; knock and the door will be opened for you.")+"\"\n\n- Jesus Christ -"; break; + case 20: + tip = "\""+tr("Start where you are. Use what you have. Do what you can.")+"\"\n\n- Arthur Ashe -"; break; + case 21: + tip = "\""+tr("A person who never made a mistake never tried anything new.")+"\"\n\n- Albert Einstein -"; break; + case 22: + tip = "\""+tr("It does not matter how slowly you go as long as you do not stop.")+"\"\n\n- Confucius -"; break; + case 23: + tip = "\""+tr("Do what you can, where you are, with what you have.")+"\"\n\n- Theodore Roosevelt -"; break; + case 24: + tip = "\""+tr("Remember no one can make you feel inferior without your consent.")+"\"\n\n- Eleanor Roosevelt -"; break; + case 25: + tip = "\""+tr("It’s not the years in your life that count. It’s the life in your years.")+"\"\n\n- Abraham Lincoln -"; break; + case 26: + tip = "\""+tr("Either write something worth reading or do something worth writing.")+"\"\n\n- Benjamin Franklin -"; break; + case 27: + tip = "\""+tr("The only way to do great work is to love what you do.")+"\"\n\n- Steve Jobs -"; break; + case 28: + tip = "\""+tr("Political correctness is tyranny with manners.")+"\"\n\n- Charlton Heston -"; break; + case 29: + tip = "\""+tr("Only two things are infinite, the universe and human stupidity, and I'm not sure about the former.")+"\"\n\n- Albert Einstein -"; break; + case 30: + tip = "\""+tr("I find that the harder I work, the more luck I seem to have.")+"\"\n\n- Thomas Jefferson -"; break; + case 31: + tip = "\""+tr("Do, or do not. There is no 'try'.")+"\"\n\n- Yoda -"; break; + case 32: + tip = "\""+tr("A mathematician is a device for turning coffee into theorems.")+"\"\n\n- Paul Erdos -"; break; + case 33: + tip = "\""+tr("Good people do not need laws to tell them to act responsibly, while bad people will find a way around the laws.")+"\"\n\n- Plato -"; break; + case 34: + tip = "\""+tr("Black holes are where God divided by zero.")+"\"\n\n- Steven Wright -"; break; + case 35: + tip = "\""+tr("It's kind of fun to do the impossible.")+"\"\n\n- Walt Disney -"; break; + case 36: + tip = "\""+tr("Knowledge speaks, but wisdom listens.")+"\"\n\n- Jimi Hendrix -"; break; + case 37: + tip = "\""+tr("A witty saying proves nothing.")+"\"\n\n- Voltaire -"; break; + case 38: + tip = "\""+tr("Success usually comes to those who are too busy to be looking for it.")+"\"\n\n- Henry David Thoreau -"; break; + case 39: + tip = "\""+tr("Well-timed silence hath more eloquence than speech.")+"\"\n\n- Martin Fraquhar Tupper -"; break; + case 40: + tip = "\""+tr("I have never let my schooling interfere with my education.")+"\"\n\n- Mark Twain -"; break; + case 41: + tip = "\""+tr("The best way to predict the future is to invent it.")+"\"\n\n- Alan Kay -"; break; + case 42: + tip = "\""+tr("Well done is better than well said.")+"\"\n\n- Benjamin Franklin -"; break; + case 43: + tip = "\""+tr("Sometimes it is not enough that we do our best; we must do what is required.")+"\"\n\n- Sir Winston Churchill -"; break; + case 44: + tip = "\""+tr("The truth is more important than the facts.")+"\"\n\n- Frank Lloyd Wright -"; break; + case 45: + tip = "\""+tr("Better to remain silent and be thought a fool than to speak out and remove all doubt.")+"\"\n\n- Abraham Lincoln -"; break; } ui->label_welcome->setText( tip); } -- cgit From f44da8e86aa502221702c3298288bac1373a7cc7 Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Fri, 9 Dec 2016 10:37:31 -0500 Subject: Fix up the item visibility within the theme engine selector page on first load. --- src-qt5/core-utils/lumina-config/pages/page_theme.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src-qt5') diff --git a/src-qt5/core-utils/lumina-config/pages/page_theme.cpp b/src-qt5/core-utils/lumina-config/pages/page_theme.cpp index 0d946e81..52579ec2 100644 --- a/src-qt5/core-utils/lumina-config/pages/page_theme.cpp +++ b/src-qt5/core-utils/lumina-config/pages/page_theme.cpp @@ -117,7 +117,7 @@ ui->combo_session_themefile->clear(); index = ui->combo_qt5_theme->findData("internal_custom"); } if(index>=0){ ui->combo_qt5_theme->setCurrentIndex(index); } - + checkQt5Theme(); //update item visibility QApplication::processEvents(); loading = false; } -- cgit From d3cec7b2198761622f444dc5a18db2cc2c7fecfa Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Tue, 13 Dec 2016 11:44:35 -0500 Subject: Add new options for the Lumina tips: If a lumina-motd file (executable or text) is found within one of the etc directories (/usr/local/etc/lumina-motd on FreeBSD) or as a valid binary on PATH, then that file will be "preferred" for generating the tips rather than the built-in system. This allows system administrators and/or OS-distributors to customize the login messages "at will" for their particular use-case. NOTE: By making the lumina-motd file a blank text file the tips will be disabled. --- src-qt5/core/lumina-desktop/BootSplash.cpp | 22 ++++++++++++++++++++-- 1 file changed, 20 insertions(+), 2 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/core/lumina-desktop/BootSplash.cpp b/src-qt5/core/lumina-desktop/BootSplash.cpp index 8903d963..1a648973 100644 --- a/src-qt5/core/lumina-desktop/BootSplash.cpp +++ b/src-qt5/core/lumina-desktop/BootSplash.cpp @@ -16,8 +16,24 @@ BootSplash::BootSplash() : QWidget(0, Qt::SplashScreen | Qt::X11BypassWindowMana } void BootSplash::generateTipOfTheDay(){ - int index = qrand()%46; //Make sure this number matches the length of the case below (max value +1) + //Try to find a system-defined message of the day for lumina + QStringList dirs; dirs << LOS::AppPrefix()+"/etc/" << LOS::SysPrefix()+"/etc/" << L_ETCDIR+"/"; + QString sysMOTD = "lumina-motd"; + for(int i=0; i<dirs.length(); i++){ + if(QFile::exists(dirs[i]+sysMOTD)){ sysMOTD.prepend(dirs[i]); break; } + } + QString tip; + if(sysMOTD.contains("/") && LUtils::isValidBinary(sysMOTD)){ + //is binary - run it to generate text + tip = LUtils::getCmdOutput(sysMOTD).join("\n"); + + }else if(QFile::exists(sysMOTD)){ + //text file - read it to generate text + tip = LUtils::readFile(sysMOTD).join("\n"); + + }else{ + int index = qrand()%46; //Make sure this number matches the length of the case below (max value +1) switch(index){ case 0: tip = tr("This desktop is powered by coffee, coffee, and more coffee."); break; @@ -111,7 +127,9 @@ void BootSplash::generateTipOfTheDay(){ tip = "\""+tr("The truth is more important than the facts.")+"\"\n\n- Frank Lloyd Wright -"; break; case 45: tip = "\""+tr("Better to remain silent and be thought a fool than to speak out and remove all doubt.")+"\"\n\n- Abraham Lincoln -"; break; - } + } //end of switch for tips + + } //end of fallback tip generation ui->label_welcome->setText( tip); } -- cgit From aff07f65a041e74e1c897a6da54a4de90a1add15 Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Tue, 13 Dec 2016 13:36:35 -0500 Subject: Fix the window title within the input device page. --- src-qt5/core-utils/lumina-config/pages/page_mouse.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src-qt5') diff --git a/src-qt5/core-utils/lumina-config/pages/page_mouse.cpp b/src-qt5/core-utils/lumina-config/pages/page_mouse.cpp index a9f3168a..bda90ad4 100644 --- a/src-qt5/core-utils/lumina-config/pages/page_mouse.cpp +++ b/src-qt5/core-utils/lumina-config/pages/page_mouse.cpp @@ -50,7 +50,7 @@ void page_mouse::SaveSettings(){ void page_mouse::LoadSettings(int){ emit HasPendingChanges(false); - emit ChangePageTitle( tr("Mouse Settings") ); + emit ChangePageTitle( tr("Input Device Settings") ); } -- cgit From 7df10054631b1037b9747b74fa245c8b03470ec5 Mon Sep 17 00:00:00 2001 From: JT Pennington <jt@obs-sec.com> Date: Wed, 14 Dec 2016 12:18:40 -0500 Subject: comment out trueos mouse page --- src-qt5/core-utils/lumina-config/pages/getPage.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/core-utils/lumina-config/pages/getPage.h b/src-qt5/core-utils/lumina-config/pages/getPage.h index aeeade43..c7b5b076 100644 --- a/src-qt5/core-utils/lumina-config/pages/getPage.h +++ b/src-qt5/core-utils/lumina-config/pages/getPage.h @@ -39,7 +39,7 @@ static QList<PAGEINFO> KnownPages(){ list << PageInfo("session-locale", QObject::tr("Localization"), QObject::tr("Locale Settings"), "preferences-desktop-locale",QObject::tr("Change the default locale settings for this user"), "user", QStringList(), QStringList() << "user"<<"locale"<<"language"<<"translations"); list << PageInfo("session-options", QObject::tr("General Options"), QObject::tr("User Settings"), "configure",QObject::tr("Change basic user settings such as time/date formats"), "user", QStringList(), QStringList() << "user"<<"settings"<<"time"<<"date"<<"icon"<<"reset"<<"numlock"<<"clock"); list << PageInfo("input-devices", QObject::tr("Input Device Settings"), QObject::tr("Input Device Settings"), "preferences-desktop-peripherals",QObject::tr("Adjust keyboard and mouse devices"), "user", QStringList(), QStringList() << "user"<<"speed"<<"accel"<<"mouse" << "keyboard"); - list << PageInfo("mouse-settings", QObject::tr("Mouse Settings"), QObject::tr("Mouse Settings"), "preferences-desktop-mouse",QObject::tr("Adjust mouse devices"), "user", QStringList(), QStringList() << "user"<<"speed"<<"accel"<<"mouse"); + // list << PageInfo("mouse-settings", QObject::tr("TrueOS Mouse Settings"), QObject::tr("TrueOS Mouse Settings"), "preferences-desktop-mouse",QObject::tr("Adjust mouse devices"), "user", QStringList(), QStringList() << "user"<<"speed"<<"accel"<<"mouse"); //Now sort the items according to the translated name QStringList names; for(int i=0; i<list.length(); i++){ names << list[i].name; } @@ -68,7 +68,7 @@ static QList<PAGEINFO> KnownPages(){ #include "page_session_options.h" #include "page_compton.h" #include "page_mouse.h" -#include "page_mouse_trueos.h" +// #include "page_mouse_trueos.h" static PageWidget* GetNewPage(QString id, QWidget *parent){ //Find the page that matches this "id" @@ -86,7 +86,7 @@ static PageWidget* GetNewPage(QString id, QWidget *parent){ else if(id=="session-options"){ page = new page_session_options(parent); } else if(id=="compton"){ page = new page_compton(parent); } else if(id=="input-devices"){ page = new page_mouse(parent); } - else if(id=="mouse-settings"){ page = new page_mouse_trueos(parent); } + // else if(id=="mouse-settings"){ page = new page_mouse_trueos(parent); } //Return the main control_panel page as the fallback/default if(page==0){ id.clear(); page = new page_main(parent); } page->setWhatsThis(id); -- cgit From 5dbb320e7f6fa560c02cca1264bee3d2a20e78d4 Mon Sep 17 00:00:00 2001 From: JT Pennington <jt@obs-sec.com> Date: Wed, 14 Dec 2016 12:21:11 -0500 Subject: comment out page_mouse_trueos --- src-qt5/core-utils/lumina-config/pages/pages.pri | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/core-utils/lumina-config/pages/pages.pri b/src-qt5/core-utils/lumina-config/pages/pages.pri index 4ea13f01..56a3fcd5 100644 --- a/src-qt5/core-utils/lumina-config/pages/pages.pri +++ b/src-qt5/core-utils/lumina-config/pages/pages.pri @@ -14,8 +14,8 @@ HEADERS += $${PWD}/getPage.h \ $${PWD}/page_session_locale.h \ $${PWD}/page_session_options.h \ $${PWD}/page_compton.h \ - $${PWD}/page_mouse.h \ - $$PWD/page_mouse_trueos.h + $${PWD}/page_mouse.h +// $$PWD/page_mouse_trueos.h SOURCES += $${PWD}/page_main.cpp \ @@ -31,8 +31,8 @@ SOURCES += $${PWD}/page_main.cpp \ $${PWD}/page_session_locale.cpp \ $${PWD}/page_session_options.cpp \ $${PWD}/page_compton.cpp \ - $${PWD}/page_mouse.cpp \ - $$PWD/page_mouse_trueos.cpp + $${PWD}/page_mouse.cpp +// $$PWD/page_mouse_trueos.cpp FORMS += $${PWD}/page_main.ui \ @@ -48,5 +48,5 @@ FORMS += $${PWD}/page_main.ui \ $${PWD}/page_session_locale.ui \ $${PWD}/page_session_options.ui \ $${PWD}/page_compton.ui \ - $${PWD}/page_mouse.ui \ - $$PWD/page_mouse_trueos.ui + $${PWD}/page_mouse.ui +// $$PWD/page_mouse_trueos.ui -- cgit From 07fb0c089ce991a7849b3eecc6ae65c57741141d Mon Sep 17 00:00:00 2001 From: JT Pennington <jt@obs-sec.com> Date: Wed, 14 Dec 2016 12:23:14 -0500 Subject: fixing white space to keep Ken happy --- src-qt5/core-utils/lumina-config/pages/page_mouse.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/core-utils/lumina-config/pages/page_mouse.h b/src-qt5/core-utils/lumina-config/pages/page_mouse.h index 47b90303..6dc6bdc0 100644 --- a/src-qt5/core-utils/lumina-config/pages/page_mouse.h +++ b/src-qt5/core-utils/lumina-config/pages/page_mouse.h @@ -13,14 +13,14 @@ #include <QTreeWidgetItem> namespace Ui{ - class page_mouse; + class page_mouse; }; class page_mouse : public PageWidget{ Q_OBJECT public: - page_mouse(QWidget *parent); - ~page_mouse(); + page_mouse(QWidget *parent); + ~page_mouse(); public slots: void SaveSettings(); @@ -28,7 +28,7 @@ public slots: void updateIcons(); private: - Ui::page_mouse *ui; + Ui::page_mouse *ui; QList<LInputDevice*> devices; void generateUI(); -- cgit From 061412f249486f1d145ccdcbcd6b2159773b7551 Mon Sep 17 00:00:00 2001 From: JT Pennington <jt@obs-sec.com> Date: Wed, 14 Dec 2016 12:24:18 -0500 Subject: Update page_mouse.h --- src-qt5/core-utils/lumina-config/pages/page_mouse.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/core-utils/lumina-config/pages/page_mouse.h b/src-qt5/core-utils/lumina-config/pages/page_mouse.h index 6dc6bdc0..5409a9c2 100644 --- a/src-qt5/core-utils/lumina-config/pages/page_mouse.h +++ b/src-qt5/core-utils/lumina-config/pages/page_mouse.h @@ -13,14 +13,14 @@ #include <QTreeWidgetItem> namespace Ui{ - class page_mouse; + class page_mouse; }; class page_mouse : public PageWidget{ Q_OBJECT public: - page_mouse(QWidget *parent); - ~page_mouse(); + page_mouse(QWidget *parent); + ~page_mouse(); public slots: void SaveSettings(); @@ -28,7 +28,7 @@ public slots: void updateIcons(); private: - Ui::page_mouse *ui; + Ui::page_mouse *ui; QList<LInputDevice*> devices; void generateUI(); -- cgit From 15cc547b0d5da0c8dc7ae40d9d4a149247887fe4 Mon Sep 17 00:00:00 2001 From: JT Pennington <jt@obs-sec.com> Date: Wed, 14 Dec 2016 12:44:41 -0500 Subject: fix missing brackets --- src-qt5/core-utils/lumina-config/pages/pages.pri | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/core-utils/lumina-config/pages/pages.pri b/src-qt5/core-utils/lumina-config/pages/pages.pri index 56a3fcd5..02319976 100644 --- a/src-qt5/core-utils/lumina-config/pages/pages.pri +++ b/src-qt5/core-utils/lumina-config/pages/pages.pri @@ -15,7 +15,7 @@ HEADERS += $${PWD}/getPage.h \ $${PWD}/page_session_options.h \ $${PWD}/page_compton.h \ $${PWD}/page_mouse.h -// $$PWD/page_mouse_trueos.h +// $${PWD}/page_mouse_trueos.h SOURCES += $${PWD}/page_main.cpp \ @@ -32,7 +32,7 @@ SOURCES += $${PWD}/page_main.cpp \ $${PWD}/page_session_options.cpp \ $${PWD}/page_compton.cpp \ $${PWD}/page_mouse.cpp -// $$PWD/page_mouse_trueos.cpp +// $${PWD}/page_mouse_trueos.cpp FORMS += $${PWD}/page_main.ui \ @@ -49,4 +49,4 @@ FORMS += $${PWD}/page_main.ui \ $${PWD}/page_session_options.ui \ $${PWD}/page_compton.ui \ $${PWD}/page_mouse.ui -// $$PWD/page_mouse_trueos.ui +// $${PWD}/page_mouse_trueos.ui -- cgit From 3ef3d00b097a8ea9a4131e70e3c1dbd9ee1c38a5 Mon Sep 17 00:00:00 2001 From: Ken Moore <ken@ixsystems.com> Date: Wed, 14 Dec 2016 15:07:38 -0500 Subject: Add some more PTY work on the terminal. --- .../lumina-terminal/TerminalWidget.cpp | 3 ++ .../desktop-utils/lumina-terminal/TtyProcess.cpp | 38 ++++++++++++++++++---- 2 files changed, 34 insertions(+), 7 deletions(-) (limited to 'src-qt5') diff --git a/src-qt5/desktop-utils/lumina-terminal/TerminalWidget.cpp b/src-qt5/desktop-utils/lumina-terminal/TerminalWidget.cpp index 83474f04..e009b1c0 100644 --- a/src-qt5/desktop-utils/lumina-terminal/TerminalWidget.cpp +++ b/src-qt5/desktop-utils/lumina-terminal/TerminalWidget.cpp @@ -148,6 +148,9 @@ void TerminalWidget::applyANSI(QByteArray code){ else{ qDebug() << "Unhandled ANSI Code:" << code; } + /*}else if(code.startsWith("[@") && code.length()==3){ + //Strange VT220? code - just print the character after the @ + InsertText( QString(code[2]) );*/ }else if(code.startsWith("[")){ // VT100 ESCAPE CODES //CURSOR MOVEMENT diff --git a/src-qt5/desktop-utils/lumina-terminal/TtyProcess.cpp b/src-qt5/desktop-utils/lumina-terminal/TtyProcess.cpp index 88eeb1ec..6fddee39 100644 --- a/src-qt5/desktop-utils/lumina-terminal/TtyProcess.cpp +++ b/src-qt5/desktop-utils/lumina-terminal/TtyProcess.cpp @@ -25,8 +25,8 @@ bool TTYProcess::startTTY(QString prog, QStringList args, QString workdir){ QProcessEnvironment env = QProcessEnvironment::systemEnvironment(); setenv("TERM","vt220-color",1);//"vt102-color",1); //vt100: VT100 emulation support (QTerminal sets "xterm" here) //unsetenv("TERM"); - //unsetenv("TERMCAP"); - setenv("TERMCAP","xterm",1); + unsetenv("TERMCAP"); + //setenv("TERMCAP","xterm",1); /*setenv("TERMCAP",":do=2\E[B:co#80:li#24:cl=50\E[H\E[J:sf=2*\ED:\ :le=^H:bs:am:cm=5\E[%i%d;%dH:nd=2\E[C:up=2\E[A:\ :ce=3\E[K:cd=50\E[J:so=2\E[7m:se=2\E[m:us=2\E[4m:ue=2\E[m:\ @@ -42,7 +42,7 @@ bool TTYProcess::startTTY(QString prog, QStringList args, QString workdir){ :K1=\EOq:K2=\EOr:K3=\EOs:K4=\EOp:K5=\EOn:pt:sr=2*\EM:xn:\ :sc=2\E7:rc=2\E8:cs=5\E[%i%d;%dr:UP=2\E[%dA:DO=2\E[%dB:RI=2\E[%dC:\ :LE=2\E[%dD:ct=2\E[3g:st=2\EH:ta=^I:ms:bl=^G:cr=^M:eo:it#8:\ - :RA=\E[?7l:SA=\E[?7h:po=\E[5i:pf=\E[4i:",1); //see /etc/termcap as well*/ + :RA=\E[?7l:SA=\E[?7h:po=\E[5i:pf=\E[4i:",1); //see /etc/termcap as well */ QStringList filter = env.keys().filter("XTERM"); for(int i=0; i<filter.length(); i++){ unsetenv(filter[i].toLocal8Bit().data()); } //if(env.contains("TERM")){ unsetenv("TERM"); } @@ -233,6 +233,12 @@ QByteArray TTYProcess::CleanANSI(QByteArray raw, bool &incomplete){ raw = raw.remove(index,1); index = raw.indexOf("\x07"); } + //VT220(?) print character code + index=raw.indexOf("\x1b[@"); + while(index>=0){ + raw = raw.remove(index,3); + index = raw.indexOf("\x1b[@"); + } //VT102 Identify request index = raw.indexOf("\x1b[Z"); @@ -242,7 +248,7 @@ QByteArray TTYProcess::CleanANSI(QByteArray raw, bool &incomplete){ //Also send the proper reply to this identify request right away writeTTY("\x1b[/Z"); } -//Terminal Status request + //Terminal Status request index = raw.indexOf("\x1b[5n"); while(index>=0){ raw = raw.remove(index,1); @@ -250,14 +256,15 @@ QByteArray TTYProcess::CleanANSI(QByteArray raw, bool &incomplete){ //Also send the proper reply to this identify request right away writeTTY("\x1b[c"); //everything ok } -//Terminal Identify request + //Terminal Identify request index = raw.indexOf("\x1b[c"); while(index>=0){ raw = raw.remove(index,1); - index = raw.indexOf("\x1b[?1;7c"); + index = raw.indexOf("\x1b[c"); //Also send the proper reply to this identify request right away writeTTY("\x1b[/Z"); } + incomplete = false; return raw; } @@ -283,7 +290,24 @@ pid_t TTYProcess::LaunchProcess(int& fd, char *prog, char **child_args){ //Adjust the slave side mode to RAW struct termios TSET; rc = tcgetattr(fds, &TSET); //read the current settings - cfmakesane(&TSET); //set the RAW mode on the settings ( cfmakeraw(&TSET); ) + cfmakesane(&TSET); //set the SANE mode on the settings ( cfmakeraw(&TSET); ) + //Set Input Modes + TSET.c_iflag |= IGNPAR; //ignore parity errors + TSET.c_iflag &= ~(IGNBRK | PARMRK | ISTRIP | ICRNL | IXON | IXANY | IXOFF); //ignore special characters + //Set Local Modes + TSET.c_lflag &= (ECHO | ECHONL | ECHOKE); //Echo inputs (normal, newline, and KILL character line break) + TSET.c_lflag &= ~ICANON ; //non-canonical mode (individual inputs - not a line-at-a-time) + //Set Control Modes + TSET.c_cflag |= CLOCAL; //Local Terminal Connection (non-modem) + //TSET.c_lflag &= ~IEXTEN; + //TSET.c_cflag &= ~(CSIZE | PARENB); + //TSET.c_cflag |= CS8; + //tt.c_oflag &= ~OPOST; // disable special output processing + //Set Output Modes + TSET.c_oflag |= OPOST; + //TSET.c_oflag |= OXTABS; + TSET.c_cc[VTIME] = 0; // timeout + //Now apply the settings tcsetattr(fds, TCSANOW, &TSET); //apply the changed settings //Change the controlling terminal in child thread to the slave PTY -- cgit