[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#447519: xterm: [UXTerm] doesn't support *XTerm class in ~/.Xresources



On Tue, Oct 23, 2007 at 07:42:21PM +0200, Luca Capello wrote:
> Hi Thomas!
> 
> On Tue, 23 Oct 2007 17:47:00 +0200, Thomas Dickey wrote:
> > On Sun, Oct 21, 2007 at 11:40:11PM +0200, Luca Capello wrote:
> >> I'm not sure this is really a bug, but I cannot find anything in
> >> the documentation.  In case it's there, can anyone point me at it,
> >> please?
> >> 
> >> Basically, I'd like to define UXTerm resources in the *XTerm form
> >> (which is perfectly valid for xterm itself), in order to avoid
> >> resource duplications.  As I wrote, it seems that xterm supports
> >> *XTerm, while uxterm no.
> >
> > The uxterm script sets the class to "UXTerm" so that there are no
> > conflicts in resource intent/interpretation between the two uses.
> 
> I'm aware of that and indeed this is a reason I started with "I'm not
> sure this is really a bug".
> 
> If the "problem" is not clear, here my second try: I usually quite
> exclusively uxterm and thus I could specify UXTerm resources as
> UXTerm.  However, sometime I start an xterm and, obviously, I don't
> have my UXTerm settings.  Since resources specified as *XTerm are
> correctly read by xterm, I assumed that '*' is a wildcard, which
> stands for "all", thus "*XTerm" means "every class which ends in
> XTerm".

Wildcards in Xt resources aren't supposed to do that (oddly enough).
They replace whole leaf-names rather than parts of them.  The resource
syntax is documented in the X manpage (at the moment I'm on Solaris,
and know the the Linux manpage is named different...).  Here's the
text, for reference:

     The precise syntax for resources is:

     ResourceLine      = Comment | IncludeFile | ResourceSpec | <empty line>
     Comment           = "!" {<any character except null or newline>}
     IncludeFile       = "#" WhiteSpace "include" WhiteSpace FileName WhiteSpace
     FileName          = <valid filename for operating system>
     ResourceSpec      = WhiteSpace ResourceName WhiteSpace ":" WhiteSpace Value
     ResourceName      = [Binding] {Component Binding} ComponentName
     Binding           = "." | "*"
     WhiteSpace        = {<space> | <horizontal tab>}
     Component         = "?" | ComponentName
     ComponentName     = NameChar {NameChar}
     NameChar          = "a"-"z" | "A"-"Z" | "0"-"9" | "_" | "-"
     Value             = {<any character except null or unescaped newline>}

I usually do this a different way, setting
	$XAPPLRESDIR
to my
	$HOME/app-defaults
(and putting individual resource files there).

Doing that means I don't have to prefix things with the class name,
unless I'm overriding something in the system's app-defaults file.
(More-specific patterns override more-general ones - you cannot redefine
the same pattern).

I use "#include" there, and in the system's app-defaults to reduce
duplication.
 
> If the latter is right, this should be the case for UXTerm, too.
> Since it's not the case, this is a bug.  However, if I'm wrong, I'll
> change the severity of this bug as 'wishlist' ;-)
> 
> Thx, bye,
> Gismo / Luca

-- 
Thomas E. Dickey
http://invisible-island.net
ftp://invisible-island.net

Attachment: pgpLBYy8zUoLB.pgp
Description: PGP signature


Reply to: