summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--gnu/local.mk1
-rw-r--r--gnu/packages/patches/texmacs-wayland-hidpi.patch22
-rw-r--r--gnu/packages/text-editors.scm8
3 files changed, 27 insertions, 4 deletions
diff --git a/gnu/local.mk b/gnu/local.mk
index 3b09aa1b171..b66ab6b2639 100644
--- a/gnu/local.mk
+++ b/gnu/local.mk
@@ -2485,6 +2485,7 @@ dist_patch_DATA = \
%D%/packages/patches/tensile-copy-if-not-exist.patch \
%D%/packages/patches/texi2html-document-encoding.patch \
%D%/packages/patches/texi2html-i18n.patch \
+ %D%/packages/patches/texmacs-wayland-hidpi.patch \
%D%/packages/patches/tflite-micro_disable_download.patch \
%D%/packages/patches/thefuck-test-environ.patch \
%D%/packages/patches/thefuck-remove-broken-tests.patch \
diff --git a/gnu/packages/patches/texmacs-wayland-hidpi.patch b/gnu/packages/patches/texmacs-wayland-hidpi.patch
new file mode 100644
index 00000000000..decf500125f
--- /dev/null
+++ b/gnu/packages/patches/texmacs-wayland-hidpi.patch
@@ -0,0 +1,22 @@
+Author: Danny Milosavljevic <dannym@friendly-machines.com>
+Date: 2024-12-11 18:30:00 CET 2024
+License: gpl3+
+
+diff -ru orig/qsbrdssq407hsajf74z60vp3rhgafjsl-mogan-1.1.1-checkout/src/Texmacs/Texmacs/texmacs.cpp qsbrdssq407hsajf74z60vp3rhgafjsl-mogan-1.1.1-checkout/src/Texmacs/Texmacs/texmacs.cpp
+--- orig/qsbrdssq407hsajf74z60vp3rhgafjsl-mogan-1.1.1-checkout/src/Texmacs/Texmacs/texmacs.cpp 2024-05-10 01:51:55.312256939 +0200
++++ qsbrdssq407hsajf74z60vp3rhgafjsl-mogan-1.1.1-checkout/src/Texmacs/Texmacs/texmacs.cpp 2024-05-10 01:52:43.659909394 +0200
+@@ -685,8 +685,12 @@
+ #ifndef OS_MINGW
+ set_env ("LC_NUMERIC", "POSIX");
+ #ifndef OS_MACOS
+- set_env ("QT_QPA_PLATFORM", "xcb");
+- set_env ("XDG_SESSION_TYPE", "x11");
++ if (get_env ("XDG_SESSION_TYPE") == "wayland") {
++ set_env ("QT_QPA_PLATFORM", "wayland"); QGuiApplication::setAttribute(Qt::AA_DisableHighDpiScaling); QGuiApplication::setAttribute(Qt::AA_UseHighDpiPixmaps);
++ } else {
++ set_env ("QT_QPA_PLATFORM", "xcb");
++ set_env ("XDG_SESSION_TYPE", "x11");
++ }
+ #endif
+ #endif
+ #ifdef MACOSX_EXTENSIONS
diff --git a/gnu/packages/text-editors.scm b/gnu/packages/text-editors.scm
index f18dc12417a..723671e7c8f 100644
--- a/gnu/packages/text-editors.scm
+++ b/gnu/packages/text-editors.scm
@@ -133,7 +133,6 @@
#:use-module (gnu packages sqlite)
#:use-module (gnu packages terminals)
#:use-module (gnu packages texinfo)
- #:use-module (gnu packages tls)
#:use-module (gnu packages version-control)
#:use-module (gnu packages xml)
#:use-module (gnu packages xorg))
@@ -1292,20 +1291,21 @@ interface with CI pipeline UIs.")
(define-public texmacs
(package
(name "texmacs")
- (version "2.1.5")
+ (version "2.1.4")
(source
(origin
(method url-fetch)
(uri (string-append "https://www.texmacs.org/Download/ftp/tmftp/"
"source/TeXmacs-" version "-src.tar.gz"))
(sha256
- (base32 "0q3k0asf31mm2jl7fi7244sk6c9lprf434cj4c5h2ycfpayjg8dk"))))
+ (base32 "11l1q5lmsj9g7yil1dn7n1cgsr8iikx59kg9riahpb6xw0p959l7"))
+ (patches
+ (search-patches "texmacs-wayland-hidpi.patch"))))
(build-system qt-build-system)
(native-inputs
(list pkg-config xdg-utils)) ;for xdg-icon-resource
(inputs
(list freetype
- gnutls
guile-1.8
libjpeg-turbo
libxcrypt