On Mon, 2003-02-03 at 00:32, David Thompson wrote:
> One thing I was wondering was would you want to add the ability to 
> allow the height and width of the layout to be set by an X resource? 
> I found in the code where I could change it and was wondering if it 
> would make sense to make them X resources?
I'm not sure if it makes sense or not.  You can try it and
see if it improves the results you get.  

I've made them command line options (also X resources settable
in ~/DX so that you can avoid typing every time you start DX.)
If you make a setting that won't work, you get an error message.
I had tried to make the values as small as possible in order to
make the layout take as little space as possible, so really about
all you can do is spread it out more.

(N.B.  Although I've made them command line options that dxui
understands, the dx script will still reject them, so in order
to use them you must run ./dxui directly or you must put them
into ~/DX.)

You can set the amount by which nodes are spaced out vertically. The
default is 90. (units for all these are in pixels.)
    -autoLayoutHeight %d

You can set the amount by which disconnected subgraphs are spaced
horizontally.  The default is 30.
    -autoLayoutGroupSpacing %d
An example of what this does... You might have a macro with lots of
inputs and you might wire each input to a transmitter and put all
these in a page.  So you have lots of separate groups of nodes
with no wires entering or leaving each group.  So, the group spacing
value is the number of pixels by which these groups are separated
from one another.

You can set the amount by which individual nodes are spaced
horizontally.  The default is 15.
    -autoLayoutNodeSpacing %d
You can't really count on accomplishing anything with this option.
The layout code always tries to make arcs straight. If that isn't
possible due to a collision between nodes that would result, then
the code will separate nodes by this amount.

If you make settings that you use for all nets and
like better than the defaults, then
let me know what they are.  Perhaps the defaults should be changed.
I think you really can't make much improvement by changing these
values

Making the settings in ~/DX is like this:
./dxui -autoLayoutHeight 100
     becomes
DX*autoLayoutHeight: 100

Martin

Reply via email to