Home » U++ Library support » U++ Widgets - General questions or Mixed problems » keeping fixed x/y ratio in a control
keeping fixed x/y ratio in a control [message #8142] |
Mon, 12 February 2007 19:20  |
exolon
Messages: 62 Registered: July 2006 Location: 53'21N 6'18W
|
Member |
|
|
Hi,
I'm using a Ctrl as a container for drawing. However, when I resize the window, drawings in the 'pane' become stretched and no longer on a 1:1 (or whatever i:j initial constant) x:y aspect.
This is especially obvious because I'm drawing text into the Ctrl as well, in a Drawing object. I suppose either I can forcibly scale the Drawing object to a sensible ratio before painting it, or I could find a way to dynamically resize the parent Ctrl to match the ratio of the minimum x/y value.
Is there an easy way to do this? I couldn't find a function to override in Ctrl that will allow me to adjust things when resizing - I've tried overriding SetRect and SetFrameRect in their various incarnations, but they don't seem to be called.
|
|
|
Goto Forum:
Current Time: Wed Jun 04 21:47:04 CEST 2025
Total time taken to generate the page: 3.37093 seconds
|