← Back to team overview

kicad-developers team mailing list archive

Re: UIpolicies.txt


Dick Hollenbeck wrote:
>> I was thinking about a base dialog class that would be responsible
>> watching the control contents and automatically resizing the dialog when
>> they are changed. That would be tricky. A base dialog class that
>> provides the three function calls to resize the dialog and set the
>> minimum size would be trivial.
> Yes, that's what I was talking about. But I no longer think it is 
> necessary. These are just guidelines. I ran into a dialog last night 
> where none of this works, due to wxWidgets bugs or whatever. So to do 
> this automatically and unconditionally is not something I can support.

I wasn't suggesting unconditional support for this. As I expected,
there are cases where it doesn't work. I was trying to alert other
developers to a possible solution to layout differences between
platforms. Maybe the policy should be more generic to have developers
make sure that initial dialog layouts are sane. I think this should be
part of UIPolicies.txt. Remember the previous EESchema options dialog
where the word "Parameters" was truncated due to a sizer issue? I think
most users would expect the initial dialog size not to obscure any
control text and at least be usable without having to first resize it.

> A far more useful benefit to the user is to remember the size and 
> position of these dialogs on close, so it can come up with size he likes 
> according to how he set it previously. This is what I have been coding 
> recently and you can find it in DRC and Layer setup. The nice thing 
> here is that for a dual monitor setup, the dialog can be told to come up 
> on the second monitor, and with the size you last preferred.

Agreed. After the initial size, let the user configure the dialog the
way they want it. I see a base dialog class in your future;)


> As a low priority, the only to do item here is to maybe make the 
> external function to do the Fix() and SetMinimum() sequence and put it 
> into common.c, but this was your policy item, you can set its priority. 
> I'm saying it is not a high priority for me.
> Dick


Follow ups