Skip to content

u/krage

In this archive from Jun 2013 to Dec 2014

0
posts
9
comments
0
media
37
score

Top comments

The simplest rotation of colour schemes I can see is just rotating those command line args... so not especially elegant, but this should work:

#!/bin/bash

#define some theme sequence
theme[0]="-bg #ff0000"
theme[1]="-bg #00ff00"
theme[2]="-bg #0000ff"

#check for last used theme id
if [ ! -f "/tmp/termtheme" ] ; then
  theme_id=0 #defaulting to first theme
else
  theme_id=`cat /tmp/termtheme` #load previous
  theme_id=`expr ${theme_id} + 1` #increment it
  theme_id=`expr ${theme_id} % ${#theme[@]}` #don't exceed max
fi

#store theme id we're about to use
echo "${theme_id}" > /tmp/termtheme

#launch the terminal
rxvt-unicode ${theme[${theme_id}]}

Just expand the theme strings at the top with the complete set of args that you want to change from their defaults in the given theme. They're all pretty obvious in that man page linked previously (-bg, -fg, --color1, --color2, etc.).

7 points

urxvt can certainly do the margin thing, set along these lines in .Xdefaults/.Xresources:

URxvt.internalBorder: 1

Value is the pixel size of margin, max allowed appears to be 100 according to man page.

Edit: Also it just occured to me that you can redefine the entire colourscheme via arguments when launching urxvt, so you could potentially launch your terminals via a shell script to randomize or rotate colour schemes to get your varied background colours unrelated to whatever defaults you've listed in your .Xdefaults/.Xresources.

7 points

Subreddits

Keyboard shortcuts

Move and act

jork
Next / previous post or comment
Enteroro
Open the post
f
Open the media viewer
s
Save
h
Hide (the toast has Undo)
Tab
Right after an action: the toast's Undo
x
Collapse the comment
v
Next layout: cards, compact, grid

Go to

/
Search
gthenh
Home
gthena
All
gthens
Subreddits
gthenl
Library
?
This list
Esc
Close a menu or this list

In the viewer

←or→
Previous / next file
↑or↓
Previous / next post
korj
Previous / next post
Space
Play / pause
m
Mute
z
Zoom
s
Save
o
Open the post (on its own page: back to it)
Esc
Close

Keys do nothing while you type in a box.