Use Alacritty as terminal

This commit is contained in:
Alex Kotov 2021-11-18 18:57:41 +05:00
parent 8be8ec9eb2
commit 6adf87b4ae
Signed by: kotovalexarian
GPG key ID: 553C0EBBEB5D5F08
6 changed files with 49 additions and 36 deletions

View file

@ -3,12 +3,15 @@ CPPFLAGS += -DENABLE_XINERAMA
PKGS += xinerama PKGS += xinerama
.endif .endif
.if "$(WITH_TERMINAL)" == "ptterm" .if "$(WITH_TERMINAL)" == "alacritty"
CPPFLAGS += -DWITH_TERMINAL -DWITH_TERMINAL_PTTERM CPPFLAGS += -DWITH_TERMINAL -DWITH_TERMINAL_ALACRITTY
.endif
.if "$(WITH_TERMINAL)" == "xterm"
CPPFLAGS += -DWITH_TERMINAL -DWITH_TERMINAL_XTERM
.endif .endif
.if "$(WITH_TERMINAL)" == "gnome" .if "$(WITH_TERMINAL)" == "gnome"
CPPFLAGS += -DWITH_TERMINAL -DWITH_TERMINAL_GNOME CPPFLAGS += -DWITH_TERMINAL -DWITH_TERMINAL_GNOME
.endif .endif
.if "$(WITH_TERMINAL)" == "st"
CPPFLAGS += -DWITH_TERMINAL -DWITH_TERMINAL_ST
.endif
.if "$(WITH_TERMINAL)" == "xterm"
CPPFLAGS += -DWITH_TERMINAL -DWITH_TERMINAL_XTERM
.endif

View file

@ -3,12 +3,15 @@ CPPFLAGS += -DENABLE_XINERAMA
PKGS += xinerama PKGS += xinerama
endif endif
ifeq (ptterm,$(WITH_TERMINAL)) ifeq (alacritty,$(WITH_TERMINAL))
CPPFLAGS += -DWITH_TERMINAL -DWITH_TERMINAL_PTTERM CPPFLAGS += -DWITH_TERMINAL -DWITH_TERMINAL_ALACRITTY
endif
ifeq (xterm,$(WITH_TERMINAL))
CPPFLAGS += -DWITH_TERMINAL -DWITH_TERMINAL_XTERM
endif endif
ifeq (gnome,$(WITH_TERMINAL)) ifeq (gnome,$(WITH_TERMINAL))
CPPFLAGS += -DWITH_TERMINAL -DWITH_TERMINAL_GNOME CPPFLAGS += -DWITH_TERMINAL -DWITH_TERMINAL_GNOME
endif endif
ifeq (st,$(WITH_TERMINAL))
CPPFLAGS += -DWITH_TERMINAL -DWITH_TERMINAL_ST
endif
ifeq (xterm,$(WITH_TERMINAL))
CPPFLAGS += -DWITH_TERMINAL -DWITH_TERMINAL_XTERM
endif

34
configure vendored
View file

@ -40,14 +40,13 @@ File tuning of the installation directories:
--mandir DIR man documentation [DATAROOTDIR/man] --mandir DIR man documentation [DATAROOTDIR/man]
Optional Features: Optional Features:
--enable-gnome-terminal use GNOME Terminal instead of ptterm
--disable-xinerama disable Xinerama --disable-xinerama disable Xinerama
Optional Packages: Optional Packages:
--with-PACKAGE[ ARG] use PACKAGE [ARG=yes] --with-PACKAGE[ ARG] use PACKAGE [ARG=yes]
--without-PACKAGE do not use PACKAGE (same as --with-PACKAGE no) --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE no)
--with-terminal [ptterm|xterm|gnome] --with-terminal [alacritty|gnome|st|xterm]
use ARG as terminal [ptterm] use ARG as terminal [alacritty]
--without-terminal do not use terminal at all --without-terminal do not use terminal at all
HELP HELP
exit exit
@ -116,17 +115,10 @@ while [ $# -gt 0 ]; do
usage usage
fi fi
;; ;;
ptterm) alacritty)
if [ "$with_terminal" = '' ]; then if [ "$with_terminal" = '' ]; then
with_terminal='ptterm' with_terminal='alacritty'
elif [ "$with_terminal" != 'ptterm' ]; then elif [ "$with_terminal" != 'alacritty' ]; then
usage
fi
;;
xterm)
if [ "$with_terminal" = '' ]; then
with_terminal='xterm'
elif [ "$with_terminal" != 'xterm' ]; then
usage usage
fi fi
;; ;;
@ -137,6 +129,20 @@ while [ $# -gt 0 ]; do
usage usage
fi fi
;; ;;
st)
if [ "$with_terminal" = '' ]; then
with_terminal='st'
elif [ "$with_terminal" != 'st' ]; then
usage
fi
;;
xterm)
if [ "$with_terminal" = '' ]; then
with_terminal='xterm'
elif [ "$with_terminal" != 'xterm' ]; then
usage
fi
;;
*) *)
do_shift='no' do_shift='no'
;; ;;
@ -171,7 +177,7 @@ if [ "$enable_xinerama" = '' ]; then
fi fi
if [ "$with_terminal" = '' -o "$with_terminal" = 'yes' ]; then if [ "$with_terminal" = '' -o "$with_terminal" = 'yes' ]; then
with_terminal='ptterm' with_terminal='alacritty'
fi fi
echo "PREFIX = $prefix" echo "PREFIX = $prefix"

View file

@ -62,8 +62,7 @@ Spawn
for launching other programs. for launching other programs.
.TP .TP
.B Mod1\-Shift\-/ .B Mod1\-Shift\-/
Start Start terminal.
.BR ptterm(1).
.TP .TP
.B Mod1\-, .B Mod1\-,
Focus previous screen, if any. Focus previous screen, if any.
@ -165,8 +164,7 @@ Resize focused window while dragging. Tiled windows will be toggled to the float
PolytreeWM is customized by creating a custom config.h and (re)compiling the PolytreeWM is customized by creating a custom config.h and (re)compiling the
source code. This keeps it fast, secure and simple. source code. This keeps it fast, secure and simple.
.SH SEE ALSO .SH SEE ALSO
.BR rofi (1), .BR rofi (1)
.BR ptterm (1)
.SH ISSUES .SH ISSUES
Java applications which use the XToolkit/XAWT backend may draw grey windows Java applications which use the XToolkit/XAWT backend may draw grey windows
only. The XToolkit/XAWT backend breaks ICCCM-compliance in recent JDK 1.5 and early only. The XToolkit/XAWT backend breaks ICCCM-compliance in recent JDK 1.5 and early

View file

@ -27,9 +27,9 @@ static const Rule rules[] = {
* WM_CLASS(STRING) = instance, class * WM_CLASS(STRING) = instance, class
* WM_NAME(STRING) = title * WM_NAME(STRING) = title
*/ */
/* class, instance, title, tags mask, isfloating, isterminal, noswallow, monitor */ /* class, instance, title, tags mask, isfloating, isterminal, noswallow, monitor */
{ "ptterm", NULL, NULL, 0, 0, 1, 0, -1 }, { "alacritty", NULL, NULL, 0, 0, 1, 0, -1 },
{ NULL, NULL, "Event Tester", 0, 0, 0, 1, -1 }, // xev { NULL, NULL, "Event Tester", 0, 0, 0, 1, -1 }, // xev
}; };
/* layout(s) */ /* layout(s) */

View file

@ -41,14 +41,17 @@ static struct Command commands[] = {
{ {
.name = "term", .name = "term",
.monitor_arg_index = 0, .monitor_arg_index = 0,
#ifdef WITH_TERMINAL_PTTERM #ifdef WITH_TERMINAL_ALACRITTY
.args = { "ptterm", NULL }, .args = { "alacritty", NULL },
#endif
#ifdef WITH_TERMINAL_XTERM
.args = { "xterm", NULL },
#endif #endif
#ifdef WITH_TERMINAL_GNOME #ifdef WITH_TERMINAL_GNOME
.args = { "gnome-terminal", "--wait", NULL }, .args = { "gnome-terminal", "--wait", NULL },
#endif
#ifdef WITH_TERMINAL_ST
.args = { "st", NULL },
#endif
#ifdef WITH_TERMINAL_XTERM
.args = { "xterm", NULL },
#endif #endif
}, },
#endif #endif