Skip to content
This repository has been archived by the owner on Jan 16, 2022. It is now read-only.

Minimal height for KryptonForm #202

Open
NatasaJ17 opened this issue Jul 3, 2019 · 3 comments
Open

Minimal height for KryptonForm #202

NatasaJ17 opened this issue Jul 3, 2019 · 3 comments

Comments

@NatasaJ17
Copy link

Hi,
Why minimal height for KryptonForms is set on 78 px.? I have collapse option on my forms where I set form height on 40 px.
I use old dlls and its possible to set that height, but now I want to use new dlls and I found this "defect".

@Smurf-IV
Copy link
Collaborator

Smurf-IV commented Jul 6, 2019

This is possibly related to the fixes for #54 and #74

The min Y is set by '

            mmi.ptMinTrackSize.Y = Math.Max(mmi.ptMinTrackSize.Y*2, MinimumSize.Height);

to allow the title bar, and a status bar to be sensibly displayed the mmi.ptMinTrackSize.Y*2 is used from the 'PI.MINMAXINFO mmi = (PI.MINMAXINFO)Marshal.PtrToStructure(m.LParam, typeof(PI.MINMAXINFO));' that is passed to the OnWM_GETMINMAXINFO(ref Message m) call.

Please be aware that on multi-monitor aware dpi, forcing a 40pixel minimum for the use of an extra-largefont on a 4k screen, is going to be rather small !

@Smurf-IV
Copy link
Collaborator

Smurf-IV commented Jul 6, 2019

The reason for the won't fix, is as above, However, if you want to override the the OnWM_GETMINMAXINFO(ref Message m) call, then you still can, and that will allow you to set a smaller minimum for the form you are wanting to control.

@PWagner1
Copy link
Collaborator

PWagner1 commented Jul 6, 2019

I agree, with 4k displays, setting sizes too small will result in microscopic UI results.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

3 participants