Robert,

> And I could not resist to also do some of the other stuff,
> i.e. inheritance, filters, ... ;/

> Please test it!  If I get positive feedback it might be committed ...

Well I've tested it out and it all seems to work brilliantly.  Thanks!

My settings are now something like this:

  (setq bbdb-display-layout-alist 
      '((one-line (order phones net)
                  (name-end . 24) (toggle . t))
        (multi-line (parent . full-multi-line)
                    (omit timestamp)
                    (newline . nil)
                    (toggle . t))          
        (pop-up-multi-line 
         (omit addresses timestamp aka obsolete-net)
         (phones-filter . "work")
         (toggle . nil))
        (full-multi-line 
         (order net phones addresses mail-alias notes www t)
         (newline . t)
         (toggle . nil))))

which means as well as getting exactly what I wanted to see in the pop
up buffer, the field ordering in the full-multi-line layout is now
exactly the same as that of the multi-line layout, with the remaining
fields at the end.

My next tweak will probably be to write a filter function which
chooses one 'most useful' phone number or address to display in the
one line layout.
 
My only quibble with the design is that the 'filter' approach (while
doing exactly what I was asking for) doesn't allow you to put several
phones or address fields in the layout but still control the order
completely (say for instance you wanted work phone and address to
always come before home phone and address). This might arguably be
better done by allowing (phone-filter . FILTER) to appear inside the
omit or order option lists.  But maybe it's complex enough already as
it is - I can certainly live with it.

Some minor documentation typos which you might want to fix before
committing:

>   By default there are three different layout types used by BBDB, which are
                         ^^^^^ four now, not three!

> !  (parent . FILTER)               +               +              nil
               ^^^^^^  LAYOUT-NAME would make sense here

>   - toggle: controls if this layout is included when toggeling the display layout
                                                       ^^^^^^^^^ toggling       

> ! - newline: appends a newline to the formated record in multi-line layout.
                                        ^^^^^^^^ formatted


And to think that in the old days I used to occasionally edit the
.bbdb file by hand to reorder multiple phone fields...

Patrick



-------------------------------------------------------
This sf.net email is sponsored by: Influence the future 
of Java(TM) technology. Join the Java Community 
Process(SM) (JCP(SM)) program now. 
http://ads.sourceforge.net/cgi-bin/redirect.pl?sunm0004en
_______________________________________________
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/bbdb-info
BBDB Home Page: http://bbdb.sourceforge.net/

Reply via email to