[Qt-interest] aspect-ratio for graphs
Murphy, Sean M.
sean.murphy at gd-ais.com
Thu Jul 15 20:41:29 CEST 2010
> With your help I am now closer to what I would like. I think that
> part of my problem was the wish that the frame would always have an
> aspect ratio of 1:1. This mechanism does not achieve this. If you
> take your example you can obviously squeeze the vertical height to
> make the frames no longer square, I was half hoping that by some magic
> the horizontal width could also be made to reduce, but I think that
> asking to much (or is it?).
> Anyway I guess it would be nice to be able to set the min-height of
> the main window to ensure that you cannot squeeze the height to the
> point of destroying the aspect ratio. I tried re-implementing the
> sizeHint() function for the frame but that did not help.
> Should I try catching the resize event (have not looked at this yet)
> and see if I can stop the main window from being resized to far using
> that method?
> My other problem is that depending on the mode I need to display
> either 6 graphs across the screen or just 3.
If you want to go the resize event route, you can look at this that I wrote a looooong time ago!
http://lists.trolltech.com/qt-interest/2004-10/thread00121-0.html
Sean
More information about the Qt-interest-old
mailing list