summaryrefslogtreecommitdiff
path: root/.b/etc/X11
diff options
context:
space:
mode:
authorSyndamia <kamen@syndamia.com>2022-09-06 10:53:34 +0300
committerSyndamia <kamen@syndamia.com>2022-09-06 10:53:34 +0300
commitabdbd80ac4dcc42619ee4ed12c19fb5d71fa2d83 (patch)
treeba3e845eefb201676fcc87e964ab5035f3222585 /.b/etc/X11
parentdd6a62a3c881c0b2e71db5bb923c60a54d2b016d (diff)
downloaddotfiles-abdbd80ac4dcc42619ee4ed12c19fb5d71fa2d83.tar
dotfiles-abdbd80ac4dcc42619ee4ed12c19fb5d71fa2d83.tar.gz
dotfiles-abdbd80ac4dcc42619ee4ed12c19fb5d71fa2d83.zip
Added many configs to .b
Diffstat (limited to '.b/etc/X11')
-rwxr-xr-x.b/etc/X11/Sessions/Xsession107
-rwxr-xr-x.b/etc/X11/Sessions/openbox1
-rw-r--r--.b/etc/X11/xdm/Xaccess98
-rw-r--r--.b/etc/X11/xdm/Xresources73
-rw-r--r--.b/etc/X11/xdm/Xservers12
-rw-r--r--.b/etc/X11/xdm/xdm-config31
-rw-r--r--.b/etc/X11/xinit/xinitrc65
-rwxr-xr-x.b/etc/X11/xinit/xinitrc.d/00-xhost7
-rwxr-xr-x.b/etc/X11/xinit/xinitrc.d/40-libcanberra-gtk-module16
-rwxr-xr-x.b/etc/X11/xinit/xinitrc.d/80-dbus13
-rwxr-xr-x.b/etc/X11/xinit/xinitrc.d/80xapp-gtk3-module.sh10
-rwxr-xr-x.b/etc/X11/xinit/xinitrc.d/90-consolekit32
-rwxr-xr-x.b/etc/X11/xinit/xserverrc6
-rw-r--r--.b/etc/X11/xorg.conf.d/20opengl.conf2
14 files changed, 473 insertions, 0 deletions
diff --git a/.b/etc/X11/Sessions/Xsession b/.b/etc/X11/Sessions/Xsession
new file mode 100755
index 0000000..c86ccee
--- /dev/null
+++ b/.b/etc/X11/Sessions/Xsession
@@ -0,0 +1,107 @@
+#!/bin/sh
+# $XConsortium: Xsession /main/10 1995/12/18 18:21:28 gildea $
+
+case $# in
+1)
+ case $1 in
+ failsafe)
+ exec xterm -geometry 80x24-0-0
+ ;;
+ esac
+esac
+
+# redirect errors to a file in user's home directory if we can
+for errfile in "$HOME/.xsession-errors" "${TMPDIR-/tmp}/xses-$USER" "/tmp/xses-$USER"
+do
+ if ( cp /dev/null "$errfile" 2> /dev/null )
+ then
+ chmod 600 "$errfile"
+ exec > "$errfile" 2>&1
+ break
+ fi
+done
+
+# clean up after xbanner
+if which freetemp 2> /dev/null ; then
+ freetemp
+fi
+
+startup=$HOME/.xsession
+
+userresources=$HOME/.Xresources
+usermodmap=$HOME/.Xmodmap
+userxkbmap=$HOME/.Xkbmap
+
+sysresources=/etc/X11/Xresources
+sysmodmap=/etc/X11/Xmodmap
+sysxkbmap=/etc/X11/Xkbmap
+
+rh6sysresources=/etc/X11/xinit/Xresources
+rh6sysmodmap=/etc/X11/xinit/Xmodmap
+
+
+# merge in defaults
+if [ -f "$rh6sysresources" ]; then
+ xrdb -merge "$rh6sysresources"
+fi
+
+if [ -f "$sysresources" ]; then
+ xrdb -merge "$sysresources"
+fi
+
+if [ -f "$userresources" ]; then
+ xrdb -merge "$userresources"
+fi
+
+# merge in keymaps
+if [ -f "$sysxkbmap" ]; then
+ setxkbmap `cat "$sysxkbmap"`
+ XKB_IN_USE=yes
+fi
+
+if [ -f "$userxkbmap" ]; then
+ setxkbmap `cat "$userxkbmap"`
+ XKB_IN_USE=yes
+fi
+
+#
+# Eeek, this seems like too much magic here
+#
+if [ -z "$XKB_IN_USE" -a ! -L /etc/X11/X ]; then
+ if grep '^exec.*/Xsun' /etc/X11/X > /dev/null 2>&1 && [ -f /etc/X11/XF86Config ]; then
+ xkbsymbols=`sed -n -e 's/^[ ]*XkbSymbols[ ]*"\(.*\)".*$/\1/p' /etc/X11/XF86Config`
+ if [ -n "$xkbsymbols" ]; then
+ setxkbmap -symbols "$xkbsymbols"
+ XKB_IN_USE=yes
+ fi
+ fi
+fi
+
+# xkb and xmodmap don't play nice together
+if [ -z "$XKB_IN_USE" ]; then
+ if [ -f "$rh6sysmodmap" ]; then
+ xmodmap "$rh6sysmodmap"
+ fi
+
+ if [ -f "$sysmodmap" ]; then
+ xmodmap "$sysmodmap"
+ fi
+
+ if [ -f "$usermodmap" ]; then
+ xmodmap "$usermodmap"
+ fi
+fi
+
+unset XKB_IN_USE
+
+if [ -x "$startup" ]; then
+ exec "$startup"
+elif [ -x "$HOME/.Xclients" ]; then
+ exec "$HOME/.Xclients"
+elif [ -x /etc/X11/xinit/Xclients ]; then
+ exec /etc/X11/xinit/Xclients
+elif [ -x /etc/X11/Xclients ]; then
+ exec /etc/X11/Xclients
+else
+ exec xsm
+fi
diff --git a/.b/etc/X11/Sessions/openbox b/.b/etc/X11/Sessions/openbox
new file mode 100755
index 0000000..99319e1
--- /dev/null
+++ b/.b/etc/X11/Sessions/openbox
@@ -0,0 +1 @@
+/usr/bin/openbox-session
diff --git a/.b/etc/X11/xdm/Xaccess b/.b/etc/X11/xdm/Xaccess
new file mode 100644
index 0000000..c843888
--- /dev/null
+++ b/.b/etc/X11/xdm/Xaccess
@@ -0,0 +1,98 @@
+#
+# Access control file for XDMCP connections
+#
+# To control Direct and Broadcast access:
+#
+# pattern
+#
+# To control Indirect queries:
+#
+# pattern list of hostnames and/or macros ...
+#
+# To use the chooser:
+#
+# pattern CHOOSER BROADCAST
+#
+# or
+#
+# pattern CHOOSER list of hostnames and/or macros ...
+#
+# To define macros:
+#
+# %name list of hosts ...
+#
+# To control which addresses xdm listens for requests on:
+#
+# LISTEN address [list of multicast groups ... ]
+#
+# The first form tells xdm which displays to respond to itself.
+# The second form tells xdm to forward indirect queries from hosts matching
+# the specified pattern to the indicated list of hosts.
+# The third form tells xdm to handle indirect queries using the chooser;
+# the chooser is directed to send its own queries out via the broadcast
+# address and display the results on the terminal.
+# The fourth form is similar to the third, except instead of using the
+# broadcast address, it sends DirectQuerys to each of the hosts in the list
+# The fifth form tells xdm which addresses to listen for incoming connections
+# on. If present, xdm will only listen for connections on the specified
+# interfaces and/or multicast groups.
+#
+# In all cases, xdm uses the first entry which matches the terminal;
+# for IndirectQuery messages only entries with right hand sides can
+# match, for Direct and Broadcast Query messages, only entries without
+# right hand sides can match.
+#
+
+#* #any host can get a login window
+
+#
+# To hardwire a specific terminal to a specific host, you can
+# leave the terminal sending indirect queries to this host, and
+# use an entry of the form:
+#
+
+#terminal-a host-a
+
+
+#
+# The nicest way to run the chooser is to just ask it to broadcast
+# requests to the network - that way new hosts show up automatically.
+# Sometimes, however, the chooser can't figure out how to broadcast,
+# so this may not work in all environments.
+#
+
+#* CHOOSER BROADCAST #any indirect host can get a chooser
+
+#
+# If you'd prefer to configure the set of hosts each terminal sees,
+# then just uncomment these lines (and comment the CHOOSER line above)
+# and edit the %hostlist line as appropriate
+#
+
+#%hostlist host-a host-b
+
+#* CHOOSER %hostlist #
+
+#
+# If you have a machine with multiple network interfaces or IP addresses
+# you can control which interfaces accept XDMCP packets by listing a LISTEN
+# line for each interface you want to listen on. You can additionally list
+# one or more multicast groups after each address to listen on those groups
+# on that address.
+#
+# If no LISTEN is specified, the default is the same as "LISTEN *" - listen on
+# all unicast interfaces, but not for multicast packets. If any LISTEN lines
+# are specified, then only the listed interfaces will be listened on.
+#
+# IANA has assigned FF0X:0:0:0:0:0:0:12B as the permanently assigned
+# multicast addresses for XDMCP, where X in the prefix may be replaced
+# by any valid scope identifier, such as 1 for Node-Local, 2 for Link-Local,
+# 5 for Site-Local, and so on. The default is equivalent to the example shown
+# here using the Link-Local version to most closely match the old IPv4 subnet
+# broadcast behavior.
+#
+# LISTEN * ff02:0:0:0:0:0:0:12b
+
+# This example shows listening for multicast on all scopes up to site-local
+#
+# LISTEN * ff01:0:0:0:0:0:0:12b ff02:0:0:0:0:0:0:12b ff03:0:0:0:0:0:0:12b ff04:0:0:0:0:0:0:12b ff05:0:0:0:0:0:0:12b
diff --git a/.b/etc/X11/xdm/Xresources b/.b/etc/X11/xdm/Xresources
new file mode 100644
index 0000000..4412ccb
--- /dev/null
+++ b/.b/etc/X11/xdm/Xresources
@@ -0,0 +1,73 @@
+Xcursor.theme: whiteglass
+
+
+
+xlogin*login.translations: #override \
+ Ctrl<Key>R: abort-display()\n\
+ <Key>F1: set-session-argument(failsafe) finish-field()\n\
+ <Key>Delete: delete-character()\n\
+ <Key>Left: move-backward-character()\n\
+ <Key>Right: move-forward-character()\n\
+ <Key>Home: move-to-begining()\n\
+ <Key>End: move-to-end()\n\
+ Ctrl<Key>KP_Enter: set-session-argument(failsafe) finish-field()\n\
+ <Key>KP_Enter: set-session-argument() finish-field()\n\
+ Ctrl<Key>Return: set-session-argument(failsafe) finish-field()\n\
+ <Key>Return: set-session-argument() finish-field()
+
+xlogin*greeting: Welcome
+xlogin*namePrompt: Username:
+xlogin*passwdPrompt: ``Password: ``
+xlogin*fail: Login incorrect or forbidden by policy
+
+xlogin*greetFont: -adobe-helvetica-bold-o-normal--24-240-75-75-p-138-iso8859-1
+xlogin*font: -adobe-helvetica-medium-r-normal--18-180-75-75-p-98-iso8859-1
+xlogin*promptFont: -adobe-helvetica-bold-r-normal--18-180-75-75-p-103-iso8859-1
+xlogin*failFont: -adobe-helvetica-bold-r-normal--18-180-75-75-p-103-iso8859-1
+xlogin*greetFace: Helvetica-24:bold
+xlogin*face: Helvetica-18
+xlogin*promptFace: Helvetica-18
+xlogin*failFace: Helvetica-18:bold
+
+#ifdef COLOR
+xlogin*borderWidth: 1
+xlogin*frameWidth: 0
+xlogin*innerFramesWidth: 0
+xlogin*shdColor: #b8bb26
+xlogin*hiColor: #b8bb26
+xlogin*background: #282828
+xlogin*greetColor: #d49408
+xlogin*failColor: #c80003
+*Foreground: #ffeede
+!*Background: steelblue
+#else
+xlogin*borderWidth: 3
+xlogin*frameWidth: 0
+xlogin*innerFramesWidth: 1
+xlogin*shdColor: black
+xlogin*hiColor: black
+#endif
+
+xlogin*echoPasswd: true
+
+!#if PLANES >= 8
+!xlogin*logoFileName: /usr/share/xdm/pixmaps/xorg.xpm
+!#else
+!xlogin*logoFileName: /usr/share/xdm/pixmaps/xorg-bw.xpm
+!#endif
+!xlogin*useShape: true
+!xlogin*logoPadding: 10
+
+
+XConsole.text.geometry: 480x130
+XConsole.verbose: true
+XConsole*iconic: true
+XConsole*font: fixed
+
+Chooser*geometry: 700x500+300+200
+Chooser*allowShellResize: false
+Chooser*viewport.forceBars: true
+Chooser*label.font: *-new century schoolbook-bold-i-normal-*-240-*
+Chooser*label.label: XDMCP Host Menu from CLIENTHOST
+Chooser*list.font: -*-*-medium-r-normal-*-*-230-*-*-c-*-iso8859-1
+Chooser*Command.font: *-new century schoolbook-bold-r-normal-*-180-* \ No newline at end of file
diff --git a/.b/etc/X11/xdm/Xservers b/.b/etc/X11/xdm/Xservers
new file mode 100644
index 0000000..53c459c
--- /dev/null
+++ b/.b/etc/X11/xdm/Xservers
@@ -0,0 +1,12 @@
+#
+# Xservers file, workstation prototype
+#
+# This file should contain an entry to start the server on the
+# local display; if you have more than one display (not screen),
+# you can add entries to the list (one per line). If you also
+# have some X terminals connected which do not support XDMCP,
+# you can add them here as well. Each X terminal line should
+# look like:
+# XTerminalName:0 foreign
+#
+:0 local /usr/bin/X :0 vt7
diff --git a/.b/etc/X11/xdm/xdm-config b/.b/etc/X11/xdm/xdm-config
new file mode 100644
index 0000000..29ef25b
--- /dev/null
+++ b/.b/etc/X11/xdm/xdm-config
@@ -0,0 +1,31 @@
+!
+!
+!
+!
+!
+DisplayManager.authDir: /var/lib/xdm
+DisplayManager.errorLogFile: /var/log/xdm.log
+DisplayManager.pidFile: /var/run/xdm.pid
+DisplayManager.keyFile: /etc/X11/xdm/xdm-keys
+DisplayManager.servers: /etc/X11/xdm/Xservers
+DisplayManager.accessFile: /etc/X11/xdm/Xaccess
+DisplayManager*resources: /etc/X11/xdm/Xresources
+DisplayManager.willing: su nobody -s /bin/sh -c /usr/lib64/X11/xdm/Xwilling
+! All displays should use authorization, but we cannot be sure
+! X terminals may not be configured that way, so they will require
+! individual resource settings.
+DisplayManager*authorize: true
+DisplayManager*authName: MIT-MAGIC-COOKIE-1
+!
+DisplayManager*chooser: /usr/lib64/X11/xdm/chooser
+DisplayManager*startup: /usr/lib64/X11/xdm/Xstartup
+DisplayManager*session: /usr/lib64/X11/xdm/Xsession
+DisplayManager*reset: /usr/lib64/X11/xdm/Xreset
+DisplayManager*authComplain: true
+! The following three resources set up display :0 as the console.
+DisplayManager._0.setup: /usr/lib64/X11/xdm/Xsetup_0
+DisplayManager._0.startup: /usr/lib64/X11/xdm/GiveConsole
+DisplayManager._0.reset: /usr/lib64/X11/xdm/TakeConsole
+! SECURITY: do not listen for XDMCP or Chooser requests
+! Comment out this line if you want to manage X terminals with xdm
+DisplayManager.requestPort: 0
diff --git a/.b/etc/X11/xinit/xinitrc b/.b/etc/X11/xinit/xinitrc
new file mode 100644
index 0000000..1109fc3
--- /dev/null
+++ b/.b/etc/X11/xinit/xinitrc
@@ -0,0 +1,65 @@
+#!/bin/sh
+
+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
+
+# start some nice programs
+
+if [ -n "`/etc/X11/chooser.sh`" ]; then
+ command="`/etc/X11/chooser.sh`"
+else
+ failsafe="yes"
+fi
+
+if [ -d /etc/X11/xinit/xinitrc.d ] ; then
+ for f in /etc/X11/xinit/xinitrc.d/?* ; do
+ [ -x "$f" ] && . "$f"
+ done
+ unset f
+fi
+
+if [ -n "$failsafe" ]; then
+ twm &
+ xclock -geometry 50x50-1+1 &
+ xterm -geometry 80x50+494+51 &
+ xterm -geometry 80x20+494-0 &
+ exec xterm -geometry 80x66+0+0 -name login
+else
+ exec $command
+fi
diff --git a/.b/etc/X11/xinit/xinitrc.d/00-xhost b/.b/etc/X11/xinit/xinitrc.d/00-xhost
new file mode 100755
index 0000000..82cf103
--- /dev/null
+++ b/.b/etc/X11/xinit/xinitrc.d/00-xhost
@@ -0,0 +1,7 @@
+#!/bin/sh
+# Allow all local connections from the current UID
+# This fixes issues with hostname changes (usually by dhcp clients)
+# see bug 287498 for more info
+
+[ -x /usr/bin/xhost ] && [ -x /usr/bin/id ] &&
+ xhost +si:localuser:`id -un` > /dev/null 2>&1
diff --git a/.b/etc/X11/xinit/xinitrc.d/40-libcanberra-gtk-module b/.b/etc/X11/xinit/xinitrc.d/40-libcanberra-gtk-module
new file mode 100755
index 0000000..63c16af
--- /dev/null
+++ b/.b/etc/X11/xinit/xinitrc.d/40-libcanberra-gtk-module
@@ -0,0 +1,16 @@
+#!/bin/sh
+# to be sourced
+
+case "$SESSION" in
+ GNOME)
+ # Done by gnome-settings-daemon
+ ;;
+ *)
+ if [ -z "$GTK_MODULES" ] ; then
+ GTK_MODULES="canberra-gtk-module"
+ else
+ GTK_MODULES="$GTK_MODULES:canberra-gtk-module"
+ fi
+ export GTK_MODULES
+ ;;
+esac
diff --git a/.b/etc/X11/xinit/xinitrc.d/80-dbus b/.b/etc/X11/xinit/xinitrc.d/80-dbus
new file mode 100755
index 0000000..5593e2c
--- /dev/null
+++ b/.b/etc/X11/xinit/xinitrc.d/80-dbus
@@ -0,0 +1,13 @@
+#!/bin/bash
+
+# launches a session dbus instance
+
+dbuslaunch="`which dbus-launch 2>/dev/null`"
+if [ -n "$dbuslaunch" ] && [ -x "$dbuslaunch" ] && [ -z "$DBUS_SESSION_BUS_ADDRESS" ]; then
+ if [ -n "$command" ]; then
+ command="$dbuslaunch --exit-with-session $command"
+ else
+ eval `$dbuslaunch --sh-syntax --exit-with-session`
+ fi
+fi
+
diff --git a/.b/etc/X11/xinit/xinitrc.d/80xapp-gtk3-module.sh b/.b/etc/X11/xinit/xinitrc.d/80xapp-gtk3-module.sh
new file mode 100755
index 0000000..4b2ec2a
--- /dev/null
+++ b/.b/etc/X11/xinit/xinitrc.d/80xapp-gtk3-module.sh
@@ -0,0 +1,10 @@
+#!/bin/bash
+# This file is sourced by xinit(1) or a display manager's Xsession, not executed.
+
+if [ -z "$GTK_MODULES" ] ; then
+ GTK_MODULES="xapp-gtk3-module"
+else
+ GTK_MODULES="$GTK_MODULES:xapp-gtk3-module"
+fi
+
+export GTK_MODULES
diff --git a/.b/etc/X11/xinit/xinitrc.d/90-consolekit b/.b/etc/X11/xinit/xinitrc.d/90-consolekit
new file mode 100755
index 0000000..358fc24
--- /dev/null
+++ b/.b/etc/X11/xinit/xinitrc.d/90-consolekit
@@ -0,0 +1,32 @@
+# -*- sh -*-
+# Xsession.d script for ck-launch-session.
+#
+#
+# This file is sourced by Xsession(5), not executed.
+
+CK_LAUNCH_SESSION=/usr/bin/ck-launch-session
+
+is_on_console() {
+ session=$(dbus-send --system --dest=org.freedesktop.ConsoleKit \
+ --type=method_call --print-reply --reply-timeout=2000 \
+ /org/freedesktop/ConsoleKit/Manager \
+ org.freedesktop.ConsoleKit.Manager.GetCurrentSession \
+ | grep path | awk '{print $3}' | sed s/\"//g)
+ x11_display=$(dbus-send --system --dest=org.freedesktop.ConsoleKit \
+ --type=method_call --print-reply --reply-timeout=2000 \
+ $session org.freedesktop.ConsoleKit.Session.GetX11Display \
+ | grep string | awk '{print $2}' | sed s/\"//g)
+
+ if [ -z "$x11_display" ] ; then
+ return 0
+ else
+ return 1
+ fi
+}
+
+# gdm already creates a CK session for us, so do not run the expensive D-Bus
+# calls if we have $GDMSESSION
+if [ -z "$GDMSESSION" ] && [ -x "$CK_LAUNCH_SESSION" ] && \
+ ( [ -z "$XDG_SESSION_COOKIE" ] || is_on_console ) ; then
+ command="$CK_LAUNCH_SESSION $command"
+fi
diff --git a/.b/etc/X11/xinit/xserverrc b/.b/etc/X11/xinit/xserverrc
new file mode 100755
index 0000000..6b57eeb
--- /dev/null
+++ b/.b/etc/X11/xinit/xserverrc
@@ -0,0 +1,6 @@
+#!/bin/sh
+if [ -z "$XDG_VTNR" ]; then
+ exec /usr/bin/X -nolisten tcp "$@"
+else
+ exec /usr/bin/X -nolisten tcp "$@" vt$XDG_VTNR
+fi
diff --git a/.b/etc/X11/xorg.conf.d/20opengl.conf b/.b/etc/X11/xorg.conf.d/20opengl.conf
new file mode 100644
index 0000000..582220f
--- /dev/null
+++ b/.b/etc/X11/xorg.conf.d/20opengl.conf
@@ -0,0 +1,2 @@
+Section "Files"
+EndSection