xorg
Table of Contents
xmessage- like an
echoforX.- Define the font using inside
~/.Xresourcesor~/.Xdefaults:Xmessage*font: -*-terminus-*-*-*-*-*-*-*-*-*-120-*-u. (Then issuexrdb load ~/.Xresourcesto get that into effect.)
- Define the font using inside
xfontsel- choose fonts
xsetroot- sets the background.
xsetroot -solid SteelBlue
xview- load images into an X11 window or onto the root window
(cf.
xloadimage,xsetbg) xprop- property displayer for X
xprop -root|grep ^_NET_CLIENT_LIST. get window list.
xwininfo- window information utility for X
xwininfo -id 0x800003– info from a particular window
xbiff- e-Mail
- Only handles Mbox, not Maildir.
xclock- clock
1. quests
- Getting the URL of the current tab from a browser
- nesting one server on another:
XnestXnest -ac :1
Xephyrhttps://freedesktop.org/wiki/Software/Xephyr/
two xservers at once.
Call the first one with
startxas normal, then call the other one, using another.xinitrcif you wish, on another tty:startx ~/.xinitrc-fvwm -- :1
1.1. interacting via Common LISP
a fork of crhodes' fork of danb's fork of the CLX library, an X11 client for Common Lisp
- Related: Investigating the CLX library
1.1.1. list all fonts
(xlib:list-fonts (xlib:open-display "") "*") (xlib:display-roots (xlib:open-display "")) (xlib:list-extensions (xlib:open-display "")) (describe (slot-value (car (xlib:display-roots (xlib:open-display ""))) 'xlib::root)) ;; xdotool search --name "Mozilla Firefox" windowsize 1280 720 (xlib:root-resources (car (xlib:display-roots (xlib:open-display "")))) (xlib:global-pointer-position (xlib:open-display ""))
1.1.2. the focused window
(xlib:input-focus (xlib:open-display "")) (query-tree (xlib:input-focus (xlib:open-display "")))
1.1.3. window list
~(query-tree (slot-value (car (display-roots (xlib:open-display ""))) 'root))~
1.1.4. window name
(get-property
(car (query-tree (slot-value (car (display-roots (xlib:open-display "")))
'root)))
:WM_NAME :type :string :result-type 'string :transform #'card8->char)
(defun window-name-get (window)
(get-property window :WM_NAME :type :string :result-type 'string
:transform #'card8->char))
(defun window-get-atoms (window)
(get-property window :WM_NAME :type :string :result-type 'string
:transform #'card8->char)))
(loop for each in
(query-tree (slot-value (car (display-roots (xlib:open-display ""))) 'root))
collect (window-name-get each))
(defconstant +predefined-atoms+
'#(nil :PRIMARY :SECONDARY :ARC :ATOM :BITMAP
:CARDINAL :COLORMAP :CURSOR
:CUT_BUFFER0 :CUT_BUFFER1 :CUT_BUFFER2 :CUT_BUFFER3
:CUT_BUFFER4 :CUT_BUFFER5 :CUT_BUFFER6 :CUT_BUFFER7
:DRAWABLE :FONT :INTEGER :PIXMAP :POINT :RECTANGLE
:RESOURCE_MANAGER :RGB_COLOR_MAP :RGB_BEST_MAP
:RGB_BLUE_MAP :RGB_DEFAULT_MAP
:RGB_GRAY_MAP :RGB_GREEN_MAP :RGB_RED_MAP :STRING
:VISUALID :WINDOW :WM_COMMAND :WM_HINTS
:WM_CLIENT_MACHINE :WM_ICON_NAME :WM_ICON_SIZE
:WM_NAME :WM_NORMAL_HINTS :WM_SIZE_HINTS
:WM_ZOOM_HINTS :MIN_SPACE :NORM_SPACE :MAX_SPACE
:END_SPACE :SUPERSCRIPT_X :SUPERSCRIPT_Y
:SUBSCRIPT_X :SUBSCRIPT_Y
:UNDERLINE_POSITION :UNDERLINE_THICKNESS
:STRIKEOUT_ASCENT :STRIKEOUT_DESCENT
:ITALIC_ANGLE :X_HEIGHT :QUAD_WIDTH :WEIGHT
:POINT_SIZE :RESOLUTION :COPYRIGHT :NOTICE
:FONT_NAME :FAMILY_NAME :FULL_NAME :CAP_HEIGHT
:WM_CLASS :WM_TRANSIENT_FOR))
- clipboard
- ~/quicklisp/dists/quicklisp/software/clx-20220707-git/demo/clipboard.lisp
2. related reading
3. keyboard
See quicklisp/dists/quicklisp/software/stumpwm-20220707-git/keysyms.lisp.
(XLIB:KEYSYM->CHARACTER (xlib:open-display "") 112) ; #\p (keysym->keysym-name 65501) ; "F32"
