summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--.ci/windows/build.bat2
-rw-r--r--.gitlab-ci.yml7
-rw-r--r--CHANGELOG.md197
-rw-r--r--CMakeLists.txt12
-rw-r--r--README.md55
-rw-r--r--appveyor.yml134
-rw-r--r--im.nheko.Nheko.yaml73
-rw-r--r--resources/AppxManifest.xml2
-rw-r--r--resources/Nheko.appinstaller10
-rw-r--r--resources/NhekoNightly.appinstaller2
-rw-r--r--resources/nheko.appdata.xml.in7
-rw-r--r--resources/qml/RoomList.qml2
-rw-r--r--resources/qml/TimelineView.qml4
-rw-r--r--resources/qml/dialogs/InputDialog.qml2
-rw-r--r--src/LoginPage.cpp3
-rw-r--r--src/RegisterPage.cpp3
-rw-r--r--src/timeline/InputBar.cpp15
-rw-r--r--src/timeline/InputBar.h16
-rw-r--r--src/timeline/TimelineModel.cpp9
19 files changed, 331 insertions, 224 deletions
diff --git a/.ci/windows/build.bat b/.ci/windows/build.bat

index 4d392cb7..7e952237 100644 --- a/.ci/windows/build.bat +++ b/.ci/windows/build.bat
@@ -4,7 +4,7 @@ if defined CI_COMMIT_TAG ( set VERSION=%CI_COMMIT_TAG% ) else ( - set VERSION=v0.11.3 + set VERSION=v0.12.0 ) set INSTVERSION=%VERSION:~1% set WINVERSION=%VERSION:~1%.%CI_JOB_ID% diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index 464d0f86..13fe25dd 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml
@@ -96,9 +96,14 @@ pages: - apk add curl jq script: - export LATEST_WINDOWS_NIGHTLY=$(curl "https://nheko.im/api/v4/projects/2/packages?package_name=windows-nightly&order_by=version&sort=desc" | jq -r '.[0].version') - - sed "s/0.11.3.4/${LATEST_WINDOWS_NIGHTLY}/g" -i resources/NhekoNightly.appinstaller + #- export LATEST_WINDOWS=$(curl "https://nheko.im/api/v4/projects/2/packages?package_name=windows&order_by=version&sort=desc" | jq -r '.[0].version') + # hardcoded to avoid fuzzy matching + - export LATEST_WINDOWS='0.12.0.35798' + - sed "s/0.12.0.0/${LATEST_WINDOWS_NIGHTLY}/g" -i resources/NhekoNightly.appinstaller + - sed "s/0.12.0.0/${LATEST_WINDOWS}/g" -i resources/Nheko.appinstaller - mkdir public - mv resources/NhekoNightly.appinstaller public + - mv resources/Nheko.appinstaller public needs: - job: upload-windows optional: true diff --git a/CHANGELOG.md b/CHANGELOG.md
index aa0ed778..955dcb04 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md
@@ -1,5 +1,202 @@ # Changelog +## [0.12.0] -- 2024-06-12 + +### Notes + +The packages for windows are split into an appinstaller file with autoupdates +and an msix, which can be installed directly and won't check for updates. The +appimage is currently disabled until someone ports it to Qt6. The flatpak appid +changed and you will need to migrate manually. + +For packagers most of our dependencies have been changed or updated. Most +significantly Nheko now depends on KDSingleApplication and Qt6. + +### Highlights + +- Qt6 6️⃣ + - This release migrates to version 6 of the Qt toolkit. + - This brings various changes to Nheko. Scrolling might feel slower on some + platforms. Theming will look different. You have been warned! + - We left out all the fixes we had to do for this from the changelog. + Otherwise it might have been twice as long... +- Intentional mentions 🔔 + - You can now decide if a message should mention someone or not. + - Replies now also include an explicit mention (MSC4142). +- Event expiration ⏲️ + - You can now make Nheko delete messages regularly. + - Configure either a time or a maximum number of messages. + - Can be configured per room or globally. +- Ignoring users (NepNep) 🔕 + - You can now ignore other users. + - This will hide their messages from the timeline. + - You can either user the `/ignore` command, the button in their profile or + the button in the Nheko settings. + +### Features + +- Support for video calls (including screenshare) on Windows. This support is + currently not available in prebuilt packages. (checkraisefold) +- `/glitch` commands to garble your text. (LorenDB) +- Deleting sticker packs. (FallenValkyrie) +- Settings for your current profile state. (online, offline, unavailable, auto) +- "Goto this event" button in the timeline when searching. +- Right click menu entry to go to event when searching. (Sateallia) +- Remember the last used filter (community, tag, etc) between restarts. (Sateallia) +- Render reactions with custom emoji. +- Add custom emoji to the emoji popup. +- Add edit button to sticker and emoji popups. +- Optionally sort the room list alphabetically. (Sateallia) +- Allow sending custom message types. (LorenDB) +- Rainfall effect. (LorenDB) +- Screenshare using XDG desktop portals (like on Wayland). (David Elsing) +- Show which rooms you share with another user. + +### Improvements + +- Support MSC3916 for authenticated media. +- Disable workarounds for inline images for Qt6.7 and up. +- Various improvements around window activation on Wayland. (q234rty) +- Update emoji shortcodes. (TheDrawingCoder-Gamer) +- Windows and Apple Silicon builds on our own hardware. (Thanks Thulinma for + sponsoring access the Apple Silicon box) +- MSIX builds and appinstaller for Windows with valid signatures and automatic updates. +- Add environment variable to dump the video call pipeline. +- Bump supported maximum Matrix version to 1.10. +- Various fixes around blurry graphics on HiDPI systems. (q234rty) +- Build instructions for Qt6 version on Debian Trixie. (enigma9o7) +- Allow reporting messages to your server admin. (LorenDB) +- Matrix URI handling on macOS. (LorenDB) +- Disable endless pagination for threads. +- Deinit gstreamer appropriately. (NepNep) +- Support the "fixed" mac method during verification. +- Show/hide password button on login page. (Bubu) +- Faster blurhash decode. +- Speedup room switching. +- Setting to disable swipe navigation. (duarm) +- Click handling for Windows notifications. +- Update gstreamer in flatpak. (Francesco Gazzetta) +- Activation token handling for notifications. +- Improve Haiku support. (Begasus) +- Switch to KDSingleApplication for single instance handling. +- Trust handling for received megolm sessions. +- Highlight spaces in bold in the quick switcher. +- Throttle sync processing when the window is unfocused. +- Allow hiding unsupported events via the hidden events dialog. +- Change appid to im.nheko.Nheko. (Miika Tuominen) +- .editorconfig and .gitattributes. (Aminda Suomalainen) +- Remove fetched messages only on startup. +- Focus message input after drag and dropping a file. (Sateallia) +- Add extra styling for effect messages. +- Reduce CPU usage from animated images not currently visible. +- Close and open buttons for the room directory. (LorenDB) +- Touch scrolling for text. (LorenDB) +- Unify our usage of `@user:example.com`. (LorenDB) +- Explicit default font options. (LorenDB) +- Show powerlevel of mods and admins in the timeline. +- Mark room as read from the room list. +- Focus input bar after selecting a file. (Sateallia) +- Rework history settings. +- Show server ACL changes. +- Show inviter on invites. +- Sections for the sticker picker. +- Automatically strip file extensions of images in sticker picker. +- Focus the input bar on key presses. +- Search rooms in quick switcher by 'activity'. +- Make tombstoned rooms italic in the quick switcher. +- Allow uploading multiple files at once via the file picker. (Sateallia) +- Combine notifications above a certain count. (LcsTen) +- Allow querying the status msg over dbus (if enabled). +- Allow `#` character in url fragments (to work around clients not escaping + matrix.to links). +- Improve state event redaction. +- Hide inaccessible rooms in communities. (LcsTen) +- Update community metadata automatically. +- Include ACLs in via calculation. +- Focus message input on "scroll to bottom". (tastytea) +- Warn on invalid /command. (LorenDB) +- Cleanup table rendering. +- Blurhash images on privacy screen. (LorenDB) +- Improve OpenBSD support. (Klemens Nanni) +- Show full status mesage in profile and on hover. (Bubu) +- Animate transition from blurhash. (LorenDB) + +### Translations + +- Portugese (Tmpod) +- Polish (Przemysław Romanik, Vaxry) +- Dutch (Jaron Viëtor, Ruben De Smet) +- Turkish (Tennouji Misaki, Emilia) +- Chinese (Traditional) (AdrianL40) +- Chinese (Simplified) (Poesty Li, Eric, Integral, Estela ad Astra) +- Russian (pizdjuk) +- Indonesian (Linerly) +- Esperanto (Tirifto) +- Estonian (Priit Jõerüüt) +- French (val, luilegeant, CB, Guillaume Girol, Pixead, Mohamad Damaj, Tonus, + Mayeul Cantan) +- German +- Italian (DynamoFox, Elia Tomasi) +- Spanish (CM0use) +- Finnish (Lurkki14, Aminda Suomalainen) +- Arabic (nk) +- Persian (Farooq Karimi Zadeh) +- Ukrainian (NullPointerException) + +### Bugfixes + +- Prevent shortcuts from inserting unprintable characters. +- Display emojis in avatars properly. +- Prevent opening empty Nheko profiles by accident. +- DMs created in Nheko were not marked as DMs properly. +- Prevent opening user profiles for empty mxids. +- Fix crash during video calls on Linux. (checkraisefold) +- Fix validation errors in Linux appdata.xml. (Echo J) +- Properly copy images to the clipboard on Windows. (NepNep) +- Prevent emoji verification and room settings from being clipped by default. + (Brayd) +- Properly remove attributes on del tags. +- Properly scope presence setting to profiles. +- Animated images first rendered outside the visible area shouldn't be + invisible anymore. +- Correctly handle of multiple devices in parallel. +- Avoid lag when media messages are shown from enumerating audio devices. +- Hidden topic for spaces. +- Url encoding for widget urls. +- Profile argument parsing for `-p=`. (LorenDB) +- Unset hidden space setting when leaving a space. +- Round images are square. +- Don't freeze after stopping a call on Wayland. (GStreamer frees the EGL + context...) +- Database name length limitation on some filesystems with long userids. +- Pagination in search. +- Save profile also when no setting is modified. +- Fix decrypt notification setting not being stored properly. +- Calculate the name of rooms with 3 members correctly. +- Crash on database migration. (mips64-el) +- `<hr>` tag escaping. +- Confetti being left over after a celebration. +- Powerlevel indicator size in timeline. +- Duplicate qml ids. (ShootingStarDragons) +- Presence updates in the timeline. +- Pagination in rooms only containing redactions. +- Set a pack avatar. +- Make settings comboboxes dependent on content width. +- Don't lose message draft history after an edit. +- Workaround some WM specific behaviour regarding the focus during search. + (Sateallia) +- Handle network errors better when marking a mssage as read. +- Name and attributions of image packs should be plain text. +- Displaying encrypted thumbnails. +- 0 size dialogs. (0xDEADCADE) +- Loading image packs in unjoined communities. +- Show encryption dialog once, not twice. (LorenDB) +- Elide nicks and userids in various dialogs. (LorenDB) +- macOS builds (1000x). +- Disable qml disk cache by default. +- QT_SCALE_FACTOR on OpenBSD. (Klemens Nanni) +- Deduplicate reactions. + ## [0.11.3] -- 2023-02-23 ### Bugfix diff --git a/CMakeLists.txt b/CMakeLists.txt
index 28844070..04738bda 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt
@@ -113,8 +113,8 @@ include(QtCommon) include(GNUInstallDirs) set(CPACK_PACKAGE_VERSION_MAJOR "0") -set(CPACK_PACKAGE_VERSION_MINOR "11") -set(CPACK_PACKAGE_VERSION_PATCH "3") +set(CPACK_PACKAGE_VERSION_MINOR "12") +set(CPACK_PACKAGE_VERSION_PATCH "0") set(PROJECT_VERSION_MAJOR ${CPACK_PACKAGE_VERSION_MAJOR}) set(PROJECT_VERSION_MINOR ${CPACK_PACKAGE_VERSION_MINOR}) set(PROJECT_VERSION_PATCH ${CPACK_PACKAGE_VERSION_PATCH}) @@ -125,8 +125,8 @@ fix_project_version() # Set additional project information set(COMPANY "Nheko") -set(COPYRIGHT "Copyright (c) 2023 Nheko Contributors") -set(IDENTIFIER "io.github.nheko-reborn.nheko") +set(COPYRIGHT "Copyright (c) 2024 Nheko Contributors") +set(IDENTIFIER "im.nheko.Nheko") add_project_meta(META_FILES_TO_INCLUDE) @@ -606,13 +606,13 @@ if(USE_BUNDLED_MTXCLIENT) FetchContent_Declare( MatrixClient GIT_REPOSITORY https://github.com/Nheko-Reborn/mtxclient.git - GIT_TAG a70753812e3fb832df12b24ee0ee6c70d68060d5 + GIT_TAG v0.10.0 ) set(BUILD_LIB_EXAMPLES OFF CACHE INTERNAL "") set(BUILD_LIB_TESTS OFF CACHE INTERNAL "") FetchContent_MakeAvailable(MatrixClient) else() - find_package(MatrixClient 0.9.0 REQUIRED) + find_package(MatrixClient 0.10.0 REQUIRED) endif() if(VOIP) diff --git a/README.md b/README.md
index 44c22b61..2dc297d5 100644 --- a/README.md +++ b/README.md
@@ -12,7 +12,7 @@ feels more like a mainstream chat app ([Element], Telegram etc) and less like an ### Stable [![Stable Version](https://img.shields.io/badge/download-stable-green.svg)](https://github.com/Nheko-Reborn/nheko/releases/latest) -<a href='https://flathub.org/apps/details/io.github.NhekoReborn.Nheko'><img height='32' alt='Download on Flathub' src='https://flathub.org/assets/badges/flathub-badge-en.png'/></a> +<a href='https://flathub.org/apps/details/im.nheko.Nheko'><img height='32' alt='Download on Flathub' src='https://flathub.org/assets/badges/flathub-badge-en.png'/></a> [![Packaging status](https://repology.org/badge/tiny-repos/nheko.svg)](https://repology.org/project/nheko/versions) For other options and details see the [Installation](#installation) section. @@ -39,17 +39,19 @@ Most of the features you would expect from a chat application are missing right but we are getting close to a more feature complete client. Specifically there is support for: - E2E encryption. -- VoIP calls (voice & video). +- VoIP calls (voice & video, support varies by platform). - User registration. - Creating, joining & leaving rooms. - Sending & receiving invites. - Sending & receiving files and emoji (inline widgets for images, audio and file messages). +- Custom stickers and emoji. - Replies with text, images and other media (and actually render them as inline widgets). - Typing notifications. - Username auto-completion. - Message & mention notifications. - Redacting messages. - Read receipts. +- Presence and status messages (if enabled on the server side). - Basic communities support. - Room switcher (ctrl-K). - Light, Dark & System themes. @@ -60,8 +62,9 @@ Specifically there is support for: ### Releases -Releases for Linux (AppImage), macOS (disk image) & Windows (x64 installer) +Releases for Linux (Flatpak), macOS (disk image) & Windows (x64 msix or appinstaller) can be found in the [GitHub releases](https://github.com/Nheko-Reborn/nheko/releases). +The appinstaller on Windows will regularly check our servers for updates. The msix won't. ### Repositories @@ -143,7 +146,7 @@ sudo zypper install qt-jdenticon #### Flatpak ``` -flatpak install flathub io.github.NhekoReborn.Nheko +flatpak install flathub im.nheko.Nheko ``` #### Guix @@ -157,8 +160,8 @@ guix install nheko Install nheko via the `Discover` app in Desktop Mode (this installs the flatpak). To also make it work in Game Mode you'll have create a wrapper script that starts kwalletd and then nheko. You can create `/home/deck/nheko.sh` with the following content and then add this script as a "Non-Steam Game" to Steam. ```bash #!/bin/sh -kwalletd5& -flatpak run --env=XDG_CURRENT_DESKTOP=KDE --env=KDE_SESSION_VERSION=5 --branch=stable --arch=x86_64 --command=io.github.NhekoReborn.Nheko --file-forwarding io.github.NhekoReborn.Nheko @@u @@ +kwalletd6& +flatpak run --env=XDG_CURRENT_DESKTOP=KDE --env=KDE_SESSION_VERSION=5 --branch=stable --arch=x86_64 --command=im.nheko.Nheko --file-forwarding im.nheko.Nheko @@u @@ ``` #### macOS (10.14 and above) @@ -237,14 +240,14 @@ sharing easier. **A:** Nheko uses Qt's image plugins to render images. You might need to install additional packages to display some image types like webp. Usually those -packages are called `qt5-image-formats-plugins`, `qt5-imageformats` or similar. +packages are called `qt6-image-formats-plugins`, `qt6-imageformats` or similar. KDE has similar plugins, that can extend the supported image types even more. --- ### Build Requirements -- Qt5 (5.15 or greater). Required for overlapping hover handlers in Qml. +- Qt6 (6.5 or greater). Required for overlapping hover handlers in Qml. - CMake 3.15 or greater. (Lower version may work, but may break boost linking) - [mtxclient](https://github.com/Nheko-Reborn/mtxclient) - [coeurl](https://nheko.im/nheko-reborn/coeurl) @@ -253,7 +256,7 @@ KDE has similar plugins, that can extend the supported image types even more. - [cmark](https://github.com/commonmark/cmark) 0.29 or greater. - [libolm](https://gitlab.matrix.org/matrix-org/olm) - [spdlog](https://github.com/gabime/spdlog) (1.8.1 too old) -- [GStreamer](https://gitlab.freedesktop.org/gstreamer) 1.18.0 or greater (optional, needed for VoIP support. Pass `-DVOIP=OFF` to disable.). +- [GStreamer](https://gitlab.freedesktop.org/gstreamer) 1.20.0 or greater (optional, needed for VoIP support. Pass `-DVOIP=OFF` to disable.). - Installing the gstreamer core library plus gst-plugins-base, gst-plugins-good & gst-plugins-bad is often sufficient. The qmlgl plugin though is often packaged separately. The actual plugin requirements are as follows: @@ -265,7 +268,7 @@ KDE has similar plugins, that can extend the supported image types even more. - [KDSingleApplication](https://github.com/KDAB/KDSingleApplication) (1.0 or greater with Qt6 support) - A compiler that supports C++ 20: - Clang 16 (Only clazy 16 is tested in CI) - - GCC 11 (tested on Gitlab CI) + - GCC 11.3 (tested on Gitlab CI) - MSVC 19.13 (tested on AppVeyor) Nheko can use bundled version for most of those libraries automatically, if the versions in your distro are too old. @@ -303,17 +306,17 @@ make docker-app-image #### Arch Linux ```bash -sudo pacman -S qt5-base \ - qt5-tools \ - qt5-multimedia \ - qt5-svg \ +sudo pacman -S qt6-base \ + qt6-tools \ + qt6-multimedia \ + qt6-svg \ cmake \ gcc \ fontconfig \ lmdb \ cmark \ boost \ - qtkeychain-qt5 + qtkeychain-qt6 ``` #### Debian 13 [Testing/Sid] (Nheko QT6 Version) @@ -335,8 +338,8 @@ cmake --build build *Build requirements + qml modules needed at runtime (you may not need all of them, but the following seem to work according to reports):* ```bash sudo apt install --no-install-recommends g++ cmake make zlib1g-dev libssl-dev libolm-dev liblmdb-dev libcmark-dev nlohmann-json3-dev libspdlog-dev libevent-dev libcurl4-openssl-dev libre2-dev libxcb-ewmh-dev asciidoc-base \ -qt{base,declarative,tools,multimedia,quickcontrols2-}5-dev libqt5svg5-dev qt5keychain-dev qml-module-qt{gstreamer,multimedia,quick-extras,-labs-settings,-labs-platform,graphicaleffects,quick-controls2,quick-particles2} \ -libgstreamer1.0-dev libgstreamer-plugins-{base,bad}1.0-dev qtgstreamer-plugins-qt5 libnice-dev ninja-build +qt{base,declarative,tools,multimedia,quickcontrols2-}5-dev libqt6svg5-dev qt6keychain-dev qml-module-qt{gstreamer,multimedia,quick-extras,-labs-settings,-labs-platform,graphicaleffects,quick-controls2,quick-particles2} \ +libgstreamer1.0-dev libgstreamer-plugins-{base,bad}1.0-dev qtgstreamer-plugins-qt6 libnice-dev ninja-build ``` lmdb++-dev is too old so bundled lmdbxx must be used. libspdlog-dev in debian bullseye is too old (without backporting) so requires using hunter to use bundled spdlog. @@ -365,7 +368,7 @@ guix environment nheko ```bash brew update -brew install qt5 lmdb cmake llvm spdlog boost cmark libolm qtkeychain +brew install qt6 lmdb cmake llvm spdlog boost cmark libolm qtkeychain ``` #### Windows @@ -398,18 +401,18 @@ Adapt the USE_BUNDLED_* as needed. If the build fails with the following error ``` -Could not find a package configuration file provided by "Qt5Widgets" with +Could not find a package configuration file provided by "Qt6Widgets" with any of the following names: -Qt5WidgetsConfig.cmake -qt5widgets-config.cmake +Qt6WidgetsConfig.cmake +qt6widgets-config.cmake ``` -You might need to pass `-DCMAKE_PREFIX_PATH` to cmake to point it at your qt5 install. +You might need to pass `-DCMAKE_PREFIX_PATH` to cmake to point it at your qt6 install. e.g on macOS ``` -cmake -S. -Bbuild -DCMAKE_BUILD_TYPE=Release -DCMAKE_PREFIX_PATH=$(brew --prefix qt5) +cmake -S. -Bbuild -DCMAKE_BUILD_TYPE=Release -DCMAKE_PREFIX_PATH=$(brew --prefix qt6) cmake --build build ``` @@ -420,11 +423,11 @@ The `nheko` binary will be located in the `build` directory. After installing all dependencies, you need to edit the `CMakeSettings.json` to be able to load and compile nheko within Visual Studio. -You need to fill out the paths for the `Qt5_DIR`. -The Qt5 dir should point to the `lib\cmake\Qt5` dir. +You need to fill out the paths for the `Qt6_DIR`. +The Qt6 dir should point to the `lib\cmake\Qt6` dir. Examples for the paths are: - - `C:\\Qt\\5.15.1\\msvc2017_64\\lib\\cmake\\Qt5` + - `C:\\Qt\\6.5.2\\msvc2017_64\\lib\\cmake\\Qt6` You should also enable hunter by setting `HUNTER_ENABLED` to `ON` and `BUILD_SHARED_LIBS` to `OFF`. diff --git a/appveyor.yml b/appveyor.yml deleted file mode 100644
index 084e7179..00000000 --- a/appveyor.yml +++ /dev/null
@@ -1,134 +0,0 @@ ---- - -version: 0.11.3-{build} - -configuration: Release -image: Visual Studio 2022 -platform: x64 - -environment: - APPVEYOR_SAVE_CACHE_ON_ERROR: true - MATRIX_ACCESS_TOKEN: - secure: Qoy+QQ8zWXYCQrck9GtXJsoPTv9r/rhgCDUlKJ6ue+gkteYG40E9MxgwP1svn6bse20H4z6Svrxn8kFbcJB7Wg2Cnv1s326/vsJJzhWir2eHFFGK+f4SB992/U0HoQmk3Cq5hPk7dLcA7KqHIa1g1PTSFPfl1VODJ2UqqAyn8nzbC5ym+wwU1buJqoWPlTyHBW7eE8wNe77+qI18XpF7NN8yuOOyg3Tzup9YyXLrI36XiJu/5JD3j3s3V1QiUTpuLyQzqwuBUOf1MHTbzuPwHm3ZwzSM98WD6aL6riaK9qa7mDbSx1aY0ukIYSY9IdAfHNwZY/DEAn+QAVD+ZTvPq04ASv+kmSFpOBKr07kpqfM= - - - -cache: - - c:\hunter\ -> appveyor.yml, CMakeLists.txt, cmake/Hunter/config.cmake - - build\_deps -> appveyor.yml, CMakeLists.txt - -build: - verbosity: minimal - -install: - - set QT_DIR=C:\Qt\6.5\msvc2019_64 - - set PATH=C:\Strawberry\perl\bin;C:\Python39-x64;%QT_DIR%\bin;%PATH% - -build_script: - # VERSION format: branch-master/branch-1.2 - # INSTVERSION format: x.y.z - # WINVERSION format: 9999.0.0.123/1.2.0.234 - - if "%APPVEYOR_REPO_TAG%"=="false" set INSTVERSION=0.11.3 - - if "%APPVEYOR_REPO_TAG%"=="false" set VERSION=0.11.3 - - if "%APPVEYOR_REPO_TAG%"=="false" set WINVERSION=%INSTVERSION%.%APPVEYOR_BUILD_NUMBER% - # VERSION format: v1.2.3/v1.3.4 - # INSTVERSION format: 1.2.3/1.3.4 - # WINVERSION format: 1.2.3.123/1.3.4.234 - - if "%APPVEYOR_REPO_TAG%"=="true" set VERSION=%APPVEYOR_REPO_TAG_NAME% - - if "%APPVEYOR_REPO_TAG%"=="true" set INSTVERSION=%VERSION:~1% - - if "%APPVEYOR_REPO_TAG%"=="true" set WINVERSION=%VERSION:~1%.%APPVEYOR_BUILD_NUMBER% - - set DATE=%date:~10,4%-%date:~4,2%-%date:~7,2% - - echo %VERSION% - - echo %INSTVERSION% - - echo %DATE% - - # Build nheko - - cmake -G "Visual Studio 17 2022" -A x64 -H. -Bbuild - -DHUNTER_ROOT="C:\hunter" - -DHUNTER_ENABLED=ON -DBUILD_SHARED_LIBS=OFF -DUSE_BUNDLED_OPENSSL=ON -DUSE_BUNDLED_KDSINGLEAPPLICATION=ON - -DCMAKE_BUILD_TYPE=Release -DHUNTER_CONFIGURATION_TYPES=Release - - - cmake --build build --config Release - - - call "C:\Program Files\Microsoft Visual Studio\2022\Community\VC\Auxiliary\Build\vcvarsall.bat" x64 - - git clone https://github.com/Nheko-Reborn/qt-jdenticon.git - - cd qt-jdenticon - - qmake - - nmake - - cd .. - -after_build: - # Variables - - set BUILD=%APPVEYOR_BUILD_FOLDER% - - echo %BUILD% - - mkdir NhekoRelease - - copy build\Release\nheko.exe NhekoRelease\nheko.exe - - copy qt-jdenticon\release\qtjdenticon0.dll NhekoRelease\qtjdenticon.dll - - copy build\_deps\cmark-build\src\Release\cmark.dll NhekoRelease\cmark.dll - - windeployqt --qmldir resources\qml\ NhekoRelease\nheko.exe - - - 7z a nheko_win_64.zip .\NhekoRelease\* - - ls -lh build\Release\ - - ls -lh NhekoRelease\ - - mkdir NhekoData - - xcopy .\NhekoRelease\*.* NhekoData\*.* /s /e /c /y - # - # Create the Qt Installer Framework version - # - - mkdir installer - - mkdir installer\config - - mkdir installer\packages - - mkdir installer\packages\io.github.nhekoreborn.nheko - - mkdir installer\packages\io.github.nhekoreborn.nheko\data - - mkdir installer\packages\io.github.nhekoreborn.nheko\meta - # Copy installer data - - copy %BUILD%\resources\nheko.ico installer\config - - copy %BUILD%\resources\nheko.png installer\config - - copy %BUILD%\COPYING installer\packages\io.github.nhekoreborn.nheko\meta\license.txt - - copy %BUILD%\deploy\installer\config.xml installer\config - - copy %BUILD%\deploy\installer\controlscript.qs installer\config - - copy %BUILD%\deploy\installer\uninstall.qs installer\packages\io.github.nhekoreborn.nheko\data - - copy %BUILD%\deploy\installer\gui\package.xml installer\packages\io.github.nhekoreborn.nheko\meta - - copy %BUILD%\deploy\installer\gui\installscript.qs installer\packages\io.github.nhekoreborn.nheko\meta - # Amend version and date - - sed -i "s/__VERSION__/%VERSION%/" installer\config\config.xml - - sed -i "s/__VERSION__/%VERSION%/" installer\packages\io.github.nhekoreborn.nheko\meta\package.xml - - sed -i "s/__DATE__/%DATE%/" installer\packages\io.github.nhekoreborn.nheko\meta\package.xml - # Copy nheko data - - xcopy NhekoData\*.* installer\packages\io.github.nhekoreborn.nheko\data\*.* /s /e /c /y - - copy NhekoRelease\nheko.exe installer\packages\io.github.nhekoreborn.nheko\data - - mkdir tools - - curl -L -O https://download.qt.io/official_releases/qt-installer-framework/4.3.0/QtInstallerFramework-windows-x86-4.3.0.exe - - 7z x QtInstallerFramework-windows-x86-4.3.0.exe -otools -aoa - - set PATH=%BUILD%\tools\bin;%PATH% - - binarycreator.exe -f -c installer\config\config.xml -p installer\packages nheko-installer.exe - - # build an msix - - mkdir msix - - xcopy .\NhekoRelease\*.* msix\*.* /s /e /c /y - - copy %BUILD%\resources\nheko.png msix - - copy %BUILD%\resources\AppxManifest.xml msix - - del msix\vc_redist* - - 'sed -i "s/ Version=[^ ]*/ Version=\"%WINVERSION%\"/" msix\AppxManifest.xml' - - '"C:\Program Files (x86)\Windows Kits\10\App Certification Kit\makeappx.exe" pack -d msix -p nheko.msix' - - - copy nheko-installer.exe nheko-%APPVEYOR_REPO_TAG_NAME%-installer.exe - - copy nheko-installer.exe nheko-%APPVEYOR_PULL_REQUEST_HEAD_COMMIT%-installer.exe - - ps: .\.ci\upload-nightly.ps1 - -deploy: - - description: "Development builds" - provider: GitHub - auth_token: - secure: "ShStWeqp+TkYqJPQr7uFZb+B8ZTgC7Iwth+IkhjfRDCTLhy8gtWvlPzlQilder3E" - artifact: nheko-${APPVEYOR_REPO_TAG_NAME}-installer.exe - force_update: true - prerelease: true - on: - appveyor_repo_tag: true - -artifacts: - - path: nheko_win_64.zip - - path: nheko.msix - - path: nheko-$(APPVEYOR_REPO_TAG_NAME)-installer.exe - - path: nheko-$(APPVEYOR_PULL_REQUEST_HEAD_COMMIT)-installer.exe diff --git a/im.nheko.Nheko.yaml b/im.nheko.Nheko.yaml
index aa874c0e..8cdc5edb 100644 --- a/im.nheko.Nheko.yaml +++ b/im.nheko.Nheko.yaml
@@ -1,21 +1,23 @@ id: im.nheko.Nheko command: im.nheko.Nheko runtime: org.kde.Platform -runtime-version: '6.6' +runtime-version: '6.7' sdk: org.kde.Sdk finish-args: - - --device=dri - # needed for webcams, see #517 + # needed for webcams, see https://github.com/Nheko-Reborn/nheko/issues/517 - --device=all - --share=ipc - --share=network - --socket=pulseaudio - - --socket=wayland - --socket=x11 + - --socket=wayland - --talk-name=org.freedesktop.Notifications - --talk-name=org.freedesktop.secrets + - --talk-name=org.kde.kwalletd5 + - --talk-name=org.kde.kwalletd6 - --talk-name=org.freedesktop.StatusNotifierItem - - --talk-name=org.kde.* + # needed for tray icon + - --talk-name=org.kde.StatusNotifierWatcher cleanup: - /include - /lib/pkgconfig @@ -83,18 +85,18 @@ modules: - sha256: 5197b3147cfcfaa67dd564db7b878e4a4b3d9f3443801722b3915cdeced656cb type: archive url: https://github.com/gabime/spdlog/archive/v1.8.1.tar.gz - - config-opts: + - name: olm + config-opts: - -DCMAKE_BUILD_TYPE=Release buildsystem: cmake-ninja - name: olm sources: - commit: 92769cec711c604a1f682b95d6944578d2a1bb3d disable-shallow-clone: true tag: 3.2.12 type: git url: https://gitlab.matrix.org/matrix-org/olm.git - - buildsystem: meson - name: libsecret + - name: libsecret + buildsystem: meson config-opts: - -Dmanpage=false - -Dvapi=false @@ -137,51 +139,52 @@ modules: # tag: v5.93.0 # type: git # url: https://invent.kde.org/frameworks/kimageformats.git - - config-opts: + - name: QtKeychain + config-opts: - -DCMAKE_BUILD_TYPE=Release - -DBUILD_TEST_APPLICATION=OFF - -DQTKEYCHAIN_STATIC=ON - -DBUILD_WITH_QT6=ON buildsystem: cmake-ninja - name: QtKeychain sources: - commit: 69f993c47efed7e557d79a30a367014d9a27d809 tag: 0.14.1 type: git url: https://github.com/frankosterfeld/qtkeychain.git - - config-opts: + - name: nlohmann + config-opts: - -DJSON_BuildTests=OFF - buildsystem: cmake - name: nlohmann + buildsystem: cmake-ninja sources: - sha256: d69f9deb6a75e2580465c6c4c5111b89c4dc2fa94e3a85fcd2ffcd9a143d9273 type: archive url: https://github.com/nlohmann/json/archive/v3.11.2.tar.gz - - config-opts: + - name: kdsingleapplication + config-opts: - -DKDSingleApplication_EXAMPLES=OFF - -DKDSingleApplication_QT6=ON - buildsystem: cmake - name: kdsingleapplication + buildsystem: cmake-ninja sources: - sha256: c92355dc10f3ebd39363458458fb5bdd9662e080cf77d91f0437763c4d936520 type: archive url: https://github.com/KDAB/KDSingleApplication/releases/download/v1.0.0/kdsingleapplication-1.0.0.tar.gz - - buildsystem: simple + - name: re2 + buildsystem: simple build-commands: - make static - make prefix=/app static-install - name: re2 sources: - sha256: f89c61410a072e5cbcf8c27e3a778da7d6fd2f2b5b1445cd4f4508bee946ab0f type: archive url: https://github.com/google/re2/archive/refs/tags/2022-06-01.tar.gz - - buildsystem: meson - name: gstreamer + - name: gstreamer + buildsystem: meson sources: - - commit: 4d13eddc8b6d3f42ba44682ba42048acf170547f - tag: 1.22.7 + - commit: d2c02bb704b5804ca057fc7e6c7b16b4466fd7d5 + tag: 1.22.12 type: git url: https://gitlab.freedesktop.org/gstreamer/gstreamer.git + disable-submodules: true config-opts: - --auto-features=disabled - -Dgood=enabled @@ -195,46 +198,46 @@ modules: - -Dgst-plugins-base:gl_winsys=x11,wayland - -Dgst-plugins-base:x11=enabled - -Dgst-plugins-base:xshm=enabled - - buildsystem: cmake - name: qt-jdenticon + - name: qt-jdenticon + buildsystem: cmake-ninja no-make-install: true build-commands: - mkdir -p /app/bin/ - cp libqtjdenticon.so /app/bin/ sources: - - commit: 1e7013d64fd081d76e4ce69f2693129c817fd8f1 - #tag: v0.3.0 + - commit: 39cde33d4b23b57aa5b94e94071d6ff18d2bd92a + tag: v0.3.1 type: git url: https://github.com/Nheko-Reborn/qt-jdenticon.git - - buildsystem: meson + - name: coeurl + buildsystem: meson config-opts: - -Ddefault_library=static - name: coeurl sources: - commit: 3007387745cf84138d0855e0f04ff94261fc7175 #tag: v0.3.0 type: git url: https://nheko.im/nheko-reborn/coeurl.git - - config-opts: + - name: mtxclient + config-opts: - -DBUILD_LIB_TESTS=OFF - -DBUILD_LIB_EXAMPLES=OFF - -DCMAKE_BUILD_TYPE=Release - -DBUILD_SHARED_LIBS=OFF buildsystem: cmake-ninja - name: mtxclient sources: - - commit: a70753812e3fb832df12b24ee0ee6c70d68060d5 - #tag: v0.9.2 + - commit: 457bc52773b40142848f0b2ab025516bf6ed634d + tag: v0.10.0 type: git url: https://github.com/Nheko-Reborn/mtxclient.git - - config-opts: + - name: nheko + config-opts: - -DCMAKE_BUILD_TYPE=Release - -DLMDBXX_INCLUDE_DIR=.deps/lmdbxx - -DCOMPILE_QML=ON - -DMAN=OFF - -DFLATPAK=ON buildsystem: cmake-ninja - name: nheko sources: - path: . type: dir diff --git a/resources/AppxManifest.xml b/resources/AppxManifest.xml
index 9f933604..8253f839 100644 --- a/resources/AppxManifest.xml +++ b/resources/AppxManifest.xml
@@ -4,7 +4,7 @@ xmlns:uap="http://schemas.microsoft.com/appx/manifest/uap/windows10" xmlns:uap10="http://schemas.microsoft.com/appx/manifest/uap/windows10/10" xmlns:rescap="http://schemas.microsoft.com/appx/manifest/foundation/windows10/restrictedcapabilities"> - <Identity Name="im.nheko.Nheko" Version="0.11.3.4" Publisher="CN=Nicolas Werner, O=Nicolas Werner, L=Munich, S=Bavaria, C=DE" ProcessorArchitecture="x64"/> + <Identity Name="im.nheko.Nheko" Version="0.12.0.0" Publisher="CN=Nicolas Werner, O=Nicolas Werner, L=Munich, S=Bavaria, C=DE" ProcessorArchitecture="x64"/> <Properties> <DisplayName>Nheko</DisplayName> <PublisherDisplayName>Nheko-Reborn</PublisherDisplayName> diff --git a/resources/Nheko.appinstaller b/resources/Nheko.appinstaller new file mode 100644
index 00000000..004a0d73 --- /dev/null +++ b/resources/Nheko.appinstaller
@@ -0,0 +1,10 @@ +<?xml version="1.0" encoding="utf-8"?> +<AppInstaller Uri="https://nheko-reborn.pages.nheko.im/nheko/Nheko.appinstaller" Version="0.0.0.1" xmlns="http://schemas.microsoft.com/appx/appinstaller/2018"> + <MainPackage Name="im.nheko.Nheko" Version="0.12.0.0" Publisher="CN=Nicolas Werner, O=Nicolas Werner, L=Munich, S=Bavaria, C=DE" Uri="https://nheko.im/api/v4/projects/2/packages/generic/windows/0.12.0.0/nheko.msix" ProcessorArchitecture="x64" /> + <UpdateSettings> + <!-- We can't set this to check only once a month, so just check once a week. If the user doesn't want that ping, they should install the msix directly. --> + <OnLaunch HoursBetweenUpdateChecks="168" ShowPrompt="true" /> + <ForceUpdateFromAnyVersion>true</ForceUpdateFromAnyVersion> + </UpdateSettings> +</AppInstaller> + diff --git a/resources/NhekoNightly.appinstaller b/resources/NhekoNightly.appinstaller
index bd94f5d9..88f1fd8a 100644 --- a/resources/NhekoNightly.appinstaller +++ b/resources/NhekoNightly.appinstaller
@@ -1,6 +1,6 @@ <?xml version="1.0" encoding="utf-8"?> <AppInstaller Uri="https://nheko-reborn.pages.nheko.im/nheko/NhekoNightly.appinstaller" Version="0.0.0.1" xmlns="http://schemas.microsoft.com/appx/appinstaller/2018"> - <MainPackage Name="im.nheko.Nheko" Version="0.11.3.4" Publisher="CN=Nicolas Werner, O=Nicolas Werner, L=Munich, S=Bavaria, C=DE" Uri="https://nheko.im/api/v4/projects/2/packages/generic/windows-nightly/0.11.3.4/nheko.msix" ProcessorArchitecture="x64" /> + <MainPackage Name="im.nheko.Nheko" Version="0.12.0.0" Publisher="CN=Nicolas Werner, O=Nicolas Werner, L=Munich, S=Bavaria, C=DE" Uri="https://nheko.im/api/v4/projects/2/packages/generic/windows-nightly/0.12.0.0/nheko.msix" ProcessorArchitecture="x64" /> <UpdateSettings> <!-- We can't set this to check only once a month, so just check once a week. If the user doesn't want that ping, they should install the msix directly. --> <OnLaunch HoursBetweenUpdateChecks="168" ShowPrompt="true" /> diff --git a/resources/nheko.appdata.xml.in b/resources/nheko.appdata.xml.in
index 69a632a1..77d1c6ad 100644 --- a/resources/nheko.appdata.xml.in +++ b/resources/nheko.appdata.xml.in
@@ -59,6 +59,13 @@ <url type="homepage">https://github.com/Nheko-Reborn/nheko</url> <update_contact>https://github.com/Nheko-Reborn</update_contact> <releases> + <release date="2024-06-12" version="0.12.0"> + <description> + <p>This release features a complete port to Qt6, intentional mentions, expiring messages, ignoring users, better sticker and emoji handling and much, much more!</p> + </description> + + <url>https://github.com/Nheko-Reborn/nheko/releases/tag/v0.12.0</url> + </release> <release date="2023-02-23" version="0.11.3"/> <release date="2023-02-20" version="0.11.2"/> <release date="2023-01-15" version="0.11.1"/> diff --git a/resources/qml/RoomList.qml b/resources/qml/RoomList.qml
index 350b3846..c82bc43a 100644 --- a/resources/qml/RoomList.qml +++ b/resources/qml/RoomList.qml
@@ -249,6 +249,8 @@ Page { prompt: qsTr("Enter your status message:") title: qsTr("Status Message") + text: userInfoGrid.profile ? Presence.userStatus(userInfoGrid.profile.userid) : "" + onAccepted: function (text) { Nheko.setStatusMessage(text); } diff --git a/resources/qml/TimelineView.qml b/resources/qml/TimelineView.qml
index c29eb537..53b1951c 100644 --- a/resources/qml/TimelineView.qml +++ b/resources/qml/TimelineView.qml
@@ -27,7 +27,9 @@ Item { Keys.onPressed: event => { if (event.text && event.key !== Qt.Key_Enter && event.key !== Qt.Key_Return && !topBar.searchHasFocus) { TimelineManager.focusMessageInput(); - room.input.setText(room.input.text + event.text); + if (event.modifiers != Qt.ControlModifier) { + room.input.setText(room.input.text + event.text); + } } } onRoomChanged: if (room != null) diff --git a/resources/qml/dialogs/InputDialog.qml b/resources/qml/dialogs/InputDialog.qml
index bf3cbc9a..c963febb 100644 --- a/resources/qml/dialogs/InputDialog.qml +++ b/resources/qml/dialogs/InputDialog.qml
@@ -13,6 +13,8 @@ ApplicationWindow { property alias prompt: promptLabel.text property alias echoMode: statusInput.echoMode + property alias text: statusInput.text + signal accepted(text: string) modality: Qt.NonModal diff --git a/src/LoginPage.cpp b/src/LoginPage.cpp
index ea295136..9b48730d 100644 --- a/src/LoginPage.cpp +++ b/src/LoginPage.cpp
@@ -184,13 +184,14 @@ LoginPage::checkHomeserverVersion() "v1.7", "v1.8", "v1.9", + "v1.10", }; return supported.count(v) != 0; }) == versions.versions.cend()) { emit versionErrorCb( tr("The selected server does not support a version of the Matrix protocol, that this " "client understands (%1 to %2). You can't sign in.") - .arg(u"v1.1", u"v1.9")); + .arg(u"v1.1", u"v1.10")); return; } diff --git a/src/RegisterPage.cpp b/src/RegisterPage.cpp
index 824547bc..93e2cf1b 100644 --- a/src/RegisterPage.cpp +++ b/src/RegisterPage.cpp
@@ -139,13 +139,14 @@ RegisterPage::versionsCheck() "v1.7", "v1.8", "v1.9", + "v1.10", }; return supported.count(v) != 0; }) == versions.versions.cend()) { emit setHsError( tr("The selected server does not support a version of the Matrix protocol that " "this client understands (%1 to %2). You can't register.") - .arg(u"v1.1", u"v1.9")); + .arg(u"v1.1", u"v1.10")); emit hsErrorChanged(); return; } diff --git a/src/timeline/InputBar.cpp b/src/timeline/InputBar.cpp
index 2d15d01a..57c1263b 100644 --- a/src/timeline/InputBar.cpp +++ b/src/timeline/InputBar.cpp
@@ -187,9 +187,6 @@ InputBar::addMention(QString mention, QString text) mentionTexts_.push_back(text); emit mentionsChanged(); - if (mention == u"@room") { - this->containsAtRoom_ = true; - } } } @@ -200,9 +197,6 @@ InputBar::removeMention(QString mention) mentions_.removeAt(idx); mentionTexts_.removeAt(idx); emit mentionsChanged(); - if (mention == u"@room") { - this->containsAtRoom_ = false; - } } } @@ -244,6 +238,7 @@ InputBar::updateTextContentProperties(const QString &t, bool charDeleted) auto roomMention = containsRoomMention(t) && this->room->permissions()->canPingRoom(); if (roomMention != this->containsAtRoom_) { + this->containsAtRoom_ = roomMention; if (roomMention) addMention(QStringLiteral(u"@room"), QStringLiteral(u"@room")); else @@ -500,8 +495,11 @@ mtx::common::Mentions InputBar::generateMentions() { std::vector<std::string> userMentions; + bool atRoom = false; for (const auto &m : mentions_) - if (m != u"@room") + if (m == u"@room") + atRoom = true; + else userMentions.push_back(m.toStdString()); if (!room->reply().isEmpty()) { @@ -515,7 +513,8 @@ InputBar::generateMentions() auto mention = mtx::common::Mentions{ .user_ids = userMentions, - .room = containsAtRoom_, + // We use the atRoom from the mentions list to allow suppressing a room mention + .room = atRoom, }; // this->containsAtRoom_ = false; diff --git a/src/timeline/InputBar.h b/src/timeline/InputBar.h
index c38de662..5e885d4f 100644 --- a/src/timeline/InputBar.h +++ b/src/timeline/InputBar.h
@@ -194,15 +194,17 @@ public slots: void storeForEdit() { - textBeforeEdit = text(); - mentionsBefore = mentions_; - mentionTextsBefore = mentionTexts_; + textBeforeEdit = text(); + mentionsBefore = mentions_; + mentionTextsBefore = mentionTexts_; + containsAtRoomBefore = containsAtRoom_; emit mentionsChanged(); } void restoreAfterEdit() { - mentions_ = mentionsBefore; - mentionTexts_ = mentionTextsBefore; + mentions_ = mentionsBefore; + mentionTexts_ = mentionTextsBefore; + containsAtRoom_ = containsAtRoomBefore; mentionsBefore.clear(); mentionTextsBefore.clear(); setText(textBeforeEdit); @@ -216,6 +218,9 @@ public slots: mentions_ = newMentions; mentionTexts_ = newMentionTexts; + + this->containsAtRoom_ = newMentions.contains(u"@room"); + emit mentionsChanged(); } @@ -331,6 +336,7 @@ private: // store stuff during edits QStringList mentionsBefore, mentionTextsBefore; QString textBeforeEdit; + bool containsAtRoomBefore = false; using UploadHandle = std::unique_ptr<MediaUpload, DeleteLaterDeleter>; std::vector<UploadHandle> unconfirmedUploads; diff --git a/src/timeline/TimelineModel.cpp b/src/timeline/TimelineModel.cpp
index 14fd574b..48b58ee5 100644 --- a/src/timeline/TimelineModel.cpp +++ b/src/timeline/TimelineModel.cpp
@@ -736,7 +736,9 @@ TimelineModel::data(const mtx::events::collections::TimelineEvents &event, int r .arg(displayName(QString::fromStdString(e.sender))) .arg(QStringLiteral("<img height=\"32\" src=\"%1\">") .arg(QUrl::toPercentEncoding( - QString::fromStdString(e.content.url)))); + QString::fromStdString(e.content.url) + .replace("mxc://", "image://MxcImage/"), + ":/"))); else return tr("%1 removed the room avatar.") .arg(displayName(QString::fromStdString(e.sender))); @@ -2244,8 +2246,9 @@ TimelineModel::getRoomVias(const QString &roomId) void TimelineModel::copyLinkToEvent(const QString &eventId) const { - auto link = QStringLiteral("%1/%2?%3") - .arg(getBareRoomLink(room_id_), + // Event links shouldn't use an alias, since that can be repointed. + auto link = QStringLiteral("https://matrix.to/#/%1/%2?%3") + .arg(QUrl::toPercentEncoding(room_id_), QString(QUrl::toPercentEncoding(eventId)), getRoomVias(room_id_)); QGuiApplication::clipboard()->setText(link);