You are not logged in.
Hey, I'm using xurvt with bspwm and when connecting with VNC I'd like to remove any transparency/tint effect.
My VNC config is separated and it works, but problem now is I can't manage to get rid of the bluish filter that will occur on inactive windows, which slow down the connection when switching windows. Could anybody help?
Here's my .Xdefaults_bspwm_vnc file:
! Configure urxvt terminal
!
utxvt*termName: rxvt-unicode
urxvt*depth: 24
urxvt*transparent: false
urxvt*background: rgb:0000/0000/0000
urxvt*foreground: gray
! urxvt*fading: 0
! urxvt*fadeColor: cyan
! urxvt*tintColor: none
! urxvt*shading: 100
! rxvt next xterm (plain?)
urxvt*scrollstyle: next
urxvt*secondaryScroll: false
Xft.antialias: false
urxvt*loginShell: false
urxvt*meta: ignore
urxvt*utmpInhibit: true
urxvt*saveLines: 5120
urxvt*mapAlert: true
urxvt*visualBell: false
urxvt*pastableTabs: true
urxvt*urlLauncher: firefox
urxvt*font: xft:Terminus:pixelsize=15
urxvt*boldFont: xft:Terminus bold:pixelsize=15
urxvt*italicFont: xft:Terminus:pixelsize=15:autohint=true
urxvt*boldItalicFont: xft:Terminus bold:pixelsize=15:autohint=true
urxvt*externalBorder: 70
urxvt*internalBorder: 5
urxvt*linespace: 5
urxvt*colorBD: 1
urxvt*colorUL: 2
urxvt*jumpScroll: true
urxvt*scrollBar: false
urxvt*scrollBar_right: false
urxvt*scrollBar_floating:false
urxvt*color0: #000000
urxvt*color1: #dc74d1
urxvt*color2: #0eb8c7
urxvt*color3: #dfe37e
urxvt*color4: #7777cc
urxvt*color5: #9e88f0
urxvt*color6: #73f7ff
urxvt*color7: #e1dddd
urxvt*color8: #8b8f93
urxvt*color9: #dc74d1
urxvt*color10: #0eb8c7
urxvt*color11: #dfe37e
urxvt*color12: #4444ff
urxvt*color13: #9e88f0
urxvt*color14: #73f7ff
urxvt*color15: #e1dddd
The .config/bspwm/bspwmrc_vnc file:
#! /bin/sh
trap 'trap - TERM; kill 0' INT TERM QUIT EXIT
bspc config border_width 1
bspc config window_gap 3
bspc config split_ratio 0.50
bspc config borderless_monocle true
bspc config gapless_monocle true
#bspc config normal_border_color "#3E3D31"
#bspc config active_border_color "#5e5d51"
bspc config focused_border_color "#333355"
#bspc config urgent_border_color "#FC5C94"
#bspc config presel_border_color "#FE87F4"
bspc monitor -d I II III IV V VI VII VIII IX X
bspc rule -a Gimp desktop=^8 follow=on floating=on
bspc rule -a Chromium desktop=^2
bspc rule -a mplayer2 floating=on
bspc rule -a Kupfer.py focus=on
bspc rule -a Screenkey manage=off
Last edited by 82Emugel (2014-12-21 06:14:41)
Offline
Try removing the "depth: 24" option.
-depth bitdepth
Compile frills: Attempt to find a visual with the given bit depth; resource depth.[Please note that many X servers (and libXft) are buggy with respect to "-depth 32"
and/or alpha channels, and will cause all sorts of graphical corruption. This is
harmless, but we can't do anything about this, so watch out]
Offline
Did
! urxvt*depth: 24
and same.
But, I just discovered my main .Xdefaults file with the non-vnc xurvt settings was used as well (I renamed it and now my urxvt is white). So problem is not in the file I posted.
My file ~/.xinitrc_bspwm_vnc looks like:
#!/bin/sh
xset b
xset +fp /usr/share/fonts/local
xset fp rehash
xset r rate 300 6
xrdb -merge ~/.Xdefaults.bspwm_vnc &
xsetroot -cursor_name left_ptr &
xsetroot -solid "#000044"
sxhkd -c ~/.config/sxhkd/sxhkdrc_vnc &
exec /usr/local/bin/bspwm -c ~/.config/bspwm/bspwmrc_vnc
And this one is called by ~/.vnc/xinitrc when $DISPLAY is set to ":2":
#!/bin/sh
# $XConsortium: xinitrc.cpp,v 1.4 91/08/22 11:41:34 rws Exp $
userresources=$HOME/.Xresources
usermodmap=$HOME/.Xmodmap
sysresources=/etc/X11/xinit/.Xresources
sysmodmap=/etc/X11/xinit/.Xmodmap
# merge in defaults and keymaps
if [ -f $sysresources ]; then
xrdb -merge $sysresources
fi
if [ -f $sysmodmap ]; then
xmodmap $sysmodmap
fi
if [ -f $userresources ]; then
xrdb -merge $userresources
fi
if [ -f $usermodmap ]; then
xmodmap $usermodmap
fi
case $DISPLAY in
":1" ) echo "Running /etc/X11/xinit/xinitrc.wmaker" ; /etc/X11/xinit/xinitrc.wmaker ;;
":2" ) echo "Running .xinitrc_bspwm_vnc" ; ~/.xinitrc_bspwm_vnc ;;
":0" ) ;;
* ) echo "Please configure $0 for DISPLAY $DISPLAY"; exit ;;
esac
echo Done
The file ~/.Xresources doesn't exist.
So why would .Xdefaults be used instead of .Xdefaults_bspwm_vnc?
The string "Running .xinitrc_bspwm_vnc" appears in .vnc/$HOSTNAME:2.log so the ~/.xinitrc_bspwm_vnc is likely called, and it's called anyway since that's the file that lauches bspwm and I can connect with VNC.
Last edited by 82Emugel (2014-12-20 21:02:13)
Offline
I'm lost sorry, I don't even use VNC...
EDIT: .Xdefaults is sourced automatically by rxvt-unicode on startup -- see man urxvt
Last edited by Head_on_a_Stick (2014-12-20 21:02:24)
Offline
Oh, that would explain a lot. So I probably need to disable one by one the things declared in .Xdefaults related to transparency.
I'll try tomorrow and post whatever happened. Thanks!
Hum, let's hope it doesn't read that file after I set the defaults.
Last edited by 82Emugel (2014-12-20 21:07:01)
Offline
Even after I removed my .Xdefaults, this line seems without effect:
xrdb -merge ~/.Xdefaults.bspwm_vnc &
The ~/.Xdefaults.bspwm_vnc is declaring a black background:
urxvt*transparent: false
urxvt*background: #000000
urxvt*foreground: gray
But the urxvt windows appear unaffected, with a white background.
Offline
From your ~/.vnc/xinitrc:
[...]
sysresources=/etc/X11/xinit/.Xresources
[...]
if [ -f $sysresources ]; then
xrdb -merge $sysresources
fi
What is in /etc/X11/xinit/.Xresources?
Offline
It doesn't exist.
From xrdb documentation, I noticed that xrdb must be defined for a specific DISPLAY, so I tried
xrdb -display :2 -merge ~/.Xdefaults.bspwm_vnc &
Along with other variations such as localhost:2, `hostname`:2 and so on, but it still doesn't work (white background)
Last edited by 82Emugel (2014-12-20 21:48:28)
Offline
I really don't have any more ideas, sorry.
Offline
Better wait if someone had the same problem, thanks for the help so far
Offline
Hum... something new, whenever I do xrdb -display :2 -load ~/.Xdefaults.old &
the terminals appear with a black background. Likely something wrong in my .Xdefaults.bspwm_vnc
Offline
Hum now it works.
I think it needed the -display :2, and get my color files correct.
So, xrdb -display :2 -load ~/.Xdefaults.bspwm_vnc -merge SOME_COLOR_THEME_FILE &
However, when my .Xdefaults.old gets renamed to .Xdefaults, it gets parsed again and the transparency comes back. So I really don't understand the point of xrdb in that case…
Edit: maybe this may help:
~/.Xdefaults is the older method of storing X resources. This file is re-read every time an Xlib program is started. If X11 is used over the network, the file must be present on the same filesystem as the programs.~/.Xresources is newer. It is loaded with xrdb into the RESOURCE_MANAGER property of the X11 root window. Whenever any program looks up a resource, it is read straight from RESOURCE_MANAGER.If this property does not exist, Xlib falls back to the old method of reading .Xdefaults on every program startup. Note that most distributions will load ~/.Xresources automatically if it is present, causing .Xdefaults to be ignored even if you have never run xrdb manually.The advantage of the new method is that it's enough to call xrdb once, and the resources will be available to any program running on this display, whether local or remote. (The name ~/.Xresources is only a convention – you can use xrdb to load any file, even .Xdefaults.)
Last edited by 82Emugel (2014-12-20 22:11:35)
Offline
For urxvt, if .Xdefaults exists then .Xdefaults will override any settings made in .Xresources. Each new instance of urxvt will re-read .Xdefaults.
However. if .Xdefaults does not exist then a new urxvt instance will go with what has been set in the X server resource database.
See man urxvt for the order in which resource files are read, at the top of the section labeled, oddly, 'RESOURCES'. The last read resource file overwrites any settings made by any previously read file.
I got rid of my ~/.Xdefaults several years ago, after similar confusion about where resources should be set and the order in which they are read. I now keep my urxvt settings in a separate file, .urxvt. I call that file into my ~/.Xresources file using an include statement:
# include ".urxvt"
Offline
Thanks thisoldman,
I got it to work by not even defining an .Xresources file, but instead xrdbing either .Xresources.bspwm, .Xresources.wmaker or .Xresources.bspwm_vnc from whichever xinitrc file that would get called.
Eg in my aforementioned ~/.xinitrc.bspwm_vnc, and making sure there exist neither a .Xdefaults nor a .Xresources file:
xrdb -load ~/.Xresources.bspwm_vnc -merge ~/.config/COLORTHEMES/current &
Problem solved
Last edited by 82Emugel (2014-12-21 06:16:06)
Offline