Skip to content

Commit

Permalink
Merge tag '0.14.1' into wsl
Browse files Browse the repository at this point in the history
Release qterminal 0.14.1
  • Loading branch information
kghost committed Apr 3, 2019
2 parents afde43d + 6e243af commit 8a74f14
Show file tree
Hide file tree
Showing 60 changed files with 25,487 additions and 343 deletions.
17 changes: 9 additions & 8 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -1,18 +1,19 @@
# remove files from deployment using `git archive`

# git files
.gitattributes export-ignore
.github export-ignore
.gitignore export-ignore
.gitattributes export-ignore
.github export-ignore
.gitignore export-ignore


# several files and directories we never want to export
# a little bit belt and braces as the most of these files
# should never ever be in the repository

.*~ export-ignore
.kdev4 export-ignore
.*~ export-ignore
.kdev4 export-ignore
.translation-update export-ignore

/build export-ignore
/temp export-ignore
/tmp export-ignore
/build export-ignore
/temp export-ignore
/tmp export-ignore
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
build
*.pro.user*
src/translations/qterminal
1 change: 1 addition & 0 deletions .translation-update
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
translations='./src'
40 changes: 35 additions & 5 deletions CHANGELOG
Original file line number Diff line number Diff line change
@@ -1,3 +1,33 @@
qterminal-0.14.1 / 2019-02-25
=============================

* Bumped version to 0.14.1
* Only translations was changed.

qterminal-0.14.0 / 2019-01-25
=============================

* Bumped version to 0.14.0
The big bump was needed to prevent conflicts with translations that
were former built out of lxqt-l10n and have version 0.13.0
* New implemented:
- Added terminal margins
- Added history-based tab switching
* Implementation fixes:
- main: Fixed translation loading
- propertiesdialog: Smaller settings dialog
- propertiesdialog: Prevent TAB from changing focus in shortcut editor
- Suppress compilation warnings
- Don't use automatic string conversions
- Remember the maximization state of the window
- Refactored Limit/limit -> Fixed/fixed tabwitdh
- Refactor STR_VERSION -> QTERMINAL_VERSION
* Improved cmake scripting
- Set cmake_minimum_required to 3.1.0
- Removed locale compile definitons
* Moved translations from lxqt-l10n back to qterminal
- Removed obsolete translation fuctionality
- Added translation promo in README.md

qterminal-0.9.0 / 2018-05-21
============================
Expand Down Expand Up @@ -44,7 +74,7 @@ qterminal-0.9.0 / 2018-05-21
* Add RTL support button
* Update Catalan translation

0.8.0 / 2017-10-21
qterminal-0.8.0 / 2017-10-21
==================

* Release 0.8.0: Update changelog
Expand Down Expand Up @@ -90,7 +120,7 @@ qterminal-0.9.0 / 2018-05-21
* Fix a copy/paste error from 4afcc4d0d0922f526f89aadf16ec0517f6b5267e
* Update dependencies and cleanup trailing spaces

0.7.1 / 2016-12-21
qterminal-0.7.1 / 2016-12-21
==================

* Release 0.7.1: Update changelog
Expand All @@ -108,7 +138,7 @@ qterminal-0.9.0 / 2018-05-21
* Show exit confirmation dialog when closing the last window tab (#242)
* remove "building with cpack" from CMakeLists.txt - not used anymore Added very basic .gitattributes

0.7.0 / 2016-09-24
qterminal-0.7.0 / 2016-09-24
==================

* Release 0.7.0: Add changelog
Expand Down Expand Up @@ -209,7 +239,7 @@ qterminal-0.9.0 / 2018-05-21
* Rework settings window
* Fixed translation (added tr() for some combo boxes in properties dialog).

0.6.0 / 2014-10-21
qterminal-0.6.0 / 2014-10-21
==================

* Release 0.6.0
Expand Down Expand Up @@ -238,7 +268,7 @@ qterminal-0.9.0 / 2018-05-21
* Fixed install qterminal incon
* Simple profile support

0.5.0 / 2014-05-27
qterminal-0.5.0 / 2014-05-27
==================

* basic Qt5 port
Expand Down
68 changes: 36 additions & 32 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,30 +1,33 @@
cmake_minimum_required(VERSION 3.0.2 FATAL_ERROR)

cmake_minimum_required(VERSION 3.1.0 FATAL_ERROR)
# CMP0000: Call the cmake_minimum_required() command at the beginning of the top-level
# CMakeLists.txt file even before calling the project() command.
# The cmake_minimum_required(VERSION) command implicitly invokes the cmake_policy(VERSION)
# command to specify that the current project code is written for the given range of CMake
# versions.
project(qterminal)

include(GNUInstallDirs)
include(CheckFunctionExists)

# qterminal version
set(STR_VERSION "0.9.0")
set(LXQTBT_MINIMUM_VERSION "0.5.0")
set(QTERMWIDGET_MINIMUM_VERSION "0.9.0")
set(QTERMINAL_VERSION "0.14.1")

option(UPDATE_TRANSLATIONS "Update source translation translations/*.ts files" OFF)

if(NOT CMAKE_BUILD_TYPE)
set(CMAKE_BUILD_TYPE Release)
endif()

# we need qpa/qplatformnativeinterface.h for global shortcut
find_package(Qt5Gui REQUIRED)
find_package(Qt5Widgets REQUIRED)
find_package(Qt5Network REQUIRED)
find_package(Qt5LinguistTools REQUIRED)
if(APPLE)
elseif(UNIX)
find_package(Qt5X11Extras REQUIRED)
find_package(Qt5DBus)

# Minimum Versions
set(LXQTBT_MINIMUM_VERSION "0.6.0")
set(QTERMWIDGET_MINIMUM_VERSION "0.14.1")
set(QT_MINIMUM_VERSION "5.7.1")

find_package(Qt5Gui ${QT_MINIMUM_VERSION} REQUIRED)
find_package(Qt5LinguistTools ${QT_MINIMUM_VERSION} REQUIRED)
find_package(Qt5Widgets ${QT_MINIMUM_VERSION} REQUIRED)
find_package(Qt5Network ${QT_MINIMUM_VERSION} REQUIRED)
if(UNIX)
find_package(Qt5DBus ${QT_MINIMUM_VERSION} REQUIRED)
find_package(Qt5X11Extras ${QT_MINIMUM_VERSION} REQUIRED)
endif()
find_package(QTermWidget5 ${QTERMWIDGET_MINIMUM_VERSION} REQUIRED)
find_package(lxqt-build-tools ${LXQTBT_MINIMUM_VERSION} REQUIRED)
Expand All @@ -49,8 +52,7 @@ elseif(UNIX)
endif()

add_definitions(
-DSTR_VERSION=\"${STR_VERSION}\"
-DQT_NO_FOREACH
-DQTERMINAL_VERSION=\"${QTERMINAL_VERSION}\"
)

set(EXE_NAME qterminal)
Expand All @@ -68,6 +70,7 @@ set(QTERM_SRC
src/bookmarkswidget.cpp
src/fontdialog.cpp
src/dbusaddressable.cpp
src/tab-switcher.cpp
)

set(QTERM_MOC_SRC
Expand All @@ -80,9 +83,9 @@ set(QTERM_MOC_SRC
src/propertiesdialog.h
src/bookmarkswidget.h
src/fontdialog.h
src/tab-switcher.h
)


if (Qt5DBus_FOUND)
add_definitions(-DHAVE_QDBUS)
QT5_ADD_DBUS_ADAPTOR(QTERM_SRC src/org.lxqt.QTerminal.Window.xml mainwindow.h MainWindow)
Expand Down Expand Up @@ -134,14 +137,6 @@ lxqt_translate_ts(QTERM_QM
${QTERM_UI_SRC}
${QTERM_MOC_SRC}
TRANSLATION_DIR "src/translations"
PULL_TRANSLATIONS
${PULL_TRANSLATIONS}
CLEAN_TRANSLATIONS
${CLEAN_TRANSLATIONS}
TRANSLATIONS_REPO
${TRANSLATIONS_REPO}
TRANSLATIONS_REFSPEC
${TRANSLATIONS_REFSPEC}
)

include_directories(
Expand All @@ -164,12 +159,12 @@ if(APPLEBUNDLE)

# create Info.plist file
set(MACOSX_BUNDLE_ICON_FILE qterminal.icns)
set(MACOSX_BUNDLE_INFO_STRING "QTerminal ${STR_VERSION}")
set(MACOSX_BUNDLE_INFO_STRING "QTerminal ${QTERMINAL_VERSION}")
set(MACOSX_BUNDLE_GUI_IDENTIFIER "com.qterminal")
set(MACOSX_BUNDLE_LONG_VERSION_STRING "${STR_VERSION}")
set(MACOSX_BUNDLE_LONG_VERSION_STRING "${QTERMINAL_VERSION}")
set(MACOSX_BUNDLE_BUNDLE_NAME "${EXE_NAME}")
set(MACOSX_BUNDLE_SHORT_VERSION_STRING "${STR_VERSION}")
set(MACOSX_BUNDLE_BUNDLE_VERSION "${STR_VERSION}")
set(MACOSX_BUNDLE_SHORT_VERSION_STRING "${QTERMINAL_VERSION}")
set(MACOSX_BUNDLE_BUNDLE_VERSION "${QTERMINAL_VERSION}")
set(MACOSX_BUNDLE_COPYRIGHT "(c) Petr Vanek <[email protected]>")

set_source_files_properties("${CMAKE_CURRENT_SOURCE_DIR}/macosx/qterminal.icns"
Expand Down Expand Up @@ -214,6 +209,15 @@ if(HAVE_F_SETENV)
)
endif()

target_compile_definitions(${EXE_NAME}
PRIVATE
"QT_USE_QSTRINGBUILDER"
"QT_NO_CAST_FROM_ASCII"
"QT_NO_CAST_TO_ASCII"
"QT_NO_URL_CAST_FROM_STRING"
"QT_NO_CAST_FROM_BYTEARRAY"
)

target_link_libraries(${EXE_NAME}
Qt5::Gui
qtermwidget5
Expand Down
4 changes: 4 additions & 0 deletions qterminal.desktop
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,14 @@
Name=QTerminal
Type=Application
GenericName=Terminal emulator
GenericName[ca]=Emulador de terminal
GenericName[cs]=Emulátor terminálu
GenericName[es]=Emulador de terminal


Comment=Terminal emulator
Comment[ca]=Emulador de terminal
Comment[cs]=Emulátor terminálu
Comment[de]=Befehlszeile verwenden
Comment[el]=Προσομοιωτής τερματικού
Comment[es]=Emulador de terminal
Expand Down
2 changes: 1 addition & 1 deletion qterminal.pro
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ CONFIG += link_pkgconfig \

PKGCONFIG += qtermwidget5

DEFINES += STR_VERSION=\\\"0.9.0\\\"
DEFINES += QTERMINAL_VERSION=\\\"0.9.0\\\"

SOURCES += $$files(src/*.cpp)
HEADERS += $$files(src/*.h)
Expand Down
2 changes: 2 additions & 0 deletions qterminal_drop.desktop
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ Icon=utilities-terminal

Name=QTerminal drop down
Name[ca]=QTerminal desplegable
Name[cs]=Rozbalovací QTerminál
Name[de]=QTerminal herabhängend
Name[el]=QTerminal αναπτυσσόμενο
Name[es]=QTerminal desplegable
Expand Down Expand Up @@ -55,6 +56,7 @@ GenericName[zh_TW]=下拉式終端機

Comment=A drop-down terminal emulator.
Comment[ca]=Un emulador de terminal desplegable.
Comment[cs]=Vysouvací emulátor terminálu.
Comment[de]=Ein Ausklapp-Terminalemulator.
Comment[el]=Ένας αναπτυσσόμενος προσομοιωτής τερματικού.
Comment[es]=Un emulador de terminal desplegable.
Expand Down
30 changes: 15 additions & 15 deletions src/bookmarkswidget.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ class BookmarkRootItem : public AbstractBookmarkItem
: AbstractBookmarkItem()
{
m_type = AbstractBookmarkItem::Root;
m_value = m_display = "root";
m_value = m_display = QStringLiteral("root");
}
};

Expand Down Expand Up @@ -132,8 +132,8 @@ class BookmarkLocalGroupItem : public BookmarkGroupItem
}
name = QStandardPaths::displayName(i);

path.replace(" ", "\\ ");
cmd = "cd " + path;
path.replace(QLatin1String(" "), QLatin1String("\\ "));
cmd = QLatin1String("cd ") + path;

addChild(new BookmarkCommandItem(name, cmd, this));
}
Expand All @@ -148,8 +148,8 @@ class BookmarkLocalGroupItem : public BookmarkGroupItem
{
continue;
}
path.replace(" ", "\\ ");
cmd = "cd " + path;
path.replace(QLatin1String(" "), QLatin1String("\\ "));
cmd = QLatin1String("cd ") + path;
addChild(new BookmarkCommandItem(i, cmd, this));
}
}
Expand Down Expand Up @@ -188,20 +188,20 @@ class BookmarkFileGroupItem : public BookmarkGroupItem
{
AbstractBookmarkItem *parent = m_map.contains(xmlPos()) ? m_map[xmlPos()] : this;
QString tag = xml.name().toString();
if (tag == "group")
if (tag == QLatin1String("group"))
{
QString name = xml.attributes().value("name").toString();
QString name = xml.attributes().value(QLatin1String("name")).toString();
m_pos.append(name);

BookmarkGroupItem *i = new BookmarkGroupItem(name, parent);
parent->addChild(i);

m_map[xmlPos()] = i;
}
else if (tag == "command")
else if (tag == QLatin1String("command"))
{
QString name = xml.attributes().value("name").toString();
QString cmd = xml.attributes().value("value").toString();
QString name = xml.attributes().value(QLatin1String("name")).toString();
QString cmd = xml.attributes().value(QLatin1String("value")).toString();

BookmarkCommandItem *i = new BookmarkCommandItem(name, cmd, parent);
parent->addChild(i);
Expand All @@ -211,7 +211,7 @@ class BookmarkFileGroupItem : public BookmarkGroupItem
case QXmlStreamReader::EndElement:
{
QString tag = xml.name().toString();
if (tag == "group")
if (tag == QLatin1String("group"))
{
m_pos.removeLast();
}
Expand All @@ -233,7 +233,7 @@ class BookmarkFileGroupItem : public BookmarkGroupItem

QString xmlPos()
{
return m_pos.join(".");
return m_pos.join(QLatin1Char('.'));
}
};

Expand Down Expand Up @@ -302,8 +302,8 @@ AbstractBookmarkItem *BookmarksModel::getItem(const QModelIndex &index) const
return m_root;
}

QVariant BookmarksModel::headerData(int section, Qt::Orientation orientation,
int role) const
QVariant BookmarksModel::headerData(int /*section*/, Qt::Orientation /*orientation*/,
int /*role*/) const
{
return QVariant();
}
Expand Down Expand Up @@ -393,5 +393,5 @@ void BookmarksWidget::handleCommand(const QModelIndex& index)
if (!item || item->type() != AbstractBookmarkItem::Command)
return;

emit callCommand(item->value() + "\n"); // TODO/FIXME: decide how to handle EOL
emit callCommand(item->value() + QLatin1Char('\n')); // TODO/FIXME: decide how to handle EOL
}
8 changes: 6 additions & 2 deletions src/config.h
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,8 @@
#define QUIT "Quit"
#define PREFERENCES "Preferences..."

#define TAB_PREV_HISTORY "Previous Tab in History"
#define TAB_NEXT_HISTORY "Next Tab in History"
#define TAB_NEXT "Next Tab"
#define TAB_PREV "Previous Tab"

Expand Down Expand Up @@ -72,8 +74,10 @@
// ACTIONS
#define CLEAR_TERMINAL_SHORTCUT "Ctrl+Shift+X"

#define TAB_PREV_SHORTCUT "Ctrl+PgUp|Ctrl+Shift+Tab"
#define TAB_NEXT_SHORTCUT "Ctrl+PgDown|Ctrl+Tab"
#define TAB_PREV_HISTORY_SHORTCUT "Ctrl+Tab"
#define TAB_NEXT_HISTORY_SHORTCUT "Ctrl+Shift+Tab"
#define TAB_PREV_SHORTCUT "Ctrl+PgUp"
#define TAB_NEXT_SHORTCUT "Ctrl+PgDown"
#define SUB_BOTTOM_SHORTCUT "Alt+Down"
#define SUB_TOP_SHORTCUT "Alt+Up"
#define SUB_LEFT_SHORTCUT "Alt+Left"
Expand Down
Loading

0 comments on commit 8a74f14

Please sign in to comment.