Can not start TWM

You have a problem with Salix? Post here and we'll do what we can to help.
Post Reply
PelleB
Posts: 70
Joined: 21. Sep 2010, 05:44

Can not start TWM

Post by PelleB »

For some reason TWM (and VTWM, CTWM) will not start, it seems that it can not load its fonts. I get the following in .xsession-errors

Code: Select all

/etc/gdm/Xsession: Beginning session setup...
xrdb: colon missing on line 371, ignoring line
/etc/gdm/Xsession: Setup done, will execute: /usr/bin/ssh-agent -- twm -f /home/pelle/.twmrc
twm:  unable to open fontset "-adobe-helvetica-bold-r-normal--*-120-*-*-*-*-*-*"
Changing font does not help, compiling TWM in stead of using the Salix package does not help. Reinstalling TWM does not change anything. The fontset is in place, TVTWM uses more or less the same configuration without any problem, and I have TWM running on a laptop with Salix without any problem. The font settings are from system.twmrc.

I can live without TWM, but I have a feeling that understanding this problem would be very useful.

Per B.
User avatar
gapan
Salix Wizard
Posts: 6236
Joined: 6. Jun 2009, 17:40

Re: Can not start TWM

Post by gapan »

What is your ~/.twmrc?
Image
Image
PelleB
Posts: 70
Joined: 21. Sep 2010, 05:44

Re: Can not start TWM

Post by PelleB »

Code: Select all

#NoDefaults
RandomPlacement
#SqueezeTitle
DontMoveOff
NoGrabServer
RestartPreviousState
DecorateTransients
ShowIconManager
UsePPosition "on"

TitleFont "-adobe-helvetica-bold-r-normal--*-120-*-*-*-*-*-*"
ResizeFont "-adobe-helvetica-bold-r-normal--*-120-*-*-*-*-*-*"
MenuFont "-adobe-helvetica-bold-r-normal--*-120-*-*-*-*-*-*"
IconFont "-adobe-helvetica-bold-r-normal--*-100-*-*-*-*-*-*"
IconManagerFont "-adobe-helvetica-bold-r-normal--*-100-*-*-*"

#ClientBorderWidth

# Manejo de iconos
#
IconRegion "500x200+500+570" South West 5 10
IconDirectory "/home/pelle/.xbm" 
ForceIcons
Icons
{
    "XTerm"	"terminal"
    "xfce4-terminal"	"terminal"
    "thunar"	"filing.cabinet.xbm"
    "Firefox"	"netscape.xbm"
    "Thunderbird" "mail.xbm"
    "Geany" "m_char_special.xbm"
    "Seamonkey" "seamonkey.xpm"
    "aterm"		"/usr/include/X11/bitmaps/terminal.xbm"
    "xterm"		"/usr/include/X11/bitmaps/monitor.xbm"
    "ROX-Filer"		"/usr/include/X11/bitmaps/folder.xbm"
    "Mousepad"		"/usr/include/X11/bitmaps/keyboard.xbm"
    "GQview"		"/usr/include/X11/bitmaps/eye_large.xbm"
}

AutoRaise
{
    "xclock"
    "mlclock"
}

NoTitle
{
    "mlclock" "xload" "pload" "stalonetray" "intclock" "rclock" "wmsmixer" "pyradio" "TWM Icon Manager" 
    "xmem" "xnetload"
    
    
}
IconManagerDontShow
{
    "Virtual Desktop"
    "xclock" "xload" "pload" "stalonetray" "wmsmixer" "xmem" "xnetload"
    "dclock"
    "rclock"
    "lmclock"
    "buici-clock"
    "dclock"
    "xload"
    "xnetload"
    "xbiff"
    "xeyes"
    "oclock"
    
    "wmnd"
    "wmnet"
}
Pixmaps
{
    TitleHighlight "hlines2"
}

Color
{
#    BorderColor "OliveDrab"
    BorderColor "Red"    
    DefaultBackground "green4"
    DefaultForeground "yellow2"
    TitleBackground "green3"
    TitleForeground "yellow2"
	MenuForeground "yellow2"
    MenuBackground "WebGreen"
    MenuTitleBackground "yellow2"
    MenuTitleForeground "ForestGreen"
    MenuShadowColor "DarkGreen"
    IconBackground "WebGreen"
    IconForeground "Gold2"
    IconBorderColor "OliveDrab"
    IconManagerBackground "DarkOrchid4" { "pyradio" "blue" "Terminal" "green" "xfce4-terminal" "Green3" "gslapt" "orange1" "sourcery"
    "orange1" } 
    IconManagerForeground "maroon1" { "pyradio" "yellow" "xfce4-terminal" "yellow" "gslapt" "black" "sourcery" "black"}
}

#
# Define some useful functions for motion-based actions.
#
MoveDelta 3
Function "move-or-lower" { f.move f.deltastop f.lower }
Function "move-or-raise" { f.move f.deltastop f.raise }
Function "move-or-iconify" { f.move f.deltastop f.iconify }

#
# Set some useful bindings.  Sort of uwm-ish, sort of simple-button-ish
#
Button1 = : root : f.menu "defops"
Button2 = : root : f.menu "TwmWindows"
Button3 = : root : f.menu "meny"

Button1 = m : window|icon : f.function "move-or-lower"
Button2 = m : window|icon : f.iconify
Button3 = m : window|icon : f.function "move-or-raise"

Button1 = : title : f.function "move-or-raise"
Button2 = : title : f.raiselower

Button1 = : icon : f.function "move-or-iconify"
Button2 = : icon : f.iconify

Button1 = : iconmgr : f.raise
Button2 = : iconmgr : f.iconify
Button3 = : iconmgr : f.lower

"F1"    =      : window : f.raise
"F1"    =      : title  : f.raise

"F2"    =      : window : f.lower
"F2"    =      : title  : f.lower

"F3"    =      : window : f.showiconmgr
"F3"    =      : title  : f.showiconmgr

"F4"    =      : window : f.hideiconmgr
"F4"    =      : title  : f.hideiconmgr

# This is for the window bar
RightTitleButton  "/home/pelle/.xbm/gclose.xbm"  = f.delete
RightTitleButton "/home/pelle/.xbm/gresize.xbm" = f.raiselower

#RightTitleButton "/usr/X11R6/include/X11/bitmaps/tamanio.xbm" = f.resize
#RightTitleButton "/usr/X11/include/bitmaps/menu12"  = f.resize

#
# And a menus with the usual things
#
menu "defops"
{
"TWM"			f.title
"Iconify"		f.iconify
"Resize"	f.resize
"Move"			f.move
"Raise"		f.raise
"Lower"			f.lower
""			f.nop
#"Foco"			f.focus
#"Quitar Foco"		f.unfocus
"Showiconmgr"		f.showiconmgr
"Hideiconmgr"	f.hideiconmgr

"Meny"		f.menu "meny"

""			f.nop
"Destroy"		f.destroy
"Delete"		f.delete
""			f.nop
"Restart"		f.restart
"Quit"			f.quit
}

menu "meny"
{
"Meny"			f.title
"Terminal"	f.exec"xfce4-terminal &"
    "FBrun"	f.exec "fbrun &"
    "TkRunIt" f.exec "tkRunIt &"
    "DPMS off" f.exec "xset s off -dpms"
    "Geany" f.exec "geany &"
    "Thunar" f.exec "thunar &"
    "XTerm"	f.exec "xterm &"
    "PL"	f.exec "setxkbmap pl -variant qwertz"
    "SE"	f.exec "setxkbmap se"
    "Start"	f.exec "/home/pelle/twmstart.sh"
    
"Internet"		f.menu "internet"
"Bild"		f.menu "bild"
"Multimedia"		f.menu "multimedia"
"Text"	f.menu "text"
"Apps"	f.menu "app"
"Program"	f.menu "program"
"Spel"	f.menu "spel"
"System"	f.menu "system"
""			f.nop
}
menu "text"
{
"Text"	f.title
"Mousepad"		f.exec "mousepad &"
"Geany"			f.exec "geany &"
"Xed"		f.exec "xed &"
""			f.nop
"Nedit"			f.exec "nedit &"
"Bluefish"		f.exec "bluefish &"
"Gloe"			f.exec "gloe &"
"GTKEdit"		f.exec "gtkedit &"
}

menu "multimedia"
{
"Multimedia"		f.title
"Audacious"		f.exec "audacious &"
"Decibel"		f.exec "decibel-audio-player &"
"Xine"		f.exec "xine &"
"Xmix"		f.exec "xmix &"
"Xmixer"		f.exec "xmixer &"
"Xmix"		f.exec "xmix &"
}

menu "bild"
{
"Bild"		f.title
"GIMP"		f.exec "gimp &"
"Mirage"		f.exec "mirage &"
"XBMBrowser"		f.exec "xbmbrowser &"
}

menu "internet"
{
"Internet"		f.title
"Firefox"			f.exec "firefox &"
#"Seamonkey Mail"		f.exec "seamonkey -mail &"
#"Pidgin"		f.exec "pidgin &"
"Filezilla"			f.exec "filezilla &"
#"Pyradio"	f.exec "xvt +sb -e pyradio &"
"Soma"	f.exec "xfce4-terminal -e soma &"
}

menu "app"
{
"Apps"	f.title
#"XColorsel"		f.exec "xcolorsel &"
"Xcalc"		f.exec "xcalc &"
"Xman"		f.exec "xman &"
"Pychrom"      f.exec "pychrom -c /usr/share/X11/rgb.txt &"
"Unibrow"      f.exec "unibrow &'"
""			f.nop
"PyStopWatch"			f.exec "pystopwatch &"
"Bluefish"		f.exec "bluefish &"
"Gloe"			f.exec "gloe &"
"GTKEdit"		f.exec "gtkedit &"
}
menu "program"
{
"Program"	f.title
"AFT"		f.exec "android-file-transfer &"
"Xcalc"		f.exec "xcalc &"
"Xman"		f.exec "xman &"
"Gonvert"      f.exec "gonvert &"
"XMDiary"		f.exec "xdiary &"
"XMAddressbook"      f.exec "xmaddressbook &'"
}

menu "system"
{
"System"		f.title
"Gslapt"	f.exec "gksu gslapt &"
"Sourcery"	f.exec "gksu sourcery &"
"ThunarSU"		f.exec "gksu thunar &"
#"MountUSB1"		f.exec "mount_msdosfs /dev/da4s1 /usr/home/pelle/mnt"
#"UmountUSB1"		f.exec "umount /dev/da4s1"
}

#Atajos de teclado
"x"	=	mod3 : root : f.exec "xfrun4 &"
"a"	=	mod3 : root : f.exec "aterm &"
I tried using system.twmrc too, and tried starting TWM in different ways (xinitrc.twm, and just twm ). It woks fine on the laptop with the same verion of Salix (64-bit 14.2)
User avatar
gapan
Salix Wizard
Posts: 6236
Joined: 6. Jun 2009, 17:40

Re: Can not start TWM

Post by gapan »

You're missing some of those adobe fonts. Either remove the font lines from your .twmrc, or install the fonts. They're probably in the font-adobe-100dpi package.
Image
Image
PelleB
Posts: 70
Joined: 21. Sep 2010, 05:44

Re: Can not start TWM

Post by PelleB »

I have font-adobe-100dpi and font-adobe-75dpi 1.0.3-noarch-1 installed, I have tried removing the font settings and tried a different font, changing size etc., the result is the same. TVTWM and MWM use the same font, no problem.
User avatar
gapan
Salix Wizard
Posts: 6236
Joined: 6. Jun 2009, 17:40

Re: Can not start TWM

Post by gapan »

Try using these fonts:

Code: Select all

TitleFont "-misc-dejavu sans-medium-r-normal--0-100-*-*-*-*-iso0646-1"
ResizeFont "-misc-dejavu sans-medium-r-normal--0-100-*-*-*-*-iso0646-1"
MenuFont "-misc-dejavu sans-medium-r-normal--0-100-*-*-*-*-iso0646-1"
IconFont "-misc-dejavu sans-medium-r-normal--0-100-*-*-*-*-iso0646-1"
IconManagerFont "-misc-dejavu sans-medium-r-normal--0-100-*-*-*-*-iso0646-1"
You should have the dejavu-fonts-ttf package already installed.
Image
Image
PelleB
Posts: 70
Joined: 21. Sep 2010, 05:44

Re: Can not start TWM

Post by PelleB »

Well, it made a difference

Code: Select all

/etc/gdm/Xsession: Beginning session setup...
xrdb: colon missing on line 371, ignoring line
/etc/gdm/Xsession: Setup done, will execute: /usr/bin/ssh-agent -- twm -f /home/pelle/.twmrc
twm:  unable to open fontset "fixed"
twm: warning: font for charset JISX0208.1983-0 is lacking.
twm: warning: font for charset KSC5601.1987-0 is lacking.
twm: warning: font for charset JISX0208.1983-0 is lacking.
twm: warning: font for charset KSC5601.1987-0 is lacking.
twm: warning: font for charset JISX0208.1983-0 is lacking.
twm: warning: font for charset KSC5601.1987-0 is lacking.
twm: warning: font for charset JISX0208.1983-0 is lacking.
twm: warning: font for charset KSC5601.1987-0 is lacking.
twm: warning: font for charset JISX0208.1983-0 is lacking.
twm: warning: font for charset KSC5601.1987-0 is lacking.
I removed some of the preinstalled fonts (but not Dejavu) for some Asian languages that I do not know, could that be the problem?

Edit: Yes, it was. I installed sinhala_lklug-font-ttf and tibmachuni-font-ttf and am now using TWM.

Thanks for helping me, it did guide me to the solution even though I do not understand why I need a Tibetan font to use Helvetica.
User avatar
Luffy
Posts: 42
Joined: 3. Jul 2017, 22:03

Re: Can not start TWM

Post by Luffy »

Wiki:
"You might find that titlebars and menu entries in TWM are extremely large - twice the size that one might typically expect. This is a locale issue with TWM that occurs when a UTF-8 locale is used. Setting the locale to C fixes the issue. See [2]."

I use Terminus font: "-xos4-terminus-medium-r-normal-*-*-120-*-*-c-*-paratype-pt154"

Regards
PelleB
Posts: 70
Joined: 21. Sep 2010, 05:44

Re: Can not start TWM

Post by PelleB »

Thanks!

That probably also explains why I need the Tibetan machine font installed to use Helvetica too. However I will leave the locale as it is and TWM looking a bit like Windows10 as I do not know what effect a change would have on other applications.

Terminus is one of my preferred choices.
Post Reply