[haiku-3rdparty-dev] Re: Window size becomes 'indecreasable'

  • From: Ingo Weinhold <ingo_weinhold@xxxxxx>
  • To: haiku-3rdparty-dev@xxxxxxxxxxxxx
  • Date: Mon, 2 Oct 2017 20:42:37 +0200

On 01.10.2017 01:46, brian@tycho.email wrote:

On September 30, 2017 at 12:52 PM Humdinger <dmarc-noreply@xxxxxxxxxxxxx> wrote:

-> the string "~ Empty project ~" in fSizeInfo gets exchanged with
what space is left on the medium
-> the bar fSizeBar is adjusted accordingly
=> The window jumps to become a bit wider (I suspect because of the
changed fSizeInfo string), but now you also can't make the window any
narrower.

What might be wrong?

The B_AUTO_UPDATE_SIZE_LIMITS flag on the window is probably doing that. Try 
without the flag and set a reasonable size on the window like:
SetSizeLimits(400, B_SIZE_UNLIMITED, 300, B_SIZE_UNLIMITED);

That's what they call chaos programming. The mechanism you disable this way ensures that the size limits of your views propagate to your window. It is a very useful mechanism and off the top of my head I can't think of a reason for disabling it.

CU, Ingo


Other related posts: