Subject: Re: FVWM: mwm like icons?

From: Tim Phipps <[email-masked]>
Date: Wed, 28 May 1997 10:12:56 +0100 (BST)

>   1. No icon box
>   2. Specify where icons should go and in which direction they
>      should "grow".
> 
> Specifically, I like the first icon to go in the top right corner
> and have subsequent icons go to the left of that (i.e., I like the
> icons to be at the top of the screen from right to left).  Is this
> possible with fvwm?  If so, how?

Style "*" IconBox l t r b

Specifies a region in which to place icons where l, t, r & b are numbers for the 
left, top, right & bottom coordinates of the region respectively.  Unfortunately 
the icons are placed from left to right and then top to bottom (like 
"*iconPlacement: left top" placement in mwm) and there is no way to change it.

The IconBox style could be changed such that l, t, r & b become x1, y1, x2 & y2 
and icon placement could begin at the corner specified by x1, y1 but it would 
need an extra parameter to tell it which way to go (vertical or horizontal).

Cheers,
Tim Phipps.
--
Visit the official FVWM web page at <URL:http://www.hpc.uh.edu/fvwm/>.
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: Alfred von Campe <[email-masked]>
Date: Wed, 28 May 1997 09:23:30 -0400

Thanks to all about the hint for "Style IconBox".  I missed that
when I read the man page, probably because of the name (I don't
want an icon box).  However, I have two problems.  First, I can't
get it to work, and second, it doesn't really do what I want since
I want the icons to go from right to left.  I realize that there's
nothing I can do about the second problem (other than placing the
icons manually), so let this be an official request to add this in
a future release (if such a request is allowed on this list).

But I'd like to at least get the IconBox Style functionality to
work.  Here is the line I added to my .fvwm2rc file (this is cut
and pasted, so there are no typos):

Style "*"           IconBox +700 +0 -0 +200

I am defining a region in the upper right hand corner of the
screen for my icons.  I then restarted fvwm2 and iconified some
windows, but they didn't go in the upper right hand corner of the
screen.  I tried it with both existing windows as well as newly
created windows.  By default, the icons seem to go wherever the
mouse happens to be.  If I use the iconify button on the right
hand side of the titlebar, the icon goes where the top right
corner of the window used to be.  If I use Iconify from the menu
on the left of the titlebar, then the icon goes approximately
where the Iconify entry on the menu was on the screen.

One thing that would be helpful is if fvwm2 would at least force
icons to snap to a grid.  This way I could move them manually to
the top right corner of the screen and have them line up.

Sorry for such a lengthy message, and thanks for reading it if
you got this far.

Alfred
-- 
+------------------------------------------------------------+
| Phone: H: 508.448.6214, W: 508.490.6306, fax: 508.460.2888  \
|  Mail: Alfred von Campe, 402 Lowell Road, Groton, MA 01450   \
| Email: [email-masked]                                  \
+----------------------------------+-----------------------------+
| Why is common sense so uncommon? | I'd rather be flying N4381Q |
+----------------------------------+-----------------------------+
--
Visit the official FVWM web page at <URL:http://www.hpc.uh.edu/fvwm/>.
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: Morsy Cheikhrouhou <[email-masked]>
Date: Wed, 28 May 1997 15:41:59 +0200

Hello,

First, I would like to thank everyone who gave hints on how to have my own 
.fvwmrc while keeping the link our administrator put in everyone's home dir.

what i finally did is the following. I created my own .fvwmrc+ file where I 
put my own preferences. Then in my .xinitrc I put this line:

fvwm -f .fvwmrc.sys -f .fvwmrc+

where .fvwmrc.sys is previously generated using "awk" :

awk '....' .fvwmrc  > .fvwmrc.sys

(.fvwmrc is the file maintained by the administrator)
Thus, I still have my fvwm automatically updated while having my own 
preferences.

Thanks again.

  //////_______________________________________________________________________
   %%%%%| Morsy Cheikhrouhou                [email-masked]     |
 ////// |    PhD Student                        +33 (0) 4.93.00.26.48         |
  %%%%% | EURECOM Institute                     http://www.eurecom.fr         |
//////  | Corporate Communications       BP 193, 06904 Sophia Antipolis Cedex |
 %%%%%  |_____________________________________________________________________|
         ^_^  IF YOU WANT TO ATTAIN YOUR DREAMS, YOU MUST FIRST WAKEUP !   ^_^

---

From: Dan Espen <[email-masked]>
Date: Wed, 28 May 1997 10:28:37 -0400

> a future release (if such a request is allowed on this list).

Requests are common, but patches are often more productive.

> Style "*"           IconBox +700 +0 -0 +200

fvwm2 is not understanding "-0".  This works:

Style "*"           IconBox +700 +0 -1 +200

> where the Iconify entry on the menu was on the screen.

If fvwm2 doesn't understand the "style iconbox" it  just acts like the
iconbox is full and does what you describe.

> the top right corner of the screen and have them line up.

Usually with  fvwm2, if you want more  complex behavior,  the standard
answer is "use a module".  The built-in behaviors are typically pretty
basic.  Thats  not to say that  there is a module  that does  what you
want, I don't think there is, but there probably could be...

--
Dan Espen                                    Phone: (908) 699-5570
[email-masked]
444 Hoes Lane  Room RRC 1C-214
Piscataway, NJ 08854
--
Visit the official FVWM web page at <URL:http://www.hpc.uh.edu/fvwm/>.
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: Richard Lister <[email-masked]>
Date: Wed, 28 May 1997 10:55:25 -0400

On Wed, 28 May 1997 10:28:37 -0400
Dan Espen <[email-masked]> 

> fvwm2 is not understanding "-0".  This works:

I've wondered about this for a while ... bug or feature?

Ric

Richard J Lister, Georgetown Institute for Cognitive and Computational Sciences
Georgetown University Medical Center, Washington, DC.
Phone: 202-687 2878
Email: [email-masked] 
Web: http://www.giccs.georgetown.edu/
--
Visit the official FVWM web page at <URL:http://www.hpc.uh.edu/fvwm/>.
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: Wed, 28 May 1997 12:05:45 -0400

> I've wondered about this for a while ... bug or feature?

Lets call it  a  bug.  Heres a  lightly  tested patch that   fixes it.
Apply it in the fvwm sub-directory.  (The line  numbers could be off a
bit, I do have a few other patches applied.)

*** style.c	Wed May 28 11:54:09 1997
--- style.c.orig	Wed May 28 11:58:16 1997
***************
*** 293,305 ****
            for(i=0;i<num;i++)
            {
              while(isspace(*restofline))restofline++;
-             if (*restofline == '-') {   /* If leading minus sign */
-               if (i == 0 || i == 2) {   /* if a width */
-                 IconBox[i] += Scr.MyDisplayWidth;
-               } else {                  /* it must be a height */
-                 IconBox[i] += Scr.MyDisplayHeight;
-               } /* end width/height */
-             } /* end leading minus sign */
              while((!isspace(*restofline))&&(*restofline!= 0)&&
                    (*restofline != ',')&&(*restofline != '\n'))
                restofline++;
--- 293,298 ----
***************
*** 307,312 ****
--- 300,317 ----
            if(num !=4)
              fvwm_msg(ERR,"ProcessNewStyle",
                       "IconBox style requires 4 arguments!");
+           else
+           {
+             /* check for negative locations */
+             if(IconBox[0] < 0)
+               IconBox[0] += Scr.MyDisplayWidth;
+             if(IconBox[1] < 0)
+               IconBox[1] += Scr.MyDisplayHeight;
+             if(IconBox[2] < 0)
+               IconBox[2] += Scr.MyDisplayWidth;
+             if(IconBox[3] < 0)
+               IconBox[3] += Scr.MyDisplayHeight;
+           }
          }
          else if(mystrncasecmp(restofline,"ICON",4)==0)
          {