FS patch

2001-04-13 Thread David C. Thompson

I know that it may be too late for dia 0.87, but I have a patch
for the FS objects. It also touches app/disp_callbacks.c in one
small spot to allow Object menus to have submenus. It should not
affect any other objects.

The patch is about 24k uncompressed, so I've put it on the web
rather than attach it. It's at

http://madlab.me.utexas.edu/~dcthomp/dload/dia-FS-010413-1.patch.gz

The Changelog/CVS entry would be
-
* app/disp_callbacks.c:
   - Allow submenus in DiaMenus.
   - Don't require DiaMenu.title to be non-null (so that
 submenus aren't required to have titles)

* objects/FS/function.c:
   - object menu now has submenus, an almost complete list of
 standard-basis verbs, and a start on nouns.
   - box padding, dash length, and other visual attributes are
 scaled by the font size... eventually font height will be
 a function property.
   - draw functions with smaller font to make initial view hold
 a reasonable number of functions.
-

This is the second time I've submitted it. If there's something
wrong with it, please let me know so I can fix it.

David




Re: FS patch

2001-04-13 Thread Lars Clausen

On Fri, 13 Apr 2001, David C. Thompson wrote:

 I know that it may be too late for dia 0.87, but I have a patch
 for the FS objects. It also touches app/disp_callbacks.c in one
 small spot to allow Object menus to have submenus. It should not
 affect any other objects.
 
 The patch is about 24k uncompressed, so I've put it on the web
 rather than attach it. It's at
 
 http://madlab.me.utexas.edu/~dcthomp/dload/dia-FS-010413-1.patch.gz
 
 The Changelog/CVS entry would be
 -
 * app/disp_callbacks.c:
- Allow submenus in DiaMenus.
- Don't require DiaMenu.title to be non-null (so that
  submenus aren't required to have titles)
 
 * objects/FS/function.c:
- object menu now has submenus, an almost complete list of
  standard-basis verbs, and a start on nouns.
- box padding, dash length, and other visual attributes are
  scaled by the font size... eventually font height will be
  a function property.
- draw functions with smaller font to make initial view hold
  a reasonable number of functions.
 -
 
 This is the second time I've submitted it. If there's something
 wrong with it, please let me know so I can fix it.

Seems to work.  That sure is a lot of words in those menus.  Now I don't
know the FS system, but a submenu link Verb/Channel/Guide/Guide/Guide seems
funny to me.  Is this a standardized setup?
Also, it would be nice if the two Fn entries were togglemenus.

It will be in CVS in the morning.

Just so that we have somebody do it, I will make sure to apply any patch
sent to the list, unless somebody else objects to it.  I'll give one day
for objections, and send an acknowledgement when it's in CVS.

-Lars

-- 
Lars Clausen (http://shasta.cs.uiuc.edu/~lrclause) | Hrdgrim of Numenor
"I do not agree with a word that you say, but I| Retainer of Sir Kegg
will defend to the death your right to say it."|   of Westfield
--Evelyn Beatrice Hall paraphrasing Voltaire   | Chaos Berserker of Khorne




Re: FS patch

2001-04-13 Thread David Thompson

 Seems to work.  That sure is a lot of words in those menus.  Now I don't
 know the FS system, but a submenu link Verb/Channel/Guide/Guide/Guide seems
 funny to me.  Is this a standardized setup?
There is no standard setup I'm making it up as I go along (the
interface, that is -- the verbs form a "standard basis" that people
contend will cover every mechanical product). I struggled with the
menus, but
1. There's no way for a menu item to be a button and a submenu
2. Having a menu with a repeated word seemed just as awkward,
   especially since the menu is really there for people that are
   just learning, who will need to see the list of "refinements"
   of each word anyway.
If you have any suggestions, I'd be glad to hear them.

 Also, it would be nice if the two Fn entries were togglemenus.
I didn't see a way to do this with DiaMenu items. Want me to add
something to the DiaMenu struct for it, or is there a better way?

The other thing I've been thinking about is a way to add some
"document-class" specific functions to Dia. For instance, many
people want to add functions to Dia that only run on UML diagrams.
What if, in addition to 
  object name="blahdescriptionyadda/description/object
entries in sheets there were
  menu name="blah"descriptionyadda/description
function name="blah"descriptionyadda/description/function
  /menu
tags that would put up sheet-sensitive menu items only when that
sheet was selected?

 It will be in CVS in the morning.
Thanks!

 Just so that we have somebody do it, I will make sure to apply any patch
 sent to the list, unless somebody else objects to it.  I'll give one day
 for objections, and send an acknowledgement when it's in CVS.
I hope I didn't sound angry about it... it's just a little tedious to keep
a patch up to date when the CVS source is changing. (Not that CVS
maintainers have exciting, tedium-free lives :-)

David