Discussion:
Changing font size in trminal emulator
(too old to reply)
James H. Markowitz
2020-07-20 21:19:53 UTC
Permalink
No strictly a Slackware question, but somebody in this forum
might know the answer.

I am using Slackware 14.2 with Xfce. In this environment, the
terminal emulator that I use is xfce4-terminal, part of Xfce.

If I want to change the font used in this terminal emulator, I
just have to do Preferences -> Appearance in the xfce4-terminal menu, and
changing the font size as needed.

The problem with this is that, after doing this, the font size is
changed in every xfce4-terminal that I may have. While this is probably
appropriate in many circumstances, it is not in mine.

Anybody know whether it is possible to change the size of the
terminal font in a single, specific xfce4-terminal alone?

I would be willing to use other terminal emulator if that is not
possible with xfce4-terminal, provided that they have similar
capabilities. For instance, xterm (and variations) can do what I want,
but I have been unable to get them to display UTF8 characters properly -
which xfce4-terminal does without any problems.
Rich
2020-07-20 21:40:59 UTC
Permalink
Post by James H. Markowitz
If I want to change the font used in this terminal emulator, I
just have to do Preferences -> Appearance in the xfce4-terminal menu, and
changing the font size as needed.
The problem with this is that, after doing this, the font size is
changed in every xfce4-terminal that I may have. While this is probably
appropriate in many circumstances, it is not in mine.
Anybody know whether it is possible to change the size of the
terminal font in a single, specific xfce4-terminal alone?
Check the documentation for the terminal emulator to see if it takes
command line parameters to specify a font for a particular launched
instance.
Post by James H. Markowitz
I would be willing to use other terminal emulator if that is
not possible with xfce4-terminal, provided that they have similar
capabilities. For instance, xterm (and variations) can do what I
want, but I have been unable to get them to display UTF8 characters
properly - which xfce4-terminal does without any problems.
For xterm, you have to start them with some extra CLI switches to
enable UTF-8 and you need to tell it to use a font with all the
characters you expect to encounter.

It also helps to setup the LC and LANG environment variables to be
UTF-8 (if none of this is setup by default to start with).

I use this little script to launch a UTF-8 xterm for those instances I
want to do something in a terminal that needs UTF-8:

#!/bin/bash

FONT="-misc-fixed-medium-r-normal-*-20-200-75-75-c-100-iso10646-1"

export LC_ALL=en_US.UTF-8
export LANG=en_US.UTF-8
export LANGUAGE=en_US.UTF-8

exec xterm -ls -en UTF-8 -font "$FONT" -title "utf-8 xterm" "$@"

The magic part of the font spec is the iso10646 part, that's the
encoding spec that means "works with UTF-8". You can find font strings
via "xfontsel". Note that xfontsel normally prefers bitmapped fonts,
you have to add "-scaled" when launching it to use scalable fonts.
Javier
2020-07-21 23:38:24 UTC
Permalink
Post by Rich
Post by James H. Markowitz
If I want to change the font used in this terminal emulator, I
just have to do Preferences -> Appearance in the xfce4-terminal menu, and
changing the font size as needed.
The problem with this is that, after doing this, the font size is
changed in every xfce4-terminal that I may have. While this is probably
appropriate in many circumstances, it is not in mine.
Anybody know whether it is possible to change the size of the
terminal font in a single, specific xfce4-terminal alone?
Check the documentation for the terminal emulator to see if it takes
command line parameters to specify a font for a particular launched
instance.
Post by James H. Markowitz
I would be willing to use other terminal emulator if that is
not possible with xfce4-terminal, provided that they have similar
capabilities. For instance, xterm (and variations) can do what I
want, but I have been unable to get them to display UTF8 characters
properly - which xfce4-terminal does without any problems.
For xterm, you have to start them with some extra CLI switches to
enable UTF-8 and you need to tell it to use a font with all the
characters you expect to encounter.
It also helps to setup the LC and LANG environment variables to be
UTF-8 (if none of this is setup by default to start with).
I use this little script to launch a UTF-8 xterm for those instances I
#!/bin/bash
FONT="-misc-fixed-medium-r-normal-*-20-200-75-75-c-100-iso10646-1"
export LC_ALL=en_US.UTF-8
export LANG=en_US.UTF-8
export LANGUAGE=en_US.UTF-8
The magic part of the font spec is the iso10646 part, that's the
encoding spec that means "works with UTF-8". You can find font strings
via "xfontsel". Note that xfontsel normally prefers bitmapped fonts,
you have to add "-scaled" when launching it to use scalable fonts.
A good selection of fonts can be seen in /usr/share/X11/app-defaults/UXTerm

It defines 6 fonts that can be changed with Shift-Keypad+/Keypad-
or with the xterm 3rd menu: Ctrl + Right mouse button (xterm menus
are accessed with Ctrl + Mouse buttons so they don't waste screen space).
Defining the xdefaults you add your favourite fonts, but there is
a limit of 6.

For high dpi screens I use big fonts from the terminus package:

uxterm -font -xos4-terminus-bold-r-normal--28-280-72-72-c-140-iso10646-1
uxterm -font -xos4-terminus-bold-r-normal--32-320-72-72-c-160-iso10646-1

PS: if you want to use emacs -nw inside xterm remember to set Meta-Sends-scape.
Jimmy Johnson
2020-07-21 09:52:46 UTC
Permalink
Post by James H. Markowitz
No strictly a Slackware question, but somebody in this forum
might know the answer.
I am using Slackware 14.2 with Xfce. In this environment, the
terminal emulator that I use is xfce4-terminal, part of Xfce.
If I want to change the font used in this terminal emulator, I
just have to do Preferences -> Appearance in the xfce4-terminal menu, and
changing the font size as needed.
The problem with this is that, after doing this, the font size is
changed in every xfce4-terminal that I may have. While this is probably
appropriate in many circumstances, it is not in mine.
Anybody know whether it is possible to change the size of the
terminal font in a single, specific xfce4-terminal alone?
I'm a kde user and it seems your settings are probably the same as
konsole, there I can save the default profile to a different name in the
general tab and switch to any saved profile in menu, settings.
--
Jimmy Johnson

Slackware Current KDE5 - AMD A8-7600 - EXT4 at sda8
Registered Linux User #380263
Poprocks
2020-07-21 17:36:10 UTC
Permalink
Post by James H. Markowitz
No strictly a Slackware question, but somebody in this forum
might know the answer.
I am using Slackware 14.2 with Xfce. In this environment, the
terminal emulator that I use is xfce4-terminal, part of Xfce.
If I want to change the font used in this terminal emulator, I
just have to do Preferences -> Appearance in the xfce4-terminal menu, and
changing the font size as needed.
The problem with this is that, after doing this, the font size is
changed in every xfce4-terminal that I may have. While this is probably
appropriate in many circumstances, it is not in mine.
Anybody know whether it is possible to change the size of the
terminal font in a single, specific xfce4-terminal alone?
In xfce4-terminal, unlike some other terminal emulators for X, you can't
have multiple profiles as far as I'm aware.

However, you can override the default font face and size by using the
--font option. Be sure to use the Xft nomenclature; the legacy X11
bitmap font nomenclature is not supported. For example:

xfce4-terminal --font 'terminus 18'

This will run xfce4-terminal with terminus font size 18, but if you run
xfce4-terminal again without arguments, the terminal with launch with
the default font as defined in the settings.
Post by James H. Markowitz
I would be willing to use other terminal emulator if that is not
possible with xfce4-terminal, provided that they have similar
capabilities. For instance, xterm (and variations) can do what I want,
but I have been unable to get them to display UTF8 characters properly -
which xfce4-terminal does without any problems.
To avoid this issue, you should make sure you are running a terminal
with utf8 support, such as urxvt or uxterm.
King Beowulf
2020-07-23 15:34:43 UTC
Permalink
Post by James H. Markowitz
Anybody know whether it is possible to change the size of the
terminal font in a single, specific xfce4-terminal alone?
Select the xfce4-terminal window you need to reduce the font size in,
then press

CTRL -

to reduce the size,

CTRL +

to increase the size. Other open terminals will not be effected and the
font size will be reset when you close and reopen.
James H. Markowitz
2020-07-23 16:00:26 UTC
Permalink
Post by King Beowulf
Post by James H. Markowitz
Anybody know whether it is possible to change the size of the
terminal font in a single, specific xfce4-terminal alone?
Select the xfce4-terminal window you need to reduce the font size in,
then press
CTRL -
to reduce the size,
CTRL +
to increase the size. Other open terminals will not be effected and the
font size will be reset when you close and reopen.
That does not work for me - those keystrokes do nothing.
Javier
2020-07-23 17:33:45 UTC
Permalink
Post by James H. Markowitz
Post by King Beowulf
CTRL -
to reduce the size,
CTRL +
to increase the size. Other open terminals will not be effected and the
font size will be reset when you close and reopen.
That does not work for me - those keystrokes do nothing.
For xfce4-terminal it's Ctrl-+, Ctrl-- in the main keyboard, not on
the numeric keypad. Should work, at least on a US keyboard.

For xterm the keys are Shift-+, Shift-- on the numeric keypad.
Henrik Carlqvist
2020-07-24 09:51:41 UTC
Permalink
Post by James H. Markowitz
Post by King Beowulf
CTRL -
to reduce the size,
CTRL +
to increase the size. Other open terminals will not be effected and
the font size will be reset when you close and reopen.
That does not work for me - those keystrokes do nothing.
For xfce4-terminal it's Ctrl-+, Ctrl-- in the main keyboard, not on the
numeric keypad. Should work, at least on a US keyboard.
For xterm the keys are Shift-+, Shift-- on the numeric keypad.
I can confirm that ctrl-+ or ctrl-- does not work with xfce terminal
version 0.6.3 in Slackware 14.2. However it does work fine with the
Konsole terminal emulator. Numerical ctrl-+ does nothing in xfce
terminal, non-numerical ctrl-+ gives a + in the terminal, at least with
swedish keyboard layout.

regards Henrik
Javier
2020-07-24 11:41:35 UTC
Permalink
Post by Henrik Carlqvist
Post by James H. Markowitz
Post by King Beowulf
CTRL -
to reduce the size,
CTRL +
to increase the size. Other open terminals will not be effected and
the font size will be reset when you close and reopen.
That does not work for me - those keystrokes do nothing.
For xfce4-terminal it's Ctrl-+, Ctrl-- in the main keyboard, not on the
numeric keypad. Should work, at least on a US keyboard.
For xterm the keys are Shift-+, Shift-- on the numeric keypad.
I can confirm that ctrl-+ or ctrl-- does not work with xfce terminal
version 0.6.3 in Slackware 14.2. However it does work fine with the
Konsole terminal emulator. Numerical ctrl-+ does nothing in xfce
terminal, non-numerical ctrl-+ gives a + in the terminal, at least with
swedish keyboard layout.
regards Henrik
It works in later versions. I'm using xfce4-terminal 0.8.7.4 (Xfce 4.12).

It's written in the ChangeLog:

https://archive.xfce.org/src/apps/xfce4-terminal/0.8/xfce4-terminal-0.8.7.tar.bz2

They added the change in July 2016, just a few weeks after Slackware 14.2
was released.


commit 77194638860b9ddfe14e11bcad3fa9b66f840d8f
Author: Igor <***@yandex.ru>
Date: Mon Jul 25 17:37:01 2016 +0300

Add ability to zoom in/out by pressing Ctrl +/-

Patch provided by a Debian user and adopted by Alexander Butenko:
https://bugzilla.xfce.org/show_bug.cgi?id=5605
James H. Markowitz
2020-07-24 15:06:48 UTC
Permalink
Post by Javier
Post by Henrik Carlqvist
Post by Javier
Post by James H. Markowitz
Post by King Beowulf
CTRL -
to reduce the size,
CTRL +
to increase the size. Other open terminals will not be effected and
the font size will be reset when you close and reopen.
That does not work for me - those keystrokes do nothing.
For xfce4-terminal it's Ctrl-+, Ctrl-- in the main keyboard, not on
the numeric keypad. Should work, at least on a US keyboard.
For xterm the keys are Shift-+, Shift-- on the numeric keypad.
I can confirm that ctrl-+ or ctrl-- does not work with xfce terminal
version 0.6.3 in Slackware 14.2. However it does work fine with the
Konsole terminal emulator. Numerical ctrl-+ does nothing in xfce
terminal, non-numerical ctrl-+ gives a + in the terminal, at least with
swedish keyboard layout.
regards Henrik
It works in later versions. I'm using xfce4-terminal 0.8.7.4 (Xfce 4.12).
https://archive.xfce.org/src/apps/xfce4-terminal/0.8/xfce4-
terminal-0.8.7.tar.bz2
Post by Javier
They added the change in July 2016, just a few weeks after Slackware
14.2 was released.
commit 77194638860b9ddfe14e11bcad3fa9b66f840d8f Author: Igor
Date: Mon Jul 25 17:37:01 2016 +0300
Add ability to zoom in/out by pressing Ctrl +/-
https://bugzilla.xfce.org/show_bug.cgi?id=5605
Can this be built for 14.2 without having to take the system
apart? I had a quick go and got scared when the build process complained
about gtk+ (I think) being too old.
Javier
2020-07-24 16:50:54 UTC
Permalink
Post by James H. Markowitz
Can this be built for 14.2 without having to take the system
apart? I had a quick go and got scared when the build process complained
about gtk+ (I think) being too old.
If you have problems with gtk libraries pick an older version:

0.6.92 is from September 2016, but has already added the Ctrl +/- keybinding.

https://archive.xfce.org/src/apps/xfce4-terminal/0.6/xfce4-terminal-0.6.92.tar.bz2

The last one is from December 2019, but might not build in Slack 14.2.

https://archive.xfce.org/src/apps/xfce4-terminal/0.8/xfce4-terminal-0.8.9.tar.bz2

Just try installing it under /usr/local or some other custom directory
to avoid clashing with softaware installed by Slackware.
You might need to redefine the desktop menus.

cd $(mktemp -d)
wget https://archive.xfce.org/src/apps/xfce4-terminal/0.6/xfce4-terminal-0.6.92.tar.bz2
tar xjf xfce4-terminal-0.6.92.tar.bz2
cd xfce4-terminal-0.6.92
./configure --prefix=/usr/local/
make
sudo make install


export $PATH=/usr/local/bin:${PATH}
xfce4-terminal

If it doesn't work just delete it
rm /usr/local/bin/xfce4-terminal
Clark Smith
2020-07-24 19:12:27 UTC
Permalink
Post by Javier
Post by James H. Markowitz
Can this be built for 14.2 without having to take the system
apart? I had a quick go and got scared when the build process
complained about gtk+ (I think) being too old.
0.6.92 is from September 2016, but has already added the Ctrl +/- keybinding.
https://archive.xfce.org/src/apps/xfce4-terminal/0.6/xfce4-
terminal-0.6.92.tar.bz2
Post by Javier
The last one is from December 2019, but might not build in Slack 14.2.
https://archive.xfce.org/src/apps/xfce4-terminal/0.8/xfce4-
terminal-0.8.9.tar.bz2
Post by Javier
Just try installing it under /usr/local or some other custom directory
to avoid clashing with softaware installed by Slackware.
You might need to redefine the desktop menus.
cd $(mktemp -d)
wget
https://archive.xfce.org/src/apps/xfce4-terminal/0.6/xfce4-
terminal-0.6.92.tar.bz2
Post by Javier
tar xjf xfce4-terminal-0.6.92.tar.bz2 cd xfce4-terminal-0.6.92
./configure --prefix=/usr/local/
make sudo make install
export $PATH=/usr/local/bin:${PATH}
xfce4-terminal
If it doesn't work just delete it rm /usr/local/bin/xfce4-terminal
Not much luck with 0.6.92 either. It does build, but it does not
run:

$ xfce4-terminal
xfce4-terminal: error while loading shared libraries:
libvte-2.91.so.0: cannot open shared object file: No such file or
directory

I guess I'll wait for the next release of Slackware.
Henrik Carlqvist
2020-07-24 20:34:02 UTC
Permalink
Post by Clark Smith
I guess I'll wait for the next release of Slackware.
Or pick another terminal emulator. Would Konsole work better for you? I
prefer xterm myself but usually use iso-8859-1 encoding instead of utf8.

regards Henrik
Javier
2020-07-24 21:17:02 UTC
Permalink
Post by Clark Smith
Not much luck with 0.6.92 either. It does build, but it does not
$ xfce4-terminal
libvte-2.91.so.0: cannot open shared object file: No such file or
directory
That file is in the vte library.

https://gitlab.gnome.org/GNOME/vte

But don't attemp to build that yourself on Slackware. It has too many
dependences.

As Henrik said, the best is to use konsole or uxterm.
James H. Markowitz
2020-07-24 21:38:49 UTC
Permalink
Post by Javier
Post by Clark Smith
Not much luck with 0.6.92 either. It does build, but it does not
$ xfce4-terminal xfce4-terminal: error while loading shared
libraries: libvte-2.91.so.0: cannot open shared object file: No
such file or directory
That file is in the vte library.
https://gitlab.gnome.org/GNOME/vte
But don't attemp to build that yourself on Slackware. It has too many
dependences.
As Henrik said, the best is to use konsole or uxterm.
Thanks. As it happens, in a roundabout way I can get xfce4-
terminal to do what I want in this respect, by means of the following
script:

#! /bin/sh

GENERIC_CONF=$HOME/.config/xfce4/terminal/terminalrc
CONF_ROOT=$HOME/.term-config
CONF_DIR=`mktemp -d $CONF_ROOT/config.XXXXXX`
mkdir -p $CONF_DIR/xfce4/terminal
cp -p $GENERIC_CONF $CONF_DIR/xfce4/terminal
env XDG_CONFIG_HOME=$CONF_DIR xfce4-terminal --disable-server
rm -rf $CONF_DIR

It's a hack all right, but it will do until the next Slackware.

notbob
2020-07-23 16:35:56 UTC
Permalink
font size will be reset [go back to normal] when you....
....hit CTRL 0

nb
Loading...