[openbox] Launching applications

Anthony Thyssen A.Thyssen at griffith.edu.au
Mon Oct 3 20:55:25 EDT 2011


On Mon, 3 Oct 2011 15:16:33 -0700
Brian Mattern <rephorm at rephorm.com> wrote:
| On Mon, 03 Oct 2011, Anthony Thyssen wrote:
| > For example (after looking up its man page) make you "mutt launcher"
| > something like...
| > 
| >   urxt -name "mutt" -title "mutt" -e mutt &
| > 
| 
| As described in the manpage, the -name option causes urxvt to use
| "mutt" to lookup X resources. So, any custom urxvt colors / options
| set in your .Xdefaults will be lost. It should be sufficient to use
| the -title option.

Note that if your custom urxvt resources were correctly then custom
colors/options will NOT be lost!

The -name option does NOT change the Class name, only the instance name.
And you can use either name for resources...

Resources using the capatilized class name are applied to all instances
of the application. Resources define using an instance name (typically
all lowercase to differentiate) are only applied to specific 'named'
instances of the application, and can override Class resources.

For example, I have global XTerm resources, and specific resources
for instances 'tiny' and 'MailEd'.

=======8<--------CUT HERE----------axes/crowbars permitted---------------
! I prefer to use dark xterms with white text
XTerm*background:               black
XTerm*foreground:               white
XTerm*borderColor:              white
XTerm*cursorColor:              white
! But give the scrollbar some color.
XTerm*Scrollbar.background:     black
XTerm*Scrollbar.foreground:     dodgerblue
XTerm*Scrollbar.borderColor:    skyblue
! Expand the word symbols so double click selects whole path strings
XTerm*charClass:                45-47:48,95:48,126:48
!
! Lines start from pointed to word (for triple clicks)
!   This allows me to select commands but ignore prompts when grabbing
!   commands or arguments for use in other windows
XTerm*cutToBeginningOfLine:     False
!
!
! Tiny Special purpose Xterm
! recolor scrollbars
tiny*Scrollbar.foreground:     firebrick
tiny*Scrollbar.borderColor:    tomato
tiny*saveLines:     100
tiny*cutToBeginningOfLine:     True
!
! Special Xterm used for Mail Editing (in capitals)
! add some application level keyboard macros
MailED*VT100.Translations:       #override \
   <Key> F1  : string("A.Thyssen at griffith.edu.au") \n\
   <Key> F2  : string("http://www.ict.griffith.edu.au/anthony/") \n\

=======8<--------CUT HERE----------axes/crowbars permitted---------------

All my XTerms white on black (by default due to the resources)
but my 'tiny' window has a different colored scrollbar.
and only my 'MailED' xterm has some specific keyboard marcos.

I can check what reseources are defines for a App using "appres"
Including those that come from system application default files.

   appres  XTerm tiny

just remember 'instances' override 'class' resources.

The same would be true for xrvt.

I also do similar things for XMessage windows with a special
'logout' button xmessage window which if I press anywhere
in it, it just exits normaly (exits abnormally on X shutdown)

Resources are VERY cool!

It is just a shame that so many modern GUI applications (like
"gnome-terminal") don't use resources, but other methods of
setting and storing there configuration settings.


ASIDE: I was using and programming the low level X window system when
X10 was released!  I wrote 'widgets' for some applications.  And even
still have the X Protocol Xlib, Xathena books on my book shelf.

For more info see my personal notes (some going way back) in
  http://www.ict.griffith.edu.au/anthony/info/X/Resources.hints
  http://www.ict.griffith.edu.au/anthony/info/X/WindowID.hints

and other files in that directory.


  Anthony Thyssen ( System Programmer )    <A.Thyssen at griffith.edu.au>
 --------------------------------------------------------------------------
 "Well, don't just stand there, Sergeant Benton.  Go put yourself under arrest."
             -- Brigadier, Doctor Who, "Invasion of the Dinosaurs"
 --------------------------------------------------------------------------
   Anthony's Castle     http://www.ict.griffith.edu.au/anthony/


More information about the openbox mailing list