Subject: FVWM: Access to Client Application Resource Database

From: "Leo Deck" <[email-masked]>
Date: Mon, 06 Dec 1999 19:41:20 PST

On a Sun Solaris system, I have fvwm configured (via .fvwmrc) to execute a 
shell script when a particular selection is made from the fvwm "StartMenu".  
The shell script sets some environment variables and starts an X-Windows GUI 
application.  The GUI makes a call to XtVaAppInitialize() that causes a 
connection to the X server to be
opened.  The call to XtVaAppInitialize() also causes the resource database 
for the application to be loaded by the resource manager.

When fvwm has to manage the GUI application window after the GUI requests 
that the window be mapped, is there any way that fvwm can be modified to get 
access to the application's resource database?  If so, please describe the 
way to access the application's resource database.

Thanks in advance.

Leo Deck

______________________________________________________
Get Your Private, Free Email at http://www.hotmail.com
--
Visit the official FVWM web page at <URL: http://www.fvwm.org/>.
To unsubscribe from the list, send "unsubscribe fvwm" in the body of a
message to [email-masked].
To report problems, send mail to [email-masked].

---

From: Dan Espen <[email-masked]>
Date: Mon, 06 Dec 1999 23:49:46 -0500

> way to access the application's resource database.

I saw this question  this morning, and now this  evening, but  I still
don't understand it.

What do you want fvwm to do to your application?

Fvwm doesn't normally muck around with X resources, there are tools
like editres for that.

--
Dan Espen
444 Hoes Lane  Room RRC 1C-214           E-mail: [email-masked]
Piscataway, NJ 08854                     Phone: (732) 699-5570
--
Visit the official FVWM web page at <URL: http://www.fvwm.org/>.
To unsubscribe from the list, send "unsubscribe fvwm" in the body of a
message to [email-masked].
To report problems, send mail to [email-masked].

---

From: "Leo Deck" <[email-masked]>
Date: Tue, 07 Dec 1999 05:22:51 PST

I would like for fvwm to be able to recognize clientDecoration and 
clientFunctions resources from an application's resource database and 
provide the appropriate window decorations and functions for the 
application's window.  The clientDecoration and clientFunctions resources 
are specified in the application's default resource file.  The default 
resource file is located in a directory path (i.e., XAPPLRESDIR) defined in 
the shell script that starts the application, and the directory path is not 
readily available to the window manager.
XAPPLRESDIR for the user login session that activated fvwm is not the same 
directory path as the XAPPLRESDIR defined in the application startup shell 
script.

For example, if the application's name is app1 and it's class is App1, the 
application-specific default resource file's name would be App1, and the 
resources of interest could be specified in the file App1 in a format as 
follows:

  app1*clientDecoration: value
  app1*clientFunctions: value

The application resource file does get loaded by the resource manager, 
because the application itself can query the resource database and find the 
clientDecoration and clientFunctions resource specifications.  However, this 
resource database does not seem to be available to fvwm.

I realize that I am trying to do something that is probably out of the 
ordinary.  Perhaps, it is not possible to do this.  Any insight into the 
feasibility or possibility of doing something like this would be 
appreciated.

Leo Deck

>From: Dan Espen <[email-masked]>
>To: "Leo Deck" <[email-masked]>
>CC: [email-masked]
>Subject: Re: FVWM: Access to Client Application Resource Database
>Date: Mon, 06 Dec 1999 23:49:46 -0500
>MIME-Version: 1.0 (generated by tm-edit 7.108)
>From [email-masked] Mon Dec 06 20:55:06 1999
>Received: from [129.7.128.18] by hotmail.com (3.2) with ESMTP id 
>MHotMailBA15DE1A006FD82197B281078012BCC70; Mon Dec 06 20:54:51 1999
>Received: from sina.hpc.uh.edu ([email-masked] [129.7.3.5])by 
>spinoza.math.uh.edu (8.9.1/8.9.1) with ESMTP id WAB06004;Mon, 6 Dec 1999 
>22:53:12 -0600 (CST)
>Received: by sina.hpc.uh.edu (TLB v0.09a (1.20 tibbs 1996/10/09 22:03:07)); 
>Mon, 06 Dec 1999 22:51:06 -0600 (CST)
>Received: from dnsmx2pya.telcordia.com (dnsmx2pya.telcordia.com 
>[128.96.20.32])by sina.hpc.uh.edu (8.9.3/8.9.3) with ESMTP id WAA14888for 
><[email-masked]>; Mon, 6 Dec 1999 22:50:57 -0600 (CST)
>Received: from castle.mk.telcordia.com (castle.mk.telcordia.com 
>[128.96.133.172])by dnsmx2pya.telcordia.com (8.9.3/8.9.2) with ESMTP id 
>XAA22682;Mon, 6 Dec 1999 23:49:47 -0500 (EST)
>Received: from mk.telcordia.com (fork [128.96.128.32])by 
>castle.mk.telcordia.com (8.8.8/8.8.8) with ESMTP id XAA00228;Mon, 6 Dec 
>1999 23:49:47 -0500 (EST)
>Message-Id: <[email-masked]>
>In-reply-to: Your message of Mon, 06 Dec 1999 19:41:20 -0800.             
><[email-masked]>
>x-face: 
>H2G63xNIQ1G~92=">,W';}5I'2EN+pvbeFK2U`LLazP;W3/AU'795C^6M1;wX3''q-~||]i 
>=q\|l:fMk^4zF@^JHkw75M~[d)NKA},lfIOD=B'QWUuv_7Pu+j*']@]x]y'(Eyh}IAEhQDV@tJ?\E" 
><=..HSTdYCt'DevYza*qnf_0?9qelUgqeJkJA'7Zr<-NU
>Sender: [email-masked]
>Precedence: list
>X-Majordomo: 1.94.jlt7
>

---

From: Dan Espen <[email-masked]>
Date: Tue, 07 Dec 1999 09:07:15 -0500

> feasibility or possibility of doing something like this would be 

OK,  I'm not   an   expert on this,    but   fvwm pays  attention   to
MOTIF_WM_HINTS.   Search for "MWMDecorHints" and "MWMFunctionHints" in
the man page.  This may do what you want.

---

From: Pete Forman <[email-masked]>
Date: Tue, 7 Dec 1999 14:40:28 +0000 (GMT)

Leo Deck writes:
 > I realize that I am trying to do something that is probably out of
 > the ordinary.  Perhaps, it is not possible to do this.  Any insight
 > into the feasibility or possibility of doing something like this
 > would be appreciated.

The program appres does part of what you ask for.

    appres App1

will print out the resource records that get loaded into the database
of app1.

Of course for this to work appres has to have the same environment as
app1.  You'll need to take steps to set XENVIRONMENT,
XUSERFILESEARCHPATH, XAPPLRESDIR, etc.  On some OSs such as AIX, flags
to ps can print out a process's environment.  Which reminds me, appres
needs to execute on the same host as app1.
-- 
Pete Forman
Western Geophysical
[email-masked]
--
Visit the official FVWM web page at <URL: http://www.fvwm.org/>.
To unsubscribe from the list, send "unsubscribe fvwm" in the body of a
message to [email-masked].
To report problems, send mail to [email-masked].

---

From: Fuzzy Fox <[email-masked]>
Date: Tue, 7 Dec 1999 10:31:36 -0600

> Fvwm doesn't normally muck around with X resources, there are tools

Other window manglers, such as MWM, will notice certain resources in the
client's database, and react to them.  Back when I used to use MWM, I
had these sorts of resource settings:

    *oclock.clientDecoration:       none
    *xconsole.clientDecoration:     none
    *phone.clientDecoration:        -maximize -resizeh
    *xbiff.clientDecoration:        border
    *xclock.clientDecoration:       border
    *XLoad.clientDecoration:        border
    *xpostage.clientDecoration:     border
    mwm*iconbox*clientDecoration:   menu resizeh minimize

FVWM doesn't pay attention to these; it uses the "Style" directive,
which can be sensitive to the same sorts of resource names as the
application uses, so it is often possible to get the same effects,
although there is no "resource tree" capability.

I was never taught why the above worked, but just did it.  Now that I
look it over and think about it, I think the wildcards at the start of
the resource string allowed the setting to appear in MWM's resource
database, where it can pick them up.

But I dunno.  Been using FVWM too long now.  :)

-- 
   [email-masked] (Fuzzy Fox)     || "Good judgment comes from experience.
sometimes known as David DeSimone  ||  Experience comes from bad judgment."
  http://www.dallas.net/~fox/      ||                 -- Life Lessons
--
Visit the official FVWM web page at <URL: http://www.fvwm.org/>.
To unsubscribe from the list, send "unsubscribe fvwm" in the body of a
message to [email-masked].
To report problems, send mail to [email-masked].